oa-componentbook 1.0.1-stage.36 → 1.0.1-stage.360
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/build/components/oa-component-checkbox/CustomCheckBox.js +20 -17
- package/build/components/oa-component-checkbox/styles.js +1 -1
- package/build/components/oa-component-datepicker/CustomDatePicker.js +25 -22
- package/build/components/oa-component-drawer/CustomDrawer.js +2 -0
- package/build/components/oa-component-dropdown/CustomDropdown.js +16 -4
- package/build/components/oa-component-icons/MaterialIcon.js +1 -1
- package/build/components/oa-component-modal/styles.js +3 -2
- package/build/components/oa-component-pagination/CustomPagination.js +111 -0
- package/build/components/oa-component-pagination/styles.js +12 -0
- package/build/components/oa-component-select/CustomSelect.js +116 -56
- package/build/components/oa-component-steps/CustomSteps.js +117 -0
- package/build/components/oa-component-steps/styles.js +12 -0
- package/build/components/oa-component-table/CustomTable.js +28 -5
- package/build/components/oa-component-table/CustomTableV1.js +520 -0
- package/build/components/oa-component-table/styles.js +1 -1
- package/build/components/oa-component-table/stylesV1.js +19 -0
- package/build/components/oa-component-tabs/CustomTabs.js +1 -1
- package/build/components/oa-component-tag/CustomTag.js +17 -5
- package/build/components/oa-component-tag/styles.js +30 -3
- package/build/components/oa-component-textarea/{TextArea.js → CustomTextArea.js} +4 -4
- package/build/components/oa-component-tooltip/CustomTooltip.js +8 -4
- package/build/components/oa-component-upload/CustomUpload.js +120 -40
- package/build/components/oa-component-viewer/CustomViewer.js +3 -1
- package/build/dev/oa-component-document-viewer/CustomDocumentViewer.js +367 -0
- package/build/dev/oa-component-document-viewer/styles.js +12 -0
- package/build/dev/oa-component-upload/CustomUpload.js +3 -0
- package/build/dev/oa-widget-document-modal/DocumentSideModal.js +166 -0
- package/build/dev/oa-widget-document-modal/styles.js +12 -0
- package/build/dev/oa-widget-document-side-drawer/DocumentSideDrawer.js +196 -0
- package/build/dev/oa-widget-document-side-drawer/styles.js +12 -0
- package/build/global-css/GlobalCss.js +2 -1
- package/build/global-css/GridLayout.js +1 -1
- package/build/global-css/commonStyles.js +11 -0
- package/build/images/Car.png +0 -0
- package/build/images/TwoWheeler.png +0 -0
- package/build/images/astronaut_emptystate.png +0 -0
- package/build/images/exportGrp01.png +0 -0
- package/build/images/exportGrp02.png +0 -0
- package/build/images/exportGrp03.png +0 -0
- package/build/images/outOfStock.png +0 -0
- package/build/index.js +100 -2
- package/build/layout/DetailDataLayout/DetailDataLayout.js +20 -0
- package/build/layout/DetailDataLayout/components/Form.js +22 -0
- package/build/layout/DetailDataLayout/components/Header.js +32 -0
- package/build/layout/DetailDataLayout/style.css +9 -0
- package/build/layout/DetailDataLayout/styles.js +12 -0
- package/build/layout/GenricLayOut/GenricLayOut.js +2275 -0
- package/build/layout/GenricLayOut/components/AppliedFilters.js +84 -0
- package/build/layout/GenricLayOut/components/CardList.js +34 -0
- package/build/layout/GenricLayOut/components/DropdownSearch.js +48 -0
- package/build/layout/GenricLayOut/components/Header.js +74 -0
- package/build/layout/GenricLayOut/components/Modal.js +85 -0
- package/build/layout/GenricLayOut/components/Search.js +51 -0
- package/build/layout/GenricLayOut/components/StaticFilter.css +73 -0
- package/build/layout/GenricLayOut/components/StaticFilter.js +37 -0
- package/build/layout/GenricLayOut/reducer/layoutReducer.js +290 -0
- package/build/layout/GenricLayOut/resolver/staticConfigResolver.js +98 -0
- package/build/layout/GenricLayOut/styles.js +22 -0
- package/build/utils/download-file.js +23 -0
- package/build/widgets/oa-form-widget/FormWidget.js +519 -0
- package/build/widgets/oa-form-widget/FormWidgetStyle.js +18 -0
- package/build/widgets/oa-widget-add-spare-part/AddSparePartCollapseWidget.js +73 -12
- package/build/widgets/oa-widget-add-spare-part/AddSparePartWidget.js +51 -7
- package/build/widgets/oa-widget-address/AddressWidget.js +12 -17
- package/build/widgets/oa-widget-approval/ApprovalWidgetNew.js +481 -0
- package/build/widgets/oa-widget-approval/styles.js +2 -2
- package/build/widgets/oa-widget-chat/ChatWidget.js +5 -5
- package/build/widgets/oa-widget-close-claim/CloseClaimWidget.js +17 -5
- package/build/widgets/oa-widget-collapsible-key-value/CollapsibleKeyValueWidget.js +399 -0
- package/build/widgets/oa-widget-collapsible-key-value/styles.js +16 -0
- package/build/widgets/oa-widget-content-panel/ContentPanel.js +82 -0
- package/build/widgets/oa-widget-content-panel/styles.js +12 -0
- package/build/widgets/oa-widget-customer-rating-card/CustomerRatingCard.js +5 -5
- package/build/widgets/oa-widget-detailcard/styles.js +1 -1
- package/build/widgets/oa-widget-document-upload/DocUploadWidget.js +6 -9
- package/build/widgets/oa-widget-dropdown-search-input/DropdownSearchInput.js +56 -19
- package/build/widgets/oa-widget-dropdown-search-input/styles.js +1 -1
- package/build/widgets/oa-widget-guide/GuideWidget.js +70 -0
- package/build/widgets/oa-widget-guide/GuideWidgetStyle.js +12 -0
- package/build/widgets/oa-widget-hub-automation-modal/HubAutomationDeleteBiker.js +24 -0
- package/build/widgets/oa-widget-hub-automation-modal/HubAutomationModal.js +34 -0
- package/build/widgets/oa-widget-hub-automation-modal/HubAutomationModalStyle.js +13 -0
- package/build/widgets/oa-widget-image-carousel/ImageCarouselWidget.js +257 -0
- package/build/widgets/oa-widget-image-carousel/styles.js +23 -0
- package/build/widgets/oa-widget-image-gallery/FullscreenViewer.js +169 -0
- package/build/widgets/oa-widget-image-gallery/ImageGallery.js +87 -0
- package/build/widgets/oa-widget-image-gallery/ThumbnailGrid.js +146 -0
- package/build/widgets/oa-widget-image-gallery/imageCache.js +15 -0
- package/build/widgets/oa-widget-image-gallery/imageGalleryStyle.js +16 -0
- package/build/widgets/oa-widget-item-info-card/InfoCardListWidget.js +60 -0
- package/build/widgets/oa-widget-item-info-card/ItemInfoCardWidget.js +77 -0
- package/build/widgets/oa-widget-item-info-card/styles.css +50 -0
- package/build/widgets/oa-widget-item-info-card/styles.js +14 -0
- package/build/widgets/oa-widget-key-value/KeyValueWidget.js +37 -10
- package/build/widgets/oa-widget-kpi/KPICardWidget.js +86 -0
- package/build/widgets/oa-widget-kpi/styles.js +12 -0
- package/build/widgets/oa-widget-map-base-location/AddressDetails.js +21 -7
- package/build/widgets/oa-widget-map-base-location/AddressForm.js +32 -5
- package/build/widgets/oa-widget-map-base-location/MapBaseLocation.js +9 -3
- package/build/widgets/oa-widget-map-base-location/MapComponent.js +17 -2
- package/build/widgets/oa-widget-membershipcard/MembershipCard.js +14 -3
- package/build/widgets/oa-widget-membershipcard/styles.js +1 -1
- package/build/widgets/oa-widget-notes/NotesWidget.js +2 -1
- package/build/widgets/oa-widget-progressive-steps/ProgressiveStepsWidget.js +392 -0
- package/build/widgets/oa-widget-progressive-steps/styles.js +12 -0
- package/build/widgets/oa-widget-reimbursement-breakup/ReimbursementBreakupWidget.js +18 -9
- package/build/widgets/oa-widget-reimbursement-breakup/styles.js +1 -1
- package/build/widgets/oa-widget-reupload-drawer/ReUploadDrawer.js +164 -0
- package/build/widgets/oa-widget-sidebar/SidebarWidget.js +87 -0
- package/build/widgets/oa-widget-sidebar/components/Header.js +30 -0
- package/build/widgets/oa-widget-sidebar/sidebar.css +0 -0
- package/build/widgets/oa-widget-sidebar/styles.js +12 -0
- package/build/widgets/oa-widget-spare-part/SparePartsWidget.js +57 -29
- package/build/widgets/oa-widget-track-shipment-list/fn.js +16 -4
- package/package.json +4 -2
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.initialState = exports.genericLayoutReducer = exports.actionTypes = void 0;
|
|
7
|
+
require("core-js/modules/web.dom-collections.iterator.js");
|
|
8
|
+
require("core-js/modules/es.symbol.description.js");
|
|
9
|
+
var _immer = require("immer");
|
|
10
|
+
var _staticConfigResolver = require("../resolver/staticConfigResolver");
|
|
11
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
12
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
13
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
14
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
15
|
+
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 */
|
|
16
|
+
const initialState = exports.initialState = {};
|
|
17
|
+
const actionTypes = exports.actionTypes = {
|
|
18
|
+
INIT: "INIT",
|
|
19
|
+
SET_LOADING: "SET_LOADING",
|
|
20
|
+
SET_DROPDOWN_SEARCH_VALUE: "SET_DROPDOWN_SEARCH_VALUE",
|
|
21
|
+
SET_DROPDOWN_SEARCH_ERROR: "SET_DROPDOWN_SEARCH_ERROR",
|
|
22
|
+
SET_INPUT_SEARCH_VALUE: "SET_INPUT_SEARCH_VALUE",
|
|
23
|
+
SET_INPUT_SEARCH_ERROR: "SET_INPUT_SEARCH_ERROR",
|
|
24
|
+
SET_DROPDOWN_SEARCH_OPTION: "SET_DROPDOWN_SEARCH_OPTION",
|
|
25
|
+
SET_DRAWER: "SET_DRAWER",
|
|
26
|
+
SET_NESTED_DRAWER: "SET_NESTED_DRAWER",
|
|
27
|
+
TOGGLE_IMAGE_VIEW: "TOGGLE_IMAGE_VIEW",
|
|
28
|
+
SET_TABLE_DATA: "SET_TABLE_DATA",
|
|
29
|
+
SET_TABLE_EMPTY: "SET_TABLE_EMPTY",
|
|
30
|
+
SET_PAGINATION: "SET_PAGINATION",
|
|
31
|
+
SET_SORTING: "SET_SORTING",
|
|
32
|
+
TAB_CLICK: "TAB_CLICK",
|
|
33
|
+
TOGGLE_DRAWER: "TOGGLE_DRAWER",
|
|
34
|
+
CLOSE_DRAWER: "CLOSE_DRAWER",
|
|
35
|
+
NESTED_DRAWER_OPEN: "NESTED_DRAWER_OPEN",
|
|
36
|
+
NESTED_DRAWER_CLOSED: "NESTED_DRAWER_CLOSED",
|
|
37
|
+
TABLE_FOOTER_TOGGLE: "TABLE_FOOTER_TOGGLE",
|
|
38
|
+
// Use to show hide the footer of the table
|
|
39
|
+
TABLE_ROW_SELECTED_DATA: "TABLE_ROW_SELECTED_DATA",
|
|
40
|
+
// Use to store the selected rows of the table
|
|
41
|
+
TOGGLE_MODAL: "TOGGLE_MODAL",
|
|
42
|
+
// Use to show hide the modal
|
|
43
|
+
SET_MODAL: "SET_MODAL",
|
|
44
|
+
SET_TABLE_FILTER: "SET_TABLE_FILTER",
|
|
45
|
+
SET_CUSTOM_DRAWER_DATA_SELECT: "SET_CUSTOM_DRAWER_DATA_SELECT",
|
|
46
|
+
SET_SUBHEADING_SELECTED_CONFIG: "SET_SUBHEADING_SELECTED_CONFIG",
|
|
47
|
+
SET_CUSTOM_DRAWER: "SET_CUSTOM_DRAWER",
|
|
48
|
+
CUSTOM_DRAWER_OPEN: "CUSTOM_DRAWER_OPEN",
|
|
49
|
+
CUSTOM_DRAWER_CLOSED: "CUSTOM_DRAWER_CLOSED",
|
|
50
|
+
UPDATE_FILTER_DEFAULT_VALUES: "UPDATE_FILTER_DEFAULT_VALUES",
|
|
51
|
+
SET_STATIC_FILTER_SELECTION: "SET_STATIC_FILTER_SELECTION",
|
|
52
|
+
SET_STATIC_FILTER_VISIBILITY: "SET_STATIC_FILTER_VISIBILITY",
|
|
53
|
+
SET_TABLE_COLUMNS_RESET: "SET_TABLE_COLUMNS_RESET",
|
|
54
|
+
SET_APPLIED_FILTERS: "SET_APPLIED_FILTERS",
|
|
55
|
+
REMOVE_APPLIED_FILTER: "REMOVE_APPLIED_FILTER",
|
|
56
|
+
CLEAR_ALL_APPLIED_FILTERS: "CLEAR_ALL_APPLIED_FILTERS",
|
|
57
|
+
UPDATE_FILTER_FORM_VALUES: "UPDATE_FILTER_FORM_VALUES",
|
|
58
|
+
SET_STATIC_FILTER: "SET_STATIC_FILTER"
|
|
59
|
+
};
|
|
60
|
+
function getFieldDefaultValue(widget) {
|
|
61
|
+
switch (widget) {
|
|
62
|
+
case "select":
|
|
63
|
+
case "radio":
|
|
64
|
+
return undefined;
|
|
65
|
+
case "date":
|
|
66
|
+
return "";
|
|
67
|
+
case "input":
|
|
68
|
+
case "textArea":
|
|
69
|
+
return "";
|
|
70
|
+
default:
|
|
71
|
+
return "";
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
const genericLayoutReducer = exports.genericLayoutReducer = (0, _immer.produce)((draft, action) => {
|
|
75
|
+
var _draft$imageViewer, _action$payload, _action$payload2, _draft$tabs, _draft$customDrawer$d, _draft$tables, _action$payload3, _action$payload4, _action$payload5, _draft$tabs$active, _draft$tabs2, _action$payload6, _action$payload7, _action$payload8, _draft$staticFilter, _draft$tables2, _draft$customDrawer$d2, _draft$customDrawer$d3, _draft$customDrawer$d4;
|
|
76
|
+
switch (action.type) {
|
|
77
|
+
case actionTypes.INIT:
|
|
78
|
+
return (0, _staticConfigResolver.removeHidden)(action.payload);
|
|
79
|
+
case actionTypes.SET_LOADING:
|
|
80
|
+
draft.isLoading = action.payload;
|
|
81
|
+
break;
|
|
82
|
+
case actionTypes.SET_DROPDOWN_SEARCH_VALUE:
|
|
83
|
+
draft.dropdownSearch.value = action.payload;
|
|
84
|
+
draft.dropdownSearch.error = null;
|
|
85
|
+
break;
|
|
86
|
+
case actionTypes.SET_DROPDOWN_SEARCH_ERROR:
|
|
87
|
+
draft.dropdownSearch.error = action.payload;
|
|
88
|
+
break;
|
|
89
|
+
case actionTypes.TOGGLE_IMAGE_VIEW:
|
|
90
|
+
draft.imageViewer.visible = !((_draft$imageViewer = draft.imageViewer) !== null && _draft$imageViewer !== void 0 && _draft$imageViewer.visible);
|
|
91
|
+
draft.imageViewer.content = action === null || action === void 0 ? void 0 : action.payload;
|
|
92
|
+
break;
|
|
93
|
+
case actionTypes.SET_INPUT_SEARCH_VALUE:
|
|
94
|
+
draft.inputSearch.value = action.payload;
|
|
95
|
+
draft.inputSearch.error = null;
|
|
96
|
+
break;
|
|
97
|
+
case actionTypes.SET_INPUT_SEARCH_ERROR:
|
|
98
|
+
draft.inputSearch.error = action.payload;
|
|
99
|
+
break;
|
|
100
|
+
case actionTypes.SET_TABLE_EMPTY:
|
|
101
|
+
draft.tables.data = [];
|
|
102
|
+
case actionTypes.SET_DROPDOWN_SEARCH_OPTION:
|
|
103
|
+
draft.dropdownSearch.selectedOption = action === null || action === void 0 ? void 0 : action.payload;
|
|
104
|
+
draft.dropdownSearch.value = null;
|
|
105
|
+
draft.dropdownSearch.error = null;
|
|
106
|
+
break;
|
|
107
|
+
case actionTypes.SET_TABLE_DATA:
|
|
108
|
+
draft.tables.data = (_action$payload = action.payload) === null || _action$payload === void 0 ? void 0 : _action$payload.dataSource;
|
|
109
|
+
draft.tables.pagination = _objectSpread(_objectSpread({}, draft.tables.pagination), {}, {
|
|
110
|
+
total: (_action$payload2 = action.payload) === null || _action$payload2 === void 0 ? void 0 : _action$payload2.totalRecords
|
|
111
|
+
});
|
|
112
|
+
(_draft$tabs = draft.tabs) === null || _draft$tabs === void 0 || (_draft$tabs = _draft$tabs.list) === null || _draft$tabs === void 0 || _draft$tabs.map(l => {
|
|
113
|
+
l.value = action.payload[l === null || l === void 0 ? void 0 : l.tabKey];
|
|
114
|
+
return l;
|
|
115
|
+
});
|
|
116
|
+
break;
|
|
117
|
+
case actionTypes.SET_PAGINATION:
|
|
118
|
+
draft.tables.pagination = _objectSpread(_objectSpread({}, draft.tables.pagination), action.payload);
|
|
119
|
+
break;
|
|
120
|
+
case actionTypes.SET_TABLE_FILTER:
|
|
121
|
+
draft.tables.filter = _objectSpread(_objectSpread({}, draft.tables.filter), action.payload);
|
|
122
|
+
break;
|
|
123
|
+
case actionTypes.UPDATE_FILTER_DEFAULT_VALUES:
|
|
124
|
+
if ((_draft$customDrawer$d = draft.customDrawer.data) !== null && _draft$customDrawer$d !== void 0 && (_draft$customDrawer$d = _draft$customDrawer$d.groups) !== null && _draft$customDrawer$d !== void 0 && (_draft$customDrawer$d = _draft$customDrawer$d[0]) !== null && _draft$customDrawer$d !== void 0 && _draft$customDrawer$d.items) {
|
|
125
|
+
draft.customDrawer.data.groups[0].items.forEach(item => {
|
|
126
|
+
if (action.payload[item.name] !== undefined) {
|
|
127
|
+
item.defaultValue = action.payload[item.name];
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
}
|
|
131
|
+
break;
|
|
132
|
+
case actionTypes.SET_SORTING:
|
|
133
|
+
draft.tables.sorting = _objectSpread(_objectSpread({}, (_draft$tables = draft.tables) === null || _draft$tables === void 0 ? void 0 : _draft$tables.sorting), action.payload);
|
|
134
|
+
break;
|
|
135
|
+
case actionTypes.TAB_CLICK:
|
|
136
|
+
draft.tabs.active = (_action$payload3 = action.payload) === null || _action$payload3 === void 0 ? void 0 : _action$payload3.active;
|
|
137
|
+
const shouldShowStaticFilter = ((_action$payload4 = action.payload) === null || _action$payload4 === void 0 ? void 0 : _action$payload4.active) === "HR-CANCELLED" || ((_action$payload5 = action.payload) === null || _action$payload5 === void 0 ? void 0 : _action$payload5.active) === "FINANCIER-CANCELLED";
|
|
138
|
+
if (draft.staticFilter) {
|
|
139
|
+
draft.staticFilter.visible = shouldShowStaticFilter;
|
|
140
|
+
}
|
|
141
|
+
break;
|
|
142
|
+
case actionTypes.SET_DRAWER:
|
|
143
|
+
draft.drawer.data[(_draft$tabs$active = draft === null || draft === void 0 || (_draft$tabs2 = draft.tabs) === null || _draft$tabs2 === void 0 ? void 0 : _draft$tabs2.active) !== null && _draft$tabs$active !== void 0 ? _draft$tabs$active : "default"][(_action$payload6 = action.payload) === null || _action$payload6 === void 0 ? void 0 : _action$payload6.active] = action.payload.dynamicConfig;
|
|
144
|
+
break;
|
|
145
|
+
case actionTypes.SET_MODAL:
|
|
146
|
+
draft.modal.modalContent = (_action$payload7 = action.payload) === null || _action$payload7 === void 0 || (_action$payload7 = _action$payload7.modalData) === null || _action$payload7 === void 0 ? void 0 : _action$payload7.modalContent;
|
|
147
|
+
draft.modal.value = (_action$payload8 = action.payload) === null || _action$payload8 === void 0 || (_action$payload8 = _action$payload8.modalData) === null || _action$payload8 === void 0 ? void 0 : _action$payload8.value;
|
|
148
|
+
break;
|
|
149
|
+
case actionTypes.SET_NESTED_DRAWER:
|
|
150
|
+
draft.nestedDrawer.data.cancelOrder = action.payload;
|
|
151
|
+
break;
|
|
152
|
+
case actionTypes.TOGGLE_DRAWER:
|
|
153
|
+
draft.drawer.visible = true;
|
|
154
|
+
draft.drawer.active = action.payload;
|
|
155
|
+
break;
|
|
156
|
+
case actionTypes.NESTED_DRAWER_OPEN:
|
|
157
|
+
draft.nestedDrawer.visible = true;
|
|
158
|
+
break;
|
|
159
|
+
case actionTypes.NESTED_DRAWER_CLOSED:
|
|
160
|
+
draft.nestedDrawer.visible = false;
|
|
161
|
+
break;
|
|
162
|
+
case actionTypes.SET_CUSTOM_DRAWER:
|
|
163
|
+
draft.customDrawer.data = action.payload;
|
|
164
|
+
break;
|
|
165
|
+
case actionTypes.CUSTOM_DRAWER_OPEN:
|
|
166
|
+
draft.customDrawer.visible = true;
|
|
167
|
+
break;
|
|
168
|
+
case actionTypes.CUSTOM_DRAWER_CLOSED:
|
|
169
|
+
draft.customDrawer.visible = false;
|
|
170
|
+
break;
|
|
171
|
+
case actionTypes.CLOSE_DRAWER:
|
|
172
|
+
draft.drawer.visible = false;
|
|
173
|
+
break;
|
|
174
|
+
case actionTypes.TABLE_FOOTER_TOGGLE:
|
|
175
|
+
draft.tables.tableFooter.visible = action.payload;
|
|
176
|
+
break;
|
|
177
|
+
case actionTypes.TABLE_ROW_SELECTED_DATA:
|
|
178
|
+
draft.tables.selectedRowKeys = action.payload;
|
|
179
|
+
break;
|
|
180
|
+
case actionTypes.TOGGLE_MODAL:
|
|
181
|
+
draft.modal.visible = action.payload;
|
|
182
|
+
break;
|
|
183
|
+
case actionTypes.SET_CUSTOM_DRAWER_DATA_SELECT:
|
|
184
|
+
{
|
|
185
|
+
var _draft$tabs$active2, _draft$tabs3, _draft$drawer;
|
|
186
|
+
const tabKey = (_draft$tabs$active2 = draft === null || draft === void 0 || (_draft$tabs3 = draft.tabs) === null || _draft$tabs3 === void 0 ? void 0 : _draft$tabs3.active) !== null && _draft$tabs$active2 !== void 0 ? _draft$tabs$active2 : "default";
|
|
187
|
+
const record = draft === null || draft === void 0 || (_draft$drawer = draft.drawer) === null || _draft$drawer === void 0 || (_draft$drawer = _draft$drawer.data) === null || _draft$drawer === void 0 || (_draft$drawer = _draft$drawer[tabKey]) === null || _draft$drawer === void 0 ? void 0 : _draft$drawer[action.payload.key];
|
|
188
|
+
if (!(record !== null && record !== void 0 && record.groups)) break;
|
|
189
|
+
|
|
190
|
+
// Loop through all groups
|
|
191
|
+
for (const group of record.groups) {
|
|
192
|
+
// Look for a `keyValue` type item containing `Billing Address`
|
|
193
|
+
const targetItem = (group.items || []).find(item => (item === null || item === void 0 ? void 0 : item.type) === "keyValue" && (item === null || item === void 0 ? void 0 : item.value) && Object.prototype.hasOwnProperty.call(item.value, "Billing Address"));
|
|
194
|
+
|
|
195
|
+
// If found, update the value
|
|
196
|
+
if (targetItem) {
|
|
197
|
+
targetItem.value["Billing Address"] = action.payload.value;
|
|
198
|
+
break; // Stop after updating
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
break;
|
|
202
|
+
}
|
|
203
|
+
case actionTypes.SET_SUBHEADING_SELECTED_CONFIG:
|
|
204
|
+
draft.header.subHeading.jsxConfig.value = action.payload;
|
|
205
|
+
draft.dropdownSearch.error = null;
|
|
206
|
+
break;
|
|
207
|
+
case actionTypes.SET_STATIC_FILTER_SELECTION:
|
|
208
|
+
if ((_draft$staticFilter = draft.staticFilter) !== null && _draft$staticFilter !== void 0 && _draft$staticFilter.data) {
|
|
209
|
+
draft.staticFilter.data = draft.staticFilter.data.map(filter => _objectSpread(_objectSpread({}, filter), {}, {
|
|
210
|
+
selected: filter.value === action.payload
|
|
211
|
+
}));
|
|
212
|
+
}
|
|
213
|
+
break;
|
|
214
|
+
case actionTypes.SET_STATIC_FILTER:
|
|
215
|
+
draft.staticFilter.data = action.payload;
|
|
216
|
+
break;
|
|
217
|
+
case actionTypes.SET_STATIC_FILTER_VISIBILITY:
|
|
218
|
+
if (draft.staticFilter) {
|
|
219
|
+
draft.staticFilter.visible = action.payload;
|
|
220
|
+
}
|
|
221
|
+
break;
|
|
222
|
+
case actionTypes.SET_TABLE_COLUMNS_RESET:
|
|
223
|
+
if ((_draft$tables2 = draft.tables) !== null && _draft$tables2 !== void 0 && (_draft$tables2 = _draft$tables2.columns) !== null && _draft$tables2 !== void 0 && _draft$tables2[action.payload.tabKey]) {
|
|
224
|
+
draft.tables.columns[action.payload.tabKey] = action.payload.columns;
|
|
225
|
+
}
|
|
226
|
+
break;
|
|
227
|
+
case actionTypes.SET_APPLIED_FILTERS:
|
|
228
|
+
draft.customDrawer.appliedFilters = action.payload;
|
|
229
|
+
break;
|
|
230
|
+
case actionTypes.REMOVE_APPLIED_FILTER:
|
|
231
|
+
const {
|
|
232
|
+
filterKey
|
|
233
|
+
} = action.payload;
|
|
234
|
+
if (draft.customDrawer.appliedFilters[filterKey]) {
|
|
235
|
+
delete draft.customDrawer.appliedFilters[filterKey];
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
// Reset the corresponding form field in custom drawer
|
|
239
|
+
if ((_draft$customDrawer$d2 = draft.customDrawer.data) !== null && _draft$customDrawer$d2 !== void 0 && _draft$customDrawer$d2.groups) {
|
|
240
|
+
draft.customDrawer.data.groups.forEach(group => {
|
|
241
|
+
group.items.forEach(item => {
|
|
242
|
+
if (item.name === filterKey) {
|
|
243
|
+
// Reset to original default value based on widget type
|
|
244
|
+
item.defaultValue = getFieldDefaultValue(item.widget);
|
|
245
|
+
}
|
|
246
|
+
});
|
|
247
|
+
});
|
|
248
|
+
}
|
|
249
|
+
break;
|
|
250
|
+
case actionTypes.CLEAR_ALL_APPLIED_FILTERS:
|
|
251
|
+
draft.customDrawer.appliedFilters = {};
|
|
252
|
+
|
|
253
|
+
// Reset all form fields to original default values
|
|
254
|
+
if ((_draft$customDrawer$d3 = draft.customDrawer.data) !== null && _draft$customDrawer$d3 !== void 0 && _draft$customDrawer$d3.groups) {
|
|
255
|
+
draft.customDrawer.data.groups.forEach(group => {
|
|
256
|
+
group.items.forEach(item => {
|
|
257
|
+
if (item.name === "filterBy") {
|
|
258
|
+
item.defaultValue = draft.customDrawer.defaultAppliedFilter; // Reset to default
|
|
259
|
+
} else if (item.name === "fromDate" || item.name === "toDate") {
|
|
260
|
+
item.defaultValue = ""; // Reset dates to empty
|
|
261
|
+
}
|
|
262
|
+
});
|
|
263
|
+
});
|
|
264
|
+
}
|
|
265
|
+
break;
|
|
266
|
+
case actionTypes.UPDATE_FILTER_FORM_VALUES:
|
|
267
|
+
if ((_draft$customDrawer$d4 = draft.customDrawer.data) !== null && _draft$customDrawer$d4 !== void 0 && _draft$customDrawer$d4.groups) {
|
|
268
|
+
const {
|
|
269
|
+
formValues
|
|
270
|
+
} = action.payload;
|
|
271
|
+
draft.customDrawer.data.groups.forEach(group => {
|
|
272
|
+
group.items.forEach(item => {
|
|
273
|
+
if (item.name && formValues.hasOwnProperty(item.name)) {
|
|
274
|
+
item.defaultValue = formValues[item.name];
|
|
275
|
+
} else if (item.name && !formValues.hasOwnProperty(item.name)) {
|
|
276
|
+
// Reset to original default if not in applied filters
|
|
277
|
+
if (item.name === "filterBy") {
|
|
278
|
+
item.defaultValue = draft.customDrawer.defaultAppliedFilter;
|
|
279
|
+
} else {
|
|
280
|
+
item.defaultValue = "";
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
});
|
|
284
|
+
});
|
|
285
|
+
}
|
|
286
|
+
break;
|
|
287
|
+
default:
|
|
288
|
+
break;
|
|
289
|
+
}
|
|
290
|
+
});
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
exports.removeHidden = removeHidden;
|
|
8
|
+
require("core-js/modules/es.string.trim.js");
|
|
9
|
+
require("core-js/modules/web.dom-collections.iterator.js");
|
|
10
|
+
require("core-js/modules/es.regexp.exec.js");
|
|
11
|
+
require("core-js/modules/es.string.match.js");
|
|
12
|
+
require("core-js/modules/es.string.replace.js");
|
|
13
|
+
require("core-js/modules/es.array.includes.js");
|
|
14
|
+
require("core-js/modules/es.string.includes.js");
|
|
15
|
+
/* eslint-disable */
|
|
16
|
+
function replaceVariables(config) {
|
|
17
|
+
for (var _len = arguments.length, dataSources = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
18
|
+
dataSources[_key - 1] = arguments[_key];
|
|
19
|
+
}
|
|
20
|
+
// Resolve value from multiple data sources using dot notation
|
|
21
|
+
const getValueFromSources = key => {
|
|
22
|
+
const path = key.trim().split(".");
|
|
23
|
+
for (const dataSource of dataSources) {
|
|
24
|
+
let current = dataSource;
|
|
25
|
+
for (const segment of path) {
|
|
26
|
+
if (current && typeof current === "object" && segment in current) {
|
|
27
|
+
current = current[segment];
|
|
28
|
+
} else {
|
|
29
|
+
current = undefined;
|
|
30
|
+
break;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
if (current !== undefined) {
|
|
34
|
+
return current;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
return undefined; // ← Don't default to ""
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
// Replace placeholders in a string
|
|
41
|
+
const replacePlaceholders = value => {
|
|
42
|
+
const fullMatch = value.match(/^{{\s*([^}]+)\s*}}$/);
|
|
43
|
+
if (fullMatch) {
|
|
44
|
+
const replacement = getValueFromSources(fullMatch[1]);
|
|
45
|
+
return replacement !== undefined ? replacement : ""; // ← Keep original if not found
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
// Inline replacements: convert only primitive values
|
|
49
|
+
return value.replace(/{{\s*([^}]+)\s*}}/g, (_, key) => {
|
|
50
|
+
const replacement = getValueFromSources(key);
|
|
51
|
+
if (replacement === undefined || typeof replacement === "object" || typeof replacement === "function") {
|
|
52
|
+
return ""; // ← Keep the placeholder intact
|
|
53
|
+
}
|
|
54
|
+
return String(replacement);
|
|
55
|
+
});
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
// Recursively process entire config object
|
|
59
|
+
const processValue = value => {
|
|
60
|
+
if (Array.isArray(value)) {
|
|
61
|
+
return value.map(processValue);
|
|
62
|
+
}
|
|
63
|
+
if (typeof value === "object" && value !== null) {
|
|
64
|
+
const newObj = {};
|
|
65
|
+
for (const key in value) {
|
|
66
|
+
if (Object.hasOwn(value, key)) {
|
|
67
|
+
newObj[key] = processValue(value[key]);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return newObj;
|
|
71
|
+
}
|
|
72
|
+
if (typeof value === "string" && value.includes("{{")) {
|
|
73
|
+
return replacePlaceholders(value);
|
|
74
|
+
}
|
|
75
|
+
return value;
|
|
76
|
+
};
|
|
77
|
+
return processValue(config);
|
|
78
|
+
}
|
|
79
|
+
function removeHidden(obj) {
|
|
80
|
+
if (typeof obj !== "object" || obj === null) return obj;
|
|
81
|
+
|
|
82
|
+
// If the object has isShow: false, remove it entirely
|
|
83
|
+
if (obj.isShow === false) return undefined;
|
|
84
|
+
|
|
85
|
+
// Create a new object to hold filtered keys
|
|
86
|
+
const result = Array.isArray(obj) ? [] : {};
|
|
87
|
+
for (const key in obj) {
|
|
88
|
+
const value = obj[key];
|
|
89
|
+
const cleanedValue = removeHidden(value);
|
|
90
|
+
|
|
91
|
+
// Only add if cleanedValue is not undefined
|
|
92
|
+
if (cleanedValue !== undefined) {
|
|
93
|
+
result[key] = cleanedValue;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
return result;
|
|
97
|
+
}
|
|
98
|
+
var _default = exports.default = replaceVariables;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
require("core-js/modules/es.weak-map.js");
|
|
4
|
+
require("core-js/modules/web.dom-collections.iterator.js");
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.default = exports.TableDataStyle = exports.OapageWithDataStyle = exports.ListofDamageParts = exports.IncidentListParts = exports.FormWidgetStyle = exports.DrawerWithOutFooter = void 0;
|
|
9
|
+
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
10
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
|
|
11
|
+
/* eslint-disable */
|
|
12
|
+
// styles.js
|
|
13
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
14
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
15
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
16
|
+
const DrawerWithOutFooter = exports.DrawerWithOutFooter = (0, _styledComponents.createGlobalStyle)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n.hubAutomationContainer .fullPageLayout {padding: 0 !important; background: #fff !important;}\n.hubAutomationContainer .fullPageLayout .oaRightLayouts{\n max-width: 1154px;\n margin: 24px auto;\n padding: 0 16px;\n box-shadow: none;}\n.oaDrawer div + div.ant-drawer-body{padding-bottom:100px !important;}\n\n.ant-checkbox-indeterminate .ant-checkbox-inner:after {\n background-color: #014fc5;\n}\n\n.ant-form-item .ant-form-item-label >label.ant-form-item-required::before {display:none;}\n.ant-form-item .ant-form-item-label >label.ant-form-item-required::after{ content: \"*\"; color: #DE350B; visibility: visible !important;}\n\n\n.cstUplaodWithFullWidth{margin-bottom:24px;}\n.cstUplaodWithFullWidth:last-child{margin-bottom:0;}\n.cstUplaodWithFullWidth .uploadDiv{width:100%;}\n.cstUplaodWithFullWidth .uploadDiv .ant-upload-list-item-container, .cstUplaodWithFullWidth .uploadDiv .ant-upload-wrapper .ant-upload-list-picture-card .ant-upload-select, .cstUplaodWithFullWidth .uploadDiv .ant-upload-wrapper.ant-upload-picture-card-wrapper .ant-upload-list.ant-upload-list-picture-card .ant-upload-list-item-container {\n width: 100%; \n height: 120px;\n}\n\n\n\n\n.oaDrawer .ant-form-item .ant-form-item-explain-error {\n color: #DE350B;\n font-size: 12px;\n margin: 4px 0 0 0;\n}\n.bottomSelectedSecion{background: #F6F6F6; padding: 16px 36px; position: fixed; bottom: 0; left: 0; right: 0;\nbox-shadow: 0px 2px 10px 0px rgba(0, 0, 0, 0.14);\n display: flex; z-index: 2;\n align-items: center;\n justify-content: end;\n gap: 24px;}\n\n\n\n.listOfItems{ border-radius: 12px;\n border: 1px solid #E0E0E0;\n padding: 24px;\n margin: 24px 0 0 0;}\n modalSubheading{\n padding: 24px;\n margin: 24px 0 0 0;}\n\n.listOfItemsWithoutBorder{\n padding: 24px 0;\n margin: 24px 0 0 0;}\n\n modalSubheading{\n padding: 24px;\n margin: 24px 0 0 0;}\n\n\n\n\n.modalIconAndTextBox{display:flex; flex-direction:row; align-items: center; margin: 0 0 16px 0; gap:4px;}\n"])));
|
|
17
|
+
const FormWidgetStyle = exports.FormWidgetStyle = _styledComponents.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n .formBottomAction {\n position: absolute;\n bottom: 0px;\n background-color: rgb(249, 249, 249);\n box-shadow: rgba(0, 0, 0, 0.1) 0px -2px 8px;\n padding: 16px;\n display: flex;\n justify-content: flex-end;\n gap: 12px;\n z-index: 10;\n left: 0;\n right: 0;\n }\n\n .formBottomAction .ant-form-item {\n margin-bottom: 0px;\n }\n\n .searchErrorMsg {\n font-size: 12px;\n }\n .searchErrorMsg {\n font-size: 12px;\n }\n"])));
|
|
18
|
+
const TableDataStyle = exports.TableDataStyle = _styledComponents.default.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n .tableContainerList th,\n button {\n white-space: nowrap;\n }\n .tableContainerList th,\n button {\n white-space: nowrap;\n }\n"])));
|
|
19
|
+
const OapageWithDataStyle = exports.OapageWithDataStyle = _styledComponents.default.aside(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n .oaTopHeaderAndBtnSec {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n }\n\n .fullPageLayout {\n display: flex;\n padding: 8px;\n background: #f6f6f6;\n }\n .ant-pagination {\n padding: 0 16px;\n justify-content: end;\n }\n .layoutHeadingPage {\n display: flex;\n gap: 8px;\n margin: 0 0 32px 0;\n flex-direction: column;\n justify-content: flex-start;\n }\n\n .topHadingWithIcon span {\n display: flex;\n align-items: center;\n justify-content: flex-start;\n gap: 8px;\n }\n\n .subHadingText {\n margin: 0 0 0 36px;\n }\n\n .marginNone {\n margin: 0 !important;\n }\n\n .subHadingText > span {\n display: flex;\n flex-direction: row;\n gap: 4px;\n align-items: center;\n }\n\n .oaRightLayouts {\n width: 100%;\n min-height: calc(100vh - 16px);\n padding: 76px 48px;\n overflow-y: auto;\n border-radius: 16px;\n background: #fff;\n box-shadow: 0px 2px 10px 0px rgba(0, 0, 0, 0.14);\n }\n\n .oaheaderSearchAndFilter {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin: 0 0 16px 0;\n gap: 16px;\n }\n\n .oaRightLayouts .iconAndTextSecBox {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 8px;\n }\n .inLine {\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: 4px;\n }\n\n .customeSelectDropdown {\n margin: 4px 0 0 8px;\n }\n\n .cardData {\n padding: 28px 0 48px 0;\n }\n\n .ant-carousel .slick-dots {\n position: static;\n margin: 20px auto 12px 0;\n }\n .ant-carousel .slick-dots li {\n width: 8px;\n height: 8px;\n }\n .ant-carousel .slick-dots li button {\n width: 8px;\n height: 8px;\n background: #cacaca;\n border-radius: 50%;\n opacity: 0.5;\n }\n .ant-carousel .slick-dots li.slick-active {\n width: 8px;\n height: 8px;\n }\n .ant-carousel .slick-dots li.slick-active button {\n width: 8px;\n height: 8px;\n opacity: 1;\n }\n .ant-carousel .slick-dots li::after {\n width: 8px;\n height: 8px;\n border-radius: 50%;\n opacity: 1;\n background: #717171;\n }\n\n .oaTabs .ant-tabs-nav {\n border-top: 1px solid #e0e0e0;\n border-left: 1px solid #e0e0e0;\n border-right: 1px solid #e0e0e0;\n padding: 12px 22px 0 22px;\n margin: 0 0 8px 0;\n background: #fff;\n border-radius: 4px 4px 0 0;\n }\n .ant-card-body {\n padding: 24px 16px !important;\n border-radius: 16px;\n background: #f6f6f6;\n }\n .cardContainer {\n display: flex;\n gap: 24px;\n }\n .selectAndSearch .noClear {\n border-radius: 0 4px 4px 0;\n width: 320px;\n }\n\n .searchErrorMsg {\n font-size: 12px;\n margin: 4px 0px 0px;\n color: #de350b;\n }\n .searchOnly {\n margin: 0px 0px 16px;\n position: relative;\n }\n .searchOnly .ant-input-affix-wrapper {\n border-radius: 4px;\n max-width: 420px;\n padding-left: 44px;\n }\n .searchOnly .cstSearchIcon {\n position: absolute;\n left: 16px;\n top: 14px;\n z-index: 2;\n }\n\n .selectAndSearch .ant-input-affix-wrapper {\n border-radius: 0 4px 4px 0;\n width: 320px;\n }\n\n .selectAndSearch {\n flex-shrink: 0;\n }\n\n .customeSelectDropdown .ant-select-selector {\n border: none;\n padding: 0;\n }\n .customeSelectDropdown .ant-select-selection-item > span {\n font-size: 24px;\n font-weight: 500;\n line-height: 32px;\n }\n\n .customeSelectDropdown .ant-select {\n margin: 0 0 0 32px;\n }\n\n .customeSelectDropdown .ant-select .ant-select-arrow {\n color: #014fc5;\n inset-inline-end: -6px;\n }\n\n .customeSelectDropdown .ant-select-selector {\n box-shadow: none !important;\n }\n .oaheaderButtons {\n display: flex;\n gap: 24px;\n align-items: center;\n position: relative;\n flex-grow: 1;\n justify-content: space-between;\n }\n\n .oaheaderButtons.single-child {\n justify-content: flex-end;\n }\n\n .oaheaderButtonsRight {\n display: flex;\n flex-direction: row;\n gap: 16px;\n }\n\n .oaheaderButtons .notifyDot {\n width: 12px;\n height: 12px;\n background: #de350b;\n position: absolute;\n top: -4px;\n right: -4px;\n border-radius: 50%;\n }\n\n @media only screen and (max-width: 600px) {\n .selectAndSearch .ant-input-affix-wrapper {\n width: calc(100% - 84px);\n }\n .oaheaderSearchAndFilter .dropDownSearchContainer {\n width: 100%;\n }\n\n .oaheaderSearchAndFilter {\n align-items: flex-end;\n flex-direction: column;\n gap: 16px;\n }\n\n .inLine {\n flex-direction: column;\n gap: 0;\n align-items: flex-start;\n }\n\n .subHadingText > span {\n flex-direction: column;\n align-items: flex-start;\n }\n\n .fullPageLayout {\n flex-direction: column;\n padding: 0;\n }\n .oaRightLayouts {\n padding: 16px;\n border-radius: 0;\n background: #fff;\n box-shadow: none;\n height: auto;\n background: #f6f6f6;\n }\n .oaTabs .ant-tabs-nav {\n margin: 0 0 28px 0;\n padding: 12px 0 0 0;\n }\n .layoutHeadingPage {\n margin: 0 0 16px 0;\n background: #fff;\n padding: 16px;\n border-radius: 8px;\n width: 100%;\n }\n .layoutHeadingAndSearch {\n background: #fff;\n padding: 20px 16px;\n margin: 0;\n width: 100%;\n border-radius: 8px;\n }\n }\n"])));
|
|
20
|
+
const ListofDamageParts = exports.ListofDamageParts = _styledComponents.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n ul.damagedParts {\n display: flex;\n flex-direction: column;\n margin: 8px 0 0 16px;\n list-style-type: disc;\n }\n ul.damagedParts li {\n padding: 4px 0;\n width: 100%;\n }\n ul.damagedParts li::marker {\n color: #717171;\n font-size: 20px;\n }\n"])));
|
|
21
|
+
const IncidentListParts = exports.IncidentListParts = _styledComponents.default.div(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n .qaSec dl {\n display: flex;\n flex-direction: column;\n margin: 0;\n padding: 0;\n }\n .qaSec dl dt {\n display: flex;\n flex-direction: column;\n margin: 16px 0 0 0;\n }\n .qaSec dl dt:first-child {\n margin-top: 8px;\n }\n"])));
|
|
22
|
+
var _default = exports.default = {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
require("core-js/modules/web.dom-collections.iterator.js");
|
|
8
|
+
require("core-js/modules/web.url.js");
|
|
9
|
+
require("core-js/modules/web.url-search-params.js");
|
|
10
|
+
const downloadFileData = function downloadFileData(data) {
|
|
11
|
+
let fileName = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'file.xlsx';
|
|
12
|
+
const blob = new Blob([data], {
|
|
13
|
+
type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
|
|
14
|
+
});
|
|
15
|
+
const fileURL = (window.URL || window.webkitURL).createObjectURL(blob);
|
|
16
|
+
const link = document.createElement('a');
|
|
17
|
+
link.href = fileURL;
|
|
18
|
+
link.download = fileName; // fallback, since headers are not available
|
|
19
|
+
document.body.appendChild(link);
|
|
20
|
+
link.click();
|
|
21
|
+
document.body.removeChild(link);
|
|
22
|
+
};
|
|
23
|
+
var _default = exports.default = downloadFileData;
|