@threadlabs/looma 0.53.14 → 0.53.16

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/editor/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { O as __exportAll, _ as setReferenceDisplay, b as fileAttachmentSize, c as imageSourceUrls, g as referenceDisplay, h as getReferenceDisplay, l as mapImageSourceUrls, m as LoomaReferencePresentation, p as LoomaReference, u as normalizeImageSources, v as LoomaFileAttachment, x as LOOMA_CALLOUT_TONES, y as fileAttachmentAttrs } from "./chunks/expressmark.js";
1
+ import { S as LOOMA_CALLOUT_TONES, _ as referenceDisplay, b as fileAttachmentAttrs, c as imageSourceUrls, g as observeReferenceDisplay, h as getReferenceDisplay, k as __exportAll, l as mapImageSourceUrls, m as LoomaReferencePresentation, p as LoomaReference, u as normalizeImageSources, v as setReferenceDisplay, x as fileAttachmentSize, y as LoomaFileAttachment } from "./chunks/expressmark.js";
2
2
  import { i as TABLE_CELL_BACKGROUND_PRESETS, n as resolveTableCellAt, r as TABLE_CELL_BACKGROUND_OPTIONS, t as measureTableOverlayGeometry } from "./chunks/table-overlay.js";
3
3
  import "./ui.js";
4
4
  import { $ as LoomaFootnote, A as createLoomaMentionExtension, B as createImageMedia, C as getActiveTableCellBackground, D as createSiteRelativeLinks, E as LoomaSmartPaste, F as LoomaImage, G as normalizeTableOfContentsConfig, H as LoomaTableOfContents, I as LoomaInlineImage, J as LoomaTabs, K as tableOfContentsTree, L as isLoomaImageName, M as MAX_MENTION_RESULT_LIMIT, N as filterLoomaMentionItems, O as siteRelativeHref, P as normalizeMentionResultLimit, Q as LOOMA_FOOTNOTE_LABEL, R as normalizeImageDimension, S as getActiveTableCellAlignment, T as setActiveTableCellBackground, U as getTableOfContentsEntries, V as imageDeliveryAttributes, W as navigateTableOfContents, X as LoomaLinkDefinition, Y as LoomaLineBlock, Z as LOOMA_FOOTNOTE_INSERTED, _ as getDefaultEditorExtensions, a as NO_TABLE_CAPABILITIES, at as revealLoomaExpandAt, b as LoomaTableCell, c as handleTableAction, ct as normalizeLoomaChipColor, d as normalizeActiveTableColumnWidths, dt as LOOMA_ACTIVE_BLOCK_CLASS, et as LoomaFootnoteReference, f as shouldShowTextFormattingToolbar, ft as LOOMA_ACTIVE_BLOCK_TYPING_IDLE_MS, g as LoomaTableKit, h as selectedTableElement, i as getDefaultSlashCommands, it as LoomaExpand, j as DEFAULT_MENTION_RESULT_LIMIT, k as LoomaMentionSuggestionPluginKey, l as handleTableOverlayAction, lt as LoomaCallout, m as selectedTableCellElement, mt as LoomaActiveBlockPluginKey, n as createLoomaSlashCommandExtension, nt as LoomaFigcaption, o as focusTableOverlayTarget, ot as LOOMA_CHIP_COLORS, p as menuAnchorRect, pt as LoomaActiveBlock, q as LoomaTab, r as filterLoomaSlashCommands, rt as LoomaFigure, s as getActiveTableUiState, st as LoomaChip, t as LoomaSlashCommand, tt as findLoomaFootnote, u as insertTableAtRange, ut as LOOMA_ACTIVE_BLOCK_BLUR_GRACE_MS, v as getLoomaTableExtensions, w as setActiveTableCellAlignment, x as LoomaTableHeader, y as LoomaTable, z as normalizeImagePlacement } from "./chunks/extensions.js";
