@koobiq/components 19.6.0 → 19.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.
Files changed (43) hide show
  1. package/breadcrumbs/breadcrumbs.scss +0 -4
  2. package/code-block/code-block-highlight.d.ts +1 -0
  3. package/core/option/option.d.ts +8 -0
  4. package/core/validation/validation.d.ts +1 -1
  5. package/fesm2022/koobiq-components-breadcrumbs.mjs +2 -2
  6. package/fesm2022/koobiq-components-breadcrumbs.mjs.map +1 -1
  7. package/fesm2022/koobiq-components-code-block.mjs +10 -7
  8. package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
  9. package/fesm2022/koobiq-components-core.mjs +31 -13
  10. package/fesm2022/koobiq-components-core.mjs.map +1 -1
  11. package/fesm2022/koobiq-components-datepicker.mjs +1 -1
  12. package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
  13. package/fesm2022/koobiq-components-file-upload.mjs +4 -4
  14. package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
  15. package/fesm2022/koobiq-components-filter-bar.mjs +3 -3
  16. package/fesm2022/koobiq-components-filter-bar.mjs.map +1 -1
  17. package/fesm2022/koobiq-components-form-field.mjs +4 -4
  18. package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
  19. package/fesm2022/koobiq-components-modal.mjs +8 -6
  20. package/fesm2022/koobiq-components-modal.mjs.map +1 -1
  21. package/fesm2022/koobiq-components-select.mjs +31 -9
  22. package/fesm2022/koobiq-components-select.mjs.map +1 -1
  23. package/fesm2022/koobiq-components-tags.mjs +49 -34
  24. package/fesm2022/koobiq-components-tags.mjs.map +1 -1
  25. package/fesm2022/koobiq-components-timezone.mjs +4 -4
  26. package/fesm2022/koobiq-components-timezone.mjs.map +1 -1
  27. package/fesm2022/koobiq-components-tooltip.mjs +2 -2
  28. package/fesm2022/koobiq-components-tooltip.mjs.map +1 -1
  29. package/fesm2022/koobiq-components-tree-select.mjs +2 -2
  30. package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
  31. package/fesm2022/koobiq-components-tree.mjs +1 -1
  32. package/fesm2022/koobiq-components-tree.mjs.map +1 -1
  33. package/form-field/_form-field-theme.scss +10 -2
  34. package/form-field/form-field-tokens.scss +1 -0
  35. package/form-field/form-field.scss +19 -0
  36. package/package.json +4 -4
  37. package/schematics/ng-add/index.js +2 -2
  38. package/select/select-tokens.scss +2 -2
  39. package/select/select.component.d.ts +10 -1
  40. package/tags/tag-list.component.d.ts +15 -11
  41. package/tags/tag.component.d.ts +5 -2
  42. package/timezone/timezone-option-tokens.scss +0 -10
  43. package/tooltip/_tooltip-theme.scss +5 -1
@@ -47,9 +47,15 @@
47
47
  &:-webkit-autofill,
48
48
  &:-webkit-autofill:hover,
49
49
  &:-webkit-autofill:focus {
50
+ // set as transparent to not override container background-color;
51
+ --kbq-form-field-states-autofill-background: var(--kbq-background-transparent);
50
52
  -webkit-box-shadow: inset 0 0 0 40rem var(--kbq-form-field-states-autofill-background);
51
53
  -webkit-text-fill-color: var(--kbq-form-field-states-autofill-text);
52
54
  caret-color: var(--kbq-form-field-states-autofill-text);
55
+
56
+ /* hide browser default autofill background, no matter what background color set */
57
+ transition: background-color 5000s ease-in-out;
58
+ background-color: var(--kbq-background-transparent) !important;
53
59
  }
54
60
  }
55
61
 
@@ -72,7 +78,8 @@
72
78
  @include _kbq-form-field-state(states-focused);
73
79
 
74
80
  & .kbq-form-field__container {
75
- box-shadow: inset 0 0 0.1px 1px var(--kbq-form-field-states-focused-focus-outline);
81
+ box-shadow: inset 0 0 0.1px var(--kbq-form-field-size-focus-outline-width)
82
+ var(--kbq-form-field-states-focused-focus-outline);
76
83
  }
77
84
  }
