avero-ui 0.0.0-stage → 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +1043 -2
- package/fesm2022/avero-ui-accordion.mjs +515 -0
- package/fesm2022/avero-ui-accordion.mjs.map +1 -0
- package/fesm2022/avero-ui-animate-on-scroll.mjs +223 -0
- package/fesm2022/avero-ui-animate-on-scroll.mjs.map +1 -0
- package/fesm2022/avero-ui-auto-complete.mjs +638 -0
- package/fesm2022/avero-ui-auto-complete.mjs.map +1 -0
- package/fesm2022/avero-ui-auto-focus.mjs +88 -0
- package/fesm2022/avero-ui-auto-focus.mjs.map +1 -0
- package/fesm2022/avero-ui-avatar.mjs +274 -0
- package/fesm2022/avero-ui-avatar.mjs.map +1 -0
- package/fesm2022/avero-ui-badge.mjs +278 -0
- package/fesm2022/avero-ui-badge.mjs.map +1 -0
- package/fesm2022/avero-ui-bind.mjs +103 -0
- package/fesm2022/avero-ui-bind.mjs.map +1 -0
- package/fesm2022/avero-ui-block-ui.mjs +175 -0
- package/fesm2022/avero-ui-block-ui.mjs.map +1 -0
- package/fesm2022/avero-ui-breadcrumb.mjs +187 -0
- package/fesm2022/avero-ui-breadcrumb.mjs.map +1 -0
- package/fesm2022/avero-ui-button.mjs +118 -0
- package/fesm2022/avero-ui-button.mjs.map +1 -0
- package/fesm2022/avero-ui-calendar.mjs +412 -0
- package/fesm2022/avero-ui-calendar.mjs.map +1 -0
- package/fesm2022/avero-ui-card.mjs +305 -0
- package/fesm2022/avero-ui-card.mjs.map +1 -0
- package/fesm2022/avero-ui-carousel.mjs +390 -0
- package/fesm2022/avero-ui-carousel.mjs.map +1 -0
- package/fesm2022/avero-ui-cascade-select.mjs +771 -0
- package/fesm2022/avero-ui-cascade-select.mjs.map +1 -0
- package/fesm2022/avero-ui-chart.mjs +361 -0
- package/fesm2022/avero-ui-chart.mjs.map +1 -0
- package/fesm2022/avero-ui-checkbox.mjs +279 -0
- package/fesm2022/avero-ui-checkbox.mjs.map +1 -0
- package/fesm2022/avero-ui-chip.mjs +256 -0
- package/fesm2022/avero-ui-chip.mjs.map +1 -0
- package/fesm2022/avero-ui-class-names.mjs +80 -0
- package/fesm2022/avero-ui-class-names.mjs.map +1 -0
- package/fesm2022/avero-ui-color-picker.mjs +665 -0
- package/fesm2022/avero-ui-color-picker.mjs.map +1 -0
- package/fesm2022/avero-ui-confirm-dialog.mjs +561 -0
- package/fesm2022/avero-ui-confirm-dialog.mjs.map +1 -0
- package/fesm2022/avero-ui-confirm-popup.mjs +406 -0
- package/fesm2022/avero-ui-confirm-popup.mjs.map +1 -0
- package/fesm2022/avero-ui-context-menu.mjs +409 -0
- package/fesm2022/avero-ui-context-menu.mjs.map +1 -0
- package/fesm2022/avero-ui-core.mjs +38 -0
- package/fesm2022/avero-ui-core.mjs.map +1 -0
- package/fesm2022/avero-ui-data-view.mjs +312 -0
- package/fesm2022/avero-ui-data-view.mjs.map +1 -0
- package/fesm2022/avero-ui-dialog.mjs +595 -0
- package/fesm2022/avero-ui-dialog.mjs.map +1 -0
- package/fesm2022/avero-ui-divider.mjs +119 -0
- package/fesm2022/avero-ui-divider.mjs.map +1 -0
- package/fesm2022/avero-ui-dock.mjs +243 -0
- package/fesm2022/avero-ui-dock.mjs.map +1 -0
- package/fesm2022/avero-ui-drawer.mjs +577 -0
- package/fesm2022/avero-ui-drawer.mjs.map +1 -0
- package/fesm2022/avero-ui-dropdown.mjs +510 -0
- package/fesm2022/avero-ui-dropdown.mjs.map +1 -0
- package/fesm2022/avero-ui-dynamic-dialog.mjs +268 -0
- package/fesm2022/avero-ui-dynamic-dialog.mjs.map +1 -0
- package/fesm2022/avero-ui-fieldset.mjs +354 -0
- package/fesm2022/avero-ui-fieldset.mjs.map +1 -0
- package/fesm2022/avero-ui-file-upload.mjs +658 -0
- package/fesm2022/avero-ui-file-upload.mjs.map +1 -0
- package/fesm2022/avero-ui-fluid.mjs +147 -0
- package/fesm2022/avero-ui-fluid.mjs.map +1 -0
- package/fesm2022/avero-ui-focus-trap.mjs +120 -0
- package/fesm2022/avero-ui-focus-trap.mjs.map +1 -0
- package/fesm2022/avero-ui-galleria.mjs +523 -0
- package/fesm2022/avero-ui-galleria.mjs.map +1 -0
- package/fesm2022/avero-ui-icon-field.mjs +99 -0
- package/fesm2022/avero-ui-icon-field.mjs.map +1 -0
- package/fesm2022/avero-ui-image-compare.mjs +274 -0
- package/fesm2022/avero-ui-image-compare.mjs.map +1 -0
- package/fesm2022/avero-ui-image.mjs +397 -0
- package/fesm2022/avero-ui-image.mjs.map +1 -0
- package/fesm2022/avero-ui-input-group.mjs +79 -0
- package/fesm2022/avero-ui-input-group.mjs.map +1 -0
- package/fesm2022/avero-ui-input-mask.mjs +678 -0
- package/fesm2022/avero-ui-input-mask.mjs.map +1 -0
- package/fesm2022/avero-ui-input-number.mjs +390 -0
- package/fesm2022/avero-ui-input-number.mjs.map +1 -0
- package/fesm2022/avero-ui-input-otp.mjs +541 -0
- package/fesm2022/avero-ui-input-otp.mjs.map +1 -0
- package/fesm2022/avero-ui-input.mjs +140 -0
- package/fesm2022/avero-ui-input.mjs.map +1 -0
- package/fesm2022/avero-ui-knob.mjs +436 -0
- package/fesm2022/avero-ui-knob.mjs.map +1 -0
- package/fesm2022/avero-ui-mega-menu.mjs +431 -0
- package/fesm2022/avero-ui-mega-menu.mjs.map +1 -0
- package/fesm2022/avero-ui-menu.mjs +398 -0
- package/fesm2022/avero-ui-menu.mjs.map +1 -0
- package/fesm2022/avero-ui-menubar.mjs +387 -0
- package/fesm2022/avero-ui-menubar.mjs.map +1 -0
- package/fesm2022/avero-ui-message.mjs +221 -0
- package/fesm2022/avero-ui-message.mjs.map +1 -0
- package/fesm2022/avero-ui-order-list.mjs +302 -0
- package/fesm2022/avero-ui-order-list.mjs.map +1 -0
- package/fesm2022/avero-ui-organization-chart.mjs +505 -0
- package/fesm2022/avero-ui-organization-chart.mjs.map +1 -0
- package/fesm2022/avero-ui-paginator.mjs +319 -0
- package/fesm2022/avero-ui-paginator.mjs.map +1 -0
- package/fesm2022/avero-ui-panel-menu.mjs +339 -0
- package/fesm2022/avero-ui-panel-menu.mjs.map +1 -0
- package/fesm2022/avero-ui-password.mjs +483 -0
- package/fesm2022/avero-ui-password.mjs.map +1 -0
- package/fesm2022/avero-ui-popover.mjs +469 -0
- package/fesm2022/avero-ui-popover.mjs.map +1 -0
- package/fesm2022/avero-ui-progress-bar.mjs +194 -0
- package/fesm2022/avero-ui-progress-bar.mjs.map +1 -0
- package/fesm2022/avero-ui-progress-spinner.mjs +150 -0
- package/fesm2022/avero-ui-progress-spinner.mjs.map +1 -0
- package/fesm2022/avero-ui-radio.mjs +67 -0
- package/fesm2022/avero-ui-radio.mjs.map +1 -0
- package/fesm2022/avero-ui-rating.mjs +271 -0
- package/fesm2022/avero-ui-rating.mjs.map +1 -0
- package/fesm2022/avero-ui-scroll-panel.mjs +415 -0
- package/fesm2022/avero-ui-scroll-panel.mjs.map +1 -0
- package/fesm2022/avero-ui-slider.mjs +274 -0
- package/fesm2022/avero-ui-slider.mjs.map +1 -0
- package/fesm2022/avero-ui-splitter.mjs +438 -0
- package/fesm2022/avero-ui-splitter.mjs.map +1 -0
- package/fesm2022/avero-ui-stepper.mjs +626 -0
- package/fesm2022/avero-ui-stepper.mjs.map +1 -0
- package/fesm2022/avero-ui-switch.mjs +252 -0
- package/fesm2022/avero-ui-switch.mjs.map +1 -0
- package/fesm2022/avero-ui-table.mjs +448 -0
- package/fesm2022/avero-ui-table.mjs.map +1 -0
- package/fesm2022/avero-ui-tabs.mjs +693 -0
- package/fesm2022/avero-ui-tabs.mjs.map +1 -0
- package/fesm2022/avero-ui-textarea.mjs +180 -0
- package/fesm2022/avero-ui-textarea.mjs.map +1 -0
- package/fesm2022/avero-ui-tiered-menu.mjs +444 -0
- package/fesm2022/avero-ui-tiered-menu.mjs.map +1 -0
- package/fesm2022/avero-ui-timeline.mjs +348 -0
- package/fesm2022/avero-ui-timeline.mjs.map +1 -0
- package/fesm2022/avero-ui-toast.mjs +291 -0
- package/fesm2022/avero-ui-toast.mjs.map +1 -0
- package/fesm2022/avero-ui-toggle-button.mjs +317 -0
- package/fesm2022/avero-ui-toggle-button.mjs.map +1 -0
- package/fesm2022/avero-ui-toolbar.mjs +284 -0
- package/fesm2022/avero-ui-toolbar.mjs.map +1 -0
- package/fesm2022/avero-ui-tooltip.mjs +442 -0
- package/fesm2022/avero-ui-tooltip.mjs.map +1 -0
- package/fesm2022/avero-ui-tree.mjs +426 -0
- package/fesm2022/avero-ui-tree.mjs.map +1 -0
- package/fesm2022/avero-ui-virtual-scroller.mjs +503 -0
- package/fesm2022/avero-ui-virtual-scroller.mjs.map +1 -0
- package/fesm2022/avero-ui.mjs +114 -0
- package/fesm2022/avero-ui.mjs.map +1 -0
- package/package.json +342 -3
- package/scripts/install-agent-skills.mjs +31 -0
- package/skills/avero-ui-build/SKILL.md +40 -0
- package/skills/avero-ui-build/agents/openai.yaml +4 -0
- package/skills/avero-ui-build/assets/workspace-page.scss +94 -0
- package/skills/avero-ui-build/assets/workspace-page.ts +222 -0
- package/skills/avero-ui-build/references/components.md +47 -0
- package/skills/avero-ui-build/references/integration.md +65 -0
- package/skills/avero-ui-build/references/recipes.md +88 -0
- package/styles/theme.scss +92 -0
- package/types/avero-ui-accordion.d.ts +101 -0
- package/types/avero-ui-animate-on-scroll.d.ts +56 -0
- package/types/avero-ui-auto-complete.d.ts +188 -0
- package/types/avero-ui-auto-focus.d.ts +24 -0
- package/types/avero-ui-avatar.d.ts +73 -0
- package/types/avero-ui-badge.d.ts +71 -0
- package/types/avero-ui-bind.d.ts +26 -0
- package/types/avero-ui-block-ui.d.ts +31 -0
- package/types/avero-ui-breadcrumb.d.ts +65 -0
- package/types/avero-ui-button.d.ts +37 -0
- package/types/avero-ui-calendar.d.ts +105 -0
- package/types/avero-ui-card.d.ts +53 -0
- package/types/avero-ui-carousel.d.ts +128 -0
- package/types/avero-ui-cascade-select.d.ts +212 -0
- package/types/avero-ui-chart.d.ts +106 -0
- package/types/avero-ui-checkbox.d.ts +90 -0
- package/types/avero-ui-chip.d.ts +63 -0
- package/types/avero-ui-class-names.d.ts +24 -0
- package/types/avero-ui-color-picker.d.ts +173 -0
- package/types/avero-ui-confirm-dialog.d.ts +113 -0
- package/types/avero-ui-confirm-popup.d.ts +68 -0
- package/types/avero-ui-context-menu.d.ts +95 -0
- package/types/avero-ui-core.d.ts +11 -0
- package/types/avero-ui-data-view.d.ts +102 -0
- package/types/avero-ui-dialog.d.ts +118 -0
- package/types/avero-ui-divider.d.ts +31 -0
- package/types/avero-ui-dock.d.ts +80 -0
- package/types/avero-ui-drawer.d.ts +109 -0
- package/types/avero-ui-dropdown.d.ts +146 -0
- package/types/avero-ui-dynamic-dialog.d.ts +51 -0
- package/types/avero-ui-fieldset.d.ts +73 -0
- package/types/avero-ui-file-upload.d.ts +195 -0
- package/types/avero-ui-fluid.d.ts +32 -0
- package/types/avero-ui-focus-trap.d.ts +25 -0
- package/types/avero-ui-galleria.d.ts +156 -0
- package/types/avero-ui-icon-field.d.ts +22 -0
- package/types/avero-ui-image-compare.d.ts +77 -0
- package/types/avero-ui-image.d.ts +111 -0
- package/types/avero-ui-input-group.d.ts +14 -0
- package/types/avero-ui-input-mask.d.ts +178 -0
- package/types/avero-ui-input-number.d.ts +131 -0
- package/types/avero-ui-input-otp.d.ts +140 -0
- package/types/avero-ui-input.d.ts +36 -0
- package/types/avero-ui-knob.d.ts +139 -0
- package/types/avero-ui-mega-menu.d.ts +115 -0
- package/types/avero-ui-menu.d.ts +100 -0
- package/types/avero-ui-menubar.d.ts +91 -0
- package/types/avero-ui-message.d.ts +54 -0
- package/types/avero-ui-order-list.d.ts +85 -0
- package/types/avero-ui-organization-chart.d.ts +145 -0
- package/types/avero-ui-paginator.d.ts +104 -0
- package/types/avero-ui-panel-menu.d.ts +99 -0
- package/types/avero-ui-password.d.ts +163 -0
- package/types/avero-ui-popover.d.ts +91 -0
- package/types/avero-ui-progress-bar.d.ts +45 -0
- package/types/avero-ui-progress-spinner.d.ts +41 -0
- package/types/avero-ui-radio.d.ts +16 -0
- package/types/avero-ui-rating.d.ts +75 -0
- package/types/avero-ui-scroll-panel.d.ts +78 -0
- package/types/avero-ui-slider.d.ts +92 -0
- package/types/avero-ui-splitter.d.ts +90 -0
- package/types/avero-ui-stepper.d.ts +134 -0
- package/types/avero-ui-switch.d.ts +83 -0
- package/types/avero-ui-table.d.ts +150 -0
- package/types/avero-ui-tabs.d.ts +135 -0
- package/types/avero-ui-textarea.d.ts +43 -0
- package/types/avero-ui-tiered-menu.d.ts +105 -0
- package/types/avero-ui-timeline.d.ts +97 -0
- package/types/avero-ui-toast.d.ts +99 -0
- package/types/avero-ui-toggle-button.d.ts +115 -0
- package/types/avero-ui-toolbar.d.ts +33 -0
- package/types/avero-ui-tooltip.d.ts +93 -0
- package/types/avero-ui-tree.d.ts +128 -0
- package/types/avero-ui-virtual-scroller.d.ts +149 -0
- package/types/avero-ui.d.ts +82 -0
|
@@ -0,0 +1,541 @@
|
|
|
1
|
+
import { NgTemplateOutlet } from "@angular/common";
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
import { ChangeDetectionStrategy, Component, ElementRef, booleanAttribute, computed, contentChild, effect, forwardRef, inject, input, numberAttribute, output, signal, untracked, viewChildren } from "@angular/core";
|
|
4
|
+
import { NG_VALIDATORS, NG_VALUE_ACCESSOR } from "@angular/forms";
|
|
5
|
+
import { AvInput } from "avero-ui/input";
|
|
6
|
+
var AvInputOtp = class AvInputOtp {
|
|
7
|
+
inputId = input.required(...ngDevMode ? [{ debugName: "inputId" }] : /* istanbul ignore next */ []);
|
|
8
|
+
label = input.required(...ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []);
|
|
9
|
+
length = input(4, {
|
|
10
|
+
...ngDevMode ? { debugName: "length" } : /* istanbul ignore next */ {},
|
|
11
|
+
transform: numberAttribute
|
|
12
|
+
});
|
|
13
|
+
integerOnly = input(false, {
|
|
14
|
+
...ngDevMode ? { debugName: "integerOnly" } : /* istanbul ignore next */ {},
|
|
15
|
+
transform: booleanAttribute
|
|
16
|
+
});
|
|
17
|
+
mask = input(false, {
|
|
18
|
+
...ngDevMode ? { debugName: "mask" } : /* istanbul ignore next */ {},
|
|
19
|
+
transform: booleanAttribute
|
|
20
|
+
});
|
|
21
|
+
disabled = input(false, {
|
|
22
|
+
...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
|
|
23
|
+
transform: booleanAttribute
|
|
24
|
+
});
|
|
25
|
+
readonly = input(false, {
|
|
26
|
+
...ngDevMode ? { debugName: "readonly" } : /* istanbul ignore next */ {},
|
|
27
|
+
transform: booleanAttribute
|
|
28
|
+
});
|
|
29
|
+
required = input(false, {
|
|
30
|
+
...ngDevMode ? { debugName: "required" } : /* istanbul ignore next */ {},
|
|
31
|
+
transform: booleanAttribute
|
|
32
|
+
});
|
|
33
|
+
invalid = input(false, {
|
|
34
|
+
...ngDevMode ? { debugName: "invalid" } : /* istanbul ignore next */ {},
|
|
35
|
+
transform: booleanAttribute
|
|
36
|
+
});
|
|
37
|
+
describedBy = input(null, ...ngDevMode ? [{ debugName: "describedBy" }] : /* istanbul ignore next */ []);
|
|
38
|
+
avSize = input("md", ...ngDevMode ? [{ debugName: "avSize" }] : /* istanbul ignore next */ []);
|
|
39
|
+
variant = input("outlined", ...ngDevMode ? [{ debugName: "variant" }] : /* istanbul ignore next */ []);
|
|
40
|
+
separatorAfter = input(0, {
|
|
41
|
+
...ngDevMode ? { debugName: "separatorAfter" } : /* istanbul ignore next */ {},
|
|
42
|
+
transform: numberAttribute
|
|
43
|
+
});
|
|
44
|
+
characterLabel = input("Character", ...ngDevMode ? [{ debugName: "characterLabel" }] : /* istanbul ignore next */ []);
|
|
45
|
+
onChange = output();
|
|
46
|
+
onComplete = output();
|
|
47
|
+
separatorTemplate = contentChild("separator", ...ngDevMode ? [{ debugName: "separatorTemplate" }] : /* istanbul ignore next */ []);
|
|
48
|
+
count = computed(() => Number.isFinite(this.length()) ? Math.max(1, Math.min(32, Math.floor(this.length()))) : 4, ...ngDevMode ? [{ debugName: "count" }] : /* istanbul ignore next */ []);
|
|
49
|
+
indices = computed(() => Array.from({ length: this.count() }, (_, i) => i), ...ngDevMode ? [{ debugName: "indices" }] : /* istanbul ignore next */ []);
|
|
50
|
+
cells = signal([], ...ngDevMode ? [{ debugName: "cells" }] : /* istanbul ignore next */ []);
|
|
51
|
+
fields = viewChildren("field", {
|
|
52
|
+
...ngDevMode ? { debugName: "fields" } : /* istanbul ignore next */ {},
|
|
53
|
+
read: ElementRef
|
|
54
|
+
});
|
|
55
|
+
host = inject(ElementRef);
|
|
56
|
+
formDisabled = signal(false, ...ngDevMode ? [{ debugName: "formDisabled" }] : /* istanbul ignore next */ []);
|
|
57
|
+
isDisabled = computed(() => this.disabled() || this.formDisabled(), ...ngDevMode ? [{ debugName: "isDisabled" }] : /* istanbul ignore next */ []);
|
|
58
|
+
locked = computed(() => this.isDisabled() || this.readonly(), ...ngDevMode ? [{ debugName: "locked" }] : /* istanbul ignore next */ []);
|
|
59
|
+
composing = /* @__PURE__ */ new Set();
|
|
60
|
+
source = "";
|
|
61
|
+
change = () => {};
|
|
62
|
+
touched = () => {};
|
|
63
|
+
validatorChanged = () => {};
|
|
64
|
+
constructor() {
|
|
65
|
+
effect(() => {
|
|
66
|
+
const count = this.count();
|
|
67
|
+
this.integerOnly();
|
|
68
|
+
untracked(() => {
|
|
69
|
+
this.cells.set(this.normalize(this.source, count));
|
|
70
|
+
this.validatorChanged();
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
}
|
|
74
|
+
characters(value) {
|
|
75
|
+
return Array.from(value).filter((char) => this.integerOnly() ? /^[0-9]$/.test(char) : !/[\s\p{C}]/u.test(char));
|
|
76
|
+
}
|
|
77
|
+
normalize(value, count = this.count()) {
|
|
78
|
+
const chars = this.characters(value);
|
|
79
|
+
return Array.from({ length: count }, (_, i) => chars[i] ?? "");
|
|
80
|
+
}
|
|
81
|
+
writeValue(value) {
|
|
82
|
+
this.source = typeof value === "string" ? value : "";
|
|
83
|
+
this.cells.set(this.normalize(this.source));
|
|
84
|
+
}
|
|
85
|
+
registerOnChange(fn) {
|
|
86
|
+
this.change = fn;
|
|
87
|
+
}
|
|
88
|
+
registerOnTouched(fn) {
|
|
89
|
+
this.touched = fn;
|
|
90
|
+
}
|
|
91
|
+
setDisabledState(value) {
|
|
92
|
+
this.formDisabled.set(value);
|
|
93
|
+
}
|
|
94
|
+
registerOnValidatorChange(fn) {
|
|
95
|
+
this.validatorChanged = fn;
|
|
96
|
+
}
|
|
97
|
+
validate(control) {
|
|
98
|
+
if (control.value == null || control.value === "") return null;
|
|
99
|
+
const text = String(control.value);
|
|
100
|
+
return this.characters(text).join("") === text && Array.from(text).length === this.count() && (text !== this.cells().join("") || this.cells().every(Boolean)) ? null : { otp: { requiredLength: this.count() } };
|
|
101
|
+
}
|
|
102
|
+
sync() {
|
|
103
|
+
this.fields().forEach((field, i) => field.nativeElement.value = this.cells()[i] ?? "");
|
|
104
|
+
}
|
|
105
|
+
focus(index) {
|
|
106
|
+
const field = this.fields()[Math.max(0, Math.min(this.count() - 1, index))]?.nativeElement;
|
|
107
|
+
field?.focus();
|
|
108
|
+
field?.select();
|
|
109
|
+
}
|
|
110
|
+
select(event) {
|
|
111
|
+
event.target.select();
|
|
112
|
+
}
|
|
113
|
+
commit(cells, event) {
|
|
114
|
+
if (this.locked()) {
|
|
115
|
+
this.sync();
|
|
116
|
+
return;
|
|
117
|
+
}
|
|
118
|
+
const previous = this.cells();
|
|
119
|
+
const changed = cells.some((value, i) => value !== previous[i]);
|
|
120
|
+
this.cells.set(cells);
|
|
121
|
+
this.sync();
|
|
122
|
+
if (!changed) return;
|
|
123
|
+
this.source = cells.join("");
|
|
124
|
+
const value = this.source || null;
|
|
125
|
+
this.change(value);
|
|
126
|
+
this.validatorChanged();
|
|
127
|
+
const detail = {
|
|
128
|
+
value,
|
|
129
|
+
originalEvent: event
|
|
130
|
+
};
|
|
131
|
+
this.onChange.emit(detail);
|
|
132
|
+
if (cells.every(Boolean)) this.onComplete.emit(detail);
|
|
133
|
+
}
|
|
134
|
+
insert(text, index, event) {
|
|
135
|
+
if (this.locked()) {
|
|
136
|
+
this.sync();
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
const chars = this.characters(text);
|
|
140
|
+
if (!chars.length) {
|
|
141
|
+
this.sync();
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
const start = chars.length >= this.count() ? 0 : index;
|
|
145
|
+
const cells = [...this.cells()];
|
|
146
|
+
const take = chars.slice(0, this.count() - start);
|
|
147
|
+
take.forEach((char, offset) => cells[start + offset] = char);
|
|
148
|
+
this.commit(cells, event);
|
|
149
|
+
this.focus(start + take.length);
|
|
150
|
+
}
|
|
151
|
+
erase(index, backwards, event) {
|
|
152
|
+
if (this.locked()) return;
|
|
153
|
+
const cells = [...this.cells()];
|
|
154
|
+
const target = backwards && !cells[index] ? Math.max(0, index - 1) : index;
|
|
155
|
+
cells[target] = "";
|
|
156
|
+
this.commit(cells, event);
|
|
157
|
+
this.focus(backwards ? Math.max(0, index - 1) : index);
|
|
158
|
+
}
|
|
159
|
+
key(event, index) {
|
|
160
|
+
if (event.isComposing || this.composing.has(index) || this.isDisabled()) return;
|
|
161
|
+
const targets = {
|
|
162
|
+
ArrowLeft: index - 1,
|
|
163
|
+
ArrowRight: index + 1,
|
|
164
|
+
Home: 0,
|
|
165
|
+
End: this.count() - 1
|
|
166
|
+
};
|
|
167
|
+
if (event.key in targets && !event.ctrlKey && !event.metaKey) {
|
|
168
|
+
event.preventDefault();
|
|
169
|
+
this.focus(targets[event.key]);
|
|
170
|
+
} else if (!this.readonly() && (event.key === "Backspace" || event.key === "Delete")) {
|
|
171
|
+
event.preventDefault();
|
|
172
|
+
this.erase(index, event.key === "Backspace", event);
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
beforeInput(event, index) {
|
|
176
|
+
if (this.locked()) {
|
|
177
|
+
event.preventDefault();
|
|
178
|
+
return;
|
|
179
|
+
}
|
|
180
|
+
if (event.isComposing || this.composing.has(index) || !event.cancelable) return;
|
|
181
|
+
if (event.inputType.startsWith("insert") && event.data !== null) {
|
|
182
|
+
event.preventDefault();
|
|
183
|
+
this.insert(event.data, index, event);
|
|
184
|
+
} else if (event.inputType.startsWith("delete")) {
|
|
185
|
+
event.preventDefault();
|
|
186
|
+
this.erase(index, event.inputType.includes("Backward"), event);
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
inputChanged(event, index) {
|
|
190
|
+
if (this.composing.has(index)) return;
|
|
191
|
+
const value = event.target.value;
|
|
192
|
+
if (value) this.insert(value, index, event);
|
|
193
|
+
else {
|
|
194
|
+
const cells = [...this.cells()];
|
|
195
|
+
cells[index] = "";
|
|
196
|
+
this.commit(cells, event);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
paste(event, index) {
|
|
200
|
+
const value = event.clipboardData?.getData("text");
|
|
201
|
+
if (value !== void 0) {
|
|
202
|
+
event.preventDefault();
|
|
203
|
+
this.insert(value, index, event);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
compositionStart(index) {
|
|
207
|
+
this.composing.add(index);
|
|
208
|
+
}
|
|
209
|
+
compositionEnd(event, index) {
|
|
210
|
+
this.composing.delete(index);
|
|
211
|
+
this.inputChanged(event, index);
|
|
212
|
+
}
|
|
213
|
+
leave(event) {
|
|
214
|
+
if (!this.host.nativeElement.contains(event.relatedTarget)) this.touched();
|
|
215
|
+
}
|
|
216
|
+
static ɵfac = i0.ɵɵngDeclareFactory({
|
|
217
|
+
minVersion: "12.0.0",
|
|
218
|
+
version: "22.3.2",
|
|
219
|
+
ngImport: i0,
|
|
220
|
+
type: AvInputOtp,
|
|
221
|
+
deps: [],
|
|
222
|
+
target: i0.ɵɵFactoryTarget.Component
|
|
223
|
+
});
|
|
224
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({
|
|
225
|
+
minVersion: "17.0.0",
|
|
226
|
+
version: "22.3.2",
|
|
227
|
+
type: AvInputOtp,
|
|
228
|
+
isStandalone: true,
|
|
229
|
+
selector: "av-input-otp",
|
|
230
|
+
inputs: {
|
|
231
|
+
inputId: {
|
|
232
|
+
classPropertyName: "inputId",
|
|
233
|
+
publicName: "inputId",
|
|
234
|
+
isSignal: true,
|
|
235
|
+
isRequired: true,
|
|
236
|
+
transformFunction: null
|
|
237
|
+
},
|
|
238
|
+
label: {
|
|
239
|
+
classPropertyName: "label",
|
|
240
|
+
publicName: "label",
|
|
241
|
+
isSignal: true,
|
|
242
|
+
isRequired: true,
|
|
243
|
+
transformFunction: null
|
|
244
|
+
},
|
|
245
|
+
length: {
|
|
246
|
+
classPropertyName: "length",
|
|
247
|
+
publicName: "length",
|
|
248
|
+
isSignal: true,
|
|
249
|
+
isRequired: false,
|
|
250
|
+
transformFunction: null
|
|
251
|
+
},
|
|
252
|
+
integerOnly: {
|
|
253
|
+
classPropertyName: "integerOnly",
|
|
254
|
+
publicName: "integerOnly",
|
|
255
|
+
isSignal: true,
|
|
256
|
+
isRequired: false,
|
|
257
|
+
transformFunction: null
|
|
258
|
+
},
|
|
259
|
+
mask: {
|
|
260
|
+
classPropertyName: "mask",
|
|
261
|
+
publicName: "mask",
|
|
262
|
+
isSignal: true,
|
|
263
|
+
isRequired: false,
|
|
264
|
+
transformFunction: null
|
|
265
|
+
},
|
|
266
|
+
disabled: {
|
|
267
|
+
classPropertyName: "disabled",
|
|
268
|
+
publicName: "disabled",
|
|
269
|
+
isSignal: true,
|
|
270
|
+
isRequired: false,
|
|
271
|
+
transformFunction: null
|
|
272
|
+
},
|
|
273
|
+
readonly: {
|
|
274
|
+
classPropertyName: "readonly",
|
|
275
|
+
publicName: "readonly",
|
|
276
|
+
isSignal: true,
|
|
277
|
+
isRequired: false,
|
|
278
|
+
transformFunction: null
|
|
279
|
+
},
|
|
280
|
+
required: {
|
|
281
|
+
classPropertyName: "required",
|
|
282
|
+
publicName: "required",
|
|
283
|
+
isSignal: true,
|
|
284
|
+
isRequired: false,
|
|
285
|
+
transformFunction: null
|
|
286
|
+
},
|
|
287
|
+
invalid: {
|
|
288
|
+
classPropertyName: "invalid",
|
|
289
|
+
publicName: "invalid",
|
|
290
|
+
isSignal: true,
|
|
291
|
+
isRequired: false,
|
|
292
|
+
transformFunction: null
|
|
293
|
+
},
|
|
294
|
+
describedBy: {
|
|
295
|
+
classPropertyName: "describedBy",
|
|
296
|
+
publicName: "describedBy",
|
|
297
|
+
isSignal: true,
|
|
298
|
+
isRequired: false,
|
|
299
|
+
transformFunction: null
|
|
300
|
+
},
|
|
301
|
+
avSize: {
|
|
302
|
+
classPropertyName: "avSize",
|
|
303
|
+
publicName: "avSize",
|
|
304
|
+
isSignal: true,
|
|
305
|
+
isRequired: false,
|
|
306
|
+
transformFunction: null
|
|
307
|
+
},
|
|
308
|
+
variant: {
|
|
309
|
+
classPropertyName: "variant",
|
|
310
|
+
publicName: "variant",
|
|
311
|
+
isSignal: true,
|
|
312
|
+
isRequired: false,
|
|
313
|
+
transformFunction: null
|
|
314
|
+
},
|
|
315
|
+
separatorAfter: {
|
|
316
|
+
classPropertyName: "separatorAfter",
|
|
317
|
+
publicName: "separatorAfter",
|
|
318
|
+
isSignal: true,
|
|
319
|
+
isRequired: false,
|
|
320
|
+
transformFunction: null
|
|
321
|
+
},
|
|
322
|
+
characterLabel: {
|
|
323
|
+
classPropertyName: "characterLabel",
|
|
324
|
+
publicName: "characterLabel",
|
|
325
|
+
isSignal: true,
|
|
326
|
+
isRequired: false,
|
|
327
|
+
transformFunction: null
|
|
328
|
+
}
|
|
329
|
+
},
|
|
330
|
+
outputs: {
|
|
331
|
+
onChange: "onChange",
|
|
332
|
+
onComplete: "onComplete"
|
|
333
|
+
},
|
|
334
|
+
host: { listeners: { "focusout": "leave($event)" } },
|
|
335
|
+
providers: [{
|
|
336
|
+
provide: NG_VALUE_ACCESSOR,
|
|
337
|
+
useExisting: forwardRef(() => AvInputOtp),
|
|
338
|
+
multi: true
|
|
339
|
+
}, {
|
|
340
|
+
provide: NG_VALIDATORS,
|
|
341
|
+
useExisting: forwardRef(() => AvInputOtp),
|
|
342
|
+
multi: true
|
|
343
|
+
}],
|
|
344
|
+
queries: [{
|
|
345
|
+
propertyName: "separatorTemplate",
|
|
346
|
+
first: true,
|
|
347
|
+
predicate: ["separator"],
|
|
348
|
+
descendants: true,
|
|
349
|
+
isSignal: true
|
|
350
|
+
}],
|
|
351
|
+
viewQueries: [{
|
|
352
|
+
propertyName: "fields",
|
|
353
|
+
predicate: ["field"],
|
|
354
|
+
descendants: true,
|
|
355
|
+
read: ElementRef,
|
|
356
|
+
isSignal: true
|
|
357
|
+
}],
|
|
358
|
+
ngImport: i0,
|
|
359
|
+
template: "<div class=\"label\" [id]=\"inputId() + '-label'\">{{ label() }}</div>\n<div\n class=\"fields\"\n role=\"group\"\n dir=\"ltr\"\n [attr.aria-labelledby]=\"inputId() + '-label'\"\n [attr.aria-describedby]=\"describedBy()\"\n [class.filled]=\"variant() === 'filled'\"\n [attr.data-size]=\"avSize()\"\n>\n @for (index of indices(); track index) {\n <input\n #field\n avInput\n [id]=\"inputId() + '-' + index\"\n [type]=\"mask() ? 'password' : 'text'\"\n [value]=\"cells()[index] || ''\"\n [avSize]=\"avSize()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"readonly()\"\n [attr.aria-required]=\"required()\"\n [attr.aria-invalid]=\"invalid()\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-label]=\"label() + ' — ' + characterLabel() + ' ' + (index + 1) + ' / ' + count()\"\n [attr.inputmode]=\"integerOnly() ? 'numeric' : 'text'\"\n [autocomplete]=\"index === 0 ? 'one-time-code' : 'off'\"\n autocapitalize=\"off\"\n spellcheck=\"false\"\n (focus)=\"select($event)\"\n (keydown)=\"key($event, index)\"\n (beforeinput)=\"beforeInput($event, index)\"\n (input)=\"inputChanged($event, index)\"\n (paste)=\"paste($event, index)\"\n (compositionstart)=\"compositionStart(index)\"\n (compositionend)=\"compositionEnd($event, index)\"\n />\n @if (separatorAfter() === index + 1 && index + 1 < count()) {\n <span class=\"separator\" aria-hidden=\"true\">\n @if (separatorTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template\" />\n } @else {\n –\n }\n </span>\n }\n }\n</div>\n",
|
|
360
|
+
styles: [":host{display:inline-block;max-width:100%;font-family:inherit}.label{margin-bottom:8px;font-size:14px;font-weight:500;color:var(--av-input-color, var(--av-text-strong, #0f172a))}.fields{display:flex;flex-wrap:wrap;align-items:center;gap:var(--av-input-otp-gap, 8px)}.fields input{flex:0 0 var(--av-input-otp-width, 40px);width:var(--av-input-otp-width, 40px);padding:0;text-align:center;font-variant-numeric:tabular-nums;font-weight:600}.fields[data-size=sm] input{flex-basis:var(--av-input-otp-width, 32px);width:var(--av-input-otp-width, 32px)}.fields[data-size=lg] input{flex-basis:var(--av-input-otp-width, 48px);width:var(--av-input-otp-width, 48px)}.filled{--av-input-background: var(--av-input-otp-filled-background, var(--av-surface-muted, #f1f5f9))}.separator{color:var(--av-input-otp-separator-color, var(--av-text-muted, #64748b))}\n"],
|
|
361
|
+
dependencies: [{
|
|
362
|
+
kind: "component",
|
|
363
|
+
type: AvInput,
|
|
364
|
+
selector: "input[avInput]",
|
|
365
|
+
inputs: ["avSize"]
|
|
366
|
+
}, {
|
|
367
|
+
kind: "directive",
|
|
368
|
+
type: NgTemplateOutlet,
|
|
369
|
+
selector: "[ngTemplateOutlet]",
|
|
370
|
+
inputs: [
|
|
371
|
+
"ngTemplateOutletContext",
|
|
372
|
+
"ngTemplateOutlet",
|
|
373
|
+
"ngTemplateOutletInjector"
|
|
374
|
+
]
|
|
375
|
+
}],
|
|
376
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
377
|
+
});
|
|
378
|
+
};
|
|
379
|
+
i0.ɵɵngDeclareClassMetadata({
|
|
380
|
+
minVersion: "12.0.0",
|
|
381
|
+
version: "22.3.2",
|
|
382
|
+
ngImport: i0,
|
|
383
|
+
type: AvInputOtp,
|
|
384
|
+
decorators: [{
|
|
385
|
+
type: Component,
|
|
386
|
+
args: [{
|
|
387
|
+
selector: "av-input-otp",
|
|
388
|
+
imports: [AvInput, NgTemplateOutlet],
|
|
389
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
390
|
+
providers: [{
|
|
391
|
+
provide: NG_VALUE_ACCESSOR,
|
|
392
|
+
useExisting: forwardRef(() => AvInputOtp),
|
|
393
|
+
multi: true
|
|
394
|
+
}, {
|
|
395
|
+
provide: NG_VALIDATORS,
|
|
396
|
+
useExisting: forwardRef(() => AvInputOtp),
|
|
397
|
+
multi: true
|
|
398
|
+
}],
|
|
399
|
+
host: { "(focusout)": "leave($event)" },
|
|
400
|
+
template: "<div class=\"label\" [id]=\"inputId() + '-label'\">{{ label() }}</div>\n<div\n class=\"fields\"\n role=\"group\"\n dir=\"ltr\"\n [attr.aria-labelledby]=\"inputId() + '-label'\"\n [attr.aria-describedby]=\"describedBy()\"\n [class.filled]=\"variant() === 'filled'\"\n [attr.data-size]=\"avSize()\"\n>\n @for (index of indices(); track index) {\n <input\n #field\n avInput\n [id]=\"inputId() + '-' + index\"\n [type]=\"mask() ? 'password' : 'text'\"\n [value]=\"cells()[index] || ''\"\n [avSize]=\"avSize()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"readonly()\"\n [attr.aria-required]=\"required()\"\n [attr.aria-invalid]=\"invalid()\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-label]=\"label() + ' — ' + characterLabel() + ' ' + (index + 1) + ' / ' + count()\"\n [attr.inputmode]=\"integerOnly() ? 'numeric' : 'text'\"\n [autocomplete]=\"index === 0 ? 'one-time-code' : 'off'\"\n autocapitalize=\"off\"\n spellcheck=\"false\"\n (focus)=\"select($event)\"\n (keydown)=\"key($event, index)\"\n (beforeinput)=\"beforeInput($event, index)\"\n (input)=\"inputChanged($event, index)\"\n (paste)=\"paste($event, index)\"\n (compositionstart)=\"compositionStart(index)\"\n (compositionend)=\"compositionEnd($event, index)\"\n />\n @if (separatorAfter() === index + 1 && index + 1 < count()) {\n <span class=\"separator\" aria-hidden=\"true\">\n @if (separatorTemplate(); as template) {\n <ng-container [ngTemplateOutlet]=\"template\" />\n } @else {\n –\n }\n </span>\n }\n }\n</div>\n",
|
|
401
|
+
styles: [":host{display:inline-block;max-width:100%;font-family:inherit}.label{margin-bottom:8px;font-size:14px;font-weight:500;color:var(--av-input-color, var(--av-text-strong, #0f172a))}.fields{display:flex;flex-wrap:wrap;align-items:center;gap:var(--av-input-otp-gap, 8px)}.fields input{flex:0 0 var(--av-input-otp-width, 40px);width:var(--av-input-otp-width, 40px);padding:0;text-align:center;font-variant-numeric:tabular-nums;font-weight:600}.fields[data-size=sm] input{flex-basis:var(--av-input-otp-width, 32px);width:var(--av-input-otp-width, 32px)}.fields[data-size=lg] input{flex-basis:var(--av-input-otp-width, 48px);width:var(--av-input-otp-width, 48px)}.filled{--av-input-background: var(--av-input-otp-filled-background, var(--av-surface-muted, #f1f5f9))}.separator{color:var(--av-input-otp-separator-color, var(--av-text-muted, #64748b))}\n"]
|
|
402
|
+
}]
|
|
403
|
+
}],
|
|
404
|
+
ctorParameters: () => [],
|
|
405
|
+
propDecorators: {
|
|
406
|
+
inputId: [{
|
|
407
|
+
type: i0.Input,
|
|
408
|
+
args: [{
|
|
409
|
+
isSignal: true,
|
|
410
|
+
alias: "inputId",
|
|
411
|
+
required: true
|
|
412
|
+
}]
|
|
413
|
+
}],
|
|
414
|
+
label: [{
|
|
415
|
+
type: i0.Input,
|
|
416
|
+
args: [{
|
|
417
|
+
isSignal: true,
|
|
418
|
+
alias: "label",
|
|
419
|
+
required: true
|
|
420
|
+
}]
|
|
421
|
+
}],
|
|
422
|
+
length: [{
|
|
423
|
+
type: i0.Input,
|
|
424
|
+
args: [{
|
|
425
|
+
isSignal: true,
|
|
426
|
+
alias: "length",
|
|
427
|
+
required: false
|
|
428
|
+
}]
|
|
429
|
+
}],
|
|
430
|
+
integerOnly: [{
|
|
431
|
+
type: i0.Input,
|
|
432
|
+
args: [{
|
|
433
|
+
isSignal: true,
|
|
434
|
+
alias: "integerOnly",
|
|
435
|
+
required: false
|
|
436
|
+
}]
|
|
437
|
+
}],
|
|
438
|
+
mask: [{
|
|
439
|
+
type: i0.Input,
|
|
440
|
+
args: [{
|
|
441
|
+
isSignal: true,
|
|
442
|
+
alias: "mask",
|
|
443
|
+
required: false
|
|
444
|
+
}]
|
|
445
|
+
}],
|
|
446
|
+
disabled: [{
|
|
447
|
+
type: i0.Input,
|
|
448
|
+
args: [{
|
|
449
|
+
isSignal: true,
|
|
450
|
+
alias: "disabled",
|
|
451
|
+
required: false
|
|
452
|
+
}]
|
|
453
|
+
}],
|
|
454
|
+
readonly: [{
|
|
455
|
+
type: i0.Input,
|
|
456
|
+
args: [{
|
|
457
|
+
isSignal: true,
|
|
458
|
+
alias: "readonly",
|
|
459
|
+
required: false
|
|
460
|
+
}]
|
|
461
|
+
}],
|
|
462
|
+
required: [{
|
|
463
|
+
type: i0.Input,
|
|
464
|
+
args: [{
|
|
465
|
+
isSignal: true,
|
|
466
|
+
alias: "required",
|
|
467
|
+
required: false
|
|
468
|
+
}]
|
|
469
|
+
}],
|
|
470
|
+
invalid: [{
|
|
471
|
+
type: i0.Input,
|
|
472
|
+
args: [{
|
|
473
|
+
isSignal: true,
|
|
474
|
+
alias: "invalid",
|
|
475
|
+
required: false
|
|
476
|
+
}]
|
|
477
|
+
}],
|
|
478
|
+
describedBy: [{
|
|
479
|
+
type: i0.Input,
|
|
480
|
+
args: [{
|
|
481
|
+
isSignal: true,
|
|
482
|
+
alias: "describedBy",
|
|
483
|
+
required: false
|
|
484
|
+
}]
|
|
485
|
+
}],
|
|
486
|
+
avSize: [{
|
|
487
|
+
type: i0.Input,
|
|
488
|
+
args: [{
|
|
489
|
+
isSignal: true,
|
|
490
|
+
alias: "avSize",
|
|
491
|
+
required: false
|
|
492
|
+
}]
|
|
493
|
+
}],
|
|
494
|
+
variant: [{
|
|
495
|
+
type: i0.Input,
|
|
496
|
+
args: [{
|
|
497
|
+
isSignal: true,
|
|
498
|
+
alias: "variant",
|
|
499
|
+
required: false
|
|
500
|
+
}]
|
|
501
|
+
}],
|
|
502
|
+
separatorAfter: [{
|
|
503
|
+
type: i0.Input,
|
|
504
|
+
args: [{
|
|
505
|
+
isSignal: true,
|
|
506
|
+
alias: "separatorAfter",
|
|
507
|
+
required: false
|
|
508
|
+
}]
|
|
509
|
+
}],
|
|
510
|
+
characterLabel: [{
|
|
511
|
+
type: i0.Input,
|
|
512
|
+
args: [{
|
|
513
|
+
isSignal: true,
|
|
514
|
+
alias: "characterLabel",
|
|
515
|
+
required: false
|
|
516
|
+
}]
|
|
517
|
+
}],
|
|
518
|
+
onChange: [{
|
|
519
|
+
type: i0.Output,
|
|
520
|
+
args: ["onChange"]
|
|
521
|
+
}],
|
|
522
|
+
onComplete: [{
|
|
523
|
+
type: i0.Output,
|
|
524
|
+
args: ["onComplete"]
|
|
525
|
+
}],
|
|
526
|
+
separatorTemplate: [{
|
|
527
|
+
type: i0.ContentChild,
|
|
528
|
+
args: ["separator", { isSignal: true }]
|
|
529
|
+
}],
|
|
530
|
+
fields: [{
|
|
531
|
+
type: i0.ViewChildren,
|
|
532
|
+
args: ["field", {
|
|
533
|
+
read: ElementRef,
|
|
534
|
+
isSignal: true
|
|
535
|
+
}]
|
|
536
|
+
}]
|
|
537
|
+
}
|
|
538
|
+
});
|
|
539
|
+
export { AvInputOtp };
|
|
540
|
+
|
|
541
|
+
//# sourceMappingURL=avero-ui-input-otp.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"avero-ui-input-otp.mjs","names":[],"sources":["../../../projects/avero-ui/src/lib/input-otp/input-otp.ts","../../../projects/avero-ui/src/lib/input-otp/input-otp.html"],"sourcesContent":["import { NgTemplateOutlet } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n effect,\n ElementRef,\n forwardRef,\n inject,\n input,\n numberAttribute,\n output,\n signal,\n TemplateRef,\n untracked,\n viewChildren,\n} from '@angular/core';\nimport {\n AbstractControl,\n ControlValueAccessor,\n NG_VALIDATORS,\n NG_VALUE_ACCESSOR,\n ValidationErrors,\n Validator,\n} from '@angular/forms';\nimport { AvInput } from 'avero-ui/input';\n\nexport interface AvInputOtpChangeEvent {\n originalEvent: Event;\n value: string | null;\n}\n@Component({\n selector: 'av-input-otp',\n imports: [AvInput, NgTemplateOutlet],\n templateUrl: './input-otp.html',\n styleUrl: './input-otp.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n { provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => AvInputOtp), multi: true },\n { provide: NG_VALIDATORS, useExisting: forwardRef(() => AvInputOtp), multi: true },\n ],\n host: { '(focusout)': 'leave($event)' },\n})\nexport class AvInputOtp implements ControlValueAccessor, Validator {\n readonly inputId = input.required<string>();\n readonly label = input.required<string>();\n readonly length = input(4, { transform: numberAttribute });\n readonly integerOnly = input(false, { transform: booleanAttribute });\n readonly mask = input(false, { transform: booleanAttribute });\n readonly disabled = input(false, { transform: booleanAttribute });\n readonly readonly = input(false, { transform: booleanAttribute });\n readonly required = input(false, { transform: booleanAttribute });\n readonly invalid = input(false, { transform: booleanAttribute });\n readonly describedBy = input<string | null>(null);\n readonly avSize = input<'sm' | 'md' | 'lg'>('md');\n readonly variant = input<'outlined' | 'filled'>('outlined');\n readonly separatorAfter = input(0, { transform: numberAttribute });\n readonly characterLabel = input('Character');\n readonly onChange = output<AvInputOtpChangeEvent>();\n readonly onComplete = output<AvInputOtpChangeEvent>();\n protected readonly separatorTemplate = contentChild<TemplateRef<unknown>>('separator');\n protected readonly count = computed(() =>\n Number.isFinite(this.length()) ? Math.max(1, Math.min(32, Math.floor(this.length()))) : 4,\n );\n protected readonly indices = computed(() => Array.from({ length: this.count() }, (_, i) => i));\n protected readonly cells = signal<string[]>([]);\n private readonly fields = viewChildren('field', { read: ElementRef<HTMLInputElement> });\n private readonly host = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly formDisabled = signal(false);\n protected readonly isDisabled = computed(() => this.disabled() || this.formDisabled());\n private readonly locked = computed(() => this.isDisabled() || this.readonly());\n private readonly composing = new Set<number>();\n private source = '';\n private change: (value: string | null) => void = () => {};\n private touched = () => {};\n private validatorChanged = () => {};\n constructor() {\n effect(() => {\n const count = this.count();\n this.integerOnly();\n untracked(() => {\n this.cells.set(this.normalize(this.source, count));\n this.validatorChanged();\n });\n });\n }\n private characters(value: string): string[] {\n return Array.from(value).filter((char) =>\n this.integerOnly() ? /^[0-9]$/.test(char) : !/[\\s\\p{C}]/u.test(char),\n );\n }\n private normalize(value: string, count = this.count()): string[] {\n const chars = this.characters(value);\n return Array.from({ length: count }, (_, i) => chars[i] ?? '');\n }\n writeValue(value: unknown): void {\n this.source = typeof value === 'string' ? value : '';\n this.cells.set(this.normalize(this.source));\n }\n registerOnChange(fn: (value: string | null) => void): void {\n this.change = fn;\n }\n registerOnTouched(fn: () => void): void {\n this.touched = fn;\n }\n setDisabledState(value: boolean): void {\n this.formDisabled.set(value);\n }\n registerOnValidatorChange(fn: () => void): void {\n this.validatorChanged = fn;\n }\n validate(control: AbstractControl): ValidationErrors | null {\n if (control.value == null || control.value === '') return null;\n const text = String(control.value);\n const valid =\n this.characters(text).join('') === text &&\n Array.from(text).length === this.count() &&\n (text !== this.cells().join('') || this.cells().every(Boolean));\n return valid ? null : { otp: { requiredLength: this.count() } };\n }\n private sync(): void {\n this.fields().forEach((field, i) => (field.nativeElement.value = this.cells()[i] ?? ''));\n }\n private focus(index: number): void {\n const field = this.fields()[Math.max(0, Math.min(this.count() - 1, index))]?.nativeElement;\n field?.focus();\n field?.select();\n }\n protected select(event: Event): void {\n (event.target as HTMLInputElement).select();\n }\n private commit(cells: string[], event: Event): void {\n if (this.locked()) {\n this.sync();\n return;\n }\n const previous = this.cells();\n const changed = cells.some((value, i) => value !== previous[i]);\n this.cells.set(cells);\n this.sync();\n if (!changed) return;\n this.source = cells.join('');\n const value = this.source || null;\n this.change(value);\n this.validatorChanged();\n const detail = { value, originalEvent: event };\n this.onChange.emit(detail);\n if (cells.every(Boolean)) this.onComplete.emit(detail);\n }\n private insert(text: string, index: number, event: Event): void {\n if (this.locked()) {\n this.sync();\n return;\n }\n const chars = this.characters(text);\n if (!chars.length) {\n this.sync();\n return;\n }\n // Autofill/full-code paste replaces the whole code, regardless of the focused cell.\n const start = chars.length >= this.count() ? 0 : index;\n const cells = [...this.cells()];\n const take = chars.slice(0, this.count() - start);\n take.forEach((char, offset) => (cells[start + offset] = char));\n this.commit(cells, event);\n this.focus(start + take.length);\n }\n private erase(index: number, backwards: boolean, event: Event): void {\n if (this.locked()) return;\n const cells = [...this.cells()];\n const target = backwards && !cells[index] ? Math.max(0, index - 1) : index;\n cells[target] = '';\n this.commit(cells, event);\n this.focus(backwards ? Math.max(0, index - 1) : index);\n }\n protected key(event: KeyboardEvent, index: number): void {\n if (event.isComposing || this.composing.has(index) || this.isDisabled()) return;\n const targets: Record<string, number> = {\n ArrowLeft: index - 1,\n ArrowRight: index + 1,\n Home: 0,\n End: this.count() - 1,\n };\n if (event.key in targets && !event.ctrlKey && !event.metaKey) {\n event.preventDefault();\n this.focus(targets[event.key]);\n } else if (!this.readonly() && (event.key === 'Backspace' || event.key === 'Delete')) {\n event.preventDefault();\n this.erase(index, event.key === 'Backspace', event);\n }\n }\n protected beforeInput(event: InputEvent, index: number): void {\n if (this.locked()) {\n event.preventDefault();\n return;\n }\n if (event.isComposing || this.composing.has(index) || !event.cancelable) return;\n if (event.inputType.startsWith('insert') && event.data !== null) {\n event.preventDefault();\n this.insert(event.data, index, event);\n } else if (event.inputType.startsWith('delete')) {\n event.preventDefault();\n this.erase(index, event.inputType.includes('Backward'), event);\n }\n }\n protected inputChanged(event: Event, index: number): void {\n if (this.composing.has(index)) return;\n const value = (event.target as HTMLInputElement).value;\n if (value) this.insert(value, index, event);\n else {\n const cells = [...this.cells()];\n cells[index] = '';\n this.commit(cells, event);\n }\n }\n protected paste(event: ClipboardEvent, index: number): void {\n const value = event.clipboardData?.getData('text');\n if (value !== undefined) {\n event.preventDefault();\n this.insert(value, index, event);\n }\n }\n protected compositionStart(index: number): void {\n this.composing.add(index);\n }\n protected compositionEnd(event: Event, index: number): void {\n this.composing.delete(index);\n this.inputChanged(event, index);\n }\n protected leave(event: FocusEvent): void {\n if (!this.host.nativeElement.contains(event.relatedTarget as Node | null)) this.touched();\n }\n}\n","<div class=\"label\" [id]=\"inputId() + '-label'\">{{ label() }}</div>\n<div\n class=\"fields\"\n role=\"group\"\n dir=\"ltr\"\n [attr.aria-labelledby]=\"inputId() + '-label'\"\n [attr.aria-describedby]=\"describedBy()\"\n [class.filled]=\"variant() === 'filled'\"\n [attr.data-size]=\"avSize()\"\n>\n @for (index of indices(); track index) {\n <input\n #field\n avInput\n [id]=\"inputId() + '-' + index\"\n [type]=\"mask() ? 'password' : 'text'\"\n [value]=\"cells()[index] || ''\"\n [avSize]=\"avSize()\"\n [disabled]=\"isDisabled()\"\n [readOnly]=\"readonly()\"\n [attr.aria-required]=\"required()\"\n [attr.aria-invalid]=\"invalid()\"\n [attr.aria-describedby]=\"describedBy()\"\n [attr.aria-label]=\"label() + ' — ' + characterLabel() + ' ' + (index + 1) + ' / ' + count()\"\n [attr.inputmode]=\"integerOnly() ? 'numeric' : 'text'\"\n [autocomplete]=\"index === 0 ? 'one-time-code' : 'off'\"\n autocapitalize=\"off\"\n spellcheck=\"false\"\n (focus)=\"select($event)\"\n (keydown)=\"key($event, index)\"\n (beforeinput)=\"beforeInput($event, index)\"\n (input)=\"inputChanged($event, index)\"\n (paste)=\"paste($event, index)\"\n (compositionstart)=\"compositionStart(index)\"\n (compositionend)=\"compositionEnd($event, index)\"\n />\n @if (separatorAfter() === index + 1 && index + 1 < count()) {\n <span class=\"separator\" aria-hid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