@banyan_cloud/roots 1.0.341 → 1.0.343
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/cjs/index.js +28 -6
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +28 -6
- package/dist/esm/index.js.map +1 -1
- package/dist/index.js +28 -6
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -15635,7 +15635,8 @@ var Dates = function Dates(props) {
|
|
|
15635
15635
|
setSelectedRange = props.setSelectedRange,
|
|
15636
15636
|
disabledDates = props.disabledDates,
|
|
15637
15637
|
disableDatesBefore = props.disableDatesBefore,
|
|
15638
|
-
enableFutureDates = props.enableFutureDates
|
|
15638
|
+
enableFutureDates = props.enableFutureDates,
|
|
15639
|
+
disableDatesAfter = props.disableDatesAfter;
|
|
15639
15640
|
var _ref = selectedMonth || {},
|
|
15640
15641
|
monthAsNumber = _ref.monthAsNumber,
|
|
15641
15642
|
year = _ref.year;
|
|
@@ -15731,6 +15732,9 @@ var Dates = function Dates(props) {
|
|
|
15731
15732
|
return (disableDatesBefore === null || disableDatesBefore === void 0 ? void 0 : disableDatesBefore.length) > 0 && isBefore(date, fromUnixTime(disableDatesBefore));
|
|
15732
15733
|
};
|
|
15733
15734
|
var disabledAfterDate = function disabledAfterDate(date) {
|
|
15735
|
+
if (disableDatesAfter) {
|
|
15736
|
+
return (disableDatesAfter === null || disableDatesAfter === void 0 ? void 0 : disableDatesAfter.length) > 0 && isAfter(date, fromUnixTime(disableDatesAfter));
|
|
15737
|
+
}
|
|
15734
15738
|
var dObj = new Date();
|
|
15735
15739
|
dObj.setDate(dObj.getDate() + 1);
|
|
15736
15740
|
dObj.setHours(0, 0, 0, 0);
|
|
@@ -16192,6 +16196,7 @@ var Calender = function Calender(props) {
|
|
|
16192
16196
|
onClear = props.onClear,
|
|
16193
16197
|
disabledDates = props.disabledDates,
|
|
16194
16198
|
disableDatesBefore = props.disableDatesBefore,
|
|
16199
|
+
disableDatesAfter = props.disableDatesAfter,
|
|
16195
16200
|
value = props.value,
|
|
16196
16201
|
setFixedRange = props.setFixedRange,
|
|
16197
16202
|
fixedRange = props.fixedRange,
|
|
@@ -16397,6 +16402,7 @@ var Calender = function Calender(props) {
|
|
|
16397
16402
|
setSelectedMonth: setSelectedMonth,
|
|
16398
16403
|
disabledDates: disabledDates,
|
|
16399
16404
|
disableDatesBefore: disableDatesBefore,
|
|
16405
|
+
disableDatesAfter: disableDatesAfter,
|
|
16400
16406
|
enableFutureDates: enableFutureDates
|
|
16401
16407
|
})) : /*#__PURE__*/jsxRuntime.jsx(ClockView, _objectSpread2(_objectSpread2({}, commonCalenderProps), {}, {
|
|
16402
16408
|
setSelectedMonth: setSelectedMonth,
|
|
@@ -16551,6 +16557,7 @@ var DatePicker = function DatePicker(props) {
|
|
|
16551
16557
|
disabled = props.disabled,
|
|
16552
16558
|
className = props.className,
|
|
16553
16559
|
disableDatesBefore = props.disableDatesBefore,
|
|
16560
|
+
disableDatesAfter = props.disableDatesAfter,
|
|
16554
16561
|
_onClear = props.onClear,
|
|
16555
16562
|
customRanges = props.customRanges,
|
|
16556
16563
|
custom = props.custom,
|
|
@@ -16677,6 +16684,7 @@ var DatePicker = function DatePicker(props) {
|
|
|
16677
16684
|
},
|
|
16678
16685
|
disabledDates: disabledDates,
|
|
16679
16686
|
disableDatesBefore: disableDatesBefore,
|
|
16687
|
+
disableDatesAfter: disableDatesAfter,
|
|
16680
16688
|
value: value,
|
|
16681
16689
|
setFixedRange: setFixedRange,
|
|
16682
16690
|
customRanges: customRanges,
|
|
@@ -16816,7 +16824,8 @@ DatePicker.propTypes = {
|
|
|
16816
16824
|
type: propTypesExports.string
|
|
16817
16825
|
}),
|
|
16818
16826
|
className: propTypesExports.string,
|
|
16819
|
-
disableDatesBefore: propTypesExports.arrayOf(propTypesExports.
|
|
16827
|
+
disableDatesBefore: propTypesExports.arrayOf(propTypesExports.number),
|
|
16828
|
+
disableDatesAfter: propTypesExports.arrayOf(propTypesExports.number),
|
|
16820
16829
|
defaultRangeSelection: propTypesExports.arrayOf(propTypesExports.number),
|
|
16821
16830
|
customRanges: propTypesExports.arrayOf(propTypesExports.shape({
|
|
16822
16831
|
title: propTypesExports.string,
|
|
@@ -22373,12 +22382,16 @@ var TableCell = /*#__PURE__*/React.forwardRef(function TableCell(props, ref) {
|
|
|
22373
22382
|
sticky = props.sticky,
|
|
22374
22383
|
sort = props.sort,
|
|
22375
22384
|
onSort = props.onSort,
|
|
22385
|
+
sortValue = props.sortValue,
|
|
22376
22386
|
html = props.html,
|
|
22377
22387
|
json = props.json;
|
|
22378
|
-
var _useState = React.useState('
|
|
22388
|
+
var _useState = React.useState('default'),
|
|
22379
22389
|
_useState2 = _slicedToArray(_useState, 2),
|
|
22380
22390
|
sortState = _useState2[0],
|
|
22381
22391
|
setSortState = _useState2[1];
|
|
22392
|
+
React.useEffect(function () {
|
|
22393
|
+
setSortState((sortValue === null || sortValue === void 0 ? void 0 : sortValue[id]) || 'default');
|
|
22394
|
+
}, [sortValue]);
|
|
22382
22395
|
var spanElement = /*#__PURE__*/jsxRuntime.jsx("span", _objectSpread2(_objectSpread2({}, _objectSpread2(_objectSpread2({}, cellTitle != null ? {
|
|
22383
22396
|
title: cellTitle
|
|
22384
22397
|
} : {}), {}, {
|
|
@@ -22400,7 +22413,7 @@ var TableCell = /*#__PURE__*/React.forwardRef(function TableCell(props, ref) {
|
|
|
22400
22413
|
}
|
|
22401
22414
|
return /*#__PURE__*/jsxRuntime.jsx(BaseCell, {
|
|
22402
22415
|
ref: ref,
|
|
22403
|
-
className: classes(modules_7ba8d001.root, modules_7ba8d001["".concat(type, "-cell")], modules_7ba8d001["sticky-".concat(sticky)], modules_7ba8d001["sort-".concat(
|
|
22416
|
+
className: classes(modules_7ba8d001.root, modules_7ba8d001["".concat(type, "-cell")], modules_7ba8d001["sticky-".concat(sticky)], modules_7ba8d001["sort-".concat(sortState)], sortState != null ? modules_7ba8d001.sortable : '', className),
|
|
22404
22417
|
attrs: _objectSpread2({
|
|
22405
22418
|
style: style
|
|
22406
22419
|
}, attrs),
|
|
@@ -22476,6 +22489,7 @@ var TableRow = /*#__PURE__*/React.forwardRef(function BaseTable(props, ref) {
|
|
|
22476
22489
|
Expandable = props.expandable,
|
|
22477
22490
|
_props$onSort = props.onSort,
|
|
22478
22491
|
onSort = _props$onSort === void 0 ? function () {} : _props$onSort,
|
|
22492
|
+
sortValue = props.sortValue,
|
|
22479
22493
|
_props$rowHeight = props.rowHeight,
|
|
22480
22494
|
rowHeight = _props$rowHeight === void 0 ? 'md' : _props$rowHeight,
|
|
22481
22495
|
_toggleDrawer = props.toggleDrawer,
|
|
@@ -22524,6 +22538,7 @@ var TableRow = /*#__PURE__*/React.forwardRef(function BaseTable(props, ref) {
|
|
|
22524
22538
|
cellTitle: cellContent,
|
|
22525
22539
|
type: type,
|
|
22526
22540
|
onSort: onSort,
|
|
22541
|
+
sortValue: sortValue,
|
|
22527
22542
|
rowHeight: rowHeight,
|
|
22528
22543
|
toggleDrawer: function toggleDrawer(index, standalone) {
|
|
22529
22544
|
_toggleDrawer({
|
|
@@ -22801,6 +22816,7 @@ var TableHeader = function TableHeader(props) {
|
|
|
22801
22816
|
customCells = props.customCells,
|
|
22802
22817
|
expandable = props.expandable,
|
|
22803
22818
|
onSort = props.onSort,
|
|
22819
|
+
sortValue = props.sortValue,
|
|
22804
22820
|
rowHeight = props.rowHeight,
|
|
22805
22821
|
_props$theme = props.theme,
|
|
22806
22822
|
theme = _props$theme === void 0 ? '' : _props$theme,
|
|
@@ -22821,6 +22837,7 @@ var TableHeader = function TableHeader(props) {
|
|
|
22821
22837
|
customCells: customCells,
|
|
22822
22838
|
expandable: expandable,
|
|
22823
22839
|
onSort: onSort,
|
|
22840
|
+
sortValue: sortValue,
|
|
22824
22841
|
rowHeight: rowHeight,
|
|
22825
22842
|
onRowClick: onRowClick,
|
|
22826
22843
|
theme: theme,
|
|
@@ -23031,6 +23048,7 @@ var BaseTable = /*#__PURE__*/React.forwardRef(function BaseTable(props, ref) {
|
|
|
23031
23048
|
onRowClick = props.onRowClick,
|
|
23032
23049
|
expandable = props.expandable,
|
|
23033
23050
|
onSort = props.onSort,
|
|
23051
|
+
sortValue = props.sortValue,
|
|
23034
23052
|
rowHeight = props.rowHeight,
|
|
23035
23053
|
theme = props.theme,
|
|
23036
23054
|
placeholder = props.placeholder,
|
|
@@ -23066,6 +23084,7 @@ var BaseTable = /*#__PURE__*/React.forwardRef(function BaseTable(props, ref) {
|
|
|
23066
23084
|
customCells: customCells,
|
|
23067
23085
|
expandable: expandable,
|
|
23068
23086
|
onSort: onSort,
|
|
23087
|
+
sortValue: sortValue,
|
|
23069
23088
|
onRowClick: onRowClick,
|
|
23070
23089
|
onCheck: onCheck,
|
|
23071
23090
|
checkedRows: checkedRows,
|
|
@@ -23963,6 +23982,8 @@ var Table = function Table(props) {
|
|
|
23963
23982
|
rightActions = _props$rightActions === void 0 ? null : _props$rightActions,
|
|
23964
23983
|
_props$onSort = props.onSort,
|
|
23965
23984
|
onSort = _props$onSort === void 0 ? function () {} : _props$onSort,
|
|
23985
|
+
_props$sortValue = props.sortValue,
|
|
23986
|
+
sortValue = _props$sortValue === void 0 ? 'asc' : _props$sortValue,
|
|
23966
23987
|
_props$rowHeight = props.rowHeight,
|
|
23967
23988
|
rowHeight = _props$rowHeight === void 0 ? 'md' : _props$rowHeight,
|
|
23968
23989
|
_props$theme = props.theme,
|
|
@@ -24147,6 +24168,7 @@ var Table = function Table(props) {
|
|
|
24147
24168
|
customCells: customCells,
|
|
24148
24169
|
className: modules_2e8406c7.table,
|
|
24149
24170
|
onSort: onSort,
|
|
24171
|
+
sortValue: sortValue,
|
|
24150
24172
|
rowHeight: rowHeight,
|
|
24151
24173
|
onRowClick: onRowClick,
|
|
24152
24174
|
defaultActiveIndex: defaultActiveIndex,
|
|
@@ -24674,7 +24696,7 @@ var modules_d563b0a9 = {"root":"BaseV2Widget_module_root__05b06aba","header":"Ba
|
|
|
24674
24696
|
n(css$5,{});
|
|
24675
24697
|
|
|
24676
24698
|
var generateOptions$1 = function generateOptions(_ref) {
|
|
24677
|
-
var _optionData$id, _optionData$placehold, _optionData$value, _optionData$onChange, _optionData$selectOpt, _optionData$title, _optionData$onClick, _optionData$placehold2, _optionData$range, _optionData$onApply, _optionData$onClear, _optionData$date;
|
|
24699
|
+
var _optionData$id, _optionData$placehold, _optionData$value, _optionData$onChange, _optionData$selectOpt, _optionData$title, _optionData$onClick, _optionData$placehold2, _optionData$range, _optionData$onApply, _optionData$onClear, _optionData$date, _optionData$title2;
|
|
24678
24700
|
var optionData = _ref.optionData,
|
|
24679
24701
|
toggleDrawer = _ref.toggleDrawer;
|
|
24680
24702
|
switch ((_optionData$id = optionData === null || optionData === void 0 ? void 0 : optionData.id) !== null && _optionData$id !== void 0 ? _optionData$id : '') {
|
|
@@ -24720,7 +24742,7 @@ var generateOptions$1 = function generateOptions(_ref) {
|
|
|
24720
24742
|
});
|
|
24721
24743
|
case 'filter':
|
|
24722
24744
|
return /*#__PURE__*/jsxRuntime.jsx(Button, {
|
|
24723
|
-
title:
|
|
24745
|
+
title: (_optionData$title2 = optionData === null || optionData === void 0 ? void 0 : optionData.title) !== null && _optionData$title2 !== void 0 ? _optionData$title2 : 'Filter',
|
|
24724
24746
|
variant: "outlined",
|
|
24725
24747
|
size: "auto",
|
|
24726
24748
|
className: modules_d563b0a9['filter-button'],
|