kiban-design-system 1.0.276-alpha.0 → 1.0.278-alpha.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.js
CHANGED
|
@@ -10011,7 +10011,18 @@ const Item$3 = ({ label, isDisabled, icon, onClick, isActive: isActiveProp, subN
|
|
|
10011
10011
|
}, [location, isExact, isActiveProp, url]);
|
|
10012
10012
|
useEffect(() => {
|
|
10013
10013
|
if (isActive && subNavigationItems) {
|
|
10014
|
-
setCurrentTierItems === null || setCurrentTierItems === void 0 ? void 0 : setCurrentTierItems(subNavigationItems || [],
|
|
10014
|
+
setCurrentTierItems === null || setCurrentTierItems === void 0 ? void 0 : setCurrentTierItems(subNavigationItems || [], {
|
|
10015
|
+
label,
|
|
10016
|
+
url,
|
|
10017
|
+
isDisabled,
|
|
10018
|
+
isActive: isActiveProp,
|
|
10019
|
+
subNavigationItems: subNavigationItems || [],
|
|
10020
|
+
truncateText,
|
|
10021
|
+
anchorProps,
|
|
10022
|
+
isExternal,
|
|
10023
|
+
isExact,
|
|
10024
|
+
isVisible,
|
|
10025
|
+
});
|
|
10015
10026
|
}
|
|
10016
10027
|
}, [isActive]);
|
|
10017
10028
|
const labelMarkup = label ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$p}__Label` }, { children: label }), void 0)) : null;
|
|
@@ -10021,7 +10032,18 @@ const Item$3 = ({ label, isDisabled, icon, onClick, isActive: isActiveProp, subN
|
|
|
10021
10032
|
if (!isDisabled) {
|
|
10022
10033
|
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
10023
10034
|
if (!isSubNavigation) {
|
|
10024
|
-
setCurrentTierItems === null || setCurrentTierItems === void 0 ? void 0 : setCurrentTierItems(subNavigationItems || [],
|
|
10035
|
+
setCurrentTierItems === null || setCurrentTierItems === void 0 ? void 0 : setCurrentTierItems(subNavigationItems || [], {
|
|
10036
|
+
label,
|
|
10037
|
+
url,
|
|
10038
|
+
isDisabled,
|
|
10039
|
+
isActive: isActiveProp,
|
|
10040
|
+
subNavigationItems: subNavigationItems || [],
|
|
10041
|
+
truncateText,
|
|
10042
|
+
anchorProps,
|
|
10043
|
+
isExternal,
|
|
10044
|
+
isExact,
|
|
10045
|
+
isVisible,
|
|
10046
|
+
});
|
|
10025
10047
|
}
|
|
10026
10048
|
}
|
|
10027
10049
|
};
|
|
@@ -10091,16 +10113,18 @@ const AlphaSideMenu = ({ children, collapsed, anchorComponent, collapseExpandIco
|
|
|
10091
10113
|
}
|
|
10092
10114
|
});
|
|
10093
10115
|
const cssClassNames = cssClassName(COMPONENT_NAME$m, isCollapsed && 'isCollapsed');
|
|
10094
|
-
const handleSetCurrentTierItems = (items,
|
|
10095
|
-
if (!
|
|
10096
|
-
|
|
10097
|
-
|
|
10098
|
-
|
|
10099
|
-
|
|
10116
|
+
const handleSetCurrentTierItems = (items, item) => {
|
|
10117
|
+
if (!(item === null || item === void 0 ? void 0 : item.isExternal)) {
|
|
10118
|
+
if (!items.length) {
|
|
10119
|
+
setSubNavigationTierItems([]);
|
|
10120
|
+
setSubNavigationTierTitle(undefined);
|
|
10121
|
+
setIsCollapsed(false);
|
|
10122
|
+
return;
|
|
10123
|
+
}
|
|
10124
|
+
setSubNavigationTierItems(items);
|
|
10125
|
+
setSubNavigationTierTitle(item === null || item === void 0 ? void 0 : item.label);
|
|
10126
|
+
setIsCollapsed(true);
|
|
10100
10127
|
}
|
|
10101
|
-
setSubNavigationTierItems(items);
|
|
10102
|
-
setSubNavigationTierTitle(title);
|
|
10103
|
-
setIsCollapsed(true);
|
|
10104
10128
|
};
|
|
10105
10129
|
const handleExpand = () => {
|
|
10106
10130
|
setIsCollapsed(!isCollapsed);
|
|
@@ -30662,7 +30686,7 @@ const AlphaGraphicCard = ({ data }) => {
|
|
|
30662
30686
|
};
|
|
30663
30687
|
|
|
30664
30688
|
const COMPONENT_NAME = 'AlphaZipCodeInput';
|
|
30665
|
-
const AlphaZipCodeInput = ({ label, isRequired, items, onBlur, onFocus, onChange, value, labelEmpty, loading, }) => {
|
|
30689
|
+
const AlphaZipCodeInput = ({ label, isRequired, items, onBlur, onFocus, onChange, value, labelEmpty, loading, placeholder, }) => {
|
|
30666
30690
|
const [isFocusActive, setIsFocusActive] = useState(false);
|
|
30667
30691
|
const [showPopover, setShowPopover] = useState(false);
|
|
30668
30692
|
const handleOnBlur = () => {
|
|
@@ -30685,7 +30709,7 @@ const AlphaZipCodeInput = ({ label, isRequired, items, onBlur, onFocus, onChange
|
|
|
30685
30709
|
};
|
|
30686
30710
|
const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME}__LabelWrapper` }, { children: jsxs("label", Object.assign({ className: `${COMPONENT_NAME}__Label` }, { children: [label, isRequired ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME}__Label--isRequired` }, { children: "*" }), void 0)) : null] }), void 0) }), void 0)) : null;
|
|
30687
30711
|
const classesInput = cssClassName(`${COMPONENT_NAME}__InputWrapper`, isFocusActive && 'isFocus', loading && 'loading');
|
|
30688
|
-
const inputMarkup = (jsx("div", Object.assign({ className: classesInput }, { children: jsx("input", { className: `${COMPONENT_NAME}__InputWrapper--input`, onBlur: handleOnBlur, onFocus: handleOnFocus, onChange: handleOnChange, maxLength: 5, value: value }, void 0) }), void 0));
|
|
30712
|
+
const inputMarkup = (jsx("div", Object.assign({ className: classesInput }, { children: jsx("input", { className: `${COMPONENT_NAME}__InputWrapper--input`, onBlur: handleOnBlur, onFocus: handleOnFocus, onChange: handleOnChange, maxLength: 5, value: value, placeholder: placeholder }, void 0) }), void 0));
|
|
30689
30713
|
const handleOnSelectItem = (item) => {
|
|
30690
30714
|
if (onChange)
|
|
30691
30715
|
onChange(item[0]);
|