design-zystem 1.0.234 → 1.0.235
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 +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +8 -10
- package/dist/index.mjs +8 -10
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -510,6 +510,8 @@ interface AccordionProps {
|
|
|
510
510
|
items?: AccordionItem[];
|
|
511
511
|
/** Mode single — titre du panneau */
|
|
512
512
|
title?: ReactNode;
|
|
513
|
+
/** Slot à droite du titre, avant le chevron (badge, action, counter…) */
|
|
514
|
+
titleEnd?: ReactNode;
|
|
513
515
|
/** Mode single — contenu */
|
|
514
516
|
children?: ReactNode;
|
|
515
517
|
defaultOpen?: boolean;
|
|
@@ -527,7 +529,7 @@ interface AccordionProps {
|
|
|
527
529
|
maxHeight?: number;
|
|
528
530
|
backgroundHeader?: keyof typeof colors | string;
|
|
529
531
|
}
|
|
530
|
-
declare const Accordion: ({ items, title, children, defaultOpen, open: controlledOpen, onToggle, openItemId: controlledItemId, onItemToggle, needCheckbox, checkboxValue, onCheck, bordered, disabled, maxHeight, backgroundHeader, }: AccordionProps) => react_jsx_runtime.JSX.Element;
|
|
532
|
+
declare const Accordion: ({ items, title, titleEnd, children, defaultOpen, open: controlledOpen, onToggle, openItemId: controlledItemId, onItemToggle, needCheckbox, checkboxValue, onCheck, bordered, disabled, maxHeight, backgroundHeader, }: AccordionProps) => react_jsx_runtime.JSX.Element;
|
|
531
533
|
|
|
532
534
|
interface ColorPickerProps {
|
|
533
535
|
label?: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -510,6 +510,8 @@ interface AccordionProps {
|
|
|
510
510
|
items?: AccordionItem[];
|
|
511
511
|
/** Mode single — titre du panneau */
|
|
512
512
|
title?: ReactNode;
|
|
513
|
+
/** Slot à droite du titre, avant le chevron (badge, action, counter…) */
|
|
514
|
+
titleEnd?: ReactNode;
|
|
513
515
|
/** Mode single — contenu */
|
|
514
516
|
children?: ReactNode;
|
|
515
517
|
defaultOpen?: boolean;
|
|
@@ -527,7 +529,7 @@ interface AccordionProps {
|
|
|
527
529
|
maxHeight?: number;
|
|
528
530
|
backgroundHeader?: keyof typeof colors | string;
|
|
529
531
|
}
|
|
530
|
-
declare const Accordion: ({ items, title, children, defaultOpen, open: controlledOpen, onToggle, openItemId: controlledItemId, onItemToggle, needCheckbox, checkboxValue, onCheck, bordered, disabled, maxHeight, backgroundHeader, }: AccordionProps) => react_jsx_runtime.JSX.Element;
|
|
532
|
+
declare const Accordion: ({ items, title, titleEnd, children, defaultOpen, open: controlledOpen, onToggle, openItemId: controlledItemId, onItemToggle, needCheckbox, checkboxValue, onCheck, bordered, disabled, maxHeight, backgroundHeader, }: AccordionProps) => react_jsx_runtime.JSX.Element;
|
|
531
533
|
|
|
532
534
|
interface ColorPickerProps {
|
|
533
535
|
label?: string;
|
package/dist/index.js
CHANGED
|
@@ -2758,6 +2758,7 @@ var ContentPadding = import_styled_components21.default.div`
|
|
|
2758
2758
|
var Accordion = ({
|
|
2759
2759
|
items,
|
|
2760
2760
|
title,
|
|
2761
|
+
titleEnd,
|
|
2761
2762
|
children,
|
|
2762
2763
|
defaultOpen = false,
|
|
2763
2764
|
open: controlledOpen,
|
|
@@ -2813,6 +2814,7 @@ var Accordion = ({
|
|
|
2813
2814
|
onClick: () => toggleItem(item.id),
|
|
2814
2815
|
children: [
|
|
2815
2816
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(TriggerRow, { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Text, { size: "s", weight: "600", children: item.title }) }),
|
|
2817
|
+
titleEnd,
|
|
2816
2818
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
|
|
2817
2819
|
Icon,
|
|
2818
2820
|
{
|
|
@@ -2845,6 +2847,7 @@ var Accordion = ({
|
|
|
2845
2847
|
}
|
|
2846
2848
|
),
|
|
2847
2849
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(TriggerRow, { children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Text, { size: "s", weight: "600", children: title }) }),
|
|
2850
|
+
titleEnd,
|
|
2848
2851
|
/* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Icon, { name: isOpen ? "chevron-up" : "chevron-down", size: "m" })
|
|
2849
2852
|
]
|
|
2850
2853
|
}
|
|
@@ -3844,28 +3847,23 @@ var TabButton = import_styled_components38.default.button.withConfig({
|
|
|
3844
3847
|
position: relative;
|
|
3845
3848
|
cursor: ${(p) => p.$disabled ? "not-allowed" : "pointer"};
|
|
3846
3849
|
color: ${(p) => {
|
|
3847
|
-
if (p.$variant === "pills")
|
|
3848
|
-
return p.$active ? colors.grey_600 : colors.grey_500;
|
|
3849
|
-
}
|
|
3850
|
+
if (p.$variant === "pills") return colors.dark;
|
|
3850
3851
|
return p.$active ? colors.blue_700 : colors.grey_400;
|
|
3851
3852
|
}};
|
|
3852
3853
|
font-family: ${TOKENS.fontFamily};
|
|
3853
|
-
font-size: 16px;
|
|
3854
|
+
font-size: ${(p) => p.$variant === "pills" ? "14px" : "16px"};
|
|
3854
3855
|
font-weight: ${(p) => {
|
|
3855
|
-
if (p.$variant === "pills") return
|
|
3856
|
+
if (p.$variant === "pills") return p.$active ? 700 : 500;
|
|
3856
3857
|
return p.$active ? 700 : 600;
|
|
3857
3858
|
}};
|
|
3858
3859
|
line-height: 1.2;
|
|
3859
3860
|
white-space: nowrap;
|
|
3860
3861
|
outline: none;
|
|
3861
3862
|
text-align: center;
|
|
3862
|
-
box-shadow:
|
|
3863
|
+
box-shadow: none;
|
|
3863
3864
|
transition:
|
|
3864
3865
|
background-color 150ms ease,
|
|
3865
|
-
color 150ms ease
|
|
3866
|
-
box-shadow 150ms ease;
|
|
3867
|
-
|
|
3868
|
-
${(p) => p.$variant === "pills" && !p.$active && `&:hover:not(:disabled) { background: ${colors.grey_300}; }`}
|
|
3866
|
+
color 150ms ease;
|
|
3869
3867
|
|
|
3870
3868
|
&:focus-visible {
|
|
3871
3869
|
outline: 2px solid
|
package/dist/index.mjs
CHANGED
|
@@ -2671,6 +2671,7 @@ var ContentPadding = styled21.div`
|
|
|
2671
2671
|
var Accordion = ({
|
|
2672
2672
|
items,
|
|
2673
2673
|
title,
|
|
2674
|
+
titleEnd,
|
|
2674
2675
|
children,
|
|
2675
2676
|
defaultOpen = false,
|
|
2676
2677
|
open: controlledOpen,
|
|
@@ -2726,6 +2727,7 @@ var Accordion = ({
|
|
|
2726
2727
|
onClick: () => toggleItem(item.id),
|
|
2727
2728
|
children: [
|
|
2728
2729
|
/* @__PURE__ */ jsx25(TriggerRow, { children: /* @__PURE__ */ jsx25(Text, { size: "s", weight: "600", children: item.title }) }),
|
|
2730
|
+
titleEnd,
|
|
2729
2731
|
/* @__PURE__ */ jsx25(
|
|
2730
2732
|
Icon,
|
|
2731
2733
|
{
|
|
@@ -2758,6 +2760,7 @@ var Accordion = ({
|
|
|
2758
2760
|
}
|
|
2759
2761
|
),
|
|
2760
2762
|
/* @__PURE__ */ jsx25(TriggerRow, { children: /* @__PURE__ */ jsx25(Text, { size: "s", weight: "600", children: title }) }),
|
|
2763
|
+
titleEnd,
|
|
2761
2764
|
/* @__PURE__ */ jsx25(Icon, { name: isOpen ? "chevron-up" : "chevron-down", size: "m" })
|
|
2762
2765
|
]
|
|
2763
2766
|
}
|
|
@@ -3766,28 +3769,23 @@ var TabButton = styled38.button.withConfig({
|
|
|
3766
3769
|
position: relative;
|
|
3767
3770
|
cursor: ${(p) => p.$disabled ? "not-allowed" : "pointer"};
|
|
3768
3771
|
color: ${(p) => {
|
|
3769
|
-
if (p.$variant === "pills")
|
|
3770
|
-
return p.$active ? colors.grey_600 : colors.grey_500;
|
|
3771
|
-
}
|
|
3772
|
+
if (p.$variant === "pills") return colors.dark;
|
|
3772
3773
|
return p.$active ? colors.blue_700 : colors.grey_400;
|
|
3773
3774
|
}};
|
|
3774
3775
|
font-family: ${TOKENS.fontFamily};
|
|
3775
|
-
font-size: 16px;
|
|
3776
|
+
font-size: ${(p) => p.$variant === "pills" ? "14px" : "16px"};
|
|
3776
3777
|
font-weight: ${(p) => {
|
|
3777
|
-
if (p.$variant === "pills") return
|
|
3778
|
+
if (p.$variant === "pills") return p.$active ? 700 : 500;
|
|
3778
3779
|
return p.$active ? 700 : 600;
|
|
3779
3780
|
}};
|
|
3780
3781
|
line-height: 1.2;
|
|
3781
3782
|
white-space: nowrap;
|
|
3782
3783
|
outline: none;
|
|
3783
3784
|
text-align: center;
|
|
3784
|
-
box-shadow:
|
|
3785
|
+
box-shadow: none;
|
|
3785
3786
|
transition:
|
|
3786
3787
|
background-color 150ms ease,
|
|
3787
|
-
color 150ms ease
|
|
3788
|
-
box-shadow 150ms ease;
|
|
3789
|
-
|
|
3790
|
-
${(p) => p.$variant === "pills" && !p.$active && `&:hover:not(:disabled) { background: ${colors.grey_300}; }`}
|
|
3788
|
+
color 150ms ease;
|
|
3791
3789
|
|
|
3792
3790
|
&:focus-visible {
|
|
3793
3791
|
outline: 2px solid
|