fontmin-rs 1.1.0 → 1.2.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.
@@ -49,7 +49,7 @@
49
49
  "default": true
50
50
  },
51
51
  "parallel": {
52
- "description": "Reserved Rust CLI parallelism settings.",
52
+ "description": "Bounded per-file parallelism settings for Rust CLI and Node.js builds.",
53
53
  "$ref": "#/definitions/ParallelOptions"
54
54
  },
55
55
  "cache": {
@@ -313,6 +313,18 @@
313
313
  "description": "Cache directory.",
314
314
  "type": "string",
315
315
  "default": "node_modules/.cache/fontmin-rs"
316
+ },
317
+ "maxAgeMs": {
318
+ "description": "Maximum cache entry age in milliseconds before pruning.",
319
+ "type": "integer",
320
+ "minimum": 1,
321
+ "default": 2592000000
322
+ },
323
+ "maxEntries": {
324
+ "description": "Maximum number of persistent cache entries retained.",
325
+ "type": "integer",
326
+ "minimum": 1,
327
+ "default": 256
316
328
  }
317
329
  }
318
330
  },
package/dist/cli.mjs CHANGED
@@ -1,11 +1,11 @@
1
- import { A as subsetTtf, D as instantiateFont, E as inspectCollection, F as ttfToEot, H as woffToTtf, I as ttfToSvg, J as loadConfig, L as ttfToWoff, M as subsetTtfWithReport, O as otfToTtf, R as ttfToWoff2, S as extractCollectionFace, U as missingGlyphWarning, V as woff2ToTtf, W as normalizeDeliverySlices$1, a as expandInputPath, i as cleanOutputDirectory, k as reduceVariationSpace, q as findConfig, r as normalizeCacheOptions, s as resolveSubsetTextFile, t as optimize, w as inspect, x as eotToTtf, y as analyzeCoverage } from "./optimize-pipeline-BoD2Cm8l.mjs";
2
- import { a as glyph, i as deliverySlices, l as svgs2ttf } from "./plugins-DxYlVHuH.mjs";
1
+ import { A as reduceVariationSpace, C as extractCollectionFace, D as inspectCollection, G as normalizeDeliverySlices$1, H as woff2ToTtf, I as ttfToEot, J as findConfig, L as ttfToSvg, N as subsetTtfWithReport, O as instantiateFont, R as ttfToWoff, S as eotToTtf, T as inspect, U as woffToTtf, W as missingGlyphWarning, Y as loadConfig, a as cleanOutputDirectory, b as analyzeCoverage, c as resolveSubsetTextFile, i as atomicWriteFile, j as subsetTtf, k as otfToTtf, o as expandInputPath, r as normalizeCacheOptions, t as optimize, z as ttfToWoff2 } from "./optimize-pipeline-XbDo08bZ.mjs";
2
+ import { a as glyph, i as deliverySlices, l as svgs2ttf } from "./plugins-DsijrTfF.mjs";
3
3
  import { mkdir, readFile, stat, writeFile } from "node:fs/promises";
4
4
  import { basename, dirname, extname, resolve } from "node:path";
5
5
  //#region src/cli.mjs
6
6
  const INIT_CONFIG_FILE = "fontmin.config.jsonc";
7
7
  const CONFIG_SCHEMA_PATH = "./node_modules/fontmin-rs/configuration_schema.json";
8
- const FONTMIN_VERSION = "1.1.0";
8
+ const FONTMIN_VERSION = "1.2.0";
9
9
  let emitWarnings = true;
