material-react-table-narender 2.13.10 → 2.13.12
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/index.esm.js +13 -8
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +13 -8
- package/dist/index.js.map +1 -1
- package/locales/te/index.d.ts +3 -0
- package/locales/te/index.esm.d.ts +3 -0
- package/locales/te/index.esm.js +95 -0
- package/locales/te/index.js +99 -0
- package/locales/te/package.json +6 -0
- package/package.json +1 -1
- package/src/utils/cell.utils.ts +15 -7
package/dist/index.esm.js
CHANGED
@@ -437,6 +437,11 @@ const openEditingCell = ({ cell, table, }) => {
|
|
437
437
|
const cellKeyboardShortcuts = ({ cell, cellElements, cellValue, containerElement, event, header, parentElement, table, }) => {
|
438
438
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
439
439
|
debugger;
|
440
|
+
if (event.altKey && event.key.toLowerCase() === 'n') {
|
441
|
+
event.preventDefault();
|
442
|
+
table.options.enableKeyboardShortcuts = !table.options.enableKeyboardShortcuts;
|
443
|
+
return;
|
444
|
+
}
|
440
445
|
if (!table.options.enableKeyboardShortcuts)
|
441
446
|
return;
|
442
447
|
if (event.isPropagationStopped())
|
@@ -500,24 +505,24 @@ const cellKeyboardShortcuts = ({ cell, cellElements, cellValue, containerElement
|
|
500
505
|
const button = currentCell.querySelector('button');
|
501
506
|
const autocomplete = currentCell.querySelector('.MuiAutocomplete-root input[type="text"]');
|
502
507
|
// Focus the appropriate element
|
503
|
-
if (
|
508
|
+
if (autocomplete) {
|
509
|
+
autocomplete.focus();
|
510
|
+
(_j = autocomplete.select) === null || _j === void 0 ? void 0 : _j.call(autocomplete);
|
511
|
+
}
|
512
|
+
else if (input) {
|
504
513
|
input.focus();
|
505
|
-
(
|
514
|
+
(_k = input.select) === null || _k === void 0 ? void 0 : _k.call(input);
|
506
515
|
}
|
507
516
|
else if (select) {
|
508
517
|
select.focus();
|
509
518
|
}
|
510
519
|
else if (checkbox) {
|
511
520
|
checkbox.focus();
|
512
|
-
checkbox.click();
|
521
|
+
// checkbox.click();
|
513
522
|
}
|
514
523
|
else if (button) {
|
515
524
|
button.focus();
|
516
|
-
button.click();
|
517
|
-
}
|
518
|
-
else if (autocomplete) {
|
519
|
-
autocomplete.focus();
|
520
|
-
(_k = autocomplete.select) === null || _k === void 0 ? void 0 : _k.call(autocomplete);
|
525
|
+
// button.click();
|
521
526
|
}
|
522
527
|
}
|
523
528
|
}
|