@tethys/cdk 19.0.4 → 19.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -79,10 +79,10 @@ class HostRenderer extends AbstractElementRenderer {
79
79
  get element() {
80
80
  return this.elementRef.nativeElement;
81
81
  }
82
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: HostRenderer, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
83
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: HostRenderer }); }
82
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: HostRenderer, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
83
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: HostRenderer }); }
84
84
  }
85
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: HostRenderer, decorators: [{
85
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: HostRenderer, decorators: [{
86
86
  type: Injectable
87
87
  }] });
88
88
  function useHostRenderer() {
@@ -122,12 +122,15 @@ class ThyStealthView {
122
122
  this.templateRef = inject((TemplateRef));
123
123
  this.stealthViewBehavior = useStealthViewRenderer(this.templateRef);
124
124
  }
125
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyStealthView, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
126
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.4", type: ThyStealthView, isStandalone: true, selector: "ng-template[thyStealthView]", exportAs: ["thyStealthView"], ngImport: i0 }); }
125
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyStealthView, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
126
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.6", type: ThyStealthView, isStandalone: true, selector: "ng-template[thyStealthView]", exportAs: ["thyStealthView"], ngImport: i0 }); }
127
127
  }
128
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyStealthView, decorators: [{
128
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyStealthView, decorators: [{
129
129
  type: Directive,
130
- args: [{ selector: 'ng-template[thyStealthView]', standalone: true, exportAs: 'thyStealthView' }]
130
+ args: [{
131
+ selector: 'ng-template[thyStealthView]',
132
+ exportAs: 'thyStealthView'
133
+ }]
131
134
  }], ctorParameters: () => [] });
132
135
 
