You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
549 B

  1. 'use strict'
  2. export default {
  3. namespaced: true,
  4. state: {
  5. busy: false,
  6. insertContent: ''
  7. },
  8. getters: {},
  9. mutations: {
  10. busyChange: (state, busyState) => { state.shown = busyState },
  11. insertContentChange: (state, newContent) => { state.insertContent = newContent }
  12. },
  13. actions: {
  14. busyStart({ commit }) { commit('busyChange', true) },
  15. busyStop({ commit }) { commit('busyChange', false) },
  16. insert({ commit }, content) {
  17. commit('insertContentChange', content)
  18. wikijs.$emit('editor/insert')
  19. }
  20. }
  21. }