@yuneta/gobj-ui 7.23.189 → 7.23.190
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
CHANGED
|
@@ -26440,6 +26440,7 @@ var attrs_table$5 = [
|
|
|
26440
26440
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_INTEGER, "page_size", 0, 0, "Rows per page. 0 leaves the `tabulator_settings` value alone. With with_remote_paging it is also the size of each fetch (200 when unset)"),
|
|
26441
26441
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_BOOLEAN, "with_in_row_edit_icons", 0, true, "Add a last column with internal EDIT/DELETE icon"),
|
|
26442
26442
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_BOOLEAN, "editable", 0, false, "Edit state"),
|
|
26443
|
+
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_INTEGER, "max_col_width", 0, 420, "Ceiling, in px, for a data column. The table lays out `fitDataFill`, which sizes a column to its DATA: one `description` holding a paragraph took the whole viewport and left every other column off screen. 0 removes the ceiling; a reader still widens any column by hand (columns are resizable)"),
|
|
26443
26444
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_BOOLEAN, "with_checkbox", 0, true, "Auxiliary first column to select rows"),
|
|
26444
26445
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_BOOLEAN, "with_radio", 0, false, "Auxiliary first column to select one row"),
|
|
26445
26446
|
(0, _yuneta_gobj_js.SDATA)(_yuneta_gobj_js.data_type_t.DTP_BOOLEAN, "with_selection_bar", 0, false, "Show the shared selection bar (\"N selected\" + a way out) above the table while in edition mode. OFF by default: the bar takes its words from the HOST's i18n, and a host that has not defined \"{{n}} selected\" and \"clear selection\" would render the keys"),
|
|
@@ -27332,6 +27333,7 @@ function create_tabulator(gobj) {
|
|
|
27332
27333
|
}
|
|
27333
27334
|
if (colDef.headerFilter && colDef.headerFilter !== "tickCross") colDef.minWidth = 150;
|
|
27334
27335
|
}
|
|
27336
|
+
let max_col_width = (0, _yuneta_gobj_js.gobj_read_integer_attr)(gobj, "max_col_width");
|
|
27335
27337
|
for (let i = 0; i < desc.cols.length; i++) {
|
|
27336
27338
|
let col = desc.cols[i];
|
|
27337
27339
|
if (!col.id || col.id[0] === "_") continue;
|
|
@@ -27434,6 +27436,7 @@ function create_tabulator(gobj) {
|
|
|
27434
27436
|
hozAlign,
|
|
27435
27437
|
formatter: colFormatter
|
|
27436
27438
|
};
|
|
27439
|
+
if (max_col_width > 0) colDef.maxWidth = max_col_width;
|
|
27437
27440
|
if (with_header_filters) apply_header_filter(colDef, field_desc);
|
|
27438
27441
|
if (with_inline_edit) inline_editor_for(colDef, col, field_desc);
|
|
27439
27442
|
if (vertAlign) colDef.vertAlign = vertAlign;
|
package/dist/gobj-ui.es.js
CHANGED
|
@@ -26435,6 +26435,7 @@ var attrs_table$5 = [
|
|
|
26435
26435
|
SDATA(data_type_t.DTP_INTEGER, "page_size", 0, 0, "Rows per page. 0 leaves the `tabulator_settings` value alone. With with_remote_paging it is also the size of each fetch (200 when unset)"),
|
|
26436
26436
|
SDATA(data_type_t.DTP_BOOLEAN, "with_in_row_edit_icons", 0, true, "Add a last column with internal EDIT/DELETE icon"),
|
|
26437
26437
|
SDATA(data_type_t.DTP_BOOLEAN, "editable", 0, false, "Edit state"),
|
|
26438
|
+
SDATA(data_type_t.DTP_INTEGER, "max_col_width", 0, 420, "Ceiling, in px, for a data column. The table lays out `fitDataFill`, which sizes a column to its DATA: one `description` holding a paragraph took the whole viewport and left every other column off screen. 0 removes the ceiling; a reader still widens any column by hand (columns are resizable)"),
|
|
26438
26439
|
SDATA(data_type_t.DTP_BOOLEAN, "with_checkbox", 0, true, "Auxiliary first column to select rows"),
|
|
26439
26440
|
SDATA(data_type_t.DTP_BOOLEAN, "with_radio", 0, false, "Auxiliary first column to select one row"),
|
|
26440
26441
|
SDATA(data_type_t.DTP_BOOLEAN, "with_selection_bar", 0, false, "Show the shared selection bar (\"N selected\" + a way out) above the table while in edition mode. OFF by default: the bar takes its words from the HOST's i18n, and a host that has not defined \"{{n}} selected\" and \"clear selection\" would render the keys"),
|
|
@@ -27327,6 +27328,7 @@ function create_tabulator(gobj) {
|
|
|
27327
27328
|
}
|
|
27328
27329
|
if (colDef.headerFilter && colDef.headerFilter !== "tickCross") colDef.minWidth = 150;
|
|
27329
27330
|
}
|
|
27331
|
+
let max_col_width = gobj_read_integer_attr(gobj, "max_col_width");
|
|
27330
27332
|
for (let i = 0; i < desc.cols.length; i++) {
|
|
27331
27333
|
let col = desc.cols[i];
|
|
27332
27334
|
if (!col.id || col.id[0] === "_") continue;
|
|
@@ -27429,6 +27431,7 @@ function create_tabulator(gobj) {
|
|
|
27429
27431
|
hozAlign,
|
|
27430
27432
|
formatter: colFormatter
|
|
27431
27433
|
};
|
|
27434
|
+
if (max_col_width > 0) colDef.maxWidth = max_col_width;
|
|
27432
27435
|
if (with_header_filters) apply_header_filter(colDef, field_desc);
|
|
27433
27436
|
if (with_inline_edit) inline_editor_for(colDef, col, field_desc);
|
|
27434
27437
|
if (vertAlign) colDef.vertAlign = vertAlign;
|
package/package.json
CHANGED
|
@@ -210,6 +210,7 @@ SDATA(data_type_t.DTP_BOOLEAN, "with_in_row_edit_icons", 0, true, "Add a
|
|
|
210
210
|
SDATA(data_type_t.DTP_BOOLEAN, "editable", 0, false, "Edit state"),
|
|
211
211
|
|
|
212
212
|
/*---------------- Selection Mode ----------------*/
|
|
213
|
+
SDATA(data_type_t.DTP_INTEGER, "max_col_width", 0, 420, "Ceiling, in px, for a data column. The table lays out `fitDataFill`, which sizes a column to its DATA: one `description` holding a paragraph took the whole viewport and left every other column off screen. 0 removes the ceiling; a reader still widens any column by hand (columns are resizable)"),
|
|
213
214
|
SDATA(data_type_t.DTP_BOOLEAN, "with_checkbox", 0, true, "Auxiliary first column to select rows"),
|
|
214
215
|
SDATA(data_type_t.DTP_BOOLEAN, "with_radio", 0, false, "Auxiliary first column to select one row"),
|
|
215
216
|
SDATA(data_type_t.DTP_BOOLEAN, "with_selection_bar", 0, false, "Show the shared selection bar (\"N selected\" + a way out) above the table while in edition mode. OFF by default: the bar takes its words from the HOST's i18n, and a host that has not defined \"{{n}} selected\" and \"clear selection\" would render the keys"),
|
|
@@ -1341,6 +1342,8 @@ function create_tabulator(gobj)
|
|
|
1341
1342
|
}
|
|
1342
1343
|
}
|
|
1343
1344
|
|
|
1345
|
+
let max_col_width = gobj_read_integer_attr(gobj, "max_col_width");
|
|
1346
|
+
|
|
1344
1347
|
for (let i = 0; i < desc.cols.length; i++) {
|
|
1345
1348
|
let col = desc.cols[i];
|
|
1346
1349
|
if(!col.id || col.id[0]==='_') {
|
|
@@ -1472,6 +1475,16 @@ function create_tabulator(gobj)
|
|
|
1472
1475
|
hozAlign: hozAlign,
|
|
1473
1476
|
formatter: colFormatter,
|
|
1474
1477
|
};
|
|
1478
|
+
/* A ceiling, because `fitDataFill` sizes a column to its DATA and
|
|
1479
|
+
* a text column has no natural width: one `description` holding a
|
|
1480
|
+
* paragraph -- the agent's `configurations` is full of them --
|
|
1481
|
+
* came out wider than the viewport and pushed every other column,
|
|
1482
|
+
* the id included, off the screen. The cell keeps its whole text;
|
|
1483
|
+
* what the ceiling costs is having to widen the column, or open
|
|
1484
|
+
* the record, to read the end of it. */
|
|
1485
|
+
if(max_col_width > 0) {
|
|
1486
|
+
colDef.maxWidth = max_col_width;
|
|
1487
|
+
}
|
|
1475
1488
|
if(with_header_filters) {
|
|
1476
1489
|
apply_header_filter(colDef, field_desc);
|
|
1477
1490
|
}
|