design-zystem 1.0.341 → 1.0.343

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
@@ -151,6 +151,7 @@ interface BulkSection {
151
151
  icon: string;
152
152
  action: () => void;
153
153
  disabled?: boolean;
154
+ disabledTooltip?: string;
154
155
  }
155
156
  interface BulkProps {
156
157
  onClose?: () => void;
package/dist/index.d.ts CHANGED
@@ -151,6 +151,7 @@ interface BulkSection {
151
151
  icon: string;
152
152
  action: () => void;
153
153
  disabled?: boolean;
154
+ disabledTooltip?: string;
154
155
  }
155
156
  interface BulkProps {
156
157
  onClose?: () => void;
package/dist/index.js CHANGED
@@ -817,8 +817,142 @@ var Divider = (_a) => {
817
817
  );
818
818
  };
819
819
 
820
- // src/ui-legacy/Components/Bulk/Bulk.tsx
820
+ // src/ui-legacy/Components/Tooltip/Tooltip.tsx
821
+ var import_react3 = require("react");
822
+ var import_styled_components8 = __toESM(require("styled-components"));
821
823
  var import_jsx_runtime9 = require("react/jsx-runtime");
824
+ var StyledTooltipWrapper = import_styled_components8.default.div`
825
+ position: relative;
826
+ display: ${(props) => props.$fullWidth ? "block" : "inline-block"};
827
+ width: ${(props) => props.$fullWidth ? "100%" : "auto"};
828
+ cursor: pointer;
829
+ `;
830
+ var StyledTooltipContent = import_styled_components8.default.div`
831
+ visibility: ${(props) => props.$isVisible ? "visible" : "hidden"};
832
+ background-color: ${(props) => props.$backgroundColor || colors.black};
833
+ color: ${colors.white};
834
+ text-align: center;
835
+ padding: 8px;
836
+ border-radius: 4px;
837
+ position: absolute;
838
+ width: ${(props) => props.$width || "200px"};
839
+ height: ${(props) => props.$height || "auto"};
840
+ opacity: ${(props) => props.$isVisible ? 1 : 0};
841
+ transition: opacity 0.3s;
842
+ z-index: 1;
843
+ display: flex;
844
+ flex-direction: column;
845
+ align-items: center;
846
+ gap: 4px;
847
+
848
+ ${(props) => {
849
+ switch (props.$direction) {
850
+ case "top":
851
+ return `
852
+ bottom: 125%;
853
+ left: 50%;
854
+ transform: translateX(-50%);
855
+ &::after {
856
+ content: "";
857
+ position: absolute;
858
+ top: 100%;
859
+ left: 50%;
860
+ transform: translateX(-50%);
861
+ border-width: 5px;
862
+ border-style: solid;
863
+ border-color: ${props.$backgroundColor || colors.black} transparent transparent transparent;
864
+ }
865
+ `;
866
+ case "bottom":
867
+ return `
868
+ top: 125%;
869
+ left: 50%;
870
+ transform: translateX(-50%);
871
+ &::after {
872
+ content: "";
873
+ position: absolute;
874
+ bottom: 100%;
875
+ left: 50%;
876
+ transform: translateX(-50%);
877
+ border-width: 5px;
878
+ border-style: solid;
879
+ border-color: transparent transparent ${props.$backgroundColor || colors.black} transparent;
880
+ }
881
+ `;
882
+ case "left":
883
+ return `
884
+ top: 50%;
885
+ right: 125%;
886
+ transform: translateY(-50%);
887
+ &::after {
888
+ content: "";
889
+ position: absolute;
890
+ top: 50%;
891
+ left: 100%;
892
+ transform: translateY(-50%);
893
+ border-width: 5px;
894
+ border-style: solid;
895
+ border-color: transparent transparent transparent ${props.$backgroundColor || colors.black};
896
+ }
897
+ `;
898
+ case "right":
899
+ default:
900
+ return `
901
+ top: 50%;
902
+ left: 125%;
903
+ transform: translateY(-50%);
904
+ &::after {
905
+ content: "";
906
+ position: absolute;
907
+ top: 50%;
908
+ right: 100%;
909
+ transform: translateY(-50%);
910
+ border-width: 5px;
911
+ border-style: solid;
912
+ border-color: transparent ${props.$backgroundColor || colors.black} transparent transparent;
913
+ }
914
+ `;
915
+ }
916
+ }}
917
+ `;
918
+ var Tooltip = ({
919
+ backgroundColor,
920
+ data = [],
921
+ width,
922
+ height,
923
+ direction = "top",
924
+ fullWidth = false,
925
+ children
926
+ }) => {
927
+ const [isVisible, setIsVisible] = (0, import_react3.useState)(false);
928
+ const handleMouseEnter = () => setIsVisible(true);
929
+ const handleMouseLeave = () => setIsVisible(false);
930
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
931
+ StyledTooltipWrapper,
932
+ {
933
+ $fullWidth: fullWidth,
934
+ onMouseEnter: handleMouseEnter,
935
+ onMouseLeave: handleMouseLeave,
936
+ children: [
937
+ children,
938
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
939
+ StyledTooltipContent,
940
+ {
941
+ $isVisible: isVisible,
942
+ $backgroundColor: backgroundColor,
943
+ $width: width,
944
+ $height: height,
945
+ $direction: direction,
946
+ children: data.length > 0 ? data.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Text, { size: "s", color: "white", children: item }, index)) : /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Text, { size: "s", color: "white", children: "Aucune donn\xE9e" })
947
+ }
948
+ )
949
+ ]
950
+ }
951
+ );
952
+ };
953
+
954
+ // src/ui-legacy/Components/Bulk/Bulk.tsx
955
+ var import_jsx_runtime10 = require("react/jsx-runtime");
822
956
  var Bulk = ({
823
957
  onClose,
824
958
  leftTitle,
@@ -830,7 +964,7 @@ var Bulk = ({
830
964
  const mainColor = colors[variant] || colors.blue_700;
831
965
  const textColorStyle = colors[textColor] || colors.white;
832
966
  const hoverColorStyle = colors[hoverColor] || colors.blue_900;
833
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
967
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
834
968
  Box,
835
969
  {
836
970
  background: mainColor,
@@ -842,11 +976,11 @@ var Bulk = ({
842
976
  zIndex: 500,
843
977
  borderRadius: "12px"
844
978
  },
845
- children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Row, { alignItems: "center", children: [
846
- leftTitle && /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Row, { gap: 24, alignItems: "center", children: [
847
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Icon, { name: "xmark", color: "white", size: "l", onClick: onClose }),
848
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Text, { color: textColorStyle, weight: "bold", size: "s", wrap: "nowrap", children: leftTitle }),
849
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
979
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Row, { alignItems: "center", children: [
980
+ leftTitle && /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Row, { gap: 24, alignItems: "center", children: [
981
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Icon, { name: "xmark", color: "white", size: "l", onClick: onClose }),
982
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Text, { color: textColorStyle, weight: "bold", size: "s", wrap: "nowrap", children: leftTitle }),
983
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
850
984
  Divider,
851
985
  {
852
986
  orientation: "vertical",
@@ -856,9 +990,9 @@ var Bulk = ({
856
990
  }
857
991
  )
858
992
  ] }),
859
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Row, { alignItems: "center", children: sections.map((section, idx) => {
993
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Row, { alignItems: "center", children: sections.map((section, idx) => {
860
994
  const isLast = idx === sections.length - 1;
861
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
995
+ const sectionButton = /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
862
996
  Row,
863
997
  {
864
998
  gap: 6,
@@ -883,7 +1017,7 @@ var Bulk = ({
883
1017
  e.currentTarget.style.background = mainColor;
884
1018
  },
885
1019
  children: [
886
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1020
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
887
1021
  Icon,
888
1022
  {
889
1023
  name: section.icon,
@@ -892,7 +1026,7 @@ var Bulk = ({
892
1026
  family: "regular"
893
1027
  }
894
1028
  ),
895
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1029
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
896
1030
  Text,
897
1031
  {
898
1032
  color: textColorStyle,
@@ -906,6 +1040,7 @@ var Bulk = ({
906
1040
  },
907
1041
  section.title
908
1042
  );
1043
+ return section.disabled && section.disabledTooltip ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Tooltip, { data: [section.disabledTooltip], children: sectionButton }, section.title) : sectionButton;
909
1044
  }) })
910
1045
  ] })
911
1046
  }
@@ -913,22 +1048,22 @@ var Bulk = ({
913
1048
  };
914
1049
 
915
1050
  // src/ui-legacy/Components/Collapse/Collapse.tsx
916
- var import_react3 = require("react");
917
- var import_styled_components8 = __toESM(require("styled-components"));
918
- var import_jsx_runtime10 = require("react/jsx-runtime");
919
- var Wrapper = import_styled_components8.default.div`
1051
+ var import_react4 = require("react");
1052
+ var import_styled_components9 = __toESM(require("styled-components"));
1053
+ var import_jsx_runtime11 = require("react/jsx-runtime");
1054
+ var Wrapper = import_styled_components9.default.div`
920
1055
  overflow: hidden;
921
1056
  transition: height 0.25s ease;
922
1057
  height: ${(p) => p.$height}px;
923
1058
  `;
924
- var Inner = import_styled_components8.default.div`
1059
+ var Inner = import_styled_components9.default.div`
925
1060
  max-height: ${(p) => p.$maxHeight ? `${p.$maxHeight}px` : "none"};
926
1061
  overflow-y: ${(p) => p.$maxHeight ? "auto" : "visible"};
927
1062
  `;
928
1063
  var Collapse = ({ open, children, maxHeight }) => {
929
- const innerRef = (0, import_react3.useRef)(null);
930
- const [height, setHeight] = (0, import_react3.useState)(0);
931
- const recalc = (0, import_react3.useCallback)(() => {
1064
+ const innerRef = (0, import_react4.useRef)(null);
1065
+ const [height, setHeight] = (0, import_react4.useState)(0);
1066
+ const recalc = (0, import_react4.useCallback)(() => {
932
1067
  if (open && innerRef.current) {
933
1068
  const full = innerRef.current.scrollHeight;
934
1069
  setHeight(maxHeight ? Math.min(full, maxHeight) : full);
@@ -936,20 +1071,20 @@ var Collapse = ({ open, children, maxHeight }) => {
936
1071
  setHeight(0);
937
1072
  }
938
1073
  }, [open, maxHeight]);
939
- (0, import_react3.useEffect)(recalc, [recalc]);
940
- (0, import_react3.useEffect)(() => {
1074
+ (0, import_react4.useEffect)(recalc, [recalc]);
1075
+ (0, import_react4.useEffect)(() => {
941
1076
  if (!open || !innerRef.current) return;
942
1077
  const observer = new ResizeObserver(recalc);
943
1078
  observer.observe(innerRef.current);
944
1079
  return () => observer.disconnect();
945
1080
  }, [open, recalc]);
946
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Wrapper, { $height: height, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Inner, { ref: innerRef, $maxHeight: maxHeight, children }) });
1081
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Wrapper, { $height: height, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Inner, { ref: innerRef, $maxHeight: maxHeight, children }) });
947
1082
  };
948
1083
 
949
1084
  // src/ui-legacy/Components/Button/Button.tsx
950
- var import_react4 = require("react");
951
- var import_styled_components9 = __toESM(require("styled-components"));
952
- var import_jsx_runtime11 = require("react/jsx-runtime");
1085
+ var import_react5 = require("react");
1086
+ var import_styled_components10 = __toESM(require("styled-components"));
1087
+ var import_jsx_runtime12 = require("react/jsx-runtime");
953
1088
  var defaultSizes = {
954
1089
  xs: { height: 32, paddingX: 16, textSize: "xs" },
955
1090
  s: { height: 36, paddingX: 16, textSize: "s" },
@@ -978,7 +1113,7 @@ var shouldForwardProp4 = (p) => ![
978
1113
  "iconOnlySize",
979
1114
  "noHover"
980
1115
  ].includes(p);
981
- var StyledButton = import_styled_components9.default.button.withConfig({
1116
+ var StyledButton = import_styled_components10.default.button.withConfig({
982
1117
  shouldForwardProp: shouldForwardProp4
983
1118
  })`
984
1119
  position: relative;
@@ -1070,7 +1205,7 @@ var StyledButton = import_styled_components9.default.button.withConfig({
1070
1205
  border-radius: 6px;
1071
1206
  `}
1072
1207
  `;
1073
- var Loader = import_styled_components9.default.span`
1208
+ var Loader = import_styled_components10.default.span`
1074
1209
  border: 3px solid transparent;
1075
1210
  border-top: 3px solid currentColor;
1076
1211
  border-radius: 50%;
@@ -1121,9 +1256,9 @@ var Button = (_a) => {
1121
1256
  "noHover",
1122
1257
  "iconOnlySize"
1123
1258
  ]);
1124
- const ref = (0, import_react4.useRef)(null);
1259
+ const ref = (0, import_react5.useRef)(null);
1125
1260
  const sizeConfig = defaultSizes[size];
1126
- const renderIconSlot = (icon) => typeof icon === "string" ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1261
+ const renderIconSlot = (icon) => typeof icon === "string" ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1127
1262
  Icon,
1128
1263
  {
1129
1264
  name: icon,
@@ -1132,7 +1267,7 @@ var Button = (_a) => {
1132
1267
  color: iconColor != null ? iconColor : outline ? variant : colors.white
1133
1268
  }
1134
1269
  ) : icon;
1135
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
1270
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1136
1271
  StyledButton,
1137
1272
  __spreadProps(__spreadValues({
1138
1273
  ref,
@@ -1150,10 +1285,10 @@ var Button = (_a) => {
1150
1285
  iconOnlySize
1151
1286
  }, rest), {
1152
1287
  children: [
1153
- isLoading && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Loader, {}),
1154
- !isLoading && /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Row, { gap: "8", fullwidth: true, justifyContent: "center", alignItems: "center", children: [
1288
+ isLoading && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Loader, {}),
1289
+ !isLoading && /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Row, { gap: "8", fullwidth: true, justifyContent: "center", alignItems: "center", children: [
1155
1290
  iconLeft && renderIconSlot(iconLeft),
1156
- label && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
1291
+ label && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1157
1292
  Text,
1158
1293
  {
1159
1294
  size: sizeConfig.textSize,
@@ -1171,11 +1306,11 @@ var Button = (_a) => {
1171
1306
  };
1172
1307
 
1173
1308
  // src/ui-legacy/Components/Modal/Modal.tsx
1174
- var import_react5 = require("react");
1175
- var import_styled_components10 = __toESM(require("styled-components"));
1176
- var import_jsx_runtime12 = require("react/jsx-runtime");
1309
+ var import_react6 = require("react");
1310
+ var import_styled_components11 = __toESM(require("styled-components"));
1311
+ var import_jsx_runtime13 = require("react/jsx-runtime");
1177
1312
  var shouldForwardProp5 = (prop) => !["width", "height", "minHeight", "padding", "backgroundColor"].includes(prop);
1178
- var ModalBackdrop = import_styled_components10.default.div`
1313
+ var ModalBackdrop = import_styled_components11.default.div`
1179
1314
  position: fixed;
1180
1315
  top: 0;
1181
1316
  left: 0;
@@ -1185,7 +1320,7 @@ var ModalBackdrop = import_styled_components10.default.div`
1185
1320
  backdrop-filter: blur(5px);
1186
1321
  z-index: 4;
1187
1322
  `;
1188
- var ModalContainer = import_styled_components10.default.div.withConfig({ shouldForwardProp: shouldForwardProp5 })`
1323
+ var ModalContainer = import_styled_components11.default.div.withConfig({ shouldForwardProp: shouldForwardProp5 })`
1189
1324
  position: fixed;
1190
1325
  top: 50%;
1191
1326
  left: 50%;
@@ -1208,7 +1343,7 @@ var ModalContainer = import_styled_components10.default.div.withConfig({ shouldF
1208
1343
  max-height: 90%;
1209
1344
  overflow: auto;
1210
1345
  `;
1211
- var ModalHeader = import_styled_components10.default.div`
1346
+ var ModalHeader = import_styled_components11.default.div`
1212
1347
  display: flex;
1213
1348
  justify-content: space-between;
1214
1349
  align-items: center;
@@ -1216,14 +1351,14 @@ var ModalHeader = import_styled_components10.default.div`
1216
1351
  border-bottom: 1px solid #ddd;
1217
1352
  width: 100%;
1218
1353
  `;
1219
- var ModalCore = import_styled_components10.default.div`
1354
+ var ModalCore = import_styled_components11.default.div`
1220
1355
  padding: 20px;
1221
1356
  background-color: white;
1222
1357
  border-radius: 0 0 10px 10px;
1223
1358
  overflow: auto;
1224
1359
  height: 100%;
1225
1360
  `;
1226
- var ModalClose = import_styled_components10.default.span`
1361
+ var ModalClose = import_styled_components11.default.span`
1227
1362
  font-size: 32px;
1228
1363
  color: #fff;
1229
1364
  cursor: pointer;
@@ -1247,7 +1382,7 @@ var Modal = (props) => {
1247
1382
  const hideModal = () => {
1248
1383
  closeModal == null ? void 0 : closeModal();
1249
1384
  };
1250
- (0, import_react5.useEffect)(() => {
1385
+ (0, import_react6.useEffect)(() => {
1251
1386
  if (showModal) {
1252
1387
  document.body.classList.add("modal-open");
1253
1388
  } else {
@@ -1257,9 +1392,9 @@ var Modal = (props) => {
1257
1392
  document.body.classList.remove("modal-open");
1258
1393
  };
1259
1394
  }, [showModal]);
1260
- return showModal && /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
1261
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ModalBackdrop, { onClick: hideModal }),
1262
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
1395
+ return showModal && /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_jsx_runtime13.Fragment, { children: [
1396
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ModalBackdrop, { onClick: hideModal }),
1397
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
1263
1398
  ModalContainer,
1264
1399
  {
1265
1400
  width,
@@ -1268,11 +1403,11 @@ var Modal = (props) => {
1268
1403
  backgroundColor,
1269
1404
  minHeight,
1270
1405
  children: [
1271
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ModalHeader, { children: [
1272
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(Text_default, { color: "white", weight: "700", children: title ? title : "DELIVERY CAR" }),
1273
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ModalClose, { onClick: hideModal, children: "\xD7" })
1406
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(ModalHeader, { children: [
1407
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Text_default, { color: "white", weight: "700", children: title ? title : "DELIVERY CAR" }),
1408
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ModalClose, { onClick: hideModal, children: "\xD7" })
1274
1409
  ] }),
1275
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ModalCore, { children })
1410
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ModalCore, { children })
1276
1411
  ]
1277
1412
  }
1278
1413
  )
@@ -1280,15 +1415,15 @@ var Modal = (props) => {
1280
1415
  };
1281
1416
 
1282
1417
  // src/ui-legacy/Components/ModalConfirmation/ModalConfirmation.tsx
1283
- var import_jsx_runtime13 = require("react/jsx-runtime");
1418
+ var import_jsx_runtime14 = require("react/jsx-runtime");
1284
1419
  var ModalConfirmation = (props) => {
1285
1420
  const { isOpen, onConfirm, onCancel, isLoading, width } = props;
1286
1421
  if (!isOpen) return null;
1287
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Modal, { showModal: isOpen, closeModal: onCancel, width, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(Col, { gap: "16", justifyContent: "center", alignItems: "center", fullWidth: true, children: [
1288
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Row, { gap: "8", justifyContent: "center", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Text, { align: "center", margin: "1em 0", size: "xl", children: "\xCAtes-vous s\xFBr de vouloir faire cette action ?" }) }),
1289
- /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(Row, { gap: "8", justifyContent: "center", children: [
1290
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Button, { onClick: onCancel, variant: "danger", children: "Annuler" }),
1291
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Button, { variant: "success", onClick: onConfirm, isLoading, children: "Confirmer" })
1422
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Modal, { showModal: isOpen, closeModal: onCancel, width, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(Col, { gap: "16", justifyContent: "center", alignItems: "center", fullWidth: true, children: [
1423
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Row, { gap: "8", justifyContent: "center", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Text, { align: "center", margin: "1em 0", size: "xl", children: "\xCAtes-vous s\xFBr de vouloir faire cette action ?" }) }),
1424
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(Row, { gap: "8", justifyContent: "center", children: [
1425
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Button, { onClick: onCancel, variant: "danger", children: "Annuler" }),
1426
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Button, { variant: "success", onClick: onConfirm, isLoading, children: "Confirmer" })
1292
1427
  ] })
1293
1428
  ] }) });
1294
1429
  };
@@ -1297,8 +1432,8 @@ var ModalConfirmation = (props) => {
1297
1432
  var import_react7 = require("react");
1298
1433
 
1299
1434
  // src/ui-legacy/Components/Bubble/Bubble.tsx
1300
- var import_styled_components11 = __toESM(require("styled-components"));
1301
- var import_jsx_runtime14 = require("react/jsx-runtime");
1435
+ var import_styled_components12 = __toESM(require("styled-components"));
1436
+ var import_jsx_runtime15 = require("react/jsx-runtime");
1302
1437
  var textSizes3 = {
1303
1438
  xxs: ".4em",
1304
1439
  xs: ".6em",
@@ -1318,7 +1453,7 @@ var paddingSizes = {
1318
1453
  xxl: "10px 20px"
1319
1454
  };
1320
1455
  var resolveColor2 = (value, fallback = "transparent") => colors[value] || value || fallback;
1321
- var pulseAnimation = import_styled_components11.keyframes`
1456
+ var pulseAnimation = import_styled_components12.keyframes`
1322
1457
  0% {
1323
1458
  transform: scale(1);
1324
1459
  box-shadow: 0 0 0 0 var(--bubble-pulse-color);
@@ -1345,7 +1480,7 @@ var shouldForwardProp6 = (prop) => ![
1345
1480
  "pulse",
1346
1481
  "pointer"
1347
1482
  ].includes(prop);
1348
- var StyledBubble = import_styled_components11.default.span.withConfig({
1483
+ var StyledBubble = import_styled_components12.default.span.withConfig({
1349
1484
  shouldForwardProp: shouldForwardProp6
1350
1485
  })`
1351
1486
  color: ${(props) => resolveColor2(props.color, "inherit")};
@@ -1362,7 +1497,7 @@ var StyledBubble = import_styled_components11.default.span.withConfig({
1362
1497
  text-overflow: ellipsis;
1363
1498
  max-width: ${(props) => props.maxChars ? `${props.maxChars}ch` : "none"};
1364
1499
  white-space: nowrap;
1365
- ${(props) => props.pulse && import_styled_components11.css`
1500
+ ${(props) => props.pulse && import_styled_components12.css`
1366
1501
  --bubble-pulse-color: ${resolveColor2(
1367
1502
  props.backgroundColor,
1368
1503
  colors.grey_600
@@ -1378,141 +1513,7 @@ var StyledBubble = import_styled_components11.default.span.withConfig({
1378
1513
  `;
1379
1514
  var Bubble = (_a) => {
1380
1515
  var _b = _a, { children } = _b, otherProps = __objRest(_b, ["children"]);
1381
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(StyledBubble, __spreadProps(__spreadValues({}, otherProps), { children }));
1382
- };
1383
-
1384
- // src/ui-legacy/Components/Tooltip/Tooltip.tsx
1385
- var import_react6 = require("react");
1386
- var import_styled_components12 = __toESM(require("styled-components"));
1387
- var import_jsx_runtime15 = require("react/jsx-runtime");
1388
- var StyledTooltipWrapper = import_styled_components12.default.div`
1389
- position: relative;
1390
- display: ${(props) => props.$fullWidth ? "block" : "inline-block"};
1391
- width: ${(props) => props.$fullWidth ? "100%" : "auto"};
1392
- cursor: pointer;
1393
- `;
1394
- var StyledTooltipContent = import_styled_components12.default.div`
1395
- visibility: ${(props) => props.$isVisible ? "visible" : "hidden"};
1396
- background-color: ${(props) => props.$backgroundColor || colors.black};
1397
- color: ${colors.white};
1398
- text-align: center;
1399
- padding: 8px;
1400
- border-radius: 4px;
1401
- position: absolute;
1402
- width: ${(props) => props.$width || "200px"};
1403
- height: ${(props) => props.$height || "auto"};
1404
- opacity: ${(props) => props.$isVisible ? 1 : 0};
1405
- transition: opacity 0.3s;
1406
- z-index: 1;
1407
- display: flex;
1408
- flex-direction: column;
1409
- align-items: center;
1410
- gap: 4px;
1411
-
1412
- ${(props) => {
1413
- switch (props.$direction) {
1414
- case "top":
1415
- return `
1416
- bottom: 125%;
1417
- left: 50%;
1418
- transform: translateX(-50%);
1419
- &::after {
1420
- content: "";
1421
- position: absolute;
1422
- top: 100%;
1423
- left: 50%;
1424
- transform: translateX(-50%);
1425
- border-width: 5px;
1426
- border-style: solid;
1427
- border-color: ${props.$backgroundColor || colors.black} transparent transparent transparent;
1428
- }
1429
- `;
1430
- case "bottom":
1431
- return `
1432
- top: 125%;
1433
- left: 50%;
1434
- transform: translateX(-50%);
1435
- &::after {
1436
- content: "";
1437
- position: absolute;
1438
- bottom: 100%;
1439
- left: 50%;
1440
- transform: translateX(-50%);
1441
- border-width: 5px;
1442
- border-style: solid;
1443
- border-color: transparent transparent ${props.$backgroundColor || colors.black} transparent;
1444
- }
1445
- `;
1446
- case "left":
1447
- return `
1448
- top: 50%;
1449
- right: 125%;
1450
- transform: translateY(-50%);
1451
- &::after {
1452
- content: "";
1453
- position: absolute;
1454
- top: 50%;
1455
- left: 100%;
1456
- transform: translateY(-50%);
1457
- border-width: 5px;
1458
- border-style: solid;
1459
- border-color: transparent transparent transparent ${props.$backgroundColor || colors.black};
1460
- }
1461
- `;
1462
- case "right":
1463
- default:
1464
- return `
1465
- top: 50%;
1466
- left: 125%;
1467
- transform: translateY(-50%);
1468
- &::after {
1469
- content: "";
1470
- position: absolute;
1471
- top: 50%;
1472
- right: 100%;
1473
- transform: translateY(-50%);
1474
- border-width: 5px;
1475
- border-style: solid;
1476
- border-color: transparent ${props.$backgroundColor || colors.black} transparent transparent;
1477
- }
1478
- `;
1479
- }
1480
- }}
1481
- `;
1482
- var Tooltip = ({
1483
- backgroundColor,
1484
- data = [],
1485
- width,
1486
- height,
1487
- direction = "top",
1488
- fullWidth = false,
1489
- children
1490
- }) => {
1491
- const [isVisible, setIsVisible] = (0, import_react6.useState)(false);
1492
- const handleMouseEnter = () => setIsVisible(true);
1493
- const handleMouseLeave = () => setIsVisible(false);
1494
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
1495
- StyledTooltipWrapper,
1496
- {
1497
- $fullWidth: fullWidth,
1498
- onMouseEnter: handleMouseEnter,
1499
- onMouseLeave: handleMouseLeave,
1500
- children: [
1501
- children,
1502
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1503
- StyledTooltipContent,
1504
- {
1505
- $isVisible: isVisible,
1506
- $backgroundColor: backgroundColor,
1507
- $width: width,
1508
- $height: height,
1509
- $direction: direction,
1510
- children: data.length > 0 ? data.map((item, index) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Text, { size: "s", color: "white", children: item }, index)) : /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Text, { size: "s", color: "white", children: "Aucune donn\xE9e" })
1511
- }
1512
- )
1513
- ]
1514
- }
1515
- );
1516
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StyledBubble, __spreadProps(__spreadValues({}, otherProps), { children }));
1516
1517
  };
1517
1518
 
1518
1519
  // src/ui-legacy/Components/NewModal/NewModal.tsx