@bizapps/design-system-testing 1.12.1 → 1.12.3
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/editor.cjs +1 -1
- package/dist/editor.cjs.map +1 -1
- package/dist/editor.js +1 -1
- package/dist/editor.js.map +1 -1
- package/dist/main.cjs +32 -12
- package/dist/main.cjs.map +1 -1
- package/dist/main.js +32 -12
- package/dist/main.js.map +1 -1
- package/package.json +1 -1
package/dist/main.cjs
CHANGED
|
@@ -2716,7 +2716,7 @@ function DialogTitle({ className, ...props }) {
|
|
|
2716
2716
|
radixUi.Dialog.Title,
|
|
2717
2717
|
{
|
|
2718
2718
|
"data-slot": "dialog-title",
|
|
2719
|
-
className: cn("font-heading text-lg leading-none font-bold", className),
|
|
2719
|
+
className: cn("font-heading text-lg leading-none font-bold wrap-anywhere", className),
|
|
2720
2720
|
...props
|
|
2721
2721
|
}
|
|
2722
2722
|
);
|
|
@@ -2730,7 +2730,7 @@ function DialogDescription({
|
|
|
2730
2730
|
{
|
|
2731
2731
|
"data-slot": "dialog-description",
|
|
2732
2732
|
className: cn(
|
|
2733
|
-
"text-muted-foreground *:[a]:hover:text-foreground text-sm *:[a]:underline *:[a]:underline-offset-3",
|
|
2733
|
+
"text-muted-foreground *:[a]:hover:text-foreground text-sm wrap-anywhere *:[a]:underline *:[a]:underline-offset-3",
|
|
2734
2734
|
className
|
|
2735
2735
|
),
|
|
2736
2736
|
...props
|
|
@@ -2897,7 +2897,7 @@ function AlertDialogTitle({
|
|
|
2897
2897
|
radixUi.AlertDialog.Title,
|
|
2898
2898
|
{
|
|
2899
2899
|
"data-slot": "alert-dialog-title",
|
|
2900
|
-
className: cn("font-heading text-lg font-bold", className),
|
|
2900
|
+
className: cn("font-heading text-lg font-bold wrap-anywhere", className),
|
|
2901
2901
|
...props
|
|
2902
2902
|
}
|
|
2903
2903
|
);
|
|
@@ -2911,7 +2911,7 @@ function AlertDialogDescription({
|
|
|
2911
2911
|
{
|
|
2912
2912
|
"data-slot": "alert-dialog-description",
|
|
2913
2913
|
className: cn(
|
|
2914
|
-
"text-muted-foreground *:[a]:hover:text-foreground text-xs text-balance md:text-pretty *:[a]:underline *:[a]:underline-offset-3",
|
|
2914
|
+
"text-muted-foreground *:[a]:hover:text-foreground text-xs text-balance wrap-anywhere md:text-pretty *:[a]:underline *:[a]:underline-offset-3",
|
|
2915
2915
|
className
|
|
2916
2916
|
),
|
|
2917
2917
|
...props
|
|
@@ -9224,6 +9224,13 @@ var DEFAULT_LABELS = {
|
|
|
9224
9224
|
var EASE = "cubic-bezier(.2,.8,.2,1)";
|
|
9225
9225
|
var MOTION_MS = 240;
|
|
9226
9226
|
var FADE_MS = MOTION_MS / 2;
|
|
9227
|
+
var RAIL_STAGGER_MS = 20;
|
|
9228
|
+
var ACCORDION_EASE = "cubic-bezier(.4,0,.2,1)";
|
|
9229
|
+
var ACCORDION_ITEM_FADE_MS = 260;
|
|
9230
|
+
var ACCORDION_OPEN_DELAY_MS = 120;
|
|
9231
|
+
var ACCORDION_OPEN_STAGGER_MS = 50;
|
|
9232
|
+
var ACCORDION_CLOSE_FADE_MS = 160;
|
|
9233
|
+
var ACCORDION_STAGGER_CAP = 8;
|
|
9227
9234
|
var MORPH_MS = 360;
|
|
9228
9235
|
var MORPH_EASE = "cubic-bezier(.65,0,.35,1)";
|
|
9229
9236
|
var BOUNCE_KEYFRAMES = [
|
|
@@ -9361,7 +9368,7 @@ var DEFAULT_WIDTH = 305;
|
|
|
9361
9368
|
var DEFAULT_COLLAPSED_WIDTH = 48;
|
|
9362
9369
|
var TILE_ICON_SIZE = 22;
|
|
9363
9370
|
var MIN_COLLAPSED_WIDTH = 40;
|
|
9364
|
-
var t = (prop, ms = 300, delay = 0) => `${prop} ${ms}ms ${
|
|
9371
|
+
var t = (prop, ms = 300, delay = 0, ease2 = EASE) => `${prop} ${ms}ms ${ease2} ${delay}ms`;
|
|
9365
9372
|
function transition2(reduced, ...parts) {
|
|
9366
9373
|
const kept = reduced ? parts.filter((part) => /^(opacity|visibility|background|color|box-shadow)/.test(part)) : parts;
|
|
9367
9374
|
return kept.join(", ") || "none";
|
|
@@ -10009,6 +10016,11 @@ function ModuleCard({
|
|
|
10009
10016
|
});
|
|
10010
10017
|
return () => animation2?.cancel();
|
|
10011
10018
|
}, [collapsed, hasActive, reduced]);
|
|
10019
|
+
const [toggle, setToggle] = react.useState({ collapsed, open, accordion: false });
|
|
10020
|
+
if (toggle.collapsed !== collapsed || toggle.open !== open) {
|
|
10021
|
+
setToggle({ collapsed, open, accordion: toggle.collapsed === collapsed });
|
|
10022
|
+
}
|
|
10023
|
+
const accordion = toggle.accordion && !reduced;
|
|
10012
10024
|
const items = filterItems(module.items, query);
|
|
10013
10025
|
const isEmpty = module.items.length === 0;
|
|
10014
10026
|
const emptyMessage = /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -10227,6 +10239,7 @@ function ModuleCard({
|
|
|
10227
10239
|
list,
|
|
10228
10240
|
visible: open,
|
|
10229
10241
|
staggerIndex: index,
|
|
10242
|
+
accordion,
|
|
10230
10243
|
onSelect: (navigates) => onSelect(item, navigates)
|
|
10231
10244
|
},
|
|
10232
10245
|
item.id
|
|
@@ -10351,20 +10364,27 @@ function ModuleCard({
|
|
|
10351
10364
|
}
|
|
10352
10365
|
) });
|
|
10353
10366
|
}
|
|
10354
|
-
function ItemRow({ item, list, visible, staggerIndex, onSelect }) {
|
|
10367
|
+
function ItemRow({ item, list, visible, staggerIndex, accordion, onSelect }) {
|
|
10355
10368
|
const { activeItemId, favoriteIds, reduced, labels, resolveIcon, renderLink } = list;
|
|
10356
10369
|
const active = item.id === activeItemId;
|
|
10357
10370
|
const favorite = favoriteIds?.includes(item.id) ?? false;
|
|
10358
10371
|
const tabIndex = visible ? 0 : -1;
|
|
10359
10372
|
const staggered = staggerIndex !== void 0;
|
|
10360
|
-
|
|
10373
|
+
let fade = t("opacity", FADE_MS, 0);
|
|
10374
|
+
if (staggered && accordion) {
|
|
10375
|
+
const step = Math.min(staggerIndex, ACCORDION_STAGGER_CAP);
|
|
10376
|
+
fade = visible ? t(
|
|
10377
|
+
"opacity",
|
|
10378
|
+
ACCORDION_ITEM_FADE_MS,
|
|
10379
|
+
ACCORDION_OPEN_DELAY_MS + step * ACCORDION_OPEN_STAGGER_MS,
|
|
10380
|
+
ACCORDION_EASE
|
|
10381
|
+
) : t("opacity", ACCORDION_CLOSE_FADE_MS, 0, ACCORDION_EASE);
|
|
10382
|
+
} else if (staggered && visible) {
|
|
10383
|
+
fade = t("opacity", FADE_MS, Math.min(staggerIndex * RAIL_STAGGER_MS, FADE_MS));
|
|
10384
|
+
}
|
|
10361
10385
|
const rowStyle = staggered ? {
|
|
10362
10386
|
opacity: visible ? 1 : 0,
|
|
10363
|
-
transition: transition2(
|
|
10364
|
-
reduced,
|
|
10365
|
-
t("opacity", FADE_MS, delay),
|
|
10366
|
-
"background-color 180ms ease-out"
|
|
10367
|
-
)
|
|
10387
|
+
transition: transition2(reduced, fade, "background-color 180ms ease-out")
|
|
10368
10388
|
} : { transition: "background-color 180ms ease-out" };
|
|
10369
10389
|
const className = cn(
|
|
10370
10390
|
"focus-visible:ring-primary flex min-h-[46px] min-w-0 flex-1 cursor-pointer items-start gap-3 rounded-[10px] border-0 bg-transparent py-[13px] pr-1 pl-3 text-left text-[13px] leading-5 transition-transform duration-180 ease-[cubic-bezier(.2,.8,.2,1)] outline-none hover:text-primary focus-visible:ring-2 focus-visible:ring-inset disabled:cursor-not-allowed disabled:opacity-50",
|