@superdoc-dev/mcp 0.12.0 → 0.13.0

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.
Files changed (2) hide show
  1. package/dist/index.js +431 -163
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -52172,7 +52172,7 @@ var init_remark_gfm_BhnWr3yf_es = __esm(() => {
52172
52172
  emptyOptions2 = {};
52173
52173
  });
52174
52174
 
52175
- // ../../packages/superdoc/dist/chunks/SuperConverter-DAuqlmYY.es.js
52175
+ // ../../packages/superdoc/dist/chunks/SuperConverter-kHxKGgu-.es.js
52176
52176
  function getExtensionConfigField(extension$1, field, context = { name: "" }) {
52177
52177
  const fieldValue = extension$1.config[field];
52178
52178
  if (typeof fieldValue === "function")
@@ -52736,7 +52736,7 @@ function wsOptionsFor(type, preserveWhitespace, base$1) {
52736
52736
  return (preserveWhitespace ? OPT_PRESERVE_WS : 0) | (preserveWhitespace === "full" ? OPT_PRESERVE_WS_FULL : 0);
52737
52737
  return type && type.whitespace == "pre" ? OPT_PRESERVE_WS | OPT_PRESERVE_WS_FULL : base$1 & ~OPT_OPEN_LEFT;
52738
52738
  }
52739
- function normalizeList(dom) {
52739
+ function normalizeList$1(dom) {
52740
52740
  for (let child = dom.firstChild, prevItem = null;child; child = child.nextSibling) {
52741
52741
  let name = child.nodeType == 1 ? child.nodeName.toLowerCase() : null;
52742
52742
  if (name && listTags.hasOwnProperty(name) && prevItem) {
@@ -87043,7 +87043,105 @@ function familyWithFaces(name, license, faces) {
87043
87043
  faces
87044
87044
  };
87045
87045
  }
87046
- function normalizeFamilyKey$1(family$1) {
87046
+ function isBundledPackPresent() {
87047
+ return bundledPackPresent;
87048
+ }
87049
+ function withTrailingSlash(base$1) {
87050
+ return base$1.endsWith("/") ? base$1 : `${base$1}/`;
87051
+ }
87052
+ function joinUrl(base$1, file2) {
87053
+ return `${withTrailingSlash(base$1)}${file2}`;
87054
+ }
87055
+ function weightToken(weight) {
87056
+ return weight === "bold" ? "700" : "400";
87057
+ }
87058
+ function bundledAssetSignature(resolve) {
87059
+ const family$1 = BUNDLED_MANIFEST[0];
87060
+ const face = family$1?.faces[0];
87061
+ if (!family$1 || !face)
87062
+ return "";
87063
+ return resolve({
87064
+ file: face.file,
87065
+ family: family$1.family,
87066
+ weight: weightToken(face.weight),
87067
+ style: face.style,
87068
+ source: "bundled-substitute"
87069
+ });
87070
+ }
87071
+ function installBundledSubstitutes(registry2, options = {}) {
87072
+ const resolve = options.resolveAssetUrl ?? ((context) => joinUrl(options.assetBaseUrl ?? defaultAssetBase, context.file));
87073
+ const signature = bundledAssetSignature(resolve);
87074
+ const installed = installedRegistries.get(registry2);
87075
+ if (installed !== undefined) {
87076
+ if (installed !== signature)
87077
+ console.warn(`[superdoc] bundled fonts are already registered for this document from "${installed}"; a later fonts config resolving to "${signature}" is ignored. Use one fonts.assetBaseUrl / fonts.resolveAssetUrl per document.`);
87078
+ return;
87079
+ }
87080
+ installedRegistries.set(registry2, signature);
87081
+ for (const family$1 of BUNDLED_MANIFEST)
87082
+ for (const face of family$1.faces) {
87083
+ const context = {
87084
+ file: face.file,
87085
+ family: family$1.family,
87086
+ weight: weightToken(face.weight),
87087
+ style: face.style,
87088
+ source: "bundled-substitute"
87089
+ };
87090
+ registry2.register({
87091
+ family: family$1.family,
87092
+ source: `url(${resolve(context)})`,
87093
+ descriptors: {
87094
+ weight: face.weight,
87095
+ style: face.style
87096
+ }
87097
+ });
87098
+ }
87099
+ }
87100
+ function normalizeKey$1(family$1) {
87101
+ return family$1.trim().replace(/^["']|["']$/g, "").toLowerCase();
87102
+ }
87103
+ function normalizeList(families) {
87104
+ if (!Array.isArray(families))
87105
+ return;
87106
+ const out = [...new Set(families.filter((f2) => typeof f2 === "string").map(normalizeKey$1).filter(Boolean))].sort();
87107
+ return out.length > 0 ? out : undefined;
87108
+ }
87109
+ function createBundledActivation(input) {
87110
+ if (!input.packConfigured)
87111
+ return BASELINE_BUNDLED;
87112
+ const include = normalizeList(input.include);
87113
+ const exclude = include ? undefined : normalizeList(input.exclude);
87114
+ if (!include && !exclude)
87115
+ return FULLY_ACTIVE_BUNDLED;
87116
+ if (include) {
87117
+ const set$1 = new Set(include);
87118
+ return Object.freeze({
87119
+ packConfigured: true,
87120
+ isActive: (family$1) => set$1.has(normalizeKey$1(family$1)),
87121
+ signature: JSON.stringify({
87122
+ p: true,
87123
+ i: include
87124
+ })
87125
+ });
87126
+ }
87127
+ const set3 = new Set(exclude);
87128
+ return Object.freeze({
87129
+ packConfigured: true,
87130
+ isActive: (family$1) => !set3.has(normalizeKey$1(family$1)),
87131
+ signature: JSON.stringify({
87132
+ p: true,
87133
+ x: exclude
87134
+ })
87135
+ });
87136
+ }
87137
+ function deriveBundledActivation(config$43) {
87138
+ return createBundledActivation({
87139
+ packConfigured: !!(config$43?.resolveAssetUrl || config$43?.assetBaseUrl) || isBundledPackPresent(),
87140
+ include: config$43?.bundled?.include,
87141
+ exclude: config$43?.bundled?.exclude
87142
+ });
87143
+ }
87144
+ function normalizeFamilyKey$2(family$1) {
87047
87145
  return family$1.trim().replace(/^["']|["']$/g, "").toLowerCase();
87048
87146
  }
87049
87147
  function sortPairs(pairs) {
@@ -87122,7 +87220,7 @@ function deriveBundledSubstitutes() {
87122
87220
  for (const row of SUBSTITUTION_EVIDENCE) {
87123
87221
  const fallback = getRenderableFallback(row.logicalFamily, { canRenderFamily });
87124
87222
  if (fallback?.policyAction === "substitute")
87125
- substitutes[normalizeFamilyKey$1(row.logicalFamily)] = fallback.substituteFamily;
87223
+ substitutes[normalizeFamilyKey$2(row.logicalFamily)] = fallback.substituteFamily;
87126
87224
  }
87127
87225
  return Object.freeze(substitutes);
87128
87226
  }
@@ -87131,7 +87229,7 @@ function deriveCategoryFallbacks() {
87131
87229
  for (const row of SUBSTITUTION_EVIDENCE) {
87132
87230
  const fallback = getRenderableFallback(row.logicalFamily, { canRenderFamily });
87133
87231
  if (fallback?.policyAction === "category_fallback")
87134
- fallbacks[normalizeFamilyKey$1(row.logicalFamily)] = fallback.substituteFamily;
87232
+ fallbacks[normalizeFamilyKey$2(row.logicalFamily)] = fallback.substituteFamily;
87135
87233
  }
87136
87234
  return Object.freeze(fallbacks);
87137
87235
  }
@@ -87141,8 +87239,8 @@ function stripFamilyQuotes(family$1) {
87141
87239
  function splitStack(cssFontFamily) {
87142
87240
  return cssFontFamily.split(",").map((part) => part.trim()).filter(Boolean);
87143
87241
  }
87144
- function createFontResolver() {
87145
- return new FontResolver;
87242
+ function createFontResolver(activation) {
87243
+ return new FontResolver(activation);
87146
87244
  }
87147
87245
  function resolveFontFamily(logicalFamily) {
87148
87246
  return defaultResolver.resolveFontFamily(logicalFamily);
@@ -87159,57 +87257,6 @@ function getFontConfigVersion() {
87159
87257
  function bumpFontConfigVersion() {
87160
87258
  return fontConfigVersion += 1;
87161
87259
  }
87162
- function withTrailingSlash(base$1) {
87163
- return base$1.endsWith("/") ? base$1 : `${base$1}/`;
87164
- }
87165
- function joinUrl(base$1, file2) {
87166
- return `${withTrailingSlash(base$1)}${file2}`;
87167
- }
87168
- function weightToken(weight) {
87169
- return weight === "bold" ? "700" : "400";
87170
- }
87171
- function bundledAssetSignature(resolve) {
87172
- const family$1 = BUNDLED_MANIFEST[0];
87173
- const face = family$1?.faces[0];
87174
- if (!family$1 || !face)
87175
- return "";
87176
- return resolve({
87177
- file: face.file,
87178
- family: family$1.family,
87179
- weight: weightToken(face.weight),
87180
- style: face.style,
87181
- source: "bundled-substitute"
87182
- });
87183
- }
87184
- function installBundledSubstitutes(registry2, options = {}) {
87185
- const resolve = options.resolveAssetUrl ?? ((context) => joinUrl(options.assetBaseUrl ?? defaultAssetBase, context.file));
87186
- const signature = bundledAssetSignature(resolve);
87187
- const installed = installedRegistries.get(registry2);
87188
- if (installed !== undefined) {
87189
- if (installed !== signature)
87190
- console.warn(`[superdoc] bundled fonts are already registered for this document from "${installed}"; a later fonts config resolving to "${signature}" is ignored. Use one fonts.assetBaseUrl / fonts.resolveAssetUrl per document.`);
87191
- return;
87192
- }
87193
- installedRegistries.set(registry2, signature);
87194
- for (const family$1 of BUNDLED_MANIFEST)
87195
- for (const face of family$1.faces) {
87196
- const context = {
87197
- file: face.file,
87198
- family: family$1.family,
87199
- weight: weightToken(face.weight),
87200
- style: face.style,
87201
- source: "bundled-substitute"
87202
- };
87203
- registry2.register({
87204
- family: family$1.family,
87205
- source: `url(${resolve(context)})`,
87206
- descriptors: {
87207
- weight: face.weight,
87208
- style: face.style
87209
- }
87210
- });
87211
- }
87212
- }
87213
87260
  function toEvidence(fallback) {
87214
87261
  if (!fallback)
87215
87262
  return;
@@ -87322,7 +87369,7 @@ function canonicalizeFontSource(source) {
87322
87369
  inner = inner.slice(1, -1);
87323
87370
  return `url(${JSON.stringify(inner)})`;
87324
87371
  }
87325
- function normalizeFamilyKey(family$1) {
87372
+ function normalizeFamilyKey$1(family$1) {
87326
87373
  return family$1.trim().replace(/^["']|["']$/g, "").toLowerCase();
87327
87374
  }
87328
87375
  function normalizeWeight(weight) {
@@ -87341,7 +87388,7 @@ function normalizeStyle(style) {
87341
87388
  return s.startsWith("italic") || s.startsWith("oblique") ? "italic" : "normal";
87342
87389
  }
87343
87390
  function faceKeyOf(family$1, weight, style) {
87344
- return `${normalizeFamilyKey(family$1)}|${weight}|${style}`;
87391
+ return `${normalizeFamilyKey$1(family$1)}|${weight}|${style}`;
87345
87392
  }
87346
87393
  function faceProbe(family$1, weight, style, size) {
87347
87394
  return `${style === "italic" ? "italic " : ""}${weight} ${size} ${quoteFamily(family$1)}`;
@@ -87393,8 +87440,10 @@ function deriveOfferings() {
87393
87440
  function compareLogicalFamily(a, b) {
87394
87441
  return a.logicalFamily.localeCompare(b.logicalFamily, "en", { sensitivity: "base" });
87395
87442
  }
87396
- function getBuiltInToolbarFontOfferings() {
87397
- return FONT_OFFERINGS.filter((o) => o.offering === "default" || o.bundled && ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES.has(o.logicalFamily) && (o.offering === "qualified" || o.offering === "category_fallback")).sort(compareLogicalFamily);
87443
+ function getBuiltInToolbarFontOfferings(activation = BASELINE_BUNDLED) {
87444
+ if (!activation.packConfigured)
87445
+ return FONT_OFFERINGS.filter((o) => o.bundled && BUILT_IN_TOOLBAR_BASELINE_FAMILIES.has(o.logicalFamily)).sort(compareLogicalFamily);
87446
+ return FONT_OFFERINGS.filter((o) => (o.offering === "default" || o.bundled && ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES.has(o.logicalFamily) && (o.offering === "qualified" || o.offering === "category_fallback")) && activation.isActive(o.logicalFamily)).sort(compareLogicalFamily);
87398
87447
  }
87399
87448
  function fontOfferingStack(offering) {
87400
87449
  return `${offering.logicalFamily}, ${offering.generic}`;
@@ -87402,12 +87451,73 @@ function fontOfferingStack(offering) {
87402
87451
  function fontOfferingRenderStack(offering) {
87403
87452
  return offering.physicalFamily ? `${offering.physicalFamily}, ${offering.generic}` : fontOfferingStack(offering);
87404
87453
  }
87405
- function getDefaultFontFamilyOptions() {
87406
- return getBuiltInToolbarFontOfferings().map((offering) => ({
87454
+ function getDefaultFontFamilyOptions(activation = BASELINE_BUNDLED) {
87455
+ return getBuiltInToolbarFontOfferings(activation).map((offering) => ({
87407
87456
  label: offering.logicalFamily,
87408
87457
  value: fontOfferingStack(offering)
87409
87458
  }));
87410
87459
  }
87460
+ function normalizeFamilyKey(family$1) {
87461
+ return family$1.trim().replace(/^["']|["']$/g, "").toLowerCase();
87462
+ }
87463
+ function editDistance(a, b) {
87464
+ const m = a.length;
87465
+ const n = b.length;
87466
+ if (Math.abs(m - n) > 2)
87467
+ return 3;
87468
+ let prev = Array.from({ length: n + 1 }, (_, i$1) => i$1);
87469
+ for (let i$1 = 1;i$1 <= m; i$1 += 1) {
87470
+ const curr = [i$1];
87471
+ for (let j = 1;j <= n; j += 1) {
87472
+ const cost = a[i$1 - 1] === b[j - 1] ? 0 : 1;
87473
+ curr[j] = Math.min(curr[j - 1] + 1, prev[j] + 1, prev[j - 1] + cost);
87474
+ }
87475
+ prev = curr;
87476
+ }
87477
+ return prev[n];
87478
+ }
87479
+ function closestBundledFamily(name) {
87480
+ const key = normalizeFamilyKey(name);
87481
+ let best = null;
87482
+ let bestDist = 3;
87483
+ for (const family$1 of BUNDLED_LOGICAL_FAMILIES) {
87484
+ const dist = editDistance(key, normalizeFamilyKey(family$1));
87485
+ if (dist < bestDist) {
87486
+ bestDist = dist;
87487
+ best = family$1;
87488
+ }
87489
+ }
87490
+ return best;
87491
+ }
87492
+ function coerceCurationList(value, field) {
87493
+ if (value == null)
87494
+ return [];
87495
+ if (!Array.isArray(value)) {
87496
+ console.warn(`[superdoc] fonts.bundled.${field} must be an array of font names; ignoring it. Prefer createSuperDocFonts(), which rejects malformed curation.`);
87497
+ return [];
87498
+ }
87499
+ return value.filter((name) => typeof name === "string");
87500
+ }
87501
+ function warnUnknownBundledSelection(selection) {
87502
+ if (!selection)
87503
+ return;
87504
+ const include = coerceCurationList(selection.include, "include");
87505
+ const exclude = coerceCurationList(selection.exclude, "exclude");
87506
+ if (include.length && exclude.length)
87507
+ console.warn("[superdoc] fonts.bundled: set `include` OR `exclude`, not both. Using `include` (the allow-list) and ignoring `exclude`. Prefer createSuperDocFonts(), which rejects this.");
87508
+ const seen = /* @__PURE__ */ new Set;
87509
+ for (const name of [...include, ...exclude]) {
87510
+ const trimmed = typeof name === "string" ? name.trim() : "";
87511
+ if (!trimmed)
87512
+ continue;
87513
+ const key = normalizeFamilyKey(trimmed);
87514
+ if (BUNDLED_LOGICAL_KEYS.has(key) || seen.has(key))
87515
+ continue;
87516
+ seen.add(key);
87517
+ const suggestion = closestBundledFamily(trimmed);
87518
+ console.warn(`[superdoc] fonts.bundled: "${trimmed}" is not a bundled font, so curating it has no effect${suggestion ? ` (did you mean "${suggestion}"?)` : ""}. Curate by Word family name, e.g. Calibri, Cambria, Times New Roman. Docs: https://docs.superdoc.dev/getting-started/fonts`);
87519
+ }
87520
+ }
87411
87521
  function normalizeKey(family$1) {
87412
87522
  return family$1.trim().replace(/^["']|["']$/g, "").toLowerCase();
87413
87523
  }
@@ -99213,7 +99323,7 @@ var isRegExp = (value) => {
99213
99323
  this.localPreserveWS = true;
99214
99324
  let name = dom.nodeName.toLowerCase(), ruleID;
99215
99325
  if (listTags.hasOwnProperty(name) && this.parser.normalizeLists)
99216
- normalizeList(dom);
99326
+ normalizeList$1(dom);
99217
99327
  let rule = this.options.ruleFromNode && this.options.ruleFromNode(dom) || (ruleID = this.parser.matchTag(dom, this, matchAfter));
99218
99328
  out:
99219
99329
  if (rule ? rule.ignore : ignoreTags.hasOwnProperty(name)) {
@@ -114367,19 +114477,32 @@ var isRegExp = (value) => {
114367
114477
  tags.push(`</${name}>`);
114368
114478
  return tags;
114369
114479
  }
114370
- }, SETTLED_STATUSES, SUBSTITUTION_EVIDENCE$1, LINE_BREAK_SAFE_VERDICTS, BY_LOGICAL, BUNDLED_MANIFEST, SUBSTITUTION_EVIDENCE, bundledFamilies, canRenderFamily = (family$1) => bundledFamilies.has(family$1), BUNDLED_SUBSTITUTES, CATEGORY_FALLBACKS, FontResolver = class {
114480
+ }, SETTLED_STATUSES, SUBSTITUTION_EVIDENCE$1, LINE_BREAK_SAFE_VERDICTS, BY_LOGICAL, BUNDLED_MANIFEST, defaultAssetBase = "/fonts/", bundledPackPresent = false, installedRegistries, FULLY_ACTIVE_BUNDLED, BASELINE_BUNDLED, SUBSTITUTION_EVIDENCE, bundledFamilies, canRenderFamily = (family$1) => bundledFamilies.has(family$1), BUNDLED_SUBSTITUTES, CATEGORY_FALLBACKS, FontResolver = class {
114371
114481
  #overrides = /* @__PURE__ */ new Map;
114372
114482
  #embedded = /* @__PURE__ */ new Map;
114373
114483
  #version = 0;
114374
114484
  #cachedSignature = null;
114485
+ #activation;
114486
+ constructor(activation = FULLY_ACTIVE_BUNDLED) {
114487
+ this.#activation = activation;
114488
+ }
114489
+ setActivation(activation) {
114490
+ if (this.#activation.signature === activation.signature) {
114491
+ this.#activation = activation;
114492
+ return;
114493
+ }
114494
+ this.#activation = activation;
114495
+ this.#version += 1;
114496
+ this.#cachedSignature = null;
114497
+ }
114375
114498
  map(logicalFamily, physicalFamily) {
114376
- const key = normalizeFamilyKey$1(logicalFamily);
114499
+ const key = normalizeFamilyKey$2(logicalFamily);
114377
114500
  const physical = physicalFamily?.trim();
114378
114501
  if (!key || !physical)
114379
114502
  return;
114380
114503
  if (this.#overrides.get(key) === physical)
114381
114504
  return;
114382
- if (key === normalizeFamilyKey$1(physical)) {
114505
+ if (key === normalizeFamilyKey$2(physical)) {
114383
114506
  if (this.#overrides.delete(key)) {
114384
114507
  this.#version += 1;
114385
114508
  this.#cachedSignature = null;
@@ -114391,13 +114514,13 @@ var isRegExp = (value) => {
114391
114514
  this.#cachedSignature = null;
114392
114515
  }
114393
114516
  unmap(logicalFamily) {
114394
- if (this.#overrides.delete(normalizeFamilyKey$1(logicalFamily))) {
114517
+ if (this.#overrides.delete(normalizeFamilyKey$2(logicalFamily))) {
114395
114518
  this.#version += 1;
114396
114519
  this.#cachedSignature = null;
114397
114520
  }
114398
114521
  }
114399
114522
  mapEmbedded(logicalFamily, physicalFamily) {
114400
- const key = normalizeFamilyKey$1(logicalFamily);
114523
+ const key = normalizeFamilyKey$2(logicalFamily);
114401
114524
  const physical = physicalFamily?.trim();
114402
114525
  if (!key || !physical)
114403
114526
  return;
@@ -114428,44 +114551,58 @@ var isRegExp = (value) => {
114428
114551
  get signature() {
114429
114552
  if (this.#cachedSignature !== null)
114430
114553
  return this.#cachedSignature;
114431
- if (this.#overrides.size === 0 && this.#embedded.size === 0)
114554
+ const activation = this.#activation.signature;
114555
+ const hasOverrides = this.#overrides.size > 0;
114556
+ const hasEmbedded = this.#embedded.size > 0;
114557
+ if (!hasOverrides && !hasEmbedded && activation === "") {
114432
114558
  this.#cachedSignature = "";
114433
- else {
114434
- const overridePairs = sortPairs([...this.#overrides.entries()]);
114435
- this.#cachedSignature = this.#embedded.size === 0 ? JSON.stringify(overridePairs) : JSON.stringify({
114559
+ return this.#cachedSignature;
114560
+ }
114561
+ const overridePairs = sortPairs([...this.#overrides.entries()]);
114562
+ if (activation === "")
114563
+ this.#cachedSignature = !hasEmbedded ? JSON.stringify(overridePairs) : JSON.stringify({
114436
114564
  o: overridePairs,
114437
114565
  e: sortPairs([...this.#embedded.entries()])
114438
114566
  });
114567
+ else {
114568
+ const obj = { a: activation };
114569
+ if (hasOverrides)
114570
+ obj.o = overridePairs;
114571
+ if (hasEmbedded)
114572
+ obj.e = sortPairs([...this.#embedded.entries()]);
114573
+ this.#cachedSignature = JSON.stringify(obj);
114439
114574
  }
114440
114575
  return this.#cachedSignature;
114441
114576
  }
114442
114577
  #physicalFor(bareFamily) {
114443
- const key = normalizeFamilyKey$1(bareFamily);
114578
+ const key = normalizeFamilyKey$2(bareFamily);
114444
114579
  const override = this.#overrides.get(key);
114445
114580
  if (override)
114446
114581
  return {
114447
114582
  physical: override,
114448
114583
  reason: "custom_mapping"
114449
114584
  };
114450
- const bundled = BUNDLED_SUBSTITUTES[key];
114451
- if (bundled)
114452
- return {
114453
- physical: bundled,
114454
- reason: "bundled_substitute"
114455
- };
114456
- const category = CATEGORY_FALLBACKS[key];
114457
- if (category)
114458
- return {
114459
- physical: category,
114460
- reason: "category_fallback"
114461
- };
114585
+ if (this.#activation.isActive(bareFamily)) {
114586
+ const bundled = BUNDLED_SUBSTITUTES[key];
114587
+ if (bundled)
114588
+ return {
114589
+ physical: bundled,
114590
+ reason: "bundled_substitute"
114591
+ };
114592
+ const category = CATEGORY_FALLBACKS[key];
114593
+ if (category)
114594
+ return {
114595
+ physical: category,
114596
+ reason: "category_fallback"
114597
+ };
114598
+ }
114462
114599
  return {
114463
114600
  physical: bareFamily,
114464
114601
  reason: "as_requested"
114465
114602
  };
114466
114603
  }
114467
114604
  #resolveFaceLadder(primary, face, hasFace) {
114468
- const key = normalizeFamilyKey$1(primary);
114605
+ const key = normalizeFamilyKey$2(primary);
114469
114606
  const override = this.#overrides.get(key);
114470
114607
  if (override && hasFace(override, face.weight, face.style))
114471
114608
  return {
@@ -114483,10 +114620,13 @@ var isRegExp = (value) => {
114483
114620
  physical: primary,
114484
114621
  reason: "registered_face"
114485
114622
  };
114486
- const docfonts = resolveDocfontsFace(primary, face, hasFace);
114487
- if (docfonts)
114488
- return docfonts;
114489
- const bundled = BUNDLED_SUBSTITUTES[key];
114623
+ const active = this.#activation.isActive(primary);
114624
+ if (active) {
114625
+ const docfonts = resolveDocfontsFace(primary, face, hasFace);
114626
+ if (docfonts)
114627
+ return docfonts;
114628
+ }
114629
+ const bundled = active ? BUNDLED_SUBSTITUTES[key] : undefined;
114490
114630
  if (override || bundled)
114491
114631
  return {
114492
114632
  physical: primary,
@@ -114534,7 +114674,7 @@ var isRegExp = (value) => {
114534
114674
  if (parts.length === 0)
114535
114675
  return cssFontFamily;
114536
114676
  const { physical } = this.#resolveFaceLadder(parts[0], face, hasFace);
114537
- if (normalizeFamilyKey$1(physical) !== normalizeFamilyKey$1(parts[0]))
114677
+ if (normalizeFamilyKey$2(physical) !== normalizeFamilyKey$2(parts[0]))
114538
114678
  return [physical, ...parts.slice(1)].join(", ");
114539
114679
  return cssFontFamily;
114540
114680
  }
@@ -114549,7 +114689,7 @@ var isRegExp = (value) => {
114549
114689
  out.add(this.resolvePrimaryPhysicalFamily(family$1));
114550
114690
  return [...out];
114551
114691
  }
114552
- }, defaultResolver, DEFAULT_FONT_MEASURE_CONTEXT, fontConfigVersion = 0, defaultAssetBase = "/fonts/", installedRegistries, faceSlotFor = ({ weight, style }) => {
114692
+ }, defaultResolver, DEFAULT_FONT_MEASURE_CONTEXT, fontConfigVersion = 0, faceSlotFor = ({ weight, style }) => {
114553
114693
  const bold = weight === "700";
114554
114694
  const italic = style === "italic";
114555
114695
  if (bold && italic)
@@ -114559,7 +114699,7 @@ var isRegExp = (value) => {
114559
114699
  if (italic)
114560
114700
  return "italic";
114561
114701
  return "regular";
114562
- }, isRenderedSubstitute = (reason) => reason === "bundled_substitute" || reason === "category_fallback", RENDER_ALL, FS_TYPE_RESTRICTED = 2, FS_SELECTION_ITALIC = 1, BOLD_WEIGHT_THRESHOLD = 600, SFNT_TABLE_DIR_OFFSET = 12, SFNT_TABLE_RECORD_SIZE = 16, OS2_USWEIGHTCLASS = 4, OS2_FSTYPE = 8, OS2_FSSELECTION = 62, OS2_MIN_LENGTH, DEFAULT_FONT_LOAD_TIMEOUT_MS = 3000, DEFAULT_PROBE_SIZE = "16px", FontRegistry = class {
114702
+ }, isRenderedSubstitute = (reason) => reason === "bundled_substitute" || reason === "category_fallback", RENDER_ALL, FS_TYPE_RESTRICTED = 2, FS_SELECTION_ITALIC = 1, BOLD_WEIGHT_THRESHOLD = 600, SFNT_TABLE_DIR_OFFSET = 12, SFNT_TABLE_RECORD_SIZE = 16, OS2_USWEIGHTCLASS = 4, OS2_FSTYPE = 8, OS2_FSSELECTION = 62, OS2_MIN_LENGTH, BUNDLED_SUBSTITUTE_FAMILIES, DEFAULT_FONT_LOAD_TIMEOUT_MS = 3000, DEFAULT_PROBE_SIZE = "16px", FontRegistry = class {
114563
114703
  #fontSet;
114564
114704
  #FontFaceCtor;
114565
114705
  #probeSize;
@@ -114570,6 +114710,7 @@ var isRegExp = (value) => {
114570
114710
  #status = /* @__PURE__ */ new Map;
114571
114711
  #sources = /* @__PURE__ */ new Map;
114572
114712
  #warnedFailures = /* @__PURE__ */ new Set;
114713
+ #warnedBundledSubstituteFailure = false;
114573
114714
  #inflight = /* @__PURE__ */ new Map;
114574
114715
  #faceStatus = /* @__PURE__ */ new Map;
114575
114716
  #faceInflight = /* @__PURE__ */ new Map;
@@ -114631,7 +114772,7 @@ var isRegExp = (value) => {
114631
114772
  };
114632
114773
  }
114633
114774
  #trackFace(family$1, key) {
114634
- const fam = normalizeFamilyKey(family$1);
114775
+ const fam = normalizeFamilyKey$1(family$1);
114635
114776
  const set3 = this.#facesByFamily.get(fam) ?? /* @__PURE__ */ new Set;
114636
114777
  set3.add(key);
114637
114778
  this.#facesByFamily.set(fam, set3);
@@ -114685,7 +114826,7 @@ var isRegExp = (value) => {
114685
114826
  this.#providerFaceKeys.delete(key);
114686
114827
  this.#faceStatus.delete(key);
114687
114828
  this.#faceSources.delete(key);
114688
- const fam = normalizeFamilyKey(family$1);
114829
+ const fam = normalizeFamilyKey$1(family$1);
114689
114830
  const keys$1 = this.#facesByFamily.get(fam);
114690
114831
  if (keys$1) {
114691
114832
  keys$1.delete(key);
@@ -114700,7 +114841,7 @@ var isRegExp = (value) => {
114700
114841
  }
114701
114842
  getStatus(family$1) {
114702
114843
  const statuses = [];
114703
- const faceKeys = this.#facesByFamily.get(normalizeFamilyKey(family$1));
114844
+ const faceKeys = this.#facesByFamily.get(normalizeFamilyKey$1(family$1));
114704
114845
  if (faceKeys)
114705
114846
  for (const k of faceKeys)
114706
114847
  statuses.push(this.#faceStatus.get(k) ?? "unloaded");
@@ -114843,6 +114984,10 @@ var isRegExp = (value) => {
114843
114984
  }
114844
114985
  }
114845
114986
  #warnFaceFailureOnce(request, key) {
114987
+ if (BUNDLED_SUBSTITUTE_FAMILIES.has(request.family)) {
114988
+ this.#warnBundledSubstituteFailureOnce(request.family);
114989
+ return;
114990
+ }
114846
114991
  if (this.#warnedFaceFailures.has(key))
114847
114992
  return;
114848
114993
  this.#warnedFaceFailures.add(key);
@@ -114893,6 +115038,10 @@ var isRegExp = (value) => {
114893
115038
  }
114894
115039
  }
114895
115040
  #warnLoadFailureOnce(family$1) {
115041
+ if (BUNDLED_SUBSTITUTE_FAMILIES.has(family$1)) {
115042
+ this.#warnBundledSubstituteFailureOnce(family$1);
115043
+ return;
115044
+ }
114896
115045
  if (this.#warnedFailures.has(family$1))
114897
115046
  return;
114898
115047
  this.#warnedFailures.add(family$1);
@@ -114900,7 +115049,18 @@ var isRegExp = (value) => {
114900
115049
  const detail = sources && sources.length ? ` from ${sources.join(", ")}` : "";
114901
115050
  console.warn(`[superdoc] font asset failed to load for "${family$1}"${detail}. Check fonts.assetBaseUrl / fonts.resolveAssetUrl so the bundled .woff2 are served.`);
114902
115051
  }
114903
- }, registriesByFontSet, domlessRegistry = null, BUNDLED_FAMILIES, SUPPORTED_ALIAS_FAMILIES, ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES, FONT_OFFERINGS, prepareCommentParaIds = (comment) => {
115052
+ #warnBundledSubstituteFailureOnce(family$1) {
115053
+ if (this.#warnedBundledSubstituteFailure)
115054
+ return;
115055
+ this.#warnedBundledSubstituteFailure = true;
115056
+ console.warn(`[superdoc] Bundled fallback fonts failed to load (e.g. "${family$1}"). Text will render with system fallbacks, so some fonts may look unchanged on machines that lack them. Fix one of:
115057
+ - install @superdoc-dev/fonts and pass it:
115058
+ import { superdocFonts } from '@superdoc-dev/fonts';
115059
+ new SuperDoc({ /* ... */ fonts: superdocFonts });
115060
+ - or set fonts.assetBaseUrl / fonts.resolveAssetUrl to where the bundled .woff2 are served.
115061
+ Docs: https://docs.superdoc.dev/getting-started/fonts`);
115062
+ }
115063
+ }, registriesByFontSet, domlessRegistry = null, BUNDLED_FAMILIES, SUPPORTED_ALIAS_FAMILIES, BUILT_IN_TOOLBAR_BASELINE_FAMILIES, ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES, FONT_OFFERINGS, BUNDLED_LOGICAL_FAMILIES, BUNDLED_LOGICAL_KEYS, prepareCommentParaIds = (comment) => {
114904
115064
  return {
114905
115065
  ...comment,
114906
115066
  commentParaId: generateDocxRandomId()
@@ -119021,7 +119181,7 @@ var isRegExp = (value) => {
119021
119181
  sourceId: stringOf(primary.sourceId),
119022
119182
  revisionGroupId: stringOf(primary.revisionGroupId) || representativeRevisionId
119023
119183
  });
119024
- }, stringOf = (value) => typeof value === "string" ? value : value == null ? "" : String(value), groupedCache, SDT_NODE_NAMES, SDT_BLOCK_NAME = "structuredContentBlock", SDT_INLINE_NAME = "structuredContent", SDT_NODE_TYPES, VALID_CONTROL_TYPES, VALID_LOCK_MODES, VALID_APPEARANCES, FIELD_LIKE_SDT_TYPES, liveDocumentCountsCache, BIBLIOGRAPHY_NAMESPACE_URI = "http://schemas.openxmlformats.org/officeDocument/2006/bibliography", CUSTOM_XML_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml", CUSTOM_XML_PROPS_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps", DEFAULT_SELECTED_STYLE = "/APA.XSL", DEFAULT_STYLE_NAME = "APA", DEFAULT_VERSION = "6", API_TO_OOXML_SOURCE_TYPE, OOXML_TO_API_SOURCE_TYPE, SIMPLE_FIELD_TO_XML_TAG, XML_TAG_TO_SIMPLE_FIELD, import_lib2, FONT_FAMILY_FALLBACKS, DEFAULT_GENERIC_FALLBACK = "sans-serif", DEFAULT_FONT_SIZE_PT = 10, CURRENT_APP_VERSION = "1.39.0", SUPERDOC_DOCUMENT_ORIGIN_PROPERTY = "SuperdocDocumentOrigin", STORED_DOCUMENT_ORIGINS, collectRunDefaultProperties = (runProps, { allowOverrideTypeface = true, allowOverrideSize = true, themeResolver, state }) => {
119184
+ }, stringOf = (value) => typeof value === "string" ? value : value == null ? "" : String(value), groupedCache, SDT_NODE_NAMES, SDT_BLOCK_NAME = "structuredContentBlock", SDT_INLINE_NAME = "structuredContent", SDT_NODE_TYPES, VALID_CONTROL_TYPES, VALID_LOCK_MODES, VALID_APPEARANCES, FIELD_LIKE_SDT_TYPES, liveDocumentCountsCache, BIBLIOGRAPHY_NAMESPACE_URI = "http://schemas.openxmlformats.org/officeDocument/2006/bibliography", CUSTOM_XML_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml", CUSTOM_XML_PROPS_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps", DEFAULT_SELECTED_STYLE = "/APA.XSL", DEFAULT_STYLE_NAME = "APA", DEFAULT_VERSION = "6", API_TO_OOXML_SOURCE_TYPE, OOXML_TO_API_SOURCE_TYPE, SIMPLE_FIELD_TO_XML_TAG, XML_TAG_TO_SIMPLE_FIELD, import_lib2, FONT_FAMILY_FALLBACKS, DEFAULT_GENERIC_FALLBACK = "sans-serif", DEFAULT_FONT_SIZE_PT = 10, CURRENT_APP_VERSION = "1.40.1", SUPERDOC_DOCUMENT_ORIGIN_PROPERTY = "SuperdocDocumentOrigin", STORED_DOCUMENT_ORIGINS, collectRunDefaultProperties = (runProps, { allowOverrideTypeface = true, allowOverrideSize = true, themeResolver, state }) => {
119025
119185
  if (!runProps?.elements?.length || !state)
119026
119186
  return;
119027
119187
  const fontsNode = runProps.elements.find((el) => el.name === "w:rFonts");
@@ -119055,7 +119215,7 @@ var isRegExp = (value) => {
119055
119215
  state.kern = kernNode.attributes["w:val"];
119056
119216
  }
119057
119217
  }, SuperConverter;
119058
- var init_SuperConverter_DAuqlmYY_es = __esm(() => {
119218
+ var init_SuperConverter_kHxKGgu_es = __esm(() => {
119059
119219
  init_rolldown_runtime_Bg48TavK_es();
119060
119220
  init_jszip_C49i9kUs_es();
119061
119221
  init_xml_js_CqGKpaft_es();
@@ -157966,6 +158126,17 @@ var init_SuperConverter_DAuqlmYY_es = __esm(() => {
157966
158126
  }]),
157967
158127
  family("TeX Gyre Bonum", "TeXGyreBonum", "LicenseRef-GUST-Font-License-1.0")
157968
158128
  ]);
158129
+ installedRegistries = /* @__PURE__ */ new WeakMap;
158130
+ FULLY_ACTIVE_BUNDLED = Object.freeze({
158131
+ packConfigured: true,
158132
+ isActive: () => true,
158133
+ signature: ""
158134
+ });
158135
+ BASELINE_BUNDLED = Object.freeze({
158136
+ packConfigured: false,
158137
+ isActive: () => false,
158138
+ signature: JSON.stringify({ p: false })
158139
+ });
157969
158140
  SUBSTITUTION_EVIDENCE = SUBSTITUTION_EVIDENCE$1;
157970
158141
  bundledFamilies = new Set(BUNDLED_MANIFEST.map((f2) => f2.family));
157971
158142
  BUNDLED_SUBSTITUTES = deriveBundledSubstitutes();
@@ -157975,9 +158146,9 @@ var init_SuperConverter_DAuqlmYY_es = __esm(() => {
157975
158146
  resolvePhysical: (cssFontFamily, _face) => resolvePhysicalFamily(cssFontFamily),
157976
158147
  fontSignature: ""
157977
158148
  });
157978
- installedRegistries = /* @__PURE__ */ new WeakMap;
157979
158149
  RENDER_ALL = { canRenderFamily: () => true };
157980
158150
  OS2_MIN_LENGTH = OS2_FSSELECTION + 2;
158151
+ BUNDLED_SUBSTITUTE_FAMILIES = new Set(BUNDLED_MANIFEST.map((f2) => f2.family));
157981
158152
  registriesByFontSet = /* @__PURE__ */ new WeakMap;
157982
158153
  BUNDLED_FAMILIES = new Set(BUNDLED_MANIFEST.map((f2) => f2.family));
157983
158154
  SUPPORTED_ALIAS_FAMILIES = new Set([
@@ -157985,6 +158156,11 @@ var init_SuperConverter_DAuqlmYY_es = __esm(() => {
157985
158156
  "Courier",
157986
158157
  "Times"
157987
158158
  ]);
158159
+ BUILT_IN_TOOLBAR_BASELINE_FAMILIES = new Set([
158160
+ "Arial",
158161
+ "Courier New",
158162
+ "Times New Roman"
158163
+ ]);
157988
158164
  ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES = new Set([
157989
158165
  "Arial Black",
157990
158166
  "Arial Narrow",
@@ -158005,6 +158181,8 @@ var init_SuperConverter_DAuqlmYY_es = __esm(() => {
158005
158181
  "Verdana"
158006
158182
  ]);
158007
158183
  FONT_OFFERINGS = deriveOfferings();
158184
+ BUNDLED_LOGICAL_FAMILIES = [...new Set(FONT_OFFERINGS.filter((o) => o.bundled).map((o) => o.logicalFamily))].sort((a, b) => a.localeCompare(b, "en", { sensitivity: "base" }));
158185
+ BUNDLED_LOGICAL_KEYS = new Set(BUNDLED_LOGICAL_FAMILIES.map(normalizeFamilyKey));
158008
158186
  ALL_COMMENT_TARGETS = COMMENT_FILE_BASENAMES;
158009
158187
  REL_ID_NUMERIC_PATTERN = /rId|mi/g;
158010
158188
  FOOTNOTES_CONFIG$1 = {
@@ -159799,7 +159977,7 @@ var init_SuperConverter_DAuqlmYY_es = __esm(() => {
159799
159977
  };
159800
159978
  });
159801
159979
 
159802
- // ../../packages/superdoc/dist/chunks/create-headless-toolbar-BT0XKtIW.es.js
159980
+ // ../../packages/superdoc/dist/chunks/create-headless-toolbar-DYsLIQ7b.es.js
159803
159981
  function parseSizeUnit(val = "0") {
159804
159982
  const length = val.toString() || "0";
159805
159983
  const value = Number.parseFloat(length);
@@ -170448,8 +170626,8 @@ var CSS_DIMENSION_REGEX, DOM_SIZE_UNITS, normalizeActorId = (value) => {
170448
170626
  }
170449
170627
  };
170450
170628
  };
170451
- var init_create_headless_toolbar_BT0XKtIW_es = __esm(() => {
170452
- init_SuperConverter_DAuqlmYY_es();
170629
+ var init_create_headless_toolbar_DYsLIQ7b_es = __esm(() => {
170630
+ init_SuperConverter_kHxKGgu_es();
170453
170631
  init_uuid_B2wVPhPi_es();
170454
170632
  init_constants_D9qj59G2_es();
170455
170633
  init_dist_B8HfvhaK_es();
@@ -225140,7 +225318,7 @@ var init_remark_gfm_eZN6yzWQ_es = __esm(() => {
225140
225318
  init_remark_gfm_BhnWr3yf_es();
225141
225319
  });
225142
225320
 
225143
- // ../../packages/superdoc/dist/chunks/src-DGC_pZIT.es.js
225321
+ // ../../packages/superdoc/dist/chunks/src-BkVhvl5H.es.js
225144
225322
  function deleteProps(obj, propOrProps) {
225145
225323
  const props = typeof propOrProps === "string" ? [propOrProps] : propOrProps;
225146
225324
  const removeNested = (target, pathParts, index2 = 0) => {
@@ -225214,7 +225392,7 @@ function prosemirrorToYXmlFragment(doc$12, xmlFragment) {
225214
225392
  }
225215
225393
  function getSuperdocVersion() {
225216
225394
  try {
225217
- return "1.39.0";
225395
+ return "1.40.1";
225218
225396
  } catch {
225219
225397
  return "unknown";
225220
225398
  }
@@ -237500,20 +237678,32 @@ function scrollToElement(targetElement, options = {
237500
237678
  behavior: options.behavior
237501
237679
  });
237502
237680
  }
237681
+ function toolbarFontOptionsFor(activation = BASELINE_BUNDLED) {
237682
+ return getBuiltInToolbarFontOfferings(activation).map((offering) => ({
237683
+ label: offering.logicalFamily,
237684
+ key: fontOfferingStack(offering),
237685
+ fontWeight: 400,
237686
+ props: {
237687
+ style: { fontFamily: fontOfferingRenderStack(offering) },
237688
+ "data-item": "btn-fontFamily-option"
237689
+ }
237690
+ }));
237691
+ }
237503
237692
  function normalizeToolbarFamily(value) {
237504
237693
  return String(value ?? "").trim().toLowerCase();
237505
237694
  }
237506
237695
  function compareToolbarFontOptions(a2, b$1) {
237507
237696
  return String(a2.label ?? "").trim().localeCompare(String(b$1.label ?? "").trim(), "en", { sensitivity: "base" });
237508
237697
  }
237509
- function composeToolbarFontOptions(documentOptions, configFonts) {
237698
+ function composeToolbarFontOptions(documentOptions, configFonts, activation = BASELINE_BUNDLED) {
237510
237699
  if (configFonts)
237511
237700
  return configFonts;
237512
- if (!documentOptions?.length)
237701
+ if (!activation.packConfigured && !documentOptions?.length)
237513
237702
  return;
237514
- const seen = new Set(TOOLBAR_FONTS.map((option) => normalizeToolbarFamily(option.label)));
237515
- const merged = [...TOOLBAR_FONTS];
237516
- for (const option of documentOptions) {
237703
+ const base4 = toolbarFontOptionsFor(activation);
237704
+ const seen = new Set(base4.map((option) => normalizeToolbarFamily(option.label)));
237705
+ const merged = [...base4];
237706
+ for (const option of documentOptions ?? []) {
237517
237707
  const dedupeKey = normalizeToolbarFamily(option.logicalFamily);
237518
237708
  if (seen.has(dedupeKey))
237519
237709
  continue;
@@ -237528,7 +237718,7 @@ function composeToolbarFontOptions(documentOptions, configFonts) {
237528
237718
  }
237529
237719
  });
237530
237720
  }
237531
- return merged.length > TOOLBAR_FONTS.length ? merged.sort(compareToolbarFontOptions) : undefined;
237721
+ return merged.sort(compareToolbarFontOptions);
237532
237722
  }
237533
237723
  function isExtensionRulesEnabled(extension2, enabled) {
237534
237724
  if (Array.isArray(enabled))
@@ -302658,7 +302848,7 @@ var Node$13 = class Node$14 {
302658
302848
  domAvailabilityCache = false;
302659
302849
  return false;
302660
302850
  }
302661
- }, summaryVersion = "1.39.0", nodeKeys, markKeys, transformListsInCopiedContent = (html3) => {
302851
+ }, summaryVersion = "1.40.1", nodeKeys, markKeys, transformListsInCopiedContent = (html3) => {
302662
302852
  const container = document.createElement("div");
302663
302853
  container.innerHTML = html3;
302664
302854
  const result = [];
@@ -303844,7 +304034,7 @@ var Node$13 = class Node$14 {
303844
304034
  return () => {};
303845
304035
  const handle3 = setInterval(callback, intervalMs);
303846
304036
  return () => clearInterval(handle3);
303847
- }, HISTORY_UNSAFE_OPS, CANONICAL_COMMENT_IGNORED_KEYS, INITIAL_HASH, ROUND_CONSTANTS, V1_COVERAGE, V2_COVERAGE, SNAPSHOT_VERSION_V2 = "sd-diff-snapshot/v2", PAYLOAD_VERSION_V1 = "sd-diff-payload/v1", PAYLOAD_VERSION_V2 = "sd-diff-payload/v2", ENGINE_ID = "super-editor", STAGED_CONVERTER_KEYS, DiffServiceError, TC_LEVEL_MIN = 1, TC_LEVEL_MAX = 9, ALLOWED_WRAP_ATTRS, WRAP_TYPES_SUPPORTING_SIDE, WRAP_TYPES_SUPPORTING_DISTANCES, RELATIVE_HEIGHT_MIN = 0, RELATIVE_HEIGHT_MAX = 4294967295, FORBIDDEN_RAW_PATCH_NAMES, CONTROL_TYPE_SDT_PR_ELEMENTS, DEFAULT_CHECKBOX_SYMBOL_FONT2 = "MS Gothic", DEFAULT_CHECKBOX_CHECKED_HEX2 = "2612", DEFAULT_CHECKBOX_UNCHECKED_HEX2 = "2610", VARIANT_ORDER, KIND_ORDER, HEADER_RELATIONSHIP_TYPE3 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header", FOOTER_RELATIONSHIP_TYPE3 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer", DOCUMENT_RELS_PATH2 = "word/_rels/document.xml.rels", HEADER_FILE_PATTERN2, FOOTER_FILE_PATTERN2, SPECIAL_NOTE_TYPES, BOOKMARK_SCAN_REVISION_PREFIX = "bookmark-scan:", import_lib4, CUSTOM_XML_DATA_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml", CUSTOM_XML_PROPS_RELATIONSHIP_TYPE2 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps", CUSTOM_XML_DATASTORE_NAMESPACE = "http://schemas.openxmlformats.org/officeDocument/2006/customXml", SETTINGS_PART, RESTART_POLICY_TO_OOXML, VALID_DISPLAYS, REFERENCE_BLOCK_PREFIX, CAPTION_STYLE_NAMES, CAPTION_PARAGRAPH_STYLE_ID = "Caption", CAPTION_FORMAT_TO_OOXML, DOCUMENT_STAT_FIELD_TYPES, TOA_LEADER_REVERSE_MAP, EDGE_NODE_TYPES, CONTENT_TYPES_PART_ID = "[Content_Types].xml", CONTENT_TYPES_NS = "http://schemas.openxmlformats.org/package/2006/content-types", contentTypesPartDescriptor, empty_exports, init_empty, CURRENT_APP_VERSION2 = "1.39.0", PIXELS_PER_INCH2 = 96, MAX_HEIGHT_BUFFER_PX = 50, MAX_WIDTH_BUFFER_PX = 20, TRACKED_REVIEW_MARK_NAMES2, isTrackedReviewMark = (mark2) => Boolean(mark2?.type?.name && TRACKED_REVIEW_MARK_NAMES2.has(mark2.type.name)), trackedReviewMarkKey = (mark2) => {
304037
+ }, HISTORY_UNSAFE_OPS, CANONICAL_COMMENT_IGNORED_KEYS, INITIAL_HASH, ROUND_CONSTANTS, V1_COVERAGE, V2_COVERAGE, SNAPSHOT_VERSION_V2 = "sd-diff-snapshot/v2", PAYLOAD_VERSION_V1 = "sd-diff-payload/v1", PAYLOAD_VERSION_V2 = "sd-diff-payload/v2", ENGINE_ID = "super-editor", STAGED_CONVERTER_KEYS, DiffServiceError, TC_LEVEL_MIN = 1, TC_LEVEL_MAX = 9, ALLOWED_WRAP_ATTRS, WRAP_TYPES_SUPPORTING_SIDE, WRAP_TYPES_SUPPORTING_DISTANCES, RELATIVE_HEIGHT_MIN = 0, RELATIVE_HEIGHT_MAX = 4294967295, FORBIDDEN_RAW_PATCH_NAMES, CONTROL_TYPE_SDT_PR_ELEMENTS, DEFAULT_CHECKBOX_SYMBOL_FONT2 = "MS Gothic", DEFAULT_CHECKBOX_CHECKED_HEX2 = "2612", DEFAULT_CHECKBOX_UNCHECKED_HEX2 = "2610", VARIANT_ORDER, KIND_ORDER, HEADER_RELATIONSHIP_TYPE3 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header", FOOTER_RELATIONSHIP_TYPE3 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer", DOCUMENT_RELS_PATH2 = "word/_rels/document.xml.rels", HEADER_FILE_PATTERN2, FOOTER_FILE_PATTERN2, SPECIAL_NOTE_TYPES, BOOKMARK_SCAN_REVISION_PREFIX = "bookmark-scan:", import_lib4, CUSTOM_XML_DATA_RELATIONSHIP_TYPE = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXml", CUSTOM_XML_PROPS_RELATIONSHIP_TYPE2 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/customXmlProps", CUSTOM_XML_DATASTORE_NAMESPACE = "http://schemas.openxmlformats.org/officeDocument/2006/customXml", SETTINGS_PART, RESTART_POLICY_TO_OOXML, VALID_DISPLAYS, REFERENCE_BLOCK_PREFIX, CAPTION_STYLE_NAMES, CAPTION_PARAGRAPH_STYLE_ID = "Caption", CAPTION_FORMAT_TO_OOXML, DOCUMENT_STAT_FIELD_TYPES, TOA_LEADER_REVERSE_MAP, EDGE_NODE_TYPES, CONTENT_TYPES_PART_ID = "[Content_Types].xml", CONTENT_TYPES_NS = "http://schemas.openxmlformats.org/package/2006/content-types", contentTypesPartDescriptor, empty_exports, init_empty, CURRENT_APP_VERSION2 = "1.40.1", PIXELS_PER_INCH2 = 96, MAX_HEIGHT_BUFFER_PX = 50, MAX_WIDTH_BUFFER_PX = 20, TRACKED_REVIEW_MARK_NAMES2, isTrackedReviewMark = (mark2) => Boolean(mark2?.type?.name && TRACKED_REVIEW_MARK_NAMES2.has(mark2.type.name)), trackedReviewMarkKey = (mark2) => {
303848
304038
  if (!isTrackedReviewMark(mark2))
303849
304039
  return null;
303850
304040
  const id2 = typeof mark2.attrs?.id === "string" ? mark2.attrs.id : "";
@@ -323159,6 +323349,8 @@ menclose::after {
323159
323349
  }
323160
323350
  applyInitialConfig(config3) {
323161
323351
  this.#cancelPendingRuntimeReflow();
323352
+ warnUnknownBundledSelection(config3?.bundled);
323353
+ this.#resolver.setActivation(deriveBundledActivation(config3));
323162
323354
  if (!config3)
323163
323355
  return;
323164
323356
  const registered$1 = this.#registerFamilies(config3.families);
@@ -323384,13 +323576,13 @@ menclose::after {
323384
323576
  return;
323385
323577
  console.log(...args$1);
323386
323578
  }, HEADER_FOOTER_INIT_BUDGET_MS = 200, MAX_ZOOM_WARNING_THRESHOLD = 10, MAX_SELECTION_RECTS_PER_USER = 100, SEMANTIC_RESIZE_DEBOUNCE_MS = 120, MIN_SEMANTIC_CONTENT_WIDTH_PX = 1, GLOBAL_PERFORMANCE, PresentationEditor, ICONS, TEXTS, tableActionsOptions, TRACKED_MARK_NAMES;
323387
- var init_src_DGC_pZIT_es = __esm(() => {
323579
+ var init_src_BkVhvl5H_es = __esm(() => {
323388
323580
  init_rolldown_runtime_Bg48TavK_es();
323389
- init_SuperConverter_DAuqlmYY_es();
323581
+ init_SuperConverter_kHxKGgu_es();
323390
323582
  init_jszip_C49i9kUs_es();
323391
323583
  init_xml_js_CqGKpaft_es();
323392
323584
  init_uuid_B2wVPhPi_es();
323393
- init_create_headless_toolbar_BT0XKtIW_es();
323585
+ init_create_headless_toolbar_DYsLIQ7b_es();
323394
323586
  init_constants_D9qj59G2_es();
323395
323587
  init_dist_B8HfvhaK_es();
323396
323588
  init_unified_Dsuw2be5_es();
@@ -344210,15 +344402,7 @@ function print() { __p += __j.call(arguments, '') }
344210
344402
  };
344211
344403
  }
344212
344404
  }, [["__scopeId", "data-v-d25821a5"]]);
344213
- TOOLBAR_FONTS = getBuiltInToolbarFontOfferings().map((offering) => ({
344214
- label: offering.logicalFamily,
344215
- key: fontOfferingStack(offering),
344216
- fontWeight: 400,
344217
- props: {
344218
- style: { fontFamily: fontOfferingRenderStack(offering) },
344219
- "data-item": "btn-fontFamily-option"
344220
- }
344221
- }));
344405
+ TOOLBAR_FONTS = toolbarFontOptionsFor(BASELINE_BUNDLED);
344222
344406
  TOOLBAR_FONT_SIZES = [
344223
344407
  {
344224
344408
  label: "8",
@@ -346796,7 +346980,7 @@ function print() { __p += __j.call(arguments, '') }
346796
346980
  this.overflowItems = overflowItems.filter((item) => allConfigItems.includes(item.name.value));
346797
346981
  }
346798
346982
  #resolveToolbarFonts(configFonts) {
346799
- return composeToolbarFontOptions(this.superdoc?.fonts?.getDocumentFontOptions?.() ?? [], configFonts);
346983
+ return composeToolbarFontOptions(this.superdoc?.fonts?.getDocumentFontOptions?.() ?? [], configFonts, deriveBundledActivation(this.superdoc?.config?.fonts));
346800
346984
  }
346801
346985
  #rebuildToolbarItems() {
346802
346986
  this.#makeToolbarItems({
@@ -352884,10 +353068,14 @@ function print() { __p += __j.call(arguments, '') }
352884
353068
  getRequiredFaces: () => this.#fontPlan?.requiredFaces ?? [],
352885
353069
  getUsedFaces: () => this.#fontPlan?.usedFaces ?? [],
352886
353070
  fontResolver: this.#fontResolver,
352887
- onRegistryResolved: (registry3) => installBundledSubstitutes(registry3, {
352888
- assetBaseUrl: this.#options.fontAssets?.assetBaseUrl,
352889
- resolveAssetUrl: this.#options.fontAssets?.resolveAssetUrl
352890
- }),
353071
+ onRegistryResolved: (registry3) => {
353072
+ if (!deriveBundledActivation(this.#options.fontAssets).packConfigured)
353073
+ return;
353074
+ installBundledSubstitutes(registry3, {
353075
+ assetBaseUrl: this.#options.fontAssets?.assetBaseUrl,
353076
+ resolveAssetUrl: this.#options.fontAssets?.resolveAssetUrl
353077
+ });
353078
+ },
352891
353079
  getFontEnvironment: () => {
352892
353080
  const ownerDoc = this.#visibleHost?.ownerDocument ?? (typeof document !== "undefined" ? document : null);
352893
353081
  const view = ownerDoc?.defaultView ?? (typeof window !== "undefined" ? window : null);
@@ -359177,11 +359365,11 @@ function print() { __p += __j.call(arguments, '') }
359177
359365
  ]);
359178
359366
  });
359179
359367
 
359180
- // ../../packages/superdoc/dist/chunks/create-super-doc-ui-Zmv88GYo.es.js
359368
+ // ../../packages/superdoc/dist/chunks/create-super-doc-ui-VZsj-Y0e.es.js
359181
359369
  var DEFAULT_TEXT_ALIGN_OPTIONS, DEFAULT_LINE_HEIGHT_OPTIONS, DEFAULT_ZOOM_OPTIONS, DEFAULT_DOCUMENT_MODE_OPTIONS, DEFAULT_FONT_SIZE_OPTIONS, headlessToolbarConstants, MOD_ALIASES, ALT_ALIASES, CTRL_ALIASES, SHIFT_ALIASES, BUILTIN_CONTEXT_MENU_GROUPS, BUILTIN_GROUP_ORDER, RESERVED_PROXY_PROPERTY_NAMES, ALL_TOOLBAR_COMMAND_IDS, EMPTY_ACTIVE_IDS, FONT_SIZE_OPTIONS;
359182
- var init_create_super_doc_ui_Zmv88GYo_es = __esm(() => {
359183
- init_SuperConverter_DAuqlmYY_es();
359184
- init_create_headless_toolbar_BT0XKtIW_es();
359370
+ var init_create_super_doc_ui_VZsj_Y0e_es = __esm(() => {
359371
+ init_SuperConverter_kHxKGgu_es();
359372
+ init_create_headless_toolbar_DYsLIQ7b_es();
359185
359373
  DEFAULT_TEXT_ALIGN_OPTIONS = [
359186
359374
  {
359187
359375
  label: "Left",
@@ -359472,16 +359660,16 @@ var init_zipper_yaJVJ4z9_es = __esm(() => {
359472
359660
 
359473
359661
  // ../../packages/superdoc/dist/super-editor.es.js
359474
359662
  var init_super_editor_es = __esm(() => {
359475
- init_src_DGC_pZIT_es();
359476
- init_SuperConverter_DAuqlmYY_es();
359663
+ init_src_BkVhvl5H_es();
359664
+ init_SuperConverter_kHxKGgu_es();
359477
359665
  init_jszip_C49i9kUs_es();
359478
359666
  init_xml_js_CqGKpaft_es();
359479
- init_create_headless_toolbar_BT0XKtIW_es();
359667
+ init_create_headless_toolbar_DYsLIQ7b_es();
359480
359668
  init_constants_D9qj59G2_es();
359481
359669
  init_dist_B8HfvhaK_es();
359482
359670
  init_unified_Dsuw2be5_es();
359483
359671
  init_DocxZipper_FUsfThjV_es();
359484
- init_create_super_doc_ui_Zmv88GYo_es();
359672
+ init_create_super_doc_ui_VZsj_Y0e_es();
359485
359673
  init_ui_C5PAS9hY_es();
359486
359674
  init_eventemitter3_BnGqBE_Q_es();
359487
359675
  init_errors_CNaD6vcg_es();
@@ -463175,6 +463363,30 @@ var init_bundled_manifest = __esm(() => {
463175
463363
  ]);
463176
463364
  });
463177
463365
 
463366
+ // ../../shared/font-system/src/bundled.ts
463367
+ var installedRegistries2;
463368
+ var init_bundled = __esm(() => {
463369
+ init_bundled_manifest();
463370
+ init_bundled_manifest();
463371
+ installedRegistries2 = new WeakMap;
463372
+ });
463373
+
463374
+ // ../../shared/font-system/src/activation.ts
463375
+ var FULLY_ACTIVE_BUNDLED2, BASELINE_BUNDLED2;
463376
+ var init_activation = __esm(() => {
463377
+ init_bundled();
463378
+ FULLY_ACTIVE_BUNDLED2 = Object.freeze({
463379
+ packConfigured: true,
463380
+ isActive: () => true,
463381
+ signature: ""
463382
+ });
463383
+ BASELINE_BUNDLED2 = Object.freeze({
463384
+ packConfigured: false,
463385
+ isActive: () => false,
463386
+ signature: JSON.stringify({ p: false })
463387
+ });
463388
+ });
463389
+
463178
463390
  // ../../shared/font-system/src/substitution-evidence.ts
463179
463391
  var SUBSTITUTION_EVIDENCE3;
463180
463392
  var init_substitution_evidence = __esm(() => {
@@ -463274,6 +463486,19 @@ class FontResolver2 {
463274
463486
  #embedded = new Map;
463275
463487
  #version = 0;
463276
463488
  #cachedSignature = null;
463489
+ #activation;
463490
+ constructor(activation = FULLY_ACTIVE_BUNDLED2) {
463491
+ this.#activation = activation;
463492
+ }
463493
+ setActivation(activation) {
463494
+ if (this.#activation.signature === activation.signature) {
463495
+ this.#activation = activation;
463496
+ return;
463497
+ }
463498
+ this.#activation = activation;
463499
+ this.#version += 1;
463500
+ this.#cachedSignature = null;
463501
+ }
463277
463502
  map(logicalFamily, physicalFamily) {
463278
463503
  const key2 = normalizeFamilyKey3(logicalFamily);
463279
463504
  const physical = physicalFamily?.trim();
@@ -463330,11 +463555,23 @@ class FontResolver2 {
463330
463555
  get signature() {
463331
463556
  if (this.#cachedSignature !== null)
463332
463557
  return this.#cachedSignature;
463333
- if (this.#overrides.size === 0 && this.#embedded.size === 0) {
463558
+ const activation = this.#activation.signature;
463559
+ const hasOverrides = this.#overrides.size > 0;
463560
+ const hasEmbedded = this.#embedded.size > 0;
463561
+ if (!hasOverrides && !hasEmbedded && activation === "") {
463334
463562
  this.#cachedSignature = "";
463563
+ return this.#cachedSignature;
463564
+ }
463565
+ const overridePairs = sortPairs2([...this.#overrides.entries()]);
463566
+ if (activation === "") {
463567
+ this.#cachedSignature = !hasEmbedded ? JSON.stringify(overridePairs) : JSON.stringify({ o: overridePairs, e: sortPairs2([...this.#embedded.entries()]) });
463335
463568
  } else {
463336
- const overridePairs = sortPairs2([...this.#overrides.entries()]);
463337
- this.#cachedSignature = this.#embedded.size === 0 ? JSON.stringify(overridePairs) : JSON.stringify({ o: overridePairs, e: sortPairs2([...this.#embedded.entries()]) });
463569
+ const obj = { a: activation };
463570
+ if (hasOverrides)
463571
+ obj.o = overridePairs;
463572
+ if (hasEmbedded)
463573
+ obj.e = sortPairs2([...this.#embedded.entries()]);
463574
+ this.#cachedSignature = JSON.stringify(obj);
463338
463575
  }
463339
463576
  return this.#cachedSignature;
463340
463577
  }
@@ -463343,12 +463580,14 @@ class FontResolver2 {
463343
463580
  const override = this.#overrides.get(key2);
463344
463581
  if (override)
463345
463582
  return { physical: override, reason: "custom_mapping" };
463346
- const bundled = BUNDLED_SUBSTITUTES2[key2];
463347
- if (bundled)
463348
- return { physical: bundled, reason: "bundled_substitute" };
463349
- const category = CATEGORY_FALLBACKS2[key2];
463350
- if (category)
463351
- return { physical: category, reason: "category_fallback" };
463583
+ if (this.#activation.isActive(bareFamily)) {
463584
+ const bundled = BUNDLED_SUBSTITUTES2[key2];
463585
+ if (bundled)
463586
+ return { physical: bundled, reason: "bundled_substitute" };
463587
+ const category = CATEGORY_FALLBACKS2[key2];
463588
+ if (category)
463589
+ return { physical: category, reason: "category_fallback" };
463590
+ }
463352
463591
  return { physical: bareFamily, reason: "as_requested" };
463353
463592
  }
463354
463593
  #resolveFaceLadder(primary, face, hasFace) {
@@ -463364,10 +463603,13 @@ class FontResolver2 {
463364
463603
  if (hasFace(primary, face.weight, face.style)) {
463365
463604
  return { physical: primary, reason: "registered_face" };
463366
463605
  }
463367
- const docfonts = resolveDocfontsFace2(primary, face, hasFace);
463368
- if (docfonts)
463369
- return docfonts;
463370
- const bundled = BUNDLED_SUBSTITUTES2[key2];
463606
+ const active = this.#activation.isActive(primary);
463607
+ if (active) {
463608
+ const docfonts = resolveDocfontsFace2(primary, face, hasFace);
463609
+ if (docfonts)
463610
+ return docfonts;
463611
+ }
463612
+ const bundled = active ? BUNDLED_SUBSTITUTES2[key2] : undefined;
463371
463613
  if (override || bundled) {
463372
463614
  return { physical: primary, reason: "fallback_face_absent" };
463373
463615
  }
@@ -463433,6 +463675,7 @@ function resolvePhysicalFamily2(cssFontFamily) {
463433
463675
  var bundledFamilies2, canRenderFamily2 = (family3) => bundledFamilies2.has(family3), BUNDLED_SUBSTITUTES2, CATEGORY_FALLBACKS2, defaultResolver2, DEFAULT_FONT_MEASURE_CONTEXT2;
463434
463676
  var init_resolver = __esm(() => {
463435
463677
  init_dist11();
463678
+ init_activation();
463436
463679
  init_bundled_manifest();
463437
463680
  init_substitution_evidence();
463438
463681
  bundledFamilies2 = new Set(BUNDLED_MANIFEST2.map((f2) => f2.family));
@@ -463444,14 +463687,6 @@ var init_resolver = __esm(() => {
463444
463687
  fontSignature: ""
463445
463688
  });
463446
463689
  });
463447
- // ../../shared/font-system/src/bundled.ts
463448
- var installedRegistries2;
463449
- var init_bundled = __esm(() => {
463450
- init_bundled_manifest();
463451
- init_bundled_manifest();
463452
- installedRegistries2 = new WeakMap;
463453
- });
463454
-
463455
463690
  // ../../shared/font-system/src/report.ts
463456
463691
  var init_report = __esm(() => {
463457
463692
  init_resolver();
@@ -463544,6 +463779,7 @@ class FontRegistry2 {
463544
463779
  #status = new Map;
463545
463780
  #sources = new Map;
463546
463781
  #warnedFailures = new Set;
463782
+ #warnedBundledSubstituteFailure = false;
463547
463783
  #inflight = new Map;
463548
463784
  #faceStatus = new Map;
463549
463785
  #faceInflight = new Map;
@@ -463779,6 +464015,10 @@ class FontRegistry2 {
463779
464015
  }
463780
464016
  }
463781
464017
  #warnFaceFailureOnce(request, key2) {
464018
+ if (BUNDLED_SUBSTITUTE_FAMILIES2.has(request.family)) {
464019
+ this.#warnBundledSubstituteFailureOnce(request.family);
464020
+ return;
464021
+ }
463782
464022
  if (this.#warnedFaceFailures.has(key2))
463783
464023
  return;
463784
464024
  this.#warnedFaceFailures.add(key2);
@@ -463818,6 +464058,10 @@ class FontRegistry2 {
463818
464058
  }
463819
464059
  }
463820
464060
  #warnLoadFailureOnce(family3) {
464061
+ if (BUNDLED_SUBSTITUTE_FAMILIES2.has(family3)) {
464062
+ this.#warnBundledSubstituteFailureOnce(family3);
464063
+ return;
464064
+ }
463821
464065
  if (this.#warnedFailures.has(family3))
463822
464066
  return;
463823
464067
  this.#warnedFailures.add(family3);
@@ -463825,9 +464069,22 @@ class FontRegistry2 {
463825
464069
  const detail = sources && sources.length ? ` from ${sources.join(", ")}` : "";
463826
464070
  console.warn(`[superdoc] font asset failed to load for "${family3}"${detail}. ` + `Check fonts.assetBaseUrl / fonts.resolveAssetUrl so the bundled .woff2 are served.`);
463827
464071
  }
464072
+ #warnBundledSubstituteFailureOnce(family3) {
464073
+ if (this.#warnedBundledSubstituteFailure)
464074
+ return;
464075
+ this.#warnedBundledSubstituteFailure = true;
464076
+ console.warn(`[superdoc] Bundled fallback fonts failed to load (e.g. "${family3}"). Text will render with ` + `system fallbacks, so some fonts may look unchanged on machines that lack them. Fix one of:
464077
+ ` + ` - install @superdoc-dev/fonts and pass it:
464078
+ ` + ` import { superdocFonts } from '@superdoc-dev/fonts';
464079
+ ` + ` new SuperDoc({ /* ... */ fonts: superdocFonts });
464080
+ ` + ` - or set fonts.assetBaseUrl / fonts.resolveAssetUrl to where the bundled .woff2 are served.
464081
+ ` + `Docs: https://docs.superdoc.dev/getting-started/fonts`);
464082
+ }
463828
464083
  }
463829
- var DEFAULT_FONT_LOAD_TIMEOUT_MS2 = 3000, DEFAULT_PROBE_SIZE2 = "16px", registriesByFontSet2;
464084
+ var BUNDLED_SUBSTITUTE_FAMILIES2, DEFAULT_FONT_LOAD_TIMEOUT_MS2 = 3000, DEFAULT_PROBE_SIZE2 = "16px", registriesByFontSet2;
463830
464085
  var init_registry2 = __esm(() => {
464086
+ init_bundled_manifest();
464087
+ BUNDLED_SUBSTITUTE_FAMILIES2 = new Set(BUNDLED_MANIFEST2.map((f2) => f2.family));
463831
464088
  registriesByFontSet2 = new WeakMap;
463832
464089
  });
463833
464090
 
@@ -463860,12 +464117,17 @@ function deriveOfferings2() {
463860
464117
  });
463861
464118
  return Object.freeze(offerings);
463862
464119
  }
463863
- var BUNDLED_FAMILIES2, SUPPORTED_ALIAS_FAMILIES2, ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES2, FONT_OFFERINGS2;
464120
+ function normalizeFamilyKey5(family3) {
464121
+ return family3.trim().replace(/^["']|["']$/g, "").toLowerCase();
464122
+ }
464123
+ var BUNDLED_FAMILIES2, SUPPORTED_ALIAS_FAMILIES2, BUILT_IN_TOOLBAR_BASELINE_FAMILIES2, ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES2, FONT_OFFERINGS2, BUNDLED_LOGICAL_FAMILIES2, BUNDLED_LOGICAL_KEYS2;
463864
464124
  var init_font_offerings = __esm(() => {
464125
+ init_activation();
463865
464126
  init_bundled_manifest();
463866
464127
  init_substitution_evidence();
463867
464128
  BUNDLED_FAMILIES2 = new Set(BUNDLED_MANIFEST2.map((f2) => f2.family));
463868
464129
  SUPPORTED_ALIAS_FAMILIES2 = new Set(["Arial MT", "Courier", "Times"]);
464130
+ BUILT_IN_TOOLBAR_BASELINE_FAMILIES2 = new Set(["Arial", "Courier New", "Times New Roman"]);
463869
464131
  ADVERTISED_BUILT_IN_TOOLBAR_FAMILIES2 = new Set([
463870
464132
  "Arial Black",
463871
464133
  "Arial Narrow",
@@ -463886,10 +464148,15 @@ var init_font_offerings = __esm(() => {
463886
464148
  "Verdana"
463887
464149
  ]);
463888
464150
  FONT_OFFERINGS2 = deriveOfferings2();
464151
+ BUNDLED_LOGICAL_FAMILIES2 = [
464152
+ ...new Set(FONT_OFFERINGS2.filter((o) => o.bundled).map((o) => o.logicalFamily))
464153
+ ].sort((a2, b2) => a2.localeCompare(b2, "en", { sensitivity: "base" }));
464154
+ BUNDLED_LOGICAL_KEYS2 = new Set(BUNDLED_LOGICAL_FAMILIES2.map(normalizeFamilyKey5));
463889
464155
  });
463890
464156
 
463891
464157
  // ../../shared/font-system/src/document-font-options.ts
463892
464158
  var init_document_font_options = __esm(() => {
464159
+ init_activation();
463893
464160
  init_report();
463894
464161
  init_font_offerings();
463895
464162
  });
@@ -463899,6 +464166,7 @@ var init_src5 = __esm(() => {
463899
464166
  init_types8();
463900
464167
  init_resolver();
463901
464168
  init_resolver();
464169
+ init_activation();
463902
464170
  init_bundled();
463903
464171
  init_report();
463904
464172
  init_os2();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superdoc-dev/mcp",
3
- "version": "0.12.0",
3
+ "version": "0.13.0",
4
4
  "type": "module",
5
5
  "engines": {
6
6
  "node": ">=20"
@@ -19,9 +19,9 @@
19
19
  "@types/bun": "^1.3.8",
20
20
  "@types/node": "22.19.2",
21
21
  "typescript": "^5.9.2",
22
+ "@superdoc/document-api": "0.0.1",
22
23
  "@superdoc/super-editor": "0.0.1",
23
- "superdoc": "1.39.0",
24
- "@superdoc/document-api": "0.0.1"
24
+ "superdoc": "1.40.1"
25
25
  },
26
26
  "publishConfig": {
27
27
  "access": "public"