133
136
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"tethys-cdk-dom.mjs","sources":["../../../cdk/dom/abstract-element-renderer.ts","../../../cdk/dom/element-renderer.ts","../../../cdk/dom/host-renderer.ts","../../../cdk/dom/stealth-view-renderer.ts","../../../cdk/dom/stealth-view-directive.ts","../../../cdk/dom/tethys-cdk-dom.ts"],"sourcesContent":["import { Renderer2, inject, RendererStyleFlags2 } from '@angular/core';\n\nexport abstract class AbstractElementRenderer {\n private renderer = inject(Renderer2);\n\n protected abstract element: Element;\n\n private classNames: string[] = [];\n\n private get safeElement() {\n if (!this.element) {\n throw new Error(`Element is null, should call setElement method for ElementRenderer before update dom.`);\n }\n return this.element;\n }\n\n updateClass(classNames: string[]) {\n if (this.classNames) {\n this.classNames.forEach(className => {\n if (classNames.indexOf(className) < 0) {\n this.removeClass(className);\n }\n });\n }\n const newClasses: string[] = [];\n classNames.forEach(className => {\n if (className) {\n newClasses.push(className);\n if (this.classNames.indexOf(className) < 0) {\n this.addClass(className);\n }\n }\n });\n this.classNames = newClasses;\n return this;\n }\n\n updateClassByMap(classMap: Record<string, boolean>) {\n const newClasses = [];\n for (const key in classMap) {\n if (classMap.hasOwnProperty(key) && classMap[key]) {\n newClasses.push(key);\n }\n }\n this.updateClass(newClasses);\n }\n\n addClass(className: string) {\n this.renderer.addClass(this.safeElement, className);\n return this;\n }\n\n removeClass(className: string) {\n this.renderer.removeClass(this.safeElement, className);\n return this;\n }\n\n setStyle(style: string, value: any, flags?: RendererStyleFlags2) {\n this.renderer.setStyle(this.safeElement, style, value, flags);\n return this;\n }\n}\n","import { AbstractElementRenderer } from './abstract-element-renderer';\n\nexport class ElementRenderer extends AbstractElementRenderer {\n protected element: Element;\n\n setElement(element: Element) {\n this.element = element;\n }\n\n constructor(element: Element) {\n super();\n this.element = element;\n }\n}\n\nexport function useElementRenderer(element?: Element): ElementRenderer {\n return new ElementRenderer(element);\n}\n","import { Injectable, inject, ElementRef } from '@angular/core';\nimport { AbstractElementRenderer } from './abstract-element-renderer';\n\n/**\n * @private\n */\n@Injectable()\nexport class HostRenderer extends AbstractElementRenderer {\n private elementRef = inject(ElementRef);\n\n protected get element() {\n return this.elementRef.nativeElement;\n }\n}\n\nexport function useHostRenderer() {\n return new HostRenderer();\n}\n","import { ApplicationRef, DestroyRef, Directive, EmbeddedViewRef, inject, Injector, isSignal, Signal, TemplateRef } from '@angular/core';\n\nexport interface StealthViewRenderer {\n rootNodes: Node[];\n}\n\nexport function useStealthViewRenderer(templateRefInput: Signal<TemplateRef<any>> | TemplateRef<any>): StealthViewRenderer {\n const injector = inject(Injector);\n const applicationRef = inject(ApplicationRef);\n const destroyRef = inject(DestroyRef);\n\n let embeddedViewRef: EmbeddedViewRef<any>;\n\n destroyRef.onDestroy(() => {\n if (embeddedViewRef) {\n embeddedViewRef.destroy();\n applicationRef.detachView(embeddedViewRef);\n }\n });\n\n const result = {\n get rootNodes() {\n if (!embeddedViewRef) {\n const templateRef = isSignal(templateRefInput) ? templateRefInput() : templateRefInput;\n embeddedViewRef = templateRef.createEmbeddedView({}, injector);\n applicationRef.attachView(embeddedViewRef);\n }\n return embeddedViewRef.rootNodes;\n }\n };\n return result;\n}\n","import { Directive, inject, TemplateRef } from '@angular/core';\nimport { useStealthViewRenderer } from './stealth-view-renderer';\n\n@Directive({ selector: 'ng-template[thyStealthView]', standalone: true, exportAs: 'thyStealthView' })\n// eslint-disable-next-line @angular-eslint/directive-class-suffix\nexport class ThyStealthView {\n private templateRef = inject(TemplateRef<any>);\n\n private stealthViewBehavior = useStealthViewRenderer(this.templateRef);\n\n get rootNodes() {\n return this.stealthViewBehavior.rootNodes;\n }\n\n constructor() {}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAEsB,uBAAuB,CAAA;AAA7C,IAAA,WAAA,GAAA;AACY,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,SAAS,CAAC;QAI5B,IAAU,CAAA,UAAA,GAAa,EAAE;;AAEjC,IAAA,IAAY,WAAW,GAAA;AACnB,QAAA,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;AACf,YAAA,MAAM,IAAI,KAAK,CAAC,CAAA,qFAAA,CAAuF,CAAC;;QAE5G,OAAO,IAAI,CAAC,OAAO;;AAGvB,IAAA,WAAW,CAAC,UAAoB,EAAA;AAC5B,QAAA,IAAI,IAAI,CAAC,UAAU,EAAE;AACjB,YAAA,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,SAAS,IAAG;gBAChC,IAAI,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE;AACnC,oBAAA,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC;;AAEnC,aAAC,CAAC;;QAEN,MAAM,UAAU,GAAa,EAAE;AAC/B,QAAA,UAAU,CAAC,OAAO,CAAC,SAAS,IAAG;YAC3B,IAAI,SAAS,EAAE;AACX,gBAAA,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC;gBAC1B,IAAI,IAAI,CAAC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BAAA,cAAc,CAAC,UAAU,CAAC,eAAe,CAAC;;YAE9C,OAAO,eAAe,CAAC,SAAS;;KAEvC;AACD,IAAA,OAAO,MAAM;AACjB;;AC3BA;MACa,cAAc,CAAA;AAKvB,IAAA,IAAI,SAAS,GAAA;AACT,QAAA,OAAO,IAAI,CAAC,mBAAmB,CAAC,SAAS;;AAG7C,IAAA,WAAA,GAAA;AARQ,QAAA,IAAA,CAAA,WAAW,GAAG,MAAM,EAAC,WAAgB,EAAC;AAEtC,QAAA,IAAA,CAAA,mBAAmB,GAAG,sBAAsB,CAAC,IAAI,CAAC,WAAW,CAAC;;8GAH7D,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAd,cAAc,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,6BAAA,EAAA,QAAA,EAAA,CAAA,gBAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAF1B,SAAS;mBAAC,EAAE,QAAQ,EAAE,6BAA6B,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,gBAAgB,EAAE;;;ACHpG;;AAEG;;;;"}
1
+ {"version":3,"file":"tethys-cdk-dom.mjs","sources":["../../../cdk/dom/abstract-element-renderer.ts","../../../cdk/dom/element-renderer.ts","../../../cdk/dom/host-renderer.ts","../../../cdk/dom/stealth-view-renderer.ts","../../../cdk/dom/stealth-view-directive.ts","../../../cdk/dom/tethys-cdk-dom.ts"],"sourcesContent":["import { Renderer2, inject, RendererStyleFlags2 } from '@angular/core';\n\nexport abstract class AbstractElementRenderer {\n private renderer = inject(Renderer2);\n\n protected abstract element: Element;\n\n private classNames: string[] = [];\n\n private get safeElement() {\n if (!this.element) {\n throw new Error(`Element is null, should call setElement method for ElementRenderer before update dom.`);\n }\n return this.element;\n }\n\n updateClass(classNames: string[]) {\n if (this.classNames) {\n this.classNames.forEach(className => {\n if (classNames.indexOf(className) < 0) {\n this.removeClass(className);\n }\n });\n }\n const newClasses: string[] = [];\n classNames.forEach(className => {\n if (className) {\n newClasses.push(className);\n if (this.classNames.indexOf(className) < 0) {\n this.addClass(className);\n }\n }\n });\n this.classNames = newClasses;\n return this;\n }\n\n updateClassByMap(classMap: Record<string, boolean>) {\n const newClasses = [];\n for (const key in classMap) {\n if (classMap.hasOwnProperty(key) && classMap[key]) {\n newClasses.push(key);\n }\n }\n this.updateClass(newClasses);\n }\n\n addClass(className: string) {\n this.renderer.addClass(this.safeElement, className);\n return this;\n }\n\n removeClass(className: string) {\n this.renderer.removeClass(this.safeElement, className);\n return this;\n }\n\n setStyle(style: string, value: any, flags?: RendererStyleFlags2) {\n this.renderer.setStyle(this.safeElement, style, value, flags);\n return this;\n }\n}\n","import { AbstractElementRenderer } from './abstract-element-renderer';\n\nexport class ElementRenderer extends AbstractElementRenderer {\n protected element: Element;\n\n setElement(element: Element) {\n this.element = element;\n }\n\n constructor(element: Element) {\n super();\n this.element = element;\n }\n}\n\nexport function useElementRenderer(element?: Element): ElementRenderer {\n return new ElementRenderer(element);\n}\n","import { Injectable, inject, ElementRef } from '@angular/core';\nimport { AbstractElementRenderer } from './abstract-element-renderer';\n\n/**\n * @private\n */\n@Injectable()\nexport class HostRenderer extends AbstractElementRenderer {\n private elementRef = inject(ElementRef);\n\n protected get element() {\n return this.elementRef.nativeElement;\n }\n}\n\nexport function useHostRenderer() {\n return new HostRenderer();\n}\n","import { ApplicationRef, DestroyRef, Directive, EmbeddedViewRef, inject, Injector, isSignal, Signal, TemplateRef } from '@angular/core';\n\nexport interface StealthViewRenderer {\n rootNodes: Node[];\n}\n\nexport function useStealthViewRenderer(templateRefInput: Signal<TemplateRef<any>> | TemplateRef<any>): StealthViewRenderer {\n const injector = inject(Injector);\n const applicationRef = inject(ApplicationRef);\n const destroyRef = inject(DestroyRef);\n\n let embeddedViewRef: EmbeddedViewRef<any>;\n\n destroyRef.onDestroy(() => {\n if (embeddedViewRef) {\n embeddedViewRef.destroy();\n applicationRef.detachView(embeddedViewRef);\n }\n });\n\n const result = {\n get rootNodes() {\n if (!embeddedViewRef) {\n const templateRef = isSignal(templateRefInput) ? templateRefInput() : templateRefInput;\n embeddedViewRef = templateRef.createEmbeddedView({}, injector);\n applicationRef.attachView(embeddedViewRef);\n }\n return embeddedViewRef.rootNodes;\n }\n };\n return result;\n}\n","import { Directive, inject, TemplateRef } from '@angular/core';\nimport { useStealthViewRenderer } from './stealth-view-renderer';\n\n@Directive({\n selector: 'ng-template[thyStealthView]',\n exportAs: 'thyStealthView'\n})\n// eslint-disable-next-line @angular-eslint/directive-class-suffix\nexport class ThyStealthView {\n private templateRef = inject(TemplateRef<any>);\n\n private stealthViewBehavior = useStealthViewRenderer(this.templateRef);\n\n get rootNodes() {\n return this.stealthViewBehavior.rootNodes;\n }\n\n constructor() {}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;MAEsB,uBAAuB,CAAA;AAA7C,IAAA,WAAA,GAAA;AACY,QAAA,IAAA,CAAA,QAAQ,GAAG,MAAM,CAAC,SAAS,CAAC;QAI5B,IAAU,CAAA,UAAA,GAAa,EAAE;;AAEjC,IAAA,IAAY,WAAW,GAAA;AACnB,QAAA,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE;AACf,YAAA,MAAM,IAAI,KAAK,CAAC,CAAA,qFAAA,CAAuF,CAAC;;QAE5G,OAAO,IAAI,CAAC,OAAO;;AAGvB,IAAA,WAAW,CAAC,UAAoB,EAAA;AAC5B,QAAA,IAAI,IAAI,CAAC,UAAU,EAAE;AACjB,YAAA,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,SAAS,IAAG;gBAChC,IAAI,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE;AACnC,oBAAA,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC;;AAEnC,a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AAC,eAAe,EAAE;AAClB,gBAAA,MAAM,WAAW,GAAG,QAAQ,CAAC,gBAAgB,CAAC,GAAG,gBAAgB,EAAE,GAAG,gBAAgB;gBACtF,eAAe,GAAG,WAAW,CAAC,kBAAkB,CAAC,EAAE,EAAE,QAAQ,CAAC;AAC9D,gBAAA,cAAc,CAAC,UAAU,CAAC,eAAe,CAAC;;YAE9C,OAAO,eAAe,CAAC,SAAS;;KAEvC;AACD,IAAA,OAAO,MAAM;AACjB;;ACxBA;MACa,cAAc,CAAA;AAKvB,IAAA,IAAI,SAAS,GAAA;AACT,QAAA,OAAO,IAAI,CAAC,mBAAmB,CAAC,SAAS;;AAG7C,IAAA,WAAA,GAAA;AARQ,QAAA,IAAA,CAAA,WAAW,GAAG,MAAM,EAAC,WAAgB,EAAC;AAEtC,QAAA,IAAA,CAAA,mBAAmB,GAAG,sBAAsB,CAAC,IAAI,CAAC,WAAW,CAAC;;8GAH7D,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAd,cAAc,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,6BAAA,EAAA,QAAA,EAAA,CAAA,gBAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAd,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,6BAA6B;AACvC,oBAAA,QAAQ,EAAE;AACb,iBAAA;;;ACND;;AAEG;;;;"}
@@ -52,10 +52,10 @@ class ThyEventDispatcher {
52
52
  this._removeGlobalListener();
53
53
  this._event$.complete();
54
54
  }
55
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyEventDispatcher, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive }); }
56
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.4", type: ThyEventDispatcher, isStandalone: true, ngImport: i0 }); }
55
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyEventDispatcher, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive }); }
56
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.6", type: ThyEventDispatcher, isStandalone: true, ngImport: i0 }); }
57
57
  }
