@koobiq/components 19.7.0 → 19.8.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/accordion/accordion-content.directive.d.ts +1 -0
- package/autocomplete/autocomplete-trigger.directive.d.ts +2 -1
- package/autocomplete/autocomplete.component.d.ts +7 -1
- package/code-block/_code-block-theme.scss +1 -10
- package/code-block/code-block-highlight.d.ts +61 -7
- package/code-block/code-block-tokens.scss +5 -10
- package/code-block/code-block.d.ts +14 -1
- package/code-block/code-block.scss +8 -7
- package/core/forms/forms-tokens.scss +1 -1
- package/core/locales/en-US.d.ts +1 -0
- package/core/locales/es-LA.d.ts +1 -0
- package/core/locales/locale-service.d.ts +5 -0
- package/core/locales/pt-BR.d.ts +1 -0
- package/core/locales/ru-RU.d.ts +1 -0
- package/core/locales/tk-TM.d.ts +1 -0
- package/core/option/option.d.ts +2 -1
- package/core/styles/common/_groups-mixins.scss +2 -2
- package/core/styles/common/_groups.scss +6 -6
- package/dropdown/dropdown-item.scss +9 -6
- package/dropdown/dropdown-tokens.scss +1 -1
- package/dropdown/dropdown-trigger.directive.d.ts +8 -1
- package/dropdown/dropdown.component.d.ts +6 -6
- package/dropdown/dropdown.scss +1 -1
- package/dropdown/dropdown.types.d.ts +19 -7
- package/fesm2022/koobiq-components-accordion.mjs +32 -29
- package/fesm2022/koobiq-components-accordion.mjs.map +1 -1
- package/fesm2022/koobiq-components-actions-panel.mjs +10 -10
- package/fesm2022/koobiq-components-alert.mjs +16 -16
- package/fesm2022/koobiq-components-app-switcher.mjs +25 -25
- package/fesm2022/koobiq-components-app-switcher.mjs.map +1 -1
- package/fesm2022/koobiq-components-autocomplete.mjs +35 -23
- package/fesm2022/koobiq-components-autocomplete.mjs.map +1 -1
- package/fesm2022/koobiq-components-badge.mjs +13 -13
- package/fesm2022/koobiq-components-breadcrumbs.mjs +25 -25
- package/fesm2022/koobiq-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/koobiq-components-button-toggle.mjs +10 -10
- package/fesm2022/koobiq-components-button.mjs +19 -19
- package/fesm2022/koobiq-components-button.mjs.map +1 -1
- package/fesm2022/koobiq-components-checkbox.mjs +10 -10
- package/fesm2022/koobiq-components-clamped-text.mjs +13 -13
- package/fesm2022/koobiq-components-clamped-text.mjs.map +1 -1
- package/fesm2022/koobiq-components-code-block.mjs +143 -46
- package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
- package/fesm2022/koobiq-components-content-panel.mjs +28 -28
- package/fesm2022/koobiq-components-core.mjs +229 -225
- package/fesm2022/koobiq-components-core.mjs.map +1 -1
- package/fesm2022/koobiq-components-datepicker.mjs +37 -42
- package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-divider.mjs +7 -7
- package/fesm2022/koobiq-components-dl.mjs +13 -13
- package/fesm2022/koobiq-components-dropdown.mjs +69 -38
- package/fesm2022/koobiq-components-dropdown.mjs.map +1 -1
- package/fesm2022/koobiq-components-dynamic-translation.mjs +13 -13
- package/fesm2022/koobiq-components-ellipsis-center.mjs +7 -7
- package/fesm2022/koobiq-components-empty-state.mjs +19 -19
- package/fesm2022/koobiq-components-file-upload.mjs +39 -39
- package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
- package/fesm2022/koobiq-components-filter-bar.mjs +85 -85
- package/fesm2022/koobiq-components-filter-bar.mjs.map +1 -1
- package/fesm2022/koobiq-components-form-field.mjs +83 -81
- package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
- package/fesm2022/koobiq-components-icon.mjs +343 -21
- package/fesm2022/koobiq-components-icon.mjs.map +1 -1
- package/fesm2022/koobiq-components-inline-edit.mjs +19 -17
- package/fesm2022/koobiq-components-inline-edit.mjs.map +1 -1
- package/fesm2022/koobiq-components-input.mjs +22 -22
- package/fesm2022/koobiq-components-link.mjs +7 -7
- package/fesm2022/koobiq-components-list.mjs +19 -19
- package/fesm2022/koobiq-components-loader-overlay.mjs +16 -16
- package/fesm2022/koobiq-components-markdown.mjs +10 -10
- package/fesm2022/koobiq-components-modal.mjs +28 -28
- package/fesm2022/koobiq-components-modal.mjs.map +1 -1
- package/fesm2022/koobiq-components-navbar-ic.mjs +40 -40
- package/fesm2022/koobiq-components-navbar-ic.mjs.map +1 -1
- package/fesm2022/koobiq-components-navbar.mjs +82 -56
- package/fesm2022/koobiq-components-navbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-notification-center.mjs +168 -31
- package/fesm2022/koobiq-components-notification-center.mjs.map +1 -1
- package/fesm2022/koobiq-components-overflow-items.mjs +16 -16
- package/fesm2022/koobiq-components-popover.mjs +18 -18
- package/fesm2022/koobiq-components-popover.mjs.map +1 -1
- package/fesm2022/koobiq-components-progress-bar.mjs +13 -13
- package/fesm2022/koobiq-components-progress-spinner.mjs +13 -13
- package/fesm2022/koobiq-components-radio.mjs +10 -10
- package/fesm2022/koobiq-components-resizer.mjs +10 -10
- package/fesm2022/koobiq-components-risk-level.mjs +7 -7
- package/fesm2022/koobiq-components-scrollbar.mjs +12 -12
- package/fesm2022/koobiq-components-scrollbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-search-expandable.mjs +7 -7
- package/fesm2022/koobiq-components-select.mjs +129 -64
- package/fesm2022/koobiq-components-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidebar.mjs +13 -13
- package/fesm2022/koobiq-components-sidepanel.mjs +28 -28
- package/fesm2022/koobiq-components-sidepanel.mjs.map +1 -1
- package/fesm2022/koobiq-components-skeleton.mjs +10 -10
- package/fesm2022/koobiq-components-split-button.mjs +7 -7
- package/fesm2022/koobiq-components-splitter.mjs +16 -16
- package/fesm2022/koobiq-components-table.mjs +10 -10
- package/fesm2022/koobiq-components-tabs.mjs +54 -54
- package/fesm2022/koobiq-components-tabs.mjs.map +1 -1
- package/fesm2022/koobiq-components-tags.mjs +38 -31
- package/fesm2022/koobiq-components-tags.mjs.map +1 -1
- package/fesm2022/koobiq-components-textarea.mjs +7 -7
- package/fesm2022/koobiq-components-time-range.mjs +22 -22
- package/fesm2022/koobiq-components-timepicker.mjs +11 -26
- package/fesm2022/koobiq-components-timepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-timezone.mjs +58 -37
- package/fesm2022/koobiq-components-timezone.mjs.map +1 -1
- package/fesm2022/koobiq-components-title.mjs +7 -7
- package/fesm2022/koobiq-components-toast.mjs +58 -39
- package/fesm2022/koobiq-components-toast.mjs.map +1 -1
- package/fesm2022/koobiq-components-toggle.mjs +7 -7
- package/fesm2022/koobiq-components-tooltip.mjs +16 -16
- package/fesm2022/koobiq-components-top-bar.mjs +17 -25
- package/fesm2022/koobiq-components-top-bar.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree-select.mjs +14 -8
- package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree.mjs +74 -39
- package/fesm2022/koobiq-components-tree.mjs.map +1 -1
- package/fesm2022/koobiq-components-username.mjs +28 -28
- package/fesm2022/koobiq-components-username.mjs.map +1 -1
- package/file-upload/multiple-file-upload.component.scss +6 -0
- package/file-upload/single-file-upload.component.scss +6 -0
- package/form-field/_form-field-theme.scss +9 -4
- package/form-field/fieldset-tokens.scss +1 -0
- package/form-field/fieldset.scss +1 -0
- package/form-field/form-field-tokens.scss +1 -0
- package/form-field/password-toggle.scss +1 -1
- package/icon/icon-button.scss +5 -0
- package/icon/icon-item.scss +5 -0
- package/icon/icon-registry-providers.d.ts +34 -0
- package/icon/icon-registry.d.ts +50 -0
- package/icon/icon.component.d.ts +16 -3
- package/icon/icon.scss +7 -0
- package/icon/public-api.d.ts +2 -0
- package/inline-edit/inline-edit.d.ts +3 -1
- package/inline-edit/inline-edit.scss +1 -11
- package/link/_link-theme.scss +9 -2
- package/navbar/_navbar-theme.scss +0 -4
- package/navbar/navbar-brand.component.d.ts +3 -1
- package/navbar/navbar-item.component.d.ts +1 -0
- package/navbar/navbar-item.scss +9 -0
- package/navbar/navbar.component.d.ts +1 -0
- package/notification-center/_notification-center-theme.scss +2 -1
- package/notification-center/notification-center.d.ts +29 -1
- package/notification-center/notification-center.scss +28 -3
- package/notification-center/notification-center.service.d.ts +44 -1
- package/notification-center/notification-item.scss +1 -1
- package/package.json +5 -5
- package/popover/popover.scss +3 -3
- package/prebuilt-themes/dark-theme.css +1 -1
- package/prebuilt-themes/light-theme.css +1 -1
- package/prebuilt-themes/theme.css +1 -1
- package/schematics/ng-add/index.js +4 -4
- package/scrollbar/scrollbar-tokens.scss +1 -1
- package/select/select-option.directive.d.ts +9 -10
- package/select/select.component.d.ts +42 -3
- package/tabs/_tabs-common.scss +4 -1
- package/timepicker/timepicker.directive.d.ts +1 -0
- package/timezone/timezone-option.directive.d.ts +12 -9
- package/toast/toast.service.d.ts +5 -3
- package/top-bar/top-bar.d.ts +0 -7
- package/top-bar/top-bar.scss +3 -9
- package/tree/tree-selection.component.d.ts +7 -0
|
@@ -62,6 +62,8 @@ export declare class KbqInlineEdit {
|
|
|
62
62
|
readonly editModeWidth: import("@angular/core").InputSignalWithTransform<number | undefined, unknown>;
|
|
63
63
|
/** User-defined tooltip placement */
|
|
64
64
|
readonly tooltipPlacement: import("@angular/core").InputSignal<PopUpPlacements | undefined>;
|
|
65
|
+
/** Classes to be passed to the inline edit panel. */
|
|
66
|
+
readonly overlayPanelClass: import("@angular/core").InputSignal<string | string[]>;
|
|
65
67
|
/** Handler function to retrieve the current value */
|
|
66
68
|
readonly getValueHandler: import("@angular/core").InputSignal<(() => unknown) | undefined>;
|
|
67
69
|
/** Handler function to update the value */
|
|
@@ -155,5 +157,5 @@ export declare class KbqInlineEdit {
|
|
|
155
157
|
private getInputNativeElement;
|
|
156
158
|
private markAllAsTouched;
|
|
157
159
|
static ɵfac: i0.ɵɵFactoryDeclaration<KbqInlineEdit, never>;
|
|
158
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<KbqInlineEdit, "kbq-inline-edit", ["kbqInlineEdit"], { "showActions": { "alias": "showActions"; "required": false; "isSignal": true; }; "showTooltipOnError": { "alias": "showTooltipOnError"; "required": false; "isSignal": true; }; "validationTooltip": { "alias": "validationTooltip"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "editModeWidth": { "alias": "editModeWidth"; "required": false; "isSignal": true; }; "tooltipPlacement": { "alias": "tooltipPlacement"; "required": false; "isSignal": true; }; "getValueHandler": { "alias": "getValueHandler"; "required": false; "isSignal": true; }; "setValueHandler": { "alias": "setValueHandler"; "required": false; "isSignal": true; }; "canSaveOnEnter": { "alias": "canSaveOnEnter"; "required": false; "isSignal": true; }; "interactiveSelectors": { "alias": "interactiveSelectors"; "required": false; "isSignal": true; }; }, { "saved": "saved"; "canceled": "canceled"; "modeChange": "modeChange"; }, ["menu", "label", "formFieldRefList"], ["kbq-label", "[kbqInlineEditViewMode]", "[kbqInlineEditMenu]", "[kbqInlineEditEditMode]"], true, [{ directive: typeof i1.CdkMonitorFocus; inputs: {}; outputs: {}; }]>;
|
|
160
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<KbqInlineEdit, "kbq-inline-edit", ["kbqInlineEdit"], { "showActions": { "alias": "showActions"; "required": false; "isSignal": true; }; "showTooltipOnError": { "alias": "showTooltipOnError"; "required": false; "isSignal": true; }; "validationTooltip": { "alias": "validationTooltip"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "editModeWidth": { "alias": "editModeWidth"; "required": false; "isSignal": true; }; "tooltipPlacement": { "alias": "tooltipPlacement"; "required": false; "isSignal": true; }; "overlayPanelClass": { "alias": "overlayPanelClass"; "required": false; "isSignal": true; }; "getValueHandler": { "alias": "getValueHandler"; "required": false; "isSignal": true; }; "setValueHandler": { "alias": "setValueHandler"; "required": false; "isSignal": true; }; "canSaveOnEnter": { "alias": "canSaveOnEnter"; "required": false; "isSignal": true; }; "interactiveSelectors": { "alias": "interactiveSelectors"; "required": false; "isSignal": true; }; }, { "saved": "saved"; "canceled": "canceled"; "modeChange": "modeChange"; }, ["menu", "label", "formFieldRefList"], ["kbq-label", "[kbqInlineEditViewMode]", "[kbqInlineEditMenu]", "[kbqInlineEditEditMode]"], true, [{ directive: typeof i1.CdkMonitorFocus; inputs: {}; outputs: {}; }]>;
|
|
159
161
|
}
|
|
@@ -78,11 +78,6 @@
|
|
|
78
78
|
.kbq-label {
|
|
79
79
|
color: var(--kbq-inline-edit-label-color);
|
|
80
80
|
}
|
|
81
|
-
|
|
82
|
-
.kbq-inline-edit__focus_container {
|
|
83
|
-
display: flex;
|
|
84
|
-
flex-direction: column;
|
|
85
|
-
}
|
|
86
81
|
}
|
|
87
82
|
|
|
88
83
|
@mixin _inline-edit-typography {
|
|
@@ -123,13 +118,8 @@
|
|
|
123
118
|
}
|
|
124
119
|
|
|
125
120
|
&.kbq-inline-edit_view {
|
|
126
|
-
.kbq-inline-edit__view-container
|
|
127
|
-
display: flex;
|
|
128
|
-
text-overflow: ellipsis;
|
|
129
|
-
}
|
|
130
|
-
|
|
121
|
+
.kbq-inline-edit__view-container,
|
|
131
122
|
.kbq-inline-edit__view-content {
|
|
132
|
-
display: inline-block;
|
|
133
123
|
text-overflow: ellipsis;
|
|
134
124
|
}
|
|
135
125
|
}
|
package/link/_link-theme.scss
CHANGED
|
@@ -29,8 +29,15 @@
|
|
|
29
29
|
box-decoration-break: clone;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
&.kbq-text-with-icon
|
|
33
|
-
|
|
32
|
+
&.kbq-text-with-icon {
|
|
33
|
+
.kbq-icon {
|
|
34
|
+
vertical-align: baseline;
|
|
35
|
+
|
|
36
|
+
&:has(> svg) {
|
|
37
|
+
vertical-align: middle;
|
|
38
|
+
line-height: 0;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
34
41
|
}
|
|
35
42
|
|
|
36
43
|
&.kbq-text-with-icon .kbq-link__text {
|
|
@@ -16,7 +16,9 @@ export declare class KbqNavbarBrand extends KbqTooltipTrigger implements AfterCo
|
|
|
16
16
|
/** alternative display of the brand name in two lines */
|
|
17
17
|
longTitle: boolean;
|
|
18
18
|
/** text that will be displayed in the tooltip. By default, the text is taken from kbq-navbar-title. */
|
|
19
|
-
collapsedText: string;
|
|
19
|
+
get collapsedText(): string;
|
|
20
|
+
set collapsedText(value: string);
|
|
21
|
+
private _collapsedText;
|
|
20
22
|
get isLink(): boolean;
|
|
21
23
|
/** @docs-private */
|
|
22
24
|
get croppedText(): string;
|
|
@@ -122,6 +122,7 @@ export declare class KbqNavbarItem extends KbqTooltipTrigger implements AfterCon
|
|
|
122
122
|
get hasCroppedText(): boolean;
|
|
123
123
|
constructor(rectangleElement: KbqNavbarRectangleElement, navbarFocusableItem: KbqNavbarFocusableItem, changeDetectorRef: ChangeDetectorRef, dropdownTrigger: KbqDropdownTrigger, bento: KbqNavbarBento);
|
|
124
124
|
ngAfterContentInit(): void;
|
|
125
|
+
updateDropdown(): void;
|
|
125
126
|
updateTooltip(): void;
|
|
126
127
|
getTitleWidth(): number;
|
|
127
128
|
onKeyDown($event: KeyboardEvent): void;
|
package/navbar/navbar-item.scss
CHANGED
|
@@ -20,6 +20,15 @@
|
|
|
20
20
|
min-height: var(--kbq-size-l);
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
// Filled fade-contrast only: its background is a semi-transparent tint, so the
|
|
24
|
+
// navbar icon shows through. Composite the tint over an opaque bg-tertiary substrate.
|
|
25
|
+
// The outline variant is intentionally left untouched — it stays a clean transparent outline.
|
|
26
|
+
& .kbq-badge-filled.kbq-badge_fade-contrast {
|
|
27
|
+
background:
|
|
28
|
+
linear-gradient(var(--kbq-background-contrast-fade), var(--kbq-background-contrast-fade)),
|
|
29
|
+
var(--kbq-background-bg-tertiary);
|
|
30
|
+
}
|
|
31
|
+
|
|
23
32
|
& .kbq-button-icon {
|
|
24
33
|
position: absolute;
|
|
25
34
|
padding-left: var(--kbq-size-xs);
|
|
@@ -14,6 +14,7 @@ export declare class KbqFocusableComponent implements AfterContentInit, AfterVie
|
|
|
14
14
|
get tabIndex(): any;
|
|
15
15
|
set tabIndex(value: any);
|
|
16
16
|
private _tabIndex;
|
|
17
|
+
private lastFocusOrigin;
|
|
17
18
|
get optionFocusChanges(): Observable<KbqNavbarFocusableItemEvent>;
|
|
18
19
|
get optionBlurChanges(): Observable<KbqNavbarFocusableItemEvent>;
|
|
19
20
|
private readonly destroyRef;
|
|
@@ -14,6 +14,7 @@ export declare const KBQ_NOTIFICATION_CENTER_DEFAULT_CONFIGURATION: {
|
|
|
14
14
|
noNotifications: string;
|
|
15
15
|
failedToLoadNotifications: string;
|
|
16
16
|
repeat: string;
|
|
17
|
+
loadingMore: string;
|
|
17
18
|
};
|
|
18
19
|
/** Injection Token for providing configuration of notification-center */
|
|
19
20
|
export declare const KBQ_NOTIFICATION_CENTER_CONFIGURATION: InjectionToken<unknown>;
|
|
@@ -46,6 +47,11 @@ export declare class KbqNotificationCenterComponent extends KbqPopUp implements
|
|
|
46
47
|
protected isTopOverflow: boolean;
|
|
47
48
|
/** @docs-private */
|
|
48
49
|
protected isBottomOverflow: boolean;
|
|
50
|
+
/** Distance in pixels from the bottom of the list at which the next page is requested.
|
|
51
|
+
* @docs-private */
|
|
52
|
+
protected scrolledToBottomOffset: number;
|
|
53
|
+
/** Emits on every scroll of the list container; drives the scroll-to-bottom check. */
|
|
54
|
+
private readonly scroll$;
|
|
49
55
|
/** localized data
|
|
50
56
|
* @docs-private */
|
|
51
57
|
get localeData(): any;
|
|
@@ -61,6 +67,25 @@ export declare class KbqNotificationCenterComponent extends KbqPopUp implements
|
|
|
61
67
|
private _popoverHeight;
|
|
62
68
|
constructor();
|
|
63
69
|
ngAfterViewInit(): void;
|
|
70
|
+
/** Handles the list container scroll: updates overflow shadows and feeds the scroll-to-bottom check.
|
|
71
|
+
* @docs-private */
|
|
72
|
+
protected onContainerScroll(): void;
|
|
73
|
+
/** Retries loading the next page from the bottom error row.
|
|
74
|
+
* @docs-private */
|
|
75
|
+
protected retryLoadMore(): void;
|
|
76
|
+
/**
|
|
77
|
+
* Requests the next page (via `service.onNextPage`) once the list is scrolled to within
|
|
78
|
+
* `scrolledToBottomOffset` pixels of the bottom. Two triggers feed it: the user scrolling, and a
|
|
79
|
+
* page finishing loading. The latter keeps paging when a freshly loaded page is too short to
|
|
80
|
+
* overflow the viewport — otherwise no further scroll event would fire and pagination would
|
|
81
|
+
* stall. Suppressed while a load is in flight, errored, or when there is nothing more to load.
|
|
82
|
+
*/
|
|
83
|
+
private subscribeToScrolledToBottom;
|
|
84
|
+
/** Whether the list is scrolled to within `scrolledToBottomOffset` pixels of the bottom. */
|
|
85
|
+
private isScrolledToBottom;
|
|
86
|
+
/** Emits `onNextPage` unless a load is already in flight, errored, or there is nothing more to load. */
|
|
87
|
+
private requestNextPage;
|
|
88
|
+
private focusScrollContainer;
|
|
64
89
|
/** @docs-private */
|
|
65
90
|
updateClassMap(placement: string, customClass: string, size: KbqPopUpSizeValues): void;
|
|
66
91
|
/** @docs-private */
|
|
@@ -102,6 +127,8 @@ export declare class KbqNotificationCenterTrigger extends KbqPopUpTrigger<KbqNot
|
|
|
102
127
|
panelClass: string;
|
|
103
128
|
/** Offset of popUp */
|
|
104
129
|
offset: number | null;
|
|
130
|
+
/** Distance in pixels from the bottom of the list at which the next page is requested via `onNextPage`. */
|
|
131
|
+
scrolledToBottomOffset: number;
|
|
105
132
|
/** Use popover or not */
|
|
106
133
|
get popoverMode(): boolean;
|
|
107
134
|
set popoverMode(value: boolean);
|
|
@@ -149,8 +176,9 @@ export declare class KbqNotificationCenterTrigger extends KbqPopUpTrigger<KbqNot
|
|
|
149
176
|
/** @docs-private */
|
|
150
177
|
closingActions(): import("rxjs").Observable<void | import("@angular/cdk/scrolling-module.d-ud2XrbF8").C | MouseEvent>;
|
|
151
178
|
static ɵfac: i0.ɵɵFactoryDeclaration<KbqNotificationCenterTrigger, never>;
|
|
152
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<KbqNotificationCenterTrigger, "[kbqNotificationCenterTrigger]", ["kbqNotificationCenterTrigger"], { "placement": { "alias": "kbqNotificationCenterPlacement"; "required": false; }; "backdropClass": { "alias": "backdropClass"; "required": false; }; "panelClass": { "alias": "kbqNotificationCenterPanelClass"; "required": false; }; "offset": { "alias": "offset"; "required": false; }; "popoverMode": { "alias": "popoverMode"; "required": false; }; "popoverHeight": { "alias": "popoverHeight"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "stickToWindow": { "alias": "stickToWindow"; "required": false; }; "container": { "alias": "container"; "required": false; }; }, { "placementChange": "kbqPlacementChange"; "visibleChange": "kbqVisibleChange"; }, never, never, true, never>;
|
|
179
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<KbqNotificationCenterTrigger, "[kbqNotificationCenterTrigger]", ["kbqNotificationCenterTrigger"], { "placement": { "alias": "kbqNotificationCenterPlacement"; "required": false; }; "backdropClass": { "alias": "backdropClass"; "required": false; }; "panelClass": { "alias": "kbqNotificationCenterPanelClass"; "required": false; }; "offset": { "alias": "offset"; "required": false; }; "scrolledToBottomOffset": { "alias": "scrolledToBottomOffset"; "required": false; }; "popoverMode": { "alias": "popoverMode"; "required": false; }; "popoverHeight": { "alias": "popoverHeight"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "stickToWindow": { "alias": "stickToWindow"; "required": false; }; "container": { "alias": "container"; "required": false; }; }, { "placementChange": "kbqPlacementChange"; "visibleChange": "kbqVisibleChange"; }, never, never, true, never>;
|
|
153
180
|
static ngAcceptInputType_offset: unknown;
|
|
181
|
+
static ngAcceptInputType_scrolledToBottomOffset: unknown;
|
|
154
182
|
static ngAcceptInputType_popoverMode: unknown;
|
|
155
183
|
static ngAcceptInputType_disabled: unknown;
|
|
156
184
|
}
|
|
@@ -36,7 +36,7 @@
|
|
|
36
36
|
|
|
37
37
|
justify-content: space-between;
|
|
38
38
|
|
|
39
|
-
padding: var(--kbq-size-
|
|
39
|
+
padding: var(--kbq-size-m) var(--kbq-size-xl) var(--kbq-size-xxs) var(--kbq-size-xxl);
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
.kbq-notification-center-title {
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
display: flex;
|
|
68
68
|
flex-direction: row;
|
|
69
69
|
|
|
70
|
-
padding: var(--kbq-size-s) var(--kbq-size-
|
|
70
|
+
padding: var(--kbq-size-s) var(--kbq-size-xl);
|
|
71
71
|
|
|
72
72
|
& .kbq-notification-center-sub-header__button {
|
|
73
73
|
position: absolute;
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
|
|
93
93
|
border-radius: inherit;
|
|
94
94
|
|
|
95
|
-
padding-bottom: var(--kbq-size-
|
|
95
|
+
padding-bottom: var(--kbq-size-xl);
|
|
96
96
|
|
|
97
97
|
& .kbq-loader-overlay_parent {
|
|
98
98
|
border-radius: inherit;
|
|
@@ -103,6 +103,31 @@
|
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
+
.kbq-notification-center-load-more {
|
|
107
|
+
display: flex;
|
|
108
|
+
|
|
109
|
+
align-items: center;
|
|
110
|
+
justify-content: center;
|
|
111
|
+
|
|
112
|
+
padding: 26px 0;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.kbq-notification-center-load-more-error {
|
|
116
|
+
display: flex;
|
|
117
|
+
flex-direction: column;
|
|
118
|
+
|
|
119
|
+
align-items: center;
|
|
120
|
+
justify-content: center;
|
|
121
|
+
|
|
122
|
+
padding: var(--kbq-size-xxs) var(--kbq-size-xxl);
|
|
123
|
+
|
|
124
|
+
text-align: center;
|
|
125
|
+
|
|
126
|
+
& .kbq-button {
|
|
127
|
+
margin-top: var(--kbq-size-s);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
106
131
|
.kbq-notification-center-empty-container,
|
|
107
132
|
.kbq-notification-center-error-container {
|
|
108
133
|
display: flex;
|
|
@@ -4,6 +4,8 @@ import { BehaviorSubject, Observable } from 'rxjs';
|
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
export interface KbqNotificationItem extends Omit<KbqToastData, 'closeButton'> {
|
|
6
6
|
id?: string;
|
|
7
|
+
/** Numeric id of the shown toast, set by `push()` and consumed by `hideToast()`. */
|
|
8
|
+
toastId?: number;
|
|
7
9
|
title?: string | TemplateRef<unknown>;
|
|
8
10
|
style?: string | KbqToastStyle;
|
|
9
11
|
icon?: boolean | TemplateRef<unknown>;
|
|
@@ -19,6 +21,13 @@ type KbqNotificationsGroup = {
|
|
|
19
21
|
title: string;
|
|
20
22
|
items: KbqNotificationItem[];
|
|
21
23
|
};
|
|
24
|
+
/** Payload emitted by `KbqNotificationCenterService.onDelete`. */
|
|
25
|
+
export type KbqNotificationDeleteEvent = {
|
|
26
|
+
/** What was removed: a single item, a whole date group, or all notifications. */
|
|
27
|
+
type: 'item' | 'group' | 'all';
|
|
28
|
+
/** The notification items that were removed. */
|
|
29
|
+
items: KbqNotificationItem[];
|
|
30
|
+
};
|
|
22
31
|
export declare class KbqNotificationCenterService {
|
|
23
32
|
/** @docs-private */
|
|
24
33
|
private readonly adapter;
|
|
@@ -32,12 +41,36 @@ export declare class KbqNotificationCenterService {
|
|
|
32
41
|
readonly loadingMode: BehaviorSubject<boolean>;
|
|
33
42
|
/** @docs-private */
|
|
34
43
|
readonly errorMode: BehaviorSubject<boolean>;
|
|
44
|
+
/**
|
|
45
|
+
* Whether the bottom "load more" spinner is shown while the next page is being loaded.
|
|
46
|
+
* Note: this is the infinite-scroll indicator and is distinct from `loadingMode`,
|
|
47
|
+
* which renders the full-screen loader instead of the list.
|
|
48
|
+
*/
|
|
49
|
+
readonly loadingMore: BehaviorSubject<boolean>;
|
|
50
|
+
/**
|
|
51
|
+
* Whether the bottom "load more" error row (with a retry button) is shown.
|
|
52
|
+
* Distinct from `errorMode`, which replaces the whole list with the full-screen error state.
|
|
53
|
+
*/
|
|
54
|
+
readonly loadMoreErrorMode: BehaviorSubject<boolean>;
|
|
55
|
+
/**
|
|
56
|
+
* Whether there are more notifications to load. While `true`, scrolling to the bottom
|
|
57
|
+
* emits `onNextPage`; set it to `false` to stop further infinite-scroll requests.
|
|
58
|
+
*/
|
|
59
|
+
readonly hasMore: BehaviorSubject<boolean>;
|
|
35
60
|
/** @docs-private */
|
|
36
61
|
readonly onRead: BehaviorSubject<KbqNotificationItem | null>;
|
|
37
62
|
/** Triggers an event when the user presses the reload button. */
|
|
38
63
|
readonly onReload: EventEmitter<void>;
|
|
64
|
+
/** Triggers an event when the list is scrolled to the bottom and the next page should be loaded. */
|
|
65
|
+
readonly onNextPage: EventEmitter<void>;
|
|
66
|
+
/** Triggers an event when an item, a group, or all notifications are removed. */
|
|
67
|
+
readonly onDelete: EventEmitter<KbqNotificationDeleteEvent>;
|
|
39
68
|
private originalItems;
|
|
40
|
-
/**
|
|
69
|
+
/**
|
|
70
|
+
* Grouped notifications, always ordered from newest to oldest: day groups are sorted by date
|
|
71
|
+
* descending, and notifications within each day are sorted by date descending.
|
|
72
|
+
* @docs-private
|
|
73
|
+
*/
|
|
41
74
|
readonly groupedItems: Observable<KbqNotificationsGroup[]>;
|
|
42
75
|
/** Emits an event whenever the changes. */
|
|
43
76
|
readonly changes: Observable<boolean | KbqNotificationItem | KbqNotificationItem[] | null>;
|
|
@@ -55,8 +88,16 @@ export declare class KbqNotificationCenterService {
|
|
|
55
88
|
setLoadingMode(value: boolean): void;
|
|
56
89
|
/** Set error mode */
|
|
57
90
|
setErrorMode(value: boolean): void;
|
|
91
|
+
/** Set the bottom "load more" spinner visibility. */
|
|
92
|
+
setLoadingMore(value: boolean): void;
|
|
93
|
+
/** Set the bottom "load more" error state visibility. */
|
|
94
|
+
setLoadMoreErrorMode(value: boolean): void;
|
|
95
|
+
/** Set whether there are more notifications to load via infinite scroll. */
|
|
96
|
+
setHasMore(value: boolean): void;
|
|
58
97
|
/** Push new notification item in center */
|
|
59
98
|
push(item: KbqNotificationItem): void;
|
|
99
|
+
/** Hides the toast that corresponds to the given notification item. */
|
|
100
|
+
hideToast(item: KbqNotificationItem): void;
|
|
60
101
|
/** Remove notification item */
|
|
61
102
|
remove(removedItem: KbqNotificationItem): void;
|
|
62
103
|
/** Remove group of notification items */
|
|
@@ -64,6 +105,8 @@ export declare class KbqNotificationCenterService {
|
|
|
64
105
|
/** Remove all notification items */
|
|
65
106
|
removeAll(): void;
|
|
66
107
|
private makeGroup;
|
|
108
|
+
/** Compares two notifications by date so the newest comes first. */
|
|
109
|
+
private compareByDateDesc;
|
|
67
110
|
private setIds;
|
|
68
111
|
private setReadState;
|
|
69
112
|
static ɵfac: i0.ɵɵFactoryDeclaration<KbqNotificationCenterService, never>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koobiq/components",
|
|
3
|
-
"version": "19.
|
|
3
|
+
"version": "19.8.1",
|
|
4
4
|
"description": "koobiq",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -25,12 +25,12 @@
|
|
|
25
25
|
"@angular/cdk": "^19.0.0",
|
|
26
26
|
"@angular/core": "^19.0.0",
|
|
27
27
|
"@angular/forms": "^19.0.0",
|
|
28
|
-
"@koobiq/cdk": "19.
|
|
29
|
-
"@koobiq/angular-moment-adapter": "19.
|
|
30
|
-
"@koobiq/angular-luxon-adapter": "19.
|
|
28
|
+
"@koobiq/cdk": "19.8.1",
|
|
29
|
+
"@koobiq/angular-moment-adapter": "19.8.1",
|
|
30
|
+
"@koobiq/angular-luxon-adapter": "19.8.1",
|
|
31
31
|
"@koobiq/date-formatter": "^3.2.3",
|
|
32
32
|
"@koobiq/icons": "^11.1.3",
|
|
33
|
-
"@koobiq/design-tokens": "3.14.0"
|
|
33
|
+
"@koobiq/design-tokens": "^3.14.0"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"tslib": "^2.6.2"
|
package/popover/popover.scss
CHANGED
|
@@ -23,7 +23,7 @@ $arrow-padding: 24px;
|
|
|
23
23
|
z-index: 1;
|
|
24
24
|
|
|
25
25
|
&.kbq-popover_small {
|
|
26
|
-
|
|
26
|
+
width: var(--kbq-popover-size-container-width-small);
|
|
27
27
|
|
|
28
28
|
& .kbq-popover__content_default-paddings.kbq-popover__content {
|
|
29
29
|
padding: var(--kbq-size-l);
|
|
@@ -31,11 +31,11 @@ $arrow-padding: 24px;
|
|
|
31
31
|
}
|
|
32
32
|
|
|
33
33
|
&.kbq-popover_medium {
|
|
34
|
-
|
|
34
|
+
width: var(--kbq-popover-size-container-width-medium);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
&.kbq-popover_large {
|
|
38
|
-
|
|
38
|
+
width: var(--kbq-popover-size-container-width-large);
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
@include pop-up.popup-margins(kbq-popover, 8px);
|