oasis-editor 0.0.72 → 0.0.74

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.
@@ -2483,7 +2483,7 @@ function OasisEditorAppLazy(props = {}) {
2483
2483
  onCleanup(() => {
2484
2484
  cancelled = true;
2485
2485
  });
2486
- import("./OasisEditorApp-BqiPk81i.js").then((m) => {
2486
+ import("./OasisEditorApp-BkJmlejJ.js").then((m) => {
2487
2487
  cancelled = true;
2488
2488
  setProgress(1);
2489
2489
  setTimeout(() => setApp(() => m.OasisEditorApp), 180);
@@ -14078,32 +14078,41 @@ function renumberFootnotes(document2) {
14078
14078
  if (!blocks) return blocks;
14079
14079
  let blockChanged = false;
14080
14080
  const nextBlocks = blocks.map((block) => {
14081
- if (block.type === "paragraph") {
14082
- const updated = rewriteParagraphMarkers$1(block, markerByFootnoteId);
14083
- if (updated !== block) blockChanged = true;
14084
- return updated;
14085
- }
14086
- let tableChanged = false;
14087
- const nextRows = block.rows.map((row) => {
14088
- let rowChanged = false;
14089
- const nextCells = row.cells.map((cell) => {
14090
- let cellChanged = false;
14091
- const nextCellBlocks = cell.blocks.map((p) => {
14092
- const updated = rewriteParagraphMarkers$1(p, markerByFootnoteId);
14093
- if (updated !== p) cellChanged = true;
14094
- return updated;
14081
+ switch (block.type) {
14082
+ case "paragraph": {
14083
+ const updated = rewriteParagraphMarkers$1(block, markerByFootnoteId);
14084
+ if (updated !== block) blockChanged = true;
14085
+ return updated;
14086
+ }
14087
+ case "table": {
14088
+ let tableChanged = false;
14089
+ const nextRows = block.rows.map((row) => {
14090
+ let rowChanged = false;
14091
+ const nextCells = row.cells.map((cell) => {
14092
+ let cellChanged = false;
14093
+ const nextCellBlocks = cell.blocks.map((p) => {
14094
+ const updated = rewriteParagraphMarkers$1(
14095
+ p,
14096
+ markerByFootnoteId
14097
+ );
14098
+ if (updated !== p) cellChanged = true;
14099
+ return updated;
14100
+ });
14101
+ if (!cellChanged) return cell;
14102
+ rowChanged = true;
14103
+ return { ...cell, blocks: nextCellBlocks };
14104
+ });
14105
+ if (!rowChanged) return row;
14106
+ tableChanged = true;
14107
+ return { ...row, cells: nextCells };
14095
14108
  });
14096
- if (!cellChanged) return cell;
14097
- rowChanged = true;
14098
- return { ...cell, blocks: nextCellBlocks };
14099
- });
14100
- if (!rowChanged) return row;
14101
- tableChanged = true;
14102
- return { ...row, cells: nextCells };
14103
- });
14104
- if (!tableChanged) return block;
14105
- blockChanged = true;
14106
- return { ...block, rows: nextRows };
14109
+ if (!tableChanged) return block;
14110
+ blockChanged = true;
14111
+ return { ...block, rows: nextRows };
14112
+ }
14113
+ default:
14114
+ return assertNever(block, "block");
14115
+ }
14107
14116
  });
14108
14117
  if (!blockChanged) return blocks;
14109
14118
  mutatedSections = true;
@@ -14232,32 +14241,38 @@ function renumberEndnotes(document2) {
14232
14241
  if (!blocks) return blocks;
14233
14242
  let blockChanged = false;
14234
14243
  const nextBlocks = blocks.map((block) => {
14235
- if (block.type === "paragraph") {
14236
- const updated = rewriteParagraphMarkers(block, markerByEndnoteId);
14237
- if (updated !== block) blockChanged = true;
14238
- return updated;
14239
- }
14240
- let tableChanged = false;
14241
- const nextRows = block.rows.map((row) => {
14242
- let rowChanged = false;
14243
- const nextCells = row.cells.map((cell) => {
14244
- let cellChanged = false;
14245
- const nextCellBlocks = cell.blocks.map((p) => {
14246
- const updated = rewriteParagraphMarkers(p, markerByEndnoteId);
14247
- if (updated !== p) cellChanged = true;
14248
- return updated;
14244
+ switch (block.type) {
14245
+ case "paragraph": {
14246
+ const updated = rewriteParagraphMarkers(block, markerByEndnoteId);
14247
+ if (updated !== block) blockChanged = true;
14248
+ return updated;
14249
+ }
14250
+ case "table": {
14251
+ let tableChanged = false;
14252
+ const nextRows = block.rows.map((row) => {
14253
+ let rowChanged = false;
14254
+ const nextCells = row.cells.map((cell) => {
14255
+ let cellChanged = false;
14256
+ const nextCellBlocks = cell.blocks.map((p) => {
14257
+ const updated = rewriteParagraphMarkers(p, markerByEndnoteId);
14258
+ if (updated !== p) cellChanged = true;
14259
+ return updated;
14260
+ });
14261
+ if (!cellChanged) return cell;
14262
+ rowChanged = true;
14263
+ return { ...cell, blocks: nextCellBlocks };
14264
+ });
14265
+ if (!rowChanged) return row;
14266
+ tableChanged = true;
14267
+ return { ...row, cells: nextCells };
14249
14268
  });
14250
- if (!cellChanged) return cell;
14251
- rowChanged = true;
14252
- return { ...cell, blocks: nextCellBlocks };
14253
- });
14254
- if (!rowChanged) return row;
14255
- tableChanged = true;
14256
- return { ...row, cells: nextCells };
14257
- });
14258
- if (!tableChanged) return block;
14259
- blockChanged = true;
14260
- return { ...block, rows: nextRows };
14269
+ if (!tableChanged) return block;
14270
+ blockChanged = true;
14271
+ return { ...block, rows: nextRows };
14272
+ }
14273
+ default:
14274
+ return assertNever(block, "block");
14275
+ }
14261
14276
  });
14262
14277
  if (!blockChanged) return blocks;
14263
14278
  mutatedSections = true;
@@ -35612,7 +35627,7 @@ function importDocxInWorker(buffer, options = {}) {
35612
35627
  const worker = new Worker(
35613
35628
  new URL(
35614
35629
  /* @vite-ignore */
35615
- "" + new URL("assets/importDocxWorker-Bn1fun73.js", import.meta.url).href,
35630
+ "" + new URL("assets/importDocxWorker-CmygfpkG.js", import.meta.url).href,
35616
35631
  import.meta.url
35617
35632
  ),
35618
35633
  {
@@ -1,4 +1,4 @@
1
- import { b4, bX, bY, bZ, b_, b$, bm, c0, b5, b0, c1, c2, c3, b3, c4, a_, c5, c6, c7, c8, c9, bS, ca, cb, cc, cd, ce, cf, cg, ch, ci, cj, ck, br, cl, bR, cm, bZ as bZ2, c2 as c22, c4 as c42, cd as cd2, cf as cf2, ck as ck2, cn, b2, aZ, co, cp, cq, a$, cr, cs, b1 } from "./index-Ybd6l30Z.js";
1
+ import { b4, bX, bY, bZ, b_, b$, bm, c0, b5, b0, c1, c2, c3, b3, c4, a_, c5, c6, c7, c8, c9, bS, ca, cb, cc, cd, ce, cf, cg, ch, ci, cj, ck, br, cl, bR, cm, bZ as bZ2, c2 as c22, c4 as c42, cd as cd2, cf as cf2, ck as ck2, cn, b2, aZ, co, cp, cq, a$, cr, cs, b1 } from "./index-ByZZP8TQ.js";
2
2
  export {
3
3
  b4 as BalloonShell,
4
4
  bX as Button,