@yuneta/gobj-ui 7.23.123 → 7.23.124
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/gobj-ui.cjs.js +6 -3
- package/dist/gobj-ui.es.js +6 -3
- package/package.json +1 -1
- package/src/yui_tabulator_i18n.js +10 -2
package/dist/gobj-ui.cjs.js
CHANGED
|
@@ -6014,10 +6014,13 @@ function yui_tabulator_name_filters(table, t) {
|
|
|
6014
6014
|
***************************************************************/
|
|
6015
6015
|
var TABULATOR_ROW_SELECT_ARIA = "Select Row";
|
|
6016
6016
|
function yui_tabulator_name_row_selects(table, t) {
|
|
6017
|
-
if (!table
|
|
6017
|
+
if (!table) return;
|
|
6018
6018
|
try {
|
|
6019
|
-
let $el = table.getElement();
|
|
6020
|
-
if (!$el)
|
|
6019
|
+
let $el = table.element || (typeof table.getElement === "function" ? table.getElement() : null);
|
|
6020
|
+
if (!$el) {
|
|
6021
|
+
(0, _yuneta_gobj_js.log_warning)("yui_tabulator_name_row_selects: table has no element: its row-selection boxes keep Tabulator's English name");
|
|
6022
|
+
return;
|
|
6023
|
+
}
|
|
6021
6024
|
let boxes = $el.querySelectorAll(`input[type=checkbox][aria-label="${TABULATOR_ROW_SELECT_ARIA}"]`);
|
|
6022
6025
|
for (let $box of boxes) {
|
|
6023
6026
|
$box.setAttribute("aria-label", t("select row"));
|
package/dist/gobj-ui.es.js
CHANGED
|
@@ -6009,10 +6009,13 @@ function yui_tabulator_name_filters(table, t) {
|
|
|
6009
6009
|
***************************************************************/
|
|
6010
6010
|
var TABULATOR_ROW_SELECT_ARIA = "Select Row";
|
|
6011
6011
|
function yui_tabulator_name_row_selects(table, t) {
|
|
6012
|
-
if (!table
|
|
6012
|
+
if (!table) return;
|
|
6013
6013
|
try {
|
|
6014
|
-
let $el = table.getElement();
|
|
6015
|
-
if (!$el)
|
|
6014
|
+
let $el = table.element || (typeof table.getElement === "function" ? table.getElement() : null);
|
|
6015
|
+
if (!$el) {
|
|
6016
|
+
log_warning("yui_tabulator_name_row_selects: table has no element: its row-selection boxes keep Tabulator's English name");
|
|
6017
|
+
return;
|
|
6018
|
+
}
|
|
6016
6019
|
let boxes = $el.querySelectorAll(`input[type=checkbox][aria-label="${TABULATOR_ROW_SELECT_ARIA}"]`);
|
|
6017
6020
|
for (let $box of boxes) {
|
|
6018
6021
|
$box.setAttribute("aria-label", t("select row"));
|
package/package.json
CHANGED
|
@@ -160,12 +160,20 @@ const TABULATOR_ROW_SELECT_ARIA = "Select Row";
|
|
|
160
160
|
|
|
161
161
|
function yui_tabulator_name_row_selects(table, t)
|
|
162
162
|
{
|
|
163
|
-
if(!table
|
|
163
|
+
if(!table) {
|
|
164
164
|
return;
|
|
165
165
|
}
|
|
166
166
|
try {
|
|
167
|
-
|
|
167
|
+
/* A Tabulator INSTANCE carries its node as `.element`; only its
|
|
168
|
+
* Column/Row components have `getElement()`. Testing for the
|
|
169
|
+
* method and returning silently made this a no-op on every real
|
|
170
|
+
* table -- and a no-op is what a dump of the deployed page
|
|
171
|
+
* showed, with the boxes still saying "Select Row". */
|
|
172
|
+
let $el = table.element
|
|
173
|
+
|| (typeof table.getElement === "function" ? table.getElement() : null);
|
|
168
174
|
if(!$el) {
|
|
175
|
+
log_warning("yui_tabulator_name_row_selects: table has no element: "
|
|
176
|
+
+ "its row-selection boxes keep Tabulator's English name");
|
|
169
177
|
return;
|
|
170
178
|
}
|
|
171
179
|
let boxes = $el.querySelectorAll(
|