78
85
 
@@ -83,7 +90,8 @@
83
90
  @include _kbq-form-field-state(states-error);
84
91
 
85
92
  &.cdk-focused .kbq-form-field__container {
86
- box-shadow: inset 0 0 0.1px 1px var(--kbq-form-field-states-error-focused-focus-outline);
93
+ box-shadow: inset 0 0 0.1px var(--kbq-form-field-size-focus-outline-width)
94
+ var(--kbq-form-field-states-error-focused-focus-outline);
87
95
  }
88
96
 
89
97
  & .kbq-icon.kbq-empty {
@@ -3,6 +3,7 @@
3
3
 
4
4
  --kbq-form-field-size-border-width: var(--kbq-size-border-width);
5
5
  --kbq-form-field-size-border-radius: var(--kbq-size-border-radius);
6
+ --kbq-form-field-size-focus-outline-width: 1px;
6
7
 
7
8
  --kbq-form-field-size-icon-size: var(--kbq-size-l);
8
9
  --kbq-form-field-size-icon-margin-left: var(--kbq-size-s);
@@ -109,6 +109,25 @@
109
109
  &.cdk-focused,
110
110
  &.kbq-focused {
111
111
  z-index: 3;
112
+
113
+ .kbq-input {
114
+ &:-webkit-autofill,
115
+ &:-webkit-autofill:hover,
116
+ &:-webkit-autofill:focus {
117
+ min-height: calc(
118
+ var(--kbq-form-field-size-height) - var(--kbq-form-field-size-border-width) *
119
+ 2 - var(--kbq-form-field-size-focus-outline-width) * 2
120
+ );
121
+
122
+ --kbq-input-size-padding-vertical: calc(
123
+ var(--kbq-size-xs) - var(--kbq-form-field-size-border-width) - var(
124
+ --kbq-form-field-size-focus-outline-width
125
+ )
126
+ );
127
+
128
+ margin: var(--kbq-form-field-size-border-width) 0;
129
+ }
130
+ }
112
131
  }
113
132
 
114
133
  &.kbq-form-field_without-borders .kbq-form-field__container,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@koobiq/components",
3
- "version": "19.6.0",
3
+ "version": "19.7.0",
4
4
  "description": "koobiq",
5
5
  "repository": {
6
6
  "type": "git",
@@ -25,9 +25,9 @@
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.6.0",
29
- "@koobiq/angular-moment-adapter": "19.6.0",
30
- "@koobiq/angular-luxon-adapter": "19.6.0",
28
+ "@koobiq/cdk": "19.7.0",
29
+ "@koobiq/angular-moment-adapter": "19.7.0",
30
+ "@koobiq/angular-luxon-adapter": "19.7.0",
31
31
  "@koobiq/date-formatter": "^3.2.3",
32
32
  "@koobiq/icons": "^11.1.3",
33
33
  "@koobiq/design-tokens": "3.14.0"
@@ -27,8 +27,8 @@ function ngAdd(options) {
27
27
  }
28
28
  // Installing dependencies
29
29
  utils_packageConfig.addPackageToPackageJson(tree, '@angular/cdk', "^19.2.19");
30
- utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/cdk', "^19.6.0");
31
- utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/angular-luxon-adapter', "^19.6.0");
30
+ utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/cdk', "^19.7.0");
31
+ utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/angular-luxon-adapter', "^19.7.0");
32
32
  utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/date-formatter', "^3.4.0");
33
33
  utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/date-adapter', "^3.4.0");
34
34
  utils_packageConfig.addPackageToPackageJson(tree, '@koobiq/icons', "^11.5.0");
@@ -1,8 +1,8 @@
1
1
  .kbq-select,
2
2
  .kbq-tree-select,
3
3
  .kbq-select__panel {
4
- --kbq-select-size-single-padding-left: var(--kbq-form-field-size-infix-padding);
5
- --kbq-select-size-single-padding-right: var(--kbq-form-field-size-suffix-padding);
4
+ --kbq-select-size-single-padding-left: 0;
5
+ --kbq-select-size-single-padding-right: 0;
6
6
  --kbq-select-size-single-padding-vertical: var(--kbq-size-xs);
7
7
  --kbq-select-size-single-content-gap: var(--kbq-size-xxs);
8
8
  --kbq-select-size-multiple-padding-left: 0;
@@ -176,6 +176,15 @@ export declare class KbqSelect extends KbqAbstractSelect implements AfterContent
176
176
  searchEmpty: KbqSelectSearchEmptyResult;
177
177
  /** Template string for hidden items text. Supports {{ number }} placeholder. */
178
178
  hiddenItemsText: string;
179
+ /** Determines whether preselected values are displayed. */
180
+ showPreselectedValues: boolean;
181
+ /**
182
+ * Specifies the maximum number of trigger values allowed.
183
+ * This constant limits the size of the trigger values array to ensure performance
184
+ * and prevent excessive memory usage.
185
+ * A value of `0` indicates that there is no limit.
186
+ */
187
+ triggerValuesLimit: number;
179
188
  /** Classes to be passed to the select panel. Supports the same syntax as `ngClass`. */
180
189
  panelClass: string | string[] | Set<string> | {
181
190
  [key: string]: any;
@@ -570,7 +579,7 @@ export declare class KbqSelect extends KbqAbstractSelect implements AfterContent
570
579
  /** Removes the dropdown class from the overlay container when select closes. */
571
580
  private removeClassFromOverlayContainer;
572
581
  static ɵfac: i0.ɵɵFactoryDeclaration<KbqSelect, [null, null, null, null, null, null, { optional: true; }, { optional: true; }, { optional: true; }, { optional: true; host: true; }, { optional: true; self: true; }, null, { optional: true; }]>;
573
- static ɵcmp: i0.ɵɵComponentDeclaration<KbqSelect, "kbq-select", ["kbqSelect"], { "hiddenItemsText": { "alias": "hiddenItemsText"; "required": false; }; "panelClass": { "alias": "panelClass"; "required": false; }; "backdropClass": { "alias": "backdropClass"; "required": false; }; "errorStateMatcher": { "alias": "errorStateMatcher"; "required": false; }; "sortComparator": { "alias": "sortComparator"; "required": false; }; "multiline": { "alias": "multiline"; "required": false; }; "searchMinOptionsThreshold": { "alias": "searchMinOptionsThreshold"; "required": false; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "required": { "alias": "required"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "compareWith": { "alias": "compareWith"; "required": false; }; "selectAllHandler": { "alias": "selectAllHandler"; "required": false; }; "panelWidth": { "alias": "panelWidth"; "required": false; }; "panelMinWidth": { "alias": "panelMinWidth"; "required": false; }; "value": { "alias": "value"; "required": false; }; "id": { "alias": "id"; "required": false; }; "tabIndex": { "alias": "tabIndex"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "hiddenItemsTextFormatter": { "alias": "hiddenItemsTextFormatter"; "required": false; }; }, { "openedChange": "openedChange"; "beforeOpened": "beforeOpened"; "openedStream": "opened"; "closedStream": "closed"; "selectionChange": "selectionChange"; "valueChange": "valueChange"; }, ["footer", "cdkVirtualForOf", "customTrigger", "customMatcher", "customTagTemplateRef", "cleaner", "search", "searchEmpty", "options", "optionGroups"], ["kbq-select-matcher, [kbq-select-matcher]", "kbq-select-trigger, [kbq-select-trigger]", "kbq-cleaner", "[kbqSelectSearch]", "[kbq-select-search-empty-result]", "*", "kbq-select-footer,[kbq-select-footer]"], true, never>;
582
+ static ɵcmp: i0.ɵɵComponentDeclaration<KbqSelect, "kbq-select", ["kbqSelect"], { "hiddenItemsText": { "alias": "hiddenItemsText"; "required": false; }; "showPreselectedValues": { "alias": "showPreselectedValues"; "required": false; }; "triggerValuesLimit": { "alias": "triggerValuesLimit"; "required": false; }; "panelClass": { "alias": "panelClass"; "required": false; }; "backdropClass": { "alias": "backdropClass"; "required": false; }; "errorStateMatcher": { "alias": "errorStateMatcher"; "required": false; }; "sortComparator": { "alias": "sortComparator"; "required": false; }; "multiline": { "alias": "multiline"; "required": false; }; "searchMinOptionsThreshold": { "alias": "searchMinOptionsThreshold"; "required": false; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "required": { "alias": "required"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "compareWith": { "alias": "compareWith"; "required": false; }; "selectAllHandler": { "alias": "selectAllHandler"; "required": false; }; "panelWidth": { "alias": "panelWidth"; "required": false; }; "panelMinWidth": { "alias": "panelMinWidth"; "required": false; }; "value": { "alias": "value"; "required": false; }; "id": { "alias": "id"; "required": false; }; "tabIndex": { "alias": "tabIndex"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "hiddenItemsTextFormatter": { "alias": "hiddenItemsTextFormatter"; "required": false; }; }, { "openedChange": "openedChange"; "beforeOpened": "beforeOpened"; "openedStream": "opened"; "closedStream": "closed"; "selectionChange": "selectionChange"; "valueChange": "valueChange"; }, ["footer", "cdkVirtualForOf", "customTrigger", "customMatcher", "customTagTemplateRef", "cleaner", "search", "searchEmpty", "options", "optionGroups"], ["kbq-select-matcher, [kbq-select-matcher]", "kbq-select-trigger, [kbq-select-trigger]", "kbq-cleaner", "[kbqSelectSearch]", "[kbq-select-search-empty-result]", "*", "kbq-select-footer,[kbq-select-footer]"], true, never>;
574
583
  static ngAcceptInputType_multiline: unknown;
575
584
  static ngAcceptInputType_multiple: unknown;
576
585
  static ngAcceptInputType_panelMinWidth: unknown;
@@ -63,11 +63,17 @@ export declare class KbqTagList implements KbqFormFieldControl<any>, ControlValu
63
63
  */
64
64
  get tagBlurChanges(): Observable<KbqTagEvent>;
65
65
  /**
66
- * Combined stream of all of the child tags' remove change events.
66
+ * Combined stream of all of the child tags' destroyed events.
67
67
  *
68
68
  * @docs-private
69
69
  */
70
70
  get tagRemoveChanges(): Observable<KbqTagEvent>;
71
+ /**
72
+ * Combined stream of all of the child tags' removal request events.
73
+ *
74
+ * @docs-private
75
+ */
76
+ protected get tagBeforeRemoveChanges(): Observable<KbqTagEvent>;
71
77
  /**
72
78
  * Combined stream of all of the child tags' edit change events.
73
79
  *
@@ -157,7 +163,8 @@ export declare class KbqTagList implements KbqFormFieldControl<any>, ControlValu
157
163
  editable: boolean;
158
164
  /**
159
165
  * Whether to emit change events when tags are added/removed.
160
- * Set to `false` to prevent the form control from being marked as dirty during programmatic updates.
166
+ *
167
+ * @deprecated No longer needed. Will be removed in the next major release.
161
168
  */
162
169
  emitOnTagChanges: boolean;
163
170
  /** Whether the tags in the list are removable. */
@@ -227,20 +234,16 @@ export declare class KbqTagList implements KbqFormFieldControl<any>, ControlValu
227
234
  errorState: boolean;
228
235
  /** The tag input to add more tags */
229
236
  private tagInput;
237
+ /** True when the next `tags.changes` emission is triggered by a UI action, not programmatic update. */
238
+ private pendingUIChange;
230
239
  /**
231
240
  * When a tag is destroyed, we store the index of the destroyed tag until the tags
232
241
  * query list notifies about the update. This is necessary because we cannot determine an
233
242
  * appropriate tag that should receive focus until the array of tags updated completely.
234
243
  */
235
244
  private lastDestroyedTagIndex;
236
- /** Subscription to focus changes in the tags. */
237
- private tagFocusSubscription;
238
- /** Subscription to blur changes in the tags. */
239
- private tagBlurSubscription;
240
- /** Subscription to remove changes in tags. */
241
- private tagRemoveSubscription;
242
- /** Subscription to edit changes in tags. */
243
- private tagEditSubscription;
245
+ /** Triggers unsubscription from all per-tags streams when tags are reset. */
246
+ private readonly tagsSubscriptions$;
244
247
  constructor(elementRef: ElementRef<HTMLElement>, changeDetectorRef: ChangeDetectorRef, defaultErrorStateMatcher: ErrorStateMatcher, dir: Directionality, parentForm: NgForm, parentFormGroup: FormGroupDirective, ngControl: NgControl);
245
248
  ngDoCheck(): void;
246
249
  ngAfterContentInit(): void;
@@ -252,6 +255,8 @@ export declare class KbqTagList implements KbqFormFieldControl<any>, ControlValu
252
255
  onTouched: () => void;
253
256
  /** @docs-private */
254
257
  onChange: (value: any) => void;
258
+ /** Notifies that the next `tags.changes` emission is UI-initiated. */
259
+ notifyPendingTagChange(): void;
255
260
  /**
256
261
  * Associates an HTML input element with this tag list.
257
262
  *
@@ -344,7 +349,6 @@ export declare class KbqTagList implements KbqFormFieldControl<any>, ControlValu
344
349
  removeSelected(): void;
345
350
  private propagateTagsChanges;
346
351
  private resetTags;
347
- private dropSubscriptions;
348
352
  /** Listens to user-generated selection events on each tag. */
349
353
  private listenToTagsFocus;
350
354
  private listenToTagsRemoved;
@@ -134,9 +134,12 @@ export declare class KbqTag extends KbqColorDirective implements IFocusableOptio
134
134
  removeIcon: KbqTagRemove;
135
135
  /** Emitted when the tag is selected or deselected. */
136
136
  readonly selectionChange: EventEmitter<KbqTagSelectionChange>;
137
- /** Emitted when the tag is destroyed. */
137
+ /** Emitted when the tag is destroyed and leaving the DOM. */
138
138
  readonly destroyed: EventEmitter<KbqTagEvent>;
139
- /** Emitted when a tag is to be removed. */
139
+ /**
140
+ * Emitted when a tag is to be removed.
141
+ * Fires on programmatic and UI removal (click or keyboard).
142
+ */
140
143
  readonly removed: EventEmitter<KbqTagEvent>;
141
144
  /** Whether the tag is selected. */
142
145
  get selected(): boolean;
@@ -1,22 +1,12 @@
1
- @use '../list/list-tokens';
2
1
  @use '../core/option/option-tokens';
3
2
 
4
3
  .kbq-timezone-select__panel {
5
- --kbq-select-size-single-padding-left: var(--kbq-size-m);
6
- --kbq-select-size-single-padding-right: var(--kbq-size-xxs);
7
- --kbq-select-size-single-padding-vertical: var(--kbq-size-xs);
8
- --kbq-select-size-single-content-gap: var(--kbq-size-xxs);
9
- --kbq-select-size-multiple-padding-left: var(--kbq-size-xxs);
10
- --kbq-select-size-multiple-padding-right: var(--kbq-size-xxs);
11
- --kbq-select-size-multiple-content-gap: var(--kbq-size-xxs);
12
4
  --kbq-timezone-option-size-padding: var(--kbq-size-xxs) 10px;
13
5
  --kbq-timezone-option-size-column-gap: 16px;
14
6
  --kbq-timezone-option-size-height: auto;
15
7
  --kbq-timezone-option-size-max-height: 5em;
16
8
  --kbq-timezone-option-size-optgroup-label-padding: 12px 12px 4px 12px;
17
9
  /* THEME TOKENS */
18
- --kbq-select-panel-dropdown-background: var(--kbq-background-card);
19
- --kbq-select-panel-dropdown-shadow: var(--kbq-shadow-popup);
20
10
  --kbq-timezone-option-text: var(--kbq-foreground-contrast);
21
11
  --kbq-timezone-option-caption: var(--kbq-foreground-contrast-secondary);
22
12
  --kbq-timezone-option-optgroup-label: var(--kbq-foreground-contrast-secondary);
@@ -4,7 +4,11 @@
4
4
  & .kbq-tooltip__inner {
5
5
  color: var(--kbq-tooltip-#{$style-name}-text);
6
6
 
7
- background-color: var(--kbq-tooltip-#{$style-name}-background);
7
+ background-image: linear-gradient(
8
+ var(--kbq-tooltip-#{$style-name}-background),
9
+ var(--kbq-tooltip-#{$style-name}-background)
10
+ );
11
+ background-color: var(--kbq-background-bg);
8
12
  }
9
13
 
10
14
  & .kbq-tooltip__arrow {