@shoplflow/base 0.46.6 → 0.46.8
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 +59 -20
- package/dist/index.d.cts +5 -3
- package/dist/index.d.ts +5 -3
- package/dist/index.js +60 -21
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -3038,6 +3038,60 @@ var StyledCalloutIcon = styled6__default.default.svg`
|
|
|
3038
3038
|
styled6__default.default.div`
|
|
3039
3039
|
padding: 2px 0;
|
|
3040
3040
|
`;
|
|
3041
|
+
styled6__default.default.div``;
|
|
3042
|
+
var BulletDot = styled6__default.default.span`
|
|
3043
|
+
margin-top: 8px;
|
|
3044
|
+
width: 3px;
|
|
3045
|
+
height: 3px;
|
|
3046
|
+
border-radius: 50%;
|
|
3047
|
+
flex-shrink: 0;
|
|
3048
|
+
background-color: ${({ color = "neutral700" }) => exports.colorTokens[color]};
|
|
3049
|
+
`;
|
|
3050
|
+
var BulletHelperText = (_a) => {
|
|
3051
|
+
var _b = _a, { color = "neutral700", children } = _b, rest = __objRest(_b, ["color", "children"]);
|
|
3052
|
+
const getChildren = () => {
|
|
3053
|
+
if (typeof children === "string") {
|
|
3054
|
+
return /* @__PURE__ */ jsxRuntime.jsx(exports.Text, __spreadProps(__spreadValues({ typography: "paragraph2", color }, rest), { children }));
|
|
3055
|
+
}
|
|
3056
|
+
return children;
|
|
3057
|
+
};
|
|
3058
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(exports.StackContainer.Horizontal, { spacing: "spacing06", width: "100%", justify: "flex-start", minHeight: "20px", children: [
|
|
3059
|
+
/* @__PURE__ */ jsxRuntime.jsx(BulletDot, { color }),
|
|
3060
|
+
getChildren()
|
|
3061
|
+
] });
|
|
3062
|
+
};
|
|
3063
|
+
var NormalHelperText = (_a) => {
|
|
3064
|
+
var _b = _a, { color, position, children } = _b, rest = __objRest(_b, ["color", "position", "children"]);
|
|
3065
|
+
const getPositionStyle = React3.useCallback(() => {
|
|
3066
|
+
switch (position) {
|
|
3067
|
+
case "PRESET-TOP":
|
|
3068
|
+
return {
|
|
3069
|
+
marginTop: "8px"
|
|
3070
|
+
};
|
|
3071
|
+
case "PRESET-BOTTOM":
|
|
3072
|
+
return {
|
|
3073
|
+
marginBottom: "8px"
|
|
3074
|
+
};
|
|
3075
|
+
default:
|
|
3076
|
+
return;
|
|
3077
|
+
}
|
|
3078
|
+
}, [position]);
|
|
3079
|
+
const getChildren = () => {
|
|
3080
|
+
if (typeof children === "string") {
|
|
3081
|
+
return /* @__PURE__ */ jsxRuntime.jsx(exports.Text, __spreadProps(__spreadValues({ color, typography: "caption_400" }, rest), { children }));
|
|
3082
|
+
}
|
|
3083
|
+
return children;
|
|
3084
|
+
};
|
|
3085
|
+
return /* @__PURE__ */ jsxRuntime.jsx(exports.StackContainer.Vertical, { width: "100%", spacing: "spacing04", style: getPositionStyle(), children: getChildren() });
|
|
3086
|
+
};
|
|
3087
|
+
var HelperText = (_a) => {
|
|
3088
|
+
var _b = _a, { type = "NORMAL", position = "PRESET-TOP", color = "neutral700" } = _b, rest = __objRest(_b, ["type", "position", "color"]);
|
|
3089
|
+
if (type === "BULLET") {
|
|
3090
|
+
return /* @__PURE__ */ jsxRuntime.jsx(BulletHelperText, __spreadValues({ color }, rest));
|
|
3091
|
+
}
|
|
3092
|
+
return /* @__PURE__ */ jsxRuntime.jsx(NormalHelperText, __spreadValues({ color, position }, rest));
|
|
3093
|
+
};
|
|
3094
|
+
var HelperText_default = HelperText;
|
|
3041
3095
|
var Callout = (_a) => {
|
|
3042
3096
|
var _b = _a, { children, styleVar = "INFORMATION", fillWidth } = _b, rest = __objRest(_b, ["children", "styleVar", "fillWidth"]);
|
|
3043
3097
|
return /* @__PURE__ */ jsxRuntime.jsx(StyledCallout, __spreadProps(__spreadValues({}, rest), { styleVar, "data-shoplflow": "Callout", fillWidth, children }));
|
|
@@ -3046,23 +3100,8 @@ var CalloutText = (_a) => {
|
|
|
3046
3100
|
var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
|
|
3047
3101
|
return /* @__PURE__ */ jsxRuntime.jsx(exports.Text, __spreadProps(__spreadValues({}, rest), { typography: "paragraph2", children }));
|
|
3048
3102
|
};
|
|
3049
|
-
var CalloutBulletList = ({ children }) => {
|
|
3050
|
-
return /* @__PURE__ */ jsxRuntime.
|
|
3051
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
3052
|
-
"div",
|
|
3053
|
-
{
|
|
3054
|
-
style: {
|
|
3055
|
-
marginTop: "8px",
|
|
3056
|
-
backgroundColor: exports.colorTokens.neutral700,
|
|
3057
|
-
width: "3px",
|
|
3058
|
-
height: "3px",
|
|
3059
|
-
borderRadius: "50%",
|
|
3060
|
-
flexShrink: 0
|
|
3061
|
-
}
|
|
3062
|
-
}
|
|
3063
|
-
),
|
|
3064
|
-
children
|
|
3065
|
-
] });
|
|
3103
|
+
var CalloutBulletList = ({ children, color = "neutral700" }) => {
|
|
3104
|
+
return /* @__PURE__ */ jsxRuntime.jsx(HelperText_default, { type: "BULLET", color, children });
|
|
3066
3105
|
};
|
|
3067
3106
|
var CalloutIcon = ({ iconSource, color }) => {
|
|
3068
3107
|
return /* @__PURE__ */ jsxRuntime.jsx(StyledCalloutIcon, { as: iconSource, color });
|
|
@@ -3080,7 +3119,7 @@ exports.CalloutTypes = {
|
|
|
3080
3119
|
};
|
|
3081
3120
|
|
|
3082
3121
|
// src/components/Callout/version.ts
|
|
3083
|
-
exports.CALLOUT_VERSION = "2.1.
|
|
3122
|
+
exports.CALLOUT_VERSION = "2.1.4";
|
|
3084
3123
|
var StyledDropdown = styled6__default.default.div`
|
|
3085
3124
|
width: ${({ width }) => width};
|
|
3086
3125
|
`;
|
|
@@ -6605,7 +6644,7 @@ var WeekDatepicker = ({
|
|
|
6605
6644
|
maxDate,
|
|
6606
6645
|
onlySingleWeek
|
|
6607
6646
|
}) => {
|
|
6608
|
-
const year =
|
|
6647
|
+
const year = initStartDate ? dateFns.getISOWeekYear(initStartDate) : dateFns.getISOWeekYear(/* @__PURE__ */ new Date());
|
|
6609
6648
|
const [currentDate, setCurrentDate] = React3.useState(new Date(year, 5, 5));
|
|
6610
6649
|
const [selectedStartWeekAndYear, setSelectedStartWeekAndYear] = React3.useState(
|
|
6611
6650
|
initStartDate ? [dateFns.getISOWeek(initStartDate || /* @__PURE__ */ new Date()), dateFns.getISOWeekYear(initStartDate || /* @__PURE__ */ new Date())] : null
|
|
@@ -6771,7 +6810,7 @@ var WeekDatepicker = ({
|
|
|
6771
6810
|
exports.WeekDatepicker = WeekDatepicker;
|
|
6772
6811
|
|
|
6773
6812
|
// src/components/Datepickers/version.ts
|
|
6774
|
-
exports.DATEPICKERS_VERSION = "2.0.
|
|
6813
|
+
exports.DATEPICKERS_VERSION = "2.0.2";
|
|
6775
6814
|
var StyledNumberCombobox = styled6__default.default.div``;
|
|
6776
6815
|
var IconWrapper2 = styled6__default.default(framerMotion.motion.div)`
|
|
6777
6816
|
display: flex;
|
package/dist/index.d.cts
CHANGED
|
@@ -788,11 +788,13 @@ declare const Callout: {
|
|
|
788
788
|
({ children, styleVar, fillWidth, ...rest }: CalloutProps): react_jsx_runtime.JSX.Element;
|
|
789
789
|
Text: ({ children, ...rest }: TextProps) => react_jsx_runtime.JSX.Element;
|
|
790
790
|
Icon: ({ iconSource, color }: CalloutIconProps) => react_jsx_runtime.JSX.Element;
|
|
791
|
-
BulletList: ({ children }: ChildrenProps
|
|
791
|
+
BulletList: ({ children, color }: ChildrenProps & {
|
|
792
|
+
color?: ColorTokens;
|
|
793
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
792
794
|
};
|
|
793
795
|
|
|
794
796
|
/** @internal 컴포넌트 메타데이터: 버전 */
|
|
795
|
-
declare const CALLOUT_VERSION = "2.1.
|
|
797
|
+
declare const CALLOUT_VERSION = "2.1.4";
|
|
796
798
|
|
|
797
799
|
interface PopperProps extends PopperOptionProps {
|
|
798
800
|
}
|
|
@@ -1651,7 +1653,7 @@ type YearSelectProps = {
|
|
|
1651
1653
|
};
|
|
1652
1654
|
|
|
1653
1655
|
/** @internal 컴포넌트 메타데이터: 버전 */
|
|
1654
|
-
declare const DATEPICKERS_VERSION = "2.0.
|
|
1656
|
+
declare const DATEPICKERS_VERSION = "2.0.2";
|
|
1655
1657
|
|
|
1656
1658
|
declare const NumberComboboxSizeVariants: {
|
|
1657
1659
|
readonly S: "S";
|
package/dist/index.d.ts
CHANGED
|
@@ -788,11 +788,13 @@ declare const Callout: {
|
|
|
788
788
|
({ children, styleVar, fillWidth, ...rest }: CalloutProps): react_jsx_runtime.JSX.Element;
|
|
789
789
|
Text: ({ children, ...rest }: TextProps) => react_jsx_runtime.JSX.Element;
|
|
790
790
|
Icon: ({ iconSource, color }: CalloutIconProps) => react_jsx_runtime.JSX.Element;
|
|
791
|
-
BulletList: ({ children }: ChildrenProps
|
|
791
|
+
BulletList: ({ children, color }: ChildrenProps & {
|
|
792
|
+
color?: ColorTokens;
|
|
793
|
+
}) => react_jsx_runtime.JSX.Element;
|
|
792
794
|
};
|
|
793
795
|
|
|
794
796
|
/** @internal 컴포넌트 메타데이터: 버전 */
|
|
795
|
-
declare const CALLOUT_VERSION = "2.1.
|
|
797
|
+
declare const CALLOUT_VERSION = "2.1.4";
|
|
796
798
|
|
|
797
799
|
interface PopperProps extends PopperOptionProps {
|
|
798
800
|
}
|
|
@@ -1651,7 +1653,7 @@ type YearSelectProps = {
|
|
|
1651
1653
|
};
|
|
1652
1654
|
|
|
1653
1655
|
/** @internal 컴포넌트 메타데이터: 버전 */
|
|
1654
|
-
declare const DATEPICKERS_VERSION = "2.0.
|
|
1656
|
+
declare const DATEPICKERS_VERSION = "2.0.2";
|
|
1655
1657
|
|
|
1656
1658
|
declare const NumberComboboxSizeVariants: {
|
|
1657
1659
|
readonly S: "S";
|
package/dist/index.js
CHANGED
|
@@ -18,7 +18,7 @@ import DatePicker2 from 'react-datepicker';
|
|
|
18
18
|
import 'react-datepicker/dist/react-datepicker.css';
|
|
19
19
|
import SimpleBarReact from 'simplebar-react';
|
|
20
20
|
import { ko } from 'date-fns/locale';
|
|
21
|
-
import {
|
|
21
|
+
import { getISOWeekYear, getISOWeek, startOfMonth, endOfMonth, differenceInCalendarMonths, getISOWeeksInYear, differenceInCalendarISOWeeks, startOfISOWeek, addWeeks, endOfISOWeek } from 'date-fns';
|
|
22
22
|
|
|
23
23
|
var __create = Object.create;
|
|
24
24
|
var __defProp = Object.defineProperty;
|
|
@@ -3011,6 +3011,60 @@ var StyledCalloutIcon = styled6.svg`
|
|
|
3011
3011
|
styled6.div`
|
|
3012
3012
|
padding: 2px 0;
|
|
3013
3013
|
`;
|
|
3014
|
+
styled6.div``;
|
|
3015
|
+
var BulletDot = styled6.span`
|
|
3016
|
+
margin-top: 8px;
|
|
3017
|
+
width: 3px;
|
|
3018
|
+
height: 3px;
|
|
3019
|
+
border-radius: 50%;
|
|
3020
|
+
flex-shrink: 0;
|
|
3021
|
+
background-color: ${({ color = "neutral700" }) => colorTokens[color]};
|
|
3022
|
+
`;
|
|
3023
|
+
var BulletHelperText = (_a) => {
|
|
3024
|
+
var _b = _a, { color = "neutral700", children } = _b, rest = __objRest(_b, ["color", "children"]);
|
|
3025
|
+
const getChildren = () => {
|
|
3026
|
+
if (typeof children === "string") {
|
|
3027
|
+
return /* @__PURE__ */ jsx(Text_default, __spreadProps(__spreadValues({ typography: "paragraph2", color }, rest), { children }));
|
|
3028
|
+
}
|
|
3029
|
+
return children;
|
|
3030
|
+
};
|
|
3031
|
+
return /* @__PURE__ */ jsxs(StackContainer_default.Horizontal, { spacing: "spacing06", width: "100%", justify: "flex-start", minHeight: "20px", children: [
|
|
3032
|
+
/* @__PURE__ */ jsx(BulletDot, { color }),
|
|
3033
|
+
getChildren()
|
|
3034
|
+
] });
|
|
3035
|
+
};
|
|
3036
|
+
var NormalHelperText = (_a) => {
|
|
3037
|
+
var _b = _a, { color, position, children } = _b, rest = __objRest(_b, ["color", "position", "children"]);
|
|
3038
|
+
const getPositionStyle = useCallback(() => {
|
|
3039
|
+
switch (position) {
|
|
3040
|
+
case "PRESET-TOP":
|
|
3041
|
+
return {
|
|
3042
|
+
marginTop: "8px"
|
|
3043
|
+
};
|
|
3044
|
+
case "PRESET-BOTTOM":
|
|
3045
|
+
return {
|
|
3046
|
+
marginBottom: "8px"
|
|
3047
|
+
};
|
|
3048
|
+
default:
|
|
3049
|
+
return;
|
|
3050
|
+
}
|
|
3051
|
+
}, [position]);
|
|
3052
|
+
const getChildren = () => {
|
|
3053
|
+
if (typeof children === "string") {
|
|
3054
|
+
return /* @__PURE__ */ jsx(Text_default, __spreadProps(__spreadValues({ color, typography: "caption_400" }, rest), { children }));
|
|
3055
|
+
}
|
|
3056
|
+
return children;
|
|
3057
|
+
};
|
|
3058
|
+
return /* @__PURE__ */ jsx(StackContainer_default.Vertical, { width: "100%", spacing: "spacing04", style: getPositionStyle(), children: getChildren() });
|
|
3059
|
+
};
|
|
3060
|
+
var HelperText = (_a) => {
|
|
3061
|
+
var _b = _a, { type = "NORMAL", position = "PRESET-TOP", color = "neutral700" } = _b, rest = __objRest(_b, ["type", "position", "color"]);
|
|
3062
|
+
if (type === "BULLET") {
|
|
3063
|
+
return /* @__PURE__ */ jsx(BulletHelperText, __spreadValues({ color }, rest));
|
|
3064
|
+
}
|
|
3065
|
+
return /* @__PURE__ */ jsx(NormalHelperText, __spreadValues({ color, position }, rest));
|
|
3066
|
+
};
|
|
3067
|
+
var HelperText_default = HelperText;
|
|
3014
3068
|
var Callout = (_a) => {
|
|
3015
3069
|
var _b = _a, { children, styleVar = "INFORMATION", fillWidth } = _b, rest = __objRest(_b, ["children", "styleVar", "fillWidth"]);
|
|
3016
3070
|
return /* @__PURE__ */ jsx(StyledCallout, __spreadProps(__spreadValues({}, rest), { styleVar, "data-shoplflow": "Callout", fillWidth, children }));
|
|
@@ -3019,23 +3073,8 @@ var CalloutText = (_a) => {
|
|
|
3019
3073
|
var _b = _a, { children } = _b, rest = __objRest(_b, ["children"]);
|
|
3020
3074
|
return /* @__PURE__ */ jsx(Text_default, __spreadProps(__spreadValues({}, rest), { typography: "paragraph2", children }));
|
|
3021
3075
|
};
|
|
3022
|
-
var CalloutBulletList = ({ children }) => {
|
|
3023
|
-
return /* @__PURE__ */
|
|
3024
|
-
/* @__PURE__ */ jsx(
|
|
3025
|
-
"div",
|
|
3026
|
-
{
|
|
3027
|
-
style: {
|
|
3028
|
-
marginTop: "8px",
|
|
3029
|
-
backgroundColor: colorTokens.neutral700,
|
|
3030
|
-
width: "3px",
|
|
3031
|
-
height: "3px",
|
|
3032
|
-
borderRadius: "50%",
|
|
3033
|
-
flexShrink: 0
|
|
3034
|
-
}
|
|
3035
|
-
}
|
|
3036
|
-
),
|
|
3037
|
-
children
|
|
3038
|
-
] });
|
|
3076
|
+
var CalloutBulletList = ({ children, color = "neutral700" }) => {
|
|
3077
|
+
return /* @__PURE__ */ jsx(HelperText_default, { type: "BULLET", color, children });
|
|
3039
3078
|
};
|
|
3040
3079
|
var CalloutIcon = ({ iconSource, color }) => {
|
|
3041
3080
|
return /* @__PURE__ */ jsx(StyledCalloutIcon, { as: iconSource, color });
|
|
@@ -3053,7 +3092,7 @@ var CalloutTypes = {
|
|
|
3053
3092
|
};
|
|
3054
3093
|
|
|
3055
3094
|
// src/components/Callout/version.ts
|
|
3056
|
-
var CALLOUT_VERSION = "2.1.
|
|
3095
|
+
var CALLOUT_VERSION = "2.1.4";
|
|
3057
3096
|
var StyledDropdown = styled6.div`
|
|
3058
3097
|
width: ${({ width }) => width};
|
|
3059
3098
|
`;
|
|
@@ -6578,7 +6617,7 @@ var WeekDatepicker = ({
|
|
|
6578
6617
|
maxDate,
|
|
6579
6618
|
onlySingleWeek
|
|
6580
6619
|
}) => {
|
|
6581
|
-
const year =
|
|
6620
|
+
const year = initStartDate ? getISOWeekYear(initStartDate) : getISOWeekYear(/* @__PURE__ */ new Date());
|
|
6582
6621
|
const [currentDate, setCurrentDate] = useState(new Date(year, 5, 5));
|
|
6583
6622
|
const [selectedStartWeekAndYear, setSelectedStartWeekAndYear] = useState(
|
|
6584
6623
|
initStartDate ? [getISOWeek(initStartDate || /* @__PURE__ */ new Date()), getISOWeekYear(initStartDate || /* @__PURE__ */ new Date())] : null
|
|
@@ -6744,7 +6783,7 @@ var WeekDatepicker = ({
|
|
|
6744
6783
|
var WeekDatepicker_default = WeekDatepicker;
|
|
6745
6784
|
|
|
6746
6785
|
// src/components/Datepickers/version.ts
|
|
6747
|
-
var DATEPICKERS_VERSION = "2.0.
|
|
6786
|
+
var DATEPICKERS_VERSION = "2.0.2";
|
|
6748
6787
|
var StyledNumberCombobox = styled6.div``;
|
|
6749
6788
|
var IconWrapper2 = styled6(motion.div)`
|
|
6750
6789
|
display: flex;
|