@ionic/angular 9.0.4-dev.11789406216.162770a8 → 9.0.4-dev.11789496656.1690cf55

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.
Files changed (55) hide show
  1. package/dist/common/directives/navigation/back-button.d.ts +1 -0
  2. package/dist/common/directives/navigation/back-button.js +15 -3
  3. package/dist/common/directives/navigation/back-button.js.map +1 -1
  4. package/dist/common/directives/navigation/nav.d.ts +2 -0
  5. package/dist/common/directives/navigation/nav.js +12 -3
  6. package/dist/common/directives/navigation/nav.js.map +1 -1
  7. package/dist/common/directives/navigation/router-outlet.d.ts +2 -0
  8. package/dist/common/directives/navigation/router-outlet.js +8 -2
  9. package/dist/common/directives/navigation/router-outlet.js.map +1 -1
  10. package/dist/common/overlays/modal.d.ts +9 -0
  11. package/dist/common/overlays/modal.js +14 -11
  12. package/dist/common/overlays/modal.js.map +1 -1
  13. package/dist/common/overlays/popover.d.ts +10 -0
  14. package/dist/common/overlays/popover.js +15 -12
  15. package/dist/common/overlays/popover.js.map +1 -1
  16. package/dist/common/utils/boolean-attribute.d.ts +24 -0
  17. package/dist/common/utils/boolean-attribute.js +36 -0
  18. package/dist/common/utils/boolean-attribute.js.map +1 -0
  19. package/dist/standalone/directives/checkbox.d.ts +3 -0
  20. package/dist/standalone/directives/checkbox.js +8 -5
  21. package/dist/standalone/directives/checkbox.js.map +1 -1
  22. package/dist/standalone/directives/datetime.d.ts +9 -0
  23. package/dist/standalone/directives/datetime.js +14 -11
  24. package/dist/standalone/directives/datetime.js.map +1 -1
  25. package/dist/standalone/directives/icon.d.ts +3 -0
  26. package/dist/standalone/directives/icon.js +19 -3
  27. package/dist/standalone/directives/icon.js.map +1 -1
  28. package/dist/standalone/directives/input-otp.d.ts +2 -0
  29. package/dist/standalone/directives/input-otp.js +7 -4
  30. package/dist/standalone/directives/input-otp.js.map +1 -1
  31. package/dist/standalone/directives/input.d.ts +10 -0
  32. package/dist/standalone/directives/input.js +15 -12
  33. package/dist/standalone/directives/input.js.map +1 -1
  34. package/dist/standalone/directives/radio-group.d.ts +1 -0
  35. package/dist/standalone/directives/radio-group.js +13 -3
  36. package/dist/standalone/directives/radio-group.js.map +1 -1
  37. package/dist/standalone/directives/range.d.ts +5 -0
  38. package/dist/standalone/directives/range.js +10 -7
  39. package/dist/standalone/directives/range.js.map +1 -1
  40. package/dist/standalone/directives/searchbar.d.ts +4 -0
  41. package/dist/standalone/directives/searchbar.js +9 -6
  42. package/dist/standalone/directives/searchbar.js.map +1 -1
  43. package/dist/standalone/directives/segment.d.ts +4 -0
  44. package/dist/standalone/directives/segment.js +14 -3
  45. package/dist/standalone/directives/segment.js.map +1 -1
  46. package/dist/standalone/directives/select.d.ts +2 -0
  47. package/dist/standalone/directives/select.js +7 -4
  48. package/dist/standalone/directives/select.js.map +1 -1
  49. package/dist/standalone/directives/textarea.d.ts +8 -0
  50. package/dist/standalone/directives/textarea.js +13 -10
  51. package/dist/standalone/directives/textarea.js.map +1 -1
  52. package/dist/standalone/directives/toggle.d.ts +3 -0
  53. package/dist/standalone/directives/toggle.js +8 -5
  54. package/dist/standalone/directives/toggle.js.map +1 -1
  55. package/package.json +2 -2
