From 811fe1cde3782069c51b95bf79989827d2ea758e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tu=C4=9F=C3=A7e=20K=C3=BC=C3=A7=C3=BCko=C4=9Flu?= Date: Tue, 23 May 2023 12:15:04 +0300 Subject: [PATCH] Refactor #3965 - BaseComponent update --- components/lib/basecomponent/BaseComponent.vue | 3 +++ 1 file changed, 3 insertions(+) diff --git a/components/lib/basecomponent/BaseComponent.vue b/components/lib/basecomponent/BaseComponent.vue index c156da97b..da4e0e2c1 100644 --- a/components/lib/basecomponent/BaseComponent.vue +++ b/components/lib/basecomponent/BaseComponent.vue @@ -54,6 +54,9 @@ export default { cx(key = '', params = {}) { return !this.isUnstyled ? ObjectUtils.getItemValue(this.getOption(this.$options.css && this.$options.css.classes, key), { instance: this, props: this.$props, state: this.$data, ...params }) : undefined; }, + cxo(obj = {}, key = '', params = {}) { + return !this.isUnstyled ? ObjectUtils.getItemValue(this.getOption(obj.css && obj.css.classes, key), { instance: obj, props: obj && obj.props, state: obj && obj.data, ...params }) : undefined; + }, sx(key = '', when = true, params = {}) { if (when) { const self = ObjectUtils.getItemValue(this.getOption(this.$options.css && this.$options.css.inlineStyles, key), { instance: this, props: this.$props, state: this.$data, ...params });