@epam/ai-dial-ui-kit 0.16.0-dev.38 → 0.16.0-dev.39
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/dist/CHANGELOG.md +2 -0
- package/dist/components/New/Tag/Tag.js +34 -34
- package/dist/components/New/Tag/constants.js +13 -4
- package/dist/components-manifest.json +9 -4
- package/dist/dial-ui-kit.cjs +3 -3
- package/dist/src/components/New/Tag/Tag.d.ts +9 -5
- package/dist/src/components/New/Tag/constants.d.ts +12 -4
- package/dist/src/types/tag.d.ts +3 -1
- package/dist/types/tag.js +2 -2
- package/package.json +1 -1
|
@@ -16,9 +16,10 @@ export interface TagProps extends NativeTagProps {
|
|
|
16
16
|
* aliases: Chip|Pill
|
|
17
17
|
* Design system 2.0
|
|
18
18
|
*
|
|
19
|
-
* The tag
|
|
20
|
-
*
|
|
21
|
-
* usually reaching for a
|
|
19
|
+
* The tag is the 32px pill of the 2.0 design; `TagAppearance.Bordered` is the
|
|
20
|
+
* compact 24px value chip of a form field. There is no `size` prop: a tag sizes
|
|
21
|
+
* itself, and a caller that needs a different height is usually reaching for a
|
|
22
|
+
* button.
|
|
22
23
|
*
|
|
23
24
|
* The label truncates rather than wrapping, and carries a native `title` so the
|
|
24
25
|
* full text stays reachable when it does.
|
|
@@ -28,7 +29,9 @@ export interface TagProps extends NativeTagProps {
|
|
|
28
29
|
* the caller: a clickable tag that is also closable gives a screen reader two
|
|
29
30
|
* actions with no way to tell which one it landed on.
|
|
30
31
|
*
|
|
31
|
-
*
|
|
32
|
+
* `outlined` and `selectable` draw no rim and are told apart by their fill;
|
|
33
|
+
* `bordered` draws one: the outlined `Badge`'s look, for a value the user can
|
|
34
|
+
* remove, on a surface the rimless fill would vanish on.
|
|
32
35
|
* `TagAppearance.Selectable` is the filter chip of the 2.0 design: no fill
|
|
33
36
|
* at all until it is selected, one hover tint shared by both states, a semibold
|
|
34
37
|
* label once selected, and the state carried on `aria-pressed` rather than by
|
|
@@ -55,7 +58,8 @@ export interface TagProps extends NativeTagProps {
|
|
|
55
58
|
* @param label - Text content displayed inside the tag.
|
|
56
59
|
* @param [icon] - Icon rendered before the label.
|
|
57
60
|
* @param [appearance=TagAppearance.Outlined] - `outlined` is the filled chip on the raised
|
|
58
|
-
* layer; `selectable` is the unfilled filter chip that tints and turns semibold when selected
|
|
61
|
+
* layer; `selectable` is the unfilled filter chip that tints and turns semibold when selected;
|
|
62
|
+
* `bordered` is the compact rimmed value chip of a form field.
|
|
59
63
|
* @param [selected=false] - Applies the accent-tinted selected styling.
|
|
60
64
|
* @param [disabled=false] - Stops the tag responding: no click handling, no remove control. The design defines no disabled tag, so the colours stay put.
|
|
61
65
|
* @param [closable=false] - Renders the remove button. Needs `onRemove` to appear.
|
|
@@ -6,10 +6,18 @@ import { TagAppearance } from '../../../types/tag';
|
|
|
6
6
|
*/
|
|
7
7
|
export declare const tagBaseClassName = "inline-flex h-[32px] max-w-full items-center gap-1 rounded-full px-3";
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
9
|
+
* Shape and type scale per appearance, over `tagBaseClassName`. The bordered
|
|
10
|
+
* chip is the compact value chip of a form field — the removable twin of
|
|
11
|
+
* `Badge`'s outlined label: its 24px, 6px corner and rim on the sunken layer,
|
|
12
|
+
* with the value in primary text on the small type scale.
|
|
13
|
+
*/
|
|
14
|
+
export declare const tagShapeClassNames: Record<TagAppearance, string>;
|
|
15
|
+
/**
|
|
16
|
+
* Fill and text colour per appearance and selection. `outlined` and
|
|
17
|
+
* `selectable` draw no rim and are told apart by their fill — `outlined` sits
|
|
18
|
+
* on the raised layer, `selectable` on nothing until it is selected, where it
|
|
19
|
+
* also steps its label up from secondary to primary. `bordered` is the one with
|
|
20
|
+
* a rim, on the sunken layer.
|
|
13
21
|
*/
|
|
14
22
|
export declare const tagStateClassNames: Record<TagAppearance, Record<'default' | 'selected', string>>;
|
|
15
23
|
/** Cursor and focus ring of a tag that can be activated. */
|
package/dist/src/types/tag.d.ts
CHANGED
package/dist/types/tag.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var
|
|
1
|
+
var d = /* @__PURE__ */ ((e) => (e.Outlined = "outlined", e.Selectable = "selectable", e.Bordered = "bordered", e))(d || {});
|
|
2
2
|
export {
|
|
3
|
-
|
|
3
|
+
d as TagAppearance
|
|
4
4
|
};
|