kiban-design-system 1.1.6-hotfix.0 → 1.1.8-hotfix.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.
Files changed (35) hide show
  1. package/dist/components/ActionList/ActionList.props.d.ts +4 -0
  2. package/dist/components/AlphaMultiSelectionPicker/AlphaMultiSelectionPicker.d.ts +4 -0
  3. package/dist/components/AlphaMultiSelectionPicker/AlphaMultiSelectionPicker.props.d.ts +14 -0
  4. package/dist/components/AlphaMultiSelectionPicker/components/Picker/Picker.d.ts +5 -0
  5. package/dist/components/{AlphaTimeSelector/components/TimePicker/TimePicker.props.d.ts → AlphaMultiSelectionPicker/components/Picker/Picker.props.d.ts} +3 -3
  6. package/dist/components/AlphaMultiSelectionPicker/components/Picker/components/List/List.props.d.ts +6 -0
  7. package/dist/components/AlphaMultiSelectionPicker/components/Picker/index.d.ts +3 -0
  8. package/dist/components/AlphaMultiSelectionPicker/components/index.d.ts +1 -0
  9. package/dist/components/AlphaMultiSelectionPicker/index.d.ts +3 -0
  10. package/dist/components/AlphaSegmentedControl/AlphaSegmentedControl.d.ts +5 -0
  11. package/dist/components/AlphaSegmentedControl/AlphaSegmentedControl.props.d.ts +14 -0
  12. package/dist/components/AlphaSegmentedControl/index.d.ts +3 -0
  13. package/dist/components/AlphaTimeSelector/TimeSelector.d.ts +1 -1
  14. package/dist/components/AlphaTimeSelector/TimeSelector.props.d.ts +14 -8
  15. package/dist/components/AlphaZipCodeInput/AlphaZipCodeInput.d.ts +5 -0
  16. package/dist/components/AlphaZipCodeInput/AlphaZipCodeInput.props.d.ts +17 -0
  17. package/dist/components/AlphaZipCodeInput/index.d.ts +3 -0
  18. package/dist/components/index.d.ts +3 -0
  19. package/dist/index.css +3 -3
  20. package/dist/index.css.map +1 -1
  21. package/dist/index.js +338 -234
  22. package/dist/index.js.map +1 -1
  23. package/dist/utils/formatFileSize.d.ts +2 -0
  24. package/dist/utils/index.d.ts +2 -1
  25. package/package.json +1 -1
  26. package/dist/components/AlphaTimeSelector/components/TimePicker/TimePicker.d.ts +0 -5
  27. package/dist/components/AlphaTimeSelector/components/TimePicker/TimePicker.test.d.ts +0 -1
  28. package/dist/components/AlphaTimeSelector/components/TimePicker/components/List/List.props.d.ts +0 -6
  29. package/dist/components/AlphaTimeSelector/components/TimePicker/components/List/List.test.d.ts +0 -1
  30. package/dist/components/AlphaTimeSelector/components/TimePicker/index.d.ts +0 -3
  31. package/dist/components/AlphaTimeSelector/components/index.d.ts +0 -1
  32. /package/dist/components/{AlphaTimeSelector/TimeSelector.test.d.ts → AlphaMultiSelectionPicker/AlphaMultiSelectionPicker.test.d.ts} +0 -0
  33. /package/dist/components/{AlphaTimeSelector/components/TimePicker → AlphaMultiSelectionPicker/components/Picker}/components/List/List.d.ts +0 -0
  34. /package/dist/components/{AlphaTimeSelector/components/TimePicker → AlphaMultiSelectionPicker/components/Picker}/components/List/index.d.ts +0 -0
  35. /package/dist/components/{AlphaTimeSelector/components/TimePicker → AlphaMultiSelectionPicker/components/Picker}/components/index.d.ts +0 -0
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import react, { createElement, createContext, useState, useEffect, useContext, isValidElement, Fragment as Fragment$1, useRef, useCallback, useMemo, Children, memo, cloneElement, useLayoutEffect, forwardRef } from 'react';
1
+ import react, { createElement, isValidElement, createContext, useState, useEffect, useContext, Fragment as Fragment$1, useRef, useCallback, useMemo, Children, memo, cloneElement, useLayoutEffect, forwardRef } from 'react';
2
2
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
3
3
  import { createPortal } from 'react-dom';
4
4
  import _extends$2 from '@babel/runtime/helpers/esm/extends';
