@cuby-ui/core 0.0.337 → 0.0.338
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/esm2022/widgets/select-modal/components/select-modal-search/select-modal-search.component.mjs +16 -6
- package/fesm2022/cuby-ui-core.mjs +11 -3
- package/fesm2022/cuby-ui-core.mjs.map +1 -1
- package/package.json +4 -4
- package/widgets/select-modal/components/select-modal-search/select-modal-search.component.d.ts +8 -3
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
|
2
|
-
import {
|
|
1
|
+
import { ChangeDetectionStrategy, Component, DestroyRef, inject, input, output } from '@angular/core';
|
|
2
|
+
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
3
|
+
import { ReactiveFormsModule } from '@angular/forms';
|
|
4
|
+
import { debounceTime } from 'rxjs';
|
|
3
5
|
import { CuiIconButtonModule } from '../../../../components/icon-button';
|
|
4
6
|
import { CuiInputModule } from '../../../../components/input-text';
|
|
5
7
|
import * as i0 from "@angular/core";
|
|
@@ -10,13 +12,21 @@ import * as i4 from "../../../../components/icon-button/icon-button.component";
|
|
|
10
12
|
import * as i5 from "@angular/forms";
|
|
11
13
|
export class CuiSelectModalSearchComponent {
|
|
12
14
|
constructor() {
|
|
13
|
-
this.
|
|
15
|
+
this.destroyRef = inject(DestroyRef);
|
|
16
|
+
this.searchControl = input.required();
|
|
17
|
+
this.controlDelay = input(700);
|
|
18
|
+
this.searchStringChanged = output();
|
|
19
|
+
}
|
|
20
|
+
ngOnInit() {
|
|
21
|
+
this.searchControl().valueChanges
|
|
22
|
+
.pipe(debounceTime(this.controlDelay()), takeUntilDestroyed(this.destroyRef))
|
|
23
|
+
.subscribe((value) => this.searchStringChanged.emit(value));
|
|
14
24
|
}
|
|
15
25
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CuiSelectModalSearchComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
16
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
26
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "18.2.13", type: CuiSelectModalSearchComponent, isStandalone: true, selector: "cui-select-modal-search", inputs: { searchControl: { classPropertyName: "searchControl", publicName: "searchControl", isSignal: true, isRequired: true, transformFunction: null }, controlDelay: { classPropertyName: "controlDelay", publicName: "controlDelay", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { searchStringChanged: "searchStringChanged" }, ngImport: i0, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl()\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"], dependencies: [{ kind: "ngmodule", type: CuiInputModule }, { kind: "component", type: i1.CuiInputTextComponent, selector: "cui-input-text" }, { kind: "directive", type: i2.CuiTextFieldIconLeftDirective, selector: "[cuiTextFieldIconLeft]", inputs: ["cuiTextFieldIconLeft"] }, { kind: "directive", type: i3.CuiTextFieldPlaceholderDirective, selector: "[cuiTextFieldPlaceholder]", inputs: ["cuiTextFieldPlaceholder"] }, { kind: "ngmodule", type: CuiIconButtonModule }, { kind: "component", type: i4.CuiIconButtonComponent, selector: "button[cuiIconButton][icon], a[cuiIconButton][icon]", inputs: ["icon", "color", "hoverColor"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
17
27
|
}
|
|
18
28
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CuiSelectModalSearchComponent, decorators: [{
|
|
19
29
|
type: Component,
|
|
20
|
-
args: [{ selector: 'cui-select-modal-search', imports: [CuiInputModule, CuiIconButtonModule, ReactiveFormsModule], standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"] }]
|
|
30
|
+
args: [{ selector: 'cui-select-modal-search', imports: [CuiInputModule, CuiIconButtonModule, ReactiveFormsModule], standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl()\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"] }]
|
|
21
31
|
}] });
|
|
22
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
32
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2VsZWN0LW1vZGFsLXNlYXJjaC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jb3JlL3dpZGdldHMvc2VsZWN0LW1vZGFsL2NvbXBvbmVudHMvc2VsZWN0LW1v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ICAgICAgICAgLnN1YnNjcmliZSgodmFsdWUpID0+IHRoaXMuc2VhcmNoU3RyaW5nQ2hhbmdlZC5lbWl0KHZhbHVlKSk7XG4gICAgfVxufVxuIiwiPGN1aS1pbnB1dC10ZXh0XG4gICAgY3VpVGV4dEZpZWxkUGxhY2Vob2xkZXI9XCJTZWFyY2guLi5cIlxuICAgIGN1aVRleHRGaWVsZEljb25MZWZ0PVwiY3VpSWNvblNlYXJjaFwiXG4gICAgW2Zvcm1Db250cm9sXT1cInNlYXJjaENvbnRyb2woKVwiXG4gICAgY2xhc3M9XCJzZWFyY2hcIlxuLz5cbjxidXR0b25cbiAgICBjbGFzcz1cImZpbHRlcnNcIlxuICAgIHR5cGU9XCJidXR0b25cIlxuICAgIGN1aUljb25CdXR0b25cbiAgICBpY29uPVwiY3VpSWNvbkZpbHRlcnNMaW5lc1wiXG4+PC9idXR0b24+XG4iXX0=
|
|
@@ -10040,14 +10040,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
10040
10040
|
|
|
10041
10041
|
class CuiSelectModalSearchComponent {
|
|
10042
10042
|
constructor() {
|
|
10043
|
-
this.
|
|
10043
|
+
this.destroyRef = inject(DestroyRef);
|
|
10044
|
+
this.searchControl = input.required();
|
|
10045
|
+
this.controlDelay = input(700);
|
|
10046
|
+
this.searchStringChanged = output();
|
|
10047
|
+
}
|
|
10048
|
+
ngOnInit() {
|
|
10049
|
+
this.searchControl().valueChanges
|
|
10050
|
+
.pipe(debounceTime(this.controlDelay()), takeUntilDestroyed(this.destroyRef))
|
|
10051
|
+
.subscribe((value) => this.searchStringChanged.emit(value));
|
|
10044
10052
|
}
|
|
10045
10053
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CuiSelectModalSearchComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
10046
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
10054
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "18.2.13", type: CuiSelectModalSearchComponent, isStandalone: true, selector: "cui-select-modal-search", inputs: { searchControl: { classPropertyName: "searchControl", publicName: "searchControl", isSignal: true, isRequired: true, transformFunction: null }, controlDelay: { classPropertyName: "controlDelay", publicName: "controlDelay", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { searchStringChanged: "searchStringChanged" }, ngImport: i0, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl()\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"], dependencies: [{ kind: "ngmodule", type: CuiInputModule }, { kind: "component", type: CuiInputTextComponent, selector: "cui-input-text" }, { kind: "directive", type: CuiTextFieldIconLeftDirective, selector: "[cuiTextFieldIconLeft]", inputs: ["cuiTextFieldIconLeft"] }, { kind: "directive", type: CuiTextFieldPlaceholderDirective, selector: "[cuiTextFieldPlaceholder]", inputs: ["cuiTextFieldPlaceholder"] }, { kind: "ngmodule", type: CuiIconButtonModule }, { kind: "component", type: CuiIconButtonComponent, selector: "button[cuiIconButton][icon], a[cuiIconButton][icon]", inputs: ["icon", "color", "hoverColor"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
10047
10055
|
}
|
|
10048
10056
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: CuiSelectModalSearchComponent, decorators: [{
|
|
10049
10057
|
type: Component,
|
|
10050
|
-
args: [{ selector: 'cui-select-modal-search', imports: [CuiInputModule, CuiIconButtonModule, ReactiveFormsModule], standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"] }]
|
|
10058
|
+
args: [{ selector: 'cui-select-modal-search', imports: [CuiInputModule, CuiIconButtonModule, ReactiveFormsModule], standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<cui-input-text\n cuiTextFieldPlaceholder=\"Search...\"\n cuiTextFieldIconLeft=\"cuiIconSearch\"\n [formControl]=\"searchControl()\"\n class=\"search\"\n/>\n<button\n class=\"filters\"\n type=\"button\"\n cuiIconButton\n icon=\"cuiIconFiltersLines\"\n></button>\n", styles: [":host{padding-right:15px;display:flex;align-items:center;gap:4px}.search{width:100%}.filters{padding:4px;width:auto;height:auto}\n"] }]
|
|
10051
10059
|
}] });
|
|
10052
10060
|
|
|
10053
10061
|
class CuiSelectModalComponent {
|