polytypo 1.23.0 → 1.24.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 (50) hide show
  1. package/dist/{chunk-MNHZALA4.cjs → chunk-3GKRQ3XO.cjs} +3 -3
  2. package/dist/{chunk-MNHZALA4.cjs.map → chunk-3GKRQ3XO.cjs.map} +1 -1
  3. package/dist/{chunk-4T6472KQ.js → chunk-44PLJMOX.js} +2 -2
  4. package/dist/{chunk-GFBX7ERJ.cjs → chunk-4GNJWMXI.cjs} +3 -1
  5. package/dist/chunk-4GNJWMXI.cjs.map +1 -0
  6. package/dist/{chunk-H3Z64VQD.js → chunk-6BZSWQLS.js} +3 -3
  7. package/dist/chunk-6XJG3XEK.cjs +34 -0
  8. package/dist/{chunk-IFUGQYHJ.cjs.map → chunk-6XJG3XEK.cjs.map} +1 -1
  9. package/dist/{chunk-GXN5UU4W.cjs → chunk-BRUSFT2Q.cjs} +6 -6
  10. package/dist/{chunk-GXN5UU4W.cjs.map → chunk-BRUSFT2Q.cjs.map} +1 -1
  11. package/dist/{chunk-YEALOS6F.js → chunk-D57NGDLG.js} +4 -4
  12. package/dist/chunk-J3EZK5OW.cjs +36 -0
  13. package/dist/{chunk-VRSUY6YN.cjs.map → chunk-J3EZK5OW.cjs.map} +1 -1
  14. package/dist/{chunk-MLASZMHY.js → chunk-L3J52D7B.js} +3 -3
  15. package/dist/{chunk-2DXV6J4X.js → chunk-MLCRELTI.js} +99 -7
  16. package/dist/chunk-MLCRELTI.js.map +1 -0
  17. package/dist/{chunk-TYJELWIF.cjs → chunk-PXXHTL3K.cjs} +23 -23
  18. package/dist/{chunk-TYJELWIF.cjs.map → chunk-PXXHTL3K.cjs.map} +1 -1
  19. package/dist/chunk-RQTVK2RX.cjs +38 -0
  20. package/dist/{chunk-LOWQTULZ.cjs.map → chunk-RQTVK2RX.cjs.map} +1 -1
  21. package/dist/{chunk-Q5RRHO32.js → chunk-RW32MNW5.js} +2 -2
  22. package/dist/{chunk-CI3NZEM3.js → chunk-UPOI5JM4.js} +3 -1
  23. package/dist/chunk-UPOI5JM4.js.map +1 -0
  24. package/dist/{chunk-IT7K7NZV.js → chunk-W24ZJOMS.js} +2 -2
  25. package/dist/{chunk-RMNY65SN.cjs → chunk-XHTWS33U.cjs} +101 -9
  26. package/dist/chunk-XHTWS33U.cjs.map +1 -0
  27. package/dist/html.cjs +9 -9
  28. package/dist/html.js +4 -4
  29. package/dist/index.cjs +17 -17
  30. package/dist/index.js +7 -7
  31. package/dist/markdown.cjs +10 -10
  32. package/dist/markdown.js +5 -5
  33. package/dist/text.cjs +8 -8
  34. package/dist/text.js +3 -3
  35. package/dist/yaml.cjs +9 -9
  36. package/dist/yaml.js +4 -4
  37. package/package.json +1 -1
  38. package/dist/chunk-2DXV6J4X.js.map +0 -1
  39. package/dist/chunk-CI3NZEM3.js.map +0 -1
  40. package/dist/chunk-GFBX7ERJ.cjs.map +0 -1
  41. package/dist/chunk-IFUGQYHJ.cjs +0 -34
  42. package/dist/chunk-LOWQTULZ.cjs +0 -38
  43. package/dist/chunk-RMNY65SN.cjs.map +0 -1
  44. package/dist/chunk-VRSUY6YN.cjs +0 -36
  45. /package/dist/{chunk-4T6472KQ.js.map → chunk-44PLJMOX.js.map} +0 -0
  46. /package/dist/{chunk-H3Z64VQD.js.map → chunk-6BZSWQLS.js.map} +0 -0
  47. /package/dist/{chunk-YEALOS6F.js.map → chunk-D57NGDLG.js.map} +0 -0
  48. /package/dist/{chunk-MLASZMHY.js.map → chunk-L3J52D7B.js.map} +0 -0
  49. /package/dist/{chunk-Q5RRHO32.js.map → chunk-RW32MNW5.js.map} +0 -0
  50. /package/dist/{chunk-IT7K7NZV.js.map → chunk-W24ZJOMS.js.map} +0 -0
