polytypo 1.25.0 → 1.26.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 (48) hide show
  1. package/dist/chunk-4L3HIHZT.cjs +36 -0
  2. package/dist/{chunk-UJMW63TZ.cjs.map → chunk-4L3HIHZT.cjs.map} +1 -1
  3. package/dist/{chunk-HWVGXO5H.js → chunk-55725NLR.js} +3 -3
  4. package/dist/{chunk-OUVKOYI7.js → chunk-6P4F3YOR.js} +3 -1
  5. package/dist/chunk-6P4F3YOR.js.map +1 -0
  6. package/dist/{chunk-FE7YMHQU.js → chunk-BXKUA5GP.js} +2 -2
  7. package/dist/{chunk-4IIUWRN3.js → chunk-E2E36U6A.js} +2 -2
  8. package/dist/{chunk-2WVKV756.cjs → chunk-GBT2MDOB.cjs} +23 -23
  9. package/dist/{chunk-2WVKV756.cjs.map → chunk-GBT2MDOB.cjs.map} +1 -1
  10. package/dist/chunk-I256PAWQ.cjs +34 -0
  11. package/dist/{chunk-QWOHGE6N.cjs.map → chunk-I256PAWQ.cjs.map} +1 -1
  12. package/dist/{chunk-NXEVUYTW.js → chunk-KWXTSOIH.js} +4 -4
  13. package/dist/chunk-QD3P5HZV.cjs +38 -0
  14. package/dist/{chunk-Q6DV2BRC.cjs.map → chunk-QD3P5HZV.cjs.map} +1 -1
  15. package/dist/{chunk-PHGV7KQI.cjs → chunk-SEO7SHTQ.cjs} +3 -3
  16. package/dist/{chunk-PHGV7KQI.cjs.map → chunk-SEO7SHTQ.cjs.map} +1 -1
  17. package/dist/{chunk-SZZNBSBH.js → chunk-UFJ3OXGT.js} +3 -3
  18. package/dist/{chunk-4MM34PXT.js → chunk-UJ4W3CPI.js} +2 -2
  19. package/dist/{chunk-BCZZLKYF.cjs → chunk-UYUYS46S.cjs} +6 -6
  20. package/dist/{chunk-BCZZLKYF.cjs.map → chunk-UYUYS46S.cjs.map} +1 -1
  21. package/dist/{chunk-WQHYXBRQ.cjs → chunk-V6EGWED5.cjs} +4 -4
  22. package/dist/{chunk-WQHYXBRQ.cjs.map → chunk-V6EGWED5.cjs.map} +1 -1
  23. package/dist/{chunk-HV73VY4T.js → chunk-Y6GIAYA4.js} +2 -2
  24. package/dist/{chunk-BADHFMDP.cjs → chunk-YC5PR4PR.cjs} +3 -1
  25. package/dist/chunk-YC5PR4PR.cjs.map +1 -0
  26. package/dist/html.cjs +9 -9
  27. package/dist/html.js +4 -4
  28. package/dist/index.cjs +17 -17
  29. package/dist/index.js +7 -7
  30. package/dist/markdown.cjs +10 -10
  31. package/dist/markdown.js +5 -5
  32. package/dist/text.cjs +8 -8
  33. package/dist/text.js +3 -3
  34. package/dist/yaml.cjs +9 -9
  35. package/dist/yaml.js +4 -4
  36. package/package.json +1 -1
  37. package/dist/chunk-BADHFMDP.cjs.map +0 -1
  38. package/dist/chunk-OUVKOYI7.js.map +0 -1
  39. package/dist/chunk-Q6DV2BRC.cjs +0 -38
  40. package/dist/chunk-QWOHGE6N.cjs +0 -34
  41. package/dist/chunk-UJMW63TZ.cjs +0 -36
  42. /package/dist/{chunk-HWVGXO5H.js.map → chunk-55725NLR.js.map} +0 -0
  43. /package/dist/{chunk-FE7YMHQU.js.map → chunk-BXKUA5GP.js.map} +0 -0
  44. /package/dist/{chunk-4IIUWRN3.js.map → chunk-E2E36U6A.js.map} +0 -0
  45. /package/dist/{chunk-NXEVUYTW.js.map → chunk-KWXTSOIH.js.map} +0 -0
  46. /package/dist/{chunk-SZZNBSBH.js.map → chunk-UFJ3OXGT.js.map} +0 -0
  47. /package/dist/{chunk-4MM34PXT.js.map → chunk-UJ4W3CPI.js.map} +0 -0
  48. /package/dist/{chunk-HV73VY4T.js.map → chunk-Y6GIAYA4.js.map} +0 -0