@@ -897,6 +897,63 @@ var Icons = /*#__PURE__*/Object.freeze({
897
897
  */
898
898
  const Icon = ({ name }) => (jsx("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, { children: createElement(Icons[name]) }), void 0));
899
899
 
900
+ const isComponentTypeOf = (childComponent, parentComponent) => {
901
+ var _a;
902
+ if (childComponent === null ||
903
+ !isValidElement(childComponent) ||
904
+ typeof childComponent === 'string') {
905
+ return false;
906
+ }
907
+ const { type: childComponentType } = childComponent;
908
+ const Components = Array.isArray(parentComponent)
909
+ ? parentComponent
910
+ : [parentComponent];
911
+ const type = ((_a = childComponent.props) === null || _a === void 0 ? void 0 : _a.__type__) || childComponentType;
912
+ return Components.some((Component) => typeof type !== 'string' && type === Component);
913
+ };
914
+
915
+ function formatFileSize(bytes) {
916
+ const units = ['Bytes', 'KB', 'MB', 'GB', 'TB'];
917
+ let unitIndex = 0;
918
+ let size = bytes;
919
+ while (size >= 1024 && unitIndex < units.length - 1) {
920
+ size /= 1024;
921
+ unitIndex += 1;
922
+ }
923
+ return `${size.toFixed(2)} ${units[unitIndex]}`;
924
+ }
925
+ // eslint-disable-next-line
926
+ // code end
927
+
928
+ const cssClassName = (mainClass, ...classes) => {
929
+ const filteredClasses = classes
930
+ .filter(Boolean)
931
+ .map((clss) => `${mainClass}--${clss}`);
932
+ filteredClasses.unshift(mainClass);
933
+ return filteredClasses.join(' ');
934
+ };
935
+
936
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
937
+ const isValidIcon = (icon) => typeof icon === 'string' || typeof icon === 'function';
938
+
939
+ const themeClassConverter = (themeClass) => {
940
+ const classConverter = themeClass.charAt(0).toLocaleUpperCase() +
941
+ themeClass.slice(1).toLocaleLowerCase();
942
+ return classConverter;
943
+ };
944
+
945
+ function capitalize(str) {
946
+ return str.charAt(0).toUpperCase() + str.slice(1);
947
+ }
948
+
949
+ const SuccessIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("path", { d: 'M22 11.08V12a10 10 0 1 1-5.93-9.14' }, void 0), jsx("polyline", { points: '22 4 12 14.01 9 11.01' }, void 0)] }), void 0));
950
+
951
+ const ErrorIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("circle", { cx: '12', cy: '12', r: '10' }, void 0), jsx("line", { x1: '15', y1: '9', x2: '9', y2: '15' }, void 0), jsx("line", { x1: '9', y1: '9', x2: '15', y2: '15' }, void 0)] }), void 0));
952
+
953
+ const PendingIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("circle", { cx: '12', cy: '12', r: '10' }, void 0), jsx("line", { x1: '8', y1: '12', x2: '16', y2: '12' }, void 0)] }), void 0));
954
+
955
+ const WarningIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, { children: [jsx("path", { d: 'M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z' }, void 0), jsx("line", { x1: '12', y1: '9', x2: '12', y2: '13' }, void 0), jsx("line", { x1: '12', y1: '17', x2: '12.01', y2: '17' }, void 0)] }), void 0));
956
+
900
957
  /**
901
958
  * It is necessary to create a list that receives
902
959
  * strings or Nodes as elements, clicking on
@@ -928,7 +985,11 @@ const ActionList = ({ header, items, sections }) => {
928
985
  .join(' ');
929
986
  return (jsxs("li", Object.assign({ "aria-label": item.ariaLabel, className: classesItem, onClick: () => item.onClick && item.onClick() }, { children: [item.icon && (jsx("span", Object.assign({ className: 'Action-list__item-icon' }, { children: jsx(Icon, { name: item.icon }, void 0) }), void 0)), item.content] }), j));
930
987
  }) }), void 0)] }), i));
931
- })), items && !sections && (jsx("ul", Object.assign({ className: 'Action-list__items-container' }, { children: items === null || items === void 0 ? void 0 : items.map((item, j) => (jsxs("li", Object.assign({ "aria-label": item.ariaLabel, className: `Action-list__item ${item.isActive && 'Action-list__item-active'}`, onClick: () => item.onClick && item.onClick() }, { children: [item.icon && (jsx("span", Object.assign({ className: 'Action-list__item-icon' }, { children: jsx(Icon, { name: item.icon }, void 0) }), void 0)), item.content] }), j))) }), void 0))] }), void 0));
988
+ })), items && !sections && (jsx("ul", Object.assign({ className: 'Action-list__items-container' }, { children: items === null || items === void 0 ? void 0 : items.map((item, j) => {
989
+ const { ariaLabel, content, icon, isActive, isDisabled, onClick } = item;
990
+ const className = cssClassName('Action-list__item', isActive && 'active', isDisabled && 'disabled');
991
+ return (jsxs("li", Object.assign({ "aria-label": ariaLabel, className: className, onClick: () => onClick && !isDisabled && onClick() }, { children: [icon && (jsx("span", Object.assign({ className: 'Action-list__item-icon' }, { children: jsx(Icon, { name: icon }, void 0) }), void 0)), content] }), j));
992
+ }) }), void 0))] }), void 0));
932
993
  };
933
994
 
934
995
  const MAIN_CLASS$t = 'Alert';
@@ -1017,54 +1078,10 @@ const useShowAlert = () => {
1017
1078
  return addAlert;
1018
1079
  };
1019
1080
 
1020
- const isComponentTypeOf = (childComponent, parentComponent) => {
1021
- var _a;
1022
- if (childComponent === null ||
1023
- !isValidElement(childComponent) ||
1024
- typeof childComponent === 'string') {
1025
- return false;
1026
- }
1027
- const { type: childComponentType } = childComponent;
1028
- const Components = Array.isArray(parentComponent)
1029
- ? parentComponent
1030
- : [parentComponent];
1031
- const type = ((_a = childComponent.props) === null || _a === void 0 ? void 0 : _a.__type__) || childComponentType;
1032
- return Components.some((Component) => typeof type !== 'string' && type === Component);
1033
- };
1034
-
1035
- const cssClassName = (mainClass, ...classes) => {
1036
- const filteredClasses = classes
1037
- .filter(Boolean)
1038
- .map((clss) => `${mainClass}--${clss}`);
1039
- filteredClasses.unshift(mainClass);
1040
- return filteredClasses.join(' ');
1041
- };
1042
-
1043
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
1044
- const isValidIcon = (icon) => typeof icon === 'string' || typeof icon === 'function';
1045
-
1046
- const themeClassConverter = (themeClass) => {
1047
- const classConverter = themeClass.charAt(0).toLocaleUpperCase() +
1048
- themeClass.slice(1).toLocaleLowerCase();
1049
- return classConverter;
1050
- };
1051
-
1052
- function capitalize(str) {
1053
- return str.charAt(0).toUpperCase() + str.slice(1);
1054
- }
1055
-
1056
- const SuccessIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("path", { d: 'M22 11.08V12a10 10 0 1 1-5.93-9.14' }, void 0), jsx("polyline", { points: '22 4 12 14.01 9 11.01' }, void 0)] }), void 0));
1057
-
1058
- const ErrorIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("circle", { cx: '12', cy: '12', r: '10' }, void 0), jsx("line", { x1: '15', y1: '9', x2: '9', y2: '15' }, void 0), jsx("line", { x1: '9', y1: '9', x2: '15', y2: '15' }, void 0)] }), void 0));
1059
-
1060
- const PendingIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2' }, { children: [jsx("circle", { cx: '12', cy: '12', r: '10' }, void 0), jsx("line", { x1: '8', y1: '12', x2: '16', y2: '12' }, void 0)] }), void 0));
1061
-
1062
- const WarningIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24', viewBox: '0 0 24 24', fill: 'none', stroke: 'currentColor', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, { children: [jsx("path", { d: 'M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z' }, void 0), jsx("line", { x1: '12', y1: '9', x2: '12', y2: '13' }, void 0), jsx("line", { x1: '12', y1: '17', x2: '12.01', y2: '17' }, void 0)] }), void 0));
1063
-
1064
- const COMPONENT_NAME$A = 'AlphaAttributeInput';
1081
+ const COMPONENT_NAME$B = 'AlphaAttributeInput';
1065
1082
  const AlphaAttributeInput = ({ items, divider, label, isRequired, }) => {
1066
1083
  const [isFocused, setIsFocused] = useState(false);
1067
- const className = cssClassName(COMPONENT_NAME$A, isFocused && 'isFocused');
1084
+ const className = cssClassName(COMPONENT_NAME$B, isFocused && 'isFocused');
1068
1085
  const handleBlur = (callback) => {
1069
1086
  setIsFocused(false);
1070
1087
  if (callback) {
@@ -1083,25 +1100,25 @@ const AlphaAttributeInput = ({ items, divider, label, isRequired, }) => {
1083
1100
  item.onChange(event.target.value);
1084
1101
  }
1085
1102
  };
1086
- const itemLabelMarkup = item.label ? (jsx("label", Object.assign({ className: `${COMPONENT_NAME$A}__ItemLabelWrapper` }, { children: item.label }), void 0)) : null;
1087
- const dividerMarkup = divider && index < items.length - 1 ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$A}__Divider` }, { children: divider }), void 0)) : null;
1088
- return (jsxs(Fragment$1, { children: [jsxs("div", Object.assign({ className: `${COMPONENT_NAME$A}__Item` }, { children: [itemLabelMarkup, jsx("input", { type: item.type, value: item.value, onChange: handleChange, onBlur: () => handleBlur(item.onBlur), onFocus: () => handleFocus(item.onFocus), placeholder: item.placeholder, min: item.min, max: item.max, minLength: item.minLength, maxLength: item.maxLength }, void 0)] }), index), dividerMarkup] }, index));
1103
+ const itemLabelMarkup = item.label ? (jsx("label", Object.assign({ className: `${COMPONENT_NAME$B}__ItemLabelWrapper` }, { children: item.label }), void 0)) : null;
1104
+ const dividerMarkup = divider && index < items.length - 1 ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$B}__Divider` }, { children: divider }), void 0)) : null;
1105
+ return (jsxs(Fragment$1, { children: [jsxs("div", Object.assign({ className: `${COMPONENT_NAME$B}__Item` }, { children: [itemLabelMarkup, jsx("input", { type: item.type, value: item.value, onChange: handleChange, onBlur: () => handleBlur(item.onBlur), onFocus: () => handleFocus(item.onFocus), placeholder: item.placeholder, min: item.min, max: item.max, minLength: item.minLength, maxLength: item.maxLength }, void 0)] }), index), dividerMarkup] }, index));
1089
1106
  };
1090
- const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$A}__LabelWrapper` }, { children: jsxs("label", Object.assign({ className: `${COMPONENT_NAME$A}__Label` }, { children: [label, isRequired ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$A}__IsRequiredSign` }, { children: "*" }), void 0)) : null] }), void 0) }), void 0)) : null;
1091
- const itemsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$A}__ItemsWrapper` }, { children: items.map(renderItem) }), void 0));
1107
+ const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$B}__LabelWrapper` }, { children: jsxs("label", Object.assign({ className: `${COMPONENT_NAME$B}__Label` }, { children: [label, isRequired ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$B}__IsRequiredSign` }, { children: "*" }), void 0)) : null] }), void 0) }), void 0)) : null;
1108
+ const itemsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$B}__ItemsWrapper` }, { children: items.map(renderItem) }), void 0));
1092
1109
  return (jsxs("div", Object.assign({ className: className }, { children: [labelMarkup, itemsMarkup] }), void 0));
1093
1110
  };
1094
1111
 
1095
- const COMPONENT_NAME$z = 'AlphaBadge';
1112
+ const COMPONENT_NAME$A = 'AlphaBadge';
1096
1113
  const AlphaBadge = ({ theme: themeProp, children, isSuccess, isWarning, isDanger, isPrimary, }) => {
1097
1114
  const { theme } = useTheme();
1098
1115
  const THEME_CLASS = `${theme}`;
1099
- const className = cssClassName(COMPONENT_NAME$z, !themeProp && THEME_CLASS, isPrimary && 'isPrimary', isDanger && 'isDanger', isSuccess && 'isSuccess', isWarning && 'isWarning', themeProp && `${themeProp.toUpperCase()}`);
1100
- const childrenMarkup = children && (jsx("span", Object.assign({ className: `${COMPONENT_NAME$z}__TextWrapper` }, { children: children }), void 0));
1116
+ const className = cssClassName(COMPONENT_NAME$A, !themeProp && THEME_CLASS, isPrimary && 'isPrimary', isDanger && 'isDanger', isSuccess && 'isSuccess', isWarning && 'isWarning', themeProp && `${themeProp.toUpperCase()}`);
1117
+ const childrenMarkup = children && (jsx("span", Object.assign({ className: `${COMPONENT_NAME$A}__TextWrapper` }, { children: children }), void 0));
1101
1118
  return jsx("span", Object.assign({ className: className }, { children: childrenMarkup }), void 0);
1102
1119
  };
1103
1120
 
1104
- const COMPONENT_NAME$y = 'AlphaIcon';
1121
+ const COMPONENT_NAME$z = 'AlphaIcon';
1105
1122
  const ICON_COLOR_VARIANTS = [
1106
1123
  'danger',
1107
1124
  'darkGray',
@@ -1128,9 +1145,9 @@ const AlphaIcon = ({ source, size, color, filled, hasBackdrop, outlined, }) => {
1128
1145
  if (color && !ICON_COLOR_VARIANTS.includes(color)) {
1129
1146
  console.warn(`The color ${color} is not supported for the AlphaIcon component when hasBackdrop is true.`);
1130
1147
  }
1131
- const className = cssClassName(COMPONENT_NAME$y, color && `is-${color}`, filled && 'isFilled', outlined && 'isOutlined', size && `is-${size}`, hasBackdrop && 'hasBackdrop', source && `source-${sourceType}`);
1148
+ const className = cssClassName(COMPONENT_NAME$z, color && `is-${color}`, filled && 'isFilled', outlined && 'isOutlined', size && `is-${size}`, hasBackdrop && 'hasBackdrop', source && `source-${sourceType}`);
1132
1149
  const Source = source;
1133
- const StringSource = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$y}__StringSource` }, { children: jsx("span", { children: source }, void 0) }), void 0));
1150
+ const StringSource = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$z}__StringSource` }, { children: jsx("span", { children: source }, void 0) }), void 0));
1134
1151
  const content = {
1135
1152
  function: jsx(Source, {}, void 0),
1136
1153
  string: StringSource,
@@ -1138,9 +1155,9 @@ const AlphaIcon = ({ source, size, color, filled, hasBackdrop, outlined, }) => {
1138
1155
  return jsx("span", Object.assign({ className: className }, { children: content[sourceType] }), void 0);
1139
1156
  };
1140
1157
 
1141
- const COMPONENT_NAME$x = 'AlphaSpinner';
1158
+ const COMPONENT_NAME$y = 'AlphaSpinner';
1142
1159
  const AlphaSpinner = ({ icon, size }) => {
1143
- const className = cssClassName(COMPONENT_NAME$x);
1160
+ const className = cssClassName(COMPONENT_NAME$y);
1144
1161
  let iconSource;
1145
1162
  if (icon) {
1146
1163
  if (isValidIcon(icon.icon)) {
@@ -1150,16 +1167,16 @@ const AlphaSpinner = ({ icon, size }) => {
1150
1167
  iconSource = icon.icon;
1151
1168
  }
1152
1169
  }
1153
- const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$x}__IconWrapper` }, { children: iconSource }), void 0)) : null;
1170
+ const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$y}__IconWrapper` }, { children: iconSource }), void 0)) : null;
1154
1171
  return jsx("div", Object.assign({ className: className }, { children: iconMarkup }), void 0);
1155
1172
  };
1156
1173
 
1157
- const COMPONENT_NAME$w = 'AlphaButton';
1174
+ const COMPONENT_NAME$x = 'AlphaButton';
1158
1175
  const AlphaButton = ({ ariaLabel, children, icon, spinnerIcon, iconPosition = 'left', id, isDanger, isDisabled, isFullWidth, isLink, isLoading, isPrimary, isSubmit, isTertiary, size = 'medium', textAlign = 'center', isRounded, theme: themeProp, onClick, onFocus, onBlur, onKeyPress, onKeyUp, onKeyDown, onMouseEnter, onMouseLeave, onTouchStart, onTouchEnd, }) => {
1159
1176
  const { theme } = useTheme();
1160
1177
  const THEME_CLASS = `${theme}`;
1161
1178
  const isIconOnly = !children && icon;
1162
- const className = cssClassName(COMPONENT_NAME$w, !themeProp && THEME_CLASS, isPrimary && 'isPrimary', isDanger && 'isDanger', isTertiary && 'isTertiary', isFullWidth && 'isFullWidth', isLink && 'isLink', isDisabled && 'isDisabled', isLoading && 'isLoading', size && `is-${size}`, textAlign && `has-text-${textAlign}`, icon && `has-icon-${iconPosition}`, isIconOnly && 'onlyIcon', isIconOnly && isRounded && 'isRounded', themeProp && `${themeProp.toUpperCase()}`);
1179
+ const className = cssClassName(COMPONENT_NAME$x, !themeProp && THEME_CLASS, isPrimary && 'isPrimary', isDanger && 'isDanger', isTertiary && 'isTertiary', isFullWidth && 'isFullWidth', isLink && 'isLink', isDisabled && 'isDisabled', isLoading && 'isLoading', size && `is-${size}`, textAlign && `has-text-${textAlign}`, icon && `has-icon-${iconPosition}`, isIconOnly && 'onlyIcon', isIconOnly && isRounded && 'isRounded', themeProp && `${themeProp.toUpperCase()}`);
1163
1180
  const buttonProps = {
1164
1181
  id,
1165
1182
  type: isSubmit ? 'submit' : 'button',
@@ -1176,7 +1193,7 @@ const AlphaButton = ({ ariaLabel, children, icon, spinnerIcon, iconPosition = 'l
1176
1193
  onTouchStart,
1177
1194
  onTouchEnd,
1178
1195
  };
1179
- const childrenMarkup = children ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$w}__TextWrapper` }, { children: children }), void 0)) : null;
1196
+ const childrenMarkup = children ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$x}__TextWrapper` }, { children: children }), void 0)) : null;
1180
1197
  let iconSource;
1181
1198
  let spinnerIconSource;
1182
1199
  if (icon) {
@@ -1195,18 +1212,18 @@ const AlphaButton = ({ ariaLabel, children, icon, spinnerIcon, iconPosition = 'l
1195
1212
  spinnerIconSource = spinnerIcon.icon;
1196
1213
  }
1197
1214
  }
1198
- const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$w}__IconWrapper` }, { children: iconSource }), void 0)) : null;
1199
- const spinnerMarkup = isLoading && (jsx("span", Object.assign({ className: `${COMPONENT_NAME$w}__SpinnerWrapper` }, { children: spinnerIconSource }), void 0));
1215
+ const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$x}__IconWrapper` }, { children: iconSource }), void 0)) : null;
1216
+ const spinnerMarkup = isLoading && (jsx("span", Object.assign({ className: `${COMPONENT_NAME$x}__SpinnerWrapper` }, { children: spinnerIconSource }), void 0));
1200
1217
  return (jsxs("button", Object.assign({ className: className }, buttonProps, { children: [spinnerMarkup, iconMarkup, childrenMarkup] }), void 0));
1201
1218
  };
1202
1219
 
1203
- const COMPONENT_NAME$v = 'AlphaChip';
1220
+ const COMPONENT_NAME$w = 'AlphaChip';
1204
1221
  const AlphaChip = ({ children, hasError, removeButtonIcon, isDisabled, theme, onRemove, }) => {
1205
1222
  const { theme: currentTheme } = useTheme();
1206
1223
  const THEME_CLASS = `${currentTheme}`;
1207
- const className = cssClassName(COMPONENT_NAME$v, hasError && 'hasError', isDisabled && 'isDisabled', theme && `${theme.toUpperCase()}`, THEME_CLASS);
1208
- const childrenMarkup = children ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$v}__TextWrapper` }, { children: children }), void 0)) : null;
1209
- const closeButtonMarkup = removeButtonIcon && (jsx("div", Object.assign({ className: `${COMPONENT_NAME$v}__CloseButtonWrapper` }, { children: jsx(AlphaButton, { onClick: onRemove, icon: removeButtonIcon }, void 0) }), void 0));
1224
+ const className = cssClassName(COMPONENT_NAME$w, hasError && 'hasError', isDisabled && 'isDisabled', theme && `${theme.toUpperCase()}`, THEME_CLASS);
1225
+ const childrenMarkup = children ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$w}__TextWrapper` }, { children: children }), void 0)) : null;
1226
+ const closeButtonMarkup = removeButtonIcon && (jsx("div", Object.assign({ className: `${COMPONENT_NAME$w}__CloseButtonWrapper` }, { children: jsx(AlphaButton, { onClick: onRemove, icon: removeButtonIcon }, void 0) }), void 0));
1210
1227
  return (jsxs("div", Object.assign({ className: className }, { children: [childrenMarkup, closeButtonMarkup] }), void 0));
1211
1228
  };
1212
1229
 
@@ -1406,10 +1423,10 @@ const Panel$1 = ({ id, children, isHidden }) => {
1406
1423
  return (jsx("div", Object.assign({ className: className, id: id }, { children: children }), void 0));
1407
1424
  };
1408
1425
 
1409
- const COMPONENT_NAME$u = 'Tabs';
1426
+ const COMPONENT_NAME$v = 'Tabs';
1410
1427
  const Tabs = ({ onSelect, selected, tabs, children, className, areFitted, }) => {
1411
1428
  const { theme } = useTheme();
1412
- const classNames = cssClassName(COMPONENT_NAME$u, `is${themeClassConverter(theme)}`);
1429
+ const classNames = cssClassName(COMPONENT_NAME$v, `is${themeClassConverter(theme)}`);
1413
1430
  const panelMarkup = children
1414
1431
  ? tabs.map((tab, index) => selected === index ? (jsx(Panel$1, Object.assign({ id: tab.panelID || `${tab.id}-panel` }, { children: children }), tab.id)) : (jsx(Panel$1, { id: tab.panelID || `${tab.id}-panel`, isHidden: true }, tab.id)))
1415
1432
  : null;
@@ -1567,10 +1584,10 @@ const getPosition = (activator, tooltip, alignment) => {
1567
1584
  };
1568
1585
  };
1569
1586
 
1570
- const COMPONENT_NAME$t = 'Alpha__TooltipOverlay';
1587
+ const COMPONENT_NAME$u = 'Alpha__TooltipOverlay';
1571
1588
  const Overlay = ({ children, activator, active, zIndexOverride, position = 'bottom', appearance = 'default', width, parentTooltip, theme, onClick, }) => {
1572
1589
  const tooltipRef = useRef(null);
1573
- const overlayClassName = cssClassName(COMPONENT_NAME$t, position && `is-${position}`, appearance && `is-${appearance}`, theme && appearance === 'default' && `is-${theme}`);
1590
+ const overlayClassName = cssClassName(COMPONENT_NAME$u, position && `is-${position}`, appearance && `is-${appearance}`, theme && appearance === 'default' && `is-${theme}`);
1574
1591
  const [positionStyles, setPositionStyles] = useState({
1575
1592
  '--tooltip-overlay-top': 0,
1576
1593
  '--tooltip-overlay-left': 0,
@@ -1606,7 +1623,7 @@ const Overlay = ({ children, activator, active, zIndexOverride, position = 'bott
1606
1623
  return markup;
1607
1624
  };
1608
1625
 
1609
- const COMPONENT_NAME$s = 'AlphaTooltip';
1626
+ const COMPONENT_NAME$t = 'AlphaTooltip';
1610
1627
  const AlphaTooltip = ({ content, children, activatorWrapper = 'span', isActive: isActiveProp = false, onClose, onOpen, position, width, parentTooltip, zIndexOverride, appearance, persistence, theme, }) => {
1611
1628
  const [activatorNode, setActivatorNode] = useState(null);
1612
1629
  const [isActive, setIsActive] = useState(isActiveProp);
@@ -1614,7 +1631,7 @@ const AlphaTooltip = ({ content, children, activatorWrapper = 'span', isActive:
1614
1631
  const isMouseOver = useRef(false);
1615
1632
  const activatorContainer = useRef(null);
1616
1633
  const WrapperComponent = activatorWrapper;
1617
- const className = cssClassName(COMPONENT_NAME$s);
1634
+ const className = cssClassName(COMPONENT_NAME$t);
1618
1635
  const handleOpen = useCallback(() => {
1619
1636
  if (!isActivePersistence) {
1620
1637
  setIsActive(true);
@@ -2193,10 +2210,10 @@ const Popover$1 = ({ activator, children, isActive, onClose, isFullWidth = false
2193
2210
  };
2194
2211
  Popover$1.Pane = Pane$1;
2195
2212
 
2196
- const COMPONENT_NAME$r = 'Divider';
2213
+ const COMPONENT_NAME$s = 'Divider';
2197
2214
  const Divider = ({ alignment = 'left', label }) => {
2198
- const className = cssClassName(COMPONENT_NAME$r, alignment, !label && 'no-label');
2199
- const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$r}__LabelWrapper` }, { children: jsx("span", Object.assign({ className: `${COMPONENT_NAME$r}__Label` }, { children: label }), void 0) }), void 0)) : null;
2215
+ const className = cssClassName(COMPONENT_NAME$s, alignment, !label && 'no-label');
2216
+ const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$s}__LabelWrapper` }, { children: jsx("span", Object.assign({ className: `${COMPONENT_NAME$s}__Label` }, { children: label }), void 0) }), void 0)) : null;
2200
2217
  return jsx("div", Object.assign({ className: className }, { children: labelMarkup }), void 0);
2201
2218
  };
2202
2219
 
@@ -9690,7 +9707,7 @@ function formatDate(date, toISO) {
9690
9707
  return DateTime.fromJSDate(date).toFormat('dd/MM/yyyy');
9691
9708
  }
9692
9709
 
9693
- const COMPONENT_NAME$q = 'DateInput';
9710
+ const COMPONENT_NAME$r = 'DateInput';
9694
9711
  const AlphaInputDate = ({ ariaLabel, disabled, label, onChange, value, isRequired, placeholder, onBlur, errorMessage, months, weekdays, }) => {
9695
9712
  const [isPopoverActive, setIsPopoverActive] = useState(false);
9696
9713
  const [{ month, year }, setDate] = useState({
@@ -9701,7 +9718,7 @@ const AlphaInputDate = ({ ariaLabel, disabled, label, onChange, value, isRequire
9701
9718
  const [isErrorTooltipActive, setIsErrorTooltipActive] = useState(false);
9702
9719
  const [selectedDate, setSelectedDate] = useState();
9703
9720
  const inputRef = useRef(null);
9704
- const className = cssClassName(COMPONENT_NAME$q);
9721
+ const className = cssClassName(COMPONENT_NAME$r);
9705
9722
  const handleMonthChange = (monthValue, yearValue) => {
9706
9723
  setDate({ month: monthValue, year: yearValue });
9707
9724
  };
@@ -9823,7 +9840,7 @@ const AlphaInputDate = ({ ariaLabel, disabled, label, onChange, value, isRequire
9823
9840
  }
9824
9841
  }, [selectedDate]);
9825
9842
  const datePickerMarkup = (jsx(DatePicker, { weekStartsOn: 1, month: month, year: year, onMonthChange: handleMonthChange, onChange: handleDateChange, selected: selectedDate || undefined, months: months, weekDays: weekdays }, void 0));
9826
- const inputMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$q}__InputWrapper`, onClick: () => setIsPopoverActive(true), ref: inputRef }, { children: jsx(AlphaTooltip, Object.assign({ persistence: true, isActive: isErrorTooltipActive, content: errorMessage, appearance: 'error' }, { children: jsx(InputText, { ariaLabel: ariaLabel, disabled: disabled, label: label, onChange: handleInputChange, value: inputValue, maxLength: 10, placeholder: placeholder, onBlur: handleInputBlur, icon: 'Calendar', isRequired: isRequired }, void 0) }), void 0) }), void 0));
9843
+ const inputMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$r}__InputWrapper`, onClick: () => setIsPopoverActive(true), ref: inputRef }, { children: jsx(AlphaTooltip, Object.assign({ persistence: true, isActive: isErrorTooltipActive, content: errorMessage, appearance: 'error' }, { children: jsx(InputText, { ariaLabel: ariaLabel, disabled: disabled, label: label, onChange: handleInputChange, value: inputValue, maxLength: 10, placeholder: placeholder, onBlur: handleInputBlur, icon: 'Calendar', isRequired: isRequired }, void 0) }), void 0) }), void 0));
9827
9844
  const popoverMarkup = (jsx(Popover$1, Object.assign({ activator: inputMarkup, isActive: isPopoverActive, isFullWidth: true, onClose: () => setIsPopoverActive(false) }, { children: datePickerMarkup }), void 0));
9828
9845
  return jsx("div", Object.assign({ className: className }, { children: popoverMarkup }), void 0);
9829
9846
  };
@@ -9913,9 +9930,9 @@ const AlphaFilterControl = ({ primaryAction, secondaryActions, sections, title,
9913
9930
  return (jsxs("div", Object.assign({ className: `${MAIN_CLASS$k}` }, { children: [headerMarkup, bodyMarkup, actionsMarkup] }), void 0));
9914
9931
  };
9915
9932
 
9916
- const COMPONENT_NAME$p = 'AlphaInlineError';
9933
+ const COMPONENT_NAME$q = 'AlphaInlineError';
9917
9934
  const AlphaInlineError = ({ icon, children }) => {
9918
- const className = cssClassName(COMPONENT_NAME$p);
9935
+ const className = cssClassName(COMPONENT_NAME$q);
9919
9936
  let iconSource;
9920
9937
  if (icon) {
9921
9938
  if (isValidIcon(icon.icon)) {
@@ -9925,23 +9942,23 @@ const AlphaInlineError = ({ icon, children }) => {
9925
9942
  iconSource = icon.icon;
9926
9943
  }
9927
9944
  }
9928
- const iconMarkup = icon ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$p}__IconWrapper` }, { children: iconSource }), void 0)) : null;
9929
- const messageMarkup = children ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$p}__MessageWrapper` }, { children: children }), void 0)) : null;
9945
+ const iconMarkup = icon ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$q}__IconWrapper` }, { children: iconSource }), void 0)) : null;
9946
+ const messageMarkup = children ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$q}__MessageWrapper` }, { children: children }), void 0)) : null;
9930
9947
  return (jsxs("div", Object.assign({ className: className }, { children: [iconMarkup, messageMarkup] }), void 0));
9931
9948
  };
9932
9949
 
9933
- const COMPONENT_NAME$o = 'AlphaLabel';
9934
- const className$1 = cssClassName(COMPONENT_NAME$o);
9950
+ const COMPONENT_NAME$p = 'AlphaLabel';
9951
+ const className$1 = cssClassName(COMPONENT_NAME$p);
9935
9952
  const AlphaLabel = ({ children, isRequired, action, id }) => {
9936
- const requiredSignMarkup = isRequired ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$o}__RequiredSign` }, { children: "*" }), void 0)) : null;
9953
+ const requiredSignMarkup = isRequired ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$p}__RequiredSign` }, { children: "*" }), void 0)) : null;
9937
9954
  const labelMarkup = (jsxs("label", Object.assign({ htmlFor: id }, { children: [children, requiredSignMarkup] }), void 0));
9938
- const actionMarkup = action ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$o}__ActionWrapper` }, { children: jsx(AlphaButton, Object.assign({ id: action.id, isDanger: action.isDanger, onMouseEnter: action.onMouseEnter, onTouchStart: action.onTouchStart, isLink: true, onClick: action.onClick, isDisabled: action.isDisabled }, { children: action.content }), void 0) }), void 0)) : null;
9955
+ const actionMarkup = action ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$p}__ActionWrapper` }, { children: jsx(AlphaButton, Object.assign({ id: action.id, isDanger: action.isDanger, onMouseEnter: action.onMouseEnter, onTouchStart: action.onTouchStart, isLink: true, onClick: action.onClick, isDisabled: action.isDisabled }, { children: action.content }), void 0) }), void 0)) : null;
9939
9956
  return (jsxs("div", Object.assign({ className: className$1 }, { children: [labelMarkup, actionMarkup] }), void 0));
9940
9957
  };
9941
9958
 
9942
- const COMPONENT_NAME$n = 'AlphaLabelledField__HelpText';
9959
+ const COMPONENT_NAME$o = 'AlphaLabelledField__HelpText';
9943
9960
  const HelpText = ({ message, icon }) => {
9944
- const className = cssClassName(COMPONENT_NAME$n);
9961
+ const className = cssClassName(COMPONENT_NAME$o);
9945
9962
  let iconSource;
9946
9963
  if (icon) {
9947
9964
  if (isValidIcon(icon.icon)) {
@@ -9951,24 +9968,24 @@ const HelpText = ({ message, icon }) => {
9951
9968
  iconSource = icon.icon;
9952
9969
  }
9953
9970
  }
9954
- const iconMarkup = iconSource ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$n}__IconWrapper` }, { children: iconSource }), void 0)) : null;
9955
- const messageMarkup = message ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$n}__MessageWrapper` }, { children: message }), void 0)) : null;
9971
+ const iconMarkup = iconSource ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$o}__IconWrapper` }, { children: iconSource }), void 0)) : null;
9972
+ const messageMarkup = message ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$o}__MessageWrapper` }, { children: message }), void 0)) : null;
9956
9973
  return (jsxs("div", Object.assign({ className: className }, { children: [iconMarkup, messageMarkup] }), void 0));
9957
9974
  };
9958
9975
 
9959
- const COMPONENT_NAME$m = 'AlphaLabelledField';
9976
+ const COMPONENT_NAME$n = 'AlphaLabelledField';
9960
9977
  const AlphaLabelledField = ({ label, children, action, error, helpText, id, isRequired, }) => {
9961
- const className = cssClassName(COMPONENT_NAME$m);
9962
- const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$m}__LabelWrapper` }, { children: jsx(AlphaLabel, Object.assign({ action: action, id: id, isRequired: isRequired }, { children: label }), void 0) }), void 0)) : null;
9963
- const errorMarkup = error ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$m}__ErrorWrapper` }, { children: jsx(AlphaInlineError, Object.assign({ icon: error.icon }, { children: error.message }), void 0) }), void 0)) : null;
9978
+ const className = cssClassName(COMPONENT_NAME$n);
9979
+ const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$n}__LabelWrapper` }, { children: jsx(AlphaLabel, Object.assign({ action: action, id: id, isRequired: isRequired }, { children: label }), void 0) }), void 0)) : null;
9980
+ const errorMarkup = error ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$n}__ErrorWrapper` }, { children: jsx(AlphaInlineError, Object.assign({ icon: error.icon }, { children: error.message }), void 0) }), void 0)) : null;
9964
9981
  const helpTextMarkup = helpText ? (jsx(HelpText, { message: helpText.message, icon: helpText.icon }, void 0)) : null;
9965
- const contentMarkup = errorMarkup ? (jsx(AlphaTooltip, Object.assign({ persistence: true, content: errorMarkup, isActive: Boolean(errorMarkup), appearance: 'error' }, { children: jsx("div", Object.assign({ className: `${COMPONENT_NAME$m}__ContentWrapper` }, { children: children }), void 0) }), void 0)) : (children);
9982
+ const contentMarkup = errorMarkup ? (jsx(AlphaTooltip, Object.assign({ persistence: true, content: errorMarkup, isActive: Boolean(errorMarkup), appearance: 'error' }, { children: jsx("div", Object.assign({ className: `${COMPONENT_NAME$n}__ContentWrapper` }, { children: children }), void 0) }), void 0)) : (children);
9966
9983
  return (jsxs("div", Object.assign({ className: className }, { children: [labelMarkup, contentMarkup, helpTextMarkup] }), void 0));
9967
9984
  };
9968
9985
 
9969
- const COMPONENT_NAME$l = 'AlphaInputText';
9986
+ const COMPONENT_NAME$m = 'AlphaInputText';
9970
9987
  const AlphaInputText = ({ isDisabled, label }) => {
9971
- const className = cssClassName(COMPONENT_NAME$l, isDisabled && 'isDisabled');
9988
+ const className = cssClassName(COMPONENT_NAME$m, isDisabled && 'isDisabled');
9972
9989
  return (jsx(AlphaLabelledField, Object.assign({ label: label }, { children: jsx("div", { className: className }, void 0) }), void 0));
9973
9990
  };
9974
9991
 
@@ -9976,14 +9993,14 @@ const StepDefault = {
9976
9993
  status: 'incomplete',
9977
9994
  };
9978
9995
 
9979
- const COMPONENT_NAME$k = 'AlphaStepper__Step';
9996
+ const COMPONENT_NAME$l = 'AlphaStepper__Step';
9980
9997
  const Step = ({ iconMarkup, label, isComplete, isInactive, isSuccess, isLastStepComplete, isLastStepInactive, }) => {
9981
9998
  const { theme } = useTheme();
9982
- const itemClassName = cssClassName(`${COMPONENT_NAME$k}__Item`, isComplete && `is-${theme}-light-after`, isInactive && 'is-inactive-light-after', isSuccess && 'is-success-light-after', isSuccess && 'is-success-light-before', isLastStepComplete && `is-${theme}-light-before`, isLastStepInactive && 'is-inactive-light-before');
9983
- return (jsxs("div", Object.assign({ className: COMPONENT_NAME$k }, { children: [jsx("div", Object.assign({ className: itemClassName }, { children: iconMarkup }), void 0), jsx("div", Object.assign({ className: `${COMPONENT_NAME$k}__Label` }, { children: label }), void 0)] }), void 0));
9999
+ const itemClassName = cssClassName(`${COMPONENT_NAME$l}__Item`, isComplete && `is-${theme}-light-after`, isInactive && 'is-inactive-light-after', isSuccess && 'is-success-light-after', isSuccess && 'is-success-light-before', isLastStepComplete && `is-${theme}-light-before`, isLastStepInactive && 'is-inactive-light-before');
10000
+ return (jsxs("div", Object.assign({ className: COMPONENT_NAME$l }, { children: [jsx("div", Object.assign({ className: itemClassName }, { children: iconMarkup }), void 0), jsx("div", Object.assign({ className: `${COMPONENT_NAME$l}__Label` }, { children: label }), void 0)] }), void 0));
9984
10001
  };
9985
10002
 
9986
- const COMPONENT_NAME$j = 'AlphaStepper';
10003
+ const COMPONENT_NAME$k = 'AlphaStepper';
9987
10004
  const getSourceIcon = (icon) => {
9988
10005
  if (icon) {
9989
10006
  if (isValidIcon(icon.icon)) {
@@ -9998,7 +10015,7 @@ const AlphaStepper = ({ isSuccess, steps = [], completeIcon, incompleteIcon, err
9998
10015
  const { theme } = useTheme();
9999
10016
  const renderStep = (step = Object.assign({}, StepDefault), index) => {
10000
10017
  const lastStepStatus = steps[index - 1] ? steps[index - 1].status : '';
10001
- const iconClassName = cssClassName(`${COMPONENT_NAME$j}__IconWrapper`, (step.status === 'complete' || step.status === 'active') && `is-${theme}`, step.status !== 'complete' && `is-inactive`, step.hasError && errorIcon && 'is-danger', isSuccess && `is-success`);
10018
+ const iconClassName = cssClassName(`${COMPONENT_NAME$k}__IconWrapper`, (step.status === 'complete' || step.status === 'active') && `is-${theme}`, step.status !== 'complete' && `is-inactive`, step.hasError && errorIcon && 'is-danger', isSuccess && `is-success`);
10002
10019
  let iconSource = getSourceIcon(incompleteIcon);
10003
10020
  if (step.hasError && errorIcon)
10004
10021
  iconSource = getSourceIcon(errorIcon);
@@ -10009,16 +10026,16 @@ const AlphaStepper = ({ isSuccess, steps = [], completeIcon, incompleteIcon, err
10009
10026
  const isInactive = step.status === 'incomplete' || step.status === 'active';
10010
10027
  const isLastStepComplete = lastStepStatus === 'complete';
10011
10028
  const isLastStepInactive = lastStepStatus === 'incomplete' || lastStepStatus === 'active';
10012
- return (jsx(Step, { iconMarkup: iconMarkup, label: step.label, isComplete: isComplete, isInactive: isInactive, isSuccess: isSuccess, isLastStepComplete: isLastStepComplete, isLastStepInactive: isLastStepInactive }, `${COMPONENT_NAME$j}-${index}`));
10029
+ return (jsx(Step, { iconMarkup: iconMarkup, label: step.label, isComplete: isComplete, isInactive: isInactive, isSuccess: isSuccess, isLastStepComplete: isLastStepComplete, isLastStepInactive: isLastStepInactive }, `${COMPONENT_NAME$k}-${index}`));
10013
10030
  };
10014
10031
  const stepsMarkup = steps ? steps.map(renderStep) : null;
10015
- return jsx("div", Object.assign({ className: `${COMPONENT_NAME$j}__Container` }, { children: stepsMarkup }), void 0);
10032
+ return jsx("div", Object.assign({ className: `${COMPONENT_NAME$k}__Container` }, { children: stepsMarkup }), void 0);
10016
10033
  };
10017
10034
 
10018
- const COMPONENT_NAME$i = 'AlphaTag';
10035
+ const COMPONENT_NAME$j = 'AlphaTag';
10019
10036
  const AlphaTag = ({ color, children }) => {
10020
- const className = cssClassName(COMPONENT_NAME$i, color && `is-${color.color}-${color.intensity}`);
10021
- const childrenMarkup = (jsx("span", Object.assign({ className: `${COMPONENT_NAME$i}__TextWrapper` }, { children: children }), void 0));
10037
+ const className = cssClassName(COMPONENT_NAME$j, color && `is-${color.color}-${color.intensity}`);
10038
+ const childrenMarkup = (jsx("span", Object.assign({ className: `${COMPONENT_NAME$j}__TextWrapper` }, { children: children }), void 0));
10022
10039
  return jsx("div", Object.assign({ className: className }, { children: childrenMarkup }), void 0);
10023
10040
  };
10024
10041
 
@@ -10029,11 +10046,11 @@ const StatusIcon = {
10029
10046
  Warning: WarningIcon,
10030
10047
  };
10031
10048
 
10032
- const COMPONENT_NAME$h = 'AlphaTile';
10049
+ const COMPONENT_NAME$i = 'AlphaTile';
10033
10050
  const AlphaTile = ({ isSelected, icon, status, theme: themeProp, title, onClick, }) => {
10034
10051
  const { theme } = useTheme();
10035
- const className = cssClassName(COMPONENT_NAME$h, `is${themeClassConverter(themeProp || theme)}`, isSelected && 'isSelected');
10036
- const statusWrapperClassName = cssClassName(`${COMPONENT_NAME$h}--StatusWrapper`, status && `is${status}`);
10052
+ const className = cssClassName(COMPONENT_NAME$i, `is${themeClassConverter(themeProp || theme)}`, isSelected && 'isSelected');
10053
+ const statusWrapperClassName = cssClassName(`${COMPONENT_NAME$i}--StatusWrapper`, status && `is${status}`);
10037
10054
  let iconSource;
10038
10055
  if (icon) {
10039
10056
  if (isValidIcon(icon.icon)) {
@@ -10043,10 +10060,10 @@ const AlphaTile = ({ isSelected, icon, status, theme: themeProp, title, onClick,
10043
10060
  iconSource = icon.icon;
10044
10061
  }
10045
10062
  }
10046
- const iconWrapper = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$h}__IconWrapper` }, { children: iconSource }), void 0)) : null;
10047
- const mediaMarkup = icon ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$h}__MediaWrapper` }, { children: iconWrapper }), void 0)) : null;
10048
- const titleWrapper = title ? (jsx("div", { children: jsx("div", Object.assign({ className: `${COMPONENT_NAME$h}__TitleWrapper` }, { children: title }), void 0) }, void 0)) : null;
10049
- const HeaderWrapper = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$h}__HeaderWrapper` }, { children: [mediaMarkup, titleWrapper] }), void 0));
10063
+ const iconWrapper = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$i}__IconWrapper` }, { children: iconSource }), void 0)) : null;
10064
+ const mediaMarkup = icon ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$i}__MediaWrapper` }, { children: iconWrapper }), void 0)) : null;
10065
+ const titleWrapper = title ? (jsx("div", { children: jsx("div", Object.assign({ className: `${COMPONENT_NAME$i}__TitleWrapper` }, { children: title }), void 0) }, void 0)) : null;
10066
+ const HeaderWrapper = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$i}__HeaderWrapper` }, { children: [mediaMarkup, titleWrapper] }), void 0));
10050
10067
  const statusIcon = status ? StatusIcon[status] : '';
10051
10068
  const statusWrapper = status ? (jsx("div", Object.assign({ className: statusWrapperClassName }, { children: jsx(AlphaIcon, { source: statusIcon, size: 'medium', outlined: true }, void 0) }), void 0)) : null;
10052
10069
  return (jsxs("div", Object.assign({ className: className, onClick: onClick }, { children: [HeaderWrapper, statusWrapper] }), void 0));
@@ -16689,9 +16706,9 @@ function getRangeDate(range, date) {
16689
16706
  };
16690
16707
  }
16691
16708
 
16692
- const COMPONENT_NAME$g = 'DatePicker__Day';
16709
+ const COMPONENT_NAME$h = 'DatePicker__Day';
16693
16710
  const Day = memo(function Day({ day, isDisabled, isFirstSelectedDay, isLastSelectedDay, isInRange, isSelected, onClick, theme: themeProp, }) {
16694
- const emptyDayClassName = cssClassName(COMPONENT_NAME$g, !day && 'isEmpty');
16711
+ const emptyDayClassName = cssClassName(COMPONENT_NAME$h, !day && 'isEmpty');
16695
16712
  if (!day) {
16696
16713
  return jsx("td", { className: emptyDayClassName }, void 0);
16697
16714
  }
@@ -16702,14 +16719,14 @@ const Day = memo(function Day({ day, isDisabled, isFirstSelectedDay, isLastSelec
16702
16719
  }
16703
16720
  };
16704
16721
  const today = isToday(new Date(), day);
16705
- const className = cssClassName(COMPONENT_NAME$g, today && 'isToday', `theme-${themeProp || theme}`, isSelected && 'isSelected', isDisabled && 'isDisabled', isInRange && 'isInRange', isFirstSelectedDay && 'isFirstSelectedDay', isLastSelectedDay && 'isLastSelectedDay');
16722
+ const className = cssClassName(COMPONENT_NAME$h, today && 'isToday', `theme-${themeProp || theme}`, isSelected && 'isSelected', isDisabled && 'isDisabled', isInRange && 'isInRange', isFirstSelectedDay && 'isFirstSelectedDay', isLastSelectedDay && 'isLastSelectedDay');
16706
16723
  const date = day.getDate();
16707
16724
  return (jsx("td", Object.assign({ className: className }, { children: jsx("button", Object.assign({ onClick: handleClick }, { children: date }), void 0) }), void 0));
16708
16725
  });
16709
16726
 
16710
- const COMPONENT_NAME$f = 'DatePicker__Month';
16727
+ const COMPONENT_NAME$g = 'DatePicker__Month';
16711
16728
  const Month = ({ month = new Date().getMonth(), year = new Date().getFullYear(), allowRange, disableAfterDate, disableBeforeDate, onChange, selected, weekStartsOn = 0, disableDates, weekDays, }) => {
16712
- const className = cssClassName(COMPONENT_NAME$f);
16729
+ const className = cssClassName(COMPONENT_NAME$g);
16713
16730
  const weeks = useMemo(() => getWeeksByMonth(month, year, weekStartsOn), [month, year, weekStartsOn]);
16714
16731
  const handleDateClick = useCallback((selectedDate) => {
16715
16732
  if (onChange) {
@@ -16734,9 +16751,9 @@ const Month = ({ month = new Date().getMonth(), year = new Date().getFullYear(),
16734
16751
  return jsx("div", Object.assign({ className: className }, { children: calendarGridMarkup }), void 0);
16735
16752
  };
16736
16753
 
16737
- const COMPONENT_NAME$e = 'DatePIcker__YearField';
16754
+ const COMPONENT_NAME$f = 'DatePIcker__YearField';
16738
16755
  const YearField = ({ onChange, value, min, max, onBlur, onFocus, onKeyDown, onKeyUp, }) => {
16739
- const className = cssClassName(COMPONENT_NAME$e);
16756
+ const className = cssClassName(COMPONENT_NAME$f);
16740
16757
  const handleChange = (event) => {
16741
16758
  if (onChange) {
16742
16759
  const value = event.target.value.trim();
@@ -16780,10 +16797,10 @@ const IconButton = (_a) => {
16780
16797
  return (jsx("button", Object.assign({ className: className, onClick: onClick, onBlur: onBlur, onFocus: onFocus }, rest, { children: icon && jsx(Icon, { name: icon }, void 0) }), void 0));
16781
16798
  };
16782
16799
 
16783
- const COMPONENT_NAME$d = 'DatePicker__Header';
16800
+ const COMPONENT_NAME$e = 'DatePicker__Header';
16784
16801
  const Header$2 = ({ month, year, onChange, months }) => {
16785
16802
  const [yearValue, setYearValue] = useState(year);
16786
- const headerClassName = cssClassName(COMPONENT_NAME$d);
16803
+ const headerClassName = cssClassName(COMPONENT_NAME$e);
16787
16804
  const handleMonthChange = useCallback((month, year) => {
16788
16805
  if (onChange) {
16789
16806
  onChange(month, year);
@@ -16813,10 +16830,10 @@ const Header$2 = ({ month, year, onChange, months }) => {
16813
16830
  const previousYear = getPreviousYear(month, year);
16814
16831
  const nextMonth = getNextMonth(month);
16815
16832
  const nextYear = getNextYear(month, year);
16816
- return (jsxs("div", Object.assign({ className: headerClassName }, { children: [jsx(IconButton, { icon: 'ArrowLeft', size: 'small', appearance: 'secondary', onClick: () => handleMonthChange(previousMonth, previousYear) }, void 0), jsxs("span", Object.assign({ className: `${COMPONENT_NAME$d}__DateLabel` }, { children: [montName, jsx(YearField, { value: yearValue, onChange: setYearValue, onBlur: handleYearBlur, min: MINIMUM_SELECTABLE_YEAR }, void 0)] }), void 0), jsx(IconButton, { icon: 'ArrowRight', size: 'small', appearance: 'secondary', onClick: () => handleMonthChange(nextMonth, nextYear) }, void 0)] }), void 0));
16833
+ return (jsxs("div", Object.assign({ className: headerClassName }, { children: [jsx(IconButton, { icon: 'ArrowLeft', size: 'small', appearance: 'secondary', onClick: () => handleMonthChange(previousMonth, previousYear) }, void 0), jsxs("span", Object.assign({ className: `${COMPONENT_NAME$e}__DateLabel` }, { children: [montName, jsx(YearField, { value: yearValue, onChange: setYearValue, onBlur: handleYearBlur, min: MINIMUM_SELECTABLE_YEAR }, void 0)] }), void 0), jsx(IconButton, { icon: 'ArrowRight', size: 'small', appearance: 'secondary', onClick: () => handleMonthChange(nextMonth, nextYear) }, void 0)] }), void 0));
16817
16834
  };
16818
16835
 
16819
- const COMPONENT_NAME$c = 'DatePicker';
16836
+ const COMPONENT_NAME$d = 'DatePicker';
16820
16837
  function getMonthSelectedDate(selected) {
16821
16838
  return selected instanceof Date
16822
16839
  ? {
@@ -16826,7 +16843,7 @@ function getMonthSelectedDate(selected) {
16826
16843
  : selected;
16827
16844
  }
16828
16845
  const DatePicker = ({ allowRange, disableAfterDate, disableBeforeDate, id, month = new Date().getMonth(), year = new Date().getFullYear(), onChange, selected, onMonthChange, weekStartsOn, disableDates, months, weekDays, }) => {
16829
- const className = cssClassName(COMPONENT_NAME$c);
16846
+ const className = cssClassName(COMPONENT_NAME$d);
16830
16847
  const handleDateChange = useCallback((dateRange) => {
16831
16848
  if (onChange) {
16832
16849
  onChange(dateRange);
@@ -16841,19 +16858,19 @@ const TrashIcon = () => (jsxs("svg", Object.assign({ width: '24', height: '24',
16841
16858
  // eslint-disable-next-line max-len
16842
16859
  d: 'M8 6V4C8 3.46957 8.21071 2.96086 8.58579 2.58579C8.96086 2.21071 9.46957 2 10 2H14C14.5304 2 15.0391 2.21071 15.4142 2.58579C15.7893 2.96086 16 3.46957 16 4V6M19 6V20C19 20.5304 18.7893 21.0391 18.4142 21.4142C18.0391 21.7893 17.5304 22 17 22H7C6.46957 22 5.96086 21.7893 5.58579 21.4142C5.21071 21.0391 5 20.5304 5 20V6H19Z', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, void 0), jsx("path", { d: 'M10 11V17', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, void 0), jsx("path", { d: 'M14 11V17', strokeWidth: '2', strokeLinecap: 'round', strokeLinejoin: 'round' }, void 0)] }), void 0));
16843
16860
 
16844
- const COMPONENT_NAME$b = 'DeletableSection';
16861
+ const COMPONENT_NAME$c = 'DeletableSection';
16845
16862
  const DeletableSection = ({ ariaLabel, children, onDelete, iconDeletable, isDeletable, }) => {
16846
16863
  const { theme } = useTheme();
16847
16864
  const THEME_CLASS = `${theme}`;
16848
- const className = cssClassName(COMPONENT_NAME$b);
16849
- const classNameButton = cssClassName(`${COMPONENT_NAME$b}__DeleteButtonWrapper`, THEME_CLASS);
16865
+ const className = cssClassName(COMPONENT_NAME$c);
16866
+ const classNameButton = cssClassName(`${COMPONENT_NAME$c}__DeleteButtonWrapper`, THEME_CLASS);
16850
16867
  const icon = iconDeletable || TrashIcon;
16851
- const deleteButtonMarkup = onDelete && isDeletable ? (jsx("div", Object.assign({ className: classNameButton }, { children: jsx("button", Object.assign({ "aria-label": ariaLabel ? `${ariaLabel}-removeForm` : ariaLabel, className: `${COMPONENT_NAME$b}__DeleteButton`, onClick: onDelete }, { children: jsx(AlphaIcon, { source: icon, outlined: true }, void 0) }), void 0) }), void 0)) : null;
16852
- const contentMarkup = children ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$b}__ContentWrapper` }, { children: children }), void 0)) : null;
16868
+ const deleteButtonMarkup = onDelete && isDeletable ? (jsx("div", Object.assign({ className: classNameButton }, { children: jsx("button", Object.assign({ "aria-label": ariaLabel ? `${ariaLabel}-removeForm` : ariaLabel, className: `${COMPONENT_NAME$c}__DeleteButton`, onClick: onDelete }, { children: jsx(AlphaIcon, { source: icon, outlined: true }, void 0) }), void 0) }), void 0)) : null;
16869
+ const contentMarkup = children ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$c}__ContentWrapper` }, { children: children }), void 0)) : null;
16853
16870
  return (jsxs("div", Object.assign({ className: className }, { children: [deleteButtonMarkup, contentMarkup] }), void 0));
16854
16871
  };
16855
16872
 
16856
- const COMPONENT_NAME$a = 'AlphaInputTag';
16873
+ const COMPONENT_NAME$b = 'AlphaInputTag';
16857
16874
  const InputTag$1 = ({ ariaLabel, id, inputTextPlaceholder, inputTextValue, isRequired, label, onChange, onInputTextChange, addedTags = [], triggerKeys = ['Enter'], onBlur, onFocus, isDisabled, hasError, tagRemoveIcon, helpText, }) => {
16858
16875
  const [isFocused, setIsFocused] = useState(false);
16859
16876
  const inputRef = useRef(null);
@@ -16896,10 +16913,10 @@ const InputTag$1 = ({ ariaLabel, id, inputTextPlaceholder, inputTextValue, isReq
16896
16913
  }
16897
16914
  };
16898
16915
  const renderTag = (tag, index) => {
16899
- return (jsx("div", Object.assign({ className: `${COMPONENT_NAME$a}__TagWrapper` }, { children: jsx(AlphaChip, Object.assign({ removeButtonIcon: tagRemoveIcon, onRemove: () => handleRemoveTag(index) }, { children: tag }), void 0) }), index));
16916
+ return (jsx("div", Object.assign({ className: `${COMPONENT_NAME$b}__TagWrapper` }, { children: jsx(AlphaChip, Object.assign({ removeButtonIcon: tagRemoveIcon, onRemove: () => handleRemoveTag(index) }, { children: tag }), void 0) }), index));
16900
16917
  };
16901
- const className = cssClassName(COMPONENT_NAME$a);
16902
- const inputWrapperClassName = cssClassName(`${COMPONENT_NAME$a}__InputWrapper`, isFocused && 'isFocused', isDisabled && 'isDisabled', hasError && 'hasError');
16918
+ const className = cssClassName(COMPONENT_NAME$b);
16919
+ const inputWrapperClassName = cssClassName(`${COMPONENT_NAME$b}__InputWrapper`, isFocused && 'isFocused', isDisabled && 'isDisabled', hasError && 'hasError');
16903
16920
  const handleInputChange = (event) => {
16904
16921
  if (onInputTextChange) {
16905
16922
  onInputTextChange(event.target.value);
@@ -23633,7 +23650,7 @@ var pako = {
23633
23650
  * @returns {symbol} - Element FileItem
23634
23651
  * @param {string} InputTextProps.ariaLabel - Label to use in automatic tests
23635
23652
  */