@@ -2579,6 +2579,7 @@ var A$4 = [
2579
2579
  "data-ui-button-state",
2580
2580
  "data-ui-button-prop-align",
2581
2581
  "data-ui-button-prop-disabled",
2582
+ "data-ui-button-prop-fit",
2582
2583
  "data-ui-button-prop-href",
2583
2584
  "data-ui-button-prop-interaction-tone",
2584
2585
  "data-ui-button-prop-interaction-variant",
@@ -2618,6 +2619,7 @@ var A$4 = [
2618
2619
  "data-ui-button-state",
2619
2620
  "data-ui-button-prop-align",
2620
2621
  "data-ui-button-prop-disabled",
2622
+ "data-ui-button-prop-fit",
2621
2623
  "data-ui-button-prop-href",
2622
2624
  "data-ui-button-prop-interaction-tone",
2623
2625
  "data-ui-button-prop-interaction-variant",
@@ -2655,6 +2657,7 @@ var A$4 = [
2655
2657
  "data-ui-button-state",
2656
2658
  "data-ui-button-prop-align",
2657
2659
  "data-ui-button-prop-disabled",
2660
+ "data-ui-button-prop-fit",
2658
2661
  "data-ui-button-prop-href",
2659
2662
  "data-ui-button-prop-interaction-tone",
2660
2663
  "data-ui-button-prop-interaction-variant",
@@ -2694,6 +2697,7 @@ var A$4 = [
2694
2697
  "data-ui-button-state",
2695
2698
  "data-ui-button-prop-align",
2696
2699
  "data-ui-button-prop-disabled",
2700
+ "data-ui-button-prop-fit",
2697
2701
  "data-ui-button-prop-href",
2698
2702
  "data-ui-button-prop-interaction-tone",
2699
2703
  "data-ui-button-prop-interaction-variant",
@@ -2748,6 +2752,14 @@ var D$18 = {
2748
2752
  j: 0,
2749
2753
  m: "b"
2750
2754
  },
2755
+ "fit": {
2756
+ "required": false,
2757
+ "default": false,
2758
+ c: checkBoolean,
2759
+ t: "boolean",
2760
+ j: 0,
2761
+ m: "b"
2762
+ },
2751
2763
  "href": {
2752
2764
  "required": false,
2753
2765
  c: checkString,
@@ -2936,6 +2948,7 @@ function createUiButton(options = {}, html) {
2936
2948
  const attributes = Object.fromEntries([...[], ...Object.entries(authoredAttributes)].filter(([name]) => ![
2937
2949
  "align",
2938
2950
  "disabled",
2951
+ "fit",
2939
2952
  "href",
2940
2953
  "interaction-tone",
2941
2954
  "interaction-variant",
@@ -2974,6 +2987,7 @@ function createUiButton(options = {}, html) {
2974
2987
  null,
2975
2988
  null,
2976
2989
  null,
2990
+ null,
2977
2991
  null
2978
2992
  ];
2979
2993
  let B = acceptProps(void 0, D$18, S$18.n, v, componentProps, [], html);
@@ -2985,22 +2999,23 @@ function createUiButton(options = {}, html) {
2985
2999
  }
2986
3000
  if (j === 3) return awaitInput(B, "align", true);
2987
3001
  if (j === 4) return awaitInput(B, "disabled", true);
2988
- if (j === 5) return awaitInput(B, "href", true);
2989
- if (j === 6) return awaitInput(B, "interactionTone", true);
2990
- if (j === 7) return awaitInput(B, "interactionVariant", true);
2991
- if (j === 8) return awaitInput(B, "loading", true);
2992
- if (j === 9) return awaitInput(B, "pending", true);
2993
- if (j === 10) return awaitInput(B, "preset", true);
2994
- if (j === 11) return awaitInput(B, "rel", true);
2995
- if (j === 12) return awaitInput(B, "selected", true);
2996
- if (j === 13) return awaitInput(B, "shape", true);
2997
- if (j === 14) return awaitInput(B, "size", true);
2998
- if (j === 15) return awaitInput(B, "square", true);
2999
- if (j === 16) return awaitInput(B, "stretch", true);
3000
- if (j === 17) return awaitInput(B, "target", true);
3001
- if (j === 18) return awaitInput(B, "tone", true);
3002
- if (j === 19) return awaitInput(B, "type", true);
3003
- if (j === 20) return awaitInput(B, "variant", true);
3002
+ if (j === 5) return awaitInput(B, "fit", true);
3003
+ if (j === 6) return awaitInput(B, "href", true);
3004
+ if (j === 7) return awaitInput(B, "interactionTone", true);
3005
+ if (j === 8) return awaitInput(B, "interactionVariant", true);
3006
+ if (j === 9) return awaitInput(B, "loading", true);
3007
+ if (j === 10) return awaitInput(B, "pending", true);
3008
+ if (j === 11) return awaitInput(B, "preset", true);
3009
+ if (j === 12) return awaitInput(B, "rel", true);
3010
+ if (j === 13) return awaitInput(B, "selected", true);
3011
+ if (j === 14) return awaitInput(B, "shape", true);
3012
+ if (j === 15) return awaitInput(B, "size", true);
3013
+ if (j === 16) return awaitInput(B, "square", true);
3014
+ if (j === 17) return awaitInput(B, "stretch", true);
3015
+ if (j === 18) return awaitInput(B, "target", true);
3016
+ if (j === 19) return awaitInput(B, "tone", true);
3017
+ if (j === 20) return awaitInput(B, "type", true);
3018
+ if (j === 21) return awaitInput(B, "variant", true);
3004
3019
  return v[j] === void 0 ? UNRESOLVED_INPUT : READY_INPUT;
3005
3020
  };
3006
3021
  const X = {
@@ -3013,12 +3028,12 @@ function createUiButton(options = {}, html) {
3013
3028
  const ke = [];
3014
3029
  const K = [
3015
3030
  () => readIndex({
3016
- "none": inputRead(v[20], inputStatus(20)),
3031
+ "none": inputRead(v[21], inputStatus(21)),
3017
3032
  "primary": "solid",
3018
3033
  "standard": "solid",
3019
3034
  "quiet": "ghost",
3020
3035
  "destructive": "solid"
3021
- }, inputRead(v[10], inputStatus(10))),
3036
+ }, inputRead(v[11], inputStatus(11))),
3022
3037
  () => readIndex(recordValue([
3023
3038
  "none",
3024
3039
  "primary",
@@ -3028,13 +3043,13 @@ function createUiButton(options = {}, html) {
3028
3043
  ], [
3029
3044
  readIndex({
3030
3045
  "true": "danger",
3031
- "false": inputRead(v[18], inputStatus(18))
3032
- }, textCall("concat", [equalValue(inputRead(v[20], inputStatus(20)), "danger")])),
3046
+ "false": inputRead(v[19], inputStatus(19))
3047
+ }, textCall("concat", [equalValue(inputRead(v[21], inputStatus(21)), "danger")])),
3033
3048
  "accent",
3034
3049
  "neutral",
3035
3050
  "neutral",
3036
3051
  "danger"
3037
- ]), inputRead(v[10], inputStatus(10))),
3052
+ ]), inputRead(v[11], inputStatus(11))),
3038
3053
  () => readIndex({
3039
3054
  "true": null,
3040
3055
  "false": readIndex({
@@ -3042,8 +3057,8 @@ function createUiButton(options = {}, html) {
3042
3057
  "outline": "outline",
3043
3058
  "solid": "solid",
3044
3059
  "ghost": "ghost"
3045
- }, inputRead(v[7], inputStatus(7)))
3046
- }, textCall("concat", [truthy(equalValue(inputRead(v[6], inputStatus(6)), "inherit")) && truthy(equalValue(inputRead(v[7], inputStatus(7)), "inherit"))]))
3060
+ }, inputRead(v[8], inputStatus(8)))
3061
+ }, textCall("concat", [truthy(equalValue(inputRead(v[7], inputStatus(7)), "inherit")) && truthy(equalValue(inputRead(v[8], inputStatus(8)), "inherit"))]))
3047
3062
  ];
3048
3063
  const g = (j) => {
3049
3064
  const i = j - 0;
@@ -3068,7 +3083,7 @@ function createUiButton(options = {}, html) {
3068
3083
  }
3069
3084
  return next;
3070
3085
  };
3071
- let a = truthy(equalValue(g(0), "card")) && truthy(equalValue(v[5], null, true)) ? 0 : truthy(equalValue(g(0), "card")) ? 1 : truthy(equalValue(v[5], null, true)) ? 2 : 3;
3086
+ let a = truthy(equalValue(g(0), "card")) && truthy(equalValue(v[6], null, true)) ? 0 : truthy(equalValue(g(0), "card")) ? 1 : truthy(equalValue(v[6], null, true)) ? 2 : 3;
3072
3087
  let element;
3073
3088
  if (a === 0) {
3074
3089
  element = document.createElement("a");
@@ -3243,7 +3258,7 @@ function createUiButton(options = {}, html) {
3243
3258
  return r;
3244
3259
  };
3245
3260
  const p0 = (r, c, d) => {
3246
- if (c & 1075191792) {
3261
+ if (c & 1076641744) {
3247
3262
  resetForwardedAttributes(r.n, attributes, r.v0);
3248
3263
  r.v0 = forwardAttributes(r.n, attributes);
3249
3264
  const x0 = g(0);
@@ -3257,8 +3272,8 @@ function createUiButton(options = {}, html) {
3257
3272
  }
3258
3273
  const x2 = readIndex({
3259
3274
  "true": null,
3260
- "false": v[6]
3261
- }, textCall("concat", [equalValue(v[6], "inherit")]));
3275
+ "false": v[7]
3276
+ }, textCall("concat", [equalValue(v[7], "inherit")]));
3262
3277
  if (x2 !== NONCONFORMING) r.g3 = x2;
3263
3278
  if (r.g3 !== NONCONFORMING) {
3264
3279
  const s3 = toAttribute(r.g3, "data-interaction-tone");
@@ -3270,67 +3285,69 @@ function createUiButton(options = {}, html) {
3270
3285
  const s4 = toAttribute(r.g4, "data-interaction-appearance");
3271
3286
  writeAttribute(r.n, "data-interaction-appearance", r.v4 = s4);
3272
3287
  }
3273
- const x4 = v[12];
3288
+ const x4 = v[13];
3274
3289
  const s5 = toAttribute(x4, "data-selected");
3275
3290
  writeAttribute(r.n, "data-selected", r.v5 = s5);
3276
3291
  const x5 = readIndex({
3277
3292
  "true": null,
3278
- "false": v[5]
3279
- }, textCall("concat", [truthy(v[4]) || truthy(v[8]) || truthy(v[9])]));
3293
+ "false": v[6]
3294
+ }, textCall("concat", [truthy(v[4]) || truthy(v[9]) || truthy(v[10])]));
3280
3295
  if (x5 !== NONCONFORMING) r.g6 = x5;
3281
3296
  if (r.g6 !== NONCONFORMING) {
3282
3297
  const s6 = toAttribute(r.g6, "href");
3283
3298
  writeUrlAttribute(r.n, "href", r.v6 = s6);
3284
3299
  }
3285
- const x6 = v[17];
3300
+ const x6 = v[18];
3286
3301
  const s7 = toAttribute(x6, "target");
3287
3302
  writeAttribute(r.n, "target", r.v7 = s7);
3288
- const x7 = v[11];
3303
+ const x7 = v[12];
3289
3304
  const s8 = toAttribute(x7, "rel");
3290
3305
  writeAttribute(r.n, "rel", r.v8 = s8);
3291
3306
  const x8 = readIndex({
3292
3307
  "true": "true",
3293
3308
  "false": null
3294
- }, textCall("concat", [truthy(v[4]) || truthy(v[8]) || truthy(v[9])]));
3309
+ }, textCall("concat", [truthy(v[4]) || truthy(v[9]) || truthy(v[10])]));
3295
3310
  if (x8 !== NONCONFORMING) r.g9 = x8;
3296
3311
  if (r.g9 !== NONCONFORMING) {
3297
3312
  const s9 = toAttribute(r.g9, "aria-disabled");
3298
3313
  writeAttribute(r.n, "aria-disabled", r.v9 = s9);
3299
3314
  }
3300
- const x9 = truthy(v[8]) || truthy(v[9]);
3315
+ const x9 = truthy(v[9]) || truthy(v[10]);
3301
3316
  const s10 = toAttribute(x9, "aria-busy");
3302
3317
  writeAttribute(r.n, "aria-busy", r.v10 = s10);
3303
3318
  const x10 = readIndex({
3304
3319
  "true": "0",
3305
3320
  "false": null
3306
- }, textCall("concat", [(truthy(v[8]) || truthy(v[9])) && !truthy(v[4])]));
3321
+ }, textCall("concat", [(truthy(v[9]) || truthy(v[10])) && !truthy(v[4])]));
3307
3322
  if (x10 !== NONCONFORMING) r.g11 = x10;
3308
3323
  if (r.g11 !== NONCONFORMING) {
3309
3324
  const s11 = toAttribute(r.g11, "tabindex");
3310
3325
  writeAttribute(r.n, "tabindex", r.v11 = s11);
3311
3326
  }
3312
3327
  }
3313
- if (c & 123656) {
3328
+ if (c & 247336) {
3314
3329
  const s12 = hostState([
3315
3330
  "align",
3316
3331
  "stretch",
3317
3332
  "size",
3318
3333
  "shape",
3319
3334
  "square",
3335
+ "fit",
3320
3336
  "loading",
3321
3337
  "pending"
3322
3338
  ], [
3323
3339
  v[3],
3324
- v[16],
3325
- v[14],
3326
- v[13],
3340
+ v[17],
3327
3341
  v[15],
3328
- v[8],
3329
- v[9]
3342
+ v[14],
3343
+ v[16],
3344
+ v[5],
3345
+ v[9],
3346
+ v[10]
3330
3347
  ]);
3331
3348
  if (s12 !== r.v12) writeAttribute(r.n, "data-ui-button-state", (r.v12 = s12) === "" ? null : s12);
3332
3349
  }
3333
- if (c & 768 && !(truthy(v[8]) || truthy(v[9])) !== !r.b0) {
3350
+ if (c & 1536 && !(truthy(v[9]) || truthy(v[10])) !== !r.b0) {
3334
3351
  if (r.b0) {
3335
3352
  r.b0 = void 0;
3336
3353
  clearRegion(r.a1, r.e0);
@@ -3339,7 +3356,7 @@ function createUiButton(options = {}, html) {
3339
3356
  r.e0.before(r.b0.n);
3340
3357
  }
3341
3358
  } else if (r.b0 !== void 0) r.b0;
3342
- if (c & 768 && !!(truthy(v[8]) || truthy(v[9])) !== !r.b1) {
3359
+ if (c & 1536 && !!(truthy(v[9]) || truthy(v[10])) !== !r.b1) {
3343
3360
  if (r.b1) {
3344
3361
  dispose(r.b1);
3345
3362
  r.b1 = void 0;
@@ -3423,7 +3440,7 @@ function createUiButton(options = {}, html) {
3423
3440
  return r;
3424
3441
  };
3425
3442
  const p6 = (r, c, d) => {
3426
- if (c & 1075582928) {
3443
+ if (c & 1077424016) {
3427
3444
  resetForwardedAttributes(r.n, attributes, r.v0);
3428
3445
  r.v0 = forwardAttributes(r.n, attributes);
3429
3446
  const x0 = g(0);
@@ -3437,8 +3454,8 @@ function createUiButton(options = {}, html) {
3437
3454
  }
3438
3455
  const x2 = readIndex({
3439
3456
  "true": null,
3440
- "false": v[6]
3441
- }, textCall("concat", [equalValue(v[6], "inherit")]));
3457
+ "false": v[7]
3458
+ }, textCall("concat", [equalValue(v[7], "inherit")]));
3442
3459
  if (x2 !== NONCONFORMING) r.g3 = x2;
3443
3460
  if (r.g3 !== NONCONFORMING) {
3444
3461
  const s3 = toAttribute(r.g3, "data-interaction-tone");
@@ -3450,10 +3467,10 @@ function createUiButton(options = {}, html) {
3450
3467
  const s4 = toAttribute(r.g4, "data-interaction-appearance");
3451
3468
  writeAttribute(r.n, "data-interaction-appearance", r.v4 = s4);
3452
3469
  }
3453
- const x4 = v[12];
3470
+ const x4 = v[13];
3454
3471
  const s5 = toAttribute(x4, "data-selected");
3455
3472
  writeAttribute(r.n, "data-selected", r.v5 = s5);
3456
- const x5 = v[19];
3473
+ const x5 = v[20];
3457
3474
  const s6 = toAttribute(x5, "type");
3458
3475
  writeAttribute(r.n, "type", r.v6 = s6);
3459
3476
  const x6 = v[4];
@@ -3462,37 +3479,39 @@ function createUiButton(options = {}, html) {
3462
3479
  const x7 = readIndex({
3463
3480
  "true": "true",
3464
3481
  "false": null
3465
- }, textCall("concat", [truthy(v[8]) || truthy(v[9])]));
3482
+ }, textCall("concat", [truthy(v[9]) || truthy(v[10])]));
3466
3483
  if (x7 !== NONCONFORMING) r.g8 = x7;
3467
3484
  if (r.g8 !== NONCONFORMING) {
3468
3485
  const s8 = toAttribute(r.g8, "aria-disabled");
3469
3486
  writeAttribute(r.n, "aria-disabled", r.v8 = s8);
3470
3487
  }
3471
- const x8 = truthy(v[8]) || truthy(v[9]);
3488
+ const x8 = truthy(v[9]) || truthy(v[10]);
3472
3489
  const s9 = toAttribute(x8, "aria-busy");
3473
3490
  writeAttribute(r.n, "aria-busy", r.v9 = s9);
3474
3491
  }
3475
- if (c & 123656) {
3492
+ if (c & 247336) {
3476
3493
  const s10 = hostState([
3477
3494
  "align",
3478
3495
  "stretch",
3479
3496
  "size",
3480
3497
  "shape",
3481
3498
  "square",
3499
+ "fit",
3482
3500
  "loading",
3483
3501
  "pending"
3484
3502
  ], [
3485
3503
  v[3],
3486
- v[16],
3487
- v[14],
3488
- v[13],
3504
+ v[17],
3489
3505
  v[15],
3490
- v[8],
3491
- v[9]
3506
+ v[14],
3507
+ v[16],
3508
+ v[5],
3509
+ v[9],
3510
+ v[10]
3492
3511
  ]);
3493
3512
  if (s10 !== r.v10) writeAttribute(r.n, "data-ui-button-state", (r.v10 = s10) === "" ? null : s10);
3494
3513
  }
3495
- if (c & 768 && !(truthy(v[8]) || truthy(v[9])) !== !r.b0) {
3514
+ if (c & 1536 && !(truthy(v[9]) || truthy(v[10])) !== !r.b0) {
3496
3515
  if (r.b0) {
3497
3516
  r.b0 = void 0;
3498
3517
  clearRegion(r.a1, r.e0);
@@ -3501,7 +3520,7 @@ function createUiButton(options = {}, html) {
3501
3520
  r.e0.before(r.b0.n);
3502
3521
  }
3503
3522
  } else if (r.b0 !== void 0) r.b0;
3504
- if (c & 768 && !!(truthy(v[8]) || truthy(v[9])) !== !r.b1) {
3523
+ if (c & 1536 && !!(truthy(v[9]) || truthy(v[10])) !== !r.b1) {
3505
3524
  if (r.b1) {
3506
3525
  dispose(r.b1);
3507
3526
  r.b1 = void 0;
@@ -3583,7 +3602,7 @@ function createUiButton(options = {}, html) {
3583
3602
  return r;
3584
3603
  };
3585
3604
  const p12 = (r, c, d) => {
3586
- if (c & 1075191792) {
3605
+ if (c & 1076641744) {
3587
3606
  resetForwardedAttributes(r.n, attributes, r.v0);
3588
3607
  r.v0 = forwardAttributes(r.n, attributes);
3589
3608
  const x0 = g(0);
@@ -3597,8 +3616,8 @@ function createUiButton(options = {}, html) {
3597
3616
  }
3598
3617
  const x2 = readIndex({
3599
3618
  "true": null,
3600
- "false": v[6]
3601
- }, textCall("concat", [equalValue(v[6], "inherit")]));
3619
+ "false": v[7]
3620
+ }, textCall("concat", [equalValue(v[7], "inherit")]));
3602
3621
  if (x2 !== NONCONFORMING) r.g3 = x2;
3603
3622
  if (r.g3 !== NONCONFORMING) {
3604
3623
  const s3 = toAttribute(r.g3, "data-interaction-tone");
@@ -3610,67 +3629,69 @@ function createUiButton(options = {}, html) {
3610
3629
  const s4 = toAttribute(r.g4, "data-interaction-appearance");
3611
3630
  writeAttribute(r.n, "data-interaction-appearance", r.v4 = s4);
3612
3631
  }
3613
- const x4 = v[12];
3632
+ const x4 = v[13];
3614
3633
  const s5 = toAttribute(x4, "data-selected");
3615
3634
  writeAttribute(r.n, "data-selected", r.v5 = s5);
3616
3635
  const x5 = readIndex({
3617
3636
  "true": null,
3618
- "false": v[5]
3619
- }, textCall("concat", [truthy(v[4]) || truthy(v[8]) || truthy(v[9])]));
3637
+ "false": v[6]
3638
+ }, textCall("concat", [truthy(v[4]) || truthy(v[9]) || truthy(v[10])]));
3620
3639
  if (x5 !== NONCONFORMING) r.g6 = x5;
3621
3640
  if (r.g6 !== NONCONFORMING) {
3622
3641
  const s6 = toAttribute(r.g6, "href");
3623
3642
  writeUrlAttribute(r.n, "href", r.v6 = s6);
3624
3643
  }
3625
- const x6 = v[17];
3644
+ const x6 = v[18];
3626
3645
  const s7 = toAttribute(x6, "target");
3627
3646
  writeAttribute(r.n, "target", r.v7 = s7);
3628
- const x7 = v[11];
3647
+ const x7 = v[12];
3629
3648
  const s8 = toAttribute(x7, "rel");
3630
3649
  writeAttribute(r.n, "rel", r.v8 = s8);
3631
3650
  const x8 = readIndex({
3632
3651
  "true": "true",
3633
3652
  "false": null
3634
- }, textCall("concat", [truthy(v[4]) || truthy(v[8]) || truthy(v[9])]));
3653
+ }, textCall("concat", [truthy(v[4]) || truthy(v[9]) || truthy(v[10])]));
3635
3654
  if (x8 !== NONCONFORMING) r.g9 = x8;
3636
3655
  if (r.g9 !== NONCONFORMING) {
3637
3656
  const s9 = toAttribute(r.g9, "aria-disabled");
3638
3657
  writeAttribute(r.n, "aria-disabled", r.v9 = s9);
3639
3658
  }
3640
- const x9 = truthy(v[8]) || truthy(v[9]);
3659
+ const x9 = truthy(v[9]) || truthy(v[10]);
3641
3660
  const s10 = toAttribute(x9, "aria-busy");
3642
3661
  writeAttribute(r.n, "aria-busy", r.v10 = s10);
3643
3662
  const x10 = readIndex({
3644
3663
  "true": "0",
3645
3664
  "false": null
3646
- }, textCall("concat", [(truthy(v[8]) || truthy(v[9])) && !truthy(v[4])]));
3665
+ }, textCall("concat", [(truthy(v[9]) || truthy(v[10])) && !truthy(v[4])]));
3647
3666
  if (x10 !== NONCONFORMING) r.g11 = x10;
3648
3667
  if (r.g11 !== NONCONFORMING) {
3649
3668
  const s11 = toAttribute(r.g11, "tabindex");
3650
3669
  writeAttribute(r.n, "tabindex", r.v11 = s11);
3651
3670
  }
3652
3671
  }
3653
- if (c & 123656) {
3672
+ if (c & 247336) {
3654
3673
  const s12 = hostState([
3655
3674
  "align",
3656
3675
  "stretch",
3657
3676
  "size",
3658
3677
  "shape",
3659
3678
  "square",
3679
+ "fit",
3660
3680
  "loading",
3661
3681
  "pending"
3662
3682
  ], [
3663
3683
  v[3],
3664
- v[16],
3665
- v[14],
3666
- v[13],
3684
+ v[17],
3667
3685
  v[15],
3668
- v[8],
3669
- v[9]
3686
+ v[14],
3687
+ v[16],
3688
+ v[5],
3689
+ v[9],
3690
+ v[10]
3670
3691
  ]);
3671
3692
  if (s12 !== r.v12) writeAttribute(r.n, "data-ui-button-state", (r.v12 = s12) === "" ? null : s12);
3672
3693
  }
3673
- if (c & 768 && !(truthy(v[8]) || truthy(v[9])) !== !r.b0) {
3694
+ if (c & 1536 && !(truthy(v[9]) || truthy(v[10])) !== !r.b0) {
3674
3695
  if (r.b0) {
3675
3696
  r.b0 = void 0;
3676
3697
  clearRegion(r.a1, r.e0);
@@ -3747,7 +3768,7 @@ function createUiButton(options = {}, html) {
3747
3768
  return r;
3748
3769
  };
3749
3770
  const p16 = (r, c, d) => {
3750
- if (c & 1075582928) {
3771
+ if (c & 1077424016) {
3751
3772
  resetForwardedAttributes(r.n, attributes, r.v0);
3752
3773
  r.v0 = forwardAttributes(r.n, attributes);
3753
3774
  const x0 = g(0);
@@ -3761,8 +3782,8 @@ function createUiButton(options = {}, html) {
3761
3782
  }
3762
3783
  const x2 = readIndex({
3763
3784
  "true": null,
3764
- "false": v[6]
3765
- }, textCall("concat", [equalValue(v[6], "inherit")]));
3785
+ "false": v[7]
3786
+ }, textCall("concat", [equalValue(v[7], "inherit")]));
3766
3787
  if (x2 !== NONCONFORMING) r.g3 = x2;
3767
3788
  if (r.g3 !== NONCONFORMING) {
3768
3789
  const s3 = toAttribute(r.g3, "data-interaction-tone");
@@ -3774,10 +3795,10 @@ function createUiButton(options = {}, html) {
3774
3795
  const s4 = toAttribute(r.g4, "data-interaction-appearance");
3775
3796
  writeAttribute(r.n, "data-interaction-appearance", r.v4 = s4);
3776
3797
  }
3777
- const x4 = v[12];
3798
+ const x4 = v[13];
3778
3799
  const s5 = toAttribute(x4, "data-selected");
3779
3800
  writeAttribute(r.n, "data-selected", r.v5 = s5);
3780
- const x5 = v[19];
3801
+ const x5 = v[20];
3781
3802
  const s6 = toAttribute(x5, "type");
3782
3803
  writeAttribute(r.n, "type", r.v6 = s6);
3783
3804
  const x6 = v[4];
@@ -3786,37 +3807,39 @@ function createUiButton(options = {}, html) {
3786
3807
  const x7 = readIndex({
3787
3808
  "true": "true",
3788
3809
  "false": null
3789
- }, textCall("concat", [truthy(v[8]) || truthy(v[9])]));
3810
+ }, textCall("concat", [truthy(v[9]) || truthy(v[10])]));
3790
3811
  if (x7 !== NONCONFORMING) r.g8 = x7;
3791
3812
  if (r.g8 !== NONCONFORMING) {
3792
3813
  const s8 = toAttribute(r.g8, "aria-disabled");
3793
3814
  writeAttribute(r.n, "aria-disabled", r.v8 = s8);
3794
3815
  }
3795
- const x8 = truthy(v[8]) || truthy(v[9]);
3816
+ const x8 = truthy(v[9]) || truthy(v[10]);
3796
3817
  const s9 = toAttribute(x8, "aria-busy");
3797
3818
  writeAttribute(r.n, "aria-busy", r.v9 = s9);
3798
3819
  }
3799
- if (c & 123656) {
3820
+ if (c & 247336) {
3800
3821
  const s10 = hostState([
3801
3822
  "align",
3802
3823
  "stretch",
3803
3824
  "size",
3804
3825
  "shape",
3805
3826
  "square",
3827
+ "fit",
3806
3828
  "loading",
3807
3829
  "pending"
3808
3830
  ], [
3809
3831
  v[3],
3810
- v[16],
3811
- v[14],
3812
- v[13],
3832
+ v[17],
3813
3833
  v[15],
3814
- v[8],
3815
- v[9]
3834
+ v[14],
3835
+ v[16],
3836
+ v[5],
3837
+ v[9],
3838
+ v[10]
3816
3839
  ]);
3817
3840
  if (s10 !== r.v10) writeAttribute(r.n, "data-ui-button-state", (r.v10 = s10) === "" ? null : s10);
3818
3841
  }
3819
- if (c & 768 && !(truthy(v[8]) || truthy(v[9])) !== !r.b0) {
3842
+ if (c & 1536 && !(truthy(v[9]) || truthy(v[10])) !== !r.b0) {
3820
3843
  if (r.b0) {
3821
3844
  r.b0 = void 0;
3822
3845
  clearRegion(r.a1, r.e0);
@@ -3872,8 +3895,8 @@ function createUiButton(options = {}, html) {
3872
3895
  R = M[a](element, d);
3873
3896
  return;
3874
3897
  }
3875
- if (c & 1074791456) {
3876
- const t = truthy(equalValue(g(0), "card")) && truthy(equalValue(v[5], null, true)) ? 0 : truthy(equalValue(g(0), "card")) ? 1 : truthy(equalValue(v[5], null, true)) ? 2 : 3;
3898
+ if (c & 1075841088) {
3899
+ const t = truthy(equalValue(g(0), "card")) && truthy(equalValue(v[6], null, true)) ? 0 : truthy(equalValue(g(0), "card")) ? 1 : truthy(equalValue(v[6], null, true)) ? 2 : 3;
3877
3900
  if (t !== a) {
3878
3901
  dispose(R);
3879
3902
  for (const key in I.r) delete I.r[key];
@@ -3907,6 +3930,7 @@ function createUiButton(options = {}, html) {
3907
3930
  defineComponent("ui-button", createUiButton, [
3908
3931
  "align",
3909
3932
  "disabled",
3933
+ "fit",
3910
3934
  "href",
3911
3935
  "interactionTone",
3912
3936
  "interactionVariant",
@@ -11948,14 +11972,14 @@ var tableOfContentsNodeView = ({ editor, node, getPos }) => {
11948
11972
  };
11949
11973
  //#endregion
11950
11974
  //#region src/editor/heading-link.ts
11951
- var sequence = 0;
11975
+ var sequence$1 = 0;
11952
11976
  /**
11953
11977
  * Copy affordance for an existing heading anchor.
11954
11978
  * @ownership The caller appends `dom` beside heading content and calls `destroy` on removal.
11955
11979
  * The current ID and page URL are read at activation, so edits and client navigation cannot leave a stale link.
11956
11980
  */
11957
11981
  function createHeadingLink(heading) {
11958
- const id = `looma-heading-link-${++sequence}`;
11982
+ const id = `looma-heading-link-${++sequence$1}`;
11959
11983
  const icon = element(createUiIcon({
11960
11984
  name: "link",
11961
11985
  attributes: { "aria-hidden": "true" }
@@ -14119,75 +14143,207 @@ var dividerNodeView = ({ editor, getPos }) => {
14119
14143
  };
14120
14144
  };
14121
14145
  //#endregion
14146
+ //#region src/editor/file-deletions.ts
14147
+ /** Remove an authored reference without changing the original file's availability. */
14148
+ function removeFileBlock(editor, position) {
14149
+ if (editor.isDestroyed || !editor.isEditable) return;
14150
+ const at = position();
14151
+ if (at === void 0) return;
14152
+ const original = editor.state.doc.nodeAt(at);
14153
+ if (original?.type.name !== "loomaFileAttachment") return;
14154
+ editor.view.dispatch(closeHistory(editor.state.tr).delete(at, at + original.nodeSize));
14155
+ editor.view.focus();
14156
+ }
14157
+ /** Remove one block optimistically; retain a mapped rollback anchor while transport runs. */
14158
+ async function deleteFileBlock(editor, position, file, services) {
14159
+ if (!services.enabled() || editor.isDestroyed || !editor.isEditable) return;
14160
+ const controller = new AbortController();
14161
+ const cancel = () => controller.abort();
14162
+ editor.on("destroy", cancel);
14163
+ let restore, unwatch;
14164
+ try {
14165
+ if (!await services.confirm(file, controller.signal) || controller.signal.aborted || editor.isDestroyed || !editor.isEditable) return;
14166
+ const at = position();
14167
+ if (at === void 0) return;
14168
+ const original = editor.state.doc.nodeAt(at);
14169
+ if (original?.type.name !== "loomaFileAttachment" || original.attrs.href !== file.href) return;
14170
+ editor.view.dispatch(closeHistory(editor.state.tr));
14171
+ editor.view.dispatch(editor.state.tr.delete(at, at + original.nodeSize));
14172
+ let anchor = at, valid = true;
14173
+ const map = ({ transaction }) => {
14174
+ const next = transaction.mapping.mapResult(anchor, -1);
14175
+ if (next.deletedAcross) valid = false;
14176
+ anchor = next.pos;
14177
+ };
14178
+ editor.on("transaction", map);
14179
+ unwatch = () => editor.off("transaction", map);
14180
+ restore = () => {
14181
+ if (valid && !editor.isDestroyed) editor.view.dispatch(editor.state.tr.insert(anchor, original).setMeta("addToHistory", false));
14182
+ };
14183
+ if (!await services.remove(file, controller.signal)) throw new Error("The file was not deleted. Please retry.");
14184
+ restore = void 0;
14185
+ if (!editor.isDestroyed) {
14186
+ setReferenceDisplay(editor, {
14187
+ ...getReferenceDisplay(editor),
14188
+ [`attachment:${file.href}`]: {
14189
+ label: file.name,
14190
+ status: "deleted",
14191
+ deletable: false
14192
+ }
14193
+ });
14194
+ editor.view.dispatch(closeHistory(editor.state.tr));
14195
+ }
14196
+ } catch (error) {
14197
+ unwatch?.();
14198
+ unwatch = void 0;
14199
+ restore?.();
14200
+ if (!controller.signal.aborted) services.onError(error, file);
14201
+ } finally {
14202
+ unwatch?.();
14203
+ editor.off("destroy", cancel);
14204
+ }
14205
+ }
14206
+ //#endregion
14122
14207
  //#region src/editor/node-views/file-attachment.ts
14123
- /** A whole-card native link, with decorative SVGs and authored filename/size. No nested action. */
14124
- var fileAttachmentNodeView = ({ node }) => {
14125
- const metadata = (attrs) => {
14208
+ var sequence = 0;
14209
+ /** A compact file link with an editable reference action and optional original deletion. */
14210
+ var createFileAttachmentNodeView = (services) => ({ node, editor, getPos }) => {
14211
+ let current = node, pending = false;
14212
+ const metadata = () => {
14126
14213
  try {
14127
- return fileAttachmentAttrs(attrs);
14214
+ return fileAttachmentAttrs(current.attrs);
14128
14215
  } catch {
14129
14216
  return null;
14130
14217
  }
14131
14218
  };
14132
- const a = metadata(node.attrs);
14133
- const name = document.createTextNode(a?.name ?? "Unavailable attachment"), size = document.createTextNode(a ? fileAttachmentSize(a.size) : "");
14134
- const dom = createUiButton({
14219
+ const deletesOriginal = () => {
14220
+ const a = metadata(), display = a ? getReferenceDisplay(editor)[`attachment:${a.href}`] : void 0;
14221
+ return Boolean(a && services.enabled() && display?.status !== "deleted" && display?.status !== "pending" && display?.deletable !== false);
14222
+ };
14223
+ const name = document.createTextNode(""), size = document.createTextNode("");
14224
+ const download = createUiIcon({
14225
+ name: "download",
14226
+ tone: "muted",
14227
+ attributes: { "aria-hidden": "true" }
14228
+ });
14229
+ const card = createUiButton({
14135
14230
  variant: "card",
14136
14231
  tone: "neutral",
14137
- href: a?.href ?? "",
14138
- disabled: !a,
14232
+ size: "sm",
14233
+ fit: true,
14234
+ href: "",
14139
14235
  target: "_blank",
14140
14236
  rel: "noopener noreferrer",
14141
- attributes: {
14142
- contenteditable: "false",
14143
- "data-looma-file-attachment": ""
14144
- },
14237
+ attributes: { "data-looma-file-attachment": "" },
14145
14238
  slots: {
14146
14239
  icon: [createUiIcon({
14147
14240
  name: "file",
14148
14241
  tone: "secondary",
14149
14242
  attributes: { "aria-hidden": "true" }
14150
14243
  })],
14151
- action: [createUiIcon({
14152
- name: "download",
14153
- tone: "secondary",
14154
- attributes: { "aria-hidden": "true" }
14155
- })]
14244
+ action: [download]
14156
14245
  },
14157
14246
  children: [createUiStack({
14158
- gap: "xs",
14247
+ gap: "none",
14159
14248
  children: [createUiText({
14160
14249
  as: "span",
14161
- tone: "default",
14162
14250
  weight: "medium",
14163
14251
  wrap: "anywhere",
14252
+ attributes: { "data-looma-file-name": "" },
14164
14253
  children: [name]
14165
14254
  }), createUiText({
14166
14255
  as: "span",
14167
- size: "sm",
14168
- tone: "secondary",
14256
+ size: "xs",
14257
+ tone: "muted",
14258
+ attributes: { "data-looma-file-size": "" },
14169
14259
  children: [size]
14170
14260
  })]
14171
14261
  })]
14172
14262
  });
14263
+ const id = `looma-file-delete-${++sequence}`;
14264
+ const trash = createUiIconButton({
14265
+ label: "Delete file",
14266
+ variant: "ghost",
14267
+ tone: "neutral",
14268
+ size: "xs",
14269
+ attributes: {
14270
+ id,
14271
+ "data-looma-file-delete": ""
14272
+ },
14273
+ children: [createUiIcon({
14274
+ name: "trash",
14275
+ tone: "muted",
14276
+ attributes: { "aria-hidden": "true" }
14277
+ })]
14278
+ });
14279
+ trash.addEventListener("click", async () => {
14280
+ if (!deletesOriginal()) {
14281
+ removeFileBlock(editor, getPos);
14282
+ return;
14283
+ }
14284
+ const a = metadata();
14285
+ if (!a || pending) return;
14286
+ pending = true;
14287
+ render();
14288
+ try {
14289
+ await deleteFileBlock(editor, getPos, a, services);
14290
+ } finally {
14291
+ pending = false;
14292
+ render();
14293
+ }
14294
+ });
14295
+ const tooltip = document.createTextNode("");
14296
+ const dom = createUiCluster({
14297
+ padding: "s",
14298
+ gap: "xs",
14299
+ wrap: "nowrap",
14300
+ attributes: {
14301
+ contenteditable: "false",
14302
+ "data-looma-file-block": ""
14303
+ },
14304
+ children: [
14305
+ card,
14306
+ trash,
14307
+ createUiTooltip({
14308
+ for: id,
14309
+ children: [tooltip]
14310
+ })
14311
+ ]
14312
+ });
14313
+ const render = () => {
14314
+ const a = metadata(), display = a ? getReferenceDisplay(editor)[`attachment:${a.href}`] : void 0;
14315
+ const deleted = display?.status === "deleted";
14316
+ name.data = a ? `${a.name}${deleted ? " (deleted)" : ""}` : "Unavailable attachment";
14317
+ size.data = a ? fileAttachmentSize(a.size) : "";
14318
+ componentRegistry.update(card, {
14319
+ href: a?.href ?? "",
14320
+ disabled: !a || deleted || display?.status === "pending"
14321
+ });
14322
+ download.hidden = deleted;
14323
+ trash.hidden = !editor.isEditable;
14324
+ const deleteOriginal = deletesOriginal(), verb = deleteOriginal ? "Delete" : "Remove";
14325
+ tooltip.data = deleteOriginal ? "Delete file and remove reference" : "Remove attachment reference";
14326
+ componentRegistry.update(trash, {
14327
+ loading: pending,
14328
+ label: `${verb} ${a?.name ?? "unavailable attachment"}`
14329
+ });
14330
+ };
14331
+ const stop = observeReferenceDisplay(editor, render);
14332
+ render();
14173
14333
  return {
14174
14334
  dom,
14175
14335
  update(next) {
14176
- if (next.type !== node.type) return false;
14177
- const a = metadata(next.attrs);
14178
- name.data = a?.name ?? "Unavailable attachment";
14179
- size.data = a ? fileAttachmentSize(a.size) : "";
14180
- componentRegistry.update(dom, {
14181
- href: a?.href ?? "",
14182
- disabled: !a
14183
- });
14336
+ if (next.type !== current.type) return false;
14337
+ current = next;
14338
+ render();
14184
14339
  return true;
14185
14340
  },
14341
+ destroy: stop,
14186
14342
  selectNode() {
14187
- componentRegistry.update(dom, { selected: true });
14343
+ componentRegistry.update(card, { selected: true });
14188
14344
  },
14189
14345
  deselectNode() {
14190
- componentRegistry.update(dom, { selected: false });
14346
+ componentRegistry.update(card, { selected: false });
14191
14347
  },
14192
14348
  stopEvent: (event) => event.type === "click" || event.type === "keydown",
14193
14349
  ignoreMutation: () => true
@@ -15503,7 +15659,9 @@ var EDITOR_REQUEST_NAMES = [
15503
15659
  "link-search",
15504
15660
  "link-resolve",
15505
15661
  "image-upload",
15506
- "file-upload"
15662
+ "file-upload",
15663
+ "file-delete-confirm",
15664
+ "file-delete"
15507
15665
  ];
15508
15666
  var uploadProgressText = (progress, label = "Uploading image…") => progress && progress.total > 0 ? `${label} ${Math.round(Math.min(1, progress.loaded / progress.total) * 100)}%` : label;
15509
15667
  var editorInstanceSequence = 0;
@@ -15792,9 +15950,11 @@ function createDocumentEditorSession(props, options) {
15792
15950
  const arrived = (name) => current.has(name) && !responders.has(name);
15793
15951
  const extensionsArrived = arrived("extensions");
15794
15952
  const slashChanged = arrived("slash-commands") || current.has("image-upload") !== responders.has("image-upload") || current.has("file-upload") !== responders.has("file-upload");
15953
+ const fileDeletionChanged = current.has("file-delete") !== responders.has("file-delete") || current.has("file-delete-confirm") !== responders.has("file-delete-confirm");
15795
15954
  responders = current;
15796
15955
  if (extensionsArrived) askExtensions();
15797
15956
  if (slashChanged) askSlashCommands();
15957
+ if (fileDeletionChanged && uiState.editor) setReferenceDisplay(uiState.editor, { ...getReferenceDisplay(uiState.editor) });
15798
15958
  };
15799
15959
  afterRender(checkResponders);
15800
15960
  let stopAnnouncements;
@@ -15866,7 +16026,15 @@ function createDocumentEditorSession(props, options) {
15866
16026
  headingNodeView,
15867
16027
  expandNodeView,
15868
16028
  dividerNodeView,
15869
- fileAttachmentNodeView,
16029
+ fileAttachmentNodeView: createFileAttachmentNodeView({
16030
+ enabled: () => answers("file-delete") && answers("file-delete-confirm"),
16031
+ confirm: async (file, signal) => (await ask("file-delete-confirm", { file }, { signal }))?.confirmed === true,
16032
+ remove: async (file, signal) => (await ask("file-delete", { file }, { signal }))?.deleted === true,
16033
+ onError: (error, file) => emit("file-delete-error", {
16034
+ error,
16035
+ file
16036
+ })
16037
+ }),
15870
16038
  calloutNodeView,
15871
16039
  imageNodeView,
15872
16040
  inlineImageNodeView: imageNodeView
@@ -17354,4 +17522,4 @@ function createToolbarTooltip(onChange, delay = () => 400) {
17354
17522
  };
17355
17523
  }
17356
17524
  //#endregion
17357
- export { DEFAULT_MENTION_RESULT_LIMIT, LOOMA_ACTIVE_BLOCK_BLUR_GRACE_MS, LOOMA_ACTIVE_BLOCK_CLASS, LOOMA_ACTIVE_BLOCK_TYPING_IDLE_MS, LOOMA_CALLOUT_TONES, LOOMA_CHIP_COLORS, LOOMA_FOOTNOTE_LABEL, LOOMA_ICONS, LoomaActiveBlock, LoomaActiveBlockPluginKey, LoomaCallout, LoomaChip, LoomaExpand, LoomaFigcaption, LoomaFigure, LoomaFileAttachment, LoomaFootnote, LoomaFootnoteReference, LoomaImage, LoomaInlineImage, LoomaLineBlock, LoomaLinkDefinition, LoomaMentionSuggestionPluginKey, LoomaReference, LoomaReferencePresentation, LoomaSlashCommand, LoomaSmartPaste, LoomaTab, LoomaTable, LoomaTableCell, LoomaTableHeader, LoomaTableKit, LoomaTableOfContents, LoomaTabs, MAX_MENTION_RESULT_LIMIT, TABLE_CELL_BACKGROUND_OPTIONS, TABLE_CELL_BACKGROUND_PRESETS, createDocumentEditorSession, createLoomaMentionExtension, createLoomaSlashCommandExtension, createSiteRelativeLinks, createToolbarTooltip, filterLoomaMentionItems, filterLoomaSlashCommands, findLoomaFootnote, getActiveTableCellAlignment, getActiveTableCellBackground, getActiveTableUiState, getDefaultEditorExtensions, getDefaultSlashCommands, getLoomaTableExtensions, getReferenceDisplay, getTableOfContentsEntries, getVisualViewportRect, handleTableAction, handleTableOverlayAction, imageSourceUrls, insertTableAtRange, loomaIconMarkup, mapImageSourceUrls, measureTableOverlayGeometry, normalizeActiveTableColumnWidths, normalizeImageDimension, normalizeImagePlacement, normalizeImageSources, normalizeLoomaChipColor, normalizeMentionResultLimit, normalizeTableOfContentsConfig, referenceDisplay, resolveTableCellAt, revealLoomaExpandAt, setActiveTableCellAlignment, setActiveTableCellBackground, setReferenceDisplay, shouldShowTextFormattingToolbar, siteRelativeHref };
17525
+ export { DEFAULT_MENTION_RESULT_LIMIT, LOOMA_ACTIVE_BLOCK_BLUR_GRACE_MS, LOOMA_ACTIVE_BLOCK_CLASS, LOOMA_ACTIVE_BLOCK_TYPING_IDLE_MS, LOOMA_CALLOUT_TONES, LOOMA_CHIP_COLORS, LOOMA_FOOTNOTE_LABEL, LOOMA_ICONS, LoomaActiveBlock, LoomaActiveBlockPluginKey, LoomaCallout, LoomaChip, LoomaExpand, LoomaFigcaption, LoomaFigure, LoomaFileAttachment, LoomaFootnote, LoomaFootnoteReference, LoomaImage, LoomaInlineImage, LoomaLineBlock, LoomaLinkDefinition, LoomaMentionSuggestionPluginKey, LoomaReference, LoomaReferencePresentation, LoomaSlashCommand, LoomaSmartPaste, LoomaTab, LoomaTable, LoomaTableCell, LoomaTableHeader, LoomaTableKit, LoomaTableOfContents, LoomaTabs, MAX_MENTION_RESULT_LIMIT, TABLE_CELL_BACKGROUND_OPTIONS, TABLE_CELL_BACKGROUND_PRESETS, createDocumentEditorSession, createLoomaMentionExtension, createLoomaSlashCommandExtension, createSiteRelativeLinks, createToolbarTooltip, fileAttachmentSize, filterLoomaMentionItems, filterLoomaSlashCommands, findLoomaFootnote, getActiveTableCellAlignment, getActiveTableCellBackground, getActiveTableUiState, getDefaultEditorExtensions, getDefaultSlashCommands, getLoomaTableExtensions, getReferenceDisplay, getTableOfContentsEntries, getVisualViewportRect, handleTableAction, handleTableOverlayAction, imageSourceUrls, insertTableAtRange, loomaIconMarkup, mapImageSourceUrls, measureTableOverlayGeometry, normalizeActiveTableColumnWidths, normalizeImageDimension, normalizeImagePlacement, normalizeImageSources, normalizeLoomaChipColor, normalizeMentionResultLimit, normalizeTableOfContentsConfig, referenceDisplay, resolveTableCellAt, revealLoomaExpandAt, setActiveTableCellAlignment, setActiveTableCellBackground, setReferenceDisplay, shouldShowTextFormattingToolbar, siteRelativeHref };