Socket
Socket
Sign inDemoInstall

@grapecity/wijmo.angular2.directivebase

Package Overview
Dependencies
Maintainers
0
Versions
1296
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@grapecity/wijmo.angular2.directivebase - npm Package Compare versions

Comparing version 5.20241.9 to 5.20241.19

4

es2015-commonjs.js
/*!
*
* Wijmo Library 5.20241.9
* Wijmo Library 5.20241.19
* https://developer.mescius.com/wijmo

@@ -14,2 +14,2 @@ *

"use strict";var __importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)Object.hasOwnProperty.call(e,i)&&(t[i]=e[i]);t.default=e;return t};Object.defineProperty(exports,"__esModule",{value:!0});const core_1=require("@angular/core"),wijmo=__importStar(require("@grapecity/wijmo"));class WjOptions{}WjOptions.asyncBindings=!0;exports.WjOptions=WjOptions;class WjComponentResolvedMetadata{constructor(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}resolveChangeEventMap(e){let t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(!i||!i.length)return;let n=i.map(e=>e.split(":")).map(e=>({implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}));this.allImplEvents=n.map(e=>e.implName);let s=n.filter(e=>e.implName&&e.exposeName);for(let e of s){if(Ng2Utils.getWjEventName(e.implName)){let i={eventImpl:e.implName,event:e.exposeName},n=r[e.exposeName];n&&n.length&&(i.props=n.map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}));t.push(i)}}for(let e in r)if(e.indexOf(".")>-1){let i={eventImpl:null,event:e,props:r[e].map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})};t.push(i)}}}exports.WjComponentResolvedMetadata=WjComponentResolvedMetadata;class WjDirectiveBehavior{constructor(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=e=>e();this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();let n=this.nz=i.get(core_1.NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;let s=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==s.siblingId&&(s.siblingId=++WjDirectiveBehavior.siblingDirId+"");let o=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];o?this.resolvedTypeData=o:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=o=this.resolvedTypeData=new WjComponentResolvedMetadata(s);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,s.siblingId);this.subscribeToEvents(!1)}static getHostElement(e,t){WjDirectiveBehavior.ngZone=t.get(core_1.NgZone);return e.nativeElement}static attach(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)}static getZone(e){const t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone}ngOnInit(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)}ngAfterViewInit(){this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout(()=>{this.isDestroyed||this.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)})}ngOnDestroy(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){let i=this.parentBehavior.directive,r=this._getParentProp();if(!this.parentBehavior.isDestroyed&&i&&r&&e){let n=i[r];if(wijmo.isArray(n)&&n){var t=n.indexOf(e);t>=0&&n.splice(t,1)}}}if(e instanceof wijmo.Control&&e.hostElement){let t=this.elementRef.nativeElement,i=t&&t.parentNode,r=i?Array.prototype.indexOf.call(i.childNodes,t):-1;e.dispose();if(r>-1&&Array.prototype.indexOf.call(i.childNodes,t)<0){t.textContent="";r<i.childNodes.length&&i.replaceChild(t,i.childNodes[r])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}}static instantiateTemplate(e,t,i,r=!1,n={}){var s,o=t.createEmbeddedView(i,n,t.length),a=o.rootNodes;if(r&&1===a.length)s=a[0];else{s=document.createElement("div");for(let e of a)s.appendChild(e)}e&&e.appendChild(s);return{viewRef:o,rootElement:s}}getPropChangeEvent(e){let t=this.typeData.changeEvents;if(t)for(let i in t)if(t[i].indexOf(e)>-1)return i;return null}_createEvents(){let e=this.resolvedTypeData.allImplEvents;for(let t of e)this.directive[t]=new core_1.EventEmitter(!1)}_overrideDirectiveMethods(){const e=this.directive;if(e instanceof wijmo.Control){const t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){core_1.NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run(()=>{t(e)})}.bind(e)}}subscribeToEvents(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(let i of t)e!==i.event.indexOf(".")<0&&this.addHandlers(i);if(e)for(let e of t)this.triggerPropChangeEvents(e,!0)}addHandlers(e){let t=this.directive;WjDirectiveBehavior.evaluatePath(t,e.event).addHandler((i,r)=>{this.nzRun(()=>{this.isInitialized&&this.triggerPropChangeEvents(e);e.eventImpl&&this._triggerEvent(t[e.eventImpl],r,e.props&&e.props.length>0)})})}triggerPropChangeEvents(e,t=!0){let i=this.directive;if(e.props&&e.props.length)for(let r of e.props)this._triggerEvent(i[r.evImpl],i[r.prop],t)}_setupAsChild(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}}_isAsyncBinding(){let e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e}_isChild(){return this._isParentInitializer()||this._isParentReferencer()}_isParentInitializer(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]}_isParentReferencer(){return!!this.typeData.parentRefProperty}_getParentProp(){return this.directive[WjDirectiveBehavior.parPropAttr]}_getParentReferenceProperty(){return this.typeData.parentRefProperty}_useParentObj(){return!1}_parentInCtor(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()}_initParent(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();let r=e[t];if(wijmo.isArray(r)){let e=this._isHostElement(),t=e?this._getSiblingIndex():-1;(t<0||t>=r.length)&&(t=r.length);r.splice(t,0,i);if(e){const e=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(e,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}}_getSiblingIndex(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,s=0;s<i.length;s++){var o=i[s];if(1==o.nodeType&&o.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(o===e)return r}}return-1}_siblingInserted(e){for(let t of e)if("childList"===t.type&&t.addedNodes.length>0){if(Array.from(t.addedNodes).some(e=>e===this.elementRef.nativeElement)){const e=this._getSiblingIndex(),t=this.parentBehavior.directive[this._getParentProp()],i=this.directive,r=t.indexOf(i);if(e>=0&&r>=0&&e!==r){t.splice(r,1);const n=Math.min(e,t.length);t.splice(n,0,i)}}}}_isHostElement(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE}_triggerEvent(e,t,i){if(i&&this._isAsyncBinding()){let i={event:e,args:t};this._pendingEvents.push(i);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout(()=>{this._triggerPendingEvents(!1)},0))}else e.emit(t)}_triggerPendingEvents(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(this.isDestroyed)return;let t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(let e of t)e.event.emit(e.args);e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}flushPendingEvents(){this._triggerPendingEvents(!0)}static evaluatePath(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)}static getBehavior(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null}}WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");exports.WjDirectiveBehavior=WjDirectiveBehavior;class Ng2Utils{static initEvents(e,t){var i=[];for(let e of t){let t=e.props;e.event&&e.eventImpl&&i.push(e.eventImpl+":"+e.event);if(t&&t.length)for(let e of t)i.push(e.evImpl+":"+e.evExposed)}return i}static getChangeEventNameImplemented(e){return Ng2Utils.getChangeEventNameExposed(e)+Ng2Utils.changeEventImplementSuffix}static getChangeEventNameExposed(e){return e+"Change"}static getWjEventNameImplemented(e){return e+Ng2Utils.wjEventImplementSuffix}static getWjEventName(e){if(e){const t=Ng2Utils.wjEventImplementSuffix;let i=e.length-t.length;if(i>0&&e.substr(i)===t)return e.substr(0,i)}return null}static getBaseType(e){let t;return e&&(t=Object.getPrototypeOf(e.prototype))&&t.constructor}static getAnnotations(e){return Reflect.getMetadata("annotations",e)}static getAnnotation(e,t){if(t&&e)for(let i of e)if(i instanceof t)return i;return null}static getTypeAnnotation(e,t,i){for(let r=e;r;r=i?null:Ng2Utils.getBaseType(r)){let e=Ng2Utils.getAnnotation(Ng2Utils.getAnnotations(r),t);if(e)return e}return null}static equals(e,t){return e!=e&&t!=t||wijmo.DateTime.equals(e,t)||e===t}static _copy(e,t,i,r,n){if(e&&t)for(let s in t)if(r||"_"!==s[0]){let r=t[s];if(!n||n(s,r)){let t=e[s];wijmo.isArray(r)?e[s]=(!wijmo.isArray(t)||i?[]:t).concat(r):void 0!==r&&(e[s]=r)}}}}Ng2Utils.changeEventImplementSuffix="PC";Ng2Utils.wjEventImplementSuffix="Ng";exports.Ng2Utils=Ng2Utils;class WjValueAccessor{constructor(e){this._writeQnt=0;this._isSubscribed=!1;this._dirUpdateQnt=0;this._onChange=e=>{};this._onTouched=()=>{};this._directive=e;this._behavior=WjDirectiveBehavior.getBehavior(e)}writeValue(e){this._modelValue=e;++this._writeQnt;if(this._directive.isInitialized){this._ensureInitEhUnsubscribed();this._updateDirective()}else if(!this._dirInitEh){let e=this._directive.initialized;this._dirInitEh=e.subscribe(()=>{this._updateDirective();this._ensureInitEhUnsubscribed()})}}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){let t=this._directive;t instanceof wijmo.Control&&(t.isDisabled=e)}_updateDirective(){if(!this._isFirstChange()||null!=this._modelValue){this._ensureNgModelProp();if(this._directive&&this._ngModelProp){let e=this._modelValue;""===e&&(e=null);this._dirUpdateQnt++;try{this._directive[this._ngModelProp]=e}finally{this._dirUpdateQnt--}}this._ensureSubscribed()}}_ensureSubscribed(){if(this._isSubscribed)return;let e=this._directive;if(e){this._ensureNgModelProp();let t=this._ngModelProp=e[WjDirectiveBehavior.wjModelPropAttr];if(t){let i=this._behavior.getPropChangeEvent(t);i&&e[i].addHandler(this._dirValChgEh,this)}e instanceof wijmo.Control&&e.lostFocus.addHandler(this._dirLostFocusEh,this);this._isSubscribed=!0}}_ensureNgModelProp(){!this._ngModelProp&&this._directive&&(this._ngModelProp=this._directive[WjDirectiveBehavior.wjModelPropAttr])}_ensureInitEhUnsubscribed(){if(this._dirInitEh){this._dirInitEh.unsubscribe();this._dirInitEh=null}}_isFirstChange(){return this._writeQnt<2}_dirValChgEh(e,t){if(this._onChange&&this._directive&&this._ngModelProp){let e=this._directive[this._ngModelProp],t=this._modelValue;""===t&&(t=null);if(!(this._dirUpdateQnt>0&&_isNullOrEmpty(t)&&_isNullOrEmpty(e)||Ng2Utils.equals(t,e))||wijmo.isArray(e)){this._modelValue=e;this._onChange(e)}}}_dirLostFocusEh(e,t){this._onTouched&&this._onTouched()}}exports.WjValueAccessor=WjValueAccessor;function WjValueAccessorFactory(e){return new WjValueAccessor(e)}exports.WjValueAccessorFactory=WjValueAccessorFactory;function _isNullOrEmpty(e){return null==e||""===e}
"use strict";var __importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)Object.hasOwnProperty.call(e,i)&&(t[i]=e[i]);t.default=e;return t};Object.defineProperty(exports,"__esModule",{value:!0});const core_1=require("@angular/core"),wijmo=__importStar(require("@grapecity/wijmo"));class WjOptions{}WjOptions.asyncBindings=!0;exports.WjOptions=WjOptions;class WjComponentResolvedMetadata{constructor(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}resolveChangeEventMap(e){let t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(!i||!i.length)return;let n=i.map(e=>e.split(":")).map(e=>({implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}));this.allImplEvents=n.map(e=>e.implName);let s=n.filter(e=>e.implName&&e.exposeName);for(let e of s){if(Ng2Utils.getWjEventName(e.implName)){let i={eventImpl:e.implName,event:e.exposeName},n=r[e.exposeName];n&&n.length&&(i.props=n.map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}));t.push(i)}}for(let e in r)if(e.indexOf(".")>-1){let i={eventImpl:null,event:e,props:r[e].map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})};t.push(i)}}}exports.WjComponentResolvedMetadata=WjComponentResolvedMetadata;class WjDirectiveBehavior{constructor(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=e=>e();this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();let n=this.nz=i.get(core_1.NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;let s=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==s.siblingId&&(s.siblingId=++WjDirectiveBehavior.siblingDirId+"");let o=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];o?this.resolvedTypeData=o:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=o=this.resolvedTypeData=new WjComponentResolvedMetadata(s);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,s.siblingId);this.subscribeToEvents(!1);this.directive instanceof wijmo.Control&&(this.directive.workingAs="Angular2")}static getHostElement(e,t){WjDirectiveBehavior.ngZone=t.get(core_1.NgZone);return e.nativeElement}static attach(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)}static getZone(e){const t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone}ngOnInit(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)}ngAfterViewInit(){this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout(()=>{this.isDestroyed||this.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)})}ngOnDestroy(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){let i=this.parentBehavior.directive,r=this._getParentProp();if(!this.parentBehavior.isDestroyed&&i&&r&&e){let n=i[r];if(wijmo.isArray(n)&&n){var t=n.indexOf(e);t>=0&&n.splice(t,1)}}}if(e instanceof wijmo.Control&&e.hostElement){let t=this.elementRef.nativeElement,i=t&&t.parentNode,r=i?Array.prototype.indexOf.call(i.childNodes,t):-1;e.dispose();if(r>-1&&Array.prototype.indexOf.call(i.childNodes,t)<0){t.textContent="";r<i.childNodes.length&&i.replaceChild(t,i.childNodes[r])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}}static instantiateTemplate(e,t,i,r=!1,n={}){var s,o=t.createEmbeddedView(i,n,t.length),a=o.rootNodes;if(r&&1===a.length)s=a[0];else{s=document.createElement("div");for(let e of a)s.appendChild(e)}e&&e.appendChild(s);return{viewRef:o,rootElement:s}}getPropChangeEvent(e){let t=this.typeData.changeEvents;if(t)for(let i in t)if(t[i].indexOf(e)>-1)return i;return null}_createEvents(){let e=this.resolvedTypeData.allImplEvents;for(let t of e)this.directive[t]=new core_1.EventEmitter(!1)}_overrideDirectiveMethods(){const e=this.directive;if(e instanceof wijmo.Control){const t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){core_1.NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run(()=>{t(e)})}.bind(e)}}subscribeToEvents(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(let i of t)e!==i.event.indexOf(".")<0&&this.addHandlers(i);if(e)for(let e of t)this.triggerPropChangeEvents(e,!0)}addHandlers(e){let t=this.directive;WjDirectiveBehavior.evaluatePath(t,e.event).addHandler((i,r)=>{this.nzRun(()=>{this.isInitialized&&this.triggerPropChangeEvents(e);e.eventImpl&&this._triggerEvent(t[e.eventImpl],r,e.props&&e.props.length>0)})})}triggerPropChangeEvents(e,t=!0){let i=this.directive;if(e.props&&e.props.length)for(let r of e.props)this._triggerEvent(i[r.evImpl],i[r.prop],t)}_setupAsChild(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}}_isAsyncBinding(){let e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e}_isChild(){return this._isParentInitializer()||this._isParentReferencer()}_isParentInitializer(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]}_isParentReferencer(){return!!this.typeData.parentRefProperty}_getParentProp(){return this.directive[WjDirectiveBehavior.parPropAttr]}_getParentReferenceProperty(){return this.typeData.parentRefProperty}_useParentObj(){return!1}_parentInCtor(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()}_initParent(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();let r=e[t];if(wijmo.isArray(r)){let e=this._isHostElement(),t=e?this._getSiblingIndex():-1;(t<0||t>=r.length)&&(t=r.length);r.splice(t,0,i);if(e){const e=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(e,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}}_getSiblingIndex(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,s=0;s<i.length;s++){var o=i[s];if(1==o.nodeType&&o.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(o===e)return r}}return-1}_siblingInserted(e){for(let t of e)if("childList"===t.type&&t.addedNodes.length>0){if(Array.from(t.addedNodes).some(e=>e===this.elementRef.nativeElement)){const e=this._getSiblingIndex(),t=this.parentBehavior.directive[this._getParentProp()],i=this.directive,r=t.indexOf(i);if(e>=0&&r>=0&&e!==r){t.splice(r,1);const n=Math.min(e,t.length);t.splice(n,0,i)}}}}_isHostElement(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE}_triggerEvent(e,t,i){if(i&&this._isAsyncBinding()){let i={event:e,args:t};this._pendingEvents.push(i);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout(()=>{this._triggerPendingEvents(!1)},0))}else e.emit(t)}_triggerPendingEvents(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(this.isDestroyed)return;let t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(let e of t)e.event.emit(e.args);e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}flushPendingEvents(){this._triggerPendingEvents(!0)}static evaluatePath(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)}static getBehavior(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null}}WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");exports.WjDirectiveBehavior=WjDirectiveBehavior;class Ng2Utils{static initEvents(e,t){var i=[];for(let e of t){let t=e.props;e.event&&e.eventImpl&&i.push(e.eventImpl+":"+e.event);if(t&&t.length)for(let e of t)i.push(e.evImpl+":"+e.evExposed)}return i}static getChangeEventNameImplemented(e){return Ng2Utils.getChangeEventNameExposed(e)+Ng2Utils.changeEventImplementSuffix}static getChangeEventNameExposed(e){return e+"Change"}static getWjEventNameImplemented(e){return e+Ng2Utils.wjEventImplementSuffix}static getWjEventName(e){if(e){const t=Ng2Utils.wjEventImplementSuffix;let i=e.length-t.length;if(i>0&&e.substr(i)===t)return e.substr(0,i)}return null}static getBaseType(e){let t;return e&&(t=Object.getPrototypeOf(e.prototype))&&t.constructor}static getAnnotations(e){return Reflect.getMetadata("annotations",e)}static getAnnotation(e,t){if(t&&e)for(let i of e)if(i instanceof t)return i;return null}static getTypeAnnotation(e,t,i){for(let r=e;r;r=i?null:Ng2Utils.getBaseType(r)){let e=Ng2Utils.getAnnotation(Ng2Utils.getAnnotations(r),t);if(e)return e}return null}static equals(e,t){return e!=e&&t!=t||wijmo.DateTime.equals(e,t)||e===t}static _copy(e,t,i,r,n){if(e&&t)for(let s in t)if(r||"_"!==s[0]){let r=t[s];if(!n||n(s,r)){let t=e[s];wijmo.isArray(r)?e[s]=(!wijmo.isArray(t)||i?[]:t).concat(r):void 0!==r&&(e[s]=r)}}}}Ng2Utils.changeEventImplementSuffix="PC";Ng2Utils.wjEventImplementSuffix="Ng";exports.Ng2Utils=Ng2Utils;class WjValueAccessor{constructor(e){this._writeQnt=0;this._isSubscribed=!1;this._dirUpdateQnt=0;this._onChange=e=>{};this._onTouched=()=>{};this._directive=e;this._behavior=WjDirectiveBehavior.getBehavior(e)}writeValue(e){this._modelValue=e;++this._writeQnt;if(this._directive.isInitialized){this._ensureInitEhUnsubscribed();this._updateDirective()}else if(!this._dirInitEh){let e=this._directive.initialized;this._dirInitEh=e.subscribe(()=>{this._updateDirective();this._ensureInitEhUnsubscribed()})}}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){let t=this._directive;t instanceof wijmo.Control&&(t.isDisabled=e)}_updateDirective(){if(!this._isFirstChange()||null!=this._modelValue){this._ensureNgModelProp();if(this._directive&&this._ngModelProp){let e=this._modelValue;""===e&&(e=null);this._dirUpdateQnt++;try{this._directive[this._ngModelProp]=e}finally{this._dirUpdateQnt--}}this._ensureSubscribed()}}_ensureSubscribed(){if(this._isSubscribed)return;let e=this._directive;if(e){this._ensureNgModelProp();let t=this._ngModelProp=e[WjDirectiveBehavior.wjModelPropAttr];if(t){let i=this._behavior.getPropChangeEvent(t);i&&e[i].addHandler(this._dirValChgEh,this)}e instanceof wijmo.Control&&e.lostFocus.addHandler(this._dirLostFocusEh,this);this._isSubscribed=!0}}_ensureNgModelProp(){!this._ngModelProp&&this._directive&&(this._ngModelProp=this._directive[WjDirectiveBehavior.wjModelPropAttr])}_ensureInitEhUnsubscribed(){if(this._dirInitEh){this._dirInitEh.unsubscribe();this._dirInitEh=null}}_isFirstChange(){return this._writeQnt<2}_dirValChgEh(e,t){if(this._onChange&&this._directive&&this._ngModelProp){let e=this._directive[this._ngModelProp],t=this._modelValue;""===t&&(t=null);if(!(this._dirUpdateQnt>0&&_isNullOrEmpty(t)&&_isNullOrEmpty(e)||Ng2Utils.equals(t,e))||wijmo.isArray(e)){this._modelValue=e;this._onChange(e)}}}_dirLostFocusEh(e,t){this._onTouched&&this._onTouched()}}exports.WjValueAccessor=WjValueAccessor;function WjValueAccessorFactory(e){return new WjValueAccessor(e)}exports.WjValueAccessorFactory=WjValueAccessorFactory;function _isNullOrEmpty(e){return null==e||""===e}
/*!
*
* Wijmo Library 5.20241.9
* Wijmo Library 5.20241.19
* https://developer.mescius.com/wijmo

@@ -15,5 +15,5 @@ *

import{EventEmitter,NgZone}from"@angular/core";import*as wijmo from"@grapecity/wijmo";import * as ɵngcc0 from '@angular/core';
export class WjOptions{}WjOptions.asyncBindings=!0;export class WjComponentResolvedMetadata{constructor(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}resolveChangeEventMap(e){let t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(!i||!i.length)return;let n=i.map(e=>e.split(":")).map(e=>({implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}));this.allImplEvents=n.map(e=>e.implName);let s=n.filter(e=>e.implName&&e.exposeName);for(let e of s){if(Ng2Utils.getWjEventName(e.implName)){let i={eventImpl:e.implName,event:e.exposeName},n=r[e.exposeName];n&&n.length&&(i.props=n.map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}));t.push(i)}}for(let e in r)if(e.indexOf(".")>-1){let i={eventImpl:null,event:e,props:r[e].map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})};t.push(i)}}}export class WjDirectiveBehavior{constructor(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=e=>e();this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();let n=this.nz=i.get(NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;let s=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==s.siblingId&&(s.siblingId=++WjDirectiveBehavior.siblingDirId+"");let o=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];o?this.resolvedTypeData=o:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=o=this.resolvedTypeData=new WjComponentResolvedMetadata(s);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,s.siblingId);this.subscribeToEvents(!1)}static getHostElement(e,t){WjDirectiveBehavior.ngZone=t.get(NgZone);return e.nativeElement}static attach(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)}static getZone(e){const t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone}ngOnInit(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)}ngAfterViewInit(){this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout(()=>{this.isDestroyed||this.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)})}ngOnDestroy(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){let i=this.parentBehavior.directive,r=this._getParentProp();if(!this.parentBehavior.isDestroyed&&i&&r&&e){let n=i[r];if(wijmo.isArray(n)&&n){var t=n.indexOf(e);t>=0&&n.splice(t,1)}}}if(e instanceof wijmo.Control&&e.hostElement){let t=this.elementRef.nativeElement,i=t&&t.parentNode,r=i?Array.prototype.indexOf.call(i.childNodes,t):-1;e.dispose();if(r>-1&&Array.prototype.indexOf.call(i.childNodes,t)<0){t.textContent="";r<i.childNodes.length&&i.replaceChild(t,i.childNodes[r])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}}static instantiateTemplate(e,t,i,r=!1,n={}){var s,o=t.createEmbeddedView(i,n,t.length),a=o.rootNodes;if(r&&1===a.length)s=a[0];else{s=document.createElement("div");for(let e of a)s.appendChild(e)}e&&e.appendChild(s);return{viewRef:o,rootElement:s}}getPropChangeEvent(e){let t=this.typeData.changeEvents;if(t)for(let i in t)if(t[i].indexOf(e)>-1)return i;return null}_createEvents(){let e=this.resolvedTypeData.allImplEvents;for(let t of e)this.directive[t]=new EventEmitter(!1)}_overrideDirectiveMethods(){const e=this.directive;if(e instanceof wijmo.Control){const t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run(()=>{t(e)})}.bind(e)}}subscribeToEvents(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(let i of t)e!==i.event.indexOf(".")<0&&this.addHandlers(i);if(e)for(let e of t)this.triggerPropChangeEvents(e,!0)}addHandlers(e){let t=this.directive;WjDirectiveBehavior.evaluatePath(t,e.event).addHandler((i,r)=>{this.nzRun(()=>{this.isInitialized&&this.triggerPropChangeEvents(e);e.eventImpl&&this._triggerEvent(t[e.eventImpl],r,e.props&&e.props.length>0)})})}triggerPropChangeEvents(e,t=!0){let i=this.directive;if(e.props&&e.props.length)for(let r of e.props)this._triggerEvent(i[r.evImpl],i[r.prop],t)}_setupAsChild(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}}_isAsyncBinding(){let e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e}_isChild(){return this._isParentInitializer()||this._isParentReferencer()}_isParentInitializer(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]}_isParentReferencer(){return!!this.typeData.parentRefProperty}_getParentProp(){return this.directive[WjDirectiveBehavior.parPropAttr]}_getParentReferenceProperty(){return this.typeData.parentRefProperty}_useParentObj(){return!1}_parentInCtor(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()}_initParent(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();let r=e[t];if(wijmo.isArray(r)){let e=this._isHostElement(),t=e?this._getSiblingIndex():-1;(t<0||t>=r.length)&&(t=r.length);r.splice(t,0,i);if(e){const e=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(e,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}}_getSiblingIndex(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,s=0;s<i.length;s++){var o=i[s];if(1==o.nodeType&&o.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(o===e)return r}}return-1}_siblingInserted(e){for(let t of e)if("childList"===t.type&&t.addedNodes.length>0){if(Array.from(t.addedNodes).some(e=>e===this.elementRef.nativeElement)){const e=this._getSiblingIndex(),t=this.parentBehavior.directive[this._getParentProp()],i=this.directive,r=t.indexOf(i);if(e>=0&&r>=0&&e!==r){t.splice(r,1);const n=Math.min(e,t.length);t.splice(n,0,i)}}}}_isHostElement(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE}_triggerEvent(e,t,i){if(i&&this._isAsyncBinding()){let i={event:e,args:t};this._pendingEvents.push(i);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout(()=>{this._triggerPendingEvents(!1)},0))}else e.emit(t)}_triggerPendingEvents(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(this.isDestroyed)return;let t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(let e of t)e.event.emit(e.args);e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}flushPendingEvents(){this._triggerPendingEvents(!0)}static evaluatePath(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)}static getBehavior(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null}}
export class WjOptions{}WjOptions.asyncBindings=!0;export class WjComponentResolvedMetadata{constructor(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}resolveChangeEventMap(e){let t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(!i||!i.length)return;let n=i.map(e=>e.split(":")).map(e=>({implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}));this.allImplEvents=n.map(e=>e.implName);let s=n.filter(e=>e.implName&&e.exposeName);for(let e of s){if(Ng2Utils.getWjEventName(e.implName)){let i={eventImpl:e.implName,event:e.exposeName},n=r[e.exposeName];n&&n.length&&(i.props=n.map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}));t.push(i)}}for(let e in r)if(e.indexOf(".")>-1){let i={eventImpl:null,event:e,props:r[e].map(e=>{return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})};t.push(i)}}}export class WjDirectiveBehavior{constructor(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=e=>e();this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();let n=this.nz=i.get(NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;let s=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==s.siblingId&&(s.siblingId=++WjDirectiveBehavior.siblingDirId+"");let o=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];o?this.resolvedTypeData=o:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=o=this.resolvedTypeData=new WjComponentResolvedMetadata(s);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,s.siblingId);this.subscribeToEvents(!1);this.directive instanceof wijmo.Control&&(this.directive.workingAs="Angular2")}static getHostElement(e,t){WjDirectiveBehavior.ngZone=t.get(NgZone);return e.nativeElement}static attach(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)}static getZone(e){const t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone}ngOnInit(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)}ngAfterViewInit(){this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout(()=>{this.isDestroyed||this.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)})}ngOnDestroy(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){let i=this.parentBehavior.directive,r=this._getParentProp();if(!this.parentBehavior.isDestroyed&&i&&r&&e){let n=i[r];if(wijmo.isArray(n)&&n){var t=n.indexOf(e);t>=0&&n.splice(t,1)}}}if(e instanceof wijmo.Control&&e.hostElement){let t=this.elementRef.nativeElement,i=t&&t.parentNode,r=i?Array.prototype.indexOf.call(i.childNodes,t):-1;e.dispose();if(r>-1&&Array.prototype.indexOf.call(i.childNodes,t)<0){t.textContent="";r<i.childNodes.length&&i.replaceChild(t,i.childNodes[r])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}}static instantiateTemplate(e,t,i,r=!1,n={}){var s,o=t.createEmbeddedView(i,n,t.length),a=o.rootNodes;if(r&&1===a.length)s=a[0];else{s=document.createElement("div");for(let e of a)s.appendChild(e)}e&&e.appendChild(s);return{viewRef:o,rootElement:s}}getPropChangeEvent(e){let t=this.typeData.changeEvents;if(t)for(let i in t)if(t[i].indexOf(e)>-1)return i;return null}_createEvents(){let e=this.resolvedTypeData.allImplEvents;for(let t of e)this.directive[t]=new EventEmitter(!1)}_overrideDirectiveMethods(){const e=this.directive;if(e instanceof wijmo.Control){const t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run(()=>{t(e)})}.bind(e)}}subscribeToEvents(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(let i of t)e!==i.event.indexOf(".")<0&&this.addHandlers(i);if(e)for(let e of t)this.triggerPropChangeEvents(e,!0)}addHandlers(e){let t=this.directive;WjDirectiveBehavior.evaluatePath(t,e.event).addHandler((i,r)=>{this.nzRun(()=>{this.isInitialized&&this.triggerPropChangeEvents(e);e.eventImpl&&this._triggerEvent(t[e.eventImpl],r,e.props&&e.props.length>0)})})}triggerPropChangeEvents(e,t=!0){let i=this.directive;if(e.props&&e.props.length)for(let r of e.props)this._triggerEvent(i[r.evImpl],i[r.prop],t)}_setupAsChild(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}}_isAsyncBinding(){let e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e}_isChild(){return this._isParentInitializer()||this._isParentReferencer()}_isParentInitializer(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]}_isParentReferencer(){return!!this.typeData.parentRefProperty}_getParentProp(){return this.directive[WjDirectiveBehavior.parPropAttr]}_getParentReferenceProperty(){return this.typeData.parentRefProperty}_useParentObj(){return!1}_parentInCtor(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()}_initParent(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();let r=e[t];if(wijmo.isArray(r)){let e=this._isHostElement(),t=e?this._getSiblingIndex():-1;(t<0||t>=r.length)&&(t=r.length);r.splice(t,0,i);if(e){const e=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(e,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}}_getSiblingIndex(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,s=0;s<i.length;s++){var o=i[s];if(1==o.nodeType&&o.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(o===e)return r}}return-1}_siblingInserted(e){for(let t of e)if("childList"===t.type&&t.addedNodes.length>0){if(Array.from(t.addedNodes).some(e=>e===this.elementRef.nativeElement)){const e=this._getSiblingIndex(),t=this.parentBehavior.directive[this._getParentProp()],i=this.directive,r=t.indexOf(i);if(e>=0&&r>=0&&e!==r){t.splice(r,1);const n=Math.min(e,t.length);t.splice(n,0,i)}}}}_isHostElement(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE}_triggerEvent(e,t,i){if(i&&this._isAsyncBinding()){let i={event:e,args:t};this._pendingEvents.push(i);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout(()=>{this._triggerPendingEvents(!1)},0))}else e.emit(t)}_triggerPendingEvents(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(this.isDestroyed)return;let t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(let e of t)e.event.emit(e.args);e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}flushPendingEvents(){this._triggerPendingEvents(!0)}static evaluatePath(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)}static getBehavior(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null}}
WjDirectiveBehavior.ɵfac = function WjDirectiveBehavior_Factory(t) { ɵngcc0.ɵɵinvalidFactory(); };
WjDirectiveBehavior.ɵdir = /*@__PURE__*/ ɵngcc0.ɵɵdefineDirective({ type: WjDirectiveBehavior });WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");
export class Ng2Utils{static initEvents(e,t){var i=[];for(let e of t){let t=e.props;e.event&&e.eventImpl&&i.push(e.eventImpl+":"+e.event);if(t&&t.length)for(let e of t)i.push(e.evImpl+":"+e.evExposed)}return i}static getChangeEventNameImplemented(e){return Ng2Utils.getChangeEventNameExposed(e)+Ng2Utils.changeEventImplementSuffix}static getChangeEventNameExposed(e){return e+"Change"}static getWjEventNameImplemented(e){return e+Ng2Utils.wjEventImplementSuffix}static getWjEventName(e){if(e){const t=Ng2Utils.wjEventImplementSuffix;let i=e.length-t.length;if(i>0&&e.substr(i)===t)return e.substr(0,i)}return null}static getBaseType(e){let t;return e&&(t=Object.getPrototypeOf(e.prototype))&&t.constructor}static getAnnotations(e){return Reflect.getMetadata("annotations",e)}static getAnnotation(e,t){if(t&&e)for(let i of e)if(i instanceof t)return i;return null}static getTypeAnnotation(e,t,i){for(let r=e;r;r=i?null:Ng2Utils.getBaseType(r)){let e=Ng2Utils.getAnnotation(Ng2Utils.getAnnotations(r),t);if(e)return e}return null}static equals(e,t){return e!=e&&t!=t||wijmo.DateTime.equals(e,t)||e===t}static _copy(e,t,i,r,n){if(e&&t)for(let s in t)if(r||"_"!==s[0]){let r=t[s];if(!n||n(s,r)){let t=e[s];wijmo.isArray(r)?e[s]=(!wijmo.isArray(t)||i?[]:t).concat(r):void 0!==r&&(e[s]=r)}}}}Ng2Utils.changeEventImplementSuffix="PC";Ng2Utils.wjEventImplementSuffix="Ng";export class WjValueAccessor{constructor(e){this._writeQnt=0;this._isSubscribed=!1;this._dirUpdateQnt=0;this._onChange=e=>{};this._onTouched=()=>{};this._directive=e;this._behavior=WjDirectiveBehavior.getBehavior(e)}writeValue(e){this._modelValue=e;++this._writeQnt;if(this._directive.isInitialized){this._ensureInitEhUnsubscribed();this._updateDirective()}else if(!this._dirInitEh){let e=this._directive.initialized;this._dirInitEh=e.subscribe(()=>{this._updateDirective();this._ensureInitEhUnsubscribed()})}}registerOnChange(e){this._onChange=e}registerOnTouched(e){this._onTouched=e}setDisabledState(e){let t=this._directive;t instanceof wijmo.Control&&(t.isDisabled=e)}_updateDirective(){if(!this._isFirstChange()||null!=this._modelValue){this._ensureNgModelProp();if(this._directive&&this._ngModelProp){let e=this._modelValue;""===e&&(e=null);this._dirUpdateQnt++;try{this._directive[this._ngModelProp]=e}finally{this._dirUpdateQnt--}}this._ensureSubscribed()}}_ensureSubscribed(){if(this._isSubscribed)return;let e=this._directive;if(e){this._ensureNgModelProp();let t=this._ngModelProp=e[WjDirectiveBehavior.wjModelPropAttr];if(t){let i=this._behavior.getPropChangeEvent(t);i&&e[i].addHandler(this._dirValChgEh,this)}e instanceof wijmo.Control&&e.lostFocus.addHandler(this._dirLostFocusEh,this);this._isSubscribed=!0}}_ensureNgModelProp(){!this._ngModelProp&&this._directive&&(this._ngModelProp=this._directive[WjDirectiveBehavior.wjModelPropAttr])}_ensureInitEhUnsubscribed(){if(this._dirInitEh){this._dirInitEh.unsubscribe();this._dirInitEh=null}}_isFirstChange(){return this._writeQnt<2}_dirValChgEh(e,t){if(this._onChange&&this._directive&&this._ngModelProp){let e=this._directive[this._ngModelProp],t=this._modelValue;""===t&&(t=null);if(!(this._dirUpdateQnt>0&&_isNullOrEmpty(t)&&_isNullOrEmpty(e)||Ng2Utils.equals(t,e))||wijmo.isArray(e)){this._modelValue=e;this._onChange(e)}}}_dirLostFocusEh(e,t){this._onTouched&&this._onTouched()}}export function WjValueAccessorFactory(e){return new WjValueAccessor(e)}function _isNullOrEmpty(e){return null==e||""===e}
/*!
*
* Wijmo Library 5.20241.9
* Wijmo Library 5.20241.19
* https://developer.mescius.com/wijmo

@@ -15,5 +15,5 @@ *

import{EventEmitter,NgZone}from"@angular/core";import*as wijmo from"@grapecity/wijmo";import * as ɵngcc0 from '@angular/core';
var WjOptions=function(){function WjOptions(){}WjOptions.asyncBindings=!0;return WjOptions}();export{WjOptions};var WjComponentResolvedMetadata=function(){function WjComponentResolvedMetadata(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}WjComponentResolvedMetadata.prototype.resolveChangeEventMap=function(e){var t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(i&&i.length){var n=i.map((function(e){return e.split(":")})).map((function(e){return{implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}}));this.allImplEvents=n.map((function(e){return e.implName}));for(var o=0,s=n.filter((function(e){return e.implName&&e.exposeName}));o<s.length;o++){var a=s[o];if(Ng2Utils.getWjEventName(a.implName)){var v={eventImpl:a.implName,event:a.exposeName},h=r[a.exposeName];h&&h.length&&(v.props=h.map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})));t.push(v)}}for(var c in r)if(c.indexOf(".")>-1){v={eventImpl:null,event:c,props:r[c].map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}))};t.push(v)}}};return WjComponentResolvedMetadata}();export{WjComponentResolvedMetadata};var WjDirectiveBehavior=function(){function WjDirectiveBehavior(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=function(e){return e()};this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();var n=this.nz=i.get(NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;var o=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==o.siblingId&&(o.siblingId=++WjDirectiveBehavior.siblingDirId+"");var s=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];s?this.resolvedTypeData=s:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=s=this.resolvedTypeData=new WjComponentResolvedMetadata(o);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,o.siblingId);this.subscribeToEvents(!1)}WjDirectiveBehavior.getHostElement=function(e,t){WjDirectiveBehavior.ngZone=t.get(NgZone);return e.nativeElement};WjDirectiveBehavior.attach=function(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)};WjDirectiveBehavior.getZone=function(e){var t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone};WjDirectiveBehavior.prototype.ngOnInit=function(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)};WjDirectiveBehavior.prototype.ngAfterViewInit=function(){var e=this;this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout((function(){e.isDestroyed||e.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)}))};WjDirectiveBehavior.prototype.ngOnDestroy=function(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){var t=this.parentBehavior.directive,i=this._getParentProp();if(!this.parentBehavior.isDestroyed&&t&&i&&e){var r=t[i];if(wijmo.isArray(r)&&r){var n=r.indexOf(e);n>=0&&r.splice(n,1)}}}if(e instanceof wijmo.Control&&e.hostElement){var o=this.elementRef.nativeElement,s=o&&o.parentNode,a=s?Array.prototype.indexOf.call(s.childNodes,o):-1;e.dispose();if(a>-1&&Array.prototype.indexOf.call(s.childNodes,o)<0){o.textContent="";a<s.childNodes.length&&s.replaceChild(o,s.childNodes[a])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}};WjDirectiveBehavior.instantiateTemplate=function(e,t,i,r,n){void 0===r&&(r=!1);void 0===n&&(n={});var o,s=t.createEmbeddedView(i,n,t.length),a=s.rootNodes;if(r&&1===a.length)o=a[0];else{o=document.createElement("div");for(var v=0,h=a;v<h.length;v++){var c=h[v];o.appendChild(c)}}e&&e.appendChild(o);return{viewRef:s,rootElement:o}};WjDirectiveBehavior.prototype.getPropChangeEvent=function(e){var t=this.typeData.changeEvents;if(t)for(var i in t)if(t[i].indexOf(e)>-1)return i;return null};WjDirectiveBehavior.prototype._createEvents=function(){for(var e=0,t=this.resolvedTypeData.allImplEvents;e<t.length;e++){var i=t[e];this.directive[i]=new EventEmitter(!1)}};WjDirectiveBehavior.prototype._overrideDirectiveMethods=function(){var e=this.directive;if(e instanceof wijmo.Control){var t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run((function(){t(e)}))}.bind(e)}};WjDirectiveBehavior.prototype.subscribeToEvents=function(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(var i=0,r=t;i<r.length;i++){e!==(s=r[i]).event.indexOf(".")<0&&this.addHandlers(s)}if(e)for(var n=0,o=t;n<o.length;n++){var s=o[n];this.triggerPropChangeEvents(s,!0)}};WjDirectiveBehavior.prototype.addHandlers=function(e){var t=this,i=this.directive;WjDirectiveBehavior.evaluatePath(i,e.event).addHandler((function(r,n){t.nzRun((function(){t.isInitialized&&t.triggerPropChangeEvents(e);e.eventImpl&&t._triggerEvent(i[e.eventImpl],n,e.props&&e.props.length>0)}))}))};WjDirectiveBehavior.prototype.triggerPropChangeEvents=function(e,t){void 0===t&&(t=!0);var i=this.directive;if(e.props&&e.props.length)for(var r=0,n=e.props;r<n.length;r++){var o=n[r];this._triggerEvent(i[o.evImpl],i[o.prop],t)}};WjDirectiveBehavior.prototype._setupAsChild=function(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}};WjDirectiveBehavior.prototype._isAsyncBinding=function(){var e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e};WjDirectiveBehavior.prototype._isChild=function(){return this._isParentInitializer()||this._isParentReferencer()};WjDirectiveBehavior.prototype._isParentInitializer=function(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._isParentReferencer=function(){return!!this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._getParentProp=function(){return this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._getParentReferenceProperty=function(){return this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._useParentObj=function(){return!1};WjDirectiveBehavior.prototype._parentInCtor=function(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()};WjDirectiveBehavior.prototype._initParent=function(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();var r=e[t];if(wijmo.isArray(r)){var n=this._isHostElement(),o=n?this._getSiblingIndex():-1;(o<0||o>=r.length)&&(o=r.length);r.splice(o,0,i);if(n){var s=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(s,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}};WjDirectiveBehavior.prototype._getSiblingIndex=function(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,o=0;o<i.length;o++){var s=i[o];if(1==s.nodeType&&s.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(s===e)return r}}return-1};WjDirectiveBehavior.prototype._siblingInserted=function(e){for(var t=this,i=0,r=e;i<r.length;i++){var n=r[i];if("childList"===n.type&&n.addedNodes.length>0){if(Array.from(n.addedNodes).some((function(e){return e===t.elementRef.nativeElement}))){var o=this._getSiblingIndex(),s=this.parentBehavior.directive[this._getParentProp()],a=this.directive,v=s.indexOf(a);if(o>=0&&v>=0&&o!==v){s.splice(v,1);var h=Math.min(o,s.length);s.splice(h,0,a)}}}}};WjDirectiveBehavior.prototype._isHostElement=function(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE};WjDirectiveBehavior.prototype._triggerEvent=function(e,t,i){var r=this;if(i&&this._isAsyncBinding()){var n={event:e,args:t};this._pendingEvents.push(n);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout((function(){r._triggerPendingEvents(!1)}),0))}else e.emit(t)};WjDirectiveBehavior.prototype._triggerPendingEvents=function(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(!this.isDestroyed){var t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(var i=0,r=t;i<r.length;i++){var n=r[i];n.event.emit(n.args)}e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}};WjDirectiveBehavior.prototype.flushPendingEvents=function(){this._triggerPendingEvents(!0)};WjDirectiveBehavior.evaluatePath=function(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)};WjDirectiveBehavior.getBehavior=function(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null};WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");
var WjOptions=function(){function WjOptions(){}WjOptions.asyncBindings=!0;return WjOptions}();export{WjOptions};var WjComponentResolvedMetadata=function(){function WjComponentResolvedMetadata(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}WjComponentResolvedMetadata.prototype.resolveChangeEventMap=function(e){var t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(i&&i.length){var n=i.map((function(e){return e.split(":")})).map((function(e){return{implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}}));this.allImplEvents=n.map((function(e){return e.implName}));for(var o=0,s=n.filter((function(e){return e.implName&&e.exposeName}));o<s.length;o++){var a=s[o];if(Ng2Utils.getWjEventName(a.implName)){var v={eventImpl:a.implName,event:a.exposeName},h=r[a.exposeName];h&&h.length&&(v.props=h.map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})));t.push(v)}}for(var c in r)if(c.indexOf(".")>-1){v={eventImpl:null,event:c,props:r[c].map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}))};t.push(v)}}};return WjComponentResolvedMetadata}();export{WjComponentResolvedMetadata};var WjDirectiveBehavior=function(){function WjDirectiveBehavior(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=function(e){return e()};this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();var n=this.nz=i.get(NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;var o=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==o.siblingId&&(o.siblingId=++WjDirectiveBehavior.siblingDirId+"");var s=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];s?this.resolvedTypeData=s:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=s=this.resolvedTypeData=new WjComponentResolvedMetadata(o);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,o.siblingId);this.subscribeToEvents(!1);this.directive instanceof wijmo.Control&&(this.directive.workingAs="Angular2")}WjDirectiveBehavior.getHostElement=function(e,t){WjDirectiveBehavior.ngZone=t.get(NgZone);return e.nativeElement};WjDirectiveBehavior.attach=function(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)};WjDirectiveBehavior.getZone=function(e){var t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone};WjDirectiveBehavior.prototype.ngOnInit=function(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)};WjDirectiveBehavior.prototype.ngAfterViewInit=function(){var e=this;this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout((function(){e.isDestroyed||e.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)}))};WjDirectiveBehavior.prototype.ngOnDestroy=function(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){var t=this.parentBehavior.directive,i=this._getParentProp();if(!this.parentBehavior.isDestroyed&&t&&i&&e){var r=t[i];if(wijmo.isArray(r)&&r){var n=r.indexOf(e);n>=0&&r.splice(n,1)}}}if(e instanceof wijmo.Control&&e.hostElement){var o=this.elementRef.nativeElement,s=o&&o.parentNode,a=s?Array.prototype.indexOf.call(s.childNodes,o):-1;e.dispose();if(a>-1&&Array.prototype.indexOf.call(s.childNodes,o)<0){o.textContent="";a<s.childNodes.length&&s.replaceChild(o,s.childNodes[a])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}};WjDirectiveBehavior.instantiateTemplate=function(e,t,i,r,n){void 0===r&&(r=!1);void 0===n&&(n={});var o,s=t.createEmbeddedView(i,n,t.length),a=s.rootNodes;if(r&&1===a.length)o=a[0];else{o=document.createElement("div");for(var v=0,h=a;v<h.length;v++){var c=h[v];o.appendChild(c)}}e&&e.appendChild(o);return{viewRef:s,rootElement:o}};WjDirectiveBehavior.prototype.getPropChangeEvent=function(e){var t=this.typeData.changeEvents;if(t)for(var i in t)if(t[i].indexOf(e)>-1)return i;return null};WjDirectiveBehavior.prototype._createEvents=function(){for(var e=0,t=this.resolvedTypeData.allImplEvents;e<t.length;e++){var i=t[e];this.directive[i]=new EventEmitter(!1)}};WjDirectiveBehavior.prototype._overrideDirectiveMethods=function(){var e=this.directive;if(e instanceof wijmo.Control){var t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run((function(){t(e)}))}.bind(e)}};WjDirectiveBehavior.prototype.subscribeToEvents=function(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(var i=0,r=t;i<r.length;i++){e!==(s=r[i]).event.indexOf(".")<0&&this.addHandlers(s)}if(e)for(var n=0,o=t;n<o.length;n++){var s=o[n];this.triggerPropChangeEvents(s,!0)}};WjDirectiveBehavior.prototype.addHandlers=function(e){var t=this,i=this.directive;WjDirectiveBehavior.evaluatePath(i,e.event).addHandler((function(r,n){t.nzRun((function(){t.isInitialized&&t.triggerPropChangeEvents(e);e.eventImpl&&t._triggerEvent(i[e.eventImpl],n,e.props&&e.props.length>0)}))}))};WjDirectiveBehavior.prototype.triggerPropChangeEvents=function(e,t){void 0===t&&(t=!0);var i=this.directive;if(e.props&&e.props.length)for(var r=0,n=e.props;r<n.length;r++){var o=n[r];this._triggerEvent(i[o.evImpl],i[o.prop],t)}};WjDirectiveBehavior.prototype._setupAsChild=function(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}};WjDirectiveBehavior.prototype._isAsyncBinding=function(){var e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e};WjDirectiveBehavior.prototype._isChild=function(){return this._isParentInitializer()||this._isParentReferencer()};WjDirectiveBehavior.prototype._isParentInitializer=function(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._isParentReferencer=function(){return!!this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._getParentProp=function(){return this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._getParentReferenceProperty=function(){return this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._useParentObj=function(){return!1};WjDirectiveBehavior.prototype._parentInCtor=function(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()};WjDirectiveBehavior.prototype._initParent=function(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();var r=e[t];if(wijmo.isArray(r)){var n=this._isHostElement(),o=n?this._getSiblingIndex():-1;(o<0||o>=r.length)&&(o=r.length);r.splice(o,0,i);if(n){var s=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(s,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}};WjDirectiveBehavior.prototype._getSiblingIndex=function(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,o=0;o<i.length;o++){var s=i[o];if(1==s.nodeType&&s.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(s===e)return r}}return-1};WjDirectiveBehavior.prototype._siblingInserted=function(e){for(var t=this,i=0,r=e;i<r.length;i++){var n=r[i];if("childList"===n.type&&n.addedNodes.length>0){if(Array.from(n.addedNodes).some((function(e){return e===t.elementRef.nativeElement}))){var o=this._getSiblingIndex(),s=this.parentBehavior.directive[this._getParentProp()],a=this.directive,v=s.indexOf(a);if(o>=0&&v>=0&&o!==v){s.splice(v,1);var h=Math.min(o,s.length);s.splice(h,0,a)}}}}};WjDirectiveBehavior.prototype._isHostElement=function(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE};WjDirectiveBehavior.prototype._triggerEvent=function(e,t,i){var r=this;if(i&&this._isAsyncBinding()){var n={event:e,args:t};this._pendingEvents.push(n);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout((function(){r._triggerPendingEvents(!1)}),0))}else e.emit(t)};WjDirectiveBehavior.prototype._triggerPendingEvents=function(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(!this.isDestroyed){var t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(var i=0,r=t;i<r.length;i++){var n=r[i];n.event.emit(n.args)}e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}};WjDirectiveBehavior.prototype.flushPendingEvents=function(){this._triggerPendingEvents(!0)};WjDirectiveBehavior.evaluatePath=function(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)};WjDirectiveBehavior.getBehavior=function(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null};WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");
WjDirectiveBehavior.ɵfac = function WjDirectiveBehavior_Factory(t) { ɵngcc0.ɵɵinvalidFactory(); };
WjDirectiveBehavior.ɵdir = /*@__PURE__*/ ɵngcc0.ɵɵdefineDirective({ type: WjDirectiveBehavior });
return WjDirectiveBehavior}();export{WjDirectiveBehavior};var Ng2Utils=function(){function Ng2Utils(){}Ng2Utils.initEvents=function(e,t){for(var i=[],r=0,n=t;r<n.length;r++){var o=n[r],s=o.props;o.event&&o.eventImpl&&i.push(o.eventImpl+":"+o.event);if(s&&s.length)for(var a=0,v=s;a<v.length;a++){var h=v[a];i.push(h.evImpl+":"+h.evExposed)}}return i};Ng2Utils.getChangeEventNameImplemented=function(e){return Ng2Utils.getChangeEventNameExposed(e)+Ng2Utils.changeEventImplementSuffix};Ng2Utils.getChangeEventNameExposed=function(e){return e+"Change"};Ng2Utils.getWjEventNameImplemented=function(e){return e+Ng2Utils.wjEventImplementSuffix};Ng2Utils.getWjEventName=function(e){if(e){var t=Ng2Utils.wjEventImplementSuffix,i=e.length-t.length;if(i>0&&e.substr(i)===t)return e.substr(0,i)}return null};Ng2Utils.getBaseType=function(e){var t;return e&&(t=Object.getPrototypeOf(e.prototype))&&t.constructor};Ng2Utils.getAnnotations=function(e){return Reflect.getMetadata("annotations",e)};Ng2Utils.getAnnotation=function(e,t){if(t&&e)for(var i=0,r=e;i<r.length;i++){var n=r[i];if(n instanceof t)return n}return null};Ng2Utils.getTypeAnnotation=function(e,t,i){for(var r=e;r;r=i?null:Ng2Utils.getBaseType(r)){var n=Ng2Utils.getAnnotation(Ng2Utils.getAnnotations(r),t);if(n)return n}return null};Ng2Utils.equals=function(e,t){return e!=e&&t!=t||wijmo.DateTime.equals(e,t)||e===t};Ng2Utils._copy=function(e,t,i,r,n){if(e&&t)for(var o in t)if(r||"_"!==o[0]){var s=t[o];if(!n||n(o,s)){var a=e[o];wijmo.isArray(s)?e[o]=(!wijmo.isArray(a)||i?[]:a).concat(s):void 0!==s&&(e[o]=s)}}};Ng2Utils.changeEventImplementSuffix="PC";Ng2Utils.wjEventImplementSuffix="Ng";return Ng2Utils}();export{Ng2Utils};var WjValueAccessor=function(){function WjValueAccessor(e){this._writeQnt=0;this._isSubscribed=!1;this._dirUpdateQnt=0;this._onChange=function(e){};this._onTouched=function(){};this._directive=e;this._behavior=WjDirectiveBehavior.getBehavior(e)}WjValueAccessor.prototype.writeValue=function(e){var t=this;this._modelValue=e;++this._writeQnt;if(this._directive.isInitialized){this._ensureInitEhUnsubscribed();this._updateDirective()}else if(!this._dirInitEh){var i=this._directive.initialized;this._dirInitEh=i.subscribe((function(){t._updateDirective();t._ensureInitEhUnsubscribed()}))}};WjValueAccessor.prototype.registerOnChange=function(e){this._onChange=e};WjValueAccessor.prototype.registerOnTouched=function(e){this._onTouched=e};WjValueAccessor.prototype.setDisabledState=function(e){var t=this._directive;t instanceof wijmo.Control&&(t.isDisabled=e)};WjValueAccessor.prototype._updateDirective=function(){if(!this._isFirstChange()||null!=this._modelValue){this._ensureNgModelProp();if(this._directive&&this._ngModelProp){var e=this._modelValue;""===e&&(e=null);this._dirUpdateQnt++;try{this._directive[this._ngModelProp]=e}finally{this._dirUpdateQnt--}}this._ensureSubscribed()}};WjValueAccessor.prototype._ensureSubscribed=function(){if(!this._isSubscribed){var e=this._directive;if(e){this._ensureNgModelProp();var t=this._ngModelProp=e[WjDirectiveBehavior.wjModelPropAttr];if(t){var i=this._behavior.getPropChangeEvent(t);i&&e[i].addHandler(this._dirValChgEh,this)}e instanceof wijmo.Control&&e.lostFocus.addHandler(this._dirLostFocusEh,this);this._isSubscribed=!0}}};WjValueAccessor.prototype._ensureNgModelProp=function(){!this._ngModelProp&&this._directive&&(this._ngModelProp=this._directive[WjDirectiveBehavior.wjModelPropAttr])};WjValueAccessor.prototype._ensureInitEhUnsubscribed=function(){if(this._dirInitEh){this._dirInitEh.unsubscribe();this._dirInitEh=null}};WjValueAccessor.prototype._isFirstChange=function(){return this._writeQnt<2};WjValueAccessor.prototype._dirValChgEh=function(e,t){if(this._onChange&&this._directive&&this._ngModelProp){var i=this._directive[this._ngModelProp],r=this._modelValue;""===r&&(r=null);if(!(this._dirUpdateQnt>0&&_isNullOrEmpty(r)&&_isNullOrEmpty(i)||Ng2Utils.equals(r,i))||wijmo.isArray(i)){this._modelValue=i;this._onChange(i)}}};WjValueAccessor.prototype._dirLostFocusEh=function(e,t){this._onTouched&&this._onTouched()};return WjValueAccessor}();export{WjValueAccessor};export function WjValueAccessorFactory(e){return new WjValueAccessor(e)}function _isNullOrEmpty(e){return null==e||""===e}
/*!
*
* Wijmo Library 5.20241.9
* Wijmo Library 5.20241.19
* https://developer.mescius.com/wijmo

@@ -5,0 +5,0 @@ *

/*!
*
* Wijmo Library 5.20241.9
* Wijmo Library 5.20241.19
* https://developer.mescius.com/wijmo

@@ -15,5 +15,5 @@ *

"use strict";var ɵngcc0 = require('@angular/core');
var __importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)Object.hasOwnProperty.call(e,i)&&(t[i]=e[i]);t.default=e;return t};Object.defineProperty(exports,"__esModule",{value:!0});var core_1=require("@angular/core"),wijmo=__importStar(require("@grapecity/wijmo")),WjOptions=function(){function WjOptions(){}WjOptions.asyncBindings=!0;return WjOptions}();exports.WjOptions=WjOptions;var WjComponentResolvedMetadata=function(){function WjComponentResolvedMetadata(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}WjComponentResolvedMetadata.prototype.resolveChangeEventMap=function(e){var t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(i&&i.length){var n=i.map((function(e){return e.split(":")})).map((function(e){return{implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}}));this.allImplEvents=n.map((function(e){return e.implName}));for(var o=0,s=n.filter((function(e){return e.implName&&e.exposeName}));o<s.length;o++){var a=s[o];if(Ng2Utils.getWjEventName(a.implName)){var v={eventImpl:a.implName,event:a.exposeName},h=r[a.exposeName];h&&h.length&&(v.props=h.map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})));t.push(v)}}for(var c in r)if(c.indexOf(".")>-1){v={eventImpl:null,event:c,props:r[c].map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}))};t.push(v)}}};return WjComponentResolvedMetadata}();exports.WjComponentResolvedMetadata=WjComponentResolvedMetadata;var WjDirectiveBehavior=function(){function WjDirectiveBehavior(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=function(e){return e()};this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();var n=this.nz=i.get(core_1.NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;var o=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==o.siblingId&&(o.siblingId=++WjDirectiveBehavior.siblingDirId+"");var s=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];s?this.resolvedTypeData=s:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=s=this.resolvedTypeData=new WjComponentResolvedMetadata(o);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,o.siblingId);this.subscribeToEvents(!1)}WjDirectiveBehavior.getHostElement=function(e,t){WjDirectiveBehavior.ngZone=t.get(core_1.NgZone);return e.nativeElement};WjDirectiveBehavior.attach=function(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)};WjDirectiveBehavior.getZone=function(e){var t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone};WjDirectiveBehavior.prototype.ngOnInit=function(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)};WjDirectiveBehavior.prototype.ngAfterViewInit=function(){var e=this;this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout((function(){e.isDestroyed||e.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)}))};WjDirectiveBehavior.prototype.ngOnDestroy=function(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){var t=this.parentBehavior.directive,i=this._getParentProp();if(!this.parentBehavior.isDestroyed&&t&&i&&e){var r=t[i];if(wijmo.isArray(r)&&r){var n=r.indexOf(e);n>=0&&r.splice(n,1)}}}if(e instanceof wijmo.Control&&e.hostElement){var o=this.elementRef.nativeElement,s=o&&o.parentNode,a=s?Array.prototype.indexOf.call(s.childNodes,o):-1;e.dispose();if(a>-1&&Array.prototype.indexOf.call(s.childNodes,o)<0){o.textContent="";a<s.childNodes.length&&s.replaceChild(o,s.childNodes[a])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}};WjDirectiveBehavior.instantiateTemplate=function(e,t,i,r,n){void 0===r&&(r=!1);void 0===n&&(n={});var o,s=t.createEmbeddedView(i,n,t.length),a=s.rootNodes;if(r&&1===a.length)o=a[0];else{o=document.createElement("div");for(var v=0,h=a;v<h.length;v++){var c=h[v];o.appendChild(c)}}e&&e.appendChild(o);return{viewRef:s,rootElement:o}};WjDirectiveBehavior.prototype.getPropChangeEvent=function(e){var t=this.typeData.changeEvents;if(t)for(var i in t)if(t[i].indexOf(e)>-1)return i;return null};WjDirectiveBehavior.prototype._createEvents=function(){for(var e=0,t=this.resolvedTypeData.allImplEvents;e<t.length;e++){var i=t[e];this.directive[i]=new core_1.EventEmitter(!1)}};WjDirectiveBehavior.prototype._overrideDirectiveMethods=function(){var e=this.directive;if(e instanceof wijmo.Control){var t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){core_1.NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run((function(){t(e)}))}.bind(e)}};WjDirectiveBehavior.prototype.subscribeToEvents=function(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(var i=0,r=t;i<r.length;i++){e!==(s=r[i]).event.indexOf(".")<0&&this.addHandlers(s)}if(e)for(var n=0,o=t;n<o.length;n++){var s=o[n];this.triggerPropChangeEvents(s,!0)}};WjDirectiveBehavior.prototype.addHandlers=function(e){var t=this,i=this.directive;WjDirectiveBehavior.evaluatePath(i,e.event).addHandler((function(r,n){t.nzRun((function(){t.isInitialized&&t.triggerPropChangeEvents(e);e.eventImpl&&t._triggerEvent(i[e.eventImpl],n,e.props&&e.props.length>0)}))}))};WjDirectiveBehavior.prototype.triggerPropChangeEvents=function(e,t){void 0===t&&(t=!0);var i=this.directive;if(e.props&&e.props.length)for(var r=0,n=e.props;r<n.length;r++){var o=n[r];this._triggerEvent(i[o.evImpl],i[o.prop],t)}};WjDirectiveBehavior.prototype._setupAsChild=function(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}};WjDirectiveBehavior.prototype._isAsyncBinding=function(){var e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e};WjDirectiveBehavior.prototype._isChild=function(){return this._isParentInitializer()||this._isParentReferencer()};WjDirectiveBehavior.prototype._isParentInitializer=function(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._isParentReferencer=function(){return!!this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._getParentProp=function(){return this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._getParentReferenceProperty=function(){return this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._useParentObj=function(){return!1};WjDirectiveBehavior.prototype._parentInCtor=function(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()};WjDirectiveBehavior.prototype._initParent=function(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();var r=e[t];if(wijmo.isArray(r)){var n=this._isHostElement(),o=n?this._getSiblingIndex():-1;(o<0||o>=r.length)&&(o=r.length);r.splice(o,0,i);if(n){var s=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(s,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}};WjDirectiveBehavior.prototype._getSiblingIndex=function(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,o=0;o<i.length;o++){var s=i[o];if(1==s.nodeType&&s.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(s===e)return r}}return-1};WjDirectiveBehavior.prototype._siblingInserted=function(e){for(var t=this,i=0,r=e;i<r.length;i++){var n=r[i];if("childList"===n.type&&n.addedNodes.length>0){if(Array.from(n.addedNodes).some((function(e){return e===t.elementRef.nativeElement}))){var o=this._getSiblingIndex(),s=this.parentBehavior.directive[this._getParentProp()],a=this.directive,v=s.indexOf(a);if(o>=0&&v>=0&&o!==v){s.splice(v,1);var h=Math.min(o,s.length);s.splice(h,0,a)}}}}};WjDirectiveBehavior.prototype._isHostElement=function(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE};WjDirectiveBehavior.prototype._triggerEvent=function(e,t,i){var r=this;if(i&&this._isAsyncBinding()){var n={event:e,args:t};this._pendingEvents.push(n);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout((function(){r._triggerPendingEvents(!1)}),0))}else e.emit(t)};WjDirectiveBehavior.prototype._triggerPendingEvents=function(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(!this.isDestroyed){var t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(var i=0,r=t;i<r.length;i++){var n=r[i];n.event.emit(n.args)}e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}};WjDirectiveBehavior.prototype.flushPendingEvents=function(){this._triggerPendingEvents(!0)};WjDirectiveBehavior.evaluatePath=function(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)};WjDirectiveBehavior.getBehavior=function(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null};WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");
var __importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)Object.hasOwnProperty.call(e,i)&&(t[i]=e[i]);t.default=e;return t};Object.defineProperty(exports,"__esModule",{value:!0});var core_1=require("@angular/core"),wijmo=__importStar(require("@grapecity/wijmo")),WjOptions=function(){function WjOptions(){}WjOptions.asyncBindings=!0;return WjOptions}();exports.WjOptions=WjOptions;var WjComponentResolvedMetadata=function(){function WjComponentResolvedMetadata(e){this.changeEventMap=[];this.allImplEvents=[];this.resolveChangeEventMap(e)}WjComponentResolvedMetadata.prototype.resolveChangeEventMap=function(e){var t=this.changeEventMap,i=e.outputs,r=e.changeEvents||{};t.splice(0,t.length);this.allImplEvents=[];if(i&&i.length){var n=i.map((function(e){return e.split(":")})).map((function(e){return{implName:e[0].trim(),exposeName:e[1]&&e[1].trim()}}));this.allImplEvents=n.map((function(e){return e.implName}));for(var o=0,s=n.filter((function(e){return e.implName&&e.exposeName}));o<s.length;o++){var a=s[o];if(Ng2Utils.getWjEventName(a.implName)){var v={eventImpl:a.implName,event:a.exposeName},h=r[a.exposeName];h&&h.length&&(v.props=h.map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}})));t.push(v)}}for(var c in r)if(c.indexOf(".")>-1){v={eventImpl:null,event:c,props:r[c].map((function(e){return{prop:e,evExposed:Ng2Utils.getChangeEventNameExposed(e),evImpl:Ng2Utils.getChangeEventNameImplemented(e)}}))};t.push(v)}}};return WjComponentResolvedMetadata}();exports.WjComponentResolvedMetadata=WjComponentResolvedMetadata;var WjDirectiveBehavior=function(){function WjDirectiveBehavior(e,t,i,r){this._pendingEvents=[];this.isInitialized=!1;this.isDestroyed=!1;this.nzRun=function(e){return e()};this.directive=e;this.elementRef=t;this.injector=i;this._overrideDirectiveMethods();var n=this.nz=i.get(core_1.NgZone);n&&(this.nzRun=n.run.bind(n));this.injectedParent=r;var o=this.typeData=e.constructor[WjDirectiveBehavior.directiveTypeDataProp];null==o.siblingId&&(o.siblingId=++WjDirectiveBehavior.siblingDirId+"");var s=e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp];s?this.resolvedTypeData=s:e.constructor[WjDirectiveBehavior.directiveResolvedTypeDataProp]=s=this.resolvedTypeData=new WjComponentResolvedMetadata(o);e[WjDirectiveBehavior.BehaviourRefProp]=this;i[WjDirectiveBehavior.BehaviourRefProp]=this;e[WjDirectiveBehavior.isInitializedPropAttr]=!1;this._createEvents();this._setupAsChild();this._isHostElement()&&t.nativeElement.setAttribute(WjDirectiveBehavior.siblingDirIdAttr,o.siblingId);this.subscribeToEvents(!1);this.directive instanceof wijmo.Control&&(this.directive.workingAs="Angular2")}WjDirectiveBehavior.getHostElement=function(e,t){WjDirectiveBehavior.ngZone=t.get(core_1.NgZone);return e.nativeElement};WjDirectiveBehavior.attach=function(e,t,i,r){return new WjDirectiveBehavior(e,t,i,r)};WjDirectiveBehavior.getZone=function(e){var t=WjDirectiveBehavior.getBehavior(e);return t&&t.nz||WjDirectiveBehavior.ngZone};WjDirectiveBehavior.prototype.ngOnInit=function(){this.isInitialized=!0;this._initParent();this.subscribeToEvents(!0)};WjDirectiveBehavior.prototype.ngAfterViewInit=function(){var e=this;this.directive[WjDirectiveBehavior.isInitializedPropAttr]=!0;setTimeout((function(){e.isDestroyed||e.directive[WjDirectiveBehavior.initializedEventAttr].emit(void 0)}))};WjDirectiveBehavior.prototype.ngOnDestroy=function(){if(!this.isDestroyed){this.isDestroyed=!0;var e=this.directive;this._siblingInsertedMO&&this._siblingInsertedMO.disconnect();if(this._isChild()&&this.parentBehavior){var t=this.parentBehavior.directive,i=this._getParentProp();if(!this.parentBehavior.isDestroyed&&t&&i&&e){var r=t[i];if(wijmo.isArray(r)&&r){var n=r.indexOf(e);n>=0&&r.splice(n,1)}}}if(e instanceof wijmo.Control&&e.hostElement){var o=this.elementRef.nativeElement,s=o&&o.parentNode,a=s?Array.prototype.indexOf.call(s.childNodes,o):-1;e.dispose();if(a>-1&&Array.prototype.indexOf.call(s.childNodes,o)<0){o.textContent="";a<s.childNodes.length&&s.replaceChild(o,s.childNodes[a])}}this.injector[WjDirectiveBehavior.BehaviourRefProp]=null}};WjDirectiveBehavior.instantiateTemplate=function(e,t,i,r,n){void 0===r&&(r=!1);void 0===n&&(n={});var o,s=t.createEmbeddedView(i,n,t.length),a=s.rootNodes;if(r&&1===a.length)o=a[0];else{o=document.createElement("div");for(var v=0,h=a;v<h.length;v++){var c=h[v];o.appendChild(c)}}e&&e.appendChild(o);return{viewRef:s,rootElement:o}};WjDirectiveBehavior.prototype.getPropChangeEvent=function(e){var t=this.typeData.changeEvents;if(t)for(var i in t)if(t[i].indexOf(e)>-1)return i;return null};WjDirectiveBehavior.prototype._createEvents=function(){for(var e=0,t=this.resolvedTypeData.allImplEvents;e<t.length;e++){var i=t[e];this.directive[i]=new core_1.EventEmitter(!1)}};WjDirectiveBehavior.prototype._overrideDirectiveMethods=function(){var e=this.directive;if(e instanceof wijmo.Control){var t=e._resizeObserverCallback.bind(e);e._resizeObserverCallback=function(e){core_1.NgZone.isInAngularZone()?t(e):WjDirectiveBehavior.getZone(this).run((function(){t(e)}))}.bind(e)}};WjDirectiveBehavior.prototype.subscribeToEvents=function(e){var t=this.resolvedTypeData.changeEventMap;e=!!e;for(var i=0,r=t;i<r.length;i++){e!==(s=r[i]).event.indexOf(".")<0&&this.addHandlers(s)}if(e)for(var n=0,o=t;n<o.length;n++){var s=o[n];this.triggerPropChangeEvents(s,!0)}};WjDirectiveBehavior.prototype.addHandlers=function(e){var t=this,i=this.directive;WjDirectiveBehavior.evaluatePath(i,e.event).addHandler((function(r,n){t.nzRun((function(){t.isInitialized&&t.triggerPropChangeEvents(e);e.eventImpl&&t._triggerEvent(i[e.eventImpl],n,e.props&&e.props.length>0)}))}))};WjDirectiveBehavior.prototype.triggerPropChangeEvents=function(e,t){void 0===t&&(t=!0);var i=this.directive;if(e.props&&e.props.length)for(var r=0,n=e.props;r<n.length;r++){var o=n[r];this._triggerEvent(i[o.evImpl],i[o.prop],t)}};WjDirectiveBehavior.prototype._setupAsChild=function(){if(this._isChild()){this._isHostElement()&&(this.elementRef.nativeElement.style.display="none");this.parentBehavior=WjDirectiveBehavior.getBehavior(this.injectedParent)}};WjDirectiveBehavior.prototype._isAsyncBinding=function(){var e=this.directive[WjDirectiveBehavior.asyncBindingUpdatePropAttr];return null==e?WjOptions.asyncBindings:e};WjDirectiveBehavior.prototype._isChild=function(){return this._isParentInitializer()||this._isParentReferencer()};WjDirectiveBehavior.prototype._isParentInitializer=function(){return null!=this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._isParentReferencer=function(){return!!this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._getParentProp=function(){return this.directive[WjDirectiveBehavior.parPropAttr]};WjDirectiveBehavior.prototype._getParentReferenceProperty=function(){return this.typeData.parentRefProperty};WjDirectiveBehavior.prototype._useParentObj=function(){return!1};WjDirectiveBehavior.prototype._parentInCtor=function(){return this._isParentReferencer()&&""==this._getParentReferenceProperty()};WjDirectiveBehavior.prototype._initParent=function(){if(this.parentBehavior&&!this._useParentObj()){var e=this.parentBehavior.directive,t=this._getParentProp(),i=this.directive;if(this._isParentInitializer()){this._getParentProp();var r=e[t];if(wijmo.isArray(r)){var n=this._isHostElement(),o=n?this._getSiblingIndex():-1;(o<0||o>=r.length)&&(o=r.length);r.splice(o,0,i);if(n){var s=this.elementRef.nativeElement;this._siblingInsertedMO=new MutationObserver(this._siblingInserted.bind(this));this._siblingInsertedMO.observe(s,{childList:!0})}}else e[t]=i}this._isParentReferencer()&&!this._parentInCtor()&&(i[this._getParentReferenceProperty()]=e)}};WjDirectiveBehavior.prototype._getSiblingIndex=function(){var e=this.elementRef.nativeElement,t=e.parentElement;if(!t)return-1;for(var i=t.childNodes,r=-1,n=this.typeData.siblingId,o=0;o<i.length;o++){var s=i[o];if(1==s.nodeType&&s.getAttribute(WjDirectiveBehavior.siblingDirIdAttr)==n){++r;if(s===e)return r}}return-1};WjDirectiveBehavior.prototype._siblingInserted=function(e){for(var t=this,i=0,r=e;i<r.length;i++){var n=r[i];if("childList"===n.type&&n.addedNodes.length>0){if(Array.from(n.addedNodes).some((function(e){return e===t.elementRef.nativeElement}))){var o=this._getSiblingIndex(),s=this.parentBehavior.directive[this._getParentProp()],a=this.directive,v=s.indexOf(a);if(o>=0&&v>=0&&o!==v){s.splice(v,1);var h=Math.min(o,s.length);s.splice(h,0,a)}}}}};WjDirectiveBehavior.prototype._isHostElement=function(){return this.elementRef.nativeElement.nodeType===Node.ELEMENT_NODE};WjDirectiveBehavior.prototype._triggerEvent=function(e,t,i){var r=this;if(i&&this._isAsyncBinding()){var n={event:e,args:t};this._pendingEvents.push(n);null==this._pendingEventsTO&&(this._pendingEventsTO=setTimeout((function(){r._triggerPendingEvents(!1)}),0))}else e.emit(t)};WjDirectiveBehavior.prototype._triggerPendingEvents=function(e){if(null!=this._pendingEventsTO){clearTimeout(this._pendingEventsTO);this._pendingEventsTO=null}if(!this.isDestroyed){var t=[].concat(this._pendingEvents);this._pendingEvents.splice(0,this._pendingEvents.length);for(var i=0,r=t;i<r.length;i++){var n=r[i];n.event.emit(n.args)}e&&this._pendingEvents.length&&this._triggerPendingEvents(!0)}};WjDirectiveBehavior.prototype.flushPendingEvents=function(){this._triggerPendingEvents(!0)};WjDirectiveBehavior.evaluatePath=function(e,t){this._pathBinding.path=t;return this._pathBinding.getValue(e)};WjDirectiveBehavior.getBehavior=function(e){return e?e[WjDirectiveBehavior.BehaviourRefProp]:null};WjDirectiveBehavior.directiveTypeDataProp="meta";WjDirectiveBehavior.directiveResolvedTypeDataProp="_wjResolvedMeta";WjDirectiveBehavior.BehaviourRefProp="_wjBehaviour";WjDirectiveBehavior.parPropAttr="wjProperty";WjDirectiveBehavior.wjModelPropAttr="wjModelProperty";WjDirectiveBehavior.initializedEventAttr="initialized";WjDirectiveBehavior.isInitializedPropAttr="isInitialized";WjDirectiveBehavior.siblingDirIdAttr="wj-directive-id";WjDirectiveBehavior.asyncBindingUpdatePropAttr="asyncBindings";WjDirectiveBehavior.siblingDirId=0;WjDirectiveBehavior.wijmoComponentProviderId="WjComponent";WjDirectiveBehavior.outsideZoneEvents={pointermove:!0,pointerover:!0,mousemove:!0,wheel:!0,touchmove:!0,pointerenter:!0,pointerleave:!0,pointerout:!0,mouseover:!0,mouseenter:!0,mouseleave:!0,mouseout:!0};WjDirectiveBehavior._pathBinding=new wijmo.Binding("");
WjDirectiveBehavior.ɵfac = function WjDirectiveBehavior_Factory(t) { ɵngcc0.ɵɵinvalidFactory(); };
WjDirectiveBehavior.ɵdir = /*@__PURE__*/ ɵngcc0.ɵɵdefineDirective({ type: WjDirectiveBehavior });
return WjDirectiveBehavior}();exports.WjDirectiveBehavior=WjDirectiveBehavior;var Ng2Utils=function(){function Ng2Utils(){}Ng2Utils.initEvents=function(e,t){for(var i=[],r=0,n=t;r<n.length;r++){var o=n[r],s=o.props;o.event&&o.eventImpl&&i.push(o.eventImpl+":"+o.event);if(s&&s.length)for(var a=0,v=s;a<v.length;a++){var h=v[a];i.push(h.evImpl+":"+h.evExposed)}}return i};Ng2Utils.getChangeEventNameImplemented=function(e){return Ng2Utils.getChangeEventNameExposed(e)+Ng2Utils.changeEventImplementSuffix};Ng2Utils.getChangeEventNameExposed=function(e){return e+"Change"};Ng2Utils.getWjEventNameImplemented=function(e){return e+Ng2Utils.wjEventImplementSuffix};Ng2Utils.getWjEventName=function(e){if(e){var t=Ng2Utils.wjEventImplementSuffix,i=e.length-t.length;if(i>0&&e.substr(i)===t)return e.substr(0,i)}return null};Ng2Utils.getBaseType=function(e){var t;return e&&(t=Object.getPrototypeOf(e.prototype))&&t.constructor};Ng2Utils.getAnnotations=function(e){return Reflect.getMetadata("annotations",e)};Ng2Utils.getAnnotation=function(e,t){if(t&&e)for(var i=0,r=e;i<r.length;i++){var n=r[i];if(n instanceof t)return n}return null};Ng2Utils.getTypeAnnotation=function(e,t,i){for(var r=e;r;r=i?null:Ng2Utils.getBaseType(r)){var n=Ng2Utils.getAnnotation(Ng2Utils.getAnnotations(r),t);if(n)return n}return null};Ng2Utils.equals=function(e,t){return e!=e&&t!=t||wijmo.DateTime.equals(e,t)||e===t};Ng2Utils._copy=function(e,t,i,r,n){if(e&&t)for(var o in t)if(r||"_"!==o[0]){var s=t[o];if(!n||n(o,s)){var a=e[o];wijmo.isArray(s)?e[o]=(!wijmo.isArray(a)||i?[]:a).concat(s):void 0!==s&&(e[o]=s)}}};Ng2Utils.changeEventImplementSuffix="PC";Ng2Utils.wjEventImplementSuffix="Ng";return Ng2Utils}();exports.Ng2Utils=Ng2Utils;var WjValueAccessor=function(){function WjValueAccessor(e){this._writeQnt=0;this._isSubscribed=!1;this._dirUpdateQnt=0;this._onChange=function(e){};this._onTouched=function(){};this._directive=e;this._behavior=WjDirectiveBehavior.getBehavior(e)}WjValueAccessor.prototype.writeValue=function(e){var t=this;this._modelValue=e;++this._writeQnt;if(this._directive.isInitialized){this._ensureInitEhUnsubscribed();this._updateDirective()}else if(!this._dirInitEh){var i=this._directive.initialized;this._dirInitEh=i.subscribe((function(){t._updateDirective();t._ensureInitEhUnsubscribed()}))}};WjValueAccessor.prototype.registerOnChange=function(e){this._onChange=e};WjValueAccessor.prototype.registerOnTouched=function(e){this._onTouched=e};WjValueAccessor.prototype.setDisabledState=function(e){var t=this._directive;t instanceof wijmo.Control&&(t.isDisabled=e)};WjValueAccessor.prototype._updateDirective=function(){if(!this._isFirstChange()||null!=this._modelValue){this._ensureNgModelProp();if(this._directive&&this._ngModelProp){var e=this._modelValue;""===e&&(e=null);this._dirUpdateQnt++;try{this._directive[this._ngModelProp]=e}finally{this._dirUpdateQnt--}}this._ensureSubscribed()}};WjValueAccessor.prototype._ensureSubscribed=function(){if(!this._isSubscribed){var e=this._directive;if(e){this._ensureNgModelProp();var t=this._ngModelProp=e[WjDirectiveBehavior.wjModelPropAttr];if(t){var i=this._behavior.getPropChangeEvent(t);i&&e[i].addHandler(this._dirValChgEh,this)}e instanceof wijmo.Control&&e.lostFocus.addHandler(this._dirLostFocusEh,this);this._isSubscribed=!0}}};WjValueAccessor.prototype._ensureNgModelProp=function(){!this._ngModelProp&&this._directive&&(this._ngModelProp=this._directive[WjDirectiveBehavior.wjModelPropAttr])};WjValueAccessor.prototype._ensureInitEhUnsubscribed=function(){if(this._dirInitEh){this._dirInitEh.unsubscribe();this._dirInitEh=null}};WjValueAccessor.prototype._isFirstChange=function(){return this._writeQnt<2};WjValueAccessor.prototype._dirValChgEh=function(e,t){if(this._onChange&&this._directive&&this._ngModelProp){var i=this._directive[this._ngModelProp],r=this._modelValue;""===r&&(r=null);if(!(this._dirUpdateQnt>0&&_isNullOrEmpty(r)&&_isNullOrEmpty(i)||Ng2Utils.equals(r,i))||wijmo.isArray(i)){this._modelValue=i;this._onChange(i)}}};WjValueAccessor.prototype._dirLostFocusEh=function(e,t){this._onTouched&&this._onTouched()};return WjValueAccessor}();exports.WjValueAccessor=WjValueAccessor;function WjValueAccessorFactory(e){return new WjValueAccessor(e)}exports.WjValueAccessorFactory=WjValueAccessorFactory;function _isNullOrEmpty(e){return null==e||""===e}
{
"name": "@grapecity/wijmo.angular2.directivebase",
"version": "5.20241.9",
"version": "5.20241.19",
"description": "UI library for pure JS, Angular, React, Vue and more...",

@@ -10,3 +10,3 @@ "author": "MESCIUS inc",

"dependencies": {
"@grapecity/wijmo": "5.20241.9"
"@grapecity/wijmo": "5.20241.19"
},

@@ -13,0 +13,0 @@ "homepage": "https://developer.mescius.com/wijmo",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc