@lotte-innovate/ui-component-test 0.1.76 → 0.1.78
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +9 -11
- package/dist/globals.css +2 -2
- package/dist/lib/_virtual/index.mjs +1 -1
- package/dist/lib/_virtual/index2.mjs +1 -1
- package/dist/lib/_virtual/index3.mjs +1 -1
- package/dist/lib/_virtual/react-is.development.mjs +2 -0
- package/dist/lib/_virtual/react-is.development.mjs.map +1 -0
- package/dist/lib/_virtual/react-is.production.min.mjs +2 -0
- package/dist/lib/_virtual/react-is.production.min.mjs.map +1 -0
- package/dist/lib/components/Editor/index.d.ts +10 -5
- package/dist/lib/components/Editor/index.js +50 -6
- package/dist/lib/components/Footer/index.js +8 -1
- package/dist/lib/components/Gnb/GnbInfo.js +1 -0
- package/dist/lib/components/Gnb/GnbLogo.js +3 -4
- package/dist/lib/components/Gnb/GnbMenu.js +1 -0
- package/dist/lib/components/Gnb/GnbRoot.js +4 -2
- package/dist/lib/components/Grid/Pagination.d.ts +2 -0
- package/dist/lib/components/Grid/Pagination.js +17 -0
- package/dist/lib/components/Grid/index.d.ts +1 -2
- package/dist/lib/components/Grid/index.js +40 -47
- package/dist/lib/components/Grid/useGrid.d.ts +1 -1
- package/dist/lib/components/Grid/useGrid.js +19 -11
- package/dist/lib/components/Slider/index.d.ts +2 -1
- package/dist/lib/components/index.d.ts +2 -1
- package/dist/lib/components/index.js +3 -1
- package/dist/lib/dist/lib/components/BarChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbEllipsis.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbItem.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbLink.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbList.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbPage.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Breadcrumb/BreadcrumbSeparator.mjs.map +1 -1
- package/dist/lib/dist/lib/components/BubbleChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/ContextMenu/ContextMenuGroup.mjs.map +1 -1
- package/dist/lib/dist/lib/components/ContextMenu/ContextMenuSeparator.mjs.map +1 -1
- package/dist/lib/dist/lib/components/ContextMenu/ContextMenuTrigger.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Dialog/DialogTrigger.mjs.map +1 -1
- package/dist/lib/dist/lib/components/DoughnutChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/DropdownMenu/DropdonMenuRadioGroup.mjs.map +1 -1
- package/dist/lib/dist/lib/components/DropdownMenu/DropdownMenuSeparator.mjs.map +1 -1
- package/dist/lib/dist/lib/components/DropdownMenu/DropdownMenuSub.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Editor/index.mjs +1 -1
- package/dist/lib/dist/lib/components/Footer/index.mjs +1 -1
- package/dist/lib/dist/lib/components/Gnb/GnbInfo.mjs +1 -0
- package/dist/lib/dist/lib/components/Gnb/GnbInfo.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Gnb/GnbLogo.mjs +1 -1
- package/dist/lib/dist/lib/components/Gnb/GnbLogo.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Gnb/GnbMenu.mjs +2 -1
- package/dist/lib/dist/lib/components/Gnb/GnbMenu.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Gnb/GnbRoot.mjs +1 -1
- package/dist/lib/dist/lib/components/Grid/Pagination.mjs +2 -0
- package/dist/lib/dist/lib/components/Grid/Pagination.mjs.map +1 -0
- package/dist/lib/dist/lib/components/Grid/index.mjs +3 -0
- package/dist/lib/dist/lib/components/Grid/index.mjs.map +1 -0
- package/dist/lib/dist/lib/components/Grid/useGrid.mjs +3 -0
- package/dist/lib/dist/lib/components/Grid/useGrid.mjs.map +1 -0
- package/dist/lib/dist/lib/components/HoverCard/HoverCardTrigger.mjs.map +1 -1
- package/dist/lib/dist/lib/components/LineChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Menubar/MenubarMenu.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Menubar/MenubarSeparator.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Menubar/MenubarSub.mjs.map +1 -1
- package/dist/lib/dist/lib/components/NavigationMenu/NavigationMenuIndicator.mjs.map +1 -1
- package/dist/lib/dist/lib/components/NavigationMenu/NavigationMenuItem.mjs.map +1 -1
- package/dist/lib/dist/lib/components/PieChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/Popover/PopoverTrigger.mjs.map +1 -1
- package/dist/lib/dist/lib/components/RadarChart/index.mjs.map +1 -1
- package/dist/lib/dist/lib/components/SegmentedControl/SegmentedControlItem.mjs.map +1 -1
- package/dist/lib/dist/lib/constants.mjs +1 -1
- package/dist/lib/dist/lib/constants.mjs.map +1 -1
- package/dist/lib/dist/lib/index.mjs +1 -1
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/ScriptLoader2.mjs +2 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/ScriptLoader2.mjs.map +1 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/TinyMCE.mjs +2 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/TinyMCE.mjs.map +1 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/Utils.mjs +2 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/Utils.mjs.map +1 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/components/Editor.mjs +2 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/components/Editor.mjs.map +1 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/components/EditorPropTypes.mjs +2 -0
- package/dist/lib/node_modules/@tinymce/tinymce-react/lib/es2015/main/ts/components/EditorPropTypes.mjs.map +1 -0
- package/dist/lib/node_modules/marked/lib/marked.esm.mjs +2 -0
- package/dist/lib/node_modules/marked/lib/marked.esm.mjs.map +1 -0
- package/dist/lib/node_modules/object-assign/index.mjs +7 -0
- package/dist/lib/node_modules/object-assign/index.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/checkPropTypes.mjs +2 -0
- package/dist/lib/node_modules/prop-types/checkPropTypes.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/factoryWithThrowingShims.mjs +2 -0
- package/dist/lib/node_modules/prop-types/factoryWithThrowingShims.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/factoryWithTypeCheckers.mjs +2 -0
- package/dist/lib/node_modules/prop-types/factoryWithTypeCheckers.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/index.mjs +2 -0
- package/dist/lib/node_modules/prop-types/index.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/lib/ReactPropTypesSecret.mjs +2 -0
- package/dist/lib/node_modules/prop-types/lib/ReactPropTypesSecret.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/lib/has.mjs +2 -0
- package/dist/lib/node_modules/prop-types/lib/has.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/cjs/react-is.development.mjs +10 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/cjs/react-is.development.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.mjs +10 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/cjs/react-is.production.min.mjs.map +1 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/index.mjs +2 -0
- package/dist/lib/node_modules/prop-types/node_modules/react-is/index.mjs.map +1 -0
- package/dist/lib/tsconfig.tsbuildinfo +1 -1
- package/dist/lib/types.d.ts +2 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +7 -6
- package/public/tinymce/CHANGELOG.md +3453 -0
- package/public/tinymce/README.md +73 -0
- package/public/tinymce/bower.json +27 -0
- package/public/tinymce/composer.json +52 -0
- package/public/tinymce/icons/default/icons.js +194 -0
- package/public/tinymce/icons/default/icons.min.js +1 -0
- package/public/tinymce/icons/default/index.js +7 -0
- package/public/tinymce/license.txt +21 -0
- package/public/tinymce/models/dom/index.js +7 -0
- package/public/tinymce/models/dom/model.js +8040 -0
- package/public/tinymce/models/dom/model.min.js +4 -0
- package/public/tinymce/package.json +32 -0
- package/public/tinymce/plugins/advlist/index.js +7 -0
- package/public/tinymce/plugins/advlist/plugin.js +259 -0
- package/public/tinymce/plugins/advlist/plugin.min.js +4 -0
- package/public/tinymce/plugins/autolink/index.js +7 -0
- package/public/tinymce/plugins/autolink/plugin.js +228 -0
- package/public/tinymce/plugins/autolink/plugin.min.js +4 -0
- package/public/tinymce/plugins/code/index.js +7 -0
- package/public/tinymce/plugins/code/plugin.js +85 -0
- package/public/tinymce/plugins/code/plugin.min.js +4 -0
- package/public/tinymce/plugins/codesample/index.js +7 -0
- package/public/tinymce/plugins/codesample/plugin.js +2463 -0
- package/public/tinymce/plugins/codesample/plugin.min.js +4 -0
- package/public/tinymce/plugins/image/index.js +7 -0
- package/public/tinymce/plugins/image/plugin.js +1505 -0
- package/public/tinymce/plugins/image/plugin.min.js +4 -0
- package/public/tinymce/plugins/link/index.js +7 -0
- package/public/tinymce/plugins/link/plugin.js +1242 -0
- package/public/tinymce/plugins/link/plugin.min.js +4 -0
- package/public/tinymce/plugins/lists/index.js +7 -0
- package/public/tinymce/plugins/lists/plugin.js +2172 -0
- package/public/tinymce/plugins/lists/plugin.min.js +4 -0
- package/public/tinymce/plugins/table/index.js +7 -0
- package/public/tinymce/plugins/table/plugin.js +3462 -0
- package/public/tinymce/plugins/table/plugin.min.js +4 -0
- package/public/tinymce/skins/content/dark/content.css +66 -0
- package/public/tinymce/skins/content/dark/content.js +2 -0
- package/public/tinymce/skins/content/dark/content.min.css +1 -0
- package/public/tinymce/skins/content/default/content.css +61 -0
- package/public/tinymce/skins/content/default/content.js +2 -0
- package/public/tinymce/skins/content/default/content.min.css +1 -0
- package/public/tinymce/skins/content/document/content.js +2 -0
- package/public/tinymce/skins/content/document/content.min.css +1 -0
- package/public/tinymce/skins/content/tinymce-5/content.js +2 -0
- package/public/tinymce/skins/content/tinymce-5/content.min.css +1 -0
- package/public/tinymce/skins/content/tinymce-5-dark/content.js +2 -0
- package/public/tinymce/skins/content/tinymce-5-dark/content.min.css +1 -0
- package/public/tinymce/skins/content/writer/content.js +2 -0
- package/public/tinymce/skins/content/writer/content.min.css +1 -0
- package/public/tinymce/skins/ui/oxide/content.css +785 -0
- package/public/tinymce/skins/ui/oxide/content.inline.css +779 -0
- package/public/tinymce/skins/ui/oxide/content.inline.js +2 -0
- package/public/tinymce/skins/ui/oxide/content.inline.min.css +1 -0
- package/public/tinymce/skins/ui/oxide/content.js +2 -0
- package/public/tinymce/skins/ui/oxide/content.min.css +1 -0
- package/public/tinymce/skins/ui/oxide/skin.css +3763 -0
- package/public/tinymce/skins/ui/oxide/skin.js +2 -0
- package/public/tinymce/skins/ui/oxide/skin.min.css +1 -0
- package/public/tinymce/skins/ui/oxide/skin.shadowdom.css +30 -0
- package/public/tinymce/skins/ui/oxide/skin.shadowdom.js +2 -0
- package/public/tinymce/skins/ui/oxide/skin.shadowdom.min.css +1 -0
- package/public/tinymce/skins/ui/oxide-dark/content.css +766 -0
- package/public/tinymce/skins/ui/oxide-dark/content.inline.css +779 -0
- package/public/tinymce/skins/ui/oxide-dark/content.inline.js +2 -0
- package/public/tinymce/skins/ui/oxide-dark/content.inline.min.css +1 -0
- package/public/tinymce/skins/ui/oxide-dark/content.js +2 -0
- package/public/tinymce/skins/ui/oxide-dark/content.min.css +1 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.css +3766 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.js +2 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.min.css +1 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.css +30 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.js +2 -0
- package/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5/content.inline.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5/content.inline.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5/content.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5/content.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5/skin.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5/skin.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/content.inline.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/content.inline.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/content.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/content.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/skin.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/skin.min.css +1 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.js +2 -0
- package/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.min.css +1 -0
- package/public/tinymce/themes/silver/index.js +7 -0
- package/public/tinymce/themes/silver/theme.js +30775 -0
- package/public/tinymce/themes/silver/theme.min.js +384 -0
- package/public/tinymce/tinymce.d.ts +3238 -0
- package/public/tinymce/tinymce.js +31779 -0
- package/public/tinymce/tinymce.min.js +384 -0
- package/dist/lib/_virtual/_commonjsHelpers.mjs +0 -2
- package/dist/lib/_virtual/_commonjsHelpers.mjs.map +0 -1
- package/dist/lib/_virtual/_interop_require_default.mjs +0 -2
- package/dist/lib/_virtual/_interop_require_default.mjs.map +0 -1
- package/dist/lib/_virtual/_interop_require_wildcard.mjs +0 -2
- package/dist/lib/_virtual/_interop_require_wildcard.mjs.map +0 -1
- package/dist/lib/_virtual/action-async-storage.external.mjs +0 -2
- package/dist/lib/_virtual/action-async-storage.external.mjs.map +0 -1
- package/dist/lib/_virtual/add-base-path.mjs +0 -2
- package/dist/lib/_virtual/add-base-path.mjs.map +0 -1
- package/dist/lib/_virtual/add-locale.mjs +0 -2
- package/dist/lib/_virtual/add-locale.mjs.map +0 -1
- package/dist/lib/_virtual/add-locale2.mjs +0 -2
- package/dist/lib/_virtual/add-locale2.mjs.map +0 -1
- package/dist/lib/_virtual/add-path-prefix.mjs +0 -2
- package/dist/lib/_virtual/add-path-prefix.mjs.map +0 -1
- package/dist/lib/_virtual/amp-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/amp-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/amp-mode.mjs +0 -2
- package/dist/lib/_virtual/amp-mode.mjs.map +0 -1
- package/dist/lib/_virtual/app-paths.mjs +0 -2
- package/dist/lib/_virtual/app-paths.mjs.map +0 -1
- package/dist/lib/_virtual/app-router-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/app-router-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/async-local-storage.mjs +0 -2
- package/dist/lib/_virtual/async-local-storage.mjs.map +0 -1
- package/dist/lib/_virtual/bailout-to-client-rendering.mjs +0 -2
- package/dist/lib/_virtual/bailout-to-client-rendering.mjs.map +0 -1
- package/dist/lib/_virtual/bailout-to-csr.mjs +0 -2
- package/dist/lib/_virtual/bailout-to-csr.mjs.map +0 -1
- package/dist/lib/_virtual/client-hook-in-server-component-error.mjs +0 -2
- package/dist/lib/_virtual/client-hook-in-server-component-error.mjs.map +0 -1
- package/dist/lib/_virtual/detect-domain-locale.mjs +0 -2
- package/dist/lib/_virtual/detect-domain-locale.mjs.map +0 -1
- package/dist/lib/_virtual/detect-domain-locale2.mjs +0 -2
- package/dist/lib/_virtual/detect-domain-locale2.mjs.map +0 -1
- package/dist/lib/_virtual/ensure-leading-slash.mjs +0 -2
- package/dist/lib/_virtual/ensure-leading-slash.mjs.map +0 -1
- package/dist/lib/_virtual/escape-regexp.mjs +0 -2
- package/dist/lib/_virtual/escape-regexp.mjs.map +0 -1
- package/dist/lib/_virtual/format-url.mjs +0 -2
- package/dist/lib/_virtual/format-url.mjs.map +0 -1
- package/dist/lib/_virtual/get-domain-locale.mjs +0 -2
- package/dist/lib/_virtual/get-domain-locale.mjs.map +0 -1
- package/dist/lib/_virtual/get-img-props.mjs +0 -2
- package/dist/lib/_virtual/get-img-props.mjs.map +0 -1
- package/dist/lib/_virtual/get-segment-value.mjs +0 -2
- package/dist/lib/_virtual/get-segment-value.mjs.map +0 -1
- package/dist/lib/_virtual/has-base-path.mjs +0 -2
- package/dist/lib/_virtual/has-base-path.mjs.map +0 -1
- package/dist/lib/_virtual/head-manager-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/head-manager-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/head.mjs +0 -2
- package/dist/lib/_virtual/head.mjs.map +0 -1
- package/dist/lib/_virtual/hooks-client-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/hooks-client-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/image-blur-svg.mjs +0 -2
- package/dist/lib/_virtual/image-blur-svg.mjs.map +0 -1
- package/dist/lib/_virtual/image-component.mjs +0 -2
- package/dist/lib/_virtual/image-component.mjs.map +0 -1
- package/dist/lib/_virtual/image-config-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/image-config-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/image-config.mjs +0 -2
- package/dist/lib/_virtual/image-config.mjs.map +0 -1
- package/dist/lib/_virtual/image-external.mjs +0 -2
- package/dist/lib/_virtual/image-external.mjs.map +0 -1
- package/dist/lib/_virtual/image-loader.mjs +0 -2
- package/dist/lib/_virtual/image-loader.mjs.map +0 -1
- package/dist/lib/_virtual/image.mjs +0 -2
- package/dist/lib/_virtual/image.mjs.map +0 -1
- package/dist/lib/_virtual/index4.mjs +0 -2
- package/dist/lib/_virtual/index4.mjs.map +0 -1
- package/dist/lib/_virtual/index5.mjs +0 -2
- package/dist/lib/_virtual/index5.mjs.map +0 -1
- package/dist/lib/_virtual/index6.mjs +0 -2
- package/dist/lib/_virtual/index6.mjs.map +0 -1
- package/dist/lib/_virtual/index7.mjs +0 -2
- package/dist/lib/_virtual/index7.mjs.map +0 -1
- package/dist/lib/_virtual/index8.mjs +0 -2
- package/dist/lib/_virtual/index8.mjs.map +0 -1
- package/dist/lib/_virtual/index9.mjs +0 -2
- package/dist/lib/_virtual/index9.mjs.map +0 -1
- package/dist/lib/_virtual/interception-routes.mjs +0 -2
- package/dist/lib/_virtual/interception-routes.mjs.map +0 -1
- package/dist/lib/_virtual/interpolate-as.mjs +0 -2
- package/dist/lib/_virtual/interpolate-as.mjs.map +0 -1
- package/dist/lib/_virtual/is-dynamic.mjs +0 -2
- package/dist/lib/_virtual/is-dynamic.mjs.map +0 -1
- package/dist/lib/_virtual/is-local-url.mjs +0 -2
- package/dist/lib/_virtual/is-local-url.mjs.map +0 -1
- package/dist/lib/_virtual/link.mjs +0 -2
- package/dist/lib/_virtual/link.mjs.map +0 -1
- package/dist/lib/_virtual/link2.mjs +0 -2
- package/dist/lib/_virtual/link2.mjs.map +0 -1
- package/dist/lib/_virtual/match-remote-pattern.mjs +0 -2
- package/dist/lib/_virtual/match-remote-pattern.mjs.map +0 -1
- package/dist/lib/_virtual/navigation.mjs +0 -2
- package/dist/lib/_virtual/navigation.mjs.map +0 -1
- package/dist/lib/_virtual/navigation2.mjs +0 -2
- package/dist/lib/_virtual/navigation2.mjs.map +0 -1
- package/dist/lib/_virtual/normalize-locale-path.mjs +0 -2
- package/dist/lib/_virtual/normalize-locale-path.mjs.map +0 -1
- package/dist/lib/_virtual/normalize-locale-path2.mjs +0 -2
- package/dist/lib/_virtual/normalize-locale-path2.mjs.map +0 -1
- package/dist/lib/_virtual/normalize-trailing-slash.mjs +0 -2
- package/dist/lib/_virtual/normalize-trailing-slash.mjs.map +0 -1
- package/dist/lib/_virtual/not-found.mjs +0 -2
- package/dist/lib/_virtual/not-found.mjs.map +0 -1
- package/dist/lib/_virtual/omit.mjs +0 -2
- package/dist/lib/_virtual/omit.mjs.map +0 -1
- package/dist/lib/_virtual/parse-path.mjs +0 -2
- package/dist/lib/_virtual/parse-path.mjs.map +0 -1
- package/dist/lib/_virtual/path-has-prefix.mjs +0 -2
- package/dist/lib/_virtual/path-has-prefix.mjs.map +0 -1
- package/dist/lib/_virtual/querystring.mjs +0 -2
- package/dist/lib/_virtual/querystring.mjs.map +0 -1
- package/dist/lib/_virtual/redirect-status-code.mjs +0 -2
- package/dist/lib/_virtual/redirect-status-code.mjs.map +0 -1
- package/dist/lib/_virtual/redirect.mjs +0 -2
- package/dist/lib/_virtual/redirect.mjs.map +0 -1
- package/dist/lib/_virtual/remove-trailing-slash.mjs +0 -2
- package/dist/lib/_virtual/remove-trailing-slash.mjs.map +0 -1
- package/dist/lib/_virtual/request-async-storage.external.mjs +0 -2
- package/dist/lib/_virtual/request-async-storage.external.mjs.map +0 -1
- package/dist/lib/_virtual/request-idle-callback.mjs +0 -2
- package/dist/lib/_virtual/request-idle-callback.mjs.map +0 -1
- package/dist/lib/_virtual/resolve-href.mjs +0 -2
- package/dist/lib/_virtual/resolve-href.mjs.map +0 -1
- package/dist/lib/_virtual/route-matcher.mjs +0 -2
- package/dist/lib/_virtual/route-matcher.mjs.map +0 -1
- package/dist/lib/_virtual/route-regex.mjs +0 -2
- package/dist/lib/_virtual/route-regex.mjs.map +0 -1
- package/dist/lib/_virtual/router-context.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/router-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/router-reducer-types.mjs +0 -2
- package/dist/lib/_virtual/router-reducer-types.mjs.map +0 -1
- package/dist/lib/_virtual/segment.mjs +0 -2
- package/dist/lib/_virtual/segment.mjs.map +0 -1
- package/dist/lib/_virtual/server-inserted-html.shared-runtime.mjs +0 -2
- package/dist/lib/_virtual/server-inserted-html.shared-runtime.mjs.map +0 -1
- package/dist/lib/_virtual/side-effect.mjs +0 -2
- package/dist/lib/_virtual/side-effect.mjs.map +0 -1
- package/dist/lib/_virtual/sorted-routes.mjs +0 -2
- package/dist/lib/_virtual/sorted-routes.mjs.map +0 -1
- package/dist/lib/_virtual/static-generation-async-storage.external.mjs +0 -2
- package/dist/lib/_virtual/static-generation-async-storage.external.mjs.map +0 -1
- package/dist/lib/_virtual/toastui-editor-plugin-color-syntax.mjs +0 -2
- package/dist/lib/_virtual/toastui-editor-plugin-color-syntax.mjs.map +0 -1
- package/dist/lib/_virtual/toastui-editor-plugin-color-syntax2.mjs +0 -2
- package/dist/lib/_virtual/toastui-editor-plugin-color-syntax2.mjs.map +0 -1
- package/dist/lib/_virtual/toastui-editor-viewer.mjs +0 -2
- package/dist/lib/_virtual/toastui-editor-viewer.mjs.map +0 -1
- package/dist/lib/_virtual/toastui-editor-viewer2.mjs +0 -2
- package/dist/lib/_virtual/toastui-editor-viewer2.mjs.map +0 -1
- package/dist/lib/_virtual/tui-color-picker.mjs +0 -2
- package/dist/lib/_virtual/tui-color-picker.mjs.map +0 -1
- package/dist/lib/_virtual/use-intersection.mjs +0 -2
- package/dist/lib/_virtual/use-intersection.mjs.map +0 -1
- package/dist/lib/_virtual/utils.mjs +0 -2
- package/dist/lib/_virtual/utils.mjs.map +0 -1
- package/dist/lib/_virtual/warn-once.mjs +0 -2
- package/dist/lib/_virtual/warn-once.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineConnector.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineConnector.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineContent.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineContent.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineDescription.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineDescription.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineHeader.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineHeader.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineIcon.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineIcon.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineItem.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineItem.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineRoot.mjs +0 -3
- package/dist/lib/dist/lib/components/Timeline/TimelineRoot.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineTime.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineTime.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/TimelineTitle.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/TimelineTitle.mjs.map +0 -1
- package/dist/lib/dist/lib/components/Timeline/index.mjs +0 -2
- package/dist/lib/dist/lib/components/Timeline/index.mjs.map +0 -1
- package/dist/lib/node_modules/@swc/helpers/cjs/_interop_require_default.mjs +0 -2
- package/dist/lib/node_modules/@swc/helpers/cjs/_interop_require_default.mjs.map +0 -1
- package/dist/lib/node_modules/@swc/helpers/cjs/_interop_require_wildcard.mjs +0 -2
- package/dist/lib/node_modules/@swc/helpers/cjs/_interop_require_wildcard.mjs.map +0 -1
- package/dist/lib/node_modules/@toast-ui/editor/dist/esm/index.mjs +0 -37
- package/dist/lib/node_modules/@toast-ui/editor/dist/esm/index.mjs.map +0 -1
- package/dist/lib/node_modules/@toast-ui/editor/dist/toastui-editor-viewer.mjs +0 -24
- package/dist/lib/node_modules/@toast-ui/editor/dist/toastui-editor-viewer.mjs.map +0 -1
- package/dist/lib/node_modules/@toast-ui/editor-plugin-color-syntax/dist/toastui-editor-plugin-color-syntax.mjs +0 -8
- package/dist/lib/node_modules/@toast-ui/editor-plugin-color-syntax/dist/toastui-editor-plugin-color-syntax.mjs.map +0 -1
- package/dist/lib/node_modules/@toast-ui/react-editor/dist/esm/index.mjs +0 -22
- package/dist/lib/node_modules/@toast-ui/react-editor/dist/esm/index.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/add-base-path.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/add-base-path.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/add-locale.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/add-locale.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/action-async-storage.external.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/action-async-storage.external.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/async-local-storage.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/async-local-storage.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/bailout-to-client-rendering.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/bailout-to-client-rendering.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/client-hook-in-server-component-error.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/client-hook-in-server-component-error.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/navigation.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/navigation.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/not-found.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/not-found.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/redirect-status-code.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/redirect-status-code.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/redirect.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/redirect.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/request-async-storage.external.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/request-async-storage.external.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/router-reducer/reducers/get-segment-value.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/router-reducer/reducers/get-segment-value.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/router-reducer/router-reducer-types.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/router-reducer/router-reducer-types.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/components/static-generation-async-storage.external.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/components/static-generation-async-storage.external.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/detect-domain-locale.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/detect-domain-locale.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/get-domain-locale.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/get-domain-locale.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/has-base-path.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/has-base-path.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/image-component.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/image-component.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/link.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/link.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/normalize-locale-path.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/normalize-locale-path.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/normalize-trailing-slash.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/normalize-trailing-slash.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/request-idle-callback.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/request-idle-callback.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/resolve-href.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/resolve-href.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/client/use-intersection.mjs +0 -2
- package/dist/lib/node_modules/next/dist/client/use-intersection.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/compiled/micromatch/index.mjs +0 -23
- package/dist/lib/node_modules/next/dist/compiled/micromatch/index.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/server/future/helpers/interception-routes.mjs +0 -2
- package/dist/lib/node_modules/next/dist/server/future/helpers/interception-routes.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/amp-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/amp-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/amp-mode.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/amp-mode.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/app-router-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/app-router-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/escape-regexp.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/escape-regexp.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/get-img-props.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/get-img-props.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/head-manager-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/head-manager-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/head.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/head.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/hooks-client-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/hooks-client-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/i18n/detect-domain-locale.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/i18n/detect-domain-locale.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/i18n/normalize-locale-path.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/i18n/normalize-locale-path.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/image-blur-svg.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/image-blur-svg.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/image-config-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/image-config-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/image-config.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/image-config.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/image-external.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/image-external.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/image-loader.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/image-loader.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/lazy-dynamic/bailout-to-csr.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/lazy-dynamic/bailout-to-csr.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/match-remote-pattern.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/match-remote-pattern.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/add-locale.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/add-locale.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/add-path-prefix.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/add-path-prefix.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/app-paths.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/app-paths.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/format-url.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/format-url.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/index.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/index.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/interpolate-as.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/interpolate-as.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/is-dynamic.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/is-dynamic.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/is-local-url.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/is-local-url.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/omit.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/omit.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/parse-path.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/parse-path.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/path-has-prefix.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/path-has-prefix.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/querystring.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/querystring.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/route-matcher.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/route-matcher.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/route-regex.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/route-regex.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/sorted-routes.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router/utils/sorted-routes.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/router-context.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/router-context.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/segment.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/segment.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/server-inserted-html.shared-runtime.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/server-inserted-html.shared-runtime.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/side-effect.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/side-effect.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/utils/warn-once.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/utils/warn-once.mjs.map +0 -1
- package/dist/lib/node_modules/next/dist/shared/lib/utils.mjs +0 -2
- package/dist/lib/node_modules/next/dist/shared/lib/utils.mjs.map +0 -1
- package/dist/lib/node_modules/next/image.mjs +0 -2
- package/dist/lib/node_modules/next/image.mjs.map +0 -1
- package/dist/lib/node_modules/next/link.mjs +0 -2
- package/dist/lib/node_modules/next/link.mjs.map +0 -1
- package/dist/lib/node_modules/next/navigation.mjs +0 -2
- package/dist/lib/node_modules/next/navigation.mjs.map +0 -1
- package/dist/lib/node_modules/orderedmap/dist/index.mjs +0 -2
- package/dist/lib/node_modules/orderedmap/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/orderedmap/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/orderedmap/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-commands/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-commands/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-history/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-history/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-inputrules/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-inputrules/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-inputrules/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-inputrules/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-keymap/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-keymap/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-keymap/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-keymap/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-model/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-model/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-model/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-model/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-state/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-state/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-state/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-state/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-transform/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-transform/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-transform/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-transform/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-view/dist/index.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-view/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/prosemirror-view/dist/index2.mjs +0 -2
- package/dist/lib/node_modules/prosemirror-view/dist/index2.mjs.map +0 -1
- package/dist/lib/node_modules/rope-sequence/dist/index.mjs +0 -2
- package/dist/lib/node_modules/rope-sequence/dist/index.mjs.map +0 -1
- package/dist/lib/node_modules/tui-color-picker/dist/tui-color-picker.mjs +0 -10
- package/dist/lib/node_modules/tui-color-picker/dist/tui-color-picker.mjs.map +0 -1
- package/dist/lib/node_modules/w3c-keyname/index.mjs +0 -2
- package/dist/lib/node_modules/w3c-keyname/index.mjs.map +0 -1
- package/dist/lib/node_modules/w3c-keyname/index2.mjs +0 -2
- package/dist/lib/node_modules/w3c-keyname/index2.mjs.map +0 -1
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../node_modules/prosemirror-history/dist/index.js"],"sourcesContent":["import RopeSequence from 'rope-sequence';\nimport { Mapping } from 'prosemirror-transform';\nimport { PluginKey, Plugin } from 'prosemirror-state';\n\n// ProseMirror's history isn't simply a way to roll back to a previous\n// state, because ProseMirror supports applying changes without adding\n// them to the history (for example during collaboration).\n//\n// To this end, each 'Branch' (one for the undo history and one for\n// the redo history) keeps an array of 'Items', which can optionally\n// hold a step (an actual undoable change), and always hold a position\n// map (which is needed to move changes below them to apply to the\n// current document).\n//\n// An item that has both a step and a selection bookmark is the start\n// of an 'event' — a group of changes that will be undone or redone at\n// once. (It stores only the bookmark, since that way we don't have to\n// provide a document until the selection is actually applied, which\n// is useful when compressing.)\n// Used to schedule history compression\nconst max_empty_items = 500;\nclass Branch {\n constructor(items, eventCount) {\n this.items = items;\n this.eventCount = eventCount;\n }\n // Pop the latest event off the branch's history and apply it\n // to a document transform.\n popEvent(state, preserveItems) {\n if (this.eventCount == 0)\n return null;\n let end = this.items.length;\n for (;; end--) {\n let next = this.items.get(end - 1);\n if (next.selection) {\n --end;\n break;\n }\n }\n let remap, mapFrom;\n if (preserveItems) {\n remap = this.remapping(end, this.items.length);\n mapFrom = remap.maps.length;\n }\n let transform = state.tr;\n let selection, remaining;\n let addAfter = [], addBefore = [];\n this.items.forEach((item, i) => {\n if (!item.step) {\n if (!remap) {\n remap = this.remapping(end, i + 1);\n mapFrom = remap.maps.length;\n }\n mapFrom--;\n addBefore.push(item);\n return;\n }\n if (remap) {\n addBefore.push(new Item(item.map));\n let step = item.step.map(remap.slice(mapFrom)), map;\n if (step && transform.maybeStep(step).doc) {\n map = transform.mapping.maps[transform.mapping.maps.length - 1];\n addAfter.push(new Item(map, undefined, undefined, addAfter.length + addBefore.length));\n }\n mapFrom--;\n if (map)\n remap.appendMap(map, mapFrom);\n }\n else {\n transform.maybeStep(item.step);\n }\n if (item.selection) {\n selection = remap ? item.selection.map(remap.slice(mapFrom)) : item.selection;\n remaining = new Branch(this.items.slice(0, end).append(addBefore.reverse().concat(addAfter)), this.eventCount - 1);\n return false;\n }\n }, this.items.length, 0);\n return { remaining: remaining, transform, selection: selection };\n }\n // Create a new branch with the given transform added.\n addTransform(transform, selection, histOptions, preserveItems) {\n let newItems = [], eventCount = this.eventCount;\n let oldItems = this.items, lastItem = !preserveItems && oldItems.length ? oldItems.get(oldItems.length - 1) : null;\n for (let i = 0; i < transform.steps.length; i++) {\n let step = transform.steps[i].invert(transform.docs[i]);\n let item = new Item(transform.mapping.maps[i], step, selection), merged;\n if (merged = lastItem && lastItem.merge(item)) {\n item = merged;\n if (i)\n newItems.pop();\n else\n oldItems = oldItems.slice(0, oldItems.length - 1);\n }\n newItems.push(item);\n if (selection) {\n eventCount++;\n selection = undefined;\n }\n if (!preserveItems)\n lastItem = item;\n }\n let overflow = eventCount - histOptions.depth;\n if (overflow > DEPTH_OVERFLOW) {\n oldItems = cutOffEvents(oldItems, overflow);\n eventCount -= overflow;\n }\n return new Branch(oldItems.append(newItems), eventCount);\n }\n remapping(from, to) {\n let maps = new Mapping;\n this.items.forEach((item, i) => {\n let mirrorPos = item.mirrorOffset != null && i - item.mirrorOffset >= from\n ? maps.maps.length - item.mirrorOffset : undefined;\n maps.appendMap(item.map, mirrorPos);\n }, from, to);\n return maps;\n }\n addMaps(array) {\n if (this.eventCount == 0)\n return this;\n return new Branch(this.items.append(array.map(map => new Item(map))), this.eventCount);\n }\n // When the collab module receives remote changes, the history has\n // to know about those, so that it can adjust the steps that were\n // rebased on top of the remote changes, and include the position\n // maps for the remote changes in its array of items.\n rebased(rebasedTransform, rebasedCount) {\n if (!this.eventCount)\n return this;\n let rebasedItems = [], start = Math.max(0, this.items.length - rebasedCount);\n let mapping = rebasedTransform.mapping;\n let newUntil = rebasedTransform.steps.length;\n let eventCount = this.eventCount;\n this.items.forEach(item => { if (item.selection)\n eventCount--; }, start);\n let iRebased = rebasedCount;\n this.items.forEach(item => {\n let pos = mapping.getMirror(--iRebased);\n if (pos == null)\n return;\n newUntil = Math.min(newUntil, pos);\n let map = mapping.maps[pos];\n if (item.step) {\n let step = rebasedTransform.steps[pos].invert(rebasedTransform.docs[pos]);\n let selection = item.selection && item.selection.map(mapping.slice(iRebased + 1, pos));\n if (selection)\n eventCount++;\n rebasedItems.push(new Item(map, step, selection));\n }\n else {\n rebasedItems.push(new Item(map));\n }\n }, start);\n let newMaps = [];\n for (let i = rebasedCount; i < newUntil; i++)\n newMaps.push(new Item(mapping.maps[i]));\n let items = this.items.slice(0, start).append(newMaps).append(rebasedItems);\n let branch = new Branch(items, eventCount);\n if (branch.emptyItemCount() > max_empty_items)\n branch = branch.compress(this.items.length - rebasedItems.length);\n return branch;\n }\n emptyItemCount() {\n let count = 0;\n this.items.forEach(item => { if (!item.step)\n count++; });\n return count;\n }\n // Compressing a branch means rewriting it to push the air (map-only\n // items) out. During collaboration, these naturally accumulate\n // because each remote change adds one. The `upto` argument is used\n // to ensure that only the items below a given level are compressed,\n // because `rebased` relies on a clean, untouched set of items in\n // order to associate old items with rebased steps.\n compress(upto = this.items.length) {\n let remap = this.remapping(0, upto), mapFrom = remap.maps.length;\n let items = [], events = 0;\n this.items.forEach((item, i) => {\n if (i >= upto) {\n items.push(item);\n if (item.selection)\n events++;\n }\n else if (item.step) {\n let step = item.step.map(remap.slice(mapFrom)), map = step && step.getMap();\n mapFrom--;\n if (map)\n remap.appendMap(map, mapFrom);\n if (step) {\n let selection = item.selection && item.selection.map(remap.slice(mapFrom));\n if (selection)\n events++;\n let newItem = new Item(map.invert(), step, selection), merged, last = items.length - 1;\n if (merged = items.length && items[last].merge(newItem))\n items[last] = merged;\n else\n items.push(newItem);\n }\n }\n else if (item.map) {\n mapFrom--;\n }\n }, this.items.length, 0);\n return new Branch(RopeSequence.from(items.reverse()), events);\n }\n}\nBranch.empty = new Branch(RopeSequence.empty, 0);\nfunction cutOffEvents(items, n) {\n let cutPoint;\n items.forEach((item, i) => {\n if (item.selection && (n-- == 0)) {\n cutPoint = i;\n return false;\n }\n });\n return items.slice(cutPoint);\n}\nclass Item {\n constructor(\n // The (forward) step map for this item.\n map, \n // The inverted step\n step, \n // If this is non-null, this item is the start of a group, and\n // this selection is the starting selection for the group (the one\n // that was active before the first step was applied)\n selection, \n // If this item is the inverse of a previous mapping on the stack,\n // this points at the inverse's offset\n mirrorOffset) {\n this.map = map;\n this.step = step;\n this.selection = selection;\n this.mirrorOffset = mirrorOffset;\n }\n merge(other) {\n if (this.step && other.step && !other.selection) {\n let step = other.step.merge(this.step);\n if (step)\n return new Item(step.getMap().invert(), step, this.selection);\n }\n }\n}\n// The value of the state field that tracks undo/redo history for that\n// state. Will be stored in the plugin state when the history plugin\n// is active.\nclass HistoryState {\n constructor(done, undone, prevRanges, prevTime, prevComposition) {\n this.done = done;\n this.undone = undone;\n this.prevRanges = prevRanges;\n this.prevTime = prevTime;\n this.prevComposition = prevComposition;\n }\n}\nconst DEPTH_OVERFLOW = 20;\n// Record a transformation in undo history.\nfunction applyTransaction(history, state, tr, options) {\n let historyTr = tr.getMeta(historyKey), rebased;\n if (historyTr)\n return historyTr.historyState;\n if (tr.getMeta(closeHistoryKey))\n history = new HistoryState(history.done, history.undone, null, 0, -1);\n let appended = tr.getMeta(\"appendedTransaction\");\n if (tr.steps.length == 0) {\n return history;\n }\n else if (appended && appended.getMeta(historyKey)) {\n if (appended.getMeta(historyKey).redo)\n return new HistoryState(history.done.addTransform(tr, undefined, options, mustPreserveItems(state)), history.undone, rangesFor(tr.mapping.maps), history.prevTime, history.prevComposition);\n else\n return new HistoryState(history.done, history.undone.addTransform(tr, undefined, options, mustPreserveItems(state)), null, history.prevTime, history.prevComposition);\n }\n else if (tr.getMeta(\"addToHistory\") !== false && !(appended && appended.getMeta(\"addToHistory\") === false)) {\n // Group transforms that occur in quick succession into one event.\n let composition = tr.getMeta(\"composition\");\n let newGroup = history.prevTime == 0 ||\n (!appended && history.prevComposition != composition &&\n (history.prevTime < (tr.time || 0) - options.newGroupDelay || !isAdjacentTo(tr, history.prevRanges)));\n let prevRanges = appended ? mapRanges(history.prevRanges, tr.mapping) : rangesFor(tr.mapping.maps);\n return new HistoryState(history.done.addTransform(tr, newGroup ? state.selection.getBookmark() : undefined, options, mustPreserveItems(state)), Branch.empty, prevRanges, tr.time, composition == null ? history.prevComposition : composition);\n }\n else if (rebased = tr.getMeta(\"rebased\")) {\n // Used by the collab module to tell the history that some of its\n // content has been rebased.\n return new HistoryState(history.done.rebased(tr, rebased), history.undone.rebased(tr, rebased), mapRanges(history.prevRanges, tr.mapping), history.prevTime, history.prevComposition);\n }\n else {\n return new HistoryState(history.done.addMaps(tr.mapping.maps), history.undone.addMaps(tr.mapping.maps), mapRanges(history.prevRanges, tr.mapping), history.prevTime, history.prevComposition);\n }\n}\nfunction isAdjacentTo(transform, prevRanges) {\n if (!prevRanges)\n return false;\n if (!transform.docChanged)\n return true;\n let adjacent = false;\n transform.mapping.maps[0].forEach((start, end) => {\n for (let i = 0; i < prevRanges.length; i += 2)\n if (start <= prevRanges[i + 1] && end >= prevRanges[i])\n adjacent = true;\n });\n return adjacent;\n}\nfunction rangesFor(maps) {\n let result = [];\n for (let i = maps.length - 1; i >= 0 && result.length == 0; i--)\n maps[i].forEach((_from, _to, from, to) => result.push(from, to));\n return result;\n}\nfunction mapRanges(ranges, mapping) {\n if (!ranges)\n return null;\n let result = [];\n for (let i = 0; i < ranges.length; i += 2) {\n let from = mapping.map(ranges[i], 1), to = mapping.map(ranges[i + 1], -1);\n if (from <= to)\n result.push(from, to);\n }\n return result;\n}\n// Apply the latest event from one branch to the document and shift the event\n// onto the other branch.\nfunction histTransaction(history, state, redo) {\n let preserveItems = mustPreserveItems(state);\n let histOptions = historyKey.get(state).spec.config;\n let pop = (redo ? history.undone : history.done).popEvent(state, preserveItems);\n if (!pop)\n return null;\n let selection = pop.selection.resolve(pop.transform.doc);\n let added = (redo ? history.done : history.undone).addTransform(pop.transform, state.selection.getBookmark(), histOptions, preserveItems);\n let newHist = new HistoryState(redo ? added : pop.remaining, redo ? pop.remaining : added, null, 0, -1);\n return pop.transform.setSelection(selection).setMeta(historyKey, { redo, historyState: newHist });\n}\nlet cachedPreserveItems = false, cachedPreserveItemsPlugins = null;\n// Check whether any plugin in the given state has a\n// `historyPreserveItems` property in its spec, in which case we must\n// preserve steps exactly as they came in, so that they can be\n// rebased.\nfunction mustPreserveItems(state) {\n let plugins = state.plugins;\n if (cachedPreserveItemsPlugins != plugins) {\n cachedPreserveItems = false;\n cachedPreserveItemsPlugins = plugins;\n for (let i = 0; i < plugins.length; i++)\n if (plugins[i].spec.historyPreserveItems) {\n cachedPreserveItems = true;\n break;\n }\n }\n return cachedPreserveItems;\n}\n/**\nSet a flag on the given transaction that will prevent further steps\nfrom being appended to an existing history event (so that they\nrequire a separate undo command to undo).\n*/\nfunction closeHistory(tr) {\n return tr.setMeta(closeHistoryKey, true);\n}\nconst historyKey = new PluginKey(\"history\");\nconst closeHistoryKey = new PluginKey(\"closeHistory\");\n/**\nReturns a plugin that enables the undo history for an editor. The\nplugin will track undo and redo stacks, which can be used with the\n[`undo`](https://prosemirror.net/docs/ref/#history.undo) and [`redo`](https://prosemirror.net/docs/ref/#history.redo) commands.\n\nYou can set an `\"addToHistory\"` [metadata\nproperty](https://prosemirror.net/docs/ref/#state.Transaction.setMeta) of `false` on a transaction\nto prevent it from being rolled back by undo.\n*/\nfunction history(config = {}) {\n config = { depth: config.depth || 100,\n newGroupDelay: config.newGroupDelay || 500 };\n return new Plugin({\n key: historyKey,\n state: {\n init() {\n return new HistoryState(Branch.empty, Branch.empty, null, 0, -1);\n },\n apply(tr, hist, state) {\n return applyTransaction(hist, state, tr, config);\n }\n },\n config,\n props: {\n handleDOMEvents: {\n beforeinput(view, e) {\n let inputType = e.inputType;\n let command = inputType == \"historyUndo\" ? undo : inputType == \"historyRedo\" ? redo : null;\n if (!command)\n return false;\n e.preventDefault();\n return command(view.state, view.dispatch);\n }\n }\n }\n });\n}\nfunction buildCommand(redo, scroll) {\n return (state, dispatch) => {\n let hist = historyKey.getState(state);\n if (!hist || (redo ? hist.undone : hist.done).eventCount == 0)\n return false;\n if (dispatch) {\n let tr = histTransaction(hist, state, redo);\n if (tr)\n dispatch(scroll ? tr.scrollIntoView() : tr);\n }\n return true;\n };\n}\n/**\nA command function that undoes the last change, if any.\n*/\nconst undo = buildCommand(false, true);\n/**\nA command function that redoes the last undone change, if any.\n*/\nconst redo = buildCommand(true, true);\n/**\nA command function that undoes the last change. Don't scroll the\nselection into view.\n*/\nconst undoNoScroll = buildCommand(false, false);\n/**\nA command function that redoes the last undone change. Don't\nscroll the selection into view.\n*/\nconst redoNoScroll = buildCommand(true, false);\n/**\nThe amount of undoable events available in a given state.\n*/\nfunction undoDepth(state) {\n let hist = historyKey.getState(state);\n return hist ? hist.done.eventCount : 0;\n}\n/**\nThe amount of redoable events available in a given editor state.\n*/\nfunction redoDepth(state) {\n let hist = historyKey.getState(state);\n return hist ? hist.undone.eventCount : 0;\n}\n\nexport { closeHistory, history, redo, redoDepth, redoNoScroll, undo, undoDepth, undoNoScroll };\n"],"names":["Branch","constructor","items","eventCount","this","popEvent","state","preserveItems","remap","mapFrom","end","length","get","selection","remapping","maps","remaining","transform","tr","addAfter","addBefore","forEach","item","i","step","push","Item","map","slice","maybeStep","doc","mapping","undefined","appendMap","append","reverse","concat","addTransform","histOptions","newItems","oldItems","lastItem","steps","merged","invert","docs","merge","pop","overflow","depth","DEPTH_OVERFLOW","n","cutPoint","cutOffEvents","from","to","Mapping","mirrorPos","mirrorOffset","addMaps","array","rebased","rebasedTransform","rebasedCount","rebasedItems","start","Math","max","newUntil","iRebased","pos","getMirror","min","newMaps","branch","emptyItemCount","compress","count","upto","events","getMap","newItem","last","RopeSequence","empty","other","HistoryState","done","undone","prevRanges","prevTime","prevComposition","rangesFor","result","_from","_to","mapRanges","ranges","cachedPreserveItems","cachedPreserveItemsPlugins","mustPreserveItems","plugins","spec","historyPreserveItems","historyKey","PluginKey","closeHistoryKey","history","config","newGroupDelay","Plugin","key","init","apply","hist","options","historyTr","getMeta","historyState","appended","redo","composition","newGroup","time","docChanged","adjacent","isAdjacentTo","getBookmark","applyTransaction","props","handleDOMEvents","beforeinput","view","e","inputType","command","undo","preventDefault","dispatch","buildCommand","scroll","getState","resolve","added","newHist","setSelection","setMeta","histTransaction","scrollIntoView","undoDepth"],"mappings":"uMAqBA,MAAMA,EACF,WAAAC,CAAYC,EAAOC,GACfC,KAAKF,MAAQA,EACbE,KAAKD,WAAaA,CAC1B,CAGI,QAAAE,CAASC,EAAOC,GACZ,GAAuB,GAAnBH,KAAKD,WACL,OAAO,KACX,IAQIK,EAAOC,EARPC,EAAMN,KAAKF,MAAMS,OACrB,MAAQD,IAAO,CAEX,GADWN,KAAKF,MAAMU,IAAIF,EAAM,GACvBG,UAAW,GACdH,EACF,KAChB,CACA,CAEYH,IACAC,EAAQJ,KAAKU,UAAUJ,EAAKN,KAAKF,MAAMS,QACvCF,EAAUD,EAAMO,KAAKJ,QAEzB,IACIE,EAAWG,EADXC,EAAYX,EAAMY,GAElBC,EAAW,GAAIC,EAAY,GA+B/B,OA9BAhB,KAAKF,MAAMmB,SAAQ,CAACC,EAAMC,KACtB,IAAKD,EAAKE,KAON,OANKhB,IACDA,EAAQJ,KAAKU,UAAUJ,EAAKa,EAAI,GAChCd,EAAUD,EAAMO,KAAKJ,QAEzBF,SACAW,EAAUK,KAAKH,GAGnB,GAAId,EAAO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AOgG,KAAKM,OACzC7D,GAAOyE,EAAOb,EAAQnB,OAASmB,EAAQpB,MAAMlF,SAASC,EAAOC,GACjE,IAAKwC,EACD,OAAO,KACX,IAAIlC,EAAYkC,EAAIlC,UAAUiI,QAAQ/F,EAAI9B,UAAUa,KAChDiH,GAASvB,EAAOb,EAAQpB,KAAOoB,EAAQnB,QAAQnD,aAAaU,EAAI9B,UAAWX,EAAMO,UAAUkH,cAAezF,EAAa/B,GACvHyI,EAAU,IAAI1D,EAAakC,EAAOuB,EAAQhG,EAAI/B,UAAWwG,EAAOzE,EAAI/B,UAAY+H,EAAO,KAAM,GAAI,GACrG,OAAOhG,EAAI9B,UAAUgI,aAAapI,GAAWqI,QAAQ1C,EAAY,CAAEgB,OAAMF,aAAc0B,GAC3F,CAwEqBG,CAAgBjC,EAAM5G,EAAOkH,GAClCtG,GACAwH,EAASE,EAAS1H,EAAGkI,iBAAmBlI,EACxD,CACQ,OAAO,CAAI,CAEnB,CAIK,MAACsH,EAAOG,GAAa,GAAO,GAI3BnB,EAAOmB,GAAa,GAAM,GAchC,SAASU,EAAU/I,GACf,IAAI4G,EAAOV,EAAWqC,SAASvI,GAC/B,OAAO4G,EAAOA,EAAK3B,KAAKpF,WAAa,CACzC","x_google_ignoreList":[0]}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{__exports as e}from"../../../_virtual/index5.mjs";import{__require as t}from"../../prosemirror-state/dist/index.mjs";import{__require as n}from"../../prosemirror-transform/dist/index2.mjs";var r;function o(){if(r)return e;r=1;var o,i=t(),s=n(),u=(o=function e(t,n){var r,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.match=t,this.match=t,this.handler="string"==typeof n?(r=n,function(e,t,n,o){var i=r;if(t[1]){var s=t[0].lastIndexOf(t[1]);i+=t[0].slice(s+t[1].length);var u=(n+=s)-o;u>0&&(i=t[0].slice(s-u,s)+i,n=o)}return e.tr.insertText(i,n,o)}):n,this.undoable=!1!==o.undoable,this.inCode=o.inCode||!1},Object.defineProperty(o,"prototype",{writable:!1}),o);var a=500;function l(e,t,n,r,o,i){if(e.composing)return!1;for(var s=e.state,u=s.doc.resolve(t),l=u.parent.textBetween(Math.max(0,u.parentOffset-a),u.parentOffset,null,"")+r,c=0;c<o.length;c++){var f=o[c];if(u.parent.type.spec.code){if(!f.inCode)continue}else if("only"===f.inCode)continue;var p=f.match.exec(l),d=p&&f.handler(s,p,t-(p[0].length-r.length),n);if(d)return f.undoable&&d.setMeta(i,{transform:d,from:t,to:n,text:r}),e.dispatch(d),!0}return!1}var c=new u(/--$/,"—"),f=new u(/\.\.\.$/,"…"),p=new u(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(")$/,"“"),d=new u(/"$/,"”"),v=new u(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(')$/,"‘"),h=new u(/'$/,"’"),m=[p,d,v,h];return e.InputRule=u,e.closeDoubleQuote=d,e.closeSingleQuote=h,e.ellipsis=f,e.emDash=c,e.inputRules=function(e){var t=e.rules,n=new i.Plugin({state:{init:function(){return null},apply:function(e,t){var n=e.getMeta(this);return n||(e.selectionSet||e.docChanged?null:t)}},props:{handleTextInput:function(e,r,o,i){return l(e,r,o,i,t,n)},handleDOMEvents:{compositionend:function(e){setTimeout((function(){var r=e.state.selection.$cursor;r&&l(e,r.pos,r.pos,"",t,n)}))}}},isInputRules:!0});return n},e.openDoubleQuote=p,e.openSingleQuote=v,e.smartQuotes=m,e.textblockTypeInputRule=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return new u(e,(function(e,r,o,i){var s=e.doc.resolve(o),u=n instanceof Function?n(r):n;return s.node(-1).canReplaceWith(s.index(-1),s.indexAfter(-1),t)?e.tr.delete(o,i).setBlockType(o,o,t,u):null}))},e.undoInputRule=function(e,t){for(var n=e.plugins,r=0;r<n.length;r++){var o=n[r],i=void 0;if(o.spec.isInputRules&&(i=o.getState(e))){if(t){for(var s=e.tr,u=i.transform,a=u.steps.length-1;a>=0;a--)s.step(u.steps[a].invert(u.docs[a]));if(i.text){var l=s.doc.resolve(i.from).marks();s.replaceWith(i.from,i.to,e.schema.text(i.text,l))}else s.delete(i.from,i.to);t(s)}return!0}}return!1},e.wrappingInputRule=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3?arguments[3]:void 0;return new u(e,(function(e,o,i,u){var a=n instanceof Function?n(o):n,l=e.tr.delete(i,u),c=l.doc.resolve(i).blockRange(),f=c&&s.findWrapping(c,t,a);if(!f)return null;l.wrap(c,f);var p=l.doc.resolve(i-1).nodeBefore;return p&&p.type==t&&s.canJoin(l.doc,i-1)&&(!r||r(o,p))&&l.join(i-1),l}))},e}export{o as __require};
|
2
|
-
//# sourceMappingURL=index.mjs.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../node_modules/prosemirror-inputrules/dist/index.cjs"],"sourcesContent":["'use strict';\n\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }\nfunction _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, \"prototype\", { writable: false }); return Constructor; }\nfunction _toPropertyKey(arg) { var key = _toPrimitive(arg, \"string\"); return _typeof(key) === \"symbol\" ? key : String(key); }\nfunction _toPrimitive(input, hint) { if (_typeof(input) !== \"object\" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || \"default\"); if (_typeof(res) !== \"object\") return res; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (hint === \"string\" ? String : Number)(input); }\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\nvar prosemirrorState = require('prosemirror-state');\nvar prosemirrorTransform = require('prosemirror-transform');\nvar InputRule = _createClass(function InputRule(match, handler) {\n var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};\n _classCallCheck(this, InputRule);\n this.match = match;\n this.match = match;\n this.handler = typeof handler == \"string\" ? stringHandler(handler) : handler;\n this.undoable = options.undoable !== false;\n this.inCode = options.inCode || false;\n});\nfunction stringHandler(string) {\n return function (state, match, start, end) {\n var insert = string;\n if (match[1]) {\n var offset = match[0].lastIndexOf(match[1]);\n insert += match[0].slice(offset + match[1].length);\n start += offset;\n var cutOff = start - end;\n if (cutOff > 0) {\n insert = match[0].slice(offset - cutOff, offset) + insert;\n start = end;\n }\n }\n return state.tr.insertText(insert, start, end);\n };\n}\nvar MAX_MATCH = 500;\nfunction inputRules(_ref) {\n var rules = _ref.rules;\n var plugin = new prosemirrorState.Plugin({\n state: {\n init: function init() {\n return null;\n },\n apply: function apply(tr, prev) {\n var stored = tr.getMeta(this);\n if (stored) return stored;\n return tr.selectionSet || tr.docChanged ? null : prev;\n }\n },\n props: {\n handleTextInput: function handleTextInput(view, from, to, text) {\n return run(view, from, to, text, rules, plugin);\n },\n handleDOMEvents: {\n compositionend: function compositionend(view) {\n setTimeout(function () {\n var $cursor = view.state.selection.$cursor;\n if ($cursor) run(view, $cursor.pos, $cursor.pos, \"\", rules, plugin);\n });\n }\n }\n },\n isInputRules: true\n });\n return plugin;\n}\nfunction run(view, from, to, text, rules, plugin) {\n if (view.composing) return false;\n var state = view.state,\n $from = state.doc.resolve(from);\n var textBefore = $from.parent.textBetween(Math.max(0, $from.parentOffset - MAX_MATCH), $from.parentOffset, null, \"\\uFFFC\") + text;\n for (var i = 0; i < rules.length; i++) {\n var rule = rules[i];\n if ($from.parent.type.spec.code) {\n if (!rule.inCode) continue;\n } else if (rule.inCode === \"only\") {\n continue;\n }\n var match = rule.match.exec(textBefore);\n var tr = match && rule.handler(state, match, from - (match[0].length - text.length), to);\n if (!tr) continue;\n if (rule.undoable) tr.setMeta(plugin, {\n transform: tr,\n from: from,\n to: to,\n text: text\n });\n view.dispatch(tr);\n return true;\n }\n return false;\n}\nvar undoInputRule = function undoInputRule(state, dispatch) {\n var plugins = state.plugins;\n for (var i = 0; i < plugins.length; i++) {\n var plugin = plugins[i],\n undoable = void 0;\n if (plugin.spec.isInputRules && (undoable = plugin.getState(state))) {\n if (dispatch) {\n var tr = state.tr,\n toUndo = undoable.transform;\n for (var j = toUndo.steps.length - 1; j >= 0; j--) tr.step(toUndo.steps[j].invert(toUndo.docs[j]));\n if (undoable.text) {\n var marks = tr.doc.resolve(undoable.from).marks();\n tr.replaceWith(undoable.from, undoable.to, state.schema.text(undoable.text, marks));\n } else {\n tr[\"delete\"](undoable.from, undoable.to);\n }\n dispatch(tr);\n }\n return true;\n }\n }\n return false;\n};\nvar emDash = new InputRule(/--$/, \"—\");\nvar ellipsis = new InputRule(/\\.\\.\\.$/, \"…\");\nvar openDoubleQuote = new InputRule(/(?:^|[\\s\\{\\[\\(\\<'\"\\u2018\\u201C])(\")$/, \"“\");\nvar closeDoubleQuote = new InputRule(/\"$/, \"”\");\nvar openSingleQuote = new InputRule(/(?:^|[\\s\\{\\[\\(\\<'\"\\u2018\\u201C])(')$/, \"‘\");\nvar closeSingleQuote = new InputRule(/'$/, \"’\");\nvar smartQuotes = [openDoubleQuote, closeDoubleQuote, openSingleQuote, closeSingleQuote];\nfunction wrappingInputRule(regexp, nodeType) {\n var getAttrs = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n var joinPredicate = arguments.length > 3 ? arguments[3] : undefined;\n return new InputRule(regexp, function (state, match, start, end) {\n var attrs = getAttrs instanceof Function ? getAttrs(match) : getAttrs;\n var tr = state.tr[\"delete\"](start, end);\n var $start = tr.doc.resolve(start),\n range = $start.blockRange(),\n wrapping = range && prosemirrorTransform.findWrapping(range, nodeType, attrs);\n if (!wrapping) return null;\n tr.wrap(range, wrapping);\n var before = tr.doc.resolve(start - 1).nodeBefore;\n if (before && before.type == nodeType && prosemirrorTransform.canJoin(tr.doc, start - 1) && (!joinPredicate || joinPredicate(match, before))) tr.join(start - 1);\n return tr;\n });\n}\nfunction textblockTypeInputRule(regexp, nodeType) {\n var getAttrs = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n return new InputRule(regexp, function (state, match, start, end) {\n var $start = state.doc.resolve(start);\n var attrs = getAttrs instanceof Function ? getAttrs(match) : getAttrs;\n if (!$start.node(-1).canReplaceWith($start.index(-1), $start.indexAfter(-1), nodeType)) return null;\n return state.tr[\"delete\"](start, end).setBlockType(start, start, nodeType, attrs);\n });\n}\nexports.InputRule = InputRule;\nexports.closeDoubleQuote = closeDoubleQuote;\nexports.closeSingleQuote = closeSingleQuote;\nexports.ellipsis = ellipsis;\nexports.emDash = emDash;\nexports.inputRules = inputRules;\nexports.openDoubleQuote = openDoubleQuote;\nexports.openSingleQuote = openSingleQuote;\nexports.smartQuotes = smartQuotes;\nexports.textblockTypeInputRule = textblockTypeInputRule;\nexports.undoInputRule = undoInputRule;\nexports.wrappingInputRule = wrappingInputRule;\n"],"names":["Constructor","prosemirrorState","require$$0","prosemirrorTransform","require$$1","InputRule","match","handler","string","options","arguments","length","undefined","instance","TypeError","_classCallCheck","this","state","start","end","insert","offset","lastIndexOf","slice","cutOff","tr","insertText","undoable","inCode","Object","defineProperty","writable","MAX_MATCH","run","view","from","to","text","rules","plugin","composing","$from","doc","resolve","textBefore","parent","textBetween","Math","max","parentOffset","i","rule","type","spec","code","exec","setMeta","transform","dispatch","emDash","ellipsis","openDoubleQuote","closeDoubleQuote","openSingleQuote","closeSingleQuote","smartQuotes","dist","inputRules","_ref","Plugin","init","apply","prev","stored","getMeta","selectionSet","docChanged","props","handleTextInput","handleDOMEvents","compositionend","setTimeout","$cursor","selection","pos","isInputRules","textblockTypeInputRule","regexp","nodeType","getAttrs","$start","attrs","Function","node","canReplaceWith","index","indexAfter","setBlockType","undoInputRule","plugins","getState","toUndo","j","steps","step","invert","docs","marks","replaceWith","schema","wrappingInputRule","joinPredicate","range","blockRange","wrapping","findWrapping","wrap","before","nodeBefore","canJoin","join"],"mappings":"yOAQA,IAJsBA,EAIlBC,EAA+CC,IAC/CC,EAAuDC,IACvDC,GANkBL,EAMO,SAASK,EAAUC,EAAOC,GACrD,IAQqBC,EARjBC,EAAUC,UAAUC,OAAS,QAAsBC,IAAjBF,UAAU,GAAmBA,UAAU,GAAK,CAAE,GAJtF,SAAyBG,EAAUb,GAAe,KAAMa,aAAoBb,GAAgB,MAAM,IAAIc,UAAU,oCAAuC,CAKrJC,CAAgBC,KAAMX,GACtBW,KAAKV,MAAQA,EACbU,KAAKV,MAAQA,EACbU,KAAKT,QAA4B,iBAAXA,GAIDC,EAJqCD,EAKnD,SAAUU,EAAOX,EAAOY,EAAOC,GACpC,IAAIC,EAASZ,EACb,GAAIF,EAAM,GAAI,CACZ,IAAIe,EAASf,EAAM,GAAGgB,YAAYhB,EAAM,IACxCc,GAAUd,EAAM,GAAGiB,MAAMF,EAASf,EAAM,GAAGK,QAE3C,IAAIa,GADJN,GAASG,GACYF,EACjBK,EAAS,IACXJ,EAASd,EAAM,GAAGiB,MAAMF,EAASG,EAAQH,GAAUD,EACnDF,EAAQC,EAEhB,CACI,OAAOF,EAAMQ,GAAGC,WAAWN,EAAQF,EAAOC,EAC3C,GAlBoEZ,EACrES,KAAKW,UAAgC,IAArBlB,EAAQkB,SACxBX,KAAKY,OAASnB,EAAQmB,SAAU,CAClC,EAdkMC,OAAOC,eAAe9B,EAAa,YAAa,CAAE+B,UAAU,IAAiB/B,GA+B/Q,IAAIg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,EAAGiB,IAAKxB,EAAQ,MAAQ6F,GAAiBA,EAAczG,EAAO+G,KAAU5F,EAAG+F,KAAKtG,EAAQ,GACvJO,CACX,GACA","x_google_ignoreList":[0]}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{Plugin as e}from"../../prosemirror-state/dist/index2.mjs";class t{constructor(e,t,n={}){var s;this.match=e,this.match=e,this.handler="string"==typeof t?(s=t,function(e,t,n,r){let o=s;if(t[1]){let e=t[0].lastIndexOf(t[1]);o+=t[0].slice(e+t[1].length);let s=(n+=e)-r;s>0&&(o=t[0].slice(e-s,e)+o,n=r)}return e.tr.insertText(o,n,r)}):t,this.undoable=!1!==n.undoable,this.inCode=n.inCode||!1}}const n=500;function s({rules:t}){let n=new e({state:{init:()=>null,apply(e,t){let n=e.getMeta(this);return n||(e.selectionSet||e.docChanged?null:t)}},props:{handleTextInput:(e,s,o,l)=>r(e,s,o,l,t,n),handleDOMEvents:{compositionend:e=>{setTimeout((()=>{let{$cursor:s}=e.state.selection;s&&r(e,s.pos,s.pos,"",t,n)}))}}},isInputRules:!0});return n}function r(e,t,s,r,o,l){if(e.composing)return!1;let i=e.state,a=i.doc.resolve(t),u=a.parent.textBetween(Math.max(0,a.parentOffset-n),a.parentOffset,null,"")+r;for(let n=0;n<o.length;n++){let c=o[n];if(a.parent.type.spec.code){if(!c.inCode)continue}else if("only"===c.inCode)continue;let f=c.match.exec(u),p=f&&c.handler(i,f,t-(f[0].length-r.length),s);if(p)return c.undoable&&p.setMeta(l,{transform:p,from:t,to:s,text:r}),e.dispatch(p),!0}return!1}const o=(e,t)=>{let n=e.plugins;for(let s=0;s<n.length;s++){let r,o=n[s];if(o.spec.isInputRules&&(r=o.getState(e))){if(t){let n=e.tr,s=r.transform;for(let e=s.steps.length-1;e>=0;e--)n.step(s.steps[e].invert(s.docs[e]));if(r.text){let t=n.doc.resolve(r.from).marks();n.replaceWith(r.from,r.to,e.schema.text(r.text,t))}else n.delete(r.from,r.to);t(n)}return!0}}return!1};new t(/--$/,"—"),new t(/\.\.\.$/,"…"),new t(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(")$/,"“"),new t(/"$/,"”"),new t(/(?:^|[\s\{\[\(\<'"\u2018\u201C])(')$/,"‘"),new t(/'$/,"’");export{t as InputRule,s as inputRules,o as undoInputRule};
|
2
|
-
//# sourceMappingURL=index2.mjs.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index2.mjs","sources":["../../../../../node_modules/prosemirror-inputrules/dist/index.js"],"sourcesContent":["import { Plugin } from 'prosemirror-state';\nimport { findWrapping, canJoin } from 'prosemirror-transform';\n\n/**\nInput rules are regular expressions describing a piece of text\nthat, when typed, causes something to happen. This might be\nchanging two dashes into an emdash, wrapping a paragraph starting\nwith `\"> \"` into a blockquote, or something entirely different.\n*/\nclass InputRule {\n // :: (RegExp, union<string, (state: EditorState, match: [string], start: number, end: number) → ?Transaction>)\n /**\n Create an input rule. The rule applies when the user typed\n something and the text directly in front of the cursor matches\n `match`, which should end with `$`.\n \n The `handler` can be a string, in which case the matched text, or\n the first matched group in the regexp, is replaced by that\n string.\n \n Or a it can be a function, which will be called with the match\n array produced by\n [`RegExp.exec`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp/exec),\n as well as the start and end of the matched range, and which can\n return a [transaction](https://prosemirror.net/docs/ref/#state.Transaction) that describes the\n rule's effect, or null to indicate the input was not handled.\n */\n constructor(\n /**\n @internal\n */\n match, handler, options = {}) {\n this.match = match;\n this.match = match;\n this.handler = typeof handler == \"string\" ? stringHandler(handler) : handler;\n this.undoable = options.undoable !== false;\n this.inCode = options.inCode || false;\n }\n}\nfunction stringHandler(string) {\n return function (state, match, start, end) {\n let insert = string;\n if (match[1]) {\n let offset = match[0].lastIndexOf(match[1]);\n insert += match[0].slice(offset + match[1].length);\n start += offset;\n let cutOff = start - end;\n if (cutOff > 0) {\n insert = match[0].slice(offset - cutOff, offset) + insert;\n start = end;\n }\n }\n return state.tr.insertText(insert, start, end);\n };\n}\nconst MAX_MATCH = 500;\n/**\nCreate an input rules plugin. When enabled, it will cause text\ninput that matches any of the given rules to trigger the rule's\naction.\n*/\nfunction inputRules({ rules }) {\n let plugin = new Plugin({\n state: {\n init() { return null; },\n apply(tr, prev) {\n let stored = tr.getMeta(this);\n if (stored)\n return stored;\n return tr.selectionSet || tr.docChanged ? null : prev;\n }\n },\n props: {\n handleTextInput(view, from, to, text) {\n return run(view, from, to, text, rules, plugin);\n },\n handleDOMEvents: {\n compositionend: (view) => {\n setTimeout(() => {\n let { $cursor } = view.state.selection;\n if ($cursor)\n run(view, $cursor.pos, $cursor.pos, \"\", rules, plugin);\n });\n }\n }\n },\n isInputRules: true\n });\n return plugin;\n}\nfunction run(view, from, to, text, rules, plugin) {\n if (view.composing)\n return false;\n let state = view.state, $from = state.doc.resolve(from);\n let textBefore = $from.parent.textBetween(Math.max(0, $from.parentOffset - MAX_MATCH), $from.parentOffset, null, \"\\ufffc\") + text;\n for (let i = 0; i < rules.length; i++) {\n let rule = rules[i];\n if ($from.parent.type.spec.code) {\n if (!rule.inCode)\n continue;\n }\n else if (rule.inCode === \"only\") {\n continue;\n }\n let match = rule.match.exec(textBefore);\n let tr = match && rule.handler(state, match, from - (match[0].length - text.length), to);\n if (!tr)\n continue;\n if (rule.undoable)\n tr.setMeta(plugin, { transform: tr, from, to, text });\n view.dispatch(tr);\n return true;\n }\n return false;\n}\n/**\nThis is a command that will undo an input rule, if applying such a\nrule was the last thing that the user did.\n*/\nconst undoInputRule = (state, dispatch) => {\n let plugins = state.plugins;\n for (let i = 0; i < plugins.length; i++) {\n let plugin = plugins[i], undoable;\n if (plugin.spec.isInputRules && (undoable = plugin.getState(state))) {\n if (dispatch) {\n let tr = state.tr, toUndo = undoable.transform;\n for (let j = toUndo.steps.length - 1; j >= 0; j--)\n tr.step(toUndo.steps[j].invert(toUndo.docs[j]));\n if (undoable.text) {\n let marks = tr.doc.resolve(undoable.from).marks();\n tr.replaceWith(undoable.from, undoable.to, state.schema.text(undoable.text, marks));\n }\n else {\n tr.delete(undoable.from, undoable.to);\n }\n dispatch(tr);\n }\n return true;\n }\n }\n return false;\n};\n\n/**\nConverts double dashes to an emdash.\n*/\nconst emDash = new InputRule(/--$/, \"—\");\n/**\nConverts three dots to an ellipsis character.\n*/\nconst ellipsis = new InputRule(/\\.\\.\\.$/, \"…\");\n/**\n“Smart” opening double quotes.\n*/\nconst openDoubleQuote = new InputRule(/(?:^|[\\s\\{\\[\\(\\<'\"\\u2018\\u201C])(\")$/, \"“\");\n/**\n“Smart” closing double quotes.\n*/\nconst closeDoubleQuote = new InputRule(/\"$/, \"”\");\n/**\n“Smart” opening single quotes.\n*/\nconst openSingleQuote = new InputRule(/(?:^|[\\s\\{\\[\\(\\<'\"\\u2018\\u201C])(')$/, \"‘\");\n/**\n“Smart” closing single quotes.\n*/\nconst closeSingleQuote = new InputRule(/'$/, \"’\");\n/**\nSmart-quote related input rules.\n*/\nconst smartQuotes = [openDoubleQuote, closeDoubleQuote, openSingleQuote, closeSingleQuote];\n\n/**\nBuild an input rule for automatically wrapping a textblock when a\ngiven string is typed. The `regexp` argument is\ndirectly passed through to the `InputRule` constructor. You'll\nprobably want the regexp to start with `^`, so that the pattern can\nonly occur at the start of a textblock.\n\n`nodeType` is the type of node to wrap in. If it needs attributes,\nyou can either pass them directly, or pass a function that will\ncompute them from the regular expression match.\n\nBy default, if there's a node with the same type above the newly\nwrapped node, the rule will try to [join](https://prosemirror.net/docs/ref/#transform.Transform.join) those\ntwo nodes. You can pass a join predicate, which takes a regular\nexpression match and the node before the wrapped node, and can\nreturn a boolean to indicate whether a join should happen.\n*/\nfunction wrappingInputRule(regexp, nodeType, getAttrs = null, joinPredicate) {\n return new InputRule(regexp, (state, match, start, end) => {\n let attrs = getAttrs instanceof Function ? getAttrs(match) : getAttrs;\n let tr = state.tr.delete(start, end);\n let $start = tr.doc.resolve(start), range = $start.blockRange(), wrapping = range && findWrapping(range, nodeType, attrs);\n if (!wrapping)\n return null;\n tr.wrap(range, wrapping);\n let before = tr.doc.resolve(start - 1).nodeBefore;\n if (before && before.type == nodeType && canJoin(tr.doc, start - 1) &&\n (!joinPredicate || joinPredicate(match, before)))\n tr.join(start - 1);\n return tr;\n });\n}\n/**\nBuild an input rule that changes the type of a textblock when the\nmatched text is typed into it. You'll usually want to start your\nregexp with `^` to that it is only matched at the start of a\ntextblock. The optional `getAttrs` parameter can be used to compute\nthe new node's attributes, and works the same as in the\n`wrappingInputRule` function.\n*/\nfunction textblockTypeInputRule(regexp, nodeType, getAttrs = null) {\n return new InputRule(regexp, (state, match, start, end) => {\n let $start = state.doc.resolve(start);\n let attrs = getAttrs instanceof Function ? getAttrs(match) : getAttrs;\n if (!$start.node(-1).canReplaceWith($start.index(-1), $start.indexAfter(-1), nodeType))\n return null;\n return state.tr\n .delete(start, end)\n .setBlockType(start, start, nodeType, attrs);\n });\n}\n\nexport { InputRule, closeDoubleQuote, closeSingleQuote, ellipsis, emDash, inputRules, openDoubleQuote, openSingleQuote, smartQuotes, textblockTypeInputRule, undoInputRule, wrappingInputRule };\n"],"names":["InputRule","constructor","match","handler","options","string","this","state","start","end","insert","offset","lastIndexOf","slice","length","cutOff","tr","insertText","undoable","inCode","MAX_MATCH","inputRules","rules","plugin","Plugin","init","apply","prev","stored","getMeta","selectionSet","docChanged","props","handleTextInput","view","from","to","text","run","handleDOMEvents","compositionend","setTimeout","$cursor","selection","pos","isInputRules","composing","$from","doc","resolve","textBefore","parent","textBetween","Math","max","parentOffset","i","rule","type","spec","code","exec","setMeta","transform","dispatch","undoInputRule","plugins","getState","toUndo","j","steps","step","invert","docs","marks","replaceWith","schema","delete"],"mappings":"iEASA,MAAMA,EAkBF,WAAAC,CAIAC,EAAOC,EAASC,EAAU,IAQ9B,IAAuBC,EAPfC,KAAKJ,MAAQA,EACbI,KAAKJ,MAAQA,EACbI,KAAKH,QAA4B,iBAAXA,GAKPE,EAL2CF,EAMvD,SAAUI,EAAOL,EAAO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CACY,OAAO,CACnB,CACA,CACI,OAAO,CAAK,EAMD,IAAIhB,EAAU,MAAO,KAInB,IAAIA,EAAU,UAAW,KAIlB,IAAIA,EAAU,uCAAwC,KAIrD,IAAIA,EAAU,KAAM,KAIrB,IAAIA,EAAU,uCAAwC,KAIrD,IAAIA,EAAU,KAAM","x_google_ignoreList":[0]}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{__exports as e}from"../../../_virtual/index2.mjs";import{__require as t}from"../../w3c-keyname/index.mjs";import{__require as r}from"../../prosemirror-state/dist/index.mjs";var i;function n(){if(i)return e;i=1,Object.defineProperty(e,"__esModule",{value:!0});var n=t(),a=r(),o="undefined"!=typeof navigator&&/Mac|iP(hone|[oa]d)/.test(navigator.platform);function f(e){var t,r,i,n,a=e.split(/-(?!$)/),f=a[a.length-1];"Space"==f&&(f=" ");for(var s=0;s<a.length-1;s++){var l=a[s];if(/^(cmd|meta|m)$/i.test(l))n=!0;else if(/^a(lt)?$/i.test(l))t=!0;else if(/^(c|ctrl|control)$/i.test(l))r=!0;else if(/^s(hift)?$/i.test(l))i=!0;else{if(!/^mod$/i.test(l))throw new Error("Unrecognized modifier name: "+l);o?n=!0:r=!0}}return t&&(f="Alt-"+f),r&&(f="Ctrl-"+f),n&&(f="Meta-"+f),i&&(f="Shift-"+f),f}function s(e,t){var r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return t.altKey&&(e="Alt-"+e),t.ctrlKey&&(e="Ctrl-"+e),t.metaKey&&(e="Meta-"+e),r&&t.shiftKey&&(e="Shift-"+e),e}function l(e){var t=function(e){var t=Object.create(null);for(var r in e)t[f(r)]=e[r];return t}(e);return function(e,r){var i,a=n.keyName(r),o=t[s(a,r)];if(o&&o(e.state,e.dispatch,e))return!0;if(1==a.length&&" "!=a){if(r.shiftKey){var f=t[s(a,r,!1)];if(f&&f(e.state,e.dispatch,e))return!0}if((r.shiftKey||r.altKey||r.metaKey||a.charCodeAt(0)>127)&&(i=n.base[r.keyCode])&&i!=a){var l=t[s(i,r)];if(l&&l(e.state,e.dispatch,e))return!0}}return!1}}return e.keydownHandler=l,e.keymap=function(e){return new a.Plugin({props:{handleKeyDown:l(e)}})},e}export{n as __require};
|
2
|
-
//# sourceMappingURL=index.mjs.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../node_modules/prosemirror-keymap/dist/index.cjs"],"sourcesContent":["'use strict';\n\nObject.defineProperty(exports, '__esModule', {\n value: true\n});\n\nvar w3cKeyname = require('w3c-keyname');\n\nvar prosemirrorState = require('prosemirror-state');\n\nvar mac = typeof navigator != \"undefined\" ? /Mac|iP(hone|[oa]d)/.test(navigator.platform) : false;\n\nfunction normalizeKeyName(name) {\n var parts = name.split(/-(?!$)/),\n result = parts[parts.length - 1];\n if (result == \"Space\") result = \" \";\n var alt, ctrl, shift, meta;\n\n for (var i = 0; i < parts.length - 1; i++) {\n var mod = parts[i];\n if (/^(cmd|meta|m)$/i.test(mod)) meta = true;else if (/^a(lt)?$/i.test(mod)) alt = true;else if (/^(c|ctrl|control)$/i.test(mod)) ctrl = true;else if (/^s(hift)?$/i.test(mod)) shift = true;else if (/^mod$/i.test(mod)) {\n if (mac) meta = true;else ctrl = true;\n } else throw new Error(\"Unrecognized modifier name: \" + mod);\n }\n\n if (alt) result = \"Alt-\" + result;\n if (ctrl) result = \"Ctrl-\" + result;\n if (meta) result = \"Meta-\" + result;\n if (shift) result = \"Shift-\" + result;\n return result;\n}\n\nfunction normalize(map) {\n var copy = Object.create(null);\n\n for (var prop in map) {\n copy[normalizeKeyName(prop)] = map[prop];\n }\n\n return copy;\n}\n\nfunction modifiers(name, event) {\n var shift = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;\n if (event.altKey) name = \"Alt-\" + name;\n if (event.ctrlKey) name = \"Ctrl-\" + name;\n if (event.metaKey) name = \"Meta-\" + name;\n if (shift && event.shiftKey) name = \"Shift-\" + name;\n return name;\n}\n\nfunction keymap(bindings) {\n return new prosemirrorState.Plugin({\n props: {\n handleKeyDown: keydownHandler(bindings)\n }\n });\n}\n\nfunction keydownHandler(bindings) {\n var map = normalize(bindings);\n return function (view, event) {\n var name = w3cKeyname.keyName(event),\n baseName,\n direct = map[modifiers(name, event)];\n if (direct && direct(view.state, view.dispatch, view)) return true;\n\n if (name.length == 1 && name != \" \") {\n if (event.shiftKey) {\n var noShift = map[modifiers(name, event, false)];\n if (noShift && noShift(view.state, view.dispatch, view)) return true;\n }\n\n if ((event.shiftKey || event.altKey || event.metaKey || name.charCodeAt(0) > 127) && (baseName = w3cKeyname.base[event.keyCode]) && baseName != name) {\n var fromCode = map[modifiers(baseName, event)];\n if (fromCode && fromCode(view.state, view.dispatch, view)) return true;\n }\n }\n\n return false;\n };\n}\n\nexports.keydownHandler = keydownHandler;\nexports.keymap = keymap;\n"],"names":["Object","defineProperty","dist","value","w3cKeyname","require$$0","prosemirrorState","require$$1","mac","navigator","test","platform","normalizeKeyName","name","alt","ctrl","shift","meta","parts","split","result","length","i","mod","Error","modifiers","event","arguments","undefined","altKey","ctrlKey","metaKey","shiftKey","keydownHandler","bindings","map","copy","create","prop","normalize","view","baseName","keyName","direct","state","dispatch","noShift","charCodeAt","base","keyCode","fromCode","keymap","Plugin","props","handleKeyDown"],"mappings":"yNAEAA,OAAOC,eAAeC,EAAS,aAAc,CAC3CC,OAAO,IAGT,IAAIC,EAAaC,IAEbC,EAA+CC,IAE/CC,EAA0B,oBAAbC,WAA2B,qBAAqBC,KAAKD,UAAUE,UAEhF,SAASC,EAAiBC,GACxB,IAGIC,EAAKC,EAAMC,EAAOC,EAHlBC,EAAQL,EAAKM,MAAM,UACnBC,EAASF,EAAMA,EAAMG,OAAS,GACpB,SAAVD,IAAmBA,EAAS,KAGhC,IAAK,IAAIE,EAAI,EAAGA,EAAIJ,EAAMG,OAAS,EAAGC,IAAK,CACzC,IAAIC,EAAML,EAAMI,GAChB,GAAI,kBAAkBZ,KAAKa,GAAMN,GAAO,OAAU,GAAI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AWlB,EAAKkC,WAAW,GAAK,OAASN,EAAWrC,EAAW4C,KAAKtB,EAAMuB,WAAaR,GAAY5B,EAAM,CACpJ,IAAIqC,EAAWf,EAAIV,EAAUgB,EAAUf,IACvC,GAAIwB,GAAYA,EAASV,EAAKI,MAAOJ,EAAKK,SAAUL,GAAO,OAAO,CAC1E,CACA,CAEI,OAAO,CACR,CACH,QAEAtC,EAAA+B,eAAyBA,EACzB/B,EAAAiD,OAjCA,SAAgBjB,GACd,OAAO,IAAI5B,EAAiB8C,OAAO,CACjCC,MAAO,CACLC,cAAerB,EAAeC,KAGpC","x_google_ignoreList":[0]}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{keyName as t,base as e}from"../../w3c-keyname/index2.mjs";import{Plugin as i}from"../../prosemirror-state/dist/index2.mjs";const r="undefined"!=typeof navigator&&/Mac|iP(hone|[oa]d)/.test(navigator.platform);function n(t){let e,i,n,o,f=t.split(/-(?!$)/),l=f[f.length-1];"Space"==l&&(l=" ");for(let t=0;t<f.length-1;t++){let l=f[t];if(/^(cmd|meta|m)$/i.test(l))o=!0;else if(/^a(lt)?$/i.test(l))e=!0;else if(/^(c|ctrl|control)$/i.test(l))i=!0;else if(/^s(hift)?$/i.test(l))n=!0;else{if(!/^mod$/i.test(l))throw new Error("Unrecognized modifier name: "+l);r?o=!0:i=!0}}return e&&(l="Alt-"+l),i&&(l="Ctrl-"+l),o&&(l="Meta-"+l),n&&(l="Shift-"+l),l}function o(t,e,i=!0){return e.altKey&&(t="Alt-"+t),e.ctrlKey&&(t="Ctrl-"+t),e.metaKey&&(t="Meta-"+t),i&&e.shiftKey&&(t="Shift-"+t),t}function f(t){return new i({props:{handleKeyDown:l(t)}})}function l(i){let r=function(t){let e=Object.create(null);for(let i in t)e[n(i)]=t[i];return e}(i);return function(i,n){let f,l=t(n),a=r[o(l,n)];if(a&&a(i.state,i.dispatch,i))return!0;if(1==l.length&&" "!=l){if(n.shiftKey){let t=r[o(l,n,!1)];if(t&&t(i.state,i.dispatch,i))return!0}if((n.shiftKey||n.altKey||n.metaKey||l.charCodeAt(0)>127)&&(f=e[n.keyCode])&&f!=l){let t=r[o(f,n)];if(t&&t(i.state,i.dispatch,i))return!0}}return!1}}export{l as keydownHandler,f as keymap};
|
2
|
-
//# sourceMappingURL=index2.mjs.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index2.mjs","sources":["../../../../../node_modules/prosemirror-keymap/dist/index.js"],"sourcesContent":["import { keyName, base } from 'w3c-keyname';\nimport { Plugin } from 'prosemirror-state';\n\nconst mac = typeof navigator != \"undefined\" ? /Mac|iP(hone|[oa]d)/.test(navigator.platform) : false;\nfunction normalizeKeyName(name) {\n let parts = name.split(/-(?!$)/), result = parts[parts.length - 1];\n if (result == \"Space\")\n result = \" \";\n let alt, ctrl, shift, meta;\n for (let i = 0; i < parts.length - 1; i++) {\n let mod = parts[i];\n if (/^(cmd|meta|m)$/i.test(mod))\n meta = true;\n else if (/^a(lt)?$/i.test(mod))\n alt = true;\n else if (/^(c|ctrl|control)$/i.test(mod))\n ctrl = true;\n else if (/^s(hift)?$/i.test(mod))\n shift = true;\n else if (/^mod$/i.test(mod)) {\n if (mac)\n meta = true;\n else\n ctrl = true;\n }\n else\n throw new Error(\"Unrecognized modifier name: \" + mod);\n }\n if (alt)\n result = \"Alt-\" + result;\n if (ctrl)\n result = \"Ctrl-\" + result;\n if (meta)\n result = \"Meta-\" + result;\n if (shift)\n result = \"Shift-\" + result;\n return result;\n}\nfunction normalize(map) {\n let copy = Object.create(null);\n for (let prop in map)\n copy[normalizeKeyName(prop)] = map[prop];\n return copy;\n}\nfunction modifiers(name, event, shift = true) {\n if (event.altKey)\n name = \"Alt-\" + name;\n if (event.ctrlKey)\n name = \"Ctrl-\" + name;\n if (event.metaKey)\n name = \"Meta-\" + name;\n if (shift && event.shiftKey)\n name = \"Shift-\" + name;\n return name;\n}\n/**\nCreate a keymap plugin for the given set of bindings.\n\nBindings should map key names to [command](https://prosemirror.net/docs/ref/#commands)-style\nfunctions, which will be called with `(EditorState, dispatch,\nEditorView)` arguments, and should return true when they've handled\nthe key. Note that the view argument isn't part of the command\nprotocol, but can be used as an escape hatch if a binding needs to\ndirectly interact with the UI.\n\nKey names may be strings like `\"Shift-Ctrl-Enter\"`—a key\nidentifier prefixed with zero or more modifiers. Key identifiers\nare based on the strings that can appear in\n[`KeyEvent.key`](https:developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key).\nUse lowercase letters to refer to letter keys (or uppercase letters\nif you want shift to be held). You may use `\"Space\"` as an alias\nfor the `\" \"` name.\n\nModifiers can be given in any order. `Shift-` (or `s-`), `Alt-` (or\n`a-`), `Ctrl-` (or `c-` or `Control-`) and `Cmd-` (or `m-` or\n`Meta-`) are recognized. For characters that are created by holding\nshift, the `Shift-` prefix is implied, and should not be added\nexplicitly.\n\nYou can use `Mod-` as a shorthand for `Cmd-` on Mac and `Ctrl-` on\nother platforms.\n\nYou can add multiple keymap plugins to an editor. The order in\nwhich they appear determines their precedence (the ones early in\nthe array get to dispatch first).\n*/\nfunction keymap(bindings) {\n return new Plugin({ props: { handleKeyDown: keydownHandler(bindings) } });\n}\n/**\nGiven a set of bindings (using the same format as\n[`keymap`](https://prosemirror.net/docs/ref/#keymap.keymap)), return a [keydown\nhandler](https://prosemirror.net/docs/ref/#view.EditorProps.handleKeyDown) that handles them.\n*/\nfunction keydownHandler(bindings) {\n let map = normalize(bindings);\n return function (view, event) {\n let name = keyName(event), baseName, direct = map[modifiers(name, event)];\n if (direct && direct(view.state, view.dispatch, view))\n return true;\n // A character key\n if (name.length == 1 && name != \" \") {\n if (event.shiftKey) {\n // In case the name was already modified by shift, try looking\n // it up without its shift modifier\n let noShift = map[modifiers(name, event, false)];\n if (noShift && noShift(view.state, view.dispatch, view))\n return true;\n }\n if ((event.shiftKey || event.altKey || event.metaKey || name.charCodeAt(0) > 127) &&\n (baseName = base[event.keyCode]) && baseName != name) {\n // Try falling back to the keyCode when there's a modifier\n // active or the character produced isn't ASCII, and our table\n // produces a different name from the the keyCode. See #668,\n // #1060\n let fromCode = map[modifiers(baseName, event)];\n if (fromCode && fromCode(view.state, view.dispatch, view))\n return true;\n }\n }\n return false;\n };\n}\n\nexport { keydownHandler, keymap };\n"],"names":["mac","navigator","test","platform","normalizeKeyName","name","alt","ctrl","shift","meta","parts","split","result","length","i","mod","Error","modifiers","event","altKey","ctrlKey","metaKey","shiftKey","keymap","bindings","Plugin","props","handleKeyDown","keydownHandler","map","copy","Object","create","prop","normalize","view","baseName","keyName","direct","state","dispatch","noShift","charCodeAt","base","keyCode","fromCode"],"mappings":"kIAGA,MAAMA,EAA0B,oBAAbC,WAA2B,qBAAqBC,KAAKD,UAAUE,UAClF,SAASC,EAAiBC,GACtB,IAGIC,EAAKC,EAAMC,EAAOC,EAHlBC,EAAQL,EAAKM,MAAM,UAAWC,EAASF,EAAMA,EAAMG,OAAS,GAClD,SAAVD,IACAA,EAAS,KAEb,IAAK,IAAIE,EAAI,EAAGA,EAAIJ,EAAMG,OAAS,EAAGC,IAAK,CACvC,IAAIC,EAAML,EAAMI,GAChB,GAAI,kBAAkBZ,KAAKa,GACvBN,GAAO,OACN,GAAI,YAAYP,KAAKa,GACtBT,GAAM,OACL,GAAI,sBAAsBJ,KAAKa,GAChCR,GAAO,OACN,GAAI,cAAcL,KAAKa,GACxBP,GAAQ,MACP,KAAI,SAASN,KAAKa,GAOnB,MAAM,IAAIC,MAAM,+BAAiCD,GAN7Cf,EACAS,GAAO,EAEPF,GAAO,CAG0C,CACjE,CASI,OARID,IACAM,EAAS,OAASA,GAClBL,IACAK,EAAS,QAAUA,GACnBH,IACAG,EAAS,QAAUA,GACnBJ,IACAI,EAAS,SAAWA,GACjBA,CACX,CAOA,SAASK,EAAUZ,EAAMa,EAAOV,GAAQ,GASpC,OARIU,EAAMC,SACNd,EAAO,OAASA,GAChBa,EAAME,UACNf,EAAO,QAAUA,GACjBa,EAAMG,UACNhB,EAAO,QAAUA,GACjBG,GAASU,EAAMI,WACfjB,EAAO,SAAWA,GACfA,CACX,CAgCA,SAASkB,EAAOC,GACZ,OAAO,IAAIC,EAAO,CAAEC,MAAO,CAAEC,cAAeC,EAAeJ,KAC/D,CAMA,SAASI,EAAeJ,GACpB,IAAIK,EAzDR,SAAmBA,GACf,IAAIC,EAAOC,OAAOC,OAAO,MACzB,IAAK,IAAIC,KAAQJ,EACbC,EAAK1B,EAAiB6B,IAASJ,EAAII,GACvC,OAAOH,CACX,CAoDcI,CAAUV,GACpB,OAAO,SAAUW,EAAMjB,GACnB,IAA2BkB,EAAvB/B,EAAOgC,EAAQnB,GAAkBoB,EAAST,EAAIZ,EAAUZ,EAAMa,IAClE,GAAIoB,GAAUA,EAAOH,EAAKI,MAAOJ,EAAKK,SAAUL,GAC5C,OAAO,EAEX,GAAmB,GAAf9B,EAAKQ,QAAuB,KAARR,EAAa,CACjC,GAAIa,EAAMI,SAAU,CAGhB,IAAImB,EAAUZ,EAAIZ,EAAUZ,EAAMa,GAAO,IACzC,GAAIuB,GAAWA,EAAQN,EAAKI,MAAOJ,EAAKK,SAAUL,GAC9C,OAAO,CAC3B,CACY,IAAKjB,EAAMI,UAAYJ,EAAMC,QAAUD,EAAMG,SAAWhB,EAAKqC,WAAW,GAAK,OACxEN,EAAWO,EAAKzB,EAAM0B,WAAaR,GAAY/B,EAAM,CAKtD,IAAIwC,EAAWhB,EAAIZ,EAAUmB,EAAUlB,IACvC,GAAI2B,GAAYA,EAASV,EAAKI,MAAOJ,EAAKK,SAAUL,GAChD,OAAO,CAC3B,CACA,CACQ,OAAO,CACV,CACL","x_google_ignoreList":[0]}
|
@@ -1,2 +0,0 @@
|
|
1
|
-
import{__exports as t}from"../../../_virtual/index3.mjs";import{__require as e}from"../../orderedmap/dist/index.mjs";var n;function r(){if(n)return t;function r(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(!t)return;if("string"==typeof t)return i(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(t);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(t,e)}(t))||e){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var s,a=!0,h=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){h=!0,s=t},f:function(){try{a||null==n.return||n.return()}finally{if(h)throw s}}}}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function o(){return o="undefined"!=typeof Reflect&&Reflect.get?Reflect.get.bind():function(t,e,n){var r=function(t,e){for(;!Object.prototype.hasOwnProperty.call(t,e)&&null!==(t=f(t)););return t}(t,e);if(r){var i=Object.getOwnPropertyDescriptor(r,e);return i.get?i.get.call(arguments.length<3?t:n):i.value}},o.apply(this,arguments)}function s(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&l(t,e)}function a(t){var e=c();return function(){var n,r=f(t);if(e){var i=f(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return function(t,e){if(e&&("object"===p(e)||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}(this,n)}}function h(t){var e="function"==typeof Map?new Map:void 0;return h=function(t){if(null===t||!function(t){try{return-1!==Function.toString.call(t).indexOf("[native code]")}catch(e){return"function"==typeof t}}(t))return t;if("function"!=typeof t)throw new TypeError("Super expression must either be null or a function");if(void 0!==e){if(e.has(t))return e.get(t);e.set(t,n)}function n(){return u(t,arguments,f(this).constructor)}return n.prototype=Object.create(t.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),l(n,t)},h(t)}function u(t,e,n){return u=c()?Reflect.construct.bind():function(t,e,n){var r=[null];r.push.apply(r,e);var i=new(Function.bind.apply(t,r));return n&&l(i,n.prototype),i},u.apply(null,arguments)}function c(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return!1}}function l(t,e){return l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},l(t,e)}function f(t){return f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},f(t)}function p(t){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},p(t)}function d(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function v(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,(i=r.key,o=void 0,o=function(t,e){if("object"!==p(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e);if("object"!==p(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(i,"string"),"symbol"===p(o)?o:String(o)),r)}var i,o}function y(t,e,n){return e&&v(t.prototype,e),n&&v(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}n=1;var m=e();function k(t,e,n){for(var r=0;;r++){if(r==t.childCount||r==e.childCount)return t.childCount==e.childCount?null:n;var i=t.child(r),o=e.child(r);if(i!=o){if(!i.sameMarkup(o))return n;if(i.isText&&i.text!=o.text){for(var s=0;i.text[s]==o.text[s];s++)n++;return n}if(i.content.size||o.content.size){var a=k(i.content,o.content,n+1);if(null!=a)return a}n+=i.nodeSize}else n+=i.nodeSize}}function g(t,e,n,r){for(var i=t.childCount,o=e.childCount;;){if(0==i||0==o)return i==o?null:{a:n,b:r};var s=t.child(--i),a=e.child(--o),h=s.nodeSize;if(s!=a){if(!s.sameMarkup(a))return{a:n,b:r};if(s.isText&&s.text!=a.text){for(var u=0,c=Math.min(s.text.length,a.text.length);u<c&&s.text[s.text.length-u-1]==a.text[a.text.length-u-1];)u++,n--,r--;return{a:n,b:r}}if(s.content.size||a.content.size){var l=g(s.content,a.content,n-1,r-1);if(l)return l}n-=h,r-=h}else n-=h,r-=h}}var x=function(){function t(e,n){if(d(this,t),this.content=e,this.size=n||0,null==n)for(var r=0;r<e.length;r++)this.size+=e[r].nodeSize}return y(t,[{key:"nodesBetween",value:function(t,e,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4?arguments[4]:void 0,o=0,s=0;s<e;o++){var a=this.content[o],h=s+a.nodeSize;if(h>t&&!1!==n(a,r+s,i||null,o)&&a.content.size){var u=s+1;a.nodesBetween(Math.max(0,t-u),Math.min(a.content.size,e-u),n,r+u)}s=h}}},{key:"descendants",value:function(t){this.nodesBetween(0,this.size,t)}},{key:"textBetween",value:function(t,e,n,r){var i="",o=!0;return this.nodesBetween(t,e,(function(s,a){var h=s.isText?s.text.slice(Math.max(t,a)-a,e-a):s.isLeaf?r?"function"==typeof r?r(s):r:s.type.spec.leafText?s.type.spec.leafText(s):"":"";s.isBlock&&(s.isLeaf&&h||s.isTextblock)&&n&&(o?o=!1:i+=n),i+=h}),0),i}},{key:"append",value:function(e){if(!e.size)return this;if(!this.size)return e;var n=this.lastChild,r=e.firstChild,i=this.content.slice(),o=0;for(n.isText&&n.sameMarkup(r)&&(i[i.length-1]=n.withText(n.text+r.text),o=1);o<e.content.length;o++)i.push(e.content[o]);return new t(i,this.size+e.size)}},{key:"cut",value:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.size;if(0==e&&n==this.size)return this;var r=[],i=0;if(n>e)for(var o=0,s=0;s<n;o++){var a=this.content[o],h=s+a.nodeSize;h>e&&((s<e||h>n)&&(a=a.isText?a.cut(Math.max(0,e-s),Math.min(a.text.length,n-s)):a.cut(Math.max(0,e-s-1),Math.min(a.content.size,n-s-1))),r.push(a),i+=a.nodeSize),s=h}return new t(r,i)}},{key:"cutByIndex",value:function(e,n){return e==n?t.empty:0==e&&n==this.content.length?this:new t(this.content.slice(e,n))}},{key:"replaceChild",value:function(e,n){var r=this.content[e];if(r==n)return this;var i=this.content.slice(),o=this.size+n.nodeSize-r.nodeSize;return i[e]=n,new t(i,o)}},{key:"addToStart",value:function(e){return new t([e].concat(this.content),this.size+e.nodeSize)}},{key:"addToEnd",value:function(e){return new t(this.content.concat(e),this.size+e.nodeSize)}},{key:"eq",value:function(t){if(this.content.length!=t.content.length)return!1;for(var e=0;e<this.content.length;e++)if(!this.content[e].eq(t.content[e]))return!1;return!0}},{key:"firstChild",get:function(){return this.content.length?this.content[0]:null}},{key:"lastChild",get:function(){return this.content.length?this.content[this.content.length-1]:null}},{key:"childCount",get:function(){return this.content.length}},{key:"child",value:function(t){var e=this.content[t];if(!e)throw new RangeError("Index "+t+" out of range for "+this);return e}},{key:"maybeChild",value:function(t){return this.content[t]||null}},{key:"forEach",value:function(t){for(var e=0,n=0;e<this.content.length;e++){var r=this.content[e];t(r,n,e),n+=r.nodeSize}}},{key:"findDiffStart",value:function(t){return k(this,t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:0)}},{key:"findDiffEnd",value:function(t){return g(this,t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.size,arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.size)}},{key:"findIndex",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1;if(0==t)return S(0,t);if(t==this.size)return S(this.content.length,t);if(t>this.size||t<0)throw new RangeError("Position ".concat(t," outside of fragment (").concat(this,")"));for(var n=0,r=0;;n++){var i=r+this.child(n).nodeSize;if(i>=t)return i==t||e>0?S(n+1,i):S(n,r);r=i}}},{key:"toString",value:function(){return"<"+this.toStringInner()+">"}},{key:"toStringInner",value:function(){return this.content.join(", ")}},{key:"toJSON",value:function(){return this.content.length?this.content.map((function(t){return t.toJSON()})):null}}],[{key:"fromJSON",value:function(e,n){if(!n)return t.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new t(n.map(e.nodeFromJSON))}},{key:"fromArray",value:function(e){if(!e.length)return t.empty;for(var n,r=0,i=0;i<e.length;i++){var o=e[i];r+=o.nodeSize,i&&o.isText&&e[i-1].sameMarkup(o)?(n||(n=e.slice(0,i)),n[n.length-1]=o.withText(n[n.length-1].text+o.text)):n&&n.push(o)}return new t(n||e,r)}},{key:"from",value:function(e){if(!e)return t.empty;if(e instanceof t)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new t([e],e.nodeSize);throw new RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}]),t}();x.empty=new x([],0);var w={index:0,offset:0};function S(t,e){return w.index=t,w.offset=e,w}function b(t,e){if(t===e)return!0;if(!t||"object"!=p(t)||!e||"object"!=p(e))return!1;var n=Array.isArray(t);if(Array.isArray(e)!=n)return!1;if(n){if(t.length!=e.length)return!1;for(var r=0;r<t.length;r++)if(!b(t[r],e[r]))return!1}else{for(var i in t)if(!(i in e)||!b(t[i],e[i]))return!1;for(var o in e)if(!(o in t))return!1}return!0}var O=function(){function t(e,n){d(this,t),this.type=e,this.attrs=n}return y(t,[{key:"addToSet",value:function(t){for(var e,n=!1,r=0;r<t.length;r++){var i=t[r];if(this.eq(i))return t;if(this.type.excludes(i.type))e||(e=t.slice(0,r));else{if(i.type.excludes(this.type))return t;!n&&i.type.rank>this.type.rank&&(e||(e=t.slice(0,r)),e.push(this),n=!0),e&&e.push(i)}}return e||(e=t.slice()),n||e.push(this),e}},{key:"removeFromSet",value:function(t){for(var e=0;e<t.length;e++)if(this.eq(t[e]))return t.slice(0,e).concat(t.slice(e+1));return t}},{key:"isInSet",value:function(t){for(var e=0;e<t.length;e++)if(this.eq(t[e]))return!0;return!1}},{key:"eq",value:function(t){return this==t||this.type==t.type&&b(this.attrs,t.attrs)}},{key:"toJSON",value:function(){var t={type:this.type.name};for(var e in this.attrs){t.attrs=this.attrs;break}return t}}],[{key:"fromJSON",value:function(t,e){if(!e)throw new RangeError("Invalid input for Mark.fromJSON");var n=t.marks[e.type];if(!n)throw new RangeError("There is no mark type ".concat(e.type," in this schema"));var r=n.create(e.attrs);return n.checkAttrs(r.attrs),r}},{key:"sameSet",value:function(t,e){if(t==e)return!0;if(t.length!=e.length)return!1;for(var n=0;n<t.length;n++)if(!t[n].eq(e[n]))return!1;return!0}},{key:"setFrom",value:function(e){if(!e||Array.isArray(e)&&0==e.length)return t.none;if(e instanceof t)return[e];var n=e.slice();return n.sort((function(t,e){return t.type.rank-e.type.rank})),n}}]),t}();O.none=[];var E=function(t){s(n,t);var e=a(n);function n(){return d(this,n),e.apply(this,arguments)}return y(n)}(h(Error)),C=function(){function t(e,n,r){d(this,t),this.content=e,this.openStart=n,this.openEnd=r}return y(t,[{key:"size",get:function(){return this.content.size-this.openStart-this.openEnd}},{key:"insertAt",value:function(e,n){var r=M(this.content,e+this.openStart,n);return r&&new t(r,this.openStart,this.openEnd)}},{key:"removeBetween",value:function(e,n){return new t(T(this.content,e+this.openStart,n+this.openStart),this.openStart,this.openEnd)}},{key:"eq",value:function(t){return this.content.eq(t.content)&&this.openStart==t.openStart&&this.openEnd==t.openEnd}},{key:"toString",value:function(){return this.content+"("+this.openStart+","+this.openEnd+")"}},{key:"toJSON",value:function(){if(!this.content.size)return null;var t={content:this.content.toJSON()};return this.openStart>0&&(t.openStart=this.openStart),this.openEnd>0&&(t.openEnd=this.openEnd),t}}],[{key:"fromJSON",value:function(e,n){if(!n)return t.empty;var r=n.openStart||0,i=n.openEnd||0;if("number"!=typeof r||"number"!=typeof i)throw new RangeError("Invalid input for Slice.fromJSON");return new t(x.fromJSON(e,n.content),r,i)}},{key:"maxOpen",value:function(e){for(var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],r=0,i=0,o=e.firstChild;o&&!o.isLeaf&&(n||!o.type.spec.isolating);o=o.firstChild)r++;for(var s=e.lastChild;s&&!s.isLeaf&&(n||!s.type.spec.isolating);s=s.lastChild)i++;return new t(e,r,i)}}]),t}();function T(t,e,n){var r=t.findIndex(e),i=r.index,o=r.offset,s=t.maybeChild(i),a=t.findIndex(n),h=a.index,u=a.offset;if(o==e||s.isText){if(u!=n&&!t.child(h).isText)throw new RangeError("Removing non-flat range");return t.cut(0,e).append(t.cut(n))}if(i!=h)throw new RangeError("Removing non-flat range");return t.replaceChild(i,s.copy(T(s.content,e-o-1,n-o-1)))}function M(t,e,n,r){var i=t.findIndex(e),o=i.index,s=i.offset,a=t.maybeChild(o);if(s==e||a.isText)return t.cut(0,e).append(n).append(t.cut(e));var h=M(a.content,e-s-1,n);return h&&t.replaceChild(o,a.copy(h))}function A(t,e,n){if(n.openStart>t.depth)throw new E("Inserted content deeper than insertion position");if(t.depth-n.openStart!=e.depth-n.openEnd)throw new E("Inconsistent open depths");return N(t,e,n,0)}function N(t,e,n,r){var i=t.index(r),o=t.node(r);if(i==e.index(r)&&r<t.depth-n.openStart){var s=N(t,e,n,r+1);return o.copy(o.content.replaceChild(i,s))}if(n.content.size){if(n.openStart||n.openEnd||t.depth!=r||e.depth!=r){var a=function(t,e){for(var n=e.depth-t.openStart,r=e.node(n).copy(t.content),i=n-1;i>=0;i--)r=e.node(i).copy(x.from(r));return{start:r.resolveNoCache(t.openStart+n),end:r.resolveNoCache(r.content.size-t.openEnd-n)}}(n,t);return j(o,P(t,a.start,a.end,e,r))}var h=t.parent,u=h.content;return j(h,u.cut(0,t.parentOffset).append(n.content).append(u.cut(e.parentOffset)))}return j(o,B(t,e,r))}function z(t,e){if(!e.type.compatibleContent(t.type))throw new E("Cannot join "+e.type.name+" onto "+t.type.name)}function R(t,e,n){var r=t.node(n);return z(r,e.node(n)),r}function I(t,e){var n=e.length-1;n>=0&&t.isText&&t.sameMarkup(e[n])?e[n]=t.withText(e[n].text+t.text):e.push(t)}function F(t,e,n,r){var i=(e||t).node(n),o=0,s=e?e.index(n):i.childCount;t&&(o=t.index(n),t.depth>n?o++:t.textOffset&&(I(t.nodeAfter,r),o++));for(var a=o;a<s;a++)I(i.child(a),r);e&&e.depth==n&&e.textOffset&&I(e.nodeBefore,r)}function j(t,e){return t.type.checkContent(e),t.copy(e)}function P(t,e,n,r,i){var o=t.depth>i&&R(t,e,i+1),s=r.depth>i&&R(n,r,i+1),a=[];return F(null,t,i,a),o&&s&&e.index(i)==n.index(i)?(z(o,s),I(j(o,P(t,e,n,r,i+1)),a)):(o&&I(j(o,B(t,e,i+1)),a),F(e,n,i,a),s&&I(j(s,B(n,r,i+1)),a)),F(r,null,i,a),new x(a)}function B(t,e,n){var r=[];(F(null,t,n,r),t.depth>n)&&I(j(R(t,e,n+1),B(t,e,n+1)),r);return F(e,null,n,r),new x(r)}C.empty=new C(x.empty,0,0);var D=function(){function t(e,n,r){d(this,t),this.pos=e,this.path=n,this.parentOffset=r,this.depth=n.length/3-1}return y(t,[{key:"resolveDepth",value:function(t){return null==t?this.depth:t<0?this.depth+t:t}},{key:"parent",get:function(){return this.node(this.depth)}},{key:"doc",get:function(){return this.node(0)}},{key:"node",value:function(t){return this.path[3*this.resolveDepth(t)]}},{key:"index",value:function(t){return this.path[3*this.resolveDepth(t)+1]}},{key:"indexAfter",value:function(t){return t=this.resolveDepth(t),this.index(t)+(t!=this.depth||this.textOffset?1:0)}},{key:"start",value:function(t){return 0==(t=this.resolveDepth(t))?0:this.path[3*t-1]+1}},{key:"end",value:function(t){return t=this.resolveDepth(t),this.start(t)+this.node(t).content.size}},{key:"before",value:function(t){if(!(t=this.resolveDepth(t)))throw new RangeError("There is no position before the top-level node");return t==this.depth+1?this.pos:this.path[3*t-1]}},{key:"after",value:function(t){if(!(t=this.resolveDepth(t)))throw new RangeError("There is no position after the top-level node");return t==this.depth+1?this.pos:this.path[3*t-1]+this.path[3*t].nodeSize}},{key:"textOffset",get:function(){return this.pos-this.path[this.path.length-1]}},{key:"nodeAfter",get:function(){var t=this.parent,e=this.index(this.depth);if(e==t.childCount)return null;var n=this.pos-this.path[this.path.length-1],r=t.child(e);return n?t.child(e).cut(n):r}},{key:"nodeBefore",get:function(){var t=this.index(this.depth),e=this.pos-this.path[this.path.length-1];return e?this.parent.child(t).cut(0,e):0==t?null:this.parent.child(t-1)}},{key:"posAtIndex",value:function(t,e){e=this.resolveDepth(e);for(var n=this.path[3*e],r=0==e?0:this.path[3*e-1]+1,i=0;i<t;i++)r+=n.child(i).nodeSize;return r}},{key:"marks",value:function(){var t=this.parent,e=this.index();if(0==t.content.size)return O.none;if(this.textOffset)return t.child(e).marks;var n=t.maybeChild(e-1),r=t.maybeChild(e);if(!n){var i=n;n=r,r=i}for(var o=n.marks,s=0;s<o.length;s++)!1!==o[s].type.spec.inclusive||r&&o[s].isInSet(r.marks)||(o=o[s--].removeFromSet(o));return o}},{key:"marksAcross",value:function(t){var e=this.parent.maybeChild(this.index());if(!e||!e.isInline)return null;for(var n=e.marks,r=t.parent.maybeChild(t.index()),i=0;i<n.length;i++)!1!==n[i].type.spec.inclusive||r&&n[i].isInSet(r.marks)||(n=n[i--].removeFromSet(n));return n}},{key:"sharedDepth",value:function(t){for(var e=this.depth;e>0;e--)if(this.start(e)<=t&&this.end(e)>=t)return e;return 0}},{key:"blockRange",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this,e=arguments.length>1?arguments[1]:void 0;if(t.pos<this.pos)return t.blockRange(this);for(var n=this.depth-(this.parent.inlineContent||this.pos==t.pos?1:0);n>=0;n--)if(t.pos<=this.end(n)&&(!e||e(this.node(n))))return new _(this,t,n);return null}},{key:"sameParent",value:function(t){return this.pos-this.parentOffset==t.pos-t.parentOffset}},{key:"max",value:function(t){return t.pos>this.pos?t:this}},{key:"min",value:function(t){return t.pos<this.pos?t:this}},{key:"toString",value:function(){for(var t="",e=1;e<=this.depth;e++)t+=(t?"/":"")+this.node(e).type.name+"_"+this.index(e-1);return t+":"+this.parentOffset}}],[{key:"resolve",value:function(e,n){if(!(n>=0&&n<=e.content.size))throw new RangeError("Position "+n+" out of range");for(var r=[],i=0,o=n,s=e;;){var a=s.content.findIndex(o),h=a.index,u=a.offset,c=o-u;if(r.push(s,h,i+u),!c)break;if((s=s.child(h)).isText)break;o=c-1,i+=u+1}return new t(n,r,o)}},{key:"resolveCached",value:function(e,n){var r=L.get(e);if(r)for(var i=0;i<r.elts.length;i++){var o=r.elts[i];if(o.pos==n)return o}else L.set(e,r=new J);var s=r.elts[r.i]=t.resolve(e,n);return r.i=(r.i+1)%q,s}}]),t}(),J=y((function t(){d(this,t),this.elts=[],this.i=0})),q=12,L=new WeakMap,_=function(){function t(e,n,r){d(this,t),this.$from=e,this.$to=n,this.depth=r}return y(t,[{key:"start",get:function(){return this.$from.before(this.depth+1)}},{key:"end",get:function(){return this.$to.after(this.depth+1)}},{key:"parent",get:function(){return this.$from.node(this.depth)}},{key:"startIndex",get:function(){return this.$from.index(this.depth)}},{key:"endIndex",get:function(){return this.$to.indexAfter(this.depth)}}]),t}(),W=Object.create(null),$=function(){function t(e,n,r){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:O.none;d(this,t),this.type=e,this.attrs=n,this.marks=i,this.content=r||x.empty}return y(t,[{key:"nodeSize",get:function(){return this.isLeaf?1:2+this.content.size}},{key:"childCount",get:function(){return this.content.childCount}},{key:"child",value:function(t){return this.content.child(t)}},{key:"maybeChild",value:function(t){return this.content.maybeChild(t)}},{key:"forEach",value:function(t){this.content.forEach(t)}},{key:"nodesBetween",value:function(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;this.content.nodesBetween(t,e,n,r,this)}},{key:"descendants",value:function(t){this.nodesBetween(0,this.content.size,t)}},{key:"textContent",get:function(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}},{key:"textBetween",value:function(t,e,n,r){return this.content.textBetween(t,e,n,r)}},{key:"firstChild",get:function(){return this.content.firstChild}},{key:"lastChild",get:function(){return this.content.lastChild}},{key:"eq",value:function(t){return this==t||this.sameMarkup(t)&&this.content.eq(t.content)}},{key:"sameMarkup",value:function(t){return this.hasMarkup(t.type,t.attrs,t.marks)}},{key:"hasMarkup",value:function(t,e,n){return this.type==t&&b(this.attrs,e||t.defaultAttrs||W)&&O.sameSet(this.marks,n||O.none)}},{key:"copy",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return e==this.content?this:new t(this.type,this.attrs,e,this.marks)}},{key:"mark",value:function(e){return e==this.marks?this:new t(this.type,this.attrs,this.content,e)}},{key:"cut",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.content.size;return 0==t&&e==this.content.size?this:this.copy(this.content.cut(t,e))}},{key:"slice",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.content.size,n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(t==e)return C.empty;var r=this.resolve(t),i=this.resolve(e),o=n?0:r.sharedDepth(e),s=r.start(o),a=r.node(o).content.cut(r.pos-s,i.pos-s);return new C(a,r.depth-o,i.depth-o)}},{key:"replace",value:function(t,e,n){return A(this.resolve(t),this.resolve(e),n)}},{key:"nodeAt",value:function(t){for(var e=this;;){var n=e.content.findIndex(t),r=n.index,i=n.offset;if(!(e=e.maybeChild(r)))return null;if(i==t||e.isText)return e;t-=i+1}}},{key:"childAfter",value:function(t){var e=this.content.findIndex(t),n=e.index,r=e.offset;return{node:this.content.maybeChild(n),index:n,offset:r}}},{key:"childBefore",value:function(t){if(0==t)return{node:null,index:0,offset:0};var e=this.content.findIndex(t),n=e.index,r=e.offset;if(r<t)return{node:this.content.child(n),index:n,offset:r};var i=this.content.child(n-1);return{node:i,index:n-1,offset:r-i.nodeSize}}},{key:"resolve",value:function(t){return D.resolveCached(this,t)}},{key:"resolveNoCache",value:function(t){return D.resolve(this,t)}},{key:"rangeHasMark",value:function(t,e,n){var r=!1;return e>t&&this.nodesBetween(t,e,(function(t){return n.isInSet(t.marks)&&(r=!0),!r})),r}},{key:"isBlock",get:function(){return this.type.isBlock}},{key:"isTextblock",get:function(){return this.type.isTextblock}},{key:"inlineContent",get:function(){return this.type.inlineContent}},{key:"isInline",get:function(){return this.type.isInline}},{key:"isText",get:function(){return this.type.isText}},{key:"isLeaf",get:function(){return this.type.isLeaf}},{key:"isAtom",get:function(){return this.type.isAtom}},{key:"toString",value:function(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);var t=this.type.name;return this.content.size&&(t+="("+this.content.toStringInner()+")"),G(this.marks,t)}},{key:"contentMatchAt",value:function(t){var e=this.type.contentMatch.matchFragment(this.content,0,t);if(!e)throw new Error("Called contentMatchAt on a node with invalid content");return e}},{key:"canReplace",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:x.empty,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:n.childCount,o=this.contentMatchAt(t).matchFragment(n,r,i),s=o&&o.matchFragment(this.content,e);if(!s||!s.validEnd)return!1;for(var a=r;a<i;a++)if(!this.type.allowsMarks(n.child(a).marks))return!1;return!0}},{key:"canReplaceWith",value:function(t,e,n,r){if(r&&!this.type.allowsMarks(r))return!1;var i=this.contentMatchAt(t).matchType(n),o=i&&i.matchFragment(this.content,e);return!!o&&o.validEnd}},{key:"canAppend",value:function(t){return t.content.size?this.canReplace(this.childCount,this.childCount,t.content):this.type.compatibleContent(t.type)}},{key:"check",value:function(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);for(var t=O.none,e=0;e<this.marks.length;e++){var n=this.marks[e];n.type.checkAttrs(n.attrs),t=n.addToSet(t)}if(!O.sameSet(t,this.marks))throw new RangeError("Invalid collection of marks for node ".concat(this.type.name,": ").concat(this.marks.map((function(t){return t.type.name}))));this.content.forEach((function(t){return t.check()}))}},{key:"toJSON",value:function(){var t={type:this.type.name};for(var e in this.attrs){t.attrs=this.attrs;break}return this.content.size&&(t.content=this.content.toJSON()),this.marks.length&&(t.marks=this.marks.map((function(t){return t.toJSON()}))),t}}],[{key:"fromJSON",value:function(t,e){if(!e)throw new RangeError("Invalid input for Node.fromJSON");var n=void 0;if(e.marks){if(!Array.isArray(e.marks))throw new RangeError("Invalid mark data for Node.fromJSON");n=e.marks.map(t.markFromJSON)}if("text"==e.type){if("string"!=typeof e.text)throw new RangeError("Invalid text node in JSON");return t.text(e.text,n)}var r=x.fromJSON(t,e.content),i=t.nodeType(e.type).create(e.attrs,r,n);return i.type.checkAttrs(i.attrs),i}}]),t}();$.prototype.text=void 0;var U=function(t){s(n,t);var e=a(n);function n(t,r,i,o){var s;if(d(this,n),s=e.call(this,t,r,null,o),!i)throw new RangeError("Empty text nodes are not allowed");return s.text=i,s}return y(n,[{key:"toString",value:function(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):G(this.marks,JSON.stringify(this.text))}},{key:"textContent",get:function(){return this.text}},{key:"textBetween",value:function(t,e){return this.text.slice(t,e)}},{key:"nodeSize",get:function(){return this.text.length}},{key:"mark",value:function(t){return t==this.marks?this:new n(this.type,this.attrs,this.text,t)}},{key:"withText",value:function(t){return t==this.text?this:new n(this.type,this.attrs,t,this.marks)}},{key:"cut",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.text.length;return 0==t&&e==this.text.length?this:this.withText(this.text.slice(t,e))}},{key:"eq",value:function(t){return this.sameMarkup(t)&&this.text==t.text}},{key:"toJSON",value:function(){var t=o(f(n.prototype),"toJSON",this).call(this);return t.text=this.text,t}}]),n}($);function G(t,e){for(var n=t.length-1;n>=0;n--)e=t[n].type.name+"("+e+")";return e}var V=function(){function t(e){d(this,t),this.validEnd=e,this.next=[],this.wrapCache=[]}return y(t,[{key:"matchType",value:function(t){for(var e=0;e<this.next.length;e++)if(this.next[e].type==t)return this.next[e].next;return null}},{key:"matchFragment",value:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.childCount,r=this,i=e;r&&i<n;i++)r=r.matchType(t.child(i).type);return r}},{key:"inlineContent",get:function(){return 0!=this.next.length&&this.next[0].type.isInline}},{key:"defaultType",get:function(){for(var t=0;t<this.next.length;t++){var e=this.next[t].type;if(!e.isText&&!e.hasRequiredAttrs())return e}return null}},{key:"compatible",value:function(t){for(var e=0;e<this.next.length;e++)for(var n=0;n<t.next.length;n++)if(this.next[e].type==t.next[n].type)return!0;return!1}},{key:"fillBefore",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=[this];return function i(o,s){var a=o.matchFragment(t,n);if(a&&(!e||a.validEnd))return x.from(s.map((function(t){return t.createAndFill()})));for(var h=0;h<o.next.length;h++){var u=o.next[h],c=u.type,l=u.next;if(!c.isText&&!c.hasRequiredAttrs()&&-1==r.indexOf(l)){r.push(l);var f=i(l,s.concat(c));if(f)return f}}return null}(this,[])}},{key:"findWrapping",value:function(t){for(var e=0;e<this.wrapCache.length;e+=2)if(this.wrapCache[e]==t)return this.wrapCache[e+1];var n=this.computeWrapping(t);return this.wrapCache.push(t,n),n}},{key:"computeWrapping",value:function(t){for(var e=Object.create(null),n=[{match:this,type:null,via:null}];n.length;){var r=n.shift(),i=r.match;if(i.matchType(t)){for(var o=[],s=r;s.type;s=s.via)o.push(s.type);return o.reverse()}for(var a=0;a<i.next.length;a++){var h=i.next[a],u=h.type,c=h.next;u.isLeaf||u.hasRequiredAttrs()||u.name in e||r.type&&!c.validEnd||(n.push({match:u.contentMatch,type:u,via:r}),e[u.name]=!0)}}return null}},{key:"edgeCount",get:function(){return this.next.length}},{key:"edge",value:function(t){if(t>=this.next.length)throw new RangeError("There's no ".concat(t,"th edge in this content match"));return this.next[t]}},{key:"toString",value:function(){var t=[];return function e(n){t.push(n);for(var r=0;r<n.next.length;r++)-1==t.indexOf(n.next[r].next)&&e(n.next[r].next)}(this),t.map((function(e,n){for(var r=n+(e.validEnd?"*":" ")+" ",i=0;i<e.next.length;i++)r+=(i?", ":"")+e.next[i].type.name+"->"+t.indexOf(e.next[i].next);return r})).join("\n")}}],[{key:"parse",value:function(e,n){var r=new H(e,n);if(null==r.next)return t.empty;var i=K(r);r.next&&r.err("Unexpected trailing text");var o=nt(function(t){var e=[[]];return i(o(t,0),n()),e;function n(){return e.push([])-1}function r(t,n,r){var i={term:r,to:n};return e[t].push(i),i}function i(t,e){t.forEach((function(t){return t.to=e}))}function o(t,e){if("choice"==t.type)return t.exprs.reduce((function(t,n){return t.concat(o(n,e))}),[]);if("seq"!=t.type){if("star"==t.type){var s=n();return r(e,s),i(o(t.expr,s),s),[r(s)]}if("plus"==t.type){var a=n();return i(o(t.expr,e),a),i(o(t.expr,a),a),[r(a)]}if("opt"==t.type)return[r(e)].concat(o(t.expr,e));if("range"==t.type){for(var h=e,u=0;u<t.min;u++){var c=n();i(o(t.expr,h),c),h=c}if(-1==t.max)i(o(t.expr,h),h);else for(var l=t.min;l<t.max;l++){var f=n();r(h,f),i(o(t.expr,h),f),h=f}return[r(h)]}if("name"==t.type)return[r(e,void 0,t.value)];throw new Error("Unknown expr type")}for(var p=0;;p++){var d=o(t.exprs[p],e);if(p==t.exprs.length-1)return d;i(d,e=n())}}}(i));return function(t,e){for(var n=0,r=[t];n<r.length;n++){for(var i=r[n],o=!i.validEnd,s=[],a=0;a<i.next.length;a++){var h=i.next[a],u=h.type,c=h.next;s.push(u.name),!o||u.isText||u.hasRequiredAttrs()||(o=!1),-1==r.indexOf(c)&&r.push(c)}o&&e.err("Only non-generatable nodes ("+s.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}(o,r),o}}]),t}();V.empty=new V(!0);var H=function(){function t(e,n){d(this,t),this.string=e,this.nodeTypes=n,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),""==this.tokens[this.tokens.length-1]&&this.tokens.pop(),""==this.tokens[0]&&this.tokens.shift()}return y(t,[{key:"next",get:function(){return this.tokens[this.pos]}},{key:"eat",value:function(t){return this.next==t&&(this.pos++||!0)}},{key:"err",value:function(t){throw new SyntaxError(t+" (in content expression '"+this.string+"')")}}]),t}();function K(t){var e=[];do{e.push(Q(t))}while(t.eat("|"));return 1==e.length?e[0]:{type:"choice",exprs:e}}function Q(t){var e=[];do{e.push(X(t))}while(t.next&&")"!=t.next&&"|"!=t.next);return 1==e.length?e[0]:{type:"seq",exprs:e}}function X(t){for(var e=function(t){if(t.eat("(")){var e=K(t);return t.eat(")")||t.err("Missing closing paren"),e}if(!/\W/.test(t.next)){var n=function(t,e){var n=t.nodeTypes,r=n[e];if(r)return[r];var i=[];for(var o in n){var s=n[o];s.isInGroup(e)&&i.push(s)}0==i.length&&t.err("No node type or group '"+e+"' found");return i}(t,t.next).map((function(e){return null==t.inline?t.inline=e.isInline:t.inline!=e.isInline&&t.err("Mixing inline and block content"),{type:"name",value:e}}));return t.pos++,1==n.length?n[0]:{type:"choice",exprs:n}}t.err("Unexpected token '"+t.next+"'")}(t);;)if(t.eat("+"))e={type:"plus",expr:e};else if(t.eat("*"))e={type:"star",expr:e};else if(t.eat("?"))e={type:"opt",expr:e};else{if(!t.eat("{"))break;e=Z(t,e)}return e}function Y(t){/\D/.test(t.next)&&t.err("Expected number, got '"+t.next+"'");var e=Number(t.next);return t.pos++,e}function Z(t,e){var n=Y(t),r=n;return t.eat(",")&&(r="}"!=t.next?Y(t):-1),t.eat("}")||t.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:e}}function tt(t,e){return e-t}function et(t,e){var n=[];return function e(r){var i=t[r];if(1==i.length&&!i[0].term)return e(i[0].to);n.push(r);for(var o=0;o<i.length;o++){var s=i[o],a=s.term,h=s.to;a||-1!=n.indexOf(h)||e(h)}}(e),n.sort(tt)}function nt(t){var e=Object.create(null);return function n(r){var i=[];r.forEach((function(e){t[e].forEach((function(e){var n=e.term,r=e.to;if(n){for(var o,s=0;s<i.length;s++)i[s][0]==n&&(o=i[s][1]);et(t,r).forEach((function(t){o||i.push([n,o=[]]),-1==o.indexOf(t)&&o.push(t)}))}}))}));for(var o=e[r.join(",")]=new V(r.indexOf(t.length-1)>-1),s=0;s<i.length;s++){var a=i[s][1].sort(tt);o.next.push({type:i[s][0],next:e[a.join(",")]||n(a)})}return o}(et(t,0))}function rt(t){var e=Object.create(null);for(var n in t){var r=t[n];if(!r.hasDefault)return null;e[n]=r.default}return e}function it(t,e){var n=Object.create(null);for(var r in t){var i=e&&e[r];if(void 0===i){var o=t[r];if(!o.hasDefault)throw new RangeError("No value supplied for attribute "+r);i=o.default}n[r]=i}return n}function ot(t,e,n,r){for(var i in e)if(!(i in t))throw new RangeError("Unsupported attribute ".concat(i," for ").concat(n," of type ").concat(i));for(var o in t){var s=t[o];s.validate&&s.validate(e[o])}}function st(t,e){var n=Object.create(null);if(e)for(var r in e)n[r]=new ht(t,r,e[r]);return n}var at=function(){function t(e,n,r){d(this,t),this.name=e,this.schema=n,this.spec=r,this.markSet=null,this.groups=r.group?r.group.split(" "):[],this.attrs=st(e,r.attrs),this.defaultAttrs=rt(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(r.inline||"text"==e),this.isText="text"==e}return y(t,[{key:"isInline",get:function(){return!this.isBlock}},{key:"isTextblock",get:function(){return this.isBlock&&this.inlineContent}},{key:"isLeaf",get:function(){return this.contentMatch==V.empty}},{key:"isAtom",get:function(){return this.isLeaf||!!this.spec.atom}},{key:"isInGroup",value:function(t){return this.groups.indexOf(t)>-1}},{key:"whitespace",get:function(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}},{key:"hasRequiredAttrs",value:function(){for(var t in this.attrs)if(this.attrs[t].isRequired)return!0;return!1}},{key:"compatibleContent",value:function(t){return this==t||this.contentMatch.compatible(t.contentMatch)}},{key:"computeAttrs",value:function(t){return!t&&this.defaultAttrs?this.defaultAttrs:it(this.attrs,t)}},{key:"create",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new $(this,this.computeAttrs(t),x.from(e),O.setFrom(n))}},{key:"createChecked",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;return e=x.from(e),this.checkContent(e),new $(this,this.computeAttrs(t),e,O.setFrom(n))}},{key:"createAndFill",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0;if(t=this.computeAttrs(t),(e=x.from(e)).size){var r=this.contentMatch.fillBefore(e);if(!r)return null;e=r.append(e)}var i=this.contentMatch.matchFragment(e),o=i&&i.fillBefore(x.empty,!0);return o?new $(this,t,e.append(o),O.setFrom(n)):null}},{key:"validContent",value:function(t){var e=this.contentMatch.matchFragment(t);if(!e||!e.validEnd)return!1;for(var n=0;n<t.childCount;n++)if(!this.allowsMarks(t.child(n).marks))return!1;return!0}},{key:"checkContent",value:function(t){if(!this.validContent(t))throw new RangeError("Invalid content for node ".concat(this.name,": ").concat(t.toString().slice(0,50)))}},{key:"checkAttrs",value:function(t){ot(this.attrs,t,"node",this.name)}},{key:"allowsMarkType",value:function(t){return null==this.markSet||this.markSet.indexOf(t)>-1}},{key:"allowsMarks",value:function(t){if(null==this.markSet)return!0;for(var e=0;e<t.length;e++)if(!this.allowsMarkType(t[e].type))return!1;return!0}},{key:"allowedMarks",value:function(t){if(null==this.markSet)return t;for(var e,n=0;n<t.length;n++)this.allowsMarkType(t[n].type)?e&&e.push(t[n]):e||(e=t.slice(0,n));return e?e.length?e:O.none:t}}],[{key:"compile",value:function(e,n){var r=Object.create(null);e.forEach((function(e,i){return r[e]=new t(e,n,i)}));var i=n.spec.topNode||"doc";if(!r[i])throw new RangeError("Schema is missing its top node type ('"+i+"')");if(!r.text)throw new RangeError("Every schema needs a 'text' type");for(var o in r.text.attrs)throw new RangeError("The text node type should not have attributes");return r}}]),t}();var ht=function(){function t(e,n,r){d(this,t),this.hasDefault=Object.prototype.hasOwnProperty.call(r,"default"),this.default=r.default,this.validate="string"==typeof r.validate?function(t,e,n){var r=n.split("|");return function(n){var i=null===n?"null":p(n);if(r.indexOf(i)<0)throw new RangeError("Expected value of type ".concat(r," for attribute ").concat(e," on type ").concat(t,", got ").concat(i))}}(e,n,r.validate):r.validate}return y(t,[{key:"isRequired",get:function(){return!this.hasDefault}}]),t}(),ut=function(){function t(e,n,r,i){d(this,t),this.name=e,this.rank=n,this.schema=r,this.spec=i,this.attrs=st(e,i.attrs),this.excluded=null;var o=rt(this.attrs);this.instance=o?new O(this,o):null}return y(t,[{key:"create",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return!t&&this.instance?this.instance:new O(this,it(this.attrs,t))}},{key:"removeFromSet",value:function(t){for(var e=0;e<t.length;e++)t[e].type==this&&(t=t.slice(0,e).concat(t.slice(e+1)),e--);return t}},{key:"isInSet",value:function(t){for(var e=0;e<t.length;e++)if(t[e].type==this)return t[e]}},{key:"checkAttrs",value:function(t){ot(this.attrs,t,"mark",this.name)}},{key:"excludes",value:function(t){return this.excluded.indexOf(t)>-1}}],[{key:"compile",value:function(e,n){var r=Object.create(null),i=0;return e.forEach((function(e,o){return r[e]=new t(e,i++,n,o)})),r}}]),t}(),ct=function(){function t(e){d(this,t),this.linebreakReplacement=null,this.cached=Object.create(null);var n=this.spec={};for(var r in e)n[r]=e[r];n.nodes=m.from(e.nodes),n.marks=m.from(e.marks||{}),this.nodes=at.compile(this.spec.nodes,this),this.marks=ut.compile(this.spec.marks,this);var i=Object.create(null);for(var o in this.nodes){if(o in this.marks)throw new RangeError(o+" can not be both a node and a mark");var s=this.nodes[o],a=s.spec.content||"",h=s.spec.marks;if(s.contentMatch=i[a]||(i[a]=V.parse(a,this.nodes)),s.inlineContent=s.contentMatch.inlineContent,s.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!s.isInline||!s.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=s}s.markSet="_"==h?null:h?lt(this,h.split(" ")):""!=h&&s.inlineContent?null:[]}for(var u in this.marks){var c=this.marks[u],l=c.spec.excludes;c.excluded=null==l?[c]:""==l?[]:lt(this,l.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}return y(t,[{key:"node",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0;if("string"==typeof t)t=this.nodeType(t);else{if(!(t instanceof at))throw new RangeError("Invalid node type: "+t);if(t.schema!=this)throw new RangeError("Node type from different schema used ("+t.name+")")}return t.createChecked(e,n,r)}},{key:"text",value:function(t,e){var n=this.nodes.text;return new U(n,n.defaultAttrs,t,O.setFrom(e))}},{key:"mark",value:function(t,e){return"string"==typeof t&&(t=this.marks[t]),t.create(e)}},{key:"nodeFromJSON",value:function(t){return $.fromJSON(this,t)}},{key:"markFromJSON",value:function(t){return O.fromJSON(this,t)}},{key:"nodeType",value:function(t){var e=this.nodes[t];if(!e)throw new RangeError("Unknown node type: "+t);return e}}]),t}();function lt(t,e){for(var n=[],r=0;r<e.length;r++){var i=e[r],o=t.marks[i],s=o;if(o)n.push(o);else for(var a in t.marks){var h=t.marks[a];("_"==i||h.spec.group&&h.spec.group.split(" ").indexOf(i)>-1)&&n.push(s=h)}if(!s)throw new SyntaxError("Unknown mark type: '"+e[r]+"'")}return n}var ft=function(){function t(e,n){var r=this;d(this,t),this.schema=e,this.rules=n,this.tags=[],this.styles=[];var i=this.matchedStyles=[];n.forEach((function(t){if(function(t){return null!=t.tag}(t))r.tags.push(t);else if(function(t){return null!=t.style}(t)){var e=/[^=]*/.exec(t.style)[0];i.indexOf(e)<0&&i.push(e),r.styles.push(t)}})),this.normalizeLists=!this.tags.some((function(t){if(!/^(ul|ol)\b/.test(t.tag)||!t.node)return!1;var n=e.nodes[t.node];return n.contentMatch.matchType(n)}))}return y(t,[{key:"parse",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=new kt(this,e,!1);return n.addAll(t,O.none,e.from,e.to),n.finish()}},{key:"parseSlice",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=new kt(this,e,!0);return n.addAll(t,O.none,e.from,e.to),C.maxOpen(n.finish())}},{key:"matchTag",value:function(t,e,n){for(var r=n?this.tags.indexOf(n)+1:0;r<this.tags.length;r++){var i=this.tags[r];if(gt(t,i.tag)&&(void 0===i.namespace||t.namespaceURI==i.namespace)&&(!i.context||e.matchesContext(i.context))){if(i.getAttrs){var o=i.getAttrs(t);if(!1===o)continue;i.attrs=o||void 0}return i}}}},{key:"matchStyle",value:function(t,e,n,r){for(var i=r?this.styles.indexOf(r)+1:0;i<this.styles.length;i++){var o=this.styles[i],s=o.style;if(!(0!=s.indexOf(t)||o.context&&!n.matchesContext(o.context)||s.length>t.length&&(61!=s.charCodeAt(t.length)||s.slice(t.length+1)!=e))){if(o.getAttrs){var a=o.getAttrs(e);if(!1===a)continue;o.attrs=a||void 0}return o}}}}],[{key:"schemaRules",value:function(t){var e=[];function n(t){for(var n=null==t.priority?50:t.priority,r=0;r<e.length;r++){var i=e[r];if((null==i.priority?50:i.priority)<n)break}e.splice(r,0,t)}var r=function(e){var r=t.marks[e].spec.parseDOM;r&&r.forEach((function(t){n(t=xt(t)),t.mark||t.ignore||t.clearMark||(t.mark=e)}))};for(var i in t.marks)r(i);var o=function(e){var r=t.nodes[e].spec.parseDOM;r&&r.forEach((function(t){n(t=xt(t)),t.node||t.ignore||t.mark||(t.node=e)}))};for(var s in t.nodes)o(s);return e}},{key:"fromSchema",value:function(e){return e.cached.domParser||(e.cached.domParser=new t(e,t.schemaRules(e)))}}]),t}(),pt={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},dt={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},vt={ol:!0,ul:!0};function yt(t,e,n){return null!=e?(e?1:0)|("full"===e?2:0):t&&"pre"==t.whitespace?3:-5&n}var mt=function(){function t(e,n,r,i,o,s){d(this,t),this.type=e,this.attrs=n,this.marks=r,this.solid=i,this.options=s,this.content=[],this.activeMarks=O.none,this.match=o||(4&s?null:e.contentMatch)}return y(t,[{key:"findWrapping",value:function(t){if(!this.match){if(!this.type)return[];var e=this.type.contentMatch.fillBefore(x.from(t));if(!e){var n,r=this.type.contentMatch;return(n=r.findWrapping(t.type))?(this.match=r,n):null}this.match=this.type.contentMatch.matchFragment(e)}return this.match.findWrapping(t.type)}},{key:"finish",value:function(t){if(!(1&this.options)){var e,n=this.content[this.content.length-1];if(n&&n.isText&&(e=/[ \t\r\n\u000c]+$/.exec(n.text))){var r=n;n.text.length==e[0].length?this.content.pop():this.content[this.content.length-1]=r.withText(r.text.slice(0,r.text.length-e[0].length))}}var i=x.from(this.content);return!t&&this.match&&(i=i.append(this.match.fillBefore(x.empty,!0))),this.type?this.type.create(this.attrs,i,this.marks):i}},{key:"inlineContext",value:function(t){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:t.parentNode&&!pt.hasOwnProperty(t.parentNode.nodeName.toLowerCase())}}]),t}(),kt=function(){function t(e,n,r){d(this,t),this.parser=e,this.options=n,this.isOpen=r,this.open=0;var i,o=n.topNode,s=yt(null,n.preserveWhitespace,0)|(r?4:0);i=o?new mt(o.type,o.attrs,O.none,!0,n.topMatch||o.type.contentMatch,s):new mt(r?null:e.schema.topNodeType,null,O.none,!0,null,s),this.nodes=[i],this.find=n.findPositions,this.needsBlock=!1}return y(t,[{key:"top",get:function(){return this.nodes[this.open]}},{key:"addDOM",value:function(t,e){3==t.nodeType?this.addTextNode(t,e):1==t.nodeType&&this.addElement(t,e)}},{key:"addTextNode",value:function(t,e){var n=t.nodeValue,r=this.top;if(2&r.options||r.inlineContext(t)||/[^ \t\r\n\u000c]/.test(n)){if(1&r.options)n=2&r.options?n.replace(/\r\n?/g,"\n"):n.replace(/\r?\n|\r/g," ");else if(n=n.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(n)&&this.open==this.nodes.length-1){var i=r.content[r.content.length-1],o=t.previousSibling;(!i||o&&"BR"==o.nodeName||i.isText&&/[ \t\r\n\u000c]$/.test(i.text))&&(n=n.slice(1))}n&&this.insertNode(this.parser.schema.text(n),e),this.findInText(t)}else this.findInside(t)}},{key:"addElement",value:function(t,e,n){var r,i=t.nodeName.toLowerCase();vt.hasOwnProperty(i)&&this.parser.normalizeLists&&function(t){for(var e=t.firstChild,n=null;e;e=e.nextSibling){var r=1==e.nodeType?e.nodeName.toLowerCase():null;r&&vt.hasOwnProperty(r)&&n?(n.appendChild(e),e=n):"li"==r?n=e:r&&(n=null)}}(t);var o=this.options.ruleFromNode&&this.options.ruleFromNode(t)||(r=this.parser.matchTag(t,this,n));if(o?o.ignore:dt.hasOwnProperty(i))this.findInside(t),this.ignoreFallback(t,e);else if(!o||o.skip||o.closeParent){o&&o.closeParent?this.open=Math.max(0,this.open-1):o&&o.skip.nodeType&&(t=o.skip);var s,a=this.top,h=this.needsBlock;if(pt.hasOwnProperty(i))a.content.length&&a.content[0].isInline&&this.open&&(this.open--,a=this.top),s=!0,a.type||(this.needsBlock=!0);else if(!t.firstChild)return void this.leafFallback(t,e);var u=o&&o.skip?e:this.readStyles(t,e);u&&this.addAll(t,u),s&&this.sync(a),this.needsBlock=h}else{var c=this.readStyles(t,e);c&&this.addElementByRule(t,o,c,!1===o.consuming?r:void 0)}}},{key:"leafFallback",value:function(t,e){"BR"==t.nodeName&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(t.ownerDocument.createTextNode("\n"),e)}},{key:"ignoreFallback",value:function(t,e){"BR"!=t.nodeName||this.top.type&&this.top.type.inlineContent||this.findPlace(this.parser.schema.text("-"),e)}},{key:"readStyles",value:function(t,e){var n=this,r=t.style;if(r&&r.length)for(var i=0;i<this.parser.matchedStyles.length;i++){var o=this.parser.matchedStyles[i],s=r.getPropertyValue(o);if(s)for(var a,h=function(t){var r=n.parser.matchStyle(o,s,n,t);return r?r.ignore?{v:null}:(e=r.clearMark?e.filter((function(t){return!r.clearMark(t)})):e.concat(n.parser.schema.marks[r.mark].create(r.attrs)),!1!==r.consuming?(u=t,0):void(u=t=r)):(u=t,0)},u=void 0;0!==(a=h(u));)if(a)return a.v}return e}},{key:"addElementByRule",value:function(t,e,n,r){var i,o,s=this;if(e.node)if((o=this.parser.schema.nodes[e.node]).isLeaf)this.insertNode(o.create(e.attrs),n)||this.leafFallback(t,n);else{var a=this.enter(o,e.attrs||null,n,e.preserveWhitespace);a&&(i=!0,n=a)}else{var h=this.parser.schema.marks[e.mark];n=n.concat(h.create(e.attrs))}var u=this.top;if(o&&o.isLeaf)this.findInside(t);else if(r)this.addElement(t,n,r);else if(e.getContent)this.findInside(t),e.getContent(t,this.parser.schema).forEach((function(t){return s.insertNode(t,n)}));else{var c=t;"string"==typeof e.contentElement?c=t.querySelector(e.contentElement):"function"==typeof e.contentElement?c=e.contentElement(t):e.contentElement&&(c=e.contentElement),this.findAround(t,c,!0),this.addAll(c,n),this.findAround(t,c,!1)}i&&this.sync(u)&&this.open--}},{key:"addAll",value:function(t,e,n,r){for(var i=n||0,o=n?t.childNodes[n]:t.firstChild,s=null==r?null:t.childNodes[r];o!=s;o=o.nextSibling,++i)this.findAtPoint(t,i),this.addDOM(o,e);this.findAtPoint(t,i)}},{key:"findPlace",value:function(t,e){for(var n,r,i=this.open;i>=0;i--){var o=this.nodes[i],s=o.findWrapping(t);if(s&&(!n||n.length>s.length)&&(n=s,r=o,!s.length))break;if(o.solid)break}if(!n)return null;this.sync(r);for(var a=0;a<n.length;a++)e=this.enterInner(n[a],null,e,!1);return e}},{key:"insertNode",value:function(t,e){if(t.isInline&&this.needsBlock&&!this.top.type){var n=this.textblockFromContext();n&&(e=this.enterInner(n,null,e))}var i=this.findPlace(t,e);if(i){this.closeExtra();var o=this.top;o.match&&(o.match=o.match.matchType(t.type));var s,a=O.none,h=r(i.concat(t.marks));try{for(h.s();!(s=h.n()).done;){var u=s.value;(o.type?o.type.allowsMarkType(u.type):wt(u.type,t.type))&&(a=u.addToSet(a))}}catch(t){h.e(t)}finally{h.f()}return o.content.push(t.mark(a)),!0}return!1}},{key:"enter",value:function(t,e,n,r){var i=this.findPlace(t.create(e),n);return i&&(i=this.enterInner(t,e,n,!0,r)),i}},{key:"enterInner",value:function(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],i=arguments.length>4?arguments[4]:void 0;this.closeExtra();var o=this.top;o.match=o.match&&o.match.matchType(t);var s=yt(t,i,o.options);4&o.options&&0==o.content.length&&(s|=4);var a=O.none;return n=n.filter((function(e){return!(o.type?o.type.allowsMarkType(e.type):wt(e.type,t))||(a=e.addToSet(a),!1)})),this.nodes.push(new mt(t,e,a,r,null,s)),this.open++,n}},{key:"closeExtra",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this.nodes.length-1;if(e>this.open){for(;e>this.open;e--)this.nodes[e-1].content.push(this.nodes[e].finish(t));this.nodes.length=this.open+1}}},{key:"finish",value:function(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(this.isOpen||this.options.topOpen)}},{key:"sync",value:function(t){for(var e=this.open;e>=0;e--)if(this.nodes[e]==t)return this.open=e,!0;return!1}},{key:"currentPos",get:function(){this.closeExtra();for(var t=0,e=this.open;e>=0;e--){for(var n=this.nodes[e].content,r=n.length-1;r>=0;r--)t+=n[r].nodeSize;e&&t++}return t}},{key:"findAtPoint",value:function(t,e){if(this.find)for(var n=0;n<this.find.length;n++)this.find[n].node==t&&this.find[n].offset==e&&(this.find[n].pos=this.currentPos)}},{key:"findInside",value:function(t){if(this.find)for(var e=0;e<this.find.length;e++)null==this.find[e].pos&&1==t.nodeType&&t.contains(this.find[e].node)&&(this.find[e].pos=this.currentPos)}},{key:"findAround",value:function(t,e,n){if(t!=e&&this.find)for(var r=0;r<this.find.length;r++){if(null==this.find[r].pos&&1==t.nodeType&&t.contains(this.find[r].node))e.compareDocumentPosition(this.find[r].node)&(n?2:4)&&(this.find[r].pos=this.currentPos)}}},{key:"findInText",value:function(t){if(this.find)for(var e=0;e<this.find.length;e++)this.find[e].node==t&&(this.find[e].pos=this.currentPos-(t.nodeValue.length-this.find[e].offset))}},{key:"matchesContext",value:function(t){var e=this;if(t.indexOf("|")>-1)return t.split(/\s*\|\s*/).some(this.matchesContext,this);var n=t.split("/"),r=this.options.context,i=!(this.isOpen||r&&r.parent.type!=this.nodes[0].type),o=-(r?r.depth+1:0)+(i?0:1);return function t(s,a){for(;s>=0;s--){var h=n[s];if(""==h){if(s==n.length-1||0==s)continue;for(;a>=o;a--)if(t(s-1,a))return!0;return!1}var u=a>0||0==a&&i?e.nodes[a].type:r&&a>=o?r.node(a-o).type:null;if(!u||u.name!=h&&!u.isInGroup(h))return!1;a--}return!0}(n.length-1,this.open)}},{key:"textblockFromContext",value:function(){var t=this.options.context;if(t)for(var e=t.depth;e>=0;e--){var n=t.node(e).contentMatchAt(t.indexAfter(e)).defaultType;if(n&&n.isTextblock&&n.defaultAttrs)return n}for(var r in this.parser.schema.nodes){var i=this.parser.schema.nodes[r];if(i.isTextblock&&i.defaultAttrs)return i}}}]),t}();function gt(t,e){return(t.matches||t.msMatchesSelector||t.webkitMatchesSelector||t.mozMatchesSelector).call(t,e)}function xt(t){var e={};for(var n in t)e[n]=t[n];return e}function wt(t,e){var n,r=e.schema.nodes,i=function(){var n=r[o];if(!n.allowsMarkType(t))return 0;var i=[];return function t(n){i.push(n);for(var r=0;r<n.edgeCount;r++){var o=n.edge(r),s=o.type,a=o.next;if(s==e)return!0;if(i.indexOf(a)<0&&t(a))return!0}}(n.contentMatch)?{v:!0}:void 0};for(var o in r)if(0!==(n=i())&&n)return n.v}var St=function(){function t(e,n){d(this,t),this.nodes=e,this.marks=n}return y(t,[{key:"serializeFragment",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0;r||(r=Ot(n).createDocumentFragment());var i=r,o=[];return t.forEach((function(t){if(o.length||t.marks.length){for(var r=0,s=0;r<o.length&&s<t.marks.length;){var a=t.marks[s];if(e.marks[a.type.name]){if(!a.eq(o[r][0])||!1===a.type.spec.spanning)break;r++,s++}else s++}for(;r<o.length;)i=o.pop()[1];for(;s<t.marks.length;){var h=t.marks[s++],u=e.serializeMark(h,t.isInline,n);u&&(o.push([h,i]),i.appendChild(u.dom),i=u.contentDOM||u.dom)}}i.appendChild(e.serializeNodeInner(t,n))})),r}},{key:"serializeNodeInner",value:function(t,e){var n=Tt(Ot(e),this.nodes[t.type.name](t),null,t.attrs),r=n.dom,i=n.contentDOM;if(i){if(t.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(t.content,e,i)}return r}},{key:"serializeNode",value:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.serializeNodeInner(t,e),r=t.marks.length-1;r>=0;r--){var i=this.serializeMark(t.marks[r],t.isInline,e);i&&((i.contentDOM||i.dom).appendChild(n),n=i.dom)}return n}},{key:"serializeMark",value:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this.marks[t.type.name];return r&&Tt(Ot(n),r(t,e),null,t.attrs)}}],[{key:"renderSpec",value:function(t,e){return Tt(t,e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,arguments.length>3?arguments[3]:void 0)}},{key:"fromSchema",value:function(e){return e.cached.domSerializer||(e.cached.domSerializer=new t(this.nodesFromSchema(e),this.marksFromSchema(e)))}},{key:"nodesFromSchema",value:function(t){var e=bt(t.nodes);return e.text||(e.text=function(t){return t.text}),e}},{key:"marksFromSchema",value:function(t){return bt(t.marks)}}]),t}();function bt(t){var e={};for(var n in t){var r=t[n].spec.toDOM;r&&(e[n]=r)}return e}function Ot(t){return t.document||window.document}var Et=new WeakMap;function Ct(t){var e=Et.get(t);return void 0===e&&Et.set(t,e=function(t){var e=null;function n(t){if(t&&"object"==p(t))if(Array.isArray(t))if("string"==typeof t[0])e||(e=[]),e.push(t);else for(var r=0;r<t.length;r++)n(t[r]);else for(var i in t)n(t[i])}return n(t),e}(t)),e}function Tt(t,e,n,r){if("string"==typeof e)return{dom:t.createTextNode(e)};if(null!=e.nodeType)return{dom:e};if(e.dom&&null!=e.dom.nodeType)return e;var i,o=e[0];if("string"!=typeof o)throw new RangeError("Invalid array passed to renderSpec");if(r&&(i=Ct(r))&&i.indexOf(e)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");var s,a=o.indexOf(" ");a>0&&(n=o.slice(0,a),o=o.slice(a+1));var h=n?t.createElementNS(n,o):t.createElement(o),u=e[1],c=1;if(u&&"object"==p(u)&&null==u.nodeType&&!Array.isArray(u))for(var l in c=2,u)if(null!=u[l]){var f=l.indexOf(" ");f>0?h.setAttributeNS(l.slice(0,f),l.slice(f+1),u[l]):h.setAttribute(l,u[l])}for(var d=c;d<e.length;d++){var v=e[d];if(0===v){if(d<e.length-1||d>c)throw new RangeError("Content hole must be the only child of its parent node");return{dom:h,contentDOM:h}}var y=Tt(t,v,n,r),m=y.dom,k=y.contentDOM;if(h.appendChild(m),k){if(s)throw new RangeError("Multiple content holes");s=k}}return{dom:h,contentDOM:s}}return t.ContentMatch=V,t.DOMParser=ft,t.DOMSerializer=St,t.Fragment=x,t.Mark=O,t.MarkType=ut,t.Node=$,t.NodeRange=_,t.NodeType=at,t.ReplaceError=E,t.ResolvedPos=D,t.Schema=ct,t.Slice=C,t}export{r as __require};
|
2
|
-
//# sourceMappingURL=index.mjs.map
|