design-zystem 1.0.414 → 1.0.416

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.
@@ -63,6 +63,7 @@ interface BoxProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof b
63
63
  /** Left accent bar — status/score encoding. */
64
64
  accent?: ColorToken | 'none';
65
65
  width?: string;
66
+ hexBackground?: HexColor;
66
67
  }
67
68
  /**
68
69
  * Surface bordée/ombrée. Ne gère pas le flex — composer avec `Layout` pour
@@ -685,6 +686,8 @@ interface TableProps {
685
686
  /** Hauteur plancher — le tableau garde son gabarit même sans lignes, pour que
686
687
  * la page ne se replie pas entre un résultat vide et une liste chargée. */
687
688
  minHeight?: string;
689
+ /** Largeur plancher du tableau : en dessous, il défile horizontalement dans son cadre. */
690
+ minWidth?: string;
688
691
  className?: string;
689
692
  /** `rows` ne contient que la page courante (venue d'une RPC) — `Table` affiche le pied de pagination et te redonne la main via `onPageChange` pour refetch. */
690
693
  pagination?: TablePagination;
@@ -693,7 +696,7 @@ interface TableProps {
693
696
  /** Séparateur vertical entre toutes les colonnes (header, lignes, footer) — pas besoin de le poser cellule par cellule. */
694
697
  borderLeft?: boolean;
695
698
  }
696
- declare const Table: ({ width, header, rows, footer, loading, emptyState, maxHeight, minHeight, className, pagination, zebra, borderLeft, }: TableProps) => react.JSX.Element;
699
+ declare const Table: ({ width, header, rows, footer, loading, emptyState, maxHeight, minHeight, minWidth, className, pagination, zebra, borderLeft, }: TableProps) => react.JSX.Element;
697
700
 
698
701
  interface TableHeaderProps {
699
702
  children?: ReactNode;
@@ -63,6 +63,7 @@ interface BoxProps extends HTMLAttributes<HTMLDivElement>, VariantProps<typeof b
63
63
  /** Left accent bar — status/score encoding. */
64
64
  accent?: ColorToken | 'none';
65
65
  width?: string;
66
+ hexBackground?: HexColor;
66
67
  }
67
68
  /**
68
69
  * Surface bordée/ombrée. Ne gère pas le flex — composer avec `Layout` pour
@@ -685,6 +686,8 @@ interface TableProps {
685
686
  /** Hauteur plancher — le tableau garde son gabarit même sans lignes, pour que
686
687
  * la page ne se replie pas entre un résultat vide et une liste chargée. */
687
688
  minHeight?: string;
689
+ /** Largeur plancher du tableau : en dessous, il défile horizontalement dans son cadre. */
690
+ minWidth?: string;
688
691
  className?: string;
689
692
  /** `rows` ne contient que la page courante (venue d'une RPC) — `Table` affiche le pied de pagination et te redonne la main via `onPageChange` pour refetch. */
690
693
  pagination?: TablePagination;
@@ -693,7 +696,7 @@ interface TableProps {
693
696
  /** Séparateur vertical entre toutes les colonnes (header, lignes, footer) — pas besoin de le poser cellule par cellule. */
694
697
  borderLeft?: boolean;
695
698
  }
696
- declare const Table: ({ width, header, rows, footer, loading, emptyState, maxHeight, minHeight, className, pagination, zebra, borderLeft, }: TableProps) => react.JSX.Element;
699
+ declare const Table: ({ width, header, rows, footer, loading, emptyState, maxHeight, minHeight, minWidth, className, pagination, zebra, borderLeft, }: TableProps) => react.JSX.Element;
697
700
 
698
701
  interface TableHeaderProps {
699
702
  children?: ReactNode;
package/dist/ui/index.js CHANGED
@@ -532,6 +532,7 @@ var Box = (0, import_react2.forwardRef)(
532
532
  hasShadow,
533
533
  accent = "none",
534
534
  width,
535
+ hexBackground,
535
536
  className,
536
537
  style
537
538
  } = _b, props = __objRest(_b, [
@@ -540,6 +541,7 @@ var Box = (0, import_react2.forwardRef)(
540
541
  "hasShadow",
541
542
  "accent",
542
543
  "width",
544
+ "hexBackground",
543
545
  "className",
544
546
  "style"
545
547
  ]);
@@ -552,7 +554,7 @@ var Box = (0, import_react2.forwardRef)(
552
554
  ACCENT_CLASS[accent],
553
555
  className
554
556
  ),
555
- style: width ? __spreadValues({ width }, style) : style
557
+ style: __spreadValues(__spreadValues(__spreadValues({}, width && { width }), hexBackground && { backgroundColor: hexBackground }), style)
556
558
  }, props)
