ooxml-core 1.8.2 → 1.8.3
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/automation/index.cjs +3 -2
- package/dist/automation/index.mjs +3 -2
- package/dist/xlsx/edit/sort.d.ts +1 -1
- package/dist/xlsx/edit/sort.d.ts.map +1 -1
- package/dist/xlsx/index.cjs +3 -2
- package/dist/xlsx/index.mjs +3 -2
- package/dist/xlsx/ui/index.cjs +3 -2
- package/dist/xlsx/ui/index.mjs +3 -2
- package/package.json +1 -1
|
@@ -33196,6 +33196,7 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
33196
33196
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
33197
33197
|
const rows = [];
|
|
33198
33198
|
for (let row3 = firstRow; row3 <= lastRow; row3++) {
|
|
33199
|
+
if (sheet.rowInfo.get(row3)?.hidden) continue;
|
|
33199
33200
|
const cells3 = /* @__PURE__ */ new Map();
|
|
33200
33201
|
for (const [col, cell] of sheet.rows.get(row3) ?? [])
|
|
33201
33202
|
if (col >= r.start.col && col <= r.end.col) cells3.set(col, cell);
|
|
@@ -33213,9 +33214,9 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
33213
33214
|
return 0;
|
|
33214
33215
|
});
|
|
33215
33216
|
for (const { row: row3, cells: cells3 } of rows) for (const col of cells3.keys()) deleteCell(sheet, row3, col);
|
|
33216
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row,
|
|
33217
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row, rows[i2].row])));
|
|
33217
33218
|
sorted2.forEach((source2, i2) => {
|
|
33218
|
-
const row3 =
|
|
33219
|
+
const row3 = rows[i2].row;
|
|
33219
33220
|
const dRow = row3 - source2.row;
|
|
33220
33221
|
for (const [col, cell] of source2.cells) {
|
|
33221
33222
|
if (cell.formula !== void 0 && dRow) {
|
|
@@ -33190,6 +33190,7 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
33190
33190
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
33191
33191
|
const rows = [];
|
|
33192
33192
|
for (let row3 = firstRow; row3 <= lastRow; row3++) {
|
|
33193
|
+
if (sheet.rowInfo.get(row3)?.hidden) continue;
|
|
33193
33194
|
const cells3 = /* @__PURE__ */ new Map();
|
|
33194
33195
|
for (const [col, cell] of sheet.rows.get(row3) ?? [])
|
|
33195
33196
|
if (col >= r.start.col && col <= r.end.col) cells3.set(col, cell);
|
|
@@ -33207,9 +33208,9 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
33207
33208
|
return 0;
|
|
33208
33209
|
});
|
|
33209
33210
|
for (const { row: row3, cells: cells3 } of rows) for (const col of cells3.keys()) deleteCell(sheet, row3, col);
|
|
33210
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row,
|
|
33211
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row, rows[i2].row])));
|
|
33211
33212
|
sorted2.forEach((source2, i2) => {
|
|
33212
|
-
const row3 =
|
|
33213
|
+
const row3 = rows[i2].row;
|
|
33213
33214
|
const dRow = row3 - source2.row;
|
|
33214
33215
|
for (const [col, cell] of source2.cells) {
|
|
33215
33216
|
if (cell.formula !== void 0 && dRow) {
|
package/dist/xlsx/edit/sort.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export interface SortKey {
|
|
|
10
10
|
* text compares case-insensitively.
|
|
11
11
|
*/
|
|
12
12
|
export declare function compareCellValues(a: CellValue, b: CellValue, descending?: boolean): number;
|
|
13
|
-
/** Sorts rows
|
|
13
|
+
/** Sorts visible rows in place, leaving hidden rows untouched. Used by the auto-filter sort. */
|
|
14
14
|
export declare function sortRows(sheet: Worksheet, range: CellRange, keys: SortKey[], hasHeader: boolean): void;
|
|
15
15
|
/** Sorts the rows of `range` by `keys` (absolute column indices), stable, header kept in place. */
|
|
16
16
|
export declare function sortRange(ctx: EditContext, s: number, range: CellRange, keys: SortKey[], hasHeader: boolean): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sort.d.ts","sourceRoot":"","sources":["../../../xlsx/edit/sort.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAmC,MAAM,YAAY,CAAC;AAE7E,OAAO,KAAK,EAAQ,SAAS,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE3D,OAAO,EAAE,KAAK,WAAW,EAAW,MAAM,WAAW,CAAC;AAItD,MAAM,WAAW,OAAO;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,OAAO,CAAC;CACrB;AAeD;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,SAAS,EAAE,UAAU,UAAQ,GAAG,MAAM,CAaxF;AAED,
|
|
1
|
+
{"version":3,"file":"sort.d.ts","sourceRoot":"","sources":["../../../xlsx/edit/sort.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAmC,MAAM,YAAY,CAAC;AAE7E,OAAO,KAAK,EAAQ,SAAS,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAE3D,OAAO,EAAE,KAAK,WAAW,EAAW,MAAM,WAAW,CAAC;AAItD,MAAM,WAAW,OAAO;IACvB,GAAG,EAAE,MAAM,CAAC;IACZ,UAAU,CAAC,EAAE,OAAO,CAAC;CACrB;AAeD;;;GAGG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,SAAS,EAAE,UAAU,UAAQ,GAAG,MAAM,CAaxF;AAED,gGAAgG;AAChG,wBAAgB,QAAQ,CACvB,KAAK,EAAE,SAAS,EAChB,KAAK,EAAE,SAAS,EAChB,IAAI,EAAE,OAAO,EAAE,EACf,SAAS,EAAE,OAAO,GAChB,IAAI,CAkDN;AAsBD,mGAAmG;AACnG,wBAAgB,SAAS,CACxB,GAAG,EAAE,WAAW,EAChB,CAAC,EAAE,MAAM,EACT,KAAK,EAAE,SAAS,EAChB,IAAI,EAAE,OAAO,EAAE,EACf,SAAS,EAAE,OAAO,GAChB,IAAI,CAUN"}
|
package/dist/xlsx/index.cjs
CHANGED
|
@@ -27397,6 +27397,7 @@ function sortRows2(sheet, range, keys, hasHeader) {
|
|
|
27397
27397
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
27398
27398
|
const rows = [];
|
|
27399
27399
|
for (let row2 = firstRow; row2 <= lastRow; row2++) {
|
|
27400
|
+
if (sheet.rowInfo.get(row2)?.hidden) continue;
|
|
27400
27401
|
const cells = /* @__PURE__ */ new Map();
|
|
27401
27402
|
for (const [col, cell] of sheet.rows.get(row2) ?? [])
|
|
27402
27403
|
if (col >= r.start.col && col <= r.end.col) cells.set(col, cell);
|
|
@@ -27414,9 +27415,9 @@ function sortRows2(sheet, range, keys, hasHeader) {
|
|
|
27414
27415
|
return 0;
|
|
27415
27416
|
});
|
|
27416
27417
|
for (const { row: row2, cells } of rows) for (const col of cells.keys()) deleteCell(sheet, row2, col);
|
|
27417
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row,
|
|
27418
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row, rows[i2].row])));
|
|
27418
27419
|
sorted2.forEach((source2, i2) => {
|
|
27419
|
-
const row2 =
|
|
27420
|
+
const row2 = rows[i2].row;
|
|
27420
27421
|
const dRow = row2 - source2.row;
|
|
27421
27422
|
for (const [col, cell] of source2.cells) {
|
|
27422
27423
|
if (cell.formula !== void 0 && dRow) {
|
package/dist/xlsx/index.mjs
CHANGED
|
@@ -27391,6 +27391,7 @@ function sortRows2(sheet, range, keys, hasHeader) {
|
|
|
27391
27391
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
27392
27392
|
const rows = [];
|
|
27393
27393
|
for (let row2 = firstRow; row2 <= lastRow; row2++) {
|
|
27394
|
+
if (sheet.rowInfo.get(row2)?.hidden) continue;
|
|
27394
27395
|
const cells = /* @__PURE__ */ new Map();
|
|
27395
27396
|
for (const [col, cell] of sheet.rows.get(row2) ?? [])
|
|
27396
27397
|
if (col >= r.start.col && col <= r.end.col) cells.set(col, cell);
|
|
@@ -27408,9 +27409,9 @@ function sortRows2(sheet, range, keys, hasHeader) {
|
|
|
27408
27409
|
return 0;
|
|
27409
27410
|
});
|
|
27410
27411
|
for (const { row: row2, cells } of rows) for (const col of cells.keys()) deleteCell(sheet, row2, col);
|
|
27411
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row,
|
|
27412
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source2, i2) => [source2.row, rows[i2].row])));
|
|
27412
27413
|
sorted2.forEach((source2, i2) => {
|
|
27413
|
-
const row2 =
|
|
27414
|
+
const row2 = rows[i2].row;
|
|
27414
27415
|
const dRow = row2 - source2.row;
|
|
27415
27416
|
for (const [col, cell] of source2.cells) {
|
|
27416
27417
|
if (cell.formula !== void 0 && dRow) {
|
package/dist/xlsx/ui/index.cjs
CHANGED
|
@@ -17049,6 +17049,7 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
17049
17049
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
17050
17050
|
const rows2 = [];
|
|
17051
17051
|
for (let row2 = firstRow; row2 <= lastRow; row2++) {
|
|
17052
|
+
if (sheet.rowInfo.get(row2)?.hidden) continue;
|
|
17052
17053
|
const cells = /* @__PURE__ */ new Map();
|
|
17053
17054
|
for (const [col, cell] of sheet.rows.get(row2) ?? [])
|
|
17054
17055
|
if (col >= r.start.col && col <= r.end.col) cells.set(col, cell);
|
|
@@ -17066,9 +17067,9 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
17066
17067
|
return 0;
|
|
17067
17068
|
});
|
|
17068
17069
|
for (const { row: row2, cells } of rows2) for (const col of cells.keys()) deleteCell(sheet, row2, col);
|
|
17069
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source, i2) => [source.row,
|
|
17070
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source, i2) => [source.row, rows2[i2].row])));
|
|
17070
17071
|
sorted2.forEach((source, i2) => {
|
|
17071
|
-
const row2 =
|
|
17072
|
+
const row2 = rows2[i2].row;
|
|
17072
17073
|
const dRow = row2 - source.row;
|
|
17073
17074
|
for (const [col, cell] of source.cells) {
|
|
17074
17075
|
if (cell.formula !== void 0 && dRow) {
|
package/dist/xlsx/ui/index.mjs
CHANGED
|
@@ -17047,6 +17047,7 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
17047
17047
|
const sortKeys2 = keys.length ? keys : [{ col: r.start.col }];
|
|
17048
17048
|
const rows2 = [];
|
|
17049
17049
|
for (let row2 = firstRow; row2 <= lastRow; row2++) {
|
|
17050
|
+
if (sheet.rowInfo.get(row2)?.hidden) continue;
|
|
17050
17051
|
const cells = /* @__PURE__ */ new Map();
|
|
17051
17052
|
for (const [col, cell] of sheet.rows.get(row2) ?? [])
|
|
17052
17053
|
if (col >= r.start.col && col <= r.end.col) cells.set(col, cell);
|
|
@@ -17064,9 +17065,9 @@ function sortRows2(sheet, range2, keys, hasHeader) {
|
|
|
17064
17065
|
return 0;
|
|
17065
17066
|
});
|
|
17066
17067
|
for (const { row: row2, cells } of rows2) for (const col of cells.keys()) deleteCell(sheet, row2, col);
|
|
17067
|
-
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source, i2) => [source.row,
|
|
17068
|
+
moveAnnotations(sheet, dataArea, new Map(sorted2.map((source, i2) => [source.row, rows2[i2].row])));
|
|
17068
17069
|
sorted2.forEach((source, i2) => {
|
|
17069
|
-
const row2 =
|
|
17070
|
+
const row2 = rows2[i2].row;
|
|
17070
17071
|
const dRow = row2 - source.row;
|
|
17071
17072
|
for (const [col, cell] of source.cells) {
|
|
17072
17073
|
if (cell.formula !== void 0 && dRow) {
|