(window.webpackJsonp=window.webpackJsonp||[]).push([["store-categories"],{"3c6f":function(t,a,e){"use strict";a.a={HIDDEN_SERIES:[]}},fd2e:function(t,a,e){"use strict";e.r(a),e("14d9");var s=e("3c6f"),o=e("78bd");const i=s.a.HIDDEN_SERIES;a.default={namespaced:!0,state:{category:null,categories:[],whatYouLearns:[],homeCategory:[],homeCategoryId:null,categoryAll:{series:[],cat_name:"categories.all",cat_id:"all",cat_slug:"all"},categoriesAllWithSeries:[]},getters:{categoryById:t=>a=>t.categories.find(t=>t.cat_id===a),category:t=>t.category,categories:t=>t.categories,whatYouLearns:t=>t.whatYouLearns,homeCategory:t=>({...t.homeCategory,series:null==(t=t.homeCategory)||null==(t=t.series)?void 0:t.filter(t=>!i.includes(t.ser_id))})},actions:{async whatYouLearns({commit:t},{id:a=null}){t("setWhatYouLearnsState",null),a=await Object(o.e)({id:a}),200===a.status&&void 0!==a.data.data&&t("setWhatYouLearnsState",a.data.data)},async categories({commit:t},{id:a=null,filters:e=null}){const s=await Object(o.a)({id:a,filters:e});if(200===s.status&&void 0!==s.data.data)a&&t("setCategoryObject",s.data.data);else{const s=await Object(o.a)({id:a,filters:e});if(200===s.status&&void 0!==s.data.data)return t("setCategoriesState",s.data.data),s.data.data}},async getCategory({commit:t},{id:a=null}){a=await Object(o.a)({id:a}),200===a.status&&void 0!==a.data.data&&t("setHomeCategory",a.data.data)},async getCategoriesAllWithSeries({commit:t}){var a=await Object(o.b)();return 200===a.status&&void 0!==a.data.data&&(t("setCategoriesAllWithSeries",a.data.data),t("setCategoriesState",a.data.data)),a}},mutations:{setCategoryObject(t,a){t.category=a},setHomeCategory(t,a){t.homeCategory=a},setHomeCategoryId(t,a){t.homeCategoryId=a},setCategoriesState(t,a){t.categories=[],t.categories.push(...a),t.categories.push({series:[],cat_name:"categories.all",cat_id:"all",cat_slug:"all"})},setCategories(t,a){t.categories=a},setCategoryAll(t,a){t.categoryAll=a},setWhatYouLearnsState(t,a){for(var e in a)t.whatYouLearns.push(a[e])},setCategoriesAllWithSeries(t,a){t.categoriesAllWithSeries=a}}}}}]);