58
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyEventDispatcher, decorators: [{
58
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyEventDispatcher, decorators: [{
59
59
  type: Directive
60
60
  }], ctorParameters: () => [{ type: Document }, { type: i0.NgZone }, { type: undefined }] });
61
61
 
@@ -69,10 +69,10 @@ class ThyClickDispatcher extends ThyEventDispatcher {
69
69
  clicked(auditTimeInMs = DEFAULT_CLICKED_TIME) {
70
70
  return this.subscribe(auditTimeInMs);
71
71
  }
72
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyClickDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
73
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyClickDispatcher, providedIn: 'root' }); }
72
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyClickDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
73
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyClickDispatcher, providedIn: 'root' }); }
74
74
  }
75
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyClickDispatcher, decorators: [{
75
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyClickDispatcher, decorators: [{
76
76
  type: Injectable,
77
77
  args: [{
78
78
  providedIn: 'root'
@@ -96,10 +96,10 @@ class ThyKeyboardDispatcher extends ThyEventDispatcher {
96
96
  keydown(auditTimeInMs = DEFAULT_KEYDOWN_TIME) {
97
97
  return this.subscribe(auditTimeInMs);
98
98
  }
99
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyKeyboardDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
100
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyKeyboardDispatcher, providedIn: 'root' }); }
99
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyKeyboardDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
100
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyKeyboardDispatcher, providedIn: 'root' }); }
101
101
  }