@@ -1 +1 @@
1
- {"version":3,"file":"textarea.js","sourceRoot":"","sources":["../../../src/standalone/directives/textarea.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,uBAAuB,EAEvB,SAAS,EAGT,YAAY,EAGZ,UAAU,GACX,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAEtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAC;AAE7E,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;;AAEvE,MAAM,eAAe,GAAG;IACtB,UAAU;IACV,gBAAgB;IAChB,WAAW;IACX,aAAa;IACb,OAAO;IACP,M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;oBACxB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,QAAQ,EAAE,2BAA2B;oBACrC,uEAAuE;oBACvE,MAAM,EAAE,eAAe;oBACvB,SAAS,EAAE;wBACT;4BACE,OAAO,EAAE,iBAAiB;4BAC1B,WAAW,EAAE,UAAU,EAAC,GAAG,EAAE,YAAY,EAAC;4BAC1C,KAAK,EAAE,IAAI;yBACZ;qBACF;oBACD,UAAU,EAAE,IAAI;iBACjB;;sBAUE,YAAY;uBAAC,UAAU,EAAE,CAAC,eAAe,CAAC","sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n EventEmitter,\n HostListener,\n Injector,\n NgZone,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ValueAccessor } from '@ionic/angular/common';\nimport type { TextareaChangeEventDetail, TextareaInputEventDetail, Components } from '@ionic/core/components';\nimport { defineCustomElement } from '@ionic/core/components/ion-textarea.js';\n\nimport { ProxyCmp, proxyOutputs } from './angular-component-lib/utils';\n\nconst TEXTAREA_INPUTS = [\n 'autoGrow',\n 'autocapitalize',\n 'autofocus',\n 'clearOnEdit',\n 'color',\n 'cols',\n 'counter',\n 'counterFormatter',\n 'debounce',\n 'disabled',\n 'enterkeyhint',\n 'errorText',\n 'fill',\n 'helperText',\n 'inputmode',\n 'label',\n 'labelPlacement',\n 'maxlength',\n 'minlength',\n 'mode',\n 'name',\n 'placeholder',\n 'readonly',\n 'required',\n 'rows',\n 'shape',\n 'spellcheck',\n 'value',\n 'wrap',\n];\n\n@ProxyCmp({\n defineCustomElementFn: defineCustomElement,\n inputs: TEXTAREA_INPUTS,\n methods: ['setFocus', 'getInputElement'],\n})\n@Component({\n selector: 'ion-textarea',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: '<ng-content></ng-content>',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: TEXTAREA_INPUTS,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => IonTextarea),\n multi: true,\n },\n ],\n standalone: true,\n})\nexport class IonTextarea extends ValueAccessor {\n protected el: HTMLElement;\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone, injector: Injector) {\n super(injector, r);\n c.detach();\n this.el = r.nativeElement;\n proxyOutputs(this, this.el, ['ionChange', 'ionInput', 'ionBlur', 'ionFocus']);\n }\n\n @HostListener('ionInput', ['$event.target'])\n handleIonInput(el: HTMLIonTextareaElement): void {\n this.handleValueChange(el, el.value);\n }\n}\n\nexport declare interface IonTextarea extends Components.IonTextarea {\n /**\n * The `ionChange` event is fired when the user modifies the textarea's value.\nUnlike the `ionInput` event, the `ionChange` event is fired when\nthe element loses focus after its value has been modified.\n */\n ionChange: EventEmitter<CustomEvent<TextareaChangeEventDetail>>;\n /**\n * The `ionInput` event is fired each time the user modifies the textarea's value.\nUnlike the `ionChange` event, the `ionInput` event is fired for each alteration\nto the textarea's value. This typically happens for each keystroke as the user types.\n\nWhen `clearOnEdit` is enabled, the `ionInput` event will be fired when\nthe user clears the textarea by performing a keydown event.\n */\n ionInput: EventEmitter<CustomEvent<TextareaInputEventDetail>>;\n /**\n * Emitted when the input loses focus.\n */\n ionBlur: EventEmitter<CustomEvent<FocusEvent>>;\n /**\n * Emitted when the input has focus.\n */\n ionFocus: EventEmitter<CustomEvent<FocusEvent>>;\n}\n"]}
1
+ {"version":3,"file":"textarea.js","sourceRoot":"","sources":["../../../src/standalone/directives/textarea.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,uBAAuB,EAEvB,SAAS,EAGT,YAAY,EAGZ,UAAU,GACX,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAEtD,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAC;AAE7E,OAAO,EAAE,wBAAwB,EAAE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AUE,YAAY;uBAAC,UAAU,EAAE,CAAC,eAAe,CAAC","sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n EventEmitter,\n HostListener,\n Injector,\n NgZone,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ValueAccessor } from '@ionic/angular/common';\nimport type { TextareaChangeEventDetail, TextareaInputEventDetail, Components } from '@ionic/core/components';\nimport { defineCustomElement } from '@ionic/core/components/ion-textarea.js';\n\nimport { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute';\nimport { ProxyCmp, proxyOutputs } from './angular-component-lib/utils';\n\nconst TEXTAREA_INPUTS = [\n { name: 'autoGrow', transform: nullableBooleanAttribute },\n 'autocapitalize',\n { name: 'autofocus', transform: nullableBooleanAttribute },\n { name: 'clearOnEdit', transform: nullableBooleanAttribute },\n 'color',\n 'cols',\n { name: 'counter', transform: nullableBooleanAttribute },\n 'counterFormatter',\n 'debounce',\n { name: 'disabled', transform: nullableBooleanAttribute },\n 'enterkeyhint',\n 'errorText',\n 'fill',\n 'helperText',\n 'inputmode',\n 'label',\n 'labelPlacement',\n 'maxlength',\n 'minlength',\n 'mode',\n 'name',\n 'placeholder',\n { name: 'readonly', transform: nullableBooleanAttribute },\n { name: 'required', transform: nullableBooleanAttribute },\n 'rows',\n 'shape',\n { name: 'spellcheck', transform: nullableBooleanAttribute },\n 'value',\n 'wrap',\n];\n\n/* ProxyCmp only needs the names, and runs at runtime rather than through the Angular compiler. */\nconst TEXTAREA_PROXY_INPUTS = TEXTAREA_INPUTS.map((input) => (typeof input === 'string' ? input : input.name));\n\n@ProxyCmp({\n defineCustomElementFn: defineCustomElement,\n inputs: TEXTAREA_PROXY_INPUTS,\n methods: ['setFocus', 'getInputElement'],\n})\n@Component({\n selector: 'ion-textarea',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: '<ng-content></ng-content>',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: TEXTAREA_INPUTS,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => IonTextarea),\n multi: true,\n },\n ],\n standalone: true,\n})\nexport class IonTextarea extends ValueAccessor {\n protected el: HTMLElement;\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone, injector: Injector) {\n super(injector, r);\n c.detach();\n this.el = r.nativeElement;\n proxyOutputs(this, this.el, ['ionChange', 'ionInput', 'ionBlur', 'ionFocus']);\n }\n\n @HostListener('ionInput', ['$event.target'])\n handleIonInput(el: HTMLIonTextareaElement): void {\n this.handleValueChange(el, el.value);\n }\n}\n\nexport declare interface IonTextarea extends Components.IonTextarea {\n /**\n * The `ionChange` event is fired when the user modifies the textarea's value.\nUnlike the `ionInput` event, the `ionChange` event is fired when\nthe element loses focus after its value has been modified.\n */\n ionChange: EventEmitter<CustomEvent<TextareaChangeEventDetail>>;\n /**\n * The `ionInput` event is fired each time the user modifies the textarea's value.\nUnlike the `ionChange` event, the `ionInput` event is fired for each alteration\nto the textarea's value. This typically happens for each keystroke as the user types.\n\nWhen `clearOnEdit` is enabled, the `ionInput` event will be fired when\nthe user clears the textarea by performing a keydown event.\n */\n ionInput: EventEmitter<CustomEvent<TextareaInputEventDetail>>;\n /**\n * Emitted when the input loses focus.\n */\n ionBlur: EventEmitter<CustomEvent<FocusEvent>>;\n /**\n * Emitted when the input has focus.\n */\n ionFocus: EventEmitter<CustomEvent<FocusEvent>>;\n}\n"]}
@@ -10,6 +10,9 @@ export declare class IonToggle extends ValueAccessor {
10
10
  handleIonChange(el: HTMLIonToggleElement): void;
11
11
  static ɵfac: i0.ɵɵFactoryDeclaration<IonToggle, never>;
12
12
  static ɵcmp: i0.ɵɵComponentDeclaration<IonToggle, "ion-toggle", never, { "checked": { "alias": "checked"; "required": false; }; "color": { "alias": "color"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "enableOnOffLabels": { "alias": "enableOnOffLabels"; "required": false; }; "errorText": { "alias": "errorText"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "justify": { "alias": "justify"; "required": false; }; "labelPlacement": { "alias": "labelPlacement"; "required": false; }; "mode": { "alias": "mode"; "required": false; }; "name": { "alias": "name"; "required": false; }; "value": { "alias": "value"; "required": false; }; }, {}, never, ["*"], true, never>;
13
+ static ngAcceptInputType_checked: boolean | string | null | undefined;
14
+ static ngAcceptInputType_disabled: boolean | string | null | undefined;
15
+ static ngAcceptInputType_enableOnOffLabels: boolean | string | null | undefined;
13
16
  }
14
17
  export declare interface IonToggle extends Components.IonToggle {
15
18
  /**
@@ -3,13 +3,14 @@ import { ChangeDetectionStrategy, Component, HostListener, forwardRef, } from '@
3
3
  import { NG_VALUE_ACCESSOR } from '@angular/forms';
4
4
  import { ValueAccessor, setIonicClasses } from '@ionic/angular/common';
5
5
  import { defineCustomElement } from '@ionic/core/components/ion-toggle.js';
6
+ import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute';
6
7
  import { ProxyCmp, proxyOutputs } from './angular-component-lib/utils';
7
8
  import * as i0 from "@angular/core";
8
9
  const TOGGLE_INPUTS = [
9
- 'checked',
10
+ { name: 'checked', transform: nullableBooleanAttribute },
10
11
  'color',
11
- 'disabled',
12
- 'enableOnOffLabels',
12
+ { name: 'disabled', transform: nullableBooleanAttribute },
13
+ { name: 'enableOnOffLabels', transform: nullableBooleanAttribute },
13
14
  'errorText',
14
15
  'helperText',
15
16
  'justify',
@@ -18,6 +19,8 @@ const TOGGLE_INPUTS = [
18
19
  'name',
19
20
  'value',
20
21
  ];
22
+ /* ProxyCmp only needs the names, and runs at runtime rather than through the Angular compiler. */
23
+ const TOGGLE_PROXY_INPUTS = TOGGLE_INPUTS.map((input) => (typeof input === 'string' ? input : input.name));
21
24
  let IonToggle = class IonToggle extends ValueAccessor {
22
25
  z;
23
26
  el;
@@ -36,7 +39,7 @@ let IonToggle = class IonToggle extends ValueAccessor {
36
39
  this.handleValueChange(el, el.checked);
37
40
  }
38
41
  /** @nocollapse */ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.0", ngImport: i0, type: IonToggle, deps: [{ token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
39
- /** @nocollapse */ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.0", type: IonToggle, isStandalone: true, selector: "ion-toggle", inputs: { checked: "checked", color: "color", disabled: "disabled", enableOnOffLabels: "enableOnOffLabels", errorText: "errorText", helperText: "helperText", justify: "justify", labelPlacement: "labelPlacement", mode: "mode", name: "name", value: "value" }, host: { listeners: { "ionChange": "handleIonChange($event.target)" } }, providers: [
42
+ /** @nocollapse */ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "22.0.0", type: IonToggle, isStandalone: true, selector: "ion-toggle", inputs: { checked: ["checked", "checked", nullableBooleanAttribute], color: "color", disabled: ["disabled", "disabled", nullableBooleanAttribute], enableOnOffLabels: ["enableOnOffLabels", "enableOnOffLabels", nullableBooleanAttribute], errorText: "errorText", helperText: "helperText", justify: "justify", labelPlacement: "labelPlacement", mode: "mode", name: "name", value: "value" }, host: { listeners: { "ionChange": "handleIonChange($event.target)" } }, providers: [
40
43
  {
41
44
  provide: NG_VALUE_ACCESSOR,
42
45
  useExisting: forwardRef((() => IonToggle)),
@@ -47,7 +50,7 @@ let IonToggle = class IonToggle extends ValueAccessor {
47
50
  IonToggle = __decorate([
48
51
  ProxyCmp({
49
52
  defineCustomElementFn: defineCustomElement,
50
- inputs: TOGGLE_INPUTS,
53
+ inputs: TOGGLE_PROXY_INPUTS,
51
54
  })
52
55
  ], IonToggle);
53
56
  export { IonToggle };
@@ -1 +1 @@
1
- {"version":3,"file":"toggle.js","sourceRoot":"","sources":["../../../src/standalone/directives/toggle.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,uBAAuB,EAEvB,SAAS,EAGT,YAAY,E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UAAU,EAAC,GAAG,EAAE,CAAC,SAAS,EAAC;gBACxC,KAAK,EAAE,IAAI;aACZ;SACF,iDATS,2BAA2B;;AAY1B,SAAS;IAnBrB,QAAQ,CAAC;QACR,qBAAqB,EAAE,mBAAmB;QAC1C,MAAM,EAAE,aAAa;KACtB,CAAC;GAgBW,SAAS,CAkBrB;;2FAlBY,SAAS;kBAfrB,SAAS;mBAAC;oBACT,QAAQ,EAAE,YAAY;oBACtB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,QAAQ,EAAE,2BAA2B;oBACrC,uEAAuE;oBACvE,MAAM,EAAE,aAAa;oBACrB,SAAS,EAAE;wBACT;4BACE,OAAO,EAAE,iBAAiB;4BAC1B,WAAW,EAAE,UAAU,EAAC,GAAG,EAAE,UAAU,EAAC;4BACxC,KAAK,EAAE,IAAI;yBACZ;qBACF;oBACD,UAAU,EAAE,IAAI;iBACjB;;sBAeE,YAAY;uBAAC,WAAW,EAAE,CAAC,eAAe,CAAC","sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n EventEmitter,\n HostListener,\n Injector,\n NgZone,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ValueAccessor, setIonicClasses } from '@ionic/angular/common';\nimport type { ToggleChangeEventDetail, Components } from '@ionic/core/components';\nimport { defineCustomElement } from '@ionic/core/components/ion-toggle.js';\n\nimport { ProxyCmp, proxyOutputs } from './angular-component-lib/utils';\n\nconst TOGGLE_INPUTS = [\n 'checked',\n 'color',\n 'disabled',\n 'enableOnOffLabels',\n 'errorText',\n 'helperText',\n 'justify',\n 'labelPlacement',\n 'mode',\n 'name',\n 'value',\n];\n\n@ProxyCmp({\n defineCustomElementFn: defineCustomElement,\n inputs: TOGGLE_INPUTS,\n})\n@Component({\n selector: 'ion-toggle',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: '<ng-content></ng-content>',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: TOGGLE_INPUTS,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => IonToggle),\n multi: true,\n },\n ],\n standalone: true,\n})\nexport class IonToggle extends ValueAccessor {\n protected el: HTMLElement;\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone, injector: Injector) {\n super(injector, r);\n c.detach();\n this.el = r.nativeElement;\n proxyOutputs(this, this.el, ['ionChange', 'ionFocus', 'ionBlur']);\n }\n\n writeValue(value: boolean): void {\n this.elementRef.nativeElement.checked = this.lastValue = value;\n setIonicClasses(this.elementRef);\n }\n\n @HostListener('ionChange', ['$event.target'])\n handleIonChange(el: HTMLIonToggleElement): void {\n this.handleValueChange(el, el.checked);\n }\n}\n\nexport declare interface IonToggle extends Components.IonToggle {\n /**\n * Emitted when the user switches the toggle on or off. Does not emit\nwhen programmatically changing the value of the `checked` property.\n */\n ionChange: EventEmitter<CustomEvent<ToggleChangeEventDetail>>;\n /**\n * Emitted when the toggle has focus.\n */\n ionFocus: EventEmitter<CustomEvent<void>>;\n /**\n * Emitted when the toggle loses focus.\n */\n ionBlur: EventEmitter<CustomEvent<void>>;\n}\n"]}
1
+ {"version":3,"file":"toggle.js","sourceRoot":"","sources":["../../../src/standalone/directives/toggle.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,uBAAuB,EAEvB,SAAS,EAGT,YAAY,EAGZ,UAAU,GACX,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAEvE,OAAO,EAAE,mBAAmB,EAAE,MAAM,sCAAsC,CAAC;AAE3E,OAAO,EAAE,wBAAwB,EAAE,MAAM,2CAA2C,CAAC;AACrF,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;;AAEvE,MAAM,aAAa,GAAG;IACpB,EAA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nCU,wBAAwB,sDAEvB,wBAAwB,iEACf,wBAAwB,4OAuBrD;YACT;gBACE,OAAO,EAAE,iBAAiB;gBAC1B,WAAW,EAAE,UAAU,EAAC,GAAG,EAAE,CAAC,SAAS,EAAC;gBACxC,KAAK,EAAE,IAAI;aACZ;SACF,iDATS,2BAA2B;;AAY1B,SAAS;IAnBrB,QAAQ,CAAC;QACR,qBAAqB,EAAE,mBAAmB;QAC1C,MAAM,EAAE,mBAAmB;KAC5B,CAAC;GAgBW,SAAS,CAkBrB;;2FAlBY,SAAS;kBAfrB,SAAS;mBAAC;oBACT,QAAQ,EAAE,YAAY;oBACtB,eAAe,EAAE,uBAAuB,CAAC,MAAM;oBAC/C,QAAQ,EAAE,2BAA2B;oBACrC,uEAAuE;oBACvE,MAAM,EAAE,aAAa;oBACrB,SAAS,EAAE;wBACT;4BACE,OAAO,EAAE,iBAAiB;4BAC1B,WAAW,EAAE,UAAU,EAAC,GAAG,EAAE,UAAU,EAAC;4BACxC,KAAK,EAAE,IAAI;yBACZ;qBACF;oBACD,UAAU,EAAE,IAAI;iBACjB;;sBAeE,YAAY;uBAAC,WAAW,EAAE,CAAC,eAAe,CAAC","sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n EventEmitter,\n HostListener,\n Injector,\n NgZone,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { ValueAccessor, setIonicClasses } from '@ionic/angular/common';\nimport type { ToggleChangeEventDetail, Components } from '@ionic/core/components';\nimport { defineCustomElement } from '@ionic/core/components/ion-toggle.js';\n\nimport { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute';\nimport { ProxyCmp, proxyOutputs } from './angular-component-lib/utils';\n\nconst TOGGLE_INPUTS = [\n { name: 'checked', transform: nullableBooleanAttribute },\n 'color',\n { name: 'disabled', transform: nullableBooleanAttribute },\n { name: 'enableOnOffLabels', transform: nullableBooleanAttribute },\n 'errorText',\n 'helperText',\n 'justify',\n 'labelPlacement',\n 'mode',\n 'name',\n 'value',\n];\n\n/* ProxyCmp only needs the names, and runs at runtime rather than through the Angular compiler. */\nconst TOGGLE_PROXY_INPUTS = TOGGLE_INPUTS.map((input) => (typeof input === 'string' ? input : input.name));\n\n@ProxyCmp({\n defineCustomElementFn: defineCustomElement,\n inputs: TOGGLE_PROXY_INPUTS,\n})\n@Component({\n selector: 'ion-toggle',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: '<ng-content></ng-content>',\n // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property\n inputs: TOGGLE_INPUTS,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => IonToggle),\n multi: true,\n },\n ],\n standalone: true,\n})\nexport class IonToggle extends ValueAccessor {\n protected el: HTMLElement;\n constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone, injector: Injector) {\n super(injector, r);\n c.detach();\n this.el = r.nativeElement;\n proxyOutputs(this, this.el, ['ionChange', 'ionFocus', 'ionBlur']);\n }\n\n writeValue(value: boolean): void {\n this.elementRef.nativeElement.checked = this.lastValue = value;\n setIonicClasses(this.elementRef);\n }\n\n @HostListener('ionChange', ['$event.target'])\n handleIonChange(el: HTMLIonToggleElement): void {\n this.handleValueChange(el, el.checked);\n }\n}\n\nexport declare interface IonToggle extends Components.IonToggle {\n /**\n * Emitted when the user switches the toggle on or off. Does not emit\nwhen programmatically changing the value of the `checked` property.\n */\n ionChange: EventEmitter<CustomEvent<ToggleChangeEventDetail>>;\n /**\n * Emitted when the toggle has focus.\n */\n ionFocus: EventEmitter<CustomEvent<void>>;\n /**\n * Emitted when the toggle loses focus.\n */\n ionBlur: EventEmitter<CustomEvent<void>>;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ionic/angular",
3
- "version": "9.0.4-dev.11789406216.162770a8",
3
+ "version": "9.0.4-dev.11789496656.1690cf55",
4
4
  "description": "Angular specific wrappers for @ionic/core",
5
5
  "keywords": [
6
6
  "ionic",
@@ -168,7 +168,7 @@
168
168
  "css/"
169
169
  ],
170
170
  "dependencies": {
171
- "@ionic/core": "9.0.4-dev.11789406216.162770a8",
171
+ "@ionic/core": "9.0.4-dev.11789496656.1690cf55",
172
172
  "ionicons": "^8.0.13",
173
173
  "jsonc-parser": "^3.0.0",
174
174
  "tslib": "^2.3.0"