@@ -0,0 +1,36 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+
4
+ var _chunkUYUYS46Scjs = require('./chunk-UYUYS46S.cjs');
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+ var _chunkYC5PR4PRcjs = require('./chunk-YC5PR4PR.cjs');
13
+
14
+ // src/engine/yaml-pipeline.ts
15
+ function runYamlPipeline(input, options) {
16
+ const narrowTarget = _chunkYC5PR4PRcjs.resolveNarrowTarget.call(void 0, options.narrowNbsp);
17
+ const planned = _chunkYC5PR4PRcjs.planRules.call(void 0, options.rules);
18
+ const locale = _chunkYC5PR4PRcjs.getLocaleData.call(void 0, options.locale);
19
+ const keys = _chunkUYUYS46Scjs.resolveYamlKeys.call(void 0, options.keys);
20
+ _chunkYC5PR4PRcjs.assertNoProtect.call(void 0, options.protect, "yaml");
21
+ return _chunkYC5PR4PRcjs.runOverSpans.call(void 0, input, _chunkUYUYS46Scjs.yamlSpans.call(void 0, input, keys), planned, locale, "yaml", narrowTarget);
22
+ }
23
+ function analyzeYamlPipeline(input, options) {
24
+ const narrowTarget = _chunkYC5PR4PRcjs.resolveNarrowTarget.call(void 0, options.narrowNbsp);
25
+ const planned = _chunkYC5PR4PRcjs.planRules.call(void 0, options.rules);
26
+ const locale = _chunkYC5PR4PRcjs.getLocaleData.call(void 0, options.locale);
27
+ const keys = _chunkUYUYS46Scjs.resolveYamlKeys.call(void 0, options.keys);
28
+ _chunkYC5PR4PRcjs.assertNoProtect.call(void 0, options.protect, "yaml");
29
+ return _chunkYC5PR4PRcjs.analyzeOverSpans.call(void 0, input, _chunkUYUYS46Scjs.yamlSpans.call(void 0, input, keys), planned, locale, "yaml", narrowTarget);
30
+ }
31
+
32
+
33
+
34
+
35
+ exports.runYamlPipeline = runYamlPipeline; exports.analyzeYamlPipeline = analyzeYamlPipeline;
36
+ //# sourceMappingURL=chunk-4L3HIHZT.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/polytypo-js/polytypo-js/dist/chunk-UJMW63TZ.cjs","../src/engine/yaml-pipeline.ts"],"names":[],"mappings":"AAAA;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACA;ACIO,SAAS,eAAA,CAAgB,KAAA,EAAe,OAAA,EAAmC;AAChF,EAAA,MAAM,aAAA,EAAe,mDAAA,OAAoB,CAAQ,UAAU,CAAA;AAC3D,EAAA,MAAM,QAAA,EAAU,yCAAA,OAAU,CAAQ,KAAK,CAAA;AACvC,EAAA,MAAM,OAAA,EAAS,6CAAA,OAAc,CAAQ,MAAM,CAAA;AAC3C,EAAA,MAAM,KAAA,EAAO,+CAAA,OAAgB,CAAQ,IAAI,CAAA;AACzC,EAAA,+CAAA,OAAgB,CAAQ,OAAA,EAAS,MAAM,CAAA;AACvC,EAAA,OAAO,4CAAA,KAAa,EAAO,yCAAA,KAAU,EAAO,IAAI,CAAA,EAAG,OAAA,EAAS,MAAA,EAAQ,MAAA,EAAQ,YAAY,CAAA;AAC1F;AAGO,SAAS,mBAAA,CAAoB,KAAA,EAAe,OAAA,EAAqC;AACtF,EAAA,MAAM,aAAA,EAAe,mDAAA,OAAoB,CAAQ,UAAU,CAAA;AAC3D,EAAA,MAAM,QAAA,EAAU,yCAAA,OAAU,CAAQ,KAAK,CAAA;AACvC,EAAA,MAAM,OAAA,EAAS,6CAAA,OAAc,CAAQ,MAAM,CAAA;AAC3C,EAAA,MAAM,KAAA,EAAO,+CAAA,OAAgB,CAAQ,IAAI,CAAA;AACzC,EAAA,+CAAA,OAAgB,CAAQ,OAAA,EAAS,MAAM,CAAA;AACvC,EAAA,OAAO,gDAAA,KAAiB,EAAO,yCAAA,KAAU,EAAO,IAAI,CAAA,EAAG,OAAA,EAAS,MAAA,EAAQ,MAAA,EAAQ,YAAY,CAAA;AAC9F;ADJA;AACA;AACE;AACA;AACF,6FAAC","file":"/home/runner/work/polytypo-js/polytypo-js/dist/chunk-UJMW63TZ.cjs","sourcesContent":[null,"import { yamlSpans } from \"../modes/yaml.js\";\nimport type { Options } from \"../types.js\";\nimport { getLocaleData } from \"./locale.js\";\nimport { resolveNarrowTarget } from \"./narrow-target.js\";\nimport { resolveYamlKeys } from \"./yaml-keys.js\";\nimport { assertNoProtect } from \"./protect.js\";\nimport { planRules } from \"./rule-runner.js\";\nimport { analyzeOverSpans, runOverSpans } from \"./span-runner.js\";\nimport type { Change } from \"./origin.js\";\n\n/**\n * `yaml` mode only, and the only mode pipeline with **no parser dependency at all** — span\n * selection is the specified scan of modes.md 3.8, not a library. There is likewise no\n * `POLYTYPO_MALFORMED_INPUT` counterpart here: with no declared grammar to violate, a file that\n * is not YAML yields few spans or none and comes back byte for byte (modes.md 3.8.3). The only\n * throw this mode adds is `keys`, which is about the call and not the input.\n */\nexport function runYamlPipeline(input: string, options: Partial<Options>): string {\n const narrowTarget = resolveNarrowTarget(options.narrowNbsp);\n const planned = planRules(options.rules);\n const locale = getLocaleData(options.locale);\n const keys = resolveYamlKeys(options.keys);\n assertNoProtect(options.protect, \"yaml\");\n return runOverSpans(input, yamlSpans(input, keys), planned, locale, \"yaml\", narrowTarget);\n}\n\n/** analyze.md §1, `yaml` mode: offsets are into the document, not into a span (analyze.md §6). */\nexport function analyzeYamlPipeline(input: string, options: Partial<Options>): Change[] {\n const narrowTarget = resolveNarrowTarget(options.narrowNbsp);\n const planned = planRules(options.rules);\n const locale = getLocaleData(options.locale);\n const keys = resolveYamlKeys(options.keys);\n assertNoProtect(options.protect, \"yaml\");\n return analyzeOverSpans(input, yamlSpans(input, keys), planned, locale, \"yaml\", narrowTarget);\n}\n"]}
1
+ {"version":3,"sources":["/home/runner/work/polytypo-js/polytypo-js/dist/chunk-4L3HIHZT.cjs","../src/engine/yaml-pipeline.ts"],"names":[],"mappings":"AAAA;AACE;AACA;AACF,wDAA6B;AAC7B;AACE;AACA;AACA;AACA;AACA;AACA;AACF,wDAA6B;AAC7B;AACA;ACIO,SAAS,eAAA,CAAgB,KAAA,EAAe,OAAA,EAAmC;AAChF,EAAA,MAAM,aAAA,EAAe,mDAAA,OAAoB,CAAQ,UAAU,CAAA;AAC3D,EAAA,MAAM,QAAA,EAAU,yCAAA,OAAU,CAAQ,KAAK,CAAA;AACvC,EAAA,MAAM,OAAA,EAAS,6CAAA,OAAc,CAAQ,MAAM,CAAA;AAC3C,EAAA,MAAM,KAAA,EAAO,+CAAA,OAAgB,CAAQ,IAAI,CAAA;AACzC,EAAA,+CAAA,OAAgB,CAAQ,OAAA,EAAS,MAAM,CAAA;AACvC,EAAA,OAAO,4CAAA,KAAa,EAAO,yCAAA,KAAU,EAAO,IAAI,CAAA,EAAG,OAAA,EAAS,MAAA,EAAQ,MAAA,EAAQ,YAAY,CAAA;AAC1F;AAGO,SAAS,mBAAA,CAAoB,KAAA,EAAe,OAAA,EAAqC;AACtF,EAAA,MAAM,aAAA,EAAe,mDAAA,OAAoB,CAAQ,UAAU,CAAA;AAC3D,EAAA,MAAM,QAAA,EAAU,yCAAA,OAAU,CAAQ,KAAK,CAAA;AACvC,EAAA,MAAM,OAAA,EAAS,6CAAA,OAAc,CAAQ,MAAM,CAAA;AAC3C,EAAA,MAAM,KAAA,EAAO,+CAAA,OAAgB,CAAQ,IAAI,CAAA;AACzC,EAAA,+CAAA,OAAgB,CAAQ,OAAA,EAAS,MAAM,CAAA;AACvC,EAAA,OAAO,gDAAA,KAAiB,EAAO,yCAAA,KAAU,EAAO,IAAI,CAAA,EAAG,OAAA,EAAS,MAAA,EAAQ,MAAA,EAAQ,YAAY,CAAA;AAC9F;ADJA;AACA;AACE;AACA;AACF,6FAAC","file":"/home/runner/work/polytypo-js/polytypo-js/dist/chunk-4L3HIHZT.cjs","sourcesContent":[null,"import { yamlSpans } from \"../modes/yaml.js\";\nimport type { Options } from \"../types.js\";\nimport { getLocaleData } from \"./locale.js\";\nimport { resolveNarrowTarget } from \"./narrow-target.js\";\nimport { resolveYamlKeys } from \"./yaml-keys.js\";\nimport { assertNoProtect } from \"./protect.js\";\nimport { planRules } from \"./rule-runner.js\";\nimport { analyzeOverSpans, runOverSpans } from \"./span-runner.js\";\nimport type { Change } from \"./origin.js\";\n\n/**\n * `yaml` mode only, and the only mode pipeline with **no parser dependency at all** — span\n * selection is the specified scan of modes.md 3.8, not a library. There is likewise no\n * `POLYTYPO_MALFORMED_INPUT` counterpart here: with no declared grammar to violate, a file that\n * is not YAML yields few spans or none and comes back byte for byte (modes.md 3.8.3). The only\n * throw this mode adds is `keys`, which is about the call and not the input.\n */\nexport function runYamlPipeline(input: string, options: Partial<Options>): string {\n const narrowTarget = resolveNarrowTarget(options.narrowNbsp);\n const planned = planRules(options.rules);\n const locale = getLocaleData(options.locale);\n const keys = resolveYamlKeys(options.keys);\n assertNoProtect(options.protect, \"yaml\");\n return runOverSpans(input, yamlSpans(input, keys), planned, locale, \"yaml\", narrowTarget);\n}\n\n/** analyze.md §1, `yaml` mode: offsets are into the document, not into a span (analyze.md §6). */\nexport function analyzeYamlPipeline(input: string, options: Partial<Options>): Change[] {\n const narrowTarget = resolveNarrowTarget(options.narrowNbsp);\n const planned = planRules(options.rules);\n const locale = getLocaleData(options.locale);\n const keys = resolveYamlKeys(options.keys);\n assertNoProtect(options.protect, \"yaml\");\n return analyzeOverSpans(input, yamlSpans(input, keys), planned, locale, \"yaml\", narrowTarget);\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  htmlSpans
3
- } from "./chunk-HV73VY4T.js";
3
+ } from "./chunk-Y6GIAYA4.js";
4
4
  import {
5
5
  analyzeOverSpans,
6
6
  assertNoProtect,
@@ -8,7 +8,7 @@ import {
8
8
  planRules,
9
9
  resolveNarrowTarget,
10
10
  runOverSpans
11
- } from "./chunk-OUVKOYI7.js";
11
+ } from "./chunk-6P4F3YOR.js";
12
12
 