102
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyKeyboardDispatcher, decorators: [{
102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyKeyboardDispatcher, decorators: [{
103
103
  type: Injectable,
104
104
  args: [{
105
105
  providedIn: 'root'
@@ -76,10 +76,10 @@ class ThyHotkeyDispatcher extends ThyEventDispatcher {
76
76
  };
77
77
  }).pipe(runInZone(this.ngZone));
78
78
  }
79
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
80
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyDispatcher, providedIn: 'root' }); }
79
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyDispatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
80
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyDispatcher, providedIn: 'root' }); }
81
81
  }
82
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyDispatcher, decorators: [{
82
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyDispatcher, decorators: [{
83
83
  type: Injectable,
84
84
  args: [{ providedIn: 'root' }]
85
85
  }], ctorParameters: () => [] });
@@ -117,15 +117,12 @@ class ThyHotkeyDirective {
117
117
  this.subscription.unsubscribe();
118
118
  }
119
119
  }
120
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
121
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.4", type: ThyHotkeyDirective, isStandalone: false, selector: "[thyHotkey]", inputs: { thyHotkey: "thyHotkey", thyHotkeyScope: "thyHotkeyScope" }, outputs: { thyHotkeyListener: "thyHotkeyListener" }, ngImport: i0 }); }
120
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
121
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.2.6", type: ThyHotkeyDirective, isStandalone: true, selector: "[thyHotkey]", inputs: { thyHotkey: "thyHotkey", thyHotkeyScope: "thyHotkeyScope" }, outputs: { thyHotkeyListener: "thyHotkeyListener" }, ngImport: i0 }); }
122
122
  }
