@wavemaker/app-ng-runtime 12.0.0-next.45096 → 12.0.0-next.45097

Sign up to get free protection for your applications and to get access to all the features.
@@ -185,7 +185,7 @@
185
185
  this.registerDestroyListener(this.viewport.subscribe("orientationchange" /* ViewportEvent.ORIENTATION_CHANGE */, data => this.callback('orientationchange', data)));
186
186
  }
187
187
  ngAfterContentInit() {
188
- let customWidget = this.nativeElement.closest('[customwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(base.getWidgetPropsByType("wm-custom-widget-container").keys());
188
+ let customWidget = this.nativeElement.closest('[customwidgetcontainer]') || this.nativeElement.closest('[wmwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(base.getWidgetPropsByType("wm-custom-widget-container").keys());
189
189
  for (let i = 0; i < customWidget.attributes.length; i++) {
190
190
  let attr = customWidget.attributes.item(i);
191
191
  if (attr.value && attr.value !== '' && !customWidgetProps.includes(attr.name))
@@ -15,7 +15,7 @@ export class CustomWidgetDirective extends StylableComponent {
15
15
  this.registerDestroyListener(this.viewport.subscribe("orientationchange" /* ViewportEvent.ORIENTATION_CHANGE */, data => this.callback('orientationchange', data)));
16
16
  }
17
17
  ngAfterContentInit() {
18
- let customWidget = this.nativeElement.closest('[customwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(getWidgetPropsByType("wm-custom-widget-container").keys());
18
+ let customWidget = this.nativeElement.closest('[customwidgetcontainer]') || this.nativeElement.closest('[wmwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(getWidgetPropsByType("wm-custom-widget-container").keys());
19
19
  for (let i = 0; i < customWidget.attributes.length; i++) {
20
20
  let attr = customWidget.attributes.item(i);
21
21
  if (attr.value && attr.value !== '' && !customWidgetProps.includes(attr.name))
@@ -65,4 +65,4 @@ export class CustomWidgetDirective extends StylableComponent {
65
65
  ]
66
66
  }]
67
67
  }], () => [{ type: i0.Injector }, { type: i1.Viewport }], null); })();
68
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaW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AgICAgICAgICAgICAgZm9yIChjb25zdCBba2V5LCB2YWx1ZV0gb2YgT2JqZWN0LmVudHJpZXMoaW5oZXJpdGVkUHJvcHMpKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmKGtleS5pbmNsdWRlcyhcIi5ldmVudFwiKSB8fCBrZXkuaW5jbHVkZXMoJy5iaW5kJykpXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLnByb2Nlc3NBdHRyKGtleSwgdmFsdWUsIHt3aWRnZXQ6IGNoaWxkLndpZGdldCwgbmF0aXZlRWxlbWVudDogY2hpbGR9KTtcbiAgICAgICAgICAgICAgICAgICAgZWxzZVxuICAgICAgICAgICAgICAgICAgICAgICAgY2hpbGQud2lkZ2V0W2tleV0gPSB2YWx1ZTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH0pO1xuICAgIH1cblxuICAgIHByaXZhdGUgY2FsbGJhY2soZXZlbnROYW1lLCBsb2NhbHM/OiBvYmplY3QpIHtcbiAgICAgICAgbG9jYWxzID0gXy5hc3NpZ24oeyB3aWRnZXQ6IHRoaXMgfSwgbG9jYWxzKTtcbiAgICAgICAgdGhpcy5pbnZva2VFdmVudENhbGxiYWNrKGV2ZW50TmFtZSwgbG9jYWxzKTtcbiAgICB9XG5cbiAgICBwdWJsaWMgbmdPbkF0dGFjaCgpIHtcbiAgICAgICAgdGhpcy5jYWxsYmFjaygnYXR0YWNoJyk7XG4gICAgfVxuXG4gICAgcHVibGljIG5nT25EZXRhY2goKSB7XG4gICAgICAgIHRoaXMuY2FsbGJhY2soJ2RldGFjaCcpO1xuICAgIH1cblxuICAgIHB1YmxpYyBuZ09uRGVzdHJveSgpIHtcbiAgICAgICAgdGhpcy5jYWxsYmFjaygnZGVzdHJveScpO1xuICAgICAgICBzdXBlci5uZ09uRGVzdHJveSgpO1xuICAgIH1cblxufVxuIl19
68
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjo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AgIHRoaXMuY2FsbGJhY2soJ2Rlc3Ryb3knKTtcbiAgICAgICAgc3VwZXIubmdPbkRlc3Ryb3koKTtcbiAgICB9XG5cbn1cbiJdfQ==
@@ -170,7 +170,7 @@ class CustomWidgetDirective extends StylableComponent {
170
170
  this.registerDestroyListener(this.viewport.subscribe("orientationchange" /* ViewportEvent.ORIENTATION_CHANGE */, data => this.callback('orientationchange', data)));
171
171
  }
172
172
  ngAfterContentInit() {
173
- let customWidget = this.nativeElement.closest('[customwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(getWidgetPropsByType("wm-custom-widget-container").keys());
173
+ let customWidget = this.nativeElement.closest('[customwidgetcontainer]') || this.nativeElement.closest('[wmwidgetcontainer]'), inheritedProps = {}, customWidgetProps = Array.from(getWidgetPropsByType("wm-custom-widget-container").keys());
174
174
  for (let i = 0; i < customWidget.attributes.length; i++) {
175
175
  let attr = customWidget.attributes.item(i);
176
176
  if (attr.value && attr.value !== '' && !customWidgetProps.includes(attr.name))
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":["../../../../../projects/components/widgets/advanced/custom/src/custom-widget-container/custom-widget.props.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget-container/custom-widget-container.directive.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget-prop.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget.directive.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget.module.ts","../../../../../projects/components/widgets/advanced/custom/src/index.ts"],"sourcesContent":["import {PROP_BOOLEAN, PROP_STRING, register} from '@wm/components/base';\n\nexport const customWidgetProps =\n new Map(\n [\n ['class', PROP_STRING],\n ['hint', PROP_STRING],\n ['name', PROP_STRING],\n ['widgetname', PROP_STRING],\n ['show', { value: true, ...PROP_BOOLEAN }]\n ]\n )\n\nexport const registerProps = () => {\n register(\n 'wm-custom-widget',\n customWidgetProps\n );\n};\n","import {Attribute, Directive, ElementRef, Inject, Injector, OnInit, Optional} from '@angular/core';\n\nimport { noop } from '@wm/core';\nimport {PROP_TYPE, provideAs, provideAsWidgetRef, register, StylableComponent, styler} from '@wm/components/base';\n\nimport { customWidgetProps } from './custom-widget.props';\nimport { registerProps } from \"../custom-widget-container/custom-widget.props\";\nimport {capitalize, cloneDeep} from 'lodash-es';\nimport {NG_VALIDATORS, NG_VALUE_ACCESSOR} from \"@angular/forms\";\nimport {DatasetAwareFormComponent} from \"@wm/components/input\";\nimport {Subject} from \"rxjs\";\n\nconst registeredPropsSet = new Set<string>();\n\nlet customWidgetPropsMap: { [key: string]: any } = {};\n\nconst DEFAULT_CLS = 'app-html-container';\n\ndeclare const _;\n\n@Directive({\n selector: '[wmWidgetContainer]',\n providers: [\n provideAs(CustomWidgetContainerDirective, NG_VALUE_ACCESSOR, true),\n provideAs(CustomWidgetContainerDirective, NG_VALIDATORS, true),\n provideAsWidgetRef(CustomWidgetContainerDirective)\n ],\n exportAs: 'wmWidgetContainer'\n})\nexport class CustomWidgetContainerDirective extends DatasetAwareFormComponent implements OnInit {\n static initializeProps = registerProps();\n\n widgetType: string;\n name: string;\n propsReady: Function;\n widgetName: string;\n config: any;\n private props: any = {};\n private baseWidgetName: string;\n asAttr: boolean;\n configSubject: Subject<any>;\n\n constructor(\n inj: Injector, elRef: ElementRef,\n @Attribute('widgetname') widgetname: string,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n const widgetType = `wm-custom-${widgetname}`;\n const WIDGET_CONFIG = { widgetType, hostClass: DEFAULT_CLS };\n let resolveFn: Function = noop;\n\n super(inj, WIDGET_CONFIG, explicitContext, undefined, new Promise(res => resolveFn = res));\n this.propsReady = resolveFn;\n this.configSubject = new Subject();\n this.widgetType = widgetType;\n this.name = elRef.nativeElement.getAttribute('name');\n\n styler(this.nativeElement, this);\n\n // Call on property change on name to set name attribute on element.\n this.registerReadyStateListener(() => {\n super.onPropertyChange('name', this.name);\n });\n\n this.registerPropertyChangeListener(((key: string, nv: any, ov?: any) => {\n if (!key.startsWith('prop-')) return;\n const propName = key.slice(5)\n if (this.props.hasOwnProperty(propName) && this.props[propName] !== nv) {\n this.props[propName] = nv;\n }\n }))\n }\n\n get datavalue() {\n if(this.nativeElement.children.length) {\n let value = this.nativeElement.children[0].children[0]['widget'].viewParent.datavalue;\n this.updateDataValue(value);\n return value;\n }\n }\n\n set datavalue(value) {\n if(this.nativeElement.children.length)\n this.nativeElement.children[0].children[0]['widget'].viewParent.datavalue = value;\n }\n\n setBaseWidgetName(baseWidgetType: string) {\n let splitArr = baseWidgetType.split('-'), modifiedArr = [];\n modifiedArr = splitArr.map((item: any) => {\n item = item !== 'wm' ? capitalize(item) : item;\n return item;\n });\n this.baseWidgetName = modifiedArr.join('');\n }\n\n public setProps(config, resolveFn: Function) {\n this.config = config;\n this.configSubject.next();\n this.asAttr = this.nativeElement.children[0].children[0].hasAttribute('as');\n if(this.asAttr)\n this.setBaseWidgetName(config.widgetType);\n if (!config || !config.properties) {\n return;\n }\n if (!registeredPropsSet.has(this.widgetType)) {\n register(this.widgetType, this.prepareProps(config.properties));\n }else{\n this.props = Object.assign(this.props, cloneDeep(customWidgetPropsMap[this.widgetType]))\n }\n\n this.propsReady(resolveFn);\n }\n\n private prepareProps(props = {}) {\n const propsMap = new Map(customWidgetProps);\n Object.entries(props).forEach(([k, v]: [string, any]) => {\n let type = PROP_TYPE.STRING;\n\n if (v.type === 'boolean') {\n type = PROP_TYPE.BOOLEAN;\n } else if (v.type === 'number') {\n type = PROP_TYPE.NUMBER;\n } else if (v.type !== 'string') {\n type = v.type;\n }\n\n // Do not set the 'bind:*' values\n propsMap.set(`prop-${k}`, { type, value: _.startsWith(v.value, 'bind:') ? undefined : v.value });\n this.props[k] = v.value;\n });\n\n registeredPropsSet.add(this.widgetType);\n customWidgetPropsMap[this.widgetType] = this.props\n\n return propsMap;\n }\n\n updateDataValue(value) {\n if(this.formControl && this.formControl.control && value !== this.formControl.control.value)\n this.formControl.control.setValue(value);\n }\n\n updateData(key: string, value: any) {\n let modifiedKey = key.replace('base-', '');\n if(this.asAttr) {\n this[this.baseWidgetName][modifiedKey] = value;\n this.nativeElement.children[0].children[0]['widget'].viewParent[this.baseWidgetName][modifiedKey] = value;\n this[this.baseWidgetName].initDatasetItems();\n } else {\n this[modifiedKey] = value;\n this.nativeElement.children[0].children[0]['widget'].viewParent[modifiedKey] = value;\n }\n if(this.formControl && modifiedKey === 'datavalue')\n this.updateDataValue(value);\n }\n}\n","import {PROP_STRING, register} from '@wm/components/base';\n\nexport const registerProps = () => {\n register(\n 'wm-custom-widget-container',\n new Map(\n [\n ['name', PROP_STRING],\n ['class', PROP_STRING]\n ]\n )\n );\n};\n","import { AfterContentInit, Directive, ElementRef, Injector, OnDestroy, Optional } from '@angular/core';\n\nimport {Viewport, ViewportEvent} from '@wm/core';\nimport { registerProps } from './custom-widget-prop';\nimport { StylableComponent, provideAsWidgetRef, getWidgetPropsByType } from '@wm/components/base';\n\nconst DEFAULT_CLS = 'app-custom-widget-container clearfix';\nconst WIDGET_CONFIG = {widgetType: 'wm-custom-widget-container', hostClass: DEFAULT_CLS};\ndeclare const _;\n\n@Directive({\n selector: '[wmCustomWidget]',\n providers: [\n provideAsWidgetRef(CustomWidgetDirective)\n ]\n})\nexport class CustomWidgetDirective extends StylableComponent implements OnDestroy, AfterContentInit {\n static initializeProps = registerProps();\n\n constructor(inj: Injector, private viewport: Viewport) {\n super(inj, WIDGET_CONFIG);\n this.registerDestroyListener(this.viewport.subscribe(ViewportEvent.RESIZE, data => this.callback('resize', data)));\n this.registerDestroyListener(this.viewport.subscribe(ViewportEvent.ORIENTATION_CHANGE, data => this.callback('orientationchange', data)));\n }\n ngAfterContentInit() {\n let customWidget = this.nativeElement.closest('[customwidgetcontainer]'),\n inheritedProps = {},\n customWidgetProps = Array.from(getWidgetPropsByType(\"wm-custom-widget-container\").keys());\n for(let i = 0; i < customWidget.attributes.length; i++) {\n let attr = customWidget.attributes.item(i);\n if(attr.value && attr.value !== '' && !customWidgetProps.includes(attr.name))\n inheritedProps[attr.name] = attr.value;\n }\n this.processChildren(this.nativeElement.children, inheritedProps);\n }\n\n processChildren(children: any, inheritedProps: { [key: string]: string }) {\n Array.from(children).forEach((child: any) => {\n if(!child.hasAttribute('base-widget'))\n this.processChildren(child.children, inheritedProps);\n else {\n for (const [key, value] of Object.entries(inheritedProps)) {\n if(key.includes(\".event\") || key.includes('.bind'))\n this.processAttr(key, value, {widget: child.widget, nativeElement: child});\n else\n child.widget[key] = value;\n }\n }\n });\n }\n\n private callback(eventName, locals?: object) {\n locals = _.assign({ widget: this }, locals);\n this.invokeEventCallback(eventName, locals);\n }\n\n public ngOnAttach() {\n this.callback('attach');\n }\n\n public ngOnDetach() {\n this.callback('detach');\n }\n\n public ngOnDestroy() {\n this.callback('destroy');\n super.ngOnDestroy();\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { WmComponentsModule } from '@wm/components/base';\n\nimport { CustomWidgetContainerDirective } from './custom-widget-container/custom-widget-container.directive';\nimport { CustomWidgetDirective } from './custom-widget.directive'\nconst components = [\n CustomWidgetContainerDirective,\n CustomWidgetDirective\n];\n\n@NgModule({\n imports: [\n CommonModule,\n WmComponentsModule\n ],\n declarations: [...components],\n exports: [...components]\n})\nexport class CustomModule {\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["registerProps","DEFAULT_CLS"],"mappings":";;;;;;;;;;;AAEO,MAAM,iBAAiB,GAC1B,IAAI,GAAG,CACH;IACI,CAAC,OAAO,EAAE,WAAW,CAAC;IACtB,CAAC,MAAM,EAAE,WAAW,CAAC;IACrB,CAAC,MAAM,EAAE,WAAW,CAAC;IACrB,CAAC,YAAY,EAAE,WAAW,CAAC;IAC3B,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,YAAY,EAAE,CAAC;AAC7C,CAAA,CACJ,CAAA;AAEE,MAAMA,eAAa,GAAG,MAAK;AAC9B,IAAA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A,CAAA,YAAY,mBAZrB,8BAA8B;AAC9B,QAAA,qBAAqB,aAKjB,YAAY;AACZ,QAAA,kBAAkB,aAPtB,8BAA8B;QAC9B,qBAAqB,CAAA,EAAA,CAAA,CAAA,EAAA,GAAA;;ACTzB;;AAEG;;;;"}
1
+ {"version":3,"file":"index.mjs","sources":["../../../../../projects/components/widgets/advanced/custom/src/custom-widget-container/custom-widget.props.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget-container/custom-widget-container.directive.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget-prop.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget.directive.ts","../../../../../projects/components/widgets/advanced/custom/src/custom-widget.module.ts","../../../../../projects/components/widgets/advanced/custom/src/index.ts"],"sourcesContent":["import {PROP_BOOLEAN, PROP_STRING, register} from '@wm/components/base';\n\nexport const customWidgetProps =\n new Map(\n [\n ['class', PROP_STRING],\n ['hint', PROP_STRING],\n ['name', PROP_STRING],\n ['widgetname', PROP_STRING],\n ['show', { value: true, ...PROP_BOOLEAN }]\n ]\n )\n\nexport const registerProps = () => {\n register(\n 'wm-custom-widget',\n customWidgetProps\n );\n};\n","import {Attribute, Directive, ElementRef, Inject, Injector, OnInit, Optional} from '@angular/core';\n\nimport { noop } from '@wm/core';\nimport {PROP_TYPE, provideAs, provideAsWidgetRef, register, StylableComponent, styler} from '@wm/components/base';\n\nimport { customWidgetProps } from './custom-widget.props';\nimport { registerProps } from \"../custom-widget-container/custom-widget.props\";\nimport {capitalize, cloneDeep} from 'lodash-es';\nimport {NG_VALIDATORS, NG_VALUE_ACCESSOR} from \"@angular/forms\";\nimport {DatasetAwareFormComponent} from \"@wm/components/input\";\nimport {Subject} from \"rxjs\";\n\nconst registeredPropsSet = new Set<string>();\n\nlet customWidgetPropsMap: { [key: string]: any } = {};\n\nconst DEFAULT_CLS = 'app-html-container';\n\ndeclare const _;\n\n@Directive({\n selector: '[wmWidgetContainer]',\n providers: [\n provideAs(CustomWidgetContainerDirective, NG_VALUE_ACCESSOR, true),\n provideAs(CustomWidgetContainerDirective, NG_VALIDATORS, true),\n provideAsWidgetRef(CustomWidgetContainerDirective)\n ],\n exportAs: 'wmWidgetContainer'\n})\nexport class CustomWidgetContainerDirective extends DatasetAwareFormComponent implements OnInit {\n static initializeProps = registerProps();\n\n widgetType: string;\n name: string;\n propsReady: Function;\n widgetName: string;\n config: any;\n private props: any = {};\n private baseWidgetName: string;\n asAttr: boolean;\n configSubject: Subject<any>;\n\n constructor(\n inj: Injector, elRef: ElementRef,\n @Attribute('widgetname') widgetname: string,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n const widgetType = `wm-custom-${widgetname}`;\n const WIDGET_CONFIG = { widgetType, hostClass: DEFAULT_CLS };\n let resolveFn: Function = noop;\n\n super(inj, WIDGET_CONFIG, explicitContext, undefined, new Promise(res => resolveFn = res));\n this.propsReady = resolveFn;\n this.configSubject = new Subject();\n this.widgetType = widgetType;\n this.name = elRef.nativeElement.getAttribute('name');\n\n styler(this.nativeElement, this);\n\n // Call on property change on name to set name attribute on element.\n this.registerReadyStateListener(() => {\n super.onPropertyChange('name', this.name);\n });\n\n this.registerPropertyChangeListener(((key: string, nv: any, ov?: any) => {\n if (!key.startsWith('prop-')) return;\n const propName = key.slice(5)\n if (this.props.hasOwnProperty(propName) && this.props[propName] !== nv) {\n this.props[propName] = nv;\n }\n }))\n }\n\n get datavalue() {\n if(this.nativeElement.children.length) {\n let value = this.nativeElement.children[0].children[0]['widget'].viewParent.datavalue;\n this.updateDataValue(value);\n return value;\n }\n }\n\n set datavalue(value) {\n if(this.nativeElement.children.length)\n this.nativeElement.children[0].children[0]['widget'].viewParent.datavalue = value;\n }\n\n setBaseWidgetName(baseWidgetType: string) {\n let splitArr = baseWidgetType.split('-'), modifiedArr = [];\n modifiedArr = splitArr.map((item: any) => {\n item = item !== 'wm' ? capitalize(item) : item;\n return item;\n });\n this.baseWidgetName = modifiedArr.join('');\n }\n\n public setProps(config, resolveFn: Function) {\n this.config = config;\n this.configSubject.next();\n this.asAttr = this.nativeElement.children[0].children[0].hasAttribute('as');\n if(this.asAttr)\n this.setBaseWidgetName(config.widgetType);\n if (!config || !config.properties) {\n return;\n }\n if (!registeredPropsSet.has(this.widgetType)) {\n register(this.widgetType, this.prepareProps(config.properties));\n }else{\n this.props = Object.assign(this.props, cloneDeep(customWidgetPropsMap[this.widgetType]))\n }\n\n this.propsReady(resolveFn);\n }\n\n private prepareProps(props = {}) {\n const propsMap = new Map(customWidgetProps);\n Object.entries(props).forEach(([k, v]: [string, any]) => {\n let type = PROP_TYPE.STRING;\n\n if (v.type === 'boolean') {\n type = PROP_TYPE.BOOLEAN;\n } else if (v.type === 'number') {\n type = PROP_TYPE.NUMBER;\n } else if (v.type !== 'string') {\n type = v.type;\n }\n\n // Do not set the 'bind:*' values\n propsMap.set(`prop-${k}`, { type, value: _.startsWith(v.value, 'bind:') ? undefined : v.value });\n this.props[k] = v.value;\n });\n\n registeredPropsSet.add(this.widgetType);\n customWidgetPropsMap[this.widgetType] = this.props\n\n return propsMap;\n }\n\n updateDataValue(value) {\n if(this.formControl && this.formControl.control && value !== this.formControl.control.value)\n this.formControl.control.setValue(value);\n }\n\n updateData(key: string, value: any) {\n let modifiedKey = key.replace('base-', '');\n if(this.asAttr) {\n this[this.baseWidgetName][modifiedKey] = value;\n this.nativeElement.children[0].children[0]['widget'].viewParent[this.baseWidgetName][modifiedKey] = value;\n this[this.baseWidgetName].initDatasetItems();\n } else {\n this[modifiedKey] = value;\n this.nativeElement.children[0].children[0]['widget'].viewParent[modifiedKey] = value;\n }\n if(this.formControl && modifiedKey === 'datavalue')\n this.updateDataValue(value);\n }\n}\n","import {PROP_STRING, register} from '@wm/components/base';\n\nexport const registerProps = () => {\n register(\n 'wm-custom-widget-container',\n new Map(\n [\n ['name', PROP_STRING],\n ['class', PROP_STRING]\n ]\n )\n );\n};\n","import { AfterContentInit, Directive, ElementRef, Injector, OnDestroy, Optional } from '@angular/core';\n\nimport {Viewport, ViewportEvent} from '@wm/core';\nimport { registerProps } from './custom-widget-prop';\nimport { StylableComponent, provideAsWidgetRef, getWidgetPropsByType } from '@wm/components/base';\n\nconst DEFAULT_CLS = 'app-custom-widget-container clearfix';\nconst WIDGET_CONFIG = {widgetType: 'wm-custom-widget-container', hostClass: DEFAULT_CLS};\ndeclare const _;\n\n@Directive({\n selector: '[wmCustomWidget]',\n providers: [\n provideAsWidgetRef(CustomWidgetDirective)\n ]\n})\nexport class CustomWidgetDirective extends StylableComponent implements OnDestroy, AfterContentInit {\n static initializeProps = registerProps();\n\n constructor(inj: Injector, private viewport: Viewport) {\n super(inj, WIDGET_CONFIG);\n this.registerDestroyListener(this.viewport.subscribe(ViewportEvent.RESIZE, data => this.callback('resize', data)));\n this.registerDestroyListener(this.viewport.subscribe(ViewportEvent.ORIENTATION_CHANGE, data => this.callback('orientationchange', data)));\n }\n ngAfterContentInit() {\n let customWidget = this.nativeElement.closest('[customwidgetcontainer]') || this.nativeElement.closest('[wmwidgetcontainer]'),\n inheritedProps = {},\n customWidgetProps = Array.from(getWidgetPropsByType(\"wm-custom-widget-container\").keys());\n for(let i = 0; i < customWidget.attributes.length; i++) {\n let attr = customWidget.attributes.item(i);\n if(attr.value && attr.value !== '' && !customWidgetProps.includes(attr.name))\n inheritedProps[attr.name] = attr.value;\n }\n this.processChildren(this.nativeElement.children, inheritedProps);\n }\n\n processChildren(children: any, inheritedProps: { [key: string]: string }) {\n Array.from(children).forEach((child: any) => {\n if(!child.hasAttribute('base-widget'))\n this.processChildren(child.children, inheritedProps);\n else {\n for (const [key, value] of Object.entries(inheritedProps)) {\n if(key.includes(\".event\") || key.includes('.bind'))\n this.processAttr(key, value, {widget: child.widget, nativeElement: child});\n else\n child.widget[key] = value;\n }\n }\n });\n }\n\n private callback(eventName, locals?: object) {\n locals = _.assign({ widget: this }, locals);\n this.invokeEventCallback(eventName, locals);\n }\n\n public ngOnAttach() {\n this.callback('attach');\n }\n\n public ngOnDetach() {\n this.callback('detach');\n }\n\n public ngOnDestroy() {\n this.callback('destroy');\n super.ngOnDestroy();\n }\n\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { WmComponentsModule } from '@wm/components/base';\n\nimport { CustomWidgetContainerDirective } from './custom-widget-container/custom-widget-container.directive';\nimport { CustomWidgetDirective } from './custom-widget.directive'\nconst components = [\n CustomWidgetContainerDirective,\n CustomWidgetDirective\n];\n\n@NgModule({\n imports: [\n CommonModule,\n WmComponentsModule\n ],\n declarations: [...components],\n exports: [...components]\n})\nexport class CustomModule {\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["registerProps","DEFAULT_CLS"],"mappings":";;;;;;;;;;;AAEO,MAAM,iBAAiB,GAC1B,IAAI,GAAG,CACH;IACI,CAAC,OAAO,EAAE,WAAW,CAAC;IACtB,CAAC,MAAM,EAAE,WAAW,CAAC;IACrB,CAAC,MAAM,EAAE,WAAW,CAAC;IACrB,CAAC,YAAY,EAAE,WAAW,CAAC;IAC3B,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,YAAY,EAAE,CAAC;AAC7C,CAAA,CACJ,CAAA;AAEE,MAAMA,eAAa,GAAG,MAAK;AAC9B,IAAA,QAAQ,CACJ,kBAAkB,EAClB,iBAAiB,CACpB,CAAC;AACN,CAAC;;ACND,MAAM,kBAAkB,GAAG,IAAI,GAAG,EAAU,CAAC;AAE7C,IAAI,oBAAoB,GAA2B,EAAE,CAAC;AAEtD,MAAMC,aAAW,GAAG,oBAAoB,CAAC;AAanC,MAAO,8BAA+B,SAAQ,yBAAyB,CAAA;AAClE,IAAA,SAAA,IAAA,CAAA,eAAe,GAAGD,eAAa,EAAhB,CAAmB,EAAA;AAYzC,IAAA,WAAA,CACI,GAAa,EAAE,KAAiB,EACP,UAAkB,EACH,eAAoB,EAAA;AAE5D,QAAA,MAAM,UAAU,GAAG,CAAa,UAAA,EAAA,UAA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B,CAAC;AAC5C,aAAA,CAAA,EAAA,EAAA,CAAA,0BAAA,CAAA,EAAA,CAAA,CAAA,EAAA;;iFAEQ,qBAAqB,EAAA,CAAA;cANjC,SAAS;AAAC,QAAA,IAAA,EAAA,CAAA;AACP,gBAAA,QAAQ,EAAE,kBAAkB;AAC5B,gBAAA,SAAS,EAAE;AACP,oBAAA,kBAAkB,CAAuB,qBAAA,CAAA;AAC5C,iBAAA;AACJ,aAAA,CAAA;;;ACRD,MAAM,UAAU,GAAG;IACf,8BAA8B;IAC9B,qBAAqB;CACxB,CAAC;MAUW,YAAY,CAAA;6EAAZ,YAAY,GAAA,CAAA,EAAA,CAAA,EAAA;mEAAZ,YAAY,EAAA,CAAA,CAAA,EAAA;uEANjB,YAAY;YACZ,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;;iFAKb,YAAY,EAAA,CAAA;cARxB,QAAQ;AAAC,QAAA,IAAA,EAAA,CAAA;AACN,gBAAA,OAAO,EAAE;oBACL,YAAY;oBACZ,kBAAkB;AACrB,iBAAA;AACD,gBAAA,YAAY,EAAE,CAAC,GAAG,UAAU,CAAC;AAC7B,gBAAA,OAAO,EAAE,CAAC,GAAG,UAAU,CAAC;AAC3B,aAAA,CAAA;;AACY,CAAA,YAAA,EAAA,CAAA,OAAA,SAAA,KAAA,WAAA,IAAA,SAAA,KAAA,EAAA,CAAA,kBAAA,CAAA,YAAY,mBAZrB,8BAA8B;AAC9B,QAAA,qBAAqB,aAKjB,YAAY;AACZ,QAAA,kBAAkB,aAPtB,8BAA8B;QAC9B,qBAAqB,CAAA,EAAA,CAAA,CAAA,EAAA,GAAA;;ACTzB;;AAEG;;;;"}
@@ -1329,7 +1329,7 @@
1329
1329
  }
1330
1330
  this.processBindAttr(propName, attrValue, child);
1331
1331
  }
1332
- else if (type === 'event' && !this.nativeElement.hasAttribute('customwidgetcontainer')) {
1332
+ else if (type === 'event' && !this.nativeElement.hasAttribute('wmwidgetcontainer')) {
1333
1333
  this.processEventAttr(propName, attrValue, meta, child);
1334
1334
  }
1335
1335
  else if (length === 1) {
@@ -442,7 +442,7 @@ export class BaseComponent {
442
442
  }
443
443
  this.processBindAttr(propName, attrValue, child);
444
444
  }
445
- else if (type === 'event' && !this.nativeElement.hasAttribute('customwidgetcontainer')) {
445
+ else if (type === 'event' && !this.nativeElement.hasAttribute('wmwidgetcontainer')) {
446
446
  this.processEventAttr(propName, attrValue, meta, child);
447
447
  }
448
448
  else if (length === 1) {
@@ -657,4 +657,4 @@ export class BaseComponent {
657
657
  }, {
658
658
  type: Optional
659
659
  }] }, { type: Promise }], null); })();
660
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmFzZS5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jb21wb25lbnRzL2Jhc2Uvc3JjL3dpZGdldHMvY29tbW9uL2Jhc2UvYmFzZS5jb21wb25lbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUdILFVBQVUsRUFDVixNQUFNLEVBQ04sTUFBTSxFQUNOLFVBQVUsRUFDVixRQUFRLEVBR1IsUUFBUSxFQUNSLGdCQUFnQixFQUNuQixNQUFNLGVBQWUsQ0FBQztBQUN2QixPQUFPLEVBQUMsWUFBWSxFQUFDLE1BQU0sMkJBQTJCLENBQUM7QUFFdkQsT0FBTyxFQUFDLGFBQWEsRUFBRSxPQUFPLEVBQUMsTUFBTSxNQUFNLENBQUM7QUFFNUMsT0FBTyxFQUNILGVBQWUsRUFDZixXQUFXLEVBQ1gsUUFBUSxFQUNSLE1BQU0sRUFDTixRQUFRLEVBQ1IsR0FBRyxFQUNILFVBQVUsRUFDVixTQUFTLEVBQ1QsV0FBVyxFQUNYLFVBQVUsRUFDVixXQUFXLEVBQ1gsT0FBTyxFQUNQLE1BQU0sRUFDTixhQUFhLEVBQ2IsV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JlYXRlKHRoaXMsIHRoaXMud2lkZ2V0U3ViVHlwZSwgZ2V0V2lkZ2V0UHJvcHNCeVR5cGUodGhpcy53aWRnZXRTdWJUeXBlKSk7XG4gICAgfVxuXG4gICAgcHJvdGVjdGVkIGluaXRDb250ZXh0KCkge1xuICAgICAgICAvLyBjb25zdCBjb250ZXh0ID0gKHRoaXMuaW5qIGFzIGFueSkudmlldy5jb250ZXh0O1xuICAgICAgICBjb25zdCBjb250ZXh0ID0gdGhpcy5jb250ZXh0IHx8IHt9O1xuXG4gICAgICAgIGNvbnN0IHBhcmVudENvbnRleHRzID0gdGhpcy5pbmouZ2V0KENvbnRleHQsIHt9KTtcblxuICAgICAgICAvLyBhc3NpZ24gdGhlIGNvbnRleHQgcHJvcGVydHkgYWNjb3JkaW5nbHlcbiAgICAgICAgaWYgKHRoaXMudmlld1BhcmVudCAhPT0gY29udGV4dCkge1xuICAgICAgICAgICAgdGhpcy5jb250ZXh0ID0gY29udGV4dDtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIHRoaXMuY29udGV4dCA9IHt9O1xuICAgICAgICB9XG5cbiAgICAgICAgaWYgKHBhcmVudENvbnRleHRzKSB7XG4gICAgICAgICAgICBsZXQgcGFyZW50Q29udGV4dE9iaiA9IHt9O1xuICAgICAgICAgICAgaWYgKGlzQXJyYXkocGFyZW50Q29udGV4dHMpKSB7XG4gICAgICAgICAgICAgICAgZm9yRWFjaChwYXJlbnRDb250ZXh0cywgKGNvbnRleHRPYmopID0+IHtcbiAgICAgICAgICAgICAgICAgICAgT2JqZWN0LmFzc2lnbihwYXJlbnRDb250ZXh0T2JqLCBjb250ZXh0T2JqKTtcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgcGFyZW50Q29udGV4dE9iaiA9IHBhcmVudENvbnRleHRzO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgdGhpcy5jb250ZXh0ID0gT2JqZW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xuICAgICAgICByZXR1cm4gd2lkZ2V0SWRHZW5lcmF0b3IubmV4dFVpZCgpO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIEhhbmRsZXMgdGhlIGNvbW1vbiBmdW5jdGlvbmFsaXR5IGFjcm9zcyB0aGUgY29tcG9uZW50c1xuICAgICAqIGVnLFxuICAgICAqICAxLiB2YWx1ZSBvZiB0aGUgY2xhc3MgcHJvcGVydHkgd2lsbCBiZSBhcHBsaWVkIG9uIHRoZSBob3N0IGVsZW1lbnRcbiAgICAgKiAgMi4gYmFzZWQgb24gdGhlIHZhbHVlIG9mIHNob3cgcHJvcGVydHkgY29tcG9uZW50IGlzIHNob3duL2hpZGRlblxuICAgICAqXG4gICAgICogQHBhcmFtIHtzdHJpbmd9IGtleVxuICAgICAqIEBwYXJhbSBudlxuICAgICAqIEBwYXJhbSBvdlxuICAgICAqL1xuICAgIHByb3RlY3RlZCBvblByb3BlcnR5Q2hhbmdlKGtleTogc3RyaW5nLCBudjogYW55LCBvdj86IGFueSkge1xuICAgICAgICBpZiAoa2V5ID09PSAnc2hvdycpIHtcbiAgICAgICAgICAgIHRoaXMubmF0aXZlRWxlbWVudC5oaWRkZW4gPSAhbnY7XG4gICAgICAgIH0gZWxzZSBpZiAoa2V5ID09PSAnaGludCcpIHtcbiAgICAgICAgICAgIGlmICghaXNNb2JpbGVBcHAoKSkge1xuICAgICAgICAgICAgICAgIHNldEF0dHIodGhpcy5uYXRpdmVFbGVtZW50LCAndGl0bGUnLCBudik7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSBpZiAoa2V5ID09PSAnY2xhc3MnKSB7XG4gICAgICAgICAgICBzd2l0Y2hDbGFzcyh0aGlzLm5hdGl2ZUVsZW1lbnQsIG52LCBvdik7XG4gICAgICAgICAgICBsZXQgcmVzdWx0ID0gbnYubWF0Y2goLyhcXFd8XikoaChbMC02XSkpKD89XFxzfCQpLyk7XG4gICAgICAgICAgICBpZiAocmVzdWx0KSB7XG4gIC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dXQoKCkgPT4gZXZlbnRDYWxsYmFjaygpLCAxNTApO1xuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBldmVudENhbGxiYWNrKCk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICApO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIHBhcnNlIHRoZSBldmVudCBleHByZXNzaW9uIGFuZCBzYXZlIHJlZmVyZW5jZSB0byB0aGUgZnVuY3Rpb24gaW5zaWRlIGV2ZW50SGFuZGxlcnMgbWFwXG4gICAgICogSWYgdGhlIGNvbXBvbmVudCBwcm92aWRlcyBhIG92ZXJyaWRlIGZvciBhbiBldmVudCB0aHJvdWdoIEBFdmVudCBkZWNvcmF0b3IgaW52b2tlIHRoYXRcbiAgICAgKiBlbHNlIGludm9rZSB0aGUgcmVzb2x2ZWQgZnVuY3Rpb25cbiAgICAgKlxuICAgICAqIEBwYXJhbSB7c3RyaW5nfSBldmVudE5hbWVcbiAgICAgKiBAcGFyYW0ge3N0cmluZ30gZXhwclxuICAgICAqL1xuICAgIHByb3RlY3RlZCBwcm9jZXNzRXZlbnRBdHRyKGV2ZW50TmFtZTogc3RyaW5nLCBleHByOiBzdHJpbmcsIG1ldGE/OiBzdHJpbmcsIGNoaWxkPzogQ2hpbGQpIHtcbiAgICAgICAgY29uc3QgZm4gPSAkcGFyc2VFdmVudChleHByKTtcbiAgICAgICAgY29uc3QgbG9jYWxzID0gdGhpcy5jb250ZXh0O1xuICAgICAgICBsb2NhbHMud2lkZ2V0ID0gY2hpbGQgPyBjaGlsZC53aWRnZXQgOiB0aGlzLndpZGdldDtcbiAgICAgICAgY29uc3QgYm91bmRGbiA9IGZuLmJpbmQodW5kZWZpbmVkLCBjaGlsZCA/IHRoaXMudmlld1BhcmVudC52aWV3UGFyZW50IDogdGhpcy52aWV3UGFyZW50LCBsb2NhbHMpO1xuXG4gICAgICAgIGxldCB3aWRnZXQgICAgICAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldCA6IHRoaXMsXG4gICAgICAgICAgICBuYXRpdmVFbGVtZW50ICAgPSBjaGlsZCA/IGNoaWxkLm5hdGl2ZUVsZW1lbnQgOiB0aGlzLm5hdGl2ZUVsZW1lbnQ7XG5cbiAgICAgICAgY29uc3QgZXZlbnRDYWxsYmFjayA9ICgpID0+IHtcbiAgICAgICAgICAgIGxldCBib3VuZEZuVmFsO1xuICAgICAgICAgICAgJGludm9rZVdhdGNoZXJzKHRydWUpO1xuICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICBsb2NhbHMuJGV2ZW50ID0gbG9jYWxzLiRldmVudCB8fCBuZXcgd2luZG93LkN1c3RvbUV2ZW50KGV2ZW50TmFtZSk7XG4gICAgICAgICAgICAgICAgLy8gSWYgdGhlIGV2ZW50IGlzIGJvdW5kIGRpcmVjdGx5IHRvIHRoZSB2YXJpYWJsZSB0aGVuIHdlIG5lZWQgdG8gaW50ZXJuYWxseSBoYW5kbGVcbiAgICAgICAgICAgICAgICAvLyB0aGUgcHJvbWlzZSByZXR1cm5lZCBieSB0aGUgdmFyaWFibGUgY2FsbC5cbiAgICAgICAgICAgICAgICBib3VuZEZuVmFsID0gYm91bmRGbigpO1xuICAgICAgICAgICAgICAgIGlmIChib3VuZEZuVmFsIGluc3RhbmNlb2YgUHJvbWlzZSkge1xuICAgICAgICAgICAgICAgICAgICBib3VuZEZuVmFsLnRoZW4oIHJlc3BvbnNlID0+IHJlc3BvbnNlLCBlcnIgPT4gZXJyKTtcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICByZXR1cm4gYm91bmRGblZhbDtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7XG4gICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcihlKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfTtcbiAgICAgICAgaWYoY2hpbGQgJiY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wcmVzc2lvblxuICAgICAqL1xuICAgIHByb3RlY3RlZCBwcm9jZXNzQmluZEF0dHIocHJvcE5hbWU6IHN0cmluZywgZXhwcjogc3RyaW5nLCBjaGlsZCA/OiBhbnkpIHtcbiAgICAgICAgaWYoIWNoaWxkKVxuICAgICAgICAgICAgdGhpcy5pbml0U3RhdGUuZGVsZXRlKHByb3BOYW1lKTtcbiAgICAgICAgbGV0IHZpZXdQYXJlbnQgID0gY2hpbGQgPyBjaGlsZC53aWRnZXQudmlld1BhcmVudC52aWV3UGFyZW50IDogdGhpcy52aWV3UGFyZW50LFxuICAgICAgICAgICAgY29udGV4dCAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldC5jb250ZXh0IDogdGhpcy5jb250ZXh0LFxuICAgICAgICAgICAgd2lkZ2V0ICAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldCA6IHRoaXMud2lkZ2V0LFxuICAgICAgICAgICAgaXNNdXRlZCAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldC5pc011dGVkIDogdGhpcy5pc011dGVkLFxuICAgICAgICAgICAgd2lkZ2V0UHJvcHMgPSBjaGlsZCA/IGNoaWxkLndpZGdldC53aWRnZXRQcm9wcyA6IHRoaXMud2lkZ2V0UHJvcHMsXG4gICAgICAgICAgICB3aWRnZXRJZCAgICA9IGNoaWxkID8gY2hpbGQud2lkZ2V0LndpZGdldElkIDogdGhpcy53aWRnZXRJZDtcbiAgICAgICAgdGhpcy5yZWdpc3RlckRlc3Ryb3lMaXN0ZW5lcihcbiAgICAgICAgICAgICR3YXRjaChcbiAgICAgICAgICAgICAgICBleHByLFxuICAgICAgICAgICAgICAgIHZpZXdQYXJlbnQsXG4gICAgICAgICAgICAgICAgY29udGV4dCxcbiAgICAgICAgICAgICAgICBudiA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmKHByb3BOYW1lLnN0YXJ0c1dpdGgoJ2Jhc2UtJykgJiYgd2lkZ2V0LnVwZGF0ZURhdGEpXG4gICAgICAgICAgICAgICAgICAgICAgICB3aWRnZXQudXBkYXRlRGF0YShwcm9wTmFtZSwgbnYpO1xuICAgICAgICAgICAgICAgICAgICB3aWRnZXRbcHJvcE5hbWVdID0gbnZcbiAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIGdldFdhdGNoSWRlbnRpZmllcih3aWRnZXRJZCwgcHJvcE5hbWUpLFxuICAgICAgICAgICAgICAgIHByb3BOYW1lID09PSAnZGF0YXNvdXJjZScsXG4gICAgICAgICAgICAgICAgd2lkZ2V0UHJvcHMuZ2V0KHByb3BOYW1lKSxcbiAgICAgICAgICAgICAgICAoKSA9PiBpc011dGVkXG4gICAgICAgICAgICApXG4gICAgICAgICk7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogUmVtb3ZlIHdhdGNoIG9uIHRoZSBib3VuZCBwcm9wZXJ0eVxuICAgICAqL1xuICAgIHByb3RlY3RlZCByZW1vdmVQcm9wZXJ0eUJpbmRpbmcocHJvcE5hbWU6IHN0cmluZykge1xuICAgICAgICAkdW53YXRjaChnZXRXYXRjaElkZW50aWZpZXIodGhpcy53aWRnZXRJZCwgcHJvcE5hbWUpKTtcbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBpbnZva2UgdGhlIGV2ZW50IGNhbGxiYWNrIG1ldGhvZFxuICAgICAqIEBwYXJhbSB7c3RyaW5nfSBldmVudE5hbWVcbiAgICAgKiBAcGFyYW0gZXh0cmFMb2NhbHNcbiAgICAgKi9cbiAgICBwdWJsaWMgaW52b2tlRXZlbnRDYWxsYmFjayhldmVudE5hbWU6IHN0cmluZywgZXh0cmFMb2NhbHM/OiBhbnkpIHtcbiAgICAgICAgY29uc3QgY2FsbGJhY2tJbmZvID0gdGhpcy5ldmVudEhhbmRsZXJzLmdldChldmVudE5hbWUpO1xuICAgICAgICBpZiAoY2FsbGJhY2tJbmZvKSB7XG4gICAgICAgICAgICBjb25zdCBmbiA9IGNhbGxiYWNrSW5mby5jYWxsYmFjaztcb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RoaXMsIHRoaXMud2lkZ2V0U3ViVHlwZSwgZ2V0V2lkZ2V0UHJvcHNCeVR5cGUodGhpcy53aWRnZXRTdWJUeXBlKSk7XG4gICAgfVxuXG4gICAgcHJvdGVjdGVkIGluaXRDb250ZXh0KCkge1xuICAgICAgICAvLyBjb25zdCBjb250ZXh0ID0gKHRoaXMuaW5qIGFzIGFueSkudmlldy5jb250ZXh0O1xuICAgICAgICBjb25zdCBjb250ZXh0ID0gdGhpcy5jb250ZXh0IHx8IHt9O1xuXG4gICAgICAgIGNvbnN0IHBhcmVudENvbnRleHRzID0gdGhpcy5pbmouZ2V0KENvbnRleHQsIHt9KTtcblxuICAgICAgICAvLyBhc3NpZ24gdGhlIGNvbnRleHQgcHJvcGVydHkgYWNjb3JkaW5nbHlcbiAgICAgICAgaWYgKHRoaXMudmlld1BhcmVudCAhPT0gY29udGV4dCkge1xuICAgICAgICAgICAgdGhpcy5jb250ZXh0ID0gY29udGV4dDtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIHRoaXMuY29udGV4dCA9IHt9O1xuICAgICAgICB9XG5cbiAgICAgICAgaWYgKHBhcmVudENvbnRleHRzKSB7XG4gICAgICAgICAgICBsZXQgcGFyZW50Q29udGV4dE9iaiA9IHt9O1xuICAgICAgICAgICAgaWYgKGlzQXJyYXkocGFyZW50Q29udGV4dHMpKSB7XG4gICAgICAgICAgICAgICAgZm9yRWFjaChwYXJlbnRDb250ZXh0cywgKGNvbnRleHRPYmopID0+IHtcbiAgICAgICAgICAgICAgICAgICAgT2JqZWN0LmFzc2lnbihwYXJlbnRDb250ZXh0T2JqLCBjb250ZXh0T2JqKTtcbiAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgcGFyZW50Q29udGV4dE9iaiA9IHBhcmVudENvbnRleHRzO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgdGhpcy5jb250ZXh0ID0gT2JqZWN0LmFzc2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ICByZXR1cm4gd2lkZ2V0SWRHZW5lcmF0b3IubmV4dFVpZCgpO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIEhhbmRsZXMgdGhlIGNvbW1vbiBmdW5jdGlvbmFsaXR5IGFjcm9zcyB0aGUgY29tcG9uZW50c1xuICAgICAqIGVnLFxuICAgICAqICAxLiB2YWx1ZSBvZiB0aGUgY2xhc3MgcHJvcGVydHkgd2lsbCBiZSBhcHBsaWVkIG9uIHRoZSBob3N0IGVsZW1lbnRcbiAgICAgKiAgMi4gYmFzZWQgb24gdGhlIHZhbHVlIG9mIHNob3cgcHJvcGVydHkgY29tcG9uZW50IGlzIHNob3duL2hpZGRlblxuICAgICAqXG4gICAgICogQHBhcmFtIHtzdHJpbmd9IGtleVxuICAgICAqIEBwYXJhbSBudlxuICAgICAqIEBwYXJhbSBvdlxuICAgICAqL1xuICAgIHByb3RlY3RlZCBvblByb3BlcnR5Q2hhbmdlKGtleTogc3RyaW5nLCBudjogYW55LCBvdj86IGFueSkge1xuICAgICAgICBpZiAoa2V5ID09PSAnc2hvdycpIHtcbiAgICAgICAgICAgIHRoaXMubmF0aXZlRWxlbWVudC5oaWRkZW4gPSAhbnY7XG4gICAgICAgIH0gZWxzZSBpZiAoa2V5ID09PSAnaGludCcpIHtcbiAgICAgICAgICAgIGlmICghaXNNb2JpbGVBcHAoKSkge1xuICAgICAgICAgICAgICAgIHNldEF0dHIodGhpcy5uYXRpdmVFbGVtZW50LCAndGl0bGUnLCBudik7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSBpZiAoa2V5ID09PSAnY2xhc3MnKSB7XG4gICAgICAgICAgICBzd2l0Y2hDbGFzcyh0aGlzLm5hdGl2ZUVsZW1lbnQsIG52LCBvdik7XG4gICAgICAgICAgICBsZXQgcmVzdWx0ID0gbnYubWF0Y2goLyhcXFd8XikoaChbMC02XSkpKD89XFxzfCQpLyk7XG4gICAgICAgICAgICBpZiAocmVzdWx0KSB7XG4gICAgICAgICAg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PT4gZXZlbnRDYWxsYmFjaygpLCAxNTApO1xuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBldmVudENhbGxiYWNrKCk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICApO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIHBhcnNlIHRoZSBldmVudCBleHByZXNzaW9uIGFuZCBzYXZlIHJlZmVyZW5jZSB0byB0aGUgZnVuY3Rpb24gaW5zaWRlIGV2ZW50SGFuZGxlcnMgbWFwXG4gICAgICogSWYgdGhlIGNvbXBvbmVudCBwcm92aWRlcyBhIG92ZXJyaWRlIGZvciBhbiBldmVudCB0aHJvdWdoIEBFdmVudCBkZWNvcmF0b3IgaW52b2tlIHRoYXRcbiAgICAgKiBlbHNlIGludm9rZSB0aGUgcmVzb2x2ZWQgZnVuY3Rpb25cbiAgICAgKlxuICAgICAqIEBwYXJhbSB7c3RyaW5nfSBldmVudE5hbWVcbiAgICAgKiBAcGFyYW0ge3N0cmluZ30gZXhwclxuICAgICAqL1xuICAgIHByb3RlY3RlZCBwcm9jZXNzRXZlbnRBdHRyKGV2ZW50TmFtZTogc3RyaW5nLCBleHByOiBzdHJpbmcsIG1ldGE/OiBzdHJpbmcsIGNoaWxkPzogQ2hpbGQpIHtcbiAgICAgICAgY29uc3QgZm4gPSAkcGFyc2VFdmVudChleHByKTtcbiAgICAgICAgY29uc3QgbG9jYWxzID0gdGhpcy5jb250ZXh0O1xuICAgICAgICBsb2NhbHMud2lkZ2V0ID0gY2hpbGQgPyBjaGlsZC53aWRnZXQgOiB0aGlzLndpZGdldDtcbiAgICAgICAgY29uc3QgYm91bmRGbiA9IGZuLmJpbmQodW5kZWZpbmVkLCBjaGlsZCA/IHRoaXMudmlld1BhcmVudC52aWV3UGFyZW50IDogdGhpcy52aWV3UGFyZW50LCBsb2NhbHMpO1xuXG4gICAgICAgIGxldCB3aWRnZXQgICAgICAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldCA6IHRoaXMsXG4gICAgICAgICAgICBuYXRpdmVFbGVtZW50ICAgPSBjaGlsZCA/IGNoaWxkLm5hdGl2ZUVsZW1lbnQgOiB0aGlzLm5hdGl2ZUVsZW1lbnQ7XG5cbiAgICAgICAgY29uc3QgZXZlbnRDYWxsYmFjayA9ICgpID0+IHtcbiAgICAgICAgICAgIGxldCBib3VuZEZuVmFsO1xuICAgICAgICAgICAgJGludm9rZVdhdGNoZXJzKHRydWUpO1xuICAgICAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgICAgICBsb2NhbHMuJGV2ZW50ID0gbG9jYWxzLiRldmVudCB8fCBuZXcgd2luZG93LkN1c3RvbUV2ZW50KGV2ZW50TmFtZSk7XG4gICAgICAgICAgICAgICAgLy8gSWYgdGhlIGV2ZW50IGlzIGJvdW5kIGRpcmVjdGx5IHRvIHRoZSB2YXJpYWJsZSB0aGVuIHdlIG5lZWQgdG8gaW50ZXJuYWxseSBoYW5kbGVcbiAgICAgICAgICAgICAgICAvLyB0aGUgcHJvbWlzZSByZXR1cm5lZCBieSB0aGUgdmFyaWFibGUgY2FsbC5cbiAgICAgICAgICAgICAgICBib3VuZEZuVmFsID0gYm91bmRGbigpO1xuICAgICAgICAgICAgICAgIGlmIChib3VuZEZuVmFsIGluc3RhbmNlb2YgUHJvbWlzZSkge1xuICAgICAgICAgICAgICAgICAgICBib3VuZEZuVmFsLnRoZW4oIHJlc3BvbnNlID0+IHJlc3BvbnNlLCBlcnIgPT4gZXJyKTtcbiAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICByZXR1cm4gYm91bmRGblZhbDtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9IGNhdGNoIChlKSB7XG4gICAgICAgICAgICAgICAgY29uc29sZS5lcnJvcihlKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfTtcbiAgICAgICAgaWYoY2hpbGQgJiYgIWNoaWx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vblxuICAgICAqL1xuICAgIHByb3RlY3RlZCBwcm9jZXNzQmluZEF0dHIocHJvcE5hbWU6IHN0cmluZywgZXhwcjogc3RyaW5nLCBjaGlsZCA/OiBhbnkpIHtcbiAgICAgICAgaWYoIWNoaWxkKVxuICAgICAgICAgICAgdGhpcy5pbml0U3RhdGUuZGVsZXRlKHByb3BOYW1lKTtcbiAgICAgICAgbGV0IHZpZXdQYXJlbnQgID0gY2hpbGQgPyBjaGlsZC53aWRnZXQudmlld1BhcmVudC52aWV3UGFyZW50IDogdGhpcy52aWV3UGFyZW50LFxuICAgICAgICAgICAgY29udGV4dCAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldC5jb250ZXh0IDogdGhpcy5jb250ZXh0LFxuICAgICAgICAgICAgd2lkZ2V0ICAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldCA6IHRoaXMud2lkZ2V0LFxuICAgICAgICAgICAgaXNNdXRlZCAgICAgPSBjaGlsZCA/IGNoaWxkLndpZGdldC5pc011dGVkIDogdGhpcy5pc011dGVkLFxuICAgICAgICAgICAgd2lkZ2V0UHJvcHMgPSBjaGlsZCA/IGNoaWxkLndpZGdldC53aWRnZXRQcm9wcyA6IHRoaXMud2lkZ2V0UHJvcHMsXG4gICAgICAgICAgICB3aWRnZXRJZCAgICA9IGNoaWxkID8gY2hpbGQud2lkZ2V0LndpZGdldElkIDogdGhpcy53aWRnZXRJZDtcbiAgICAgICAgdGhpcy5yZWdpc3RlckRlc3Ryb3lMaXN0ZW5lcihcbiAgICAgICAgICAgICR3YXRjaChcbiAgICAgICAgICAgICAgICBleHByLFxuICAgICAgICAgICAgICAgIHZpZXdQYXJlbnQsXG4gICAgICAgICAgICAgICAgY29udGV4dCxcbiAgICAgICAgICAgICAgICBudiA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGlmKHByb3BOYW1lLnN0YXJ0c1dpdGgoJ2Jhc2UtJykgJiYgd2lkZ2V0LnVwZGF0ZURhdGEpXG4gICAgICAgICAgICAgICAgICAgICAgICB3aWRnZXQudXBkYXRlRGF0YShwcm9wTmFtZSwgbnYpO1xuICAgICAgICAgICAgICAgICAgICB3aWRnZXRbcHJvcE5hbWVdID0gbnZcbiAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIGdldFdhdGNoSWRlbnRpZmllcih3aWRnZXRJZCwgcHJvcE5hbWUpLFxuICAgICAgICAgICAgICAgIHByb3BOYW1lID09PSAnZGF0YXNvdXJjZScsXG4gICAgICAgICAgICAgICAgd2lkZ2V0UHJvcHMuZ2V0KHByb3BOYW1lKSxcbiAgICAgICAgICAgICAgICAoKSA9PiBpc011dGVkXG4gICAgICAgICAgICApXG4gICAgICAgICk7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogUmVtb3ZlIHdhdGNoIG9uIHRoZSBib3VuZCBwcm9wZXJ0eVxuICAgICAqL1xuICAgIHByb3RlY3RlZCByZW1vdmVQcm9wZXJ0eUJpbmRpbmcocHJvcE5hbWU6IHN0cmluZykge1xuICAgICAgICAkdW53YXRjaChnZXRXYXRjaElkZW50aWZpZXIodGhpcy53aWRnZXRJZCwgcHJvcE5hbWUpKTtcbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBpbnZva2UgdGhlIGV2ZW50IGNhbGxiYWNrIG1ldGhvZFxuICAgICAqIEBwYXJhbSB7c3RyaW5nfSBldmVudE5hbWVcbiAgICAgKiBAcGFyYW0gZXh0cmFMb2NhbHNcbiAgICAgKi9cbiAgICBwdWJsaWMgaW52b2tlRXZlbnRDYWxsYmFjayhldmVudE5hbWU6IHN0cmluZywgZXh0cmFMb2NhbHM/OiBhbnkpIHtcbiAgICAgICAgY29uc3QgY2FsbGJhY2tJbmZvID0gdGhpcy5ldmVudEhhbmRsZXJzLmdldChldmVudE5hbWUpO1xuICAgICAgICBpZiAoY2FsbGJhY2tJbmZvKSB7XG4gICAgICAgICAgICBjb25zdCBmbiA9IGNhbGxiYWNrSW5mby5jYWxsYmFjaztcbiAgICAgICA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pO1xuICAgICAgICBpZihfdE5vZGVBdHRycyA9PT0gbnVsbCkge1xuICAgICAgICAgICAgcmV0dXJuIGFjdHVhbEF0dHJzLnNvcnQoKTtcbiAgICAgICAgfVxuICAgICAgICBmb3JFYWNoKF90Tm9kZUF0dHJzLCAoYXR0ciwgaTogYW55KSA9PiB7XG4gICAgICAgICAgICBpZiAodHlwZW9mIGF0dHIgPT09ICdudW1iZXInKSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYodHlwZW9mIGF0dHIgPT09ICdzdHJpbmcnICYmIGkgJSAyID09IDApIHtcbiAgICAgICAgICAgICAgICBsZXQgbG93ZXJDYXNlQXR0ciA9IGF0dHIudG9Mb3dlckNhc2UoKTtcbiAgICAgICAgICAgICAgICBpZiAoYWN0dWFsQXR0cnMuaW5jbHVkZXMobG93ZXJDYXNlQXR0cikpIHtcbiAgICAgICAgICAgICAgICAgICAgbGV0IGluZGV4ID0gYWN0dWFsQXR0cnMuaW5kZXhPZihsb3dlckNhc2VBdHRyKVxuICAgICAgICAgICAgICAgICAgICBhY3R1YWxBdHRyc1tpbmRleF0gPSBhdHRyO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfSk7XG5cbiAgICAgICAgLypcbiAgICAgICAgU29ydGluZyBhdHRyaWJ1dGVzIGFzIHByb3BlcnRpZXMgbGlrZSBwbGFjZWhvbGRlciBpcyBub3Qgd29ya2luZyB3aGVuIGl0IGlzIGJvdW5kLlxuICAgICAgICBwbGFjZWhvbGRlciBhbmQgcGxhY2Vob2xkZXIuYmluZCB0d28gcHJvcGVydGllcyBhcmUgY29taW5nIGluIEFycmF5LlxuICAgICAgICBXaGVuIGFycmF5IGlzIG5vdCBzb3J0ZWQsIGluaXRpYWxseSBwbGFjZWhvbGRlci5iaW5kIHZhbHVlIGlzIHNldCB0aGVuIHBsYWNlaG9sZGVyIGRlZmF1bHQg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uICAgICAgICB0aGlzLndpZGdldCA9IE9iamVjdC5jcmVhdGUobnVsbCk7XG4gICAgICAgIHRoaXMuc3R5bGVDaGFuZ2UuY29tcGxldGUoKTtcbiAgICAgICAgdGhpcy5wcm9wZXJ0eUNoYW5nZS5jb21wbGV0ZSgpO1xuICAgICAgICB0aGlzLmRlc3Ryb3kuY29tcGxldGUoKTtcbiAgICAgICAgdGhpcy5pc0F0dGFjaGVkID0gZmFsc2U7XG4gICAgfVxufVxuIl19
@@ -1322,7 +1322,7 @@ class BaseComponent {
1322
1322
  }
1323
1323
  this.processBindAttr(propName, attrValue, child);
1324
1324
  }
1325
- else if (type === 'event' && !this.nativeElement.hasAttribute('customwidgetcontainer')) {
1325
+ else if (type === 'event' && !this.nativeElement.hasAttribute('wmwidgetcontainer')) {
1326
1326
  this.processEventAttr(propName, attrValue, meta, child);
1327
1327
  }
1328
1328
  else if (length === 1) {