skcr-autechre 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/README.md ADDED
@@ -0,0 +1,63 @@
1
+ # Autechre
2
+
3
+ This project was generated using [Angular CLI](https://github.com/angular/angular-cli) version 21.0.0.
4
+
5
+ ## Code scaffolding
6
+
7
+ Angular CLI includes powerful code scaffolding tools. To generate a new component, run:
8
+
9
+ ```bash
10
+ ng generate component component-name
11
+ ```
12
+
13
+ For a complete list of available schematics (such as `components`, `directives`, or `pipes`), run:
14
+
15
+ ```bash
16
+ ng generate --help
17
+ ```
18
+
19
+ ## Building
20
+
21
+ To build the library, run:
22
+
23
+ ```bash
24
+ ng build autechre
25
+ ```
26
+
27
+ This command will compile your project, and the build artifacts will be placed in the `dist/` directory.
28
+
29
+ ### Publishing the Library
30
+
31
+ Once the project is built, you can publish your library by following these steps:
32
+
33
+ 1. Navigate to the `dist` directory:
34
+ ```bash
35
+ cd dist/autechre
36
+ ```
37
+
38
+ 2. Run the `npm publish` command to publish your library to the npm registry:
39
+ ```bash
40
+ npm publish
41
+ ```
42
+
43
+ ## Running unit tests
44
+
45
+ To execute unit tests with the [Karma](https://karma-runner.github.io) test runner, use the following command:
46
+
47
+ ```bash
48
+ ng test
49
+ ```
50
+
51
+ ## Running end-to-end tests
52
+
53
+ For end-to-end (e2e) testing, run:
54
+
55
+ ```bash
56
+ ng e2e
57
+ ```
58
+
59
+ Angular CLI does not come with an end-to-end testing framework by default. You can choose one that suits your needs.
60
+
61
+ ## Additional Resources
62
+
63
+ For more information on using the Angular CLI, including detailed command references, visit the [Angular CLI Overview and Command Reference](https://angular.dev/tools/cli) page.
@@ -0,0 +1,323 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Component, input, model, signal, computed, inject, ElementRef, viewChild, effect, output } from '@angular/core';
3
+ import { trigger, transition, style, animate } from '@angular/animations';
4
+ import * as i1 from '@angular/forms';
5
+ import { FormsModule } from '@angular/forms';
6
+ import { NgClass } from '@angular/common';
7
+ import * as i2 from '@angular/cdk/scrolling';
8
+ import { ScrollingModule } from '@angular/cdk/scrolling';
9
+ import { NgIcon } from '@ng-icons/core';
10
+
11
+ class Autechre {
12
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: Autechre, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
13
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.0.3", type: Autechre, isStandalone: true, selector: "lib-autechre", ngImport: i0, template: `
14
+ <p>
15
+ autechre works!
16
+ </p>
17
+ `, isInline: true, styles: [""] }); }
18
+ }
19
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: Autechre, decorators: [{
20
+ type: Component,
21
+ args: [{ selector: 'lib-autechre', imports: [], template: `
22
+ <p>
23
+ autechre works!
24
+ </p>
25
+ ` }]
26
+ }] });
27
+
28
+ class MultiSelectComponent {
29
+ constructor() {
30
+ this.options = input.required(...(ngDevMode ? [{ debugName: "options" }] : []));
31
+ this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : []));
32
+ this.placeholder = input('', ...(ngDevMode ? [{ debugName: "placeholder" }] : []));
33
+ this.searchPlaceholder = input('', ...(ngDevMode ? [{ debugName: "searchPlaceholder" }] : []));
34
+ this.isInvalid = input(false, ...(ngDevMode ? [{ debugName: "isInvalid" }] : []));
35
+ this.isDisabled = input(false, ...(ngDevMode ? [{ debugName: "isDisabled" }] : []));
36
+ this.isSearchDisplayed = input(false, ...(ngDevMode ? [{ debugName: "isSearchDisplayed" }] : []));
37
+ this.isOptional = input(false, ...(ngDevMode ? [{ debugName: "isOptional" }] : []));
38
+ this.isFullWidth = input(false, ...(ngDevMode ? [{ debugName: "isFullWidth" }] : []));
39
+ this.areValueDisplayedOutside = input(false, ...(ngDevMode ? [{ debugName: "areValueDisplayedOutside" }] : []));
40
+ this.tooltipText = input('', ...(ngDevMode ? [{ debugName: "tooltipText" }] : []));
41
+ this.value = model([], ...(ngDevMode ? [{ debugName: "value" }] : []));
42
+ this.searchTerm = signal('', ...(ngDevMode ? [{ debugName: "searchTerm" }] : []));
43
+ this.isOpen = signal(false, ...(ngDevMode ? [{ debugName: "isOpen" }] : []));
44
+ this.dropdownTop = 0;
45
+ this.dropdownLeft = 0;
46
+ this.dropdownWidth = 0;
47
+ this.formattedOptions = computed(() => {
48
+ let formattedOptions = this.options() || [];
49
+ if (formattedOptions[0]?.value === undefined) {
50
+ formattedOptions = formattedOptions.map(option => {
51
+ return {
52
+ ...option,
53
+ value: option.id,
54
+ };
55
+ });
56
+ }
57
+ return formattedOptions;
58
+ }, ...(ngDevMode ? [{ debugName: "formattedOptions" }] : []));
59
+ this.filteredOptions = computed(() => {
60
+ const normalizedQuery = this.normalizeString(this.searchTerm());
61
+ return this.formattedOptions().filter(option => {
62
+ return this.normalizeString(option.name).includes(normalizedQuery);
63
+ });
64
+ }, ...(ngDevMode ? [{ debugName: "filteredOptions" }] : []));
65
+ this.selectedOptions = computed(() => {
66
+ return this.formattedOptions().filter(option => this.value().includes(option.value));
67
+ }, ...(ngDevMode ? [{ debugName: "selectedOptions" }] : []));
68
+ this.selectedOptionsText = computed(() => {
69
+ return this.selectedOptions()
70
+ .map(option => option.name)
71
+ .join(', ');
72
+ }, ...(ngDevMode ? [{ debugName: "selectedOptionsText" }] : []));
73
+ this.elRef = inject(ElementRef);
74
+ this.searchInputEl = viewChild('searchInput', ...(ngDevMode ? [{ debugName: "searchInputEl" }] : []));
75
+ this.resizeHandler = () => {
76
+ if (this.isOpen()) {
77
+ this.updateDropdownPosition();
78
+ }
79
+ };
80
+ this.clickOutsideHandler = (e) => {
81
+ if (!this.elRef.nativeElement.contains(e.target) && this.isOpen()) {
82
+ this.toggleSelect();
83
+ }
84
+ };
85
+ this.Math = Math;
86
+ effect(() => {
87
+ const disabledSelectedOptions = this.formattedOptions().filter(option => option.isDisabled && this.value()?.includes(option.value));
88
+ if (disabledSelectedOptions.length > 0) {
89
+ const updatedValue = this.value()?.filter(value => !disabledSelectedOptions.some(option => option.value === value));
90
+ this.value.set(updatedValue || []);
91
+ }
92
+ });
93
+ }
94
+ toggleSelect(event) {
95
+ if (event?.defaultPrevented) {
96
+ return;
97
+ }
98
+ this.isOpen.update(isOpen => !isOpen);
99
+ if (this.isOpen()) {
100
+ this.updateDropdownPosition();
101
+ document.addEventListener('click', this.clickOutsideHandler);
102
+ window.addEventListener('resize', this.resizeHandler);
103
+ window.addEventListener('scroll', this.resizeHandler, true);
104
+ this.focusSearchInput();
105
+ }
106
+ else {
107
+ document.removeEventListener('click', this.clickOutsideHandler);
108
+ window.removeEventListener('resize', this.resizeHandler);
109
+ window.removeEventListener('scroll', this.resizeHandler, true);
110
+ }
111
+ }
112
+ handleOptionClick(item) {
113
+ if (!item.isDisabled) {
114
+ const itemIndex = this.value().indexOf(item.value);
115
+ const updatedValue = [
116
+ ...this.value(),
117
+ ];
118
+ if (itemIndex >= 0) {
119
+ updatedValue.splice(itemIndex, 1);
120
+ }
121
+ else {
122
+ updatedValue.push(item.value);
123
+ }
124
+ this.value.set(updatedValue);
125
+ }
126
+ }
127
+ isItemSelected(item) {
128
+ return this.value().includes(item.value);
129
+ }
130
+ clearAllSelections(event) {
131
+ this.value.set([]);
132
+ event.stopPropagation();
133
+ }
134
+ removeOption(option, event) {
135
+ event.stopPropagation();
136
+ event.preventDefault();
137
+ const updatedValue = this.value().filter(value => value !== option.value);
138
+ this.value.set(updatedValue);
139
+ }
140
+ ngOnDestroy() {
141
+ document.removeEventListener('click', this.clickOutsideHandler);
142
+ window.removeEventListener('resize', this.resizeHandler);
143
+ window.removeEventListener('scroll', this.resizeHandler, true);
144
+ }
145
+ updateDropdownPosition() {
146
+ const buttonElement = this.elRef.nativeElement.querySelector('button');
147
+ if (buttonElement) {
148
+ const rect = buttonElement.getBoundingClientRect();
149
+ this.dropdownTop = rect.bottom + window.scrollY;
150
+ this.dropdownLeft = rect.left + window.scrollX;
151
+ this.dropdownWidth = rect.width;
152
+ }
153
+ }
154
+ focusSearchInput() {
155
+ if (!this.isOpen() || !this.isSearchDisplayed())
156
+ return;
157
+ setTimeout(() => {
158
+ requestAnimationFrame(() => {
159
+ const inputRef = this.searchInputEl();
160
+ const inputEl = inputRef?.nativeElement;
161
+ if (inputEl) {
162
+ inputEl.focus();
163
+ try {
164
+ inputEl.select?.();
165
+ }
166
+ catch { }
167
+ }
168
+ });
169
+ }, 1);
170
+ }
171
+ normalizeString(value) {
172
+ return value
173
+ .normalize('NFD')
174
+ .replace(/[\u0300-\u036f]/g, '')
175
+ .toLocaleLowerCase();
176
+ }
177
+ trackByValue(index, item) {
178
+ return item.value;
179
+ }
180
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: MultiSelectComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
181
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.3", type: MultiSelectComponent, isStandalone: true, selector: "skcr-multi-select", inputs: { options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: true, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholder: { classPropertyName: "searchPlaceholder", publicName: "searchPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, isInvalid: { classPropertyName: "isInvalid", publicName: "isInvalid", isSignal: true, isRequired: false, transformFunction: null }, isDisabled: { classPropertyName: "isDisabled", publicName: "isDisabled", isSignal: true, isRequired: false, transformFunction: null }, isSearchDisplayed: { classPropertyName: "isSearchDisplayed", publicName: "isSearchDisplayed", isSignal: true, isRequired: false, transformFunction: null }, isOptional: { classPropertyName: "isOptional", publicName: "isOptional", isSignal: true, isRequired: false, transformFunction: null }, isFullWidth: { classPropertyName: "isFullWidth", publicName: "isFullWidth", isSignal: true, isRequired: false, transformFunction: null }, areValueDisplayedOutside: { classPropertyName: "areValueDisplayedOutside", publicName: "areValueDisplayedOutside", isSignal: true, isRequired: false, transformFunction: null }, tooltipText: { classPropertyName: "tooltipText", publicName: "tooltipText", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, viewQueries: [{ propertyName: "searchInputEl", first: true, predicate: ["searchInput"], descendants: true, isSignal: true }], ngImport: i0, template: "<div>\n @if (label()) {\n <label\n class=\"flex items-center justify-between\"\n id=\"multiselect-label\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-xs text-slate-500\">Optional</span>\n }\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n }\n\n <div class=\"relative mt-1\">\n <button\n class=\"grid w-full min-h-9 cursor-default grid-cols-1 rounded-md shadow-sm py-2 px-3 text-left outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary sm:text-body-small/6\"\n (click)=\"toggleSelect($event)\"\n [disabled]=\"isDisabled() || !options().length\"\n [ngClass]=\"{\n 'outline-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-border-color focus:outline-primaryBlue focus:ring-primaryBlue': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled() || !options().length,\n 'cursor-pointer bg-white': !isDisabled() && !!options().length,\n }\"\n type=\"button\"\n aria-expanded=\"true\"\n aria-haspopup=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n <div class=\"col-start-1 row-start-1 block gap-2 truncate pr-12\">\n @if (!selectedOptions()!.length || !!areValueDisplayedOutside()) {\n <span>\n {{ placeholder() }}\n </span>\n } @else {\n <div class=\"flex flex-wrap gap-1 max-h-[4rem] overflow-auto scrollbar-hide relative\">\n @for (selectedOption of selectedOptions(); track selectedOption.value) {\n <span\n class=\"px-2 py-0.5 bg-primary-50 text-primary-800 rounded-lg text-caption font-medium flex items-center gap-1\"\n >\n {{ selectedOption.name }}\n\n <span\n class=\"cursor-pointer text-primary-800 flex items-center\"\n (mousedown)=\"removeOption(selectedOption, $event)\"\n (click)=\"$event.stopPropagation(); $event.preventDefault()\"\n >\n <ng-icon\n class=\"size-4\"\n name=\"heroXMark\"\n />\n </span>\n </span>\n }\n </div>\n }\n </div>\n\n <span class=\"col-start-1 row-start-1 flex items-center gap-2 self-center justify-self-end text-slate-500\">\n <span class=\"size-5 sm:size-4\">\n <ng-icon name=\"heroChevronUpDown\" />\n </span>\n </span>\n </button>\n\n @if (isOpen()) {\n <div\n class=\"fixed z-50 w-full rounded-md bg-white text-base shadow-lg ring-1 ring-black/5 focus:outline-hidden sm:text-body-small overflow-hidden\"\n [style.top.px]=\"dropdownTop\"\n [style.left.px]=\"dropdownLeft\"\n [style.width.px]=\"dropdownWidth\"\n @AnimationTrigger0\n role=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n @if (isSearchDisplayed()) {\n <div class=\"relative cursor-default py-2 px-3 shadow-sm select-none\">\n <div class=\"pointer-events-none absolute inset-y-0 left-1 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n\n <input\n class=\"block rounded-md w-full pl-6 pr-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n #searchInput\n type=\"text\"\n [placeholder]=\"searchPlaceholder()\"\n [(ngModel)]=\"searchTerm\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n }\n\n <cdk-virtual-scroll-viewport\n class=\"w-full\"\n [itemSize]=\"40\"\n [style.height.px]=\"Math.min(filteredOptions().length * 40, 224)\"\n >\n <div\n class=\"relative cursor-default py-2 pr-9 pl-3 select-none\"\n *cdkVirtualFor=\"let option of filteredOptions(); trackBy: trackByValue; let i = index\"\n (click)=\"handleOptionClick(option)\"\n [class.bg-slate-50]=\"!!option.isDisabled\"\n [class.hover:bg-primary-50]=\"!option.isDisabled\"\n [id]=\"'listbox-option-' + i\"\n role=\"option\"\n >\n <span class=\"block truncate\">\n {{ option.name }}\n </span>\n\n @if (isItemSelected(option)) {\n <span class=\"absolute inset-y-0 right-0 flex items-center pr-4 text-primary\">\n <ng-icon name=\"heroCheck\" />\n </span>\n }\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n </div>\n</div>\n", dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }, { kind: "ngmodule", type: ScrollingModule }, { kind: "directive", type: i2.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { kind: "directive", type: i2.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { kind: "component", type: i2.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }], animations: [
182
+ trigger('AnimationTrigger0', [
183
+ transition(':leave', [
184
+ style({ opacity: 1 }),
185
+ animate('200ms ease-in-out', style({ opacity: 0 })),
186
+ ]),
187
+ ]),
188
+ ] }); }
189
+ }
190
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: MultiSelectComponent, decorators: [{
191
+ type: Component,
192
+ args: [{ selector: 'skcr-multi-select', animations: [
193
+ trigger('AnimationTrigger0', [
194
+ transition(':leave', [
195
+ style({ opacity: 1 }),
196
+ animate('200ms ease-in-out', style({ opacity: 0 })),
197
+ ]),
198
+ ]),
199
+ ], imports: [
200
+ FormsModule,
201
+ NgClass,
202
+ NgIcon,
203
+ ScrollingModule,
204
+ ], template: "<div>\n @if (label()) {\n <label\n class=\"flex items-center justify-between\"\n id=\"multiselect-label\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-xs text-slate-500\">Optional</span>\n }\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n }\n\n <div class=\"relative mt-1\">\n <button\n class=\"grid w-full min-h-9 cursor-default grid-cols-1 rounded-md shadow-sm py-2 px-3 text-left outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary sm:text-body-small/6\"\n (click)=\"toggleSelect($event)\"\n [disabled]=\"isDisabled() || !options().length\"\n [ngClass]=\"{\n 'outline-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-border-color focus:outline-primaryBlue focus:ring-primaryBlue': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled() || !options().length,\n 'cursor-pointer bg-white': !isDisabled() && !!options().length,\n }\"\n type=\"button\"\n aria-expanded=\"true\"\n aria-haspopup=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n <div class=\"col-start-1 row-start-1 block gap-2 truncate pr-12\">\n @if (!selectedOptions()!.length || !!areValueDisplayedOutside()) {\n <span>\n {{ placeholder() }}\n </span>\n } @else {\n <div class=\"flex flex-wrap gap-1 max-h-[4rem] overflow-auto scrollbar-hide relative\">\n @for (selectedOption of selectedOptions(); track selectedOption.value) {\n <span\n class=\"px-2 py-0.5 bg-primary-50 text-primary-800 rounded-lg text-caption font-medium flex items-center gap-1\"\n >\n {{ selectedOption.name }}\n\n <span\n class=\"cursor-pointer text-primary-800 flex items-center\"\n (mousedown)=\"removeOption(selectedOption, $event)\"\n (click)=\"$event.stopPropagation(); $event.preventDefault()\"\n >\n <ng-icon\n class=\"size-4\"\n name=\"heroXMark\"\n />\n </span>\n </span>\n }\n </div>\n }\n </div>\n\n <span class=\"col-start-1 row-start-1 flex items-center gap-2 self-center justify-self-end text-slate-500\">\n <span class=\"size-5 sm:size-4\">\n <ng-icon name=\"heroChevronUpDown\" />\n </span>\n </span>\n </button>\n\n @if (isOpen()) {\n <div\n class=\"fixed z-50 w-full rounded-md bg-white text-base shadow-lg ring-1 ring-black/5 focus:outline-hidden sm:text-body-small overflow-hidden\"\n [style.top.px]=\"dropdownTop\"\n [style.left.px]=\"dropdownLeft\"\n [style.width.px]=\"dropdownWidth\"\n @AnimationTrigger0\n role=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n @if (isSearchDisplayed()) {\n <div class=\"relative cursor-default py-2 px-3 shadow-sm select-none\">\n <div class=\"pointer-events-none absolute inset-y-0 left-1 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n\n <input\n class=\"block rounded-md w-full pl-6 pr-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n #searchInput\n type=\"text\"\n [placeholder]=\"searchPlaceholder()\"\n [(ngModel)]=\"searchTerm\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n }\n\n <cdk-virtual-scroll-viewport\n class=\"w-full\"\n [itemSize]=\"40\"\n [style.height.px]=\"Math.min(filteredOptions().length * 40, 224)\"\n >\n <div\n class=\"relative cursor-default py-2 pr-9 pl-3 select-none\"\n *cdkVirtualFor=\"let option of filteredOptions(); trackBy: trackByValue; let i = index\"\n (click)=\"handleOptionClick(option)\"\n [class.bg-slate-50]=\"!!option.isDisabled\"\n [class.hover:bg-primary-50]=\"!option.isDisabled\"\n [id]=\"'listbox-option-' + i\"\n role=\"option\"\n >\n <span class=\"block truncate\">\n {{ option.name }}\n </span>\n\n @if (isItemSelected(option)) {\n <span class=\"absolute inset-y-0 right-0 flex items-center pr-4 text-primary\">\n <ng-icon name=\"heroCheck\" />\n </span>\n }\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n </div>\n</div>\n" }]
205
+ }], ctorParameters: () => [], propDecorators: { options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: true }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], searchPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholder", required: false }] }], isInvalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "isInvalid", required: false }] }], isDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "isDisabled", required: false }] }], isSearchDisplayed: [{ type: i0.Input, args: [{ isSignal: true, alias: "isSearchDisplayed", required: false }] }], isOptional: [{ type: i0.Input, args: [{ isSignal: true, alias: "isOptional", required: false }] }], isFullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "isFullWidth", required: false }] }], areValueDisplayedOutside: [{ type: i0.Input, args: [{ isSignal: true, alias: "areValueDisplayedOutside", required: false }] }], tooltipText: [{ type: i0.Input, args: [{ isSignal: true, alias: "tooltipText", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], searchInputEl: [{ type: i0.ViewChild, args: ['searchInput', { isSignal: true }] }] } });
206
+
207
+ class InputComponent {
208
+ constructor() {
209
+ this.id = input('', ...(ngDevMode ? [{ debugName: "id" }] : []));
210
+ this.type = input('text', ...(ngDevMode ? [{ debugName: "type" }] : []));
211
+ this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : []));
212
+ this.placeholder = input('', ...(ngDevMode ? [{ debugName: "placeholder" }] : []));
213
+ this.isOptional = input(false, ...(ngDevMode ? [{ debugName: "isOptional" }] : []));
214
+ this.isSearchInput = input(false, ...(ngDevMode ? [{ debugName: "isSearchInput" }] : []));
215
+ this.isInvalid = input(false, ...(ngDevMode ? [{ debugName: "isInvalid" }] : []));
216
+ this.isDisabled = input(false, ...(ngDevMode ? [{ debugName: "isDisabled" }] : []));
217
+ this.value = model(...(ngDevMode ? [undefined, { debugName: "value" }] : []));
218
+ }
219
+ handleChange(event) {
220
+ const newValue = event.target.value;
221
+ this.value.set(newValue);
222
+ }
223
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: InputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
224
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.3", type: InputComponent, isStandalone: true, selector: "skcr-input", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, isOptional: { classPropertyName: "isOptional", publicName: "isOptional", isSignal: true, isRequired: false, transformFunction: null }, isSearchInput: { classPropertyName: "isSearchInput", publicName: "isSearchInput", isSignal: true, isRequired: false, transformFunction: null }, isInvalid: { classPropertyName: "isInvalid", publicName: "isInvalid", isSignal: true, isRequired: false, transformFunction: null }, isDisabled: { classPropertyName: "isDisabled", publicName: "isDisabled", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, ngImport: i0, template: "<div>\n @if (label()) {\n <label\n class=\"mb-1 flex items-center gap-2\"\n [for]=\"id()\"\n >\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-slate-500\"> Optional </span>\n }\n </label>\n }\n\n <div class=\"relative\">\n @if (isSearchInput()) {\n <div class=\"pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n }\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"id() || label()\"\n [name]=\"id()\"\n [type]=\"type()\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'pl-10': isSearchInput(),\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled(),\n }\"\n />\n </div>\n</div>\n", styles: ["input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }] }); }
225
+ }
226
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: InputComponent, decorators: [{
227
+ type: Component,
228
+ args: [{ selector: 'skcr-input', imports: [
229
+ FormsModule,
230
+ NgClass,
231
+ NgIcon
232
+ ], template: "<div>\n @if (label()) {\n <label\n class=\"mb-1 flex items-center gap-2\"\n [for]=\"id()\"\n >\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-slate-500\"> Optional </span>\n }\n </label>\n }\n\n <div class=\"relative\">\n @if (isSearchInput()) {\n <div class=\"pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n }\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"id() || label()\"\n [name]=\"id()\"\n [type]=\"type()\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'pl-10': isSearchInput(),\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled(),\n }\"\n />\n </div>\n</div>\n", styles: ["input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}\n"] }]
233
+ }], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], isOptional: [{ type: i0.Input, args: [{ isSignal: true, alias: "isOptional", required: false }] }], isSearchInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "isSearchInput", required: false }] }], isInvalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "isInvalid", required: false }] }], isDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "isDisabled", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }] } });
234
+
235
+ class InputNumberComponent {
236
+ constructor() {
237
+ this.name = input('', ...(ngDevMode ? [{ debugName: "name" }] : []));
238
+ this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : []));
239
+ this.placeholder = input('', ...(ngDevMode ? [{ debugName: "placeholder" }] : []));
240
+ this.maxFractionDigits = input(0, ...(ngDevMode ? [{ debugName: "maxFractionDigits" }] : []));
241
+ this.isInvalid = input(false, ...(ngDevMode ? [{ debugName: "isInvalid" }] : []));
242
+ this.tooltipText = input('', ...(ngDevMode ? [{ debugName: "tooltipText" }] : []));
243
+ this.value = model(...(ngDevMode ? [undefined, { debugName: "value" }] : []));
244
+ this.inputPattern = `^\\d+\\.?\\d{0,${this.maxFractionDigits()}}$`;
245
+ }
246
+ handleKeyDown(event) {
247
+ if (!((event.key >= '0' && event.key <= '9') ||
248
+ [
249
+ 'Backspace',
250
+ 'Tab',
251
+ 'ArrowLeft',
252
+ 'ArrowRight',
253
+ 'Delete',
254
+ 'Home',
255
+ 'End',
256
+ ].includes(event.key))) {
257
+ event.preventDefault();
258
+ }
259
+ }
260
+ handleChange(event) {
261
+ const value = event.target.value;
262
+ this.value.set(value === '' ? undefined : +value);
263
+ }
264
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: InputNumberComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
265
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.3", type: InputNumberComponent, isStandalone: true, selector: "skcr-input-number", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: true, isRequired: false, transformFunction: null }, maxFractionDigits: { classPropertyName: "maxFractionDigits", publicName: "maxFractionDigits", isSignal: true, isRequired: false, transformFunction: null }, isInvalid: { classPropertyName: "isInvalid", publicName: "isInvalid", isSignal: true, isRequired: false, transformFunction: null }, tooltipText: { classPropertyName: "tooltipText", publicName: "tooltipText", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange" }, ngImport: i0, template: "<div>\n <label\n class=\"mb-1 flex items-center justify-between\"\n [for]=\"name()\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"name()\"\n [name]=\"name()\"\n type=\"text\"\n inputmode=\"numeric\"\n [pattern]=\"inputPattern\"\n [placeholder]=\"placeholder()\"\n (keydown)=\"handleKeyDown($event)\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n }\"\n />\n</div>\n", dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.PatternValidator, selector: "[pattern][formControlName],[pattern][formControl],[pattern][ngModel]", inputs: ["pattern"] }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }] }); }
266
+ }
267
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: InputNumberComponent, decorators: [{
268
+ type: Component,
269
+ args: [{ selector: 'skcr-input-number', imports: [
270
+ NgClass,
271
+ FormsModule,
272
+ NgIcon,
273
+ ], template: "<div>\n <label\n class=\"mb-1 flex items-center justify-between\"\n [for]=\"name()\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"name()\"\n [name]=\"name()\"\n type=\"text\"\n inputmode=\"numeric\"\n [pattern]=\"inputPattern\"\n [placeholder]=\"placeholder()\"\n (keydown)=\"handleKeyDown($event)\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n }\"\n />\n</div>\n" }]
274
+ }], propDecorators: { name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], placeholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeholder", required: false }] }], maxFractionDigits: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFractionDigits", required: false }] }], isInvalid: [{ type: i0.Input, args: [{ isSignal: true, alias: "isInvalid", required: false }] }], tooltipText: [{ type: i0.Input, args: [{ isSignal: true, alias: "tooltipText", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }] } });
275
+
276
+ var EButtonColorVariant;
277
+ (function (EButtonColorVariant) {
278
+ EButtonColorVariant["Primary"] = "btn-primary";
279
+ EButtonColorVariant["Danger"] = "btn-danger";
280
+ })(EButtonColorVariant || (EButtonColorVariant = {}));
281
+ class SubmitButtonComponent {
282
+ constructor() {
283
+ this.label = input('', ...(ngDevMode ? [{ debugName: "label" }] : []));
284
+ this.isLoading = input(false, ...(ngDevMode ? [{ debugName: "isLoading" }] : []));
285
+ this.isFullWidth = input(false, ...(ngDevMode ? [{ debugName: "isFullWidth" }] : []));
286
+ this.isDisabled = input(false, ...(ngDevMode ? [{ debugName: "isDisabled" }] : []));
287
+ this.isSuccess = input(false, ...(ngDevMode ? [{ debugName: "isSuccess" }] : []));
288
+ this.colorVariant = input(EButtonColorVariant.Primary, ...(ngDevMode ? [{ debugName: "colorVariant" }] : []));
289
+ this.submitClicked = output();
290
+ this.isSuccessIconDisplayed = signal(false, ...(ngDevMode ? [{ debugName: "isSuccessIconDisplayed" }] : []));
291
+ effect(() => {
292
+ if (this.isSuccess()) {
293
+ this.isSuccessIconDisplayed.set(true);
294
+ setTimeout(() => {
295
+ this.isSuccessIconDisplayed.set(false);
296
+ }, 1000);
297
+ }
298
+ });
299
+ }
300
+ handleCLick() {
301
+ this.submitClicked.emit();
302
+ }
303
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: SubmitButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
304
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.3", type: SubmitButtonComponent, isStandalone: true, selector: "skcr-submit-button", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, isLoading: { classPropertyName: "isLoading", publicName: "isLoading", isSignal: true, isRequired: false, transformFunction: null }, isFullWidth: { classPropertyName: "isFullWidth", publicName: "isFullWidth", isSignal: true, isRequired: false, transformFunction: null }, isDisabled: { classPropertyName: "isDisabled", publicName: "isDisabled", isSignal: true, isRequired: false, transformFunction: null }, isSuccess: { classPropertyName: "isSuccess", publicName: "isSuccess", isSignal: true, isRequired: false, transformFunction: null }, colorVariant: { classPropertyName: "colorVariant", publicName: "colorVariant", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { submitClicked: "submitClicked" }, ngImport: i0, template: "<button\n class=\"btn btn-large w-full\"\n type=\"button\"\n [class]=\"colorVariant()\"\n [ngClass]=\"{\n 'btn-success': isSuccessIconDisplayed(),\n 'btn-full': isFullWidth(),\n }\"\n [disabled]=\"isLoading() || isSuccessIconDisplayed() || isDisabled()\"\n (click)=\"handleCLick()\"\n>\n @if (isLoading()) {\n <span class=\"spinner\"></span>\n }\n\n @if (isSuccessIconDisplayed()) {\n <span class=\"flex items-center justify-center text-inherit\">\n <ng-icon\n name=\"heroCheck\"\n size=\"20px\"\n />\n </span>\n }\n\n @if (!isLoading() && !isSuccessIconDisplayed()) {\n {{ label() }}\n }\n</button>\n", styles: [".spinner{display:inline-block;border-radius:50%;width:1em;height:1em;border:.215em solid transparent;vertical-align:middle;font-size:16px;border-top-color:#fff;animation:spin 1s cubic-bezier(.55,.15,.45,.85) infinite}.btn.btn-success{line-height:0}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: NgIcon, selector: "ng-icon", inputs: ["name", "svg", "size", "strokeWidth", "color"] }] }); }
305
+ }
306
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.3", ngImport: i0, type: SubmitButtonComponent, decorators: [{
307
+ type: Component,
308
+ args: [{ selector: 'skcr-submit-button', imports: [
309
+ NgClass,
310
+ NgIcon,
311
+ ], template: "<button\n class=\"btn btn-large w-full\"\n type=\"button\"\n [class]=\"colorVariant()\"\n [ngClass]=\"{\n 'btn-success': isSuccessIconDisplayed(),\n 'btn-full': isFullWidth(),\n }\"\n [disabled]=\"isLoading() || isSuccessIconDisplayed() || isDisabled()\"\n (click)=\"handleCLick()\"\n>\n @if (isLoading()) {\n <span class=\"spinner\"></span>\n }\n\n @if (isSuccessIconDisplayed()) {\n <span class=\"flex items-center justify-center text-inherit\">\n <ng-icon\n name=\"heroCheck\"\n size=\"20px\"\n />\n </span>\n }\n\n @if (!isLoading() && !isSuccessIconDisplayed()) {\n {{ label() }}\n }\n</button>\n", styles: [".spinner{display:inline-block;border-radius:50%;width:1em;height:1em;border:.215em solid transparent;vertical-align:middle;font-size:16px;border-top-color:#fff;animation:spin 1s cubic-bezier(.55,.15,.45,.85) infinite}.btn.btn-success{line-height:0}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}\n"] }]
312
+ }], ctorParameters: () => [], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], isLoading: [{ type: i0.Input, args: [{ isSignal: true, alias: "isLoading", required: false }] }], isFullWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "isFullWidth", required: false }] }], isDisabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "isDisabled", required: false }] }], isSuccess: [{ type: i0.Input, args: [{ isSignal: true, alias: "isSuccess", required: false }] }], colorVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "colorVariant", required: false }] }], submitClicked: [{ type: i0.Output, args: ["submitClicked"] }] } });
313
+
314
+ /*
315
+ * Public API Surface of autechre
316
+ */
317
+
318
+ /**
319
+ * Generated bundle index. Do not edit.
320
+ */
321
+
322
+ export { Autechre, InputComponent, InputNumberComponent, MultiSelectComponent, SubmitButtonComponent };
323
+ //# sourceMappingURL=skcr-autechre.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"skcr-autechre.mjs","sources":["../../../projects/skcr-autechre/src/lib/autechre.ts","../../../projects/skcr-autechre/src/lib/multi-select/multi-select.component.ts","../../../projects/skcr-autechre/src/lib/multi-select/multi-select.component.html","../../../projects/skcr-autechre/src/lib/input/input.component.ts","../../../projects/skcr-autechre/src/lib/input/input.component.html","../../../projects/skcr-autechre/src/lib/input-number/input-number.component.ts","../../../projects/skcr-autechre/src/lib/input-number/input-number.component.html","../../../projects/skcr-autechre/src/lib/submit-button/submit-button.component.ts","../../../projects/skcr-autechre/src/lib/submit-button/submit-button.component.html","../../../projects/skcr-autechre/src/public-api.ts","../../../projects/skcr-autechre/src/skcr-autechre.ts"],"sourcesContent":["import { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-autechre',\n imports: [],\n template: `\n <p>\n autechre works!\n </p>\n `,\n styles: ``,\n})\nexport class Autechre {\n\n}\n","import {\n Component,\n computed,\n effect,\n ElementRef,\n inject,\n input,\n InputSignal,\n model,\n ModelSignal,\n OnDestroy,\n Signal,\n signal,\n viewChild,\n WritableSignal,\n} from '@angular/core';\nimport { animate, style, transition, trigger } from '@angular/animations';\nimport { FormsModule } from '@angular/forms';\nimport { NgClass } from '@angular/common';\nimport { ScrollingModule } from '@angular/cdk/scrolling';\nimport { NgIcon } from '@ng-icons/core';\nimport { FormValueControl } from '@angular/forms/signals';\nimport { TSelectOption } from '../types/select-option.type';\n\n@Component({\n selector: 'skcr-multi-select',\n templateUrl: './multi-select.component.html',\n animations: [\n trigger('AnimationTrigger0', [\n transition(':leave', [\n style({ opacity: 1 }),\n animate('200ms ease-in-out', style({ opacity: 0 })),\n ]),\n ]),\n ],\n imports: [\n FormsModule,\n NgClass,\n NgIcon,\n ScrollingModule,\n ],\n})\nexport class MultiSelectComponent implements FormValueControl<unknown[]>, OnDestroy {\n options: InputSignal<TSelectOption<unknown>[]> = input.required();\n label: InputSignal<string> = input('');\n placeholder: InputSignal<string> = input('');\n searchPlaceholder: InputSignal<string> = input('');\n isInvalid: InputSignal<boolean> = input(false);\n isDisabled: InputSignal<boolean> = input(false);\n isSearchDisplayed: InputSignal<boolean> = input(false);\n isOptional: InputSignal<boolean> = input(false);\n isFullWidth: InputSignal<boolean> = input(false);\n areValueDisplayedOutside: InputSignal<boolean> = input(false);\n tooltipText: InputSignal<string> = input('');\n\n readonly value: ModelSignal<unknown[]> = model<unknown[]>([]);\n\n searchTerm: Signal<string> = signal('');\n isOpen: WritableSignal<boolean> = signal(false);\n dropdownTop = 0;\n dropdownLeft = 0;\n dropdownWidth = 0;\n\n formattedOptions: Signal<TSelectOption<unknown>[]> = computed(() => {\n let formattedOptions: TSelectOption<unknown>[] = this.options() || [];\n\n if (formattedOptions[0]?.value === undefined) {\n formattedOptions = formattedOptions.map(option => {\n return {\n ...option,\n value: option.id,\n };\n });\n }\n\n return formattedOptions;\n });\n\n filteredOptions: Signal<TSelectOption<unknown>[]> = computed(() => {\n const normalizedQuery: string = this.normalizeString(this.searchTerm());\n\n return this.formattedOptions().filter(option => {\n return this.normalizeString(option.name).includes(normalizedQuery);\n });\n });\n\n selectedOptions = computed(() => {\n return this.formattedOptions().filter(option => this.value()!.includes(option.value));\n });\n\n selectedOptionsText = computed(() => {\n return this.selectedOptions()\n .map(option => option.name)\n .join(', ');\n });\n\n private elRef: ElementRef = inject(ElementRef);\n readonly searchInputEl = viewChild<ElementRef<HTMLInputElement>>('searchInput');\n\n constructor() {\n effect(() => {\n const disabledSelectedOptions = this.formattedOptions().filter(\n option => option.isDisabled && this.value()?.includes(option.value),\n );\n\n if (disabledSelectedOptions.length > 0) {\n const updatedValue = this.value()?.filter(\n value => !disabledSelectedOptions.some(option => option.value === value),\n );\n this.value.set(updatedValue || []);\n }\n });\n }\n\n toggleSelect(event?: MouseEvent): void {\n if (event?.defaultPrevented) {\n return;\n }\n\n this.isOpen.update(isOpen => !isOpen);\n\n if (this.isOpen()) {\n this.updateDropdownPosition();\n document.addEventListener('click', this.clickOutsideHandler);\n window.addEventListener('resize', this.resizeHandler);\n window.addEventListener('scroll', this.resizeHandler, true);\n this.focusSearchInput();\n } else {\n document.removeEventListener('click', this.clickOutsideHandler);\n window.removeEventListener('resize', this.resizeHandler);\n window.removeEventListener('scroll', this.resizeHandler, true);\n }\n }\n\n handleOptionClick(item: TSelectOption<unknown>): void {\n if (!item.isDisabled) {\n const itemIndex = this.value()!.indexOf(item.value!);\n const updatedValue = [\n ...this.value()!,\n ];\n\n if (itemIndex >= 0) {\n updatedValue.splice(itemIndex, 1);\n } else {\n updatedValue.push(item.value!);\n }\n\n this.value.set(updatedValue);\n }\n }\n\n isItemSelected(item: TSelectOption<unknown>): boolean {\n return this.value()!.includes(item.value);\n }\n\n clearAllSelections(event: MouseEvent): void {\n this.value.set([]);\n event.stopPropagation();\n }\n\n removeOption(option: TSelectOption<unknown>, event: MouseEvent): void {\n event.stopPropagation();\n event.preventDefault();\n\n const updatedValue = this.value()!.filter(value => value !== option.value);\n this.value.set(updatedValue);\n }\n\n ngOnDestroy(): void {\n document.removeEventListener('click', this.clickOutsideHandler);\n window.removeEventListener('resize', this.resizeHandler);\n window.removeEventListener('scroll', this.resizeHandler, true);\n }\n\n private updateDropdownPosition(): void {\n const buttonElement = this.elRef.nativeElement.querySelector('button');\n if (buttonElement) {\n const rect = buttonElement.getBoundingClientRect();\n this.dropdownTop = rect.bottom + window.scrollY;\n this.dropdownLeft = rect.left + window.scrollX;\n this.dropdownWidth = rect.width;\n }\n }\n\n private resizeHandler = (): void => {\n if (this.isOpen()) {\n this.updateDropdownPosition();\n }\n };\n\n private focusSearchInput(): void {\n if (!this.isOpen() || !this.isSearchDisplayed()) return;\n setTimeout(() => {\n requestAnimationFrame(() => {\n const inputRef = this.searchInputEl();\n const inputEl = inputRef?.nativeElement;\n if (inputEl) {\n inputEl.focus();\n try {\n inputEl.select?.();\n } catch {}\n }\n });\n }, 1);\n }\n\n private clickOutsideHandler: (e: MouseEvent) => void = (e: MouseEvent): void => {\n if (!this.elRef.nativeElement.contains(e.target) && this.isOpen()) {\n this.toggleSelect();\n }\n };\n\n private normalizeString(value: string): string {\n return value\n .normalize('NFD')\n .replace(/[\\u0300-\\u036f]/g, '')\n .toLocaleLowerCase();\n }\n\n trackByValue(index: number, item: TSelectOption<unknown>): unknown {\n return item.value;\n }\n\n protected readonly Math = Math;\n}\n","<div>\n @if (label()) {\n <label\n class=\"flex items-center justify-between\"\n id=\"multiselect-label\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-xs text-slate-500\">Optional</span>\n }\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n }\n\n <div class=\"relative mt-1\">\n <button\n class=\"grid w-full min-h-9 cursor-default grid-cols-1 rounded-md shadow-sm py-2 px-3 text-left outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary sm:text-body-small/6\"\n (click)=\"toggleSelect($event)\"\n [disabled]=\"isDisabled() || !options().length\"\n [ngClass]=\"{\n 'outline-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-border-color focus:outline-primaryBlue focus:ring-primaryBlue': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled() || !options().length,\n 'cursor-pointer bg-white': !isDisabled() && !!options().length,\n }\"\n type=\"button\"\n aria-expanded=\"true\"\n aria-haspopup=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n <div class=\"col-start-1 row-start-1 block gap-2 truncate pr-12\">\n @if (!selectedOptions()!.length || !!areValueDisplayedOutside()) {\n <span>\n {{ placeholder() }}\n </span>\n } @else {\n <div class=\"flex flex-wrap gap-1 max-h-[4rem] overflow-auto scrollbar-hide relative\">\n @for (selectedOption of selectedOptions(); track selectedOption.value) {\n <span\n class=\"px-2 py-0.5 bg-primary-50 text-primary-800 rounded-lg text-caption font-medium flex items-center gap-1\"\n >\n {{ selectedOption.name }}\n\n <span\n class=\"cursor-pointer text-primary-800 flex items-center\"\n (mousedown)=\"removeOption(selectedOption, $event)\"\n (click)=\"$event.stopPropagation(); $event.preventDefault()\"\n >\n <ng-icon\n class=\"size-4\"\n name=\"heroXMark\"\n />\n </span>\n </span>\n }\n </div>\n }\n </div>\n\n <span class=\"col-start-1 row-start-1 flex items-center gap-2 self-center justify-self-end text-slate-500\">\n <span class=\"size-5 sm:size-4\">\n <ng-icon name=\"heroChevronUpDown\" />\n </span>\n </span>\n </button>\n\n @if (isOpen()) {\n <div\n class=\"fixed z-50 w-full rounded-md bg-white text-base shadow-lg ring-1 ring-black/5 focus:outline-hidden sm:text-body-small overflow-hidden\"\n [style.top.px]=\"dropdownTop\"\n [style.left.px]=\"dropdownLeft\"\n [style.width.px]=\"dropdownWidth\"\n @AnimationTrigger0\n role=\"listbox\"\n aria-labelledby=\"multiselect-label\"\n >\n @if (isSearchDisplayed()) {\n <div class=\"relative cursor-default py-2 px-3 shadow-sm select-none\">\n <div class=\"pointer-events-none absolute inset-y-0 left-1 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n\n <input\n class=\"block rounded-md w-full pl-6 pr-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n #searchInput\n type=\"text\"\n [placeholder]=\"searchPlaceholder()\"\n [(ngModel)]=\"searchTerm\"\n (click)=\"$event.stopPropagation()\"\n />\n </div>\n }\n\n <cdk-virtual-scroll-viewport\n class=\"w-full\"\n [itemSize]=\"40\"\n [style.height.px]=\"Math.min(filteredOptions().length * 40, 224)\"\n >\n <div\n class=\"relative cursor-default py-2 pr-9 pl-3 select-none\"\n *cdkVirtualFor=\"let option of filteredOptions(); trackBy: trackByValue; let i = index\"\n (click)=\"handleOptionClick(option)\"\n [class.bg-slate-50]=\"!!option.isDisabled\"\n [class.hover:bg-primary-50]=\"!option.isDisabled\"\n [id]=\"'listbox-option-' + i\"\n role=\"option\"\n >\n <span class=\"block truncate\">\n {{ option.name }}\n </span>\n\n @if (isItemSelected(option)) {\n <span class=\"absolute inset-y-0 right-0 flex items-center pr-4 text-primary\">\n <ng-icon name=\"heroCheck\" />\n </span>\n }\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n }\n </div>\n</div>\n","import { NgClass } from '@angular/common';\nimport { Component, input, InputSignal, model } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { FormValueControl } from '@angular/forms/signals';\nimport { NgIcon } from '@ng-icons/core';\n\n@Component({\n selector: 'skcr-input',\n templateUrl: './input.component.html',\n styleUrls: [\n './input.component.scss',\n ],\n imports: [\n FormsModule,\n NgClass,\n NgIcon\n ],\n})\nexport class InputComponent implements FormValueControl<string | number | undefined | null> {\n id: InputSignal<string> = input('');\n type: InputSignal<string> = input('text');\n label: InputSignal<string> = input('');\n placeholder: InputSignal<string> = input('');\n isOptional: InputSignal<boolean> = input(false);\n isSearchInput: InputSignal<boolean> = input(false);\n isInvalid: InputSignal<boolean> = input(false);\n isDisabled: InputSignal<boolean> = input(false);\n\n readonly value = model<string | number | undefined | null>();\n\n handleChange(event: Event) {\n const newValue = (event.target as HTMLInputElement).value;\n this.value.set(newValue);\n }\n}\n","<div>\n @if (label()) {\n <label\n class=\"mb-1 flex items-center gap-2\"\n [for]=\"id()\"\n >\n {{ label() }}\n\n @if (isOptional()) {\n <span class=\"text-slate-500\"> Optional </span>\n }\n </label>\n }\n\n <div class=\"relative\">\n @if (isSearchInput()) {\n <div class=\"pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3\">\n <span class=\"flex items-center\">\n <ng-icon name=\"heroMagnifyingGlass\" />\n </span>\n </div>\n }\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"id() || label()\"\n [name]=\"id()\"\n [type]=\"type()\"\n [placeholder]=\"placeholder()\"\n [disabled]=\"isDisabled()\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'pl-10': isSearchInput(),\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n 'cursor-not-allowed bg-slate-50': isDisabled(),\n }\"\n />\n </div>\n</div>\n","import { NgClass } from '@angular/common';\nimport { Component, input, InputSignal, model } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { FormValueControl } from '@angular/forms/signals';\nimport { NgIcon } from '@ng-icons/core';\n\n@Component({\n selector: 'skcr-input-number',\n templateUrl: './input-number.component.html',\n imports: [\n NgClass,\n FormsModule,\n NgIcon,\n ],\n})\nexport class InputNumberComponent implements FormValueControl<number | undefined> {\n name: InputSignal<string> = input<string>('');\n label: InputSignal<string> = input<string>('');\n placeholder: InputSignal<string> = input<string>('');\n maxFractionDigits: InputSignal<number> = input<number>(0);\n isInvalid: InputSignal<boolean> = input<boolean>(false);\n tooltipText: InputSignal<string> = input<string>('');\n\n readonly value = model<number | undefined>();\n\n inputPattern = `^\\\\d+\\\\.?\\\\d{0,${this.maxFractionDigits()}}$`;\n\n handleKeyDown(event: KeyboardEvent): void {\n if (\n !(\n (event.key >= '0' && event.key <= '9') ||\n [\n 'Backspace',\n 'Tab',\n 'ArrowLeft',\n 'ArrowRight',\n 'Delete',\n 'Home',\n 'End',\n ].includes(event.key)\n )\n ) {\n event.preventDefault();\n }\n }\n\n handleChange(event: Event) {\n const value = (event.target as HTMLInputElement).value;\n\n this.value.set(value === '' ? undefined : +value);\n }\n}\n","<div>\n <label\n class=\"mb-1 flex items-center justify-between\"\n [for]=\"name()\"\n >\n <div class=\"flex items-center gap-2\">\n {{ label() }}\n </div>\n\n @if (tooltipText()) {\n <div class=\"flex items-center has-tooltip\">\n <ng-icon\n class=\"size-4\"\n name=\"heroQuestionMarkCircle\"\n />\n\n <div class=\"tooltip bg-gray-800 text-white -left-50 top-4 p-2 rounded text-xs max-w-md whitespace-normal\">\n {{ tooltipText() }}\n </div>\n </div>\n }\n </label>\n\n <input\n class=\"block w-full rounded-md px-3 py-2 text-body-small shadow-sm outline-1 -outline-offset-1 outline-border-color focus:outline-2 focus:-outline-offset-2 focus:outline-primary placeholder:text-slate-500\"\n [id]=\"name()\"\n [name]=\"name()\"\n type=\"text\"\n inputmode=\"numeric\"\n [pattern]=\"inputPattern\"\n [placeholder]=\"placeholder()\"\n (keydown)=\"handleKeyDown($event)\"\n [(ngModel)]=\"value\"\n (input)=\"handleChange($event)\"\n [ngClass]=\"{\n 'outline-destructive placeholder-destructive focus:outline-destructive focus:ring-destructive': isInvalid(),\n 'outline-lightGrey focus:outline-primary focus:ring-primary': !isInvalid(),\n }\"\n />\n</div>\n","import { NgClass } from '@angular/common';\nimport { Component, effect, input, InputSignal, output, signal, WritableSignal } from '@angular/core';\nimport { NgIcon } from '@ng-icons/core';\n\nenum EButtonColorVariant {\n Primary = 'btn-primary',\n Danger = 'btn-danger',\n}\n\n@Component({\n selector: 'skcr-submit-button',\n templateUrl: './submit-button.component.html',\n styleUrls: [\n './submit-button.component.scss',\n ],\n imports: [\n NgClass,\n NgIcon,\n ],\n})\nexport class SubmitButtonComponent {\n label: InputSignal<string> = input('');\n isLoading: InputSignal<boolean> = input<boolean>(false);\n isFullWidth: InputSignal<boolean> = input<boolean>(false);\n isDisabled: InputSignal<boolean> = input<boolean>(false);\n isSuccess: InputSignal<boolean> = input<boolean>(false);\n colorVariant: InputSignal<EButtonColorVariant> = input<EButtonColorVariant>(EButtonColorVariant.Primary);\n submitClicked = output<void>();\n\n constructor() {\n effect(() => {\n if (this.isSuccess()) {\n this.isSuccessIconDisplayed.set(true);\n\n setTimeout(() => {\n this.isSuccessIconDisplayed.set(false);\n }, 1000);\n }\n });\n }\n\n isSuccessIconDisplayed: WritableSignal<boolean> = signal(false);\n\n handleCLick(): void {\n this.submitClicked.emit();\n }\n}\n","<button\n class=\"btn btn-large w-full\"\n type=\"button\"\n [class]=\"colorVariant()\"\n [ngClass]=\"{\n 'btn-success': isSuccessIconDisplayed(),\n 'btn-full': isFullWidth(),\n }\"\n [disabled]=\"isLoading() || isSuccessIconDisplayed() || isDisabled()\"\n (click)=\"handleCLick()\"\n>\n @if (isLoading()) {\n <span class=\"spinner\"></span>\n }\n\n @if (isSuccessIconDisplayed()) {\n <span class=\"flex items-center justify-center text-inherit\">\n <ng-icon\n name=\"heroCheck\"\n size=\"20px\"\n />\n </span>\n }\n\n @if (!isLoading() && !isSuccessIconDisplayed()) {\n {{ label() }}\n }\n</button>\n","/*\n * Public API Surface of autechre\n */\n\nexport * from './lib/autechre';\nexport * from './lib/multi-select/multi-select.component';\nexport * from './lib/input/input.component';\nexport * from './lib/input-number/input-number.component';\nexport * from './lib/submit-button/submit-button.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;MAYa,QAAQ,CAAA;8GAAR,QAAQ,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAR,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,QAAQ,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,cAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EAPT;;;;AAIT,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;2FAGU,QAAQ,EAAA,UAAA,EAAA,CAAA;kBAVpB,SAAS;+BACE,cAAc,EAAA,OAAA,EACf,EAAE,EAAA,QAAA,EACD;;;;AAIT,EAAA,CAAA,EAAA;;;MCiCU,oBAAoB,CAAA;AAyD/B,IAAA,WAAA,GAAA;AAxDA,QAAA,IAAA,CAAA,OAAO,GAA0C,KAAK,CAAC,QAAQ,kDAAE;AACjE,QAAA,IAAA,CAAA,KAAK,GAAwB,KAAK,CAAC,EAAE,iDAAC;AACtC,QAAA,IAAA,CAAA,WAAW,GAAwB,KAAK,CAAC,EAAE,uDAAC;AAC5C,QAAA,IAAA,CAAA,iBAAiB,GAAwB,KAAK,CAAC,EAAE,6DAAC;AAClD,QAAA,IAAA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A,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECpBlC,kpBA4BA,EAAA,MAAA,EAAA,CAAA,gUAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EDZI,OAAO,oFACP,MAAM,EAAA,QAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,MAAA,EAAA,KAAA,EAAA,MAAA,EAAA,aAAA,EAAA,OAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;2FAGG,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAXjC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,oBAAoB,EAAA,OAAA,EAKrB;wBACP,OAAO;wBACP,MAAM;AACP,qBAAA,EAAA,QAAA,EAAA,kpBAAA,EAAA,MAAA,EAAA,CAAA,gUAAA,CAAA,EAAA;;;AElBH;;AAEG;;ACFH;;AAEG;;;;"}
package/package.json ADDED
@@ -0,0 +1,27 @@
1
+ {
2
+ "name": "skcr-autechre",
3
+ "version": "0.0.1",
4
+ "peerDependencies": {
5
+ "@ng-icons/core": "^31.3.0",
6
+ "@ng-icons/heroicons": "^31.3.0",
7
+ "@angular/animations": "^21.0.0",
8
+ "@angular/cdk": "^21.0.0",
9
+ "@angular/common": "^21.0.0",
10
+ "@angular/core": "^21.0.0"
11
+ },
12
+ "module": "fesm2022/skcr-autechre.mjs",
13
+ "typings": "types/skcr-autechre.d.ts",
14
+ "exports": {
15
+ "./package.json": {
16
+ "default": "./package.json"
17
+ },
18
+ ".": {
19
+ "types": "./types/skcr-autechre.d.ts",
20
+ "default": "./fesm2022/skcr-autechre.mjs"
21
+ }
22
+ },
23
+ "sideEffects": false,
24
+ "dependencies": {
25
+ "tslib": "^2.3.0"
26
+ }
27
+ }
@@ -0,0 +1,109 @@
1
+ import * as i0 from '@angular/core';
2
+ import { OnDestroy, InputSignal, ModelSignal, Signal, WritableSignal, ElementRef } from '@angular/core';
3
+ import { FormValueControl } from '@angular/forms/signals';
4
+
5
+ declare class Autechre {
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<Autechre, never>;
7
+ static ɵcmp: i0.ɵɵComponentDeclaration<Autechre, "lib-autechre", never, {}, {}, never, never, true, never>;
8
+ }
9
+
10
+ type TSelectOption<T> = {
11
+ name: string;
12
+ value?: T;
13
+ id?: number;
14
+ icon?: string;
15
+ isDisabled?: boolean;
16
+ };
17
+
18
+ declare class MultiSelectComponent implements FormValueControl<unknown[]>, OnDestroy {
19
+ options: InputSignal<TSelectOption<unknown>[]>;
20
+ label: InputSignal<string>;
21
+ placeholder: InputSignal<string>;
22
+ searchPlaceholder: InputSignal<string>;
23
+ isInvalid: InputSignal<boolean>;
24
+ isDisabled: InputSignal<boolean>;
25
+ isSearchDisplayed: InputSignal<boolean>;
26
+ isOptional: InputSignal<boolean>;
27
+ isFullWidth: InputSignal<boolean>;
28
+ areValueDisplayedOutside: InputSignal<boolean>;
29
+ tooltipText: InputSignal<string>;
30
+ readonly value: ModelSignal<unknown[]>;
31
+ searchTerm: Signal<string>;
32
+ isOpen: WritableSignal<boolean>;
33
+ dropdownTop: number;
34
+ dropdownLeft: number;
35
+ dropdownWidth: number;
36
+ formattedOptions: Signal<TSelectOption<unknown>[]>;
37
+ filteredOptions: Signal<TSelectOption<unknown>[]>;
38
+ selectedOptions: Signal<TSelectOption<unknown>[]>;
39
+ selectedOptionsText: Signal<string>;
40
+ private elRef;
41
+ readonly searchInputEl: Signal<ElementRef<HTMLInputElement> | undefined>;
42
+ constructor();
43
+ toggleSelect(event?: MouseEvent): void;
44
+ handleOptionClick(item: TSelectOption<unknown>): void;
45
+ isItemSelected(item: TSelectOption<unknown>): boolean;
46
+ clearAllSelections(event: MouseEvent): void;
47
+ removeOption(option: TSelectOption<unknown>, event: MouseEvent): void;
48
+ ngOnDestroy(): void;
49
+ private updateDropdownPosition;
50
+ private resizeHandler;
51
+ private focusSearchInput;
52
+ private clickOutsideHandler;
53
+ private normalizeString;
54
+ trackByValue(index: number, item: TSelectOption<unknown>): unknown;
55
+ protected readonly Math: Math;
56
+ static ɵfac: i0.ɵɵFactoryDeclaration<MultiSelectComponent, never>;
57
+ static ɵcmp: i0.ɵɵComponentDeclaration<MultiSelectComponent, "skcr-multi-select", never, { "options": { "alias": "options"; "required": true; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "searchPlaceholder": { "alias": "searchPlaceholder"; "required": false; "isSignal": true; }; "isInvalid": { "alias": "isInvalid"; "required": false; "isSignal": true; }; "isDisabled": { "alias": "isDisabled"; "required": false; "isSignal": true; }; "isSearchDisplayed": { "alias": "isSearchDisplayed"; "required": false; "isSignal": true; }; "isOptional": { "alias": "isOptional"; "required": false; "isSignal": true; }; "isFullWidth": { "alias": "isFullWidth"; "required": false; "isSignal": true; }; "areValueDisplayedOutside": { "alias": "areValueDisplayedOutside"; "required": false; "isSignal": true; }; "tooltipText": { "alias": "tooltipText"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
58
+ }
59
+
60
+ declare class InputComponent implements FormValueControl<string | number | undefined | null> {
61
+ id: InputSignal<string>;
62
+ type: InputSignal<string>;
63
+ label: InputSignal<string>;
64
+ placeholder: InputSignal<string>;
65
+ isOptional: InputSignal<boolean>;
66
+ isSearchInput: InputSignal<boolean>;
67
+ isInvalid: InputSignal<boolean>;
68
+ isDisabled: InputSignal<boolean>;
69
+ readonly value: i0.ModelSignal<string | number | null | undefined>;
70
+ handleChange(event: Event): void;
71
+ static ɵfac: i0.ɵɵFactoryDeclaration<InputComponent, never>;
72
+ static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "skcr-input", never, { "id": { "alias": "id"; "required": false; "isSignal": true; }; "type": { "alias": "type"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "isOptional": { "alias": "isOptional"; "required": false; "isSignal": true; }; "isSearchInput": { "alias": "isSearchInput"; "required": false; "isSignal": true; }; "isInvalid": { "alias": "isInvalid"; "required": false; "isSignal": true; }; "isDisabled": { "alias": "isDisabled"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
73
+ }
74
+
75
+ declare class InputNumberComponent implements FormValueControl<number | undefined> {
76
+ name: InputSignal<string>;
77
+ label: InputSignal<string>;
78
+ placeholder: InputSignal<string>;
79
+ maxFractionDigits: InputSignal<number>;
80
+ isInvalid: InputSignal<boolean>;
81
+ tooltipText: InputSignal<string>;
82
+ readonly value: i0.ModelSignal<number | undefined>;
83
+ inputPattern: string;
84
+ handleKeyDown(event: KeyboardEvent): void;
85
+ handleChange(event: Event): void;
86
+ static ɵfac: i0.ɵɵFactoryDeclaration<InputNumberComponent, never>;
87
+ static ɵcmp: i0.ɵɵComponentDeclaration<InputNumberComponent, "skcr-input-number", never, { "name": { "alias": "name"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "maxFractionDigits": { "alias": "maxFractionDigits"; "required": false; "isSignal": true; }; "isInvalid": { "alias": "isInvalid"; "required": false; "isSignal": true; }; "tooltipText": { "alias": "tooltipText"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
88
+ }
89
+
90
+ declare enum EButtonColorVariant {
91
+ Primary = "btn-primary",
92
+ Danger = "btn-danger"
93
+ }
94
+ declare class SubmitButtonComponent {
95
+ label: InputSignal<string>;
96
+ isLoading: InputSignal<boolean>;
97
+ isFullWidth: InputSignal<boolean>;
98
+ isDisabled: InputSignal<boolean>;
99
+ isSuccess: InputSignal<boolean>;
100
+ colorVariant: InputSignal<EButtonColorVariant>;
101
+ submitClicked: i0.OutputEmitterRef<void>;
102
+ constructor();
103
+ isSuccessIconDisplayed: WritableSignal<boolean>;
104
+ handleCLick(): void;
105
+ static ɵfac: i0.ɵɵFactoryDeclaration<SubmitButtonComponent, never>;
106
+ static ɵcmp: i0.ɵɵComponentDeclaration<SubmitButtonComponent, "skcr-submit-button", never, { "label": { "alias": "label"; "required": false; "isSignal": true; }; "isLoading": { "alias": "isLoading"; "required": false; "isSignal": true; }; "isFullWidth": { "alias": "isFullWidth"; "required": false; "isSignal": true; }; "isDisabled": { "alias": "isDisabled"; "required": false; "isSignal": true; }; "isSuccess": { "alias": "isSuccess"; "required": false; "isSignal": true; }; "colorVariant": { "alias": "colorVariant"; "required": false; "isSignal": true; }; }, { "submitClicked": "submitClicked"; }, never, never, true, never>;
107
+ }
108
+
109
+ export { Autechre, InputComponent, InputNumberComponent, MultiSelectComponent, SubmitButtonComponent };