@@ -1,11 +1,11 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _chunkGFBX7ERJcjs = require('./chunk-GFBX7ERJ.cjs');
3
+ var _chunk4GNJWMXIcjs = require('./chunk-4GNJWMXI.cjs');
4
4
 
5
5
  // src/engine/assert-fixed-mode.ts
6
6
  function assertFixedMode(mode, fixed, entryPoint) {
7
7
  if (mode === void 0 || mode === fixed) return;
8
- throw new (0, _chunkGFBX7ERJcjs.PolytypoError)(
8
+ throw new (0, _chunk4GNJWMXIcjs.PolytypoError)(
9
9
  "POLYTYPO_INVALID_MODE",
10
10
  `"${entryPoint}" only supports mode "${fixed}". Received "${String(mode)}" \u2014 import from "polytypo" for the other modes, or omit \`mode\` here.`
11
11
  );
@@ -14,4 +14,4 @@ function assertFixedMode(mode, fixed, entryPoint) {
14
14
 
15
15
 
16
16
  exports.assertFixedMode = assertFixedMode;
17
- //# sourceMappingURL=chunk-MNHZALA4.cjs.map
17
+ //# sourceMappingURL=chunk-3GKRQ3XO.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/polytypo-js/polytypo-js/dist/chunk-MNHZALA4.cjs","../src/engine/assert-fixed-mode.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACA;ACMO,SAAS,eAAA,CAAgB,IAAA,EAAe,KAAA,EAAa,UAAA,EAA0B;AACpF,EAAA,GAAA,CAAI,KAAA,IAAS,KAAA,EAAA,GAAa,KAAA,IAAS,KAAA,EAAO,MAAA;AAC1C,EAAA,MAAM,IAAI,oCAAA;AAAA,IACR,uBAAA;AAAA,IACA,CAAA,CAAA,EAAI,UAAU,CAAA,sBAAA,EAAyB,KAAK,CAAA,aAAA,EAAgB,MAAA,CAAO,IAAI,CAAC,CAAA,2EAAA;AAAA,EAE1E,CAAA;AACF;ADLA;AACA;AACE;AACF,0CAAC","file":"/home/runner/work/polytypo-js/polytypo-js/dist/chunk-MNHZALA4.cjs","sourcesContent":[null,"import { PolytypoError } from \"../errors.js\";\nimport type { Mode } from \"../types.js\";\n\n/**\n * `polytypo/text`, `polytypo/html` and `polytypo/markdown` each fix `mode` at the type level by\n * omitting it from their Options type (AUDIT_REMEDIATION_AND_RELEASE_PLAN.md 5.1, criterion 6).\n * A plain-JS caller — or a TypeScript caller passing a wider-typed variable, which excess-property\n * checking does not catch — can still supply a conflicting `mode` at runtime. That is rejected\n * explicitly here, never silently ignored or overridden.\n */\nexport function assertFixedMode(mode: unknown, fixed: Mode, entryPoint: string): void {\n if (mode === undefined || mode === fixed) return;\n throw new PolytypoError(\n \"POLYTYPO_INVALID_MODE\",\n `\"${entryPoint}\" only supports mode \"${fixed}\". Received \"${String(mode)}\" — ` +\n `import from \"polytypo\" for the other modes, or omit \\`mode\\` here.`,\n );\n}\n"]}
1
+ {"version":3,"sources":["/home/runner/work/polytypo-js/polytypo-js/dist/chunk-3GKRQ3XO.cjs","../src/engine/assert-fixed-mode.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACA;ACMO,SAAS,eAAA,CAAgB,IAAA,EAAe,KAAA,EAAa,UAAA,EAA0B;AACpF,EAAA,GAAA,CAAI,KAAA,IAAS,KAAA,EAAA,GAAa,KAAA,IAAS,KAAA,EAAO,MAAA;AAC1C,EAAA,MAAM,IAAI,oCAAA;AAAA,IACR,uBAAA;AAAA,IACA,CAAA,CAAA,EAAI,UAAU,CAAA,sBAAA,EAAyB,KAAK,CAAA,aAAA,EAAgB,MAAA,CAAO,IAAI,CAAC,CAAA,2EAAA;AAAA,EAE1E,CAAA;AACF;ADLA;AACA;AACE;AACF,0CAAC","file":"/home/runner/work/polytypo-js/polytypo-js/dist/chunk-3GKRQ3XO.cjs","sourcesContent":[null,"import { PolytypoError } from \"../errors.js\";\nimport type { Mode } from \"../types.js\";\n\n/**\n * `polytypo/text`, `polytypo/html` and `polytypo/markdown` each fix `mode` at the type level by\n * omitting it from their Options type (AUDIT_REMEDIATION_AND_RELEASE_PLAN.md 5.1, criterion 6).\n * A plain-JS caller — or a TypeScript caller passing a wider-typed variable, which excess-property\n * checking does not catch — can still supply a conflicting `mode` at runtime. That is rejected\n * explicitly here, never silently ignored or overridden.\n */\nexport function assertFixedMode(mode: unknown, fixed: Mode, entryPoint: string): void {\n if (mode === undefined || mode === fixed) return;\n throw new PolytypoError(\n \"POLYTYPO_INVALID_MODE\",\n `\"${entryPoint}\" only supports mode \"${fixed}\". Received \"${String(mode)}\" — ` +\n `import from \"polytypo\" for the other modes, or omit \\`mode\\` here.`,\n );\n}\n"]}
@@ -9,7 +9,7 @@ import {
9
9
  runRules,
10
10
  runRulesRecording,
11
11
  toCodePoints
12
- } from "./chunk-CI3NZEM3.js";
12
+ } from "./chunk-UPOI5JM4.js";
13
13
 
14
14
  // src/engine/text-pipeline.ts
15
15
  function runTextPipeline(input, options) {
@@ -35,4 +35,4 @@ export {
35
35
  runTextPipeline,
36
36
  analyzeTextPipeline
37
37
  };
38
- //# sourceMappingURL=chunk-4T6472KQ.js.map
38
+ //# sourceMappingURL=chunk-44PLJMOX.js.map
@@ -59,6 +59,7 @@ var KNOWN_LOCALES = [
59
59
  "hu",
60
60
  "it",
61
61
  "lt",
62
+ "lv",
62
63
  "nl",
63
64
  "pl",
64
65
  "pt-BR",
@@ -93,6 +94,7 @@ var LOCALES = {
93
94
  hu: { locale: "hu", name: "Hungarian", quotes: { primary: { open: "\u201E", close: "\u201D", innerSpace: "none" }, secondary: { open: "\xBB", close: "\xAB", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "en-tight" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: ["a. m.", "i. sz.", "Kr. e.", "Kr. u.", "s. k.", "i. e."], beforeUnits: [], spacedUnits: ["km", "kg", "kWh", "km/h", "\xB0C"], closedUnits: ["%"], beforeNumber: [], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
94
95
  it: { locale: "it", name: "Italian", quotes: { primary: { open: "\xAB", close: "\xBB", innerSpace: "none" }, secondary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: ["l", "un", "d"], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "em-spaced", range: "none" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: [], beforeUnits: ["%", "\u2030", "\u20AC", "\xB0C", "km", "cm", "mm", "kg", "km/h", "kWh"], spacedUnits: [], closedUnits: [], beforeNumber: ["n.", "pag."], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
95
96
  lt: { locale: "lt", name: "Lithuanian", quotes: { primary: { open: "\u201E", close: "\u201C", innerSpace: "none" }, secondary: { open: "\u201E", close: "\u201C", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "en-tight" }, ellipsis: { abbreviatedAfterTerminal: true }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: ["t. y.", "t. t.", "\u0161. m."], beforeUnits: ["cm", "mm", "m.", "d."], spacedUnits: ["%", "proc.", "\xB0C", "kg", "km", "EUR", "Eur", "\u20AC", "mln.", "val.", "min.", "km/h", "m/s", "ha"], closedUnits: [], beforeNumber: [], beforeWord: [], afterSymbols: ["\xA7"], initialBinding: "none" } },
97
+ lv: { locale: "lv", name: "Latvian", quotes: { primary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, secondary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "en-tight" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: ["u. c.", "u. tml.", "\u0161. g."], beforeUnits: [], spacedUnits: ["%", "\u20AC", "EUR", "km", "\xB0C"], closedUnits: [], beforeNumber: ["Nr."], beforeWord: [], afterSymbols: [], initialBinding: "single" } },
96
98
  nl: { locale: "nl", name: "Dutch", quotes: { primary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, secondary: { open: "\u2018", close: "\u2019", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: ["s", "t", "ns", "k", "m", "em", "r", "et"] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "none" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: ["prof. dr."], beforeUnits: ["\xB0C", "km/h", "kWh"], spacedUnits: ["km", "cm", "mm", "kg"], closedUnits: ["%", "\u2030"], beforeNumber: [], beforeWord: [], afterSymbols: ["\u20AC", "$"], initialBinding: "none" } },
97
99
  pl: { locale: "pl", name: "Polish", quotes: { primary: { open: "\u201E", close: "\u201D", innerSpace: "none" }, secondary: { open: "\xBB", close: "\xAB", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "en-tight" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: ["a", "i", "o", "u", "w", "z"], abbreviations: ["lek. med.", "in\u017C. g\xF3rn.", "bp sufr."], beforeUnits: ["\u2030", "\xB0C"], spacedUnits: ["km", "cm", "mm", "kg", "km/h", "kWh"], closedUnits: ["%"], beforeNumber: [], beforeWord: [], afterSymbols: ["\xA7"], initialBinding: "none" } },
98
100
  "pt-BR": { locale: "pt-BR", name: "Portuguese (Brazil)", quotes: { primary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, secondary: { open: "\u2018", close: "\u2019", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: ["d", "n", "pel", "m", "t", "lh", "sant"], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "none" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: ["p. ex."], beforeUnits: ["%", "\u2030"], spacedUnits: ["\xB0C", "km", "cm", "mm", "kg", "kW", "kWh", "Hz"], closedUnits: [], beforeNumber: ["p."], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
@@ -6555,4 +6557,4 @@ function analyzeProtected(input, holes, planned, locale, narrowTarget) {
6555
6557
 
6556
6558
 
6557
6559
  exports.PolytypoError = PolytypoError; exports.toCodePoints = toCodePoints; exports.fromCodePoints = fromCodePoints; exports.getLocaleData = getLocaleData; exports.resolveNarrowTarget = resolveNarrowTarget; exports.normalizeSpans = normalizeSpans; exports.planRules = planRules; exports.runRules = runRules; exports.runRulesRecording = runRulesRecording; exports.runOverSpans = runOverSpans; exports.runOverUnits = runOverUnits; exports.analyzeOverUnits = analyzeOverUnits; exports.analyzeOverSpans = analyzeOverSpans; exports.resolveProtect = resolveProtect; exports.assertNoProtect = assertNoProtect; exports.runProtected = runProtected; exports.analyzeProtected = analyzeProtected;
6558
- //# sourceMappingURL=chunk-GFBX7ERJ.cjs.map
6560
+ //# sourceMappingURL=chunk-4GNJWMXI.cjs.map