gridsmith-ui 0.2.18 → 0.3.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/dist/index.d.ts +1 -2
- package/dist/index.js +79 -53
- package/dist/index.js.map +1 -1
- package/dist/roots.css +27 -0
- package/package.json +3 -2
package/dist/index.d.ts
CHANGED
|
@@ -928,13 +928,12 @@ interface PageHeaderProps {
|
|
|
928
928
|
onBack?: () => void;
|
|
929
929
|
actions?: ReactNode;
|
|
930
930
|
avatar?: ReactNode;
|
|
931
|
-
stats?: ReactNode;
|
|
932
931
|
filters?: ReactNode;
|
|
933
932
|
bannerImage?: string;
|
|
934
933
|
as?: HeadingLevel;
|
|
935
934
|
className?: string;
|
|
936
935
|
}
|
|
937
|
-
declare function PageHeader({ title, description, badge, breadcrumbs, onBack, actions, avatar,
|
|
936
|
+
declare function PageHeader({ title, description, badge, breadcrumbs, onBack, actions, avatar, filters, bannerImage, as: Heading, className, }: PageHeaderProps): react_jsx_runtime.JSX.Element;
|
|
938
937
|
|
|
939
938
|
interface DockItem {
|
|
940
939
|
id: string;
|
package/dist/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { cn, GLASS_BACKDROP, lockBodyScroll, unlockBodyScroll, GLASS_OVERLAY,
|
|
1
|
+
import { cn, GLASS_BACKDROP, GLASS_DROPDOWN, lockBodyScroll, unlockBodyScroll, GLASS_OVERLAY, GLASS_SURFACE } from './chunk-5XIPPVH7.js';
|
|
2
2
|
import { Icon } from './chunk-H2XI6OUB.js';
|
|
3
3
|
import { __commonJS, __toESM } from './chunk-5WRI5ZAA.js';
|
|
4
4
|
import * as React6 from 'react';
|
|
5
|
-
import React6__default, { createContext, forwardRef, useState, useCallback, useRef, useContext, useId, useMemo, useEffect, createElement, Fragment as Fragment$1,
|
|
5
|
+
import React6__default, { createContext, forwardRef, useState, useCallback, useRef, useContext, useId, useMemo, useEffect, useLayoutEffect, isValidElement, cloneElement, createElement, Fragment as Fragment$1, useDebugValue, memo, useReducer, useSyncExternalStore as useSyncExternalStore$1, useImperativeHandle } from 'react';
|
|
6
6
|
import ReactDOM, { createPortal, unstable_batchedUpdates, flushSync } from 'react-dom';
|
|
7
7
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
8
8
|
import { useSyncExternalStore } from 'use-sync-external-store/shim/index.js';
|
|
@@ -1545,6 +1545,17 @@ var require_core = __commonJS({
|
|
|
1545
1545
|
highlight.default = highlight;
|
|
1546
1546
|
}
|
|
1547
1547
|
});
|
|
1548
|
+
function mergeRefs(...refs) {
|
|
1549
|
+
const filtered = refs.filter(Boolean);
|
|
1550
|
+
if (filtered.length === 0) return void 0;
|
|
1551
|
+
if (filtered.length === 1) return filtered[0];
|
|
1552
|
+
return (node) => {
|
|
1553
|
+
for (const ref of filtered) {
|
|
1554
|
+
if (typeof ref === "function") ref(node);
|
|
1555
|
+
else if (ref && typeof ref === "object") ref.current = node;
|
|
1556
|
+
}
|
|
1557
|
+
};
|
|
1558
|
+
}
|
|
1548
1559
|
function Slot({ children, ref, ...slotProps }) {
|
|
1549
1560
|
if (!isValidElement(children)) {
|
|
1550
1561
|
console.warn("Slot: expected a single React element child.");
|
|
@@ -1570,7 +1581,8 @@ function Slot({ children, ref, ...slotProps }) {
|
|
|
1570
1581
|
}
|
|
1571
1582
|
}
|
|
1572
1583
|
if (ref) {
|
|
1573
|
-
|
|
1584
|
+
const childRef = children.ref ?? childProps.ref;
|
|
1585
|
+
mergedProps.ref = mergeRefs(ref, childRef);
|
|
1574
1586
|
}
|
|
1575
1587
|
return cloneElement(children, mergedProps);
|
|
1576
1588
|
}
|
|
@@ -2230,7 +2242,7 @@ function Dropdown({
|
|
|
2230
2242
|
"rounded-[var(--ds-radius-md)]",
|
|
2231
2243
|
"shadow-[var(--ds-input-shadow)]",
|
|
2232
2244
|
"transition-colors",
|
|
2233
|
-
!error && !disabled && "hover:border-[var(--ds-input-border-hover)]",
|
|
2245
|
+
!error && !disabled && !open && "hover:border-[var(--ds-input-border-hover)]",
|
|
2234
2246
|
open && !error && "border-[var(--ds-input-focus-ring)] ring-2 ring-[var(--ds-input-focus-ring)]",
|
|
2235
2247
|
"focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--ds-input-focus-ring)] focus-visible:border-[var(--ds-input-focus-ring)]",
|
|
2236
2248
|
"cursor-pointer disabled:cursor-not-allowed disabled:opacity-disabled",
|
|
@@ -2781,7 +2793,7 @@ function DatePicker({ value, onChange, placeholder = "Pick a date", disabled, cl
|
|
|
2781
2793
|
"shadow-[var(--ds-input-shadow)]",
|
|
2782
2794
|
"transition-colors cursor-pointer",
|
|
2783
2795
|
"px-ds-3 py-ds-2",
|
|
2784
|
-
!error && !disabled && "hover:border-[var(--ds-input-border-hover)]",
|
|
2796
|
+
!error && !disabled && !open && "hover:border-[var(--ds-input-border-hover)]",
|
|
2785
2797
|
open && "border-[var(--ds-accent-primary)] ring-2 ring-[var(--ds-input-focus-ring)]",
|
|
2786
2798
|
disabled && "opacity-disabled cursor-not-allowed",
|
|
2787
2799
|
value ? "text-[var(--ds-text-primary)]" : "text-[var(--ds-text-muted)]"
|
|
@@ -2997,14 +3009,17 @@ function FileUpload({ onFiles, accept, multiple = true, maxSize, className, erro
|
|
|
2997
3009
|
onClick: () => inputRef.current?.click(),
|
|
2998
3010
|
"aria-invalid": error || void 0,
|
|
2999
3011
|
className: cn(
|
|
3000
|
-
"flex flex-col items-center justify-center gap-ds-2 cursor-pointer",
|
|
3012
|
+
"flex flex-col items-center justify-center gap-ds-2 cursor-pointer group",
|
|
3001
3013
|
"border-2 border-dashed rounded-[var(--ds-radius-md)]",
|
|
3002
3014
|
"transition-colors",
|
|
3003
|
-
error ? "border-[var(--ds-status-error)]" : dragOver ? "border-[var(--ds-accent-primary)] bg-[var(--ds-accent-primary)]/5" : "border-[var(--ds-border-default)] hover:border-[var(--ds-
|
|
3015
|
+
error ? "border-[var(--ds-status-error)]" : dragOver ? "border-[var(--ds-accent-primary)] bg-[var(--ds-accent-primary)]/5" : "border-[var(--ds-border-default)] hover:border-[var(--ds-accent-primary)] hover:bg-[var(--ds-accent-primary)]/5"
|
|
3004
3016
|
),
|
|
3005
3017
|
style: { padding: "var(--ds-space-8) var(--ds-space-4)" },
|
|
3006
3018
|
children: [
|
|
3007
|
-
/* @__PURE__ */ jsx("div", { className:
|
|
3019
|
+
/* @__PURE__ */ jsx("div", { className: cn(
|
|
3020
|
+
"flex items-center justify-center w-10 h-10 rounded-[var(--ds-radius-full)] transition-colors",
|
|
3021
|
+
"bg-[var(--ds-bg-muted)] group-hover:bg-[var(--ds-accent-primary)]/10"
|
|
3022
|
+
), children: /* @__PURE__ */ jsx(Icon, { name: "plus", size: 20, className: "text-[var(--ds-text-muted)] group-hover:text-[var(--ds-accent-primary)] transition-colors" }) }),
|
|
3008
3023
|
/* @__PURE__ */ jsxs("div", { className: "text-center", children: [
|
|
3009
3024
|
/* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-[var(--ds-text-primary)]", children: "Drop files here or click to browse" }),
|
|
3010
3025
|
/* @__PURE__ */ jsxs("p", { className: "text-xs text-[var(--ds-text-muted)] mt-ds-1", children: [
|
|
@@ -3134,15 +3149,15 @@ function SliderRange({
|
|
|
3134
3149
|
"aria-invalid": error || void 0,
|
|
3135
3150
|
onPointerDown: handlePointerDown("low"),
|
|
3136
3151
|
className: cn(
|
|
3137
|
-
"absolute w-ds-4 h-ds-4 rounded-[var(--ds-radius-full)]",
|
|
3152
|
+
"absolute w-ds-4 h-ds-4 -translate-x-1/2 rounded-[var(--ds-radius-full)]",
|
|
3138
3153
|
"bg-[var(--ds-bg-surface)] border-2",
|
|
3139
3154
|
error ? "border-[var(--ds-status-error)]" : "border-[var(--ds-accent-primary)]",
|
|
3140
3155
|
"shadow-[var(--ds-shadow-sm)]",
|
|
3141
|
-
"transition-shadow",
|
|
3156
|
+
"transition-[shadow,transform] duration-200 ease-out",
|
|
3142
3157
|
"focus-visible:shadow-[var(--ds-shadow-focus)]",
|
|
3143
|
-
!disabled && "cursor-grab active:cursor-grabbing"
|
|
3158
|
+
!disabled && "cursor-grab active:cursor-grabbing hover:scale-125 active:scale-150"
|
|
3144
3159
|
),
|
|
3145
|
-
style: { left: `${pct(low)}
|
|
3160
|
+
style: { left: `${pct(low)}%` }
|
|
3146
3161
|
}
|
|
3147
3162
|
),
|
|
3148
3163
|
/* @__PURE__ */ jsx(
|
|
@@ -3156,15 +3171,15 @@ function SliderRange({
|
|
|
3156
3171
|
"aria-invalid": error || void 0,
|
|
3157
3172
|
onPointerDown: handlePointerDown("high"),
|
|
3158
3173
|
className: cn(
|
|
3159
|
-
"absolute w-ds-4 h-ds-4 rounded-[var(--ds-radius-full)]",
|
|
3174
|
+
"absolute w-ds-4 h-ds-4 -translate-x-1/2 rounded-[var(--ds-radius-full)]",
|
|
3160
3175
|
"bg-[var(--ds-bg-surface)] border-2",
|
|
3161
3176
|
error ? "border-[var(--ds-status-error)]" : "border-[var(--ds-accent-primary)]",
|
|
3162
3177
|
"shadow-[var(--ds-shadow-sm)]",
|
|
3163
|
-
"transition-shadow",
|
|
3178
|
+
"transition-[shadow,transform] duration-200 ease-out",
|
|
3164
3179
|
"focus-visible:shadow-[var(--ds-shadow-focus)]",
|
|
3165
|
-
!disabled && "cursor-grab active:cursor-grabbing"
|
|
3180
|
+
!disabled && "cursor-grab active:cursor-grabbing hover:scale-125 active:scale-150"
|
|
3166
3181
|
),
|
|
3167
|
-
style: { left: `${pct(high)}
|
|
3182
|
+
style: { left: `${pct(high)}%` }
|
|
3168
3183
|
}
|
|
3169
3184
|
)
|
|
3170
3185
|
]
|
|
@@ -3259,7 +3274,7 @@ function TimePicker({
|
|
|
3259
3274
|
"shadow-[var(--ds-input-shadow)]",
|
|
3260
3275
|
"transition-colors cursor-pointer",
|
|
3261
3276
|
"px-ds-3 py-ds-2",
|
|
3262
|
-
!error && !disabled && "hover:border-[var(--ds-input-border-hover)]",
|
|
3277
|
+
!error && !disabled && !open && "hover:border-[var(--ds-input-border-hover)]",
|
|
3263
3278
|
open && "border-[var(--ds-accent-primary)] ring-2 ring-[var(--ds-input-focus-ring)]",
|
|
3264
3279
|
disabled && "opacity-disabled cursor-not-allowed",
|
|
3265
3280
|
value ? "text-[var(--ds-text-primary)]" : "text-[var(--ds-text-muted)]"
|
|
@@ -3357,6 +3372,7 @@ function NumberInput({
|
|
|
3357
3372
|
}) {
|
|
3358
3373
|
const intervalRef = useRef(void 0);
|
|
3359
3374
|
const timeoutRef = useRef(void 0);
|
|
3375
|
+
const inputRef = useRef(null);
|
|
3360
3376
|
const clamp = useCallback(
|
|
3361
3377
|
(v) => Math.min(max2, Math.max(min2, v)),
|
|
3362
3378
|
[min2, max2]
|
|
@@ -3413,7 +3429,7 @@ function NumberInput({
|
|
|
3413
3429
|
"bg-[var(--ds-input-bg)]",
|
|
3414
3430
|
"transition-colors duration-[var(--ds-transition-speed)]",
|
|
3415
3431
|
!error && !disabled && "hover:border-[var(--ds-input-border-hover)]",
|
|
3416
|
-
"
|
|
3432
|
+
"focus-within:ring-2 focus-within:ring-[var(--ds-input-focus-ring)] focus-within:border-[var(--ds-input-focus-ring)] focus-within:hover:border-[var(--ds-input-focus-ring)]",
|
|
3417
3433
|
disabled && "opacity-disabled cursor-not-allowed",
|
|
3418
3434
|
className
|
|
3419
3435
|
),
|
|
@@ -3424,7 +3440,11 @@ function NumberInput({
|
|
|
3424
3440
|
type: "button",
|
|
3425
3441
|
tabIndex: -1,
|
|
3426
3442
|
disabled: disabled || atMin,
|
|
3427
|
-
onMouseDown: () =>
|
|
3443
|
+
onMouseDown: (e) => {
|
|
3444
|
+
e.preventDefault();
|
|
3445
|
+
inputRef.current?.focus();
|
|
3446
|
+
!disabled && !atMin && startRepeat(decrement);
|
|
3447
|
+
},
|
|
3428
3448
|
onMouseUp: stopRepeat,
|
|
3429
3449
|
onMouseLeave: stopRepeat,
|
|
3430
3450
|
className: cn(
|
|
@@ -3446,6 +3466,7 @@ function NumberInput({
|
|
|
3446
3466
|
/* @__PURE__ */ jsx(
|
|
3447
3467
|
"input",
|
|
3448
3468
|
{
|
|
3469
|
+
ref: inputRef,
|
|
3449
3470
|
id,
|
|
3450
3471
|
type: "text",
|
|
3451
3472
|
inputMode: "decimal",
|
|
@@ -3473,7 +3494,11 @@ function NumberInput({
|
|
|
3473
3494
|
type: "button",
|
|
3474
3495
|
tabIndex: -1,
|
|
3475
3496
|
disabled: disabled || atMax,
|
|
3476
|
-
onMouseDown: () =>
|
|
3497
|
+
onMouseDown: (e) => {
|
|
3498
|
+
e.preventDefault();
|
|
3499
|
+
inputRef.current?.focus();
|
|
3500
|
+
!disabled && !atMax && startRepeat(increment);
|
|
3501
|
+
},
|
|
3477
3502
|
onMouseUp: stopRepeat,
|
|
3478
3503
|
onMouseLeave: stopRepeat,
|
|
3479
3504
|
className: cn(
|
|
@@ -22881,7 +22906,7 @@ function createCustomEqual(options = {}) {
|
|
|
22881
22906
|
const equals2 = createCustomInternalComparator ? createCustomInternalComparator(comparator) : createInternalEqualityComparator(comparator);
|
|
22882
22907
|
return createIsEqual({ circular, comparator, createState, equals: equals2, strict });
|
|
22883
22908
|
}
|
|
22884
|
-
var
|
|
22909
|
+
var mergeRefs2 = (...refs) => {
|
|
22885
22910
|
return (node) => {
|
|
22886
22911
|
refs.forEach((ref) => {
|
|
22887
22912
|
if (typeof ref === "function") {
|
|
@@ -22997,7 +23022,7 @@ var PureEditorContent = class extends React6__default.Component {
|
|
|
22997
23022
|
render() {
|
|
22998
23023
|
const { editor, innerRef, ...rest } = this.props;
|
|
22999
23024
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
23000
|
-
/* @__PURE__ */ jsx("div", { ref:
|
|
23025
|
+
/* @__PURE__ */ jsx("div", { ref: mergeRefs2(innerRef, this.editorContentRef), ...rest }),
|
|
23001
23026
|
(editor == null ? void 0 : editor.contentComponent) && /* @__PURE__ */ jsx(Portals, { contentComponent: editor.contentComponent })
|
|
23002
23027
|
] });
|
|
23003
23028
|
}
|
|
@@ -82438,7 +82463,7 @@ function Table2({
|
|
|
82438
82463
|
className
|
|
82439
82464
|
),
|
|
82440
82465
|
children: /* @__PURE__ */ jsxs("table", { className: "w-full text-sm", children: [
|
|
82441
|
-
/* @__PURE__ */ jsx("thead", { className: cn(stickyHeader && "sticky top-0 z-10
|
|
82466
|
+
/* @__PURE__ */ jsx("thead", { className: cn("bg-[var(--ds-bg-muted)]", stickyHeader && "sticky top-0 z-10"), children: /* @__PURE__ */ jsxs("tr", { className: "border-b-[length:var(--ds-divider-width)] border-[var(--ds-border-subtle)]", children: [
|
|
82442
82467
|
selectable && /* @__PURE__ */ jsx("th", { className: cn("w-10", density === "compact" ? "px-ds-2 py-ds-2" : "px-ds-3 py-ds-3"), children: /* @__PURE__ */ jsx(
|
|
82443
82468
|
Checkbox,
|
|
82444
82469
|
{
|
|
@@ -84089,10 +84114,10 @@ function EmptyState({ icon, title, description, action, variant = "empty", class
|
|
|
84089
84114
|
);
|
|
84090
84115
|
}
|
|
84091
84116
|
var dotVariant = {
|
|
84092
|
-
default: "bg-[var(--ds-accent-primary)]",
|
|
84093
|
-
success: "bg-[var(--ds-status-success)]",
|
|
84094
|
-
warning: "bg-[var(--ds-status-warning)]",
|
|
84095
|
-
error: "bg-[var(--ds-status-error)]"
|
|
84117
|
+
default: "bg-[var(--ds-accent-primary)] shadow-[0_0_0_3px_var(--ds-accent-primary)]/20",
|
|
84118
|
+
success: "bg-[var(--ds-status-success)] shadow-[0_0_0_3px_var(--ds-status-success)]/20",
|
|
84119
|
+
warning: "bg-[var(--ds-status-warning)] shadow-[0_0_0_3px_var(--ds-status-warning)]/20",
|
|
84120
|
+
error: "bg-[var(--ds-status-error)] shadow-[0_0_0_3px_var(--ds-status-error)]/20"
|
|
84096
84121
|
};
|
|
84097
84122
|
function Timeline({ items, orientation = "vertical", className, ref }) {
|
|
84098
84123
|
if (orientation === "horizontal") {
|
|
@@ -84474,7 +84499,7 @@ function TreeNodeRow({
|
|
|
84474
84499
|
className: cn(
|
|
84475
84500
|
"flex items-center gap-ds-2 py-ds-1.5 px-ds-2 rounded-[var(--ds-radius-md)] cursor-pointer transition-colors",
|
|
84476
84501
|
"focus-visible:outline-none focus-visible:shadow-[var(--ds-shadow-focus)]",
|
|
84477
|
-
isSelected ? "bg-[var(--ds-
|
|
84502
|
+
isSelected ? "bg-[var(--ds-tab-active-bg)] text-[var(--ds-accent-primary)] font-medium border-l-2 border-[var(--ds-accent-primary)]" : "text-[var(--ds-text-primary)] hover:bg-[var(--ds-tab-hover-bg)] hover:text-[var(--ds-text-primary)]",
|
|
84478
84503
|
node.disabled && "opacity-disabled pointer-events-none"
|
|
84479
84504
|
),
|
|
84480
84505
|
style: { paddingLeft: `calc(var(--ds-space-5) * ${depth} + var(--ds-space-2))` },
|
|
@@ -84668,7 +84693,7 @@ function Carousel({
|
|
|
84668
84693
|
disabled: !canPrev,
|
|
84669
84694
|
"aria-label": "Previous slide",
|
|
84670
84695
|
className: cn(
|
|
84671
|
-
"absolute left-
|
|
84696
|
+
"absolute left-4 top-1/2 -translate-y-1/2 z-10",
|
|
84672
84697
|
"flex items-center justify-center w-8 h-8",
|
|
84673
84698
|
"rounded-[var(--ds-radius-full)]",
|
|
84674
84699
|
"bg-[var(--ds-bg-surface-elevated)] border-[length:var(--ds-border-width)] border-[var(--ds-border-subtle)]",
|
|
@@ -84687,7 +84712,7 @@ function Carousel({
|
|
|
84687
84712
|
disabled: !canNext,
|
|
84688
84713
|
"aria-label": "Next slide",
|
|
84689
84714
|
className: cn(
|
|
84690
|
-
"absolute right-
|
|
84715
|
+
"absolute right-4 top-1/2 -translate-y-1/2 z-10",
|
|
84691
84716
|
"flex items-center justify-center w-8 h-8",
|
|
84692
84717
|
"rounded-[var(--ds-radius-full)]",
|
|
84693
84718
|
"bg-[var(--ds-bg-surface-elevated)] border-[length:var(--ds-border-width)] border-[var(--ds-border-subtle)]",
|
|
@@ -87638,7 +87663,7 @@ function DataGrid({
|
|
|
87638
87663
|
"bg-[var(--ds-bg-surface)]"
|
|
87639
87664
|
),
|
|
87640
87665
|
children: /* @__PURE__ */ jsxs("table", { className: "w-full text-sm", children: [
|
|
87641
|
-
/* @__PURE__ */ jsx("thead", { children: table.getHeaderGroups().map((hg) => /* @__PURE__ */ jsx("tr", { className: "border-b-[length:var(--ds-divider-width)] border-[var(--ds-border-subtle)]", children: hg.headers.map((header) => {
|
|
87666
|
+
/* @__PURE__ */ jsx("thead", { className: "bg-[var(--ds-bg-muted)]", children: table.getHeaderGroups().map((hg) => /* @__PURE__ */ jsx("tr", { className: "border-b-[length:var(--ds-divider-width)] border-[var(--ds-border-subtle)]", children: hg.headers.map((header) => {
|
|
87642
87667
|
const canSort = header.column.getCanSort();
|
|
87643
87668
|
const sorted = header.column.getIsSorted();
|
|
87644
87669
|
return /* @__PURE__ */ jsx(
|
|
@@ -94149,26 +94174,29 @@ var Sidebar = forwardRef(function Sidebar2({
|
|
|
94149
94174
|
}
|
|
94150
94175
|
),
|
|
94151
94176
|
/* @__PURE__ */ jsx(ScrollArea, { className: "flex-1", children }),
|
|
94152
|
-
showCollapse &&
|
|
94153
|
-
|
|
94154
|
-
|
|
94155
|
-
|
|
94156
|
-
|
|
94157
|
-
|
|
94158
|
-
|
|
94159
|
-
|
|
94160
|
-
|
|
94161
|
-
|
|
94162
|
-
|
|
94163
|
-
|
|
94164
|
-
|
|
94165
|
-
|
|
94166
|
-
|
|
94167
|
-
|
|
94168
|
-
|
|
94169
|
-
|
|
94170
|
-
|
|
94171
|
-
|
|
94177
|
+
showCollapse && (() => {
|
|
94178
|
+
const collapseButton = /* @__PURE__ */ jsxs(
|
|
94179
|
+
"button",
|
|
94180
|
+
{
|
|
94181
|
+
onClick: () => handleCollapsedChange(!collapsed),
|
|
94182
|
+
"aria-expanded": !collapsed,
|
|
94183
|
+
"aria-label": collapsed ? "Expand sidebar" : "Collapse sidebar",
|
|
94184
|
+
className: cn(
|
|
94185
|
+
"flex items-center gap-ds-2 py-ds-2 mx-ds-2 text-sm rounded-[var(--ds-radius-md)]",
|
|
94186
|
+
"transition-colors cursor-pointer",
|
|
94187
|
+
"text-[var(--ds-sidebar-text-muted)] hover:bg-[var(--ds-sidebar-item-hover)] hover:text-[var(--ds-sidebar-text)]",
|
|
94188
|
+
"focus-visible:outline-none focus-visible:shadow-[var(--ds-shadow-focus)]",
|
|
94189
|
+
collapsed ? "justify-center px-0" : "px-ds-3"
|
|
94190
|
+
),
|
|
94191
|
+
style: { marginBottom: footer ? 0 : "var(--ds-space-3)" },
|
|
94192
|
+
children: [
|
|
94193
|
+
/* @__PURE__ */ jsx(Icon, { name: "chevron-right", size: 16, className: cn("transition-transform", !collapsed && "rotate-180") }),
|
|
94194
|
+
!collapsed && /* @__PURE__ */ jsx("span", { children: "Collapse" })
|
|
94195
|
+
]
|
|
94196
|
+
}
|
|
94197
|
+
);
|
|
94198
|
+
return collapsed ? /* @__PURE__ */ jsx(Tooltip, { content: "Expand sidebar", side: "right", delay: 100, container: portalEl ?? void 0, children: collapseButton }) : collapseButton;
|
|
94199
|
+
})(),
|
|
94172
94200
|
footer && /* @__PURE__ */ jsx(
|
|
94173
94201
|
"div",
|
|
94174
94202
|
{
|
|
@@ -94765,7 +94793,6 @@ function PageHeader({
|
|
|
94765
94793
|
onBack,
|
|
94766
94794
|
actions,
|
|
94767
94795
|
avatar,
|
|
94768
|
-
stats,
|
|
94769
94796
|
filters,
|
|
94770
94797
|
bannerImage,
|
|
94771
94798
|
as: Heading2 = "h1",
|
|
@@ -94847,7 +94874,6 @@ function PageHeader({
|
|
|
94847
94874
|
] }),
|
|
94848
94875
|
actions && /* @__PURE__ */ jsx("div", { className: "flex items-center gap-ds-2 shrink-0", children: actions })
|
|
94849
94876
|
] }),
|
|
94850
|
-
stats && /* @__PURE__ */ jsx("div", { className: "flex items-center gap-ds-6 mt-ds-3", children: stats }),
|
|
94851
94877
|
filters && /* @__PURE__ */ jsx("div", { className: "flex items-center gap-ds-3 mt-ds-4", children: filters })
|
|
94852
94878
|
] })
|
|
94853
94879
|
]
|