oa-componentbook 1.0.1-stage.455 → 1.0.1-stage.457
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.
|
@@ -53,7 +53,7 @@ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key i
|
|
|
53
53
|
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
54
54
|
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); } /* eslint-disable */
|
|
55
55
|
function GenricLayOut(_ref) {
|
|
56
|
-
var _state$misc30, _sidebar$mobileMenuIt, _imageViewer$content, _imageViewer$content2, _infoData$iconConfig, _infoData$iconConfig2, _infoData$iconConfig3, _infoData$iconConfig4, _leftHeaderFirstButto, _leftHeaderFirstButto2, _infoPanel$data, _infoPanel$data2, _infoPanel$data3, _infoPanel$data4, _infoPanel$data5, _state$customDrawer3, _state$customDrawer4, _tabs$list,
|
|
56
|
+
var _state$misc30, _sidebar$mobileMenuIt, _imageViewer$content, _imageViewer$content2, _infoData$iconConfig, _infoData$iconConfig2, _infoData$iconConfig3, _infoData$iconConfig4, _leftHeaderFirstButto, _leftHeaderFirstButto2, _infoPanel$data, _infoPanel$data2, _infoPanel$data3, _infoPanel$data4, _infoPanel$data5, _state$customDrawer3, _state$customDrawer4, _tabs$list, _ref7, _tabs$extraAction$che2, _tabs$extraAction$pro, _tables$columns3, _tables$columns4, _tabs$active3, _state$tables5, _tables$selectionType, _tabs$active4, _tables$selectionType2, _tables$pagination19, _drawer$data, _tabs$active5, _drawer$data$drawer$a, _drawer$data2, _tabs$active6, _tabs$active7, _nestedDrawer$data, _nestedDrawer$data$ca, _nestedDrawer$data2, _customDrawer$data, _customDrawer$data2, _contentPanel$dataSou, _tables$tableFooter, _tables$selectedRowKe, _tables$tableFooter2, _tables$tableFooter3, _tables$tableFooter5;
|
|
57
57
|
let {
|
|
58
58
|
config,
|
|
59
59
|
getInitialData,
|
|
@@ -1223,8 +1223,9 @@ function GenricLayOut(_ref) {
|
|
|
1223
1223
|
* @returns {void}
|
|
1224
1224
|
*/
|
|
1225
1225
|
const onTabClick = async key => {
|
|
1226
|
-
var _tables$filter5, _tables$columns2, _staticFilter$data$fi2;
|
|
1227
|
-
|
|
1226
|
+
var _ref4, _tabs$extraAction$che, _tabs$extraAction, _tabs$extraAction2, _tables$filter5, _tables$columns2, _staticFilter$data$fi2;
|
|
1227
|
+
// Store the checked value to pass to handleTabClick
|
|
1228
|
+
const extraActionChecked = (_ref4 = (_tabs$extraAction$che = tabs === null || tabs === void 0 || (_tabs$extraAction = tabs.extraAction) === null || _tabs$extraAction === void 0 ? void 0 : _tabs$extraAction.checked) !== null && _tabs$extraAction$che !== void 0 ? _tabs$extraAction$che : tabs === null || tabs === void 0 || (_tabs$extraAction2 = tabs.extraAction) === null || _tabs$extraAction2 === void 0 || (_tabs$extraAction2 = _tabs$extraAction2.props) === null || _tabs$extraAction2 === void 0 ? void 0 : _tabs$extraAction2.defaultChecked) !== null && _ref4 !== void 0 ? _ref4 : false;
|
|
1228
1229
|
dispatch({
|
|
1229
1230
|
type: _layoutReducer.actionTypes.TAB_CLICK,
|
|
1230
1231
|
payload: {
|
|
@@ -1300,6 +1301,8 @@ function GenricLayOut(_ref) {
|
|
|
1300
1301
|
subHeadingSelectVal: header === null || header === void 0 || (_header$subHeading18 = header.subHeading) === null || _header$subHeading18 === void 0 || (_header$subHeading18 = _header$subHeading18.jsxConfig) === null || _header$subHeading18 === void 0 ? void 0 : _header$subHeading18.value
|
|
1301
1302
|
} : {}), (customDrawer === null || customDrawer === void 0 ? void 0 : customDrawer.appliedFilters) && Object.keys((_customDrawer$applied9 = customDrawer === null || customDrawer === void 0 ? void 0 : customDrawer.appliedFilters) !== null && _customDrawer$applied9 !== void 0 ? _customDrawer$applied9 : {}).length > 0 && _objectSpread({}, customDrawer === null || customDrawer === void 0 ? void 0 : customDrawer.appliedFilters)), (_state$misc17 = state === null || state === void 0 ? void 0 : state.misc) !== null && _state$misc17 !== void 0 ? _state$misc17 : {}), {}, {
|
|
1302
1303
|
multiSelectValue: (_state$staticFilter$m6 = state === null || state === void 0 || (_state$staticFilter6 = state.staticFilter) === null || _state$staticFilter6 === void 0 ? void 0 : _state$staticFilter6.multiSelectValue) !== null && _state$staticFilter$m6 !== void 0 ? _state$staticFilter$m6 : []
|
|
1304
|
+
}, (tabs === null || tabs === void 0 ? void 0 : tabs.extraAction) && extraActionChecked && {
|
|
1305
|
+
checked: extraActionChecked
|
|
1303
1306
|
}));
|
|
1304
1307
|
if (error) {
|
|
1305
1308
|
showErrorNotification(error);
|
|
@@ -1562,7 +1565,7 @@ function GenricLayOut(_ref) {
|
|
|
1562
1565
|
|
|
1563
1566
|
// Only process filter data if this is actually a filter drawer
|
|
1564
1567
|
if (formData.type === "FILTER-SUBMIT") {
|
|
1565
|
-
var _state$dropdownSearch7, _state$inputSearch7,
|
|
1568
|
+
var _state$dropdownSearch7, _state$inputSearch7, _ref5, _appliedFilters$filte, _state$tabs13, _config$tables29, _config$tables30, _tables$filter8, _tables$sorting19, _header$subHeading23, _header$subHeading24, _staticFilter$data9, _tables$sorting20, _state$misc21, _state$staticFilter$m9, _state$staticFilter9;
|
|
1566
1569
|
const appliedFilters = {};
|
|
1567
1570
|
Object.keys(formData).forEach(key => {
|
|
1568
1571
|
const value = formData[key];
|
|
@@ -1585,7 +1588,7 @@ function GenricLayOut(_ref) {
|
|
|
1585
1588
|
}), (state === null || state === void 0 || (_state$inputSearch7 = state.inputSearch) === null || _state$inputSearch7 === void 0 || (_state$inputSearch7 = _state$inputSearch7.value) === null || _state$inputSearch7 === void 0 ? void 0 : _state$inputSearch7.trim()) && {
|
|
1586
1589
|
searchedValue: state.inputSearch.value
|
|
1587
1590
|
}), appliedFilters), {}, {
|
|
1588
|
-
filterOn: (
|
|
1591
|
+
filterOn: (_ref5 = (_appliedFilters$filte = appliedFilters === null || appliedFilters === void 0 ? void 0 : appliedFilters.filterBy) !== null && _appliedFilters$filte !== void 0 ? _appliedFilters$filte : customDrawer === null || customDrawer === void 0 ? void 0 : customDrawer.defaultAppliedFilter) !== null && _ref5 !== void 0 ? _ref5 : "",
|
|
1589
1592
|
fromDate: appliedFilters === null || appliedFilters === void 0 ? void 0 : appliedFilters.fromDate,
|
|
1590
1593
|
toDate: appliedFilters === null || appliedFilters === void 0 ? void 0 : appliedFilters.toDate,
|
|
1591
1594
|
selectedTab: state === null || state === void 0 || (_state$tabs13 = state.tabs) === null || _state$tabs13 === void 0 ? void 0 : _state$tabs13.active,
|
|
@@ -2100,11 +2103,11 @@ function GenricLayOut(_ref) {
|
|
|
2100
2103
|
});
|
|
2101
2104
|
}
|
|
2102
2105
|
};
|
|
2103
|
-
const onMobilePageChange = async
|
|
2106
|
+
const onMobilePageChange = async _ref6 => {
|
|
2104
2107
|
let {
|
|
2105
2108
|
current,
|
|
2106
2109
|
pageSize
|
|
2107
|
-
} =
|
|
2110
|
+
} = _ref6;
|
|
2108
2111
|
resetTabsExtraActionSwitch();
|
|
2109
2112
|
dispatch({
|
|
2110
2113
|
type: _layoutReducer.actionTypes.SET_PAGINATION,
|
|
@@ -2356,7 +2359,7 @@ function GenricLayOut(_ref) {
|
|
|
2356
2359
|
onTabClick: onTabClick,
|
|
2357
2360
|
extraAction: tabs !== null && tabs !== void 0 && tabs.extraAction ? _objectSpread(_objectSpread({}, tabs.extraAction), {}, {
|
|
2358
2361
|
props: _objectSpread(_objectSpread({}, tabs.extraAction.props), {}, {
|
|
2359
|
-
checked: (
|
|
2362
|
+
checked: (_ref7 = (_tabs$extraAction$che2 = tabs.extraAction.checked) !== null && _tabs$extraAction$che2 !== void 0 ? _tabs$extraAction$che2 : (_tabs$extraAction$pro = tabs.extraAction.props) === null || _tabs$extraAction$pro === void 0 ? void 0 : _tabs$extraAction$pro.defaultChecked) !== null && _ref7 !== void 0 ? _ref7 : false,
|
|
2360
2363
|
onChange: async checked => {
|
|
2361
2364
|
var _tabs$extraAction$pro2;
|
|
2362
2365
|
// Update switch state immediately
|