@vuu-ui/vuu-table-extras 0.8.27-debug → 0.8.28-debug
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/cjs/index.js +23 -19
- package/cjs/index.js.map +2 -2
- package/esm/index.js +23 -19
- package/esm/index.js.map +2 -2
- package/package.json +12 -12
package/esm/index.js
CHANGED
|
@@ -459,16 +459,18 @@ var ColumnList = ({
|
|
|
459
459
|
({ target }) => {
|
|
460
460
|
const input = target;
|
|
461
461
|
const listItem = queryClosest(target, `.${classBaseListItem}`);
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
462
|
+
if (listItem) {
|
|
463
|
+
const {
|
|
464
|
+
dataset: { name: name2 }
|
|
465
|
+
} = listItem;
|
|
466
|
+
if (name2) {
|
|
467
|
+
const saltCheckbox = queryClosest(target, `.${classBase6}-checkBox`);
|
|
468
|
+
const saltSwitch = queryClosest(target, `.${classBase6}-switch`);
|
|
469
|
+
if (saltCheckbox) {
|
|
470
|
+
onChange(name2, "subscribed", input.checked);
|
|
471
|
+
} else if (saltSwitch) {
|
|
472
|
+
onChange(name2, "hidden", input.checked === false);
|
|
473
|
+
}
|
|
472
474
|
}
|
|
473
475
|
}
|
|
474
476
|
},
|
|
@@ -3398,15 +3400,17 @@ var useTableSettings = ({
|
|
|
3398
3400
|
const handleChangeTableAttribute = useCallback14(
|
|
3399
3401
|
(evt) => {
|
|
3400
3402
|
const button = queryClosest3(evt.target, "button");
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3409
|
-
|
|
3403
|
+
if (button) {
|
|
3404
|
+
const { ariaPressed, value } = button;
|
|
3405
|
+
console.log({ ariaPressed, value, button });
|
|
3406
|
+
setColumnState((state) => ({
|
|
3407
|
+
...state,
|
|
3408
|
+
tableConfig: {
|
|
3409
|
+
...state.tableConfig,
|
|
3410
|
+
[value]: ariaPressed !== "true"
|
|
3411
|
+
}
|
|
3412
|
+
}));
|
|
3413
|
+
}
|
|
3410
3414
|
},
|
|
3411
3415
|
[]
|
|
3412
3416
|
);
|