@axdspub/axiom-ui-forms 0.2.8 → 0.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/library/axiom-ui-forms.d.ts +36 -4
- package/library/esm/_virtual/index10.js +2 -2
- package/library/esm/_virtual/index11.js +2 -2
- package/library/esm/_virtual/index12.js +6 -2
- package/library/esm/_virtual/index12.js.map +1 -1
- package/library/esm/_virtual/index13.js +6 -2
- package/library/esm/_virtual/index13.js.map +1 -1
- package/library/esm/_virtual/index14.js +2 -2
- package/library/esm/_virtual/index15.js +4 -0
- package/library/esm/_virtual/index15.js.map +1 -0
- package/library/esm/_virtual/index16.js +4 -0
- package/library/esm/_virtual/index16.js.map +1 -0
- package/library/esm/_virtual/index17.js +4 -0
- package/library/esm/_virtual/index17.js.map +1 -0
- package/library/esm/_virtual/index6.js +2 -2
- package/library/esm/_virtual/index6.js.map +1 -1
- package/library/esm/_virtual/index7.js +2 -2
- package/library/esm/_virtual/index7.js.map +1 -1
- package/library/esm/_virtual/index8.js +2 -2
- package/library/esm/_virtual/index9.js +2 -2
- package/library/esm/_virtual/utilities.js +4 -0
- package/library/esm/_virtual/utilities.js.map +1 -0
- package/library/esm/node_modules/@axdspub/axiom-ui-utilities/library/index.js +241 -9
- package/library/esm/node_modules/@axdspub/axiom-ui-utilities/library/index.js.map +1 -1
- package/library/esm/node_modules/@babel/runtime/helpers/esm/extends.js +12 -0
- package/library/esm/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -0
- package/library/esm/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js +12 -0
- package/library/esm/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js.map +1 -0
- package/library/esm/node_modules/@codemirror/autocomplete/dist/index.js +1652 -0
- package/library/esm/node_modules/@codemirror/autocomplete/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/commands/dist/index.js +1444 -0
- package/library/esm/node_modules/@codemirror/commands/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/lang-json/dist/index.js +33 -0
- package/library/esm/node_modules/@codemirror/lang-json/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/lang-yaml/dist/index.js +59 -0
- package/library/esm/node_modules/@codemirror/lang-yaml/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/language/dist/index.js +1821 -0
- package/library/esm/node_modules/@codemirror/language/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/lint/dist/index.js +589 -0
- package/library/esm/node_modules/@codemirror/lint/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/search/dist/index.js +1227 -0
- package/library/esm/node_modules/@codemirror/search/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/state/dist/index.js +3882 -0
- package/library/esm/node_modules/@codemirror/state/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/theme-one-dark/dist/index.js +114 -0
- package/library/esm/node_modules/@codemirror/theme-one-dark/dist/index.js.map +1 -0
- package/library/esm/node_modules/@codemirror/view/dist/index.js +11052 -0
- package/library/esm/node_modules/@codemirror/view/dist/index.js.map +1 -0
- package/library/esm/node_modules/@lezer/common/dist/index.js +1704 -0
- package/library/esm/node_modules/@lezer/common/dist/index.js.map +1 -0
- package/library/esm/node_modules/@lezer/highlight/dist/index.js +876 -0
- package/library/esm/node_modules/@lezer/highlight/dist/index.js.map +1 -0
- package/library/esm/node_modules/@lezer/json/dist/index.js +38 -0
- package/library/esm/node_modules/@lezer/json/dist/index.js.map +1 -0
- package/library/esm/node_modules/@lezer/lr/dist/index.js +1855 -0
- package/library/esm/node_modules/@lezer/lr/dist/index.js.map +1 -0
- package/library/esm/node_modules/@lezer/yaml/dist/index.js +392 -0
- package/library/esm/node_modules/@lezer/yaml/dist/index.js.map +1 -0
- package/library/esm/node_modules/@marijn/find-cluster-break/src/index.js +83 -0
- package/library/esm/node_modules/@marijn/find-cluster-break/src/index.js.map +1 -0
- package/library/esm/node_modules/@radix-ui/react-icons/dist/react-icons.esm.js +67 -1
- package/library/esm/node_modules/@radix-ui/react-icons/dist/react-icons.esm.js.map +1 -1
- package/library/esm/node_modules/@uiw/codemirror-extensions-basic-setup/esm/index.js +100 -0
- package/library/esm/node_modules/@uiw/codemirror-extensions-basic-setup/esm/index.js.map +1 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/getDefaultExtensions.js +58 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/getDefaultExtensions.js.map +1 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/index.js +89 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/index.js.map +1 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/theme/light.js +12 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/theme/light.js.map +1 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/useCodeMirror.js +151 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/useCodeMirror.js.map +1 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/utils.js +19 -0
- package/library/esm/node_modules/@uiw/react-codemirror/esm/utils.js.map +1 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/deserialize.js +77 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/deserialize.js.map +1 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/index.js +25 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/index.js.map +1 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/serialize.js +159 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/serialize.js.map +1 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/types.js +14 -0
- package/library/esm/node_modules/@ungap/structured-clone/esm/types.js.map +1 -0
- package/library/esm/node_modules/ajv/dist/compile/index.js +1 -1
- package/library/esm/node_modules/ajv/dist/vocabularies/applicator/index.js +1 -1
- package/library/esm/node_modules/ajv/dist/vocabularies/core/index.js +1 -1
- package/library/esm/node_modules/ajv/dist/vocabularies/format/index.js +1 -1
- package/library/esm/node_modules/ajv/dist/vocabularies/validation/index.js +1 -1
- package/library/esm/node_modules/bail/index.js +15 -0
- package/library/esm/node_modules/bail/index.js.map +1 -0
- package/library/esm/node_modules/comma-separated-tokens/index.js +37 -0
- package/library/esm/node_modules/comma-separated-tokens/index.js.map +1 -0
- package/library/esm/node_modules/crelt/index.js +30 -0
- package/library/esm/node_modules/crelt/index.js.map +1 -0
- package/library/esm/node_modules/decode-named-character-reference/index.dom.js +39 -0
- package/library/esm/node_modules/decode-named-character-reference/index.dom.js.map +1 -0
- package/library/esm/node_modules/devlop/lib/default.js +6 -0
- package/library/esm/node_modules/devlop/lib/default.js.map +1 -0
- package/library/esm/node_modules/estree-util-is-identifier-name/lib/index.js +31 -0
- package/library/esm/node_modules/estree-util-is-identifier-name/lib/index.js.map +1 -0
- package/library/esm/node_modules/extend/index.js +127 -0
- package/library/esm/node_modules/extend/index.js.map +1 -0
- package/library/esm/node_modules/fast-uri/index.js +1 -1
- package/library/esm/node_modules/hast-util-to-jsx-runtime/lib/index.js +791 -0
- package/library/esm/node_modules/hast-util-to-jsx-runtime/lib/index.js.map +1 -0
- package/library/esm/node_modules/hast-util-whitespace/lib/index.js +37 -0
- package/library/esm/node_modules/hast-util-whitespace/lib/index.js.map +1 -0
- package/library/esm/node_modules/html-url-attributes/lib/index.js +34 -0
- package/library/esm/node_modules/html-url-attributes/lib/index.js.map +1 -0
- package/library/esm/node_modules/inline-style-parser/index.js +268 -0
- package/library/esm/node_modules/inline-style-parser/index.js.map +1 -0
- package/library/esm/node_modules/js-yaml/dist/js-yaml.js +3850 -0
- package/library/esm/node_modules/js-yaml/dist/js-yaml.js.map +1 -0
- package/library/esm/node_modules/json-schema-traverse/index.js +1 -1
- package/library/esm/node_modules/mdast-util-from-markdown/lib/index.js +1181 -0
- package/library/esm/node_modules/mdast-util-from-markdown/lib/index.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/footer.js +197 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/footer.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/blockquote.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/blockquote.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/break.js +27 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/break.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/code.js +51 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/code.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/delete.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/delete.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/emphasis.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/emphasis.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/footnote-reference.js +74 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/footnote-reference.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/heading.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/heading.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/html.js +32 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/html.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/image-reference.js +45 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/image-reference.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/image.js +40 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/image.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/index.js +67 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/index.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/inline-code.js +36 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/inline-code.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/link-reference.js +50 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/link-reference.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/link.js +41 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/link.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/list-item.js +126 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/list-item.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/list.js +57 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/list.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/paragraph.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/paragraph.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/root.js +27 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/root.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/strong.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/strong.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table-cell.js +33 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table-cell.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table-row.js +70 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table-row.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table.js +65 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/table.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/text.js +29 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/text.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/thematic-break.js +31 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/handlers/thematic-break.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/index.js +105 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/index.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/revert.js +56 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/revert.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/state.js +322 -0
- package/library/esm/node_modules/mdast-util-to-hast/lib/state.js.map +1 -0
- package/library/esm/node_modules/mdast-util-to-string/lib/index.js +111 -0
- package/library/esm/node_modules/mdast-util-to-string/lib/index.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/constructs.js +108 -0
- package/library/esm/node_modules/micromark/lib/constructs.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/create-tokenizer.js +576 -0
- package/library/esm/node_modules/micromark/lib/create-tokenizer.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/initialize/content.js +83 -0
- package/library/esm/node_modules/micromark/lib/initialize/content.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/initialize/document.js +361 -0
- package/library/esm/node_modules/micromark/lib/initialize/document.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/initialize/flow.js +62 -0
- package/library/esm/node_modules/micromark/lib/initialize/flow.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/initialize/text.js +213 -0
- package/library/esm/node_modules/micromark/lib/initialize/text.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/parse.js +60 -0
- package/library/esm/node_modules/micromark/lib/parse.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/postprocess.js +22 -0
- package/library/esm/node_modules/micromark/lib/postprocess.js.map +1 -0
- package/library/esm/node_modules/micromark/lib/preprocess.js +118 -0
- package/library/esm/node_modules/micromark/lib/preprocess.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/attention.js +245 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/attention.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/autolink.js +237 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/autolink.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/blank-line.js +65 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/blank-line.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/block-quote.js +147 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/block-quote.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/character-escape.js +68 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/character-escape.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/character-reference.js +153 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/character-reference.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-fenced.js +464 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-fenced.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-indented.js +181 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-indented.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-text.js +228 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/code-text.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/content.js +167 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/content.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/definition.js +258 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/definition.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/hard-break-escape.js +64 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/hard-break-escape.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/heading-atx.js +199 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/heading-atx.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/html-flow.js +880 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/html-flow.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/html-text.js +682 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/html-text.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-end.js +564 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-end.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-start-image.js +106 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-start-image.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-start-link.js +59 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/label-start-link.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/line-ending.js +36 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/line-ending.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/list.js +217 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/list.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/setext-underline.js +189 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/setext-underline.js.map +1 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/thematic-break.js +106 -0
- package/library/esm/node_modules/micromark-core-commonmark/lib/thematic-break.js.map +1 -0
- package/library/esm/node_modules/micromark-factory-destination/index.js +210 -0
- package/library/esm/node_modules/micromark-factory-destination/index.js.map +1 -0
- package/library/esm/node_modules/micromark-factory-label/index.js +152 -0
- package/library/esm/node_modules/micromark-factory-label/index.js.map +1 -0
- package/library/esm/node_modules/micromark-factory-space/index.js +68 -0
- package/library/esm/node_modules/micromark-factory-space/index.js.map +1 -0
- package/library/esm/node_modules/micromark-factory-title/index.js +162 -0
- package/library/esm/node_modules/micromark-factory-title/index.js.map +1 -0
- package/library/esm/node_modules/micromark-factory-whitespace/index.js +48 -0
- package/library/esm/node_modules/micromark-factory-whitespace/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-character/index.js +249 -0
- package/library/esm/node_modules/micromark-util-character/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-chunked/index.js +84 -0
- package/library/esm/node_modules/micromark-util-chunked/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-classify-character/index.js +31 -0
- package/library/esm/node_modules/micromark-util-classify-character/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-combine-extensions/index.js +96 -0
- package/library/esm/node_modules/micromark-util-combine-extensions/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-decode-numeric-character-reference/index.js +35 -0
- package/library/esm/node_modules/micromark-util-decode-numeric-character-reference/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-decode-string/index.js +49 -0
- package/library/esm/node_modules/micromark-util-decode-string/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-html-tag-name/index.js +96 -0
- package/library/esm/node_modules/micromark-util-html-tag-name/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-normalize-identifier/index.js +36 -0
- package/library/esm/node_modules/micromark-util-normalize-identifier/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-resolve-all/index.js +35 -0
- package/library/esm/node_modules/micromark-util-resolve-all/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-sanitize-uri/index.js +67 -0
- package/library/esm/node_modules/micromark-util-sanitize-uri/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-subtokenize/index.js +227 -0
- package/library/esm/node_modules/micromark-util-subtokenize/index.js.map +1 -0
- package/library/esm/node_modules/micromark-util-subtokenize/lib/splice-buffer.js +254 -0
- package/library/esm/node_modules/micromark-util-subtokenize/lib/splice-buffer.js.map +1 -0
- package/library/esm/node_modules/property-information/index.js +16 -0
- package/library/esm/node_modules/property-information/index.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/aria.js +64 -0
- package/library/esm/node_modules/property-information/lib/aria.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/find.js +101 -0
- package/library/esm/node_modules/property-information/lib/find.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/hast-to-react.js +33 -0
- package/library/esm/node_modules/property-information/lib/hast-to-react.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/html.js +318 -0
- package/library/esm/node_modules/property-information/lib/html.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/normalize.js +15 -0
- package/library/esm/node_modules/property-information/lib/normalize.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/svg.js +564 -0
- package/library/esm/node_modules/property-information/lib/svg.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/case-insensitive-transform.js +16 -0
- package/library/esm/node_modules/property-information/lib/util/case-insensitive-transform.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/case-sensitive-transform.js +14 -0
- package/library/esm/node_modules/property-information/lib/util/case-sensitive-transform.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/create.js +47 -0
- package/library/esm/node_modules/property-information/lib/util/create.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/defined-info.js +64 -0
- package/library/esm/node_modules/property-information/lib/util/defined-info.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/info.js +35 -0
- package/library/esm/node_modules/property-information/lib/util/info.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/merge.js +31 -0
- package/library/esm/node_modules/property-information/lib/util/merge.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/schema.js +32 -0
- package/library/esm/node_modules/property-information/lib/util/schema.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/util/types.js +16 -0
- package/library/esm/node_modules/property-information/lib/util/types.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/xlink.js +20 -0
- package/library/esm/node_modules/property-information/lib/xlink.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/xml.js +12 -0
- package/library/esm/node_modules/property-information/lib/xml.js.map +1 -0
- package/library/esm/node_modules/property-information/lib/xmlns.js +12 -0
- package/library/esm/node_modules/property-information/lib/xmlns.js.map +1 -0
- package/library/esm/node_modules/react-markdown/lib/index.js +267 -0
- package/library/esm/node_modules/react-markdown/lib/index.js.map +1 -0
- package/library/esm/node_modules/react-router/dist/development/chunk-HA7DTUK3.js +1 -1
- package/library/esm/node_modules/react-router/node_modules/cookie/dist/index.js +1 -1
- package/library/esm/node_modules/remark-parse/lib/index.js +43 -0
- package/library/esm/node_modules/remark-parse/lib/index.js.map +1 -0
- package/library/esm/node_modules/remark-rehype/lib/index.js +132 -0
- package/library/esm/node_modules/remark-rehype/lib/index.js.map +1 -0
- package/library/esm/node_modules/space-separated-tokens/index.js +23 -0
- package/library/esm/node_modules/space-separated-tokens/index.js.map +1 -0
- package/library/esm/node_modules/style-mod/src/style-mod.js +175 -0
- package/library/esm/node_modules/style-mod/src/style-mod.js.map +1 -0
- package/library/esm/node_modules/style-to-js/cjs/index.js +38 -0
- package/library/esm/node_modules/style-to-js/cjs/index.js.map +1 -0
- package/library/esm/node_modules/style-to-js/cjs/utilities.js +58 -0
- package/library/esm/node_modules/style-to-js/cjs/utilities.js.map +1 -0
- package/library/esm/node_modules/style-to-object/cjs/index.js +56 -0
- package/library/esm/node_modules/style-to-object/cjs/index.js.map +1 -0
- package/library/esm/node_modules/trim-lines/index.js +72 -0
- package/library/esm/node_modules/trim-lines/index.js.map +1 -0
- package/library/esm/node_modules/trough/lib/index.js +209 -0
- package/library/esm/node_modules/trough/lib/index.js.map +1 -0
- package/library/esm/node_modules/unified/lib/callable-instance.js +47 -0
- package/library/esm/node_modules/unified/lib/callable-instance.js.map +1 -0
- package/library/esm/node_modules/unified/lib/index.js +979 -0
- package/library/esm/node_modules/unified/lib/index.js.map +1 -0
- package/library/esm/node_modules/unified/node_modules/is-plain-obj/index.js +11 -0
- package/library/esm/node_modules/unified/node_modules/is-plain-obj/index.js.map +1 -0
- package/library/esm/node_modules/unist-util-is/lib/index.js +179 -0
- package/library/esm/node_modules/unist-util-is/lib/index.js.map +1 -0
- package/library/esm/node_modules/unist-util-position/lib/index.js +98 -0
- package/library/esm/node_modules/unist-util-position/lib/index.js.map +1 -0
- package/library/esm/node_modules/unist-util-stringify-position/lib/index.js +87 -0
- package/library/esm/node_modules/unist-util-stringify-position/lib/index.js.map +1 -0
- package/library/esm/node_modules/unist-util-visit/lib/index.js +95 -0
- package/library/esm/node_modules/unist-util-visit/lib/index.js.map +1 -0
- package/library/esm/node_modules/unist-util-visit-parents/lib/color.js +10 -0
- package/library/esm/node_modules/unist-util-visit-parents/lib/color.js.map +1 -0
- package/library/esm/node_modules/unist-util-visit-parents/lib/index.js +188 -0
- package/library/esm/node_modules/unist-util-visit-parents/lib/index.js.map +1 -0
- package/library/esm/node_modules/vfile/lib/index.js +644 -0
- package/library/esm/node_modules/vfile/lib/index.js.map +1 -0
- package/library/esm/node_modules/vfile/lib/minpath.browser.js +427 -0
- package/library/esm/node_modules/vfile/lib/minpath.browser.js.map +1 -0
- package/library/esm/node_modules/vfile/lib/minproc.browser.js +11 -0
- package/library/esm/node_modules/vfile/lib/minproc.browser.js.map +1 -0
- package/library/esm/node_modules/vfile/lib/minurl.browser.js +77 -0
- package/library/esm/node_modules/vfile/lib/minurl.browser.js.map +1 -0
- package/library/esm/node_modules/vfile/lib/minurl.shared.js +34 -0
- package/library/esm/node_modules/vfile/lib/minurl.shared.js.map +1 -0
- package/library/esm/node_modules/vfile-message/lib/index.js +305 -0
- package/library/esm/node_modules/vfile-message/lib/index.js.map +1 -0
- package/library/esm/node_modules/w3c-keyname/index.js +122 -0
- package/library/esm/node_modules/w3c-keyname/index.js.map +1 -0
- package/library/esm/src/Form/Components/FieldLabel.js +13 -3
- package/library/esm/src/Form/Components/FieldLabel.js.map +1 -1
- package/library/esm/src/Form/Components/InlineMarkdown.js +15 -0
- package/library/esm/src/Form/Components/InlineMarkdown.js.map +1 -0
- package/library/esm/src/Form/Components/Inputs/Boolean.js +5 -2
- package/library/esm/src/Form/Components/Inputs/Boolean.js.map +1 -1
- package/library/esm/src/Form/Components/Inputs/GeoJSONInputLoader.js +1 -1
- package/library/esm/src/Form/Components/Inputs/Geometry.js +290 -329
- package/library/esm/src/Form/Components/Inputs/Geometry.js.map +1 -1
- package/library/esm/src/Form/Components/Inputs/JSON.js +132 -0
- package/library/esm/src/Form/Components/Inputs/JSON.js.map +1 -0
- package/library/esm/src/Form/Components/Inputs/JSONInputLoader.js +19 -0
- package/library/esm/src/Form/Components/Inputs/JSONInputLoader.js.map +1 -0
- package/library/esm/src/Form/Components/Inputs/Number.js +78 -8
- package/library/esm/src/Form/Components/Inputs/Number.js.map +1 -1
- package/library/esm/src/Form/Components/Inputs/inputMap.js +2 -2
- package/library/esm/src/Form/Components/Inputs/inputMap.js.map +1 -1
- package/library/esm/src/Form/Creator/FormCreator.js +6 -2
- package/library/esm/src/Form/Creator/FormCreator.js.map +1 -1
- package/library/esm/src/Form/Creator/FormHeader.js +7 -5
- package/library/esm/src/Form/Creator/FormHeader.js.map +1 -1
- package/library/esm/src/Form/Creator/Page.js +4 -3
- package/library/esm/src/Form/Creator/Page.js.map +1 -1
- package/library/esm/src/Form/Manage/CopyableJSONOutput.js +41 -0
- package/library/esm/src/Form/Manage/CopyableJSONOutput.js.map +1 -0
- package/library/esm/src/Form/helpers.js +1 -1
- package/library/esm/src/Form/helpers.js.map +1 -1
- package/library/esm/src/Form/schemaToFormHelpers.js +87 -1
- package/library/esm/src/Form/schemaToFormHelpers.js.map +1 -1
- package/library/esm/src/library.js +1 -1
- package/package.json +7 -1
- package/library/esm/src/Form/Components/Inputs/JSONString.js +0 -34
- package/library/esm/src/Form/Components/Inputs/JSONString.js.map +0 -1
@@ -0,0 +1,162 @@
|
|
1
|
+
import { factorySpace } from '../micromark-factory-space/index.js';
|
2
|
+
import { markdownLineEnding } from '../micromark-util-character/index.js';
|
3
|
+
|
4
|
+
/**
|
5
|
+
* @import {
|
6
|
+
* Code,
|
7
|
+
* Effects,
|
8
|
+
* State,
|
9
|
+
* TokenType
|
10
|
+
* } from 'micromark-util-types'
|
11
|
+
*/
|
12
|
+
|
13
|
+
/**
|
14
|
+
* Parse titles.
|
15
|
+
*
|
16
|
+
* ###### Examples
|
17
|
+
*
|
18
|
+
* ```markdown
|
19
|
+
* "a"
|
20
|
+
* 'b'
|
21
|
+
* (c)
|
22
|
+
* "a
|
23
|
+
* b"
|
24
|
+
* 'a
|
25
|
+
* b'
|
26
|
+
* (a\)b)
|
27
|
+
* ```
|
28
|
+
*
|
29
|
+
* @param {Effects} effects
|
30
|
+
* Context.
|
31
|
+
* @param {State} ok
|
32
|
+
* State switched to when successful.
|
33
|
+
* @param {State} nok
|
34
|
+
* State switched to when unsuccessful.
|
35
|
+
* @param {TokenType} type
|
36
|
+
* Type of the whole title (`"a"`, `'b'`, `(c)`).
|
37
|
+
* @param {TokenType} markerType
|
38
|
+
* Type for the markers (`"`, `'`, `(`, and `)`).
|
39
|
+
* @param {TokenType} stringType
|
40
|
+
* Type for the value (`a`).
|
41
|
+
* @returns {State}
|
42
|
+
* Start state.
|
43
|
+
*/
|
44
|
+
function factoryTitle(effects, ok, nok, type, markerType, stringType) {
|
45
|
+
/** @type {NonNullable<Code>} */
|
46
|
+
let marker;
|
47
|
+
return start;
|
48
|
+
|
49
|
+
/**
|
50
|
+
* Start of title.
|
51
|
+
*
|
52
|
+
* ```markdown
|
53
|
+
* > | "a"
|
54
|
+
* ^
|
55
|
+
* ```
|
56
|
+
*
|
57
|
+
* @type {State}
|
58
|
+
*/
|
59
|
+
function start(code) {
|
60
|
+
if (code === 34 || code === 39 || code === 40) {
|
61
|
+
effects.enter(type);
|
62
|
+
effects.enter(markerType);
|
63
|
+
effects.consume(code);
|
64
|
+
effects.exit(markerType);
|
65
|
+
marker = code === 40 ? 41 : code;
|
66
|
+
return begin;
|
67
|
+
}
|
68
|
+
return nok(code);
|
69
|
+
}
|
70
|
+
|
71
|
+
/**
|
72
|
+
* After opening marker.
|
73
|
+
*
|
74
|
+
* This is also used at the closing marker.
|
75
|
+
*
|
76
|
+
* ```markdown
|
77
|
+
* > | "a"
|
78
|
+
* ^
|
79
|
+
* ```
|
80
|
+
*
|
81
|
+
* @type {State}
|
82
|
+
*/
|
83
|
+
function begin(code) {
|
84
|
+
if (code === marker) {
|
85
|
+
effects.enter(markerType);
|
86
|
+
effects.consume(code);
|
87
|
+
effects.exit(markerType);
|
88
|
+
effects.exit(type);
|
89
|
+
return ok;
|
90
|
+
}
|
91
|
+
effects.enter(stringType);
|
92
|
+
return atBreak(code);
|
93
|
+
}
|
94
|
+
|
95
|
+
/**
|
96
|
+
* At something, before something else.
|
97
|
+
*
|
98
|
+
* ```markdown
|
99
|
+
* > | "a"
|
100
|
+
* ^
|
101
|
+
* ```
|
102
|
+
*
|
103
|
+
* @type {State}
|
104
|
+
*/
|
105
|
+
function atBreak(code) {
|
106
|
+
if (code === marker) {
|
107
|
+
effects.exit(stringType);
|
108
|
+
return begin(marker);
|
109
|
+
}
|
110
|
+
if (code === null) {
|
111
|
+
return nok(code);
|
112
|
+
}
|
113
|
+
|
114
|
+
// Note: blank lines can’t exist in content.
|
115
|
+
if (markdownLineEnding(code)) {
|
116
|
+
// To do: use `space_or_tab_eol_with_options`, connect.
|
117
|
+
effects.enter("lineEnding");
|
118
|
+
effects.consume(code);
|
119
|
+
effects.exit("lineEnding");
|
120
|
+
return factorySpace(effects, atBreak, "linePrefix");
|
121
|
+
}
|
122
|
+
effects.enter("chunkString", {
|
123
|
+
contentType: "string"
|
124
|
+
});
|
125
|
+
return inside(code);
|
126
|
+
}
|
127
|
+
|
128
|
+
/**
|
129
|
+
*
|
130
|
+
*
|
131
|
+
* @type {State}
|
132
|
+
*/
|
133
|
+
function inside(code) {
|
134
|
+
if (code === marker || code === null || markdownLineEnding(code)) {
|
135
|
+
effects.exit("chunkString");
|
136
|
+
return atBreak(code);
|
137
|
+
}
|
138
|
+
effects.consume(code);
|
139
|
+
return code === 92 ? escape : inside;
|
140
|
+
}
|
141
|
+
|
142
|
+
/**
|
143
|
+
* After `\`, at a special character.
|
144
|
+
*
|
145
|
+
* ```markdown
|
146
|
+
* > | "a\*b"
|
147
|
+
* ^
|
148
|
+
* ```
|
149
|
+
*
|
150
|
+
* @type {State}
|
151
|
+
*/
|
152
|
+
function escape(code) {
|
153
|
+
if (code === marker || code === 92) {
|
154
|
+
effects.consume(code);
|
155
|
+
return inside;
|
156
|
+
}
|
157
|
+
return inside(code);
|
158
|
+
}
|
159
|
+
}
|
160
|
+
|
161
|
+
export { factoryTitle };
|
162
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../node_modules/micromark-factory-title/index.js"],"sourcesContent":["/**\n * @import {\n * Code,\n * Effects,\n * State,\n * TokenType\n * } from 'micromark-util-types'\n */\n\nimport { factorySpace } from 'micromark-factory-space';\nimport { markdownLineEnding } from 'micromark-util-character';\n/**\n * Parse titles.\n *\n * ###### Examples\n *\n * ```markdown\n * \"a\"\n * 'b'\n * (c)\n * \"a\n * b\"\n * 'a\n * b'\n * (a\\)b)\n * ```\n *\n * @param {Effects} effects\n * Context.\n * @param {State} ok\n * State switched to when successful.\n * @param {State} nok\n * State switched to when unsuccessful.\n * @param {TokenType} type\n * Type of the whole title (`\"a\"`, `'b'`, `(c)`).\n * @param {TokenType} markerType\n * Type for the markers (`\"`, `'`, `(`, and `)`).\n * @param {TokenType} stringType\n * Type for the value (`a`).\n * @returns {State}\n * Start state.\n */\nexport function factoryTitle(effects, ok, nok, type, markerType, stringType) {\n /** @type {NonNullable<Code>} */\n let marker;\n return start;\n\n /**\n * Start of title.\n *\n * ```markdown\n * > | \"a\"\n * ^\n * ```\n *\n * @type {State}\n */\n function start(code) {\n if (code === 34 || code === 39 || code === 40) {\n effects.enter(type);\n effects.enter(markerType);\n effects.consume(code);\n effects.exit(markerType);\n marker = code === 40 ? 41 : code;\n return begin;\n }\n return nok(code);\n }\n\n /**\n * After opening marker.\n *\n * This is also used at the closing marker.\n *\n * ```markdown\n * > | \"a\"\n * ^\n * ```\n *\n * @type {State}\n */\n function begin(code) {\n if (code === marker) {\n effects.enter(markerType);\n effects.consume(code);\n effects.exit(markerType);\n effects.exit(type);\n return ok;\n }\n effects.enter(stringType);\n return atBreak(code);\n }\n\n /**\n * At something, before something else.\n *\n * ```markdown\n * > | \"a\"\n * ^\n * ```\n *\n * @type {State}\n */\n function atBreak(code) {\n if (code === marker) {\n effects.exit(stringType);\n return begin(marker);\n }\n if (code === null) {\n return nok(code);\n }\n\n // Note: blank lines can’t exist in content.\n if (markdownLineEnding(code)) {\n // To do: use `space_or_tab_eol_with_options`, connect.\n effects.enter(\"lineEnding\");\n effects.consume(code);\n effects.exit(\"lineEnding\");\n return factorySpace(effects, atBreak, \"linePrefix\");\n }\n effects.enter(\"chunkString\", {\n contentType: \"string\"\n });\n return inside(code);\n }\n\n /**\n *\n *\n * @type {State}\n */\n function inside(code) {\n if (code === marker || code === null || markdownLineEnding(code)) {\n effects.exit(\"chunkString\");\n return atBreak(code);\n }\n effects.consume(code);\n return code === 92 ? escape : inside;\n }\n\n /**\n * After `\\`, at a special character.\n *\n * ```markdown\n * > | \"a\\*b\"\n * ^\n * ```\n *\n * @type {State}\n */\n function escape(code) {\n if (code === marker || code === 92) {\n effects.consume(code);\n return inside;\n }\n return inside(code);\n }\n}"],"names":[],"mappings":";;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,YAAY,CAAC,OAAO,EAAE,EAAE,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,UAAU,EAAE;AAC7E;AACA,EAAE,IAAI,MAAM;AACZ,EAAE,OAAO,KAAK;;AAEd;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,KAAK,CAAC,IAAI,EAAE;AACvB,IAAI,IAAI,IAAI,KAAK,EAAE,IAAI,IAAI,KAAK,EAAE,IAAI,IAAI,KAAK,EAAE,EAAE;AACnD,MAAM,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC;AACzB,MAAM,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC;AAC/B,MAAM,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AAC3B,MAAM,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC;AAC9B,MAAM,MAAM,GAAG,IAAI,KAAK,EAAE,GAAG,EAAE,GAAG,IAAI;AACtC,MAAM,OAAO,KAAK;AAClB;AACA,IAAI,OAAO,GAAG,CAAC,IAAI,CAAC;AACpB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,KAAK,CAAC,IAAI,EAAE;AACvB,IAAI,IAAI,IAAI,KAAK,MAAM,EAAE;AACzB,MAAM,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC;AAC/B,MAAM,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AAC3B,MAAM,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC;AAC9B,MAAM,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC;AACxB,MAAM,OAAO,EAAE;AACf;AACA,IAAI,OAAO,CAAC,KAAK,CAAC,UAAU,CAAC;AAC7B,IAAI,OAAO,OAAO,CAAC,IAAI,CAAC;AACxB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,OAAO,CAAC,IAAI,EAAE;AACzB,IAAI,IAAI,IAAI,KAAK,MAAM,EAAE;AACzB,MAAM,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC;AAC9B,MAAM,OAAO,KAAK,CAAC,MAAM,CAAC;AAC1B;AACA,IAAI,IAAI,IAAI,KAAK,IAAI,EAAE;AACvB,MAAM,OAAO,GAAG,CAAC,IAAI,CAAC;AACtB;;AAEA;AACA,IAAI,IAAI,kBAAkB,CAAC,IAAI,CAAC,EAAE;AAClC;AACA,MAAM,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC;AACjC,MAAM,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AAC3B,MAAM,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC;AAChC,MAAM,OAAO,YAAY,CAAC,OAAO,EAAE,OAAO,EAAE,YAAY,CAAC;AACzD;AACA,IAAI,OAAO,CAAC,KAAK,CAAC,aAAa,EAAE;AACjC,MAAM,WAAW,EAAE;AACnB,KAAK,CAAC;AACN,IAAI,OAAO,MAAM,CAAC,IAAI,CAAC;AACvB;;AAEA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,MAAM,CAAC,IAAI,EAAE;AACxB,IAAI,IAAI,IAAI,KAAK,MAAM,IAAI,IAAI,KAAK,IAAI,IAAI,kBAAkB,CAAC,IAAI,CAAC,EAAE;AACtE,MAAM,OAAO,CAAC,IAAI,CAAC,aAAa,CAAC;AACjC,MAAM,OAAO,OAAO,CAAC,IAAI,CAAC;AAC1B;AACA,IAAI,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AACzB,IAAI,OAAO,IAAI,KAAK,EAAE,GAAG,MAAM,GAAG,MAAM;AACxC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,MAAM,CAAC,IAAI,EAAE;AACxB,IAAI,IAAI,IAAI,KAAK,MAAM,IAAI,IAAI,KAAK,EAAE,EAAE;AACxC,MAAM,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AAC3B,MAAM,OAAO,MAAM;AACnB;AACA,IAAI,OAAO,MAAM,CAAC,IAAI,CAAC;AACvB;AACA;;;;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,48 @@
|
|
1
|
+
import { factorySpace } from '../micromark-factory-space/index.js';
|
2
|
+
import { markdownLineEnding, markdownSpace } from '../micromark-util-character/index.js';
|
3
|
+
|
4
|
+
/**
|
5
|
+
* @import {Effects, State} from 'micromark-util-types'
|
6
|
+
*/
|
7
|
+
|
8
|
+
/**
|
9
|
+
* Parse spaces and tabs.
|
10
|
+
*
|
11
|
+
* There is no `nok` parameter:
|
12
|
+
*
|
13
|
+
* * line endings or spaces in markdown are often optional, in which case this
|
14
|
+
* factory can be used and `ok` will be switched to whether spaces were found
|
15
|
+
* or not
|
16
|
+
* * one line ending or space can be detected with
|
17
|
+
* `markdownLineEndingOrSpace(code)` right before using `factoryWhitespace`
|
18
|
+
*
|
19
|
+
* @param {Effects} effects
|
20
|
+
* Context.
|
21
|
+
* @param {State} ok
|
22
|
+
* State switched to when successful.
|
23
|
+
* @returns {State}
|
24
|
+
* Start state.
|
25
|
+
*/
|
26
|
+
function factoryWhitespace(effects, ok) {
|
27
|
+
/** @type {boolean} */
|
28
|
+
let seen;
|
29
|
+
return start;
|
30
|
+
|
31
|
+
/** @type {State} */
|
32
|
+
function start(code) {
|
33
|
+
if (markdownLineEnding(code)) {
|
34
|
+
effects.enter("lineEnding");
|
35
|
+
effects.consume(code);
|
36
|
+
effects.exit("lineEnding");
|
37
|
+
seen = true;
|
38
|
+
return start;
|
39
|
+
}
|
40
|
+
if (markdownSpace(code)) {
|
41
|
+
return factorySpace(effects, start, seen ? "linePrefix" : "lineSuffix")(code);
|
42
|
+
}
|
43
|
+
return ok(code);
|
44
|
+
}
|
45
|
+
}
|
46
|
+
|
47
|
+
export { factoryWhitespace };
|
48
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../node_modules/micromark-factory-whitespace/index.js"],"sourcesContent":["/**\n * @import {Effects, State} from 'micromark-util-types'\n */\n\nimport { factorySpace } from 'micromark-factory-space';\nimport { markdownLineEnding, markdownSpace } from 'micromark-util-character';\n/**\n * Parse spaces and tabs.\n *\n * There is no `nok` parameter:\n *\n * * line endings or spaces in markdown are often optional, in which case this\n * factory can be used and `ok` will be switched to whether spaces were found\n * or not\n * * one line ending or space can be detected with\n * `markdownLineEndingOrSpace(code)` right before using `factoryWhitespace`\n *\n * @param {Effects} effects\n * Context.\n * @param {State} ok\n * State switched to when successful.\n * @returns {State}\n * Start state.\n */\nexport function factoryWhitespace(effects, ok) {\n /** @type {boolean} */\n let seen;\n return start;\n\n /** @type {State} */\n function start(code) {\n if (markdownLineEnding(code)) {\n effects.enter(\"lineEnding\");\n effects.consume(code);\n effects.exit(\"lineEnding\");\n seen = true;\n return start;\n }\n if (markdownSpace(code)) {\n return factorySpace(effects, start, seen ? \"linePrefix\" : \"lineSuffix\")(code);\n }\n return ok(code);\n }\n}"],"names":[],"mappings":";;;AAAA;AACA;AACA;;AAIA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,iBAAiB,CAAC,OAAO,EAAE,EAAE,EAAE;AAC/C;AACA,EAAE,IAAI,IAAI;AACV,EAAE,OAAO,KAAK;;AAEd;AACA,EAAE,SAAS,KAAK,CAAC,IAAI,EAAE;AACvB,IAAI,IAAI,kBAAkB,CAAC,IAAI,CAAC,EAAE;AAClC,MAAM,OAAO,CAAC,KAAK,CAAC,YAAY,CAAC;AACjC,MAAM,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC;AAC3B,MAAM,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC;AAChC,MAAM,IAAI,GAAG,IAAI;AACjB,MAAM,OAAO,KAAK;AAClB;AACA,IAAI,IAAI,aAAa,CAAC,IAAI,CAAC,EAAE;AAC7B,MAAM,OAAO,YAAY,CAAC,OAAO,EAAE,KAAK,EAAE,IAAI,GAAG,YAAY,GAAG,YAAY,CAAC,CAAC,IAAI,CAAC;AACnF;AACA,IAAI,OAAO,EAAE,CAAC,IAAI,CAAC;AACnB;AACA;;;;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,249 @@
|
|
1
|
+
/**
|
2
|
+
* @import {Code} from 'micromark-util-types'
|
3
|
+
*/
|
4
|
+
|
5
|
+
/**
|
6
|
+
* Check whether the character code represents an ASCII alpha (`a` through `z`,
|
7
|
+
* case insensitive).
|
8
|
+
*
|
9
|
+
* An **ASCII alpha** is an ASCII upper alpha or ASCII lower alpha.
|
10
|
+
*
|
11
|
+
* An **ASCII upper alpha** is a character in the inclusive range U+0041 (`A`)
|
12
|
+
* to U+005A (`Z`).
|
13
|
+
*
|
14
|
+
* An **ASCII lower alpha** is a character in the inclusive range U+0061 (`a`)
|
15
|
+
* to U+007A (`z`).
|
16
|
+
*
|
17
|
+
* @param code
|
18
|
+
* Code.
|
19
|
+
* @returns {boolean}
|
20
|
+
* Whether it matches.
|
21
|
+
*/
|
22
|
+
const asciiAlpha = regexCheck(/[A-Za-z]/);
|
23
|
+
|
24
|
+
/**
|
25
|
+
* Check whether the character code represents an ASCII alphanumeric (`a`
|
26
|
+
* through `z`, case insensitive, or `0` through `9`).
|
27
|
+
*
|
28
|
+
* An **ASCII alphanumeric** is an ASCII digit (see `asciiDigit`) or ASCII alpha
|
29
|
+
* (see `asciiAlpha`).
|
30
|
+
*
|
31
|
+
* @param code
|
32
|
+
* Code.
|
33
|
+
* @returns {boolean}
|
34
|
+
* Whether it matches.
|
35
|
+
*/
|
36
|
+
const asciiAlphanumeric = regexCheck(/[\dA-Za-z]/);
|
37
|
+
|
38
|
+
/**
|
39
|
+
* Check whether the character code represents an ASCII atext.
|
40
|
+
*
|
41
|
+
* atext is an ASCII alphanumeric (see `asciiAlphanumeric`), or a character in
|
42
|
+
* the inclusive ranges U+0023 NUMBER SIGN (`#`) to U+0027 APOSTROPHE (`'`),
|
43
|
+
* U+002A ASTERISK (`*`), U+002B PLUS SIGN (`+`), U+002D DASH (`-`), U+002F
|
44
|
+
* SLASH (`/`), U+003D EQUALS TO (`=`), U+003F QUESTION MARK (`?`), U+005E
|
45
|
+
* CARET (`^`) to U+0060 GRAVE ACCENT (`` ` ``), or U+007B LEFT CURLY BRACE
|
46
|
+
* (`{`) to U+007E TILDE (`~`).
|
47
|
+
*
|
48
|
+
* See:
|
49
|
+
* **\[RFC5322]**:
|
50
|
+
* [Internet Message Format](https://tools.ietf.org/html/rfc5322).
|
51
|
+
* P. Resnick.
|
52
|
+
* IETF.
|
53
|
+
*
|
54
|
+
* @param code
|
55
|
+
* Code.
|
56
|
+
* @returns {boolean}
|
57
|
+
* Whether it matches.
|
58
|
+
*/
|
59
|
+
const asciiAtext = regexCheck(/[#-'*+\--9=?A-Z^-~]/);
|
60
|
+
|
61
|
+
/**
|
62
|
+
* Check whether a character code is an ASCII control character.
|
63
|
+
*
|
64
|
+
* An **ASCII control** is a character in the inclusive range U+0000 NULL (NUL)
|
65
|
+
* to U+001F (US), or U+007F (DEL).
|
66
|
+
*
|
67
|
+
* @param {Code} code
|
68
|
+
* Code.
|
69
|
+
* @returns {boolean}
|
70
|
+
* Whether it matches.
|
71
|
+
*/
|
72
|
+
function asciiControl(code) {
|
73
|
+
return (
|
74
|
+
// Special whitespace codes (which have negative values), C0 and Control
|
75
|
+
// character DEL
|
76
|
+
code !== null && (code < 32 || code === 127)
|
77
|
+
);
|
78
|
+
}
|
79
|
+
|
80
|
+
/**
|
81
|
+
* Check whether the character code represents an ASCII digit (`0` through `9`).
|
82
|
+
*
|
83
|
+
* An **ASCII digit** is a character in the inclusive range U+0030 (`0`) to
|
84
|
+
* U+0039 (`9`).
|
85
|
+
*
|
86
|
+
* @param code
|
87
|
+
* Code.
|
88
|
+
* @returns {boolean}
|
89
|
+
* Whether it matches.
|
90
|
+
*/
|
91
|
+
const asciiDigit = regexCheck(/\d/);
|
92
|
+
|
93
|
+
/**
|
94
|
+
* Check whether the character code represents an ASCII hex digit (`a` through
|
95
|
+
* `f`, case insensitive, or `0` through `9`).
|
96
|
+
*
|
97
|
+
* An **ASCII hex digit** is an ASCII digit (see `asciiDigit`), ASCII upper hex
|
98
|
+
* digit, or an ASCII lower hex digit.
|
99
|
+
*
|
100
|
+
* An **ASCII upper hex digit** is a character in the inclusive range U+0041
|
101
|
+
* (`A`) to U+0046 (`F`).
|
102
|
+
*
|
103
|
+
* An **ASCII lower hex digit** is a character in the inclusive range U+0061
|
104
|
+
* (`a`) to U+0066 (`f`).
|
105
|
+
*
|
106
|
+
* @param code
|
107
|
+
* Code.
|
108
|
+
* @returns {boolean}
|
109
|
+
* Whether it matches.
|
110
|
+
*/
|
111
|
+
const asciiHexDigit = regexCheck(/[\dA-Fa-f]/);
|
112
|
+
|
113
|
+
/**
|
114
|
+
* Check whether the character code represents ASCII punctuation.
|
115
|
+
*
|
116
|
+
* An **ASCII punctuation** is a character in the inclusive ranges U+0021
|
117
|
+
* EXCLAMATION MARK (`!`) to U+002F SLASH (`/`), U+003A COLON (`:`) to U+0040 AT
|
118
|
+
* SIGN (`@`), U+005B LEFT SQUARE BRACKET (`[`) to U+0060 GRAVE ACCENT
|
119
|
+
* (`` ` ``), or U+007B LEFT CURLY BRACE (`{`) to U+007E TILDE (`~`).
|
120
|
+
*
|
121
|
+
* @param code
|
122
|
+
* Code.
|
123
|
+
* @returns {boolean}
|
124
|
+
* Whether it matches.
|
125
|
+
*/
|
126
|
+
const asciiPunctuation = regexCheck(/[!-/:-@[-`{-~]/);
|
127
|
+
|
128
|
+
/**
|
129
|
+
* Check whether a character code is a markdown line ending.
|
130
|
+
*
|
131
|
+
* A **markdown line ending** is the virtual characters M-0003 CARRIAGE RETURN
|
132
|
+
* LINE FEED (CRLF), M-0004 LINE FEED (LF) and M-0005 CARRIAGE RETURN (CR).
|
133
|
+
*
|
134
|
+
* In micromark, the actual character U+000A LINE FEED (LF) and U+000D CARRIAGE
|
135
|
+
* RETURN (CR) are replaced by these virtual characters depending on whether
|
136
|
+
* they occurred together.
|
137
|
+
*
|
138
|
+
* @param {Code} code
|
139
|
+
* Code.
|
140
|
+
* @returns {boolean}
|
141
|
+
* Whether it matches.
|
142
|
+
*/
|
143
|
+
function markdownLineEnding(code) {
|
144
|
+
return code !== null && code < -2;
|
145
|
+
}
|
146
|
+
|
147
|
+
/**
|
148
|
+
* Check whether a character code is a markdown line ending (see
|
149
|
+
* `markdownLineEnding`) or markdown space (see `markdownSpace`).
|
150
|
+
*
|
151
|
+
* @param {Code} code
|
152
|
+
* Code.
|
153
|
+
* @returns {boolean}
|
154
|
+
* Whether it matches.
|
155
|
+
*/
|
156
|
+
function markdownLineEndingOrSpace(code) {
|
157
|
+
return code !== null && (code < 0 || code === 32);
|
158
|
+
}
|
159
|
+
|
160
|
+
/**
|
161
|
+
* Check whether a character code is a markdown space.
|
162
|
+
*
|
163
|
+
* A **markdown space** is the concrete character U+0020 SPACE (SP) and the
|
164
|
+
* virtual characters M-0001 VIRTUAL SPACE (VS) and M-0002 HORIZONTAL TAB (HT).
|
165
|
+
*
|
166
|
+
* In micromark, the actual character U+0009 CHARACTER TABULATION (HT) is
|
167
|
+
* replaced by one M-0002 HORIZONTAL TAB (HT) and between 0 and 3 M-0001 VIRTUAL
|
168
|
+
* SPACE (VS) characters, depending on the column at which the tab occurred.
|
169
|
+
*
|
170
|
+
* @param {Code} code
|
171
|
+
* Code.
|
172
|
+
* @returns {boolean}
|
173
|
+
* Whether it matches.
|
174
|
+
*/
|
175
|
+
function markdownSpace(code) {
|
176
|
+
return code === -2 || code === -1 || code === 32;
|
177
|
+
}
|
178
|
+
|
179
|
+
// Size note: removing ASCII from the regex and using `asciiPunctuation` here
|
180
|
+
// In fact adds to the bundle size.
|
181
|
+
/**
|
182
|
+
* Check whether the character code represents Unicode punctuation.
|
183
|
+
*
|
184
|
+
* A **Unicode punctuation** is a character in the Unicode `Pc` (Punctuation,
|
185
|
+
* Connector), `Pd` (Punctuation, Dash), `Pe` (Punctuation, Close), `Pf`
|
186
|
+
* (Punctuation, Final quote), `Pi` (Punctuation, Initial quote), `Po`
|
187
|
+
* (Punctuation, Other), or `Ps` (Punctuation, Open) categories, or an ASCII
|
188
|
+
* punctuation (see `asciiPunctuation`).
|
189
|
+
*
|
190
|
+
* See:
|
191
|
+
* **\[UNICODE]**:
|
192
|
+
* [The Unicode Standard](https://www.unicode.org/versions/).
|
193
|
+
* Unicode Consortium.
|
194
|
+
*
|
195
|
+
* @param code
|
196
|
+
* Code.
|
197
|
+
* @returns
|
198
|
+
* Whether it matches.
|
199
|
+
*/
|
200
|
+
const unicodePunctuation = regexCheck(/\p{P}|\p{S}/u);
|
201
|
+
|
202
|
+
/**
|
203
|
+
* Check whether the character code represents Unicode whitespace.
|
204
|
+
*
|
205
|
+
* Note that this does handle micromark specific markdown whitespace characters.
|
206
|
+
* See `markdownLineEndingOrSpace` to check that.
|
207
|
+
*
|
208
|
+
* A **Unicode whitespace** is a character in the Unicode `Zs` (Separator,
|
209
|
+
* Space) category, or U+0009 CHARACTER TABULATION (HT), U+000A LINE FEED (LF),
|
210
|
+
* U+000C (FF), or U+000D CARRIAGE RETURN (CR) (**\[UNICODE]**).
|
211
|
+
*
|
212
|
+
* See:
|
213
|
+
* **\[UNICODE]**:
|
214
|
+
* [The Unicode Standard](https://www.unicode.org/versions/).
|
215
|
+
* Unicode Consortium.
|
216
|
+
*
|
217
|
+
* @param code
|
218
|
+
* Code.
|
219
|
+
* @returns
|
220
|
+
* Whether it matches.
|
221
|
+
*/
|
222
|
+
const unicodeWhitespace = regexCheck(/\s/);
|
223
|
+
|
224
|
+
/**
|
225
|
+
* Create a code check from a regex.
|
226
|
+
*
|
227
|
+
* @param {RegExp} regex
|
228
|
+
* Expression.
|
229
|
+
* @returns {(code: Code) => boolean}
|
230
|
+
* Check.
|
231
|
+
*/
|
232
|
+
function regexCheck(regex) {
|
233
|
+
return check;
|
234
|
+
|
235
|
+
/**
|
236
|
+
* Check whether a code matches the bound regex.
|
237
|
+
*
|
238
|
+
* @param {Code} code
|
239
|
+
* Character code.
|
240
|
+
* @returns {boolean}
|
241
|
+
* Whether the character code matches the bound regex.
|
242
|
+
*/
|
243
|
+
function check(code) {
|
244
|
+
return code !== null && code > -1 && regex.test(String.fromCharCode(code));
|
245
|
+
}
|
246
|
+
}
|
247
|
+
|
248
|
+
export { asciiAlpha, asciiAlphanumeric, asciiAtext, asciiControl, asciiDigit, asciiHexDigit, asciiPunctuation, markdownLineEnding, markdownLineEndingOrSpace, markdownSpace, unicodePunctuation, unicodeWhitespace };
|
249
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../node_modules/micromark-util-character/index.js"],"sourcesContent":["/**\n * @import {Code} from 'micromark-util-types'\n */\n\n/**\n * Check whether the character code represents an ASCII alpha (`a` through `z`,\n * case insensitive).\n *\n * An **ASCII alpha** is an ASCII upper alpha or ASCII lower alpha.\n *\n * An **ASCII upper alpha** is a character in the inclusive range U+0041 (`A`)\n * to U+005A (`Z`).\n *\n * An **ASCII lower alpha** is a character in the inclusive range U+0061 (`a`)\n * to U+007A (`z`).\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiAlpha = regexCheck(/[A-Za-z]/);\n\n/**\n * Check whether the character code represents an ASCII alphanumeric (`a`\n * through `z`, case insensitive, or `0` through `9`).\n *\n * An **ASCII alphanumeric** is an ASCII digit (see `asciiDigit`) or ASCII alpha\n * (see `asciiAlpha`).\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiAlphanumeric = regexCheck(/[\\dA-Za-z]/);\n\n/**\n * Check whether the character code represents an ASCII atext.\n *\n * atext is an ASCII alphanumeric (see `asciiAlphanumeric`), or a character in\n * the inclusive ranges U+0023 NUMBER SIGN (`#`) to U+0027 APOSTROPHE (`'`),\n * U+002A ASTERISK (`*`), U+002B PLUS SIGN (`+`), U+002D DASH (`-`), U+002F\n * SLASH (`/`), U+003D EQUALS TO (`=`), U+003F QUESTION MARK (`?`), U+005E\n * CARET (`^`) to U+0060 GRAVE ACCENT (`` ` ``), or U+007B LEFT CURLY BRACE\n * (`{`) to U+007E TILDE (`~`).\n *\n * See:\n * **\\[RFC5322]**:\n * [Internet Message Format](https://tools.ietf.org/html/rfc5322).\n * P. Resnick.\n * IETF.\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiAtext = regexCheck(/[#-'*+\\--9=?A-Z^-~]/);\n\n/**\n * Check whether a character code is an ASCII control character.\n *\n * An **ASCII control** is a character in the inclusive range U+0000 NULL (NUL)\n * to U+001F (US), or U+007F (DEL).\n *\n * @param {Code} code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport function asciiControl(code) {\n return (\n // Special whitespace codes (which have negative values), C0 and Control\n // character DEL\n code !== null && (code < 32 || code === 127)\n );\n}\n\n/**\n * Check whether the character code represents an ASCII digit (`0` through `9`).\n *\n * An **ASCII digit** is a character in the inclusive range U+0030 (`0`) to\n * U+0039 (`9`).\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiDigit = regexCheck(/\\d/);\n\n/**\n * Check whether the character code represents an ASCII hex digit (`a` through\n * `f`, case insensitive, or `0` through `9`).\n *\n * An **ASCII hex digit** is an ASCII digit (see `asciiDigit`), ASCII upper hex\n * digit, or an ASCII lower hex digit.\n *\n * An **ASCII upper hex digit** is a character in the inclusive range U+0041\n * (`A`) to U+0046 (`F`).\n *\n * An **ASCII lower hex digit** is a character in the inclusive range U+0061\n * (`a`) to U+0066 (`f`).\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiHexDigit = regexCheck(/[\\dA-Fa-f]/);\n\n/**\n * Check whether the character code represents ASCII punctuation.\n *\n * An **ASCII punctuation** is a character in the inclusive ranges U+0021\n * EXCLAMATION MARK (`!`) to U+002F SLASH (`/`), U+003A COLON (`:`) to U+0040 AT\n * SIGN (`@`), U+005B LEFT SQUARE BRACKET (`[`) to U+0060 GRAVE ACCENT\n * (`` ` ``), or U+007B LEFT CURLY BRACE (`{`) to U+007E TILDE (`~`).\n *\n * @param code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport const asciiPunctuation = regexCheck(/[!-/:-@[-`{-~]/);\n\n/**\n * Check whether a character code is a markdown line ending.\n *\n * A **markdown line ending** is the virtual characters M-0003 CARRIAGE RETURN\n * LINE FEED (CRLF), M-0004 LINE FEED (LF) and M-0005 CARRIAGE RETURN (CR).\n *\n * In micromark, the actual character U+000A LINE FEED (LF) and U+000D CARRIAGE\n * RETURN (CR) are replaced by these virtual characters depending on whether\n * they occurred together.\n *\n * @param {Code} code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport function markdownLineEnding(code) {\n return code !== null && code < -2;\n}\n\n/**\n * Check whether a character code is a markdown line ending (see\n * `markdownLineEnding`) or markdown space (see `markdownSpace`).\n *\n * @param {Code} code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport function markdownLineEndingOrSpace(code) {\n return code !== null && (code < 0 || code === 32);\n}\n\n/**\n * Check whether a character code is a markdown space.\n *\n * A **markdown space** is the concrete character U+0020 SPACE (SP) and the\n * virtual characters M-0001 VIRTUAL SPACE (VS) and M-0002 HORIZONTAL TAB (HT).\n *\n * In micromark, the actual character U+0009 CHARACTER TABULATION (HT) is\n * replaced by one M-0002 HORIZONTAL TAB (HT) and between 0 and 3 M-0001 VIRTUAL\n * SPACE (VS) characters, depending on the column at which the tab occurred.\n *\n * @param {Code} code\n * Code.\n * @returns {boolean}\n * Whether it matches.\n */\nexport function markdownSpace(code) {\n return code === -2 || code === -1 || code === 32;\n}\n\n// Size note: removing ASCII from the regex and using `asciiPunctuation` here\n// In fact adds to the bundle size.\n/**\n * Check whether the character code represents Unicode punctuation.\n *\n * A **Unicode punctuation** is a character in the Unicode `Pc` (Punctuation,\n * Connector), `Pd` (Punctuation, Dash), `Pe` (Punctuation, Close), `Pf`\n * (Punctuation, Final quote), `Pi` (Punctuation, Initial quote), `Po`\n * (Punctuation, Other), or `Ps` (Punctuation, Open) categories, or an ASCII\n * punctuation (see `asciiPunctuation`).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n *\n * @param code\n * Code.\n * @returns\n * Whether it matches.\n */\nexport const unicodePunctuation = regexCheck(/\\p{P}|\\p{S}/u);\n\n/**\n * Check whether the character code represents Unicode whitespace.\n *\n * Note that this does handle micromark specific markdown whitespace characters.\n * See `markdownLineEndingOrSpace` to check that.\n *\n * A **Unicode whitespace** is a character in the Unicode `Zs` (Separator,\n * Space) category, or U+0009 CHARACTER TABULATION (HT), U+000A LINE FEED (LF),\n * U+000C (FF), or U+000D CARRIAGE RETURN (CR) (**\\[UNICODE]**).\n *\n * See:\n * **\\[UNICODE]**:\n * [The Unicode Standard](https://www.unicode.org/versions/).\n * Unicode Consortium.\n *\n * @param code\n * Code.\n * @returns\n * Whether it matches.\n */\nexport const unicodeWhitespace = regexCheck(/\\s/);\n\n/**\n * Create a code check from a regex.\n *\n * @param {RegExp} regex\n * Expression.\n * @returns {(code: Code) => boolean}\n * Check.\n */\nfunction regexCheck(regex) {\n return check;\n\n /**\n * Check whether a code matches the bound regex.\n *\n * @param {Code} code\n * Character code.\n * @returns {boolean}\n * Whether the character code matches the bound regex.\n */\n function check(code) {\n return code !== null && code > -1 && regex.test(String.fromCharCode(code));\n }\n}"],"names":[],"mappings":"AAAA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,UAAU,GAAG,UAAU,CAAC,UAAU;;AAE/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,iBAAiB,GAAG,UAAU,CAAC,YAAY;;AAExD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,UAAU,GAAG,UAAU,CAAC,qBAAqB;;AAE1D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,YAAY,CAAC,IAAI,EAAE;AACnC,EAAE;AACF;AACA;AACA,IAAI,IAAI,KAAK,IAAI,KAAK,IAAI,GAAG,EAAE,IAAI,IAAI,KAAK,GAAG;AAC/C;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,UAAU,GAAG,UAAU,CAAC,IAAI;;AAEzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,aAAa,GAAG,UAAU,CAAC,YAAY;;AAEpD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,gBAAgB,GAAG,UAAU,CAAC,gBAAgB;;AAE3D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,kBAAkB,CAAC,IAAI,EAAE;AACzC,EAAE,OAAO,IAAI,KAAK,IAAI,IAAI,IAAI,GAAG,EAAE;AACnC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,yBAAyB,CAAC,IAAI,EAAE;AAChD,EAAE,OAAO,IAAI,KAAK,IAAI,KAAK,IAAI,GAAG,CAAC,IAAI,IAAI,KAAK,EAAE,CAAC;AACnD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,aAAa,CAAC,IAAI,EAAE;AACpC,EAAE,OAAO,IAAI,KAAK,EAAE,IAAI,IAAI,KAAK,EAAE,IAAI,IAAI,KAAK,EAAE;AAClD;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,kBAAkB,GAAG,UAAU,CAAC,cAAc;;AAE3D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACY,MAAC,iBAAiB,GAAG,UAAU,CAAC,IAAI;;AAEhD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,UAAU,CAAC,KAAK,EAAE;AAC3B,EAAE,OAAO,KAAK;;AAEd;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,SAAS,KAAK,CAAC,IAAI,EAAE;AACvB,IAAI,OAAO,IAAI,KAAK,IAAI,IAAI,IAAI,GAAG,EAAE,IAAI,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;AAC9E;AACA;;;;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,84 @@
|
|
1
|
+
/**
|
2
|
+
* Like `Array#splice`, but smarter for giant arrays.
|
3
|
+
*
|
4
|
+
* `Array#splice` takes all items to be inserted as individual argument which
|
5
|
+
* causes a stack overflow in V8 when trying to insert 100k items for instance.
|
6
|
+
*
|
7
|
+
* Otherwise, this does not return the removed items, and takes `items` as an
|
8
|
+
* array instead of rest parameters.
|
9
|
+
*
|
10
|
+
* @template {unknown} T
|
11
|
+
* Item type.
|
12
|
+
* @param {Array<T>} list
|
13
|
+
* List to operate on.
|
14
|
+
* @param {number} start
|
15
|
+
* Index to remove/insert at (can be negative).
|
16
|
+
* @param {number} remove
|
17
|
+
* Number of items to remove.
|
18
|
+
* @param {Array<T>} items
|
19
|
+
* Items to inject into `list`.
|
20
|
+
* @returns {undefined}
|
21
|
+
* Nothing.
|
22
|
+
*/
|
23
|
+
function splice(list, start, remove, items) {
|
24
|
+
const end = list.length;
|
25
|
+
let chunkStart = 0;
|
26
|
+
/** @type {Array<unknown>} */
|
27
|
+
let parameters;
|
28
|
+
|
29
|
+
// Make start between zero and `end` (included).
|
30
|
+
if (start < 0) {
|
31
|
+
start = -start > end ? 0 : end + start;
|
32
|
+
} else {
|
33
|
+
start = start > end ? end : start;
|
34
|
+
}
|
35
|
+
remove = remove > 0 ? remove : 0;
|
36
|
+
|
37
|
+
// No need to chunk the items if there’s only a couple (10k) items.
|
38
|
+
if (items.length < 10000) {
|
39
|
+
parameters = Array.from(items);
|
40
|
+
parameters.unshift(start, remove);
|
41
|
+
// @ts-expect-error Hush, it’s fine.
|
42
|
+
list.splice(...parameters);
|
43
|
+
} else {
|
44
|
+
// Delete `remove` items starting from `start`
|
45
|
+
if (remove) list.splice(start, remove);
|
46
|
+
|
47
|
+
// Insert the items in chunks to not cause stack overflows.
|
48
|
+
while (chunkStart < items.length) {
|
49
|
+
parameters = items.slice(chunkStart, chunkStart + 10000);
|
50
|
+
parameters.unshift(start, 0);
|
51
|
+
// @ts-expect-error Hush, it’s fine.
|
52
|
+
list.splice(...parameters);
|
53
|
+
chunkStart += 10000;
|
54
|
+
start += 10000;
|
55
|
+
}
|
56
|
+
}
|
57
|
+
}
|
58
|
+
|
59
|
+
/**
|
60
|
+
* Append `items` (an array) at the end of `list` (another array).
|
61
|
+
* When `list` was empty, returns `items` instead.
|
62
|
+
*
|
63
|
+
* This prevents a potentially expensive operation when `list` is empty,
|
64
|
+
* and adds items in batches to prevent V8 from hanging.
|
65
|
+
*
|
66
|
+
* @template {unknown} T
|
67
|
+
* Item type.
|
68
|
+
* @param {Array<T>} list
|
69
|
+
* List to operate on.
|
70
|
+
* @param {Array<T>} items
|
71
|
+
* Items to add to `list`.
|
72
|
+
* @returns {Array<T>}
|
73
|
+
* Either `list` or `items`.
|
74
|
+
*/
|
75
|
+
function push(list, items) {
|
76
|
+
if (list.length > 0) {
|
77
|
+
splice(list, list.length, 0, items);
|
78
|
+
return list;
|
79
|
+
}
|
80
|
+
return items;
|
81
|
+
}
|
82
|
+
|
83
|
+
export { push, splice };
|
84
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../node_modules/micromark-util-chunked/index.js"],"sourcesContent":["/**\n * Like `Array#splice`, but smarter for giant arrays.\n *\n * `Array#splice` takes all items to be inserted as individual argument which\n * causes a stack overflow in V8 when trying to insert 100k items for instance.\n *\n * Otherwise, this does not return the removed items, and takes `items` as an\n * array instead of rest parameters.\n *\n * @template {unknown} T\n * Item type.\n * @param {Array<T>} list\n * List to operate on.\n * @param {number} start\n * Index to remove/insert at (can be negative).\n * @param {number} remove\n * Number of items to remove.\n * @param {Array<T>} items\n * Items to inject into `list`.\n * @returns {undefined}\n * Nothing.\n */\nexport function splice(list, start, remove, items) {\n const end = list.length;\n let chunkStart = 0;\n /** @type {Array<unknown>} */\n let parameters;\n\n // Make start between zero and `end` (included).\n if (start < 0) {\n start = -start > end ? 0 : end + start;\n } else {\n start = start > end ? end : start;\n }\n remove = remove > 0 ? remove : 0;\n\n // No need to chunk the items if there’s only a couple (10k) items.\n if (items.length < 10000) {\n parameters = Array.from(items);\n parameters.unshift(start, remove);\n // @ts-expect-error Hush, it’s fine.\n list.splice(...parameters);\n } else {\n // Delete `remove` items starting from `start`\n if (remove) list.splice(start, remove);\n\n // Insert the items in chunks to not cause stack overflows.\n while (chunkStart < items.length) {\n parameters = items.slice(chunkStart, chunkStart + 10000);\n parameters.unshift(start, 0);\n // @ts-expect-error Hush, it’s fine.\n list.splice(...parameters);\n chunkStart += 10000;\n start += 10000;\n }\n }\n}\n\n/**\n * Append `items` (an array) at the end of `list` (another array).\n * When `list` was empty, returns `items` instead.\n *\n * This prevents a potentially expensive operation when `list` is empty,\n * and adds items in batches to prevent V8 from hanging.\n *\n * @template {unknown} T\n * Item type.\n * @param {Array<T>} list\n * List to operate on.\n * @param {Array<T>} items\n * Items to add to `list`.\n * @returns {Array<T>}\n * Either `list` or `items`.\n */\nexport function push(list, items) {\n if (list.length > 0) {\n splice(list, list.length, 0, items);\n return list;\n }\n return items;\n}"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,MAAM,CAAC,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE;AACnD,EAAE,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM;AACzB,EAAE,IAAI,UAAU,GAAG,CAAC;AACpB;AACA,EAAE,IAAI,UAAU;;AAEhB;AACA,EAAE,IAAI,KAAK,GAAG,CAAC,EAAE;AACjB,IAAI,KAAK,GAAG,CAAC,KAAK,GAAG,GAAG,GAAG,CAAC,GAAG,GAAG,GAAG,KAAK;AAC1C,GAAG,MAAM;AACT,IAAI,KAAK,GAAG,KAAK,GAAG,GAAG,GAAG,GAAG,GAAG,KAAK;AACrC;AACA,EAAE,MAAM,GAAG,MAAM,GAAG,CAAC,GAAG,MAAM,GAAG,CAAC;;AAElC;AACA,EAAE,IAAI,KAAK,CAAC,MAAM,GAAG,KAAK,EAAE;AAC5B,IAAI,UAAU,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC;AAClC,IAAI,UAAU,CAAC,OAAO,CAAC,KAAK,EAAE,MAAM,CAAC;AACrC;AACA,IAAI,IAAI,CAAC,MAAM,CAAC,GAAG,UAAU,CAAC;AAC9B,GAAG,MAAM;AACT;AACA,IAAI,IAAI,MAAM,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,CAAC;;AAE1C;AACA,IAAI,OAAO,UAAU,GAAG,KAAK,CAAC,MAAM,EAAE;AACtC,MAAM,UAAU,GAAG,KAAK,CAAC,KAAK,CAAC,UAAU,EAAE,UAAU,GAAG,KAAK,CAAC;AAC9D,MAAM,UAAU,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC;AAClC;AACA,MAAM,IAAI,CAAC,MAAM,CAAC,GAAG,UAAU,CAAC;AAChC,MAAM,UAAU,IAAI,KAAK;AACzB,MAAM,KAAK,IAAI,KAAK;AACpB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE;AAClC,EAAE,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC,EAAE;AACvB,IAAI,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE,CAAC,EAAE,KAAK,CAAC;AACvC,IAAI,OAAO,IAAI;AACf;AACA,EAAE,OAAO,KAAK;AACd;;;;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import { markdownLineEndingOrSpace, unicodeWhitespace, unicodePunctuation } from '../micromark-util-character/index.js';
|
2
|
+
|
3
|
+
/**
|
4
|
+
* @import {Code} from 'micromark-util-types'
|
5
|
+
*/
|
6
|
+
|
7
|
+
/**
|
8
|
+
* Classify whether a code represents whitespace, punctuation, or something
|
9
|
+
* else.
|
10
|
+
*
|
11
|
+
* Used for attention (emphasis, strong), whose sequences can open or close
|
12
|
+
* based on the class of surrounding characters.
|
13
|
+
*
|
14
|
+
* > 👉 **Note**: eof (`null`) is seen as whitespace.
|
15
|
+
*
|
16
|
+
* @param {Code} code
|
17
|
+
* Code.
|
18
|
+
* @returns {typeof constants.characterGroupWhitespace | typeof constants.characterGroupPunctuation | undefined}
|
19
|
+
* Group.
|
20
|
+
*/
|
21
|
+
function classifyCharacter(code) {
|
22
|
+
if (code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code)) {
|
23
|
+
return 1;
|
24
|
+
}
|
25
|
+
if (unicodePunctuation(code)) {
|
26
|
+
return 2;
|
27
|
+
}
|
28
|
+
}
|
29
|
+
|
30
|
+
export { classifyCharacter };
|
31
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../node_modules/micromark-util-classify-character/index.js"],"sourcesContent":["/**\n * @import {Code} from 'micromark-util-types'\n */\n\nimport { markdownLineEndingOrSpace, unicodePunctuation, unicodeWhitespace } from 'micromark-util-character';\n/**\n * Classify whether a code represents whitespace, punctuation, or something\n * else.\n *\n * Used for attention (emphasis, strong), whose sequences can open or close\n * based on the class of surrounding characters.\n *\n * > 👉 **Note**: eof (`null`) is seen as whitespace.\n *\n * @param {Code} code\n * Code.\n * @returns {typeof constants.characterGroupWhitespace | typeof constants.characterGroupPunctuation | undefined}\n * Group.\n */\nexport function classifyCharacter(code) {\n if (code === null || markdownLineEndingOrSpace(code) || unicodeWhitespace(code)) {\n return 1;\n }\n if (unicodePunctuation(code)) {\n return 2;\n }\n}"],"names":[],"mappings":";;AAAA;AACA;AACA;;AAGA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAAS,iBAAiB,CAAC,IAAI,EAAE;AACxC,EAAE,IAAI,IAAI,KAAK,IAAI,IAAI,yBAAyB,CAAC,IAAI,CAAC,IAAI,iBAAiB,CAAC,IAAI,CAAC,EAAE;AACnF,IAAI,OAAO,CAAC;AACZ;AACA,EAAE,IAAI,kBAAkB,CAAC,IAAI,CAAC,EAAE;AAChC,IAAI,OAAO,CAAC;AACZ;AACA;;;;","x_google_ignoreList":[0]}
|