@syncfusion/ej2-vue-base 19.4.56 → 20.1.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"ej2-vue-base.es2015.js","sources":["../src/es6/component-base.js","../src/es6/component-decorator.js","../src/es6/template.js","../src/es6/index.js"],"sourcesContent":["/**\n * Vue Component Base\n */\nimport { isNullOrUndefined, extend, getValue } from '@syncfusion/ej2-base';\nimport * as Vue3 from 'vue-class-component';\nimport * as Vue2 from 'vue';\nimport Vue from 'vue';\nexport const aVue = _interopRequireWildcard(Vue2);\nexport function _interopRequireWildcard(obj) {\n if (obj && obj.__esModule) {\n return obj;\n }\n else {\n let newObj = {};\n if (obj != null) {\n for (let key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key))\n newObj[key] = obj[key];\n }\n }\n newObj.default = obj;\n return newObj;\n }\n}\nexport const allVue = aVue;\nexport const gh = allVue.h;\nexport const isExecute = gh ? false : true;\nlet vueImport;\nif (!isExecute || parseInt(allVue.version) < 3) {\n vueImport = Vue3.Vue;\n}\nelse {\n vueImport = Vue;\n}\nexport class ComponentBase extends vueImport {\n constructor() {\n super(arguments);\n this.hasInjectedModules = false;\n this.hasChildDirective = false;\n this.childDirObjects = '';\n }\n created() {\n if (!this.propKeys) {\n return;\n }\n for (let prop of this.propKeys) {\n this.ej2Instances.addEventListener(prop, (args) => {\n this.$emit(prop, args);\n });\n }\n let injectables = getValue('$root.$options.provide', this);\n let vueInjectables = getValue('$parent.$options.provide', this);\n if (this.hasInjectedModules && !isExecute) {\n let prevModule = [];\n if (injectables) {\n prevModule = injectables[this.ej2Instances.getModuleName()] || [];\n }\n else if (vueInjectables) {\n prevModule = this.getInjectedServices() || [];\n }\n let curModule = this.ej2Instances.getInjectedModules() || [];\n for (let mod of curModule) {\n if (prevModule.indexOf(mod) === -1) {\n prevModule.push(mod);\n }\n }\n this.ej2Instances.injectedModules = prevModule;\n }\n }\n mounted() {\n let cusEle = this.$el ? this.$el.querySelectorAll(\"div.e-directive\") : null;\n if (gh && cusEle) {\n for (let i = 0; i < cusEle.length; i++) {\n cusEle[i].parentElement && cusEle[i].parentElement.removeChild(cusEle[i]);\n }\n }\n this.ej2Instances.isVue = true;\n this.ej2Instances.isVue3 = this.isVue3;\n this.ej2Instances.vueInstance = this;\n if (this.isVue3) {\n this.ej2Instances.ej2Instances = this.ej2Instances;\n this.ej2Instances.referModels = this.models;\n }\n this.ej2Instances.appendTo(this.$el);\n }\n getInjectedServices() {\n let ret = [];\n let provide;\n if (this.$vnode) {\n provide = getValue('$vnode.context.$options.provide', this);\n }\n else if (this.$parent) {\n provide = getValue('$parent.$options.provide', this);\n }\n if (provide) {\n // tslint:disable:no-any\n let injectables = provide;\n if (typeof provide === 'function') {\n // tslint:disable:no-any\n if (this.$vnode) {\n injectables = this.$vnode.context.$options.provide();\n }\n else if (this.$parent) {\n injectables = this.$parent.$options.provide();\n }\n }\n ret = injectables[this.ej2Instances.getModuleName()] || [];\n }\n return ret;\n }\n updated() {\n if (this.hasChildDirective) {\n let childKey = {};\n this.fetchChildPropValues(childKey);\n let curChildDir = JSON.stringify(childKey);\n if (this.childDirObjects !== curChildDir) {\n this.childDirObjects = curChildDir;\n this.assignValueToWrapper(childKey, false);\n }\n }\n }\n beforeDestroy() {\n let tempBeforeDestroyThis = this;\n tempBeforeDestroyThis.ej2Instances.destroy();\n tempBeforeDestroyThis.$el.style.visibility = 'hidden';\n tempBeforeDestroyThis = null;\n }\n bindProperties() {\n let options = {};\n for (let prop of this.propKeys) {\n if ((!isNullOrUndefined(this[prop]) && !this.isVue3) || (this[0] && !isNullOrUndefined(this[0][0]) && !isNullOrUndefined(this[0][0][prop]))) {\n options[prop] = !this.isVue3 ? this[prop] : this[0][0][prop];\n }\n }\n if (this.hasChildDirective) {\n this.fetchChildPropValues(options);\n }\n if (this.hasInjectedModules) {\n let prevModule = this.getInjectedServices() || [];\n let curModule = this.ej2Instances.getInjectedModules() || [];\n for (let mod of curModule) {\n if (prevModule.indexOf(mod) === -1) {\n prevModule.push(mod);\n }\n }\n this.ej2Instances.injectedModules = prevModule;\n }\n this.assignValueToWrapper(options);\n }\n assignValueToWrapper(option, silent) {\n this.ej2Instances.setProperties(extend({}, {}, option, true), isNullOrUndefined(silent) ? true : silent);\n }\n fetchChildPropValues(childOption) {\n let dirProps = {};\n if (!this.isVue3) {\n dirProps = this.getDirectiveValues(this.$slots.default, this.tagMapper || {}, this.tagNameMapper || {});\n }\n else {\n let propRef;\n if (this[0] && this[0][1].slots.default) {\n propRef = this[0][1].slots.default();\n }\n else if (this && this.$slots) {\n propRef = this.$slots.default();\n }\n if (propRef) {\n for (let i = 0; i < propRef.length; i++) {\n if (propRef[i].type.methods) {\n let key = propRef[i].type.methods.getTag().replace(\"e-\", \"\");\n let ref = this.resolveArrayDirectives(propRef[i].children, key);\n let splitKeys = key.split('-');\n let controlName = this.ej2Instances.getModuleName().toLowerCase();\n let keyRef = (splitKeys.length > 1 && controlName.indexOf(splitKeys[0]) > -1) ? splitKeys[1] : splitKeys[0];\n keyRef = keyRef.replace(controlName, '');\n if (controlName == \"splitter\" && keyRef == \"panes\") {\n keyRef = \"paneSettings\";\n }\n else if (controlName == \"bulletchart\" && keyRef == \"range\") {\n keyRef = \"ranges\";\n }\n dirProps[keyRef] = ref[key];\n }\n }\n }\n else {\n return;\n }\n }\n if (!this.childDirObjects) {\n this.childDirObjects = JSON.stringify(dirProps);\n }\n for (let dirProp of Object.keys(dirProps)) {\n childOption[dirProp] = dirProps[dirProp];\n }\n }\n resolveArrayDirectives(slots, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = {};\n items[tagName] = [];\n for (const childSlot of slot) {\n let tempObj = {};\n let tagRef = childSlot.type.methods ? childSlot.type.methods.getTag() : tagName;\n if (childSlot.children) {\n let key;\n innerDirValues = this.resolveComplexDirs(childSlot.children, this.tagMapper[\"e-\" + tagName], tagRef);\n if (innerDirValues.length) {\n tempObj = innerDirValues;\n }\n else {\n for (var i = 0; i < Object.keys(innerDirValues).length; i++) {\n key = Object.keys(innerDirValues)[i];\n tempObj[key] = innerDirValues[key];\n }\n ;\n }\n }\n if (childSlot.props) {\n Object.keys(childSlot.props).forEach((key) => {\n tempObj[key] = childSlot.props[key];\n });\n }\n if ((/[s]\\b/).test(tagRef) && innerDirValues) {\n if (!(/[s]\\b/).test(tagName) || innerDirValues.length) {\n items[tagName] = tempObj;\n }\n else {\n items[tagName].push(tempObj);\n }\n }\n else {\n items[tagName].push(tempObj);\n }\n }\n return items;\n }\n resolveComplexDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = {};\n for (const childSlot of slot) {\n let tagRef;\n let tag;\n if (tagObject[tagName]) {\n tagRef = Object.keys(tagObject[tagName]);\n tag = tagRef.find((key) => tagObject[tagName][key] ===\n childSlot.type.methods.getTag().replace(/[s]\\b/, \"\"));\n tag = tag\n ? tag.replace(\"e-\", \"\")\n : childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (this.ej2Instances.getModuleName().toLowerCase() == \"diagram\" && tag.indexOf('annotations') != -1) {\n tag = 'annotations';\n }\n }\n if (childSlot.children) {\n innerDirValues = this.resolveComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n if (!items[tag]) {\n items[tag] = [];\n }\n if (innerDirValues.length > 1) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n }\n if (slot.length > 1) {\n items = Object.keys(items).length == 0 && !items.length ? [] : items;\n if (childSlot.props) {\n items.push(childSlot.props);\n }\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n resolveComplexInnerDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = slot.length > 1 ? [] : {};\n for (const childSlot of slot) {\n let tag = childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (childSlot.children) {\n innerDirValues = this.resolveMultilevelComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n if ((/[s]\\b/).test(tag) || slot.length > 1) {\n if ((/[s]\\b/).test(tag)) {\n items[tag] = !items[tag] ? [] : items[tag];\n if (innerDirValues.length) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n }\n else if (innerDirValues) {\n items.push(innerDirValues);\n }\n }\n else {\n items = innerDirValues ? innerDirValues : items;\n }\n }\n if (slot.length > 1 && childSlot.props) {\n if (items.length >= 0) {\n items.push(childSlot.props);\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n resolveMultilevelComplexInnerDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = slot.length > 1 ? [] : {};\n for (const childSlot of slot) {\n let tag = childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (childSlot.children) {\n innerDirValues = this.resolveComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n }\n if ((/[s]\\b/).test(tag)) {\n items[tag] = !items[tag] ? [] : items[tag];\n if (innerDirValues.length) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n if (childSlot.props) {\n items[tag].push(childSlot.props);\n }\n }\n else {\n items = innerDirValues;\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n getDirectiveValues(tagDirectives, tagMapper, tagNameMapper) {\n let keyTags = Object.keys(tagMapper);\n let dir = {};\n if (tagDirectives) {\n for (let tagDirective of tagDirectives) {\n if (tagDirective.componentOptions && tagDirective.componentOptions.children && tagDirective.componentOptions.tag) {\n let dirTag = tagDirective.componentOptions.tag;\n if (keyTags.indexOf(dirTag) !== -1) {\n let tagName = tagNameMapper[dirTag] ? tagNameMapper[dirTag] : dirTag;\n dir[tagName.replace('e-', '')] = [];\n for (let tagDirChild of tagDirective.componentOptions.children) {\n let retObj = this.getVNodeValue(tagDirChild, tagMapper[dirTag], tagNameMapper);\n if (Object.keys(retObj).length !== 0) {\n dir[tagName.replace('e-', '')].push(retObj);\n }\n }\n }\n }\n }\n }\n return dir;\n }\n getMultiLevelDirValue(tagDirectories, tagKey, tagNameMapper) {\n let mulObj = {};\n for (let tagDir of tagDirectories) {\n if (tagDir.componentOptions) {\n let key = tagDir.componentOptions.tag;\n let tagName = tagNameMapper[key] ? tagNameMapper[key] : key;\n mulObj[tagName.replace('e-', '')] = [];\n if (tagDir.componentOptions && tagDir.componentOptions.children) {\n for (let tagDirChild of tagDir.componentOptions.children) {\n let mulLevObj = this.getVNodeValue(tagDirChild, tagKey[key], tagNameMapper);\n if (Object.keys(mulLevObj).length !== 0) {\n mulObj[tagName.replace('e-', '')].push(mulLevObj);\n }\n }\n }\n }\n }\n return mulObj;\n }\n getVNodeValue(tagDirective, tagKey, tagNameMapper) {\n let ret = {};\n if (tagDirective.componentOptions) {\n let dirTag = tagDirective.componentOptions.tag;\n if (typeof tagKey === 'string' && dirTag === tagKey && tagDirective.data) {\n ret = tagDirective.data.attrs ? this.getCamelCaseProps(tagDirective.data.attrs) : this.getCamelCaseProps(tagDirective.data);\n }\n else if (typeof tagKey === 'object') {\n if (tagDirective.componentOptions.children && (Object.keys(tagKey).indexOf(dirTag) !== -1)) {\n ret = this.getMultiLevelDirValue(tagDirective.componentOptions.children, tagKey[dirTag], tagNameMapper);\n }\n if (tagDirective.data && tagDirective.data.attrs) {\n ret = extend(ret, this.getCamelCaseProps(tagDirective.data.attrs));\n }\n }\n }\n return ret;\n }\n /**\n * convert kebab case directive props to camel case\n */\n getCamelCaseProps(props) {\n let retProps = {};\n for (let prop of Object.keys(props)) {\n retProps[prop.replace(/-[a-z]/g, (e) => { return e[1].toUpperCase(); })] = props[prop];\n }\n return retProps;\n }\n dataBind() {\n this.ej2Instances.dataBind();\n }\n setProperties(arg, muteOnChange) {\n return this.ej2Instances.setProperties(arg, muteOnChange);\n }\n}\n","/**\n * Vue Component Base\n */\nimport Vue from 'vue';\n// import { Base, Component as EJ2Component, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { ComponentBase } from './component-base';\nexport let $internalHooks = [\n 'data',\n 'beforeCreate',\n 'created',\n 'beforeMount',\n 'mounted',\n 'beforeDestroy',\n 'destroyed',\n 'beforeUpdate',\n 'updated',\n 'activated',\n 'deactivated',\n 'render',\n 'errorCaptured' // 2.5\n];\nexport function getProps(options = {}) {\n if (options.props) {\n for (let prop of options.props) {\n (options.newprops || (options.newprops = {}))[prop] = {};\n (options.watch || (options.watch = {}))[prop] = function (newVal) {\n this.ej2Instances[prop] = newVal;\n if (this.dataBind && (options.name !== 'DateRangePickerComponent')) {\n this.dataBind();\n }\n };\n }\n }\n return [options.newprops, options.watch];\n}\nexport function EJComponentDecorator(options, isExecute) {\n if (!isExecute) {\n return;\n }\n return function (Component) {\n return EJcomponentFactory(Component, options);\n };\n}\nexport function EJcomponentFactory(Component, options = {}) {\n options.name = options.name || Component._componentTag || Component.name;\n // prototype props.\n const proto = Component.prototype;\n if (options.props) {\n for (let prop of options.props) {\n (options.props || (options.props = {}))[prop] = {};\n (options.watch || (options.watch = {}))[prop] = function (newVal) {\n this.ej2Instances[prop] = newVal;\n if (this.dataBind && (options.name !== 'DateRangePickerComponent')) {\n this.dataBind();\n }\n };\n }\n }\n Object.getOwnPropertyNames(proto).forEach(function (key) {\n // hooks\n if (key === 'constructor') {\n return;\n }\n if ($internalHooks.indexOf(key) > -1) {\n options[key] = proto[key];\n return;\n }\n const descriptor = Object.getOwnPropertyDescriptor(proto, key);\n if (typeof descriptor.value === 'function') {\n // methods\n (options.methods || (options.methods = {}))[key] = descriptor.value;\n }\n else if (descriptor.get || descriptor.set) {\n // computed properties\n (options.computed || (options.computed = {}))[key] = {\n get: descriptor.get,\n set: descriptor.set\n };\n }\n });\n Object.getOwnPropertyNames(ComponentBase.prototype).forEach(function (key) {\n if ($internalHooks.indexOf(key) > -1) {\n options[key] = proto[key];\n return;\n }\n });\n (options.mixins || (options.mixins = [])).push({\n data() {\n return collectDataFromConstructor(this, Component);\n }\n });\n // decorate options\n const decorators = Component.__decorators__;\n if (decorators) {\n decorators.forEach(Function(options));\n delete Component.__decorators__;\n }\n // find super\n const superProto = Object.getPrototypeOf(Component.prototype);\n const Super = superProto instanceof Vue\n ? superProto.constructor\n : Vue;\n const Extended = Super.extend(options);\n return Extended;\n}\nfunction collectDataFromConstructor(vm, Component) {\n Component.prototype._init = function () {\n var _this = this;\n var keys = Object.getOwnPropertyNames(vm);\n if (vm.$options.props) {\n for (var key in vm.$options.props) {\n if (!vm.hasOwnProperty(key)) {\n keys.push(key);\n }\n }\n }\n keys.forEach(function (key) {\n if (key.charAt(0) !== '_') {\n Object.defineProperty(_this, key, {\n get: function () { return vm[key]; },\n set: function (value) { return vm[key] = value; }\n });\n }\n });\n };\n var data = new Component();\n var plainData = {};\n Object.keys(data).forEach(function (key) {\n if (data[key] !== undefined) {\n plainData[key] = data[key];\n }\n });\n return plainData;\n}\n","import Vue from \"vue\";\nimport { setTemplateEngine, getTemplateEngine, getUniqueID, createElement, detach, extend, getValue, } from \"@syncfusion/ej2-base\";\nimport { allVue, gh } from \"./component-base\";\n// tslint:disable:no-any\nlet stringCompiler = getTemplateEngine();\nexport function compile(templateElement, helper) {\n let that = this;\n if (typeof templateElement === \"string\") {\n return stringCompiler(templateElement, helper);\n }\n else {\n return (data, context, propName) => {\n let pid = getUniqueID(\"templateParentDiv\");\n let id = getUniqueID(\"templateDiv\");\n let ele = createElement(\"div\", {\n id: pid,\n innerHTML: '<div id=\"' + id + '\"></div>',\n });\n document.body.appendChild(ele);\n let tempObj = templateElement.call(that, {});\n let returnEle;\n if (context) {\n if (gh) {\n let object = tempObj;\n let propsData = getValue(\"template.propsData\", tempObj);\n let dataObj = {\n data: { data: extend(tempObj.data || {}, data) },\n parent: context.vueInstance,\n };\n if (!object.template) {\n object.template = object[Object.keys(object)[0]];\n }\n let templateCompRef;\n if (object.template.extends) {\n templateCompRef = object.template.extends._context.components.template;\n }\n else {\n templateCompRef = object.template._context.components[templateElement.name];\n if (!templateCompRef) {\n let key = Object.keys(object.template._context.components)[0];\n templateCompRef = object.template._context.components[key];\n }\n }\n let tempRef;\n if (propsData) {\n tempRef = Object.assign(templateCompRef.data(), propsData);\n }\n else {\n tempRef = Object.assign(templateCompRef.data(), dataObj.data);\n if (templateCompRef.components) {\n let objkeys = Object.keys(templateCompRef.components) || [];\n for (let objstring of objkeys) {\n let intComponent = templateCompRef.components[objstring];\n if (intComponent && intComponent.data) {\n let tempRef2 = Object.assign(intComponent.data(), dataObj.data);\n intComponent.data = function () { return tempRef2; };\n }\n }\n }\n }\n templateCompRef.data = function () { return tempRef; };\n allVue\n .createApp(templateCompRef)\n .mount(\"#\" + id);\n returnEle = ele.childNodes;\n detach(ele);\n }\n else {\n let templateFunction = tempObj.template;\n let propsData = getValue(\"template.propsData\", tempObj);\n let dataObj = {\n data: { data: extend(tempObj.data || {}, data) },\n parent: context.vueInstance,\n };\n if (propsData) {\n templateFunction = tempObj.template.extends;\n dataObj.propsData = propsData;\n }\n if (typeof templateFunction !== \"function\") {\n templateFunction = Vue.extend(templateFunction);\n }\n let templateVue = new templateFunction(dataObj);\n // let templateVue = new Vue(tempObj.template);\n // templateVue.$data.data = extend(tempObj.data, data);\n templateVue.$mount(\"#\" + id);\n returnEle = ele.childNodes;\n if (context.vueInstance) {\n let templateInstance = context.vueInstance.templateCollection;\n if (!templateInstance) {\n context.vueInstance.templateCollection = {};\n templateInstance = context.vueInstance.templateCollection;\n }\n if (propName) {\n if (!templateInstance[propName]) {\n templateInstance[propName] = [];\n }\n templateInstance[propName].push(returnEle[0]);\n }\n }\n detach(ele);\n }\n }\n return returnEle || [];\n };\n }\n}\nsetTemplateEngine({ compile: compile });\n","/**\n * index for component base\n */\nexport * from './component-base';\nexport * from './component-decorator';\nexport * from './template';\n"],"names":["Vue2","Vue3.Vue","Vue","isExecute"],"mappings":";;;;;AAAA;;;AAGA,AAIO,MAAM,IAAI,GAAG,uBAAuB,CAACA,KAAI,CAAC,CAAC;AAClD,AAAO,SAAS,uBAAuB,CAAC,GAAG,EAAE;IACzC,IAAI,GAAG,IAAI,GAAG,CAAC,UAAU,EAAE;QACvB,OAAO,GAAG,CAAC;KACd;SACI;QACD,IAAI,MAAM,GAAG,EAAE,CAAC;QAChB,IAAI,GAAG,IAAI,IAAI,EAAE;YACb,KAAK,IAAI,GAAG,IAAI,GAAG,EAAE;gBACjB,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC;oBAC9C,MAAM,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC;aAC9B;SACJ;QACD,MAAM,CAAC,OAAO,GAAG,GAAG,CAAC;QACrB,OAAO,MAAM,CAAC;KACjB;CACJ;AACD,AAAO,MAAM,MAAM,GAAG,IAAI,CAAC;AAC3B,AAAO,MAAM,EAAE,GAAG,MAAM,CAAC,CAAC,CAAC;AAC3B,AAAO,MAAM,SAAS,GAAG,EAAE,GAAG,KAAK,GAAG,IAAI,CAAC;AAC3C,IAAI,SAAS,CAAC;AACd,IAAI,CAAC,SAAS,IAAI,QAAQ,CAAC,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE;IAC5C,SAAS,GAAGC,GAAQ,CAAC;CACxB;KACI;IACD,SAAS,GAAGC,cAAG,CAAC;CACnB;AACD,AAAO,MAAM,aAAa,SAAS,SAAS,CAAC;IACzC,WAAW,GAAG;QACV,KAAK,CAAC,SAAS,CAAC,CAAC;QACjB,IAAI,CAAC,kBAAkB,GAAG,KAAK,CAAC;QAChC,IAAI,CAAC,iBAAiB,GAAG,KAAK,CAAC;QAC/B,IAAI,CAAC,eAAe,GAAG,EAAE,CAAC;KAC7B;IACD,OA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C,GAAG,EAAE,CAAC;6BACnC;4BACD,gBAAgB,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;yBACjD;qBACJ;oBACD,MAAM,CAAC,GAAG,CAAC,CAAC;iBACf;aACJ;YACD,OAAO,SAAS,IAAI,EAAE,CAAC;SAC1B,CAAC;KACL;CACJ;AACD,iBAAiB,CAAC,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,CAAC;;AC1GxC;;GAEG;;;;"}
1
+ {"version":3,"file":"ej2-vue-base.es2015.js","sources":["../src/es6/component-base.js","../src/es6/component-decorator.js","../src/es6/template.js","../src/es6/index.js"],"sourcesContent":["/**\n * Vue Component Base\n */\nimport { isNullOrUndefined, extend, getValue } from '@syncfusion/ej2-base';\nimport * as Vue3 from 'vue-class-component';\nimport * as Vue2 from 'vue';\nimport Vue from 'vue';\nexport const aVue = _interopRequireWildcard(Vue2);\nexport function _interopRequireWildcard(obj) {\n if (obj && obj.__esModule) {\n return obj;\n }\n else {\n let newObj = {};\n if (obj != null) {\n for (let key in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, key))\n newObj[key] = obj[key];\n }\n }\n newObj.default = obj;\n return newObj;\n }\n}\nexport const allVue = aVue;\nexport const gh = allVue.h;\nexport const isExecute = gh ? false : true;\nlet vueImport;\nif (!isExecute || parseInt(allVue.version) < 3) {\n vueImport = Vue3.Vue;\n}\nelse {\n vueImport = Vue;\n}\nexport class ComponentBase extends vueImport {\n constructor() {\n super(arguments);\n this.hasInjectedModules = false;\n this.hasChildDirective = false;\n this.childDirObjects = '';\n }\n created() {\n if (!this.propKeys) {\n return;\n }\n for (let prop of this.propKeys) {\n this.ej2Instances.addEventListener(prop, (args) => {\n this.$emit(prop, args);\n });\n }\n let injectables = getValue('$root.$options.provide', this);\n let vueInjectables = getValue('$parent.$options.provide', this);\n if (this.hasInjectedModules && !isExecute) {\n let prevModule = [];\n if (injectables) {\n prevModule = injectables[this.ej2Instances.getModuleName()] || [];\n }\n else if (vueInjectables) {\n prevModule = this.getInjectedServices() || [];\n }\n let curModule = this.ej2Instances.getInjectedModules() || [];\n for (let mod of curModule) {\n if (prevModule.indexOf(mod) === -1) {\n prevModule.push(mod);\n }\n }\n this.ej2Instances.injectedModules = prevModule;\n }\n }\n mounted() {\n let cusEle = this.$el ? this.$el.querySelectorAll(\"div.e-directive\") : null;\n if (gh && cusEle) {\n for (let i = 0; i < cusEle.length; i++) {\n cusEle[i].parentElement && cusEle[i].parentElement.removeChild(cusEle[i]);\n }\n }\n this.ej2Instances.isVue = true;\n this.ej2Instances.isVue3 = this.isVue3;\n this.ej2Instances.vueInstance = this;\n if (this.isVue3) {\n this.ej2Instances.ej2Instances = this.ej2Instances;\n this.ej2Instances.referModels = this.models;\n }\n this.ej2Instances.appendTo(this.$el);\n }\n getInjectedServices() {\n let ret = [];\n let provide;\n if (this.$vnode) {\n provide = getValue('$vnode.context.$options.provide', this);\n }\n else if (this.$parent) {\n provide = getValue('$parent.$options.provide', this);\n }\n if (provide) {\n // tslint:disable:no-any\n let injectables = provide;\n if (typeof provide === 'function') {\n // tslint:disable:no-any\n if (this.$vnode) {\n injectables = this.$vnode.context.$options.provide();\n }\n else if (this.$parent) {\n injectables = this.$parent.$options.provide();\n }\n }\n ret = injectables[this.ej2Instances.getModuleName()] || [];\n }\n return ret;\n }\n updated() {\n if (this.hasChildDirective) {\n let childKey = {};\n this.fetchChildPropValues(childKey);\n let curChildDir = JSON.stringify(childKey);\n if (this.childDirObjects !== curChildDir) {\n this.childDirObjects = curChildDir;\n this.assignValueToWrapper(childKey, false);\n }\n }\n }\n beforeDestroy() {\n let tempBeforeDestroyThis = this;\n tempBeforeDestroyThis.ej2Instances.destroy();\n tempBeforeDestroyThis.$el.style.visibility = 'hidden';\n tempBeforeDestroyThis = null;\n }\n bindProperties() {\n let options = {};\n for (let prop of this.propKeys) {\n if ((!isNullOrUndefined(this[prop]) && !this.isVue3) || (this[0] && !isNullOrUndefined(this[0][0]) && !isNullOrUndefined(this[0][0][prop]))) {\n options[prop] = !this.isVue3 ? this[prop] : this[0][0][prop];\n }\n }\n if (this.hasChildDirective) {\n this.fetchChildPropValues(options);\n }\n if (this.hasInjectedModules) {\n let prevModule = this.getInjectedServices() || [];\n let curModule = this.ej2Instances.getInjectedModules() || [];\n for (let mod of curModule) {\n if (prevModule.indexOf(mod) === -1) {\n prevModule.push(mod);\n }\n }\n this.ej2Instances.injectedModules = prevModule;\n }\n this.assignValueToWrapper(options);\n }\n assignValueToWrapper(option, silent) {\n this.ej2Instances.setProperties(extend({}, {}, option, true), isNullOrUndefined(silent) ? true : silent);\n }\n fetchChildPropValues(childOption) {\n let dirProps = {};\n if (!this.isVue3) {\n dirProps = this.getDirectiveValues(this.$slots.default, this.tagMapper || {}, this.tagNameMapper || {});\n }\n else {\n let propRef;\n if (this[0] && this[0][1].slots.default) {\n propRef = this[0][1].slots.default();\n }\n else if (this && this.$) {\n if (this.$.slots) {\n propRef = this.$.slots.default();\n }\n }\n if (propRef) {\n for (let i = 0; i < propRef.length; i++) {\n if (propRef[i].type.methods) {\n let key = propRef[i].type.methods.getTag().replace(\"e-\", \"\");\n let ref = this.resolveArrayDirectives(propRef[i].children, key);\n let splitKeys = key.split('-');\n let controlName = this.ej2Instances.getModuleName().toLowerCase();\n let keyRef = (splitKeys.length > 1 && controlName.indexOf(splitKeys[0]) > -1) ? splitKeys[1] : splitKeys[0];\n keyRef = keyRef.replace(controlName, '');\n if (controlName == \"splitter\" && keyRef == \"panes\") {\n keyRef = \"paneSettings\";\n }\n else if (controlName == \"bulletchart\" && keyRef == \"range\") {\n keyRef = \"ranges\";\n }\n else if (controlName == \"schedule\" && keyRef == \"header\") {\n keyRef = \"headerRows\";\n }\n dirProps[keyRef] = ref[key];\n }\n }\n }\n else {\n return;\n }\n }\n if (!this.childDirObjects) {\n this.childDirObjects = JSON.stringify(dirProps);\n }\n for (let dirProp of Object.keys(dirProps)) {\n childOption[dirProp] = dirProps[dirProp];\n }\n }\n resolveArrayDirectives(slots, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = {};\n items[tagName] = [];\n for (const childSlot of slot) {\n let tempObj = {};\n let tagRef = childSlot.type.methods ? childSlot.type.methods.getTag() : tagName;\n if (childSlot.children) {\n let key;\n innerDirValues = this.resolveComplexDirs(childSlot.children, this.tagMapper[\"e-\" + tagName], tagRef);\n if (innerDirValues.length) {\n tempObj = innerDirValues;\n }\n else {\n for (var i = 0; i < Object.keys(innerDirValues).length; i++) {\n key = Object.keys(innerDirValues)[i];\n tempObj[key] = innerDirValues[key];\n }\n ;\n }\n }\n if (childSlot.props) {\n Object.keys(childSlot.props).forEach((key) => {\n tempObj[key] = childSlot.props[key];\n });\n }\n if ((/[s]\\b/).test(tagRef) && innerDirValues) {\n if (!(/[s]\\b/).test(tagName) || innerDirValues.length) {\n items[tagName] = tempObj;\n }\n else {\n items[tagName].push(tempObj);\n }\n }\n else {\n items[tagName].push(tempObj);\n }\n }\n return items;\n }\n resolveComplexDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = {};\n for (const childSlot of slot) {\n let tagRef;\n let tag;\n if (tagObject[tagName]) {\n tagRef = Object.keys(tagObject[tagName]);\n tag = tagRef.find((key) => tagObject[tagName][key] ===\n childSlot.type.methods.getTag().replace(/[s]\\b/, \"\"));\n tag = tag\n ? tag.replace(\"e-\", \"\")\n : childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (this.ej2Instances.getModuleName().toLowerCase() == \"diagram\" && tag.indexOf('annotations') != -1) {\n tag = 'annotations';\n }\n }\n if (childSlot.children) {\n innerDirValues = this.resolveComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n if (!items[tag]) {\n items[tag] = [];\n }\n if (innerDirValues.length > 1) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n }\n if (slot.length > 1) {\n items = Object.keys(items).length == 0 && !items.length ? [] : items;\n if (childSlot.props) {\n items.push(childSlot.props);\n }\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n resolveComplexInnerDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = slot.length > 1 ? [] : {};\n for (const childSlot of slot) {\n let tag = childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (childSlot.children) {\n innerDirValues = this.resolveMultilevelComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n if ((/[s]\\b/).test(tag) || slot.length > 1) {\n if ((/[s]\\b/).test(tag)) {\n items[tag] = !items[tag] ? [] : items[tag];\n if (innerDirValues.length) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n }\n else if (innerDirValues) {\n items.push(innerDirValues);\n }\n }\n else {\n items = innerDirValues ? innerDirValues : items;\n }\n }\n if (slot.length > 1 && childSlot.props) {\n if (items.length >= 0) {\n items.push(childSlot.props);\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n else {\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n resolveMultilevelComplexInnerDirs(slots, tagObject, tagName) {\n let slot = [];\n let innerDirValues;\n slot = slots.default ? slots.default() : slots;\n let items = slot.length > 1 ? [] : {};\n for (const childSlot of slot) {\n let tag = childSlot.type.methods.getTag().replace(\"e-\", \"\");\n if (childSlot.children) {\n innerDirValues = this.resolveComplexInnerDirs(childSlot.children, tagObject[tagName], childSlot.type.methods.getTag());\n }\n if ((/[s]\\b/).test(tag)) {\n items[tag] = !items[tag] ? [] : items[tag];\n if (innerDirValues.length) {\n items[tag] = innerDirValues;\n }\n else {\n items[tag].push(innerDirValues);\n }\n if (childSlot.props) {\n items[tag].push(childSlot.props);\n }\n }\n else {\n items = innerDirValues;\n items = childSlot.props ? Object.assign(items, childSlot.props) : items;\n }\n }\n return items;\n }\n getDirectiveValues(tagDirectives, tagMapper, tagNameMapper) {\n let keyTags = Object.keys(tagMapper);\n let dir = {};\n if (tagDirectives) {\n for (let tagDirective of tagDirectives) {\n if (tagDirective.componentOptions && tagDirective.componentOptions.children && tagDirective.componentOptions.tag) {\n let dirTag = tagDirective.componentOptions.tag;\n if (keyTags.indexOf(dirTag) !== -1) {\n let tagName = tagNameMapper[dirTag] ? tagNameMapper[dirTag] : dirTag;\n dir[tagName.replace('e-', '')] = [];\n for (let tagDirChild of tagDirective.componentOptions.children) {\n let retObj = this.getVNodeValue(tagDirChild, tagMapper[dirTag], tagNameMapper);\n if (Object.keys(retObj).length !== 0) {\n dir[tagName.replace('e-', '')].push(retObj);\n }\n }\n }\n }\n }\n }\n return dir;\n }\n getMultiLevelDirValue(tagDirectories, tagKey, tagNameMapper) {\n let mulObj = {};\n for (let tagDir of tagDirectories) {\n if (tagDir.componentOptions) {\n let key = tagDir.componentOptions.tag;\n let tagName = tagNameMapper[key] ? tagNameMapper[key] : key;\n mulObj[tagName.replace('e-', '')] = [];\n if (tagDir.componentOptions && tagDir.componentOptions.children) {\n for (let tagDirChild of tagDir.componentOptions.children) {\n let mulLevObj = this.getVNodeValue(tagDirChild, tagKey[key], tagNameMapper);\n if (Object.keys(mulLevObj).length !== 0) {\n mulObj[tagName.replace('e-', '')].push(mulLevObj);\n }\n }\n }\n }\n }\n return mulObj;\n }\n getVNodeValue(tagDirective, tagKey, tagNameMapper) {\n let ret = {};\n if (tagDirective.componentOptions) {\n let dirTag = tagDirective.componentOptions.tag;\n if (typeof tagKey === 'string' && dirTag === tagKey && tagDirective.data) {\n ret = tagDirective.data.attrs ? this.getCamelCaseProps(tagDirective.data.attrs) : this.getCamelCaseProps(tagDirective.data);\n }\n else if (typeof tagKey === 'object') {\n if (tagDirective.componentOptions.children && (Object.keys(tagKey).indexOf(dirTag) !== -1)) {\n ret = this.getMultiLevelDirValue(tagDirective.componentOptions.children, tagKey[dirTag], tagNameMapper);\n }\n if (tagDirective.data && tagDirective.data.attrs) {\n ret = extend(ret, this.getCamelCaseProps(tagDirective.data.attrs));\n }\n }\n }\n return ret;\n }\n /**\n * convert kebab case directive props to camel case\n */\n getCamelCaseProps(props) {\n let retProps = {};\n for (let prop of Object.keys(props)) {\n retProps[prop.replace(/-[a-z]/g, (e) => { return e[1].toUpperCase(); })] = props[prop];\n }\n return retProps;\n }\n dataBind() {\n this.ej2Instances.dataBind();\n }\n setProperties(arg, muteOnChange) {\n return this.ej2Instances.setProperties(arg, muteOnChange);\n }\n}\n","/**\n * Vue Component Base\n */\nimport Vue from 'vue';\n// import { Base, Component as EJ2Component, isNullOrUndefined } from '@syncfusion/ej2-base';\nimport { ComponentBase } from './component-base';\nexport let $internalHooks = [\n 'data',\n 'beforeCreate',\n 'created',\n 'beforeMount',\n 'mounted',\n 'beforeDestroy',\n 'destroyed',\n 'beforeUpdate',\n 'updated',\n 'activated',\n 'deactivated',\n 'render',\n 'errorCaptured' // 2.5\n];\nexport function getProps(options = {}) {\n if (options.props) {\n for (let prop of options.props) {\n (options.newprops || (options.newprops = {}))[prop] = {};\n (options.watch || (options.watch = {}))[prop] = function (newVal) {\n this.ej2Instances[prop] = newVal;\n if (this.dataBind && (options.name !== 'DateRangePickerComponent')) {\n this.dataBind();\n }\n };\n }\n }\n return [options.newprops, options.watch];\n}\nexport function EJComponentDecorator(options, isExecute) {\n if (!isExecute) {\n return;\n }\n return function (Component) {\n return EJcomponentFactory(Component, options);\n };\n}\nexport function EJcomponentFactory(Component, options = {}) {\n options.name = options.name || Component._componentTag || Component.name;\n // prototype props.\n const proto = Component.prototype;\n if (options.props) {\n for (let prop of options.props) {\n (options.props || (options.props = {}))[prop] = {};\n (options.watch || (options.watch = {}))[prop] = function (newVal) {\n this.ej2Instances[prop] = newVal;\n if (this.dataBind && (options.name !== 'DateRangePickerComponent')) {\n this.dataBind();\n }\n };\n }\n }\n Object.getOwnPropertyNames(proto).forEach(function (key) {\n // hooks\n if (key === 'constructor') {\n return;\n }\n if ($internalHooks.indexOf(key) > -1) {\n options[key] = proto[key];\n return;\n }\n const descriptor = Object.getOwnPropertyDescriptor(proto, key);\n if (typeof descriptor.value === 'function') {\n // methods\n (options.methods || (options.methods = {}))[key] = descriptor.value;\n }\n else if (descriptor.get || descriptor.set) {\n // computed properties\n (options.computed || (options.computed = {}))[key] = {\n get: descriptor.get,\n set: descriptor.set\n };\n }\n });\n Object.getOwnPropertyNames(ComponentBase.prototype).forEach(function (key) {\n if ($internalHooks.indexOf(key) > -1) {\n options[key] = proto[key];\n return;\n }\n });\n (options.mixins || (options.mixins = [])).push({\n data() {\n return collectDataFromConstructor(this, Component);\n }\n });\n // decorate options\n const decorators = Component.__decorators__;\n if (decorators) {\n decorators.forEach(Function(options));\n delete Component.__decorators__;\n }\n // find super\n const superProto = Object.getPrototypeOf(Component.prototype);\n const Super = superProto instanceof Vue\n ? superProto.constructor\n : Vue;\n const Extended = Super.extend(options);\n return Extended;\n}\nfunction collectDataFromConstructor(vm, Component) {\n Component.prototype._init = function () {\n var _this = this;\n var keys = Object.getOwnPropertyNames(vm);\n if (vm.$options.props) {\n for (var key in vm.$options.props) {\n if (!vm.hasOwnProperty(key)) {\n keys.push(key);\n }\n }\n }\n keys.forEach(function (key) {\n if (key.charAt(0) !== '_') {\n Object.defineProperty(_this, key, {\n get: function () { return vm[key]; },\n set: function (value) { return vm[key] = value; }\n });\n }\n });\n };\n var data = new Component();\n var plainData = {};\n Object.keys(data).forEach(function (key) {\n if (data[key] !== undefined) {\n plainData[key] = data[key];\n }\n });\n return plainData;\n}\n","import Vue from \"vue\";\nimport { setTemplateEngine, getTemplateEngine, getUniqueID, createElement, detach, extend, getValue, } from \"@syncfusion/ej2-base\";\nimport { allVue, gh } from \"./component-base\";\n// tslint:disable:no-any\nlet stringCompiler = getTemplateEngine();\nexport function compile(templateElement, helper) {\n let that = this;\n return (data, context, propName, element, root) => {\n let returnEle;\n if (context) {\n let pid = getUniqueID(\"templateParentDiv\");\n let id = getUniqueID(\"templateDiv\");\n let ele = createElement(\"div\", {\n id: pid,\n innerHTML: '<div id=\"' + id + '\"></div>',\n });\n document.body.appendChild(ele);\n if (gh && typeof templateElement === \"string\") {\n let vue3Slots = getVue3Slot(context.vueInstance, templateElement, root);\n if (vue3Slots) {\n // Compilation for Vue 3 slot template\n allVue\n .createApp({\n render() {\n return vue3Slots[templateElement]({ data: data });\n }\n })\n .mount(\"#\" + id);\n returnEle = ele.childNodes;\n detach(ele);\n }\n else {\n // Compilation for Vue 3 string template\n detach(ele);\n return stringCompiler(templateElement, helper)(data);\n }\n }\n else if (gh) {\n // Compilation for Vue 3 functional template\n let tempObj = templateElement.call(that, {});\n let object = tempObj;\n let propsData = getValue(\"template.propsData\", tempObj);\n let dataObj = {\n data: { data: extend(tempObj.data || {}, data) },\n parent: context.vueInstance,\n };\n if (!object.template) {\n object.template = object[Object.keys(object)[0]];\n }\n let templateCompRef;\n if (object.template.extends) {\n templateCompRef = object.template.extends._context.components.template;\n }\n else {\n templateCompRef = object.template._context.components[templateElement.name];\n if (!templateCompRef) {\n let key = Object.keys(object.template._context.components)[0];\n templateCompRef = object.template._context.components[key];\n }\n }\n let tempRef;\n if (propsData) {\n tempRef = Object.assign(templateCompRef.data(), propsData);\n }\n else {\n tempRef = Object.assign(templateCompRef.data(), dataObj.data);\n if (templateCompRef.components) {\n let objkeys = Object.keys(templateCompRef.components) || [];\n for (let objstring of objkeys) {\n let intComponent = templateCompRef.components[objstring];\n if (intComponent && intComponent.data) {\n let tempRef2 = Object.assign(intComponent.data(), dataObj.data);\n intComponent.data = function () { return tempRef2; };\n }\n }\n }\n }\n templateCompRef.data = function () { return tempRef; };\n allVue\n .createApp(templateCompRef)\n .mount(\"#\" + id);\n returnEle = ele.childNodes;\n detach(ele);\n }\n else if (typeof templateElement === \"string\") {\n let vue2Slots = getVue2Slot(context.vueInstance, templateElement, root);\n if (vue2Slots) {\n // Compilation for Vue 2 slot template\n let vueTemplate = new Vue({\n render() {\n return vue2Slots[templateElement]({ data: data });\n }\n });\n vueTemplate.$mount(\"#\" + id);\n returnEle = ele.childNodes;\n detach(ele);\n }\n else {\n // Compilation for Vue 2 string template\n detach(ele);\n return stringCompiler(templateElement, helper)(data);\n }\n }\n else {\n // Compilation for Vue 2 functional template\n let tempObj = templateElement.call(that, {});\n let templateFunction = tempObj.template;\n let propsData = getValue(\"template.propsData\", tempObj);\n let dataObj = {\n data: { data: extend(tempObj.data || {}, data) },\n parent: context.vueInstance,\n };\n if (propsData) {\n templateFunction = tempObj.template.extends;\n dataObj.propsData = propsData;\n }\n if (typeof templateFunction !== \"function\") {\n templateFunction = Vue.extend(templateFunction);\n }\n let templateVue = new templateFunction(dataObj);\n // let templateVue = new Vue(tempObj.template);\n // templateVue.$data.data = extend(tempObj.data, data);\n templateVue.$mount(\"#\" + id);\n returnEle = ele.childNodes;\n if (context.vueInstance) {\n let templateInstance = context.vueInstance.templateCollection;\n if (!templateInstance) {\n context.vueInstance.templateCollection = {};\n templateInstance = context.vueInstance.templateCollection;\n }\n if (propName) {\n if (!templateInstance[propName]) {\n templateInstance[propName] = [];\n }\n templateInstance[propName].push(returnEle[0]);\n }\n }\n detach(ele);\n }\n }\n return returnEle || [];\n };\n}\nsetTemplateEngine({ compile: compile });\n// Get the Vue2 slot template from the root or current Vue component.\nfunction getVue2Slot(vueInstance, templateElement, root) {\n if (!vueInstance && !(root && root.vueInstance)) {\n return undefined;\n }\n let instance = (root && root.vueInstance) ? root.vueInstance : vueInstance;\n return getVue2ChildSlot(instance, templateElement);\n}\nfunction getVue2ChildSlot(vueInstance, templateElement) {\n if (!vueInstance) {\n return undefined;\n }\n let slots = vueInstance.$slots;\n let scopedSlots = vueInstance.$scopedSlots;\n let vSlots = vueInstance.scopedSlots;\n let children = vueInstance.children;\n if (scopedSlots && scopedSlots[templateElement]) {\n return scopedSlots;\n }\n else if (slots && slots.default) {\n let childSlots = slots.default;\n for (let i = 0; i < childSlots.length; i++) {\n let slot = getVue2ChildSlot(getSlot(childSlots[i]), templateElement);\n if (slot) {\n return slot;\n }\n }\n }\n else if (vSlots && vSlots[templateElement]) {\n return vSlots;\n }\n else if (children) {\n for (let i = 0; i < children.length; i++) {\n let slot = getVue2ChildSlot(getSlot(children[i]), templateElement);\n if (slot) {\n return slot;\n }\n }\n }\n return undefined;\n}\nfunction getSlot(vnode) {\n let slot = (vnode.componentOptions && vnode.componentOptions.children) ? vnode.componentOptions : vnode.data;\n return vnode.componentInstance ? vnode.componentInstance : slot;\n}\n// Get the Vue3 slot template from the root or current Vue component.\nfunction getVue3Slot(vueInstance, templateElement, root) {\n if (!vueInstance && !(root && root.vueInstance)) {\n return undefined;\n }\n let slots = (root && root.vueInstance) ? root.vueInstance.$slots : vueInstance.$slots;\n return getVue3ChildSlot(slots, templateElement);\n}\nfunction getVue3ChildSlot(slots, templateElement) {\n if (slots && slots[templateElement]) {\n return slots;\n }\n else if (slots && slots.default) {\n let childSlots = slots.default();\n for (let i = 0; i < childSlots.length; i++) {\n let slot = getVue3ChildSlot(childSlots[i].children, templateElement);\n if (slot) {\n return slot;\n }\n }\n }\n return undefined;\n}\n","/**\n * index for component base\n */\nexport * from './component-base';\nexport * from './component-decorator';\nexport * from './template';\n"],"names":["Vue2","Vue3.Vue","Vue","isExecute"],"mappings":";;;;;AAAA;;;AAGA,AAIO,MAAM,IAAI,GAAG,uBAAuB,CAACA,KAAI,CAAC,CAAC;AAClD,AAAO,SAAS,uBAAuB,CAAC,GAAG,EAAE;IACzC,IAAI,GAAG,IAAI,GAAG,CAAC,UAAU,EAAE;QACvB,OAAO,GAAG,CAAC;KACd;SACI;QACD,IAAI,MAAM,GAAG,EAAE,CAAC;QAChB,IAAI,GAAG,IAAI,IAAI,EAAE;YACb,KAAK,IAAI,GAAG,IAAI,GAAG,EAAE;gBACjB,IAAI,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC;oBAC9C,MAAM,CAAC,GA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,eAAe,CAAC,CAAC;YACrE,IAAI,IAAI,EAAE;gBACN,OAAO,IAAI,CAAC;aACf;SACJ;KACJ;IACD,OAAO,SAAS,CAAC;CACpB;;ACnND;;GAEG;;;;"}
@@ -185,8 +185,10 @@ var ComponentBase = /** @__PURE__ @class */ (function (_super) {
185
185
  if (this[0] && this[0][1].slots.default) {
186
186
  propRef = this[0][1].slots.default();
187
187
  }
188
- else if (this && this.$slots) {
189
- propRef = this.$slots.default();
188
+ else if (this && this.$) {
189
+ if (this.$.slots) {
190
+ propRef = this.$.slots.default();
191
+ }
190
192
  }
191
193
  if (propRef) {
192
194
  for (var i = 0; i < propRef.length; i++) {
@@ -203,6 +205,9 @@ var ComponentBase = /** @__PURE__ @class */ (function (_super) {
203
205
  else if (controlName == "bulletchart" && keyRef == "range") {
204
206
  keyRef = "ranges";
205
207
  }
208
+ else if (controlName == "schedule" && keyRef == "header") {
209
+ keyRef = "headerRows";
210
+ }
206
211
  dirProps[keyRef] = ref[key];
207
212
  }
208
213
  }
@@ -618,11 +623,9 @@ function collectDataFromConstructor(vm, Component) {
618
623
  var stringCompiler = getTemplateEngine();
619
624
  function compile(templateElement, helper) {
620
625
  var that = this;
621
- if (typeof templateElement === "string") {
622
- return stringCompiler(templateElement, helper);
623
- }
624
- else {
625
- return function (data, context, propName) {
626
+ return function (data, context, propName, element, root) {
627
+ var returnEle;
628
+ if (context) {
626
629
  var pid = getUniqueID("templateParentDiv");
627
630
  var id = getUniqueID("templateDiv");
628
631
  var ele = createElement("div", {
@@ -630,98 +633,205 @@ function compile(templateElement, helper) {
630
633
  innerHTML: '<div id="' + id + '"></div>',
631
634
  });
632
635
  document.body.appendChild(ele);
633
- var tempObj = templateElement.call(that, {});
634
- var returnEle;
635
- if (context) {
636
- if (gh) {
637
- var object = tempObj;
638
- var propsData = getValue("template.propsData", tempObj);
639
- var dataObj = {
640
- data: { data: extend(tempObj.data || {}, data) },
641
- parent: context.vueInstance,
642
- };
643
- if (!object.template) {
644
- object.template = object[Object.keys(object)[0]];
645
- }
646
- var templateCompRef = void 0;
647
- if (object.template.extends) {
648
- templateCompRef = object.template.extends._context.components.template;
649
- }
650
- else {
651
- templateCompRef = object.template._context.components[templateElement.name];
652
- if (!templateCompRef) {
653
- var key = Object.keys(object.template._context.components)[0];
654
- templateCompRef = object.template._context.components[key];
636
+ if (gh && typeof templateElement === "string") {
637
+ var vue3Slots_1 = getVue3Slot(context.vueInstance, templateElement, root);
638
+ if (vue3Slots_1) {
639
+ // Compilation for Vue 3 slot template
640
+ allVue
641
+ .createApp({
642
+ render: function () {
643
+ return vue3Slots_1[templateElement]({ data: data });
655
644
  }
645
+ })
646
+ .mount("#" + id);
647
+ returnEle = ele.childNodes;
648
+ detach(ele);
649
+ }
650
+ else {
651
+ // Compilation for Vue 3 string template
652
+ detach(ele);
653
+ return stringCompiler(templateElement, helper)(data);
654
+ }
655
+ }
656
+ else if (gh) {
657
+ // Compilation for Vue 3 functional template
658
+ var tempObj = templateElement.call(that, {});
659
+ var object = tempObj;
660
+ var propsData = getValue("template.propsData", tempObj);
661
+ var dataObj = {
662
+ data: { data: extend(tempObj.data || {}, data) },
663
+ parent: context.vueInstance,
664
+ };
665
+ if (!object.template) {
666
+ object.template = object[Object.keys(object)[0]];
667
+ }
668
+ var templateCompRef = void 0;
669
+ if (object.template.extends) {
670
+ templateCompRef = object.template.extends._context.components.template;
671
+ }
672
+ else {
673
+ templateCompRef = object.template._context.components[templateElement.name];
674
+ if (!templateCompRef) {
675
+ var key = Object.keys(object.template._context.components)[0];
676
+ templateCompRef = object.template._context.components[key];
656
677
  }
657
- var tempRef_1;
658
- if (propsData) {
659
- tempRef_1 = Object.assign(templateCompRef.data(), propsData);
660
- }
661
- else {
662
- tempRef_1 = Object.assign(templateCompRef.data(), dataObj.data);
663
- if (templateCompRef.components) {
664
- var objkeys = Object.keys(templateCompRef.components) || [];
665
- var _loop_1 = function (objstring) {
666
- var intComponent = templateCompRef.components[objstring];
667
- if (intComponent && intComponent.data) {
668
- var tempRef2_1 = Object.assign(intComponent.data(), dataObj.data);
669
- intComponent.data = function () { return tempRef2_1; };
670
- }
671
- };
672
- for (var _i = 0, objkeys_1 = objkeys; _i < objkeys_1.length; _i++) {
673
- var objstring = objkeys_1[_i];
674
- _loop_1(objstring);
678
+ }
679
+ var tempRef_1;
680
+ if (propsData) {
681
+ tempRef_1 = Object.assign(templateCompRef.data(), propsData);
682
+ }
683
+ else {
684
+ tempRef_1 = Object.assign(templateCompRef.data(), dataObj.data);
685
+ if (templateCompRef.components) {
686
+ var objkeys = Object.keys(templateCompRef.components) || [];
687
+ var _loop_1 = function (objstring) {
688
+ var intComponent = templateCompRef.components[objstring];
689
+ if (intComponent && intComponent.data) {
690
+ var tempRef2_1 = Object.assign(intComponent.data(), dataObj.data);
691
+ intComponent.data = function () { return tempRef2_1; };
675
692
  }
693
+ };
694
+ for (var _i = 0, objkeys_1 = objkeys; _i < objkeys_1.length; _i++) {
695
+ var objstring = objkeys_1[_i];
696
+ _loop_1(objstring);
676
697
  }
677
698
  }
678
- templateCompRef.data = function () { return tempRef_1; };
679
- allVue
680
- .createApp(templateCompRef)
681
- .mount("#" + id);
699
+ }
700
+ templateCompRef.data = function () { return tempRef_1; };
701
+ allVue
702
+ .createApp(templateCompRef)
703
+ .mount("#" + id);
704
+ returnEle = ele.childNodes;
705
+ detach(ele);
706
+ }
707
+ else if (typeof templateElement === "string") {
708
+ var vue2Slots_1 = getVue2Slot(context.vueInstance, templateElement, root);
709
+ if (vue2Slots_1) {
710
+ // Compilation for Vue 2 slot template
711
+ var vueTemplate = new Vue$1__default({
712
+ render: function () {
713
+ return vue2Slots_1[templateElement]({ data: data });
714
+ }
715
+ });
716
+ vueTemplate.$mount("#" + id);
682
717
  returnEle = ele.childNodes;
683
718
  detach(ele);
684
719
  }
685
720
  else {
686
- var templateFunction = tempObj.template;
687
- var propsData = getValue("template.propsData", tempObj);
688
- var dataObj = {
689
- data: { data: extend(tempObj.data || {}, data) },
690
- parent: context.vueInstance,
691
- };
692
- if (propsData) {
693
- templateFunction = tempObj.template.extends;
694
- dataObj.propsData = propsData;
695
- }
696
- if (typeof templateFunction !== "function") {
697
- templateFunction = Vue$1__default.extend(templateFunction);
721
+ // Compilation for Vue 2 string template
722
+ detach(ele);
723
+ return stringCompiler(templateElement, helper)(data);
724
+ }
725
+ }
726
+ else {
727
+ // Compilation for Vue 2 functional template
728
+ var tempObj = templateElement.call(that, {});
729
+ var templateFunction = tempObj.template;
730
+ var propsData = getValue("template.propsData", tempObj);
731
+ var dataObj = {
732
+ data: { data: extend(tempObj.data || {}, data) },
733
+ parent: context.vueInstance,
734
+ };
735
+ if (propsData) {
736
+ templateFunction = tempObj.template.extends;
737
+ dataObj.propsData = propsData;
738
+ }
739
+ if (typeof templateFunction !== "function") {
740
+ templateFunction = Vue$1__default.extend(templateFunction);
741
+ }
742
+ var templateVue = new templateFunction(dataObj);
743
+ // let templateVue = new Vue(tempObj.template);
744
+ // templateVue.$data.data = extend(tempObj.data, data);
745
+ templateVue.$mount("#" + id);
746
+ returnEle = ele.childNodes;
747
+ if (context.vueInstance) {
748
+ var templateInstance = context.vueInstance.templateCollection;
749
+ if (!templateInstance) {
750
+ context.vueInstance.templateCollection = {};
751
+ templateInstance = context.vueInstance.templateCollection;
698
752
  }
699
- var templateVue = new templateFunction(dataObj);
700
- // let templateVue = new Vue(tempObj.template);
701
- // templateVue.$data.data = extend(tempObj.data, data);
702
- templateVue.$mount("#" + id);
703
- returnEle = ele.childNodes;
704
- if (context.vueInstance) {
705
- var templateInstance = context.vueInstance.templateCollection;
706
- if (!templateInstance) {
707
- context.vueInstance.templateCollection = {};
708
- templateInstance = context.vueInstance.templateCollection;
709
- }
710
- if (propName) {
711
- if (!templateInstance[propName]) {
712
- templateInstance[propName] = [];
713
- }
714
- templateInstance[propName].push(returnEle[0]);
753
+ if (propName) {
754
+ if (!templateInstance[propName]) {
755
+ templateInstance[propName] = [];
715
756
  }
757
+ templateInstance[propName].push(returnEle[0]);
716
758
  }
717
- detach(ele);
718
759
  }
760
+ detach(ele);
719
761
  }
720
- return returnEle || [];
721
- };
722
- }
762
+ }
763
+ return returnEle || [];
764
+ };
723
765
  }
724
766
  setTemplateEngine({ compile: compile });
767
+ // Get the Vue2 slot template from the root or current Vue component.
768
+ function getVue2Slot(vueInstance, templateElement, root) {
769
+ if (!vueInstance && !(root && root.vueInstance)) {
770
+ return undefined;
771
+ }
772
+ var instance = (root && root.vueInstance) ? root.vueInstance : vueInstance;
773
+ return getVue2ChildSlot(instance, templateElement);
774
+ }
775
+ function getVue2ChildSlot(vueInstance, templateElement) {
776
+ if (!vueInstance) {
777
+ return undefined;
778
+ }
779
+ var slots = vueInstance.$slots;
780
+ var scopedSlots = vueInstance.$scopedSlots;
781
+ var vSlots = vueInstance.scopedSlots;
782
+ var children = vueInstance.children;
783
+ if (scopedSlots && scopedSlots[templateElement]) {
784
+ return scopedSlots;
785
+ }
786
+ else if (slots && slots.default) {
787
+ var childSlots = slots.default;
788
+ for (var i = 0; i < childSlots.length; i++) {
789
+ var slot = getVue2ChildSlot(getSlot(childSlots[i]), templateElement);
790
+ if (slot) {
791
+ return slot;
792
+ }
793
+ }
794
+ }
795
+ else if (vSlots && vSlots[templateElement]) {
796
+ return vSlots;
797
+ }
798
+ else if (children) {
799
+ for (var i = 0; i < children.length; i++) {
800
+ var slot = getVue2ChildSlot(getSlot(children[i]), templateElement);
801
+ if (slot) {
802
+ return slot;
803
+ }
804
+ }
805
+ }
806
+ return undefined;
807
+ }
808
+ function getSlot(vnode) {
809
+ var slot = (vnode.componentOptions && vnode.componentOptions.children) ? vnode.componentOptions : vnode.data;
810
+ return vnode.componentInstance ? vnode.componentInstance : slot;
811
+ }
812
+ // Get the Vue3 slot template from the root or current Vue component.
813
+ function getVue3Slot(vueInstance, templateElement, root) {
814
+ if (!vueInstance && !(root && root.vueInstance)) {
815
+ return undefined;
816
+ }
817
+ var slots = (root && root.vueInstance) ? root.vueInstance.$slots : vueInstance.$slots;
818
+ return getVue3ChildSlot(slots, templateElement);
819
+ }
820
+ function getVue3ChildSlot(slots, templateElement) {
821
+ if (slots && slots[templateElement]) {
822
+ return slots;
823
+ }
824
+ else if (slots && slots.default) {
825
+ var childSlots = slots.default();
826
+ for (var i = 0; i < childSlots.length; i++) {
827
+ var slot = getVue3ChildSlot(childSlots[i].children, templateElement);
828
+ if (slot) {
829
+ return slot;
830
+ }
831
+ }
832
+ }
833
+ return undefined;
834
+ }
725
835
 
726
836
  /**
727
837
  * index for component base