From 62770a8f124a1e950d06855d8c9fa3f14d7cdca1 Mon Sep 17 00:00:00 2001 From: Maria Hutt Date: Fri, 11 Sep 2026 15:27:37 -0700 Subject: [PATCH] feat(angular): support setting boolean props by attribute presence --- core/package-lock.json | 8 +- core/package.json | 2 +- core/stencil.config.ts | 2 + .../boolean-attribute.ts | 43 +++++++ .../angular/src/lazy/directives/proxies.ts | 115 +++++++++--------- .../boolean-attribute.ts | 43 +++++++ .../directives/ion-accordion-group.ts | 3 +- .../standalone/directives/ion-accordion.ts | 3 +- .../standalone/directives/ion-action-sheet.ts | 3 +- .../src/standalone/directives/ion-alert.ts | 3 +- .../src/standalone/directives/ion-backdrop.ts | 3 +- .../standalone/directives/ion-breadcrumb.ts | 3 +- .../src/standalone/directives/ion-button.ts | 3 +- .../src/standalone/directives/ion-buttons.ts | 3 +- .../standalone/directives/ion-card-header.ts | 3 +- .../src/standalone/directives/ion-card.ts | 3 +- .../src/standalone/directives/ion-chip.ts | 3 +- .../src/standalone/directives/ion-content.ts | 3 +- .../directives/ion-datetime-button.ts | 3 +- .../standalone/directives/ion-fab-button.ts | 3 +- .../src/standalone/directives/ion-fab-list.ts | 3 +- .../src/standalone/directives/ion-fab.ts | 3 +- .../src/standalone/directives/ion-footer.ts | 3 +- .../src/standalone/directives/ion-grid.ts | 3 +- .../src/standalone/directives/ion-header.ts | 3 +- .../directives/ion-infinite-scroll.ts | 3 +- .../standalone/directives/ion-item-divider.ts | 3 +- .../standalone/directives/ion-item-option.ts | 3 +- .../standalone/directives/ion-item-sliding.ts | 3 +- .../src/standalone/directives/ion-item.ts | 3 +- .../src/standalone/directives/ion-list.ts | 3 +- .../src/standalone/directives/ion-loading.ts | 3 +- .../standalone/directives/ion-menu-button.ts | 3 +- .../standalone/directives/ion-menu-toggle.ts | 3 +- .../src/standalone/directives/ion-menu.ts | 3 +- .../directives/ion-picker-column-option.ts | 3 +- .../directives/ion-picker-column.ts | 3 +- .../standalone/directives/ion-progress-bar.ts | 3 +- .../src/standalone/directives/ion-radio.ts | 3 +- .../standalone/directives/ion-refresher.ts | 3 +- .../directives/ion-reorder-group.ts | 3 +- .../directives/ion-segment-button.ts | 3 +- .../standalone/directives/ion-segment-view.ts | 3 +- .../standalone/directives/ion-select-modal.ts | 3 +- .../directives/ion-select-option.ts | 3 +- .../directives/ion-skeleton-text.ts | 3 +- .../src/standalone/directives/ion-spinner.ts | 3 +- .../standalone/directives/ion-split-pane.ts | 3 +- .../src/standalone/directives/ion-tab-bar.ts | 3 +- .../standalone/directives/ion-tab-button.ts | 3 +- .../src/standalone/directives/ion-toast.ts | 3 +- 51 files changed, 241 insertions(+), 107 deletions(-) create mode 100644 packages/angular/src/lazy/directives/angular-component-lib/boolean-attribute.ts create mode 100644 packages/angular/src/standalone/directives/angular-component-lib/boolean-attribute.ts diff --git a/core/package-lock.json b/core/package-lock.json index 6668c514150..7c7d72198d7 100644 --- a/core/package-lock.json +++ b/core/package-lock.json @@ -26,7 +26,7 @@ "@playwright/test": "^1.62.1", "@rollup/plugin-node-resolve": "^8.4.0", "@rollup/plugin-virtual": "^2.0.3", - "@stencil/angular-output-target": "^1.4.1", + "@stencil/angular-output-target": "^1.5.0", "@stencil/react-output-target": "^1.6.2", "@stencil/sass": "^3.0.9", "@stencil/vue-output-target": "0.14.2", @@ -1829,9 +1829,9 @@ } }, "node_modules/@stencil/angular-output-target": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-1.4.1.tgz", - "integrity": "sha512-sy+k9B5jcT6hpaVU9n+/ZUjz3qVr9PAdPgy2c3LFQouW1aFSa3Ng0O+Ia3wk7LMeL3vDetCn2X+p2ewdHGc1vA==", + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/@stencil/angular-output-target/-/angular-output-target-1.5.0.tgz", + "integrity": "sha512-zr3n6PP3Gcj5pEyJgn32eJkSXSW5sH6XuSe7mG/MbSCZ6Odds4J7zplBDAc7WgTIcaxY1xS0cR21q1SCncwpkA==", "dev": true, "license": "MIT", "peerDependencies": { diff --git a/core/package.json b/core/package.json index 990ee9e7283..0fbd977a22a 100644 --- a/core/package.json +++ b/core/package.json @@ -83,7 +83,7 @@ "@playwright/test": "^1.62.1", "@rollup/plugin-node-resolve": "^8.4.0", "@rollup/plugin-virtual": "^2.0.3", - "@stencil/angular-output-target": "^1.4.1", + "@stencil/angular-output-target": "^1.5.0", "@stencil/react-output-target": "^1.6.2", "@stencil/sass": "^3.0.9", "@stencil/vue-output-target": "0.14.2", diff --git a/core/stencil.config.ts b/core/stencil.config.ts index d24854f98b1..cba75244c6a 100644 --- a/core/stencil.config.ts +++ b/core/stencil.config.ts @@ -34,6 +34,7 @@ const getAngularOutputTargets = () => { directivesArrayFile: '../packages/angular/src/lazy/directives/proxies-list.ts', excludeComponents, outputType: 'component', + booleanAttributes: true, }), angularOutputTarget({ componentCorePackage, @@ -66,6 +67,7 @@ const getAngularOutputTargets = () => { outputType: 'standalone', // Emit each component in a separate file rather than putting them all in one large file. esModules: true, + booleanAttributes: true, }) ]; } diff --git a/packages/angular/src/lazy/directives/angular-component-lib/boolean-attribute.ts b/packages/angular/src/lazy/directives/angular-component-lib/boolean-attribute.ts new file mode 100644 index 00000000000..c116dd5bc7f --- /dev/null +++ b/packages/angular/src/lazy/directives/angular-component-lib/boolean-attribute.ts @@ -0,0 +1,43 @@ +/* eslint-disable */ +/* tslint:disable */ + +/** + * Transforms a value to a boolean so that boolean properties can be set by attribute presence, + * e.g. `` instead of ``. + * + * Strings are coerced the same way Angular's `booleanAttribute` coerces them, so `''` (a bare + * attribute) becomes `true` and `'false'` becomes `false`. + * + * Unlike Angular's `booleanAttribute`, `null` and `undefined` are passed through rather than + * coerced to `false`. Components frequently treat them as a state distinct from `false`: + * + * ```tsx + * // `undefined` means "decide based on the mode", which is not the same as `false` + * const showDetail = detail !== undefined ? detail : mode === 'ios'; + * + * // a strict comparison also behaves differently for `null` than it does for `false` + * const showHandle = handle !== false; + * ``` + * + * Both values reach inputs routinely in Angular templates, from the `async` pipe before its + * first emission and from form control values, so coercing them would change the behavior of + * bindings that work today. + * + * This is implemented here rather than imported from `@angular/core` so that consumers on + * Angular versions without `booleanAttribute` are unaffected by this file being generated. + * + * The parameter type is what Angular derives `ngAcceptInputType_*` from, so it decides which + * template bindings compile. Widening it to `unknown` would let any expression through. + * + * Declared as a function rather than an arrow constant because Angular has to resolve input + * transforms statically when compiling a library in partial compilation mode. + * + * This lives in its own file, separate from `utils.ts`, so that it carries no runtime imports. + * That keeps it independently type-checkable without pulling `rxjs` in for `proxyOutputs`. + */ +export function nullableBooleanAttribute(value: boolean | string | null | undefined): boolean | null | undefined { + if (value === null || value === undefined) { + return value; + } + return typeof value === 'boolean' ? value : value !== 'false'; +} diff --git a/packages/angular/src/lazy/directives/proxies.ts b/packages/angular/src/lazy/directives/proxies.ts index b6be5b42f03..45a01650aa0 100644 --- a/packages/angular/src/lazy/directives/proxies.ts +++ b/packages/angular/src/lazy/directives/proxies.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, EventEmitter, Output, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import { Components } from '@ionic/core'; @@ -15,7 +16,7 @@ import { Components } from '@ionic/core'; changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'mode', 'readonly', 'toggleIcon', 'toggleIconSlot', 'value'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'mode', { name: 'readonly', transform: nullableBooleanAttribute }, 'toggleIcon', 'toggleIconSlot', 'value'], standalone: false }) export class IonAccordion { @@ -38,7 +39,7 @@ export declare interface IonAccordion extends Components.IonAccordion {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'disabled', 'expand', 'mode', 'multiple', 'readonly', 'value'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'disabled', transform: nullableBooleanAttribute }, 'expand', 'mode', { name: 'multiple', transform: nullableBooleanAttribute }, { name: 'readonly', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange'], standalone: false }) @@ -74,7 +75,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'isOpen', 'keyboardClose', 'leaveAnimation', 'mode', 'subHeader', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'mode', 'subHeader', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionActionSheetDidPresent', 'ionActionSheetWillPresent', 'ionActionSheetWillDismiss', 'ionActionSheetDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], standalone: false }) @@ -147,7 +148,7 @@ Shorthand for ionActionSheetDidDismiss. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'inputs', 'isOpen', 'keyboardClose', 'leaveAnimation', 'message', 'mode', 'subHeader', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'inputs', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'message', 'mode', 'subHeader', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionAlertDidPresent', 'ionAlertWillPresent', 'ionAlertWillDismiss', 'ionAlertDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], standalone: false }) @@ -264,7 +265,7 @@ export declare interface IonAvatar extends Components.IonAvatar {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['stopPropagation', 'tappable', 'visible'], + inputs: [{ name: 'stopPropagation', transform: nullableBooleanAttribute }, { name: 'tappable', transform: nullableBooleanAttribute }, { name: 'visible', transform: nullableBooleanAttribute }], outputs: ['ionBackdropTap'], standalone: false }) @@ -319,7 +320,7 @@ export declare interface IonBadge extends Components.IonBadge {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['active', 'color', 'disabled', 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'separator', 'target'], + inputs: [{ name: 'active', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', { name: 'separator', transform: nullableBooleanAttribute }, 'target'], outputs: ['ionFocus', 'ionBlur'], standalone: false }) @@ -389,7 +390,7 @@ export declare interface IonBreadcrumbs extends Components.IonBreadcrumbs { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['buttonType', 'color', 'disabled', 'download', 'expand', 'fill', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'shape', 'size', 'strong', 'target', 'type'], + inputs: ['buttonType', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'expand', 'fill', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'shape', 'size', { name: 'strong', transform: nullableBooleanAttribute }, 'target', 'type'], outputs: ['ionFocus', 'ionBlur'], standalone: false }) @@ -426,7 +427,7 @@ export declare interface IonButton extends Components.IonButton { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse'], + inputs: [{ name: 'collapse', transform: nullableBooleanAttribute }], standalone: false }) export class IonButtons { @@ -449,7 +450,7 @@ export declare interface IonButtons extends Components.IonButtons {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['button', 'color', 'disabled', 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], + inputs: [{ name: 'button', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], standalone: false }) export class IonCard { @@ -495,7 +496,7 @@ export declare interface IonCardContent extends Components.IonCardContent {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'translucent'], + inputs: ['color', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], standalone: false }) export class IonCardHeader { @@ -564,7 +565,7 @@ export declare interface IonCardTitle extends Components.IonCardTitle {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['alignment', 'checked', 'color', 'disabled', 'errorText', 'helperText', 'indeterminate', 'justify', 'labelPlacement', 'mode', 'name', 'required', 'value'], + inputs: ['alignment', { name: 'checked', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'errorText', 'helperText', { name: 'indeterminate', transform: nullableBooleanAttribute }, 'justify', 'labelPlacement', 'mode', 'name', { name: 'required', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange', 'ionFocus', 'ionBlur'], standalone: false }) @@ -609,7 +610,7 @@ This event will not emit when programmatically setting the `checked` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'mode', 'outline'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', { name: 'outline', transform: nullableBooleanAttribute }], standalone: false }) export class IonChip { @@ -656,7 +657,7 @@ export declare interface IonCol extends Components.IonCol {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'fixedSlotPlacement', 'forceOverscroll', 'fullscreen', 'scrollEvents', 'scrollX', 'scrollY'], + inputs: ['color', 'fixedSlotPlacement', { name: 'forceOverscroll', transform: nullableBooleanAttribute }, { name: 'fullscreen', transform: nullableBooleanAttribute }, { name: 'scrollEvents', transform: nullableBooleanAttribute }, { name: 'scrollX', transform: nullableBooleanAttribute }, { name: 'scrollY', transform: nullableBooleanAttribute }], outputs: ['ionScrollStart', 'ionScroll', 'ionScrollEnd'], standalone: false }) @@ -704,7 +705,7 @@ Set `scrollEvents` to `true` to enable. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cancelText', 'clearText', 'color', 'dayValues', 'disabled', 'doneText', 'firstDayOfWeek', 'formatOptions', 'highlightedDates', 'hourCycle', 'hourValues', 'isDateEnabled', 'locale', 'max', 'min', 'minuteValues', 'mode', 'monthValues', 'multiple', 'name', 'preferWheel', 'presentation', 'readonly', 'showAdjacentDays', 'showClearButton', 'showDefaultButtons', 'showDefaultTimeLabel', 'showDefaultTitle', 'size', 'titleSelectedDatesFormatter', 'value', 'yearValues'], + inputs: ['cancelText', 'clearText', 'color', 'dayValues', { name: 'disabled', transform: nullableBooleanAttribute }, 'doneText', 'firstDayOfWeek', 'formatOptions', 'highlightedDates', 'hourCycle', 'hourValues', 'isDateEnabled', 'locale', 'max', 'min', 'minuteValues', 'mode', 'monthValues', { name: 'multiple', transform: nullableBooleanAttribute }, 'name', { name: 'preferWheel', transform: nullableBooleanAttribute }, 'presentation', { name: 'readonly', transform: nullableBooleanAttribute }, { name: 'showAdjacentDays', transform: nullableBooleanAttribute }, { name: 'showClearButton', transform: nullableBooleanAttribute }, { name: 'showDefaultButtons', transform: nullableBooleanAttribute }, { name: 'showDefaultTimeLabel', transform: nullableBooleanAttribute }, { name: 'showDefaultTitle', transform: nullableBooleanAttribute }, 'size', 'titleSelectedDatesFormatter', 'value', 'yearValues'], outputs: ['ionCancel', 'ionChange', 'ionFocus', 'ionBlur'], standalone: false }) @@ -754,7 +755,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'datetime', 'disabled', 'mode'], + inputs: ['color', 'datetime', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode'], standalone: false }) export class IonDatetimeButton { @@ -778,7 +779,7 @@ export declare interface IonDatetimeButton extends Components.IonDatetimeButton changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'edge', 'horizontal', 'vertical'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, { name: 'edge', transform: nullableBooleanAttribute }, 'horizontal', 'vertical'], standalone: false }) export class IonFab { @@ -801,7 +802,7 @@ export declare interface IonFab extends Components.IonFab {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'closeIcon', 'color', 'disabled', 'download', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'show', 'size', 'target', 'translucent', 'type'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, 'closeIcon', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', { name: 'show', transform: nullableBooleanAttribute }, 'size', 'target', { name: 'translucent', transform: nullableBooleanAttribute }, 'type'], outputs: ['ionFocus', 'ionBlur'], standalone: false }) @@ -838,7 +839,7 @@ export declare interface IonFabButton extends Components.IonFabButton { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'side'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, 'side'], standalone: false }) export class IonFabList { @@ -861,7 +862,7 @@ export declare interface IonFabList extends Components.IonFabList {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse', 'mode', 'translucent'], + inputs: ['collapse', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], standalone: false }) export class IonFooter { @@ -884,7 +885,7 @@ export declare interface IonFooter extends Components.IonFooter {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['fixed'], + inputs: [{ name: 'fixed', transform: nullableBooleanAttribute }], standalone: false }) export class IonGrid { @@ -907,7 +908,7 @@ export declare interface IonGrid extends Components.IonGrid {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse', 'mode', 'translucent'], + inputs: ['collapse', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], standalone: false }) export class IonHeader { @@ -930,7 +931,7 @@ export declare interface IonHeader extends Components.IonHeader {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'flipRtl', 'icon', 'ios', 'lazy', 'md', 'mode', 'name', 'sanitize', 'size', 'src'], + inputs: ['color', { name: 'flipRtl', transform: nullableBooleanAttribute }, 'icon', 'ios', { name: 'lazy', transform: nullableBooleanAttribute }, 'md', 'mode', 'name', { name: 'sanitize', transform: nullableBooleanAttribute }, 'size', 'src'], standalone: false }) export class IonIcon { @@ -996,7 +997,7 @@ export declare interface IonImg extends Components.IonImg { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'position', 'threshold'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'position', 'threshold'], outputs: ['ionInfinite'], standalone: false }) @@ -1055,7 +1056,7 @@ export declare interface IonInfiniteScrollContent extends Components.IonInfinite changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autocapitalize', 'autocomplete', 'autocorrect', 'autofocus', 'clearInput', 'clearInputIcon', 'clearOnEdit', 'color', 'counter', 'counterFormatter', 'debounce', 'disabled', 'enterkeyhint', 'errorText', 'fill', 'helperText', 'inputmode', 'label', 'labelPlacement', 'max', 'maxlength', 'min', 'minlength', 'mode', 'multiple', 'name', 'pattern', 'placeholder', 'readonly', 'required', 'shape', 'spellcheck', 'step', 'type', 'value'], + inputs: ['autocapitalize', 'autocomplete', { name: 'autocorrect', transform: nullableBooleanAttribute }, { name: 'autofocus', transform: nullableBooleanAttribute }, { name: 'clearInput', transform: nullableBooleanAttribute }, 'clearInputIcon', { name: 'clearOnEdit', transform: nullableBooleanAttribute }, 'color', { name: 'counter', transform: nullableBooleanAttribute }, 'counterFormatter', 'debounce', { name: 'disabled', transform: nullableBooleanAttribute }, 'enterkeyhint', 'errorText', 'fill', 'helperText', 'inputmode', 'label', 'labelPlacement', 'max', 'maxlength', 'min', 'minlength', 'mode', { name: 'multiple', transform: nullableBooleanAttribute }, 'name', 'pattern', 'placeholder', { name: 'readonly', transform: nullableBooleanAttribute }, { name: 'required', transform: nullableBooleanAttribute }, 'shape', { name: 'spellcheck', transform: nullableBooleanAttribute }, 'step', 'type', 'value'], outputs: ['ionInput', 'ionChange', 'ionBlur', 'ionFocus'], standalone: false }) @@ -1123,7 +1124,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autocapitalize', 'color', 'disabled', 'fill', 'inputmode', 'length', 'pattern', 'readonly', 'separators', 'shape', 'size', 'type', 'value'], + inputs: ['autocapitalize', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'fill', 'inputmode', 'length', 'pattern', { name: 'readonly', transform: nullableBooleanAttribute }, 'separators', 'shape', 'size', 'type', 'value'], outputs: ['ionInput', 'ionChange', 'ionComplete', 'ionBlur', 'ionFocus'], standalone: false }) @@ -1215,7 +1216,7 @@ export declare interface IonInputPasswordToggle extends Components.IonInputPassw changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['button', 'color', 'detail', 'detailIcon', 'disabled', 'download', 'href', 'lines', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], + inputs: [{ name: 'button', transform: nullableBooleanAttribute }, 'color', { name: 'detail', transform: nullableBooleanAttribute }, 'detailIcon', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'lines', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], standalone: false }) export class IonItem { @@ -1238,7 +1239,7 @@ export declare interface IonItem extends Components.IonItem {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'sticky'], + inputs: ['color', 'mode', { name: 'sticky', transform: nullableBooleanAttribute }], standalone: false }) export class IonItemDivider { @@ -1283,7 +1284,7 @@ export declare interface IonItemGroup extends Components.IonItemGroup {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'download', 'expandable', 'href', 'mode', 'rel', 'target', 'type'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', { name: 'expandable', transform: nullableBooleanAttribute }, 'href', 'mode', 'rel', 'target', 'type'], standalone: false }) export class IonItemOption { @@ -1339,7 +1340,7 @@ export declare interface IonItemOptions extends Components.IonItemOptions { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }], outputs: ['ionDrag'], standalone: false }) @@ -1395,7 +1396,7 @@ export declare interface IonLabel extends Components.IonLabel {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['inset', 'lines', 'mode'], + inputs: [{ name: 'inset', transform: nullableBooleanAttribute }, 'lines', 'mode'], standalone: false }) export class IonList { @@ -1442,7 +1443,7 @@ export declare interface IonListHeader extends Components.IonListHeader {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'cssClass', 'duration', 'enterAnimation', 'htmlAttributes', 'isOpen', 'keyboardClose', 'leaveAnimation', 'message', 'mode', 'showBackdrop', 'spinner', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'cssClass', 'duration', 'enterAnimation', 'htmlAttributes', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'message', 'mode', { name: 'showBackdrop', transform: nullableBooleanAttribute }, 'spinner', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionLoadingDidPresent', 'ionLoadingWillPresent', 'ionLoadingWillDismiss', 'ionLoadingDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], standalone: false }) @@ -1515,7 +1516,7 @@ Shorthand for ionLoadingDidDismiss. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'maxEdgeStart', 'menuId', 'side', 'swipeGesture', 'type'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'maxEdgeStart', 'menuId', 'side', { name: 'swipeGesture', transform: nullableBooleanAttribute }, 'type'], outputs: ['ionWillOpen', 'ionWillClose', 'ionDidOpen', 'ionDidClose'], standalone: false }) @@ -1563,7 +1564,7 @@ export declare interface IonMenu extends Components.IonMenu { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autoHide', 'color', 'disabled', 'menu', 'mode', 'type'], + inputs: [{ name: 'autoHide', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'menu', 'mode', 'type'], standalone: false }) export class IonMenuButton { @@ -1586,7 +1587,7 @@ export declare interface IonMenuButton extends Components.IonMenuButton {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autoHide', 'menu'], + inputs: [{ name: 'autoHide', transform: nullableBooleanAttribute }, 'menu'], standalone: false }) export class IonMenuToggle { @@ -1679,7 +1680,7 @@ export declare interface IonPicker extends Components.IonPicker {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'mode', 'value'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', 'value'], outputs: ['ionChange'], standalone: false }) @@ -1714,7 +1715,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'value'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'value'], standalone: false }) export class IonPickerColumnOption { @@ -1737,7 +1738,7 @@ export declare interface IonPickerColumnOption extends Components.IonPickerColum changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['buffer', 'color', 'mode', 'reversed', 'type', 'value'], + inputs: ['buffer', 'color', 'mode', { name: 'reversed', transform: nullableBooleanAttribute }, 'type', 'value'], standalone: false }) export class IonProgressBar { @@ -1760,7 +1761,7 @@ export declare interface IonProgressBar extends Components.IonProgressBar {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['alignment', 'color', 'disabled', 'justify', 'labelPlacement', 'mode', 'name', 'value'], + inputs: ['alignment', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'justify', 'labelPlacement', 'mode', 'name', 'value'], outputs: ['ionFocus', 'ionBlur'], standalone: false }) @@ -1797,7 +1798,7 @@ export declare interface IonRadio extends Components.IonRadio { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['allowEmptySelection', 'compareWith', 'errorText', 'helperText', 'name', 'value'], + inputs: [{ name: 'allowEmptySelection', transform: nullableBooleanAttribute }, 'compareWith', 'errorText', 'helperText', 'name', 'value'], outputs: ['ionChange'], standalone: false }) @@ -1832,7 +1833,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activeBarStart', 'color', 'debounce', 'disabled', 'dualKnobs', 'label', 'labelPlacement', 'max', 'min', 'mode', 'name', 'pin', 'pinFormatter', 'snaps', 'step', 'ticks', 'value'], + inputs: ['activeBarStart', 'color', 'debounce', { name: 'disabled', transform: nullableBooleanAttribute }, { name: 'dualKnobs', transform: nullableBooleanAttribute }, 'label', 'labelPlacement', 'max', 'min', 'mode', 'name', { name: 'pin', transform: nullableBooleanAttribute }, 'pinFormatter', { name: 'snaps', transform: nullableBooleanAttribute }, 'step', { name: 'ticks', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange', 'ionInput', 'ionFocus', 'ionBlur', 'ionKnobMoveStart', 'ionKnobMoveEnd'], standalone: false }) @@ -1902,7 +1903,7 @@ mouse drag, touch gesture, or keyboard interaction. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['closeDuration', 'disabled', 'mode', 'pullFactor', 'pullMax', 'pullMin', 'snapbackDuration'], + inputs: ['closeDuration', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', 'pullFactor', 'pullMax', 'pullMin', 'snapbackDuration'], outputs: ['ionRefresh', 'ionPull', 'ionStart', 'ionPullStart', 'ionPullEnd'], standalone: false }) @@ -2007,7 +2008,7 @@ export declare interface IonReorder extends Components.IonReorder {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }], outputs: ['ionItemReorder', 'ionReorderStart', 'ionReorderMove', 'ionReorderEnd'], standalone: false }) @@ -2112,7 +2113,7 @@ export declare interface IonRow extends Components.IonRow {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'autocapitalize', 'autocomplete', 'autocorrect', 'cancelButtonIcon', 'cancelButtonText', 'clearIcon', 'color', 'debounce', 'disabled', 'enterkeyhint', 'inputmode', 'maxlength', 'minlength', 'mode', 'name', 'placeholder', 'searchIcon', 'showCancelButton', 'showClearButton', 'spellcheck', 'type', 'value'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, 'autocapitalize', 'autocomplete', { name: 'autocorrect', transform: nullableBooleanAttribute }, 'cancelButtonIcon', 'cancelButtonText', 'clearIcon', 'color', 'debounce', { name: 'disabled', transform: nullableBooleanAttribute }, 'enterkeyhint', 'inputmode', 'maxlength', 'minlength', 'mode', 'name', 'placeholder', 'searchIcon', 'showCancelButton', 'showClearButton', { name: 'spellcheck', transform: nullableBooleanAttribute }, 'type', 'value'], outputs: ['ionInput', 'ionChange', 'ionCancel', 'ionClear', 'ionBlur', 'ionFocus'], standalone: false }) @@ -2180,7 +2181,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'mode', 'scrollable', 'selectOnFocus', 'swipeGesture', 'value'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', { name: 'scrollable', transform: nullableBooleanAttribute }, { name: 'selectOnFocus', transform: nullableBooleanAttribute }, { name: 'swipeGesture', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange'], standalone: false }) @@ -2215,7 +2216,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'layout', 'mode', 'type', 'value'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'layout', 'mode', 'type', 'value'], standalone: false }) export class IonSegmentButton { @@ -2260,7 +2261,7 @@ export declare interface IonSegmentContent extends Components.IonSegmentContent changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'swipeGesture'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, { name: 'swipeGesture', transform: nullableBooleanAttribute }], outputs: ['ionSegmentViewScroll'], standalone: false }) @@ -2294,7 +2295,7 @@ export declare interface IonSegmentView extends Components.IonSegmentView { changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cancelText', 'color', 'compareWith', 'disabled', 'errorText', 'expandedIcon', 'fill', 'helperText', 'interface', 'interfaceOptions', 'justify', 'label', 'labelPlacement', 'mode', 'multiple', 'name', 'okText', 'placeholder', 'required', 'selectedText', 'shape', 'toggleIcon', 'value'], + inputs: ['cancelText', 'color', 'compareWith', { name: 'disabled', transform: nullableBooleanAttribute }, 'errorText', 'expandedIcon', 'fill', 'helperText', 'interface', 'interfaceOptions', 'justify', 'label', 'labelPlacement', 'mode', { name: 'multiple', transform: nullableBooleanAttribute }, 'name', 'okText', 'placeholder', { name: 'required', transform: nullableBooleanAttribute }, 'selectedText', 'shape', 'toggleIcon', 'value'], outputs: ['ionChange', 'ionCancel', 'ionDismiss', 'ionFocus', 'ionBlur'], standalone: false }) @@ -2349,7 +2350,7 @@ This event will not emit when programmatically setting the `value` property. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cancelText', 'header', 'multiple', 'options'], + inputs: ['cancelText', 'header', { name: 'multiple', transform: nullableBooleanAttribute }, 'options'], standalone: false }) export class IonSelectModal { @@ -2372,7 +2373,7 @@ export declare interface IonSelectModal extends Components.IonSelectModal {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['description', 'disabled', 'justify', 'labelPlacement', 'mode', 'value'], + inputs: ['description', { name: 'disabled', transform: nullableBooleanAttribute }, 'justify', 'labelPlacement', 'mode', 'value'], standalone: false }) export class IonSelectOption { @@ -2395,7 +2396,7 @@ export declare interface IonSelectOption extends Components.IonSelectOption {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }], standalone: false }) export class IonSkeletonText { @@ -2418,7 +2419,7 @@ export declare interface IonSkeletonText extends Components.IonSkeletonText {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'duration', 'name', 'paused'], + inputs: ['color', 'duration', 'name', { name: 'paused', transform: nullableBooleanAttribute }], standalone: false }) export class IonSpinner { @@ -2441,7 +2442,7 @@ export declare interface IonSpinner extends Components.IonSpinner {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'when'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'when'], outputs: ['ionSplitPaneVisible'], standalone: false }) @@ -2497,7 +2498,7 @@ export declare interface IonTab extends Components.IonTab {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'selectedTab', 'translucent'], + inputs: ['color', 'mode', 'selectedTab', { name: 'translucent', transform: nullableBooleanAttribute }], standalone: false }) export class IonTabBar { @@ -2520,7 +2521,7 @@ export declare interface IonTabBar extends Components.IonTabBar {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'download', 'href', 'layout', 'mode', 'rel', 'selected', 'tab', 'target'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'layout', 'mode', 'rel', { name: 'selected', transform: nullableBooleanAttribute }, 'tab', 'target'], standalone: false }) export class IonTabButton { @@ -2567,7 +2568,7 @@ export declare interface IonText extends Components.IonText {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autoGrow', 'autocapitalize', 'autofocus', 'clearOnEdit', 'color', 'cols', 'counter', 'counterFormatter', 'debounce', 'disabled', 'enterkeyhint', 'errorText', 'fill', 'helperText', 'inputmode', 'label', 'labelPlacement', 'maxlength', 'minlength', 'mode', 'name', 'placeholder', 'readonly', 'required', 'rows', 'shape', 'spellcheck', 'value', 'wrap'], + inputs: [{ name: 'autoGrow', transform: nullableBooleanAttribute }, 'autocapitalize', { name: 'autofocus', transform: nullableBooleanAttribute }, { name: 'clearOnEdit', transform: nullableBooleanAttribute }, 'color', 'cols', { name: 'counter', transform: nullableBooleanAttribute }, 'counterFormatter', 'debounce', { name: 'disabled', transform: nullableBooleanAttribute }, 'enterkeyhint', 'errorText', 'fill', 'helperText', 'inputmode', 'label', 'labelPlacement', 'maxlength', 'minlength', 'mode', 'name', 'placeholder', { name: 'readonly', transform: nullableBooleanAttribute }, { name: 'required', transform: nullableBooleanAttribute }, 'rows', 'shape', { name: 'spellcheck', transform: nullableBooleanAttribute }, 'value', 'wrap'], outputs: ['ionChange', 'ionInput', 'ionBlur', 'ionFocus'], standalone: false }) @@ -2671,7 +2672,7 @@ export declare interface IonTitle extends Components.IonTitle {} changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'buttons', 'color', 'cssClass', 'duration', 'enterAnimation', 'header', 'htmlAttributes', 'icon', 'isOpen', 'keyboardClose', 'layout', 'leaveAnimation', 'message', 'mode', 'position', 'positionAnchor', 'swipeGesture', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, 'buttons', 'color', 'cssClass', 'duration', 'enterAnimation', 'header', 'htmlAttributes', 'icon', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'layout', 'leaveAnimation', 'message', 'mode', 'position', 'positionAnchor', 'swipeGesture', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionToastDidPresent', 'ionToastWillPresent', 'ionToastWillDismiss', 'ionToastDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], standalone: false }) @@ -2743,7 +2744,7 @@ Shorthand for ionToastDidDismiss. changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['alignment', 'checked', 'color', 'disabled', 'enableOnOffLabels', 'errorText', 'helperText', 'justify', 'labelPlacement', 'mode', 'name', 'required', 'value'], + inputs: ['alignment', { name: 'checked', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, { name: 'enableOnOffLabels', transform: nullableBooleanAttribute }, 'errorText', 'helperText', 'justify', 'labelPlacement', 'mode', 'name', { name: 'required', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange', 'ionFocus', 'ionBlur'], standalone: false }) diff --git a/packages/angular/src/standalone/directives/angular-component-lib/boolean-attribute.ts b/packages/angular/src/standalone/directives/angular-component-lib/boolean-attribute.ts new file mode 100644 index 00000000000..c116dd5bc7f --- /dev/null +++ b/packages/angular/src/standalone/directives/angular-component-lib/boolean-attribute.ts @@ -0,0 +1,43 @@ +/* eslint-disable */ +/* tslint:disable */ + +/** + * Transforms a value to a boolean so that boolean properties can be set by attribute presence, + * e.g. `` instead of ``. + * + * Strings are coerced the same way Angular's `booleanAttribute` coerces them, so `''` (a bare + * attribute) becomes `true` and `'false'` becomes `false`. + * + * Unlike Angular's `booleanAttribute`, `null` and `undefined` are passed through rather than + * coerced to `false`. Components frequently treat them as a state distinct from `false`: + * + * ```tsx + * // `undefined` means "decide based on the mode", which is not the same as `false` + * const showDetail = detail !== undefined ? detail : mode === 'ios'; + * + * // a strict comparison also behaves differently for `null` than it does for `false` + * const showHandle = handle !== false; + * ``` + * + * Both values reach inputs routinely in Angular templates, from the `async` pipe before its + * first emission and from form control values, so coercing them would change the behavior of + * bindings that work today. + * + * This is implemented here rather than imported from `@angular/core` so that consumers on + * Angular versions without `booleanAttribute` are unaffected by this file being generated. + * + * The parameter type is what Angular derives `ngAcceptInputType_*` from, so it decides which + * template bindings compile. Widening it to `unknown` would let any expression through. + * + * Declared as a function rather than an arrow constant because Angular has to resolve input + * transforms statically when compiling a library in partial compilation mode. + * + * This lives in its own file, separate from `utils.ts`, so that it carries no runtime imports. + * That keeps it independently type-checkable without pulling `rxjs` in for `proxyOutputs`. + */ +export function nullableBooleanAttribute(value: boolean | string | null | undefined): boolean | null | undefined { + if (value === null || value === undefined) { + return value; + } + return typeof value === 'boolean' ? value : value !== 'false'; +} diff --git a/packages/angular/src/standalone/directives/ion-accordion-group.ts b/packages/angular/src/standalone/directives/ion-accordion-group.ts index f082fe2cf19..3b9e916ad26 100644 --- a/packages/angular/src/standalone/directives/ion-accordion-group.ts +++ b/packages/angular/src/standalone/directives/ion-accordion-group.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonAccordionGroup } from '@ionic/core/comp changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'disabled', 'expand', 'mode', 'multiple', 'readonly', 'value'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'disabled', transform: nullableBooleanAttribute }, 'expand', 'mode', { name: 'multiple', transform: nullableBooleanAttribute }, { name: 'readonly', transform: nullableBooleanAttribute }, 'value'], outputs: ['ionChange'], }) export class IonAccordionGroup { diff --git a/packages/angular/src/standalone/directives/ion-accordion.ts b/packages/angular/src/standalone/directives/ion-accordion.ts index 9a55d3b8448..45cc18fb387 100644 --- a/packages/angular/src/standalone/directives/ion-accordion.ts +++ b/packages/angular/src/standalone/directives/ion-accordion.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonAccordion } from '@ionic/core/component changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'mode', 'readonly', 'toggleIcon', 'toggleIconSlot', 'value'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'mode', { name: 'readonly', transform: nullableBooleanAttribute }, 'toggleIcon', 'toggleIconSlot', 'value'], }) export class IonAccordion { protected el: HTMLIonAccordionElement; diff --git a/packages/angular/src/standalone/directives/ion-action-sheet.ts b/packages/angular/src/standalone/directives/ion-action-sheet.ts index 6975717048f..d999ce35d0c 100644 --- a/packages/angular/src/standalone/directives/ion-action-sheet.ts +++ b/packages/angular/src/standalone/directives/ion-action-sheet.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonActionSheet } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'isOpen', 'keyboardClose', 'leaveAnimation', 'mode', 'subHeader', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'mode', 'subHeader', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionActionSheetDidPresent', 'ionActionSheetWillPresent', 'ionActionSheetWillDismiss', 'ionActionSheetDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], }) export class IonActionSheet { diff --git a/packages/angular/src/standalone/directives/ion-alert.ts b/packages/angular/src/standalone/directives/ion-alert.ts index 72239b3b07d..b04585eadb5 100644 --- a/packages/angular/src/standalone/directives/ion-alert.ts +++ b/packages/angular/src/standalone/directives/ion-alert.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonAlert } from '@ionic/core/components/io changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'inputs', 'isOpen', 'keyboardClose', 'leaveAnimation', 'message', 'mode', 'subHeader', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'buttons', 'cssClass', 'enterAnimation', 'header', 'htmlAttributes', 'inputs', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'message', 'mode', 'subHeader', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionAlertDidPresent', 'ionAlertWillPresent', 'ionAlertWillDismiss', 'ionAlertDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], }) export class IonAlert { diff --git a/packages/angular/src/standalone/directives/ion-backdrop.ts b/packages/angular/src/standalone/directives/ion-backdrop.ts index 5fc957f232f..9d99000ac0b 100644 --- a/packages/angular/src/standalone/directives/ion-backdrop.ts +++ b/packages/angular/src/standalone/directives/ion-backdrop.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonBackdrop } from '@ionic/core/components changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['stopPropagation', 'tappable', 'visible'], + inputs: [{ name: 'stopPropagation', transform: nullableBooleanAttribute }, { name: 'tappable', transform: nullableBooleanAttribute }, { name: 'visible', transform: nullableBooleanAttribute }], outputs: ['ionBackdropTap'], }) export class IonBackdrop { diff --git a/packages/angular/src/standalone/directives/ion-breadcrumb.ts b/packages/angular/src/standalone/directives/ion-breadcrumb.ts index a63a99392be..9c5c4967147 100644 --- a/packages/angular/src/standalone/directives/ion-breadcrumb.ts +++ b/packages/angular/src/standalone/directives/ion-breadcrumb.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonBreadcrumb } from '@ionic/core/componen changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['active', 'color', 'disabled', 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'separator', 'target'], + inputs: [{ name: 'active', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', { name: 'separator', transform: nullableBooleanAttribute }, 'target'], outputs: ['ionFocus', 'ionBlur'], }) export class IonBreadcrumb { diff --git a/packages/angular/src/standalone/directives/ion-button.ts b/packages/angular/src/standalone/directives/ion-button.ts index b5a69a48884..3e2d0a4c863 100644 --- a/packages/angular/src/standalone/directives/ion-button.ts +++ b/packages/angular/src/standalone/directives/ion-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonButton } from '@ionic/core/components/i changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['buttonType', 'color', 'disabled', 'download', 'expand', 'fill', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'shape', 'size', 'strong', 'target', 'type'], + inputs: ['buttonType', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'expand', 'fill', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'shape', 'size', { name: 'strong', transform: nullableBooleanAttribute }, 'target', 'type'], outputs: ['ionFocus', 'ionBlur'], }) export class IonButton { diff --git a/packages/angular/src/standalone/directives/ion-buttons.ts b/packages/angular/src/standalone/directives/ion-buttons.ts index 6adfbbbba24..23eaacbc51f 100644 --- a/packages/angular/src/standalone/directives/ion-buttons.ts +++ b/packages/angular/src/standalone/directives/ion-buttons.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonButtons } from '@ionic/core/components/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse'], + inputs: [{ name: 'collapse', transform: nullableBooleanAttribute }], }) export class IonButtons { protected el: HTMLIonButtonsElement; diff --git a/packages/angular/src/standalone/directives/ion-card-header.ts b/packages/angular/src/standalone/directives/ion-card-header.ts index f9d071e5aa6..fbedac5c4cd 100644 --- a/packages/angular/src/standalone/directives/ion-card-header.ts +++ b/packages/angular/src/standalone/directives/ion-card-header.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonCardHeader } from '@ionic/core/componen changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'translucent'], + inputs: ['color', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], }) export class IonCardHeader { protected el: HTMLIonCardHeaderElement; diff --git a/packages/angular/src/standalone/directives/ion-card.ts b/packages/angular/src/standalone/directives/ion-card.ts index 1ac6acc186a..2a138ce3ac7 100644 --- a/packages/angular/src/standalone/directives/ion-card.ts +++ b/packages/angular/src/standalone/directives/ion-card.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonCard } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['button', 'color', 'disabled', 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], + inputs: [{ name: 'button', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], }) export class IonCard { protected el: HTMLIonCardElement; diff --git a/packages/angular/src/standalone/directives/ion-chip.ts b/packages/angular/src/standalone/directives/ion-chip.ts index 43a2aae4a7f..602856e125a 100644 --- a/packages/angular/src/standalone/directives/ion-chip.ts +++ b/packages/angular/src/standalone/directives/ion-chip.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonChip } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'mode', 'outline'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', { name: 'outline', transform: nullableBooleanAttribute }], }) export class IonChip { protected el: HTMLIonChipElement; diff --git a/packages/angular/src/standalone/directives/ion-content.ts b/packages/angular/src/standalone/directives/ion-content.ts index 7bbe92db0af..f46f69331c5 100644 --- a/packages/angular/src/standalone/directives/ion-content.ts +++ b/packages/angular/src/standalone/directives/ion-content.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonContent } from '@ionic/core/components/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'fixedSlotPlacement', 'forceOverscroll', 'fullscreen', 'scrollEvents', 'scrollX', 'scrollY'], + inputs: ['color', 'fixedSlotPlacement', { name: 'forceOverscroll', transform: nullableBooleanAttribute }, { name: 'fullscreen', transform: nullableBooleanAttribute }, { name: 'scrollEvents', transform: nullableBooleanAttribute }, { name: 'scrollX', transform: nullableBooleanAttribute }, { name: 'scrollY', transform: nullableBooleanAttribute }], outputs: ['ionScrollStart', 'ionScroll', 'ionScrollEnd'], }) export class IonContent { diff --git a/packages/angular/src/standalone/directives/ion-datetime-button.ts b/packages/angular/src/standalone/directives/ion-datetime-button.ts index 2e14c977f3b..22256cd9198 100644 --- a/packages/angular/src/standalone/directives/ion-datetime-button.ts +++ b/packages/angular/src/standalone/directives/ion-datetime-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonDatetimeButton } from '@ionic/core/comp changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'datetime', 'disabled', 'mode'], + inputs: ['color', 'datetime', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode'], }) export class IonDatetimeButton { protected el: HTMLIonDatetimeButtonElement; diff --git a/packages/angular/src/standalone/directives/ion-fab-button.ts b/packages/angular/src/standalone/directives/ion-fab-button.ts index 6ebe1777354..63767a545fa 100644 --- a/packages/angular/src/standalone/directives/ion-fab-button.ts +++ b/packages/angular/src/standalone/directives/ion-fab-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonFabButton } from '@ionic/core/component changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'closeIcon', 'color', 'disabled', 'download', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'show', 'size', 'target', 'translucent', 'type'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, 'closeIcon', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'form', 'href', 'mode', 'rel', 'routerAnimation', 'routerDirection', { name: 'show', transform: nullableBooleanAttribute }, 'size', 'target', { name: 'translucent', transform: nullableBooleanAttribute }, 'type'], outputs: ['ionFocus', 'ionBlur'], }) export class IonFabButton { diff --git a/packages/angular/src/standalone/directives/ion-fab-list.ts b/packages/angular/src/standalone/directives/ion-fab-list.ts index 2e2860c1a0a..f5fc979559e 100644 --- a/packages/angular/src/standalone/directives/ion-fab-list.ts +++ b/packages/angular/src/standalone/directives/ion-fab-list.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonFabList } from '@ionic/core/components/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'side'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, 'side'], }) export class IonFabList { protected el: HTMLIonFabListElement; diff --git a/packages/angular/src/standalone/directives/ion-fab.ts b/packages/angular/src/standalone/directives/ion-fab.ts index 94f45f9116d..ea76498a5ab 100644 --- a/packages/angular/src/standalone/directives/ion-fab.ts +++ b/packages/angular/src/standalone/directives/ion-fab.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonFab } from '@ionic/core/components/ion- changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['activated', 'edge', 'horizontal', 'vertical'], + inputs: [{ name: 'activated', transform: nullableBooleanAttribute }, { name: 'edge', transform: nullableBooleanAttribute }, 'horizontal', 'vertical'], }) export class IonFab { protected el: HTMLIonFabElement; diff --git a/packages/angular/src/standalone/directives/ion-footer.ts b/packages/angular/src/standalone/directives/ion-footer.ts index 3e33198b165..14771c7da44 100644 --- a/packages/angular/src/standalone/directives/ion-footer.ts +++ b/packages/angular/src/standalone/directives/ion-footer.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonFooter } from '@ionic/core/components/i changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse', 'mode', 'translucent'], + inputs: ['collapse', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], }) export class IonFooter { protected el: HTMLIonFooterElement; diff --git a/packages/angular/src/standalone/directives/ion-grid.ts b/packages/angular/src/standalone/directives/ion-grid.ts index 1c5c874ff7e..094d788ce99 100644 --- a/packages/angular/src/standalone/directives/ion-grid.ts +++ b/packages/angular/src/standalone/directives/ion-grid.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonGrid } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['fixed'], + inputs: [{ name: 'fixed', transform: nullableBooleanAttribute }], }) export class IonGrid { protected el: HTMLIonGridElement; diff --git a/packages/angular/src/standalone/directives/ion-header.ts b/packages/angular/src/standalone/directives/ion-header.ts index 929416d8c22..937d460aae9 100644 --- a/packages/angular/src/standalone/directives/ion-header.ts +++ b/packages/angular/src/standalone/directives/ion-header.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonHeader } from '@ionic/core/components/i changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['collapse', 'mode', 'translucent'], + inputs: ['collapse', 'mode', { name: 'translucent', transform: nullableBooleanAttribute }], }) export class IonHeader { protected el: HTMLIonHeaderElement; diff --git a/packages/angular/src/standalone/directives/ion-infinite-scroll.ts b/packages/angular/src/standalone/directives/ion-infinite-scroll.ts index e9ae34c3e3c..e73f03ef561 100644 --- a/packages/angular/src/standalone/directives/ion-infinite-scroll.ts +++ b/packages/angular/src/standalone/directives/ion-infinite-scroll.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonInfiniteScroll } from '@ionic/core/comp changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'position', 'threshold'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'position', 'threshold'], outputs: ['ionInfinite'], }) export class IonInfiniteScroll { diff --git a/packages/angular/src/standalone/directives/ion-item-divider.ts b/packages/angular/src/standalone/directives/ion-item-divider.ts index 04697dda2ba..e411d65cacd 100644 --- a/packages/angular/src/standalone/directives/ion-item-divider.ts +++ b/packages/angular/src/standalone/directives/ion-item-divider.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonItemDivider } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'sticky'], + inputs: ['color', 'mode', { name: 'sticky', transform: nullableBooleanAttribute }], }) export class IonItemDivider { protected el: HTMLIonItemDividerElement; diff --git a/packages/angular/src/standalone/directives/ion-item-option.ts b/packages/angular/src/standalone/directives/ion-item-option.ts index f531f1a1bdf..ffd4f948950 100644 --- a/packages/angular/src/standalone/directives/ion-item-option.ts +++ b/packages/angular/src/standalone/directives/ion-item-option.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonItemOption } from '@ionic/core/componen changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'download', 'expandable', 'href', 'mode', 'rel', 'target', 'type'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', { name: 'expandable', transform: nullableBooleanAttribute }, 'href', 'mode', 'rel', 'target', 'type'], }) export class IonItemOption { protected el: HTMLIonItemOptionElement; diff --git a/packages/angular/src/standalone/directives/ion-item-sliding.ts b/packages/angular/src/standalone/directives/ion-item-sliding.ts index 766083b51fc..1f10395630f 100644 --- a/packages/angular/src/standalone/directives/ion-item-sliding.ts +++ b/packages/angular/src/standalone/directives/ion-item-sliding.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonItemSliding } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }], outputs: ['ionDrag'], }) export class IonItemSliding { diff --git a/packages/angular/src/standalone/directives/ion-item.ts b/packages/angular/src/standalone/directives/ion-item.ts index 97133751055..53e0855e702 100644 --- a/packages/angular/src/standalone/directives/ion-item.ts +++ b/packages/angular/src/standalone/directives/ion-item.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonItem } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['button', 'color', 'detail', 'detailIcon', 'disabled', 'download', 'href', 'lines', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], + inputs: [{ name: 'button', transform: nullableBooleanAttribute }, 'color', { name: 'detail', transform: nullableBooleanAttribute }, 'detailIcon', { name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'lines', 'mode', 'rel', 'routerAnimation', 'routerDirection', 'target', 'type'], }) export class IonItem { protected el: HTMLIonItemElement; diff --git a/packages/angular/src/standalone/directives/ion-list.ts b/packages/angular/src/standalone/directives/ion-list.ts index 51d411f640f..8a2b8453d9e 100644 --- a/packages/angular/src/standalone/directives/ion-list.ts +++ b/packages/angular/src/standalone/directives/ion-list.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonList } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['inset', 'lines', 'mode'], + inputs: [{ name: 'inset', transform: nullableBooleanAttribute }, 'lines', 'mode'], }) export class IonList { protected el: HTMLIonListElement; diff --git a/packages/angular/src/standalone/directives/ion-loading.ts b/packages/angular/src/standalone/directives/ion-loading.ts index 3ba00b3cbb6..6cb99fd08f6 100644 --- a/packages/angular/src/standalone/directives/ion-loading.ts +++ b/packages/angular/src/standalone/directives/ion-loading.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonLoading } from '@ionic/core/components/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'backdropDismiss', 'cssClass', 'duration', 'enterAnimation', 'htmlAttributes', 'isOpen', 'keyboardClose', 'leaveAnimation', 'message', 'mode', 'showBackdrop', 'spinner', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, { name: 'backdropDismiss', transform: nullableBooleanAttribute }, 'cssClass', 'duration', 'enterAnimation', 'htmlAttributes', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'leaveAnimation', 'message', 'mode', { name: 'showBackdrop', transform: nullableBooleanAttribute }, 'spinner', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionLoadingDidPresent', 'ionLoadingWillPresent', 'ionLoadingWillDismiss', 'ionLoadingDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], }) export class IonLoading { diff --git a/packages/angular/src/standalone/directives/ion-menu-button.ts b/packages/angular/src/standalone/directives/ion-menu-button.ts index 344525e00d9..bd6e537511f 100644 --- a/packages/angular/src/standalone/directives/ion-menu-button.ts +++ b/packages/angular/src/standalone/directives/ion-menu-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonMenuButton } from '@ionic/core/componen changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autoHide', 'color', 'disabled', 'menu', 'mode', 'type'], + inputs: [{ name: 'autoHide', transform: nullableBooleanAttribute }, 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'menu', 'mode', 'type'], }) export class IonMenuButton { protected el: HTMLIonMenuButtonElement; diff --git a/packages/angular/src/standalone/directives/ion-menu-toggle.ts b/packages/angular/src/standalone/directives/ion-menu-toggle.ts index 641491fbb06..a30b31166da 100644 --- a/packages/angular/src/standalone/directives/ion-menu-toggle.ts +++ b/packages/angular/src/standalone/directives/ion-menu-toggle.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonMenuToggle } from '@ionic/core/componen changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['autoHide', 'menu'], + inputs: [{ name: 'autoHide', transform: nullableBooleanAttribute }, 'menu'], }) export class IonMenuToggle { protected el: HTMLIonMenuToggleElement; diff --git a/packages/angular/src/standalone/directives/ion-menu.ts b/packages/angular/src/standalone/directives/ion-menu.ts index d56b082450c..3c7526f7fc0 100644 --- a/packages/angular/src/standalone/directives/ion-menu.ts +++ b/packages/angular/src/standalone/directives/ion-menu.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonMenu } from '@ionic/core/components/ion changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'maxEdgeStart', 'menuId', 'side', 'swipeGesture', 'type'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'maxEdgeStart', 'menuId', 'side', { name: 'swipeGesture', transform: nullableBooleanAttribute }, 'type'], outputs: ['ionWillOpen', 'ionWillClose', 'ionDidOpen', 'ionDidClose'], }) export class IonMenu { diff --git a/packages/angular/src/standalone/directives/ion-picker-column-option.ts b/packages/angular/src/standalone/directives/ion-picker-column-option.ts index 2c42d4af17e..befe7f49876 100644 --- a/packages/angular/src/standalone/directives/ion-picker-column-option.ts +++ b/packages/angular/src/standalone/directives/ion-picker-column-option.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonPickerColumnOption } from '@ionic/core/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'value'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'value'], }) export class IonPickerColumnOption { protected el: HTMLIonPickerColumnOptionElement; diff --git a/packages/angular/src/standalone/directives/ion-picker-column.ts b/packages/angular/src/standalone/directives/ion-picker-column.ts index 48d621c975e..bc9b858e365 100644 --- a/packages/angular/src/standalone/directives/ion-picker-column.ts +++ b/packages/angular/src/standalone/directives/ion-picker-column.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonPickerColumn } from '@ionic/core/compon changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'disabled', 'mode', 'value'], + inputs: ['color', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', 'value'], outputs: ['ionChange'], }) export class IonPickerColumn { diff --git a/packages/angular/src/standalone/directives/ion-progress-bar.ts b/packages/angular/src/standalone/directives/ion-progress-bar.ts index 305a35529e8..29e2e32e993 100644 --- a/packages/angular/src/standalone/directives/ion-progress-bar.ts +++ b/packages/angular/src/standalone/directives/ion-progress-bar.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonProgressBar } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['buffer', 'color', 'mode', 'reversed', 'type', 'value'], + inputs: ['buffer', 'color', 'mode', { name: 'reversed', transform: nullableBooleanAttribute }, 'type', 'value'], }) export class IonProgressBar { protected el: HTMLIonProgressBarElement; diff --git a/packages/angular/src/standalone/directives/ion-radio.ts b/packages/angular/src/standalone/directives/ion-radio.ts index 60459663ff8..b028d539cbc 100644 --- a/packages/angular/src/standalone/directives/ion-radio.ts +++ b/packages/angular/src/standalone/directives/ion-radio.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonRadio } from '@ionic/core/components/io changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['alignment', 'color', 'disabled', 'justify', 'labelPlacement', 'mode', 'name', 'value'], + inputs: ['alignment', 'color', { name: 'disabled', transform: nullableBooleanAttribute }, 'justify', 'labelPlacement', 'mode', 'name', 'value'], outputs: ['ionFocus', 'ionBlur'], }) export class IonRadio { diff --git a/packages/angular/src/standalone/directives/ion-refresher.ts b/packages/angular/src/standalone/directives/ion-refresher.ts index 006c62683f7..e402002c5eb 100644 --- a/packages/angular/src/standalone/directives/ion-refresher.ts +++ b/packages/angular/src/standalone/directives/ion-refresher.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonRefresher } from '@ionic/core/component changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['closeDuration', 'disabled', 'mode', 'pullFactor', 'pullMax', 'pullMin', 'snapbackDuration'], + inputs: ['closeDuration', { name: 'disabled', transform: nullableBooleanAttribute }, 'mode', 'pullFactor', 'pullMax', 'pullMin', 'snapbackDuration'], outputs: ['ionRefresh', 'ionPull', 'ionStart', 'ionPullStart', 'ionPullEnd'], }) export class IonRefresher { diff --git a/packages/angular/src/standalone/directives/ion-reorder-group.ts b/packages/angular/src/standalone/directives/ion-reorder-group.ts index ee5757911f2..cecd0ec7989 100644 --- a/packages/angular/src/standalone/directives/ion-reorder-group.ts +++ b/packages/angular/src/standalone/directives/ion-reorder-group.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonReorderGroup } from '@ionic/core/compon changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }], outputs: ['ionItemReorder', 'ionReorderStart', 'ionReorderMove', 'ionReorderEnd'], }) export class IonReorderGroup { diff --git a/packages/angular/src/standalone/directives/ion-segment-button.ts b/packages/angular/src/standalone/directives/ion-segment-button.ts index daf64edee94..a1a1871759d 100644 --- a/packages/angular/src/standalone/directives/ion-segment-button.ts +++ b/packages/angular/src/standalone/directives/ion-segment-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSegmentButton } from '@ionic/core/compo changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'layout', 'mode', 'type', 'value'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'layout', 'mode', 'type', 'value'], }) export class IonSegmentButton { protected el: HTMLIonSegmentButtonElement; diff --git a/packages/angular/src/standalone/directives/ion-segment-view.ts b/packages/angular/src/standalone/directives/ion-segment-view.ts index 0ac2736ef37..cd4c898fce6 100644 --- a/packages/angular/src/standalone/directives/ion-segment-view.ts +++ b/packages/angular/src/standalone/directives/ion-segment-view.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSegmentView } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'swipeGesture'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, { name: 'swipeGesture', transform: nullableBooleanAttribute }], outputs: ['ionSegmentViewScroll'], }) export class IonSegmentView { diff --git a/packages/angular/src/standalone/directives/ion-select-modal.ts b/packages/angular/src/standalone/directives/ion-select-modal.ts index bc3336a0287..40311750979 100644 --- a/packages/angular/src/standalone/directives/ion-select-modal.ts +++ b/packages/angular/src/standalone/directives/ion-select-modal.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSelectModal } from '@ionic/core/compone changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['cancelText', 'header', 'multiple', 'options'], + inputs: ['cancelText', 'header', { name: 'multiple', transform: nullableBooleanAttribute }, 'options'], }) export class IonSelectModal { protected el: HTMLIonSelectModalElement; diff --git a/packages/angular/src/standalone/directives/ion-select-option.ts b/packages/angular/src/standalone/directives/ion-select-option.ts index d7696e4117f..4d504d903ef 100644 --- a/packages/angular/src/standalone/directives/ion-select-option.ts +++ b/packages/angular/src/standalone/directives/ion-select-option.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSelectOption } from '@ionic/core/compon changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['description', 'disabled', 'justify', 'labelPlacement', 'mode', 'value'], + inputs: ['description', { name: 'disabled', transform: nullableBooleanAttribute }, 'justify', 'labelPlacement', 'mode', 'value'], }) export class IonSelectOption { protected el: HTMLIonSelectOptionElement; diff --git a/packages/angular/src/standalone/directives/ion-skeleton-text.ts b/packages/angular/src/standalone/directives/ion-skeleton-text.ts index c6b32a4a82f..803ba3ac483 100644 --- a/packages/angular/src/standalone/directives/ion-skeleton-text.ts +++ b/packages/angular/src/standalone/directives/ion-skeleton-text.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSkeletonText } from '@ionic/core/compon changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }], }) export class IonSkeletonText { protected el: HTMLIonSkeletonTextElement; diff --git a/packages/angular/src/standalone/directives/ion-spinner.ts b/packages/angular/src/standalone/directives/ion-spinner.ts index 25f54aba4ad..fc95f438daa 100644 --- a/packages/angular/src/standalone/directives/ion-spinner.ts +++ b/packages/angular/src/standalone/directives/ion-spinner.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSpinner } from '@ionic/core/components/ changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'duration', 'name', 'paused'], + inputs: ['color', 'duration', 'name', { name: 'paused', transform: nullableBooleanAttribute }], }) export class IonSpinner { protected el: HTMLIonSpinnerElement; diff --git a/packages/angular/src/standalone/directives/ion-split-pane.ts b/packages/angular/src/standalone/directives/ion-split-pane.ts index 37c4eaad7ea..dde92fcf5ac 100644 --- a/packages/angular/src/standalone/directives/ion-split-pane.ts +++ b/packages/angular/src/standalone/directives/ion-split-pane.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonSplitPane } from '@ionic/core/component changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['contentId', 'disabled', 'when'], + inputs: ['contentId', { name: 'disabled', transform: nullableBooleanAttribute }, 'when'], outputs: ['ionSplitPaneVisible'], }) export class IonSplitPane { diff --git a/packages/angular/src/standalone/directives/ion-tab-bar.ts b/packages/angular/src/standalone/directives/ion-tab-bar.ts index bcd6a4cc2c1..cf016aff7de 100644 --- a/packages/angular/src/standalone/directives/ion-tab-bar.ts +++ b/packages/angular/src/standalone/directives/ion-tab-bar.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonTabBar } from '@ionic/core/components/i changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['color', 'mode', 'selectedTab', 'translucent'], + inputs: ['color', 'mode', 'selectedTab', { name: 'translucent', transform: nullableBooleanAttribute }], }) export class IonTabBar { protected el: HTMLIonTabBarElement; diff --git a/packages/angular/src/standalone/directives/ion-tab-button.ts b/packages/angular/src/standalone/directives/ion-tab-button.ts index 5c0eaf0d8e0..8d217fb05d7 100644 --- a/packages/angular/src/standalone/directives/ion-tab-button.ts +++ b/packages/angular/src/standalone/directives/ion-tab-button.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -17,7 +18,7 @@ import { defineCustomElement as defineIonTabButton } from '@ionic/core/component changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['disabled', 'download', 'href', 'layout', 'mode', 'rel', 'selected', 'tab', 'target'], + inputs: [{ name: 'disabled', transform: nullableBooleanAttribute }, 'download', 'href', 'layout', 'mode', 'rel', { name: 'selected', transform: nullableBooleanAttribute }, 'tab', 'target'], }) export class IonTabButton { protected el: HTMLIonTabButtonElement; diff --git a/packages/angular/src/standalone/directives/ion-toast.ts b/packages/angular/src/standalone/directives/ion-toast.ts index cf714875a3e..a3cf9147a81 100644 --- a/packages/angular/src/standalone/directives/ion-toast.ts +++ b/packages/angular/src/standalone/directives/ion-toast.ts @@ -3,6 +3,7 @@ import { ChangeDetectionStrategy, ChangeDetectorRef, Component, ElementRef, NgZone, EventEmitter, Output } from '@angular/core'; import { ProxyCmp } from './angular-component-lib/utils'; +import { nullableBooleanAttribute } from './angular-component-lib/boolean-attribute'; import type { Components } from '@ionic/core/components'; @@ -18,7 +19,7 @@ import { defineCustomElement as defineIonToast } from '@ionic/core/components/io changeDetection: ChangeDetectionStrategy.OnPush, template: '', // eslint-disable-next-line @angular-eslint/no-inputs-metadata-property - inputs: ['animated', 'buttons', 'color', 'cssClass', 'duration', 'enterAnimation', 'header', 'htmlAttributes', 'icon', 'isOpen', 'keyboardClose', 'layout', 'leaveAnimation', 'message', 'mode', 'position', 'positionAnchor', 'swipeGesture', 'translucent', 'trigger'], + inputs: [{ name: 'animated', transform: nullableBooleanAttribute }, 'buttons', 'color', 'cssClass', 'duration', 'enterAnimation', 'header', 'htmlAttributes', 'icon', { name: 'isOpen', transform: nullableBooleanAttribute }, { name: 'keyboardClose', transform: nullableBooleanAttribute }, 'layout', 'leaveAnimation', 'message', 'mode', 'position', 'positionAnchor', 'swipeGesture', { name: 'translucent', transform: nullableBooleanAttribute }, 'trigger'], outputs: ['ionToastDidPresent', 'ionToastWillPresent', 'ionToastWillDismiss', 'ionToastDidDismiss', 'didPresent', 'willPresent', 'willDismiss', 'didDismiss'], }) export class IonToast {