sag_components 2.0.0-beta217 → 2.0.0-beta219
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.esm.js +139 -74
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +139 -74
- package/dist/index.js.map +1 -1
- package/dist/types/components/Table/TableBody.styles.d.ts +1 -0
- package/dist/types/components/Table/data.d.ts +17 -0
- package/dist/types/icons/HeroIcon.d.ts +6 -0
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -10580,23 +10580,24 @@ const QuarterPopupPicker = ({
|
|
|
10580
10580
|
};
|
|
10581
10581
|
|
|
10582
10582
|
/* eslint-disable import/no-extraneous-dependencies */
|
|
10583
|
-
const QuarterPicker =
|
|
10584
|
-
|
|
10585
|
-
|
|
10586
|
-
|
|
10587
|
-
|
|
10588
|
-
|
|
10589
|
-
|
|
10590
|
-
|
|
10591
|
-
|
|
10592
|
-
|
|
10593
|
-
|
|
10594
|
-
|
|
10595
|
-
|
|
10596
|
-
|
|
10597
|
-
|
|
10598
|
-
|
|
10599
|
-
|
|
10583
|
+
const QuarterPicker = _ref => {
|
|
10584
|
+
let {
|
|
10585
|
+
availableQuarters,
|
|
10586
|
+
// ["Q1-2024"]
|
|
10587
|
+
label,
|
|
10588
|
+
onChange,
|
|
10589
|
+
borderRadius,
|
|
10590
|
+
required,
|
|
10591
|
+
width,
|
|
10592
|
+
height,
|
|
10593
|
+
placeholder,
|
|
10594
|
+
disabled,
|
|
10595
|
+
borderColor,
|
|
10596
|
+
borderColorFocus,
|
|
10597
|
+
textColor,
|
|
10598
|
+
selectedValue,
|
|
10599
|
+
startYear
|
|
10600
|
+
} = _ref;
|
|
10600
10601
|
const [isFocused, setIsFocused] = useState(false);
|
|
10601
10602
|
const [isOpen, setIsOpen] = useState(false);
|
|
10602
10603
|
const [value, setValue] = useState('');
|
|
@@ -11038,22 +11039,23 @@ const MonthPopupPicker = ({
|
|
|
11038
11039
|
};
|
|
11039
11040
|
|
|
11040
11041
|
/* eslint-disable import/no-extraneous-dependencies */
|
|
11041
|
-
const MonthPicker =
|
|
11042
|
-
|
|
11043
|
-
|
|
11044
|
-
|
|
11045
|
-
|
|
11046
|
-
|
|
11047
|
-
|
|
11048
|
-
|
|
11049
|
-
|
|
11050
|
-
|
|
11051
|
-
|
|
11052
|
-
|
|
11053
|
-
|
|
11054
|
-
|
|
11055
|
-
|
|
11056
|
-
|
|
11042
|
+
const MonthPicker = _ref => {
|
|
11043
|
+
let {
|
|
11044
|
+
availableMonths,
|
|
11045
|
+
label,
|
|
11046
|
+
onChange,
|
|
11047
|
+
borderRadius,
|
|
11048
|
+
required,
|
|
11049
|
+
width,
|
|
11050
|
+
height,
|
|
11051
|
+
placeholder,
|
|
11052
|
+
disabled,
|
|
11053
|
+
borderColor,
|
|
11054
|
+
borderColorFocus,
|
|
11055
|
+
textColor,
|
|
11056
|
+
selectedValue,
|
|
11057
|
+
startYear
|
|
11058
|
+
} = _ref;
|
|
11057
11059
|
const [isFocused, setIsFocused] = useState(false);
|
|
11058
11060
|
const [isOpen, setIsOpen] = useState(false);
|
|
11059
11061
|
const [value, setValue] = useState('');
|
|
@@ -24164,21 +24166,22 @@ const DeleteIcon = styled.div`
|
|
|
24164
24166
|
position: absolute;
|
|
24165
24167
|
`;
|
|
24166
24168
|
|
|
24167
|
-
const QuickFilterDropdownSingle =
|
|
24168
|
-
|
|
24169
|
-
|
|
24170
|
-
|
|
24171
|
-
|
|
24172
|
-
|
|
24173
|
-
|
|
24174
|
-
|
|
24175
|
-
|
|
24176
|
-
|
|
24177
|
-
|
|
24178
|
-
|
|
24179
|
-
|
|
24180
|
-
|
|
24181
|
-
|
|
24169
|
+
const QuickFilterDropdownSingle = _ref => {
|
|
24170
|
+
let {
|
|
24171
|
+
label,
|
|
24172
|
+
hoverColor,
|
|
24173
|
+
options,
|
|
24174
|
+
selectedValue,
|
|
24175
|
+
placeHolder,
|
|
24176
|
+
onChange,
|
|
24177
|
+
disabled,
|
|
24178
|
+
width,
|
|
24179
|
+
error,
|
|
24180
|
+
errorMessage,
|
|
24181
|
+
xIconShow,
|
|
24182
|
+
labelColor,
|
|
24183
|
+
showLabelOnTop
|
|
24184
|
+
} = _ref;
|
|
24182
24185
|
const [isFocused, setIsFocused] = useState(false);
|
|
24183
24186
|
const [showOptions, setShowOptions] = useState(false);
|
|
24184
24187
|
const [inputValue, setInputValue] = useState("");
|
|
@@ -24635,25 +24638,26 @@ const IconContainer$2 = styled.div`
|
|
|
24635
24638
|
cursor: pointer;
|
|
24636
24639
|
`;
|
|
24637
24640
|
|
|
24638
|
-
const QuickFilterDropdownMultiSelection =
|
|
24639
|
-
|
|
24640
|
-
|
|
24641
|
-
|
|
24642
|
-
|
|
24643
|
-
|
|
24644
|
-
|
|
24645
|
-
|
|
24646
|
-
|
|
24647
|
-
|
|
24648
|
-
|
|
24649
|
-
|
|
24650
|
-
|
|
24651
|
-
|
|
24652
|
-
|
|
24653
|
-
|
|
24654
|
-
|
|
24655
|
-
|
|
24656
|
-
|
|
24641
|
+
const QuickFilterDropdownMultiSelection = _ref => {
|
|
24642
|
+
let {
|
|
24643
|
+
label,
|
|
24644
|
+
labelEmptyValue,
|
|
24645
|
+
options,
|
|
24646
|
+
selectedValue,
|
|
24647
|
+
placeHolder,
|
|
24648
|
+
onChange,
|
|
24649
|
+
required,
|
|
24650
|
+
disabled,
|
|
24651
|
+
width,
|
|
24652
|
+
height,
|
|
24653
|
+
error,
|
|
24654
|
+
errorMessage,
|
|
24655
|
+
labelColor,
|
|
24656
|
+
xIconShow,
|
|
24657
|
+
checkBoxColor,
|
|
24658
|
+
showLabelOnTop,
|
|
24659
|
+
dropdownHeight
|
|
24660
|
+
} = _ref;
|
|
24657
24661
|
const [isFocused, setIsFocused] = useState(false);
|
|
24658
24662
|
const [showOptions, setShowOptions] = useState(false);
|
|
24659
24663
|
const [inputValue, setInputValue] = useState('');
|
|
@@ -36137,9 +36141,9 @@ const ToggleSlider = styled.span`
|
|
|
36137
36141
|
}
|
|
36138
36142
|
`;
|
|
36139
36143
|
|
|
36140
|
-
/**
|
|
36141
|
-
* ToggleSwitch component for on/off states.
|
|
36142
|
-
* Supports small/large sizes and disabled state.
|
|
36144
|
+
/**
|
|
36145
|
+
* ToggleSwitch component for on/off states.
|
|
36146
|
+
* Supports small/large sizes and disabled state.
|
|
36143
36147
|
*/
|
|
36144
36148
|
function ToggleSwitch(_ref) {
|
|
36145
36149
|
let {
|
|
@@ -39611,6 +39615,14 @@ styled.div`
|
|
|
39611
39615
|
}
|
|
39612
39616
|
`}
|
|
39613
39617
|
`;
|
|
39618
|
+
const HeroButton = styled.button`
|
|
39619
|
+
display: flex;
|
|
39620
|
+
align-items: center;
|
|
39621
|
+
justify-content: center;
|
|
39622
|
+
cursor: pointer;
|
|
39623
|
+
background-color: transparent;
|
|
39624
|
+
border: none;
|
|
39625
|
+
`;
|
|
39614
39626
|
|
|
39615
39627
|
// MessageBox.styles.js
|
|
39616
39628
|
const ModalOverlay = styled.div`
|
|
@@ -40074,6 +40086,38 @@ Dropdown.propTypes = {
|
|
|
40074
40086
|
placeholder: PropTypes.string
|
|
40075
40087
|
};
|
|
40076
40088
|
|
|
40089
|
+
const HeroIcon = ({
|
|
40090
|
+
width = '12',
|
|
40091
|
+
height = '16',
|
|
40092
|
+
full = false
|
|
40093
|
+
}) => full ? /*#__PURE__*/React$1.createElement("svg", {
|
|
40094
|
+
width: width,
|
|
40095
|
+
height: height,
|
|
40096
|
+
viewBox: "0 0 12 16",
|
|
40097
|
+
fill: "none",
|
|
40098
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
40099
|
+
}, /*#__PURE__*/React$1.createElement("path", {
|
|
40100
|
+
d: "M0 1.5V15.2406C0 15.6594 0.340625 16 0.759375 16C0.915625 16 1.06875 15.9531 1.19687 15.8625L6 12.5L10.8031 15.8625C10.9313 15.9531 11.0844 16 11.2406 16C11.6594 16 12 15.6594 12 15.2406V1.5C12 0.671875 11.3281 0 10.5 0H1.5C0.671875 0 0 0.671875 0 1.5Z",
|
|
40101
|
+
fill: "#066768"
|
|
40102
|
+
})) : /*#__PURE__*/React$1.createElement("svg", {
|
|
40103
|
+
width: width,
|
|
40104
|
+
height: height,
|
|
40105
|
+
viewBox: "0 0 12 16",
|
|
40106
|
+
fill: "none",
|
|
40107
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
40108
|
+
}, /*#__PURE__*/React$1.createElement("g", {
|
|
40109
|
+
"clip-path": "url(#clip0_2338_96732)"
|
|
40110
|
+
}, /*#__PURE__*/React$1.createElement("path", {
|
|
40111
|
+
d: "M0 1.5C0 0.671875 0.671875 0 1.5 0H10.5C11.3281 0 12 0.671875 12 1.5V15.3094C12 15.6906 11.6906 16 11.3094 16C11.1719 16 11.0406 15.9594 10.925 15.8844L6 12.6L1.075 15.8844C0.9625 15.9594 0.828125 16 0.690625 16C0.309375 16 0 15.6906 0 15.3094V1.5ZM1.5 1C1.225 1 1 1.225 1 1.5V14.7312L5.72188 11.5844C5.89062 11.4719 6.10938 11.4719 6.27812 11.5844L11 14.7312V1.5C11 1.225 10.775 1 10.5 1H1.5Z",
|
|
40112
|
+
fill: "#066768"
|
|
40113
|
+
})), /*#__PURE__*/React$1.createElement("defs", null, /*#__PURE__*/React$1.createElement("clipPath", {
|
|
40114
|
+
id: "clip0_2338_96732"
|
|
40115
|
+
}, /*#__PURE__*/React$1.createElement("rect", {
|
|
40116
|
+
width: "12",
|
|
40117
|
+
height: "16",
|
|
40118
|
+
fill: "white"
|
|
40119
|
+
}))));
|
|
40120
|
+
|
|
40077
40121
|
// combinedShimmerHooks.js - Chrome shimmer effect integrated with your hooks
|
|
40078
40122
|
|
|
40079
40123
|
// Chrome Shimmer Component
|
|
@@ -40173,7 +40217,8 @@ const TableBody = /*#__PURE__*/forwardRef(({
|
|
|
40173
40217
|
expandedBackgroundColor = "#E6F0F0",
|
|
40174
40218
|
onDropdownSelected = () => {},
|
|
40175
40219
|
onCheckboxClick = () => {},
|
|
40176
|
-
onHeaderCheckboxClick = () => {}
|
|
40220
|
+
onHeaderCheckboxClick = () => {},
|
|
40221
|
+
onHeroClick = () => {}
|
|
40177
40222
|
}, ref) => {
|
|
40178
40223
|
// MOVE ALL VALIDATION TO THE VERY TOP BEFORE ANY HOOKS
|
|
40179
40224
|
if (!Array.isArray(data) || !Array.isArray(columns)) {
|
|
@@ -40711,6 +40756,23 @@ const TableBody = /*#__PURE__*/forwardRef(({
|
|
|
40711
40756
|
console.warn('Error formatting checkbox:', e);
|
|
40712
40757
|
return String(value || "");
|
|
40713
40758
|
}
|
|
40759
|
+
case "hero":
|
|
40760
|
+
try {
|
|
40761
|
+
if (value === null || value === undefined) return null;
|
|
40762
|
+
return /*#__PURE__*/React$1.createElement(HeroButton, {
|
|
40763
|
+
onClick: e => {
|
|
40764
|
+
// e.stopPropagation();
|
|
40765
|
+
if (onHeroClick) {
|
|
40766
|
+
onHeroClick(row, !value);
|
|
40767
|
+
}
|
|
40768
|
+
}
|
|
40769
|
+
}, /*#__PURE__*/React$1.createElement(HeroIcon, {
|
|
40770
|
+
full: Boolean(value)
|
|
40771
|
+
}));
|
|
40772
|
+
} catch (e) {
|
|
40773
|
+
console.warn('Error formatting hero icon:', e);
|
|
40774
|
+
return null;
|
|
40775
|
+
}
|
|
40714
40776
|
default:
|
|
40715
40777
|
return String(value || "");
|
|
40716
40778
|
}
|
|
@@ -40944,7 +41006,8 @@ TableBody.propTypes = {
|
|
|
40944
41006
|
expandedBackgroundColor: PropTypes.string,
|
|
40945
41007
|
onDropdownSelected: PropTypes.func,
|
|
40946
41008
|
onCheckboxClick: PropTypes.func,
|
|
40947
|
-
onHeaderCheckboxClick: PropTypes.func
|
|
41009
|
+
onHeaderCheckboxClick: PropTypes.func,
|
|
41010
|
+
onHeroClick: PropTypes.func
|
|
40948
41011
|
};
|
|
40949
41012
|
TableBody.displayName = "TableBody";
|
|
40950
41013
|
|
|
@@ -44307,6 +44370,7 @@ const Table = props => {
|
|
|
44307
44370
|
onCheckboxClick = () => {},
|
|
44308
44371
|
onHeaderCheckboxClick = () => {},
|
|
44309
44372
|
headerCheckboxStates = {},
|
|
44373
|
+
onHeroClick = () => {},
|
|
44310
44374
|
// Accept ref as a regular prop
|
|
44311
44375
|
ref = null
|
|
44312
44376
|
} = props;
|
|
@@ -44458,7 +44522,8 @@ const Table = props => {
|
|
|
44458
44522
|
expandedBackgroundColor: expandedBackgroundColor,
|
|
44459
44523
|
onDropdownSelected: onDropdownSelected,
|
|
44460
44524
|
onCheckboxClick: onCheckboxClick,
|
|
44461
|
-
onHeaderCheckboxClick: onHeaderCheckboxClick
|
|
44525
|
+
onHeaderCheckboxClick: onHeaderCheckboxClick,
|
|
44526
|
+
onHeroClick: onHeroClick
|
|
44462
44527
|
})), data.length === 0 && /*#__PURE__*/React$1.createElement(NoEventsParent, null, /*#__PURE__*/React$1.createElement(NoEventsWrapper, null, showNoDataInSearch ? getNoDataSearchIcon(noDataSearchIcon) : getNoDataIcon(noDataIcon)), /*#__PURE__*/React$1.createElement(NoEventsMessage, null, showNoDataInSearch ? /*#__PURE__*/React$1.createElement(React$1.Fragment, null, /*#__PURE__*/React$1.createElement("strong", null, noDataInSearchTitle), /*#__PURE__*/React$1.createElement("br", null), noDataInSearchMessage) : /*#__PURE__*/React$1.createElement(React$1.Fragment, null, /*#__PURE__*/React$1.createElement("strong", null, noEventsTitle), /*#__PURE__*/React$1.createElement("br", null), noEventsSubtitle)), !showNoDataInSearch && showNoEventsButton && /*#__PURE__*/React$1.createElement(Button$1, {
|
|
44463
44528
|
height: "45px",
|
|
44464
44529
|
leftIcon: noEventsButtonIcon,
|
|
@@ -55026,7 +55091,7 @@ const OverlayDropdown = _ref => {
|
|
|
55026
55091
|
const [hoveredText, setHoveredText] = useState(null);
|
|
55027
55092
|
const [templateDialog, setTemplateDialog] = useState(null);
|
|
55028
55093
|
const [dropdownPosition, setDropdownPosition] = useState('below');
|
|
55029
|
-
const [lastDefinedGroup, setLastDefinedGroup] = useState(
|
|
55094
|
+
const [lastDefinedGroup, setLastDefinedGroup] = useState(data.find(group => group.overlayCode === 'last_defined'));
|
|
55030
55095
|
const buttonRef = useRef(null);
|
|
55031
55096
|
const dropdownRef = useRef(null);
|
|
55032
55097
|
const containerRef = useRef(null);
|