design-zystem 1.0.397 → 1.0.399

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.
@@ -732,8 +732,12 @@ interface TableRowProps {
732
732
  backgroundColor?: HexColor;
733
733
  /** Liseré vertical gauche, même usage que `backgroundColor`. */
734
734
  accentColor?: HexColor;
735
+ /** Index de la ligne dans une liste virtualisée (ex. @tanstack/react-virtual,
736
+ * dont `measureElement` lit cet attribut sur l'élément mesuré pour retrouver
737
+ * quelle ligne a changé de taille). Sans objet hors virtualisation. */
738
+ 'data-index'?: number;
735
739
  }
736
- declare const TableRow: ({ children, onClick, className, backgroundColor, accentColor, }: TableRowProps) => react.JSX.Element;
740
+ declare const TableRow: react.ForwardRefExoticComponent<TableRowProps & react.RefAttributes<HTMLTableRowElement>>;
737
741
 
738
742
  declare const SURFACE_CLASS: {
739
743
  readonly white: "bg-white";
@@ -732,8 +732,12 @@ interface TableRowProps {
732
732
  backgroundColor?: HexColor;
733
733
  /** Liseré vertical gauche, même usage que `backgroundColor`. */
734
734
  accentColor?: HexColor;
735
+ /** Index de la ligne dans une liste virtualisée (ex. @tanstack/react-virtual,
736
+ * dont `measureElement` lit cet attribut sur l'élément mesuré pour retrouver
737
+ * quelle ligne a changé de taille). Sans objet hors virtualisation. */
738
+ 'data-index'?: number;
735
739
  }
736
- declare const TableRow: ({ children, onClick, className, backgroundColor, accentColor, }: TableRowProps) => react.JSX.Element;
740
+ declare const TableRow: react.ForwardRefExoticComponent<TableRowProps & react.RefAttributes<HTMLTableRowElement>>;
737
741
 
738
742
  declare const SURFACE_CLASS: {
739
743
  readonly white: "bg-white";
package/dist/ui/index.js CHANGED
@@ -3450,30 +3450,37 @@ var TableHeaderCell = ({
3450
3450
  );
3451
3451
 
3452
3452
  // src/ui/components/ui/table/TableRow.tsx
3453
+ var import_react26 = require("react");
3453
3454
  var import_jsx_runtime39 = require("react/jsx-runtime");
3454
- var TableRow = ({
3455
- children,
3456
- onClick,
3457
- className,
3458
- backgroundColor,
3459
- accentColor
3460
- }) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3461
- "tr",
3462
- {
3455
+ var TableRow = (0, import_react26.forwardRef)(
3456
+ ({
3457
+ children,
3463
3458
  onClick,
3464
- className: cn(
3465
- "border-t border-grey-200 transition-colors hover:bg-black/[0.025]",
3466
- onClick && "cursor-pointer",
3467
- accentColor && "border-l-4",
3468
- className
3469
- ),
3470
- style: {
3471
- backgroundColor,
3472
- borderLeftColor: accentColor
3473
- },
3474
- children
3475
- }
3459
+ className,
3460
+ backgroundColor,
3461
+ accentColor,
3462
+ "data-index": dataIndex
3463
+ }, ref) => /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
3464
+ "tr",
3465
+ {
3466
+ ref,
3467
+ "data-index": dataIndex,
3468
+ onClick,
3469
+ className: cn(
3470
+ "border-t border-grey-200 transition-colors hover:bg-black/[0.025]",
3471
+ onClick && "cursor-pointer",
3472
+ accentColor && "border-l-4",
3473
+ className
3474
+ ),
3475
+ style: {
3476
+ backgroundColor,
3477
+ borderLeftColor: accentColor
3478
+ },
3479
+ children
3480
+ }
3481
+ )
3476
3482
  );
3483
+ TableRow.displayName = "TableRow";
3477
3484
 
3478
3485
  // src/ui/components/ui/table/TableCell.tsx
3479
3486
  var import_jsx_runtime40 = require("react/jsx-runtime");
@@ -3566,7 +3573,7 @@ var TableFooterCell = ({
3566
3573
  );
3567
3574
 
3568
3575
  // src/ui/components/ui/Avatar.tsx
3569
- var import_react26 = require("react");
3576
+ var import_react27 = require("react");
3570
3577
  var RadixAvatar = __toESM(require("@radix-ui/react-avatar"));
3571
3578
 
3572
3579
  // src/utils/string/capitalizeFirstLetter.ts
@@ -3690,8 +3697,8 @@ var formatNameWithInitial = (firstname, lastname) => {
3690
3697
 
3691
3698
  // src/ui/components/ui/Avatar.tsx
3692
3699
  var import_jsx_runtime44 = require("react/jsx-runtime");
3693
- var AvatarSizeContext = (0, import_react26.createContext)(40);
3694
- var useAvatarSize = () => (0, import_react26.useContext)(AvatarSizeContext);
3700
+ var AvatarSizeContext = (0, import_react27.createContext)(40);
3701
+ var useAvatarSize = () => (0, import_react27.useContext)(AvatarSizeContext);
3695
3702
  var BADGE_BG_CLASS = {
3696
3703
  "blue-700": "bg-blue-700",
3697
3704
  "blue-900": "bg-blue-900",
@@ -3722,7 +3729,7 @@ var BADGE_ICON_COLOR_CLASS = {
3722
3729
  "orange-600": "text-orange-600",
3723
3730
  "purple-700": "text-purple-700"
3724
3731
  };
3725
- var Avatar = (0, import_react26.forwardRef)(
3732
+ var Avatar = (0, import_react27.forwardRef)(
3726
3733
  (_a, ref) => {
3727
3734
  var _b = _a, {
3728
3735
  size = 40,
@@ -3775,7 +3782,7 @@ var Avatar = (0, import_react26.forwardRef)(
3775
3782
  }
3776
3783
  );
3777
3784
  Avatar.displayName = "Avatar";
3778
- var AvatarImage = (0, import_react26.forwardRef)((_a, ref) => {
3785
+ var AvatarImage = (0, import_react27.forwardRef)((_a, ref) => {
3779
3786
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3780
3787
  return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
3781
3788
  RadixAvatar.Image,
@@ -3801,7 +3808,7 @@ var FALLBACK_COLOR_CLASS = {
3801
3808
  "orange-600": "bg-orange-600 text-white",
3802
3809
  "purple-700": "bg-purple-700 text-white"
3803
3810
  };
3804
- var AvatarFallback = (0, import_react26.forwardRef)((_a, ref) => {
3811
+ var AvatarFallback = (0, import_react27.forwardRef)((_a, ref) => {
3805
3812
  var _b = _a, { color = "grey-600", className, style } = _b, props = __objRest(_b, ["color", "className", "style"]);
3806
3813
  const size = useAvatarSize();
3807
3814
  return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
@@ -3818,7 +3825,7 @@ var AvatarFallback = (0, import_react26.forwardRef)((_a, ref) => {
3818
3825
  );
3819
3826
  });
3820
3827
  AvatarFallback.displayName = "AvatarFallback";
3821
- var AvatarBadge = (0, import_react26.forwardRef)(
3828
+ var AvatarBadge = (0, import_react27.forwardRef)(
3822
3829
  (_a, ref) => {
3823
3830
  var _b = _a, { size, className, style } = _b, props = __objRest(_b, ["size", "className", "style"]);
3824
3831
  const avatarSize = useAvatarSize();
@@ -3849,14 +3856,14 @@ var AvatarGroup = (_a) => {
3849
3856
  "className",
3850
3857
  "children"
3851
3858
  ]);
3852
- const items = import_react26.Children.toArray(children).filter(
3853
- import_react26.isValidElement
3859
+ const items = import_react27.Children.toArray(children).filter(
3860
+ import_react27.isValidElement
3854
3861
  );
3855
3862
  const visible = max ? items.slice(0, max) : items;
3856
3863
  const overflow = max ? items.length - max : 0;
3857
3864
  return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(Layout, __spreadProps(__spreadValues({ className: cn("-space-x-2", className) }, props), { children: [
3858
3865
  visible.map(
3859
- (child, index) => (0, import_react26.cloneElement)(child, {
3866
+ (child, index) => (0, import_react27.cloneElement)(child, {
3860
3867
  key: index,
3861
3868
  size,
3862
3869
  className: cn("ring-2 ring-white", child.props.className)
@@ -4150,7 +4157,7 @@ var CollapsibleContent = (_a) => {
4150
4157
  };
4151
4158
 
4152
4159
  // src/ui/components/ui/Drawer.tsx
4153
- var import_react27 = require("react");
4160
+ var import_react28 = require("react");
4154
4161
  var import_vaul = require("vaul");
4155
4162
  var DialogPrimitive = __toESM(require("@radix-ui/react-dialog"));
4156
4163
 
@@ -4222,11 +4229,11 @@ var Drawer = ({
4222
4229
  overlayClassName
4223
4230
  }) => {
4224
4231
  const isVertical = direction === "left" || direction === "right";
4225
- const contentRef = (0, import_react27.useRef)(null);
4226
- const [panel, setPanel] = (0, import_react27.useState)(null);
4227
- const overlayRef = (0, import_react27.useRef)(null);
4232
+ const contentRef = (0, import_react28.useRef)(null);
4233
+ const [panel, setPanel] = (0, import_react28.useState)(null);
4234
+ const overlayRef = (0, import_react28.useRef)(null);
4228
4235
  useAllowPortalScroll(modal && open, contentRef, overlayRef);
4229
- (0, import_react27.useEffect)(() => {
4236
+ (0, import_react28.useEffect)(() => {
4230
4237
  if (!open || !panel) return;
4231
4238
  return registerOpenDrawer(panel, overlayRef.current);
4232
4239
  }, [open, panel]);
@@ -4241,7 +4248,7 @@ var Drawer = ({
4241
4248
  const overlay = target.closest("[data-vaul-overlay]");
4242
4249
  return Boolean(target.closest(KEEP_OPEN_SELECTOR)) || overlay !== null && isOverlayOfDrawerAbove(overlay, contentRef.current);
4243
4250
  };
4244
- (0, import_react27.useEffect)(() => {
4251
+ (0, import_react28.useEffect)(() => {
4245
4252
  if (modal || !open || typeof document === "undefined") return;
4246
4253
  const handlePointerDown = (event) => {
4247
4254
  var _a;
@@ -4255,7 +4262,7 @@ var Drawer = ({
4255
4262
  document.addEventListener("pointerdown", handlePointerDown);
4256
4263
  return () => document.removeEventListener("pointerdown", handlePointerDown);
4257
4264
  }, [modal, open, onClose]);
4258
- (0, import_react27.useEffect)(() => {
4265
+ (0, import_react28.useEffect)(() => {
4259
4266
  if (modal || !open) return;
4260
4267
  const frame = requestAnimationFrame(() => {
4261
4268
  document.body.style.pointerEvents = "auto";
@@ -4420,17 +4427,17 @@ var Popover = ({
4420
4427
  ] });
4421
4428
 
4422
4429
  // src/ui/components/ui/sidebar/Sidebar.tsx
4423
- var import_react29 = require("react");
4430
+ var import_react30 = require("react");
4424
4431
 
4425
4432
  // src/ui/components/ui/sidebar/SidebarContext.ts
4426
- var import_react28 = require("react");
4427
- var SidebarCollapsedContext = (0, import_react28.createContext)(false);
4433
+ var import_react29 = require("react");
4434
+ var SidebarCollapsedContext = (0, import_react29.createContext)(false);
4428
4435
  var SidebarCollapsedProvider = SidebarCollapsedContext.Provider;
4429
- var useSidebarCollapsed = () => (0, import_react28.useContext)(SidebarCollapsedContext);
4436
+ var useSidebarCollapsed = () => (0, import_react29.useContext)(SidebarCollapsedContext);
4430
4437
 
4431
4438
  // src/ui/components/ui/sidebar/Sidebar.tsx
4432
4439
  var import_jsx_runtime50 = require("react/jsx-runtime");
4433
- var Sidebar = (0, import_react29.forwardRef)(
4440
+ var Sidebar = (0, import_react30.forwardRef)(
4434
4441
  (_a, ref) => {
4435
4442
  var _b = _a, { collapsed = false, className, children } = _b, props = __objRest(_b, ["collapsed", "className", "children"]);
4436
4443
  return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(SidebarCollapsedProvider, { value: collapsed, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
@@ -4451,9 +4458,9 @@ var Sidebar = (0, import_react29.forwardRef)(
4451
4458
  Sidebar.displayName = "Sidebar";
4452
4459
 
4453
4460
  // src/ui/components/ui/sidebar/SidebarTrigger.tsx
4454
- var import_react30 = require("react");
4461
+ var import_react31 = require("react");
4455
4462
  var import_jsx_runtime51 = require("react/jsx-runtime");
4456
- var SidebarTrigger = (0, import_react30.forwardRef)((_a, ref) => {
4463
+ var SidebarTrigger = (0, import_react31.forwardRef)((_a, ref) => {
4457
4464
  var _b = _a, { collapsed, className } = _b, props = __objRest(_b, ["collapsed", "className"]);
4458
4465
  return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4459
4466
  "button",
@@ -4480,9 +4487,9 @@ var SidebarTrigger = (0, import_react30.forwardRef)((_a, ref) => {
4480
4487
  SidebarTrigger.displayName = "SidebarTrigger";
4481
4488
 
4482
4489
  // src/ui/components/ui/sidebar/SidebarHeader.tsx
4483
- var import_react31 = require("react");
4490
+ var import_react32 = require("react");
4484
4491
  var import_jsx_runtime52 = require("react/jsx-runtime");
4485
- var SidebarHeader = (0, import_react31.forwardRef)(
4492
+ var SidebarHeader = (0, import_react32.forwardRef)(
4486
4493
  (_a, ref) => {
4487
4494
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4488
4495
  return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
@@ -4497,9 +4504,9 @@ var SidebarHeader = (0, import_react31.forwardRef)(
4497
4504
  SidebarHeader.displayName = "SidebarHeader";
4498
4505
 
4499
4506
  // src/ui/components/ui/sidebar/SidebarContent.tsx
4500
- var import_react32 = require("react");
4507
+ var import_react33 = require("react");
4501
4508
  var import_jsx_runtime53 = require("react/jsx-runtime");
4502
- var SidebarContent = (0, import_react32.forwardRef)(
4509
+ var SidebarContent = (0, import_react33.forwardRef)(
4503
4510
  (_a, ref) => {
4504
4511
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4505
4512
  return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
@@ -4518,9 +4525,9 @@ var SidebarContent = (0, import_react32.forwardRef)(
4518
4525
  SidebarContent.displayName = "SidebarContent";
4519
4526
 
4520
4527
  // src/ui/components/ui/sidebar/SidebarGroup.tsx
4521
- var import_react33 = require("react");
4528
+ var import_react34 = require("react");
4522
4529
  var import_jsx_runtime54 = require("react/jsx-runtime");
4523
- var SidebarGroup = (0, import_react33.forwardRef)(
4530
+ var SidebarGroup = (0, import_react34.forwardRef)(
4524
4531
  (_a, ref) => {
4525
4532
  var _b = _a, { label, className, children } = _b, props = __objRest(_b, ["label", "className", "children"]);
4526
4533
  const collapsed = useSidebarCollapsed();
@@ -4541,9 +4548,9 @@ var SidebarGroup = (0, import_react33.forwardRef)(
4541
4548
  SidebarGroup.displayName = "SidebarGroup";
4542
4549
 
4543
4550
  // src/ui/components/ui/sidebar/SidebarMenuButton.tsx
4544
- var import_react34 = require("react");
4551
+ var import_react35 = require("react");
4545
4552
  var import_jsx_runtime55 = require("react/jsx-runtime");
4546
- var SidebarMenuButton = (0, import_react34.forwardRef)(
4553
+ var SidebarMenuButton = (0, import_react35.forwardRef)(
4547
4554
  (_a, ref) => {
4548
4555
  var _b = _a, {
4549
4556
  icon,
@@ -4623,9 +4630,9 @@ var SidebarMenuButton = (0, import_react34.forwardRef)(
4623
4630
  SidebarMenuButton.displayName = "SidebarMenuButton";
4624
4631
 
4625
4632
  // src/ui/components/ui/sidebar/SidebarMenuSub.tsx
4626
- var import_react35 = require("react");
4633
+ var import_react36 = require("react");
4627
4634
  var import_jsx_runtime56 = require("react/jsx-runtime");
4628
- var SidebarMenuSub = (0, import_react35.forwardRef)(
4635
+ var SidebarMenuSub = (0, import_react36.forwardRef)(
4629
4636
  (_a, ref) => {
4630
4637
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4631
4638
  return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
@@ -4643,22 +4650,22 @@ var SidebarMenuSub = (0, import_react35.forwardRef)(
4643
4650
  SidebarMenuSub.displayName = "SidebarMenuSub";
4644
4651
 
4645
4652
  // src/ui/components/ui/sidebar/SidebarMenuSubItem.tsx
4646
- var import_react36 = require("react");
4653
+ var import_react37 = require("react");
4647
4654
  var import_jsx_runtime57 = require("react/jsx-runtime");
4648
- var SidebarMenuSubItem = (0, import_react36.forwardRef)((_a, ref) => {
4655
+ var SidebarMenuSubItem = (0, import_react37.forwardRef)((_a, ref) => {
4649
4656
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4650
4657
  return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("li", __spreadValues({ ref, className: cn("relative", className) }, props));
4651
4658
  });
4652
4659
  SidebarMenuSubItem.displayName = "SidebarMenuSubItem";
4653
4660
 
4654
4661
  // src/ui/components/ui/sidebar/SidebarMenuSubButton.tsx
4655
- var import_react37 = require("react");
4662
+ var import_react38 = require("react");
4656
4663
  var import_jsx_runtime58 = require("react/jsx-runtime");
4657
4664
  var SIZE_CLASS = {
4658
4665
  default: "h-10",
4659
4666
  lg: "h-14"
4660
4667
  };
4661
- var SidebarMenuSubButton = (0, import_react37.forwardRef)((_a, ref) => {
4668
+ var SidebarMenuSubButton = (0, import_react38.forwardRef)((_a, ref) => {
4662
4669
  var _b = _a, { active, size = "default", className } = _b, props = __objRest(_b, ["active", "size", "className"]);
4663
4670
  return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4664
4671
  "button",
@@ -4679,9 +4686,9 @@ var SidebarMenuSubButton = (0, import_react37.forwardRef)((_a, ref) => {
4679
4686
  SidebarMenuSubButton.displayName = "SidebarMenuSubButton";
4680
4687
 
4681
4688
  // src/ui/components/ui/sidebar/SidebarFooter.tsx
4682
- var import_react38 = require("react");
4689
+ var import_react39 = require("react");
4683
4690
  var import_jsx_runtime59 = require("react/jsx-runtime");
4684
- var SidebarFooter = (0, import_react38.forwardRef)(
4691
+ var SidebarFooter = (0, import_react39.forwardRef)(
4685
4692
  (_a, ref) => {
4686
4693
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4687
4694
  return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
@@ -4719,9 +4726,9 @@ var SidebarSupportInfo = ({
4719
4726
  };
4720
4727
 
4721
4728
  // src/ui/components/ui/sidebar/SidebarMenuSearchInput.tsx
4722
- var import_react39 = require("react");
4729
+ var import_react40 = require("react");
4723
4730
  var import_jsx_runtime61 = require("react/jsx-runtime");
4724
- var SidebarMenuSearchInput = (0, import_react39.forwardRef)((_a, ref) => {
4731
+ var SidebarMenuSearchInput = (0, import_react40.forwardRef)((_a, ref) => {
4725
4732
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4726
4733
  return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(InputGroup, { children: [
4727
4734
  /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(InputGroupAddon, { align: "inline-start", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(FaIcon, { name: "magnifying-glass", size: 14, className: "text-white/50" }) }),
@@ -4740,7 +4747,7 @@ var SidebarMenuSearchInput = (0, import_react39.forwardRef)((_a, ref) => {
4740
4747
  SidebarMenuSearchInput.displayName = "SidebarMenuSearchInput";
4741
4748
 
4742
4749
  // src/ui/components/ui/sidebar/SidebarUserMenu.tsx
4743
- var import_react40 = require("react");
4750
+ var import_react41 = require("react");
4744
4751
  var RadixPopover5 = __toESM(require("@radix-ui/react-popover"));
4745
4752
  var import_jsx_runtime62 = require("react/jsx-runtime");
4746
4753
  var panelClassName = cn(
@@ -4757,7 +4764,7 @@ var SidebarUserMenu = ({
4757
4764
  className
4758
4765
  }) => {
4759
4766
  const collapsed = useSidebarCollapsed();
4760
- const [open, setOpen] = (0, import_react40.useState)(false);
4767
+ const [open, setOpen] = (0, import_react41.useState)(false);
4761
4768
  const runAndClose = (action) => {
4762
4769
  action();
4763
4770
  setOpen(false);
@@ -5075,7 +5082,7 @@ var toast = {
5075
5082
  };
5076
5083
 
5077
5084
  // src/ui/components/ui/PageContainer.tsx
5078
- var import_react41 = require("react");
5085
+ var import_react42 = require("react");
5079
5086
  var import_class_variance_authority13 = require("class-variance-authority");
5080
5087
  var import_jsx_runtime66 = require("react/jsx-runtime");
5081
5088
  var pageContainerVariants = (0, import_class_variance_authority13.cva)(
@@ -5092,7 +5099,7 @@ var pageContainerVariants = (0, import_class_variance_authority13.cva)(
5092
5099
  defaultVariants: { padding: "md" }
5093
5100
  }
5094
5101
  );
5095
- var PageContainer = (0, import_react41.forwardRef)(
5102
+ var PageContainer = (0, import_react42.forwardRef)(
5096
5103
  (_a, ref) => {
5097
5104
  var _b = _a, { padding, className } = _b, props = __objRest(_b, ["padding", "className"]);
5098
5105
  return /* @__PURE__ */ (0, import_jsx_runtime66.jsx)(
@@ -5107,7 +5114,7 @@ var PageContainer = (0, import_react41.forwardRef)(
5107
5114
  PageContainer.displayName = "PageContainer";
5108
5115
 
5109
5116
  // src/ui/components/ui/IconTabs.tsx
5110
- var import_react42 = require("react");
5117
+ var import_react43 = require("react");
5111
5118
  var import_jsx_runtime67 = require("react/jsx-runtime");
5112
5119
  var IconTabs = ({
5113
5120
  items,
@@ -5117,10 +5124,10 @@ var IconTabs = ({
5117
5124
  className
5118
5125
  }) => {
5119
5126
  var _a;
5120
- const listRef = (0, import_react42.useRef)(null);
5121
- const tabRefs = (0, import_react42.useRef)([]);
5122
- const [bar, setBar] = (0, import_react42.useState)({ left: 0, top: 0, width: 0, height: 0 });
5123
- const updateBar = (0, import_react42.useCallback)(() => {
5127
+ const listRef = (0, import_react43.useRef)(null);
5128
+ const tabRefs = (0, import_react43.useRef)([]);
5129
+ const [bar, setBar] = (0, import_react43.useState)({ left: 0, top: 0, width: 0, height: 0 });
5130
+ const updateBar = (0, import_react43.useCallback)(() => {
5124
5131
  const root = listRef.current;
5125
5132
  const activeEl = tabRefs.current[value];
5126
5133
  if (!root || !activeEl) return;
@@ -5133,7 +5140,7 @@ var IconTabs = ({
5133
5140
  height: box.height
5134
5141
  });
5135
5142
  }, [value]);
5136
- (0, import_react42.useEffect)(() => {
5143
+ (0, import_react43.useEffect)(() => {
5137
5144
  updateBar();
5138
5145
  const ro = new ResizeObserver(updateBar);
5139
5146
  if (listRef.current) ro.observe(listRef.current);
@@ -5315,7 +5322,7 @@ var Banner = ({
5315
5322
  };
5316
5323
 
5317
5324
  // src/ui/components/ui/FloatingButton.tsx
5318
- var import_react43 = require("react");
5325
+ var import_react44 = require("react");
5319
5326
 
5320
5327
  // src/ui/lib/floatingArc.ts
5321
5328
  var MAX_STEP = 65;
@@ -5469,20 +5476,20 @@ var FloatingButton = ({
5469
5476
  safeArea,
5470
5477
  onOffsetChange
5471
5478
  }) => {
5472
- const containerRef = (0, import_react43.useRef)(null);
5473
- const [placement, setPlacement] = (0, import_react43.useState)(() => ({
5479
+ const containerRef = (0, import_react44.useRef)(null);
5480
+ const [placement, setPlacement] = (0, import_react44.useState)(() => ({
5474
5481
  geometry: __spreadValues({ base: 90 }, arcLayout(actions.length, ARC_RADIUS, SUB_SIZE)),
5475
5482
  shift: { x: 0, y: 0 }
5476
5483
  }));
5477
- const [isDragging, setIsDragging] = (0, import_react43.useState)(false);
5478
- const [offset, setOffset] = (0, import_react43.useState)(() => readStoredOffset(persistKey));
5479
- const offsetRef = (0, import_react43.useRef)(offset);
5480
- const lastPointRef = (0, import_react43.useRef)({ x: 0, y: 0 });
5481
- const dragDistanceRef = (0, import_react43.useRef)(0);
5482
- (0, import_react43.useEffect)(() => {
5484
+ const [isDragging, setIsDragging] = (0, import_react44.useState)(false);
5485
+ const [offset, setOffset] = (0, import_react44.useState)(() => readStoredOffset(persistKey));
5486
+ const offsetRef = (0, import_react44.useRef)(offset);
5487
+ const lastPointRef = (0, import_react44.useRef)({ x: 0, y: 0 });
5488
+ const dragDistanceRef = (0, import_react44.useRef)(0);
5489
+ (0, import_react44.useEffect)(() => {
5483
5490
  onOffsetChange == null ? void 0 : onOffsetChange(offset);
5484
5491
  }, [offset, onOffsetChange]);
5485
- const clampOffset = (0, import_react43.useCallback)(
5492
+ const clampOffset = (0, import_react44.useCallback)(
5486
5493
  (next) => {
5487
5494
  var _a, _b, _c, _d;
5488
5495
  const el = containerRef.current;
@@ -5502,14 +5509,14 @@ var FloatingButton = ({
5502
5509
  },
5503
5510
  [safeArea == null ? void 0 : safeArea.left, safeArea == null ? void 0 : safeArea.top, safeArea == null ? void 0 : safeArea.right, safeArea == null ? void 0 : safeArea.bottom]
5504
5511
  );
5505
- (0, import_react43.useLayoutEffect)(() => {
5512
+ (0, import_react44.useLayoutEffect)(() => {
5506
5513
  const corrected = clampOffset(offsetRef.current);
5507
5514
  if (corrected.x === offsetRef.current.x && corrected.y === offsetRef.current.y)
5508
5515
  return;
5509
5516
  offsetRef.current = corrected;
5510
5517
  setOffset(corrected);
5511
5518
  }, [clampOffset]);
5512
- (0, import_react43.useEffect)(() => {
5519
+ (0, import_react44.useEffect)(() => {
5513
5520
  if (!draggable || !isDragging) return;
5514
5521
  const onPointerMove = (e) => {
5515
5522
  const dx = e.clientX - lastPointRef.current.x;
@@ -5545,7 +5552,7 @@ var FloatingButton = ({
5545
5552
  window.removeEventListener("pointercancel", endDrag);
5546
5553
  };
5547
5554
  }, [draggable, isDragging, persistKey, clampOffset]);
5548
- const resolvePlacement = (0, import_react43.useCallback)(() => {
5555
+ const resolvePlacement = (0, import_react44.useCallback)(() => {
5549
5556
  var _a, _b, _c, _d;
5550
5557
  const el = containerRef.current;
5551
5558
  if (!el || typeof window === "undefined") return;
@@ -5574,13 +5581,13 @@ var FloatingButton = ({
5574
5581
  safeArea == null ? void 0 : safeArea.right,
5575
5582
  safeArea == null ? void 0 : safeArea.bottom
5576
5583
  ]);
5577
- (0, import_react43.useLayoutEffect)(() => {
5584
+ (0, import_react44.useLayoutEffect)(() => {
5578
5585
  if (isOpen) resolvePlacement();
5579
5586
  }, [isOpen, offset, resolvePlacement]);
5580
- (0, import_react43.useLayoutEffect)(() => {
5587
+ (0, import_react44.useLayoutEffect)(() => {
5581
5588
  resolvePlacement();
5582
5589
  }, [resolvePlacement]);
5583
- (0, import_react43.useEffect)(() => {
5590
+ (0, import_react44.useEffect)(() => {
5584
5591
  if (typeof window === "undefined") return;
5585
5592
  const onResize = () => {
5586
5593
  resolvePlacement();
@@ -5676,7 +5683,7 @@ var FloatingButton = ({
5676
5683
  };
5677
5684
 
5678
5685
  // src/ui/components/ui/ActivityFeedPanel.tsx
5679
- var import_react44 = require("react");
5686
+ var import_react45 = require("react");
5680
5687
  var import_jsx_runtime70 = require("react/jsx-runtime");
5681
5688
  var PANEL_WIDTH = 500;
5682
5689
  var PANEL_MAX_HEIGHT = 750;
@@ -5711,15 +5718,15 @@ var ActivityFeedPanel = ({
5711
5718
  emptyMessage = "Rien de neuf pour l\u2019instant.",
5712
5719
  items
5713
5720
  }) => {
5714
- const panelRef = (0, import_react44.useRef)(null);
5715
- const [placement, setPlacement] = (0, import_react44.useState)(
5721
+ const panelRef = (0, import_react45.useRef)(null);
5722
+ const [placement, setPlacement] = (0, import_react45.useState)(
5716
5723
  () => typeof window === "undefined" ? {} : resolveFloatingPanelPlacement(
5717
5724
  offset,
5718
5725
  window.innerWidth,
5719
5726
  window.innerHeight
5720
5727
  )
5721
5728
  );
5722
- (0, import_react44.useEffect)(() => {
5729
+ (0, import_react45.useEffect)(() => {
5723
5730
  if (!open || typeof document === "undefined") return;
5724
5731
  const handlePointerDown = (event) => {
5725
5732
  var _a;
@@ -5730,7 +5737,7 @@ var ActivityFeedPanel = ({
5730
5737
  document.addEventListener("pointerdown", handlePointerDown);
5731
5738
  return () => document.removeEventListener("pointerdown", handlePointerDown);
5732
5739
  }, [open, onClose]);
5733
- (0, import_react44.useEffect)(() => {
5740
+ (0, import_react45.useEffect)(() => {
5734
5741
  if (!open || typeof window === "undefined") return;
5735
5742
  const recompute = () => setPlacement(
5736
5743
  resolveFloatingPanelPlacement(
@@ -6351,7 +6358,7 @@ var HistoryDrawer = (_a) => {
6351
6358
  };
6352
6359
 
6353
6360
  // src/ui/components/ui/history/HistoryButton.tsx
6354
- var import_react45 = require("react");
6361
+ var import_react46 = require("react");
6355
6362
  var import_jsx_runtime78 = require("react/jsx-runtime");
6356
6363
  var LABEL = "Historique";
6357
6364
  var SHORT_TOOLTIP = "Voir l\u2019historique des actions";
@@ -6367,7 +6374,7 @@ var HistoryButton = (_a) => {
6367
6374
  "tooltip",
6368
6375
  "onOpenChange"
6369
6376
  ]);
6370
- const [isOpen, setIsOpen] = (0, import_react45.useState)(false);
6377
+ const [isOpen, setIsOpen] = (0, import_react46.useState)(false);
6371
6378
  const changeOpen = (nextIsOpen) => {
6372
6379
  setIsOpen(nextIsOpen);
6373
6380
  onOpenChange == null ? void 0 : onOpenChange(nextIsOpen);
@@ -6667,7 +6674,7 @@ var Timeline = ({
6667
6674
  };
6668
6675
 
6669
6676
  // src/ui/components/ui/ColorPicker.tsx
6670
- var import_react46 = require("react");
6677
+ var import_react47 = require("react");
6671
6678
  var import_class_variance_authority15 = require("class-variance-authority");
6672
6679
  var import_jsx_runtime82 = require("react/jsx-runtime");
6673
6680
  var swatchVariants = (0, import_class_variance_authority15.cva)(
@@ -6696,7 +6703,7 @@ var inputVariants = (0, import_class_variance_authority15.cva)(
6696
6703
  defaultVariants: { size: "m" }
6697
6704
  }
6698
6705
  );
6699
- var ColorPicker = (0, import_react46.forwardRef)(
6706
+ var ColorPicker = (0, import_react47.forwardRef)(
6700
6707
  ({
6701
6708
  label,
6702
6709
  value,
@@ -6706,7 +6713,7 @@ var ColorPicker = (0, import_react46.forwardRef)(
6706
6713
  size,
6707
6714
  className
6708
6715
  }, ref) => {
6709
- const [internalColor, setInternalColor] = (0, import_react46.useState)(defaultValue);
6716
+ const [internalColor, setInternalColor] = (0, import_react47.useState)(defaultValue);
6710
6717
  const currentColor = value !== void 0 ? value : internalColor;
6711
6718
  const handleChange = (e) => {
6712
6719
  const next = e.target.value;
@@ -6770,7 +6777,7 @@ var ColorPicker = (0, import_react46.forwardRef)(
6770
6777
  ColorPicker.displayName = "ColorPicker";
6771
6778
 
6772
6779
  // src/ui/components/ui/FileUploadZone.tsx
6773
- var import_react47 = require("react");
6780
+ var import_react48 = require("react");
6774
6781
  var import_jsx_runtime83 = require("react/jsx-runtime");
6775
6782
  var ACCEPT_MAP = {
6776
6783
  png: "image/png",
@@ -6803,23 +6810,23 @@ var FileUploadZone = ({
6803
6810
  showFileName = false,
6804
6811
  className
6805
6812
  }) => {
6806
- const [isDragging, setIsDragging] = (0, import_react47.useState)(false);
6807
- const [internalPreviewUrl, setInternalPreviewUrl] = (0, import_react47.useState)(
6813
+ const [isDragging, setIsDragging] = (0, import_react48.useState)(false);
6814
+ const [internalPreviewUrl, setInternalPreviewUrl] = (0, import_react48.useState)(
6808
6815
  null
6809
6816
  );
6810
- const [fileType, setFileType] = (0, import_react47.useState)(null);
6811
- const [fileName, setFileName] = (0, import_react47.useState)(null);
6812
- const [inlineError, setInlineError] = (0, import_react47.useState)(null);
6813
- const inputRef = (0, import_react47.useRef)(null);
6817
+ const [fileType, setFileType] = (0, import_react48.useState)(null);
6818
+ const [fileName, setFileName] = (0, import_react48.useState)(null);
6819
+ const [inlineError, setInlineError] = (0, import_react48.useState)(null);
6820
+ const inputRef = (0, import_react48.useRef)(null);
6814
6821
  const resolvedAccept = acceptOnlyPdf ? PDF_ONLY : accept;
6815
6822
  const mimeTypes = getMimeTypes(resolvedAccept);
6816
6823
  const acceptString = mimeTypes.join(",");
6817
6824
  const previewUrl = multiple ? null : controlledPreviewUrl || (showPreview ? internalPreviewUrl : null);
6818
- const emitError = (0, import_react47.useCallback)(
6825
+ const emitError = (0, import_react48.useCallback)(
6819
6826
  (message) => onError ? onError(message) : setInlineError(message),
6820
6827
  [onError]
6821
6828
  );
6822
- const validateFile = (0, import_react47.useCallback)(
6829
+ const validateFile = (0, import_react48.useCallback)(
6823
6830
  (file) => {
6824
6831
  if (!mimeTypes.includes(file.type))
6825
6832
  return { ok: false, error: "Format de fichier non accept\xE9." };
@@ -6833,7 +6840,7 @@ var FileUploadZone = ({
6833
6840
  },
6834
6841
  [mimeTypes, maxSizeMB]
6835
6842
  );
6836
- const processFile = (0, import_react47.useCallback)(
6843
+ const processFile = (0, import_react48.useCallback)(
6837
6844
  (file) => {
6838
6845
  setInlineError(null);
6839
6846
  const result = validateFile(file);
@@ -6848,7 +6855,7 @@ var FileUploadZone = ({
6848
6855
  },
6849
6856
  [validateFile, onSave, showPreview, emitError]
6850
6857
  );
6851
- const processFiles = (0, import_react47.useCallback)(
6858
+ const processFiles = (0, import_react48.useCallback)(
6852
6859
  (files) => {
6853
6860
  setInlineError(null);
6854
6861
  for (const file of files) {
@@ -7007,7 +7014,7 @@ var FileUploadZone = ({
7007
7014
  };
7008
7015
 
7009
7016
  // src/ui/components/ui/FilePicker.tsx
7010
- var import_react48 = require("react");
7017
+ var import_react49 = require("react");
7011
7018
  var import_jsx_runtime84 = require("react/jsx-runtime");
7012
7019
  var FilePicker = ({
7013
7020
  label,
@@ -7021,7 +7028,7 @@ var FilePicker = ({
7021
7028
  disabled = false,
7022
7029
  className
7023
7030
  }) => {
7024
- const inputRef = (0, import_react48.useRef)(null);
7031
+ const inputRef = (0, import_react49.useRef)(null);
7025
7032
  return /* @__PURE__ */ (0, import_jsx_runtime84.jsxs)(import_jsx_runtime84.Fragment, { children: [
7026
7033
  /* @__PURE__ */ (0, import_jsx_runtime84.jsx)(
7027
7034
  "input",
@@ -7059,7 +7066,7 @@ var FilePicker = ({
7059
7066
  };
7060
7067
 
7061
7068
  // src/ui/components/ui/Item.tsx
7062
- var import_react49 = require("react");
7069
+ var import_react50 = require("react");
7063
7070
  var import_class_variance_authority16 = require("class-variance-authority");
7064
7071
  var import_jsx_runtime85 = require("react/jsx-runtime");
7065
7072
  var itemVariants = (0, import_class_variance_authority16.cva)(
@@ -7079,7 +7086,7 @@ var itemVariants = (0, import_class_variance_authority16.cva)(
7079
7086
  defaultVariants: { variant: "default", size: "default" }
7080
7087
  }
7081
7088
  );
7082
- var Item4 = (0, import_react49.forwardRef)(
7089
+ var Item4 = (0, import_react50.forwardRef)(
7083
7090
  (_a, ref) => {
7084
7091
  var _b = _a, { variant, size, className } = _b, props = __objRest(_b, ["variant", "size", "className"]);
7085
7092
  return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(
@@ -7238,7 +7245,7 @@ var Attachment = ({
7238
7245
  };
7239
7246
 
7240
7247
  // src/ui/components/ui/PdfPreview.tsx
7241
- var import_react50 = require("react");
7248
+ var import_react51 = require("react");
7242
7249
  var import_react_pdf = require("react-pdf");
7243
7250
  var import_jsx_runtime87 = require("react/jsx-runtime");
7244
7251
  import_react_pdf.pdfjs.GlobalWorkerOptions.workerSrc = `https://unpkg.com/pdfjs-dist@${import_react_pdf.pdfjs.version}/build/pdf.worker.min.mjs`;
@@ -7248,8 +7255,8 @@ var PdfPreview = ({
7248
7255
  maxHeight = "600px",
7249
7256
  className
7250
7257
  }) => {
7251
- const [hasError, setHasError] = (0, import_react50.useState)(false);
7252
- const [numPages, setNumPages] = (0, import_react50.useState)(0);
7258
+ const [hasError, setHasError] = (0, import_react51.useState)(false);
7259
+ const [numPages, setNumPages] = (0, import_react51.useState)(0);
7253
7260
  const height = Math.round(width * 1.3);
7254
7261
  const thumbnailSkeleton = /* @__PURE__ */ (0, import_jsx_runtime87.jsx)(Skeleton, { width, height });
7255
7262
  if (hasError) {
@@ -7305,7 +7312,7 @@ var PdfPreview = ({
7305
7312
  };
7306
7313
 
7307
7314
  // src/ui/components/ui/VideoPlayer.tsx
7308
- var import_react51 = require("react");
7315
+ var import_react52 = require("react");
7309
7316
  var import_jsx_runtime88 = require("react/jsx-runtime");
7310
7317
  var formatVideoDuration = (seconds) => {
7311
7318
  if (seconds === void 0 || !Number.isFinite(seconds) || seconds < 0)
@@ -7345,20 +7352,20 @@ var VideoPlayer = ({
7345
7352
  defaultVolume = DEFAULT_VOLUME,
7346
7353
  className
7347
7354
  }) => {
7348
- const [isInlinePlaying, setIsInlinePlaying] = (0, import_react51.useState)(false);
7349
- const [isExpanded, setIsExpanded] = (0, import_react51.useState)(false);
7350
- const [hasPosterError, setHasPosterError] = (0, import_react51.useState)(false);
7351
- const [hasFramePreviewError, setHasFramePreviewError] = (0, import_react51.useState)(false);
7352
- const inlineVideoRef = (0, import_react51.useRef)(null);
7353
- const expandedVideoRef = (0, import_react51.useRef)(null);
7354
- (0, import_react51.useEffect)(() => {
7355
+ const [isInlinePlaying, setIsInlinePlaying] = (0, import_react52.useState)(false);
7356
+ const [isExpanded, setIsExpanded] = (0, import_react52.useState)(false);
7357
+ const [hasPosterError, setHasPosterError] = (0, import_react52.useState)(false);
7358
+ const [hasFramePreviewError, setHasFramePreviewError] = (0, import_react52.useState)(false);
7359
+ const inlineVideoRef = (0, import_react52.useRef)(null);
7360
+ const expandedVideoRef = (0, import_react52.useRef)(null);
7361
+ (0, import_react52.useEffect)(() => {
7355
7362
  setHasPosterError(false);
7356
7363
  }, [poster]);
7357
- (0, import_react51.useEffect)(() => {
7364
+ (0, import_react52.useEffect)(() => {
7358
7365
  setHasFramePreviewError(false);
7359
7366
  }, [src]);
7360
7367
  const visiblePoster = hasPosterError ? void 0 : poster;
7361
- const attachExpandedVideo = (0, import_react51.useCallback)(
7368
+ const attachExpandedVideo = (0, import_react52.useCallback)(
7362
7369
  (video) => {
7363
7370
  expandedVideoRef.current = video;
7364
7371
  if (video) video.volume = clampVolume(defaultVolume);
@@ -7370,7 +7377,7 @@ var VideoPlayer = ({
7370
7377
  e.preventDefault();
7371
7378
  (_a = expandedVideoRef.current) == null ? void 0 : _a.focus({ preventScroll: true });
7372
7379
  };
7373
- const attachInlineVideo = (0, import_react51.useCallback)(
7380
+ const attachInlineVideo = (0, import_react52.useCallback)(
7374
7381
  (video) => {
7375
7382
  inlineVideoRef.current = video;
7376
7383
  if (video) video.volume = clampVolume(defaultVolume);
@@ -7635,7 +7642,7 @@ var ScrollArea = (_a) => {
7635
7642
  };
7636
7643
 
7637
7644
  // src/ui/components/ui/Message.tsx
7638
- var import_react52 = require("react");
7645
+ var import_react53 = require("react");
7639
7646
  var import_jsx_runtime90 = require("react/jsx-runtime");
7640
7647
  var BUBBLE_BACKGROUND = {
7641
7648
  own: { solid: "bg-blue-700", pale: "bg-blue-50" },
@@ -7647,7 +7654,7 @@ var BUBBLE_TAIL = {
7647
7654
  teammate: "rounded-br-none",
7648
7655
  other: "rounded-bl-none"
7649
7656
  };
7650
- var Message = (0, import_react52.forwardRef)(
7657
+ var Message = (0, import_react53.forwardRef)(
7651
7658
  (_a, ref) => {
7652
7659
  var _b = _a, {
7653
7660
  isOwn = false,
@@ -7789,7 +7796,7 @@ var Message = (0, import_react52.forwardRef)(
7789
7796
  Message.displayName = "Message";
7790
7797
 
7791
7798
  // src/ui/components/ui/MessageScroller.tsx
7792
- var import_react53 = require("react");
7799
+ var import_react54 = require("react");
7793
7800
  var import_jsx_runtime91 = require("react/jsx-runtime");
7794
7801
  var SEPARATOR_LINE = {
7795
7802
  neutral: "",
@@ -7841,9 +7848,9 @@ var MessageScroller = ({
7841
7848
  viewportRef,
7842
7849
  className
7843
7850
  }) => {
7844
- const fallbackRef = (0, import_react53.useRef)(null);
7851
+ const fallbackRef = (0, import_react54.useRef)(null);
7845
7852
  const scrollerRef = viewportRef != null ? viewportRef : fallbackRef;
7846
- (0, import_react53.useLayoutEffect)(() => {
7853
+ (0, import_react54.useLayoutEffect)(() => {
7847
7854
  if (!autoScroll) return;
7848
7855
  const viewport = scrollerRef.current;
7849
7856
  if (!viewport) return;
@@ -7897,7 +7904,7 @@ var MessageScroller = ({
7897
7904
  };
7898
7905
 
7899
7906
  // src/ui/components/ui/Stepper.tsx
7900
- var import_react54 = require("react");
7907
+ var import_react55 = require("react");
7901
7908
  var import_jsx_runtime92 = require("react/jsx-runtime");
7902
7909
  var Stepper = ({
7903
7910
  numberOfSteps,
@@ -7915,7 +7922,7 @@ var Stepper = ({
7915
7922
  children: Array.from({ length: numberOfSteps }, (_, i) => {
7916
7923
  const isActive = i === current;
7917
7924
  const isCompleted = i < current;
7918
- return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_react54.Fragment, { children: [
7925
+ return /* @__PURE__ */ (0, import_jsx_runtime92.jsxs)(import_react55.Fragment, { children: [
7919
7926
  /* @__PURE__ */ (0, import_jsx_runtime92.jsx)(
7920
7927
  "div",
7921
7928
  {
@@ -7935,7 +7942,7 @@ var Stepper = ({
7935
7942
  );
7936
7943
 
7937
7944
  // src/ui/components/ui/DatePicker.tsx
7938
- var import_react55 = require("react");
7945
+ var import_react56 = require("react");
7939
7946
  var import_react_day_picker = require("react-day-picker");
7940
7947
  var import_locale = require("react-day-picker/locale");
7941
7948
  var import_style2 = require("react-day-picker/style.css");
@@ -8004,8 +8011,8 @@ var DatePicker = ({
8004
8011
  className
8005
8012
  }) => {
8006
8013
  const isRange = mode === "range";
8007
- const [open, setOpen] = (0, import_react55.useState)(false);
8008
- const [activePreset, setActivePreset] = (0, import_react55.useState)(null);
8014
+ const [open, setOpen] = (0, import_react56.useState)(false);
8015
+ const [activePreset, setActivePreset] = (0, import_react56.useState)(null);
8009
8016
  const resolvedPresets = presets != null ? presets : isRange ? RANGE_PRESETS : SINGLE_PRESETS;
8010
8017
  const displayText = isRange ? startDate && endDate ? `${(0, import_date_fns.format)(startDate, "dd/MM/yyyy")} \u2014 ${(0, import_date_fns.format)(endDate, "dd/MM/yyyy")}` : placeholder != null ? placeholder : "S\xE9lectionner une p\xE9riode" : value ? (0, import_date_fns.format)(value, "dd/MM/yyyy") : placeholder != null ? placeholder : "S\xE9lectionner une date";
8011
8018
  const hasValue = isRange ? Boolean(startDate && endDate) : Boolean(value);
package/dist/ui/index.mjs CHANGED
@@ -3266,30 +3266,37 @@ var TableHeaderCell = ({
3266
3266
  );
3267
3267
 
3268
3268
  // src/ui/components/ui/table/TableRow.tsx
3269
+ import { forwardRef as forwardRef17 } from "react";
3269
3270
  import { jsx as jsx39 } from "react/jsx-runtime";
3270
- var TableRow = ({
3271
- children,
3272
- onClick,
3273
- className,
3274
- backgroundColor,
3275
- accentColor
3276
- }) => /* @__PURE__ */ jsx39(
3277
- "tr",
3278
- {
3271
+ var TableRow = forwardRef17(
3272
+ ({
3273
+ children,
3279
3274
  onClick,
3280
- className: cn(
3281
- "border-t border-grey-200 transition-colors hover:bg-black/[0.025]",
3282
- onClick && "cursor-pointer",
3283
- accentColor && "border-l-4",
3284
- className
3285
- ),
3286
- style: {
3287
- backgroundColor,
3288
- borderLeftColor: accentColor
3289
- },
3290
- children
3291
- }
3275
+ className,
3276
+ backgroundColor,
3277
+ accentColor,
3278
+ "data-index": dataIndex
3279
+ }, ref) => /* @__PURE__ */ jsx39(
3280
+ "tr",
3281
+ {
3282
+ ref,
3283
+ "data-index": dataIndex,
3284
+ onClick,
3285
+ className: cn(
3286
+ "border-t border-grey-200 transition-colors hover:bg-black/[0.025]",
3287
+ onClick && "cursor-pointer",
3288
+ accentColor && "border-l-4",
3289
+ className
3290
+ ),
3291
+ style: {
3292
+ backgroundColor,
3293
+ borderLeftColor: accentColor
3294
+ },
3295
+ children
3296
+ }
3297
+ )
3292
3298
  );
3299
+ TableRow.displayName = "TableRow";
3293
3300
 
3294
3301
  // src/ui/components/ui/table/TableCell.tsx
3295
3302
  import { jsx as jsx40 } from "react/jsx-runtime";
@@ -3385,7 +3392,7 @@ var TableFooterCell = ({
3385
3392
  import {
3386
3393
  createContext as createContext2,
3387
3394
  useContext as useContext2,
3388
- forwardRef as forwardRef17,
3395
+ forwardRef as forwardRef18,
3389
3396
  Children,
3390
3397
  cloneElement,
3391
3398
  isValidElement
@@ -3545,7 +3552,7 @@ var BADGE_ICON_COLOR_CLASS = {
3545
3552
  "orange-600": "text-orange-600",
3546
3553
  "purple-700": "text-purple-700"
3547
3554
  };
3548
- var Avatar = forwardRef17(
3555
+ var Avatar = forwardRef18(
3549
3556
  (_a, ref) => {
3550
3557
  var _b = _a, {
3551
3558
  size = 40,
@@ -3598,7 +3605,7 @@ var Avatar = forwardRef17(
3598
3605
  }
3599
3606
  );
3600
3607
  Avatar.displayName = "Avatar";
3601
- var AvatarImage = forwardRef17((_a, ref) => {
3608
+ var AvatarImage = forwardRef18((_a, ref) => {
3602
3609
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
3603
3610
  return /* @__PURE__ */ jsx44(
3604
3611
  RadixAvatar.Image,
@@ -3624,7 +3631,7 @@ var FALLBACK_COLOR_CLASS = {
3624
3631
  "orange-600": "bg-orange-600 text-white",
3625
3632
  "purple-700": "bg-purple-700 text-white"
3626
3633
  };
3627
- var AvatarFallback = forwardRef17((_a, ref) => {
3634
+ var AvatarFallback = forwardRef18((_a, ref) => {
3628
3635
  var _b = _a, { color = "grey-600", className, style } = _b, props = __objRest(_b, ["color", "className", "style"]);
3629
3636
  const size = useAvatarSize();
3630
3637
  return /* @__PURE__ */ jsx44(
@@ -3641,7 +3648,7 @@ var AvatarFallback = forwardRef17((_a, ref) => {
3641
3648
  );
3642
3649
  });
3643
3650
  AvatarFallback.displayName = "AvatarFallback";
3644
- var AvatarBadge = forwardRef17(
3651
+ var AvatarBadge = forwardRef18(
3645
3652
  (_a, ref) => {
3646
3653
  var _b = _a, { size, className, style } = _b, props = __objRest(_b, ["size", "className", "style"]);
3647
3654
  const avatarSize = useAvatarSize();
@@ -4243,7 +4250,7 @@ var Popover = ({
4243
4250
  ] });
4244
4251
 
4245
4252
  // src/ui/components/ui/sidebar/Sidebar.tsx
4246
- import { forwardRef as forwardRef18 } from "react";
4253
+ import { forwardRef as forwardRef19 } from "react";
4247
4254
 
4248
4255
  // src/ui/components/ui/sidebar/SidebarContext.ts
4249
4256
  import { createContext as createContext3, useContext as useContext3 } from "react";
@@ -4253,7 +4260,7 @@ var useSidebarCollapsed = () => useContext3(SidebarCollapsedContext);
4253
4260
 
4254
4261
  // src/ui/components/ui/sidebar/Sidebar.tsx
4255
4262
  import { jsx as jsx50 } from "react/jsx-runtime";
4256
- var Sidebar = forwardRef18(
4263
+ var Sidebar = forwardRef19(
4257
4264
  (_a, ref) => {
4258
4265
  var _b = _a, { collapsed = false, className, children } = _b, props = __objRest(_b, ["collapsed", "className", "children"]);
4259
4266
  return /* @__PURE__ */ jsx50(SidebarCollapsedProvider, { value: collapsed, children: /* @__PURE__ */ jsx50(
@@ -4274,9 +4281,9 @@ var Sidebar = forwardRef18(
4274
4281
  Sidebar.displayName = "Sidebar";
4275
4282
 
4276
4283
  // src/ui/components/ui/sidebar/SidebarTrigger.tsx
4277
- import { forwardRef as forwardRef19 } from "react";
4284
+ import { forwardRef as forwardRef20 } from "react";
4278
4285
  import { jsx as jsx51 } from "react/jsx-runtime";
4279
- var SidebarTrigger = forwardRef19((_a, ref) => {
4286
+ var SidebarTrigger = forwardRef20((_a, ref) => {
4280
4287
  var _b = _a, { collapsed, className } = _b, props = __objRest(_b, ["collapsed", "className"]);
4281
4288
  return /* @__PURE__ */ jsx51(
4282
4289
  "button",
@@ -4303,9 +4310,9 @@ var SidebarTrigger = forwardRef19((_a, ref) => {
4303
4310
  SidebarTrigger.displayName = "SidebarTrigger";
4304
4311
 
4305
4312
  // src/ui/components/ui/sidebar/SidebarHeader.tsx
4306
- import { forwardRef as forwardRef20 } from "react";
4313
+ import { forwardRef as forwardRef21 } from "react";
4307
4314
  import { jsx as jsx52 } from "react/jsx-runtime";
4308
- var SidebarHeader = forwardRef20(
4315
+ var SidebarHeader = forwardRef21(
4309
4316
  (_a, ref) => {
4310
4317
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4311
4318
  return /* @__PURE__ */ jsx52(
@@ -4320,9 +4327,9 @@ var SidebarHeader = forwardRef20(
4320
4327
  SidebarHeader.displayName = "SidebarHeader";
4321
4328
 
4322
4329
  // src/ui/components/ui/sidebar/SidebarContent.tsx
4323
- import { forwardRef as forwardRef21 } from "react";
4330
+ import { forwardRef as forwardRef22 } from "react";
4324
4331
  import { jsx as jsx53 } from "react/jsx-runtime";
4325
- var SidebarContent = forwardRef21(
4332
+ var SidebarContent = forwardRef22(
4326
4333
  (_a, ref) => {
4327
4334
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4328
4335
  return /* @__PURE__ */ jsx53(
@@ -4341,9 +4348,9 @@ var SidebarContent = forwardRef21(
4341
4348
  SidebarContent.displayName = "SidebarContent";
4342
4349
 
4343
4350
  // src/ui/components/ui/sidebar/SidebarGroup.tsx
4344
- import { forwardRef as forwardRef22 } from "react";
4351
+ import { forwardRef as forwardRef23 } from "react";
4345
4352
  import { jsx as jsx54, jsxs as jsxs26 } from "react/jsx-runtime";
4346
- var SidebarGroup = forwardRef22(
4353
+ var SidebarGroup = forwardRef23(
4347
4354
  (_a, ref) => {
4348
4355
  var _b = _a, { label, className, children } = _b, props = __objRest(_b, ["label", "className", "children"]);
4349
4356
  const collapsed = useSidebarCollapsed();
@@ -4364,9 +4371,9 @@ var SidebarGroup = forwardRef22(
4364
4371
  SidebarGroup.displayName = "SidebarGroup";
4365
4372
 
4366
4373
  // src/ui/components/ui/sidebar/SidebarMenuButton.tsx
4367
- import { forwardRef as forwardRef23 } from "react";
4374
+ import { forwardRef as forwardRef24 } from "react";
4368
4375
  import { jsx as jsx55, jsxs as jsxs27 } from "react/jsx-runtime";
4369
- var SidebarMenuButton = forwardRef23(
4376
+ var SidebarMenuButton = forwardRef24(
4370
4377
  (_a, ref) => {
4371
4378
  var _b = _a, {
4372
4379
  icon,
@@ -4446,9 +4453,9 @@ var SidebarMenuButton = forwardRef23(
4446
4453
  SidebarMenuButton.displayName = "SidebarMenuButton";
4447
4454
 
4448
4455
  // src/ui/components/ui/sidebar/SidebarMenuSub.tsx
4449
- import { forwardRef as forwardRef24 } from "react";
4456
+ import { forwardRef as forwardRef25 } from "react";
4450
4457
  import { jsx as jsx56 } from "react/jsx-runtime";
4451
- var SidebarMenuSub = forwardRef24(
4458
+ var SidebarMenuSub = forwardRef25(
4452
4459
  (_a, ref) => {
4453
4460
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4454
4461
  return /* @__PURE__ */ jsx56(
@@ -4466,22 +4473,22 @@ var SidebarMenuSub = forwardRef24(
4466
4473
  SidebarMenuSub.displayName = "SidebarMenuSub";
4467
4474
 
4468
4475
  // src/ui/components/ui/sidebar/SidebarMenuSubItem.tsx
4469
- import { forwardRef as forwardRef25 } from "react";
4476
+ import { forwardRef as forwardRef26 } from "react";
4470
4477
  import { jsx as jsx57 } from "react/jsx-runtime";
4471
- var SidebarMenuSubItem = forwardRef25((_a, ref) => {
4478
+ var SidebarMenuSubItem = forwardRef26((_a, ref) => {
4472
4479
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4473
4480
  return /* @__PURE__ */ jsx57("li", __spreadValues({ ref, className: cn("relative", className) }, props));
4474
4481
  });
4475
4482
  SidebarMenuSubItem.displayName = "SidebarMenuSubItem";
4476
4483
 
4477
4484
  // src/ui/components/ui/sidebar/SidebarMenuSubButton.tsx
4478
- import { forwardRef as forwardRef26 } from "react";
4485
+ import { forwardRef as forwardRef27 } from "react";
4479
4486
  import { jsx as jsx58 } from "react/jsx-runtime";
4480
4487
  var SIZE_CLASS = {
4481
4488
  default: "h-10",
4482
4489
  lg: "h-14"
4483
4490
  };
4484
- var SidebarMenuSubButton = forwardRef26((_a, ref) => {
4491
+ var SidebarMenuSubButton = forwardRef27((_a, ref) => {
4485
4492
  var _b = _a, { active, size = "default", className } = _b, props = __objRest(_b, ["active", "size", "className"]);
4486
4493
  return /* @__PURE__ */ jsx58(
4487
4494
  "button",
@@ -4502,9 +4509,9 @@ var SidebarMenuSubButton = forwardRef26((_a, ref) => {
4502
4509
  SidebarMenuSubButton.displayName = "SidebarMenuSubButton";
4503
4510
 
4504
4511
  // src/ui/components/ui/sidebar/SidebarFooter.tsx
4505
- import { forwardRef as forwardRef27 } from "react";
4512
+ import { forwardRef as forwardRef28 } from "react";
4506
4513
  import { jsx as jsx59 } from "react/jsx-runtime";
4507
- var SidebarFooter = forwardRef27(
4514
+ var SidebarFooter = forwardRef28(
4508
4515
  (_a, ref) => {
4509
4516
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4510
4517
  return /* @__PURE__ */ jsx59(
@@ -4542,9 +4549,9 @@ var SidebarSupportInfo = ({
4542
4549
  };
4543
4550
 
4544
4551
  // src/ui/components/ui/sidebar/SidebarMenuSearchInput.tsx
4545
- import { forwardRef as forwardRef28 } from "react";
4552
+ import { forwardRef as forwardRef29 } from "react";
4546
4553
  import { jsx as jsx61, jsxs as jsxs29 } from "react/jsx-runtime";
4547
- var SidebarMenuSearchInput = forwardRef28((_a, ref) => {
4554
+ var SidebarMenuSearchInput = forwardRef29((_a, ref) => {
4548
4555
  var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
4549
4556
  return /* @__PURE__ */ jsxs29(InputGroup, { children: [
4550
4557
  /* @__PURE__ */ jsx61(InputGroupAddon, { align: "inline-start", children: /* @__PURE__ */ jsx61(FaIcon, { name: "magnifying-glass", size: 14, className: "text-white/50" }) }),
@@ -4898,7 +4905,7 @@ var toast = {
4898
4905
  };
4899
4906
 
4900
4907
  // src/ui/components/ui/PageContainer.tsx
4901
- import { forwardRef as forwardRef29 } from "react";
4908
+ import { forwardRef as forwardRef30 } from "react";
4902
4909
  import { cva as cva13 } from "class-variance-authority";
4903
4910
  import { jsx as jsx66 } from "react/jsx-runtime";
4904
4911
  var pageContainerVariants = cva13(
@@ -4915,7 +4922,7 @@ var pageContainerVariants = cva13(
4915
4922
  defaultVariants: { padding: "md" }
4916
4923
  }
4917
4924
  );
4918
- var PageContainer = forwardRef29(
4925
+ var PageContainer = forwardRef30(
4919
4926
  (_a, ref) => {
4920
4927
  var _b = _a, { padding, className } = _b, props = __objRest(_b, ["padding", "className"]);
4921
4928
  return /* @__PURE__ */ jsx66(
@@ -6496,7 +6503,7 @@ var Timeline = ({
6496
6503
  };
6497
6504
 
6498
6505
  // src/ui/components/ui/ColorPicker.tsx
6499
- import { forwardRef as forwardRef30, useState as useState13 } from "react";
6506
+ import { forwardRef as forwardRef31, useState as useState13 } from "react";
6500
6507
  import { cva as cva15 } from "class-variance-authority";
6501
6508
  import { jsx as jsx82, jsxs as jsxs46 } from "react/jsx-runtime";
6502
6509
  var swatchVariants = cva15(
@@ -6525,7 +6532,7 @@ var inputVariants = cva15(
6525
6532
  defaultVariants: { size: "m" }
6526
6533
  }
6527
6534
  );
6528
- var ColorPicker = forwardRef30(
6535
+ var ColorPicker = forwardRef31(
6529
6536
  ({
6530
6537
  label,
6531
6538
  value,
@@ -6888,7 +6895,7 @@ var FilePicker = ({
6888
6895
  };
6889
6896
 
6890
6897
  // src/ui/components/ui/Item.tsx
6891
- import { forwardRef as forwardRef31 } from "react";
6898
+ import { forwardRef as forwardRef32 } from "react";
6892
6899
  import { cva as cva16 } from "class-variance-authority";
6893
6900
  import { jsx as jsx85 } from "react/jsx-runtime";
6894
6901
  var itemVariants = cva16(
@@ -6908,7 +6915,7 @@ var itemVariants = cva16(
6908
6915
  defaultVariants: { variant: "default", size: "default" }
6909
6916
  }
6910
6917
  );
6911
- var Item4 = forwardRef31(
6918
+ var Item4 = forwardRef32(
6912
6919
  (_a, ref) => {
6913
6920
  var _b = _a, { variant, size, className } = _b, props = __objRest(_b, ["variant", "size", "className"]);
6914
6921
  return /* @__PURE__ */ jsx85(
@@ -7469,7 +7476,7 @@ var ScrollArea = (_a) => {
7469
7476
  };
7470
7477
 
7471
7478
  // src/ui/components/ui/Message.tsx
7472
- import { forwardRef as forwardRef32 } from "react";
7479
+ import { forwardRef as forwardRef33 } from "react";
7473
7480
  import { jsx as jsx90, jsxs as jsxs53 } from "react/jsx-runtime";
7474
7481
  var BUBBLE_BACKGROUND = {
7475
7482
  own: { solid: "bg-blue-700", pale: "bg-blue-50" },
@@ -7481,7 +7488,7 @@ var BUBBLE_TAIL = {
7481
7488
  teammate: "rounded-br-none",
7482
7489
  other: "rounded-bl-none"
7483
7490
  };
7484
- var Message = forwardRef32(
7491
+ var Message = forwardRef33(
7485
7492
  (_a, ref) => {
7486
7493
  var _b = _a, {
7487
7494
  isOwn = false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "design-zystem",
3
- "version": "1.0.397",
3
+ "version": "1.0.399",
4
4
  "description": "A React design system of importable components",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",