23636
- const FileItem = ({ ariaLabel, name, addon, onDelete, size = 0, }) => (jsxs("div", Object.assign({ className: 'File' }, { children: [jsxs("div", Object.assign({ className: 'File__content__left' }, { children: [jsx(Icon, { name: 'Paperclip' }, void 0), jsx("p", Object.assign({ className: ' File__content__nameFile' }, { children: name }), void 0)] }), void 0), jsxs("div", Object.assign({ className: 'File__content__right' }, { children: [jsxs("button", Object.assign({ "aria-label": `${ariaLabel}-delete`, className: 'ButtonDeleteFile', onClick: onDelete }, { children: [jsx(Fragment, { children: addon }, void 0), jsx(Icon, { name: 'Close' }, void 0)] }), void 0), jsxs("p", Object.assign({ className: 'File__content__fileSize' }, { children: [(size / 1048576).toFixed(4), " M"] }), void 0)] }), void 0)] }), void 0));
23653
+ const FileItem = ({ ariaLabel, name, addon, onDelete, size = 0, }) => (jsxs("div", Object.assign({ className: 'File' }, { children: [jsxs("div", Object.assign({ className: 'File__content__left' }, { children: [jsx(Icon, { name: 'Paperclip' }, void 0), jsx("p", Object.assign({ className: ' File__content__nameFile' }, { children: name }), void 0)] }), void 0), jsxs("div", Object.assign({ className: 'File__content__right' }, { children: [jsxs("button", Object.assign({ "aria-label": `${ariaLabel}-delete`, className: 'ButtonDeleteFile', onClick: onDelete }, { children: [jsx(Fragment, { children: addon }, void 0), jsx(Icon, { name: 'Close' }, void 0)] }), void 0), jsx("p", Object.assign({ className: 'File__content__fileSize' }, { children: formatFileSize(size) }), void 0)] }), void 0)] }), void 0));
23637
23654
 