123
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyDirective, decorators: [{
123
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyDirective, decorators: [{
124
124
  type: Directive,
125
- args: [{
126
- selector: '[thyHotkey]',
127
- standalone: false
128
- }]
125
+ args: [{ selector: '[thyHotkey]' }]
129
126
  }], propDecorators: { thyHotkey: [{
130
127
  type: Input
131
128
  }], thyHotkeyScope: [{
@@ -135,17 +132,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImpor
135
132
  }] } });
136
133
 
137
134
  class ThyHotkeyModule {
138
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
139
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyModule, declarations: [ThyHotkeyDirective], exports: [ThyHotkeyDirective] }); }
140
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyModule }); }
135
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
136
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyModule, imports: [ThyHotkeyDirective], exports: [ThyHotkeyDirective] }); }
137
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyModule }); }
141
138
  }
142
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.4", ngImport: i0, type: ThyHotkeyModule, decorators: [{
139
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: ThyHotkeyModule, decorators: [{
143
140
  type: NgModule,
144
141
  args: [{
145
- imports: [],
146
- exports: [ThyHotkeyDirective],
147
- declarations: [ThyHotkeyDirective],
148
- providers: []
142
+ imports: [ThyHotkeyDirective],
143
+ exports: [ThyHotkeyDirective]
149
144
  }]
150
145
  }] });
151
146
 
