chore: build & lint

This commit is contained in:
Brandy Smith
2025-07-02 13:32:26 -04:00
parent f1dc0b2b06
commit cb7436f051
4 changed files with 659 additions and 72 deletions

File diff suppressed because it is too large Load Diff

View File

@ -41,7 +41,9 @@ export const startFocusVisible = (rootEl?: HTMLElement): FocusVisibleUtility =>
if (ev instanceof PointerEvent && ev.pointerType !== '') {
hadPointerEvent = true;
// Reset after the event loop so only the immediate focusin is suppressed
setTimeout(() => { hadPointerEvent = false; }, 0);
setTimeout(() => {
hadPointerEvent = false;
}, 0);
}
};
@ -61,9 +63,9 @@ export const startFocusVisible = (rootEl?: HTMLElement): FocusVisibleUtility =>
const onFocusin = (ev: Event) => {
const target = ev.target as HTMLElement;
if (target.classList.contains(ION_FOCUSABLE) && !hadPointerEvent) {
const toFocus = ev.composedPath().filter((el): el is HTMLElement =>
el instanceof HTMLElement && el.classList.contains(ION_FOCUSABLE)
);
const toFocus = ev
.composedPath()
.filter((el): el is HTMLElement => el instanceof HTMLElement && el.classList.contains(ION_FOCUSABLE));
setFocus(toFocus);
}
};

View File

@ -36,7 +36,6 @@ import { defineCustomElement as defineIonHeader } from '@ionic/core/components/i
import { defineCustomElement as defineIonImg } from '@ionic/core/components/ion-img.js';
import { defineCustomElement as defineIonInfiniteScroll } from '@ionic/core/components/ion-infinite-scroll.js';
import { defineCustomElement as defineIonInfiniteScrollContent } from '@ionic/core/components/ion-infinite-scroll-content.js';
import { defineCustomElement as defineIonInputOtp } from '@ionic/core/components/ion-input-otp.js';
import { defineCustomElement as defineIonInputPasswordToggle } from '@ionic/core/components/ion-input-password-toggle.js';
import { defineCustomElement as defineIonItem } from '@ionic/core/components/ion-item.js';
import { defineCustomElement as defineIonItemDivider } from '@ionic/core/components/ion-item-divider.js';
@ -982,71 +981,6 @@ export class IonInfiniteScrollContent {
export declare interface IonInfiniteScrollContent extends Components.IonInfiniteScrollContent {}
@ProxyCmp({
defineCustomElementFn: defineIonInputOtp,
inputs: ['autocapitalize', 'color', 'disabled', 'fill', 'inputmode', 'length', 'pattern', 'readonly', 'separators', 'shape', 'size', 'type', 'value'],
methods: ['setFocus']
})
@Component({
selector: 'ion-input-otp',
changeDetection: ChangeDetectionStrategy.OnPush,
template: '<ng-content></ng-content>',
// eslint-disable-next-line @angular-eslint/no-inputs-metadata-property
inputs: ['autocapitalize', 'color', 'disabled', 'fill', 'inputmode', 'length', 'pattern', 'readonly', 'separators', 'shape', 'size', 'type', 'value'],
standalone: true
})
export class IonInputOtp {
protected el: HTMLIonInputOtpElement;
constructor(c: ChangeDetectorRef, r: ElementRef, protected z: NgZone) {
c.detach();
this.el = r.nativeElement;
proxyOutputs(this, this.el, ['ionInput', 'ionChange', 'ionComplete', 'ionBlur', 'ionFocus']);
}
}
import type { InputOtpInputEventDetail as IIonInputOtpInputOtpInputEventDetail } from '@ionic/core/components';
import type { InputOtpChangeEventDetail as IIonInputOtpInputOtpChangeEventDetail } from '@ionic/core/components';
import type { InputOtpCompleteEventDetail as IIonInputOtpInputOtpCompleteEventDetail } from '@ionic/core/components';
export declare interface IonInputOtp extends Components.IonInputOtp {
/**
* The `ionInput` event is fired each time the user modifies the input's value.
Unlike the `ionChange` event, the `ionInput` event is fired for each alteration
to the input's value. This typically happens for each keystroke as the user types.
For elements that accept text input (`type=text`, `type=tel`, etc.), the interface
is [`InputEvent`](https://developer.mozilla.org/en-US/docs/Web/API/InputEvent); for others,
the interface is [`Event`](https://developer.mozilla.org/en-US/docs/Web/API/Event). If
the input is cleared on edit, the type is `null`.
*/
ionInput: EventEmitter<CustomEvent<IIonInputOtpInputOtpInputEventDetail>>;
/**
* The `ionChange` event is fired when the user modifies the input's value.
Unlike the `ionInput` event, the `ionChange` event is only fired when changes
are committed, not as the user types.
The `ionChange` event fires when the `<ion-input-otp>` component loses
focus after its value has changed.
This event will not emit when programmatically setting the `value` property.
*/
ionChange: EventEmitter<CustomEvent<IIonInputOtpInputOtpChangeEventDetail>>;
/**
* Emitted when all input boxes have been filled with valid values.
*/
ionComplete: EventEmitter<CustomEvent<IIonInputOtpInputOtpCompleteEventDetail>>;
/**
* Emitted when the input group loses focus.
*/
ionBlur: EventEmitter<CustomEvent<FocusEvent>>;
/**
* Emitted when the input group has focus.
*/
ionFocus: EventEmitter<CustomEvent<FocusEvent>>;
}
@ProxyCmp({
defineCustomElementFn: defineIonInputPasswordToggle,
inputs: ['color', 'hideIcon', 'mode', 'showIcon']

View File

@ -492,7 +492,7 @@ export const IonInput: StencilVueComponent<JSX.IonInput, JSX.IonInput["value"]>
'value', 'ion-input');
export const IonInputOtp: StencilVueComponent<JSX.IonInputOtp> = /*@__PURE__*/ defineContainer<JSX.IonInputOtp>('ion-input-otp', defineIonInputOtp, [
export const IonInputOtp: StencilVueComponent<JSX.IonInputOtp, JSX.IonInputOtp["value"]> = /*@__PURE__*/ defineContainer<JSX.IonInputOtp, JSX.IonInputOtp["value"]>('ion-input-otp', defineIonInputOtp, [
'autocapitalize',
'color',
'disabled',
@ -517,7 +517,8 @@ export const IonInputOtp: StencilVueComponent<JSX.IonInputOtp> = /*@__PURE__*/ d
'ionComplete',
'ionBlur',
'ionFocus'
]);
],
'value', 'ion-input');
export const IonInputPasswordToggle: StencilVueComponent<JSX.IonInputPasswordToggle> = /*@__PURE__*/ defineContainer<JSX.IonInputPasswordToggle>('ion-input-password-toggle', defineIonInputPasswordToggle, [