@shoplflow/base 0.15.2 → 0.16.0
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 +6 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.d.cts
CHANGED
|
@@ -1075,7 +1075,7 @@ interface InputButtonOptionProps extends Omit<HTMLAttributes<HTMLInputElement>,
|
|
|
1075
1075
|
/**
|
|
1076
1076
|
* 값이 삭제될 때 실행할 함수입니다.
|
|
1077
1077
|
*/
|
|
1078
|
-
onClear?: () => void;
|
|
1078
|
+
onClear?: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
1079
1079
|
onClick?: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
1080
1080
|
/**
|
|
1081
1081
|
* Input의 placeholder를 설정합니다.
|
package/dist/index.d.ts
CHANGED
|
@@ -1075,7 +1075,7 @@ interface InputButtonOptionProps extends Omit<HTMLAttributes<HTMLInputElement>,
|
|
|
1075
1075
|
/**
|
|
1076
1076
|
* 값이 삭제될 때 실행할 함수입니다.
|
|
1077
1077
|
*/
|
|
1078
|
-
onClear?: () => void;
|
|
1078
|
+
onClear?: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
1079
1079
|
onClick?: (e: MouseEvent<HTMLButtonElement>) => void;
|
|
1080
1080
|
/**
|
|
1081
1081
|
* Input의 placeholder를 설정합니다.
|
package/dist/index.js
CHANGED
|
@@ -991,8 +991,9 @@ var ChipToggle_default = ChipToggle;
|
|
|
991
991
|
// src/utils/getNextColor.ts
|
|
992
992
|
var getNextColor = (color, step = 1) => {
|
|
993
993
|
const colorName = color.replace(/[0-9]|_/g, "");
|
|
994
|
-
const
|
|
995
|
-
const
|
|
994
|
+
const colorNumberString = color.replace(/[a-z]|_/g, "");
|
|
995
|
+
const decimalColorNumber = Number(colorNumberString) * 0.01;
|
|
996
|
+
const nextColorNumber = Math.floor(decimalColorNumber) + 100 * step;
|
|
996
997
|
const nextColorToken = `${colorName}${nextColorNumber}`;
|
|
997
998
|
const colorKeysOfColorName = Object.keys(colorTokens).filter((colorToken) => colorToken.includes(colorName)).sort((a, b) => Number(a.replace(/[a-z]|_/g, "")) - Number(b.replace(/[a-z]|_/g, "")));
|
|
998
999
|
const colorTokenKeys = Object.keys(colorTokens);
|
|
@@ -2039,9 +2040,10 @@ var InputButton = forwardRef(
|
|
|
2039
2040
|
onClick && onClick(e);
|
|
2040
2041
|
}
|
|
2041
2042
|
};
|
|
2042
|
-
const handleOnClear = () => {
|
|
2043
|
+
const handleOnClear = (e) => {
|
|
2044
|
+
e.stopPropagation();
|
|
2043
2045
|
if (!disabled) {
|
|
2044
|
-
onClear && onClear();
|
|
2046
|
+
onClear && onClear(e);
|
|
2045
2047
|
setText("");
|
|
2046
2048
|
}
|
|
2047
2049
|
};
|