design-zystem 1.0.247 → 1.0.248

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.mts CHANGED
@@ -189,9 +189,11 @@ interface DrawerProps {
189
189
  isLoading?: boolean;
190
190
  leftVariant?: string;
191
191
  variant?: string;
192
+ leftOutline?: boolean;
193
+ rightOutline?: boolean;
192
194
  footer?: ReactNode;
193
195
  }
194
- declare const Drawer: ({ showDrawer, closeDrawer, title, width, children, leftButtonLabel, leftButtonAction, leftButtonDisabled, rightButtonLabel, rightButtonAction, rightButtonDisabled, isLoading, leftVariant, variant, footer, }: DrawerProps) => react_jsx_runtime.JSX.Element | null;
196
+ declare const Drawer: ({ showDrawer, closeDrawer, title, width, children, leftButtonLabel, leftButtonAction, leftButtonDisabled, rightButtonLabel, rightButtonAction, rightButtonDisabled, isLoading, leftVariant, variant, leftOutline, rightOutline, footer, }: DrawerProps) => react_jsx_runtime.JSX.Element | null;
195
197
 
196
198
  type SizeKey = 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';
197
199
  interface TagBubbleProps extends HTMLAttributes<HTMLDivElement> {
@@ -266,6 +268,7 @@ interface TextProps extends Omit<HTMLAttributes<HTMLElement>, 'color'> {
266
268
  p?: boolean;
267
269
  max?: number | string;
268
270
  wrap?: string;
271
+ lineClamp?: number;
269
272
  onClick?: (e: MouseEvent) => void;
270
273
  style?: CSSProperties;
271
274
  className?: string;
@@ -597,6 +600,7 @@ interface TableProps extends HTMLAttributes<HTMLDivElement> {
597
600
  className?: string;
598
601
  fullWidth?: boolean;
599
602
  borderRadius?: string;
603
+ hasShadow?: boolean;
600
604
  }
601
605
  declare const Table: react.ForwardRefExoticComponent<TableProps & react.RefAttributes<HTMLDivElement>>;
602
606
 
@@ -902,6 +906,79 @@ interface EmptyStateProps {
902
906
  }
903
907
  declare const EmptyState: ({ icon, title, description, actionLabel, onAction, }: EmptyStateProps) => react_jsx_runtime.JSX.Element;
904
908
 
909
+ interface ProgressBarProps {
910
+ /** Filled portion, 0–100. Values outside the range are clamped. */
911
+ value: number;
912
+ /** Fill color (DZ color token). */
913
+ color?: string;
914
+ /** Track (unfilled) color (DZ color token). */
915
+ trackColor?: string;
916
+ /** Bar thickness in px. */
917
+ height?: number;
918
+ /** Show the "xx %" label on the right. */
919
+ showLabel?: boolean;
920
+ }
921
+ /**
922
+ * Horizontal coverage/progress bar. Track + fill, optional right-aligned label.
923
+ */
924
+ declare const ProgressBar: ({ value, color, trackColor, height, showLabel, }: ProgressBarProps) => react_jsx_runtime.JSX.Element;
925
+
926
+ interface TimelineItem {
927
+ /** Stable key for the row. */
928
+ id: string | number;
929
+ /** Main line (event label, mission name…). */
930
+ title: string;
931
+ /** Secondary line (date, author…). */
932
+ subtitle?: string;
933
+ /** Optional free text under the title. */
934
+ description?: string;
935
+ /** Dot color (DZ color token). */
936
+ color?: string;
937
+ /** Emphasize this point (e.g. the coverage point in a simulation). */
938
+ highlighted?: boolean;
939
+ }
940
+ interface TimelineProps {
941
+ items: TimelineItem[];
942
+ /** Color of the connecting line (DZ color token). */
943
+ lineColor?: string;
944
+ /** Text shown when there is no event. */
945
+ emptyLabel?: string;
946
+ }
947
+ /**
948
+ * Vertical timeline. Used for event logs (feedback history) and chronological
949
+ * lists (recovery simulation). Each point has a colored dot + title/subtitle.
950
+ */
951
+ declare const Timeline: ({ items, lineColor, emptyLabel, }: TimelineProps) => react_jsx_runtime.JSX.Element;
952
+
953
+ interface BorderedRowProps {
954
+ /** Accent color (DZ color token) — used to encode a score/status/level. */
955
+ borderColor?: string;
956
+ /** Accent thickness in px. */
957
+ borderWidth?: number;
958
+ /** Background color (DZ color token). */
959
+ background?: string;
960
+ /** Inner padding. */
961
+ padding?: string;
962
+ /** Corner radius — pass "0" for flush table rows, default rounded card. */
963
+ borderRadius?: string;
964
+ /**
965
+ * Accent style:
966
+ * - 'edge' (default): full-height colored left border (flush rows / score bars).
967
+ * - 'bar': short rounded inset accent bar, centered (white card look).
968
+ */
969
+ accent?: 'edge' | 'bar';
970
+ /** Subtle 1px full border around the card (card look). */
971
+ bordered?: boolean;
972
+ children: ReactNode;
973
+ onClick?: () => void;
974
+ }
975
+ /**
976
+ * Row/card with a colored accent, used to encode a status (recovery score,
977
+ * feedback level…). Flush table rows: accent="edge" + borderRadius="0".
978
+ * White cards: accent="bar" + bordered + background.
979
+ */
980
+ declare const BorderedRow: ({ borderColor, borderWidth, background, padding, borderRadius, accent, bordered, children, onClick, }: BorderedRowProps) => react_jsx_runtime.JSX.Element;
981
+
905
982
  /**
906
983
  * formatDate(date, type?, language?)
907
984
  * - language : fr/en/es/... (locale inferred), default "en"
@@ -948,4 +1025,4 @@ interface OptimizeImageOptions {
948
1025
  }
949
1026
  declare const optimizeImage: (file: File | null | undefined, desiredBaseName: string, opts?: OptimizeImageOptions) => Promise<OptimizeImageResult>;
950
1027
 
951
- export { Accordion, type AccordionItem, Avatar, Box, Bubble, Bulk, Button, CardSkeleton, Checkbox, Col, Collapse, ColorPicker, DatePicker, Divider, Drawer, EmptyState, FileUploadZone, Grid, Icon, IconTabs, Image, Input, Link, List, ListItem, MetricCard, Modal, ModalConfirmation, MultiSelect, NewModal, Options, PageContainer, Pagination, Popover, Radio, Row, Select, type SelectOption, type SelectProps, SkeletonRow, SliderInput, type SortOrder, Spinner, Stepper, Switch, Table, TableBody, TableCell, TableFooter, TableFooterCell, TableFooterRow, TableHeader, TableHeaderCell, type TableHeaderCellProps, TableHeaderRow, TableRow, Tabs, TagBubble, Text, Tooltip, colors, formatDate, formatDistance, formatDuration, optimizeImage, truncateFileName, truncateText };
1028
+ export { Accordion, type AccordionItem, Avatar, BorderedRow, Box, Bubble, Bulk, Button, CardSkeleton, Checkbox, Col, Collapse, ColorPicker, DatePicker, Divider, Drawer, EmptyState, FileUploadZone, Grid, Icon, IconTabs, Image, Input, Link, List, ListItem, MetricCard, Modal, ModalConfirmation, MultiSelect, NewModal, Options, PageContainer, Pagination, Popover, ProgressBar, Radio, Row, Select, type SelectOption, type SelectProps, SkeletonRow, SliderInput, type SortOrder, Spinner, Stepper, Switch, Table, TableBody, TableCell, TableFooter, TableFooterCell, TableFooterRow, TableHeader, TableHeaderCell, type TableHeaderCellProps, TableHeaderRow, TableRow, Tabs, TagBubble, Text, Timeline, type TimelineItem, Tooltip, colors, formatDate, formatDistance, formatDuration, optimizeImage, truncateFileName, truncateText };
package/dist/index.d.ts CHANGED
@@ -189,9 +189,11 @@ interface DrawerProps {
189
189
  isLoading?: boolean;
190
190
  leftVariant?: string;
191
191
  variant?: string;
192
+ leftOutline?: boolean;
193
+ rightOutline?: boolean;
192
194
  footer?: ReactNode;
193
195
  }
194
- declare const Drawer: ({ showDrawer, closeDrawer, title, width, children, leftButtonLabel, leftButtonAction, leftButtonDisabled, rightButtonLabel, rightButtonAction, rightButtonDisabled, isLoading, leftVariant, variant, footer, }: DrawerProps) => react_jsx_runtime.JSX.Element | null;
196
+ declare const Drawer: ({ showDrawer, closeDrawer, title, width, children, leftButtonLabel, leftButtonAction, leftButtonDisabled, rightButtonLabel, rightButtonAction, rightButtonDisabled, isLoading, leftVariant, variant, leftOutline, rightOutline, footer, }: DrawerProps) => react_jsx_runtime.JSX.Element | null;
195
197
 
196
198
  type SizeKey = 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl';
197
199
  interface TagBubbleProps extends HTMLAttributes<HTMLDivElement> {
@@ -266,6 +268,7 @@ interface TextProps extends Omit<HTMLAttributes<HTMLElement>, 'color'> {
266
268
  p?: boolean;
267
269
  max?: number | string;
268
270
  wrap?: string;
271
+ lineClamp?: number;
269
272
  onClick?: (e: MouseEvent) => void;
270
273
  style?: CSSProperties;
271
274
  className?: string;
@@ -597,6 +600,7 @@ interface TableProps extends HTMLAttributes<HTMLDivElement> {
597
600
  className?: string;
598
601
  fullWidth?: boolean;
599
602
  borderRadius?: string;
603
+ hasShadow?: boolean;
600
604
  }
601
605
  declare const Table: react.ForwardRefExoticComponent<TableProps & react.RefAttributes<HTMLDivElement>>;
602
606
 
@@ -902,6 +906,79 @@ interface EmptyStateProps {
902
906
  }
903
907
  declare const EmptyState: ({ icon, title, description, actionLabel, onAction, }: EmptyStateProps) => react_jsx_runtime.JSX.Element;
904
908
 
909
+ interface ProgressBarProps {
910
+ /** Filled portion, 0–100. Values outside the range are clamped. */
911
+ value: number;
912
+ /** Fill color (DZ color token). */
913
+ color?: string;
914
+ /** Track (unfilled) color (DZ color token). */
915
+ trackColor?: string;
916
+ /** Bar thickness in px. */
917
+ height?: number;
918
+ /** Show the "xx %" label on the right. */
919
+ showLabel?: boolean;
920
+ }
921
+ /**
922
+ * Horizontal coverage/progress bar. Track + fill, optional right-aligned label.
923
+ */
924
+ declare const ProgressBar: ({ value, color, trackColor, height, showLabel, }: ProgressBarProps) => react_jsx_runtime.JSX.Element;
925
+
926
+ interface TimelineItem {
927
+ /** Stable key for the row. */
928
+ id: string | number;
929
+ /** Main line (event label, mission name…). */
930
+ title: string;
931
+ /** Secondary line (date, author…). */
932
+ subtitle?: string;
933
+ /** Optional free text under the title. */
934
+ description?: string;
935
+ /** Dot color (DZ color token). */
936
+ color?: string;
937
+ /** Emphasize this point (e.g. the coverage point in a simulation). */
938
+ highlighted?: boolean;
939
+ }
940
+ interface TimelineProps {
941
+ items: TimelineItem[];
942
+ /** Color of the connecting line (DZ color token). */
943
+ lineColor?: string;
944
+ /** Text shown when there is no event. */
945
+ emptyLabel?: string;
946
+ }
947
+ /**
948
+ * Vertical timeline. Used for event logs (feedback history) and chronological
949
+ * lists (recovery simulation). Each point has a colored dot + title/subtitle.
950
+ */
951
+ declare const Timeline: ({ items, lineColor, emptyLabel, }: TimelineProps) => react_jsx_runtime.JSX.Element;
952
+
953
+ interface BorderedRowProps {
954
+ /** Accent color (DZ color token) — used to encode a score/status/level. */
955
+ borderColor?: string;
956
+ /** Accent thickness in px. */
957
+ borderWidth?: number;
958
+ /** Background color (DZ color token). */
959
+ background?: string;
960
+ /** Inner padding. */
961
+ padding?: string;
962
+ /** Corner radius — pass "0" for flush table rows, default rounded card. */
963
+ borderRadius?: string;
964
+ /**
965
+ * Accent style:
966
+ * - 'edge' (default): full-height colored left border (flush rows / score bars).
967
+ * - 'bar': short rounded inset accent bar, centered (white card look).
968
+ */
969
+ accent?: 'edge' | 'bar';
970
+ /** Subtle 1px full border around the card (card look). */
971
+ bordered?: boolean;
972
+ children: ReactNode;
973
+ onClick?: () => void;
974
+ }
975
+ /**
976
+ * Row/card with a colored accent, used to encode a status (recovery score,
977
+ * feedback level…). Flush table rows: accent="edge" + borderRadius="0".
978
+ * White cards: accent="bar" + bordered + background.
979
+ */
980
+ declare const BorderedRow: ({ borderColor, borderWidth, background, padding, borderRadius, accent, bordered, children, onClick, }: BorderedRowProps) => react_jsx_runtime.JSX.Element;
981
+
905
982
  /**
906
983
  * formatDate(date, type?, language?)
907
984
  * - language : fr/en/es/... (locale inferred), default "en"
@@ -948,4 +1025,4 @@ interface OptimizeImageOptions {
948
1025
  }
949
1026
  declare const optimizeImage: (file: File | null | undefined, desiredBaseName: string, opts?: OptimizeImageOptions) => Promise<OptimizeImageResult>;
950
1027
 
951
- export { Accordion, type AccordionItem, Avatar, Box, Bubble, Bulk, Button, CardSkeleton, Checkbox, Col, Collapse, ColorPicker, DatePicker, Divider, Drawer, EmptyState, FileUploadZone, Grid, Icon, IconTabs, Image, Input, Link, List, ListItem, MetricCard, Modal, ModalConfirmation, MultiSelect, NewModal, Options, PageContainer, Pagination, Popover, Radio, Row, Select, type SelectOption, type SelectProps, SkeletonRow, SliderInput, type SortOrder, Spinner, Stepper, Switch, Table, TableBody, TableCell, TableFooter, TableFooterCell, TableFooterRow, TableHeader, TableHeaderCell, type TableHeaderCellProps, TableHeaderRow, TableRow, Tabs, TagBubble, Text, Tooltip, colors, formatDate, formatDistance, formatDuration, optimizeImage, truncateFileName, truncateText };
1028
+ export { Accordion, type AccordionItem, Avatar, BorderedRow, Box, Bubble, Bulk, Button, CardSkeleton, Checkbox, Col, Collapse, ColorPicker, DatePicker, Divider, Drawer, EmptyState, FileUploadZone, Grid, Icon, IconTabs, Image, Input, Link, List, ListItem, MetricCard, Modal, ModalConfirmation, MultiSelect, NewModal, Options, PageContainer, Pagination, Popover, ProgressBar, Radio, Row, Select, type SelectOption, type SelectProps, SkeletonRow, SliderInput, type SortOrder, Spinner, Stepper, Switch, Table, TableBody, TableCell, TableFooter, TableFooterCell, TableFooterRow, TableHeader, TableHeaderCell, type TableHeaderCellProps, TableHeaderRow, TableRow, Tabs, TagBubble, Text, Timeline, type TimelineItem, Tooltip, colors, formatDate, formatDistance, formatDuration, optimizeImage, truncateFileName, truncateText };
package/dist/index.js CHANGED
@@ -61,6 +61,7 @@ var index_exports = {};
61
61
  __export(index_exports, {
62
62
  Accordion: () => Accordion,
63
63
  Avatar: () => Avatar,
64
+ BorderedRow: () => BorderedRow,
64
65
  Box: () => Box,
65
66
  Bubble: () => Bubble,
66
67
  Bulk: () => Bulk,
@@ -92,6 +93,7 @@ __export(index_exports, {
92
93
  PageContainer: () => PageContainer,
93
94
  Pagination: () => Pagination,
94
95
  Popover: () => Popover,
96
+ ProgressBar: () => ProgressBar,
95
97
  Radio: () => Radio,
96
98
  Row: () => Row,
97
99
  Select: () => Select,
@@ -113,6 +115,7 @@ __export(index_exports, {
113
115
  Tabs: () => Tabs,
114
116
  TagBubble: () => TagBubble,
115
117
  Text: () => Text,
118
+ Timeline: () => Timeline,
116
119
  Tooltip: () => Tooltip,
117
120
  colors: () => colors,
118
121
  formatDate: () => formatDate,
@@ -508,6 +511,7 @@ var Text = (props) => {
508
511
  p,
509
512
  max,
510
513
  wrap,
514
+ lineClamp,
511
515
  onClick
512
516
  } = _a, rest = __objRest(_a, [
513
517
  "size",
@@ -525,9 +529,10 @@ var Text = (props) => {
525
529
  "p",
526
530
  "max",
527
531
  "wrap",
532
+ "lineClamp",
528
533
  "onClick"
529
534
  ]);
530
- const textStyle = {
535
+ const textStyle = __spreadValues({
531
536
  fontSize: textSizes[size] || size,
532
537
  fontWeight: weight,
533
538
  color: color || colors[variant],
@@ -539,11 +544,15 @@ var Text = (props) => {
539
544
  fontStyle: fontStyle || "normal",
540
545
  cursor: onClick ? "pointer" : "inherit",
541
546
  maxWidth: max ? max + "ch" : "none",
542
- display: max ? "inline-block" : "",
547
+ display: lineClamp ? "-webkit-box" : max ? "inline-block" : "",
543
548
  overflow: "hidden",
544
549
  textOverflow: max ? "ellipsis" : "",
545
550
  whiteSpace: wrap || ""
546
- };
551
+ }, lineClamp ? {
552
+ WebkitLineClamp: lineClamp,
553
+ WebkitBoxOrient: "vertical",
554
+ wordBreak: "break-word"
555
+ } : {});
547
556
  if (p) {
548
557
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("p", __spreadProps(__spreadValues({ style: textStyle, onClick }, rest), { children }));
549
558
  } else {
@@ -1505,6 +1514,8 @@ var Drawer = ({
1505
1514
  isLoading = false,
1506
1515
  leftVariant,
1507
1516
  variant = "blue_700",
1517
+ leftOutline = true,
1518
+ rightOutline = false,
1508
1519
  footer
1509
1520
  }) => {
1510
1521
  const [isRendered, setIsRendered] = (0, import_react6.useState)(showDrawer);
@@ -1552,7 +1563,7 @@ var Drawer = ({
1552
1563
  leftButtonLabel && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1553
1564
  Button,
1554
1565
  {
1555
- outline: true,
1566
+ outline: leftOutline,
1556
1567
  onClick: leftButtonAction,
1557
1568
  disabled: leftButtonDisabled,
1558
1569
  variant: leftVariant ? leftVariant : variant,
@@ -1563,6 +1574,7 @@ var Drawer = ({
1563
1574
  rightButtonLabel && /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
1564
1575
  Button,
1565
1576
  {
1577
+ outline: rightOutline,
1566
1578
  onClick: rightButtonAction,
1567
1579
  isLoading,
1568
1580
  disabled: rightButtonDisabled,
@@ -1989,7 +2001,7 @@ var SearchInput = import_styled_components17.default.input`
1989
2001
  var Option = import_styled_components17.default.div`
1990
2002
  padding: 8px;
1991
2003
  cursor: pointer;
1992
- background-color: ${(props) => props.isActive ? colors.grey_100 : "transparent"};
2004
+ background-color: ${(props) => props.$isActive ? colors.grey_100 : "transparent"};
1993
2005
 
1994
2006
  &:hover {
1995
2007
  background: ${colors.grey_100};
@@ -2146,7 +2158,7 @@ var Select = ({
2146
2158
  /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(DropdownList, { children: filteredOptions.map((option, index) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
2147
2159
  Option,
2148
2160
  {
2149
- isActive: index === activeIndex,
2161
+ $isActive: index === activeIndex,
2150
2162
  onMouseEnter: () => setActiveIndex(index),
2151
2163
  onClick: () => handleSelect(option),
2152
2164
  style: { pointerEvents: "auto" },
@@ -3233,7 +3245,8 @@ var shouldForwardPropTable = (prop) => ![
3233
3245
  "height",
3234
3246
  "maxHeight",
3235
3247
  "fullWidth",
3236
- "borderRadius"
3248
+ "borderRadius",
3249
+ "hasShadow"
3237
3250
  ].includes(prop);
3238
3251
  var StyledTable = import_styled_components26.default.div.withConfig({
3239
3252
  shouldForwardProp: shouldForwardPropTable
@@ -3258,6 +3271,7 @@ var StyledContainer3 = import_styled_components26.default.div.withConfig({
3258
3271
  height: ${(props) => props.height || "100%"};
3259
3272
  border-radius: ${(props) => props.borderRadius || "8px"};
3260
3273
  border: 1.4px solid ${colors.grey_200};
3274
+ box-shadow: ${(props) => props.hasShadow ? "0 2px 12px 0 rgba(198, 198, 198, 0.25)" : "none"};
3261
3275
  `;
3262
3276
  var Table = (0, import_react14.forwardRef)((props, ref) => {
3263
3277
  const _a = props, { children } = _a, otherProps = __objRest(_a, ["children"]);
@@ -5213,6 +5227,167 @@ var EmptyState = ({
5213
5227
  );
5214
5228
  };
5215
5229
 
5230
+ // src/Components/ProgressBar/ProgressBar.tsx
5231
+ var import_styled_components45 = __toESM(require("styled-components"));
5232
+ var import_jsx_runtime56 = require("react/jsx-runtime");
5233
+ var clampPercent = (value) => Math.max(0, Math.min(100, value));
5234
+ var Wrapper5 = import_styled_components45.default.div`
5235
+ display: flex;
5236
+ align-items: center;
5237
+ gap: 8px;
5238
+ width: 100%;
5239
+ `;
5240
+ var Track2 = import_styled_components45.default.div`
5241
+ position: relative;
5242
+ flex: 1;
5243
+ height: ${({ $height }) => $height}px;
5244
+ background: ${({ $trackColor }) => $trackColor};
5245
+ border-radius: ${({ $height }) => $height}px;
5246
+ overflow: hidden;
5247
+ `;
5248
+ var Fill = import_styled_components45.default.div`
5249
+ height: 100%;
5250
+ width: ${({ $percent }) => $percent}%;
5251
+ background: ${({ $color }) => $color};
5252
+ border-radius: ${({ $height }) => $height}px;
5253
+ transition: width 0.2s ease;
5254
+ `;
5255
+ var ProgressBar = ({
5256
+ value,
5257
+ color = colors.blue_700,
5258
+ trackColor = colors.grey_200,
5259
+ height = 8,
5260
+ showLabel = false
5261
+ }) => {
5262
+ const percent = clampPercent(value);
5263
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(Wrapper5, { children: [
5264
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Track2, { $height: height, $trackColor: trackColor, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Fill, { $height: height, $color: color, $percent: percent }) }),
5265
+ showLabel && /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(Text, { size: "s", weight: "600", children: [
5266
+ Math.round(percent),
5267
+ " %"
5268
+ ] })
5269
+ ] });
5270
+ };
5271
+
5272
+ // src/Components/Timeline/Timeline.tsx
5273
+ var import_styled_components46 = __toESM(require("styled-components"));
5274
+ var import_jsx_runtime57 = require("react/jsx-runtime");
5275
+ var List2 = import_styled_components46.default.div`
5276
+ display: flex;
5277
+ flex-direction: column;
5278
+ `;
5279
+ var Item2 = import_styled_components46.default.div`
5280
+ display: flex;
5281
+ gap: 12px;
5282
+ align-items: stretch;
5283
+ `;
5284
+ var Rail = import_styled_components46.default.div`
5285
+ display: flex;
5286
+ flex-direction: column;
5287
+ align-items: center;
5288
+ width: 16px;
5289
+ `;
5290
+ var Dot2 = import_styled_components46.default.div`
5291
+ width: 10px;
5292
+ height: 10px;
5293
+ border-radius: 50%;
5294
+ margin-top: 4px;
5295
+ flex: 0 0 auto;
5296
+ background: ${({ $color }) => $color};
5297
+ `;
5298
+ var Line = import_styled_components46.default.div`
5299
+ width: 2px;
5300
+ flex: 1;
5301
+ min-height: 16px;
5302
+ background: ${({ $color }) => $color};
5303
+ `;
5304
+ var Content = import_styled_components46.default.div`
5305
+ display: flex;
5306
+ flex-direction: column;
5307
+ gap: 2px;
5308
+ padding-bottom: ${({ $last }) => $last ? "0" : "16px"};
5309
+ `;
5310
+ var Timeline = ({
5311
+ items,
5312
+ lineColor = colors.grey_200,
5313
+ emptyLabel = "Aucun \xE9v\xE9nement"
5314
+ }) => {
5315
+ if (items.length === 0) {
5316
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Text, { size: "s", color: colors.grey_600, children: emptyLabel });
5317
+ }
5318
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(List2, { children: items.map((item, index) => {
5319
+ var _a;
5320
+ const isLast = index === items.length - 1;
5321
+ const dotColor = (_a = item.color) != null ? _a : colors.blue_700;
5322
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Item2, { children: [
5323
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Rail, { children: [
5324
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Dot2, { $color: dotColor }),
5325
+ !isLast && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Line, { $color: lineColor })
5326
+ ] }),
5327
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Content, { $last: isLast, children: [
5328
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Text, { size: "s", weight: item.highlighted ? "700" : "600", children: item.title }),
5329
+ item.subtitle && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Text, { size: "xs", color: colors.grey_600, children: item.subtitle }),
5330
+ item.description && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Text, { size: "xs", fontStyle: "italic", children: item.description })
5331
+ ] })
5332
+ ] }, item.id);
5333
+ }) });
5334
+ };
5335
+
5336
+ // src/Components/BorderedRow/BorderedRow.tsx
5337
+ var import_styled_components47 = __toESM(require("styled-components"));
5338
+ var import_jsx_runtime58 = require("react/jsx-runtime");
5339
+ var Wrapper6 = import_styled_components47.default.div`
5340
+ box-sizing: border-box;
5341
+ position: relative;
5342
+ width: 100%;
5343
+ padding: ${({ $padding }) => $padding};
5344
+ ${({ $accent, $borderWidth }) => $accent === "bar" ? `padding-left: ${$borderWidth + 16}px;` : ""}
5345
+ border-radius: ${({ $borderRadius }) => $borderRadius};
5346
+ background: ${({ $background }) => $background || "transparent"};
5347
+ cursor: ${({ $clickable }) => $clickable ? "pointer" : "default"};
5348
+ ${({ $bordered }) => $bordered ? `border: 1px solid ${colors.grey_300};` : ""}
5349
+ ${({ $accent, $borderWidth, $borderColor }) => $accent === "edge" ? `border-left: ${$borderWidth}px solid ${$borderColor};` : ""}
5350
+
5351
+ ${({ $accent, $borderWidth, $borderColor }) => $accent === "bar" ? `
5352
+ &::before {
5353
+ content: '';
5354
+ position: absolute;
5355
+ left: 10px;
5356
+ top: 50%;
5357
+ transform: translateY(-50%);
5358
+ height: 62%;
5359
+ width: ${$borderWidth}px;
5360
+ border-radius: ${$borderWidth}px;
5361
+ background: ${$borderColor};
5362
+ }
5363
+ ` : ""}
5364
+ `;
5365
+ var BorderedRow = ({
5366
+ borderColor = colors.blue_700,
5367
+ borderWidth = 4,
5368
+ background,
5369
+ padding = "12px",
5370
+ borderRadius = "8px",
5371
+ accent = "edge",
5372
+ bordered = false,
5373
+ children,
5374
+ onClick
5375
+ }) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
5376
+ Wrapper6,
5377
+ {
5378
+ $borderColor: borderColor,
5379
+ $borderWidth: borderWidth,
5380
+ $background: background,
5381
+ $padding: padding,
5382
+ $borderRadius: borderRadius,
5383
+ $accent: accent,
5384
+ $bordered: bordered,
5385
+ $clickable: !!onClick,
5386
+ onClick,
5387
+ children
5388
+ }
5389
+ );
5390
+
5216
5391
  // src/data/globalMethods.ts
5217
5392
  var formatDate = (dateString, type = "date", language = "en") => {
5218
5393
  if (!dateString) return "";
@@ -5460,6 +5635,7 @@ var optimizeImage_default = optimizeImage;
5460
5635
  0 && (module.exports = {
5461
5636
  Accordion,
5462
5637
  Avatar,
5638
+ BorderedRow,
5463
5639
  Box,
5464
5640
  Bubble,
5465
5641
  Bulk,
@@ -5491,6 +5667,7 @@ var optimizeImage_default = optimizeImage;
5491
5667
  PageContainer,
5492
5668
  Pagination,
5493
5669
  Popover,
5670
+ ProgressBar,
5494
5671
  Radio,
5495
5672
  Row,
5496
5673
  Select,
@@ -5512,6 +5689,7 @@ var optimizeImage_default = optimizeImage;
5512
5689
  Tabs,
5513
5690
  TagBubble,
5514
5691
  Text,
5692
+ Timeline,
5515
5693
  Tooltip,
5516
5694
  colors,
5517
5695
  formatDate,
package/dist/index.mjs CHANGED
@@ -414,6 +414,7 @@ var Text = (props) => {
414
414
  p,
415
415
  max,
416
416
  wrap,
417
+ lineClamp,
417
418
  onClick
418
419
  } = _a, rest = __objRest(_a, [
419
420
  "size",
@@ -431,9 +432,10 @@ var Text = (props) => {
431
432
  "p",
432
433
  "max",
433
434
  "wrap",
435
+ "lineClamp",
434
436
  "onClick"
435
437
  ]);
436
- const textStyle = {
438
+ const textStyle = __spreadValues({
437
439
  fontSize: textSizes[size] || size,
438
440
  fontWeight: weight,
439
441
  color: color || colors[variant],
@@ -445,11 +447,15 @@ var Text = (props) => {
445
447
  fontStyle: fontStyle || "normal",
446
448
  cursor: onClick ? "pointer" : "inherit",
447
449
  maxWidth: max ? max + "ch" : "none",
448
- display: max ? "inline-block" : "",
450
+ display: lineClamp ? "-webkit-box" : max ? "inline-block" : "",
449
451
  overflow: "hidden",
450
452
  textOverflow: max ? "ellipsis" : "",
451
453
  whiteSpace: wrap || ""
452
- };
454
+ }, lineClamp ? {
455
+ WebkitLineClamp: lineClamp,
456
+ WebkitBoxOrient: "vertical",
457
+ wordBreak: "break-word"
458
+ } : {});
453
459
  if (p) {
454
460
  return /* @__PURE__ */ jsx6("p", __spreadProps(__spreadValues({ style: textStyle, onClick }, rest), { children }));
455
461
  } else {
@@ -1411,6 +1417,8 @@ var Drawer = ({
1411
1417
  isLoading = false,
1412
1418
  leftVariant,
1413
1419
  variant = "blue_700",
1420
+ leftOutline = true,
1421
+ rightOutline = false,
1414
1422
  footer
1415
1423
  }) => {
1416
1424
  const [isRendered, setIsRendered] = useState3(showDrawer);
@@ -1458,7 +1466,7 @@ var Drawer = ({
1458
1466
  leftButtonLabel && /* @__PURE__ */ jsx16(
1459
1467
  Button,
1460
1468
  {
1461
- outline: true,
1469
+ outline: leftOutline,
1462
1470
  onClick: leftButtonAction,
1463
1471
  disabled: leftButtonDisabled,
1464
1472
  variant: leftVariant ? leftVariant : variant,
@@ -1469,6 +1477,7 @@ var Drawer = ({
1469
1477
  rightButtonLabel && /* @__PURE__ */ jsx16(
1470
1478
  Button,
1471
1479
  {
1480
+ outline: rightOutline,
1472
1481
  onClick: rightButtonAction,
1473
1482
  isLoading,
1474
1483
  disabled: rightButtonDisabled,
@@ -1895,7 +1904,7 @@ var SearchInput = styled17.input`
1895
1904
  var Option = styled17.div`
1896
1905
  padding: 8px;
1897
1906
  cursor: pointer;
1898
- background-color: ${(props) => props.isActive ? colors.grey_100 : "transparent"};
1907
+ background-color: ${(props) => props.$isActive ? colors.grey_100 : "transparent"};
1899
1908
 
1900
1909
  &:hover {
1901
1910
  background: ${colors.grey_100};
@@ -2052,7 +2061,7 @@ var Select = ({
2052
2061
  /* @__PURE__ */ jsx21(DropdownList, { children: filteredOptions.map((option, index) => /* @__PURE__ */ jsx21(
2053
2062
  Option,
2054
2063
  {
2055
- isActive: index === activeIndex,
2064
+ $isActive: index === activeIndex,
2056
2065
  onMouseEnter: () => setActiveIndex(index),
2057
2066
  onClick: () => handleSelect(option),
2058
2067
  style: { pointerEvents: "auto" },
@@ -3145,7 +3154,8 @@ var shouldForwardPropTable = (prop) => ![
3145
3154
  "height",
3146
3155
  "maxHeight",
3147
3156
  "fullWidth",
3148
- "borderRadius"
3157
+ "borderRadius",
3158
+ "hasShadow"
3149
3159
  ].includes(prop);
3150
3160
  var StyledTable = styled26.div.withConfig({
3151
3161
  shouldForwardProp: shouldForwardPropTable
@@ -3170,6 +3180,7 @@ var StyledContainer3 = styled26.div.withConfig({
3170
3180
  height: ${(props) => props.height || "100%"};
3171
3181
  border-radius: ${(props) => props.borderRadius || "8px"};
3172
3182
  border: 1.4px solid ${colors.grey_200};
3183
+ box-shadow: ${(props) => props.hasShadow ? "0 2px 12px 0 rgba(198, 198, 198, 0.25)" : "none"};
3173
3184
  `;
3174
3185
  var Table = forwardRef5((props, ref) => {
3175
3186
  const _a = props, { children } = _a, otherProps = __objRest(_a, ["children"]);
@@ -5139,6 +5150,167 @@ var EmptyState = ({
5139
5150
  );
5140
5151
  };
5141
5152
 
5153
+ // src/Components/ProgressBar/ProgressBar.tsx
5154
+ import styled45 from "styled-components";
5155
+ import { jsx as jsx56, jsxs as jsxs30 } from "react/jsx-runtime";
5156
+ var clampPercent = (value) => Math.max(0, Math.min(100, value));
5157
+ var Wrapper5 = styled45.div`
5158
+ display: flex;
5159
+ align-items: center;
5160
+ gap: 8px;
5161
+ width: 100%;
5162
+ `;
5163
+ var Track2 = styled45.div`
5164
+ position: relative;
5165
+ flex: 1;
5166
+ height: ${({ $height }) => $height}px;
5167
+ background: ${({ $trackColor }) => $trackColor};
5168
+ border-radius: ${({ $height }) => $height}px;
5169
+ overflow: hidden;
5170
+ `;
5171
+ var Fill = styled45.div`
5172
+ height: 100%;
5173
+ width: ${({ $percent }) => $percent}%;
5174
+ background: ${({ $color }) => $color};
5175
+ border-radius: ${({ $height }) => $height}px;
5176
+ transition: width 0.2s ease;
5177
+ `;
5178
+ var ProgressBar = ({
5179
+ value,
5180
+ color = colors.blue_700,
5181
+ trackColor = colors.grey_200,
5182
+ height = 8,
5183
+ showLabel = false
5184
+ }) => {
5185
+ const percent = clampPercent(value);
5186
+ return /* @__PURE__ */ jsxs30(Wrapper5, { children: [
5187
+ /* @__PURE__ */ jsx56(Track2, { $height: height, $trackColor: trackColor, children: /* @__PURE__ */ jsx56(Fill, { $height: height, $color: color, $percent: percent }) }),
5188
+ showLabel && /* @__PURE__ */ jsxs30(Text, { size: "s", weight: "600", children: [
5189
+ Math.round(percent),
5190
+ " %"
5191
+ ] })
5192
+ ] });
5193
+ };
5194
+
5195
+ // src/Components/Timeline/Timeline.tsx
5196
+ import styled46 from "styled-components";
5197
+ import { jsx as jsx57, jsxs as jsxs31 } from "react/jsx-runtime";
5198
+ var List2 = styled46.div`
5199
+ display: flex;
5200
+ flex-direction: column;
5201
+ `;
5202
+ var Item2 = styled46.div`
5203
+ display: flex;
5204
+ gap: 12px;
5205
+ align-items: stretch;
5206
+ `;
5207
+ var Rail = styled46.div`
5208
+ display: flex;
5209
+ flex-direction: column;
5210
+ align-items: center;
5211
+ width: 16px;
5212
+ `;
5213
+ var Dot2 = styled46.div`
5214
+ width: 10px;
5215
+ height: 10px;
5216
+ border-radius: 50%;
5217
+ margin-top: 4px;
5218
+ flex: 0 0 auto;
5219
+ background: ${({ $color }) => $color};
5220
+ `;
5221
+ var Line = styled46.div`
5222
+ width: 2px;
5223
+ flex: 1;
5224
+ min-height: 16px;
5225
+ background: ${({ $color }) => $color};
5226
+ `;
5227
+ var Content = styled46.div`
5228
+ display: flex;
5229
+ flex-direction: column;
5230
+ gap: 2px;
5231
+ padding-bottom: ${({ $last }) => $last ? "0" : "16px"};
5232
+ `;
5233
+ var Timeline = ({
5234
+ items,
5235
+ lineColor = colors.grey_200,
5236
+ emptyLabel = "Aucun \xE9v\xE9nement"
5237
+ }) => {
5238
+ if (items.length === 0) {
5239
+ return /* @__PURE__ */ jsx57(Text, { size: "s", color: colors.grey_600, children: emptyLabel });
5240
+ }
5241
+ return /* @__PURE__ */ jsx57(List2, { children: items.map((item, index) => {
5242
+ var _a;
5243
+ const isLast = index === items.length - 1;
5244
+ const dotColor = (_a = item.color) != null ? _a : colors.blue_700;
5245
+ return /* @__PURE__ */ jsxs31(Item2, { children: [
5246
+ /* @__PURE__ */ jsxs31(Rail, { children: [
5247
+ /* @__PURE__ */ jsx57(Dot2, { $color: dotColor }),
5248
+ !isLast && /* @__PURE__ */ jsx57(Line, { $color: lineColor })
5249
+ ] }),
5250
+ /* @__PURE__ */ jsxs31(Content, { $last: isLast, children: [
5251
+ /* @__PURE__ */ jsx57(Text, { size: "s", weight: item.highlighted ? "700" : "600", children: item.title }),
5252
+ item.subtitle && /* @__PURE__ */ jsx57(Text, { size: "xs", color: colors.grey_600, children: item.subtitle }),
5253
+ item.description && /* @__PURE__ */ jsx57(Text, { size: "xs", fontStyle: "italic", children: item.description })
5254
+ ] })
5255
+ ] }, item.id);
5256
+ }) });
5257
+ };
5258
+
5259
+ // src/Components/BorderedRow/BorderedRow.tsx
5260
+ import styled47 from "styled-components";
5261
+ import { jsx as jsx58 } from "react/jsx-runtime";
5262
+ var Wrapper6 = styled47.div`
5263
+ box-sizing: border-box;
5264
+ position: relative;
5265
+ width: 100%;
5266
+ padding: ${({ $padding }) => $padding};
5267
+ ${({ $accent, $borderWidth }) => $accent === "bar" ? `padding-left: ${$borderWidth + 16}px;` : ""}
5268
+ border-radius: ${({ $borderRadius }) => $borderRadius};
5269
+ background: ${({ $background }) => $background || "transparent"};
5270
+ cursor: ${({ $clickable }) => $clickable ? "pointer" : "default"};
5271
+ ${({ $bordered }) => $bordered ? `border: 1px solid ${colors.grey_300};` : ""}
5272
+ ${({ $accent, $borderWidth, $borderColor }) => $accent === "edge" ? `border-left: ${$borderWidth}px solid ${$borderColor};` : ""}
5273
+
5274
+ ${({ $accent, $borderWidth, $borderColor }) => $accent === "bar" ? `
5275
+ &::before {
5276
+ content: '';
5277
+ position: absolute;
5278
+ left: 10px;
5279
+ top: 50%;
5280
+ transform: translateY(-50%);
5281
+ height: 62%;
5282
+ width: ${$borderWidth}px;
5283
+ border-radius: ${$borderWidth}px;
5284
+ background: ${$borderColor};
5285
+ }
5286
+ ` : ""}
5287
+ `;
5288
+ var BorderedRow = ({
5289
+ borderColor = colors.blue_700,
5290
+ borderWidth = 4,
5291
+ background,
5292
+ padding = "12px",
5293
+ borderRadius = "8px",
5294
+ accent = "edge",
5295
+ bordered = false,
5296
+ children,
5297
+ onClick
5298
+ }) => /* @__PURE__ */ jsx58(
5299
+ Wrapper6,
5300
+ {
5301
+ $borderColor: borderColor,
5302
+ $borderWidth: borderWidth,
5303
+ $background: background,
5304
+ $padding: padding,
5305
+ $borderRadius: borderRadius,
5306
+ $accent: accent,
5307
+ $bordered: bordered,
5308
+ $clickable: !!onClick,
5309
+ onClick,
5310
+ children
5311
+ }
5312
+ );
5313
+
5142
5314
  // src/data/globalMethods.ts
5143
5315
  var formatDate = (dateString, type = "date", language = "en") => {
5144
5316
  if (!dateString) return "";
@@ -5385,6 +5557,7 @@ var optimizeImage_default = optimizeImage;
5385
5557
  export {
5386
5558
  Accordion,
5387
5559
  Avatar,
5560
+ BorderedRow,
5388
5561
  Box,
5389
5562
  Bubble,
5390
5563
  Bulk,
@@ -5416,6 +5589,7 @@ export {
5416
5589
  PageContainer,
5417
5590
  Pagination,
5418
5591
  Popover,
5592
+ ProgressBar,
5419
5593
  Radio,
5420
5594
  Row,
5421
5595
  Select,
@@ -5437,6 +5611,7 @@ export {
5437
5611
  Tabs,
5438
5612
  TagBubble,
5439
5613
  Text,
5614
+ Timeline,
5440
5615
  Tooltip,
5441
5616
  colors,
5442
5617
  formatDate,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "design-zystem",
3
- "version": "1.0.247",
3
+ "version": "1.0.248",
4
4
  "description": "A React design system of importable components",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",