sccoreui 6.3.60 → 6.3.61
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/App.js
CHANGED
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
4
|
-
// import { MultiSelect } from "primereact/multiselect";
|
|
5
4
|
require("./App.scss");
|
|
6
5
|
// import Home from "./pages/home";
|
|
7
|
-
// import FroalaTextEditor from "./components/froala-editor/FroalaEditor";
|
|
8
|
-
// import Home from "./pages/home";
|
|
9
|
-
// import { useState } from "react";
|
|
10
6
|
const App = () => {
|
|
11
7
|
// const [selectedCountries, setSelectedCountries] = useState(null);
|
|
12
|
-
return ((0, jsx_runtime_1.jsx)("div",
|
|
8
|
+
return ((0, jsx_runtime_1.jsx)("div", { className: "m-6" }));
|
|
13
9
|
};
|
|
14
10
|
exports.default = App;
|
|
@@ -46,6 +46,6 @@ function Search({ searchPlaceHolder }) {
|
|
|
46
46
|
setFeatureDetails(Object.assign(Object.assign({}, featureDetails), { searchedText: "" }));
|
|
47
47
|
}
|
|
48
48
|
setInputValue("");
|
|
49
|
-
}, title: "Clear" }, { children: (0, jsx_runtime_1.jsx)(svg_component_1.default, { icon: "x-close", size: 18 }) }))), (0, jsx_runtime_1.jsx)(inputtext_1.InputText, { value: inputValue, onChange: (e) => !isDisabled && setInputValue(e.target.value), className: "w-21rem", placeholder: searchPlaceHolder || "Search by name or code", disabled: isDisabled })] })));
|
|
49
|
+
}, title: "Clear" }, { children: (0, jsx_runtime_1.jsx)(svg_component_1.default, { icon: "x-close", size: 18 }) }))), (0, jsx_runtime_1.jsx)(inputtext_1.InputText, { id: "ag-grid-main-search", value: inputValue, onChange: (e) => !isDisabled && setInputValue(e.target.value), className: "w-21rem", placeholder: searchPlaceHolder || "Search by name or code", disabled: isDisabled })] })));
|
|
50
50
|
}
|
|
51
51
|
exports.default = Search;
|
|
@@ -563,12 +563,13 @@ const getGroupIds = (gridRef) => {
|
|
|
563
563
|
return { firstGroupIds, secondGroupIds };
|
|
564
564
|
};
|
|
565
565
|
exports.getGroupIds = getGroupIds;
|
|
566
|
-
const handleCheckboxClick = (e, params, featureDetails, gridData, setFeatureDetails, groupingColumns, setSelectedGroup) => {
|
|
566
|
+
const handleCheckboxClick = (e, params, featureDetails, gridData, setFeatureDetails, groupingColumns, setSelectedGroup, selectColumns) => {
|
|
567
567
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
568
568
|
const isChecked = e.checked;
|
|
569
569
|
const { data: rowData } = params;
|
|
570
570
|
// Update checkbox data and set the updated state
|
|
571
571
|
const updatedCheckBoxData = (0, exports.updateRecords)(rowData, featureDetails, gridData);
|
|
572
|
+
selectColumns(Object.assign(Object.assign({}, featureDetails), { checkBoxSelection: updatedCheckBoxData }));
|
|
572
573
|
setFeatureDetails(Object.assign(Object.assign({}, featureDetails), { checkBoxSelection: updatedCheckBoxData }));
|
|
573
574
|
// Gather parent and super parent group data for condition checks
|
|
574
575
|
const parentGroupData = (_c = (_b = (_a = params === null || params === void 0 ? void 0 : params.node) === null || _a === void 0 ? void 0 : _a.parent) === null || _b === void 0 ? void 0 : _b.childrenAfterGroup) === null || _c === void 0 ? void 0 : _c.map((childNode) => childNode === null || childNode === void 0 ? void 0 : childNode.data);
|
|
@@ -15,7 +15,7 @@ const group_checkbox_1 = tslib_1.__importDefault(require("./group-checkbox"));
|
|
|
15
15
|
const utilComponents_1 = require("./utilComponents");
|
|
16
16
|
function ParentForGrid(props) {
|
|
17
17
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
18
|
-
const { gridProps = {}, gridViewTemplate } = props;
|
|
18
|
+
const { gridProps = {}, gridViewTemplate, selectColumns = () => { } } = props;
|
|
19
19
|
const [gridData, setGridData] = (0, react_1.useState)({
|
|
20
20
|
rowData: (props === null || props === void 0 ? void 0 : props.rowData) || [],
|
|
21
21
|
columnData: (0, helper_1.sortColumns)(props === null || props === void 0 ? void 0 : props.columnData),
|
|
@@ -94,6 +94,7 @@ function ParentForGrid(props) {
|
|
|
94
94
|
else {
|
|
95
95
|
setSelectedGroup([]);
|
|
96
96
|
}
|
|
97
|
+
selectColumns(Object.assign(Object.assign({}, featureDetails), { checkBoxSelection: checkboxData }));
|
|
97
98
|
setFeatureDetails(Object.assign(Object.assign({}, featureDetails), { checkBoxSelection: checkboxData }));
|
|
98
99
|
};
|
|
99
100
|
// JSX for rendering checkbox in header
|
|
@@ -115,7 +116,7 @@ function ParentForGrid(props) {
|
|
|
115
116
|
const { data } = params;
|
|
116
117
|
// const { allBoxChecked, excludedRecords, includedRecords } = featureDetails.checkBoxSelection;
|
|
117
118
|
const isChecked = (0, helper_1.getCheckedStatus)(data, featureDetails, constants_1.GRID_CHECKBOX_STATUS, setFeatureDetails);
|
|
118
|
-
return ((0, jsx_runtime_1.jsx)(grid_checkbox_1.default, { checked: isChecked, onChange: (e) => (0, helper_1.handleCheckboxClick)(e, params, featureDetails, gridData, setFeatureDetails, groupingColumns, setSelectedGroup), isIndeterminate: false, shouldRenderOnRight: (_a = props === null || props === void 0 ? void 0 : props.conditionsToDisplay) === null || _a === void 0 ? void 0 : _a.displayCheckboxOnRight }));
|
|
119
|
+
return ((0, jsx_runtime_1.jsx)(grid_checkbox_1.default, { checked: isChecked, onChange: (e) => (0, helper_1.handleCheckboxClick)(e, params, featureDetails, gridData, setFeatureDetails, groupingColumns, setSelectedGroup, selectColumns), isIndeterminate: false, shouldRenderOnRight: (_a = props === null || props === void 0 ? void 0 : props.conditionsToDisplay) === null || _a === void 0 ? void 0 : _a.displayCheckboxOnRight }));
|
|
119
120
|
};
|
|
120
121
|
// Callback to products for getting data
|
|
121
122
|
const getData = (startRow, endRow, currentFeatures, params) => tslib_1.__awaiter(this, void 0, void 0, function* () {
|
|
@@ -51,5 +51,5 @@ export declare const getGroupIds: (gridRef: any) => {
|
|
|
51
51
|
firstGroupIds: string[];
|
|
52
52
|
secondGroupIds: string[];
|
|
53
53
|
};
|
|
54
|
-
export declare const handleCheckboxClick: (e: any, params: any, featureDetails: any, gridData: any, setFeatureDetails: any, groupingColumns: any, setSelectedGroup: any) => void;
|
|
54
|
+
export declare const handleCheckboxClick: (e: any, params: any, featureDetails: any, gridData: any, setFeatureDetails: any, groupingColumns: any, setSelectedGroup: any, selectColumns: any) => void;
|
|
55
55
|
export declare const deepClone: (obj: any) => any;
|