root.js 647 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. // initial state
  2. const state = {
  3. config: {},
  4. settings: {
  5. limit: 20,
  6. expanded: [],
  7. expandedSeries: [],
  8. showCounts: true,
  9. showGenres: true,
  10. showDeleted: false,
  11. abCacheEnabled: true,
  12. langDefault: '',
  13. },
  14. };
  15. // getters
  16. const getters = {};
  17. // actions
  18. const actions = {};
  19. // mutations
  20. const mutations = {
  21. setConfig(state, value) {
  22. state.config = value;
  23. },
  24. setSettings(state, value) {
  25. state.settings = Object.assign({}, state.settings, value);
  26. },
  27. };
  28. export default {
  29. namespaced: true,
  30. state,
  31. getters,
  32. actions,
  33. mutations
  34. };