@koobiq/components 21.0.1 → 21.1.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/badge/_badge-theme.scss +31 -0
- package/breadcrumbs/breadcrumbs.scss +5 -1
- package/checkbox/_checkbox-theme.scss +0 -17
- package/checkbox/checkbox-tokens.scss +0 -4
- package/code-block/_code-block-theme.scss +7 -6
- package/code-block/code-block-tokens.scss +8 -4
- package/code-block/code-block.scss +54 -32
- package/content-panel/content-panel-header.scss +2 -3
- package/content-panel/content-panel.scss +3 -0
- package/core/selection/pseudo-checkbox/pseudo-checkbox-tokens.scss +0 -2
- package/fesm2022/koobiq-components-accordion.mjs +4 -4
- package/fesm2022/koobiq-components-accordion.mjs.map +1 -1
- package/fesm2022/koobiq-components-actions-panel.mjs +10 -2
- package/fesm2022/koobiq-components-actions-panel.mjs.map +1 -1
- package/fesm2022/koobiq-components-app-switcher.mjs +1 -1
- package/fesm2022/koobiq-components-app-switcher.mjs.map +1 -1
- package/fesm2022/koobiq-components-badge.mjs +2 -2
- package/fesm2022/koobiq-components-badge.mjs.map +1 -1
- package/fesm2022/koobiq-components-breadcrumbs.mjs +2 -2
- package/fesm2022/koobiq-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/koobiq-components-button-toggle.mjs +1 -1
- package/fesm2022/koobiq-components-button-toggle.mjs.map +1 -1
- package/fesm2022/koobiq-components-checkbox.mjs +18 -8
- package/fesm2022/koobiq-components-checkbox.mjs.map +1 -1
- package/fesm2022/koobiq-components-clamped-text.mjs +78 -10
- package/fesm2022/koobiq-components-clamped-text.mjs.map +1 -1
- package/fesm2022/koobiq-components-code-block.mjs +63 -379
- package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
- package/fesm2022/koobiq-components-content-panel.mjs +4 -4
- package/fesm2022/koobiq-components-content-panel.mjs.map +1 -1
- package/fesm2022/koobiq-components-core.mjs +300 -37
- package/fesm2022/koobiq-components-core.mjs.map +1 -1
- package/fesm2022/koobiq-components-datepicker.mjs +151 -60
- package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-divider.mjs +3 -3
- package/fesm2022/koobiq-components-divider.mjs.map +1 -1
- package/fesm2022/koobiq-components-dropdown.mjs +3 -3
- package/fesm2022/koobiq-components-dropdown.mjs.map +1 -1
- package/fesm2022/koobiq-components-file-upload.mjs +17 -8
- package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
- package/fesm2022/koobiq-components-filter-bar.mjs +115 -36
- package/fesm2022/koobiq-components-filter-bar.mjs.map +1 -1
- package/fesm2022/koobiq-components-flag.mjs +3 -3
- package/fesm2022/koobiq-components-flag.mjs.map +1 -1
- package/fesm2022/koobiq-components-form-field.mjs +90 -27
- package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
- package/fesm2022/koobiq-components-icon.mjs +2 -2
- package/fesm2022/koobiq-components-icon.mjs.map +1 -1
- package/fesm2022/koobiq-components-inline-edit.mjs +19 -2
- package/fesm2022/koobiq-components-inline-edit.mjs.map +1 -1
- package/fesm2022/koobiq-components-input.mjs +76 -17
- package/fesm2022/koobiq-components-input.mjs.map +1 -1
- package/fesm2022/koobiq-components-list.mjs +1 -1
- package/fesm2022/koobiq-components-list.mjs.map +1 -1
- package/fesm2022/koobiq-components-modal.mjs +3 -3
- package/fesm2022/koobiq-components-modal.mjs.map +1 -1
- package/fesm2022/koobiq-components-navbar.mjs +86 -25
- package/fesm2022/koobiq-components-navbar.mjs.map +1 -1
- package/fesm2022/koobiq-components-notification-center.mjs +4 -4
- package/fesm2022/koobiq-components-notification-center.mjs.map +1 -1
- package/fesm2022/koobiq-components-overflow-items.mjs +116 -38
- package/fesm2022/koobiq-components-overflow-items.mjs.map +1 -1
- package/fesm2022/koobiq-components-popover.mjs +86 -7
- package/fesm2022/koobiq-components-popover.mjs.map +1 -1
- package/fesm2022/koobiq-components-radio.mjs +41 -19
- package/fesm2022/koobiq-components-radio.mjs.map +1 -1
- package/fesm2022/koobiq-components-search-expandable.mjs +29 -17
- package/fesm2022/koobiq-components-search-expandable.mjs.map +1 -1
- package/fesm2022/koobiq-components-select.mjs +49 -12
- package/fesm2022/koobiq-components-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-sidepanel.mjs +198 -186
- package/fesm2022/koobiq-components-sidepanel.mjs.map +1 -1
- package/fesm2022/koobiq-components-splitter.mjs +49 -25
- package/fesm2022/koobiq-components-splitter.mjs.map +1 -1
- package/fesm2022/koobiq-components-tabs.mjs +30 -11
- package/fesm2022/koobiq-components-tabs.mjs.map +1 -1
- package/fesm2022/koobiq-components-tags.mjs +1 -1
- package/fesm2022/koobiq-components-tags.mjs.map +1 -1
- package/fesm2022/koobiq-components-textarea.mjs +28 -11
- package/fesm2022/koobiq-components-textarea.mjs.map +1 -1
- package/fesm2022/koobiq-components-time-range.mjs +2 -2
- package/fesm2022/koobiq-components-time-range.mjs.map +1 -1
- package/fesm2022/koobiq-components-timepicker.mjs +71 -16
- package/fesm2022/koobiq-components-timepicker.mjs.map +1 -1
- package/fesm2022/koobiq-components-timezone.mjs +2 -2
- package/fesm2022/koobiq-components-timezone.mjs.map +1 -1
- package/fesm2022/koobiq-components-toast.mjs +2 -2
- package/fesm2022/koobiq-components-toast.mjs.map +1 -1
- package/fesm2022/koobiq-components-toggle.mjs +25 -9
- package/fesm2022/koobiq-components-toggle.mjs.map +1 -1
- package/fesm2022/koobiq-components-tooltip.mjs +90 -17
- package/fesm2022/koobiq-components-tooltip.mjs.map +1 -1
- package/fesm2022/koobiq-components-top-bar.mjs +27 -7
- package/fesm2022/koobiq-components-top-bar.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree-select.mjs +4 -4
- package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
- package/fesm2022/koobiq-components-tree.mjs +71 -27
- package/fesm2022/koobiq-components-tree.mjs.map +1 -1
- package/file-upload/_file-upload-theme.scss +0 -12
- package/file-upload/file-upload-tokens.scss +0 -1
- package/file-upload/file-upload.scss +0 -1
- package/filter-bar/_filter-bar-theme.scss +7 -8
- package/filter-bar/filter-bar.scss +0 -1
- package/filter-bar/pipes/base-pipe.scss +36 -2
- package/filter-bar/pipes/pipe-multi-tree-select.scss +27 -0
- package/form-field/_fieldset-theme.scss +2 -7
- package/form-field/_form-field-theme.scss +9 -22
- package/form-field/_hint-theme.scss +20 -0
- package/form-field/fieldset-tokens.scss +0 -1
- package/form-field/fieldset.scss +0 -3
- package/form-field/form-field-tokens.scss +1 -1
- package/form-field/form-field.scss +9 -0
- package/form-field/hint-tokens.scss +3 -0
- package/modal/modal.scss +2 -0
- package/navbar/_navbar-item_vertical.scss +48 -2
- package/navbar/_navbar-theme.scss +11 -3
- package/navbar/navbar-item.scss +17 -0
- package/navbar/navbar-tokens.scss +3 -0
- package/package.json +4 -4
- package/popover/popover.scss +1 -1
- package/radio/_radio-theme.scss +0 -30
- package/radio/radio-tokens.scss +0 -2
- package/schematics/migrations/deprecated-icons/README.md +21 -5
- package/schematics/migrations/deprecated-icons/index.cjs +8 -22
- package/schematics/migrations/deprecated-icons/schema.json +1 -1
- package/schematics/migrations/icons-replacement/README.md +16 -2
- package/schematics/migrations/icons-replacement/index.cjs +18 -16
- package/schematics/migrations/icons-replacement/schema.json +12 -3
- package/schematics/migrations/new-icons-pack/README.md +37 -25
- package/schematics/migrations/new-icons-pack/index.cjs +22 -32
- package/schematics/migrations/new-icons-pack/replacement.json +2 -14
- package/schematics/migrations/new-icons-pack/schema.json +3 -3
- package/schematics/ng-add/index.cjs +4 -4
- package/schematics/utils/custom-data.cjs +64 -0
- package/schematics/utils/icon-migration.cjs +9 -3
- package/schematics/utils/messages.cjs +4 -0
- package/schematics/utils/package-config.cjs +19 -0
- package/select/select.scss +7 -0
- package/tabs/_tabs-common.scss +23 -0
- package/textarea/textarea-tokens.scss +4 -1
- package/toast/toast.component.scss +1 -0
- package/toggle/_toggle-theme.scss +0 -17
- package/tooltip/tooltip.scss +1 -1
- package/top-bar/top-bar-tokens.scss +1 -0
- package/top-bar/top-bar.scss +10 -0
- package/types/koobiq-components-accordion.d.ts +25 -0
- package/types/koobiq-components-button-toggle.d.ts +6 -0
- package/types/koobiq-components-checkbox.d.ts +30 -0
- package/types/koobiq-components-clamped-text.d.ts +16 -3
- package/types/koobiq-components-code-block.d.ts +17 -3
- package/types/koobiq-components-core.d.ts +226 -13
- package/types/koobiq-components-datepicker.d.ts +28 -1
- package/types/koobiq-components-divider.d.ts +28 -10
- package/types/koobiq-components-dropdown.d.ts +19 -0
- package/types/koobiq-components-filter-bar.d.ts +77 -4
- package/types/koobiq-components-flag.d.ts +18 -0
- package/types/koobiq-components-form-field.d.ts +87 -6
- package/types/koobiq-components-icon.d.ts +15 -0
- package/types/koobiq-components-inline-edit.d.ts +8 -1
- package/types/koobiq-components-input.d.ts +22 -3
- package/types/koobiq-components-list.d.ts +6 -0
- package/types/koobiq-components-modal.d.ts +7 -0
- package/types/koobiq-components-navbar.d.ts +71 -7
- package/types/koobiq-components-notification-center.d.ts +13 -0
- package/types/koobiq-components-overflow-items.d.ts +26 -2
- package/types/koobiq-components-popover.d.ts +38 -3
- package/types/koobiq-components-radio.d.ts +30 -0
- package/types/koobiq-components-search-expandable.d.ts +10 -0
- package/types/koobiq-components-select.d.ts +36 -4
- package/types/koobiq-components-sidepanel.d.ts +52 -1
- package/types/koobiq-components-splitter.d.ts +13 -4
- package/types/koobiq-components-tabs.d.ts +4 -0
- package/types/koobiq-components-tags.d.ts +6 -0
- package/types/koobiq-components-textarea.d.ts +9 -2
- package/types/koobiq-components-timepicker.d.ts +15 -0
- package/types/koobiq-components-toggle.d.ts +30 -0
- package/types/koobiq-components-tooltip.d.ts +55 -10
- package/types/koobiq-components-top-bar.d.ts +11 -3
- package/types/koobiq-components-tree-select.d.ts +12 -0
- package/types/koobiq-components-tree.d.ts +37 -2
|
@@ -1,19 +1,7 @@
|
|
|
1
1
|
@use '../core/styles/common/tokens';
|
|
2
2
|
|
|
3
|
-
@mixin kbq-file-upload-theme() {
|
|
4
|
-
.kbq-file-upload__hint {
|
|
5
|
-
:where(& .kbq-hint) {
|
|
6
|
-
color: var(--kbq-foreground-contrast-secondary);
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
|
|
11
3
|
@mixin kbq-file-upload-typography() {
|
|
12
4
|
.kbq-file-upload {
|
|
13
5
|
@include tokens.kbq-typography-level-to-styles-css-variables(typography, text-normal);
|
|
14
6
|
}
|
|
15
|
-
|
|
16
|
-
.kbq-file-upload__hint .kbq-hint .kbq-hint__text {
|
|
17
|
-
@include tokens.kbq-typography-level-to-styles-css-variables(typography, text-compact);
|
|
18
|
-
}
|
|
19
7
|
}
|
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
@use '../core/styles/common/tokens' as *;
|
|
2
|
-
|
|
3
|
-
@mixin kbq-filter-bar-typography() {
|
|
4
|
-
.kbq-hint.kbq-date-period__hint .kbq-hint__text {
|
|
5
|
-
@include kbq-typography-level-to-styles-css-variables(typography, text-compact);
|
|
6
|
-
}
|
|
7
|
-
}
|
|
8
|
-
|
|
9
1
|
// Themable colour surfaces of a pipe. Kept out of the layout SCSS so every colour
|
|
10
2
|
// lives behind a theme hook (they still resolve through the global semantic tokens).
|
|
11
3
|
@mixin kbq-filter-bar-pipe-theme() {
|
|
@@ -30,6 +22,13 @@
|
|
|
30
22
|
}
|
|
31
23
|
}
|
|
32
24
|
|
|
25
|
+
.kbq-pipe-multiselect__panel,
|
|
26
|
+
.kbq-pipe-multi-tree-select__panel {
|
|
27
|
+
.kbq-pipe-select-all__counter {
|
|
28
|
+
color: var(--kbq-foreground-contrast-secondary);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
33
32
|
.kbq-pipe.kbq-pipe_removable,
|
|
34
33
|
.kbq-pipe.kbq-pipe_cleanable:not(.kbq-pipe_empty) {
|
|
35
34
|
.kbq-button.cdk-keyboard-focused::after {
|
|
@@ -92,13 +92,47 @@
|
|
|
92
92
|
|
|
93
93
|
// The dropdown is portaled into the overlay, so it is reachable only through the pipe's `panelClass`.
|
|
94
94
|
.kbq-pipe-select__panel_multiline,
|
|
95
|
-
.kbq-pipe-multiselect__panel_multiline
|
|
95
|
+
.kbq-pipe-multiselect__panel_multiline,
|
|
96
|
+
.kbq-pipe-tree-select__panel_multiline,
|
|
97
|
+
.kbq-pipe-multi-tree-select__panel_multiline {
|
|
96
98
|
// `overflow: hidden` from `kbq-list-text()` stays: it gives the flex item a minimum size of 0, so the
|
|
97
99
|
// text shrinks to the option width instead of stretching the row.
|
|
98
|
-
.kbq-option-text
|
|
100
|
+
.kbq-option-text,
|
|
101
|
+
.kbq-tree-option .kbq-option-text {
|
|
99
102
|
white-space: normal;
|
|
100
103
|
overflow-wrap: break-word;
|
|
101
104
|
}
|
|
102
105
|
}
|
|
103
106
|
|
|
107
|
+
// The gap comes from the stylesheet, not from template whitespace: the compiler strips the whitespace-only
|
|
108
|
+
// text node between the label and the counter (the tree label is an `[innerHTML]` binding, so nothing else
|
|
109
|
+
// keeps a space there), and a margin is immune to that. The tree selector carries `.kbq-tree-option` so
|
|
110
|
+
// the margin survives the option reset `.kbq-tree-option .kbq-option-text > * { margin: 0 }`, which also
|
|
111
|
+
// clears the logical longhands and would otherwise tie on specificity.
|
|
112
|
+
.kbq-pipe-multiselect__panel .kbq-pipe-select-all__counter,
|
|
113
|
+
.kbq-pipe-multi-tree-select__panel .kbq-tree-option .kbq-pipe-select-all__counter {
|
|
114
|
+
margin-inline-start: var(--kbq-size-xxs);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// A wrapped row is taller than one line: pin the checkbox and the toggle to the FIRST line,
|
|
118
|
+
// as `:has(.kbq-option-caption)` in `tree-option.scss` does for two-line options. On a 32px row
|
|
119
|
+
// this alignment coincides with the centered one, so single-line options do not change.
|
|
120
|
+
.kbq-pipe-tree-select__panel_multiline,
|
|
121
|
+
.kbq-pipe-multi-tree-select__panel_multiline {
|
|
122
|
+
.kbq-tree-option {
|
|
123
|
+
& > .kbq-pseudo-checkbox,
|
|
124
|
+
& > kbq-checkbox {
|
|
125
|
+
align-self: flex-start;
|
|
126
|
+
margin-top: var(--kbq-size-3xs);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
& > .kbq-tree-node-toggle {
|
|
130
|
+
align-self: flex-start;
|
|
131
|
+
|
|
132
|
+
height: var(--kbq-typography-text-normal-line-height);
|
|
133
|
+
margin-top: 0;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
104
138
|
@include kbq-filter-bar-pipe-theme();
|
|
@@ -13,3 +13,30 @@
|
|
|
13
13
|
height: unset;
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
|
+
|
|
17
|
+
.kbq-pipe-multi-tree-select__panel_custom-value {
|
|
18
|
+
.kbq-tree-option {
|
|
19
|
+
align-items: flex-start;
|
|
20
|
+
|
|
21
|
+
& > .kbq-pseudo-checkbox,
|
|
22
|
+
& > kbq-checkbox {
|
|
23
|
+
margin-top: var(--kbq-size-3xs);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
& > .kbq-tree-node-toggle {
|
|
27
|
+
height: var(--kbq-typography-text-normal-line-height);
|
|
28
|
+
margin-top: 0;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.kbq-pipe-multi-tree-select__panel_multiline {
|
|
34
|
+
.kbq-tree-option .kbq-option-text {
|
|
35
|
+
flex: 1 1 auto;
|
|
36
|
+
min-width: 0;
|
|
37
|
+
|
|
38
|
+
white-space: normal;
|
|
39
|
+
overflow-wrap: break-word;
|
|
40
|
+
text-overflow: clip;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
@@ -1,9 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
// Kept for back-compatibility: the 21.0 migration points the stylesheet imports of consumers to this file.
|
|
2
|
+
/* stylelint-disable-next-line block-no-empty */
|
|
3
3
|
@mixin kbq-fieldset-theme {
|
|
4
|
-
// Geometry of the hint area lives in `fieldset.scss`, next to the rest of the fieldset layout.
|
|
5
|
-
.kbq-form-field__hint {
|
|
6
|
-
@include form-field-theme.kbq-form-field-hint-theme();
|
|
7
|
-
@include form-field-theme.kbq-form-field-hint-typography();
|
|
8
|
-
}
|
|
9
4
|
}
|
|
@@ -1,17 +1,5 @@
|
|
|
1
1
|
@use '../core/styles/common/tokens';
|
|
2
2
|
|
|
3
|
-
@mixin kbq-form-field-hint-theme {
|
|
4
|
-
> .kbq-hint:not(.kbq-contrast-fade, .kbq-success, .kbq-warning, .kbq-error) {
|
|
5
|
-
color: var(--kbq-form-field-hint-text);
|
|
6
|
-
}
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
@mixin kbq-form-field-hint-typography {
|
|
10
|
-
> .kbq-hint:not(.kbq-reactive-password-hint, .kbq-contrast-fade, .kbq-success, .kbq-warning) .kbq-hint__text {
|
|
11
|
-
@include tokens.kbq-typography-level-to-styles-css-variables(typography, text-compact);
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
|
|
15
3
|
@mixin _kbq-form-field-state($state-name) {
|
|
16
4
|
.kbq-form-field__container {
|
|
17
5
|
border-color: var(--kbq-form-field-#{$state-name}-border-color);
|
|
@@ -128,7 +116,9 @@
|
|
|
128
116
|
var(--kbq-form-field-states-error-focused-focus-outline);
|
|
129
117
|
}
|
|
130
118
|
|
|
131
|
-
|
|
119
|
+
// The container holds the prefix and the suffix, while the hints sit below it and keep the color
|
|
120
|
+
// they set themselves: `-webkit-text-fill-color` would win over it.
|
|
121
|
+
& .kbq-form-field__container .kbq-icon.kbq-empty {
|
|
132
122
|
color: var(--kbq-form-field-states-error-text);
|
|
133
123
|
-webkit-text-fill-color: var(--kbq-form-field-states-error-text);
|
|
134
124
|
}
|
|
@@ -138,6 +128,10 @@
|
|
|
138
128
|
|
|
139
129
|
.kbq-form-field__label {
|
|
140
130
|
color: var(--kbq-form-field-label-color);
|
|
131
|
+
|
|
132
|
+
&.kbq-form-field__label_required .kbq-label::after {
|
|
133
|
+
color: var(--kbq-form-field-label-required-marker-color);
|
|
134
|
+
}
|
|
141
135
|
}
|
|
142
136
|
|
|
143
137
|
// Autofill says "the browser filled this in" and nothing more, so it contributes a tint and
|
|
@@ -168,7 +162,8 @@
|
|
|
168
162
|
&.kbq-disabled {
|
|
169
163
|
@include _kbq-form-field-state(states-disabled);
|
|
170
164
|
|
|
171
|
-
|
|
165
|
+
// Leaves the hints out, as in the invalid state: they follow the disabled state through `KBQ_HINT_PARENT`.
|
|
166
|
+
.kbq-form-field__container .kbq-icon.kbq-empty {
|
|
172
167
|
color: var(--kbq-form-field-states-disabled-text);
|
|
173
168
|
-webkit-text-fill-color: var(--kbq-form-field-states-disabled-text);
|
|
174
169
|
}
|
|
@@ -180,19 +175,11 @@
|
|
|
180
175
|
color: var(--kbq-icon-contrast-fade);
|
|
181
176
|
}
|
|
182
177
|
}
|
|
183
|
-
|
|
184
|
-
.kbq-form-field__hint {
|
|
185
|
-
@include kbq-form-field-hint-theme();
|
|
186
|
-
}
|
|
187
178
|
}
|
|
188
179
|
}
|
|
189
180
|
|
|
190
181
|
@mixin kbq-form-field-typography() {
|
|
191
182
|
.kbq-form-field {
|
|
192
183
|
@include tokens.kbq-typography-level-to-styles-css-variables(typography, text-normal);
|
|
193
|
-
|
|
194
|
-
.kbq-form-field__hint {
|
|
195
|
-
@include kbq-form-field-hint-typography();
|
|
196
|
-
}
|
|
197
184
|
}
|
|
198
185
|
}
|
|
@@ -9,6 +9,21 @@
|
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
@mixin kbq-hint-theme() {
|
|
12
|
+
// `:where` keeps the default color below a class that a consumer puts on the hint.
|
|
13
|
+
:where(.kbq-hint) {
|
|
14
|
+
color: var(--kbq-hint-text);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
// A disabled control greys out what the hint's `color` leaves uncolored. The colors come after this rule with the
|
|
18
|
+
// same specificity, so a color set on the hint wins over the state of its control.
|
|
19
|
+
.kbq-hint.kbq-hint_disabled {
|
|
20
|
+
color: var(--kbq-hint-states-disabled-text);
|
|
21
|
+
|
|
22
|
+
& .kbq-icon.kbq-empty {
|
|
23
|
+
color: var(--kbq-hint-states-disabled-icon);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
12
27
|
.kbq-hint {
|
|
13
28
|
&.kbq-contrast-fade {
|
|
14
29
|
@include _kbq-hint-color(fill-text-on, fade-contrast);
|
|
@@ -44,6 +59,11 @@
|
|
|
44
59
|
}
|
|
45
60
|
}
|
|
46
61
|
}
|
|
62
|
+
|
|
63
|
+
// `fillTextOff` leaves the text uncolored, so a disabled control greys it out and the icon keeps the color.
|
|
64
|
+
.kbq-hint.kbq-hint_disabled.kbq-hint_fill-text-off {
|
|
65
|
+
color: var(--kbq-hint-states-disabled-text);
|
|
66
|
+
}
|
|
47
67
|
}
|
|
48
68
|
|
|
49
69
|
@mixin kbq-hint-typography() {
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
.kbq-fieldset {
|
|
2
2
|
--kbq-fieldset-legend-margin: var(--kbq-size-s);
|
|
3
3
|
--kbq-form-field-hint-size-margin-top: var(--kbq-size-xs);
|
|
4
|
-
--kbq-form-field-hint-text: var(--kbq-foreground-contrast-secondary);
|
|
5
4
|
--kbq-form-field-hint-size-gap: var(--kbq-size-xxs);
|
|
6
5
|
--kbq-form-field-label-color: var(--kbq-foreground-contrast-secondary);
|
|
7
6
|
}
|
package/form-field/fieldset.scss
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
@use './form-field';
|
|
2
|
-
@use './fieldset-theme';
|
|
3
2
|
|
|
4
3
|
.kbq-fieldset {
|
|
5
4
|
display: flex;
|
|
@@ -67,8 +66,6 @@
|
|
|
67
66
|
margin-left: calc(var(--kbq-size-border-width) * -1);
|
|
68
67
|
}
|
|
69
68
|
}
|
|
70
|
-
|
|
71
|
-
@include fieldset-theme.kbq-fieldset-theme();
|
|
72
69
|
}
|
|
73
70
|
|
|
74
71
|
.kbq-fieldset__container {
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
--kbq-form-field-states-disabled-background: var(--kbq-states-background-disabled);
|
|
59
59
|
--kbq-form-field-states-disabled-placeholder: var(--kbq-states-foreground-disabled);
|
|
60
60
|
--kbq-form-field-states-disabled-text: var(--kbq-states-foreground-disabled);
|
|
61
|
-
--kbq-form-field-hint-text: var(--kbq-foreground-contrast-secondary);
|
|
62
61
|
--kbq-form-field-label-color: var(--kbq-foreground-contrast-secondary);
|
|
62
|
+
--kbq-form-field-label-required-marker-color: var(--kbq-foreground-error);
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
:where(.kbq-dark) {
|
|
@@ -45,6 +45,15 @@
|
|
|
45
45
|
box-sizing: border-box;
|
|
46
46
|
display: flex;
|
|
47
47
|
margin-bottom: var(--kbq-form-field-label-margin-bottom);
|
|
48
|
+
|
|
49
|
+
// Drawn inside `kbq-label`, so that it follows the last word of a label that wraps.
|
|
50
|
+
&.kbq-form-field__label_required .kbq-label::after {
|
|
51
|
+
margin-left: var(--kbq-size-3xs);
|
|
52
|
+
// The marker only repeats the `required` state of the control, so it is kept out of the accessible name of
|
|
53
|
+
// the control. The plain `content` is the fallback for browsers without the alternative text syntax.
|
|
54
|
+
content: '*';
|
|
55
|
+
content: '*' / '';
|
|
56
|
+
}
|
|
48
57
|
}
|
|
49
58
|
|
|
50
59
|
// We should override suffix spacing for select type, because it has custom suffix
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
--kbq-hint-size-compact-margin-top: 0;
|
|
5
5
|
--kbq-hint-size-compact-content-padding: var(--kbq-size-xxs);
|
|
6
6
|
/* THEME TOKENS */
|
|
7
|
+
--kbq-hint-text: var(--kbq-foreground-contrast-secondary);
|
|
7
8
|
--kbq-hint-fill-text-off-fade-contrast-text: var(--kbq-foreground-contrast);
|
|
8
9
|
--kbq-hint-fill-text-off-fade-contrast-icon: var(--kbq-icon-contrast-fade);
|
|
9
10
|
--kbq-hint-fill-text-off-success-text: var(--kbq-foreground-contrast);
|
|
@@ -20,4 +21,6 @@
|
|
|
20
21
|
--kbq-hint-fill-text-on-warning-icon: var(--kbq-icon-warning);
|
|
21
22
|
--kbq-hint-fill-text-on-error-text: var(--kbq-foreground-error);
|
|
22
23
|
--kbq-hint-fill-text-on-error-icon: var(--kbq-icon-error);
|
|
24
|
+
--kbq-hint-states-disabled-text: var(--kbq-states-foreground-disabled);
|
|
25
|
+
--kbq-hint-states-disabled-icon: var(--kbq-states-icon-disabled);
|
|
23
26
|
}
|
package/modal/modal.scss
CHANGED
|
@@ -106,6 +106,7 @@
|
|
|
106
106
|
-webkit-box-orient: vertical;
|
|
107
107
|
-webkit-line-clamp: 2;
|
|
108
108
|
overflow: hidden;
|
|
109
|
+
overflow-wrap: break-word;
|
|
109
110
|
|
|
110
111
|
padding-top: var(--kbq-size-3xs);
|
|
111
112
|
padding-bottom: var(--kbq-size-3xs);
|
|
@@ -123,6 +124,7 @@
|
|
|
123
124
|
-webkit-box-orient: vertical;
|
|
124
125
|
-webkit-line-clamp: 2;
|
|
125
126
|
overflow: hidden;
|
|
127
|
+
overflow-wrap: break-word;
|
|
126
128
|
text-overflow: ellipsis;
|
|
127
129
|
}
|
|
128
130
|
|
|
@@ -53,11 +53,22 @@
|
|
|
53
53
|
gap: var(--kbq-size-m);
|
|
54
54
|
|
|
55
55
|
// The shared `.kbq-navbar-item .kbq-badge` rule takes the badge out of flow for the icon-corner
|
|
56
|
-
// overlay used when collapsed; expanded,
|
|
57
|
-
|
|
56
|
+
// overlay used when collapsed; expanded, a badge that is a direct child stays a normal flex child
|
|
57
|
+
// laid out after the title. Nested badges (inside a custom trigger) keep their own positioning.
|
|
58
|
+
& > .kbq-badge {
|
|
58
59
|
position: static;
|
|
59
60
|
}
|
|
60
61
|
|
|
62
|
+
// A titleless item has no trailing slot for the badge: it overlays the top-right corner of the
|
|
63
|
+
// leading 40px area, matching the custom component (whose badge is `top: 0; right: 0` of its 40×40 box).
|
|
64
|
+
// Scoped to the badge as a direct child, so a badge nested inside a custom trigger keeps its own position.
|
|
65
|
+
&:not(.kbq-navbar-item_with-title) > .kbq-badge {
|
|
66
|
+
position: absolute;
|
|
67
|
+
top: 0;
|
|
68
|
+
left: calc(var(--kbq-size-xl) + var(--kbq-navbar-item-size-custom-content-width));
|
|
69
|
+
transform: translateX(-100%);
|
|
70
|
+
}
|
|
71
|
+
|
|
61
72
|
&.kbq-navbar-item_has-nested {
|
|
62
73
|
align-items: center;
|
|
63
74
|
|
|
@@ -86,6 +97,41 @@
|
|
|
86
97
|
}
|
|
87
98
|
}
|
|
88
99
|
|
|
100
|
+
&.kbq-navbar-item_has-custom-trigger {
|
|
101
|
+
& > :first-child {
|
|
102
|
+
display: flex;
|
|
103
|
+
|
|
104
|
+
align-items: center;
|
|
105
|
+
justify-content: center;
|
|
106
|
+
|
|
107
|
+
flex-shrink: 0;
|
|
108
|
+
|
|
109
|
+
width: var(--kbq-navbar-item-size-custom-content-width);
|
|
110
|
+
height: var(--kbq-navbar-item-size-custom-content-height);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
// Collapsed: the 40×40 host is centered in the item, so centering its content aligns the icon with a
|
|
114
|
+
// plain collapsed item. Expanded: the host starts at the item padding, so left-aligning its content
|
|
115
|
+
// puts the icon on the plain item's inline icon axis.
|
|
116
|
+
&.kbq-expanded {
|
|
117
|
+
padding-right: var(--kbq-size-xl);
|
|
118
|
+
padding-left: var(--kbq-size-xl);
|
|
119
|
+
|
|
120
|
+
& > :first-child {
|
|
121
|
+
justify-content: flex-start;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// Collapsed: the item is the badge's reference, as it is for a plain item (the collapsed `.kbq-badge`
|
|
126
|
+
// offsets are item-relative). A relative host would measure them from its own 40×40 box and shift the
|
|
127
|
+
// badge left by the host's centering offset.
|
|
128
|
+
&.kbq-collapsed {
|
|
129
|
+
& > :first-child {
|
|
130
|
+
position: static;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
89
135
|
&.kbq-collapsed {
|
|
90
136
|
width: var(--kbq-size-6xl);
|
|
91
137
|
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
@use '../core/styles/common/tokens' as *;
|
|
2
2
|
|
|
3
3
|
@mixin kbq-navbar-item($state-name) {
|
|
4
|
-
|
|
4
|
+
// A projected button or form field paints its own states; a custom trigger is a bare host the component
|
|
5
|
+
// styles, so the item keeps painting them for it.
|
|
6
|
+
&:not(.kbq-navbar-item_has-nested),
|
|
7
|
+
&.kbq-navbar-item_has-custom-trigger {
|
|
5
8
|
&:after {
|
|
6
9
|
display: block;
|
|
7
10
|
background: var(--kbq-navbar-item-#{$state-name}-content-background);
|
|
@@ -15,7 +18,11 @@
|
|
|
15
18
|
// No `!important` needed: the child combinator plus the item class already outweighs everything that
|
|
16
19
|
// colours a bare icon (`.kbq-icon` and its `.kbq-icon.kbq-<color>` modifiers, at most two classes), and
|
|
17
20
|
// the state variants below add a class of their own on top of this one.
|
|
18
|
-
|
|
21
|
+
// A titled item may keep its leading icon inside `kbqNavbarItemContent` (the 40×40 square a custom
|
|
22
|
+
// component uses), so the same state colour has to reach a nested icon.
|
|
23
|
+
& > .kbq-icon.kbq-empty,
|
|
24
|
+
& > .kbq-navbar-item-content .kbq-icon.kbq-empty,
|
|
25
|
+
&.kbq-navbar-item_has-custom-trigger > :first-child .kbq-icon.kbq-empty {
|
|
19
26
|
color: var(--kbq-navbar-item-#{$state-name}-content-icon-left);
|
|
20
27
|
}
|
|
21
28
|
|
|
@@ -53,7 +60,8 @@ button {
|
|
|
53
60
|
@include kbq-navbar-item(states-hover);
|
|
54
61
|
}
|
|
55
62
|
|
|
56
|
-
&.cdk-focused.cdk-keyboard-focused
|
|
63
|
+
&.cdk-focused.cdk-keyboard-focused,
|
|
64
|
+
&.kbq-navbar-item_keyboard-focused {
|
|
57
65
|
outline: none;
|
|
58
66
|
|
|
59
67
|
&:after {
|
package/navbar/navbar-item.scss
CHANGED
|
@@ -21,6 +21,23 @@
|
|
|
21
21
|
min-height: var(--kbq-size-l);
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
+
// Custom content in place of the icon: the navbar only reserves the square, the content
|
|
25
|
+
// positions itself inside it.
|
|
26
|
+
& > .kbq-navbar-item-content {
|
|
27
|
+
flex-shrink: 0;
|
|
28
|
+
|
|
29
|
+
width: var(--kbq-navbar-item-size-custom-content-width);
|
|
30
|
+
height: var(--kbq-navbar-item-size-custom-content-height);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// The item paints its state overlay and the keyboard focus ring for a custom trigger, so the trigger host
|
|
34
|
+
// has to sit above the overlay to stay clickable, and must not draw the browser's own outline inside it.
|
|
35
|
+
&.kbq-navbar-item_has-custom-trigger > :first-child {
|
|
36
|
+
z-index: 1;
|
|
37
|
+
|
|
38
|
+
outline: none;
|
|
39
|
+
}
|
|
40
|
+
|
|
24
41
|
// Filled fade-contrast only: its background is a semi-transparent tint, so the
|
|
25
42
|
// navbar icon shows through. Composite the tint over an opaque bg-tertiary substrate.
|
|
26
43
|
// The outline variant is intentionally left untouched — it stays a clean transparent outline.
|
|
@@ -4,6 +4,9 @@
|
|
|
4
4
|
/* SIZE TOKENS */
|
|
5
5
|
/* 40px of content plus the 1px gap that keeps the focus ring of adjacent items apart. */
|
|
6
6
|
--kbq-navbar-item-vertical-size-height: 41px;
|
|
7
|
+
/* The square an item reserves for custom content in place of the 16px icon. */
|
|
8
|
+
--kbq-navbar-item-size-custom-content-width: var(--kbq-size-4xl);
|
|
9
|
+
--kbq-navbar-item-size-custom-content-height: var(--kbq-size-4xl);
|
|
7
10
|
--kbq-navbar-vertical-size-expanded-width: 240px;
|
|
8
11
|
--kbq-navbar-brand-vertical-size-title-max-width: 200px;
|
|
9
12
|
--kbq-navbar-toggle-size-circle: 28px;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@koobiq/components",
|
|
3
|
-
"version": "21.0
|
|
3
|
+
"version": "21.1.0",
|
|
4
4
|
"description": "koobiq",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -27,10 +27,10 @@
|
|
|
27
27
|
"@angular/forms": "^21.0.0",
|
|
28
28
|
"@angular/platform-browser": "^21.0.0",
|
|
29
29
|
"@angular/router": "^21.0.0",
|
|
30
|
-
"@koobiq/angular-moment-adapter": "^21.0
|
|
31
|
-
"@koobiq/angular-luxon-adapter": "^21.0
|
|
30
|
+
"@koobiq/angular-moment-adapter": "^21.1.0",
|
|
31
|
+
"@koobiq/angular-luxon-adapter": "^21.1.0",
|
|
32
32
|
"@koobiq/date-adapter": "^3.4.0",
|
|
33
|
-
"@koobiq/date-formatter": "^3.
|
|
33
|
+
"@koobiq/date-formatter": "^3.7.0",
|
|
34
34
|
"@koobiq/icons": "^11.1.3 || ^12.0.0",
|
|
35
35
|
"@koobiq/design-tokens": "^4.1.0",
|
|
36
36
|
"highlight.js": "^11.11.1",
|
package/popover/popover.scss
CHANGED
|
@@ -148,7 +148,7 @@ $z-index-above-content: 2;
|
|
|
148
148
|
width: $arrow-size;
|
|
149
149
|
height: $arrow-size;
|
|
150
150
|
|
|
151
|
-
transform: rotate(45deg);
|
|
151
|
+
transform: translate(var(--kbq-popover-arrow-shift-x, 0px), var(--kbq-popover-arrow-shift-y, 0px)) rotate(45deg);
|
|
152
152
|
}
|
|
153
153
|
|
|
154
154
|
@include pop-up.popup-arrow-positions(kbq-popover, $arrow-offset, $arrow-padding);
|
package/radio/_radio-theme.scss
CHANGED
|
@@ -16,10 +16,6 @@
|
|
|
16
16
|
@mixin kbq-radio-color($type-name) {
|
|
17
17
|
@include kbq-radio-state($type-name, default);
|
|
18
18
|
|
|
19
|
-
& .kbq-hint .kbq-hint__text {
|
|
20
|
-
color: var(--kbq-radio-#{$type-name}-default-caption);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
19
|
&:hover,
|
|
24
20
|
&.kbq-hovered {
|
|
25
21
|
@include kbq-radio-state($type-name, states-hover);
|
|
@@ -56,10 +52,6 @@
|
|
|
56
52
|
cursor: default;
|
|
57
53
|
color: var(--kbq-radio-#{$type-name}-states-disabled-caption);
|
|
58
54
|
}
|
|
59
|
-
|
|
60
|
-
& .kbq-hint .kbq-hint__text {
|
|
61
|
-
color: var(--kbq-radio-#{$type-name}-states-disabled-caption);
|
|
62
|
-
}
|
|
63
55
|
}
|
|
64
56
|
}
|
|
65
57
|
|
|
@@ -82,36 +74,14 @@
|
|
|
82
74
|
.kbq-radio-group.kbq-invalid .kbq-radio-button {
|
|
83
75
|
@include kbq-radio-color(error);
|
|
84
76
|
}
|
|
85
|
-
|
|
86
|
-
// A hint of the group reads like the hints of its options; the error keeps its own color.
|
|
87
|
-
.kbq-radio-group__subscript .kbq-hint:where(:not(.kbq-error)) .kbq-hint__text {
|
|
88
|
-
color: var(--kbq-radio-theme-default-caption);
|
|
89
|
-
}
|
|
90
77
|
}
|
|
91
78
|
|
|
92
79
|
@mixin kbq-radio-typography() {
|
|
93
80
|
.kbq-radio-button {
|
|
94
81
|
@include kbq-typography-level-to-styles-css-variables(typography, text-normal);
|
|
95
|
-
|
|
96
|
-
& .kbq-hint .kbq-hint__text {
|
|
97
|
-
@include kbq-typography-level-to-styles-css-variables(typography, text-compact);
|
|
98
|
-
}
|
|
99
82
|
}
|
|
100
83
|
|
|
101
84
|
.kbq-radio-button.kbq-radio-button_big {
|
|
102
85
|
@include kbq-typography-level-to-styles-css-variables(typography, text-big);
|
|
103
|
-
|
|
104
|
-
& .kbq-hint .kbq-hint__text {
|
|
105
|
-
@include kbq-typography-level-to-styles-css-variables(typography, text-normal);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
// The error and the hints under the group read at the size of the hints of its options.
|
|
110
|
-
.kbq-radio-group_normal .kbq-radio-group__subscript .kbq-hint__text {
|
|
111
|
-
@include kbq-typography-level-to-styles-css-variables(typography, text-compact);
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
.kbq-radio-group_big .kbq-radio-group__subscript .kbq-hint__text {
|
|
115
|
-
@include kbq-typography-level-to-styles-css-variables(typography, text-normal);
|
|
116
86
|
}
|
|
117
87
|
}
|
package/radio/radio-tokens.scss
CHANGED
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
--kbq-radio-theme-default-outer-circle-border: var(--kbq-line-contrast-fade);
|
|
6
6
|
--kbq-radio-theme-default-outer-circle-background: var(--kbq-background-bg);
|
|
7
7
|
--kbq-radio-theme-default-inner-circle-background: transparent;
|
|
8
|
-
--kbq-radio-theme-default-caption: var(--kbq-foreground-contrast-secondary);
|
|
9
8
|
--kbq-radio-theme-states-hover-outer-circle-border: var(--kbq-line-contrast-fade);
|
|
10
9
|
--kbq-radio-theme-states-hover-outer-circle-background: var(--kbq-states-background-transparent-hover);
|
|
11
10
|
--kbq-radio-theme-states-hover-inner-circle-background: transparent;
|
|
@@ -33,7 +32,6 @@
|
|
|
33
32
|
--kbq-radio-error-default-outer-circle-border: var(--kbq-line-error);
|
|
34
33
|
--kbq-radio-error-default-outer-circle-background: var(--kbq-background-error-less);
|
|
35
34
|
--kbq-radio-error-default-inner-circle-background: transparent;
|
|
36
|
-
--kbq-radio-error-default-caption: var(--kbq-foreground-contrast-secondary);
|
|
37
35
|
--kbq-radio-error-states-hover-outer-circle-border: var(--kbq-line-error);
|
|
38
36
|
--kbq-radio-error-states-hover-outer-circle-background: var(--kbq-states-background-error-fade-hover);
|
|
39
37
|
--kbq-radio-error-states-hover-inner-circle-background: transparent;
|
|
@@ -22,12 +22,24 @@ word/selector-boundary-safe regex rather than real selector parsing — this cor
|
|
|
22
22
|
directly preceded by `.`, like a real class selector), but a genuine selector spelled out inside a comment is
|
|
23
23
|
still indistinguishable from one that isn't and can still be rewritten.
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
On an element without an icon directive, the bare `pt-icons` class is renamed to `kbq`, the base class of the
|
|
26
|
+
icon font, so an icon written with classes alone keeps its styles. On an element with `kbq-icon`,
|
|
27
|
+
`kbq-icon-button` or `kbq-icon-item` (plain, bound or valueless) the class is dropped, since the directive adds
|
|
28
|
+
`kbq` itself:
|
|
29
|
+
|
|
30
|
+
```html
|
|
31
|
+
<!-- before -->
|
|
32
|
+
<i class="pt-icons pt-icons-comment_16 layout-margin-right-s"></i>
|
|
33
|
+
<i kbq-icon="pt-icons-comment_16" class="pt-icons layout-margin-right-s"></i>
|
|
34
|
+
<!-- after -->
|
|
35
|
+
<i class="kbq kbq-message_16 layout-margin-right-s"></i>
|
|
36
|
+
<i kbq-icon="kbq-message_16" class="layout-margin-right-s"></i>
|
|
37
|
+
```
|
|
26
38
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
39
|
+
A `[class.pt-icons]` binding follows the same rule: dropped on an icon directive's element, `[class.kbq]`
|
|
40
|
+
elsewhere. Outside templates, where there is no element to look at, the class is renamed: a component's
|
|
41
|
+
`host` class, a string literal (`'pt-icons word-wrap_16'` becomes `'kbq wrap-text_16'`) and a stylesheet
|
|
42
|
+
selector.
|
|
31
43
|
|
|
32
44
|
`fix: false` (the default) never mutates any file — it only reports what it found.
|
|
33
45
|
|
|
@@ -37,8 +49,12 @@ Usage for Angular Cli:
|
|
|
37
49
|
|
|
38
50
|
```shell
|
|
39
51
|
ng g @koobiq/components:deprecated-icons --fix=true --project "<your project>"
|
|
52
|
+
ng g @koobiq/components:deprecated-icons --fix=true --project ./libs
|
|
40
53
|
```
|
|
41
54
|
|
|
55
|
+
`--project` takes a project name or a folder; without it the whole workspace is migrated. `node_modules` and
|
|
56
|
+
`dist` are always skipped.
|
|
57
|
+
|
|
42
58
|
Usage for Nx:
|
|
43
59
|
|
|
44
60
|
```shell
|