23638
23655
  /**
23639
23656
  * FileDrop is a component to upload files in any project
@@ -24578,7 +24595,7 @@ const SectionForm = ({ ariaLabel, data, fields, fieldsSection, iconDeletable, ic
24578
24595
  return (jsx(DeletableSection, Object.assign({ ariaLabel: ariaLabel, onDelete: onDelete, iconDeletable: iconDeletable, isDeletable: isDeletable }, { children: gridMarkup }), void 0));
24579
24596
  };
24580
24597
 
24581
- const COMPONENT_NAME$9 = 'DynamicForm';
24598
+ const COMPONENT_NAME$a = 'DynamicForm';
24582
24599
  const DynamicForm = ({ ariaLabel, dataFormArray = [], fields, fieldsSection, iconDeletable, iconHelperText, labelDivider, onChange, onAddForm, tagRemoveIcon, deletableFormArray, extraPropsFieldsArray, }) => {
24583
24600
  const { theme } = useTheme();
24584
24601
  const handleChange = (contact, id) => {
@@ -24606,11 +24623,11 @@ const DynamicForm = ({ ariaLabel, dataFormArray = [], fields, fieldsSection, ico
24606
24623
  : undefined;
24607
24624
  return (jsx(SectionForm, { ariaLabel: ariaLabel, data: form, fields: fields, fieldsSection: fieldsSection, iconDeletable: iconDeletable, iconHelperText: iconHelperText, onChange: (formData) => handleChange(formData, form.id || ''), onDelete: () => handleDelete(form.id || ''), tagRemoveIcon: tagRemoveIcon, isDeletable: isDeletable, extraPropsField: extraProps }, `DynamicForm-${form.id}-${index}}`));
24608
24625
  };
24609
- const contactsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$9}__SectionFormWrapper` }, { children: dataFormArray.map(renderForm) }), void 0));
24626
+ const contactsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$a}__SectionFormWrapper` }, { children: dataFormArray.map(renderForm) }), void 0));
24610
24627
  const dividerMarkup = labelDivider && jsx(Divider, { label: labelDivider }, void 0);
24611
24628
  const addContactButtonMarkup = onAddForm && (jsx(AlphaButton, Object.assign({ ariaLabel: ariaLabel ? `${ariaLabel}--addNewForm` : ariaLabel, isTertiary: true, onClick: onAddForm.onClick }, { children: onAddForm.label }), void 0));
24612
24629
  const THEME_CLASS = `${theme}`;
24613
- const className = cssClassName(COMPONENT_NAME$9, THEME_CLASS);
24630
+ const className = cssClassName(COMPONENT_NAME$a, THEME_CLASS);
24614
24631
  return (jsxs("div", Object.assign({ className: className }, { children: [dividerMarkup, contactsMarkup, addContactButtonMarkup] }), void 0));
24615
24632
  };
24616
24633
 
@@ -27806,19 +27823,19 @@ Sortable.mount(Remove, Revert);
27806
27823
 
27807
27824
  const Context = createContext({});
27808
27825
 
27809
- const COMPONENT_NAME$8 = 'SortableList__Item';
27826
+ const COMPONENT_NAME$9 = 'SortableList__Item';
27810
27827
  const Item$2 = ({ children }) => {
27811
27828
  const { hasHandle } = useContext(Context);
27812
- const className = cssClassName(COMPONENT_NAME$8, !hasHandle && 'no-handle');
27813
- const handleMarkup = hasHandle ? (jsxs("span", Object.assign({ className: `${COMPONENT_NAME$8}__Handle` }, { children: [jsx(Icon, { name: 'MoreVertical' }, void 0), jsx(Icon, { name: 'MoreVertical' }, void 0)] }), void 0)) : null;
27814
- const contentMarkup = (jsx("span", Object.assign({ className: `${COMPONENT_NAME$8}__Content` }, { children: children }), void 0));
27829
+ const className = cssClassName(COMPONENT_NAME$9, !hasHandle && 'no-handle');
27830
+ const handleMarkup = hasHandle ? (jsxs("span", Object.assign({ className: `${COMPONENT_NAME$9}__Handle` }, { children: [jsx(Icon, { name: 'MoreVertical' }, void 0), jsx(Icon, { name: 'MoreVertical' }, void 0)] }), void 0)) : null;
27831
+ const contentMarkup = (jsx("span", Object.assign({ className: `${COMPONENT_NAME$9}__Content` }, { children: children }), void 0));
27815
27832
  return (jsxs("li", Object.assign({ className: className }, { children: [handleMarkup, contentMarkup] }), void 0));
27816
27833
  };
27817
27834
 
27818
- const COMPONENT_NAME$7 = 'SortableList';
27835
+ const COMPONENT_NAME$8 = 'SortableList';
27819
27836
  const SortableList = function ({ renderItem, items, onSort, hasHandle, }) {
27820
27837
  const listRef = useRef(null);
27821
- const className = cssClassName(COMPONENT_NAME$7);
27838
+ const className = cssClassName(COMPONENT_NAME$8);
27822
27839
  const hasItems = items && items.length > 0;
27823
27840
  const handleSortEnd = (event) => {
27824
27841
  const { newIndex, oldIndex } = event;
@@ -27849,7 +27866,7 @@ const SortableList = function ({ renderItem, items, onSort, hasHandle, }) {
27849
27866
  }
27850
27867
  return itemComponent;
27851
27868
  };
27852
- const listClassName = cssClassName(`${COMPONENT_NAME$7}__List`);
27869
+ const listClassName = cssClassName(`${COMPONENT_NAME$8}__List`);
27853
27870
  const listMarkup = hasItems ? (jsx("ul", Object.assign({ ref: listRef, className: listClassName }, { children: Children.toArray(items.map(renderItemElement)) }), void 0)) : null;
27854
27871
  const contextValue = {
27855
27872
  hasHandle,
@@ -30177,12 +30194,12 @@ const Tile = ({ isSelected, media, onClick, title, value, subtitle = '', mediaSi
30177
30194
  return (jsxs("div", Object.assign({ className: classes, onClick: handleOnClick }, { children: [jsxs("div", Object.assign({ className: 'Tile__Wrapper' }, { children: [jsxs("div", Object.assign({ className: 'Tile__TitleWrapper' }, { children: [jsx("div", Object.assign({ className: 'Tile__Media' }, { children: jsx(Media, { icon: media, size: mediaSize, appearance: 'info' }, void 0) }), void 0), jsxs("div", { children: [jsx("div", Object.assign({ className: 'Tile__Title' }, { children: title }), void 0), subtitle ? jsx("div", Object.assign({ className: 'Tile__Subtitle' }, { children: subtitle }), void 0) : null] }, void 0)] }), void 0), jsx("div", Object.assign({ className: 'Tile__RightMediaWrapper' }, { children: rightMedia !== null && rightMedia }), void 0)] }), void 0), tagsMarkup] }), void 0));
30178
30195
  };
30179
30196
 
30180
- const COMPONENT_NAME$6 = 'Totalizer';
30197
+ const COMPONENT_NAME$7 = 'Totalizer';
30181
30198
  const Totalizer = ({ action, direction, icon, isDisabled, isFocused, label, placeholderValue, value, theme: themeProp, }) => {
30182
30199
  const { theme } = useTheme();
30183
30200
  const themeClass = `has-Theme${themeProp ? themeProp.toUpperCase() : theme.toUpperCase()}`;
30184
- const className = cssClassName(COMPONENT_NAME$6, themeClass, isDisabled && 'isDisabled', isFocused && 'isFocused', direction && `has-${direction}Direction`);
30185
- const titleMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$6}__TitleWrapper` }, { children: label }), void 0)) : null;
30201
+ const className = cssClassName(COMPONENT_NAME$7, themeClass, isDisabled && 'isDisabled', isFocused && 'isFocused', direction && `has-${direction}Direction`);
30202
+ const titleMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$7}__TitleWrapper` }, { children: label }), void 0)) : null;
30186
30203
  let iconSource;
30187
30204
  if (icon) {
30188
30205
  if (isValidIcon(icon.icon)) {
@@ -30192,25 +30209,25 @@ const Totalizer = ({ action, direction, icon, isDisabled, isFocused, label, plac
30192
30209
  iconSource = icon.icon;
30193
30210
  }
30194
30211
  }
30195
- const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$6}__IconWrapper` }, { children: iconSource }), void 0)) : null;
30196
- const headerMarkup = titleMarkup || iconMarkup ? (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$6}__HeaderWrapper` }, { children: [titleMarkup, iconMarkup] }), void 0)) : null;
30197
- const valueMarkup = value ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$6}__ValueWrapper` }, { children: value }), void 0)) : null;
30198
- const placeholderValueMarkup = placeholderValue ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$6}__PlaceholderValueWrapper` }, { children: placeholderValue }), void 0)) : null;
30212
+ const iconMarkup = icon ? (jsx("span", Object.assign({ className: `${COMPONENT_NAME$7}__IconWrapper` }, { children: iconSource }), void 0)) : null;
30213
+ const headerMarkup = titleMarkup || iconMarkup ? (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$7}__HeaderWrapper` }, { children: [titleMarkup, iconMarkup] }), void 0)) : null;
30214
+ const valueMarkup = value ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$7}__ValueWrapper` }, { children: value }), void 0)) : null;
30215
+ const placeholderValueMarkup = placeholderValue ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$7}__PlaceholderValueWrapper` }, { children: placeholderValue }), void 0)) : null;
30199
30216
  const valueContentToRender = (!valueMarkup && placeholderValueMarkup) || valueMarkup;
30200
- const valueContainerMarkup = valueMarkup || placeholderValueMarkup ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$6}__ValueContainerWrapper` }, { children: valueContentToRender }), void 0)) : null;
30201
- const actionMarkup = action ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$6}__ActionWrapper` }, { children: jsx(AlphaButton, Object.assign({ id: action.id, onClick: action.onClick, onMouseEnter: action.onMouseEnter, onTouchStart: action.onTouchStart, isDisabled: action.isDisabled || isDisabled, isLoading: action.isLoading, isDanger: action.isDanger, icon: action.icon ? { icon: action.icon } : undefined, isPrimary: true }, { children: action.content }), void 0) }), void 0)) : null;
30202
- const contentClassName = cssClassName(`${COMPONENT_NAME$6}__ContentWrapper`, action && 'has-Action');
30217
+ const valueContainerMarkup = valueMarkup || placeholderValueMarkup ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$7}__ValueContainerWrapper` }, { children: valueContentToRender }), void 0)) : null;
30218
+ const actionMarkup = action ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$7}__ActionWrapper` }, { children: jsx(AlphaButton, Object.assign({ id: action.id, onClick: action.onClick, onMouseEnter: action.onMouseEnter, onTouchStart: action.onTouchStart, isDisabled: action.isDisabled || isDisabled, isLoading: action.isLoading, isDanger: action.isDanger, icon: action.icon ? { icon: action.icon } : undefined, isPrimary: true }, { children: action.content }), void 0) }), void 0)) : null;
30219
+ const contentClassName = cssClassName(`${COMPONENT_NAME$7}__ContentWrapper`, action && 'has-Action');
30203
30220
  const contentMarkup = valueContainerMarkup || actionMarkup ? (jsxs("div", Object.assign({ className: contentClassName }, { children: [valueContainerMarkup, actionMarkup] }), void 0)) : null;
30204
30221
  return (jsxs("div", Object.assign({ className: className }, { children: [headerMarkup, contentMarkup] }), void 0));
30205
30222
  };
30206
30223
 
30207
- const COMPONENT_NAME$5 = 'TimeSelector__TimePicker__List';
30224
+ const COMPONENT_NAME$6 = 'AlphaMultiSelectionPicker__Picker__List';
30208
30225
  const List = ({ items, selected, onChange }) => {
30209
30226
  const listWrapperRef = useRef(null);
30210
30227
  const scrollToSelected = () => {
30211
30228
  const listWrapper = listWrapperRef.current;
30212
30229
  if (listWrapper) {
30213
- const selectedElement = listWrapper.querySelector(`.${COMPONENT_NAME$5}__ListItem--selected`);
30230
+ const selectedElement = listWrapper.querySelector(`.${COMPONENT_NAME$6}__ListItem--selected`);
30214
30231
  if (selectedElement) {
30215
30232
  const { top } = selectedElement.getBoundingClientRect();
30216
30233
  const { top: listWrapperTop } = listWrapper.getBoundingClientRect();
@@ -30232,17 +30249,17 @@ const List = ({ items, selected, onChange }) => {
30232
30249
  const renderItem = (item, index) => {
30233
30250
  const { label, value } = item;
30234
30251
  const isSelected = Boolean(selected !== null && selected !== undefined && selected === value);
30235
- const className = cssClassName(`${COMPONENT_NAME$5}__ListItem`, isSelected && 'selected');
30252
+ const className = cssClassName(`${COMPONENT_NAME$6}__ListItem`, isSelected && 'selected');
30236
30253
  const handleClick = () => handleChange(value);
30237
- return (jsx("li", Object.assign({ className: className, onClick: handleClick }, { children: label }), `${COMPONENT_NAME$5}__ListItem-${index}`));
30254
+ return (jsx("li", Object.assign({ className: className, onClick: handleClick }, { children: label }), `${COMPONENT_NAME$6}__ListItem-${index}`));
30238
30255
  };
30239
30256
  const itemsMarkup = items ? items.map(renderItem) : null;
30240
- const className = cssClassName(COMPONENT_NAME$5);
30257
+ const className = cssClassName(COMPONENT_NAME$6);
30241
30258
  return (jsx("div", Object.assign({ className: className, ref: listWrapperRef }, { children: jsx("ul", { children: itemsMarkup }, void 0) }), void 0));
30242
30259
  };
30243
30260
 
30244
- const COMPONENT_NAME$4 = 'TimeSelector__TimePicker';
30245
- const TimePicker = ({ headers, items, onChange, selected, theme: ThemeProp, }) => {
30261
+ const COMPONENT_NAME$5 = 'AlphaMultiSelectionPicker__Picker';
30262
+ const Picker = ({ headers, items, onChange, selected, theme: ThemeProp, }) => {
30246
30263
  const { theme: themeValue } = useTheme();
30247
30264
  const theme = ThemeProp || themeValue;
30248
30265
  if (!theme) {
@@ -30255,46 +30272,93 @@ const TimePicker = ({ headers, items, onChange, selected, theme: ThemeProp, }) =
30255
30272
  onChange(selectedValues);
30256
30273
  }
30257
30274
  };
30258
- const renderHeader = (header, index) => (jsx("span", Object.assign({ className: `${COMPONENT_NAME$4}__HeaderItem` }, { children: capitalize(header) }), `${COMPONENT_NAME$4}__HeaderItem-${index}`));
30259
- const headersMarkup = headers ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$4}__HeadersMarkup` }, { children: headers.map(renderHeader) }), void 0)) : null;
30275
+ const renderHeader = (header, index) => (jsx("span", Object.assign({ className: `${COMPONENT_NAME$5}__HeaderItem` }, { children: capitalize(header) }), `${COMPONENT_NAME$5}__HeaderItem-${index}`));
30276
+ const headersMarkup = headers ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$5}__HeadersMarkup` }, { children: headers.map(renderHeader) }), void 0)) : null;
30260
30277
  const renderList = (listItems, index) => {
30261
30278
  const selectedValue = selected ? selected[index] : undefined;
30262
- return (jsx(List, { items: listItems, onChange: (value) => handleChange(value, index), selected: selectedValue }, `${COMPONENT_NAME$4}__List-${index}`));
30279
+ return (jsx(List, { items: listItems, onChange: (value) => handleChange(value, index), selected: selectedValue }, `${COMPONENT_NAME$5}__List-${index}`));
30263
30280
  };
30264
- const itemsListsMarkup = items ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$4}__ItemsListWrapper` }, { children: items.map(renderList) }), void 0)) : null;
30265
- const className = cssClassName(COMPONENT_NAME$4, theme);
30281
+ const itemsListsMarkup = items ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$5}__ItemsListWrapper` }, { children: items.map(renderList) }), void 0)) : null;
30282
+ const className = cssClassName(COMPONENT_NAME$5, theme);
30266
30283
  return (jsxs("div", Object.assign({ className: className }, { children: [headersMarkup, itemsListsMarkup] }), void 0));
30267
30284
  };
30268
30285
 
30269
- const COMPONENT_NAME$3 = 'TimeSelector';
30270
- const TimeSelector = ({ plurals, singulars, value, disabled, error, helpText, label, onChange, readOnly, placeholderValues, minMaxDays = [0, 365], minMaxHours = [0, 24], minMaxMinutes = [0, 60], minMaxSeconds = [0, 60], theme: themeProp, isRequired, }) => {
30286
+ const AlphaMultiSelectionPicker = ({ items, onChange, theme, }) => {
30287
+ const getLabel = (value) => {
30288
+ return value < 10 ? `0${value}` : `${value}`;
30289
+ };
30290
+ const getListItem = (min, max) => {
30291
+ const numbersArray = Array.from({ length: max - min + 1 }, (_, i) => i + min);
30292
+ return numbersArray.map((number) => ({
30293
+ label: getLabel(number),
30294
+ value: number,
30295
+ }));
30296
+ };
30297
+ const headersPicker = useMemo(() => items.map((item) => item.plural), [items]);
30298
+ const itemsPicker = useMemo(() => items.map((item) => getListItem(item.min, item.max)), [items]);
30299
+ const valuesSelected = useMemo(() => items.map((item) => item.value), [items]);
30300
+ const pickerMarkup = (jsx(Picker, { items: itemsPicker, headers: headersPicker, onChange: onChange, selected: valuesSelected, theme: theme }, void 0));
30301
+ return jsx("div", { children: pickerMarkup }, void 0);
30302
+ };
30303
+
30304
+ const COMPONENT_NAME$4 = 'TimeSelector';
30305
+ const TimeSelector = ({ plurals, singulars, value, disabled, error, helpText, label, onChange, readOnly, placeholderValues, minMaxYears, minMaxMonths, minMaxDays, minMaxHours, minMaxMinutes, minMaxSeconds, theme: themeProp, isRequired, }) => {
30271
30306
  const { theme: themeValue } = useTheme();
30272
30307
  const theme = themeProp || themeValue;
30273
30308
  if (!theme) {
30274
30309
  return null;
30275
30310
  }
30311
+ const [items, setItems] = useState([]);
30312
+ const [keysValues, setKeysValues] = useState([]);
30276
30313
  const fieldRef = useRef(null);
30277
30314
  const [isFocused, setIsFocused] = useState(false);
30278
30315
  const [isActive, setIsActive] = useState(false);
30279
30316
  const toggleTimePicker = () => setIsActive(!isActive);
30280
30317
  const hasError = !!error;
30281
- const daysList = useMemo(() => getTimeList(...minMaxDays), [minMaxDays]);
30282
- const hoursList = useMemo(() => getTimeList(...minMaxHours), [minMaxHours]);
30283
- const minutesList = useMemo(() => getTimeList(...minMaxMinutes), [minMaxMinutes]);
30284
- const secondsList = useMemo(() => getTimeList(...minMaxSeconds), [minMaxSeconds]);
30318
+ const getMaxMins = () => {
30319
+ const maxMins = {
30320
+ years: minMaxYears,
30321
+ months: minMaxMonths,
30322
+ days: minMaxDays,
30323
+ hours: minMaxHours,
30324
+ minutes: minMaxMinutes,
30325
+ seconds: minMaxSeconds,
30326
+ };
30327
+ return maxMins;
30328
+ };
30329
+ const getItemMultiSelectionPicker = (key, minMax) => ({
30330
+ id: key,
30331
+ plural: plurals[key] || '',
30332
+ singular: singulars[key] || '',
30333
+ min: minMax[0],
30334
+ max: minMax[1],
30335
+ value: value ? value[key] : 0,
30336
+ });
30337
+ const getItemsMultiSelectionPicker = () => {
30338
+ const catalogMinMax = getMaxMins();
30339
+ const items = [];
30340
+ const keys = [];
30341
+ Object.keys(catalogMinMax).forEach((key) => {
30342
+ const valueMinMax = catalogMinMax[key];
30343
+ if (valueMinMax) {
30344
+ keys.push(key);
30345
+ items.push(getItemMultiSelectionPicker(key, valueMinMax));
30346
+ }
30347
+ });
30348
+ setKeysValues(keys);
30349
+ return items;
30350
+ };
30285
30351
  const handleClosePopover = () => {
30286
30352
  if (isActive) {
30287
30353
  toggleTimePicker();
30288
30354
  }
30289
30355
  };
30290
30356
  const handleTimePickerChange = (values) => {
30291
- const [days, hours, minutes, seconds] = values;
30292
- const newValue = {
30293
- days: days || 0,
30294
- hours: hours || 0,
30295
- minutes: minutes || 0,
30296
- seconds: seconds || 0,
30297
- };
30357
+ const newValue = {};
30358
+ keysValues.forEach((key, index) => {
30359
+ const valueByKey = values[index];
30360
+ newValue[key] = valueByKey || 0;
30361
+ });
30298
30362
  if (onChange) {
30299
30363
  onChange(newValue);
30300
30364
  }
@@ -30335,15 +30399,6 @@ const TimeSelector = ({ plurals, singulars, value, disabled, error, helpText, la
30335
30399
  fullValue[fieldName] = fieldVal;
30336
30400
  return fullValue;
30337
30401
  };
30338
- const getMaxMins = () => {
30339
- const maxMins = {
30340
- days: minMaxDays,
30341
- hours: minMaxHours,
30342
- minutes: minMaxMinutes,
30343
- seconds: minMaxSeconds,
30344
- };
30345
- return maxMins;
30346
- };
30347
30402
  const renderField = (field, index) => {
30348
30403
  const label = !value || (value && value[field] !== 1)
30349
30404
  ? plurals[field]
@@ -30355,50 +30410,46 @@ const TimeSelector = ({ plurals, singulars, value, disabled, error, helpText, la
30355
30410
  ? getTimeValue(value[field])
30356
30411
  : '';
30357
30412
  const separator = index === Object.keys(singulars).length - 1 ? '' : ', ';
30358
- const min = getMaxMins()[field][0];
30359
- const max = getMaxMins()[field][1];
30360
- return (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$3}__InnerField` }, { children: [jsx("input", { type: 'number', value: elValue, placeholder: placeholderValue, onFocus: handleFocusField, onBlur: handleBlurField, disabled: disabled, onChange: handleInputChange, name: field, min: min, max: max }, void 0), jsxs("span", { children: [label, separator] }, void 0)] }), index));
30413
+ const valuesMaxMin = getMaxMins()[field];
30414
+ let max;
30415
+ let min;
30416
+ if (valuesMaxMin)
30417
+ [min, max] = valuesMaxMin;
30418
+ return (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$4}__InnerField` }, { children: [jsx("input", { type: 'number', value: elValue, placeholder: placeholderValue, onFocus: handleFocusField, onBlur: handleBlurField, disabled: disabled, onChange: handleInputChange, name: field, min: min, max: max }, void 0), jsxs("span", { children: [label, separator] }, void 0)] }), index));
30361
30419
  };
30362
30420
  const fieldsMarkup = Object.keys(singulars).map(renderField);
30363
- const fieldClass = cssClassName(`${COMPONENT_NAME$3}__Field`, (isFocused || isActive) && 'isFocused');
30364
- const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__LabelWrapper` }, { children: jsx(AlphaLabel, Object.assign({ isRequired: isRequired }, { children: label }), void 0) }), void 0)) : null;
30421
+ const fieldClass = cssClassName(`${COMPONENT_NAME$4}__Field`, (isFocused || isActive) && 'isFocused');
30422
+ const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$4}__LabelWrapper` }, { children: jsx(AlphaLabel, Object.assign({ isRequired: isRequired }, { children: label }), void 0) }), void 0)) : null;
30365
30423
  const helpTextMarkup = helpText
30366
- ? helpText && (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__HelpTextWrapper` }, { children: helpText }), void 0))
30424
+ ? helpText && (jsx("div", Object.assign({ className: `${COMPONENT_NAME$4}__HelpTextWrapper` }, { children: helpText }), void 0))
30367
30425
  : null;
30368
- const fieldMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__FieldWrapper` }, { children: jsxs(AlphaTooltip, Object.assign({ content: error, appearance: 'error', persistence: true, isActive: hasError }, { children: [labelMarkup, jsx("div", Object.assign({ className: fieldClass, onClick: handleFieldClick, ref: fieldRef }, { children: fieldsMarkup }), void 0)] }), void 0) }), void 0));
30369
- const timePickerValue = useMemo(() => {
30370
- if (value) {
30371
- const { days, hours, minutes, seconds } = value;
30372
- return [days, hours, minutes, seconds];
30373
- }
30374
- return undefined;
30375
- }, [value]);
30376
- const timePickerHeaders = useMemo(() => [plurals.days, plurals.hours, plurals.minutes, plurals.seconds], [plurals]);
30377
- const timePickerMarkup = (jsx(TimePicker, { items: [daysList, hoursList, minutesList, secondsList], headers: timePickerHeaders, onChange: handleTimePickerChange, selected: timePickerValue, theme: theme }, void 0));
30426
+ const fieldMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$4}__FieldWrapper` }, { children: jsxs(AlphaTooltip, Object.assign({ content: error, appearance: 'error', persistence: true, isActive: hasError }, { children: [labelMarkup, jsx("div", Object.assign({ className: fieldClass, onClick: handleFieldClick, ref: fieldRef }, { children: fieldsMarkup }), void 0)] }), void 0) }), void 0));
30427
+ const timePickerMarkup = (jsx(AlphaMultiSelectionPicker, { items: items, onChange: handleTimePickerChange, theme: themeProp }, void 0));
30378
30428
  const popoverMarkup = (jsx(Popover$1, Object.assign({ activator: fieldMarkup, isActive: isActive, isFullWidth: true, onClose: handleClosePopover }, { children: timePickerMarkup }), void 0));
30379
- const className = cssClassName(COMPONENT_NAME$3, theme, !value && 'isEmpty');
30429
+ useEffect(() => {
30430
+ setItems(getItemsMultiSelectionPicker());
30431
+ }, []);
30432
+ useEffect(() => {
30433
+ setItems(getItemsMultiSelectionPicker());
30434
+ }, [value]);
30435
+ const className = cssClassName(COMPONENT_NAME$4, theme, !value && 'isEmpty');
30380
30436
  return (jsxs("div", Object.assign({ className: className }, { children: [popoverMarkup, helpTextMarkup] }), void 0));
30381
30437
  };
30382
30438
  function getTimeValue(value) {
30439
+ if (value === undefined)
30440
+ return '';
30383
30441
  return value < 10 ? `0${value}` : `${value}`;
30384
- }
30385
- function getTimeList(min, max) {
30386
- const numbersArray = Array.from({ length: max - min + 1 }, (_, i) => i + min);
30387
- return numbersArray.map((number) => ({
30388
- label: getTimeValue(number),
30389
- value: number,
30390
- }));
30391
30442
  }
30392
30443
 
30393
- const COMPONENT_NAME$2 = 'FilterField';
30444
+ const COMPONENT_NAME$3 = 'FilterField';
30394
30445
  const FilterField = ({ label, isRequired = false, field, onRemove, name, }) => {
30395
- const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__LabelWrapper` }, { children: label }), void 0)) : null;
30396
- const filterFieldMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__FieldWrapper`, id: name }, { children: field }), void 0));
30397
- const removeButtonMarkup = onRemove && !isRequired ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__RemoveButtonWrapper` }, { children: jsx("button", Object.assign({ type: 'button', className: `${COMPONENT_NAME$2}__RemoveButton`, onClick: onRemove }, { children: jsx(Icon, { name: 'X' }, void 0) }), void 0) }), void 0)) : null;
30398
- return (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$2}` }, { children: [labelMarkup, filterFieldMarkup, removeButtonMarkup] }), void 0));
30446
+ const labelMarkup = label ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__LabelWrapper` }, { children: label }), void 0)) : null;
30447
+ const filterFieldMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__FieldWrapper`, id: name }, { children: field }), void 0));
30448
+ const removeButtonMarkup = onRemove && !isRequired ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$3}__RemoveButtonWrapper` }, { children: jsx("button", Object.assign({ type: 'button', className: `${COMPONENT_NAME$3}__RemoveButton`, onClick: onRemove }, { children: jsx(Icon, { name: 'X' }, void 0) }), void 0) }), void 0)) : null;
30449
+ return (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$3}` }, { children: [labelMarkup, filterFieldMarkup, removeButtonMarkup] }), void 0));
30399
30450
  };
30400
30451
 
30401
- const COMPONENT_NAME$1 = 'Filters';
30452
+ const COMPONENT_NAME$2 = 'Filters';
30402
30453
  const Filters = ({ ariaLabel, filters = [], onApplyFilters, onRemoveFilter, appliedFilters, onCleanFilters, onAddFilter, addFilterButtonIcon, addFilterButtonLabel, clearButtonLabel, searchButtonLabel, extraActions, selectedFilters = [], }) => {
30403
30454
  const [isPopoverOpen, setIsPopoverOpen] = useState(false);
30404
30455
  const mainContainerRef = useRef(null);
@@ -30422,8 +30473,8 @@ const Filters = ({ ariaLabel, filters = [], onApplyFilters, onRemoveFilter, appl
30422
30473
  const extraActionsMarkup = extraActions
30423
30474
  ? extraActions.map((extraAction, index) => (createElement(AlphaButton, Object.assign({}, extraAction, { key: `extra-action-${index}` }), extraAction.label)))
30424
30475
  : null;
30425
- const secondaryActionsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$1}__SecondaryActionsWrapper` }, { children: availableFiltersPopoverMarkup }), void 0));
30426
- const mainActionsMarkup = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$1}__MainActionsWrapper` }, { children: [extraActionsMarkup, jsx(AlphaButton, Object.assign({ ariaLabel: `${ariaLabel}-cleanFilters`, onClick: onCleanFilters, isDisabled: !appliedFilters.length && !selectedFilters.length }, { children: clearButtonLabel }), void 0), jsx(AlphaButton, Object.assign({ ariaLabel: `${ariaLabel}-searchFilters`, isDisabled: !appliedFilters.length && !selectedFilters.length, isPrimary: true, onClick: onApplyFilters }, { children: searchButtonLabel }), void 0)] }), void 0));
30476
+ const secondaryActionsMarkup = (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__SecondaryActionsWrapper` }, { children: availableFiltersPopoverMarkup }), void 0));
30477
+ const mainActionsMarkup = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$2}__MainActionsWrapper` }, { children: [extraActionsMarkup, jsx(AlphaButton, Object.assign({ ariaLabel: `${ariaLabel}-cleanFilters`, onClick: onCleanFilters, isDisabled: !appliedFilters.length && !selectedFilters.length }, { children: clearButtonLabel }), void 0), jsx(AlphaButton, Object.assign({ ariaLabel: `${ariaLabel}-searchFilters`, isDisabled: !appliedFilters.length && !selectedFilters.length, isPrimary: true, onClick: onApplyFilters }, { children: searchButtonLabel }), void 0)] }), void 0));
30427
30478
  const handleRemoveFilter = (filter) => {
30428
30479
  onRemoveFilter === null || onRemoveFilter === void 0 ? void 0 : onRemoveFilter(filter);
30429
30480
  };
@@ -30434,17 +30485,17 @@ const Filters = ({ ariaLabel, filters = [], onApplyFilters, onRemoveFilter, appl
30434
30485
  const handleRemove = () => {
30435
30486
  handleRemoveFilter(filter);
30436
30487
  };
30437
- return (jsx("div", Object.assign({ className: `${COMPONENT_NAME$1}__SelectedFilter` }, { children: jsx(FilterField, { label: foundFilter.label, field: foundFilter.filter, isRequired: foundFilter.isRequired, onRemove: handleRemove, name: filter }, void 0) }), index));
30488
+ return (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__SelectedFilter` }, { children: jsx(FilterField, { label: foundFilter.label, field: foundFilter.filter, isRequired: foundFilter.isRequired, onRemove: handleRemove, name: filter }, void 0) }), index));
30438
30489
  };
30439
- const selectedFiltersMarkup = selectedFilters.length ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$1}__SelectedFiltersWrapper` }, { children: selectedFilters.map(renderSelectedFilter) }), void 0)) : null;
30440
- const actionsContainerMarkup = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$1}__ActionsWrapper` }, { children: [secondaryActionsMarkup, mainActionsMarkup] }), void 0));
30441
- return (jsxs("div", Object.assign({ className: COMPONENT_NAME$1, ref: mainContainerRef }, { children: [selectedFiltersMarkup, actionsContainerMarkup] }), void 0));
30490
+ const selectedFiltersMarkup = selectedFilters.length ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME$2}__SelectedFiltersWrapper` }, { children: selectedFilters.map(renderSelectedFilter) }), void 0)) : null;
30491
+ const actionsContainerMarkup = (jsxs("div", Object.assign({ className: `${COMPONENT_NAME$2}__ActionsWrapper` }, { children: [secondaryActionsMarkup, mainActionsMarkup] }), void 0));
30492
+ return (jsxs("div", Object.assign({ className: COMPONENT_NAME$2, ref: mainContainerRef }, { children: [selectedFiltersMarkup, actionsContainerMarkup] }), void 0));
30442
30493
  };
30443
30494
 
30444
- const COMPONENT_NAME = 'Link';
30495
+ const COMPONENT_NAME$1 = 'Link';
30445
30496
  const Link = ({ children, className: classNameProp, component, to, target, }) => {
30446
30497
  const Component = component;
30447
- const className = cssClassName(COMPONENT_NAME, classNameProp);
30498
+ const className = cssClassName(COMPONENT_NAME$1, classNameProp);
30448
30499
  return (jsx(Component, Object.assign({ className: className, to: to, target: target }, { children: children }), void 0));
30449
30500
  };
30450
30501
 
@@ -30480,5 +30531,58 @@ const AlphaGraphicCard = ({ data }) => {
30480
30531
  return jsx("div", Object.assign({ className: MAIN_CLASS }, { children: data.map(renderContainer) }), void 0);
30481
30532
  };
30482
30533
 
30483
- export { ActionList, Alert, AlertProvider, AlphaAttributeInput, AlphaBadge, AlphaButton, AlphaChip, AlphaFilterControl, AlphaGraphicCard, AlphaIcon, AlphaInlineError, AlphaInputDate, InputTag$1 as AlphaInputTag, AlphaInputText, AlphaLabel, AlphaLabelledField, AlphaSpinner, AlphaStepper, AlphaTag, AlphaTile, AlphaTooltip, Totalizer as AlphaTotalizer, AnnotatedSection, Avatar, Badge, Banner, Button, CalendarPicker, Card, Checkbox, ChoiceList, Collapsible, Connector, Container, Cover, DataTable, DatePicker, DeletableSection, Divider, DynamicForm, EmptyState, ErrorIcon, FileDownloader, Filedrop, FilterControl, Filters, Footer, Form, FormField, FormLayout, Frame, Grid, GridItem, Header$1 as Header, Icon, IconButton, IndexList, InlineEdit, InputPhoneNumber, InputTag, InputText, JsonViewer, Label, Link, ListInfo, Loader, Logo, Media, Modal, ModalHeader, Nip, OptionList, Page, PageActions, Pagination, Pane, Panel, PanelFooter, PanelHeader, PendingIcon, Popover$1 as Popover, Progress, RadioButton, SectionForm, Select, SideMenu, SkeletonInput, SkeletonMedia, SkeletonTabs, SkeletonText, SkeletonTitle, SortableList, Spinner, Stack, StepDefault, SuccessIcon, Table, Tabs, Tag, ThemeProvider, ThreadItem, Thumbnail, Tile, TimeSelector, Title, Toggle, Tooltip, WarningIcon, capitalize, cssClassName, formatDate, isComponentTypeOf, isValidIcon, themeClassConverter, useShowAlert, useTheme };
30534
+ const COMPONENT_NAME = 'AlphaZipCodeInput';
30535
+ const AlphaZipCodeInput = ({ label, isRequired, items, onBlur, onFocus, onChange, value, labelEmpty, }) => {
30536
+ const [isFocusActive, setIsFocusActive] = useState(false);
30537
+ const [showPopover, setShowPopover] = useState(false);
30538
+ const handleOnBlur = () => {
30539
+ setIsFocusActive(false);
30540
+ if (onBlur)
30541
+ onBlur();
30542
+ };
30543
+ const handleOnFocus = () => {
30544
+ setIsFocusActive(true);
30545
+ setShowPopover(Boolean(value && (value === null || value === void 0 ? void 0 : value.length) > 2));
30546
+ if (onFocus)
30547
+ onFocus();
30548
+ };
30549
+ const handleOnChange = (event) => {
30550
+ const isValid = /^[0-9]+$/i.test(event.target.value) || event.target.value === '';
30551
+ if (isValid && onChange) {
30552
+ setShowPopover(event.target.value.length > 2);
30553
+ onChange(event.target.value);
30554
+ }
30555
+ };
30556
+ 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;
30557
+ const classesInput = cssClassName(`${COMPONENT_NAME}__InputWrapper`, isFocusActive && 'isFocus');
30558
+ 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));
30559
+ const handleOnSelectItem = (item) => {
30560
+ if (onChange)
30561
+ onChange(item[0]);
30562
+ setShowPopover(false);
30563
+ };
30564
+ const renderLabelItem = (item) => (jsxs("div", Object.assign({ className: `${COMPONENT_NAME}__ItemWrapper` }, { children: [jsx("div", Object.assign({ className: `${COMPONENT_NAME}__Item__Value` }, { children: item.cp }), void 0), jsxs("div", Object.assign({ className: `${COMPONENT_NAME}__Item__Description` }, { children: [item.municipality, ", ", item.city, ", ", item.state] }), void 0)] }), void 0));
30565
+ const itemsOptions = items.map((item) => ({
30566
+ label: renderLabelItem(item),
30567
+ value: item.cp,
30568
+ }));
30569
+ const optionListMarkup = items.length > 0 ? (jsx(OptionList, { items: itemsOptions, selected: [''], onChange: handleOnSelectItem }, void 0)) : null;
30570
+ const emptyItemsMarkup = items.length === 0 ? (jsx("div", Object.assign({ className: `${COMPONENT_NAME}__EmptyItems` }, { children: labelEmpty }), void 0)) : null;
30571
+ const popoverMarkup = useMemo(() => (jsx(Popover$1, Object.assign({ activator: inputMarkup, isActive: showPopover, isFullWidth: true, onClose: () => setShowPopover(false), isFixed: true }, { children: jsxs(Popover$1.Pane, { children: [optionListMarkup, emptyItemsMarkup] }, void 0) }), void 0)), [items, value, showPopover]);
30572
+ return (jsxs("div", Object.assign({ className: `${COMPONENT_NAME}__Wrapper` }, { children: [labelMarkup, popoverMarkup] }), void 0));
30573
+ };
30574
+
30575
+ const MAINCLASS = 'SegmentedControl';
30576
+ const AlphaSegmentedControl = ({ children, title, segments, selected, onSelected, }) => {
30577
+ const renderSegment = (segment, index) => {
30578
+ const classesControl = cssClassName(`${MAINCLASS}__ControlItem`, index === selected && 'isSelected');
30579
+ return (jsx("div", Object.assign({ className: classesControl, id: segment.panelID, "aria-label": segment.ariaLabel, onClick: () => onSelected(index) }, { children: segment.content }), `segmentControl-${index}`));
30580
+ };
30581
+ const controlMarkup = (jsx("div", Object.assign({ className: `${MAINCLASS}__ControlWrapper` }, { children: segments.map(renderSegment) }), void 0));
30582
+ const headerMarkup = (jsxs("div", Object.assign({ className: `${MAINCLASS}__HeaderWrapper` }, { children: [jsx("div", Object.assign({ className: `${MAINCLASS}__Title` }, { children: title }), void 0), controlMarkup] }), void 0));
30583
+ const contentMarkup = children ? (jsx("div", Object.assign({ className: `${MAINCLASS}__ContentWrapper` }, { children: children }), void 0)) : null;
30584
+ return (jsxs("div", Object.assign({ className: `${MAINCLASS}__Container` }, { children: [headerMarkup, contentMarkup] }), void 0));
30585
+ };
30586
+
30587
+ export { ActionList, Alert, AlertProvider, AlphaAttributeInput, AlphaBadge, AlphaButton, AlphaChip, AlphaFilterControl, AlphaGraphicCard, AlphaIcon, AlphaInlineError, AlphaInputDate, InputTag$1 as AlphaInputTag, AlphaInputText, AlphaLabel, AlphaLabelledField, AlphaMultiSelectionPicker, AlphaSegmentedControl, AlphaSpinner, AlphaStepper, AlphaTag, AlphaTile, AlphaTooltip, Totalizer as AlphaTotalizer, AlphaZipCodeInput, AnnotatedSection, Avatar, Badge, Banner, Button, CalendarPicker, Card, Checkbox, ChoiceList, Collapsible, Connector, Container, Cover, DataTable, DatePicker, DeletableSection, Divider, DynamicForm, EmptyState, ErrorIcon, FileDownloader, Filedrop, FilterControl, Filters, Footer, Form, FormField, FormLayout, Frame, Grid, GridItem, Header$1 as Header, Icon, IconButton, IndexList, InlineEdit, InputPhoneNumber, InputTag, InputText, JsonViewer, Label, Link, ListInfo, Loader, Logo, Media, Modal, ModalHeader, Nip, OptionList, Page, PageActions, Pagination, Pane, Panel, PanelFooter, PanelHeader, PendingIcon, Popover$1 as Popover, Progress, RadioButton, SectionForm, Select, SideMenu, SkeletonInput, SkeletonMedia, SkeletonTabs, SkeletonText, SkeletonTitle, SortableList, Spinner, Stack, StepDefault, SuccessIcon, Table, Tabs, Tag, ThemeProvider, ThreadItem, Thumbnail, Tile, TimeSelector, Title, Toggle, Tooltip, WarningIcon, capitalize, cssClassName, formatDate, formatFileSize, isComponentTypeOf, isValidIcon, themeClassConverter, useShowAlert, useTheme };
30484
30588
  //# sourceMappingURL=index.js.map