@@ -1 +1 @@
1
- {"version":3,"file":"tethys-cdk-hotkey.mjs","sources":["../../../cdk/hotkey/hotkey.ts","../../../cdk/hotkey/hotkey-dispatcher.ts","../../../cdk/hotkey/hotkey.directive.ts","../../../cdk/hotkey/module.ts","../../../cdk/hotkey/tethys-cdk-hotkey.ts"],"sourcesContent":["const modifierKeyNames: string[] = [`Control`, 'Alt', 'Meta', 'Shift'];\n\n// We don't want to show `Shift` when `event.key` is capital\nfunction showShift(event: KeyboardEvent): boolean {\n const { shiftKey, code, key } = event;\n return shiftKey && !(code.startsWith('Key') && key.toUpperCase() === key);\n}\n\nexport function hotkey(event: KeyboardEvent): string {\n const { ctrlKey, altKey, metaKey, key } = event;\n const hotkeyString: string[] = [];\n const modifiers: boolean[] = [ctrlKey, altKey, metaKey, showShift(event)];\n for (const [i, mod] of modifiers.entries()) {\n if (mod) hotkeyString.push(modifierKeyNames[i]);\n }\n\n if (!modifierKeyNames.includes(key)) {\n hotkeyString.push(key);\n }\n\n return hotkeyString.join('+');\n}\n\nexport function isHotkey(event: KeyboardEvent, key: string) {\n return key.toUpperCase() === hotkey(event).toUpperCase();\n}\n","import { coerceElement } from '@angular/cdk/coercion';\nimport { DOCUMENT } from '@angular/common';\nimport { Injectable, NgZone, ElementRef, inject } from '@angular/core';\nimport { ThyEventDispatcher } from '@tethys/cdk/event';\nimport { fromEvent, Observable, OperatorFunction, Subscriber } from 'rxjs';\nimport { filter } from 'rxjs/operators';\nimport { isFormElement, isString, isUndefinedOrNull } from '@tethys/cdk/is';\nimport { isHotkey } from './hotkey';\n\nfunction runInZone<T>(zone: NgZone): OperatorFunction<T, T> {\n return source => {\n return new Observable(observer => {\n const onNext = (value: T) => zone.run(() => observer.next(value));\n const onError = (e: any) => zone.run(() => observer.error(e));\n const onComplete = () => zone.run(() => observer.complete());\n return source.subscribe(onNext, onError, onComplete);\n });\n };\n}\n\n@Injectable({ providedIn: 'root' })\nexport class ThyHotkeyDispatcher extends ThyEventDispatcher {\n constructor() {\n const document = inject(DOCUMENT);\n const ngZone = inject(NgZone);\n\n super(document, ngZone, 'keydown');\n }\n\n private createKeydownObservable(scope: Element | Document) {\n if (scope === this.document) {\n return this.subscribe(null);\n } else {\n return fromEvent(scope, 'keydown');\n }\n }\n\n /**\n * 热键事件订阅\n */\n keydown(hotkey: string | string[], scope?: ElementRef<Element> | Element | Document): Observable<KeyboardEvent> {\n const hotkeys = isString(hotkey) ? hotkey.split(',') : hotkey;\n const scopeElement = coerceElement(isUndefinedOrNull(scope) ? this.document : scope);\n const keydown = this.createKeydownObservable(scopeElement);\n return new Observable<KeyboardEvent>(subscriber => {\n const subscription = keydown\n .pipe(filter((event: KeyboardEvent) => hotkeys.some(key => isHotkey(event, key))))\n .subscribe((event: KeyboardEvent) => {\n // 如果当前焦点的元素是表单元素并且焦点原色不是Hotkey绑定元素则忽略快捷键\n if (isFormElement(this.document.activeElement) && this.document.activeElement !== scope) {\n return;\n }\n subscriber.next(event);\n });\n return () => {\n subscription.unsubscribe();\n };\n }).pipe(runInZone(this.ngZone));\n }\n}\n","import { DOCUMENT } from '@angular/common';\nimport { Directive, ElementRef, EventEmitter, Input, OnInit, Output, OnDestroy, inject } from '@angular/core';\nimport { Subscription } from 'rxjs';\nimport { isFormElement, isString } from '@tethys/cdk/is';\nimport { ThyHotkeyDispatcher } from './hotkey-dispatcher';\n\n/**\n * @name thyHotkey\n */\n@Directive({\n selector: '[thyHotkey]',\n standalone: false\n})\nexport class ThyHotkeyDirective implements OnInit, OnDestroy {\n private document = inject(DOCUMENT);\n private hotkeyDispatcher = inject(ThyHotkeyDispatcher);\n private elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n\n /**\n * 热键对应 Code,多个热键组合支持通过数组或逗号分割的形式传入\n */\n @Input() thyHotkey: string | string[];\n\n /**\n * 配置热键触发范围,默认绑定在 document 上\n */\n @Input() thyHotkeyScope?: string | Element | ElementRef<Element>;\n\n /**\n * 热键触发后的事件\n */\n @Output() thyHotkeyListener: EventEmitter<KeyboardEvent> = new EventEmitter();\n\n private subscription: Subscription = null;\n\n ngOnInit(): void {\n const scope = isString(this.thyHotkeyScope) ? this.document.querySelector(this.thyHotkeyScope) : this.thyHotkeyScope;\n this.subscription = this.hotkeyDispatcher.keydown(this.thyHotkey, scope).subscribe(event => {\n event.preventDefault();\n event.stopPropagation();\n if (isFormElement(this.elementRef)) {\n this.elementRef.nativeElement.focus();\n } else {\n this.elementRef.nativeElement.click();\n }\n this.thyHotkeyListener.emit(event);\n });\n }\n\n ngOnDestroy(): void {\n if (this.subscription) {\n this.subscription.unsubscribe();\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { ThyHotkeyDirective } from './hotkey.directive';\n\n@NgModule({\n imports: [],\n exports: [ThyHotkeyDirective],\n declarations: [ThyHotkeyDirective],\n providers: []\n})\nexport class ThyHotkeyModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAAA,MAAM,gBAAgB,GAAa,CAAC,CAAS,OAAA,CAAA,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC;AAEtE;AACA,SAAS,SAAS,CAAC,KAAoB,EAAA;IACnC,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,GAAG,EAAE,GAAG,KAAK;AACrC,IAAA,OAAO,Q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;;;MCtBQ,eAAe,CAAA;8GAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAf,eAAe,EAAA,YAAA,EAAA,CAHT,kBAAkB,CAAA,EAAA,OAAA,EAAA,CADvB,kBAAkB,CAAA,EAAA,CAAA,CAAA;+GAInB,eAAe,EAAA,CAAA,CAAA;;2FAAf,eAAe,EAAA,UAAA,EAAA,CAAA;kBAN3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE,EAAE;oBACX,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,YAAY,EAAE,CAAC,kBAAkB,CAAC;AAClC,oBAAA,SAAS,EAAE;AACd,iBAAA;;;ACRD;;AAEG;;;;"}
1
+ {"version":3,"file":"tethys-cdk-hotkey.mjs","sources":["../../../cdk/hotkey/hotkey.ts","../../../cdk/hotkey/hotkey-dispatcher.ts","../../../cdk/hotkey/hotkey.directive.ts","../../../cdk/hotkey/module.ts","../../../cdk/hotkey/tethys-cdk-hotkey.ts"],"sourcesContent":["const modifierKeyNames: string[] = [`Control`, 'Alt', 'Meta', 'Shift'];\n\n// We don't want to show `Shift` when `event.key` is capital\nfunction showShift(event: KeyboardEvent): boolean {\n const { shiftKey, code, key } = event;\n return shiftKey && !(code.startsWith('Key') && key.toUpperCase() === key);\n}\n\nexport function hotkey(event: KeyboardEvent): string {\n const { ctrlKey, altKey, metaKey, key } = event;\n const hotkeyString: string[] = [];\n const modifiers: boolean[] = [ctrlKey, altKey, metaKey, showShift(event)];\n for (const [i, mod] of modifiers.entries()) {\n if (mod) hotkeyString.push(modifierKeyNames[i]);\n }\n\n if (!modifierKeyNames.includes(key)) {\n hotkeyString.push(key);\n }\n\n return hotkeyString.join('+');\n}\n\nexport function isHotkey(event: KeyboardEvent, key: string) {\n return key.toUpperCase() === hotkey(event).toUpperCase();\n}\n","import { coerceElement } from '@angular/cdk/coercion';\nimport { DOCUMENT } from '@angular/common';\nimport { Injectable, NgZone, ElementRef, inject } from '@angular/core';\nimport { ThyEventDispatcher } from '@tethys/cdk/event';\nimport { fromEvent, Observable, OperatorFunction, Subscriber } from 'rxjs';\nimport { filter } from 'rxjs/operators';\nimport { isFormElement, isString, isUndefinedOrNull } from '@tethys/cdk/is';\nimport { isHotkey } from './hotkey';\n\nfunction runInZone<T>(zone: NgZone): OperatorFunction<T, T> {\n return source => {\n return new Observable(observer => {\n const onNext = (value: T) => zone.run(() => observer.next(value));\n const onError = (e: any) => zone.run(() => observer.error(e));\n const onComplete = () => zone.run(() => observer.complete());\n return source.subscribe(onNext, onError, onComplete);\n });\n };\n}\n\n@Injectable({ providedIn: 'root' })\nexport class ThyHotkeyDispatcher extends ThyEventDispatcher {\n constructor() {\n const document = inject(DOCUMENT);\n const ngZone = inject(NgZone);\n\n super(document, ngZone, 'keydown');\n }\n\n private createKeydownObservable(scope: Element | Document) {\n if (scope === this.document) {\n return this.subscribe(null);\n } else {\n return fromEvent(scope, 'keydown');\n }\n }\n\n /**\n * 热键事件订阅\n */\n keydown(hotkey: string | string[], scope?: ElementRef<Element> | Element | Document): Observable<KeyboardEvent> {\n const hotkeys = isString(hotkey) ? hotkey.split(',') : hotkey;\n const scopeElement = coerceElement(isUndefinedOrNull(scope) ? this.document : scope);\n const keydown = this.createKeydownObservable(scopeElement);\n return new Observable<KeyboardEvent>(subscriber => {\n const subscription = keydown\n .pipe(filter((event: KeyboardEvent) => hotkeys.some(key => isHotkey(event, key))))\n .subscribe((event: KeyboardEvent) => {\n // 如果当前焦点的元素是表单元素并且焦点原色不是Hotkey绑定元素则忽略快捷键\n if (isFormElement(this.document.activeElement) && this.document.activeElement !== scope) {\n return;\n }\n subscriber.next(event);\n });\n return () => {\n subscription.unsubscribe();\n };\n }).pipe(runInZone(this.ngZone));\n }\n}\n","import { DOCUMENT } from '@angular/common';\nimport { Directive, ElementRef, EventEmitter, Input, OnInit, Output, OnDestroy, inject } from '@angular/core';\nimport { Subscription } from 'rxjs';\nimport { isFormElement, isString } from '@tethys/cdk/is';\nimport { ThyHotkeyDispatcher } from './hotkey-dispatcher';\n\n/**\n * @name thyHotkey\n */\n@Directive({ selector: '[thyHotkey]' })\nexport class ThyHotkeyDirective implements OnInit, OnDestroy {\n private document = inject(DOCUMENT);\n private hotkeyDispatcher = inject(ThyHotkeyDispatcher);\n private elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n\n /**\n * 热键对应 Code,多个热键组合支持通过数组或逗号分割的形式传入\n */\n @Input() thyHotkey: string | string[];\n\n /**\n * 配置热键触发范围,默认绑定在 document 上\n */\n @Input() thyHotkeyScope?: string | Element | ElementRef<Element>;\n\n /**\n * 热键触发后的事件\n */\n @Output() thyHotkeyListener: EventEmitter<KeyboardEvent> = new EventEmitter();\n\n private subscription: Subscription = null;\n\n ngOnInit(): void {\n const scope = isString(this.thyHotkeyScope) ? this.document.querySelector(this.thyHotkeyScope) : this.thyHotkeyScope;\n this.subscription = this.hotkeyDispatcher.keydown(this.thyHotkey, scope).subscribe(event => {\n event.preventDefault();\n event.stopPropagation();\n if (isFormElement(this.elementRef)) {\n this.elementRef.nativeElement.focus();\n } else {\n this.elementRef.nativeElement.click();\n }\n this.thyHotkeyListener.emit(event);\n });\n }\n\n ngOnDestroy(): void {\n if (this.subscription) {\n this.subscription.unsubscribe();\n }\n }\n}\n","import { NgModule } from '@angular/core';\nimport { ThyHotkeyDirective } from './hotkey.directive';\n\n@NgModule({\n imports: [ThyHotkeyDirective],\n exports: [ThyHotkeyDirective]\n})\nexport class ThyHotkeyModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;AAAA,MAAM,gBAAgB,GAAa,CAAC,CAAS,OAAA,CAAA,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,CAAC;AAEtE;AACA,SAAS,SAAS,CAAC,KAAoB,EAAA;IACnC,MAAM,EAAE,QAAQ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1B;;;MCrBQ,eAAe,CAAA;8GAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAf,eAAe,EAAA,OAAA,EAAA,CAHd,kBAAkB,CAAA,EAAA,OAAA,EAAA,CAClB,kBAAkB,CAAA,EAAA,CAAA,CAAA;+GAEnB,eAAe,EAAA,CAAA,CAAA;;2FAAf,eAAe,EAAA,UAAA,EAAA,CAAA;kBAJ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACN,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,OAAO,EAAE,CAAC,kBAAkB;AAC/B,iBAAA;;;ACND;;AAEG;;;;"}
@@ -23,5 +23,5 @@ export declare class ThyHotkeyDirective implements OnInit, OnDestroy {
23
23
  ngOnInit(): void;
24
24
  ngOnDestroy(): void;
25
25
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyHotkeyDirective, never>;
26
- static ɵdir: i0.ɵɵDirectiveDeclaration<ThyHotkeyDirective, "[thyHotkey]", never, { "thyHotkey": { "alias": "thyHotkey"; "required": false; }; "thyHotkeyScope": { "alias": "thyHotkeyScope"; "required": false; }; }, { "thyHotkeyListener": "thyHotkeyListener"; }, never, never, false, never>;
26
+ static ɵdir: i0.ɵɵDirectiveDeclaration<ThyHotkeyDirective, "[thyHotkey]", never, { "thyHotkey": { "alias": "thyHotkey"; "required": false; }; "thyHotkeyScope": { "alias": "thyHotkeyScope"; "required": false; }; }, { "thyHotkeyListener": "thyHotkeyListener"; }, never, never, true, never>;
27
27
  }
@@ -2,6 +2,6 @@ import * as i0 from "@angular/core";
2
2
  import * as i1 from "./hotkey.directive";
3
3
  export declare class ThyHotkeyModule {
4
4
  static ɵfac: i0.ɵɵFactoryDeclaration<ThyHotkeyModule, never>;
5
- static ɵmod: i0.ɵɵNgModuleDeclaration<ThyHotkeyModule, [typeof i1.ThyHotkeyDirective], never, [typeof i1.ThyHotkeyDirective]>;
5
+ static ɵmod: i0.ɵɵNgModuleDeclaration<ThyHotkeyModule, never, [typeof i1.ThyHotkeyDirective], [typeof i1.ThyHotkeyDirective]>;
6
6
  static ɵinj: i0.ɵɵInjectorDeclaration<ThyHotkeyModule>;
7
7
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tethys/cdk",
3
- "version": "19.0.4",
3
+ "version": "19.0.6",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^19.0.0",
6
6
  "@angular/core": "^19.0.0",