557
559
  );
558
560
  }
@@ -3371,6 +3373,7 @@ var Table = ({
3371
3373
  emptyState,
3372
3374
  maxHeight,
3373
3375
  minHeight,
3376
+ minWidth,
3374
3377
  className,
3375
3378
  pagination,
3376
3379
  zebra = false,
@@ -3403,6 +3406,7 @@ var Table = ({
3403
3406
  "w-full table-fixed border-separate border-spacing-0 caption-bottom text-[13px]",
3404
3407
  borderLeft && "[&_th:not(:first-child)]:border-l [&_td:not(:first-child)]:border-l [&_th:not(:first-child)]:border-grey-200 [&_td:not(:first-child)]:border-grey-200"
3405
3408
  ),
3409
+ style: { minWidth: minWidth || void 0 },
3406
3410
  children: [
3407
3411
  header,
3408
3412
  /* @__PURE__ */ (0, import_jsx_runtime35.jsx)(TableBody, { useEvenBackground: zebra, children: rows }),
@@ -3471,8 +3475,8 @@ var TableHeaderCell = ({
3471
3475
  {
3472
3476
  scope: "col",
3473
3477
  className: cn(
3474
- "px-2 py-2 text-center text-[13px] font-bold",
3475
- wrap ? "whitespace-normal break-words" : "overflow-hidden text-ellipsis whitespace-nowrap",
3478
+ "overflow-hidden px-2 py-2 text-center text-[13px] font-bold",
3479
+ wrap ? "whitespace-normal break-words" : "text-ellipsis whitespace-nowrap",
3476
3480
  borderLeft && "border-l border-grey-200",
3477
3481
  sticky && cn("z-[2]", SURFACE_CLASS[surface]),
3478
3482
  className
package/dist/ui/index.mjs CHANGED
@@ -329,6 +329,7 @@ var Box = forwardRef2(
329
329
  hasShadow,
330
330
  accent = "none",
331
331
  width,
332
+ hexBackground,
332
333
  className,
333
334
  style
334
335
  } = _b, props = __objRest(_b, [
@@ -337,6 +338,7 @@ var Box = forwardRef2(
337
338
  "hasShadow",
338
339
  "accent",
339
340
  "width",
341
+ "hexBackground",
340
342
  "className",
341
343
  "style"
342
344
  ]);
@@ -349,7 +351,7 @@ var Box = forwardRef2(
349
351
  ACCENT_CLASS[accent],
350
352
  className
351
353
  ),
352
- style: width ? __spreadValues({ width }, style) : style
354
+ style: __spreadValues(__spreadValues(__spreadValues({}, width && { width }), hexBackground && { backgroundColor: hexBackground }), style)
353
355
  }, props)
354
356
  );
355
357
  }
@@ -3184,6 +3186,7 @@ var Table = ({
3184
3186
  emptyState,
3185
3187
  maxHeight,
3186
3188
  minHeight,
3189
+ minWidth,
3187
3190
  className,
3188
3191
  pagination,
3189
3192
  zebra = false,
@@ -3216,6 +3219,7 @@ var Table = ({
3216
3219
  "w-full table-fixed border-separate border-spacing-0 caption-bottom text-[13px]",
3217
3220
  borderLeft && "[&_th:not(:first-child)]:border-l [&_td:not(:first-child)]:border-l [&_th:not(:first-child)]:border-grey-200 [&_td:not(:first-child)]:border-grey-200"
3218
3221
  ),
3222
+ style: { minWidth: minWidth || void 0 },
3219
3223
  children: [
3220
3224
  header,
3221
3225
  /* @__PURE__ */ jsx35(TableBody, { useEvenBackground: zebra, children: rows }),
@@ -3284,8 +3288,8 @@ var TableHeaderCell = ({
3284
3288
  {
3285
3289
  scope: "col",
3286
3290
  className: cn(
3287
- "px-2 py-2 text-center text-[13px] font-bold",
3288
- wrap ? "whitespace-normal break-words" : "overflow-hidden text-ellipsis whitespace-nowrap",
3291
+ "overflow-hidden px-2 py-2 text-center text-[13px] font-bold",
3292
+ wrap ? "whitespace-normal break-words" : "text-ellipsis whitespace-nowrap",
3289
3293
  borderLeft && "border-l border-grey-200",
3290
3294
  sticky && cn("z-[2]", SURFACE_CLASS[surface]),
3291
3295
  className
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "design-zystem",
3
- "version": "1.0.414",
3
+ "version": "1.0.416",
4
4
  "description": "A React design system of importable components",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",