@shoplflow/base 0.32.41 → 0.32.43
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.cjs +263 -122
- package/dist/index.d.cts +8 -1
- package/dist/index.d.ts +8 -1
- package/dist/index.js +266 -125
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -856,6 +856,9 @@ var FooterContainer = styled6__default.default.div`
|
|
|
856
856
|
border-top: 1px solid ${exports.colorTokens.neutral300};
|
|
857
857
|
background: ${exports.colorTokens.neutral0};
|
|
858
858
|
`;
|
|
859
|
+
var BottomContainer = styled6__default.default.footer`
|
|
860
|
+
width: 100%;
|
|
861
|
+
`;
|
|
859
862
|
|
|
860
863
|
// src/components/Modal/Modal.types.ts
|
|
861
864
|
exports.ModalSize = {
|
|
@@ -882,6 +885,27 @@ var useViewportSizeObserver = () => {
|
|
|
882
885
|
}, []);
|
|
883
886
|
return size2;
|
|
884
887
|
};
|
|
888
|
+
var ModalOptionContext = React3.createContext({
|
|
889
|
+
heightToDeduct: 0,
|
|
890
|
+
setHeightToDeduct: utils.noop,
|
|
891
|
+
clearHeightToDeduct: utils.noop
|
|
892
|
+
});
|
|
893
|
+
var ModalOptionContextProvider = ({ children }) => {
|
|
894
|
+
const [heightToDeduct, setHeightToDeduct] = React3.useState(0);
|
|
895
|
+
const controlHeightToDeduct = React3.useCallback((heightToAdd) => {
|
|
896
|
+
setHeightToDeduct((prev) => prev + heightToAdd);
|
|
897
|
+
}, []);
|
|
898
|
+
const clearHeightToDeduct = React3.useCallback(() => {
|
|
899
|
+
setHeightToDeduct(0);
|
|
900
|
+
}, []);
|
|
901
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
902
|
+
ModalOptionContext.Provider,
|
|
903
|
+
{
|
|
904
|
+
value: { heightToDeduct, setHeightToDeduct: controlHeightToDeduct, clearHeightToDeduct },
|
|
905
|
+
children
|
|
906
|
+
}
|
|
907
|
+
);
|
|
908
|
+
};
|
|
885
909
|
var ModalContainer = (_a) => {
|
|
886
910
|
var _b = _a, { children, height, outsideClick = utils.noop } = _b, rest = __objRest(_b, ["children", "height", "outsideClick"]);
|
|
887
911
|
const ref = utils.useParentElementClick(outsideClick);
|
|
@@ -916,7 +940,7 @@ var ModalContainer = (_a) => {
|
|
|
916
940
|
height: heightWidthMargin
|
|
917
941
|
});
|
|
918
942
|
});
|
|
919
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Container, __spreadProps(__spreadValues({ ref }, rest), { height: heightWidthMargin, viewport: windowHeight, "data-shoplflow": "Modal", children: addPropInChildren }));
|
|
943
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container, __spreadProps(__spreadValues({ ref }, rest), { height: heightWidthMargin, viewport: windowHeight, "data-shoplflow": "Modal", children: /* @__PURE__ */ jsxRuntime.jsx(ModalOptionContextProvider, { children: addPropInChildren }) }));
|
|
920
944
|
};
|
|
921
945
|
var ModalContainer_default = ModalContainer;
|
|
922
946
|
var ModalFooter = ({ children }) => {
|
|
@@ -954,6 +978,13 @@ var ScrollArea = React3.forwardRef((_a, ref) => {
|
|
|
954
978
|
) });
|
|
955
979
|
});
|
|
956
980
|
exports.ScrollArea = ScrollArea;
|
|
981
|
+
var useModalOption = () => {
|
|
982
|
+
const context = React3.useContext(ModalOptionContext);
|
|
983
|
+
if (!context) {
|
|
984
|
+
throw new Error(`useModalOption cannot be called outside the ModalOptionProvider`);
|
|
985
|
+
}
|
|
986
|
+
return context;
|
|
987
|
+
};
|
|
957
988
|
var ModalBody = ({
|
|
958
989
|
children,
|
|
959
990
|
isIncludeHeader = false,
|
|
@@ -962,6 +993,7 @@ var ModalBody = ({
|
|
|
962
993
|
height: modalContainerHeight
|
|
963
994
|
}) => {
|
|
964
995
|
const { height: windowHeight } = useViewportSizeObserver();
|
|
996
|
+
const { heightToDeduct } = useModalOption();
|
|
965
997
|
const headerHeight = 64;
|
|
966
998
|
const footerHeight = 72;
|
|
967
999
|
const topBottomMargin = 64;
|
|
@@ -983,11 +1015,11 @@ var ModalBody = ({
|
|
|
983
1015
|
if (modalContainerHeight) {
|
|
984
1016
|
if (modalContainerHeight <= 1200) {
|
|
985
1017
|
if (windowHeight < modalContainerHeight) {
|
|
986
|
-
return windowHeight - topBottomMargin - headerFooterHeight;
|
|
1018
|
+
return windowHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
987
1019
|
}
|
|
988
|
-
return modalContainerHeight - topBottomMargin - headerFooterHeight;
|
|
1020
|
+
return modalContainerHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
989
1021
|
}
|
|
990
|
-
return modalContainerHeight - topBottomMargin - headerFooterHeight;
|
|
1022
|
+
return modalContainerHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
991
1023
|
} else {
|
|
992
1024
|
return "100%";
|
|
993
1025
|
}
|
|
@@ -1014,32 +1046,23 @@ var ModalBody = ({
|
|
|
1014
1046
|
}
|
|
1015
1047
|
return 0;
|
|
1016
1048
|
};
|
|
1017
|
-
const
|
|
1018
|
-
|
|
1019
|
-
autoHeightMax = autoHeightMax - 24;
|
|
1020
|
-
if (isIncludeHeader) {
|
|
1021
|
-
autoHeightMax = autoHeightMax - 24;
|
|
1022
|
-
}
|
|
1023
|
-
if (!isIncludeHeader) {
|
|
1024
|
-
autoHeightMax = autoHeightMax - 16;
|
|
1025
|
-
}
|
|
1026
|
-
return autoHeightMax;
|
|
1027
|
-
};
|
|
1049
|
+
const autoHeightMin = setAutoHeightMin();
|
|
1050
|
+
const _autoHeightMin = typeof autoHeightMin === "string" ? autoHeightMin : autoHeightMin - heightToDeduct;
|
|
1028
1051
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1029
1052
|
BodyContainer,
|
|
1030
1053
|
{
|
|
1031
1054
|
isIncludeHeader,
|
|
1032
1055
|
sizeVar,
|
|
1033
|
-
minHeight:
|
|
1034
|
-
maxHeight: setAutoHeightMax(),
|
|
1056
|
+
minHeight: _autoHeightMin,
|
|
1057
|
+
maxHeight: setAutoHeightMax() - heightToDeduct,
|
|
1035
1058
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1036
1059
|
exports.ScrollArea,
|
|
1037
1060
|
{
|
|
1038
1061
|
id: `scrollbar`,
|
|
1039
1062
|
universal: true,
|
|
1040
1063
|
autoHeight: !modalContainerHeight,
|
|
1041
|
-
autoHeightMin:
|
|
1042
|
-
autoHeightMax:
|
|
1064
|
+
autoHeightMin: _autoHeightMin,
|
|
1065
|
+
autoHeightMax: "100%",
|
|
1043
1066
|
style: {},
|
|
1044
1067
|
children: /* @__PURE__ */ jsxRuntime.jsx(ModalBodyContainerInner, { children: /* @__PURE__ */ jsxRuntime.jsx(ModalBodyContent, { isIncludeHeader, sizeVar, children }) })
|
|
1045
1068
|
}
|
|
@@ -1053,6 +1076,33 @@ var ModalHeader = ({ children }) => {
|
|
|
1053
1076
|
};
|
|
1054
1077
|
ModalHeader[exports.MODAL_HEADER_KEY] = true;
|
|
1055
1078
|
var ModalHeader_default = ModalHeader;
|
|
1079
|
+
var ModalTop = ({ children }) => {
|
|
1080
|
+
const [topRef, setTopRef] = React3.useState(null);
|
|
1081
|
+
const { setHeightToDeduct, clearHeightToDeduct } = useModalOption();
|
|
1082
|
+
React3.useEffect(() => {
|
|
1083
|
+
if (!topRef) {
|
|
1084
|
+
return;
|
|
1085
|
+
}
|
|
1086
|
+
const { height } = topRef.getBoundingClientRect();
|
|
1087
|
+
setHeightToDeduct == null ? void 0 : setHeightToDeduct(height);
|
|
1088
|
+
return () => clearHeightToDeduct();
|
|
1089
|
+
}, [topRef, setHeightToDeduct, clearHeightToDeduct]);
|
|
1090
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { ref: setTopRef, children });
|
|
1091
|
+
};
|
|
1092
|
+
var ModalTop_default = ModalTop;
|
|
1093
|
+
var ModalBottom = ({ children }) => {
|
|
1094
|
+
const [bottomRef, setBottomRef] = React3.useState(null);
|
|
1095
|
+
const { setHeightToDeduct, clearHeightToDeduct } = useModalOption();
|
|
1096
|
+
React3.useEffect(() => {
|
|
1097
|
+
if (!bottomRef) {
|
|
1098
|
+
return;
|
|
1099
|
+
}
|
|
1100
|
+
const { height } = bottomRef.getBoundingClientRect();
|
|
1101
|
+
setHeightToDeduct == null ? void 0 : setHeightToDeduct(height);
|
|
1102
|
+
return () => clearHeightToDeduct();
|
|
1103
|
+
}, [bottomRef, setHeightToDeduct, clearHeightToDeduct]);
|
|
1104
|
+
return /* @__PURE__ */ jsxRuntime.jsx(BottomContainer, { ref: setBottomRef, children });
|
|
1105
|
+
};
|
|
1056
1106
|
exports.ModalHandlerContext = React3.createContext({
|
|
1057
1107
|
addModal: utils.noop,
|
|
1058
1108
|
removeModal: utils.noop
|
|
@@ -1147,7 +1197,9 @@ var ModalProvider_default = ModalProvider;
|
|
|
1147
1197
|
exports.Modal = {
|
|
1148
1198
|
Container: ModalContainer_default,
|
|
1149
1199
|
Header: ModalHeader_default,
|
|
1200
|
+
Top: ModalTop_default,
|
|
1150
1201
|
Body: ModalBody_default,
|
|
1202
|
+
Bottom: ModalBottom,
|
|
1151
1203
|
Footer: ModalFooter_default
|
|
1152
1204
|
};
|
|
1153
1205
|
var SwitchContainer = styled6__default.default.div`
|
|
@@ -2763,9 +2815,30 @@ exports.CalloutTypes = {
|
|
|
2763
2815
|
INFORMATION: "INFORMATION",
|
|
2764
2816
|
ALERT: "ALERT"
|
|
2765
2817
|
};
|
|
2818
|
+
var StyledDropdown = styled6__default.default.div`
|
|
2819
|
+
width: ${({ width }) => width};
|
|
2820
|
+
`;
|
|
2821
|
+
var StyledDropdownContent = styled6__default.default.div`
|
|
2822
|
+
display: flex;
|
|
2823
|
+
flex-direction: column;
|
|
2824
|
+
background: ${exports.colorTokens.neutral0};
|
|
2825
|
+
width: ${({ width }) => width != null ? width : "240px"};
|
|
2826
|
+
padding: 4px;
|
|
2827
|
+
border-radius: 6px;
|
|
2828
|
+
box-shadow: ${exports.boxShadowTokens.dropShadow};
|
|
2829
|
+
`;
|
|
2830
|
+
var DropdownContext = React3.createContext(null);
|
|
2831
|
+
var useDropdown = () => {
|
|
2832
|
+
const context = React3.useContext(DropdownContext);
|
|
2833
|
+
if (context === null) {
|
|
2834
|
+
throw new Error("useDropdown must be used within a DropdownProvider");
|
|
2835
|
+
}
|
|
2836
|
+
return context;
|
|
2837
|
+
};
|
|
2766
2838
|
var getDropdownHeightBySizeVar = (size2) => {
|
|
2767
2839
|
switch (size2) {
|
|
2768
2840
|
case "M":
|
|
2841
|
+
case "L":
|
|
2769
2842
|
return "40px";
|
|
2770
2843
|
case "S":
|
|
2771
2844
|
return "32px";
|
|
@@ -2775,6 +2848,8 @@ var getDropdownHeightBySizeVar = (size2) => {
|
|
|
2775
2848
|
};
|
|
2776
2849
|
var getDropdownFontSizeBySizeVar = (size2) => {
|
|
2777
2850
|
switch (size2) {
|
|
2851
|
+
case "L":
|
|
2852
|
+
return "body2_700";
|
|
2778
2853
|
case "M":
|
|
2779
2854
|
return "body1_400";
|
|
2780
2855
|
case "S":
|
|
@@ -2785,12 +2860,20 @@ var getDropdownFontSizeBySizeVar = (size2) => {
|
|
|
2785
2860
|
};
|
|
2786
2861
|
var getDropdownStyleBySizeVar = (size2) => {
|
|
2787
2862
|
switch (size2) {
|
|
2863
|
+
case "L":
|
|
2864
|
+
return react$1.css`
|
|
2865
|
+
background-color: transparent;
|
|
2866
|
+
padding: 8px 4px 8px 12px;
|
|
2867
|
+
`;
|
|
2788
2868
|
case "M":
|
|
2789
2869
|
return react$1.css`
|
|
2870
|
+
background-color: ${exports.colorTokens.neutral0};
|
|
2871
|
+
gap: 4px;
|
|
2790
2872
|
padding: 4px 4px 4px 12px;
|
|
2791
2873
|
`;
|
|
2792
2874
|
case "S":
|
|
2793
2875
|
return react$1.css`
|
|
2876
|
+
background-color: ${exports.colorTokens.neutral0};
|
|
2794
2877
|
padding: 4px 4px 4px 8px;
|
|
2795
2878
|
gap: 4px;
|
|
2796
2879
|
`;
|
|
@@ -2800,22 +2883,24 @@ var getDropdownStyleBySizeVar = (size2) => {
|
|
|
2800
2883
|
`;
|
|
2801
2884
|
}
|
|
2802
2885
|
};
|
|
2886
|
+
var getDisabledStyle2 = (disabled) => {
|
|
2887
|
+
if (disabled) {
|
|
2888
|
+
return react$1.css`
|
|
2889
|
+
opacity: 50%;
|
|
2890
|
+
cursor: not-allowed;
|
|
2891
|
+
`;
|
|
2892
|
+
}
|
|
2893
|
+
};
|
|
2803
2894
|
var getDropdownIconSizeBySizeVar = (size2) => {
|
|
2804
2895
|
switch (size2) {
|
|
2805
2896
|
case "S":
|
|
2897
|
+
case "L":
|
|
2806
2898
|
return react$1.css`
|
|
2807
2899
|
height: 24px;
|
|
2808
2900
|
width: 24px;
|
|
2809
2901
|
min-width: 24px;
|
|
2810
2902
|
min-height: 24px;
|
|
2811
2903
|
`;
|
|
2812
|
-
case "M":
|
|
2813
|
-
return react$1.css`
|
|
2814
|
-
height: 32px;
|
|
2815
|
-
width: 32px;
|
|
2816
|
-
min-width: 32px;
|
|
2817
|
-
min-height: 32px;
|
|
2818
|
-
`;
|
|
2819
2904
|
default:
|
|
2820
2905
|
return react$1.css`
|
|
2821
2906
|
height: 32px;
|
|
@@ -2825,49 +2910,6 @@ var getDropdownIconSizeBySizeVar = (size2) => {
|
|
|
2825
2910
|
`;
|
|
2826
2911
|
}
|
|
2827
2912
|
};
|
|
2828
|
-
var StyledDropdown = styled6__default.default.div`
|
|
2829
|
-
width: ${({ width }) => width};
|
|
2830
|
-
`;
|
|
2831
|
-
var StyledDropdownContent = styled6__default.default.div`
|
|
2832
|
-
display: flex;
|
|
2833
|
-
flex-direction: column;
|
|
2834
|
-
background: ${exports.colorTokens.neutral0};
|
|
2835
|
-
width: ${({ width }) => width != null ? width : "240px"};
|
|
2836
|
-
padding: 4px;
|
|
2837
|
-
border-radius: 6px;
|
|
2838
|
-
box-shadow: ${exports.boxShadowTokens.dropShadow};
|
|
2839
|
-
`;
|
|
2840
|
-
var StyledDropdownButton = styled6__default.default.button`
|
|
2841
|
-
display: flex;
|
|
2842
|
-
flex-direction: row;
|
|
2843
|
-
align-items: center;
|
|
2844
|
-
justify-content: space-between;
|
|
2845
|
-
width: 100%;
|
|
2846
|
-
height: 100%;
|
|
2847
|
-
gap: 8px;
|
|
2848
|
-
cursor: pointer;
|
|
2849
|
-
background-color: ${exports.colorTokens.neutral0};
|
|
2850
|
-
${({ sizeVar }) => sizeVar && getDropdownStyleBySizeVar(sizeVar)};
|
|
2851
|
-
${({ disabled }) => disabled && react$1.css`
|
|
2852
|
-
background-color: ${exports.colorTokens.neutral100};
|
|
2853
|
-
cursor: not-allowed;
|
|
2854
|
-
`}
|
|
2855
|
-
`;
|
|
2856
|
-
var DropdownButtonIcon = styled6__default.default(framerMotion.motion.div)`
|
|
2857
|
-
display: flex;
|
|
2858
|
-
align-items: center;
|
|
2859
|
-
justify-content: center;
|
|
2860
|
-
|
|
2861
|
-
${({ sizeVar }) => sizeVar && getDropdownIconSizeBySizeVar(sizeVar)};
|
|
2862
|
-
`;
|
|
2863
|
-
var DropdownContext = React3.createContext(null);
|
|
2864
|
-
var useDropdown = () => {
|
|
2865
|
-
const context = React3.useContext(DropdownContext);
|
|
2866
|
-
if (context === null) {
|
|
2867
|
-
throw new Error("useDropdown must be used within a DropdownProvider");
|
|
2868
|
-
}
|
|
2869
|
-
return context;
|
|
2870
|
-
};
|
|
2871
2913
|
var getBorderColorByStatus = ({ isFocused, isError, isHovered, disabled }) => {
|
|
2872
2914
|
if (!disabled) {
|
|
2873
2915
|
if (isError) {
|
|
@@ -2882,60 +2924,72 @@ var getBorderColorByStatus = ({ isFocused, isError, isHovered, disabled }) => {
|
|
|
2882
2924
|
}
|
|
2883
2925
|
return exports.colorTokens.neutral300;
|
|
2884
2926
|
};
|
|
2927
|
+
var getButtoWrapperStyleBySizeVar = (sizeVar) => {
|
|
2928
|
+
switch (sizeVar) {
|
|
2929
|
+
case "L":
|
|
2930
|
+
return react$1.css`
|
|
2931
|
+
background-color: transparent;
|
|
2932
|
+
border-width: 2px;
|
|
2933
|
+
border-radius: 12px;
|
|
2934
|
+
`;
|
|
2935
|
+
default:
|
|
2936
|
+
return react$1.css`
|
|
2937
|
+
background-color: ${exports.colorTokens.neutral0};
|
|
2938
|
+
border-width: 1px;
|
|
2939
|
+
border-radius: 6px;
|
|
2940
|
+
`;
|
|
2941
|
+
}
|
|
2942
|
+
};
|
|
2885
2943
|
var getStyleByType = ({
|
|
2886
|
-
type,
|
|
2887
2944
|
height,
|
|
2888
|
-
|
|
2889
|
-
maxHeight,
|
|
2890
|
-
width,
|
|
2891
|
-
minWidth,
|
|
2892
|
-
maxWidth,
|
|
2893
|
-
borderRadius,
|
|
2894
|
-
customNumberInputHeight
|
|
2945
|
+
width
|
|
2895
2946
|
}) => {
|
|
2896
|
-
if (type === "number") {
|
|
2897
|
-
return react$1.css`
|
|
2898
|
-
width: ${width || "64px"};
|
|
2899
|
-
height: ${customNumberInputHeight || "32px"};
|
|
2900
|
-
border-radius: ${borderRadius ? exports.borderRadiusTokens[borderRadius] : "6px"};
|
|
2901
|
-
`;
|
|
2902
|
-
}
|
|
2903
2947
|
return react$1.css`
|
|
2904
2948
|
width: ${width || "100%"};
|
|
2905
|
-
min-width: ${minWidth || "initial"};
|
|
2906
|
-
max-width: ${maxWidth || "initial"};
|
|
2907
2949
|
height: ${height || "initial"};
|
|
2908
|
-
min-height: ${minHeight || "initial"};
|
|
2909
|
-
max-height: ${maxHeight || "initial"};
|
|
2910
|
-
border-radius: ${borderRadius ? exports.borderRadiusTokens[borderRadius] : "6px"};
|
|
2911
2950
|
`;
|
|
2912
2951
|
};
|
|
2913
|
-
var
|
|
2952
|
+
var StyledDropdownButtonWrapper = styled6__default.default.label`
|
|
2914
2953
|
position: relative;
|
|
2915
2954
|
display: flex;
|
|
2916
2955
|
align-items: center;
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2956
|
+
flex-direction: row;
|
|
2957
|
+
min-height: initial;
|
|
2958
|
+
max-height: initial;
|
|
2959
|
+
min-width: initial;
|
|
2960
|
+
max-width: initial;
|
|
2961
|
+
${({ height, width }) => getStyleByType({
|
|
2922
2962
|
height,
|
|
2923
|
-
|
|
2924
|
-
maxHeight,
|
|
2925
|
-
width,
|
|
2926
|
-
maxWidth,
|
|
2927
|
-
minWidth,
|
|
2928
|
-
borderRadius
|
|
2963
|
+
width
|
|
2929
2964
|
})};
|
|
2930
2965
|
justify-content: space-between;
|
|
2931
|
-
|
|
2932
|
-
border:
|
|
2933
|
-
|
|
2966
|
+
border-color: ${(props) => getBorderColorByStatus(props)};
|
|
2967
|
+
border-style: solid;
|
|
2968
|
+
${({ sizeVar }) => getButtoWrapperStyleBySizeVar(sizeVar)};
|
|
2969
|
+
|
|
2934
2970
|
overflow: hidden;
|
|
2935
|
-
${({ disabled }) => disabled
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2971
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2972
|
+
`;
|
|
2973
|
+
var StyledDropdownButton = styled6__default.default.button`
|
|
2974
|
+
display: flex;
|
|
2975
|
+
flex-direction: row;
|
|
2976
|
+
align-items: center;
|
|
2977
|
+
justify-content: space-between;
|
|
2978
|
+
width: 100%;
|
|
2979
|
+
height: 100%;
|
|
2980
|
+
|
|
2981
|
+
cursor: pointer;
|
|
2982
|
+
${({ sizeVar }) => sizeVar && getDropdownStyleBySizeVar(sizeVar)};
|
|
2983
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2984
|
+
`;
|
|
2985
|
+
var DropdownButtonIcon = styled6__default.default(framerMotion.motion.div)`
|
|
2986
|
+
display: flex;
|
|
2987
|
+
align-items: center;
|
|
2988
|
+
justify-content: center;
|
|
2989
|
+
flex-shrink: 0;
|
|
2990
|
+
|
|
2991
|
+
${({ sizeVar }) => sizeVar && getDropdownIconSizeBySizeVar(sizeVar)};
|
|
2992
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2939
2993
|
`;
|
|
2940
2994
|
var DropdownTriggerButton = React3.forwardRef(
|
|
2941
2995
|
(_a, ref) => {
|
|
@@ -2963,8 +3017,9 @@ var DropdownTriggerButton = React3.forwardRef(
|
|
|
2963
3017
|
}
|
|
2964
3018
|
return "neutral700";
|
|
2965
3019
|
};
|
|
3020
|
+
const LeftSourceClone = leftSource ? React3.cloneElement(leftSource, __spreadProps(__spreadValues({}, leftSource.props), { disabled })) : leftSource;
|
|
2966
3021
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2967
|
-
|
|
3022
|
+
StyledDropdownButtonWrapper,
|
|
2968
3023
|
{
|
|
2969
3024
|
onMouseEnter: handleOnMouseEnter,
|
|
2970
3025
|
onMouseLeave: handleOnMouseLeave,
|
|
@@ -2973,19 +3028,22 @@ var DropdownTriggerButton = React3.forwardRef(
|
|
|
2973
3028
|
disabled,
|
|
2974
3029
|
width,
|
|
2975
3030
|
isError,
|
|
3031
|
+
sizeVar,
|
|
2976
3032
|
height: getDropdownHeightBySizeVar(sizeVar),
|
|
2977
3033
|
children: /* @__PURE__ */ jsxRuntime.jsxs(StyledDropdownButton, __spreadProps(__spreadValues({ ref, onClick: handleOnClick, disabled }, rest), { sizeVar, children: [
|
|
2978
|
-
|
|
2979
|
-
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
2985
|
-
|
|
2986
|
-
|
|
2987
|
-
|
|
2988
|
-
|
|
3034
|
+
/* @__PURE__ */ jsxRuntime.jsxs(exports.Stack.Horizontal, { width: "100%", spacing: sizeVar === "L" ? "spacing04" : void 0, align: "center", children: [
|
|
3035
|
+
LeftSourceClone && LeftSourceClone,
|
|
3036
|
+
value || /* @__PURE__ */ jsxRuntime.jsx(
|
|
3037
|
+
exports.Text,
|
|
3038
|
+
{
|
|
3039
|
+
typography: getDropdownFontSizeBySizeVar(sizeVar),
|
|
3040
|
+
color: getTextColor({ value, disabled }),
|
|
3041
|
+
textOverflow: "ellipsis",
|
|
3042
|
+
lineClamp: 1,
|
|
3043
|
+
children: placeholder
|
|
3044
|
+
}
|
|
3045
|
+
)
|
|
3046
|
+
] }),
|
|
2989
3047
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2990
3048
|
DropdownButtonIcon,
|
|
2991
3049
|
{
|
|
@@ -2996,7 +3054,14 @@ var DropdownTriggerButton = React3.forwardRef(
|
|
|
2996
3054
|
transition: {
|
|
2997
3055
|
duration: 0.2
|
|
2998
3056
|
},
|
|
2999
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3057
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3058
|
+
exports.Icon,
|
|
3059
|
+
{
|
|
3060
|
+
iconSource: ShoplAssets.DownArrowSolidXsmallIcon,
|
|
3061
|
+
color: sizeVar === "L" ? "neutral700" : "neutral400",
|
|
3062
|
+
sizeVar: "XS"
|
|
3063
|
+
}
|
|
3064
|
+
)
|
|
3000
3065
|
}
|
|
3001
3066
|
)
|
|
3002
3067
|
] }))
|
|
@@ -3043,7 +3108,7 @@ var Dropdown = ({
|
|
|
3043
3108
|
height: triggerRef.offsetHeight
|
|
3044
3109
|
});
|
|
3045
3110
|
}
|
|
3046
|
-
}, [triggerRef]);
|
|
3111
|
+
}, [triggerRef, width]);
|
|
3047
3112
|
React3.useEffect(() => {
|
|
3048
3113
|
if (initialIsOpen === void 0) {
|
|
3049
3114
|
return;
|
|
@@ -3067,6 +3132,13 @@ var Dropdown = ({
|
|
|
3067
3132
|
Dropdown.Button = DropdownTriggerButton;
|
|
3068
3133
|
Dropdown.Content = DropdownContent;
|
|
3069
3134
|
exports.Dropdown = Dropdown;
|
|
3135
|
+
|
|
3136
|
+
// src/components/Dropdown/Dropdown.types.ts
|
|
3137
|
+
exports.DropdownOptionVariants = {
|
|
3138
|
+
CLICK: "CLICK",
|
|
3139
|
+
OUTSIDE_CLICK: "OUTSIDE_CLICK",
|
|
3140
|
+
NONE: "NONE"
|
|
3141
|
+
};
|
|
3070
3142
|
var StyledList = styled6__default.default.li`
|
|
3071
3143
|
display: flex;
|
|
3072
3144
|
flex-direction: row;
|
|
@@ -3454,6 +3526,75 @@ var assetFunction = (iconName, domainProps) => {
|
|
|
3454
3526
|
const ShoplIcon = ShoplAssets__namespace[iconName];
|
|
3455
3527
|
return domain === "hada" ? HadaIcon : ShoplIcon;
|
|
3456
3528
|
};
|
|
3529
|
+
var getBorderColorByStatus2 = ({ isFocused, isError, isHovered, disabled }) => {
|
|
3530
|
+
if (!disabled) {
|
|
3531
|
+
if (isError) {
|
|
3532
|
+
return exports.colorTokens.red300;
|
|
3533
|
+
}
|
|
3534
|
+
if (isFocused) {
|
|
3535
|
+
return exports.colorTokens.primary300;
|
|
3536
|
+
}
|
|
3537
|
+
if (isHovered) {
|
|
3538
|
+
return exports.colorTokens.neutral700;
|
|
3539
|
+
}
|
|
3540
|
+
}
|
|
3541
|
+
return exports.colorTokens.neutral300;
|
|
3542
|
+
};
|
|
3543
|
+
var getStyleByType2 = ({
|
|
3544
|
+
type,
|
|
3545
|
+
height,
|
|
3546
|
+
minHeight,
|
|
3547
|
+
maxHeight,
|
|
3548
|
+
width,
|
|
3549
|
+
minWidth,
|
|
3550
|
+
maxWidth,
|
|
3551
|
+
borderRadius,
|
|
3552
|
+
customNumberInputHeight
|
|
3553
|
+
}) => {
|
|
3554
|
+
if (type === "number") {
|
|
3555
|
+
return react$1.css`
|
|
3556
|
+
width: ${width || "64px"};
|
|
3557
|
+
height: ${customNumberInputHeight || "32px"};
|
|
3558
|
+
border-radius: ${borderRadius ? exports.borderRadiusTokens[borderRadius] : "6px"};
|
|
3559
|
+
`;
|
|
3560
|
+
}
|
|
3561
|
+
return react$1.css`
|
|
3562
|
+
width: ${width || "100%"};
|
|
3563
|
+
min-width: ${minWidth || "initial"};
|
|
3564
|
+
max-width: ${maxWidth || "initial"};
|
|
3565
|
+
height: ${height || "initial"};
|
|
3566
|
+
min-height: ${minHeight || "initial"};
|
|
3567
|
+
max-height: ${maxHeight || "initial"};
|
|
3568
|
+
border-radius: ${borderRadius ? exports.borderRadiusTokens[borderRadius] : "6px"};
|
|
3569
|
+
`;
|
|
3570
|
+
};
|
|
3571
|
+
var InputWrapper = styled6__default.default.label`
|
|
3572
|
+
position: relative;
|
|
3573
|
+
display: flex;
|
|
3574
|
+
align-items: center;
|
|
3575
|
+
border-radius: 6px;
|
|
3576
|
+
flex-direction: ${({ direction }) => direction || "row"};
|
|
3577
|
+
${({ type, height, minHeight, maxHeight, width, maxWidth, minWidth, borderRadius, customNumberInputHeight }) => getStyleByType2({
|
|
3578
|
+
customNumberInputHeight,
|
|
3579
|
+
type,
|
|
3580
|
+
height,
|
|
3581
|
+
minHeight,
|
|
3582
|
+
maxHeight,
|
|
3583
|
+
width,
|
|
3584
|
+
maxWidth,
|
|
3585
|
+
minWidth,
|
|
3586
|
+
borderRadius
|
|
3587
|
+
})};
|
|
3588
|
+
justify-content: space-between;
|
|
3589
|
+
gap: ${({ gap }) => gap || "8px"};
|
|
3590
|
+
border: 1px solid ${(props) => getBorderColorByStatus2(props)};
|
|
3591
|
+
background-color: ${exports.colorTokens.neutral0};
|
|
3592
|
+
overflow: hidden;
|
|
3593
|
+
${({ disabled }) => disabled && react$1.css`
|
|
3594
|
+
background-color: ${exports.colorTokens.neutral100};
|
|
3595
|
+
cursor: not-allowed;
|
|
3596
|
+
`};
|
|
3597
|
+
`;
|
|
3457
3598
|
|
|
3458
3599
|
// src/components/Inputs/Input/utils/getNumberLimiteRange.ts
|
|
3459
3600
|
var getNumberLimitRange = (value, min, max) => {
|
package/dist/index.d.cts
CHANGED
|
@@ -504,6 +504,10 @@ declare const MODAL_FOOTER_KEY: unique symbol;
|
|
|
504
504
|
interface ModalFooterType extends React.FC<ModalBodyProps> {
|
|
505
505
|
[MODAL_FOOTER_KEY]?: boolean;
|
|
506
506
|
}
|
|
507
|
+
interface ModalTopProps extends ChildrenProps {
|
|
508
|
+
}
|
|
509
|
+
interface ModalBottomProps extends ChildrenProps {
|
|
510
|
+
}
|
|
507
511
|
|
|
508
512
|
declare type ModalStateType = {
|
|
509
513
|
component: ReactNode;
|
|
@@ -537,7 +541,9 @@ declare const useHandleModal: () => {
|
|
|
537
541
|
declare const Modal: {
|
|
538
542
|
Container: ({ children, height, outsideClick, ...rest }: ModalContainerProps) => react_jsx_runtime.JSX.Element;
|
|
539
543
|
Header: ModalHeaderType;
|
|
544
|
+
Top: ({ children }: ModalTopProps) => react_jsx_runtime.JSX.Element;
|
|
540
545
|
Body: ({ children, isIncludeHeader, isIncludeFooter, sizeVar, height: modalContainerHeight, }: ModalBodyProps) => react_jsx_runtime.JSX.Element;
|
|
546
|
+
Bottom: ({ children }: ModalBottomProps) => react_jsx_runtime.JSX.Element;
|
|
541
547
|
Footer: ModalFooterType;
|
|
542
548
|
};
|
|
543
549
|
|
|
@@ -943,6 +949,7 @@ interface DropdownContentProps extends HTMLAttributes<HTMLDivElement>, ChildrenP
|
|
|
943
949
|
declare const dropdownSizeVariants: {
|
|
944
950
|
readonly S: "S";
|
|
945
951
|
readonly M: "M";
|
|
952
|
+
readonly L: "L";
|
|
946
953
|
};
|
|
947
954
|
declare type DropdownSizeVariantType = $Values<typeof dropdownSizeVariants>;
|
|
948
955
|
interface DropdownTriggerButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'value'>, DisableProps, LeftElementProps, SizeVariantProps<DropdownSizeVariantType> {
|
|
@@ -1524,4 +1531,4 @@ declare type NumberComboboxProps = NumberComboboxOptionProps & Omit<InputHTMLAtt
|
|
|
1524
1531
|
|
|
1525
1532
|
declare const NumberCombobox: ({ disabled, onSelect, onChange, value, width, onBlur, items, isError, sizeVar, placeholder, maxLength, className, floatingZIndex, ...rest }: NumberComboboxProps) => react_jsx_runtime.JSX.Element;
|
|
1526
1533
|
|
|
1527
|
-
export { AnnualDatepicker, AnnualDatepickerProps, AsProp, Avatar, AvatarOptionProps, AvatarProps, AvatarSizeVariantType, AvatarSizeVariants, BackDropOptionProps, BackDropProps, BorderRadiusTokens, BoxShadowTokens, Button, ButtonComponent, ButtonOptionProps, ButtonProps, ButtonSizeVariantType, ButtonSizeVariants, ButtonStyleVariantType, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout, CalloutOptionProps, CalloutProps, CalloutType, CalloutTypes, Checkbox, CheckboxOptionProps, CheckboxProps, CheckboxStyleVariantType, CheckboxStyleVariants, ChipButton, ChipButtonOptionProps, ChipButtonProps, ChipButtonSizeVariantType, ChipButtonSizeVariants, ChipButtonStyleVariantType, ChipButtonStyleVariants, ChipToggle, ChipToggleOptionProps, ChipToggleProps, ChipToggleSizeVariantType, ChipToggleSizeVariants, ChipToggleStyleVariantType, ChipToggleStyleVariants, ColorTokens, DangerouslySetInnerHTML, DayCalendarType, DayDatepicker, DayDatepickerHeaderCustomProps, DayDatepickerOptionProps, DayDatepickerProps, DayDatepickerSizeVariantType, DayDatepickerSizeVariants, DomainType, Dropdown, DropdownButton, DropdownButtonContext, DropdownButtonContextType, DropdownButtonOptionProps, DropdownButtonProps, DropdownButtonSizeVariantType, DropdownButtonSizeVariants, DropdownButtonStyleVariantType, DropdownButtonStyleVariants, DropdownContentProps, DropdownOptionProps, DropdownOptionVariantType, DropdownProps, DropdownSizeVariantType, DropdownTriggerButtonProps, FontWeightTokens, Icon, IconButton, IconButtonComponent, IconButtonOptionProps, IconButtonProps, IconButtonSizeVariantType, IconButtonSizeVariants, IconButtonStyleVariantType, IconButtonStyleVariants, IconOptionProps, IconProps, IconSizeVariants, IconSizeVariantsType, Input, InputButton, InputButtonOptionProps, InputButtonProps, InputOptionProps, InputProps, InputSizeVariantType, InputSizeVariants, List, ListContent2ColumnsProps, ListOptionProps, ListProps, ListText2RowsProps, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu, MenuOptionProps, MenuProps, MenuSizeVariantType, MenuSizeVariants, MinusBoxOptionProps, MinusBoxProps, MinusButton, Modal, ModalBodyOptionProps, ModalBodyProps, ModalContainerOptionProps, ModalContainerProps, ModalContext, ModalFooterOptionProps, ModalFooterProps, ModalFooterType, ModalHandlerContext, ModalHeaderOptionProps, ModalHeaderProps, ModalHeaderType, ModalPortal as ModalProvider, ModalSize, ModalSizeType, ModalStateType, MonthClickDateInfo, MonthDatepicker, MonthDatepickerProps, MonthDatepickerStyleType, MotionStack, MotionStackComponentType, MotionStackContainer, MotionStackContainerComponentType, NumberCombobox, NumberComboboxErrorType, NumberComboboxInputType, NumberComboboxOptionProps, NumberComboboxProps, NumberComboboxSizeVariantType, NumberComboboxSizeVariants, Pagination, PaginationOptionProps, PaginationProps, PaginationSizeSelectorProps, PolymorphicComponentProps, PolymorphicRef, Popper, PopperOptionProps, PopperPortal, PopperPortalProps, PopperProps, PopperTrigger, PopperTriggerProps, RADIO_SYMBOL_KEY, Radio, RadioOptionProps, RadioProps, RemoveModalProps, ScrollArea, ScrollAreaOptionProps, ScrollAreaProps, ScrollbarRefType, SelectInputButton, SelectInputButtonOptionProps, SelectInputButtonProps, ShoplflowProvider, ShoplflowProviderProps, SpacingTokens, SplitButton, SplitButtonContext, SplitButtonContextType, SplitButtonOptionProps, SplitButtonProps, SplitButtonSizeVariantType, SplitButtonSizeVariants, SplitButtonStyleVariantType, SplitButtonStyleVariants, Stack, StackComponentType, StackContainer, StackContainerComponentType, StackContainerGenericProps, StackContainerOptionProps, StackContainerProps, StackGenericProps, StackOptionProps, StackProps, StyledIcon, StyledStack, StyledStackContainer, Switch, SwitchOptionProps, SwitchProps, TREE_SYMBOL_KEY, TabOptionProps, TabProps, TabSizeVariantType, TabSizeVariants, TabStyleVariantType, TabStyleVariants, TabStyledProps, TabTextStyledProps, Tabs, TabsContext, TabsContextType, TabsOptionProps, TabsProps, Tag, TagOptionProps, TagProps, TagSizeVariantType, TagSizeVariants, TagStyleVariantType, TagStyleVariants, Text, Text2Rows, TextArea, TextAreaOptionProps, TextAreaProps, TextOptionProps, TextProps, ToggleButton, ToggleButtonInnerRadioOptionProps, ToggleButtonInnerRadioProps, ToggleButtonOptionProps, ToggleButtonProps, ToggleButtonSizeVariantType, ToggleButtonSizeVariants, Tooltip, TooltipContentProps, TooltipOptionProps, TooltipProps, Tree, TreeItem, TreeItemOptionProps, TreeItemProps, TreeOptionProps, TreeProps, TypographyTokens, WeekClickDateInfo, WeekDatepicker, WeekDatepickerProps, WeekDatepickerStyleType, YearSelectProps, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|
|
1534
|
+
export { AnnualDatepicker, AnnualDatepickerProps, AsProp, Avatar, AvatarOptionProps, AvatarProps, AvatarSizeVariantType, AvatarSizeVariants, BackDropOptionProps, BackDropProps, BorderRadiusTokens, BoxShadowTokens, Button, ButtonComponent, ButtonOptionProps, ButtonProps, ButtonSizeVariantType, ButtonSizeVariants, ButtonStyleVariantType, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout, CalloutOptionProps, CalloutProps, CalloutType, CalloutTypes, Checkbox, CheckboxOptionProps, CheckboxProps, CheckboxStyleVariantType, CheckboxStyleVariants, ChipButton, ChipButtonOptionProps, ChipButtonProps, ChipButtonSizeVariantType, ChipButtonSizeVariants, ChipButtonStyleVariantType, ChipButtonStyleVariants, ChipToggle, ChipToggleOptionProps, ChipToggleProps, ChipToggleSizeVariantType, ChipToggleSizeVariants, ChipToggleStyleVariantType, ChipToggleStyleVariants, ColorTokens, DangerouslySetInnerHTML, DayCalendarType, DayDatepicker, DayDatepickerHeaderCustomProps, DayDatepickerOptionProps, DayDatepickerProps, DayDatepickerSizeVariantType, DayDatepickerSizeVariants, DomainType, Dropdown, DropdownButton, DropdownButtonContext, DropdownButtonContextType, DropdownButtonOptionProps, DropdownButtonProps, DropdownButtonSizeVariantType, DropdownButtonSizeVariants, DropdownButtonStyleVariantType, DropdownButtonStyleVariants, DropdownContentProps, DropdownOptionProps, DropdownOptionVariantType, DropdownOptionVariants, DropdownProps, DropdownSizeVariantType, DropdownTriggerButtonProps, FontWeightTokens, Icon, IconButton, IconButtonComponent, IconButtonOptionProps, IconButtonProps, IconButtonSizeVariantType, IconButtonSizeVariants, IconButtonStyleVariantType, IconButtonStyleVariants, IconOptionProps, IconProps, IconSizeVariants, IconSizeVariantsType, Input, InputButton, InputButtonOptionProps, InputButtonProps, InputOptionProps, InputProps, InputSizeVariantType, InputSizeVariants, List, ListContent2ColumnsProps, ListOptionProps, ListProps, ListText2RowsProps, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu, MenuOptionProps, MenuProps, MenuSizeVariantType, MenuSizeVariants, MinusBoxOptionProps, MinusBoxProps, MinusButton, Modal, ModalBodyOptionProps, ModalBodyProps, ModalBottomProps, ModalContainerOptionProps, ModalContainerProps, ModalContext, ModalFooterOptionProps, ModalFooterProps, ModalFooterType, ModalHandlerContext, ModalHeaderOptionProps, ModalHeaderProps, ModalHeaderType, ModalPortal as ModalProvider, ModalSize, ModalSizeType, ModalStateType, ModalTopProps, MonthClickDateInfo, MonthDatepicker, MonthDatepickerProps, MonthDatepickerStyleType, MotionStack, MotionStackComponentType, MotionStackContainer, MotionStackContainerComponentType, NumberCombobox, NumberComboboxErrorType, NumberComboboxInputType, NumberComboboxOptionProps, NumberComboboxProps, NumberComboboxSizeVariantType, NumberComboboxSizeVariants, Pagination, PaginationOptionProps, PaginationProps, PaginationSizeSelectorProps, PolymorphicComponentProps, PolymorphicRef, Popper, PopperOptionProps, PopperPortal, PopperPortalProps, PopperProps, PopperTrigger, PopperTriggerProps, RADIO_SYMBOL_KEY, Radio, RadioOptionProps, RadioProps, RemoveModalProps, ScrollArea, ScrollAreaOptionProps, ScrollAreaProps, ScrollbarRefType, SelectInputButton, SelectInputButtonOptionProps, SelectInputButtonProps, ShoplflowProvider, ShoplflowProviderProps, SpacingTokens, SplitButton, SplitButtonContext, SplitButtonContextType, SplitButtonOptionProps, SplitButtonProps, SplitButtonSizeVariantType, SplitButtonSizeVariants, SplitButtonStyleVariantType, SplitButtonStyleVariants, Stack, StackComponentType, StackContainer, StackContainerComponentType, StackContainerGenericProps, StackContainerOptionProps, StackContainerProps, StackGenericProps, StackOptionProps, StackProps, StyledIcon, StyledStack, StyledStackContainer, Switch, SwitchOptionProps, SwitchProps, TREE_SYMBOL_KEY, TabOptionProps, TabProps, TabSizeVariantType, TabSizeVariants, TabStyleVariantType, TabStyleVariants, TabStyledProps, TabTextStyledProps, Tabs, TabsContext, TabsContextType, TabsOptionProps, TabsProps, Tag, TagOptionProps, TagProps, TagSizeVariantType, TagSizeVariants, TagStyleVariantType, TagStyleVariants, Text, Text2Rows, TextArea, TextAreaOptionProps, TextAreaProps, TextOptionProps, TextProps, ToggleButton, ToggleButtonInnerRadioOptionProps, ToggleButtonInnerRadioProps, ToggleButtonOptionProps, ToggleButtonProps, ToggleButtonSizeVariantType, ToggleButtonSizeVariants, Tooltip, TooltipContentProps, TooltipOptionProps, TooltipProps, Tree, TreeItem, TreeItemOptionProps, TreeItemProps, TreeOptionProps, TreeProps, TypographyTokens, WeekClickDateInfo, WeekDatepicker, WeekDatepickerProps, WeekDatepickerStyleType, YearSelectProps, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|
package/dist/index.d.ts
CHANGED
|
@@ -504,6 +504,10 @@ declare const MODAL_FOOTER_KEY: unique symbol;
|
|
|
504
504
|
interface ModalFooterType extends React.FC<ModalBodyProps> {
|
|
505
505
|
[MODAL_FOOTER_KEY]?: boolean;
|
|
506
506
|
}
|
|
507
|
+
interface ModalTopProps extends ChildrenProps {
|
|
508
|
+
}
|
|
509
|
+
interface ModalBottomProps extends ChildrenProps {
|
|
510
|
+
}
|
|
507
511
|
|
|
508
512
|
declare type ModalStateType = {
|
|
509
513
|
component: ReactNode;
|
|
@@ -537,7 +541,9 @@ declare const useHandleModal: () => {
|
|
|
537
541
|
declare const Modal: {
|
|
538
542
|
Container: ({ children, height, outsideClick, ...rest }: ModalContainerProps) => react_jsx_runtime.JSX.Element;
|
|
539
543
|
Header: ModalHeaderType;
|
|
544
|
+
Top: ({ children }: ModalTopProps) => react_jsx_runtime.JSX.Element;
|
|
540
545
|
Body: ({ children, isIncludeHeader, isIncludeFooter, sizeVar, height: modalContainerHeight, }: ModalBodyProps) => react_jsx_runtime.JSX.Element;
|
|
546
|
+
Bottom: ({ children }: ModalBottomProps) => react_jsx_runtime.JSX.Element;
|
|
541
547
|
Footer: ModalFooterType;
|
|
542
548
|
};
|
|
543
549
|
|
|
@@ -943,6 +949,7 @@ interface DropdownContentProps extends HTMLAttributes<HTMLDivElement>, ChildrenP
|
|
|
943
949
|
declare const dropdownSizeVariants: {
|
|
944
950
|
readonly S: "S";
|
|
945
951
|
readonly M: "M";
|
|
952
|
+
readonly L: "L";
|
|
946
953
|
};
|
|
947
954
|
declare type DropdownSizeVariantType = $Values<typeof dropdownSizeVariants>;
|
|
948
955
|
interface DropdownTriggerButtonProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'value'>, DisableProps, LeftElementProps, SizeVariantProps<DropdownSizeVariantType> {
|
|
@@ -1524,4 +1531,4 @@ declare type NumberComboboxProps = NumberComboboxOptionProps & Omit<InputHTMLAtt
|
|
|
1524
1531
|
|
|
1525
1532
|
declare const NumberCombobox: ({ disabled, onSelect, onChange, value, width, onBlur, items, isError, sizeVar, placeholder, maxLength, className, floatingZIndex, ...rest }: NumberComboboxProps) => react_jsx_runtime.JSX.Element;
|
|
1526
1533
|
|
|
1527
|
-
export { AnnualDatepicker, AnnualDatepickerProps, AsProp, Avatar, AvatarOptionProps, AvatarProps, AvatarSizeVariantType, AvatarSizeVariants, BackDropOptionProps, BackDropProps, BorderRadiusTokens, BoxShadowTokens, Button, ButtonComponent, ButtonOptionProps, ButtonProps, ButtonSizeVariantType, ButtonSizeVariants, ButtonStyleVariantType, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout, CalloutOptionProps, CalloutProps, CalloutType, CalloutTypes, Checkbox, CheckboxOptionProps, CheckboxProps, CheckboxStyleVariantType, CheckboxStyleVariants, ChipButton, ChipButtonOptionProps, ChipButtonProps, ChipButtonSizeVariantType, ChipButtonSizeVariants, ChipButtonStyleVariantType, ChipButtonStyleVariants, ChipToggle, ChipToggleOptionProps, ChipToggleProps, ChipToggleSizeVariantType, ChipToggleSizeVariants, ChipToggleStyleVariantType, ChipToggleStyleVariants, ColorTokens, DangerouslySetInnerHTML, DayCalendarType, DayDatepicker, DayDatepickerHeaderCustomProps, DayDatepickerOptionProps, DayDatepickerProps, DayDatepickerSizeVariantType, DayDatepickerSizeVariants, DomainType, Dropdown, DropdownButton, DropdownButtonContext, DropdownButtonContextType, DropdownButtonOptionProps, DropdownButtonProps, DropdownButtonSizeVariantType, DropdownButtonSizeVariants, DropdownButtonStyleVariantType, DropdownButtonStyleVariants, DropdownContentProps, DropdownOptionProps, DropdownOptionVariantType, DropdownProps, DropdownSizeVariantType, DropdownTriggerButtonProps, FontWeightTokens, Icon, IconButton, IconButtonComponent, IconButtonOptionProps, IconButtonProps, IconButtonSizeVariantType, IconButtonSizeVariants, IconButtonStyleVariantType, IconButtonStyleVariants, IconOptionProps, IconProps, IconSizeVariants, IconSizeVariantsType, Input, InputButton, InputButtonOptionProps, InputButtonProps, InputOptionProps, InputProps, InputSizeVariantType, InputSizeVariants, List, ListContent2ColumnsProps, ListOptionProps, ListProps, ListText2RowsProps, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu, MenuOptionProps, MenuProps, MenuSizeVariantType, MenuSizeVariants, MinusBoxOptionProps, MinusBoxProps, MinusButton, Modal, ModalBodyOptionProps, ModalBodyProps, ModalContainerOptionProps, ModalContainerProps, ModalContext, ModalFooterOptionProps, ModalFooterProps, ModalFooterType, ModalHandlerContext, ModalHeaderOptionProps, ModalHeaderProps, ModalHeaderType, ModalPortal as ModalProvider, ModalSize, ModalSizeType, ModalStateType, MonthClickDateInfo, MonthDatepicker, MonthDatepickerProps, MonthDatepickerStyleType, MotionStack, MotionStackComponentType, MotionStackContainer, MotionStackContainerComponentType, NumberCombobox, NumberComboboxErrorType, NumberComboboxInputType, NumberComboboxOptionProps, NumberComboboxProps, NumberComboboxSizeVariantType, NumberComboboxSizeVariants, Pagination, PaginationOptionProps, PaginationProps, PaginationSizeSelectorProps, PolymorphicComponentProps, PolymorphicRef, Popper, PopperOptionProps, PopperPortal, PopperPortalProps, PopperProps, PopperTrigger, PopperTriggerProps, RADIO_SYMBOL_KEY, Radio, RadioOptionProps, RadioProps, RemoveModalProps, ScrollArea, ScrollAreaOptionProps, ScrollAreaProps, ScrollbarRefType, SelectInputButton, SelectInputButtonOptionProps, SelectInputButtonProps, ShoplflowProvider, ShoplflowProviderProps, SpacingTokens, SplitButton, SplitButtonContext, SplitButtonContextType, SplitButtonOptionProps, SplitButtonProps, SplitButtonSizeVariantType, SplitButtonSizeVariants, SplitButtonStyleVariantType, SplitButtonStyleVariants, Stack, StackComponentType, StackContainer, StackContainerComponentType, StackContainerGenericProps, StackContainerOptionProps, StackContainerProps, StackGenericProps, StackOptionProps, StackProps, StyledIcon, StyledStack, StyledStackContainer, Switch, SwitchOptionProps, SwitchProps, TREE_SYMBOL_KEY, TabOptionProps, TabProps, TabSizeVariantType, TabSizeVariants, TabStyleVariantType, TabStyleVariants, TabStyledProps, TabTextStyledProps, Tabs, TabsContext, TabsContextType, TabsOptionProps, TabsProps, Tag, TagOptionProps, TagProps, TagSizeVariantType, TagSizeVariants, TagStyleVariantType, TagStyleVariants, Text, Text2Rows, TextArea, TextAreaOptionProps, TextAreaProps, TextOptionProps, TextProps, ToggleButton, ToggleButtonInnerRadioOptionProps, ToggleButtonInnerRadioProps, ToggleButtonOptionProps, ToggleButtonProps, ToggleButtonSizeVariantType, ToggleButtonSizeVariants, Tooltip, TooltipContentProps, TooltipOptionProps, TooltipProps, Tree, TreeItem, TreeItemOptionProps, TreeItemProps, TreeOptionProps, TreeProps, TypographyTokens, WeekClickDateInfo, WeekDatepicker, WeekDatepickerProps, WeekDatepickerStyleType, YearSelectProps, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|
|
1534
|
+
export { AnnualDatepicker, AnnualDatepickerProps, AsProp, Avatar, AvatarOptionProps, AvatarProps, AvatarSizeVariantType, AvatarSizeVariants, BackDropOptionProps, BackDropProps, BorderRadiusTokens, BoxShadowTokens, Button, ButtonComponent, ButtonOptionProps, ButtonProps, ButtonSizeVariantType, ButtonSizeVariants, ButtonStyleVariantType, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout, CalloutOptionProps, CalloutProps, CalloutType, CalloutTypes, Checkbox, CheckboxOptionProps, CheckboxProps, CheckboxStyleVariantType, CheckboxStyleVariants, ChipButton, ChipButtonOptionProps, ChipButtonProps, ChipButtonSizeVariantType, ChipButtonSizeVariants, ChipButtonStyleVariantType, ChipButtonStyleVariants, ChipToggle, ChipToggleOptionProps, ChipToggleProps, ChipToggleSizeVariantType, ChipToggleSizeVariants, ChipToggleStyleVariantType, ChipToggleStyleVariants, ColorTokens, DangerouslySetInnerHTML, DayCalendarType, DayDatepicker, DayDatepickerHeaderCustomProps, DayDatepickerOptionProps, DayDatepickerProps, DayDatepickerSizeVariantType, DayDatepickerSizeVariants, DomainType, Dropdown, DropdownButton, DropdownButtonContext, DropdownButtonContextType, DropdownButtonOptionProps, DropdownButtonProps, DropdownButtonSizeVariantType, DropdownButtonSizeVariants, DropdownButtonStyleVariantType, DropdownButtonStyleVariants, DropdownContentProps, DropdownOptionProps, DropdownOptionVariantType, DropdownOptionVariants, DropdownProps, DropdownSizeVariantType, DropdownTriggerButtonProps, FontWeightTokens, Icon, IconButton, IconButtonComponent, IconButtonOptionProps, IconButtonProps, IconButtonSizeVariantType, IconButtonSizeVariants, IconButtonStyleVariantType, IconButtonStyleVariants, IconOptionProps, IconProps, IconSizeVariants, IconSizeVariantsType, Input, InputButton, InputButtonOptionProps, InputButtonProps, InputOptionProps, InputProps, InputSizeVariantType, InputSizeVariants, List, ListContent2ColumnsProps, ListOptionProps, ListProps, ListText2RowsProps, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu, MenuOptionProps, MenuProps, MenuSizeVariantType, MenuSizeVariants, MinusBoxOptionProps, MinusBoxProps, MinusButton, Modal, ModalBodyOptionProps, ModalBodyProps, ModalBottomProps, ModalContainerOptionProps, ModalContainerProps, ModalContext, ModalFooterOptionProps, ModalFooterProps, ModalFooterType, ModalHandlerContext, ModalHeaderOptionProps, ModalHeaderProps, ModalHeaderType, ModalPortal as ModalProvider, ModalSize, ModalSizeType, ModalStateType, ModalTopProps, MonthClickDateInfo, MonthDatepicker, MonthDatepickerProps, MonthDatepickerStyleType, MotionStack, MotionStackComponentType, MotionStackContainer, MotionStackContainerComponentType, NumberCombobox, NumberComboboxErrorType, NumberComboboxInputType, NumberComboboxOptionProps, NumberComboboxProps, NumberComboboxSizeVariantType, NumberComboboxSizeVariants, Pagination, PaginationOptionProps, PaginationProps, PaginationSizeSelectorProps, PolymorphicComponentProps, PolymorphicRef, Popper, PopperOptionProps, PopperPortal, PopperPortalProps, PopperProps, PopperTrigger, PopperTriggerProps, RADIO_SYMBOL_KEY, Radio, RadioOptionProps, RadioProps, RemoveModalProps, ScrollArea, ScrollAreaOptionProps, ScrollAreaProps, ScrollbarRefType, SelectInputButton, SelectInputButtonOptionProps, SelectInputButtonProps, ShoplflowProvider, ShoplflowProviderProps, SpacingTokens, SplitButton, SplitButtonContext, SplitButtonContextType, SplitButtonOptionProps, SplitButtonProps, SplitButtonSizeVariantType, SplitButtonSizeVariants, SplitButtonStyleVariantType, SplitButtonStyleVariants, Stack, StackComponentType, StackContainer, StackContainerComponentType, StackContainerGenericProps, StackContainerOptionProps, StackContainerProps, StackGenericProps, StackOptionProps, StackProps, StyledIcon, StyledStack, StyledStackContainer, Switch, SwitchOptionProps, SwitchProps, TREE_SYMBOL_KEY, TabOptionProps, TabProps, TabSizeVariantType, TabSizeVariants, TabStyleVariantType, TabStyleVariants, TabStyledProps, TabTextStyledProps, Tabs, TabsContext, TabsContextType, TabsOptionProps, TabsProps, Tag, TagOptionProps, TagProps, TagSizeVariantType, TagSizeVariants, TagStyleVariantType, TagStyleVariants, Text, Text2Rows, TextArea, TextAreaOptionProps, TextAreaProps, TextOptionProps, TextProps, ToggleButton, ToggleButtonInnerRadioOptionProps, ToggleButtonInnerRadioProps, ToggleButtonOptionProps, ToggleButtonProps, ToggleButtonSizeVariantType, ToggleButtonSizeVariants, Tooltip, TooltipContentProps, TooltipOptionProps, TooltipProps, Tree, TreeItem, TreeItemOptionProps, TreeItemProps, TreeOptionProps, TreeProps, TypographyTokens, WeekClickDateInfo, WeekDatepicker, WeekDatepickerProps, WeekDatepickerStyleType, YearSelectProps, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|
package/dist/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import * as React3 from 'react';
|
|
2
|
-
import React3__default, { forwardRef, useRef, useState, useCallback, useEffect,
|
|
2
|
+
import React3__default, { forwardRef, createContext, useRef, useState, useCallback, useEffect, cloneElement, useId, useContext, useMemo, createElement } from 'react';
|
|
3
3
|
import styled6 from '@emotion/styled';
|
|
4
4
|
import { motion, AnimatePresence, LayoutGroup, LazyMotion, domAnimation } from 'framer-motion';
|
|
5
5
|
import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
|
|
6
6
|
import { createPortal } from 'react-dom';
|
|
7
7
|
import { css } from '@emotion/react';
|
|
8
|
-
import {
|
|
8
|
+
import { noop, useMergeRefs, useOutsideClick, OutSideClick, useSelect, useParentElementClick, isNullOrUndefined } from '@shoplflow/utils';
|
|
9
9
|
import Scrollbars from 'react-custom-scrollbars-2';
|
|
10
10
|
import { FloatingPortal, autoUpdate, offset, autoPlacement } from '@floating-ui/react';
|
|
11
11
|
export { arrow, flip, hide, inline, offset, shift, size } from '@floating-ui/react';
|
|
@@ -829,6 +829,9 @@ var FooterContainer = styled6.div`
|
|
|
829
829
|
border-top: 1px solid ${colorTokens.neutral300};
|
|
830
830
|
background: ${colorTokens.neutral0};
|
|
831
831
|
`;
|
|
832
|
+
var BottomContainer = styled6.footer`
|
|
833
|
+
width: 100%;
|
|
834
|
+
`;
|
|
832
835
|
|
|
833
836
|
// src/components/Modal/Modal.types.ts
|
|
834
837
|
var ModalSize = {
|
|
@@ -855,6 +858,27 @@ var useViewportSizeObserver = () => {
|
|
|
855
858
|
}, []);
|
|
856
859
|
return size2;
|
|
857
860
|
};
|
|
861
|
+
var ModalOptionContext = createContext({
|
|
862
|
+
heightToDeduct: 0,
|
|
863
|
+
setHeightToDeduct: noop,
|
|
864
|
+
clearHeightToDeduct: noop
|
|
865
|
+
});
|
|
866
|
+
var ModalOptionContextProvider = ({ children }) => {
|
|
867
|
+
const [heightToDeduct, setHeightToDeduct] = useState(0);
|
|
868
|
+
const controlHeightToDeduct = useCallback((heightToAdd) => {
|
|
869
|
+
setHeightToDeduct((prev) => prev + heightToAdd);
|
|
870
|
+
}, []);
|
|
871
|
+
const clearHeightToDeduct = useCallback(() => {
|
|
872
|
+
setHeightToDeduct(0);
|
|
873
|
+
}, []);
|
|
874
|
+
return /* @__PURE__ */ jsx(
|
|
875
|
+
ModalOptionContext.Provider,
|
|
876
|
+
{
|
|
877
|
+
value: { heightToDeduct, setHeightToDeduct: controlHeightToDeduct, clearHeightToDeduct },
|
|
878
|
+
children
|
|
879
|
+
}
|
|
880
|
+
);
|
|
881
|
+
};
|
|
858
882
|
var ModalContainer = (_a) => {
|
|
859
883
|
var _b = _a, { children, height, outsideClick = noop } = _b, rest = __objRest(_b, ["children", "height", "outsideClick"]);
|
|
860
884
|
const ref = useParentElementClick(outsideClick);
|
|
@@ -889,7 +913,7 @@ var ModalContainer = (_a) => {
|
|
|
889
913
|
height: heightWidthMargin
|
|
890
914
|
});
|
|
891
915
|
});
|
|
892
|
-
return /* @__PURE__ */ jsx(Container, __spreadProps(__spreadValues({ ref }, rest), { height: heightWidthMargin, viewport: windowHeight, "data-shoplflow": "Modal", children: addPropInChildren }));
|
|
916
|
+
return /* @__PURE__ */ jsx(Container, __spreadProps(__spreadValues({ ref }, rest), { height: heightWidthMargin, viewport: windowHeight, "data-shoplflow": "Modal", children: /* @__PURE__ */ jsx(ModalOptionContextProvider, { children: addPropInChildren }) }));
|
|
893
917
|
};
|
|
894
918
|
var ModalContainer_default = ModalContainer;
|
|
895
919
|
var ModalFooter = ({ children }) => {
|
|
@@ -927,6 +951,13 @@ var ScrollArea = forwardRef((_a, ref) => {
|
|
|
927
951
|
) });
|
|
928
952
|
});
|
|
929
953
|
var ScrollArea_default = ScrollArea;
|
|
954
|
+
var useModalOption = () => {
|
|
955
|
+
const context = useContext(ModalOptionContext);
|
|
956
|
+
if (!context) {
|
|
957
|
+
throw new Error(`useModalOption cannot be called outside the ModalOptionProvider`);
|
|
958
|
+
}
|
|
959
|
+
return context;
|
|
960
|
+
};
|
|
930
961
|
var ModalBody = ({
|
|
931
962
|
children,
|
|
932
963
|
isIncludeHeader = false,
|
|
@@ -935,6 +966,7 @@ var ModalBody = ({
|
|
|
935
966
|
height: modalContainerHeight
|
|
936
967
|
}) => {
|
|
937
968
|
const { height: windowHeight } = useViewportSizeObserver();
|
|
969
|
+
const { heightToDeduct } = useModalOption();
|
|
938
970
|
const headerHeight = 64;
|
|
939
971
|
const footerHeight = 72;
|
|
940
972
|
const topBottomMargin = 64;
|
|
@@ -956,11 +988,11 @@ var ModalBody = ({
|
|
|
956
988
|
if (modalContainerHeight) {
|
|
957
989
|
if (modalContainerHeight <= 1200) {
|
|
958
990
|
if (windowHeight < modalContainerHeight) {
|
|
959
|
-
return windowHeight - topBottomMargin - headerFooterHeight;
|
|
991
|
+
return windowHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
960
992
|
}
|
|
961
|
-
return modalContainerHeight - topBottomMargin - headerFooterHeight;
|
|
993
|
+
return modalContainerHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
962
994
|
}
|
|
963
|
-
return modalContainerHeight - topBottomMargin - headerFooterHeight;
|
|
995
|
+
return modalContainerHeight - topBottomMargin - headerFooterHeight - heightToDeduct;
|
|
964
996
|
} else {
|
|
965
997
|
return "100%";
|
|
966
998
|
}
|
|
@@ -987,32 +1019,23 @@ var ModalBody = ({
|
|
|
987
1019
|
}
|
|
988
1020
|
return 0;
|
|
989
1021
|
};
|
|
990
|
-
const
|
|
991
|
-
|
|
992
|
-
autoHeightMax = autoHeightMax - 24;
|
|
993
|
-
if (isIncludeHeader) {
|
|
994
|
-
autoHeightMax = autoHeightMax - 24;
|
|
995
|
-
}
|
|
996
|
-
if (!isIncludeHeader) {
|
|
997
|
-
autoHeightMax = autoHeightMax - 16;
|
|
998
|
-
}
|
|
999
|
-
return autoHeightMax;
|
|
1000
|
-
};
|
|
1022
|
+
const autoHeightMin = setAutoHeightMin();
|
|
1023
|
+
const _autoHeightMin = typeof autoHeightMin === "string" ? autoHeightMin : autoHeightMin - heightToDeduct;
|
|
1001
1024
|
return /* @__PURE__ */ jsx(
|
|
1002
1025
|
BodyContainer,
|
|
1003
1026
|
{
|
|
1004
1027
|
isIncludeHeader,
|
|
1005
1028
|
sizeVar,
|
|
1006
|
-
minHeight:
|
|
1007
|
-
maxHeight: setAutoHeightMax(),
|
|
1029
|
+
minHeight: _autoHeightMin,
|
|
1030
|
+
maxHeight: setAutoHeightMax() - heightToDeduct,
|
|
1008
1031
|
children: /* @__PURE__ */ jsx(
|
|
1009
1032
|
ScrollArea_default,
|
|
1010
1033
|
{
|
|
1011
1034
|
id: `scrollbar`,
|
|
1012
1035
|
universal: true,
|
|
1013
1036
|
autoHeight: !modalContainerHeight,
|
|
1014
|
-
autoHeightMin:
|
|
1015
|
-
autoHeightMax:
|
|
1037
|
+
autoHeightMin: _autoHeightMin,
|
|
1038
|
+
autoHeightMax: "100%",
|
|
1016
1039
|
style: {},
|
|
1017
1040
|
children: /* @__PURE__ */ jsx(ModalBodyContainerInner, { children: /* @__PURE__ */ jsx(ModalBodyContent, { isIncludeHeader, sizeVar, children }) })
|
|
1018
1041
|
}
|
|
@@ -1026,6 +1049,33 @@ var ModalHeader = ({ children }) => {
|
|
|
1026
1049
|
};
|
|
1027
1050
|
ModalHeader[MODAL_HEADER_KEY] = true;
|
|
1028
1051
|
var ModalHeader_default = ModalHeader;
|
|
1052
|
+
var ModalTop = ({ children }) => {
|
|
1053
|
+
const [topRef, setTopRef] = useState(null);
|
|
1054
|
+
const { setHeightToDeduct, clearHeightToDeduct } = useModalOption();
|
|
1055
|
+
useEffect(() => {
|
|
1056
|
+
if (!topRef) {
|
|
1057
|
+
return;
|
|
1058
|
+
}
|
|
1059
|
+
const { height } = topRef.getBoundingClientRect();
|
|
1060
|
+
setHeightToDeduct == null ? void 0 : setHeightToDeduct(height);
|
|
1061
|
+
return () => clearHeightToDeduct();
|
|
1062
|
+
}, [topRef, setHeightToDeduct, clearHeightToDeduct]);
|
|
1063
|
+
return /* @__PURE__ */ jsx("div", { ref: setTopRef, children });
|
|
1064
|
+
};
|
|
1065
|
+
var ModalTop_default = ModalTop;
|
|
1066
|
+
var ModalBottom = ({ children }) => {
|
|
1067
|
+
const [bottomRef, setBottomRef] = useState(null);
|
|
1068
|
+
const { setHeightToDeduct, clearHeightToDeduct } = useModalOption();
|
|
1069
|
+
useEffect(() => {
|
|
1070
|
+
if (!bottomRef) {
|
|
1071
|
+
return;
|
|
1072
|
+
}
|
|
1073
|
+
const { height } = bottomRef.getBoundingClientRect();
|
|
1074
|
+
setHeightToDeduct == null ? void 0 : setHeightToDeduct(height);
|
|
1075
|
+
return () => clearHeightToDeduct();
|
|
1076
|
+
}, [bottomRef, setHeightToDeduct, clearHeightToDeduct]);
|
|
1077
|
+
return /* @__PURE__ */ jsx(BottomContainer, { ref: setBottomRef, children });
|
|
1078
|
+
};
|
|
1029
1079
|
var ModalHandlerContext = createContext({
|
|
1030
1080
|
addModal: noop,
|
|
1031
1081
|
removeModal: noop
|
|
@@ -1120,7 +1170,9 @@ var ModalProvider_default = ModalProvider;
|
|
|
1120
1170
|
var Modal = {
|
|
1121
1171
|
Container: ModalContainer_default,
|
|
1122
1172
|
Header: ModalHeader_default,
|
|
1173
|
+
Top: ModalTop_default,
|
|
1123
1174
|
Body: ModalBody_default,
|
|
1175
|
+
Bottom: ModalBottom,
|
|
1124
1176
|
Footer: ModalFooter_default
|
|
1125
1177
|
};
|
|
1126
1178
|
var SwitchContainer = styled6.div`
|
|
@@ -2736,9 +2788,30 @@ var CalloutTypes = {
|
|
|
2736
2788
|
INFORMATION: "INFORMATION",
|
|
2737
2789
|
ALERT: "ALERT"
|
|
2738
2790
|
};
|
|
2791
|
+
var StyledDropdown = styled6.div`
|
|
2792
|
+
width: ${({ width }) => width};
|
|
2793
|
+
`;
|
|
2794
|
+
var StyledDropdownContent = styled6.div`
|
|
2795
|
+
display: flex;
|
|
2796
|
+
flex-direction: column;
|
|
2797
|
+
background: ${colorTokens.neutral0};
|
|
2798
|
+
width: ${({ width }) => width != null ? width : "240px"};
|
|
2799
|
+
padding: 4px;
|
|
2800
|
+
border-radius: 6px;
|
|
2801
|
+
box-shadow: ${boxShadowTokens.dropShadow};
|
|
2802
|
+
`;
|
|
2803
|
+
var DropdownContext = createContext(null);
|
|
2804
|
+
var useDropdown = () => {
|
|
2805
|
+
const context = useContext(DropdownContext);
|
|
2806
|
+
if (context === null) {
|
|
2807
|
+
throw new Error("useDropdown must be used within a DropdownProvider");
|
|
2808
|
+
}
|
|
2809
|
+
return context;
|
|
2810
|
+
};
|
|
2739
2811
|
var getDropdownHeightBySizeVar = (size2) => {
|
|
2740
2812
|
switch (size2) {
|
|
2741
2813
|
case "M":
|
|
2814
|
+
case "L":
|
|
2742
2815
|
return "40px";
|
|
2743
2816
|
case "S":
|
|
2744
2817
|
return "32px";
|
|
@@ -2748,6 +2821,8 @@ var getDropdownHeightBySizeVar = (size2) => {
|
|
|
2748
2821
|
};
|
|
2749
2822
|
var getDropdownFontSizeBySizeVar = (size2) => {
|
|
2750
2823
|
switch (size2) {
|
|
2824
|
+
case "L":
|
|
2825
|
+
return "body2_700";
|
|
2751
2826
|
case "M":
|
|
2752
2827
|
return "body1_400";
|
|
2753
2828
|
case "S":
|
|
@@ -2758,12 +2833,20 @@ var getDropdownFontSizeBySizeVar = (size2) => {
|
|
|
2758
2833
|
};
|
|
2759
2834
|
var getDropdownStyleBySizeVar = (size2) => {
|
|
2760
2835
|
switch (size2) {
|
|
2836
|
+
case "L":
|
|
2837
|
+
return css`
|
|
2838
|
+
background-color: transparent;
|
|
2839
|
+
padding: 8px 4px 8px 12px;
|
|
2840
|
+
`;
|
|
2761
2841
|
case "M":
|
|
2762
2842
|
return css`
|
|
2843
|
+
background-color: ${colorTokens.neutral0};
|
|
2844
|
+
gap: 4px;
|
|
2763
2845
|
padding: 4px 4px 4px 12px;
|
|
2764
2846
|
`;
|
|
2765
2847
|
case "S":
|
|
2766
2848
|
return css`
|
|
2849
|
+
background-color: ${colorTokens.neutral0};
|
|
2767
2850
|
padding: 4px 4px 4px 8px;
|
|
2768
2851
|
gap: 4px;
|
|
2769
2852
|
`;
|
|
@@ -2773,22 +2856,24 @@ var getDropdownStyleBySizeVar = (size2) => {
|
|
|
2773
2856
|
`;
|
|
2774
2857
|
}
|
|
2775
2858
|
};
|
|
2859
|
+
var getDisabledStyle2 = (disabled) => {
|
|
2860
|
+
if (disabled) {
|
|
2861
|
+
return css`
|
|
2862
|
+
opacity: 50%;
|
|
2863
|
+
cursor: not-allowed;
|
|
2864
|
+
`;
|
|
2865
|
+
}
|
|
2866
|
+
};
|
|
2776
2867
|
var getDropdownIconSizeBySizeVar = (size2) => {
|
|
2777
2868
|
switch (size2) {
|
|
2778
2869
|
case "S":
|
|
2870
|
+
case "L":
|
|
2779
2871
|
return css`
|
|
2780
2872
|
height: 24px;
|
|
2781
2873
|
width: 24px;
|
|
2782
2874
|
min-width: 24px;
|
|
2783
2875
|
min-height: 24px;
|
|
2784
2876
|
`;
|
|
2785
|
-
case "M":
|
|
2786
|
-
return css`
|
|
2787
|
-
height: 32px;
|
|
2788
|
-
width: 32px;
|
|
2789
|
-
min-width: 32px;
|
|
2790
|
-
min-height: 32px;
|
|
2791
|
-
`;
|
|
2792
2877
|
default:
|
|
2793
2878
|
return css`
|
|
2794
2879
|
height: 32px;
|
|
@@ -2798,49 +2883,6 @@ var getDropdownIconSizeBySizeVar = (size2) => {
|
|
|
2798
2883
|
`;
|
|
2799
2884
|
}
|
|
2800
2885
|
};
|
|
2801
|
-
var StyledDropdown = styled6.div`
|
|
2802
|
-
width: ${({ width }) => width};
|
|
2803
|
-
`;
|
|
2804
|
-
var StyledDropdownContent = styled6.div`
|
|
2805
|
-
display: flex;
|
|
2806
|
-
flex-direction: column;
|
|
2807
|
-
background: ${colorTokens.neutral0};
|
|
2808
|
-
width: ${({ width }) => width != null ? width : "240px"};
|
|
2809
|
-
padding: 4px;
|
|
2810
|
-
border-radius: 6px;
|
|
2811
|
-
box-shadow: ${boxShadowTokens.dropShadow};
|
|
2812
|
-
`;
|
|
2813
|
-
var StyledDropdownButton = styled6.button`
|
|
2814
|
-
display: flex;
|
|
2815
|
-
flex-direction: row;
|
|
2816
|
-
align-items: center;
|
|
2817
|
-
justify-content: space-between;
|
|
2818
|
-
width: 100%;
|
|
2819
|
-
height: 100%;
|
|
2820
|
-
gap: 8px;
|
|
2821
|
-
cursor: pointer;
|
|
2822
|
-
background-color: ${colorTokens.neutral0};
|
|
2823
|
-
${({ sizeVar }) => sizeVar && getDropdownStyleBySizeVar(sizeVar)};
|
|
2824
|
-
${({ disabled }) => disabled && css`
|
|
2825
|
-
background-color: ${colorTokens.neutral100};
|
|
2826
|
-
cursor: not-allowed;
|
|
2827
|
-
`}
|
|
2828
|
-
`;
|
|
2829
|
-
var DropdownButtonIcon = styled6(motion.div)`
|
|
2830
|
-
display: flex;
|
|
2831
|
-
align-items: center;
|
|
2832
|
-
justify-content: center;
|
|
2833
|
-
|
|
2834
|
-
${({ sizeVar }) => sizeVar && getDropdownIconSizeBySizeVar(sizeVar)};
|
|
2835
|
-
`;
|
|
2836
|
-
var DropdownContext = createContext(null);
|
|
2837
|
-
var useDropdown = () => {
|
|
2838
|
-
const context = useContext(DropdownContext);
|
|
2839
|
-
if (context === null) {
|
|
2840
|
-
throw new Error("useDropdown must be used within a DropdownProvider");
|
|
2841
|
-
}
|
|
2842
|
-
return context;
|
|
2843
|
-
};
|
|
2844
2886
|
var getBorderColorByStatus = ({ isFocused, isError, isHovered, disabled }) => {
|
|
2845
2887
|
if (!disabled) {
|
|
2846
2888
|
if (isError) {
|
|
@@ -2855,60 +2897,72 @@ var getBorderColorByStatus = ({ isFocused, isError, isHovered, disabled }) => {
|
|
|
2855
2897
|
}
|
|
2856
2898
|
return colorTokens.neutral300;
|
|
2857
2899
|
};
|
|
2900
|
+
var getButtoWrapperStyleBySizeVar = (sizeVar) => {
|
|
2901
|
+
switch (sizeVar) {
|
|
2902
|
+
case "L":
|
|
2903
|
+
return css`
|
|
2904
|
+
background-color: transparent;
|
|
2905
|
+
border-width: 2px;
|
|
2906
|
+
border-radius: 12px;
|
|
2907
|
+
`;
|
|
2908
|
+
default:
|
|
2909
|
+
return css`
|
|
2910
|
+
background-color: ${colorTokens.neutral0};
|
|
2911
|
+
border-width: 1px;
|
|
2912
|
+
border-radius: 6px;
|
|
2913
|
+
`;
|
|
2914
|
+
}
|
|
2915
|
+
};
|
|
2858
2916
|
var getStyleByType = ({
|
|
2859
|
-
type,
|
|
2860
2917
|
height,
|
|
2861
|
-
|
|
2862
|
-
maxHeight,
|
|
2863
|
-
width,
|
|
2864
|
-
minWidth,
|
|
2865
|
-
maxWidth,
|
|
2866
|
-
borderRadius,
|
|
2867
|
-
customNumberInputHeight
|
|
2918
|
+
width
|
|
2868
2919
|
}) => {
|
|
2869
|
-
if (type === "number") {
|
|
2870
|
-
return css`
|
|
2871
|
-
width: ${width || "64px"};
|
|
2872
|
-
height: ${customNumberInputHeight || "32px"};
|
|
2873
|
-
border-radius: ${borderRadius ? borderRadiusTokens[borderRadius] : "6px"};
|
|
2874
|
-
`;
|
|
2875
|
-
}
|
|
2876
2920
|
return css`
|
|
2877
2921
|
width: ${width || "100%"};
|
|
2878
|
-
min-width: ${minWidth || "initial"};
|
|
2879
|
-
max-width: ${maxWidth || "initial"};
|
|
2880
2922
|
height: ${height || "initial"};
|
|
2881
|
-
min-height: ${minHeight || "initial"};
|
|
2882
|
-
max-height: ${maxHeight || "initial"};
|
|
2883
|
-
border-radius: ${borderRadius ? borderRadiusTokens[borderRadius] : "6px"};
|
|
2884
2923
|
`;
|
|
2885
2924
|
};
|
|
2886
|
-
var
|
|
2925
|
+
var StyledDropdownButtonWrapper = styled6.label`
|
|
2887
2926
|
position: relative;
|
|
2888
2927
|
display: flex;
|
|
2889
2928
|
align-items: center;
|
|
2890
|
-
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2929
|
+
flex-direction: row;
|
|
2930
|
+
min-height: initial;
|
|
2931
|
+
max-height: initial;
|
|
2932
|
+
min-width: initial;
|
|
2933
|
+
max-width: initial;
|
|
2934
|
+
${({ height, width }) => getStyleByType({
|
|
2895
2935
|
height,
|
|
2896
|
-
|
|
2897
|
-
maxHeight,
|
|
2898
|
-
width,
|
|
2899
|
-
maxWidth,
|
|
2900
|
-
minWidth,
|
|
2901
|
-
borderRadius
|
|
2936
|
+
width
|
|
2902
2937
|
})};
|
|
2903
2938
|
justify-content: space-between;
|
|
2904
|
-
|
|
2905
|
-
border:
|
|
2906
|
-
|
|
2939
|
+
border-color: ${(props) => getBorderColorByStatus(props)};
|
|
2940
|
+
border-style: solid;
|
|
2941
|
+
${({ sizeVar }) => getButtoWrapperStyleBySizeVar(sizeVar)};
|
|
2942
|
+
|
|
2907
2943
|
overflow: hidden;
|
|
2908
|
-
${({ disabled }) => disabled
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2944
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2945
|
+
`;
|
|
2946
|
+
var StyledDropdownButton = styled6.button`
|
|
2947
|
+
display: flex;
|
|
2948
|
+
flex-direction: row;
|
|
2949
|
+
align-items: center;
|
|
2950
|
+
justify-content: space-between;
|
|
2951
|
+
width: 100%;
|
|
2952
|
+
height: 100%;
|
|
2953
|
+
|
|
2954
|
+
cursor: pointer;
|
|
2955
|
+
${({ sizeVar }) => sizeVar && getDropdownStyleBySizeVar(sizeVar)};
|
|
2956
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2957
|
+
`;
|
|
2958
|
+
var DropdownButtonIcon = styled6(motion.div)`
|
|
2959
|
+
display: flex;
|
|
2960
|
+
align-items: center;
|
|
2961
|
+
justify-content: center;
|
|
2962
|
+
flex-shrink: 0;
|
|
2963
|
+
|
|
2964
|
+
${({ sizeVar }) => sizeVar && getDropdownIconSizeBySizeVar(sizeVar)};
|
|
2965
|
+
${({ disabled }) => getDisabledStyle2(disabled)};
|
|
2912
2966
|
`;
|
|
2913
2967
|
var DropdownTriggerButton = forwardRef(
|
|
2914
2968
|
(_a, ref) => {
|
|
@@ -2936,8 +2990,9 @@ var DropdownTriggerButton = forwardRef(
|
|
|
2936
2990
|
}
|
|
2937
2991
|
return "neutral700";
|
|
2938
2992
|
};
|
|
2993
|
+
const LeftSourceClone = leftSource ? cloneElement(leftSource, __spreadProps(__spreadValues({}, leftSource.props), { disabled })) : leftSource;
|
|
2939
2994
|
return /* @__PURE__ */ jsx(
|
|
2940
|
-
|
|
2995
|
+
StyledDropdownButtonWrapper,
|
|
2941
2996
|
{
|
|
2942
2997
|
onMouseEnter: handleOnMouseEnter,
|
|
2943
2998
|
onMouseLeave: handleOnMouseLeave,
|
|
@@ -2946,19 +3001,22 @@ var DropdownTriggerButton = forwardRef(
|
|
|
2946
3001
|
disabled,
|
|
2947
3002
|
width,
|
|
2948
3003
|
isError,
|
|
3004
|
+
sizeVar,
|
|
2949
3005
|
height: getDropdownHeightBySizeVar(sizeVar),
|
|
2950
3006
|
children: /* @__PURE__ */ jsxs(StyledDropdownButton, __spreadProps(__spreadValues({ ref, onClick: handleOnClick, disabled }, rest), { sizeVar, children: [
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
3007
|
+
/* @__PURE__ */ jsxs(Stack_default.Horizontal, { width: "100%", spacing: sizeVar === "L" ? "spacing04" : void 0, align: "center", children: [
|
|
3008
|
+
LeftSourceClone && LeftSourceClone,
|
|
3009
|
+
value || /* @__PURE__ */ jsx(
|
|
3010
|
+
Text_default,
|
|
3011
|
+
{
|
|
3012
|
+
typography: getDropdownFontSizeBySizeVar(sizeVar),
|
|
3013
|
+
color: getTextColor({ value, disabled }),
|
|
3014
|
+
textOverflow: "ellipsis",
|
|
3015
|
+
lineClamp: 1,
|
|
3016
|
+
children: placeholder
|
|
3017
|
+
}
|
|
3018
|
+
)
|
|
3019
|
+
] }),
|
|
2962
3020
|
/* @__PURE__ */ jsx(
|
|
2963
3021
|
DropdownButtonIcon,
|
|
2964
3022
|
{
|
|
@@ -2969,7 +3027,14 @@ var DropdownTriggerButton = forwardRef(
|
|
|
2969
3027
|
transition: {
|
|
2970
3028
|
duration: 0.2
|
|
2971
3029
|
},
|
|
2972
|
-
children: /* @__PURE__ */ jsx(
|
|
3030
|
+
children: /* @__PURE__ */ jsx(
|
|
3031
|
+
Icon_default,
|
|
3032
|
+
{
|
|
3033
|
+
iconSource: DownArrowSolidXsmallIcon,
|
|
3034
|
+
color: sizeVar === "L" ? "neutral700" : "neutral400",
|
|
3035
|
+
sizeVar: "XS"
|
|
3036
|
+
}
|
|
3037
|
+
)
|
|
2973
3038
|
}
|
|
2974
3039
|
)
|
|
2975
3040
|
] }))
|
|
@@ -3016,7 +3081,7 @@ var Dropdown = ({
|
|
|
3016
3081
|
height: triggerRef.offsetHeight
|
|
3017
3082
|
});
|
|
3018
3083
|
}
|
|
3019
|
-
}, [triggerRef]);
|
|
3084
|
+
}, [triggerRef, width]);
|
|
3020
3085
|
useEffect(() => {
|
|
3021
3086
|
if (initialIsOpen === void 0) {
|
|
3022
3087
|
return;
|
|
@@ -3040,6 +3105,13 @@ var Dropdown = ({
|
|
|
3040
3105
|
Dropdown.Button = DropdownTriggerButton;
|
|
3041
3106
|
Dropdown.Content = DropdownContent;
|
|
3042
3107
|
var Dropdown_default = Dropdown;
|
|
3108
|
+
|
|
3109
|
+
// src/components/Dropdown/Dropdown.types.ts
|
|
3110
|
+
var DropdownOptionVariants = {
|
|
3111
|
+
CLICK: "CLICK",
|
|
3112
|
+
OUTSIDE_CLICK: "OUTSIDE_CLICK",
|
|
3113
|
+
NONE: "NONE"
|
|
3114
|
+
};
|
|
3043
3115
|
var StyledList = styled6.li`
|
|
3044
3116
|
display: flex;
|
|
3045
3117
|
flex-direction: row;
|
|
@@ -3427,6 +3499,75 @@ var assetFunction = (iconName, domainProps) => {
|
|
|
3427
3499
|
const ShoplIcon = ShoplAssets[iconName];
|
|
3428
3500
|
return domain === "hada" ? HadaIcon : ShoplIcon;
|
|
3429
3501
|
};
|
|
3502
|
+
var getBorderColorByStatus2 = ({ isFocused, isError, isHovered, disabled }) => {
|
|
3503
|
+
if (!disabled) {
|
|
3504
|
+
if (isError) {
|
|
3505
|
+
return colorTokens.red300;
|
|
3506
|
+
}
|
|
3507
|
+
if (isFocused) {
|
|
3508
|
+
return colorTokens.primary300;
|
|
3509
|
+
}
|
|
3510
|
+
if (isHovered) {
|
|
3511
|
+
return colorTokens.neutral700;
|
|
3512
|
+
}
|
|
3513
|
+
}
|
|
3514
|
+
return colorTokens.neutral300;
|
|
3515
|
+
};
|
|
3516
|
+
var getStyleByType2 = ({
|
|
3517
|
+
type,
|
|
3518
|
+
height,
|
|
3519
|
+
minHeight,
|
|
3520
|
+
maxHeight,
|
|
3521
|
+
width,
|
|
3522
|
+
minWidth,
|
|
3523
|
+
maxWidth,
|
|
3524
|
+
borderRadius,
|
|
3525
|
+
customNumberInputHeight
|
|
3526
|
+
}) => {
|
|
3527
|
+
if (type === "number") {
|
|
3528
|
+
return css`
|
|
3529
|
+
width: ${width || "64px"};
|
|
3530
|
+
height: ${customNumberInputHeight || "32px"};
|
|
3531
|
+
border-radius: ${borderRadius ? borderRadiusTokens[borderRadius] : "6px"};
|
|
3532
|
+
`;
|
|
3533
|
+
}
|
|
3534
|
+
return css`
|
|
3535
|
+
width: ${width || "100%"};
|
|
3536
|
+
min-width: ${minWidth || "initial"};
|
|
3537
|
+
max-width: ${maxWidth || "initial"};
|
|
3538
|
+
height: ${height || "initial"};
|
|
3539
|
+
min-height: ${minHeight || "initial"};
|
|
3540
|
+
max-height: ${maxHeight || "initial"};
|
|
3541
|
+
border-radius: ${borderRadius ? borderRadiusTokens[borderRadius] : "6px"};
|
|
3542
|
+
`;
|
|
3543
|
+
};
|
|
3544
|
+
var InputWrapper = styled6.label`
|
|
3545
|
+
position: relative;
|
|
3546
|
+
display: flex;
|
|
3547
|
+
align-items: center;
|
|
3548
|
+
border-radius: 6px;
|
|
3549
|
+
flex-direction: ${({ direction }) => direction || "row"};
|
|
3550
|
+
${({ type, height, minHeight, maxHeight, width, maxWidth, minWidth, borderRadius, customNumberInputHeight }) => getStyleByType2({
|
|
3551
|
+
customNumberInputHeight,
|
|
3552
|
+
type,
|
|
3553
|
+
height,
|
|
3554
|
+
minHeight,
|
|
3555
|
+
maxHeight,
|
|
3556
|
+
width,
|
|
3557
|
+
maxWidth,
|
|
3558
|
+
minWidth,
|
|
3559
|
+
borderRadius
|
|
3560
|
+
})};
|
|
3561
|
+
justify-content: space-between;
|
|
3562
|
+
gap: ${({ gap }) => gap || "8px"};
|
|
3563
|
+
border: 1px solid ${(props) => getBorderColorByStatus2(props)};
|
|
3564
|
+
background-color: ${colorTokens.neutral0};
|
|
3565
|
+
overflow: hidden;
|
|
3566
|
+
${({ disabled }) => disabled && css`
|
|
3567
|
+
background-color: ${colorTokens.neutral100};
|
|
3568
|
+
cursor: not-allowed;
|
|
3569
|
+
`};
|
|
3570
|
+
`;
|
|
3430
3571
|
|
|
3431
3572
|
// src/components/Inputs/Input/utils/getNumberLimiteRange.ts
|
|
3432
3573
|
var getNumberLimitRange = (value, min, max) => {
|
|
@@ -6387,4 +6528,4 @@ classnames/index.js:
|
|
|
6387
6528
|
*)
|
|
6388
6529
|
*/
|
|
6389
6530
|
|
|
6390
|
-
export { AnnualDatepicker_default as AnnualDatepicker, Avatar_default as Avatar, AvatarSizeVariants, Button_default as Button, ButtonSizeVariants, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout_default as Callout, CalloutTypes, Checkbox_default as Checkbox, CheckboxStyleVariants, ChipButton_default as ChipButton, ChipButtonSizeVariants, ChipButtonStyleVariants, ChipToggle_default as ChipToggle, ChipToggleSizeVariants, ChipToggleStyleVariants, DayDatepicker_default as DayDatepicker, DayDatepickerSizeVariants, Dropdown_default as Dropdown, DropdownButton_default as DropdownButton, DropdownButtonContext, DropdownButtonSizeVariants, DropdownButtonStyleVariants, Icon_default as Icon, IconButton_default as IconButton, IconButtonSizeVariants, IconButtonStyleVariants, IconSizeVariants, Input_default as Input, InputButton_default as InputButton, InputSizeVariants, List_default as List, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu_default as Menu, MenuSizeVariants, MinusButton_default as MinusButton, Modal, ModalContext, ModalHandlerContext, ModalPortal_default as ModalProvider, ModalSize, MonthDatepicker_default as MonthDatepicker, MotionStack, MotionStackContainer, NumberCombobox_default as NumberCombobox, NumberComboboxSizeVariants, Pagination_default as Pagination, Popper_default as Popper, PopperPortal, PopperTrigger, RADIO_SYMBOL_KEY, Radio_default as Radio, ScrollArea_default as ScrollArea, SelectInputButton_default as SelectInputButton, ShoplflowProvider_default as ShoplflowProvider, SplitButton_default as SplitButton, SplitButtonContext, SplitButtonSizeVariants, SplitButtonStyleVariants, Stack_default as Stack, StackContainer_default as StackContainer, StyledIcon, StyledStack, StyledStackContainer, Switch_default as Switch, TREE_SYMBOL_KEY, TabSizeVariants, TabStyleVariants, Tabs_default as Tabs, TabsContext, Tag_default as Tag, TagSizeVariants, TagStyleVariants, Text_default as Text, Text2Rows, TextArea_default as TextArea, ToggleButton_default as ToggleButton, ToggleButtonSizeVariants, Tooltip_default as Tooltip, Tree_default as Tree, TreeItem, WeekDatepicker_default as WeekDatepicker, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|
|
6531
|
+
export { AnnualDatepicker_default as AnnualDatepicker, Avatar_default as Avatar, AvatarSizeVariants, Button_default as Button, ButtonSizeVariants, ButtonStyleVariants, CHECKBOX_SYMBOL_KEY, Callout_default as Callout, CalloutTypes, Checkbox_default as Checkbox, CheckboxStyleVariants, ChipButton_default as ChipButton, ChipButtonSizeVariants, ChipButtonStyleVariants, ChipToggle_default as ChipToggle, ChipToggleSizeVariants, ChipToggleStyleVariants, DayDatepicker_default as DayDatepicker, DayDatepickerSizeVariants, Dropdown_default as Dropdown, DropdownButton_default as DropdownButton, DropdownButtonContext, DropdownButtonSizeVariants, DropdownButtonStyleVariants, DropdownOptionVariants, Icon_default as Icon, IconButton_default as IconButton, IconButtonSizeVariants, IconButtonStyleVariants, IconSizeVariants, Input_default as Input, InputButton_default as InputButton, InputSizeVariants, List_default as List, MODAL_FOOTER_KEY, MODAL_HEADER_KEY, Menu_default as Menu, MenuSizeVariants, MinusButton_default as MinusButton, Modal, ModalContext, ModalHandlerContext, ModalPortal_default as ModalProvider, ModalSize, MonthDatepicker_default as MonthDatepicker, MotionStack, MotionStackContainer, NumberCombobox_default as NumberCombobox, NumberComboboxSizeVariants, Pagination_default as Pagination, Popper_default as Popper, PopperPortal, PopperTrigger, RADIO_SYMBOL_KEY, Radio_default as Radio, ScrollArea_default as ScrollArea, SelectInputButton_default as SelectInputButton, ShoplflowProvider_default as ShoplflowProvider, SplitButton_default as SplitButton, SplitButtonContext, SplitButtonSizeVariants, SplitButtonStyleVariants, Stack_default as Stack, StackContainer_default as StackContainer, StyledIcon, StyledStack, StyledStackContainer, Switch_default as Switch, TREE_SYMBOL_KEY, TabSizeVariants, TabStyleVariants, Tabs_default as Tabs, TabsContext, Tag_default as Tag, TagSizeVariants, TagStyleVariants, Text_default as Text, Text2Rows, TextArea_default as TextArea, ToggleButton_default as ToggleButton, ToggleButtonSizeVariants, Tooltip_default as Tooltip, Tree_default as Tree, TreeItem, WeekDatepicker_default as WeekDatepicker, borderRadiusTokens, boxShadowTokens, colorTokens, fontWeightTokens, getDomain, spacingTokens, typographyTokens, useDomain, useDropdownButtonContext, useHandleModal, useModalValue, useSplitButtonContext, useTabs };
|