sag_components 2.0.0-beta269 → 2.0.0-beta270
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +5 -1
- package/dist/index.esm.js +84 -74
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +84 -74
- package/dist/index.js.map +1 -1
- package/dist/types/components/Input/Input.d.ts +5 -1
- package/dist/types/components/Input/Input.stories.d.ts +93 -72
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1305,7 +1305,7 @@ declare function WeeksPicker({ label, disabled, borderColor, borderColorFocus, t
|
|
|
1305
1305
|
restrictToRange?: boolean;
|
|
1306
1306
|
}): react_jsx_runtime.JSX.Element;
|
|
1307
1307
|
|
|
1308
|
-
declare function Input({ label, labelEmptyValue, size, selectedValue, placeHolder, inputType, onChange, onClick, onBlur, required, disabled, isDarkerBackground, width, height, error, errorMessage, labelColor, leftIcon, rightIcon, password, leftIconOnClick, rightIconOnClick, multiline, rows, maxLength, regex, onKeyDown, }: {
|
|
1308
|
+
declare function Input({ label, labelEmptyValue, size, selectedValue, placeHolder, inputType, onChange, onClick, onBlur, required, disabled, isDarkerBackground, width, minWidth, height, error, errorMessage, labelColor, leftIcon, rightIcon, password, leftIconOnClick, rightIconOnClick, multiline, rows, maxLength, regex, onKeyDown, }: {
|
|
1309
1309
|
label: any;
|
|
1310
1310
|
labelEmptyValue: any;
|
|
1311
1311
|
size: any;
|
|
@@ -1319,6 +1319,7 @@ declare function Input({ label, labelEmptyValue, size, selectedValue, placeHolde
|
|
|
1319
1319
|
disabled: any;
|
|
1320
1320
|
isDarkerBackground?: boolean;
|
|
1321
1321
|
width: any;
|
|
1322
|
+
minWidth: any;
|
|
1322
1323
|
height?: string;
|
|
1323
1324
|
error: any;
|
|
1324
1325
|
errorMessage: any;
|
|
@@ -1343,6 +1344,7 @@ declare namespace Input {
|
|
|
1343
1344
|
const labelColor: PropTypes.Requireable<string>;
|
|
1344
1345
|
const required: PropTypes.Requireable<boolean>;
|
|
1345
1346
|
const width: PropTypes.Requireable<string>;
|
|
1347
|
+
const minWidth: PropTypes.Requireable<string>;
|
|
1346
1348
|
const disabled: PropTypes.Requireable<boolean>;
|
|
1347
1349
|
const error: PropTypes.Requireable<boolean>;
|
|
1348
1350
|
const errorMessage: PropTypes.Requireable<string>;
|
|
@@ -1376,6 +1378,8 @@ declare namespace Input {
|
|
|
1376
1378
|
export { required_1 as required };
|
|
1377
1379
|
const width_1: string;
|
|
1378
1380
|
export { width_1 as width };
|
|
1381
|
+
const minWidth_1: string;
|
|
1382
|
+
export { minWidth_1 as minWidth };
|
|
1379
1383
|
const disabled_1: boolean;
|
|
1380
1384
|
export { disabled_1 as disabled };
|
|
1381
1385
|
const error_1: boolean;
|
package/dist/index.esm.js
CHANGED
|
@@ -10581,23 +10581,24 @@ const QuarterPopupPicker = ({
|
|
|
10581
10581
|
};
|
|
10582
10582
|
|
|
10583
10583
|
/* eslint-disable import/no-extraneous-dependencies */
|
|
10584
|
-
const QuarterPicker =
|
|
10585
|
-
|
|
10586
|
-
|
|
10587
|
-
|
|
10588
|
-
|
|
10589
|
-
|
|
10590
|
-
|
|
10591
|
-
|
|
10592
|
-
|
|
10593
|
-
|
|
10594
|
-
|
|
10595
|
-
|
|
10596
|
-
|
|
10597
|
-
|
|
10598
|
-
|
|
10599
|
-
|
|
10600
|
-
|
|
10584
|
+
const QuarterPicker = _ref => {
|
|
10585
|
+
let {
|
|
10586
|
+
availableQuarters,
|
|
10587
|
+
// ["Q1-2024"]
|
|
10588
|
+
label,
|
|
10589
|
+
onChange,
|
|
10590
|
+
borderRadius,
|
|
10591
|
+
required,
|
|
10592
|
+
width,
|
|
10593
|
+
height,
|
|
10594
|
+
placeholder,
|
|
10595
|
+
disabled,
|
|
10596
|
+
borderColor,
|
|
10597
|
+
borderColorFocus,
|
|
10598
|
+
textColor,
|
|
10599
|
+
selectedValue,
|
|
10600
|
+
startYear
|
|
10601
|
+
} = _ref;
|
|
10601
10602
|
const [isFocused, setIsFocused] = useState(false);
|
|
10602
10603
|
const [isOpen, setIsOpen] = useState(false);
|
|
10603
10604
|
const [value, setValue] = useState('');
|
|
@@ -11039,22 +11040,23 @@ const MonthPopupPicker = ({
|
|
|
11039
11040
|
};
|
|
11040
11041
|
|
|
11041
11042
|
/* eslint-disable import/no-extraneous-dependencies */
|
|
11042
|
-
const MonthPicker =
|
|
11043
|
-
|
|
11044
|
-
|
|
11045
|
-
|
|
11046
|
-
|
|
11047
|
-
|
|
11048
|
-
|
|
11049
|
-
|
|
11050
|
-
|
|
11051
|
-
|
|
11052
|
-
|
|
11053
|
-
|
|
11054
|
-
|
|
11055
|
-
|
|
11056
|
-
|
|
11057
|
-
|
|
11043
|
+
const MonthPicker = _ref => {
|
|
11044
|
+
let {
|
|
11045
|
+
availableMonths,
|
|
11046
|
+
label,
|
|
11047
|
+
onChange,
|
|
11048
|
+
borderRadius,
|
|
11049
|
+
required,
|
|
11050
|
+
width,
|
|
11051
|
+
height,
|
|
11052
|
+
placeholder,
|
|
11053
|
+
disabled,
|
|
11054
|
+
borderColor,
|
|
11055
|
+
borderColorFocus,
|
|
11056
|
+
textColor,
|
|
11057
|
+
selectedValue,
|
|
11058
|
+
startYear
|
|
11059
|
+
} = _ref;
|
|
11058
11060
|
const [isFocused, setIsFocused] = useState(false);
|
|
11059
11061
|
const [isOpen, setIsOpen] = useState(false);
|
|
11060
11062
|
const [value, setValue] = useState('');
|
|
@@ -24165,21 +24167,22 @@ const DeleteIcon = styled.div`
|
|
|
24165
24167
|
position: absolute;
|
|
24166
24168
|
`;
|
|
24167
24169
|
|
|
24168
|
-
const QuickFilterDropdownSingle =
|
|
24169
|
-
|
|
24170
|
-
|
|
24171
|
-
|
|
24172
|
-
|
|
24173
|
-
|
|
24174
|
-
|
|
24175
|
-
|
|
24176
|
-
|
|
24177
|
-
|
|
24178
|
-
|
|
24179
|
-
|
|
24180
|
-
|
|
24181
|
-
|
|
24182
|
-
|
|
24170
|
+
const QuickFilterDropdownSingle = _ref => {
|
|
24171
|
+
let {
|
|
24172
|
+
label,
|
|
24173
|
+
hoverColor,
|
|
24174
|
+
options,
|
|
24175
|
+
selectedValue,
|
|
24176
|
+
placeHolder,
|
|
24177
|
+
onChange,
|
|
24178
|
+
disabled,
|
|
24179
|
+
width,
|
|
24180
|
+
error,
|
|
24181
|
+
errorMessage,
|
|
24182
|
+
xIconShow,
|
|
24183
|
+
labelColor,
|
|
24184
|
+
showLabelOnTop
|
|
24185
|
+
} = _ref;
|
|
24183
24186
|
const [isFocused, setIsFocused] = useState(false);
|
|
24184
24187
|
const [showOptions, setShowOptions] = useState(false);
|
|
24185
24188
|
const [inputValue, setInputValue] = useState("");
|
|
@@ -24636,25 +24639,26 @@ const IconContainer$2 = styled.div`
|
|
|
24636
24639
|
cursor: pointer;
|
|
24637
24640
|
`;
|
|
24638
24641
|
|
|
24639
|
-
const QuickFilterDropdownMultiSelection =
|
|
24640
|
-
|
|
24641
|
-
|
|
24642
|
-
|
|
24643
|
-
|
|
24644
|
-
|
|
24645
|
-
|
|
24646
|
-
|
|
24647
|
-
|
|
24648
|
-
|
|
24649
|
-
|
|
24650
|
-
|
|
24651
|
-
|
|
24652
|
-
|
|
24653
|
-
|
|
24654
|
-
|
|
24655
|
-
|
|
24656
|
-
|
|
24657
|
-
|
|
24642
|
+
const QuickFilterDropdownMultiSelection = _ref => {
|
|
24643
|
+
let {
|
|
24644
|
+
label,
|
|
24645
|
+
labelEmptyValue,
|
|
24646
|
+
options,
|
|
24647
|
+
selectedValue,
|
|
24648
|
+
placeHolder,
|
|
24649
|
+
onChange,
|
|
24650
|
+
required,
|
|
24651
|
+
disabled,
|
|
24652
|
+
width,
|
|
24653
|
+
height,
|
|
24654
|
+
error,
|
|
24655
|
+
errorMessage,
|
|
24656
|
+
labelColor,
|
|
24657
|
+
xIconShow,
|
|
24658
|
+
checkBoxColor,
|
|
24659
|
+
showLabelOnTop,
|
|
24660
|
+
dropdownHeight
|
|
24661
|
+
} = _ref;
|
|
24658
24662
|
const [isFocused, setIsFocused] = useState(false);
|
|
24659
24663
|
const [showOptions, setShowOptions] = useState(false);
|
|
24660
24664
|
const [inputValue, setInputValue] = useState('');
|
|
@@ -35659,7 +35663,7 @@ const MainContainer = styled.div`
|
|
|
35659
35663
|
justify-content: flex-start;
|
|
35660
35664
|
align-items: flex-start;
|
|
35661
35665
|
width: ${props => props.width || '300px'};
|
|
35662
|
-
|
|
35666
|
+
min-width: ${props => props.minWidth || 'unset'};
|
|
35663
35667
|
height: ${props => props.height || '45px'};
|
|
35664
35668
|
min-height: ${props => props.multiline ? '80px' : 'auto'};
|
|
35665
35669
|
font-family: "Poppins", sans-serif;
|
|
@@ -35820,6 +35824,7 @@ const ErrorMessage = styled.div`
|
|
|
35820
35824
|
color: red;
|
|
35821
35825
|
margin-top: 5px;
|
|
35822
35826
|
max-width: ${props => props.width || '300px'};
|
|
35827
|
+
min-width: ${props => props.minWidth || 'unset'};
|
|
35823
35828
|
`;
|
|
35824
35829
|
const IconWrapper$1 = styled.div`
|
|
35825
35830
|
display: flex;
|
|
@@ -35848,6 +35853,7 @@ const Input$2 = _ref => {
|
|
|
35848
35853
|
disabled,
|
|
35849
35854
|
isDarkerBackground = false,
|
|
35850
35855
|
width,
|
|
35856
|
+
minWidth,
|
|
35851
35857
|
height = "50px",
|
|
35852
35858
|
error,
|
|
35853
35859
|
errorMessage,
|
|
@@ -35878,7 +35884,7 @@ const Input$2 = _ref => {
|
|
|
35878
35884
|
const hasOverflow = element.scrollWidth > element.clientWidth;
|
|
35879
35885
|
setIsOverflowing(hasOverflow);
|
|
35880
35886
|
}
|
|
35881
|
-
}, [inputValue, multiline, width, isFocused]);
|
|
35887
|
+
}, [inputValue, multiline, width, minWidth, isFocused]);
|
|
35882
35888
|
const handleLabelClick = () => {
|
|
35883
35889
|
if (disabled) return;
|
|
35884
35890
|
setIsFocused(true);
|
|
@@ -35973,7 +35979,8 @@ const Input$2 = _ref => {
|
|
|
35973
35979
|
isDarkerBackground: isDarkerBackground,
|
|
35974
35980
|
multiline: multiline,
|
|
35975
35981
|
onClick: handleContainerClick,
|
|
35976
|
-
title: isOverflowing && inputValue && !isFocused ? inputValue : ""
|
|
35982
|
+
title: isOverflowing && inputValue && !isFocused ? inputValue : "",
|
|
35983
|
+
minWidth: minWidth
|
|
35977
35984
|
}, /*#__PURE__*/React$1.createElement(InputContainer, {
|
|
35978
35985
|
className: "InputContainer",
|
|
35979
35986
|
labelColor: labelColor,
|
|
@@ -36033,7 +36040,8 @@ const Input$2 = _ref => {
|
|
|
36033
36040
|
multiline: multiline
|
|
36034
36041
|
})), !multiline && (password ? getPasswordIcon() : getRightIcon())), error && errorMessage?.length > 0 && /*#__PURE__*/React$1.createElement(ErrorMessage, {
|
|
36035
36042
|
className: "ErrorMessage",
|
|
36036
|
-
width: width
|
|
36043
|
+
width: width,
|
|
36044
|
+
minWidth: minWidth
|
|
36037
36045
|
}, errorMessage), multiline && maxLength && /*#__PURE__*/React$1.createElement("div", {
|
|
36038
36046
|
style: {
|
|
36039
36047
|
fontSize: "12px",
|
|
@@ -36051,6 +36059,7 @@ Input$2.propTypes = {
|
|
|
36051
36059
|
labelColor: PropTypes.string,
|
|
36052
36060
|
required: PropTypes.bool,
|
|
36053
36061
|
width: PropTypes.string,
|
|
36062
|
+
minWidth: PropTypes.string,
|
|
36054
36063
|
disabled: PropTypes.bool,
|
|
36055
36064
|
error: PropTypes.bool,
|
|
36056
36065
|
errorMessage: PropTypes.string,
|
|
@@ -36077,6 +36086,7 @@ Input$2.defaultProps = {
|
|
|
36077
36086
|
labelColor: "#066768",
|
|
36078
36087
|
required: true,
|
|
36079
36088
|
width: "300px",
|
|
36089
|
+
minWidth: "300px",
|
|
36080
36090
|
disabled: false,
|
|
36081
36091
|
error: false,
|
|
36082
36092
|
errorMessage: "",
|
|
@@ -36165,9 +36175,9 @@ const ToggleSlider = styled.span`
|
|
|
36165
36175
|
}
|
|
36166
36176
|
`;
|
|
36167
36177
|
|
|
36168
|
-
/**
|
|
36169
|
-
* ToggleSwitch component for on/off states.
|
|
36170
|
-
* Supports small/large sizes and disabled state.
|
|
36178
|
+
/**
|
|
36179
|
+
* ToggleSwitch component for on/off states.
|
|
36180
|
+
* Supports small/large sizes and disabled state.
|
|
36171
36181
|
*/
|
|
36172
36182
|
function ToggleSwitch(_ref) {
|
|
36173
36183
|
let {
|