@espressif/dashboard-ui-components 1.13.0 → 1.14.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/.claude/rules/dashboard-ui-consumption.md +41 -0
- package/.cursor/rules/dashboard-ui-consumption.mdc +39 -1
- package/CHANGELOG.md +222 -0
- package/README.md +50 -4
- package/dist/{alert.props-CcKo49Rb.d.ts → alert.props-BuLuWmXA.d.ts} +3 -3
- package/dist/common/copyright-card/copyright-card.js +1 -1
- package/dist/common/footer-card/footer-card.js +2 -2
- package/dist/common/index.d.ts +3 -0
- package/dist/common/my-account-menu/my-account-menu.js +2 -2
- package/dist/common/page-loader/page-loader.js +4 -1
- package/dist/common/profile-card/profile-card.js +2 -2
- package/dist/components/accordion/accordion.js +6 -11
- package/dist/components/alert/index.d.ts +5 -5
- package/dist/components/anchored-panel/anchored-panel.js +4 -4
- package/dist/components/async-multi-select/async-multi-select.js +8 -8
- package/dist/components/badge/index.d.ts +1 -1
- package/dist/components/bottom-sheet/_hooks/use-sheet-drag.js +112 -0
- package/dist/components/bottom-sheet/bottom-sheet.js +84 -0
- package/dist/components/bottom-sheet/index.d.ts +50 -0
- package/dist/components/bottom-sheet/index.js +3 -0
- package/dist/components/bubble/bubble.js +1 -1
- package/dist/components/calendar/calendar.js +5 -5
- package/dist/components/cards/animated-card/animated-card.js +1 -1
- package/dist/components/cards/basic-details-card.js +2 -2
- package/dist/components/cards/collapsible-card.js +1 -1
- package/dist/components/cards/index.d.ts +2 -2
- package/dist/components/cards/no-data-card/no-data-card.js +2 -2
- package/dist/components/cards/section-card.js +12 -12
- package/dist/components/cards/simple-card.js +2 -5
- package/dist/components/category-card/category-card.js +2 -2
- package/dist/components/chart/chart.js +4 -4
- package/dist/components/chart/donut-chart.js +1 -1
- package/dist/components/chart/treemap-chart.js +1 -1
- package/dist/components/choice-card/choice-card.js +3 -3
- package/dist/components/code-editor/code-editor.js +4 -3
- package/dist/components/data-table/table-header.js +1 -1
- package/dist/components/date-range-picker/date-range-picker.js +3 -3
- package/dist/components/dynamic-list/dynamic-list.js +14 -13
- package/dist/components/dynamic-list/index.d.ts +1 -1
- package/dist/components/error-display/full-size-error/full-size-error.js +2 -2
- package/dist/components/expandable-text/expandable-text-overlay.js +1 -1
- package/dist/components/facet-filters/filter-group.js +2 -2
- package/dist/components/feature-grid/feature-grid.js +3 -3
- package/dist/components/file-input/file-input.js +8 -8
- package/dist/components/file-upload/file-upload.js +4 -4
- package/dist/components/fullscreen-dialog/fullscreen-dialog.js +1 -1
- package/dist/components/gradient-ring-button/_hooks/use-ring-geometry.js +116 -0
- package/dist/components/gradient-ring-button/gradient-ring-button.js +44 -0
- package/dist/components/gradient-ring-button/gradient-ring.js +77 -0
- package/dist/components/gradient-ring-button/index.d.ts +66 -0
- package/dist/components/gradient-ring-button/index.js +3 -0
- package/dist/components/horizontal-stepper/horizontal-stepper.js +2 -6
- package/dist/components/horizontal-stepper/index.d.ts +1 -1
- package/dist/components/icon-avatar/index.d.ts +3 -3
- package/dist/components/icon-text-action-card/index.d.ts +4 -4
- package/dist/components/index.d.ts +9 -7
- package/dist/components/index.js +5 -1
- package/dist/components/key-value-manager/key-value-manager-add-popover.js +1 -1
- package/dist/components/key-value-manager/key-value-manager-table.js +1 -1
- package/dist/components/link/link.js +7 -7
- package/dist/components/list/list-item.utils.js +5 -4
- package/dist/components/list/list.js +1 -1
- package/dist/components/list-details/index.d.ts +2 -2
- package/dist/components/markdown-content/markdown-content.components.js +2 -2
- package/dist/components/media-card/media-card-reveal.js +2 -2
- package/dist/components/media-card/media-card.js +2 -2
- package/dist/components/monospace-content/index.d.ts +4 -4
- package/dist/components/monospace-content/monospace-content.js +9 -11
- package/dist/components/nav-bar/nav-bar-mobile-menu.js +3 -3
- package/dist/components/nav-bar/nav-bar.js +4 -4
- package/dist/components/notice-strip/notice-strip.js +1 -1
- package/dist/components/option-card-group/option-card-group.js +2 -2
- package/dist/components/overflow-badge-list/index.d.ts +2 -2
- package/dist/components/overflow-badge-list/overflow-badge-list.js +3 -3
- package/dist/components/page-banner/page-banner.js +1 -1
- package/dist/components/page-container/page-container.js +1 -1
- package/dist/components/pagination/pagination.js +1 -1
- package/dist/components/progress-bar/progress-bar.js +2 -2
- package/dist/components/qr-code/qr-code.js +2 -2
- package/dist/components/radio-group/radio-group.js +3 -3
- package/dist/components/range-field/range-field.js +9 -12
- package/dist/components/readout/readout.js +1 -1
- package/dist/components/requirement-list/requirement-list.js +5 -10
- package/dist/components/scrollable-sections/scrollable-sections.js +1 -1
- package/dist/components/search-field-shell.js +8 -8
- package/dist/components/selectable-card-list/selectable-card-list-shared.js +6 -6
- package/dist/components/showcase-card/showcase-card.js +2 -2
- package/dist/components/sidebar/sidebar.js +13 -15
- package/dist/components/simple-clickable-card/index.d.ts +4 -4
- package/dist/components/simple-clickable-card/simple-clickable-card-shared.js +17 -23
- package/dist/components/simple-info-card/index.d.ts +3 -3
- package/dist/components/simple-list/index.d.ts +1 -1
- package/dist/components/simple-list/simple-list.js +8 -8
- package/dist/components/simple-paginated-list/simple-paginated-list.js +1 -4
- package/dist/components/stat-card/stat-card.js +7 -13
- package/dist/components/status-badge/index.d.ts +3 -3
- package/dist/components/status-badge/status-badge.js +4 -4
- package/dist/components/status-card-list/status-card-list.js +6 -6
- package/dist/components/tag/index.d.ts +1 -1
- package/dist/components/tag/tag.js +4 -4
- package/dist/components/tag-input/tag-input.js +12 -12
- package/dist/components/timeline/timeline.js +2 -2
- package/dist/components/toast/index.d.ts +1 -1
- package/dist/components/toast/toast.js +2 -2
- package/dist/components/toolbar/index.d.ts +5 -2
- package/dist/components/toolbar/toolbar-button.js +1 -1
- package/dist/components/toolbar/toolbar.js +9 -3
- package/dist/components/trace/trace.js +1 -1
- package/dist/components/transfer-list/transfer-list.js +2 -2
- package/dist/components/typography/index.d.ts +12 -3
- package/dist/components/typography/typography-variants.js +98 -13
- package/dist/components/typography/typography.js +4 -2
- package/dist/components/user-type-badge/user-type-badge.js +4 -4
- package/dist/components/vertical-stepper/vertical-stepper.js +11 -7
- package/dist/core/alert.js +3 -3
- package/dist/core/animate-ui/components/animate/code-header.js +1 -1
- package/dist/core/animate-ui/components/animate/code.js +1 -1
- package/dist/core/animate-ui/components/animate/tabs.js +6 -6
- package/dist/core/animate-ui/components/animate/tooltip.js +1 -1
- package/dist/core/animate-ui/components/base/progress.js +2 -2
- package/dist/core/animate-ui/components/radix/accordion.js +2 -2
- package/dist/core/animate-ui/components/radix/dialog.js +2 -2
- package/dist/core/animate-ui/components/radix/dropdown-menu.js +6 -6
- package/dist/core/animate-ui/components/radix/sheet.js +2 -2
- package/dist/core/animate-ui/components/radix/sidebar.js +8 -8
- package/dist/core/animate-ui/components/radix/toggle.js +1 -1
- package/dist/core/badge.js +1 -1
- package/dist/core/breadcrumb.js +1 -1
- package/dist/core/button/button.js +2 -2
- package/dist/core/button-group.js +1 -1
- package/dist/core/button.js +2 -2
- package/dist/core/card.js +2 -2
- package/dist/core/combobox/combobox.js +3 -3
- package/dist/core/command.js +5 -5
- package/dist/core/field-label-row.js +4 -4
- package/dist/core/form.js +2 -2
- package/dist/core/index.d.ts +1 -1
- package/dist/core/input/input.js +11 -11
- package/dist/core/input-otp/input-otp.js +12 -12
- package/dist/core/label.js +1 -1
- package/dist/core/select.js +6 -6
- package/dist/core/separator.js +1 -1
- package/dist/core/table.js +2 -2
- package/dist/core/textarea/textarea.js +9 -9
- package/dist/{icon-avatar.props-RYtw2eSW.d.ts → icon-avatar.props-BJe0-vva.d.ts} +1 -1
- package/dist/{icon-text-action-card.props-B2ggncUK.d.ts → icon-text-action-card.props-BU7yFi2Q.d.ts} +2 -2
- package/dist/index.d.ts +9 -7
- package/dist/index.js +6 -2
- package/dist/layouts/entry-layout/entry-layout.js +1 -1
- package/dist/layouts/index.d.ts +21 -6
- package/dist/layouts/index.js +1 -1
- package/dist/layouts/minimal-workspace-layout/minimal-workspace-layout.js +10 -18
- package/dist/layouts/minimal-workspace-layout/sidebar-trigger.js +35 -7
- package/dist/layouts/workspace-layout/footer/footer.js +1 -1
- package/dist/markdown/index.d.ts +4 -4
- package/dist/{section-card-B7c5uc08.d.ts → section-card-DqQeQkzU.d.ts} +1 -1
- package/dist/{simple-clickable-card.props-BrPCw7CR.d.ts → simple-clickable-card.props-BhhotZMp.d.ts} +2 -2
- package/dist/{status-badge.props-lKlEOfRt.d.ts → status-badge.props-BVe8CmQZ.d.ts} +1 -1
- package/dist/styles/type-scale.js +153 -0
- package/dist/tailwind-preset.js +120 -1
- package/dist/toast/index.d.ts +1 -1
- package/dist/utils/cn.js +16 -5
- package/dist/utils/index.d.ts +31 -2
- package/dist/utils/index.js +2 -1
- package/dist/utils/variant.js +47 -47
- package/dist/{variant-D81RhpbR.d.ts → variant-DjdaxfIA.d.ts} +6 -1
- package/package.json +3 -1
- package/src/styles/theme.css +8 -3
- package/src/styles/type-scale.css +152 -0
- package/tailwind.preset.ts +23 -0
|
@@ -34,7 +34,7 @@ function Segments({ segments, error, labelled }) {
|
|
|
34
34
|
* made of tokens. With `onClick` it is a real (toggle) button.
|
|
35
35
|
*/
|
|
36
36
|
function Readout({ segments, state = "normal", labelled = false, onClick, "aria-label": label, className }) {
|
|
37
|
-
const classes = cn("dark inline-flex h-6 items-center rounded-xs border bg-background font-mono
|
|
37
|
+
const classes = cn("dark inline-flex h-6 items-center rounded-xs border bg-background type-code font-mono leading-none tabular-nums", STATE[state], className);
|
|
38
38
|
if (!onClick) return /* @__PURE__ */ jsx("span", {
|
|
39
39
|
"aria-label": label,
|
|
40
40
|
"data-slot": "readout",
|
|
@@ -20,35 +20,30 @@ var stateVisuals = {
|
|
|
20
20
|
/**
|
|
21
21
|
* Aligned with SimpleList / VerticalStepper size scales. `iconTop` centres the
|
|
22
22
|
* icon on the label's first line when a description makes the row two lines
|
|
23
|
-
* (the row then aligns to the top); `
|
|
24
|
-
*
|
|
23
|
+
* (the row then aligns to the top); `describedRowGap` is the roomier spacing
|
|
24
|
+
* two-line rows need. The text keeps its roles at every size: the label is
|
|
25
|
+
* `type-body`, the description under it `type-secondary`.
|
|
25
26
|
*/
|
|
26
27
|
var sizeStyles = {
|
|
27
28
|
sm: {
|
|
28
|
-
text: "text-xs",
|
|
29
29
|
icon: "h-3.5 w-3.5 shrink-0",
|
|
30
30
|
gap: "gap-2",
|
|
31
31
|
rowGap: "gap-1",
|
|
32
32
|
iconTop: "mt-px",
|
|
33
|
-
description: "text-xs",
|
|
34
33
|
describedRowGap: "gap-2"
|
|
35
34
|
},
|
|
36
35
|
default: {
|
|
37
|
-
text: "text-sm",
|
|
38
36
|
icon: "size-4 shrink-0",
|
|
39
37
|
gap: "gap-2",
|
|
40
38
|
rowGap: "gap-1.5",
|
|
41
39
|
iconTop: "mt-0.5",
|
|
42
|
-
description: "text-xs",
|
|
43
40
|
describedRowGap: "gap-2.5"
|
|
44
41
|
},
|
|
45
42
|
lg: {
|
|
46
|
-
text: "text-base",
|
|
47
43
|
icon: "size-5 shrink-0",
|
|
48
44
|
gap: "gap-2.5",
|
|
49
45
|
rowGap: "gap-2",
|
|
50
46
|
iconTop: "mt-0.5",
|
|
51
|
-
description: "text-sm",
|
|
52
47
|
describedRowGap: "gap-3"
|
|
53
48
|
}
|
|
54
49
|
};
|
|
@@ -77,7 +72,7 @@ var RequirementList = forwardRef(function RequirementList({ items, size = "sm",
|
|
|
77
72
|
const visuals = stateVisuals[item.met ? "met" : "unmet"];
|
|
78
73
|
const Icon = visuals.icon;
|
|
79
74
|
return /* @__PURE__ */ jsxs("li", {
|
|
80
|
-
className: cn("flex transition-colors", item.description ? "items-start" : "items-center",
|
|
75
|
+
className: cn("flex transition-colors", item.description ? "items-start" : "items-center", "type-body", styles.gap, visuals.textClass),
|
|
81
76
|
children: [
|
|
82
77
|
/* @__PURE__ */ jsx(Icon, {
|
|
83
78
|
className: cn(styles.icon, item.description && styles.iconTop),
|
|
@@ -86,7 +81,7 @@ var RequirementList = forwardRef(function RequirementList({ items, size = "sm",
|
|
|
86
81
|
item.description ? /* @__PURE__ */ jsxs("span", {
|
|
87
82
|
className: "flex min-w-0 flex-col gap-0.5",
|
|
88
83
|
children: [/* @__PURE__ */ jsx("span", { children: item.label }), /* @__PURE__ */ jsx("span", {
|
|
89
|
-
className:
|
|
84
|
+
className: "type-secondary text-muted-foreground",
|
|
90
85
|
children: item.description
|
|
91
86
|
})]
|
|
92
87
|
}) : item.label,
|
|
@@ -187,7 +187,7 @@ function ScrollableSectionsRoot({ className, children, defaultValue, scrollRootR
|
|
|
187
187
|
value: safeActiveId,
|
|
188
188
|
onValueChange: selectSection,
|
|
189
189
|
children: [/* @__PURE__ */ jsx(SelectTrigger, {
|
|
190
|
-
className: "w-full
|
|
190
|
+
className: "w-full type-label",
|
|
191
191
|
children: /* @__PURE__ */ jsx(SelectValue, { placeholder: "Section" })
|
|
192
192
|
}), /* @__PURE__ */ jsx(SelectContent, { children: tabsItems.map((item) => /* @__PURE__ */ jsx(SelectItem, {
|
|
193
193
|
value: item.id,
|
|
@@ -2,18 +2,18 @@
|
|
|
2
2
|
/** Matches `buttonVariants` outline surface (border, bg, shadow, hover). */
|
|
3
3
|
var outlineSearchShellClasses = "border-[length:var(--espd-own-border-width,var(--espd-border-width-control,1px))] border-input bg-background transition-colors hover:bg-accent hover:text-accent-foreground";
|
|
4
4
|
var searchFieldContainerSizeClasses = {
|
|
5
|
-
default: "h-9 px-4 py-2
|
|
6
|
-
sm: "h-8 px-3
|
|
7
|
-
lg: "h-10 px-8
|
|
5
|
+
default: "h-9 px-4 py-2 type-input",
|
|
6
|
+
sm: "h-8 px-3 type-input",
|
|
7
|
+
lg: "h-10 px-8 type-input"
|
|
8
8
|
};
|
|
9
9
|
/**
|
|
10
|
-
* Text
|
|
11
|
-
* page into any focused field whose text is smaller than 16px.
|
|
10
|
+
* Text role of the search `<input>` itself: `type-input` at every size, like `Input` (16px on a
|
|
11
|
+
* phone, where iOS Safari zooms the page into any focused field whose text is smaller than 16px).
|
|
12
12
|
*/
|
|
13
13
|
var searchFieldInputTextClasses = {
|
|
14
|
-
default: "
|
|
15
|
-
sm: "
|
|
16
|
-
lg: "
|
|
14
|
+
default: "type-input",
|
|
15
|
+
sm: "type-input",
|
|
16
|
+
lg: "type-input"
|
|
17
17
|
};
|
|
18
18
|
var searchFieldIconSizeClasses = {
|
|
19
19
|
default: "h-4 w-4",
|
|
@@ -10,8 +10,8 @@ var sizeStyles = {
|
|
|
10
10
|
sm: {
|
|
11
11
|
rowPad: "p-3",
|
|
12
12
|
gap: "gap-2",
|
|
13
|
-
primary: "
|
|
14
|
-
secondary: "
|
|
13
|
+
primary: "type-heading text-foreground",
|
|
14
|
+
secondary: "type-secondary text-muted-foreground",
|
|
15
15
|
icon: "h-[18px] w-[18px] shrink-0 items-center justify-center",
|
|
16
16
|
indicator: "size-3.5",
|
|
17
17
|
avatar: 36,
|
|
@@ -20,8 +20,8 @@ var sizeStyles = {
|
|
|
20
20
|
default: {
|
|
21
21
|
rowPad: "p-4",
|
|
22
22
|
gap: "gap-3",
|
|
23
|
-
primary: "
|
|
24
|
-
secondary: "
|
|
23
|
+
primary: "type-heading text-foreground",
|
|
24
|
+
secondary: "type-secondary text-muted-foreground",
|
|
25
25
|
icon: "h-6 w-6 shrink-0 items-center justify-center",
|
|
26
26
|
indicator: "size-4",
|
|
27
27
|
avatar: 44,
|
|
@@ -30,8 +30,8 @@ var sizeStyles = {
|
|
|
30
30
|
lg: {
|
|
31
31
|
rowPad: "p-6",
|
|
32
32
|
gap: "gap-4",
|
|
33
|
-
primary: "
|
|
34
|
-
secondary: "
|
|
33
|
+
primary: "type-heading text-foreground",
|
|
34
|
+
secondary: "type-secondary text-muted-foreground",
|
|
35
35
|
icon: "h-8 w-8 shrink-0 items-center justify-center",
|
|
36
36
|
indicator: "size-5",
|
|
37
37
|
avatar: 52,
|
|
@@ -41,7 +41,7 @@ function ShowcaseRow({ media, title, open, titlePrefix, meta, footer, engage })
|
|
|
41
41
|
className: "min-h-24 min-w-0 gap-1.5 py-3.5 pr-3.5 pl-1 @md:min-h-42 @md:gap-2 @md:py-5 @md:pr-5",
|
|
42
42
|
children: [
|
|
43
43
|
/* @__PURE__ */ jsx(MediaCardTitle, {
|
|
44
|
-
className: "
|
|
44
|
+
className: "font-extrabold tracking-tight",
|
|
45
45
|
title,
|
|
46
46
|
children: /* @__PURE__ */ jsx(TitleLink, {
|
|
47
47
|
open,
|
|
@@ -50,7 +50,7 @@ function ShowcaseRow({ media, title, open, titlePrefix, meta, footer, engage })
|
|
|
50
50
|
})
|
|
51
51
|
}),
|
|
52
52
|
/* @__PURE__ */ jsx(MediaCardMeta, {
|
|
53
|
-
className: "block
|
|
53
|
+
className: "block @max-md:line-clamp-2",
|
|
54
54
|
children: meta
|
|
55
55
|
}),
|
|
56
56
|
footer && /* @__PURE__ */ jsx(MediaCardFooter, {
|
|
@@ -25,20 +25,18 @@ var sidebarGroupClassName = "py-0 px-2";
|
|
|
25
25
|
*/
|
|
26
26
|
var rowIconClass = "[&_svg:not([class*='size-'])]:size-4 [&_svg]:shrink-0";
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
28
|
+
* Every nav row is the `label` role: {@link rowTypeClass} brings its line height and
|
|
29
|
+
* weight (a row's own `font-*` still wins), and the inline style its size, read from
|
|
30
|
+
* `--espd-sidebar-item-font-size` (the public override hook, `label`'s size by
|
|
31
|
+
* default). The size is an inline style, not a class, so the hook beats the role:
|
|
29
32
|
* `SidebarMenuButton` is used with `asChild`, and both the highlight effect and
|
|
30
|
-
* app-supplied `linkComponent`s drop a forwarded `style`, so
|
|
31
|
-
* element this file owns.
|
|
33
|
+
* app-supplied `linkComponent`s drop a forwarded `style`, so both live on an
|
|
34
|
+
* element this file owns.
|
|
32
35
|
*/
|
|
33
|
-
var
|
|
34
|
-
|
|
35
|
-
lineHeight: "1.25rem"
|
|
36
|
-
};
|
|
36
|
+
var rowTypeClass = "type-label";
|
|
37
|
+
var rowFontStyle = { fontSize: "var(--espd-sidebar-item-font-size, var(--espd-type-label-size, 0.875rem))" };
|
|
37
38
|
/** Group title in the collapsed-sidebar flyout — same scale as the rows by default. */
|
|
38
|
-
var flyoutGroupLabelStyle = {
|
|
39
|
-
fontSize: "var(--espd-sidebar-flyout-group-label-font-size, 0.875rem)",
|
|
40
|
-
lineHeight: "1.25rem"
|
|
41
|
-
};
|
|
39
|
+
var flyoutGroupLabelStyle = { fontSize: "var(--espd-sidebar-flyout-group-label-font-size, var(--espd-type-label-size, 0.875rem))" };
|
|
42
40
|
/**
|
|
43
41
|
* Nav icon for a group or an item. Deliberately sets no size — that comes from the
|
|
44
42
|
* row's {@link rowIconClass}. Items with no `icon` get a neutral placeholder glyph so
|
|
@@ -68,7 +66,7 @@ function forwardRowClickToLink(e) {
|
|
|
68
66
|
function GroupMenuItems({ group, isSelected, linkComponent: LinkComponent, onItemClick, onItemPointerDown }) {
|
|
69
67
|
return /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
70
68
|
/* @__PURE__ */ jsxs(DropdownMenuLabel, {
|
|
71
|
-
className: cn("flex items-center gap-2 px-3 py-2 font-normal text-muted-foreground", rowIconClass),
|
|
69
|
+
className: cn("flex items-center gap-2 px-3 py-2 font-normal text-muted-foreground", rowTypeClass, rowIconClass),
|
|
72
70
|
style: flyoutGroupLabelStyle,
|
|
73
71
|
children: [group.icon ? /* @__PURE__ */ jsx(ItemIcon, {
|
|
74
72
|
icon: group.icon,
|
|
@@ -82,7 +80,7 @@ function GroupMenuItems({ group, isSelected, linkComponent: LinkComponent, onIte
|
|
|
82
80
|
group.items.map((item) => {
|
|
83
81
|
const active = isSelected(item.path);
|
|
84
82
|
return /* @__PURE__ */ jsx(DropdownMenuItem, {
|
|
85
|
-
className: active
|
|
83
|
+
className: cn(rowTypeClass, active && "bg-accent"),
|
|
86
84
|
style: rowFontStyle,
|
|
87
85
|
onPointerDown: onItemPointerDown,
|
|
88
86
|
onClickCapture: onItemClick,
|
|
@@ -152,7 +150,7 @@ function CollapsedSidebarGroup({ group, isSelected, linkComponent: LinkComponent
|
|
|
152
150
|
})
|
|
153
151
|
});
|
|
154
152
|
}
|
|
155
|
-
var groupHeaderClass = cn("flex w-full items-center gap-2 rounded-[var(--espd-own-radius,var(--espd-radius-item,var(--radius-md)))] p-2 h-[var(--espd-sidebar-row-height-sm,calc(var(--spacing)*7))] overflow-hidden
|
|
153
|
+
var groupHeaderClass = cn("flex w-full items-center gap-2 rounded-[var(--espd-own-radius,var(--espd-radius-item,var(--radius-md)))] p-2 h-[var(--espd-sidebar-row-height-sm,calc(var(--spacing)*7))] overflow-hidden text-sidebar-foreground hover:bg-sidebar-accent/50 transition-colors cursor-pointer", rowIconClass, rowTypeClass);
|
|
156
154
|
/**
|
|
157
155
|
* Expanded sidebar group with inline collapsible items.
|
|
158
156
|
* Clicking the group header toggles expand/collapse. No flyout menus here —
|
|
@@ -271,7 +269,7 @@ function Sidebar({ items, currentPath, header, headerHeight, footer, linkCompone
|
|
|
271
269
|
icon: item.icon,
|
|
272
270
|
active
|
|
273
271
|
}), /* @__PURE__ */ jsx("span", {
|
|
274
|
-
className: cn("whitespace-nowrap max-w-[168px] truncate", active ? "font-semibold text-sidebar-accent-foreground" : "font-medium text-sidebar-foreground"),
|
|
272
|
+
className: cn("whitespace-nowrap max-w-[168px] truncate", rowTypeClass, active ? "font-semibold text-sidebar-accent-foreground" : "font-medium text-sidebar-foreground"),
|
|
275
273
|
style: rowFontStyle,
|
|
276
274
|
children: item.label
|
|
277
275
|
})]
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import { S as SimpleClickableCardProps } from '../../simple-clickable-card.props-
|
|
3
|
-
export { a as SimpleClickableCardSharedProps, b as SimpleClickableCardVariant } from '../../simple-clickable-card.props-
|
|
2
|
+
import { S as SimpleClickableCardProps } from '../../simple-clickable-card.props-BhhotZMp.js';
|
|
3
|
+
export { a as SimpleClickableCardSharedProps, b as SimpleClickableCardVariant } from '../../simple-clickable-card.props-BhhotZMp.js';
|
|
4
4
|
import '../../index-BQANnKs9.js';
|
|
5
|
-
import '../../variant-
|
|
5
|
+
import '../../variant-DjdaxfIA.js';
|
|
6
6
|
import '../../style-axes-DSQ2DGc5.js';
|
|
7
|
-
import '../../icon-avatar.props-
|
|
7
|
+
import '../../icon-avatar.props-BJe0-vva.js';
|
|
8
8
|
|
|
9
9
|
declare const SimpleClickableCard: React.ForwardRefExoticComponent<SimpleClickableCardProps & React.RefAttributes<HTMLButtonElement>>;
|
|
10
10
|
|
|
@@ -17,8 +17,7 @@ var SIZE_STYLES = {
|
|
|
17
17
|
chevronPx: 20,
|
|
18
18
|
avatar: 36,
|
|
19
19
|
iconPx: 18,
|
|
20
|
-
|
|
21
|
-
titleSizeClass: "text-xs"
|
|
20
|
+
descriptionVariant: "secondary"
|
|
22
21
|
},
|
|
23
22
|
default: {
|
|
24
23
|
rowPad: "p-4",
|
|
@@ -27,7 +26,7 @@ var SIZE_STYLES = {
|
|
|
27
26
|
chevronPx: 24,
|
|
28
27
|
avatar: 44,
|
|
29
28
|
iconPx: 22,
|
|
30
|
-
|
|
29
|
+
descriptionVariant: "body"
|
|
31
30
|
},
|
|
32
31
|
lg: {
|
|
33
32
|
rowPad: "p-6",
|
|
@@ -36,7 +35,7 @@ var SIZE_STYLES = {
|
|
|
36
35
|
chevronPx: 32,
|
|
37
36
|
avatar: 52,
|
|
38
37
|
iconPx: 26,
|
|
39
|
-
|
|
38
|
+
descriptionVariant: "body"
|
|
40
39
|
}
|
|
41
40
|
};
|
|
42
41
|
function iconSized(icon, iconPx) {
|
|
@@ -197,10 +196,10 @@ function renderTitleAndDescriptionBlocks(p) {
|
|
|
197
196
|
const { title, description, truncateTitle = false, truncateDescription = false, s, fgClass, fgStyle, descClass, descStyle } = p;
|
|
198
197
|
const titleIsString = typeof title === "string";
|
|
199
198
|
const descriptionIsString = typeof description === "string";
|
|
200
|
-
const renderTitleTypography = (
|
|
199
|
+
const renderTitleTypography = (opts) => /* @__PURE__ */ jsx(Typography, {
|
|
201
200
|
as: "span",
|
|
202
|
-
variant:
|
|
203
|
-
className: cn("min-w-0 text-left",
|
|
201
|
+
variant: "subheading",
|
|
202
|
+
className: cn("min-w-0 text-left", fgClass, !opts.truncate && "break-words"),
|
|
204
203
|
style: fgStyle,
|
|
205
204
|
children: title
|
|
206
205
|
});
|
|
@@ -208,45 +207,40 @@ function renderTitleAndDescriptionBlocks(p) {
|
|
|
208
207
|
if (hasRenderableTitle(title)) if (titleIsString && truncateTitle) titleBlock = /* @__PURE__ */ jsx(TruncatedLineWithTooltip, {
|
|
209
208
|
className: "w-full",
|
|
210
209
|
tooltipContent: title,
|
|
211
|
-
children: renderTitleTypography(
|
|
212
|
-
truncate: true,
|
|
213
|
-
extraTitleClass: s.titleSizeClass
|
|
214
|
-
})
|
|
215
|
-
});
|
|
216
|
-
else if (titleIsString) titleBlock = renderTitleTypography(s.titleVariant, {
|
|
217
|
-
truncate: false,
|
|
218
|
-
extraTitleClass: s.titleSizeClass
|
|
210
|
+
children: renderTitleTypography({ truncate: true })
|
|
219
211
|
});
|
|
212
|
+
else if (titleIsString) titleBlock = renderTitleTypography({ truncate: false });
|
|
220
213
|
else titleBlock = /* @__PURE__ */ jsx(Typography, {
|
|
221
214
|
as: "div",
|
|
222
|
-
variant:
|
|
223
|
-
className: cn("min-w-0 text-left",
|
|
215
|
+
variant: "subheading",
|
|
216
|
+
className: cn("min-w-0 text-left", fgClass),
|
|
224
217
|
style: fgStyle,
|
|
225
218
|
children: title
|
|
226
219
|
});
|
|
220
|
+
const descriptionTypeClass = hasRenderableTitle(title) ? "font-medium" : "font-normal";
|
|
227
221
|
let descriptionBlock = null;
|
|
228
222
|
if (hasRenderableDescription(description)) if (descriptionIsString && truncateDescription) descriptionBlock = /* @__PURE__ */ jsx(TruncatedLineWithTooltip, {
|
|
229
223
|
className: "w-full",
|
|
230
224
|
tooltipContent: description,
|
|
231
225
|
children: /* @__PURE__ */ jsx(Typography, {
|
|
232
226
|
as: "span",
|
|
233
|
-
variant:
|
|
234
|
-
className: cn("text-left
|
|
227
|
+
variant: s.descriptionVariant,
|
|
228
|
+
className: cn("text-left", descriptionTypeClass, descClass),
|
|
235
229
|
style: descStyle,
|
|
236
230
|
children: description
|
|
237
231
|
})
|
|
238
232
|
});
|
|
239
233
|
else if (descriptionIsString) descriptionBlock = /* @__PURE__ */ jsx(Typography, {
|
|
240
234
|
as: "span",
|
|
241
|
-
variant:
|
|
242
|
-
className: cn("break-words text-left
|
|
235
|
+
variant: s.descriptionVariant,
|
|
236
|
+
className: cn("break-words text-left", descriptionTypeClass, descClass),
|
|
243
237
|
style: descStyle,
|
|
244
238
|
children: description
|
|
245
239
|
});
|
|
246
240
|
else descriptionBlock = /* @__PURE__ */ jsx(Typography, {
|
|
247
241
|
as: "div",
|
|
248
|
-
variant:
|
|
249
|
-
className: cn("min-w-0 text-left
|
|
242
|
+
variant: s.descriptionVariant,
|
|
243
|
+
className: cn("min-w-0 text-left", descriptionTypeClass, descClass),
|
|
250
244
|
style: descStyle,
|
|
251
245
|
children: description
|
|
252
246
|
});
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { HTMLAttributes, ReactNode } from 'react';
|
|
3
|
-
import { a as SimpleClickableCardSharedProps } from '../../simple-clickable-card.props-
|
|
3
|
+
import { a as SimpleClickableCardSharedProps } from '../../simple-clickable-card.props-BhhotZMp.js';
|
|
4
4
|
import { k as StyleAxisProps } from '../../style-axes-DSQ2DGc5.js';
|
|
5
5
|
import '../../index-BQANnKs9.js';
|
|
6
|
-
import '../../variant-
|
|
7
|
-
import '../../icon-avatar.props-
|
|
6
|
+
import '../../variant-DjdaxfIA.js';
|
|
7
|
+
import '../../icon-avatar.props-BJe0-vva.js';
|
|
8
8
|
|
|
9
9
|
/** Display-only card body; only the info icon is interactive (tab/focus). */
|
|
10
10
|
interface SimpleInfoCardProps extends SimpleClickableCardSharedProps, Pick<StyleAxisProps, "radius">, Omit<HTMLAttributes<HTMLDivElement>, keyof SimpleClickableCardSharedProps | "title"> {
|
|
@@ -33,7 +33,7 @@ interface SimpleListItem {
|
|
|
33
33
|
}
|
|
34
34
|
interface SimpleListProps extends DensityProps {
|
|
35
35
|
items: SimpleListItem[];
|
|
36
|
-
/** Overall list spacing and
|
|
36
|
+
/** Overall list spacing (and the avatar size). Text keeps its type role at every size. Default: `"default"`. */
|
|
37
37
|
size?: SimpleListSize;
|
|
38
38
|
/**
|
|
39
39
|
* Default direction for items that don't specify their own. Default: `"column"`.
|
|
@@ -20,14 +20,18 @@ var AVATAR_SIZE = {
|
|
|
20
20
|
icon: "h-6 w-6"
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
|
+
/**
|
|
24
|
+
* Text roles, the same at every `size` (size moves gaps and icon sizes only):
|
|
25
|
+
* the item's label is a field label, a row item's value is running text.
|
|
26
|
+
*/
|
|
27
|
+
var LABEL_TYPOGRAPHY = "type-label";
|
|
28
|
+
var ROW_VALUE_TYPOGRAPHY = "type-body";
|
|
23
29
|
var LIST_SIZE_STYLES = {
|
|
24
30
|
sm: {
|
|
25
31
|
listGap: "gap-4",
|
|
26
32
|
rowGap: "gap-3",
|
|
27
33
|
rowGapFromSm: "sm:gap-3",
|
|
28
34
|
itemGap: "gap-1.5",
|
|
29
|
-
labelTypography: "text-xs font-medium",
|
|
30
|
-
rowValueTypography: "text-xs",
|
|
31
35
|
inlineIcon: "h-3.5 w-3.5 shrink-0",
|
|
32
36
|
avatarFallbackTypography: "text-[10px]"
|
|
33
37
|
},
|
|
@@ -36,8 +40,6 @@ var LIST_SIZE_STYLES = {
|
|
|
36
40
|
rowGap: "gap-4",
|
|
37
41
|
rowGapFromSm: "sm:gap-4",
|
|
38
42
|
itemGap: "gap-2",
|
|
39
|
-
labelTypography: "text-sm font-medium",
|
|
40
|
-
rowValueTypography: "text-sm",
|
|
41
43
|
inlineIcon: "h-4 w-4 shrink-0",
|
|
42
44
|
avatarFallbackTypography: "text-xs"
|
|
43
45
|
},
|
|
@@ -46,8 +48,6 @@ var LIST_SIZE_STYLES = {
|
|
|
46
48
|
rowGap: "gap-5",
|
|
47
49
|
rowGapFromSm: "sm:gap-5",
|
|
48
50
|
itemGap: "gap-3",
|
|
49
|
-
labelTypography: "text-base font-medium",
|
|
50
|
-
rowValueTypography: "text-base",
|
|
51
51
|
inlineIcon: "h-[18px] w-[18px] shrink-0",
|
|
52
52
|
avatarFallbackTypography: "text-sm"
|
|
53
53
|
}
|
|
@@ -90,7 +90,7 @@ function ItemRow({ item, effectiveDirection, iconStyle, avatarSize, size }) {
|
|
|
90
90
|
})
|
|
91
91
|
}) : null;
|
|
92
92
|
const labelNode = /* @__PURE__ */ jsx(Label, {
|
|
93
|
-
className:
|
|
93
|
+
className: LABEL_TYPOGRAPHY,
|
|
94
94
|
children: inlineIconNode != null ? /* @__PURE__ */ jsxs("span", {
|
|
95
95
|
className: "flex items-center gap-2",
|
|
96
96
|
children: [inlineIconNode, /* @__PURE__ */ jsx("span", { children: item.label })]
|
|
@@ -111,7 +111,7 @@ function ItemRow({ item, effectiveDirection, iconStyle, avatarSize, size }) {
|
|
|
111
111
|
className: "shrink-0",
|
|
112
112
|
children: labelNode
|
|
113
113
|
}), /* @__PURE__ */ jsx("div", {
|
|
114
|
-
className: cn("min-w-0 flex sm:flex-1 sm:justify-end",
|
|
114
|
+
className: cn("min-w-0 flex sm:flex-1 sm:justify-end", ROW_VALUE_TYPOGRAPHY),
|
|
115
115
|
children: item.content
|
|
116
116
|
})]
|
|
117
117
|
})]
|
|
@@ -11,21 +11,18 @@ var SIZE_STYLES = {
|
|
|
11
11
|
rowPad: "py-2",
|
|
12
12
|
insetX: "px-2",
|
|
13
13
|
gap: "gap-2",
|
|
14
|
-
label: "text-xs",
|
|
15
14
|
icon: "h-3.5 w-3.5 shrink-0"
|
|
16
15
|
},
|
|
17
16
|
default: {
|
|
18
17
|
rowPad: "py-3",
|
|
19
18
|
insetX: "px-2",
|
|
20
19
|
gap: "gap-3",
|
|
21
|
-
label: "text-sm",
|
|
22
20
|
icon: "h-4 w-4 shrink-0"
|
|
23
21
|
},
|
|
24
22
|
lg: {
|
|
25
23
|
rowPad: "py-4",
|
|
26
24
|
insetX: "px-3",
|
|
27
25
|
gap: "gap-4",
|
|
28
|
-
label: "text-base",
|
|
29
26
|
icon: "h-5 w-5 shrink-0"
|
|
30
27
|
}
|
|
31
28
|
};
|
|
@@ -83,7 +80,7 @@ function ListRow({ item, showBorder, styles }) {
|
|
|
83
80
|
children: renderSizedIcon(item.icon, styles.icon)
|
|
84
81
|
}) : null,
|
|
85
82
|
/* @__PURE__ */ jsx("span", {
|
|
86
|
-
className:
|
|
83
|
+
className: "min-w-0 flex-1 truncate type-body",
|
|
87
84
|
children: item.label
|
|
88
85
|
}),
|
|
89
86
|
item.action != null ? /* @__PURE__ */ jsx("span", {
|
|
@@ -40,10 +40,8 @@ var SIZE_STYLES = {
|
|
|
40
40
|
headerGap: "gap-3",
|
|
41
41
|
avatar: 40,
|
|
42
42
|
icon: "size-5",
|
|
43
|
-
heading: "text-base",
|
|
44
43
|
value: "text-2xl",
|
|
45
|
-
|
|
46
|
-
badge: "gap-1 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-2.5 py-0.5 text-xs",
|
|
44
|
+
badge: "gap-1 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-2.5 py-0.5 type-caption",
|
|
47
45
|
info: "size-7 [&_svg]:size-4",
|
|
48
46
|
visual: "h-7"
|
|
49
47
|
},
|
|
@@ -53,10 +51,8 @@ var SIZE_STYLES = {
|
|
|
53
51
|
headerGap: "gap-3",
|
|
54
52
|
avatar: 52,
|
|
55
53
|
icon: "size-6",
|
|
56
|
-
heading: "text-xl",
|
|
57
54
|
value: "text-3xl",
|
|
58
|
-
|
|
59
|
-
badge: "gap-1 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-3 py-1 text-sm",
|
|
55
|
+
badge: "gap-1 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-3 py-1 type-caption",
|
|
60
56
|
info: "size-8 [&_svg]:size-5",
|
|
61
57
|
visual: "h-8"
|
|
62
58
|
},
|
|
@@ -66,10 +62,8 @@ var SIZE_STYLES = {
|
|
|
66
62
|
headerGap: "gap-4",
|
|
67
63
|
avatar: 60,
|
|
68
64
|
icon: "size-7",
|
|
69
|
-
heading: "text-2xl",
|
|
70
65
|
value: "text-4xl",
|
|
71
|
-
|
|
72
|
-
badge: "gap-1.5 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-3.5 py-1 text-base",
|
|
66
|
+
badge: "gap-1.5 rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] px-3.5 py-1 type-caption",
|
|
73
67
|
info: "size-9 [&_svg]:size-6",
|
|
74
68
|
visual: "h-10"
|
|
75
69
|
}
|
|
@@ -164,8 +158,8 @@ var StatCard = React$1.forwardRef(({ color, size = "default", loading = false, i
|
|
|
164
158
|
children: renderSizedIcon(icon, s.icon)
|
|
165
159
|
}) : null, /* @__PURE__ */ jsx(Typography, {
|
|
166
160
|
as: "div",
|
|
167
|
-
variant: "
|
|
168
|
-
className:
|
|
161
|
+
variant: "heading",
|
|
162
|
+
className: "font-medium leading-tight",
|
|
169
163
|
children: heading
|
|
170
164
|
})]
|
|
171
165
|
}),
|
|
@@ -179,13 +173,13 @@ var StatCard = React$1.forwardRef(({ color, size = "default", loading = false, i
|
|
|
179
173
|
className: cn("flex w-full items-end", s.visual),
|
|
180
174
|
children: visual
|
|
181
175
|
}) : null, caption != null ? /* @__PURE__ */ jsx("div", {
|
|
182
|
-
className:
|
|
176
|
+
className: "min-w-0 truncate type-secondary text-foreground-secondary",
|
|
183
177
|
title: typeof caption === "string" ? caption : void 0,
|
|
184
178
|
children: caption
|
|
185
179
|
}) : null]
|
|
186
180
|
}) : null,
|
|
187
181
|
showFooter ? /* @__PURE__ */ jsxs("div", {
|
|
188
|
-
className:
|
|
182
|
+
className: "flex items-center gap-3 type-secondary",
|
|
189
183
|
children: [/* @__PURE__ */ jsxs("div", {
|
|
190
184
|
className: "flex min-w-0 flex-1 items-center gap-3",
|
|
191
185
|
children: [showTrend ? /* @__PURE__ */ jsxs(Badge, {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as class_variance_authority_types from 'class-variance-authority/types';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import { a as StatusBadgeProps } from '../../status-badge.props-
|
|
4
|
-
export { S as StatusBadgeIcon } from '../../status-badge.props-
|
|
3
|
+
import { a as StatusBadgeProps } from '../../status-badge.props-BVe8CmQZ.js';
|
|
4
|
+
export { S as StatusBadgeIcon } from '../../status-badge.props-BVe8CmQZ.js';
|
|
5
5
|
import 'lucide-react';
|
|
6
6
|
import '../../index-BQANnKs9.js';
|
|
7
|
-
import '../../variant-
|
|
7
|
+
import '../../variant-DjdaxfIA.js';
|
|
8
8
|
import '../../style-axes-DSQ2DGc5.js';
|
|
9
9
|
|
|
10
10
|
declare const statusBadgeSizeVariants: (props?: ({
|
|
@@ -22,12 +22,12 @@ var ICON_PX = {
|
|
|
22
22
|
default: 16,
|
|
23
23
|
lg: 18
|
|
24
24
|
};
|
|
25
|
-
var statusBadgeSizeVariants = cva("rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] font-normal [&_svg]:shrink-0", {
|
|
25
|
+
var statusBadgeSizeVariants = cva("rounded-[var(--espd-own-radius,var(--espd-radius-pill,calc(infinity*1px)))] type-caption font-normal [&_svg]:shrink-0", {
|
|
26
26
|
variants: {
|
|
27
27
|
size: {
|
|
28
|
-
sm: "gap-1 py-0.5
|
|
29
|
-
default: "gap-1.5 py-0.5
|
|
30
|
-
lg: "gap-1.5 py-1
|
|
28
|
+
sm: "gap-1 py-0.5",
|
|
29
|
+
default: "gap-1.5 py-0.5",
|
|
30
|
+
lg: "gap-1.5 py-1"
|
|
31
31
|
},
|
|
32
32
|
hasIcon: {
|
|
33
33
|
true: "",
|
|
@@ -82,8 +82,8 @@ var sizeStyles = {
|
|
|
82
82
|
sm: {
|
|
83
83
|
rowPad: "p-3",
|
|
84
84
|
gap: "gap-2",
|
|
85
|
-
primary: "
|
|
86
|
-
secondary: "
|
|
85
|
+
primary: "type-heading",
|
|
86
|
+
secondary: "type-secondary",
|
|
87
87
|
icon: "h-[18px] w-[18px] shrink-0",
|
|
88
88
|
endIcon: "size-5 shrink-0",
|
|
89
89
|
avatar: 36,
|
|
@@ -92,8 +92,8 @@ var sizeStyles = {
|
|
|
92
92
|
default: {
|
|
93
93
|
rowPad: "p-4",
|
|
94
94
|
gap: "gap-3",
|
|
95
|
-
primary: "
|
|
96
|
-
secondary: "
|
|
95
|
+
primary: "type-heading",
|
|
96
|
+
secondary: "type-body",
|
|
97
97
|
icon: "h-6 w-6 shrink-0",
|
|
98
98
|
endIcon: "size-6 shrink-0",
|
|
99
99
|
avatar: 44,
|
|
@@ -102,8 +102,8 @@ var sizeStyles = {
|
|
|
102
102
|
lg: {
|
|
103
103
|
rowPad: "p-6",
|
|
104
104
|
gap: "gap-4",
|
|
105
|
-
primary: "
|
|
106
|
-
secondary: "
|
|
105
|
+
primary: "type-heading",
|
|
106
|
+
secondary: "type-body",
|
|
107
107
|
icon: "h-8 w-8 shrink-0",
|
|
108
108
|
endIcon: "size-7 shrink-0",
|
|
109
109
|
avatar: 52,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { HTMLAttributes } from 'react';
|
|
3
3
|
import { S as Size, P as PresetColor } from '../../index-BQANnKs9.js';
|
|
4
|
-
import { f as Variant } from '../../variant-
|
|
4
|
+
import { f as Variant } from '../../variant-DjdaxfIA.js';
|
|
5
5
|
import { k as StyleAxisProps } from '../../style-axes-DSQ2DGc5.js';
|
|
6
6
|
|
|
7
7
|
interface TagProps extends HTMLAttributes<HTMLDivElement>, Pick<StyleAxisProps, "radius"> {
|
|
@@ -84,11 +84,11 @@ function getNameChipTint(variant, color) {
|
|
|
84
84
|
if (color === "silver") return builtInRow(SILVER_NAME_CHIP_TINT, variant);
|
|
85
85
|
return builtInRow(NAME_CHIP_TINT, variant)[color];
|
|
86
86
|
}
|
|
87
|
-
var tagSizeVariants = cva("inline-flex min-w-0 max-w-full items-center shadow-none transition-shadow duration-200 ease-out hover:shadow-sm [&_svg]:shrink-0", {
|
|
87
|
+
var tagSizeVariants = cva("inline-flex min-w-0 max-w-full items-center type-caption shadow-none transition-shadow duration-200 ease-out hover:shadow-sm [&_svg]:shrink-0", {
|
|
88
88
|
variants: { size: {
|
|
89
|
-
sm: "gap-1 px-1.5 py-0.5
|
|
90
|
-
default: "gap-1.5 px-2 py-1
|
|
91
|
-
lg: "gap-2 px-2.5 py-1.5
|
|
89
|
+
sm: "gap-1 px-1.5 py-0.5 [&_svg]:size-3",
|
|
90
|
+
default: "gap-1.5 px-2 py-1 [&_svg]:size-3.5",
|
|
91
|
+
lg: "gap-2 px-2.5 py-1.5 [&_svg]:size-4"
|
|
92
92
|
} },
|
|
93
93
|
defaultVariants: { size: "default" }
|
|
94
94
|
});
|