@universal-material/data-grid 0.3.5 → 0.3.6
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/grid.js +7 -1
- package/dist/grid.js.map +1 -1
- package/dist/grid.min.js +24 -24
- package/package.json +1 -1
package/dist/grid.js
CHANGED
|
@@ -12373,7 +12373,13 @@ let DataGrid = class DataGrid extends LitElement {
|
|
|
12373
12373
|
};
|
|
12374
12374
|
// A sobra vai para a última coluna NÃO fixa: uma fixa (ex.: ações no fim, com
|
|
12375
12375
|
// largura escolhida) fica na largura dela, como na referência (relato 0.3.3).
|
|
12376
|
-
|
|
12376
|
+
// Só fixas visíveis: para a última sem largura do autor (medida pelo
|
|
12377
|
+
// auto-width conta para a soma, mas pode levar a sobra; relato 0.3.5).
|
|
12378
|
+
const reversed = [...layout].reverse();
|
|
12379
|
+
const authorWidth = (column) => this.#userWidths.has(column) || (column.width !== null && column.width !== undefined);
|
|
12380
|
+
const last = reversed.find(({ column }) => this._fixedOf(column) === null)
|
|
12381
|
+
?? reversed.find(({ column }) => !authorWidth(column))
|
|
12382
|
+
?? layout[layout.length - 1];
|
|
12377
12383
|
let fillWidth;
|
|
12378
12384
|
if (fill && last) {
|
|
12379
12385
|
const others = layout.reduce((sum, { column, gapBefore }) => sum + gapBefore + (column === last.column ? 0 : widthOf(column) ?? 0), this.#trailingGap);
|