| Current Path : /home/jeromecohp/www/plugins/system/yooessentials/modules/core/app/models/ |
| Current File : /home/jeromecohp/www/plugins/system/yooessentials/modules/core/app/models/ConditionModel.js |
/* Essentials YOOtheme Pro (Freemium) 2.0.19 build 1026.0920; ZOOlanders https://www.zoolanders.com; Copyright (C) Joolanders, SL; http://www.gnu.org/licenses/gpl.html GNU/GPL */
import yootheme from 'yootheme';
import essentials from '../api';
export default {
name: 'ConditionModel',
data: () => ({
rules: essentials.customizer?.condition_rules || [],
}),
computed: {
conditionPanel() {
return yootheme.customizer.panels['yooessentials-condition'];
},
},
methods: {
openConditionPanel(props) {
if (!this.conditionPanel) {
throw new Error('Condition Panel Not Found');
}
this.$trigger('openDynamicPanel', {
...this.conditionPanel,
width: 450,
props,
});
},
},
};