@ethlete/cdk 3.6.0 → 3.7.0
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/CHANGELOG.md +6 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/combobox.imports.mjs +5 -2
- package/esm2022/lib/components/forms/components/select/components/combobox/components/combobox/combobox.component.mjs +5 -2
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox/combobox.directive.mjs +60 -3
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/combobox-body-empty-template.directive.mjs +30 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/index.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/public-api.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/combobox-body-error-template.directive.mjs +30 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/index.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/public-api.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/combobox-body-loading-template.directive.mjs +30 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/index.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/public-api.mjs +2 -0
- package/esm2022/lib/components/forms/components/select/components/combobox/directives/public-api.mjs +4 -1
- package/esm2022/lib/components/forms/components/select/components/combobox/partials/combobox-body/combobox-body.component.mjs +5 -4
- package/esm2022/lib/components/forms/components/select/components/combobox/private/combobox.private.types.mjs +1 -1
- package/fesm2022/ethlete-cdk.mjs +151 -6
- package/fesm2022/ethlete-cdk.mjs.map +1 -1
- package/lib/components/forms/components/select/components/combobox/combobox.imports.d.ts +2 -2
- package/lib/components/forms/components/select/components/combobox/components/combobox/combobox.component.d.ts +1 -1
- package/lib/components/forms/components/select/components/combobox/directives/combobox/combobox.directive.d.ts +24 -3
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/combobox-body-empty-template.directive.d.ts +8 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/index.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-empty-template/public-api.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/combobox-body-error-template.directive.d.ts +8 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/index.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-error-template/public-api.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/combobox-body-loading-template.directive.d.ts +8 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/index.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/combobox-body-loading-template/public-api.d.ts +1 -0
- package/lib/components/forms/components/select/components/combobox/directives/public-api.d.ts +3 -0
- package/lib/components/forms/components/select/components/combobox/private/combobox.private.types.d.ts +6 -0
- package/package.json +1 -1
|
@@ -2,5 +2,5 @@ import { InputPrefixDirective, InputSuffixDirective } from '../../../../directiv
|
|
|
2
2
|
import { LabelComponent } from '../../../label';
|
|
3
3
|
import { SelectFieldComponent } from '../select-field';
|
|
4
4
|
import { ComboboxComponent } from './components';
|
|
5
|
-
import { ComboboxOptionTemplateDirective, ComboboxSelectedOptionTemplateDirective } from './directives';
|
|
6
|
-
export declare const ComboboxImports: readonly [typeof ComboboxComponent, typeof SelectFieldComponent, typeof InputPrefixDirective, typeof InputSuffixDirective, typeof LabelComponent, typeof ComboboxOptionTemplateDirective, typeof ComboboxSelectedOptionTemplateDirective];
|
|
5
|
+
import { ComboboxBodyEmptyTemplateDirective, ComboboxBodyErrorTemplateDirective, ComboboxBodyLoadingTemplateDirective, ComboboxOptionTemplateDirective, ComboboxSelectedOptionTemplateDirective } from './directives';
|
|
6
|
+
export declare const ComboboxImports: readonly [typeof ComboboxComponent, typeof SelectFieldComponent, typeof InputPrefixDirective, typeof InputSuffixDirective, typeof LabelComponent, typeof ComboboxOptionTemplateDirective, typeof ComboboxSelectedOptionTemplateDirective, typeof ComboboxBodyErrorTemplateDirective, typeof ComboboxBodyLoadingTemplateDirective, typeof ComboboxBodyEmptyTemplateDirective];
|
|
@@ -8,5 +8,5 @@ export declare class ComboboxComponent extends DecoratedInputBase {
|
|
|
8
8
|
protected readonly combobox: ComboboxDirective;
|
|
9
9
|
constructor();
|
|
10
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxComponent, never>;
|
|
11
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ComboboxComponent, "et-combobox", never, {}, {}, never, ["[etInputPrefix]", "[etInputSuffix]", "*"], true, [{ directive: typeof i1.AnimatedOverlayDirective; inputs: {}; outputs: {}; }, { directive: typeof i2.InputDirective; inputs: { "placeholder": "placeholder"; }; outputs: {}; }, { directive: typeof i3.ComboboxDirective; inputs: { "options": "options"; "initialValue": "initialValue"; "filterInternal": "filterInternal"; "loading": "loading"; "error": "error"; "emptyText": "emptyText"; "placeholder": "placeholder"; "multiple": "multiple"; "bindLabel": "bindLabel"; "bindValue": "bindValue"; "allowCustomValues": "allowCustomValues"; "selectedOptionComponent": "selectedOptionComponent"; "optionComponent": "optionComponent"; }; outputs: { "filterChange": "filterChange"; }; }]>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ComboboxComponent, "et-combobox", never, {}, {}, never, ["[etInputPrefix]", "[etInputSuffix]", "*"], true, [{ directive: typeof i1.AnimatedOverlayDirective; inputs: {}; outputs: {}; }, { directive: typeof i2.InputDirective; inputs: { "placeholder": "placeholder"; }; outputs: {}; }, { directive: typeof i3.ComboboxDirective; inputs: { "options": "options"; "initialValue": "initialValue"; "filterInternal": "filterInternal"; "loading": "loading"; "error": "error"; "emptyText": "emptyText"; "placeholder": "placeholder"; "multiple": "multiple"; "bindLabel": "bindLabel"; "bindValue": "bindValue"; "allowCustomValues": "allowCustomValues"; "selectedOptionComponent": "selectedOptionComponent"; "optionComponent": "optionComponent"; "bodyErrorComponent": "bodyErrorComponent"; "bodyLoadingComponent": "bodyLoadingComponent"; "bodyEmptyComponent": "bodyEmptyComponent"; }; outputs: { "filterChange": "filterChange"; }; }]>;
|
|
12
12
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ComponentType } from '@angular/cdk/overlay';
|
|
2
|
-
import { ElementRef, EventEmitter, InjectionToken, OnInit, TrackByFunction } from '@angular/core';
|
|
2
|
+
import { ElementRef, EventEmitter, InjectionToken, OnInit, TemplateRef, TrackByFunction } from '@angular/core';
|
|
3
3
|
import { AnimatedOverlayComponentBase, SelectionModel, SelectionModelBinding, TypedQueryList } from '@ethlete/core';
|
|
4
4
|
import { BehaviorSubject } from 'rxjs';
|
|
5
|
-
import { ComponentWithOption, TemplateRefWithOption } from '../../private';
|
|
5
|
+
import { ComponentWithError, ComponentWithOption, TemplateRefWithError, TemplateRefWithOption } from '../../private';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
export declare const COMBOBOX_TOKEN: InjectionToken<ComboboxDirective>;
|
|
8
8
|
export type AbstractComboboxBody = AnimatedOverlayComponentBase & {
|
|
@@ -49,6 +49,15 @@ export declare class ComboboxDirective implements OnInit {
|
|
|
49
49
|
get selectedOptionComponent(): ComponentWithOption | null;
|
|
50
50
|
set selectedOptionComponent(component: ComponentWithOption | null);
|
|
51
51
|
private readonly _selectedOptionComponent$;
|
|
52
|
+
get bodyErrorComponent(): ComponentWithError | null;
|
|
53
|
+
set bodyErrorComponent(value: ComponentWithError | null);
|
|
54
|
+
private _bodyErrorComponent$;
|
|
55
|
+
get bodyLoadingComponent(): ComponentType<unknown> | null;
|
|
56
|
+
set bodyLoadingComponent(value: ComponentType<unknown> | null);
|
|
57
|
+
private _bodyLoadingComponent$;
|
|
58
|
+
get bodyEmptyComponent(): ComponentType<unknown> | null;
|
|
59
|
+
set bodyEmptyComponent(value: ComponentType<unknown> | null);
|
|
60
|
+
private _bodyEmptyComponent$;
|
|
52
61
|
protected readonly filterChange: EventEmitter<string>;
|
|
53
62
|
private _shouldIgnoreNextBlurEvent;
|
|
54
63
|
private _deletedSearchWithKeyPress;
|
|
@@ -68,12 +77,24 @@ export declare class ComboboxDirective implements OnInit {
|
|
|
68
77
|
private readonly _optionTemplate$;
|
|
69
78
|
set selectedOptionTemplate(value: TemplateRefWithOption | undefined);
|
|
70
79
|
private readonly _selectedOptionTemplate$;
|
|
80
|
+
set bodyLoadingTemplate(value: TemplateRef<unknown> | undefined);
|
|
81
|
+
private readonly _bodyLoadingTemplate$;
|
|
82
|
+
set bodyErrorTemplate(value: TemplateRefWithError | undefined);
|
|
83
|
+
private readonly _bodyErrorTemplate$;
|
|
84
|
+
set bodyEmptyTemplate(value: TemplateRef<unknown> | undefined);
|
|
85
|
+
private readonly _bodyEmptyTemplate$;
|
|
71
86
|
readonly _bindings: import("@ethlete/core").ReactiveBindingResult;
|
|
72
87
|
private _comboboxBodyComponent;
|
|
73
88
|
readonly customOptionTpl$: import("rxjs").Observable<TemplateRefWithOption | null>;
|
|
74
89
|
readonly customOptionComponent$: import("rxjs").Observable<ComponentWithOption | null>;
|
|
75
90
|
readonly customSelectedOptionTpl$: import("rxjs").Observable<TemplateRefWithOption | null>;
|
|
76
91
|
readonly customSelectedOptionComponent$: import("rxjs").Observable<ComponentWithOption | null>;
|
|
92
|
+
readonly customBodyLoadingTpl$: import("rxjs").Observable<TemplateRef<unknown> | null>;
|
|
93
|
+
readonly customBodyLoadingComponent$: import("rxjs").Observable<ComponentType<unknown> | null>;
|
|
94
|
+
readonly customBodyErrorTpl$: import("rxjs").Observable<TemplateRefWithError | null>;
|
|
95
|
+
readonly customBodyErrorComponent$: import("rxjs").Observable<ComponentWithError | null>;
|
|
96
|
+
readonly customBodyEmptyTpl$: import("rxjs").Observable<TemplateRef<unknown> | null>;
|
|
97
|
+
readonly customBodyEmptyComponent$: import("rxjs").Observable<ComponentType<unknown> | null>;
|
|
77
98
|
constructor();
|
|
78
99
|
ngOnInit(): void;
|
|
79
100
|
setBodyComponent(component: ComponentType<AbstractComboboxBody>): void;
|
|
@@ -100,5 +121,5 @@ export declare class ComboboxDirective implements OnInit {
|
|
|
100
121
|
private _debugValidateComboboxConfig;
|
|
101
122
|
private _debugValidateOptionAndInitialValueSchema;
|
|
102
123
|
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxDirective, never>;
|
|
103
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxDirective, never, never, { "options": { "alias": "options"; "required": true; }; "initialValue": { "alias": "initialValue"; "required": false; }; "filterInternal": { "alias": "filterInternal"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "error": { "alias": "error"; "required": false; }; "emptyText": { "alias": "emptyText"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "bindLabel": { "alias": "bindLabel"; "required": false; }; "bindValue": { "alias": "bindValue"; "required": false; }; "bindKey": { "alias": "bindKey"; "required": false; }; "allowCustomValues": { "alias": "allowCustomValues"; "required": false; }; "optionComponent": { "alias": "optionComponent"; "required": false; }; "selectedOptionComponent": { "alias": "selectedOptionComponent"; "required": false; }; }, { "filterChange": "filterChange"; }, ["optionTemplate", "selectedOptionTemplate"], never, true, never>;
|
|
124
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxDirective, never, never, { "options": { "alias": "options"; "required": true; }; "initialValue": { "alias": "initialValue"; "required": false; }; "filterInternal": { "alias": "filterInternal"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "error": { "alias": "error"; "required": false; }; "emptyText": { "alias": "emptyText"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "bindLabel": { "alias": "bindLabel"; "required": false; }; "bindValue": { "alias": "bindValue"; "required": false; }; "bindKey": { "alias": "bindKey"; "required": false; }; "allowCustomValues": { "alias": "allowCustomValues"; "required": false; }; "optionComponent": { "alias": "optionComponent"; "required": false; }; "selectedOptionComponent": { "alias": "selectedOptionComponent"; "required": false; }; "bodyErrorComponent": { "alias": "bodyErrorComponent"; "required": false; }; "bodyLoadingComponent": { "alias": "bodyLoadingComponent"; "required": false; }; "bodyEmptyComponent": { "alias": "bodyEmptyComponent"; "required": false; }; }, { "filterChange": "filterChange"; }, ["optionTemplate", "selectedOptionTemplate", "bodyLoadingTemplate", "bodyErrorTemplate", "bodyEmptyTemplate"], never, true, never>;
|
|
104
125
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { InjectionToken, TemplateRef } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare const COMBOBOX_BODY_EMPTY_TEMPLATE_TOKEN: InjectionToken<ComboboxBodyEmptyTemplateDirective>;
|
|
4
|
+
export declare class ComboboxBodyEmptyTemplateDirective {
|
|
5
|
+
readonly template: TemplateRef<any>;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxBodyEmptyTemplateDirective, never>;
|
|
7
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxBodyEmptyTemplateDirective, "ng-template[etComboboxBodyEmptyTemplate]", ["etComboboxBodyEmptyTemplate"], {}, {}, never, never, true, never>;
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './public-api';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './combobox-body-empty-template.directive';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { InjectionToken, TemplateRef } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare const COMBOBOX_BODY_ERROR_TEMPLATE_TOKEN: InjectionToken<ComboboxBodyErrorTemplateDirective>;
|
|
4
|
+
export declare class ComboboxBodyErrorTemplateDirective {
|
|
5
|
+
readonly template: TemplateRef<any>;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxBodyErrorTemplateDirective, never>;
|
|
7
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxBodyErrorTemplateDirective, "ng-template[etComboboxBodyErrorTemplate]", ["etComboboxBodyErrorTemplate"], {}, {}, never, never, true, never>;
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './public-api';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './combobox-body-error-template.directive';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { InjectionToken, TemplateRef } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare const COMBOBOX_BODY_LOADING_TEMPLATE_TOKEN: InjectionToken<ComboboxBodyLoadingTemplateDirective>;
|
|
4
|
+
export declare class ComboboxBodyLoadingTemplateDirective {
|
|
5
|
+
readonly template: TemplateRef<any>;
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ComboboxBodyLoadingTemplateDirective, never>;
|
|
7
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<ComboboxBodyLoadingTemplateDirective, "ng-template[etComboboxBodyLoadingTemplate]", ["etComboboxBodyLoadingTemplate"], {}, {}, never, never, true, never>;
|
|
8
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './public-api';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './combobox-body-loading-template.directive';
|
package/lib/components/forms/components/select/components/combobox/directives/public-api.d.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
export * from './combobox-body-empty-template/public-api';
|
|
2
|
+
export * from './combobox-body-error-template/public-api';
|
|
3
|
+
export * from './combobox-body-loading-template/public-api';
|
|
1
4
|
export * from './combobox-option-template/public-api';
|
|
2
5
|
export * from './combobox-selected-option-template/public-api';
|
|
3
6
|
export * from './combobox/public-api';
|
|
@@ -24,3 +24,9 @@ export type TemplateRefWithOption = TemplateRef<{
|
|
|
24
24
|
export type ComponentWithOption = ComponentType<{
|
|
25
25
|
option: any;
|
|
26
26
|
}>;
|
|
27
|
+
export type TemplateRefWithError = TemplateRef<{
|
|
28
|
+
error: unknown;
|
|
29
|
+
}>;
|
|
30
|
+
export type ComponentWithError = ComponentType<{
|
|
31
|
+
error: any;
|
|
32
|
+
}>;
|