@bgx4k3p/huly-mcp-server 2.2.3 → 2.2.5
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/README.md +186 -56
- package/node_modules/@hcengineering/account-client/lib/__tests__/utils.test.js +249 -0
- package/node_modules/@hcengineering/account-client/lib/__tests__/utils.test.js.map +7 -0
- package/node_modules/@hcengineering/account-client/lib/client.js +88 -3
- package/node_modules/@hcengineering/account-client/lib/client.js.map +2 -2
- package/node_modules/@hcengineering/account-client/lib/types.js.map +2 -2
- package/node_modules/@hcengineering/account-client/lib/utils.js +50 -0
- package/node_modules/@hcengineering/account-client/lib/utils.js.map +2 -2
- package/node_modules/@hcengineering/account-client/package.json +22 -19
- package/node_modules/@hcengineering/account-client/src/__tests__/utils.test.ts +304 -0
- package/node_modules/@hcengineering/account-client/src/client.ts +127 -6
- package/node_modules/@hcengineering/account-client/src/types.ts +7 -0
- package/node_modules/@hcengineering/account-client/src/utils.ts +65 -1
- package/node_modules/@hcengineering/analytics/lib/index.js +1 -1
- package/node_modules/@hcengineering/analytics/lib/index.js.map +2 -2
- package/node_modules/@hcengineering/analytics/package.json +19 -16
- package/node_modules/@hcengineering/analytics/src/index.ts +2 -1
- package/node_modules/@hcengineering/api-client/lib/client.js +9 -4
- package/node_modules/@hcengineering/api-client/lib/client.js.map +2 -2
- package/node_modules/@hcengineering/api-client/lib/rest/adapter.js +64 -0
- package/node_modules/@hcengineering/api-client/lib/rest/adapter.js.map +7 -0
- package/node_modules/@hcengineering/api-client/lib/rest/index.js +2 -0
- package/node_modules/@hcengineering/api-client/lib/rest/index.js.map +2 -2
- package/node_modules/@hcengineering/api-client/lib/socket/node.js +5 -1
- package/node_modules/@hcengineering/api-client/lib/socket/node.js.map +2 -2
- package/node_modules/@hcengineering/api-client/package.json +28 -25
- package/node_modules/@hcengineering/api-client/src/client.ts +10 -1
- package/node_modules/@hcengineering/api-client/src/rest/adapter.ts +96 -0
- package/node_modules/@hcengineering/api-client/src/rest/index.ts +1 -0
- package/node_modules/@hcengineering/api-client/src/socket/node.ts +6 -1
- package/node_modules/@hcengineering/chunter/lib/index.js.map +2 -2
- package/node_modules/@hcengineering/chunter/package.json +13 -10
- package/node_modules/@hcengineering/client/package.json +21 -18
- package/node_modules/@hcengineering/client-resources/package.json +24 -21
- package/node_modules/@hcengineering/collaborator-client/package.json +21 -18
- package/node_modules/@hcengineering/contact/lib/__tests__/workspaceMemberStatusUtils.test.js +38 -0
- package/node_modules/@hcengineering/contact/lib/__tests__/workspaceMemberStatusUtils.test.js.map +7 -0
- package/node_modules/@hcengineering/contact/lib/index.js +13 -4
- package/node_modules/@hcengineering/contact/lib/index.js.map +2 -2
- package/node_modules/@hcengineering/contact/lib/types.js.map +1 -1
- package/node_modules/@hcengineering/contact/lib/utils.js +132 -108
- package/node_modules/@hcengineering/contact/lib/utils.js.map +3 -3
- package/node_modules/@hcengineering/contact/lib/workspaceMemberStatusUtils.js +79 -0
- package/node_modules/@hcengineering/contact/lib/workspaceMemberStatusUtils.js.map +7 -0
- package/node_modules/@hcengineering/contact/package.json +12 -9
- package/node_modules/@hcengineering/core/CHANGELOG.md +9 -1
- package/node_modules/@hcengineering/core/lang/cs.json +6 -1
- package/node_modules/@hcengineering/core/lang/de.json +6 -1
- package/node_modules/@hcengineering/core/lang/en.json +6 -1
- package/node_modules/@hcengineering/core/lang/es.json +6 -1
- package/node_modules/@hcengineering/core/lang/fr.json +6 -1
- package/node_modules/@hcengineering/core/lang/it.json +6 -1
- package/node_modules/@hcengineering/core/lang/ja.json +6 -1
- package/node_modules/@hcengineering/core/lang/pt-br.json +70 -0
- package/node_modules/@hcengineering/core/lang/pt.json +6 -1
- package/node_modules/@hcengineering/core/lang/ru.json +6 -1
- package/node_modules/@hcengineering/core/lang/tr.json +6 -1
- package/node_modules/@hcengineering/core/lang/zh.json +6 -1
- package/node_modules/@hcengineering/core/lib/__tests__/autoJoinRoles.test.js +13 -0
- package/node_modules/@hcengineering/core/lib/__tests__/autoJoinRoles.test.js.map +7 -0
- package/node_modules/@hcengineering/core/lib/__tests__/memdb.test.js +133 -0
- package/node_modules/@hcengineering/core/lib/__tests__/memdb.test.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/__tests__/minmodel.js +25 -0
- package/node_modules/@hcengineering/core/lib/__tests__/minmodel.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/__tests__/query.test.js +43 -0
- package/node_modules/@hcengineering/core/lib/__tests__/query.test.js.map +7 -0
- package/node_modules/@hcengineering/core/lib/autoJoinRoles.js +36 -0
- package/node_modules/@hcengineering/core/lib/autoJoinRoles.js.map +7 -0
- package/node_modules/@hcengineering/core/lib/classes.js +5 -0
- package/node_modules/@hcengineering/core/lib/classes.js.map +3 -3
- package/node_modules/@hcengineering/core/lib/clone.js +13 -2
- package/node_modules/@hcengineering/core/lib/clone.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/component.js +14 -3
- package/node_modules/@hcengineering/core/lib/component.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/index.js +2 -0
- package/node_modules/@hcengineering/core/lib/index.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/memdb.js +6 -2
- package/node_modules/@hcengineering/core/lib/memdb.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/operations.js +11 -0
- package/node_modules/@hcengineering/core/lib/operations.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/predicate.js +3 -0
- package/node_modules/@hcengineering/core/lib/predicate.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/storage.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/tx.js +3 -1
- package/node_modules/@hcengineering/core/lib/tx.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/utils.js +1 -1
- package/node_modules/@hcengineering/core/lib/utils.js.map +2 -2
- package/node_modules/@hcengineering/core/lib/versioning.js +17 -0
- package/node_modules/@hcengineering/core/lib/versioning.js.map +7 -0
- package/node_modules/@hcengineering/core/package.json +22 -19
- package/node_modules/@hcengineering/core/src/__tests__/autoJoinRoles.test.ts +27 -0
- package/node_modules/@hcengineering/core/src/__tests__/memdb.test.ts +150 -1
- package/node_modules/@hcengineering/core/src/__tests__/minmodel.ts +29 -1
- package/node_modules/@hcengineering/core/src/__tests__/query.test.ts +66 -0
- package/node_modules/@hcengineering/core/src/autoJoinRoles.ts +33 -0
- package/node_modules/@hcengineering/core/src/classes.ts +61 -1
- package/node_modules/@hcengineering/core/src/clone.ts +13 -2
- package/node_modules/@hcengineering/core/src/component.ts +25 -9
- package/node_modules/@hcengineering/core/src/index.ts +2 -0
- package/node_modules/@hcengineering/core/src/memdb.ts +7 -3
- package/node_modules/@hcengineering/core/src/operations.ts +11 -0
- package/node_modules/@hcengineering/core/src/predicate.ts +3 -0
- package/node_modules/@hcengineering/core/src/storage.ts +6 -3
- package/node_modules/@hcengineering/core/src/tx.ts +4 -1
- package/node_modules/@hcengineering/core/src/utils.ts +1 -1
- package/node_modules/@hcengineering/core/src/versioning.ts +13 -0
- package/node_modules/@hcengineering/measurements/lib/__tests__/performance.test.js +3 -3
- package/node_modules/@hcengineering/measurements/lib/__tests__/performance.test.js.map +2 -2
- package/node_modules/@hcengineering/measurements/package.json +17 -14
- package/node_modules/@hcengineering/measurements/src/__tests__/performance.test.ts +3 -3
- package/node_modules/@hcengineering/platform/lang/pt-br.json +31 -0
- package/node_modules/@hcengineering/platform/lib/__tests__/i18n.test.js +100 -0
- package/node_modules/@hcengineering/platform/lib/__tests__/i18n.test.js.map +2 -2
- package/node_modules/@hcengineering/platform/lib/__tests__/status.test.js +78 -0
- package/node_modules/@hcengineering/platform/lib/__tests__/status.test.js.map +7 -0
- package/node_modules/@hcengineering/platform/lib/i18n.js +78 -69
- package/node_modules/@hcengineering/platform/lib/i18n.js.map +3 -3
- package/node_modules/@hcengineering/platform/lib/status.js +25 -0
- package/node_modules/@hcengineering/platform/lib/status.js.map +2 -2
- package/node_modules/@hcengineering/platform/package.json +18 -15
- package/node_modules/@hcengineering/platform/src/__tests__/i18n.test.ts +114 -2
- package/node_modules/@hcengineering/platform/src/__tests__/status.test.ts +77 -0
- package/node_modules/@hcengineering/platform/src/i18n.ts +99 -71
- package/node_modules/@hcengineering/platform/src/status.ts +30 -0
- package/node_modules/@hcengineering/rank/package.json +19 -16
- package/node_modules/@hcengineering/rpc/package.json +21 -18
- package/node_modules/@hcengineering/tags/package.json +12 -9
- package/node_modules/@hcengineering/task/package.json +14 -11
- package/node_modules/@hcengineering/text/lib/markup/__tests__/utils.test.js +25 -0
- package/node_modules/@hcengineering/text/lib/markup/__tests__/utils.test.js.map +2 -2
- package/node_modules/@hcengineering/text/lib/tiptapExtensions.js +6 -0
- package/node_modules/@hcengineering/text/lib/tiptapExtensions.js.map +2 -2
- package/node_modules/@hcengineering/text/package.json +23 -18
- package/node_modules/@hcengineering/text/src/markup/__tests__/utils.test.ts +27 -0
- package/node_modules/@hcengineering/text/src/tiptapExtensions.ts +3 -0
- package/node_modules/@hcengineering/text-core/lib/markup/model.js +1 -0
- package/node_modules/@hcengineering/text-core/lib/markup/model.js.map +2 -2
- package/node_modules/@hcengineering/text-core/package.json +20 -17
- package/node_modules/@hcengineering/text-core/src/markup/model.ts +2 -1
- package/node_modules/@hcengineering/text-html/package.json +19 -16
- package/node_modules/@hcengineering/text-markdown/lib/serializer.js +14 -0
- package/node_modules/@hcengineering/text-markdown/lib/serializer.js.map +2 -2
- package/node_modules/@hcengineering/text-markdown/package.json +20 -17
- package/node_modules/@hcengineering/text-markdown/src/serializer.ts +14 -0
- package/node_modules/@hcengineering/tracker/lib/index.js +1 -0
- package/node_modules/@hcengineering/tracker/lib/index.js.map +2 -2
- package/node_modules/@hcengineering/tracker/package.json +16 -13
- package/node_modules/@tiptap/core/dist/commands/focus.d.ts.map +1 -1
- package/node_modules/@tiptap/core/dist/index.cjs +19 -2
- package/node_modules/@tiptap/core/dist/index.cjs.map +1 -1
- package/node_modules/@tiptap/core/dist/index.js +19 -3
- package/node_modules/@tiptap/core/dist/index.js.map +1 -1
- package/node_modules/@tiptap/core/dist/index.umd.js +19 -2
- package/node_modules/@tiptap/core/dist/index.umd.js.map +1 -1
- package/node_modules/@tiptap/core/dist/utilities/index.d.ts +1 -0
- package/node_modules/@tiptap/core/dist/utilities/index.d.ts.map +1 -1
- package/node_modules/@tiptap/core/dist/utilities/isSafari.d.ts +10 -0
- package/node_modules/@tiptap/core/dist/utilities/isSafari.d.ts.map +1 -0
- package/node_modules/@tiptap/core/package.json +2 -2
- package/node_modules/@tiptap/core/src/commands/focus.ts +7 -2
- package/node_modules/@tiptap/core/src/utilities/index.ts +1 -0
- package/node_modules/@tiptap/core/src/utilities/isSafari.ts +11 -0
- package/node_modules/@tiptap/extension-blockquote/package.json +2 -2
- package/node_modules/@tiptap/extension-bold/package.json +2 -2
- package/node_modules/@tiptap/extension-bullet-list/package.json +2 -2
- package/node_modules/@tiptap/extension-code/package.json +2 -2
- package/node_modules/@tiptap/extension-code-block/package.json +3 -3
- package/node_modules/@tiptap/extension-document/package.json +2 -2
- package/node_modules/@tiptap/extension-dropcursor/package.json +3 -3
- package/node_modules/@tiptap/extension-gapcursor/package.json +3 -3
- package/node_modules/@tiptap/extension-hard-break/package.json +2 -2
- package/node_modules/@tiptap/extension-heading/package.json +2 -2
- package/node_modules/@tiptap/extension-highlight/package.json +2 -2
- package/node_modules/@tiptap/extension-history/package.json +3 -3
- package/node_modules/@tiptap/extension-horizontal-rule/package.json +3 -3
- package/node_modules/@tiptap/extension-italic/package.json +2 -2
- package/node_modules/@tiptap/extension-link/package.json +3 -3
- package/node_modules/@tiptap/extension-list-item/package.json +2 -2
- package/node_modules/@tiptap/extension-mention/package.json +4 -4
- package/node_modules/@tiptap/extension-ordered-list/package.json +2 -2
- package/node_modules/@tiptap/extension-paragraph/package.json +2 -2
- package/node_modules/@tiptap/extension-strike/package.json +2 -2
- package/node_modules/@tiptap/extension-subscript/README.md +14 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.cjs +61 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.cjs.map +1 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.d.ts +4 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.d.ts.map +1 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.js +56 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.js.map +1 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.umd.js +65 -0
- package/node_modules/@tiptap/extension-subscript/dist/index.umd.js.map +1 -0
- package/node_modules/@tiptap/extension-subscript/dist/subscript.d.ts +36 -0
- package/node_modules/@tiptap/extension-subscript/dist/subscript.d.ts.map +1 -0
- package/node_modules/@tiptap/extension-subscript/package.json +49 -0
- package/node_modules/@tiptap/extension-subscript/src/index.ts +5 -0
- package/node_modules/@tiptap/extension-subscript/src/subscript.ts +91 -0
- package/node_modules/@tiptap/extension-superscript/README.md +14 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.cjs +61 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.cjs.map +1 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.d.ts +4 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.d.ts.map +1 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.js +56 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.js.map +1 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.umd.js +65 -0
- package/node_modules/@tiptap/extension-superscript/dist/index.umd.js.map +1 -0
- package/node_modules/@tiptap/extension-superscript/dist/superscript.d.ts +36 -0
- package/node_modules/@tiptap/extension-superscript/dist/superscript.d.ts.map +1 -0
- package/node_modules/@tiptap/extension-superscript/package.json +49 -0
- package/node_modules/@tiptap/extension-superscript/src/index.ts +5 -0
- package/node_modules/@tiptap/extension-superscript/src/superscript.ts +91 -0
- package/node_modules/@tiptap/extension-table/package.json +3 -3
- package/node_modules/@tiptap/extension-table-cell/package.json +2 -2
- package/node_modules/@tiptap/extension-table-header/package.json +2 -2
- package/node_modules/@tiptap/extension-table-row/package.json +2 -2
- package/node_modules/@tiptap/extension-task-item/package.json +3 -3
- package/node_modules/@tiptap/extension-task-list/package.json +2 -2
- package/node_modules/@tiptap/extension-text/package.json +2 -2
- package/node_modules/@tiptap/extension-typography/package.json +2 -2
- package/node_modules/@tiptap/extension-underline/package.json +2 -2
- package/node_modules/@tiptap/html/package.json +3 -3
- package/node_modules/@tiptap/pm/package.json +1 -1
- package/node_modules/@tiptap/starter-kit/node_modules/@tiptap/extension-text-style/package.json +2 -2
- package/node_modules/@tiptap/starter-kit/package.json +22 -22
- package/node_modules/@tiptap/suggestion/package.json +3 -3
- package/node_modules/linkify-it/build/index.cjs.js +99 -94
- package/node_modules/linkify-it/index.mjs +99 -94
- package/node_modules/linkify-it/package.json +11 -1
- package/node_modules/linkifyjs/README.md +4 -2
- package/node_modules/linkifyjs/dist/linkify.cjs +8 -11
- package/node_modules/linkifyjs/dist/linkify.d.cts +14 -14
- package/node_modules/linkifyjs/dist/linkify.d.mts +14 -14
- package/node_modules/linkifyjs/dist/linkify.js +8 -11
- package/node_modules/linkifyjs/dist/linkify.min.js +1 -1
- package/node_modules/linkifyjs/dist/linkify.mjs +8 -11
- package/node_modules/linkifyjs/package.json +1 -1
- package/node_modules/markdown-it/README.md +13 -17
- package/node_modules/markdown-it/dist/index.cjs.js +111 -31
- package/node_modules/markdown-it/dist/markdown-it.js +117 -31
- package/node_modules/markdown-it/dist/markdown-it.min.js +2 -2
- package/node_modules/markdown-it/lib/common/utils.mjs +30 -1
- package/node_modules/markdown-it/lib/index.mjs +1 -1
- package/node_modules/markdown-it/lib/rules_block/heading.mjs +2 -2
- package/node_modules/markdown-it/lib/rules_block/html_block.mjs +12 -1
- package/node_modules/markdown-it/lib/rules_block/lheading.mjs +4 -1
- package/node_modules/markdown-it/lib/rules_block/paragraph.mjs +3 -1
- package/node_modules/markdown-it/lib/rules_core/smartquotes.mjs +37 -21
- package/node_modules/markdown-it/lib/rules_inline/entity.mjs +2 -2
- package/node_modules/markdown-it/lib/rules_inline/state_inline.mjs +37 -6
- package/node_modules/markdown-it/package.json +14 -3
- package/node_modules/msgpackr/README.md +1 -3
- package/node_modules/msgpackr/benchmark.md +26 -16
- package/node_modules/msgpackr/dist/index-no-eval.cjs +35 -16
- package/node_modules/msgpackr/dist/index-no-eval.cjs.map +1 -1
- package/node_modules/msgpackr/dist/index-no-eval.min.js +1 -1
- package/node_modules/msgpackr/dist/index-no-eval.min.js.map +1 -1
- package/node_modules/msgpackr/dist/index.js +35 -16
- package/node_modules/msgpackr/dist/index.js.map +1 -1
- package/node_modules/msgpackr/dist/index.min.js +1 -1
- package/node_modules/msgpackr/dist/index.min.js.map +1 -1
- package/node_modules/msgpackr/dist/node.cjs +50 -26
- package/node_modules/msgpackr/dist/node.cjs.map +1 -1
- package/node_modules/msgpackr/dist/test.js +44 -16
- package/node_modules/msgpackr/dist/test.js.map +1 -1
- package/node_modules/msgpackr/dist/unpack-no-eval.cjs +35 -16
- package/node_modules/msgpackr/dist/unpack-no-eval.cjs.map +1 -1
- package/node_modules/msgpackr/index.d.cts +2 -0
- package/node_modules/msgpackr/index.d.ts +2 -0
- package/node_modules/msgpackr/package.json +1 -1
- package/node_modules/msgpackr/stream.js +15 -10
- package/node_modules/msgpackr/unpack.js +35 -16
- package/node_modules/prosemirror-changeset/CHANGELOG.md +12 -0
- package/node_modules/prosemirror-changeset/README.md +31 -2
- package/node_modules/prosemirror-changeset/dist/index.cjs +17 -2
- package/node_modules/prosemirror-changeset/dist/index.d.cts +32 -2
- package/node_modules/prosemirror-changeset/dist/index.d.ts +32 -2
- package/node_modules/prosemirror-changeset/dist/index.js +18 -3
- package/node_modules/prosemirror-changeset/package.json +2 -2
- package/node_modules/prosemirror-changeset/src/README.md +4 -2
- package/node_modules/prosemirror-changeset/src/change.ts +18 -0
- package/node_modules/prosemirror-changeset/src/changeset.ts +10 -4
- package/node_modules/prosemirror-changeset/src/simplify.ts +1 -1
- package/node_modules/prosemirror-changeset/test/test-simplify.ts +3 -0
- package/node_modules/prosemirror-gapcursor/CHANGELOG.md +6 -0
- package/node_modules/prosemirror-gapcursor/dist/index.cjs +1 -1
- package/node_modules/prosemirror-gapcursor/dist/index.js +1 -1
- package/node_modules/prosemirror-gapcursor/package.json +3 -2
- package/node_modules/prosemirror-gapcursor/src/gapcursor.ts +1 -1
- package/node_modules/prosemirror-markdown/CHANGELOG.md +12 -0
- package/node_modules/prosemirror-markdown/dist/index.cjs +11 -1
- package/node_modules/prosemirror-markdown/dist/index.js +14 -2
- package/node_modules/prosemirror-markdown/package.json +1 -1
- package/node_modules/prosemirror-markdown/src/to_markdown.ts +12 -3
- package/node_modules/prosemirror-menu/CHANGELOG.md +18 -0
- package/node_modules/prosemirror-menu/CONTRIBUTING.md +22 -18
- package/node_modules/prosemirror-menu/README.md +69 -29
- package/node_modules/prosemirror-menu/dist/index.cjs +232 -48
- package/node_modules/prosemirror-menu/dist/index.d.cts +29 -14
- package/node_modules/prosemirror-menu/dist/index.d.ts +29 -14
- package/node_modules/prosemirror-menu/dist/index.js +229 -36
- package/node_modules/prosemirror-menu/package.json +2 -2
- package/node_modules/prosemirror-menu/src/README.md +30 -1
- package/node_modules/prosemirror-menu/src/icons.ts +3 -2
- package/node_modules/prosemirror-menu/src/menu.ts +193 -40
- package/node_modules/prosemirror-menu/src/menubar.ts +50 -5
- package/node_modules/prosemirror-menu/style/menu.css +28 -7
- package/node_modules/prosemirror-model/CHANGELOG.md +20 -0
- package/node_modules/prosemirror-model/CONTRIBUTING.md +19 -19
- package/node_modules/prosemirror-model/README.md +3 -3
- package/node_modules/prosemirror-model/dist/index.cjs +13 -10
- package/node_modules/prosemirror-model/dist/index.d.cts +25 -21
- package/node_modules/prosemirror-model/dist/index.d.ts +25 -21
- package/node_modules/prosemirror-model/dist/index.js +19 -23
- package/node_modules/prosemirror-model/package.json +2 -2
- package/node_modules/prosemirror-model/src/fragment.ts +1 -1
- package/node_modules/prosemirror-model/src/from_dom.ts +4 -1
- package/node_modules/prosemirror-model/src/node.ts +5 -4
- package/node_modules/prosemirror-model/src/replace.ts +6 -15
- package/node_modules/prosemirror-model/src/schema.ts +1 -1
- package/node_modules/prosemirror-model/src/to_dom.ts +24 -20
- package/node_modules/prosemirror-transform/CHANGELOG.md +16 -0
- package/node_modules/prosemirror-transform/dist/index.cjs +38 -4
- package/node_modules/prosemirror-transform/dist/index.d.cts +19 -0
- package/node_modules/prosemirror-transform/dist/index.d.ts +19 -0
- package/node_modules/prosemirror-transform/dist/index.js +52 -1
- package/node_modules/prosemirror-transform/package.json +1 -1
- package/node_modules/prosemirror-transform/src/replace.ts +16 -0
- package/node_modules/prosemirror-transform/src/replace_step.ts +10 -1
- package/node_modules/prosemirror-transform/src/transform.ts +21 -2
- package/node_modules/prosemirror-view/CHANGELOG.md +34 -2
- package/node_modules/prosemirror-view/CONTRIBUTING.md +19 -19
- package/node_modules/prosemirror-view/README.md +3 -3
- package/node_modules/prosemirror-view/dist/index.cjs +96 -40
- package/node_modules/prosemirror-view/dist/index.d.cts +2 -2
- package/node_modules/prosemirror-view/dist/index.d.ts +2 -2
- package/node_modules/prosemirror-view/dist/index.js +90 -39
- package/node_modules/prosemirror-view/package.json +2 -2
- package/node_modules/prosemirror-view/src/domchange.ts +1 -1
- package/node_modules/prosemirror-view/src/domobserver.ts +59 -16
- package/node_modules/prosemirror-view/src/index.ts +4 -4
- package/node_modules/prosemirror-view/src/input.ts +9 -6
- package/node_modules/prosemirror-view/src/viewdesc.ts +26 -22
- package/node_modules/prosemirror-view/style/prosemirror.css +1 -1
- package/package.json +5 -4
- package/src/client.mjs +2 -2
- package/src/config.mjs +1 -0
- package/src/helpers.mjs +2 -2
- package/src/index.mjs +31 -1
- package/src/initCodex.mjs +281 -0
- package/src/mcp.mjs +11 -1
- package/src/mcpShared.mjs +95 -5
- package/node_modules/@hcengineering/account-client/types/client.d.ts +0 -140
- package/node_modules/@hcengineering/account-client/types/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/account-client/types/index.d.ts +0 -4
- package/node_modules/@hcengineering/account-client/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/account-client/types/types.d.ts +0 -177
- package/node_modules/@hcengineering/account-client/types/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/account-client/types/utils.d.ts +0 -5
- package/node_modules/@hcengineering/account-client/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/analytics/types/index.d.ts +0 -25
- package/node_modules/@hcengineering/analytics/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/__tests__/config.test.d.ts +0 -2
- package/node_modules/@hcengineering/api-client/types/__tests__/config.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/__tests__/markup-client.test.d.ts +0 -2
- package/node_modules/@hcengineering/api-client/types/__tests__/markup-client.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/__tests__/markup-types.test.d.ts +0 -2
- package/node_modules/@hcengineering/api-client/types/__tests__/markup-types.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/__tests__/rest-utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/api-client/types/__tests__/rest-utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/__tests__/utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/api-client/types/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/client.d.ts +0 -6
- package/node_modules/@hcengineering/api-client/types/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/config.d.ts +0 -8
- package/node_modules/@hcengineering/api-client/types/config.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/index.d.ts +0 -9
- package/node_modules/@hcengineering/api-client/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/markup/client.d.ts +0 -5
- package/node_modules/@hcengineering/api-client/types/markup/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/markup/index.d.ts +0 -3
- package/node_modules/@hcengineering/api-client/types/markup/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/markup/types.d.ts +0 -41
- package/node_modules/@hcengineering/api-client/types/markup/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/rest/index.d.ts +0 -4
- package/node_modules/@hcengineering/api-client/types/rest/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/rest/rest.d.ts +0 -39
- package/node_modules/@hcengineering/api-client/types/rest/rest.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/rest/tx.d.ts +0 -3
- package/node_modules/@hcengineering/api-client/types/rest/tx.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/rest/types.d.ts +0 -16
- package/node_modules/@hcengineering/api-client/types/rest/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/rest/utils.d.ts +0 -3
- package/node_modules/@hcengineering/api-client/types/rest/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/socket/browser.d.ts +0 -4
- package/node_modules/@hcengineering/api-client/types/socket/browser.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/socket/index.d.ts +0 -3
- package/node_modules/@hcengineering/api-client/types/socket/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/socket/node.d.ts +0 -4
- package/node_modules/@hcengineering/api-client/types/socket/node.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/storage/client.d.ts +0 -21
- package/node_modules/@hcengineering/api-client/types/storage/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/storage/error.d.ts +0 -10
- package/node_modules/@hcengineering/api-client/types/storage/error.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/storage/index.d.ts +0 -4
- package/node_modules/@hcengineering/api-client/types/storage/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/storage/types.d.ts +0 -10
- package/node_modules/@hcengineering/api-client/types/storage/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/types.d.ts +0 -101
- package/node_modules/@hcengineering/api-client/types/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/api-client/types/utils.d.ts +0 -12
- package/node_modules/@hcengineering/api-client/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/chunter/types/analytics.d.ts +0 -5
- package/node_modules/@hcengineering/chunter/types/analytics.d.ts.map +0 -1
- package/node_modules/@hcengineering/chunter/types/index.d.ts +0 -211
- package/node_modules/@hcengineering/chunter/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/chunter/types/utils.d.ts +0 -7
- package/node_modules/@hcengineering/chunter/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/client/types/__tests__/client.test.d.ts +0 -2
- package/node_modules/@hcengineering/client/types/__tests__/client.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/client/types/index.d.ts +0 -69
- package/node_modules/@hcengineering/client/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/client-resources/types/__tests__/connection.test.d.ts +0 -2
- package/node_modules/@hcengineering/client-resources/types/__tests__/connection.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/client-resources/types/__tests__/integration.test.d.ts +0 -45
- package/node_modules/@hcengineering/client-resources/types/__tests__/integration.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/client-resources/types/connection.d.ts +0 -7
- package/node_modules/@hcengineering/client-resources/types/connection.d.ts.map +0 -1
- package/node_modules/@hcengineering/client-resources/types/index.d.ts +0 -11
- package/node_modules/@hcengineering/client-resources/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/collaborator-client/types/__tests__/utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/collaborator-client/types/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/collaborator-client/types/client.d.ts +0 -34
- package/node_modules/@hcengineering/collaborator-client/types/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/collaborator-client/types/index.d.ts +0 -3
- package/node_modules/@hcengineering/collaborator-client/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/collaborator-client/types/utils.d.ts +0 -9
- package/node_modules/@hcengineering/collaborator-client/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/__tests__/cache.test.d.ts +0 -2
- package/node_modules/@hcengineering/contact/types/__tests__/cache.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/analytics.d.ts +0 -6
- package/node_modules/@hcengineering/contact/types/analytics.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/avatar.d.ts +0 -12
- package/node_modules/@hcengineering/contact/types/avatar.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/cache.d.ts +0 -49
- package/node_modules/@hcengineering/contact/types/cache.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/index.d.ts +0 -367
- package/node_modules/@hcengineering/contact/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/types.d.ts +0 -25
- package/node_modules/@hcengineering/contact/types/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/contact/types/utils.d.ts +0 -110
- package/node_modules/@hcengineering/contact/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/client.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/client.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/clone.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/clone.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/collaboration.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/collaboration.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/collaborators.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/collaborators.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/common.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/common.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/connection.d.ts +0 -4
- package/node_modules/@hcengineering/core/types/__tests__/connection.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/contexts.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/contexts.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/hierarchy.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/hierarchy.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/lang.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/lang.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/limiter-edge-cases.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/limiter-edge-cases.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/limits.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/limits.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/memdb.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/memdb.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/minmodel.d.ts +0 -50
- package/node_modules/@hcengineering/core/types/__tests__/minmodel.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/objvalue.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/objvalue.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/operator-bugs.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/operator-bugs.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/operator.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/operator.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/rate-limiter.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/rate-limiter.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/time.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/time.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/__tests__/utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/core/types/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/backup.d.ts +0 -26
- package/node_modules/@hcengineering/core/types/backup.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/benchmark.d.ts +0 -19
- package/node_modules/@hcengineering/core/types/benchmark.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/classes.d.ts +0 -716
- package/node_modules/@hcengineering/core/types/classes.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/client.d.ts +0 -69
- package/node_modules/@hcengineering/core/types/client.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/clone.d.ts +0 -3
- package/node_modules/@hcengineering/core/types/clone.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/collaboration.d.ts +0 -16
- package/node_modules/@hcengineering/core/types/collaboration.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/collaborators.d.ts +0 -3
- package/node_modules/@hcengineering/core/types/collaborators.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/common.d.ts +0 -4
- package/node_modules/@hcengineering/core/types/common.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/component.d.ts +0 -229
- package/node_modules/@hcengineering/core/types/component.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/hierarchy.d.ts +0 -84
- package/node_modules/@hcengineering/core/types/hierarchy.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/index.d.ts +0 -25
- package/node_modules/@hcengineering/core/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/memdb.d.ts +0 -60
- package/node_modules/@hcengineering/core/types/memdb.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/objvalue.d.ts +0 -10
- package/node_modules/@hcengineering/core/types/objvalue.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/operations.d.ts +0 -87
- package/node_modules/@hcengineering/core/types/operations.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/operator.d.ts +0 -16
- package/node_modules/@hcengineering/core/types/operator.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/predicate.d.ts +0 -6
- package/node_modules/@hcengineering/core/types/predicate.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/proxy.d.ts +0 -21
- package/node_modules/@hcengineering/core/types/proxy.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/query.d.ts +0 -21
- package/node_modules/@hcengineering/core/types/query.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/server.d.ts +0 -82
- package/node_modules/@hcengineering/core/types/server.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/status.d.ts +0 -30
- package/node_modules/@hcengineering/core/types/status.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/storage.d.ts +0 -233
- package/node_modules/@hcengineering/core/types/storage.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/time.d.ts +0 -8
- package/node_modules/@hcengineering/core/types/time.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/tx.d.ts +0 -261
- package/node_modules/@hcengineering/core/types/tx.d.ts.map +0 -1
- package/node_modules/@hcengineering/core/types/utils.d.ts +0 -207
- package/node_modules/@hcengineering/core/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/__tests__/context.test.d.ts +0 -2
- package/node_modules/@hcengineering/measurements/types/__tests__/context.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/__tests__/index.test.d.ts +0 -2
- package/node_modules/@hcengineering/measurements/types/__tests__/index.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/__tests__/metrics.test.d.ts +0 -2
- package/node_modules/@hcengineering/measurements/types/__tests__/metrics.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/__tests__/performance.test.d.ts +0 -2
- package/node_modules/@hcengineering/measurements/types/__tests__/performance.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/context.d.ts +0 -64
- package/node_modules/@hcengineering/measurements/types/context.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/index.d.ts +0 -12
- package/node_modules/@hcengineering/measurements/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/metrics.d.ts +0 -34
- package/node_modules/@hcengineering/measurements/types/metrics.d.ts.map +0 -1
- package/node_modules/@hcengineering/measurements/types/types.d.ts +0 -88
- package/node_modules/@hcengineering/measurements/types/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/__tests__/i18n.test.d.ts +0 -2
- package/node_modules/@hcengineering/platform/types/__tests__/i18n.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/__tests__/ident.test.d.ts +0 -2
- package/node_modules/@hcengineering/platform/types/__tests__/ident.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/__tests__/plugin.d.ts +0 -7
- package/node_modules/@hcengineering/platform/types/__tests__/plugin.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/__tests__/resource.test.d.ts +0 -2
- package/node_modules/@hcengineering/platform/types/__tests__/resource.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/event.d.ts +0 -39
- package/node_modules/@hcengineering/platform/types/event.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/i18n.d.ts +0 -28
- package/node_modules/@hcengineering/platform/types/i18n.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/ident.d.ts +0 -14
- package/node_modules/@hcengineering/platform/types/ident.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/index.d.ts +0 -19
- package/node_modules/@hcengineering/platform/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/metadata.d.ts +0 -38
- package/node_modules/@hcengineering/platform/types/metadata.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/platform.d.ts +0 -218
- package/node_modules/@hcengineering/platform/types/platform.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/resource.d.ts +0 -49
- package/node_modules/@hcengineering/platform/types/resource.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/status.d.ts +0 -60
- package/node_modules/@hcengineering/platform/types/status.d.ts.map +0 -1
- package/node_modules/@hcengineering/platform/types/testUtils.d.ts +0 -8
- package/node_modules/@hcengineering/platform/types/testUtils.d.ts.map +0 -1
- package/node_modules/@hcengineering/rank/types/__tests__/utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/rank/types/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/rank/types/index.d.ts +0 -3
- package/node_modules/@hcengineering/rank/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/rank/types/types.d.ts +0 -2
- package/node_modules/@hcengineering/rank/types/types.d.ts.map +0 -1
- package/node_modules/@hcengineering/rank/types/utils.d.ts +0 -6
- package/node_modules/@hcengineering/rank/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/rpc/types/index.d.ts +0 -3
- package/node_modules/@hcengineering/rpc/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/rpc/types/rpc.d.ts +0 -96
- package/node_modules/@hcengineering/rpc/types/rpc.d.ts.map +0 -1
- package/node_modules/@hcengineering/rpc/types/sliding.d.ts +0 -11
- package/node_modules/@hcengineering/rpc/types/sliding.d.ts.map +0 -1
- package/node_modules/@hcengineering/rpc/types/test/rateLimit.spec.d.ts +0 -2
- package/node_modules/@hcengineering/rpc/types/test/rateLimit.spec.d.ts.map +0 -1
- package/node_modules/@hcengineering/tags/types/analytics.d.ts +0 -5
- package/node_modules/@hcengineering/tags/types/analytics.d.ts.map +0 -1
- package/node_modules/@hcengineering/tags/types/index.d.ts +0 -105
- package/node_modules/@hcengineering/tags/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/task/types/index.d.ts +0 -227
- package/node_modules/@hcengineering/task/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/task/types/utils.d.ts +0 -61
- package/node_modules/@hcengineering/task/types/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/extensions.d.ts +0 -53
- package/node_modules/@hcengineering/text/types/extensions.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/index.d.ts +0 -13
- package/node_modules/@hcengineering/text/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/kit.d.ts +0 -12
- package/node_modules/@hcengineering/text/types/kit.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/kits/common-kit.d.ts +0 -72
- package/node_modules/@hcengineering/text/types/kits/common-kit.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/kits/server-kit.d.ts +0 -106
- package/node_modules/@hcengineering/text/types/kits/server-kit.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/marks/code.d.ts +0 -8
- package/node_modules/@hcengineering/text/types/marks/code.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/marks/colors.d.ts +0 -21
- package/node_modules/@hcengineering/text/types/marks/colors.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/marks/inlineComment.d.ts +0 -5
- package/node_modules/@hcengineering/text/types/marks/inlineComment.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/marks/noteBase.d.ts +0 -23
- package/node_modules/@hcengineering/text/types/marks/noteBase.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/marks/qmsInlineCommentMark.d.ts +0 -6
- package/node_modules/@hcengineering/text/types/marks/qmsInlineCommentMark.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/markup/__tests__/dsl.test.d.ts +0 -2
- package/node_modules/@hcengineering/text/types/markup/__tests__/dsl.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/markup/__tests__/utils.test.d.ts +0 -5
- package/node_modules/@hcengineering/text/types/markup/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/markup/utils.d.ts +0 -19
- package/node_modules/@hcengineering/text/types/markup/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/codeblock.d.ts +0 -12
- package/node_modules/@hcengineering/text/types/nodes/codeblock.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/comment.d.ts +0 -6
- package/node_modules/@hcengineering/text/types/nodes/comment.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/embed.d.ts +0 -3
- package/node_modules/@hcengineering/text/types/nodes/embed.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/emoji.d.ts +0 -17
- package/node_modules/@hcengineering/text/types/nodes/emoji.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/file.d.ts +0 -13
- package/node_modules/@hcengineering/text/types/nodes/file.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/image.d.ts +0 -52
- package/node_modules/@hcengineering/text/types/nodes/image.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/index.d.ts +0 -11
- package/node_modules/@hcengineering/text/types/nodes/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/markdown.d.ts +0 -3
- package/node_modules/@hcengineering/text/types/nodes/markdown.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/mermaid.d.ts +0 -4
- package/node_modules/@hcengineering/text/types/nodes/mermaid.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/reference.d.ts +0 -18
- package/node_modules/@hcengineering/text/types/nodes/reference.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/todo.d.ts +0 -3
- package/node_modules/@hcengineering/text/types/nodes/todo.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/nodes/utils.d.ts +0 -6
- package/node_modules/@hcengineering/text/types/nodes/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/text/types/tiptapExtensions.d.ts +0 -28
- package/node_modules/@hcengineering/text/types/tiptapExtensions.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/index.d.ts +0 -6
- package/node_modules/@hcengineering/text-core/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/__tests__/traverse.test.d.ts +0 -2
- package/node_modules/@hcengineering/text-core/types/markup/__tests__/traverse.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/__tests__/utils.test.d.ts +0 -2
- package/node_modules/@hcengineering/text-core/types/markup/__tests__/utils.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/dsl.d.ts +0 -25
- package/node_modules/@hcengineering/text-core/types/markup/dsl.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/model.d.ts +0 -74
- package/node_modules/@hcengineering/text-core/types/markup/model.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/reference.d.ts +0 -15
- package/node_modules/@hcengineering/text-core/types/markup/reference.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/traverse.d.ts +0 -6
- package/node_modules/@hcengineering/text-core/types/markup/traverse.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-core/types/markup/utils.d.ts +0 -25
- package/node_modules/@hcengineering/text-core/types/markup/utils.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-html/types/__tests__/html.test.d.ts +0 -2
- package/node_modules/@hcengineering/text-html/types/__tests__/html.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-html/types/index.d.ts +0 -6
- package/node_modules/@hcengineering/text-html/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-html/types/parser.d.ts +0 -10
- package/node_modules/@hcengineering/text-html/types/parser.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-html/types/serializer.d.ts +0 -9
- package/node_modules/@hcengineering/text-html/types/serializer.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/__tests__/markdown.test.d.ts +0 -9
- package/node_modules/@hcengineering/text-markdown/types/__tests__/markdown.test.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/compare.d.ts +0 -10
- package/node_modules/@hcengineering/text-markdown/types/compare.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/index.d.ts +0 -14
- package/node_modules/@hcengineering/text-markdown/types/index.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/marks.d.ts +0 -8
- package/node_modules/@hcengineering/text-markdown/types/marks.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/node.d.ts +0 -4
- package/node_modules/@hcengineering/text-markdown/types/node.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/parser.d.ts +0 -50
- package/node_modules/@hcengineering/text-markdown/types/parser.d.ts.map +0 -1
- package/node_modules/@hcengineering/text-markdown/types/serializer.d.ts +0 -102
- package/node_modules/@hcengineering/text-markdown/types/serializer.d.ts.map +0 -1
- package/node_modules/@hcengineering/tracker/types/analytics.d.ts +0 -24
- package/node_modules/@hcengineering/tracker/types/analytics.d.ts.map +0 -1
- package/node_modules/@hcengineering/tracker/types/index.d.ts +0 -431
- package/node_modules/@hcengineering/tracker/types/index.d.ts.map +0 -1
|
@@ -179,6 +179,10 @@ function isPunctChar (ch) {
|
|
|
179
179
|
return ucmicro.P.test(ch) || ucmicro.S.test(ch)
|
|
180
180
|
}
|
|
181
181
|
|
|
182
|
+
function isPunctCharCode (code) {
|
|
183
|
+
return isPunctChar(fromCodePoint(code))
|
|
184
|
+
}
|
|
185
|
+
|
|
182
186
|
// Markdown ASCII punctuation characters.
|
|
183
187
|
//
|
|
184
188
|
// !, ", #, $, %, &, ', (, ), *, +, ,, -, ., /, :, ;, <, =, >, ?, @, [, \, ], ^, _, `, {, |, }, or ~
|
|
@@ -240,6 +244,7 @@ function normalizeReference (str) {
|
|
|
240
244
|
// (remove this when node v10 is no longer supported).
|
|
241
245
|
//
|
|
242
246
|
if ('ẞ'.toLowerCase() === 'Ṿ') {
|
|
247
|
+
/* c8 ignore next 2 */
|
|
243
248
|
str = str.replace(/ẞ/g, 'ß')
|
|
244
249
|
}
|
|
245
250
|
|
|
@@ -278,6 +283,28 @@ function normalizeReference (str) {
|
|
|
278
283
|
return str.toLowerCase().toUpperCase()
|
|
279
284
|
}
|
|
280
285
|
|
|
286
|
+
function isAsciiTrimmable (c) {
|
|
287
|
+
return c === 0x20 || c === 0x09 || c === 0x0a || c === 0x0d
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
// "Light" .trim() for blocks (headers, paragraphs), where unicode spaces
|
|
291
|
+
// should be preserved.
|
|
292
|
+
function asciiTrim (str) {
|
|
293
|
+
let start = 0
|
|
294
|
+
for (; start < str.length; start++) {
|
|
295
|
+
if (!isAsciiTrimmable(str.charCodeAt(start))) {
|
|
296
|
+
break
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
let end = str.length - 1
|
|
300
|
+
for (; end >= start; end--) {
|
|
301
|
+
if (!isAsciiTrimmable(str.charCodeAt(end))) {
|
|
302
|
+
break
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
return str.slice(start, end + 1)
|
|
306
|
+
}
|
|
307
|
+
|
|
281
308
|
// Re-export libraries commonly used in both markdown-it and its plugins,
|
|
282
309
|
// so plugins won't have to depend on them explicitly, which reduces their
|
|
283
310
|
// bundled size (e.g. a browser build).
|
|
@@ -299,6 +326,8 @@ export {
|
|
|
299
326
|
isWhiteSpace,
|
|
300
327
|
isMdAsciiPunct,
|
|
301
328
|
isPunctChar,
|
|
329
|
+
isPunctCharCode,
|
|
302
330
|
escapeRE,
|
|
303
|
-
normalizeReference
|
|
331
|
+
normalizeReference,
|
|
332
|
+
asciiTrim
|
|
304
333
|
}
|
|
@@ -352,7 +352,7 @@ function MarkdownIt (presetName, options) {
|
|
|
352
352
|
* ```javascript
|
|
353
353
|
* var md = require('markdown-it')()
|
|
354
354
|
* .set({ html: true, breaks: true })
|
|
355
|
-
* .set({ typographer
|
|
355
|
+
* .set({ typographer: true });
|
|
356
356
|
* ```
|
|
357
357
|
*
|
|
358
358
|
* __Note:__ To achieve the best possible performance, don't modify a
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// heading (#, ##, ...)
|
|
2
2
|
|
|
3
|
-
import { isSpace } from '../common/utils.mjs'
|
|
3
|
+
import { isSpace, asciiTrim } from '../common/utils.mjs'
|
|
4
4
|
|
|
5
5
|
export default function heading (state, startLine, endLine, silent) {
|
|
6
6
|
let pos = state.bMarks[startLine] + state.tShift[startLine]
|
|
@@ -40,7 +40,7 @@ export default function heading (state, startLine, endLine, silent) {
|
|
|
40
40
|
token_o.map = [startLine, state.line]
|
|
41
41
|
|
|
42
42
|
const token_i = state.push('inline', '', 0)
|
|
43
|
-
token_i.content = state.src.slice(pos, max)
|
|
43
|
+
token_i.content = asciiTrim(state.src.slice(pos, max))
|
|
44
44
|
token_i.map = [startLine, state.line]
|
|
45
45
|
token_i.children = []
|
|
46
46
|
|
|
@@ -42,11 +42,22 @@ export default function html_block (state, startLine, endLine, silent) {
|
|
|
42
42
|
|
|
43
43
|
let nextLine = startLine + 1
|
|
44
44
|
|
|
45
|
+
// Block types 6 and 7 (the only ones whose end condition is a blank line)
|
|
46
|
+
// have `/^$/` as their closing regexp. For all other types (1-5, e.g.
|
|
47
|
+
// `<!--` comments), a blank line is regular content and must not terminate
|
|
48
|
+
// the block - it ends only when its closing sequence is found.
|
|
49
|
+
const endsOnBlankLine = HTML_SEQUENCES[i][1].test('')
|
|
50
|
+
|
|
45
51
|
// If we are here - we detected HTML block.
|
|
46
52
|
// Let's roll down till block end.
|
|
47
53
|
if (!HTML_SEQUENCES[i][1].test(lineText)) {
|
|
48
54
|
for (; nextLine < endLine; nextLine++) {
|
|
49
|
-
if (state.sCount[nextLine] < state.blkIndent) {
|
|
55
|
+
if (state.sCount[nextLine] < state.blkIndent) {
|
|
56
|
+
// An outdented blank line shouldn't end a block that doesn't end on a
|
|
57
|
+
// blank line (e.g. a `<!--` comment inside a list item). Such blocks
|
|
58
|
+
// must continue until their closing sequence regardless of indent.
|
|
59
|
+
if (endsOnBlankLine || !state.isEmpty(nextLine)) { break }
|
|
60
|
+
}
|
|
50
61
|
|
|
51
62
|
pos = state.bMarks[nextLine] + state.tShift[nextLine]
|
|
52
63
|
max = state.eMarks[nextLine]
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
// lheading (---, ===)
|
|
2
2
|
|
|
3
|
+
import { asciiTrim } from '../common/utils.mjs'
|
|
4
|
+
|
|
3
5
|
export default function lheading (state, startLine, endLine/*, silent */) {
|
|
4
6
|
const terminatorRules = state.md.block.ruler.getRules('paragraph')
|
|
5
7
|
|
|
@@ -57,10 +59,11 @@ export default function lheading (state, startLine, endLine/*, silent */) {
|
|
|
57
59
|
|
|
58
60
|
if (!level) {
|
|
59
61
|
// Didn't find valid underline
|
|
62
|
+
state.parentType = oldParentType
|
|
60
63
|
return false
|
|
61
64
|
}
|
|
62
65
|
|
|
63
|
-
const content = state.getLines(startLine, nextLine, state.blkIndent, false)
|
|
66
|
+
const content = asciiTrim(state.getLines(startLine, nextLine, state.blkIndent, false))
|
|
64
67
|
|
|
65
68
|
state.line = nextLine + 1
|
|
66
69
|
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
// Paragraph
|
|
2
2
|
|
|
3
|
+
import { asciiTrim } from '../common/utils.mjs'
|
|
4
|
+
|
|
3
5
|
export default function paragraph (state, startLine, endLine) {
|
|
4
6
|
const terminatorRules = state.md.block.ruler.getRules('paragraph')
|
|
5
7
|
const oldParentType = state.parentType
|
|
@@ -26,7 +28,7 @@ export default function paragraph (state, startLine, endLine) {
|
|
|
26
28
|
if (terminate) { break }
|
|
27
29
|
}
|
|
28
30
|
|
|
29
|
-
const content = state.getLines(startLine, nextLine, state.blkIndent, false)
|
|
31
|
+
const content = asciiTrim(state.getLines(startLine, nextLine, state.blkIndent, false))
|
|
30
32
|
|
|
31
33
|
state.line = nextLine
|
|
32
34
|
|
|
@@ -1,20 +1,42 @@
|
|
|
1
1
|
// Convert straight quotation marks to typographic ones
|
|
2
2
|
//
|
|
3
3
|
|
|
4
|
-
import { isWhiteSpace,
|
|
4
|
+
import { isWhiteSpace, isPunctCharCode, isMdAsciiPunct } from '../common/utils.mjs'
|
|
5
5
|
|
|
6
6
|
const QUOTE_TEST_RE = /['"]/
|
|
7
7
|
const QUOTE_RE = /['"]/g
|
|
8
8
|
const APOSTROPHE = '\u2019' /* ’ */
|
|
9
9
|
|
|
10
|
-
function
|
|
11
|
-
|
|
10
|
+
function addReplacement (replacements, tokenIdx, pos, ch) {
|
|
11
|
+
if (!replacements[tokenIdx]) {
|
|
12
|
+
replacements[tokenIdx] = []
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
replacements[tokenIdx].push({ pos, ch })
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
function applyReplacements (str, replacements) {
|
|
19
|
+
let result = ''
|
|
20
|
+
let lastPos = 0
|
|
21
|
+
|
|
22
|
+
replacements.sort((a, b) => a.pos - b.pos)
|
|
23
|
+
|
|
24
|
+
for (let i = 0; i < replacements.length; i++) {
|
|
25
|
+
const replacement = replacements[i]
|
|
26
|
+
|
|
27
|
+
result += str.slice(lastPos, replacement.pos) + replacement.ch
|
|
28
|
+
lastPos = replacement.pos + 1
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
return result + str.slice(lastPos)
|
|
12
32
|
}
|
|
13
33
|
|
|
14
34
|
function process_inlines (tokens, state) {
|
|
15
35
|
let j
|
|
16
36
|
|
|
17
37
|
const stack = []
|
|
38
|
+
// token index -> list of replacements in the original token content
|
|
39
|
+
const replacements = {}
|
|
18
40
|
|
|
19
41
|
for (let i = 0; i < tokens.length; i++) {
|
|
20
42
|
const token = tokens[i]
|
|
@@ -28,9 +50,9 @@ function process_inlines (tokens, state) {
|
|
|
28
50
|
|
|
29
51
|
if (token.type !== 'text') { continue }
|
|
30
52
|
|
|
31
|
-
|
|
53
|
+
const text = token.content
|
|
32
54
|
let pos = 0
|
|
33
|
-
|
|
55
|
+
const max = text.length
|
|
34
56
|
|
|
35
57
|
/* eslint no-labels:0,block-scoped-var:0 */
|
|
36
58
|
OUTER:
|
|
@@ -78,8 +100,8 @@ function process_inlines (tokens, state) {
|
|
|
78
100
|
}
|
|
79
101
|
}
|
|
80
102
|
|
|
81
|
-
const isLastPunctChar = isMdAsciiPunct(lastChar) ||
|
|
82
|
-
const isNextPunctChar = isMdAsciiPunct(nextChar) ||
|
|
103
|
+
const isLastPunctChar = isMdAsciiPunct(lastChar) || isPunctCharCode(lastChar)
|
|
104
|
+
const isNextPunctChar = isMdAsciiPunct(nextChar) || isPunctCharCode(nextChar)
|
|
83
105
|
|
|
84
106
|
const isLastWhiteSpace = isWhiteSpace(lastChar)
|
|
85
107
|
const isNextWhiteSpace = isWhiteSpace(nextChar)
|
|
@@ -122,7 +144,7 @@ function process_inlines (tokens, state) {
|
|
|
122
144
|
if (!canOpen && !canClose) {
|
|
123
145
|
// middle of word
|
|
124
146
|
if (isSingle) {
|
|
125
|
-
|
|
147
|
+
addReplacement(replacements, i, t.index, APOSTROPHE)
|
|
126
148
|
}
|
|
127
149
|
continue
|
|
128
150
|
}
|
|
@@ -145,18 +167,8 @@ function process_inlines (tokens, state) {
|
|
|
145
167
|
closeQuote = state.md.options.quotes[1]
|
|
146
168
|
}
|
|
147
169
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
// could mess up indices when quote length != 1
|
|
151
|
-
token.content = replaceAt(token.content, t.index, closeQuote)
|
|
152
|
-
tokens[item.token].content = replaceAt(
|
|
153
|
-
tokens[item.token].content, item.pos, openQuote)
|
|
154
|
-
|
|
155
|
-
pos += closeQuote.length - 1
|
|
156
|
-
if (item.token === i) { pos += openQuote.length - 1 }
|
|
157
|
-
|
|
158
|
-
text = token.content
|
|
159
|
-
max = text.length
|
|
170
|
+
addReplacement(replacements, i, t.index, closeQuote)
|
|
171
|
+
addReplacement(replacements, item.token, item.pos, openQuote)
|
|
160
172
|
|
|
161
173
|
stack.length = j
|
|
162
174
|
continue OUTER
|
|
@@ -172,10 +184,14 @@ function process_inlines (tokens, state) {
|
|
|
172
184
|
level: thisLevel
|
|
173
185
|
})
|
|
174
186
|
} else if (canClose && isSingle) {
|
|
175
|
-
|
|
187
|
+
addReplacement(replacements, i, t.index, APOSTROPHE)
|
|
176
188
|
}
|
|
177
189
|
}
|
|
178
190
|
}
|
|
191
|
+
|
|
192
|
+
Object.keys(replacements).forEach(function (tokenIdx) {
|
|
193
|
+
tokens[tokenIdx].content = applyReplacements(tokens[tokenIdx].content, replacements[tokenIdx])
|
|
194
|
+
})
|
|
179
195
|
}
|
|
180
196
|
|
|
181
197
|
export default function smartquotes (state) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Process html entity - {, ¯, ", ...
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { decodeHTMLStrict } from 'entities'
|
|
4
4
|
import { isValidEntityCode, fromCodePoint } from '../common/utils.mjs'
|
|
5
5
|
|
|
6
6
|
const DIGITAL_RE = /^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i
|
|
@@ -33,7 +33,7 @@ export default function entity (state, silent) {
|
|
|
33
33
|
} else {
|
|
34
34
|
const match = state.src.slice(pos).match(NAMED_RE)
|
|
35
35
|
if (match) {
|
|
36
|
-
const decoded =
|
|
36
|
+
const decoded = decodeHTMLStrict(match[0])
|
|
37
37
|
if (decoded !== match[0]) {
|
|
38
38
|
if (!silent) {
|
|
39
39
|
const token = state.push('text_special', '', 0)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Inline parser state
|
|
2
2
|
|
|
3
3
|
import Token from '../token.mjs'
|
|
4
|
-
import { isWhiteSpace,
|
|
4
|
+
import { isWhiteSpace, isPunctCharCode, isMdAsciiPunct } from '../common/utils.mjs'
|
|
5
5
|
|
|
6
6
|
function StateInline (src, md, env, outTokens) {
|
|
7
7
|
this.src = src
|
|
@@ -89,8 +89,30 @@ StateInline.prototype.scanDelims = function (start, canSplitWord) {
|
|
|
89
89
|
const max = this.posMax
|
|
90
90
|
const marker = this.src.charCodeAt(start)
|
|
91
91
|
|
|
92
|
-
//
|
|
93
|
-
|
|
92
|
+
// Astral characters below are combined manually, because .codePointAt()
|
|
93
|
+
// does not guarantee numeric type output. And we don't wish JIT cache issues.
|
|
94
|
+
// The broken surrogate pairs are evaluated as U+FFFD to prevent possible
|
|
95
|
+
// crashes.
|
|
96
|
+
|
|
97
|
+
let lastChar
|
|
98
|
+
if (start === 0) {
|
|
99
|
+
// treat beginning of the line as a whitespace
|
|
100
|
+
lastChar = 0x20
|
|
101
|
+
} else if (start === 1) {
|
|
102
|
+
lastChar = this.src.charCodeAt(0)
|
|
103
|
+
if ((lastChar & 0xF800) === 0xD800) { lastChar = 0xFFFD }
|
|
104
|
+
} else {
|
|
105
|
+
lastChar = this.src.charCodeAt(start - 1)
|
|
106
|
+
if ((lastChar & 0xFC00) === 0xDC00) {
|
|
107
|
+
// low surrogate => add high one, replace broken pair with U+FFFD
|
|
108
|
+
const highSurr = this.src.charCodeAt(start - 2)
|
|
109
|
+
lastChar = (highSurr & 0xFC00) === 0xD800
|
|
110
|
+
? 0x10000 + ((highSurr - 0xD800) << 10) + (lastChar - 0xDC00)
|
|
111
|
+
: 0xFFFD
|
|
112
|
+
} else if ((lastChar & 0xFC00) === 0xD800) {
|
|
113
|
+
lastChar = 0xFFFD
|
|
114
|
+
}
|
|
115
|
+
}
|
|
94
116
|
|
|
95
117
|
let pos = start
|
|
96
118
|
while (pos < max && this.src.charCodeAt(pos) === marker) { pos++ }
|
|
@@ -98,10 +120,19 @@ StateInline.prototype.scanDelims = function (start, canSplitWord) {
|
|
|
98
120
|
const count = pos - start
|
|
99
121
|
|
|
100
122
|
// treat end of the line as a whitespace
|
|
101
|
-
|
|
123
|
+
let nextChar = pos < max ? this.src.charCodeAt(pos) : 0x20
|
|
124
|
+
if ((nextChar & 0xFC00) === 0xD800) {
|
|
125
|
+
// high surrogate => add low one, replace broken pair with U+FFFD
|
|
126
|
+
const lowSurr = this.src.charCodeAt(pos + 1)
|
|
127
|
+
nextChar = (lowSurr & 0xFC00) === 0xDC00
|
|
128
|
+
? 0x10000 + ((nextChar - 0xD800) << 10) + (lowSurr - 0xDC00)
|
|
129
|
+
: 0xFFFD
|
|
130
|
+
} else if ((nextChar & 0xFC00) === 0xDC00) {
|
|
131
|
+
nextChar = 0xFFFD
|
|
132
|
+
}
|
|
102
133
|
|
|
103
|
-
const isLastPunctChar = isMdAsciiPunct(lastChar) ||
|
|
104
|
-
const isNextPunctChar = isMdAsciiPunct(nextChar) ||
|
|
134
|
+
const isLastPunctChar = isMdAsciiPunct(lastChar) || isPunctCharCode(lastChar)
|
|
135
|
+
const isNextPunctChar = isMdAsciiPunct(nextChar) || isPunctCharCode(nextChar)
|
|
105
136
|
|
|
106
137
|
const isLastWhiteSpace = isWhiteSpace(lastChar)
|
|
107
138
|
const isNextWhiteSpace = isWhiteSpace(nextChar)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "markdown-it",
|
|
3
|
-
"version": "14.
|
|
3
|
+
"version": "14.2.0",
|
|
4
4
|
"description": "Markdown-it - modern pluggable markdown parser.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"markdown",
|
|
@@ -11,6 +11,16 @@
|
|
|
11
11
|
],
|
|
12
12
|
"repository": "markdown-it/markdown-it",
|
|
13
13
|
"license": "MIT",
|
|
14
|
+
"funding": [
|
|
15
|
+
{
|
|
16
|
+
"type": "github",
|
|
17
|
+
"url": "https://github.com/sponsors/puzrin"
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"type": "github",
|
|
21
|
+
"url": "https://github.com/sponsors/markdown-it"
|
|
22
|
+
}
|
|
23
|
+
],
|
|
14
24
|
"main": "dist/index.cjs.js",
|
|
15
25
|
"module": "index.mjs",
|
|
16
26
|
"exports": {
|
|
@@ -28,7 +38,7 @@
|
|
|
28
38
|
},
|
|
29
39
|
"scripts": {
|
|
30
40
|
"lint": "eslint .",
|
|
31
|
-
"test": "npm run lint && CJS_ONLY=1 npm run build && c8 --exclude dist --exclude test -r text -r html -r lcov mocha && node support/specsplit.mjs",
|
|
41
|
+
"test": "npm run lint && cross-env CJS_ONLY=1 npm run build && c8 --exclude dist --exclude test -r text -r html -r lcov mocha && node support/specsplit.mjs",
|
|
32
42
|
"doc": "node support/build_doc.mjs",
|
|
33
43
|
"gh-doc": "npm run doc && gh-pages -d apidoc -f",
|
|
34
44
|
"demo": "npm run lint && node support/build_demo.mjs",
|
|
@@ -47,7 +57,7 @@
|
|
|
47
57
|
"dependencies": {
|
|
48
58
|
"argparse": "^2.0.1",
|
|
49
59
|
"entities": "^4.4.0",
|
|
50
|
-
"linkify-it": "^5.0.
|
|
60
|
+
"linkify-it": "^5.0.1",
|
|
51
61
|
"mdurl": "^2.0.0",
|
|
52
62
|
"punycode.js": "^2.3.1",
|
|
53
63
|
"uc.micro": "^2.1.0"
|
|
@@ -61,6 +71,7 @@
|
|
|
61
71
|
"benchmark": "~2.1.0",
|
|
62
72
|
"c8": "^8.0.1",
|
|
63
73
|
"chai": "^4.2.0",
|
|
74
|
+
"cross-env": "^7.0.3",
|
|
64
75
|
"eslint": "^8.4.1",
|
|
65
76
|
"eslint-config-standard": "^17.1.0",
|
|
66
77
|
"express": "^4.14.0",
|
|
@@ -7,8 +7,6 @@
|
|
|
7
7
|
[](README.md)
|
|
8
8
|
[](LICENSE)
|
|
9
9
|
|
|
10
|
-
<img align="right" src="./assets/performance.png" width="380"/>
|
|
11
|
-
|
|
12
10
|
The msgpackr package is an extremely fast MessagePack NodeJS/JavaScript implementation. Currently, it is significantly faster than any other known implementations, faster than Avro (for JS), and generally faster than native V8 JSON.stringify/parse, on NodeJS. It also includes an optional record extension (the `r` in msgpackr), for defining record structures that makes MessagePack even faster and more compact, often over twice as fast as even native JSON functions, several times faster than other JS implementations, and 15-50% more compact. See the performance section for more details. Structured cloning (with support for cyclical references) is also supported through optional extensions.
|
|
13
11
|
|
|
14
12
|
## Basic Usage
|
|
@@ -104,7 +102,7 @@ packr.pack(bigDataWithLotsOfObjects);
|
|
|
104
102
|
|
|
105
103
|
Another way to further leverage the benefits of the msgpackr record structures is to use streams that naturally allow for data to reuse based on previous record structures. The stream classes have the record structure extension enabled by default and provide excellent out-of-the-box performance.
|
|
106
104
|
|
|
107
|
-
When creating a new `Packr`, `Unpackr`, `PackrStream`, or `UnpackrStream` instance, we can enable or disable the record structure extension with the `useRecords` property. When this is `false`, the record structure extension will be disabled (standard/compatibility mode), and all objects will revert to being serialized using
|
|
105
|
+
When creating a new `Packr`, `Unpackr`, `PackrStream`, or `UnpackrStream` instance, we can enable or disable the record structure extension with the `useRecords` property. When this is `false`, the record structure extension will be disabled (standard/compatibility mode), and all objects will revert to being serialized using MessagePack `map`s, and all `map`s will be deserialized to JS `Object`s as properties (like the standalone `pack` and `unpack` functions).
|
|
108
106
|
|
|
109
107
|
Streaming with record structures works by encoding a structure the first time it is seen in a stream and referencing the structure in later messages that are sent across that stream. When an encoder can expect a decoder to understand previous structure references, this can be configured using the `sequential: true` flag, which is auto-enabled by streams, but can also be used with Packr instances.
|
|
110
108
|
|
|
@@ -1,24 +1,34 @@
|
|
|
1
1
|
Here are more comprehensive benchmarks. This is comparison with the next fastest JS projects using the benchmark tool from `msgpack-lite` (and data is from some clinical research data we use that has a good mix of different value types and structures). It also includes comparison to V8 native JSON functionality, and JavaScript Avro (`avsc`, a very optimized Avro implementation):
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
require("msgpackr").
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
require("
|
|
16
|
-
require("
|
|
17
|
-
require("
|
|
18
|
-
require("
|
|
3
|
+
---------------------------------------------------------- | ------: | ----: | -----: | -----:
|
|
4
|
+
msgpackr w/ shared structures: packr.pack(obj); | 254700 | 5001 | 50929
|
|
5
|
+
msgpackr w/ shared structures: packr.unpack(buf); | 711700 | 5000 | 142340
|
|
6
|
+
require("msgpackr").pack(obj); | 234000 | 5000 | 46800
|
|
7
|
+
require("msgpackr").unpack(buf); | 186500 | 5000 | 37300
|
|
8
|
+
buf = Buffer(JSON.stringify(obj)); | 297900 | 5000 | 59580
|
|
9
|
+
obj = JSON.parse(buf); | 216600 | 5001 | 43311
|
|
10
|
+
buf = require("msgpack-lite").encode(obj); | 114000 | 5001 | 22795
|
|
11
|
+
obj = require("msgpack-lite").decode(buf); | 40700 | 5006 | 8130
|
|
12
|
+
buf = require("@msgpack/msgpack").encode(obj); | 166100 | 5000 | 33220
|
|
13
|
+
obj = require("@msgpack/msgpack").decode(buf); | 136500 | 5002 | 27289
|
|
14
|
+
buf = require("msgpack-js-v5").encode(obj); | 41600 | 5000 | 8320
|
|
15
|
+
obj = require("msgpack-js-v5").decode(buf); | 70200 | 5004 | 14028
|
|
16
|
+
buf = require("msgpack-js").encode(obj); | 40400 | 5012 | 8060
|
|
17
|
+
obj = require("msgpack-js").decode(buf); | 67100 | 5002 | 13414
|
|
18
|
+
buf = require("msgpack5")().encode(obj); | 15800 | 5024 | 3144
|
|
19
|
+
obj = require("msgpack5")().decode(buf); | 30600 | 5004 | 6115
|
|
20
|
+
buf = require("notepack").encode(obj); | 125100 | 5002 | 25009
|
|
21
|
+
obj = require("notepack").decode(buf); | 98600 | 5004 | 19704
|
|
22
|
+
require("what-the-pack")... encoder.encode(obj); | 150300 | 5001 | 30053
|
|
23
|
+
require("what-the-pack")... encoder.decode(buf); | 100100 | 5000 | 20020
|
|
24
|
+
obj = require("msgpack-unpack").decode(buf); | 14900 | 5031 | 2961
|
|
25
|
+
require("avsc")...make schema/type...type.toBuffer(obj); | 266600 | 5000 | 53320
|
|
26
|
+
require("avsc")...make schema/type...type.fromBuffer(obj); | 370200 | 5000 | 74040
|
|
19
27
|
|
|
20
28
|
(`avsc` is schema-based and more comparable in style to msgpackr with shared structures).
|
|
21
29
|
|
|
30
|
+
(note that benchmarks below are several years old)
|
|
31
|
+
|
|
22
32
|
Here is a benchmark of streaming data (again borrowed from `msgpack-lite`'s benchmarking), where msgpackr is able to take advantage of the structured record extension and really pull away from other tools:
|
|
23
33
|
|
|
24
34
|
operation (1000000 x 2) | op | ms | op/s
|
|
@@ -31,13 +31,6 @@
|
|
|
31
31
|
var inlineObjectReadThreshold = 2;
|
|
32
32
|
var readStruct;
|
|
33
33
|
var BlockedFunction; // we use search and replace to change the next call to BlockedFunction to avoid CSP issues for
|
|
34
|
-
// no-eval build
|
|
35
|
-
try {
|
|
36
|
-
new BlockedFunction ('');
|
|
37
|
-
} catch(error) {
|
|
38
|
-
// if eval variants are not supported, do not create inline object readers ever
|
|
39
|
-
inlineObjectReadThreshold = Infinity;
|
|
40
|
-
}
|
|
41
34
|
|
|
42
35
|
class Unpackr {
|
|
43
36
|
constructor(options) {
|
|
@@ -503,11 +496,18 @@
|
|
|
503
496
|
function readObject() {
|
|
504
497
|
// This initial function is quick to instantiate, but runs slower. After several iterations pay the cost to build the faster function
|
|
505
498
|
if (readObject.count++ > inlineObjectReadThreshold) {
|
|
506
|
-
let
|
|
507
|
-
|
|
499
|
+
let optimizedReadObject;
|
|
500
|
+
try {
|
|
501
|
+
optimizedReadObject = structure.read = (new BlockedFunction ('r', 'return function(){return ' + (currentUnpackr.freezeData ? 'Object.freeze' : '') +
|
|
502
|
+
'({' + structure.map(key => key === '__proto__' ? '__proto_:r()' : validName.test(key) ? key + ':r()' : ('[' + JSON.stringify(key) + ']:r()')).join(',') + '})}'))(read);
|
|
503
|
+
} catch(error) {
|
|
504
|
+
// in CF workers, the new BlockedFunction call could begin to fail at any point in time
|
|
505
|
+
inlineObjectReadThreshold = Infinity; // disable going forward
|
|
506
|
+
return readObject(); // recursively try again
|
|
507
|
+
}
|
|
508
508
|
if (structure.highByte === 0)
|
|
509
509
|
structure.read = createSecondByteReader(firstId, structure.read);
|
|
510
|
-
return
|
|
510
|
+
return optimizedReadObject() // second byte is already read, if there is one so immediately read object
|
|
511
511
|
}
|
|
512
512
|
let object = {};
|
|
513
513
|
for (let i = 0, l = structure.length; i < l; i++) {
|
|
@@ -576,26 +576,45 @@
|
|
|
576
576
|
} else if ((byte1 & 0xe0) === 0xc0) {
|
|
577
577
|
// 2 bytes
|
|
578
578
|
const byte2 = src[position$1++] & 0x3f;
|
|
579
|
-
|
|
579
|
+
const codePoint = ((byte1 & 0x1f) << 6) | byte2;
|
|
580
|
+
// Reject overlong encoding: 2-byte sequences must encode values >= 0x80
|
|
581
|
+
if (codePoint < 0x80) {
|
|
582
|
+
units.push(0xFFFD); // replacement character
|
|
583
|
+
} else {
|
|
584
|
+
units.push(codePoint);
|
|
585
|
+
}
|
|
580
586
|
} else if ((byte1 & 0xf0) === 0xe0) {
|
|
581
587
|
// 3 bytes
|
|
582
588
|
const byte2 = src[position$1++] & 0x3f;
|
|
583
589
|
const byte3 = src[position$1++] & 0x3f;
|
|
584
|
-
|
|
590
|
+
const codePoint = ((byte1 & 0x1f) << 12) | (byte2 << 6) | byte3;
|
|
591
|
+
// Reject overlong encoding: 3-byte sequences must encode values >= 0x800
|
|
592
|
+
// Also reject surrogates (0xD800-0xDFFF)
|
|
593
|
+
if (codePoint < 0x800 || (codePoint >= 0xD800 && codePoint <= 0xDFFF)) {
|
|
594
|
+
units.push(0xFFFD); // replacement character
|
|
595
|
+
} else {
|
|
596
|
+
units.push(codePoint);
|
|
597
|
+
}
|
|
585
598
|
} else if ((byte1 & 0xf8) === 0xf0) {
|
|
586
599
|
// 4 bytes
|
|
587
600
|
const byte2 = src[position$1++] & 0x3f;
|
|
588
601
|
const byte3 = src[position$1++] & 0x3f;
|
|
589
602
|
const byte4 = src[position$1++] & 0x3f;
|
|
590
603
|
let unit = ((byte1 & 0x07) << 0x12) | (byte2 << 0x0c) | (byte3 << 0x06) | byte4;
|
|
591
|
-
|
|
604
|
+
// Reject overlong encoding: 4-byte sequences must encode values >= 0x10000
|
|
605
|
+
// Also reject values > 0x10FFFF (maximum valid Unicode)
|
|
606
|
+
if (unit < 0x10000 || unit > 0x10FFFF) {
|
|
607
|
+
units.push(0xFFFD); // replacement character
|
|
608
|
+
} else if (unit > 0xffff) {
|
|
592
609
|
unit -= 0x10000;
|
|
593
610
|
units.push(((unit >>> 10) & 0x3ff) | 0xd800);
|
|
594
611
|
unit = 0xdc00 | (unit & 0x3ff);
|
|
612
|
+
units.push(unit);
|
|
613
|
+
} else {
|
|
614
|
+
units.push(unit);
|
|
595
615
|
}
|
|
596
|
-
units.push(unit);
|
|
597
616
|
} else {
|
|
598
|
-
units.push(
|
|
617
|
+
units.push(0xFFFD); // replacement character for invalid lead byte
|
|
599
618
|
}
|
|
600
619
|
|
|
601
620
|
if (units.length >= 0x1000) {
|
|
@@ -958,7 +977,7 @@
|
|
|
958
977
|
if (length <= 40) {
|
|
959
978
|
let out = view.getBigUint64(start);
|
|
960
979
|
for (let i = start + 8; i < end; i += 8) {
|
|
961
|
-
out <<= BigInt(
|
|
980
|
+
out <<= BigInt(64);
|
|
962
981
|
out |= view.getBigUint64(i);
|
|
963
982
|
}
|
|
964
983
|
return out
|