10
10
  const DEFAULT_INIT_CONFIG = `{
11
11
  // Generated by fontmin-rs init.
@@ -108,7 +108,8 @@ async function coverageCommand(args) {
108
108
  const [input] = args;
109
109
  requireValue(input, "coverage requires an input font");
110
110
  if (options.text === void 0 && options.unicodes.length === 0 && !basicText) throw new Error("coverage requires --text, --text-file, --unicodes, or --basic-text");
111
- const report = analyzeCoverage(selectCollectionFace(await readFile(input), fontNumber), {
111
+ const contents = selectCollectionFace(await readFile(input), fontNumber);
112
+ const report = analyzeCoverage(contents, {
112
113
  basicText,
113
114
  text: options.text,
114
115
  unicodes: options.unicodes
@@ -221,6 +222,7 @@ async function runBuildCommand(args) {
221
222
  const outDir = readOption(args, ["-o", "--out-dir"]);
222
223
  const formats = readOption(args, ["--formats"]);
223
224
  const preset = readOption(args, ["--preset"]);
225
+ const parallel = parallelFromThreads(readOption(args, ["--threads"]));
224
226
  const basicText = readFlag(args, ["-b", "--basic-text"]);
225
227
  const fontFamily = readOption(args, ["--font-family"]);
226
228
  const fontPath = readOption(args, ["--font-path"]);
@@ -242,6 +244,7 @@ async function runBuildCommand(args) {
242
244
  cssUnicodeRanges,
243
245
  deliverySlices,
244
246
  outDir,
247
+ parallel,
245
248
  variationCoordinates
246
249
  });
247
250
  return;
@@ -259,6 +262,7 @@ async function runBuildCommand(args) {
259
262
  inputs: [...args],
260
263
  noOriginal,
261
264
  outDir,
265
+ parallel,
262
266
  preset,
263
267
  subsetOptions,
264
268
  variationCoordinates
@@ -277,6 +281,7 @@ async function runBuildCommand(args) {
277
281
  cssUnicodeRanges,
278
282
  deliverySlices,
279
283
  outDir,
284
+ parallel,
280
285
  variationCoordinates
281
286
  });
282
287
  return;
@@ -293,6 +298,7 @@ async function runBuildCommand(args) {
293
298
  formats,
294
299
  noOriginal,
295
300
  outDir,
301
+ parallel,
296
302
  preset,
297
303
  subsetOptions,
298
304
  variationCoordinates
@@ -309,7 +315,7 @@ async function runBuildCommand(args) {
309
315
  if (autoDelivery !== void 0) throw new Error("iconfont preset does not support automatic delivery slices");
310
316
  const inputs = await expandInputPaths(inputPatterns, process.cwd());
311
317
  const cacheOptions = normalizeCacheOptions(void 0, process.cwd(), cacheOverride);
312
- await buildIconfontCommand(inputs, outDir, fontFamily, fontPath ?? "./", [], {}, cacheOptions, cssUnicodeRanges);
318
+ await buildIconfontCommand(inputs, outDir, fontFamily, fontPath ?? "./", parallel, [], {}, cacheOptions, cssUnicodeRanges);
313
319
  return;
314
320
  }
315
321
  const inputs = await expandInputPaths(inputPatterns, process.cwd());
@@ -328,11 +334,12 @@ async function runBuildCommand(args) {
328
334
  fontFamily,
329
335
  fontPath,
330
336
  outputFormats,
337
+ parallel,
331
338
  subsetOptions,
332
339
  variationCoordinates
333
340
  });
334
341
  }
335
- async function buildDirectInput(input, outDir, { basicText, autoDelivery, cacheOptions, cssGlyph, cssUnicodeRanges, deliverySlices: deliverySlices$1, fontFamily, fontPath, outputFormats, subsetOptions, variationCoordinates }) {
342
+ async function buildDirectInput(input, outDir, { basicText, autoDelivery, cacheOptions, cssGlyph, cssUnicodeRanges, deliverySlices: deliverySlices$1, fontFamily, fontPath, outputFormats, parallel, subsetOptions, variationCoordinates }) {
336
343
  const baseName = basename(input, extname(input));
337
344
  const shouldSubset = !(subsetOptions.text === void 0 && subsetOptions.unicodes.length === 0 && subsetOptions.gids.length === 0 && subsetOptions.glyphNames.length === 0 && subsetOptions.layoutFeatures.length === 0 && subsetOptions.layoutScripts.length === 0 && subsetOptions.layoutLanguages.length === 0 && subsetOptions.nameIds.length === 0 && subsetOptions.nameLanguages.length === 0 && subsetOptions.dropTables.length === 0 && subsetOptions.passThroughTables.length === 0 && !basicText);
338
345
  const plugins = [normalizeToTtfPlugin(variationCoordinates)];
@@ -368,6 +375,7 @@ async function buildDirectInput(input, outDir, { basicText, autoDelivery, cacheO
368
375
  input: [input],
369
376
  outDir,
370
377
  outputs: outputFormats,
378
+ parallel,
371
379
  plugins
372
380
  });
373
381
  }
@@ -386,7 +394,7 @@ function reportShowTime(startedAt) {
386
394
  const elapsedMs = Number(process.hrtime.bigint() - startedAt) / 1e6;
387
395
  process.stdout.write(`fontmin-rs build completed in ${Math.round(elapsedMs)} ms\n`);
388
396
  }
389
- async function buildIconfontCommand(inputs, outDir, fontFamily, fontPath, outputs = [], css = {}, cacheOptions = normalizeCacheOptions(void 0, process.cwd()), cssUnicodeRanges = css.unicodeRanges ?? []) {
397
+ async function buildIconfontCommand(inputs, outDir, fontFamily, fontPath, parallel, outputs = [], css = {}, cacheOptions = normalizeCacheOptions(void 0, process.cwd()), cssUnicodeRanges = css.unicodeRanges ?? []) {
390
398
  if (inputs.length === 0) throw new Error("build requires at least one input font");
391
399
  const family = fontFamily ?? "iconfont";
392
400
  const fileName = outputFileName(outputs, "ttf", "iconfont.ttf");
@@ -410,10 +418,11 @@ async function buildIconfontCommand(inputs, outDir, fontFamily, fontPath, output
410
418
  fileName: cssFileName,
411
419
  format: "css"
412
420
  }],
421
+ parallel,
413
422
  plugins: [svgs2ttf({ fontName: family })]
414
423
  });
415
424
  }
416
- async function buildConfigCommand(configPath, { autoDelivery, basicText, cacheOverride, cssGlyph, cssUnicodeRanges = [], deliverySlices = [], fontFamily, fontPath, formats, inputs: inputOverrides = [], noOriginal, outDir: outDirOverride, preset, subsetOptions, variationCoordinates = {} } = {}) {
425
+ async function buildConfigCommand(configPath, { autoDelivery, basicText, cacheOverride, cssGlyph, cssUnicodeRanges = [], deliverySlices = [], fontFamily, fontPath, formats, inputs: inputOverrides = [], noOriginal, outDir: outDirOverride, parallel, preset, subsetOptions, variationCoordinates = {} } = {}) {
417
426
  const resolvedConfigPath = resolve(configPath);
418
427
  const config = await loadConfig(resolvedConfigPath);
419
428
  const cwd = typeof config.cwd === "string" ? resolve(config.cwd) : dirname(resolvedConfigPath);
@@ -440,6 +449,7 @@ async function buildConfigCommand(configPath, { autoDelivery, basicText, cacheOv
440
449
  };
441
450
  if (deliverySlices.length > 0) config.delivery = { slices: deliverySlices };
442
451
  if (autoDelivery !== void 0) config.autoDelivery = autoDelivery;
452
+ if (parallel !== void 0) config.parallel = parallel;
443
453
  if (config.autoDelivery !== void 0 && normalizeDeliverySlices(config.delivery?.slices ?? []).length > 0) throw new Error("build accepts only one of autoDelivery or delivery slices");
444
454
  applySubsetOverrides(config, {
445
455
  basicText,
@@ -449,7 +459,7 @@ async function buildConfigCommand(configPath, { autoDelivery, basicText, cacheOv
449
459
  await mkdir(outDir, { recursive: true });
450
460
  for (const inputPath of inputPaths) await buildConfigInput(inputPath, outDir, outputFormats, config, cwd, cacheOptions, resolvedVariationCoordinates);
451
461
  }
452
- async function buildIconfontConfigCommand(configPath, { autoDelivery, cacheOverride, cssUnicodeRanges = [], deliverySlices = [], fontFamily, fontPath, formats, inputs: inputOverrides = [], outDir: outDirOverride }) {
462
+ async function buildIconfontConfigCommand(configPath, { autoDelivery, cacheOverride, cssUnicodeRanges = [], deliverySlices = [], fontFamily, fontPath, formats, inputs: inputOverrides = [], outDir: outDirOverride, parallel }) {
453
463
  if (formats !== void 0) throw new Error("build accepts only one of --formats or --preset");
454
464
  const resolvedConfigPath = resolve(configPath);
455
465
  const config = await loadConfig(resolvedConfigPath);
@@ -461,10 +471,11 @@ async function buildIconfontConfigCommand(configPath, { autoDelivery, cacheOverr
461
471
  if (cssUnicodeRanges.length > 0) css.unicodeRanges = cssUnicodeRanges;
462
472
  if (deliverySlices.length > 0) config.delivery = { slices: deliverySlices };
463
473
  if (autoDelivery !== void 0) config.autoDelivery = autoDelivery;
474
+ if (parallel !== void 0) config.parallel = parallel;
464
475
  if (normalizeDeliverySlices(config.delivery?.slices ?? []).length > 0) throw new Error("iconfont preset does not support delivery slices");
465
476
  if (config.autoDelivery !== void 0) throw new Error("iconfont preset does not support automatic delivery slices");
466
477
  if (config.clean === true) await cleanOutputDirectory(cwd, outDir, [resolvedConfigPath, ...inputs]);
467
- await buildIconfontCommand(inputs, outDir, fontFamily ?? css.fontFamily, fontPath ?? css.fontPath ?? "./", config.outputs ?? [], css, cacheOptions, css.unicodeRanges);
478
+ await buildIconfontCommand(inputs, outDir, fontFamily ?? css.fontFamily, fontPath ?? css.fontPath ?? "./", config.parallel, config.outputs ?? [], css, cacheOptions, css.unicodeRanges);
468
479
  }
469
480
  function expandConfigInputPaths(inputs, cwd) {
470
481
  return expandInputPaths(inputs, cwd);
@@ -526,6 +537,7 @@ async function buildConfigInput(input, outDir, outputFormats, config, cwd, cache
526
537
  input: [input],
527
538
  outDir,
528
539
  outputs: outputConfigsForFormats(config.outputs, outputFormats),
540
+ parallel: config.parallel,
529
541
  plugins,
530
542
  preserveOriginal: config.preserveOriginal,
531
543
  runtime: config.runtime
@@ -621,7 +633,8 @@ function warnForMissingUnicode(contents, options) {
621
633
  const policy = options.missingGlyphs ?? "warn";
622
634
  const hasUnicodeSelection = options.basicText === true || options.text !== void 0 || options.unicodes.length > 0;
623
635
  if (policy === "warn" && hasUnicodeSelection) {
624
- const warning = missingGlyphWarning(analyzeCoverage(contents, options));
636
+ const report = analyzeCoverage(contents, options);
637
+ const warning = missingGlyphWarning(report);
625
638
  if (warning !== void 0 && emitWarnings) process.stderr.write(`warning: ${warning}\n`);
626
639
  }
627
640
  }
@@ -768,6 +781,10 @@ function parseOptionalPositiveInteger(value, option) {
768
781
  if (!Number.isSafeInteger(parsed)) throw new TypeError(`${option} must be a safe positive integer`);
769
782
  return parsed;
770
783
  }
784
+ function parallelFromThreads(value) {
785
+ const count = parseOptionalPositiveInteger(value, "--threads");
786
+ return count === void 0 ? void 0 : { threads: { count } };
787
+ }
771
788
  function normalizeDeliverySlices(values) {
772
789
  return normalizeDeliverySlices$1(values, { allowEmpty: true }).map((slice) => ({
773
790
  name: slice.name,
@@ -959,7 +976,7 @@ function requireValue(value, message) {
959
976
  }
960
977
  async function writeOutput(output, contents) {
961
978
  await mkdir(dirname(output), { recursive: true });
962
- await writeFile(output, contents);
979
+ await atomicWriteFile(output, contents);
963
980
  }
964
981
  function usage(stream) {
965
982
  stream.write(`Usage:
@@ -967,7 +984,7 @@ function usage(stream) {
967
984
  fontmin-rs coverage <INPUT> (-t|--text <TEXT> | --text-file <FILE> | --unicodes <LIST> | -b|--basic-text) [--font-number <INDEX>] [--json]
968
985
  fontmin-rs convert <INPUT> -f|--format <ttf|woff|woff2|eot|svg> -o|--output <OUTPUT> [--font-number <INDEX>] [--variation <TAG=VALUE>]...
969
986
  fontmin-rs instance <INPUT> -o|--output <OUTPUT> [--font-number <INDEX>] [--variation <TAG=VALUE>]... [--variation-range <TAG=MIN:MAX[:DEFAULT]>]... [--keep-variable] [--downgrade-cff2]
970
- fontmin-rs build <INPUT...> [-c|--config <CONFIG>] [-o|--out-dir <OUT_DIR>] [-t|--text <TEXT>] [--text-file <FILE>] [--unicodes <LIST>] [--gids <LIST>] [--glyph-names <NAMES>] [--retain-gids] [--retain-glyph-names] [--retain-legacy-cmap] [--retain-symbol-cmap] [--layout-features <TAGS>] [--layout-scripts <TAGS>] [--layout-languages <TAGS>] [--name-ids <IDS>] [--name-languages <IDS>] [--drop-tables <TAGS>] [--pass-through-tables <TAGS>] [-b|--basic-text] [--missing-glyphs <ignore|warn|error>] [-d|--deflate-woff] [-T|--show-time] [--silent] [--cache] [--no-cache] [--css-glyph] [--css-unicode-range <RANGE>]... [--delivery-slice <NAME:RANGE[,RANGE...]>]... [--auto-delivery] [--delivery-languages <LANGUAGES>] [--delivery-frequency-text <TEXT>] [--delivery-target-bytes <BYTES>] [--delivery-tolerance <FRACTION>] [--delivery-max-slices <COUNT>] [--delivery-measure-format <ttf|woff|woff2>] [--variation <TAG=VALUE>]... [--formats <FORMATS>] [--preset <compat|modern-web|iconfont>] [--no-original] [--font-family <FONT_FAMILY>] [--font-path <FONT_PATH>]
987
+ fontmin-rs build <INPUT...> [-c|--config <CONFIG>] [-o|--out-dir <OUT_DIR>] [-t|--text <TEXT>] [--text-file <FILE>] [--unicodes <LIST>] [--gids <LIST>] [--glyph-names <NAMES>] [--retain-gids] [--retain-glyph-names] [--retain-legacy-cmap] [--retain-symbol-cmap] [--layout-features <TAGS>] [--layout-scripts <TAGS>] [--layout-languages <TAGS>] [--name-ids <IDS>] [--name-languages <IDS>] [--drop-tables <TAGS>] [--pass-through-tables <TAGS>] [-b|--basic-text] [--missing-glyphs <ignore|warn|error>] [-d|--deflate-woff] [-T|--show-time] [--silent] [--threads <COUNT>] [--cache] [--no-cache] [--css-glyph] [--css-unicode-range <RANGE>]... [--delivery-slice <NAME:RANGE[,RANGE...]>]... [--auto-delivery] [--delivery-languages <LANGUAGES>] [--delivery-frequency-text <TEXT>] [--delivery-target-bytes <BYTES>] [--delivery-tolerance <FRACTION>] [--delivery-max-slices <COUNT>] [--delivery-measure-format <ttf|woff|woff2>] [--variation <TAG=VALUE>]... [--formats <FORMATS>] [--preset <compat|modern-web|iconfont>] [--no-original] [--font-family <FONT_FAMILY>] [--font-path <FONT_PATH>]
971
988
  fontmin-rs bench <INPUT> [-t|--text <TEXT>] [--text-file <FILE>] [--unicodes <LIST>] [-b|--basic-text] [--font-number <INDEX>] [--json]
972
989
  fontmin-rs inspect <INPUT> [--font-number <INDEX>] [--json]
973
990
  fontmin-rs init
@@ -1,5 +1,5 @@
1
1
  import { t as FontminSubsetTextOptions } from "./compat-exports-DyKGeNd8.mjs";
2
- import { D as FontminCompatCssOptions, K as Svg2TtfOptions, P as FontminPlugin, T as FontAsset, d as ttf2svg, f as ttf2woff, i as deliverySlices, j as FontminConfig, k as FontminCompatGlyphOptions, l as svgs2ttf, p as ttf2woff2, u as ttf2eot, z as Otf2TtfOptions } from "./plugins-BEY324ti.mjs";
2
+ import { D as FontminCompatCssOptions, P as FontminPlugin, T as FontAsset, d as ttf2svg, f as ttf2woff, i as deliverySlices, j as FontminConfig, k as FontminCompatGlyphOptions, l as svgs2ttf, p as ttf2woff2, q as Svg2TtfOptions, u as ttf2eot, z as Otf2TtfOptions } from "./plugins-BjiQCO0q.mjs";
3
3
  import { PassThrough } from "node:stream";
4
4
  //#region src/compat.d.ts
5
5
  type FontminSource = string | string[] | Uint8Array;
@@ -1,5 +1,5 @@
1
- import { K as defineConfig, t as optimize } from "./optimize-pipeline-BoD2Cm8l.mjs";
2
- import { a as glyph, c as svg2ttf, d as ttf2svg, f as ttf2woff, i as deliverySlices, l as svgs2ttf, p as ttf2woff2, s as otf2ttf, u as ttf2eot, v as createBuiltinPlugin } from "./plugins-DxYlVHuH.mjs";
1
+ import { q as defineConfig, t as optimize } from "./optimize-pipeline-XbDo08bZ.mjs";
2
+ import { a as glyph, c as svg2ttf, d as ttf2svg, f as ttf2woff, i as deliverySlices, l as svgs2ttf, p as ttf2woff2, s as otf2ttf, u as ttf2eot, v as createBuiltinPlugin } from "./plugins-DsijrTfF.mjs";
3
3
  import { resolve } from "node:path";
4
4
  import { readdirSync } from "node:fs";
5
5
  import { PassThrough } from "node:stream";
package/dist/compat.d.mts CHANGED
@@ -1,3 +1,3 @@
1
1
  import { i as util, n as mime, r as plugins } from "./compat-exports-DyKGeNd8.mjs";
2
- import { t as FontminCompat } from "./compat-CaQYmIHb.mjs";
2
+ import { t as FontminCompat } from "./compat-CpBAsH66.mjs";
3
3
  export { FontminCompat as default, mime, plugins, util };
package/dist/compat.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import { i as util, n as mime, r as plugins, t as FontminCompat } from "./compat-BxQFeNHb.mjs";
1
+ import { i as util, n as mime, r as plugins, t as FontminCompat } from "./compat-D8l7c3fw.mjs";
2
2
  export { FontminCompat as default, mime, plugins, util };
package/dist/index.d.mts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { i as util, n as mime, r as plugins } from "./compat-exports-DyKGeNd8.mjs";
2
- import { $ as VariationSpacePluginOptions, A as FontminCompatPresetOptions, At as LayoutSubsetMode, B as OutputConfig, C as CssOptions, Ct as FontCollectionInfo, D as FontminCompatCssOptions, Dt as GidMapping, E as FontminCompatCssInfo, Et as FontMetadata, F as FontminTtfEditor, Ft as SvgIcon, G as SubsetPlan, H as PluginDiagnostic, I as FontminTtfObject, It as UnicodeGidMapping, J as Svgs2TtfOutput, K as Svg2TtfOptions, L as MaybePromise, Lt as VariationSpaceOptions, M as FontminGlyphTransform, Mt as OutputFormat, N as FontminOutputFile, Nt as SubsetReport, O as FontminCompatFontFamily, Ot as GlyphNameGidMapping, P as FontminPlugin, Pt as SubsetResult, Q as Ttf2WoffOptions, R as ModernWebOptions, Rt as WoffOptions, S as CssFontFamily, St as FontCollectionFaceInfo, T as FontAsset, Tt as FontInfo, U as RuntimeMode, V as PluginContext, W as SubsetOptions, X as Ttf2SvgOptions, Y as Ttf2EotOptions, Z as Ttf2Woff2Options, _ as AssetFormat, _t as CoverageOptions, a as glyph, at as AutoDeliveryPlan, b as CacheOptions, bt as CssGlyph, c as svg2ttf, ct as DeliveryLanguagePreset, d as ttf2svg, dt as AxisRange, et as WebDeliveryManifest, f as ttf2woff, ft as AxisSetting, g as ArtifactFormat, gt as ColorFontTechnologyCapability, h as webDelivery, ht as ColorFontTechnology, i as deliverySlices, it as WebDeliveryOptions, j as FontminConfig, jt as MissingGlyphPolicy, k as FontminCompatGlyphOptions, kt as InstanceOptions, l as svgs2ttf, lt as detectDeliveryLanguages, m as variationSpace, mt as ColorFontCapabilityReport, n as css, nt as WebDeliveryManifestSource, o as modernWeb, ot as AutoDeliveryPlanOptions, p as ttf2woff2, pt as CapabilitySupport, q as Svgs2TtfOptions, r as definePlugin, rt as WebDeliveryManifestSummary, s as otf2ttf, st as AutoDeliveryPlanSlice, t as autoDeliverySlices, tt as WebDeliveryManifestAsset, u as ttf2eot, ut as unicodeRangesFromCodePoints, v as AutoDeliveryOptions, vt as CoverageReport, w as DeliverySlice, wt as FontFormat, x as ConfigOutput, xt as FontCapabilityReport, y as AutoDeliverySubsetOptions, yt as CssFontSource, z as Otf2TtfOptions } from "./plugins-BEY324ti.mjs";
3
- import { t as FontminCompat } from "./compat-CaQYmIHb.mjs";
4
- import { t as fontminCompatPreset } from "./presets-DR1VXlhA.mjs";
2
+ import { $ as Ttf2WoffOptions, A as FontminCompatPresetOptions, At as InstanceOptions, B as OutputConfig, C as CssOptions, Ct as FontCollectionFaceInfo, D as FontminCompatCssOptions, Dt as FontMetadata, E as FontminCompatCssInfo, Et as FontInfo, F as FontminTtfEditor, Ft as SubsetResult, G as SubsetOptions, H as PluginContext, I as FontminTtfObject, It as SvgIcon, J as Svgs2TtfOptions, K as SubsetPlan, L as MaybePromise, Lt as UnicodeGidMapping, M as FontminGlyphTransform, Mt as MissingGlyphPolicy, N as FontminOutputFile, Nt as OutputFormat, O as FontminCompatFontFamily, Ot as GidMapping, P as FontminPlugin, Pt as SubsetReport, Q as Ttf2Woff2Options, R as ModernWebOptions, Rt as VariationSpaceOptions, S as CssFontFamily, St as FontCapabilityReport, T as FontAsset, Tt as FontFormat, U as PluginDiagnostic, V as ParallelOptions, W as RuntimeMode, X as Ttf2EotOptions, Y as Svgs2TtfOutput, Z as Ttf2SvgOptions, _ as AssetFormat, _t as ColorFontTechnologyCapability, a as glyph, at as WebDeliveryOptions, b as CacheOptions, bt as CssFontSource, c as svg2ttf, ct as AutoDeliveryPlanSlice, d as ttf2svg, dt as unicodeRangesFromCodePoints, et as VariationSpacePluginOptions, f as ttf2woff, ft as AxisRange, g as ArtifactFormat, gt as ColorFontTechnology, h as webDelivery, ht as ColorFontCapabilityReport, i as deliverySlices, it as WebDeliveryManifestSummary, j as FontminConfig, jt as LayoutSubsetMode, k as FontminCompatGlyphOptions, kt as GlyphNameGidMapping, l as svgs2ttf, lt as DeliveryLanguagePreset, m as variationSpace, mt as CapabilitySupport, n as css, nt as WebDeliveryManifestAsset, o as modernWeb, ot as AutoDeliveryPlan, p as ttf2woff2, pt as AxisSetting, q as Svg2TtfOptions, r as definePlugin, rt as WebDeliveryManifestSource, s as otf2ttf, st as AutoDeliveryPlanOptions, t as autoDeliverySlices, tt as WebDeliveryManifest, u as ttf2eot, ut as detectDeliveryLanguages, v as AutoDeliveryOptions, vt as CoverageOptions, w as DeliverySlice, wt as FontCollectionInfo, x as ConfigOutput, xt as CssGlyph, y as AutoDeliverySubsetOptions, yt as CoverageReport, z as Otf2TtfOptions, zt as WoffOptions } from "./plugins-BjiQCO0q.mjs";
3
+ import { t as FontminCompat } from "./compat-CpBAsH66.mjs";
4
+ import { t as fontminCompatPreset } from "./presets-L-mYLg94.mjs";
5
5
  //#region src/web-text.d.ts
6
6
  interface WebTextDiscoveryOptions {
7
7
  /** Project directory used to resolve file paths and globs. */
@@ -78,4 +78,4 @@ declare function generateFontFaceCss(sources: CssFontSource[], options?: CssOpti
78
78
  //#region src/optimize-pipeline.d.ts
79
79
  declare function optimize(unresolvedConfig: FontminConfig): Promise<FontAsset[]>;
80
80
  //#endregion
81
- export { type ArtifactFormat, type AssetFormat, type AutoDeliveryOptions, type AutoDeliveryPlan, type AutoDeliveryPlanOptions, type AutoDeliveryPlanSlice, type AutoDeliverySubsetOptions, type AxisRange, type AxisSetting, type CacheOptions, type CapabilitySupport, type ColorFontCapabilityReport, type ColorFontTechnology, type ColorFontTechnologyCapability, type ConfigOutput, type CoverageOptions, type CoverageReport, type CssFontFamily, type CssFontSource, type CssGlyph, type CssOptions, type DeliveryLanguagePreset, type DeliverySlice, type FontAsset, type FontCapabilityReport, type FontCollectionFaceInfo, type FontCollectionInfo, type FontFormat, type FontInfo, type FontMetadata, type FontminCompatCssInfo, type FontminCompatCssOptions, type FontminCompatFontFamily, type FontminCompatGlyphOptions, type FontminCompatPresetOptions, type FontminConfig, type FontminDiagnosticCode, FontminDiagnosticError, type FontminGlyphTransform, type FontminOutputFile, type FontminPlugin, type FontminTtfEditor, type FontminTtfObject, type GidMapping, type GlyphNameGidMapping, type InstanceOptions, type LayoutSubsetMode, type MaybePromise, type MissingGlyphPolicy, type ModernWebOptions, type Otf2TtfOptions, type OutputConfig, type OutputFormat, type PluginContext, type PluginDiagnostic, type RuntimeMode, type SubsetOptions, type SubsetPlan, type SubsetReport, type SubsetResult, type Svg2TtfOptions, type SvgIcon, type Svgs2TtfOptions, type Svgs2TtfOutput, type Ttf2EotOptions, type Ttf2SvgOptions, type Ttf2Woff2Options, type Ttf2WoffOptions, type UnicodeGidMapping, type VariationSpaceOptions, type VariationSpacePluginOptions, type WebDeliveryManifest, type WebDeliveryManifestAsset, type WebDeliveryManifestSource, type WebDeliveryManifestSummary, type WebDeliveryOptions, type WebTextDiscoveryOptions, type WebTextDiscoveryResult, type WoffOptions, analyzeCoverage, autoDeliverySlices, createTtfSubsetPlan, css, FontminCompat as default, defineConfig, definePlugin, deliverySlices, detectDeliveryLanguages, discoverWebText, eotToTtf, extractCollectionFace, extractWebText, fontminCompatPreset, generateFontFaceCss, glyph, inspect, inspectCapabilities, inspectCollection, instantiateFont, loadConfig, mime, modernWeb, optimize, otf2ttf, otfToTtf, plugins, reduceVariationSpace, subsetTtf, subsetTtfWithPlan, subsetTtfWithReport, svg2ttf, svgFontToTtf, svgs2ttf, svgsToTtf, ttf2eot, ttf2svg, ttf2woff, ttf2woff2, ttfToEot, ttfToSvg, ttfToWoff, ttfToWoff2, ttfToWoff2Async, unicodeRangesFromCodePoints, util, validateWoff2, variationSpace, webDelivery, woff2ToTtf, woffToTtf };
81
+ export { type ArtifactFormat, type AssetFormat, type AutoDeliveryOptions, type AutoDeliveryPlan, type AutoDeliveryPlanOptions, type AutoDeliveryPlanSlice, type AutoDeliverySubsetOptions, type AxisRange, type AxisSetting, type CacheOptions, type CapabilitySupport, type ColorFontCapabilityReport, type ColorFontTechnology, type ColorFontTechnologyCapability, type ConfigOutput, type CoverageOptions, type CoverageReport, type CssFontFamily, type CssFontSource, type CssGlyph, type CssOptions, type DeliveryLanguagePreset, type DeliverySlice, type FontAsset, type FontCapabilityReport, type FontCollectionFaceInfo, type FontCollectionInfo, type FontFormat, type FontInfo, type FontMetadata, type FontminCompatCssInfo, type FontminCompatCssOptions, type FontminCompatFontFamily, type FontminCompatGlyphOptions, type FontminCompatPresetOptions, type FontminConfig, type FontminDiagnosticCode, FontminDiagnosticError, type FontminGlyphTransform, type FontminOutputFile, type FontminPlugin, type FontminTtfEditor, type FontminTtfObject, type GidMapping, type GlyphNameGidMapping, type InstanceOptions, type LayoutSubsetMode, type MaybePromise, type MissingGlyphPolicy, type ModernWebOptions, type Otf2TtfOptions, type OutputConfig, type OutputFormat, type ParallelOptions, type PluginContext, type PluginDiagnostic, type RuntimeMode, type SubsetOptions, type SubsetPlan, type SubsetReport, type SubsetResult, type Svg2TtfOptions, type SvgIcon, type Svgs2TtfOptions, type Svgs2TtfOutput, type Ttf2EotOptions, type Ttf2SvgOptions, type Ttf2Woff2Options, type Ttf2WoffOptions, type UnicodeGidMapping, type VariationSpaceOptions, type VariationSpacePluginOptions, type WebDeliveryManifest, type WebDeliveryManifestAsset, type WebDeliveryManifestSource, type WebDeliveryManifestSummary, type WebDeliveryOptions, type WebTextDiscoveryOptions, type WebTextDiscoveryResult, type WoffOptions, analyzeCoverage, autoDeliverySlices, createTtfSubsetPlan, css, FontminCompat as default, defineConfig, definePlugin, deliverySlices, detectDeliveryLanguages, discoverWebText, eotToTtf, extractCollectionFace, extractWebText, fontminCompatPreset, generateFontFaceCss, glyph, inspect, inspectCapabilities, inspectCollection, instantiateFont, loadConfig, mime, modernWeb, optimize, otf2ttf, otfToTtf, plugins, reduceVariationSpace, subsetTtf, subsetTtfWithPlan, subsetTtfWithReport, svg2ttf, svgFontToTtf, svgs2ttf, svgsToTtf, ttf2eot, ttf2svg, ttf2woff, ttf2woff2, ttfToEot, ttfToSvg, ttfToWoff, ttfToWoff2, ttfToWoff2Async, unicodeRangesFromCodePoints, util, validateWoff2, variationSpace, webDelivery, woff2ToTtf, woffToTtf };
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { A as subsetTtf, B as validateWoff2, C as generateFontFaceCss, D as instantiateFont, E as inspectCollection, F as ttfToEot, G as FontminDiagnosticError, H as woffToTtf, I as ttfToSvg, J as loadConfig, K as defineConfig, L as ttfToWoff, M as subsetTtfWithReport, N as svgFontToTtf, O as otfToTtf, P as svgsToTtf, R as ttfToWoff2, S as extractCollectionFace, T as inspectCapabilities, V as woff2ToTtf, b as createTtfSubsetPlan, c as discoverWebText, g as unicodeRangesFromCodePoints, h as detectDeliveryLanguages, j as subsetTtfWithPlan, k as reduceVariationSpace, l as extractWebText, t as optimize, w as inspect, x as eotToTtf, y as analyzeCoverage, z as ttfToWoff2Async } from "./optimize-pipeline-BoD2Cm8l.mjs";
2
- import { i as util, n as mime, r as plugins, t as FontminCompat } from "./compat-BxQFeNHb.mjs";
3
- import { a as glyph, c as svg2ttf, d as ttf2svg, f as ttf2woff, g as webDelivery, i as deliverySlices, l as svgs2ttf, m as variationSpace, n as css, o as modernWeb, p as ttf2woff2, r as definePlugin, s as otf2ttf, t as autoDeliverySlices, u as ttf2eot } from "./plugins-DxYlVHuH.mjs";
1
+ import { A as reduceVariationSpace, B as ttfToWoff2Async, C as extractCollectionFace, D as inspectCollection, E as inspectCapabilities, F as svgsToTtf, H as woff2ToTtf, I as ttfToEot, K as FontminDiagnosticError, L as ttfToSvg, M as subsetTtfWithPlan, N as subsetTtfWithReport, O as instantiateFont, P as svgFontToTtf, R as ttfToWoff, S as eotToTtf, T as inspect, U as woffToTtf, V as validateWoff2, Y as loadConfig, _ as unicodeRangesFromCodePoints, b as analyzeCoverage, g as detectDeliveryLanguages, j as subsetTtf, k as otfToTtf, l as discoverWebText, q as defineConfig, t as optimize, u as extractWebText, w as generateFontFaceCss, x as createTtfSubsetPlan, z as ttfToWoff2 } from "./optimize-pipeline-XbDo08bZ.mjs";
2
+ import { i as util, n as mime, r as plugins, t as FontminCompat } from "./compat-D8l7c3fw.mjs";
3
+ import { a as glyph, c as svg2ttf, d as ttf2svg, f as ttf2woff, g as webDelivery, i as deliverySlices, l as svgs2ttf, m as variationSpace, n as css, o as modernWeb, p as ttf2woff2, r as definePlugin, s as otf2ttf, t as autoDeliverySlices, u as ttf2eot } from "./plugins-DsijrTfF.mjs";
4
4
  import { fontminCompatPreset } from "./presets.mjs";
5
5
  export { FontminDiagnosticError, analyzeCoverage, autoDeliverySlices, createTtfSubsetPlan, css, FontminCompat as default, defineConfig, definePlugin, deliverySlices, detectDeliveryLanguages, discoverWebText, eotToTtf, extractCollectionFace, extractWebText, fontminCompatPreset, generateFontFaceCss, glyph, inspect, inspectCapabilities, inspectCollection, instantiateFont, loadConfig, mime, modernWeb, optimize, otf2ttf, otfToTtf, plugins, reduceVariationSpace, subsetTtf, subsetTtfWithPlan, subsetTtfWithReport, svg2ttf, svgFontToTtf, svgs2ttf, svgsToTtf, ttf2eot, ttf2svg, ttf2woff, ttf2woff2, ttfToEot, ttfToSvg, ttfToWoff, ttfToWoff2, ttfToWoff2Async, unicodeRangesFromCodePoints, util, validateWoff2, variationSpace, webDelivery, woff2ToTtf, woffToTtf };