13
13
  // src/engine/html-pipeline.ts
14
14
  function runHtmlPipeline(input, options) {
@@ -31,4 +31,4 @@ export {
31
31
  runHtmlPipeline,
32
32
  analyzeHtmlPipeline
33
33
  };
34
- //# sourceMappingURL=chunk-HWVGXO5H.js.map
34
+ //# sourceMappingURL=chunk-55725NLR.js.map
@@ -46,6 +46,7 @@ function isValidCodePoint(value) {
46
46
  var KNOWN_LOCALES = [
47
47
  "bg",
48
48
  "cs",
49
+ "da",
49
50
  "de-CH",
50
51
  "de-DE",
51
52
  "el",
@@ -82,6 +83,7 @@ var ALIASES = {
82
83
  var LOCALES = {
83
84
  bg: { locale: "bg", name: "Bulgarian", 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-spaced" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: [], beforeUnits: [], spacedUnits: ["\u043A\u043C", "\u043A\u0433", "\u043B\u0432.", "\u0433."], closedUnits: ["%"], beforeNumber: [], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
84
85
  cs: { locale: "cs", name: "Czech", quotes: { primary: { open: "\u201E", close: "\u201C", innerSpace: "none" }, secondary: { open: "\u201A", close: "\u2018", 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", "k", "o", "s", "u", "v", "z"], abbreviations: ["a. s.", "s. r. o."], beforeUnits: ["%", "\xB0C", "ha", "kg", "km", "cm", "mm", "m\xB2", "kWh", "km/h", "str.", "hod."], spacedUnits: [], closedUnits: [], beforeNumber: [], beforeWord: ["tj.", "tzv.", "tzn."], afterSymbols: ["\xA7"], initialBinding: "single" } },
86
+ da: { locale: "da", name: "Danish", quotes: { primary: { open: "\xBB", close: "\xAB", innerSpace: "none" }, secondary: { open: "\u203A", close: "\u2039", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "en-spaced", range: "none" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: [], beforeUnits: [], spacedUnits: ["%", "kr", "\u20AC", "km", "kg", "cm", "ha"], closedUnits: [], beforeNumber: [], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
85
87
  "de-CH": { locale: "de-CH", name: "German (Switzerland)", quotes: { primary: { open: "\xAB", close: "\xBB", innerSpace: "none" }, secondary: { open: "\u2039", close: "\u203A", 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: ["z. B.", "d. h.", "u. a.", "u. U.", "m. a. W.", "m. w. H."], beforeUnits: [], spacedUnits: ["%", "\u2030", "\xB0C", "km", "cm", "mm", "kg", "km/h", "kWh"], closedUnits: [], beforeNumber: ["Art.", "Abs.", "Ziff.", "Kap.", "S."], beforeWord: ["St."], afterSymbols: ["\xA7", "\xA7\xA7"], initialBinding: "chain" } },
86
88
  "de-DE": { locale: "de-DE", name: "German (Germany)", quotes: { primary: { open: "\u201E", close: "\u201C", innerSpace: "none" }, secondary: { open: "\u201A", close: "\u2018", 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: ["z. B.", "d. h.", "u. a.", "u. \xC4.", "z. T.", "i. d. R."], beforeUnits: ["\u2030"], spacedUnits: ["%", "\u20AC", "\xB0C", "km", "cm", "mm", "kg", "km/h", "kWh"], closedUnits: [], beforeNumber: ["Nr.", "S."], beforeWord: ["St."], afterSymbols: ["\xA7", "\xA7\xA7"], initialBinding: "chain" } },
87
89
  el: { locale: "el", name: "Greek", quotes: { primary: { open: "\xAB", close: "\xBB", innerSpace: "none" }, secondary: { open: "\u201C", close: "\u201D", innerSpace: "none" }, elisionIdioms: [], elisionClitics: { before: [], after: [] }, punctuationPlacement: "none" }, dash: { parenthetical: "em-paired", range: "none" }, ellipsis: { abbreviatedAfterTerminal: false }, hyphen: { prefixes: [], suffixes: [], compounds: [] }, nbsp: { beforePunctuation: [], narrowBeforePunctuation: [], afterShortWords: [], abbreviations: [], beforeUnits: [], spacedUnits: [], closedUnits: ["%", "\xB0C"], beforeNumber: [], beforeWord: [], afterSymbols: [], initialBinding: "none" } },
@@ -6559,4 +6561,4 @@ export {
6559
6561
  runProtected,
6560
6562
  analyzeProtected
6561
6563
  };
6562
- //# sourceMappingURL=chunk-OUVKOYI7.js.map
6564
+ //# sourceMappingURL=chunk-6P4F3YOR.js.map