@ones-editor/editor 0.0.3-beta.200 → 0.0.3-beta.201

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- (function(){"use strict";try{if(typeof document!="undefined"){var t=document.createElement("style");t.appendChild(document.createTextNode(`@keyframes ones-editor-blink{0%,to{background-color:transparent}50%{background-color:var(--primary-color)}}*{--link-color: #338fe5;--color-0: #e52727;--color-1: #eb6414;--color-2: #f0a100;--color-3: #24b47e;--color-4: #338fe5;--color-5: #9678d3;--color-6: #909090;--background-color-0: #fad4d4;--background-color-1: #fbe0d0;--background-color-2: #fceccc;--background-color-3: #d3f0e5;--background-color-4: #d6e9fa;--background-color-5: #eae4f6;--background-color-6: #dedede;--background-color-7: #e52727;--background-color-8: #eb6414;--background-color-9: #f0a100;--background-color-10: #24b47e;--background-color-11: #338fe5;--background-color-12: #9678d3;--background-color-13: #909090;--background-color-14: #e8e8e8;--font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif}div.editor-root{--text-color: #303030;--primary-color: #338fe5;--background-selection: #338fe533;--background-code: #cdcdcd40}div.editor-root{color:var(--text-color);position:relative;box-sizing:border-box;min-height:100%;width:100%;z-index:1}div.editor-root.readonly div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span.text.link{cursor:pointer}div.editor-root *{box-sizing:border-box;font-family:var(--font-family)}div.editor-root button{outline:none}div.editor-root.active div.editor-content .editor-cursor{opacity:1}div.editor-root .safari.mobile div.editor-content .editor-input{pointer-events:all;width:8px}div.editor-root div.editor-content{height:100%;width:100%;padding:0 30px 30px}div.editor-root div.editor-content .editor-cursor{position:absolute;background:var(--primary-color);width:2px;transition:top .1s ease-in,left .1s linear;animation:ones-editor-blink 1s ease-in-out infinite;opacity:0;pointer-events:none}div.editor-root div.editor-content .editor-input{position:absolute;opacity:0;pointer-events:none;width:16px;height:20px;font-size:16px}div.editor-root div.editor-content div[data-type=editor-container]{position:relative}div.editor-root div.editor-content div[data-type=editor-container].root{user-select:none;width:100%;cursor:text}div.editor-root div.editor-content div[data-type=editor-container].root>.container-blocks>*+*{margin-top:1em}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block]:not(:first-of-type){background-color:var(--background-selection)}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block]:not(:first-of-type) div[data-type=block-background]>.editor-selection-background{background-color:transparent!important}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block].embed-block>div[data-type=block-content]:before,div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block].embed-block .embed-selected-content:before{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]+div[data-type=editor-block][data-style-quoted]{margin-top:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block]{font-size:var(--font-size);line-height:var(--line-height);position:relative;--font-size: 15px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=center] div[data-type=block-content]{text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=right] div[data-type=block-content]{text-align:end}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].block-hidden{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=text]{cursor:text}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]{word-break:break-word;position:relative}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span{cursor:text}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text{white-space:pre-wrap}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link{color:var(--link-color)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link:hover{text-decoration:underline}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link.style-strikethrough:hover{text-decoration:underline line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-bold{font-weight:700}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-italic{font-style:italic}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-underline{text-decoration:underline}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-strikethrough{text-decoration:line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-underline.style-strikethrough{text-decoration:underline line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-code{border-radius:5px;-moz-border-radius:5px;-webkit-border-radius:5px;background-color:var(--background-code);padding:4px;font:.8em Monaco,Consolas,"Andale Mono",DejaVu Sans Mono,monospace}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-sub{vertical-align:sub;font-size:70%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-super{vertical-align:super;font-size:70%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="0"]{color:var(--color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="1"]{color:var(--color-1)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="2"]{color:var(--color-2)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="3"]{color:var(--color-3)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="4"]{color:var(--color-4)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="5"]{color:var(--color-5)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="6"]{color:var(--color-6)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="0"]{background-color:var(--background-color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="1"]{background-color:var(--background-color-1)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="2"]{background-color:var(--background-color-2)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="3"]{background-color:var(--background-color-3)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="4"]{background-color:var(--background-color-4)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="5"]{background-color:var(--background-color-5)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="6"]{background-color:var(--background-color-6)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="7"]{background-color:var(--background-color-7)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="8"]{background-color:var(--background-color-8)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="9"]{background-color:var(--background-color-9)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="10"]{background-color:var(--background-color-10)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="11"]{background-color:var(--background-color-11)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="12"]{background-color:var(--background-color-12)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="13"]{background-color:var(--background-color-13)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="14"]{background-color:var(--background-color-14)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].inputting-insertion>span[data-type=insertion-content]{border-bottom:1px solid var(--primary-color)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion{width:0px;position:relative;display:inline-block;vertical-align:text-bottom;overflow:visible;height:1em}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content]{position:absolute;color:transparent;width:3px;left:-3px;border-right:var(--cursor-color) 1px solid;text-overflow:clip;display:inline-block;top:-5px;bottom:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content] span[data-cursor-name]{display:inline-block;width:8px;background-color:transparent;border:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content] span[data-cursor-name]:hover:before,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion.active>span[data-type=insertion-content] span[data-cursor-name]:before{content:attr(data-cursor-name);position:absolute;top:-12px;height:1.1em;background-color:var(--cursor-color);z-index:27;left:0px;color:#fff;white-space:nowrap;font-size:12px;display:flex;align-items:center;padding:1px 4px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=box-content]{border-radius:2px;margin-left:8px;margin-right:8px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=editor-box].br-box>span[data-type=box-content] img{vertical-align:middle;max-width:1em}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=editor-box][data-box-type=image].image-box span[data-type=box-content]{user-select:none;margin-left:0;margin-right:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-tools] .editor-block-anchor{position:absolute}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-background] .editor-selection-background{position:absolute;background-color:var(--background-selection);z-index:1;pointer-events:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block{cursor:default}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.hover>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block.hover>div[data-type=block-content]{outline:1px solid #338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block>div[data-type=block-content]{display:flex}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.hover .embed-hover-content{outline:1px solid #338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected .embed-selected-content{position:relative}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected>div[data-type=block-content]:before,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected .embed-selected-content:before{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#338fe5;opacity:.1}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block{color:#909090;font-size:12px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block>div[data-type=block-content]{padding:5px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]{border-left:4px solid #e8e8e8;color:#909090}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]:not([data-list-level]){padding-left:8px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="1"]{--font-size: 28px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="1"]:not(:first-child){margin-top:24px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="2"]{--font-size: 26px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="2"]:not(:first-child){margin-top:24px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="3"]{--font-size: 24px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="3"]:not(:first-child){margin-top:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="4"]{--font-size: 22px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="4"]:not(:first-child){margin-top:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="5"]{--font-size: 20px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="5"]:not(:first-child){margin-top:16px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="6"]{--font-size: 18px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="6"]:not(:first-child){margin-top:16px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="7"]{--font-size: 16px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="8"]{--font-size: 14px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading]{font-size:var(--font-size);line-height:var(--line-height);font-weight:700}.editor-disable-scroll{position:fixed;left:0;top:0;width:100vw;height:100vh;z-index:9900;overflow:hidden}div:not(.comment-editor-root)>div.editor-root>div.editor-content>div[data-type=editor-container]>div.container-blocks>div[data-type=editor-block]:first-of-type{font-size:30px;line-height:1.3}div.comment-editor-root div.root.select-all>.container-blocks>div[data-type=editor-block]:first-of-type{background-color:var(--background-selection)}div.comment-editor-root div.root.select-all>.container-blocks>div[data-type=editor-block]:first-of-type div[data-type=block-background]>.editor-selection-background{background-color:transparent!important}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-anchor{position:absolute;pointer-events:none;z-index:-1}.editor-command-bar.toolbar .color-button{width:24px;height:24px;display:flex;padding:0;margin:0;align-items:center;justify-content:center;background-color:transparent;border:0;outline:0;border-radius:3px;cursor:pointer}.editor-command-bar.toolbar .color-button[data-color="0"]{color:var(--color-0)}.editor-command-bar.toolbar .color-button[data-color="1"]{color:var(--color-1)}.editor-command-bar.toolbar .color-button[data-color="2"]{color:var(--color-2)}.editor-command-bar.toolbar .color-button[data-color="3"]{color:var(--color-3)}.editor-command-bar.toolbar .color-button[data-color="4"]{color:var(--color-4)}.editor-command-bar.toolbar .color-button[data-color="5"]{color:var(--color-5)}.editor-command-bar.toolbar .color-button[data-color="6"]{color:var(--color-6)}.editor-command-bar.toolbar .color-button[data-background-color="0"]{background-color:var(--background-color-0)}.editor-command-bar.toolbar .color-button[data-background-color="1"]{background-color:var(--background-color-1)}.editor-command-bar.toolbar .color-button[data-background-color="2"]{background-color:var(--background-color-2)}.editor-command-bar.toolbar .color-button[data-background-color="3"]{background-color:var(--background-color-3)}.editor-command-bar.toolbar .color-button[data-background-color="4"]{background-color:var(--background-color-4)}.editor-command-bar.toolbar .color-button[data-background-color="5"]{background-color:var(--background-color-5)}.editor-command-bar.toolbar .color-button[data-background-color="6"]{background-color:var(--background-color-6)}.editor-command-bar.toolbar .color-button[data-background-color="7"]{background-color:var(--background-color-7)}.editor-command-bar.toolbar .color-button[data-background-color="8"]{background-color:var(--background-color-8)}.editor-command-bar.toolbar .color-button[data-background-color="9"]{background-color:var(--background-color-9)}.editor-command-bar.toolbar .color-button[data-background-color="10"]{background-color:var(--background-color-10)}.editor-command-bar.toolbar .color-button[data-background-color="11"]{background-color:var(--background-color-11)}.editor-command-bar.toolbar .color-button[data-background-color="12"]{background-color:var(--background-color-12)}.editor-command-bar.toolbar .color-button[data-background-color="13"]{background-color:var(--background-color-13)}.editor-command-bar.toolbar .color-button[data-background-color="14"]{background-color:var(--background-color-14)}.tippy-content{white-space:pre-line}.editor-button{min-height:26px;min-width:46px;font-size:12px;font-weight:400;outline:none;background-color:#fff;color:#606060;border:1px solid #c7c7c7;padding:4px 8px;border-radius:4px;margin-right:8px;cursor:pointer}.editor-button:disabled{cursor:not-allowed;opacity:.5;background-color:#e8e8e8}.editor-button:not(:disabled):hover{border:1px solid #338fe5;background-color:#eaf3fc;color:#338fe5}.editor-button.primary{font-weight:500;border:1px solid rgba(0,0,0,0);background-color:var(--editor-button-bg-color, #338fe5);color:var(--editor-button-color, #fff)}.editor-button.primary:not(:disabled):hover{background-color:#5ca5ea;border:1px solid rgba(0,0,0,0);color:var(--editor-button-color, #fff)}.editor-button.primary:disabled{cursor:not-allowed;opacity:.5}.editor-button.primary:not(:disabled):active{background-color:#2872b7;color:#fff;border-color:#2872b7}.editor-button:last-child{margin-right:0}.editor-button:not(:disabled):active{background-color:#d6e9fa;color:#2872b7;border-color:#2872b7}.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}[data-theme=dropdown-list]{border-radius:4px;background:white;position:relative;max-width:calc(100vw - 24px);box-shadow:#0f0f0f0d 0 0 0 1px,#0f0f0f1a 0 3px 6px,#0f0f0f33 0 9px 24px;overflow:hidden}[data-theme=dropdown-list] .tippy-content{padding:0;background:white;color:#303030}[data-theme=dropdown-list] .tippy-content .editor-command-bar{max-height:50vh}[data-theme=dropdown-list] .filterable-list{min-width:100px;max-width:300px;display:flex;flex-direction:column;max-height:100%}[data-theme=dropdown-list] .filterable-list .filter{padding:8px}[data-theme=dropdown-list] .filterable-list .filter .filter-container{width:100%;font-size:14px;line-height:20px;padding:3px 6px;position:relative;border-radius:3px;box-shadow:#0f0f0f1a 0 0 0 1px inset;background:rgba(242,241,238,.6);cursor:text;height:28px;box-sizing:border-box;display:flex;align-items:center}[data-theme=dropdown-list] .filterable-list .filter .filter-container input.filter-input{border:none;outline:none;flex-grow:1;background:transparent}[data-theme=dropdown-list] .filterable-list .list{max-height:60vh;overflow-y:auto;padding:8px 0}[data-theme=dropdown-list] .filterable-list .list .list-item{user-select:none;transition:background 20ms ease-in 0s;cursor:pointer;width:calc(100% - 8px);margin-left:4px;margin-right:4px;border-radius:3px;height:24px;padding:4px 8px;display:flex;align-items:center;box-sizing:border-box}[data-theme=dropdown-list] .filterable-list .list .list-item .list-text{white-space:nowrap}[data-theme=dropdown-list] .filterable-list .list .list-item.selected{background-color:#eee}[data-theme=dropdown-list] .filterable-list .list .list-item.disabled{color:#c1c1c1}::placeholder{color:#bbb}.toast{font-family:Avenir,Helvetica,Arial,sans-serif;visibility:hidden;min-width:250px;margin-left:-125px;background-color:#333;color:#fff;text-align:center;border-radius:2px;padding:8px;position:fixed;z-index:1;left:50%;bottom:30px}.toast.show{visibility:visible;animation:toast_fade_in .5s,toast_fade_out .5s 2.5s}.toast.positioned.show{animation:toast_fade_in_positioned .5s,toast_fade_out_positioned .5s 2.5s}.toast.positioned{bottom:unset}@keyframes toast_fade_in{0%{bottom:0;opacity:0}to{bottom:30px;opacity:1}}@keyframes toast_fade_out{0%{bottom:30px;opacity:1}to{bottom:0;opacity:0}}@keyframes toast_fade_in_positioned{0%{opacity:0}to{opacity:1}}@keyframes toast_fade_out_positioned{0%{opacity:1}to{opacity:0}}div.tippy-box[data-theme=toolbar] .tippy-content,div.tippy-box[data-theme=menu] .tippy-content{padding:0}div.tippy-box[data-theme=menu] .tippy-content .editor-command-bar.menu{min-width:180px}div.tippy-box[data-theme=menu] .tippy-content .editor-command-bar-root,div.tippy-box[data-theme=toolbar] .tippy-content .editor-command-bar-root{box-shadow:0 0 1px #30303040,0 12px 24px #30303026}div.tippy-box button{outline:none}.editor-command-bar-root{display:flex;flex-direction:column;align-items:flex-start;background:#ffffff;border-radius:2px;max-height:50vh;overflow:auto}.editor-command-bar-root.scrollable-bar>.editor-command-bar.menu{overflow-y:auto}.editor-command-bar{pointer-events:all;display:flex;box-sizing:border-box;--text-color: #606060;--primary-color: #338fe5;--selected-color: #f8f8f8;--separator-color: #e8e8e8;--warn-color: #fdf4f4}.editor-command-bar.fixed.toolbar{box-shadow:none}.editor-command-bar.menu{flex:1;width:100%;display:flex;flex-direction:column;align-items:flex-start;padding:5px 0}.editor-command-bar.menu .command-item.standard{color:#303030;user-select:none;transition:background 20ms ease-in 0s;cursor:pointer;width:100%;height:32px;padding:6px 10px;display:flex;align-items:center;box-sizing:border-box}.editor-command-bar.menu .command-item.standard .menu-item-icon{align-items:center;height:24px;width:24px;margin-right:5px;margin-top:-2px;display:flex;flex-direction:column;justify-content:center}.editor-command-bar.menu .command-item.standard .menu-item-name{white-space:nowrap;flex-grow:1;display:flex;align-items:center}.editor-command-bar.menu .command-item.standard .item-subtext{color:#b2bccd}.editor-command-bar.menu .command-item.standard .menu-item-sub-indicator{display:flex;align-items:center;justify-content:center}.editor-command-bar.menu .command-item.standard .menu-item-sub-indicator svg{width:16px;height:16px}.editor-command-bar.menu .command-item.standard.disabled{color:#c7c7c7;cursor:not-allowed}.editor-command-bar.menu .command-item.separator{height:1px;margin:4px 0;background-color:var(--separator-color);width:100%}.editor-command-bar.menu .command-item.section{font-size:.8em;color:#ccc;padding:5px 5px 5px 10px}.editor-command-bar.menu .command-item.selected{background-color:var(--selected-color)}.editor-command-bar.menu .command-item.selected[data-id=delete]{color:#e52727;background-color:var(--warn-color)}.editor-command-bar.menu .command-item.selected.disabled{background-color:transparent}.editor-command-bar.menu .command-item.checked{color:var(--primary-color)}.editor-command-bar.menu .command-item.checked .menu-item-checked-icon{display:flex;align-items:center;justify-content:center;margin-left:10px}.editor-command-bar.menu .command-item.checked.disabled{color:#c7c7c7}.editor-command-bar.menu .command-item span.highlight{color:#e52727}.editor-command-bar.toolbar{display:flex;flex-direction:row;align-items:flex-start;padding:5px 10px;gap:5px;background:#ffffff;box-shadow:0 0 1px #30303033,0 8px 16px #30303026;border-radius:3px}.editor-command-bar.toolbar .command-item{background:transparent;border:none;display:flex;align-items:center;justify-content:center;color:var(--text-color);height:24px;padding:0;cursor:pointer;border-radius:3px;min-width:24px}.editor-command-bar.toolbar .command-item.selected:not(.disabled){background-color:var(--selected-color)}.editor-command-bar.toolbar .command-item.disabled{color:#c7c7c7}.editor-command-bar.toolbar .command-item.checked{color:var(--primary-color)}.editor-command-bar.toolbar .command-item.checked.disabled{color:#c7c7c7}.editor-command-bar.toolbar .command-item.separator{margin:auto 2px;height:20px;min-width:1px;width:1px;background-color:var(--separator-color);padding:0;pointer-events:none;cursor:default}.editor-command-bar.toolbar .command-item .toolbar-item-name-container,.editor-command-bar.toolbar .command-item .toolbar-item-icon-container{display:flex}.editor-command-bar.toolbar .command-item[data-dropdown=true]{padding-left:4px;padding-right:4px}.editor-command-bar.toolbar .command-item[data-dropdown=true] .toolbar-item-icon-container{width:24px;height:24px;align-items:center;justify-content:center}.editor-command-bar.toolbar .command-item .toolbar-item-dropdown-container{display:flex}.editor-command-bar.toolbar .command-item .toolbar-item-dropdown-container svg{transform:rotate(360deg);transition:transform .2s linear}.editor-command-bar.toolbar .command-item.active .toolbar-item-dropdown-container svg{transform:rotate(180deg)}.editor-command-bar.toolbar .editor-button+.editor-button{margin-left:5px}.editor-command-bar.footer{width:100%}.reference-hidden .tippy-box[data-reference-hidden]{opacity:0;pointer-events:none;transition:none}.tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px #9aa1b126,0 4px 80px -8px #24282f40,0 4px 4px -2px #5b5e6926;background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}.editor-dropdown{display:flex;align-items:center;border:1px solid #C7C7C7;border-radius:3px;font-size:14px;width:200px;height:30px}.editor-dropdown *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}.editor-dropdown .dropdown-text,.editor-dropdown .dropdown-input{flex-grow:1;padding:2px 8px;border:none;outline:none;background:transparent;font-size:14px;color:#333;min-width:0;flex-shrink:1}.editor-dropdown .dropdown-text{margin-right:4.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;height:100%;cursor:text;line-height:24px}.editor-dropdown:hover{border-color:#338fe5}.editor-dropdown.active{border-color:#338fe5;box-shadow:0 0 0 2px #338fe533}.editor-dropdown.active .dropdown-text{display:none}.editor-dropdown:not(.active) .dropdown-input{display:none}.editor-dropdown .dropdown-labels{display:flex;align-items:center;flex-shrink:0}.editor-dropdown .dropdown-labels .dropdown-label{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;border-radius:3px;display:flex;align-items:center}.editor-dropdown .dropdown-labels .dropdown-label+.dropdown-label{margin-left:5px}.editor-dropdown .dropdown-clear-icon,.editor-dropdown .dropdown-icon{flex-shrink:0;width:16px;height:16px;margin-left:4px;display:flex;align-items:center;justify-content:center;cursor:pointer}.editor-dropdown .dropdown-clear-icon{color:#909090}.editor-dropdown .dropdown-clear-icon:hover{color:#338fe5}.editor-dropdown.empty .dropdown-clear-icon,.editor-dropdown:not(:hover) .dropdown-clear-icon{display:none}.editor-dropdown.empty .dropdown-text{color:#909090}.editor-dropdown .dropdown-icon{margin-right:4px}.scale-border:after,.color-palette .palette-container-row .background-color-button.selected:after,.color-palette .palette-container-row .background-color-button:hover:after{content:"";outline:1px solid #d6e9fa;border-radius:3px;position:absolute;left:0;right:0;top:0;bottom:0;transform:scale(1.1)}.color-palette{display:flex;flex-direction:column;align-items:center;padding-top:5px;background-color:#fff;--active-color: #2872b7}.color-palette .bar-desc{box-sizing:border-box;width:100%;height:24px;padding-left:10px;margin-bottom:10px;line-height:24px;font-size:12px;font-weight:500;background:#F8F8F8;color:#909090}.color-palette .palette-container{padding:0 10px}.color-palette .background-color .palette-container-row:first-child{margin-bottom:5px}.color-palette .palette-container-row{display:flex;flex-direction:row;margin-bottom:20px}.color-palette .palette-container-row .color-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;background-color:#fff;border:1px solid #f0f0f0;display:flex;margin:0;padding:0;align-items:center;justify-content:center}.color-palette .palette-container-row .color-button:hover{border:1px solid #d6e9fa}.color-palette .palette-container-row .color-button.selected{border:1px solid var(--primary-color)}.color-palette .palette-container-row .color-button[data-color-index="-1"]{color:var(--text-color)}.color-palette .palette-container-row .color-button[data-color-index="0"]{color:var(--color-0)}.color-palette .palette-container-row .color-button[data-color-index="1"]{color:var(--color-1)}.color-palette .palette-container-row .color-button[data-color-index="2"]{color:var(--color-2)}.color-palette .palette-container-row .color-button[data-color-index="3"]{color:var(--color-3)}.color-palette .palette-container-row .color-button[data-color-index="4"]{color:var(--color-4)}.color-palette .palette-container-row .color-button[data-color-index="5"]{color:var(--color-5)}.color-palette .palette-container-row .color-button[data-color-index="6"]{color:var(--color-6)}.color-palette .palette-container-row .background-color-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;position:relative}.color-palette .palette-container-row .background-color-button.selected:after{outline:1px solid var(--primary-color)}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]{position:relative;background-color:#fff;border:1px solid #e8e8e8}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]:after{transform:scale(1.2)}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]:before{content:"";position:absolute;width:1px;height:56px;top:2px;left:22px;background-color:#c7c7c7;transform:rotate(45deg) scale(.5);transform-origin:-1px -2px}.color-palette .palette-container-row .background-color-button[data-color-index="0"]{background-color:var(--background-color-0)}.color-palette .palette-container-row .background-color-button[data-color-index="1"]{background-color:var(--background-color-1)}.color-palette .palette-container-row .background-color-button[data-color-index="2"]{background-color:var(--background-color-2)}.color-palette .palette-container-row .background-color-button[data-color-index="3"]{background-color:var(--background-color-3)}.color-palette .palette-container-row .background-color-button[data-color-index="4"]{background-color:var(--background-color-4)}.color-palette .palette-container-row .background-color-button[data-color-index="5"]{background-color:var(--background-color-5)}.color-palette .palette-container-row .background-color-button[data-color-index="6"]{background-color:var(--background-color-6)}.color-palette .palette-container-row .background-color-button[data-color-index="7"]{background-color:var(--background-color-7)}.color-palette .palette-container-row .background-color-button[data-color-index="8"]{background-color:var(--background-color-8)}.color-palette .palette-container-row .background-color-button[data-color-index="9"]{background-color:var(--background-color-9)}.color-palette .palette-container-row .background-color-button[data-color-index="10"]{background-color:var(--background-color-10)}.color-palette .palette-container-row .background-color-button[data-color-index="11"]{background-color:var(--background-color-11)}.color-palette .palette-container-row .background-color-button[data-color-index="12"]{background-color:var(--background-color-12)}.color-palette .palette-container-row .background-color-button[data-color-index="13"]{background-color:var(--background-color-13)}.color-palette .palette-container-row .background-color-button[data-color-index="14"]{background-color:var(--background-color-14)}.color-palette .palette-container-row .color-button+.color-button{margin-left:5px}.color-palette .palette-container-row .background-color-button+.background-color-button{margin-left:5px}.color-palette .clear-button-container{box-sizing:border-box;width:100%;margin-bottom:5px;padding:0 10px}.color-palette .clear-button-container .clear-button{box-sizing:border-box;padding:3px 10px;width:100%;height:26px;background:#ffffff;color:#606060;border:1px solid #c7c7c7;border-radius:3px;cursor:pointer}.color-palette .clear-button-container .clear-button:hover{border-color:var(--primary-color);color:var(--primary-color)}.color-palette .clear-button-container .clear-button:active{border-color:var(--active-color);color:var(--active-color);background-color:#d6e9fa}.editor-input-wrap .editor-input-label{margin-top:8px;margin-bottom:8px;position:relative}.editor-input-wrap .editor-input-label.required:before{content:"*";color:#e82100;position:absolute;left:-8px;top:3px}.editor-input-wrap .editor-input-label .span{font-size:14px;line-height:1.4;font-weight:700;color:#303030}.editor-input-wrap .editor-input-container{display:flex;border:none;border-radius:4px;padding:4px;background-color:#fff}.editor-input-wrap .editor-input-container .editor-input{outline:none;border:1px solid #c7c7c7;border-radius:3px;padding:4px 10px;font-size:14px;line-height:1.4;color:#000;width:100%}.editor-input-wrap .editor-input-container .editor-input:focus{border-color:#338fe5;box-shadow:0 0 0 2px #338fe533}.editor-input-wrap.error .editor-input-container{border:1px solid #e82100}.editor-input-wrap.error .editor-input-container .editor-input{border:none;outline:none;box-shadow:unset}.editor-input-wrap.error .editor-input-error{margin-top:8px;color:red;display:block}.editor-input-wrap .editor-input-error{display:none}div.scroll-container-root{position:relative}div.scroll-container-root>div.scroll-container{position:relative;overflow-x:auto;overflow-y:hidden;box-sizing:border-box;line-height:0px}div.scroll-container-root>div.scroll-container>.scroll-area{position:relative;display:inline-block;overflow:hidden;line-height:normal}div.scroll-container-root>div.scroll-container{scrollbar-width:none}div.scroll-container-root>div.scroll-container::-webkit-scrollbar{height:0;opacity:0}div.scroll-container-root>div.container-scroll-tool .container-border-shadow{position:absolute;top:0;opacity:0;width:0;border:none;pointer-events:none;transition:opacity 50ms ease-in;z-index:1}div.scroll-container-root>div.container-scroll-tool .container-right-border-shadow{right:0;background:linear-gradient(90deg,rgba(31,35,41,0) 0,rgba(31,35,41,.1));border-right:0px solid #dee0e3}div.scroll-container-root>div.container-scroll-tool .container-left-border-shadow{left:0;background:linear-gradient(270deg,rgba(31,35,41,0) 0,rgba(31,35,41,.1));border-left:0px solid #dee0e3}div.scroll-container-root>div.container-scroll-tool .container-border-shadow.active{width:8px;opacity:1}div.scroll-container-root>div.container-scroll-tool .container-right-border-shadow.active{border-right-width:1px}div.scroll-container-root>div.container-scroll-tool .container-left-border-shadow.active{border-left-width:1px}div.scroll-container-root>div.container-scroll-tool .container-scrollbar{position:absolute;left:0;z-index:1000;visibility:visible;overflow-x:auto;overflow-y:hidden;cursor:auto}div.scroll-container-root>div.container-scroll-tool .container-scrollbar div{height:1px}div.scroll-container-root>div.container-scroll-tool div.container-scrollbar.fixed{position:fixed}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar{opacity:.6;transition:opacity .1s ease-in-out}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar{height:8px}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-track{background-color:transparent}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-thumb{background-color:#646a73cc;border-radius:8px}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-button{display:none}[data-tippy-root]{font-family:Avenir,Helvetica,Arial,sans-serif}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text]{height:32px;width:unset}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text].selected:hover{background-color:transparent}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text] .link-href-button{max-width:275px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#303030;text-decoration:none}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text] .link-href-button:hover{text-decoration:underline}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link],[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link]{height:32px}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link] svg,[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link] svg{stroke-width:2}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link].selected:hover,[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link].selected:hover{background-color:transparent;color:#338fe5}[data-command-bar-id=quick-menu],[data-command-bar-id=empty-block-menu]{box-sizing:border-box;width:240px}[data-command-bar-id=quick-menu] .command-item.menu-item,[data-command-bar-id=empty-block-menu] .command-item.menu-item{width:100%;cursor:pointer}[data-command-bar-id=quick-menu] .command-item.menu-item.section,[data-command-bar-id=empty-block-menu] .command-item.menu-item.section{height:24px;padding:0 10px;font-weight:500;font-size:12px;line-height:24px;color:#909090;background:#f8f8f8;min-height:initial;box-sizing:border-box;margin:5px 0}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item{color:#303030;display:flex;width:100%;padding:6px 10px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container{display:flex;align-items:center;justify-content:center;padding-right:6px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container .quick-menu-item-icon,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container .quick-menu-item-icon{width:16px;height:16px;display:flex;align-items:center;justify-content:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content{flex-grow:1;display:flex;flex-direction:column;justify-content:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1{display:flex;align-items:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-name,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-name{flex-grow:1;font-size:14px;line-height:22px;color:#303030}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-subtext,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-subtext{color:#b2bccd}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .quick-menu-item-submenu-icon,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .quick-menu-item-submenu-icon{display:flex;align-items:center;margin-left:12px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2{margin-top:5px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2 .item-markdown,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2 .item-markdown{color:#b2bccd}[data-command-bar-id=quick-menu] .command-item.menu-item[data-id=placeholder] .quick-menu-item-icon-container,[data-command-bar-id=empty-block-menu] .command-item.menu-item[data-id=placeholder] .quick-menu-item-icon-container{display:none}[data-command-bar-id=quick-menu] .command-item.menu-item[data-id=placeholder] .item-name.text,[data-command-bar-id=empty-block-menu] .command-item.menu-item[data-id=placeholder] .item-name.text{color:#909090!important;padding:5px 0}[data-command-bar-id=block-menu]{width:240px}[data-command-bar-id=quick-menu] div.command-item>div.menu-item-name{color:#303030}[data-command-bar-id=quick-menu] div.command-item>div.menu-item-icon{color:#606060}[data-command-bar-id=quick-menu] div.command-item.section:first-of-type{margin-top:0}div.tippy-box[data-theme=editor-tooltip]{background-color:#303030;opacity:.8;font-size:12px;border-radius:3px}div.tippy-box[data-theme=editor-tooltip] .editor-tooltip-desc{display:block;margin-top:2px;color:#fff;opacity:.5}div.tippy-box[data-theme=editor-tooltip]>.tippy-arrow:before{transform:scale(.8)}div.tippy-box[data-theme=editor-tooltip]>.tippy-content{padding:4px 10px}:root div.tippy-box[data-theme=editor-tooltip]>.tippy-content{font-weight:500}:root div.tippy-box[data-theme=editor-tooltip]>.tippy-content>div>span:nth-of-type(2){font-weight:400}.link-popup-content{padding:10px 7px}.link-popup-content .link-popup-gap{margin-top:16px}.link-popup-content .editor-input-container{padding:4px 0}.link-popup-content .editor-input-container .editor-input{width:330px;line-height:1.5}.link-popup-content .editor-input-wrap .editor-input-label{margin-bottom:4px}.link-popup-content .link-popup-footer{margin:10px 0 5px;text-align:right}.link-popup-content .link-popup-footer button{min-height:30px;border-radius:3px;font-size:14px}:root{--mindmap-bg-color: #f0f2f4}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.focused [data-type=block-tools] .editor-mindmap-svg{border-radius:3px;outline:1px solid #338FE5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.editor-in-mindmap-first{height:600px;min-width:150px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-content]{margin-right:24px;transition:background-color .25s linear}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .editor-mindmap-svg{position:absolute;left:0;top:0;right:0;bottom:0;z-index:2;font-size:14px;background-color:var(--mindmap-bg-color)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar{position:absolute;top:8px;right:8px;height:24px;z-index:3}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar .editor-button.mindmap-button{background-color:transparent;outline:none;border:none;fill:none;color:#c1c1c1;cursor:pointer;min-width:initial;margin-right:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar .editor-button.mindmap-button:hover{color:#5587f0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.to-mindmap-highlight [data-type=block-content],.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.to-mindmap-highlight:hover [data-type=block-content]{background-color:#eaf3fc}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-to-mindmap-wrap,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .mention-button-wrap{position:absolute;right:0;top:2px;display:flex;align-items:center;height:calc(var(--font-size) * var(--line-height))}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-to-mindmap],.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=mention-button]{flex-grow:0;flex-shrink:0;width:24px;height:24px;min-width:24px;min-height:24px;padding:0;border:0;outline:0;display:flex;align-items:center;justify-content:end;background-color:transparent;color:#07142a;margin-right:8px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-to-mindmap] svg,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=mention-button] svg{width:16px;height:16px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-block-mention]:hover>svg{cursor:initial;background-color:#eee}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button+button[data-button-id=list-block-mention]{right:20px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="1"]{padding-left:24px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="1"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="2"]{padding-left:48px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="2"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="3"]{padding-left:72px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="3"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="4"]{padding-left:96px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="4"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="5"]{padding-left:120px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="5"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="6"]{padding-left:144px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="6"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="7"]{padding-left:168px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="7"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="8"]{padding-left:192px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="8"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="9"]{padding-left:216px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="9"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="10"]{padding-left:240px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="10"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="11"]{padding-left:264px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="11"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="12"]{padding-left:288px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="12"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=list][data-list-level="1"]{padding-left:0}div.editor-root div.editor-content div[data-block-type=list][data-list-level="2"]{padding-left:24px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="3"]{padding-left:48px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="4"]{padding-left:72px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="5"]{padding-left:96px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="6"]{padding-left:120px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="7"]{padding-left:144px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="8"]{padding-left:168px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="9"]{padding-left:192px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="10"]{padding-left:216px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="11"]{padding-left:240px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="12"]{padding-left:264px}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="1"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="2"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="3"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="4"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="5"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="6"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="7"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="8"]>div.list-container>button.list-marker{font-weight:700}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block+div[data-type=editor-block].list-block{margin-top:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block{display:flex;padding-bottom:2px;padding-top:2px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=text-only] .list-container{pointer-events:none}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] div[data-type=block-content] span.text{color:#c7c7c7}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unordered] .list-container .list-marker{font-family:PingFangSC-Regular,PingFang SC;justify-content:space-around}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper{font-feature-settings:"tnum";align-items:baseline;box-sizing:border-box;color:var(--gray-120);cursor:pointer;display:inline-flex;font-size:14px;font-variant:tabular-nums;line-height:1.5715;line-height:unset;list-style:none;margin:0;padding:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper>span.editor-check-box>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper>span.editor-check-box>span.editor-check-box-inner{border:1px solid #c7c7c7;border-collapse:initial;border-radius:3px;direction:ltr;display:block;height:14px;left:0;position:relative;top:0;transition:all .3s;width:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box{position:relative}@keyframes editorCheckboxEffect{0%{transform:scale(1);opacity:.5}to{transform:scale(1.6);opacity:0}}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box:after,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box:after{animation:editorCheckboxEffect .36s ease-in-out;animation-fill-mode:backwards;border:1px solid #338fe5;border-radius:3px;content:"";height:100%;left:0;position:absolute;top:0;width:100%;box-sizing:border-box}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner{border-color:#338fe5;background-color:#338fe5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner:after,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner:after{width:5px;height:10px;left:2px;top:5px;border:2px solid #fff;border-left:0;border-top:0;content:" ";display:table;opacity:1;position:absolute;box-sizing:border-box;transform:rotate(45deg) scale(1) translate(-50%,-50%)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper:not(.editor-check-list-wrapper-checked)>span.editor-check-box:hover>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper:not(.editor-check-list-wrapper-checked)>span.editor-check-box:hover>span.editor-check-box-inner{border-color:#338fe5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-content]{position:relative;flex-grow:1;padding-left:2px;margin-right:29px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-container{display:flex;min-width:24px;align-items:center;justify-content:center;flex-shrink:0;border-radius:3px;height:calc(var(--font-size) * var(--line-height))}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-container .list-marker{min-width:16px;border:none;background-color:transparent;outline:none;display:flex;align-items:center;justify-content:flex-end;padding:0;overflow:visible;color:var(--primary-color);font-size:var(--font-size)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block div[data-type=block-tools] .block-helper{top:2px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=center]{justify-content:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=center]>div[data-type=block-content]{flex-grow:initial}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=right]{justify-content:flex-end}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=right]>div[data-type=block-content]{flex-grow:initial}.editor-root.readonly button[data-button-id=mindmap-close]{display:none}.editor-root:not(.readonly) div[data-type=editor-block].list-block.active,.editor-root:not(.readonly) div[data-type=editor-block].list-block.hover{background-color:#f8f8f8}.editor-root:not(.readonly) div[data-type=editor-block].list-block.active .list-container,.editor-root:not(.readonly) div[data-type=editor-block].list-block.hover .list-container{cursor:pointer}.editor-root:not(.readonly) div[data-type=editor-block].list-block .list-container:hover .list-marker{cursor:pointer}.editor-root:not(.readonly) div[data-type=editor-block].list-block:not([data-list-type=unchecked]):not([data-list-type=checked]):not([data-list-type=unordered]) .list-container:hover{background-color:var(--background-selection)}.editor-root:not(.readonly) div[data-type=editor-block].list-block[data-list-type=unordered] .list-container:hover .list-marker{cursor:initial}.editor-root:not(.readonly) div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container:hover .list-marker svg>*{fill:var(--background-selection)}[data-tippy-root] .customize-start-panel{max-width:350px;padding:0 16px;color:#333;font-size:14px;line-height:21px;user-select:none;background-color:#fff!important}[data-tippy-root] .customize-start-panel-input{width:64px;margin:0 8px;border:1px solid #cfd6e1;height:24px;border-radius:3px;padding:1px 0 1px 8px;outline:none;color:inherit;background-color:#fff}[data-tippy-root] .customize-start-panel-button{min-width:40px;font-size:12px;min-height:30px;margin:0 8px 0 0;background-color:var(--primary-color);color:#fff;outline:none;border:none;padding:4px 8px;border-radius:4px;cursor:pointer}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block].list-block [data-type=block-content][data-content-placeholder]:before{left:2px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.math-box{display:inline-flex}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.math-box .mathjax-tex-text.mathjax-error{color:var(--color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] img.mathjax{max-width:100%}div.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-embed-type=math]>div[data-type=block-content]{align-items:center;justify-content:center;min-height:40px}div.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-embed-type=math]>div[data-type=block-content] img{margin:auto;padding:8px}.mathjax-editor-textarea{border:none;outline:none;width:400px;height:128px}.editor-text-button{border:0;color:var(--text-button-color, #c1c1c1);background-color:var(--text-button-bg-color, transparent);cursor:pointer;border-radius:var(--editor-border-radius, 3px);font-size:14px;padding:1px 6px;display:flex;align-items:center}.editor-text-button:hover{color:var(--text-button-color-hover, #5587F0);background-color:var(--text-button-bg-color-hover, transparent)}div[data-type=editor-block].table-block{--table-bar-width: 6px;--table-bar-left: -6px;--table-bar-top: -6px}div[data-type=editor-block].table-block>div[data-type=block-content]{position:relative;left:-26px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-resize-gripper,div[data-type=editor-block].table-block div[data-type=table-tools] .table-resize-gripper{position:absolute;background-color:transparent;cursor:col-resize;padding:0 2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-resize-gripper>.table-resize-gripper-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-resize-gripper>.table-resize-gripper-indicator{pointer-events:none;background-color:var(--primary-color);width:100%;height:100%}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container{position:absolute;background-color:transparent;z-index:10}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container.top{left:0;top:var(--table-bar-top);right:0;height:var(--table-bar-width);flex-direction:row}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container.left{top:20px;left:var(--table-bar-left);width:var(--table-bar-width);bottom:0;flex-direction:column}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar{position:absolute;left:0;top:0;right:0;bottom:0;cursor:pointer;display:flex}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar.left{flex-direction:column}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell{background-color:#e8e8e8;position:relative;flex-grow:0;flex-shrink:0}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.corner,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.corner{width:var(--table-bar-width);height:var(--table-bar-width)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.top{height:100%}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell:hover,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell:hover{background-color:#dedede}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.selected,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.selected{background-color:var(--primary-color)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.danger,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.danger{background-color:#e52727}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root{position:relative}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.top{max-width:0;width:0;overflow:visible}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.top:last-child,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.top:last-child{margin-left:-2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.left{max-height:0;height:0;overflow:visible}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.left:last-child,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.left:last-child{margin-top:-2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container{position:absolute;width:26px;height:26px;display:flex;align-items:center;justify-content:center;z-index:1}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container.top{right:-14px;top:-22px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container.left{transform:rotate(270deg);left:-22px;bottom:-14px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .insert-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .insert-indicator{position:absolute;width:3px;height:3px;background:#e8e8e8;border-radius:50%;margin-top:6px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-indicator{display:none}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button{display:unset}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button span.icon,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button span.icon{margin-top:2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .drop-marker,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .drop-marker{opacity:1;transform:scale(.7)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker{width:26px;height:26px;border-radius:3px;background:var(--primary-color);cursor:pointer;opacity:0;transform:scale(.4);transition:transform .2s ease-in,opacity .2s ease-in}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:after,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:after{content:"";display:block;width:10px;height:2px;background-color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:before,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:before{content:"";display:block;width:2px;height:10px;background-color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}div[data-type=editor-block].table-block div[data-type=block-tools] .editor-table-chart,div[data-type=editor-block].table-block div[data-type=table-tools] .editor-table-chart{padding-top:16px}div[data-type=editor-block].table-block div[data-type=table-content]{position:relative}div[data-type=editor-block].table-block div[data-type=table-content]>.error{color:red;border:1px solid red;padding:8px}div[data-type=editor-block].table-block div[data-type=table-content]>table{border-collapse:collapse;width:max-content;border-spacing:0}div[data-type=editor-block].table-block div[data-type=table-content]>table colgroup col{min-width:40px}div[data-type=editor-block].table-block div[data-type=table-content]>table,div[data-type=editor-block].table-block div[data-type=table-content]>table td,div[data-type=editor-block].table-block div[data-type=table-content]>table th{border:1px solid #c7c7c7;background-color:transparent;background-clip:padding-box}div[data-type=editor-block].table-block div[data-type=table-content]>table tr td.danger{background-color:#fce9e9!important}div[data-type=editor-block].table-block div[data-type=table-content]>table td{min-width:40px;padding:0;position:relative}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn{display:none;position:absolute;right:2px;top:2px;padding:0;width:16px;height:16px;border:none;border-radius:3px;cursor:pointer;transform:rotate(0);transition:transform .2s;background-color:transparent;color:#909090}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn:hover{background-color:#e8e8e8}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn.active{transform:rotate(180deg);color:#338fe5;background:#eaf3fc}div[data-type=editor-block].table-block div[data-type=table-content]>table td>div[data-type=editor-container].child>div.container-blocks>*+*{margin-top:5px}div[data-type=editor-block].table-block div[data-type=table-content] .child{padding:8px}div[data-type=editor-block].table-block div[data-type=table-content] .child div[data-type=editor-block].table-block>div[data-type=block-content]{pointer-events:none}div[data-type=editor-block].table-block div[data-type=table-content] .child div[data-type=editor-block].table-block>div[data-type=block-content] div[data-type=table-content]{pointer-events:auto}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-0{background-color:var(--background-color-0)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-1{background-color:var(--background-color-1)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-2{background-color:var(--background-color-2)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-3{background-color:var(--background-color-3)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-4{background-color:var(--background-color-4)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-5{background-color:var(--background-color-5)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-6{background-color:var(--background-color-6)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-7{background-color:var(--background-color-7)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-8{background-color:var(--background-color-8)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-9{background-color:var(--background-color-9)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-10{background-color:var(--background-color-10)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-11{background-color:var(--background-color-11)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-12{background-color:var(--background-color-12)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-13{background-color:var(--background-color-13)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-14{background-color:var(--background-color-14)}div[data-type=editor-block].table-block div[data-type=table-content]>table.row-title>tbody>tr:first-child>td,div[data-type=editor-block].table-block div[data-type=table-content]>table.col-title td.col-title-item{background-color:#f8f8f8}div[data-type=editor-block].table-block div[data-type=table-content]>table.stripe:not(.row-title)>tbody>tr:nth-of-type(2n),div[data-type=editor-block].table-block div[data-type=table-content]>table.stripe.row-title>tbody>tr:nth-of-type(2n + 1){background-color:#f5f8fb}div[data-type=editor-block].table-block div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block div[data-type=table-content]>.no-border>tbody>tr>td{border:1px dashed;border-color:transparent}div[data-type=editor-block].table-block.focused div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block.focused div[data-type=table-content]>table.no-border>tbody>tr>td,div[data-type=editor-block].table-block.child-focused div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block.child-focused div[data-type=table-content]>table.no-border>tbody>tr>td{border-color:#b9bfc8}div[data-type=editor-block].table-block.full-selected>div[data-type=block-content]>.scroll-container-root>.scroll-container>.scroll-area>div[data-type=table-content]>table{background-color:var(--background-selection)}div[data-type=editor-block].table-block div[data-type=table-content]>table tbody tr td.selected,div[data-type=editor-block].table-block div[data-type=table-content]>table.row-title tbody tr td.selected,div[data-type=editor-block].table-block div[data-type=table-content]>table.col-title tbody tr td.selected{background-color:var(--background-selection)}div[data-type=editor-block].table-block div[data-type=table-content]>table td div[data-type=editor-block].table-block div[data-type=table-content]>table{max-width:100%}.command-item.menu-item .table-creator{background-color:#fff;padding:0 5px}.command-item.menu-item .table-creator .table-creator-row{display:flex}.command-item.menu-item .table-creator .table-creator-row .table-creator-cell{width:16px;height:16px;margin:3px;border:solid 1px #ddd}.command-item.menu-item .table-creator .table-creator-row .table-creator-cell.active{background-color:#99c7f2}div.editor-root div.editor-content div[data-type=editor-container].root div[data-type=editor-block].table-block{margin-top:0}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color]{width:100%}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .bar-desc{display:none}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item{box-sizing:border-box;width:100%;height:32px;padding:5px 10px;display:flex;align-items:center;justify-content:space-between;color:var(--text-color)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-sub-indicator{display:flex;align-items:center;margin-left:5px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-sub-indicator svg{height:16px;width:16px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;position:relative;margin-left:auto}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]{position:relative;background-color:#fff;border:1px solid #e8e8e8}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]:after{transform:scale(1.2)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]:before{content:"";position:absolute;width:1px;height:56px;top:2px;left:22px;background-color:#c7c7c7;transform:rotate(45deg) scale(.5);transform-origin:-1px -2px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="0"]{background-color:var(--background-color-0)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="1"]{background-color:var(--background-color-1)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="2"]{background-color:var(--background-color-2)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="3"]{background-color:var(--background-color-3)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="4"]{background-color:var(--background-color-4)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="5"]{background-color:var(--background-color-5)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="6"]{background-color:var(--background-color-6)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="7"]{background-color:var(--background-color-7)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="8"]{background-color:var(--background-color-8)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="9"]{background-color:var(--background-color-9)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="10"]{background-color:var(--background-color-10)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="11"]{background-color:var(--background-color-11)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="12"]{background-color:var(--background-color-12)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="13"]{background-color:var(--background-color-13)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="14"]{background-color:var(--background-color-14)}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table]{background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.row-title>tbody>tr:first-child>td,div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.col-title td.col-title-item{background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.stripe:not(.row-title)>tbody>tr:nth-of-type(2n),div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.stripe.row-title>tbody>tr:nth-of-type(2n + 1){background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment{box-shadow:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment table{box-shadow:0 2px #f8e6ab}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment table table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment table table{box-shadow:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active{outline:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active table{border-bottom:none;outline:4px solid #f8e6ab}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active table table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active table table{box-shadow:none;outline:none}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content]:after,div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content]:after{display:none}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content] div[data-type=table-content],div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content] div[data-type=table-content]{position:relative}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content] div[data-type=table-content]:after,div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content] div[data-type=table-content]:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#303030;opacity:.1}.editor-root .editor-content div[data-type=editor-block].table-block div[data-type=block-tools] .block-helper{right:calc(100% + 5px);top:35px}[data-command-bar-id=table-row-column-toolbar] .editor-command-bar.toolbar{padding:4px}div.comment-editor-root div[data-type=editor-block].table-block>div[data-type=block-content]{left:0px}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=center] [data-type=block-content][data-content-placeholder]:before{justify-content:center}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=right] [data-type=block-content][data-content-placeholder]:before{justify-content:right}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-title-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-title-placeholder);color:#c7c7c7}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-content-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-content-placeholder);color:#c7c7c7;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:flex;align-items:center}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-tools] .block-placeholder-container{position:absolute;left:0;top:0;right:0}div.editor-root.readonly div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-title-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-title-placeholder-readonly);color:#c7c7c7}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block{min-width:360px;counter-reset:code-line}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.full-selected{background-color:var(--background-selection)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.editing-language div[data-type=block-tools] .code-block-header,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.child-focused div[data-type=block-tools] .code-block-header,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:hover div[data-type=block-tools] .code-block-header{opacity:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.wrap>div[data-type=block-tools] .code-block-header button[data-id=wrap] *{color:var(--primary-color)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child{overflow-x:auto}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]{word-break:keep-all;overflow:visible;white-space:pre}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]>span.text,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]>span.inputting-insertion{white-space:pre}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header{opacity:0;transition:opacity .3s ease-in 0s;position:absolute;top:0;display:flex;padding-left:16px;padding-right:4px;align-items:center;left:0;right:0;height:32px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .language-select{font-size:14px;color:#999;cursor:pointer;display:flex;align-items:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .language-select .arrow-icon{width:16px;height:16px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-spacer{flex-grow:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button{display:flex;justify-content:center;align-items:center;border:none;border-radius:2px;margin-left:4px;padding:0;background:none;outline:none;color:#c1c1c1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button:not(.disabled){cursor:pointer}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button:not(.disabled):hover{color:#5587f0}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button.disabled{cursor:not-allowed}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{margin-right:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-icon{height:24px;display:flex;align-items:center;justify-content:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-icon>svg{width:24px;height:24px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-label{margin-left:4px;font-size:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{display:none}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.full-selected>div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:unset}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:var(--background-code)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container]{padding-left:32px;padding-top:32px;padding-bottom:24px;border-radius:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container].selected{background-color:var(--background-selection)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] *{font-family:Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;font-size:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block+div.text-block{margin-top:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block:before{content:counter(code-line);counter-increment:code-line;position:absolute;left:-48px;top:10px;z-index:1;margin-top:-4px;display:block;width:48px;padding-right:8px;text-align:right;color:#aaa;box-sizing:border-box;font-size:12px;font-weight:400;line-height:12px;letter-spacing:0;white-space:nowrap;opacity:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-comment,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-prolog,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-doctype,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-cdata{color:#708090}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-punctuation{color:#999}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-namespace{opacity:.7}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-property,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-tag,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-boolean,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-number,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-constant,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-symbol,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-deleted{color:#905}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-selector,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-attr-name,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-string,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-char,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-builtin,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-inserted{color:#690}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-operator,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-entity,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-url,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-string{color:#9a6e3a}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-atrule,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-attr-value,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-keyword{color:#07a}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-function,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-class-name{color:#dd4a68}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-regex,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-important,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-variable{color:#e90}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-important,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-bold{font-weight:700}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-italic{font-style:italic}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-entity{cursor:help}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-caption-root{padding:8px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-caption-root *{color:#aaa}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .code-header-button[data-id=wrap],div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{display:none}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .language-select{cursor:default!important}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .language-select .arrow-icon{display:none}div.editor-root div.editor-content div[data-type=editor-container].root.select-all div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:unset}div.comment-editor-root [data-type=editor-container].root div[data-type=editor-block].code-block{min-width:0}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer{position:absolute;background-color:transparent;border:1px solid #338FE5;pointer-events:none;z-index:1;display:none}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer.active{display:block}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper{position:absolute;width:16px;height:16px;border:2px solid white;background-color:#338fe5;border-radius:50%;pointer-events:all}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom{left:calc(50% - 8px);bottom:-8px;cursor:ns-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.top-left{left:-8px;top:-8px;cursor:nwse-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.top-right{right:-8px;top:-8px;cursor:nesw-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom-left{left:-8px;bottom:-8px;cursor:nesw-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom-right{right:-8px;bottom:-8px;cursor:nwse-resize}div.editor-root.readonly div.editor-content div[data-type=editor-block]>[data-type=block-tools] .block-resizer{display:none}.before-content,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content] .images .image-container.active:before,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected:not(.focused) [data-type=block-content] .images .image-container:before{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#338fe5;opacity:.1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image]{display:flex}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].block-hidden{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=left]{justify-content:flex-start}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=center]{justify-content:center}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=right]{justify-content:flex-end}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content]{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content] .images .image-container.empty:hover,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content] .images .image-container.error:hover{outline:1px solid #338FE5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content]:before{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content]{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content] .images .image-container.active .image-warning{opacity:0;z-index:-1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].multi [data-type=block-tools] .block-resizer{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image]:not(.multi) [data-type=block-content] .images.empty{min-height:400px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content]{cursor:default}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images{width:100%;display:flex;align-items:flex-start}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter{width:10px;flex-grow:0;flex-shrink:0;padding:0 4px;cursor:col-resize;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter .image-splitter-indicator{width:100%;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter:active .image-splitter-indicator,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter:hover .image-splitter-indicator{background-color:#d9d9d9}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container{position:relative;flex:1;background-color:#f8f8f8;display:flex;min-height:inherit;overflow:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container img{max-width:100%;width:100%;height:auto}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty .upload-image-icon{display:flex;color:#c7c7c7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.error{height:100%;outline:1px solid #DEDEDE;border-radius:3px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.error img{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error{display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;z-index:1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-icon,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-icon{display:flex;color:#c7c7c7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message{display:flex;flex-direction:column;align-items:center;overflow:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-1,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-1{margin-top:10px;font-size:18px;font-weight:500;color:#303030;height:26px;vertical-align:middle;line-height:26px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;flex-shrink:0}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-2,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-3,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-2,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-3{font-size:14px;color:#606060;vertical-align:middle;height:22px;line-height:22px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;flex-shrink:0}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-2 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-3 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-2 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-3 a{text-decoration:none;color:#338fe5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .line-3 a{display:inline-flex;align-items:center;text-decoration:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .line-3 a:after{content:" ";display:inline-block;width:16px;height:16px;margin-left:5px;background-image:url("data:image/svg+xml,%3Csvg width='17' height='16' viewBox='0 0 17 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.5 2H3.5C2.94772 2 2.5 2.44772 2.5 3V13C2.5 13.5523 2.94772 14 3.5 14H13.5C14.0523 14 14.5 13.5523 14.5 13V10' stroke='%23338FE5'/%3E%3Cpath d='M14.5 2L9 7.5' stroke='%23338FE5'/%3E%3Cpath d='M8.5 2H14.5V8' stroke='%23338FE5'/%3E%3C/svg%3E%0A")}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask{position:absolute;top:0;left:0;right:0;bottom:0;background-color:#303030;opacity:.8;display:flex;align-items:center;justify-content:center}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask .uploading-progress-bar{width:75%;height:6px;border-radius:3px;display:flex;background-color:#fff}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value{background-color:#338fe5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .image-warning{position:absolute;right:5px;top:5px;color:#fff;background-color:#333;width:24px;height:24px;display:flex;align-items:center;justify-content:center;border-radius:3px;z-index:2;transition:opacity linear .2s;opacity:.7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty{display:flex;flex-direction:column;align-items:center;outline:1px solid #DEDEDE;border-radius:3px;justify-content:center;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty svg{width:48px;height:48px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-tools] .drag-container{display:flex;box-sizing:content-box;pointer-events:none;position:fixed;z-index:100;background-color:#fff;border:1px solid #338FE5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-tools] .drag-container .drag-target{width:100%}.editor-root[readonly=true] .image-splitter{visibility:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment{box-shadow:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment [data-type=block-content]{box-shadow:0 2px #f8e6ab}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment.active{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment.active [data-type=block-content]{box-shadow:none;outline:4px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block].dragging div[data-type=block-tools] .block-helper{opacity:0}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper{position:absolute;right:100%;top:0;padding-right:5px;display:flex;align-items:center}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .helper-sizer{width:0;opacity:0;pointer-events:none}div[data-type=editor-block].block-exclusive:after{content:attr(data-exclusive-tips);position:absolute;top:0px;left:0px;width:100%;background:#f8f8f8;border-radius:var(--editor-border-radius);white-space:nowrap;text-overflow:ellipsis;overflow:hidden;font-size:14px;line-height:22px;color:#909090;text-align:center;padding:9px 0;z-index:1000}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self>[data-type=block-content],.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others>[data-type=block-content]{position:relative}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others>[data-type=block-content]:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;z-index:1;background-color:#303030;opacity:.1}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.locked-by-self>[data-type=block-content]:after{pointer-events:none}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.text-block>[data-type=block-content]:after{outline:2px solid #303030}.editor-root{--selected-color: #e8e8e8}.editor-root .editor-content.dragging *{cursor:grabbing!important}.editor-root .editor-content.dragging div[data-type=editor-block] iframe{pointer-events:none}.editor-root .editor-content .editor-drop-indicator{position:absolute;background-color:var(--primary-color);pointer-events:none;transition:top .2s linear,left .2s linear,width .2s linear}.editor-root .editor-content div[data-type=editor-block].text-block.highlighted{outline:2px solid var(--background-selection);background-color:var(--background-selection)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button{width:24px;height:24px;cursor:pointer;margin:0;padding:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;border-radius:3px}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button[data-type=move]{cursor:grab}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button:hover{background-color:var(--selected-color)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button svg{width:16px;height:16px;color:#909090}.drag-image-container{position:fixed;z-index:100;box-shadow:0 3px 20px #00000026;background-color:#fff;opacity:.4}.drag-image-container.drag-placeholder{width:500px;height:200px;border:1px solid #dedede;border-radius:3px;background:#e8e8e8}.drag-image-container .drag-image{width:100%;display:none}.drag-image-container[data-status=loaded] .drag-image{display:block}.drag-image-container[data-status=loaded] .drag-loading{display:none}.editor-command-bar-root .editor-command-bar .command-item.menu-item{display:flex;align-items:center;flex:none}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles{padding:5px 10px;background-color:#fff}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section+.text-style-section{margin-top:5px}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section{display:grid;grid-template-columns:repeat(7,24px);grid-row-gap:10px;grid-column-gap:5px}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon{height:24px;padding:0;margin:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;outline:none;cursor:pointer;border-radius:3px;color:#606060}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon:hover{background-color:var(--selected-color)}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon.active{color:#338fe5}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-anchor[data-id=paste-special-button-anchor]{z-index:unset}[data-command-bar-id=paste-special-button] .editor-command-bar.toolbar{padding:0}[data-command-bar-id=paste-special-button] .editor-command-bar.toolbar .command-item[data-dropdown=true]{padding-left:5px;padding-right:5px}.editor-find-dialog{--popover-input-border: 1px solid #CFD6E1;--editor-find-dialog-input-container-border-color: #CFD6E1;--editor-find-dialog-input-container-bg-color: transparent;--editor-border-radius-big: 3px;--editor-color: #07142A;--button-black-text-color: #333;--editor-find-dialog-button-color: #333;--editor-find-dialog-icon-button-color: #333;--editor-find-dialog-button-border-bg-color: rgba(255, 255, 255, .56);--editor-find-dialog-input-placeholder-color: #b9bfc8;--editor-find-dialog-button-disabled-color: #ccc !important;--editor-find-dialog-button-hover-color: rgba(150, 150, 150, .2);--editor-find-dialog-button-border: solid 1px #ccc;box-sizing:border-box;width:400px;background-color:var(--editor-find-dialog-bg-color);border:var(--editor-find-dialog-border);border-radius:var(--editor-border-radius-big);display:flex;padding:8px 8px 0 16px;align-items:flex-start;font-size:14px;font-family:var(--editor-font-family)}.editor-find-dialog .editor-find-content{display:flex;flex-direction:column;flex-grow:1;font-family:inherit}.editor-find-dialog .editor-find-dialog-row{display:flex;margin-bottom:8px;align-items:center}.editor-find-dialog .editor-find-dialog-label{width:80px;flex-grow:0;flex-shrink:0;align-self:center}.editor-find-dialog .editor-find-dialog-input-container{border:var(--popover-input-border);border-color:var(--editor-find-dialog-input-container-border-color);background-color:var(--editor-find-dialog-input-container-bg-color);border-radius:var(--editor-border-radius-big);flex-grow:1;display:flex;padding:2px;align-items:center;height:32px;box-sizing:border-box}.editor-find-dialog .editor-find-dialog-input{border:none;flex-grow:1;width:80px;outline:none;background-color:transparent;color:var(--editor-color)}.editor-find-dialog .editor-find-dialog-input::placeholder{color:var(--editor-find-dialog-input-placeholder-color);opacity:1}.editor-find-dialog .editor-find-dialog-prev{width:24px}.editor-find-dialog .editor-find-dialog-curr{flex-grow:0;text-align:center;flex-shrink:1;display:flex;align-items:center;margin-bottom:2px}.editor-find-dialog .editor-find-dialog-next{width:24px}.editor-find-dialog .editor-find-dialog-icon-button{cursor:pointer;border-radius:4px;color:var(--editor-find-dialog-icon-button-color);background-color:var(--editor-find-dialog-button-border-bg-color);border:none;display:flex;padding:0}.editor-find-dialog .editor-find-dialog-button{padding:6px 16px;cursor:pointer;border-radius:4px;color:var(--editor-find-dialog-button-color);background-color:var(--editor-find-dialog-button-border-bg-color);margin:0 4px;border:none;font-family:inherit;line-height:21px}.editor-find-dialog .editor-find-dialog-button.icon-button{width:32px;height:32px}.editor-find-dialog .editor-find-dialog-button.active,.editor-find-dialog .editor-find-dialog-button:hover{background-color:var(--editor-find-dialog-button-hover-color)}.editor-find-dialog .editor-find-dialog-button:disabled{color:var(--editor-find-dialog-button-disabled-color);cursor:default}.editor-find-dialog .editor-find-dialog-button:disabled:hover{background-color:transparent}.editor-find-dialog .editor-find-dialog-button svg{fill:currentColor}.editor-find-dialog .editor-find-dialog-space{flex-grow:1}.editor-find-dialog .editor-find-dialog-icon-button-border{margin:0 0 0 8px;cursor:pointer;border-radius:4px;color:var(--button-black-text-color);border:var(--editor-find-dialog-button-border);background-color:var(--editor-find-dialog-button-border-bg-color);padding:0;width:32px;display:flex;justify-content:center;align-items:center}.editor-find-dialog .editor-find-dialog-button-close{margin:0 0 0 8px;cursor:pointer;border-radius:4px;color:var(--button-black-text-color);background-color:var(--editor-find-dialog-button-border-bg-color);border:none;padding:0;width:32px;height:32px;display:flex;justify-content:center;align-items:center}.editor-find-dialog .editor-find-dialog-icon-button-border svg,.editor-find-dialog .editor-find-dialog-button-close svg{fill:currentColor}.editor-find-dialog .editor-highlight{opacity:.6;pointer-events:none}.editor-find-dialog .editor-highlight .editor-highlight-child{position:absolute;background-color:bisque}.editor-find-dialog .editor-highlight.active .editor-highlight-child{position:absolute;background-color:tomato}.editor-find-dialog .editor-search-result-highlight{opacity:.6;pointer-events:none}.editor-find-dialog .editor-search-result-highlight .editor-highlight-child{position:absolute;background-color:#40e0d0}.editor-find-dialog .editor-find-dialog-status{display:flex}.editor-highlight{opacity:.6;pointer-events:none}.editor-highlight .editor-highlight-child{position:absolute;background-color:bisque}.editor-highlight.active .editor-highlight-child{position:absolute;background-color:tomato}.editor-search-result-highlight{opacity:.6;pointer-events:none}.editor-search-result-highlight .editor-highlight-child{position:absolute;background-color:#40e0d0}.editor-find-dialog-status{display:flex}.comment-editor{font-size:14px;border:1px solid #c7c7c7;border-radius:3px;padding:1px 10px;margin:6px 10px 0}.comment-editor:after{content:"";height:0;display:block;clear:both}.comment-editor-root{display:inline-block;min-width:calc(100% - 40px);padding-top:2px}.comment-editor-root div.editor-root div.editor-content{padding:0}.comment-editor-root div.editor-root div.editor-content>div[data-type=editor-container].root>div.container-blocks>*+*{margin-top:0}.comment-editor-img{float:right;color:#c1c1c1;padding:0;margin-top:2px;width:24px;height:24px;justify-content:center}.comment-editor-root:not(.comment-editor-readonly) .editor-root .editor-content [data-type=editor-block]:not([data-block-type=text]){width:248px}.comment-editor-editing{border:1px solid #338fe5}.comment-editor-readonly{border:none;padding-left:37px;margin:0}.comment-editor-readonly .comment-editor-img{display:none}.comment-item-root{position:relative;margin-top:10px}.comment-item-root:not(.last-comment-item):before{content:" ";display:block;position:absolute;left:20px;width:1px;background-color:var(--editor-border-color, #e8e8e8);overflow:hidden;opacity:.8;top:21px;bottom:-12px;transform:scaleX(.5)}.comment-item-root .item-head{padding:0 10px;position:relative;display:flex;align-items:center}.comment-item-root .item-head-avatar{margin-right:5px;width:var(--editor-comment-avatar-width, 21px);height:var(--editor-comment-avatar-width, 21px);border-radius:100%}.comment-item-root .item-head-avatar-string{display:flex;align-items:center;justify-content:center;font-size:12px;color:#fff;background-color:var(--comment-avatar-color);flex-shrink:0}.comment-item-root .item-head-username{font-size:var(--editor-comment-username-font-size, 12px);color:var(--editor-comment-username-color, #07142a);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.comment-item-root .item-head-modified{margin-left:8px;font-size:12px;color:var(--editor-comment-modified-color, #808080);flex-grow:1;white-space:nowrap}.comment-item-root .item-head-tools{display:flex;align-items:center;visibility:hidden}.comment-item-root .item-head-tools .editor-text-button svg{width:20px;height:20px}.comment-item-root .item-head-tools.active{visibility:visible}.comment-item-root .item-actions{margin-top:10px;display:flex;justify-content:flex-end;padding:0 10px}.comment-item-root .item-actions.hidden{display:none}.comment-item-root:hover:not(.comment-item-editing) .item-head-tools{visibility:visible}.comment-item-root.readonly .item-head-tools{display:none}.mobile-comment-item{margin-top:4px;background-color:var(--editor-comment-layer-bg-color);padding-bottom:20px;color:var(--editor-comment-username-color)}.mobile-comment-item .item-head{padding:12px;display:flex;align-items:center}.mobile-comment-item .item-head-avatar{width:var(--editor-comment-avatar-size);height:var(--editor-comment-avatar-size);flex-grow:0}.mobile-comment-item .item-head-username{margin-left:12px}.mobile-comment-item .item-head-modified{margin-left:12px;color:#999}.mobile-comment-item .item-editor .comment-editor-readonly{padding-left:18px}.mini-comment-item{position:relative;line-height:16px;width:20px;height:16px;text-align:center;font-size:12px;border-radius:1px;background-color:var(--editor-comment-active-color, #FFC328);color:var(--editor-comment-mini-text-color, #ffffff);cursor:pointer}.mini-comment-item:after{content:"";position:absolute;left:50%;bottom:-4px;width:6px;height:6px;background-color:var(--editor-comment-active-color, #FFC328);border-radius:1px;transform:matrix(.71,.61,.82,-.71,0,0) translate(-50%);z-index:-1}.comment-quick-reply .quick-reply-button{position:absolute;left:8px;bottom:3px;z-index:2;color:var(--editor-comment-quick-reply-color, #7084A4);font-size:12px}.comment-quick-reply .quick-reply-button.editor-text-button:hover{color:var(--text-button-color-hover, #5587F0);background-color:var(--text-button-bg-color-hover, transparent)}.comment-quick-reply .quick-reply-editor{display:none}.comment-quick-reply .quick-reply-editor .reply-editor-actions{display:flex;justify-content:flex-end;margin-top:10px;padding:0 10px}.comment-quick-reply.hidden,.comment-quick-reply.reply-editor-editing .quick-reply-button{display:none}.comment-quick-reply.reply-editor-editing .quick-reply-editor{display:block}:root{--editor-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Robot, "Helvetica Neue", Helvetica, Arial, sans-serif;--editor-comment-layer-bg-color:#ffffff;--editor-comment-group-bg-color: #ffffff;--comment-root-border-color: #eaeaea;--editor-comment-layer-active-border-color: #cecece;--editor-box-shadow: 0px 3px 20px rgba(0, 0, 0, .15);--wiz-editor-z-comment-group-active-top-before: 29;--editor-comment-quote-color: #909090;--editor-comment-quote-before-bg-color: #909090;--editor-comment-switch-button-width: 12px;--editor-comment-active-color: #FFC328;--editor-bg-color: #ffffff;--wiz-editor-z-comment-head:11;--text-button-color-hover:#5587f0;--editor-comment-username-color:#07142A;--editor-comment-avatar-size: 32px}.disabled-scroll{overflow:hidden}.editor-root .editor-content div[data-type=editor-block].text-block.comment{box-shadow:none}.editor-root .editor-content div[data-type=editor-block].text-block.comment>div[data-type=block-content]>span{border-bottom:2px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block].text-block.comment.active{box-shadow:none;outline:none}.editor-root .editor-content div[data-type=editor-block].text-block.comment.active>div[data-type=block-content] span{background-color:#f8e6ab}.editor-root .editor-content div[data-type=editor-block] span.text.comment{border-bottom:2px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block] span.text.comment.active{background-color:#faf1d1}.editor-root .editor-content div[data-type=editor-block].comment{box-shadow:0 2px #f8e6ab}.editor-root .editor-content div[data-type=editor-block].comment.active{box-shadow:none;outline:4px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-comment-button{all:unset;position:absolute;right:-28px;top:0;width:24px;height:24px;display:flex;align-items:center;justify-content:center;padding:0;border-radius:3px;color:#07142a;cursor:pointer}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-comment-button:hover{background:#eaeaea}.editor-web-comment-root{position:absolute;right:0;width:300px;top:0;bottom:0;transition:width .16s ease-in;will-change:width;font-family:var(--editor-font-family)}.editor-web-comment-root .comment-groups-container .comment-group-item-root{position:absolute;left:50%;right:0;width:290px;transform:translate(-50%);background-color:var(--editor-comment-group-bg-color);border-radius:2px;border-color:var(--editor-comment-layer-active-border-color);box-shadow:var(--editor-box-shadow);padding-bottom:18px}.editor-web-comment-root .comment-groups-container .comment-group-item-root:not(.no-animation){transition:top .2s ease-in,opacity .35s ease-in}.editor-web-comment-root .comment-groups-container .comment-group-item-root:before{content:"";position:absolute;left:0;right:0;height:6px;background-color:#fff;border-radius:2px 2px 0 0;z-index:var(--wiz-editor-z-comment-group-active-top-before)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head{display:flex;align-items:center}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-quote{box-sizing:content-box;font-size:12px;line-height:12px;height:12px;color:var(--editor-comment-quote-color);padding:18px 12px 10px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;width:100%;max-width:calc(100% - 80px)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-quote:before{content:"";display:block;width:2px;height:100%;background-color:var(--editor-comment-quote-before-bg-color);margin-right:6px;float:left;border-radius:10px}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch{display:flex;align-items:center;height:22px;padding-top:6px;visibility:hidden}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button{padding:0;width:var(--editor-comment-switch-button-width);margin:3px 0;color:#606060}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button[data-button-id=switch-up]{margin-right:16px}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button:not(.disabled):hover{color:var(--text-button-color-hover)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button.disabled{color:#60606080;cursor:not-allowed}.editor-web-comment-root .comment-groups-container .comment-group-item-root.active:before{background-color:var(--editor-comment-active-color)}.editor-web-comment-root .comment-groups-container .comment-group-item-root.active .item-head-switch{visibility:visible}.editor-web-comment-root .comment-groups-container .comment-group-item-root.readonly .comment-quick-reply{display:none}.editor-mobile-comments-root{position:fixed;left:0;right:0;bottom:0;top:0;overflow:hidden;z-index:11}.editor-mobile-comments-root .mobile-comment-mask{position:absolute;left:0;right:0;bottom:0;top:0;background-color:#00000073}.editor-mobile-comments-root .mobile-comment-groups-container{position:absolute;width:100%;height:100vh;z-index:1;overflow:hidden}.editor-mobile-comments-root .mobile-comment-groups-container .mobile-comment-groups-scroll-container{padding:0 12px}.editor-mobile-comments-root .mobile-comment-pull-info-container{position:absolute;right:0;left:0;bottom:100px;z-index:2;text-align:center;display:none}.editor-mobile-comments-root .mobile-comment-pull-info-container .mobile-comment-pull-info{display:inline-block;padding:12px;border-radius:36px;margin:0 auto;background-color:#000c;color:#fff;font-size:12px;opacity:0;transition:opacity .25s cubic-bezier(.65,.05,.36,1)}.editor-mobile-comments-root .mobile-comment-pull-info-container.active{display:block}.editor-mobile-comments-root .mobile-comment-pull-info-container.active .mobile-comment-pull-info{opacity:1}.editor-mobile-comments-root .mobile-group-item-root{margin:0 auto;width:100%;height:100vh;overflow:hidden}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item{min-height:calc(100vh + 1px);padding-bottom:50px}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item-space{height:50vh}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item-abstract{background-color:var(--editor-comment-layer-bg-color);padding:12px;color:#999;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.editor-mini-comment-root{position:absolute;right:0;top:0;bottom:0;width:48px;border-left:1px solid #f0f0f0;transition:width .16s ease-in;will-change:width;font-family:var(--editor-font-family);border:none;background-color:transparent;z-index:11}.editor-mini-comment-root .comment-groups-container{width:100%;height:100%}.editor-mini-comment-root .comment-groups-container .mini-group-item{position:absolute;top:0;left:50%;margin-left:-10px;transition:top .2s cubic-bezier(.65,.05,.36,1)}:is(.editor-web-comment-root,.editor-mobile-comments-root,.editor-mini-comment-root).hidden{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content]{margin:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content] span.file-icon{display:inline-flex;vertical-align:text-bottom}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content] .file-name{color:var(--primary-color);padding:0;border-radius:12px;margin-right:4px;white-space:wrap;word-break:break-all;cursor:pointer}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office]{justify-content:start}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office].hover [data-type=block-content]{border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content]{max-width:360px;min-width:360px;height:48px;cursor:pointer}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root{display:flex;align-items:center;min-width:360px;max-width:100%;background-color:#f5f6f7;border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root:before{border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details{display:flex;flex-direction:column;justify-content:center;font-size:14px;flex-grow:1}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-name{color:#1f2329;max-width:185px;display:flex;flex-direction:row;align-items:center;white-space:nowrap}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-size{color:#646a73;font-size:12px;margin-top:2px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-name-pre{text-overflow:ellipsis;overflow:hidden}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-actions button{width:34px;height:34px;background-color:#fff;border:1px solid #dee0e3;border-radius:50%;margin:0 8px;padding:0;background-repeat:no-repeat;background-position:50%;cursor:pointer;display:flex;align-items:center;justify-content:center;flex-shrink:0}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-actions button svg{width:16px;height:16px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-icon{display:flex;width:36px;height:36px;margin:6px 6px 6px 12px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-icon>svg{width:100%;height:100%}:root{--editor-version-button-border: black;--editor-bg-color: #ffffff;--editor-version-list-bg-color: white;--editor-version-select-bg-color: #F5F9FD}.version-dialog{display:flex;background-color:var(--editor-bg-color);width:100%;height:100%;color:var(--editor-color)}.version-dialog *{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;box-sizing:border-box}.version-dialog .version-item-latest{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;border-radius:3px;display:inline-flex;align-items:center;font-size:12px;font-weight:400;margin-left:10px}.version-dialog .version-viewer{flex:1;display:flex;flex-direction:column;width:0;padding:0}.version-dialog .version-viewer .version-dialog-editor{flex-grow:1;overflow-y:auto}.version-dialog .version-viewer .version-info-container{height:50px;border-bottom:#E8E8E8 1px solid;display:flex;align-items:center;flex-shrink:0;padding-left:20px;font-size:14px;color:#303030}.version-dialog .version-viewer .version-info-container .version-info-right .text-3{color:#909090}.version-dialog .version-viewer .version-info-container .version-info-left{display:flex;align-items:center}.version-dialog .version-viewer .version-info-container .version-info-left .text-1,.version-dialog .version-viewer .version-info-container .version-info-left .text-2{color:#909090}.version-dialog .version-viewer .version-info-container .version-info-left .name{padding-left:5px;padding-right:10px;font-weight:500}.version-dialog .version-viewer .version-info-container .version-info-left .name .version-item-latest{margin-left:5px}.version-dialog .version-viewer .version-info-container .editor-dropdown{margin-left:10px;margin-right:10px}.version-dialog .version-viewer .version-info-container .command-item[data-id=current-version]{min-width:200px;border:1px solid #f0f0f0}.version-dialog .version-viewer .version-info-container .command-item[data-id=current-version] .toolbar-item-name-container{flex-grow:1}.version-dialog .version-viewer .dialog-button-text{margin-top:1px;margin-left:-4px}.version-dialog .version-viewer .dialog-text-button{outline:none;background:transparent;border:none;display:flex;align-items:center;color:var(--editor-color);font-size:16px;font-weight:500;padding:4px 0;cursor:pointer}.version-dialog .version-viewer .dialog-text-button .dialog-button-icon{margin-right:0;width:24px;height:24px}.version-dialog .version-viewer .dialog-text-button .dialog-button-icon svg{fill:currentColor}.editor-root.history .root-container .editor-block .text-element .inline-plugin.editor-box-loading{display:none}.editor-root.history .editor-content{padding:30px 75px}.editor-root.history .history-inserted-block[data-type=editor-block] [data-type=block-content]{border:4px solid var(--op-selected-color)}.editor-root.history .history-inserted-block[data-type=editor-block]{position:relative}.editor-root.history .history-inserted-block[data-type=editor-block]:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-inserted-block[data-type=editor-block].table-block table{border:4px solid var(--op-selected-color)}.editor-root.history .history-inserted-block[data-type=editor-block].table-block table .child{pointer-events:none}.editor-root.history .history-inserted-block[data-type=editor-block].table-block{position:relative}.editor-root.history .history-inserted-block[data-type=editor-block].table-block:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-inserted-block[data-type=editor-block].table-block:hover:after{top:0}.editor-root.history .history-deleted-block [data-type=block-content]{border:4px solid var(--op-selected-color)}.editor-root.history .history-deleted-block [data-type=block-content]{position:relative}.editor-root.history .history-deleted-block [data-type=block-content]:after,.editor-root.history .history-deleted-block [data-type=block-content]:before{content:" ";position:absolute;display:flex;z-index:var(--wiz-editor-z-history-delete-marker);color:var(--op-color);justify-items:center;align-items:center;justify-content:center;align-content:center;pointer-events:none;overflow:visible;max-width:100%;max-height:100%;left:calc(50% - 16px);top:calc(50% - 2px);width:32px;height:4px;background-color:var(--op-color);transform:rotate(45deg);opacity:1}.editor-root.history .history-deleted-block [data-type=block-content]:before{transform:rotate(135deg)}.editor-root.history .history-deleted-block{position:relative}.editor-root.history .history-deleted-block:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-deleted-block .history-deleted-box{background-color:unset!important;text-decoration:unset!important}.editor-root.history .history-deleted-block .history-deleted-box:hover:after{opacity:0}.editor-root.history .history-inserted-text{line-height:revert!important;background-color:var(--op-selected-color)}.editor-root.history .history-inserted-text{position:relative}.editor-root.history .history-inserted-text:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-deleted-box{background-color:var(--op-selected-color);text-decoration:line-through}.editor-root.history .history-deleted-box{position:relative}.editor-root.history .history-deleted-box:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history [data-box-type=history-deleted-box]>span[data-type=box-content]{border:none!important;margin:0!important}.editor-root.history [data-type=editor-block].table-block div[data-type=block-content]{overflow-x:revert}.editor-dialog-root{position:absolute;left:0;top:0;bottom:0;right:0;background-color:#639;z-index:100}.size-limit-textarea{display:inline-block;position:relative}.size-limit-textarea .size-limit-textarea-input{width:100%;resize:none;overflow:hidden;color:#303030;outline:none;border:1px solid #f0f0f0;border-radius:3px}.size-limit-textarea .size-limit-textarea-input:focus,.size-limit-textarea .size-limit-textarea-input:hover{border-color:#338fe5}.size-limit-textarea .size-limit-textarea-input:focus{box-shadow:0 0 0 2px #338fe533}.size-limit-textarea .size-limit-textarea-warning{position:absolute;right:0;bottom:10px;color:#909090;z-index:1;font-size:12px;pointer-events:none}.version-list-root{width:350px;background:var(--editor-version-list-bg-color);overflow-y:auto;padding:0;border-left:#E8E8E8 1px solid;display:flex;flex-direction:column}.version-list-root .version-list-header{padding:0 6px 0 20px;font-size:14px;display:flex;align-items:center;margin-top:8px;margin-bottom:8px;flex-shrink:0;color:#909090}.version-list-root .version-list-header .version-count{flex-grow:1}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item{cursor:pointer}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item:not(.disabled):hover{color:#338fe5}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item.selected:not(.disabled){background-color:transparent}.version-list-root .version-list-empty{height:100%;display:flex;align-items:center;justify-content:center;font-size:14px;color:#909090}.version-list-root .version-list-content{flex-grow:1;overflow-y:auto}.version-list-root .version-list-content .version-item{padding:15px 10px;cursor:pointer}.version-list-root .version-list-content .version-item:not(:last-child):after{content:"";display:block;position:relative;top:15px;border-bottom:1px solid #E8E8E8}.version-list-root .version-list-content .version-item:not(:last-child):hover:after,.version-list-root .version-list-content .version-item:not(:last-child).active:after{left:-10px;width:106%}.version-list-root .version-list-content .version-item.child{padding-left:32px}.version-list-root .version-list-content .version-item:not(.active):hover{background:#F8F8F8}.version-list-root .version-list-content .version-item.active{background-color:var(--editor-version-select-bg-color)}.version-list-root .version-list-content .version-item.active .version-item-title .version-actions{display:flex}.version-list-root .version-list-content .version-item.active .version-item-title .version-item-date{color:#338fe5}.version-list-root .version-list-content .version-item.editing .version-item-memo{display:none}.version-list-root .version-list-content .version-item.active .version-item-memo{cursor:text}.version-list-root .version-list-content .version-item.active .version-item-memo:hover{outline:1px solid #338FE5}.version-list-root .version-list-content .version-item .version-item-restore-from{color:#909090;font-size:12px;line-height:1.5em;height:20px;padding:0 10px 10px}.version-list-root .version-list-content .version-item .version-item-restore-from:empty{display:none}.version-list-root .version-list-content .version-item .memo-input.size-limit-textarea{width:100%;min-height:60px;display:flex}.version-list-root .version-list-content .version-item .memo-input.size-limit-textarea textarea{padding:4px 10px;box-sizing:border-box;font-size:14px}.version-list-root .version-list-content .version-item .version-item-title{display:flex;align-items:center;padding-left:10px;padding-right:10px;height:24px}.version-list-root .version-list-content .version-item .version-item-title .version-item-date{font-size:14px;font-weight:500;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;color:#303030}.version-list-root .version-list-content .version-item .version-item-title .spacer{flex-grow:1}.version-list-root .version-list-content .version-item .version-item-title .version-actions{display:none}.version-list-root .version-list-content .version-item .version-item-title .version-actions button{display:flex;align-items:center;justify-content:center;height:16px;cursor:pointer;border:none;outline:none;background:transparent;padding:0 0 0 10px;color:#909090}.version-list-root .version-list-content .version-item .version-item-title .version-actions button:hover{color:#338fe5}.version-list-root .version-list-content .version-item .version-item-title .version-actions button.disabled,.version-list-root .version-list-content .version-item .version-item-title .version-actions button.disabled:hover{color:#c7c7c7}.version-list-root .version-list-content .version-item .version-item-title .version-actions .revert-button{border-left:1px solid #E8E8E8;margin-left:10px}.version-list-root .version-list-content .version-item .version-item-authors{list-style:none;margin:0;font-size:12px;padding-left:10px}.version-list-root .version-list-content .version-item .version-item-author{display:flex;align-items:center;margin-top:10px;color:#606060}.version-list-root .version-list-content .version-item .version-item-author-mark{width:6px;height:6px;border-radius:3px;margin-right:5px}.version-list-root .version-list-content .version-item .version-item-memo{font-size:14px;color:#303030;padding:5px 10px;border-radius:3px}.version-list-root .version-list-content .version-item .version-item-memo:empty{display:none}.versions-dropdown-header{color:var(--text-color);padding:10px;border-bottom:1px solid #f0f0f0}.versions-dropdown-header .versions-dropdown-header-info{color:#909090}.versions-dropdown-header .versions-dropdown-header-icon{display:inline-flex;vertical-align:middle;height:19px;padding-left:5px;padding-right:5px;cursor:pointer;color:#909090}.versions-dropdown-header .versions-dropdown-header-icon svg{vertical-align:baseline}.editor-command-bar.menu .command-item.standard[data-id=prev-version]{height:44px}[data-command-bar-id=versions-dropdown-popup]{width:320px}[data-command-bar-id=versions-dropdown-popup] .tippy-box{color:var(--text-color)}[data-command-bar-id=versions-dropdown-popup] .tippy-box .version-item-empty{width:100%}[data-command-bar-id=versions-dropdown-popup] .tippy-box .version-item-name{color:var(--text-color)}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar.menu .command-item.standard.disabled{color:#909090}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar{--text-color: #303030}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar.menu .command-item.section{padding:0;font-size:inherit;color:inherit}[data-command-bar-id=versions-dropdown-popup] *{box-sizing:border-box}[data-command-bar-id=versions-dropdown-popup] .editor-command-bar-header{width:100%;margin-bottom:5px}[data-command-bar-id=versions-dropdown-popup] .command-item{width:100%;cursor:pointer}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container{padding:6px 10px;width:100%}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-memo{font-size:12px;color:#909090;line-height:20px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-line1{line-height:22px;display:flex;align-items:center;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-line1 .version-item-latest{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;margin-left:10px;border-radius:3px;font-size:12px;display:inline-flex;align-items:center}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-empty{display:flex;height:34px;color:#909090;padding-left:10px;justify-content:left;align-items:center}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item{width:100%}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-info{height:24px;color:#909090;display:flex;align-items:center;padding-left:10px;background-color:#f8f8f8;width:100%;box-sizing:border-box;margin:5px 0}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container{height:34px;display:flex;align-items:center;padding-left:10px;color:#303030}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container .filter-item-input{position:relative;top:-1px;left:-2px;cursor:pointer;accent-color:#338FE5}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container .filter-item-label{user-select:none;cursor:pointer;line-height:1em}.editor-root.readonly .editor-content div[data-type=editor-block].focused div[data-type=block-tools] .block-helper .heading-marker,.editor-root.readonly .editor-content div[data-type=editor-block].highlighted div[data-type=block-tools] .block-helper .heading-marker{display:flex}.editor-root .editor-content div[data-type=editor-block].heading-collapsed div[data-type=block-tools] .block-helper .heading-collapse-button svg{transform:rotate(270deg)}.editor-root .editor-content div[data-type=editor-block].focused div[data-type=block-tools] .block-helper .heading-marker,.editor-root .editor-content div[data-type=editor-block].highlighted div[data-type=block-tools] .block-helper .heading-marker{display:none}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button{width:24px;height:24px;cursor:grab;margin:0;padding:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;border-radius:3px;box-sizing:content-box}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker:hover,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button:hover{background-color:var(--selected-color)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker svg,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button svg{transform:rotate(360deg);transition:transform .2s linear}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker svg,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button svg{width:16px;height:16px}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker{color:#c7c7c7}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker:hover{background-color:transparent}.embed-block div[data-type=block-content] .editor-toc-container{display:block;width:100%;background-color:#f0f0f0;padding:20px}.embed-block div[data-type=block-content] .editor-toc-container.loading{margin:0;min-height:100px}.embed-block div[data-type=block-content] .editor-toc-container .toc-node+.toc-node{margin-top:10px}.embed-block div[data-type=block-content] .editor-toc-container .toc-node .toc-text{cursor:pointer;color:var(--primary-color)}.embed-block div[data-type=block-content] .editor-toc-container .toc-node .toc-children{margin-top:10px;padding-left:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=mention] span[data-type=box-content]{margin:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=mention] span[data-type=box-content] .mention-name{color:var(--primary-color);padding:0;border-radius:12px;margin-left:4px;margin-right:4px;white-space:wrap;word-break:break-all;cursor:pointer}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon{width:20px;height:20px;border-radius:50%;overflow:hidden}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon img{width:100%;height:100%}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon .mention-user-avatar-string{align-items:center;display:flex;justify-content:center;overflow:hidden;height:100%;width:100%;font-size:12px;color:#fff;flex-shrink:0}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-name{flex-grow:0;margin-right:5px}.editor-root .editor-templates{position:fixed;bottom:26px;height:256px;width:auto;max-width:100%;padding-left:30px;padding-right:44px;overflow:hidden}.editor-root .editor-templates .editor-templates-title{color:#909090;font-size:14px;margin-left:0;margin-bottom:20px;line-height:19.6px}.editor-root .editor-templates .editor-templates-cards{display:flex;margin-left:0}.editor-root .editor-templates .editor-templates-cards .editor-template-card{box-sizing:border-box;display:flex;flex-direction:column;justify-content:center;cursor:pointer;flex-shrink:0;height:192px;width:188px;background:none;border:1px solid #e8e8e8;border-radius:3px;margin:0 0 0 15px;padding:0;align-items:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card:first-child{margin-left:0}.editor-root .editor-templates .editor-templates-cards .editor-template-card:hover{box-shadow:0 0 1px #30303033,0 8px 16px #30303026}.editor-root .editor-templates .editor-templates-cards .editor-template-card:hover>.editor-template-name{color:#338fe5}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-name{display:flex;align-items:center;height:40px;width:100%;border-top:1px solid #dedede;padding-left:20px;padding-right:20px;flex:0 0 50px;font-size:14px;font-weight:500;line-height:22px;color:#303030}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-name span{display:block;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-name{border-top:none}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-name span{padding-left:0;text-align:center}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-thumb-container{display:flex;align-items:center;justify-content:center;padding:16px 39px 14px}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-thumb-container>img{width:110px;height:112px;max-width:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-thumb-container{flex:1;position:relative;padding:10px 5px 0;height:142px;margin:0;overflow:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-thumb-container>img{max-width:100%}:root div[data-command-bar-id=webpage]>div.tippy-box{max-width:500px}:root div[data-command-bar-id=webpage]>div.tippy-box div.tippy-content{width:500px;padding:0}.editor-dialog-container{width:500px}.editor-dialog-container .dialog-header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;padding:0 20px;height:50px;border-bottom:1px solid #e8e8e8;margin-bottom:20px}.editor-dialog-container .dialog-header .close-icon{display:flex;cursor:pointer}.editor-dialog-container .dialog-header .dialog-header-title{padding:8px 0 11px;font-size:18px;font-weight:700;flex-grow:1}.editor-dialog-container .dialog-content{padding:0 20px 20px;border-bottom:1px solid #e8e8e8}.editor-dialog-container .dialog-footer{margin:10px 0;padding:0 20px;text-align:right}.editor-dialog-container .dialog-footer button{min-height:30px;border-radius:3px;font-size:14px}.editor-disable-scroll.editor-disable-scroll-dark{background-color:#00000080}.embed-block[data-embed-type=webpage]{height:400px;min-height:100px;max-height:1000px}.embed-block[data-embed-type=webpage] .webpage-mask{position:absolute;left:0;right:0;top:0;bottom:0;z-index:1;background-color:transparent}.embed-block[data-embed-type=webpage].resizing [data-type=block-tools] .block-resizer{pointer-events:all!important}.embed-block[data-embed-type=webpage].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=webpage].selected>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=webpage]>div[data-type=block-content]{justify-content:center;height:100%}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed{width:100%}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed .editor-preview-iframe{width:100%;max-height:500px;height:100%;border:none;position:relative}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed .editor-preview-iframe-loading{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;justify-content:center;align-items:center;background-color:#fff}.webpage-content .help-container{color:#303030;border:1px solid #dedede;padding:10px;border-radius:4px;border-left:4px solid #338fe5;margin-top:16px;margin-bottom:16px}.webpage-content .help-container .help-content{display:flex;align-items:center}.webpage-content .help-container .help-content .help-icon{display:flex;align-items:center;height:20px;color:#338fe5;margin-right:12px}.webpage-content .help-link-container{margin-top:8px;display:flex;align-items:center}.webpage-content .help-link-container .help-link-content{display:flex;align-items:center;color:#338fe5;text-decoration:none}.webpage-content .help-link-container .help-link-content .help-link-icon{width:16px;height:16px;margin-left:8px}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-embed-type=webpage]>div[data-type=block-content]:before{display:block}:root{--editor-quoted-color: #7084a4;--editor-drawio-empty-svg: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDgiIGhlaWdodD0iNDgiIHZpZXdCb3g9IjAgMCA0OCA0OCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0zOC43MjAzIDI4LjcwOTdIMjUuOTIzM0MyNS4yMTY1IDI4LjcwOTcgMjQuNjQzNSAyOC4xNDgxIDI0LjY0MzUgMjcuNDU1MlYyNS43MzMzSDIwLjUyODNDMjAuNDk4NiAyNS43Njk2IDIwLjQ2NjkgMjUuODA0MiAyMC40MzMzIDI1LjgzN0wxNS45MTkyIDMwLjI2MjFWMzQuNzU1NkgyNC42NDM1VjMzLjcyNzZDMjQuNjQzNSAzMy4wMzQ4IDI1LjIxNjUgMzIuNDczMiAyNS45MjMzIDMyLjQ3MzJIMzguNzIwM0MzOS40MjcgMzIuNDczMiA0MCAzMy4wMzQ4IDQwIDMzLjcyNzZWMzguNzQ1NUM0MCAzOS40MzgzIDM5LjQyNyA0MCAzOC43MjAzIDQwSDI1LjkyMzNDMjUuMjE2NSA0MCAyNC42NDM1IDM5LjQzODMgMjQuNjQzNSAzOC43NDU1VjM3LjMzMzNIMTQuNjI2M0MxMy45MTIyIDM3LjMzMzMgMTMuMzMzMyAzNi43NTYyIDEzLjMzMzMgMzYuMDQ0NFYzMC42OTQxTDguMzc4NTIgMjUuODM3QzguMTM2MjYgMjUuNjAxNCA4IDI1LjI4MDggOCAyNC45NDYzQzggMjQuNjExOCA4LjEzNjI2IDI0LjI5MTEgOC4zNzg1MiAyNC4wNTU2TDEzLjMzMzMgMTkuMTk4NVYxNS43NzJDMTEuNzc5OCAxNS4yMjI5IDEwLjY2NjcgMTMuNzQxNiAxMC42NjY3IDEyQzEwLjY2NjcgOS43OTA4NSAxMi40NTc1IDggMTQuNjY2NyA4QzE2Ljg3NTggOCAxOC42NjY2IDkuNzkwODUgMTguNjY2NiAxMkMxOC42NjY2IDEzLjcyNjUgMTcuNTU4OCAxNS4yNTgxIDE1LjkxOTEgMTUuNzk4OFYxOS4yODg4QzE1LjkxOTEgMTkuMzkxOCAxNS45MDY4IDE5LjQ5NDMgMTUuODgyMyAxOS41OTQzTDE5LjUxNTEgMjMuMTU1NUgyNC42NDM1VjIyLjQzNzNDMjQuNjQzNSAyMS43NDQ1IDI1LjIxNjUgMjEuMTgyOSAyNS45MjMzIDIxLjE4MjlIMzguNzIwM0MzOS40MjcgMjEuMTgyOSA0MCAyMS43NDQ1IDQwIDIyLjQzNzNWMjcuNDU1MkM0MCAyOC4xNDgxIDM5LjQyNyAyOC43MDk3IDM4LjcyMDMgMjguNzA5N1pNMjcuMjAzIDM3LjQ5MUgzNy40NDA2VjM0Ljk4MjFIMjcuMjAzVjM3LjQ5MVpNMTQuNDA1OSAyOC4xOTU0TDExLjA5MTUgMjQuOTQ2M0wxNC40MDU5IDIxLjY5NzJMMTcuNzIwNCAyNC45NDYzTDE0LjQwNTkgMjguMTk1NFpNMjcuMjAzIDI2LjIwMDhIMzcuNDQwNlYyMy42OTE4SDI3LjIwM1YyNi4yMDA4WiIgZmlsbD0iIzA3MTQyQSIvPgo8L3N2Zz4K)}.flex-center,.editor-drawio-iframe-container.loading:before{display:flex;align-items:center;justify-content:center}.full-screen,.editor-drawio-iframe-container.loading:before,.drawio-iframe-element,.editor-drawio-iframe-container{width:100%;height:100%}.editor-drawio-iframe-container{position:fixed;top:0;left:0;z-index:1000}div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content]{outline:1px solid #dedede}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio].drawio-load-error>div[data-type=block-content]{padding:0;min-height:200px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio].drawio-load-error>div[data-type=block-content] .editor-drawio-content{width:100%;height:100%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content]{justify-content:center;border-radius:3px;padding:10px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content{display:flex;flex-direction:column;align-items:center;justify-content:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content{width:100%;height:100%;background-color:#f8f8f8;display:flex;flex-direction:column;justify-content:center;text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-brand-icon>svg{width:48px;height:48px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-title{font-weight:500;font-size:18px;line-height:26px;text-align:center;color:#303030;margin:23px 0 5px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-sub-title{font-size:14px;line-height:22px;text-align:center;color:#606060}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-sub-title>span.drawio-error-retry-button{cursor:pointer;margin-left:4px;color:#338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .drawio-empty-content{display:flex;flex-direction:column;align-items:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .drawio-empty-content>span{font-size:14px;line-height:22px;text-align:center;color:#606060;margin-top:23px}.embed-block .editor-empty-drawio.editor-drawio-content.editor-embed{width:240px;height:80px;display:inline-block;text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-embed-type=drawio].embed-block>div[data-type=block-content] img{max-width:100%;max-height:100%}.editor-drawio-iframe-container.loading:before{content:attr(data-placeholder);position:absolute;top:0;left:0;background-color:#f7f6f3;z-index:2}.editor-content .editing{background-color:#cdcdcd40}.editor-content div[data-type=block-tools] .embed-code-editor-container{position:absolute;top:0;left:0px;right:0px;bottom:0;background-color:#cdcdcd40;z-index:var(--wiz-editor-z-embed-code-editor-mask);padding:8px}.editor-content div[data-type=block-tools] .embed-code-editor-container textarea{width:100%;height:100%;resize:none;outline:none;padding:12px;border:1px solid #b9bfc8;border-radius:4px;background-color:#fff;color:#333}.flex-row-center,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=mermaid],.embed-block[data-embed-type=flowchart],.embed-block[data-embed-type=plantuml]{display:flex;flex-direction:row;align-items:center;justify-content:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content],.embed-block[data-embed-type=flowchart] div[data-type=block-content],.embed-block[data-embed-type=plantuml] div[data-type=block-content]{width:100%;position:relative;border:1px solid #e5e5e5;border-radius:3px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed{width:100%;min-height:106px;background-color:#cdcdcd40}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed:after{content:attr(data-empty-tips);position:absolute;top:0;right:0;width:100%;height:100%;color:#07142a;white-space:nowrap}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed){width:100%;height:100px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed) img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed) img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed) img{display:none}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed):after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed):after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed):after{content:attr(data-invalid-text);position:absolute;top:0;right:0;width:100%;height:100%;outline:1px solid red;display:flex;flex-direction:row;align-items:center;justify-content:center;color:red}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-img-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-img-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-img-content{width:100%;text-align:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .mermaid-embed-img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .mermaid-embed-img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .mermaid-embed-img{max-width:100%;min-width:200px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .editor-plantuml-img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .editor-plantuml-img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .editor-plantuml-img{max-width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-graph-img-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-graph-img-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-graph-img-content{width:100%;text-align:center;padding:10px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-graph-img-content img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-graph-img-content img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-graph-img-content img{max-width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed{width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content{width:100%;height:100%;min-height:200px;background-color:#f8f8f8;display:flex;flex-direction:column;justify-content:center;text-align:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg{width:48px;height:48px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title{font-weight:500;font-size:18px;line-height:26px;text-align:center;color:#303030;margin:23px 0 5px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title{font-size:14px;line-height:22px;text-align:center;color:#606060}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button{cursor:pointer;margin-left:4px;color:#338fe5}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content{background-color:#fff}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg{width:48px;height:48px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title{font-weight:400;font-size:14px;line-height:22px;text-align:center;color:#606060;margin-top:23px}.hr-transition,.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container .editor-embed-hr{transition:border-top ease-in-out .4s}.embed-block[data-type=editor-block][data-embed-type=hr].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-type=editor-block][data-embed-type=hr].selected>div[data-type=block-content]{outline:none!important}.embed-block[data-type=editor-block][data-embed-type=hr]:is(.focused) div[data-type=block-content] .editor-embed-container .editor-embed-hr{caret-color:transparent}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container{display:flex;align-items:center;width:100%;height:24px}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container .editor-embed-hr{display:block;width:100%;border:none;margin:0;border-top:2px dashed #cccccc;cursor:pointer}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-tools]>div.block-helper{height:100%}:root{--hover-color: #40a9ff}.flex-column-center,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{display:flex;justify-content:center;align-items:center;flex-flow:column}.common{width:400px;height:180px;background-color:#fafafa;border:1px dashed #d9d9d9;border-radius:2px;transition:border-color .3s}.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{height:200px}.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty .media-error-icon,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .media-error-icon{display:flex}.editor-root .editor-content div[data-type=editor-block].embed-block.media-block-uploading div[data-type=block-tools] .block-helper{display:none}.embed-block[data-embed-type=video]{display:flex}.embed-block[data-embed-type=video][data-style-align=left]>div[data-type=block-content]{justify-content:flex-start}.embed-block[data-embed-type=video][data-style-align=center]>div[data-type=block-content]{justify-content:center}.embed-block[data-embed-type=video][data-style-align=right]>div[data-type=block-content]{justify-content:flex-end}.embed-block[data-embed-type=video]>div[data-type=block-content]{border:none}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error{height:400px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty .media-error-icon,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .media-error-icon{display:flex}.embed-block[data-embed-type=video].hover>div[data-type=block-content],.embed-block[data-embed-type=audio].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=video].selected>div[data-type=block-content]:before,.embed-block[data-embed-type=audio].selected>div[data-type=block-content]:before{display:none}.embed-block[data-embed-type=video]>div[data-type=block-content],.embed-block[data-embed-type=audio]>div[data-type=block-content]{justify-content:center;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media.full-screen,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media.full-screen{width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media{display:flex;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress{position:relative;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress audio,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress audio{display:block;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress video,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress video{display:block;max-width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask{position:absolute;top:0;left:0;right:0;bottom:0;background-color:#303030;opacity:.8;display:flex;align-items:center;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar{width:75%;height:6px;border-radius:3px;display:flex;background-color:#fff;overflow:hidden}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value{background-color:#338fe5}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{width:100%;background:#F8F8F8;outline:1px solid #DEDEDE;border-radius:3px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error-icon svg,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error-icon svg{width:48px;height:48px;color:#c7c7c7}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .line-1,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .line-1{margin-top:10px;font-size:18px;text-align:center;color:#303030}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .line-2,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .line-2{margin-top:5px;font-size:14px;text-align:center;color:#606060}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .retry-upload,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .retry-upload{margin-left:4px;color:#338fe5;cursor:pointer;text-decoration:none}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty{width:100%;background:#FFFFFF;outline:1px solid #DEDEDE;border-radius:3px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty svg,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty svg{width:48px;height:48px;color:#c7c7c7}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element{width:100%;display:flex;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .video-container video,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .video-container video{display:block;min-width:50px;max-width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .audio-container,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .audio-container{width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .audio-container audio,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .audio-container audio{display:block;width:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment{box-shadow:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment .media,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment .media{box-shadow:0 2px #f8e6ab}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment.active,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment.active{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment.active .media,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment.active .media{box-shadow:none;outline:4px solid #f8e6ab}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content]:after{display:none}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content] .media{position:relative}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content] .media:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#303030;opacity:.1}`)),document.head.appendChild(t)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
1
+ (function(){"use strict";try{if(typeof document!="undefined"){var t=document.createElement("style");t.appendChild(document.createTextNode(`@keyframes ones-editor-blink{0%,to{background-color:transparent}50%{background-color:var(--primary-color)}}*{--link-color: #338fe5;--color-0: #e52727;--color-1: #eb6414;--color-2: #f0a100;--color-3: #24b47e;--color-4: #338fe5;--color-5: #9678d3;--color-6: #909090;--background-color-0: #fad4d4;--background-color-1: #fbe0d0;--background-color-2: #fceccc;--background-color-3: #d3f0e5;--background-color-4: #d6e9fa;--background-color-5: #eae4f6;--background-color-6: #dedede;--background-color-7: #e52727;--background-color-8: #eb6414;--background-color-9: #f0a100;--background-color-10: #24b47e;--background-color-11: #338fe5;--background-color-12: #9678d3;--background-color-13: #909090;--background-color-14: #e8e8e8;--font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif}div.editor-root{--text-color: #303030;--primary-color: #338fe5;--background-selection: #338fe533;--background-code: #cdcdcd40}div.editor-root{color:var(--text-color);position:relative;box-sizing:border-box;min-height:100%;width:100%;z-index:1}div.editor-root.readonly div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span.text.link{cursor:pointer}div.editor-root *{box-sizing:border-box;font-family:var(--font-family)}div.editor-root button{outline:none}div.editor-root.active div.editor-content .editor-cursor{opacity:1}div.editor-root .safari.mobile div.editor-content .editor-input{pointer-events:all;width:8px}div.editor-root div.editor-content{height:100%;width:100%;padding:0 30px 30px}div.editor-root div.editor-content .editor-cursor{position:absolute;background:var(--primary-color);width:2px;transition:top .1s ease-in,left .1s linear;animation:ones-editor-blink 1s ease-in-out infinite;opacity:0;pointer-events:none}div.editor-root div.editor-content .editor-input{position:absolute;opacity:0;pointer-events:none;width:16px;height:20px;font-size:16px}div.editor-root div.editor-content div[data-type=editor-container]{position:relative}div.editor-root div.editor-content div[data-type=editor-container].root{user-select:none;width:100%;cursor:text}div.editor-root div.editor-content div[data-type=editor-container].root>.container-blocks>*+*{margin-top:1em}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block]:not(:first-of-type){background-color:var(--background-selection)}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block]:not(:first-of-type) div[data-type=block-background]>.editor-selection-background{background-color:transparent!important}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block].embed-block>div[data-type=block-content]:before,div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block].embed-block .embed-selected-content:before{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]+div[data-type=editor-block][data-style-quoted]{margin-top:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block]{font-size:var(--font-size);line-height:var(--line-height);position:relative;--font-size: 15px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=center] div[data-type=block-content]{text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=right] div[data-type=block-content]{text-align:end}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].block-hidden{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=text]{cursor:text}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]{word-break:break-word;position:relative}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span{cursor:text}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text{white-space:pre-wrap}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link{color:var(--link-color)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link:hover{text-decoration:underline}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.link.style-strikethrough:hover{text-decoration:underline line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-bold{font-weight:700}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-italic{font-style:italic}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-underline{text-decoration:underline}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-strikethrough{text-decoration:line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-underline.style-strikethrough{text-decoration:underline line-through}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-code{border-radius:5px;-moz-border-radius:5px;-webkit-border-radius:5px;background-color:var(--background-code);padding:4px;font:.8em Monaco,Consolas,"Andale Mono",DejaVu Sans Mono,monospace}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-sub{vertical-align:sub;font-size:70%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text.style-super{vertical-align:super;font-size:70%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="0"]{color:var(--color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="1"]{color:var(--color-1)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="2"]{color:var(--color-2)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="3"]{color:var(--color-3)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="4"]{color:var(--color-4)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="5"]{color:var(--color-5)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-color="6"]{color:var(--color-6)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="0"]{background-color:var(--background-color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="1"]{background-color:var(--background-color-1)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="2"]{background-color:var(--background-color-2)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="3"]{background-color:var(--background-color-3)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="4"]{background-color:var(--background-color-4)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="5"]{background-color:var(--background-color-5)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="6"]{background-color:var(--background-color-6)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="7"]{background-color:var(--background-color-7)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="8"]{background-color:var(--background-color-8)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="9"]{background-color:var(--background-color-9)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="10"]{background-color:var(--background-color-10)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="11"]{background-color:var(--background-color-11)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="12"]{background-color:var(--background-color-12)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="13"]{background-color:var(--background-color-13)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.text[data-style-bg-color="14"]{background-color:var(--background-color-14)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].inputting-insertion>span[data-type=insertion-content]{border-bottom:1px solid var(--primary-color)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion{width:0px;position:relative;display:inline-block;vertical-align:text-bottom;overflow:visible;height:1em}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content]{position:absolute;color:transparent;width:3px;left:-3px;border-right:var(--cursor-color) 1px solid;text-overflow:clip;display:inline-block;top:-5px;bottom:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content] span[data-cursor-name]{display:inline-block;width:8px;background-color:transparent;border:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion>span[data-type=insertion-content] span[data-cursor-name]:hover:before,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span[data-type=editor-insertion].remote-cursor-insertion.active>span[data-type=insertion-content] span[data-cursor-name]:before{content:attr(data-cursor-name);position:absolute;top:-12px;height:1.1em;background-color:var(--cursor-color);z-index:27;left:0px;color:#fff;white-space:nowrap;font-size:12px;display:flex;align-items:center;padding:1px 4px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=box-content]{border-radius:2px;margin-left:8px;margin-right:8px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=editor-box].br-box>span[data-type=box-content] img{vertical-align:middle;max-width:1em}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] span[data-type=editor-box][data-box-type=image].image-box span[data-type=box-content]{user-select:none;margin-left:0;margin-right:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-tools] .editor-block-anchor{position:absolute}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-background] .editor-selection-background{position:absolute;background-color:var(--background-selection);z-index:1;pointer-events:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block{cursor:default}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.hover>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block.hover>div[data-type=block-content]{outline:1px solid #338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block>div[data-type=block-content]{display:flex}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.hover .embed-hover-content{outline:1px solid #338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected>div[data-type=block-content],div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected .embed-selected-content{position:relative}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected>div[data-type=block-content]:before,div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block.selected .embed-selected-content:before{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#338fe5;opacity:.1}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block{color:#909090;font-size:12px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].unknown-block>div[data-type=block-content]{padding:5px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]{border-left:4px solid #e8e8e8;color:#909090}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-quoted]:not([data-list-level]){padding-left:8px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="1"]{--font-size: 28px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="1"]:not(:first-child){margin-top:24px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="2"]{--font-size: 26px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="2"]:not(:first-child){margin-top:24px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="3"]{--font-size: 24px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="3"]:not(:first-child){margin-top:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="4"]{--font-size: 22px;--line-height: 1.5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="4"]:not(:first-child){margin-top:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="5"]{--font-size: 20px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="5"]:not(:first-child){margin-top:16px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="6"]{--font-size: 18px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="6"]:not(:first-child){margin-top:16px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="7"]{--font-size: 16px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading="8"]{--font-size: 14px;--line-height: 1.6}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-heading]{font-size:var(--font-size);line-height:var(--line-height);font-weight:700}.editor-disable-scroll{position:fixed;left:0;top:0;width:100vw;height:100vh;z-index:9900;overflow:hidden}div:not(.comment-editor-root)>div.editor-root>div.editor-content>div[data-type=editor-container]>div.container-blocks>div[data-type=editor-block]:first-of-type{font-size:30px;line-height:1.3}div.comment-editor-root div.root.select-all>.container-blocks>div[data-type=editor-block]:first-of-type{background-color:var(--background-selection)}div.comment-editor-root div.root.select-all>.container-blocks>div[data-type=editor-block]:first-of-type div[data-type=block-background]>.editor-selection-background{background-color:transparent!important}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-anchor{position:absolute;pointer-events:none;z-index:-1}.editor-command-bar.toolbar .color-button{width:24px;height:24px;display:flex;padding:0;margin:0;align-items:center;justify-content:center;background-color:transparent;border:0;outline:0;border-radius:3px;cursor:pointer}.editor-command-bar.toolbar .color-button[data-color="0"]{color:var(--color-0)}.editor-command-bar.toolbar .color-button[data-color="1"]{color:var(--color-1)}.editor-command-bar.toolbar .color-button[data-color="2"]{color:var(--color-2)}.editor-command-bar.toolbar .color-button[data-color="3"]{color:var(--color-3)}.editor-command-bar.toolbar .color-button[data-color="4"]{color:var(--color-4)}.editor-command-bar.toolbar .color-button[data-color="5"]{color:var(--color-5)}.editor-command-bar.toolbar .color-button[data-color="6"]{color:var(--color-6)}.editor-command-bar.toolbar .color-button[data-background-color="0"]{background-color:var(--background-color-0)}.editor-command-bar.toolbar .color-button[data-background-color="1"]{background-color:var(--background-color-1)}.editor-command-bar.toolbar .color-button[data-background-color="2"]{background-color:var(--background-color-2)}.editor-command-bar.toolbar .color-button[data-background-color="3"]{background-color:var(--background-color-3)}.editor-command-bar.toolbar .color-button[data-background-color="4"]{background-color:var(--background-color-4)}.editor-command-bar.toolbar .color-button[data-background-color="5"]{background-color:var(--background-color-5)}.editor-command-bar.toolbar .color-button[data-background-color="6"]{background-color:var(--background-color-6)}.editor-command-bar.toolbar .color-button[data-background-color="7"]{background-color:var(--background-color-7)}.editor-command-bar.toolbar .color-button[data-background-color="8"]{background-color:var(--background-color-8)}.editor-command-bar.toolbar .color-button[data-background-color="9"]{background-color:var(--background-color-9)}.editor-command-bar.toolbar .color-button[data-background-color="10"]{background-color:var(--background-color-10)}.editor-command-bar.toolbar .color-button[data-background-color="11"]{background-color:var(--background-color-11)}.editor-command-bar.toolbar .color-button[data-background-color="12"]{background-color:var(--background-color-12)}.editor-command-bar.toolbar .color-button[data-background-color="13"]{background-color:var(--background-color-13)}.editor-command-bar.toolbar .color-button[data-background-color="14"]{background-color:var(--background-color-14)}.tippy-content{white-space:pre-line}.editor-button{min-height:26px;min-width:46px;font-size:12px;font-weight:400;outline:none;background-color:#fff;color:#606060;border:1px solid #c7c7c7;padding:4px 8px;border-radius:4px;margin-right:8px;cursor:pointer}.editor-button:disabled{cursor:not-allowed;opacity:.5;background-color:#e8e8e8}.editor-button:not(:disabled):hover{border:1px solid #338fe5;background-color:#eaf3fc;color:#338fe5}.editor-button.primary{font-weight:500;border:1px solid rgba(0,0,0,0);background-color:var(--editor-button-bg-color, #338fe5);color:var(--editor-button-color, #fff)}.editor-button.primary:not(:disabled):hover{background-color:#5ca5ea;border:1px solid rgba(0,0,0,0);color:var(--editor-button-color, #fff)}.editor-button.primary:disabled{cursor:not-allowed;opacity:.5}.editor-button.primary:not(:disabled):active{background-color:#2872b7;color:#fff;border-color:#2872b7}.editor-button:last-child{margin-right:0}.editor-button:not(:disabled):active{background-color:#d6e9fa;color:#2872b7;border-color:#2872b7}.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}[data-theme=dropdown-list]{border-radius:4px;background:white;position:relative;max-width:calc(100vw - 24px);box-shadow:#0f0f0f0d 0 0 0 1px,#0f0f0f1a 0 3px 6px,#0f0f0f33 0 9px 24px;overflow:hidden}[data-theme=dropdown-list] .tippy-content{padding:0;background:white;color:#303030}[data-theme=dropdown-list] .tippy-content .editor-command-bar{max-height:50vh}[data-theme=dropdown-list] .filterable-list{min-width:100px;max-width:300px;display:flex;flex-direction:column;max-height:100%}[data-theme=dropdown-list] .filterable-list .filter{padding:8px}[data-theme=dropdown-list] .filterable-list .filter .filter-container{width:100%;font-size:14px;line-height:20px;padding:3px 6px;position:relative;border-radius:3px;box-shadow:#0f0f0f1a 0 0 0 1px inset;background:rgba(242,241,238,.6);cursor:text;height:28px;box-sizing:border-box;display:flex;align-items:center}[data-theme=dropdown-list] .filterable-list .filter .filter-container input.filter-input{border:none;outline:none;flex-grow:1;background:transparent}[data-theme=dropdown-list] .filterable-list .list{max-height:60vh;overflow-y:auto;padding:8px 0}[data-theme=dropdown-list] .filterable-list .list .list-item{user-select:none;transition:background 20ms ease-in 0s;cursor:pointer;width:calc(100% - 8px);margin-left:4px;margin-right:4px;border-radius:3px;height:24px;padding:4px 8px;display:flex;align-items:center;box-sizing:border-box}[data-theme=dropdown-list] .filterable-list .list .list-item .list-text{white-space:nowrap}[data-theme=dropdown-list] .filterable-list .list .list-item.selected{background-color:#eee}[data-theme=dropdown-list] .filterable-list .list .list-item.disabled{color:#c1c1c1}::placeholder{color:#bbb}.toast{font-family:Avenir,Helvetica,Arial,sans-serif;visibility:hidden;min-width:250px;margin-left:-125px;background-color:#333;color:#fff;text-align:center;border-radius:2px;padding:8px;position:fixed;z-index:1;left:50%;bottom:30px}.toast.show{visibility:visible;animation:toast_fade_in .5s,toast_fade_out .5s 2.5s}.toast.positioned.show{animation:toast_fade_in_positioned .5s,toast_fade_out_positioned .5s 2.5s}.toast.positioned{bottom:unset}@keyframes toast_fade_in{0%{bottom:0;opacity:0}to{bottom:30px;opacity:1}}@keyframes toast_fade_out{0%{bottom:30px;opacity:1}to{bottom:0;opacity:0}}@keyframes toast_fade_in_positioned{0%{opacity:0}to{opacity:1}}@keyframes toast_fade_out_positioned{0%{opacity:1}to{opacity:0}}div.tippy-box[data-theme=toolbar] .tippy-content,div.tippy-box[data-theme=menu] .tippy-content{padding:0}div.tippy-box[data-theme=menu] .tippy-content .editor-command-bar.menu{min-width:180px}div.tippy-box[data-theme=menu] .tippy-content .editor-command-bar-root,div.tippy-box[data-theme=toolbar] .tippy-content .editor-command-bar-root{box-shadow:0 0 1px #30303040,0 12px 24px #30303026}div.tippy-box button{outline:none}.editor-command-bar-root{display:flex;flex-direction:column;align-items:flex-start;background:#ffffff;border-radius:2px;max-height:50vh;overflow:auto}.editor-command-bar-root.scrollable-bar>.editor-command-bar.menu{overflow-y:auto}.editor-command-bar{pointer-events:all;display:flex;box-sizing:border-box;--text-color: #606060;--primary-color: #338fe5;--selected-color: #f8f8f8;--separator-color: #e8e8e8;--warn-color: #fdf4f4}.editor-command-bar.fixed.toolbar{box-shadow:none}.editor-command-bar.menu{flex:1;width:100%;display:flex;flex-direction:column;align-items:flex-start;padding:5px 0}.editor-command-bar.menu .command-item.standard{color:#303030;user-select:none;transition:background 20ms ease-in 0s;cursor:pointer;width:100%;height:32px;padding:6px 10px;display:flex;align-items:center;box-sizing:border-box}.editor-command-bar.menu .command-item.standard .menu-item-icon{align-items:center;height:24px;width:24px;margin-right:5px;margin-top:-2px;display:flex;flex-direction:column;justify-content:center}.editor-command-bar.menu .command-item.standard .menu-item-name{white-space:nowrap;flex-grow:1;display:flex;align-items:center}.editor-command-bar.menu .command-item.standard .item-subtext{color:#b2bccd}.editor-command-bar.menu .command-item.standard .menu-item-sub-indicator{display:flex;align-items:center;justify-content:center}.editor-command-bar.menu .command-item.standard .menu-item-sub-indicator svg{width:16px;height:16px}.editor-command-bar.menu .command-item.standard.disabled{color:#c7c7c7;cursor:not-allowed}.editor-command-bar.menu .command-item.separator{height:1px;margin:4px 0;background-color:var(--separator-color);width:100%}.editor-command-bar.menu .command-item.section{font-size:.8em;color:#ccc;padding:5px 5px 5px 10px}.editor-command-bar.menu .command-item.selected{background-color:var(--selected-color)}.editor-command-bar.menu .command-item.selected[data-id=delete]{color:#e52727;background-color:var(--warn-color)}.editor-command-bar.menu .command-item.selected.disabled{background-color:transparent}.editor-command-bar.menu .command-item.checked{color:var(--primary-color)}.editor-command-bar.menu .command-item.checked .menu-item-checked-icon{display:flex;align-items:center;justify-content:center;margin-left:10px}.editor-command-bar.menu .command-item.checked.disabled{color:#c7c7c7}.editor-command-bar.menu .command-item span.highlight{color:#e52727}.editor-command-bar.toolbar{display:flex;flex-direction:row;align-items:flex-start;padding:5px 10px;gap:5px;background:#ffffff;box-shadow:0 0 1px #30303033,0 8px 16px #30303026;border-radius:3px}.editor-command-bar.toolbar .command-item{background:transparent;border:none;display:flex;align-items:center;justify-content:center;color:var(--text-color);height:24px;padding:0;cursor:pointer;border-radius:3px;min-width:24px}.editor-command-bar.toolbar .command-item.selected:not(.disabled){background-color:var(--selected-color)}.editor-command-bar.toolbar .command-item.disabled{color:#c7c7c7}.editor-command-bar.toolbar .command-item.checked{color:var(--primary-color)}.editor-command-bar.toolbar .command-item.checked.disabled{color:#c7c7c7}.editor-command-bar.toolbar .command-item.separator{margin:auto 2px;height:20px;min-width:1px;width:1px;background-color:var(--separator-color);padding:0;pointer-events:none;cursor:default}.editor-command-bar.toolbar .command-item .toolbar-item-name-container,.editor-command-bar.toolbar .command-item .toolbar-item-icon-container{display:flex}.editor-command-bar.toolbar .command-item[data-dropdown=true]{padding-left:4px;padding-right:4px}.editor-command-bar.toolbar .command-item[data-dropdown=true] .toolbar-item-icon-container{width:24px;height:24px;align-items:center;justify-content:center}.editor-command-bar.toolbar .command-item .toolbar-item-dropdown-container{display:flex}.editor-command-bar.toolbar .command-item .toolbar-item-dropdown-container svg{transform:rotate(360deg);transition:transform .2s linear}.editor-command-bar.toolbar .command-item.active .toolbar-item-dropdown-container svg{transform:rotate(180deg)}.editor-command-bar.toolbar .editor-button+.editor-button{margin-left:5px}.editor-command-bar.footer{width:100%}.reference-hidden .tippy-box[data-reference-hidden]{opacity:0;pointer-events:none;transition:none}.tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px #9aa1b126,0 4px 80px -8px #24282f40,0 4px 4px -2px #5b5e6926;background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}.editor-dropdown{display:flex;align-items:center;border:1px solid #C7C7C7;border-radius:3px;font-size:14px;width:200px;height:30px}.editor-dropdown *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}.editor-dropdown .dropdown-text,.editor-dropdown .dropdown-input{flex-grow:1;padding:2px 8px;border:none;outline:none;background:transparent;font-size:14px;color:#333;min-width:0;flex-shrink:1}.editor-dropdown .dropdown-text{margin-right:4.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;height:100%;cursor:text;line-height:24px}.editor-dropdown:hover{border-color:#338fe5}.editor-dropdown.active{border-color:#338fe5;box-shadow:0 0 0 2px #338fe533}.editor-dropdown.active .dropdown-text{display:none}.editor-dropdown:not(.active) .dropdown-input{display:none}.editor-dropdown .dropdown-labels{display:flex;align-items:center;flex-shrink:0}.editor-dropdown .dropdown-labels .dropdown-label{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;border-radius:3px;display:flex;align-items:center}.editor-dropdown .dropdown-labels .dropdown-label+.dropdown-label{margin-left:5px}.editor-dropdown .dropdown-clear-icon,.editor-dropdown .dropdown-icon{flex-shrink:0;width:16px;height:16px;margin-left:4px;display:flex;align-items:center;justify-content:center;cursor:pointer}.editor-dropdown .dropdown-clear-icon{color:#909090}.editor-dropdown .dropdown-clear-icon:hover{color:#338fe5}.editor-dropdown.empty .dropdown-clear-icon,.editor-dropdown:not(:hover) .dropdown-clear-icon{display:none}.editor-dropdown.empty .dropdown-text{color:#909090}.editor-dropdown .dropdown-icon{margin-right:4px}.scale-border:after,.color-palette .palette-container-row .background-color-button.selected:after,.color-palette .palette-container-row .background-color-button:hover:after{content:"";outline:1px solid #d6e9fa;border-radius:3px;position:absolute;left:0;right:0;top:0;bottom:0;transform:scale(1.1)}.color-palette{display:flex;flex-direction:column;align-items:center;padding-top:5px;background-color:#fff;--active-color: #2872b7}.color-palette .bar-desc{box-sizing:border-box;width:100%;height:24px;padding-left:10px;margin-bottom:10px;line-height:24px;font-size:12px;font-weight:500;background:#F8F8F8;color:#909090}.color-palette .palette-container{padding:0 10px}.color-palette .background-color .palette-container-row:first-child{margin-bottom:5px}.color-palette .palette-container-row{display:flex;flex-direction:row;margin-bottom:20px}.color-palette .palette-container-row .color-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;background-color:#fff;border:1px solid #f0f0f0;display:flex;margin:0;padding:0;align-items:center;justify-content:center}.color-palette .palette-container-row .color-button:hover{border:1px solid #d6e9fa}.color-palette .palette-container-row .color-button.selected{border:1px solid var(--primary-color)}.color-palette .palette-container-row .color-button[data-color-index="-1"]{color:var(--text-color)}.color-palette .palette-container-row .color-button[data-color-index="0"]{color:var(--color-0)}.color-palette .palette-container-row .color-button[data-color-index="1"]{color:var(--color-1)}.color-palette .palette-container-row .color-button[data-color-index="2"]{color:var(--color-2)}.color-palette .palette-container-row .color-button[data-color-index="3"]{color:var(--color-3)}.color-palette .palette-container-row .color-button[data-color-index="4"]{color:var(--color-4)}.color-palette .palette-container-row .color-button[data-color-index="5"]{color:var(--color-5)}.color-palette .palette-container-row .color-button[data-color-index="6"]{color:var(--color-6)}.color-palette .palette-container-row .background-color-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;position:relative}.color-palette .palette-container-row .background-color-button.selected:after{outline:1px solid var(--primary-color)}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]{position:relative;background-color:#fff;border:1px solid #e8e8e8}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]:after{transform:scale(1.2)}.color-palette .palette-container-row .background-color-button[data-color-index="-1"]:before{content:"";position:absolute;width:1px;height:56px;top:2px;left:22px;background-color:#c7c7c7;transform:rotate(45deg) scale(.5);transform-origin:-1px -2px}.color-palette .palette-container-row .background-color-button[data-color-index="0"]{background-color:var(--background-color-0)}.color-palette .palette-container-row .background-color-button[data-color-index="1"]{background-color:var(--background-color-1)}.color-palette .palette-container-row .background-color-button[data-color-index="2"]{background-color:var(--background-color-2)}.color-palette .palette-container-row .background-color-button[data-color-index="3"]{background-color:var(--background-color-3)}.color-palette .palette-container-row .background-color-button[data-color-index="4"]{background-color:var(--background-color-4)}.color-palette .palette-container-row .background-color-button[data-color-index="5"]{background-color:var(--background-color-5)}.color-palette .palette-container-row .background-color-button[data-color-index="6"]{background-color:var(--background-color-6)}.color-palette .palette-container-row .background-color-button[data-color-index="7"]{background-color:var(--background-color-7)}.color-palette .palette-container-row .background-color-button[data-color-index="8"]{background-color:var(--background-color-8)}.color-palette .palette-container-row .background-color-button[data-color-index="9"]{background-color:var(--background-color-9)}.color-palette .palette-container-row .background-color-button[data-color-index="10"]{background-color:var(--background-color-10)}.color-palette .palette-container-row .background-color-button[data-color-index="11"]{background-color:var(--background-color-11)}.color-palette .palette-container-row .background-color-button[data-color-index="12"]{background-color:var(--background-color-12)}.color-palette .palette-container-row .background-color-button[data-color-index="13"]{background-color:var(--background-color-13)}.color-palette .palette-container-row .background-color-button[data-color-index="14"]{background-color:var(--background-color-14)}.color-palette .palette-container-row .color-button+.color-button{margin-left:5px}.color-palette .palette-container-row .background-color-button+.background-color-button{margin-left:5px}.color-palette .clear-button-container{box-sizing:border-box;width:100%;margin-bottom:5px;padding:0 10px}.color-palette .clear-button-container .clear-button{box-sizing:border-box;padding:3px 10px;width:100%;height:26px;background:#ffffff;color:#606060;border:1px solid #c7c7c7;border-radius:3px;cursor:pointer}.color-palette .clear-button-container .clear-button:hover{border-color:var(--primary-color);color:var(--primary-color)}.color-palette .clear-button-container .clear-button:active{border-color:var(--active-color);color:var(--active-color);background-color:#d6e9fa}.editor-input-wrap .editor-input-label{margin-top:8px;margin-bottom:8px;position:relative}.editor-input-wrap .editor-input-label.required:before{content:"*";color:#e82100;position:absolute;left:-8px;top:3px}.editor-input-wrap .editor-input-label .span{font-size:14px;line-height:1.4;font-weight:700;color:#303030}.editor-input-wrap .editor-input-container{display:flex;border:none;border-radius:4px;padding:4px;background-color:#fff}.editor-input-wrap .editor-input-container .editor-input{outline:none;border:1px solid #c7c7c7;border-radius:3px;padding:4px 10px;font-size:14px;line-height:1.4;color:#000;width:100%}.editor-input-wrap .editor-input-container .editor-input:focus{border-color:#338fe5;box-shadow:0 0 0 2px #338fe533}.editor-input-wrap.error .editor-input-container{border:1px solid #e82100}.editor-input-wrap.error .editor-input-container .editor-input{border:none;outline:none;box-shadow:unset}.editor-input-wrap.error .editor-input-error{margin-top:8px;color:red;display:block}.editor-input-wrap .editor-input-error{display:none}div.scroll-container-root{position:relative}div.scroll-container-root>div.scroll-container{position:relative;overflow-x:auto;overflow-y:hidden;box-sizing:border-box;line-height:0px}div.scroll-container-root>div.scroll-container>.scroll-area{position:relative;display:inline-block;overflow:hidden;line-height:normal}div.scroll-container-root>div.scroll-container{scrollbar-width:none}div.scroll-container-root>div.scroll-container::-webkit-scrollbar{height:0;opacity:0}div.scroll-container-root>div.container-scroll-tool .container-border-shadow{position:absolute;top:0;opacity:0;width:0;border:none;pointer-events:none;transition:opacity 50ms ease-in;z-index:1}div.scroll-container-root>div.container-scroll-tool .container-right-border-shadow{right:0;background:linear-gradient(90deg,rgba(31,35,41,0) 0,rgba(31,35,41,.1));border-right:0px solid #dee0e3}div.scroll-container-root>div.container-scroll-tool .container-left-border-shadow{left:0;background:linear-gradient(270deg,rgba(31,35,41,0) 0,rgba(31,35,41,.1));border-left:0px solid #dee0e3}div.scroll-container-root>div.container-scroll-tool .container-border-shadow.active{width:8px;opacity:1}div.scroll-container-root>div.container-scroll-tool .container-right-border-shadow.active{border-right-width:1px}div.scroll-container-root>div.container-scroll-tool .container-left-border-shadow.active{border-left-width:1px}div.scroll-container-root>div.container-scroll-tool .container-scrollbar{position:absolute;left:0;z-index:1000;visibility:visible;overflow-x:auto;overflow-y:hidden;cursor:auto}div.scroll-container-root>div.container-scroll-tool .container-scrollbar div{height:1px}div.scroll-container-root>div.container-scroll-tool div.container-scrollbar.fixed{position:fixed}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar{opacity:.6;transition:opacity .1s ease-in-out}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar{height:8px}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-track{background-color:transparent}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-thumb{background-color:#646a73cc;border-radius:8px}div.scroll-container-root.mac>div.container-scroll-tool .container-scrollbar::-webkit-scrollbar-button{display:none}[data-tippy-root]{font-family:Avenir,Helvetica,Arial,sans-serif}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text]{height:32px;width:unset}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text].selected:hover{background-color:transparent}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text] .link-href-button{max-width:275px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#303030;text-decoration:none}[data-command-bar-id=editor-toolbar] .command-item[data-id=link-text] .link-href-button:hover{text-decoration:underline}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link],[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link]{height:32px}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link] svg,[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link] svg{stroke-width:2}[data-command-bar-id=editor-toolbar] .command-item[data-id=edit-link].selected:hover,[data-command-bar-id=editor-toolbar] .command-item[data-id=remove-link].selected:hover{background-color:transparent;color:#338fe5}[data-command-bar-id=quick-menu],[data-command-bar-id=empty-block-menu]{box-sizing:border-box;width:240px}[data-command-bar-id=quick-menu] .command-item.menu-item,[data-command-bar-id=empty-block-menu] .command-item.menu-item{width:100%;cursor:pointer}[data-command-bar-id=quick-menu] .command-item.menu-item.section,[data-command-bar-id=empty-block-menu] .command-item.menu-item.section{height:24px;padding:0 10px;font-weight:500;font-size:12px;line-height:24px;color:#909090;background:#f8f8f8;min-height:initial;box-sizing:border-box;margin:5px 0}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item{color:#303030;display:flex;width:100%;padding:6px 10px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container{display:flex;align-items:center;justify-content:center;padding-right:6px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container .quick-menu-item-icon,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-icon-container .quick-menu-item-icon{width:16px;height:16px;display:flex;align-items:center;justify-content:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content{flex-grow:1;display:flex;flex-direction:column;justify-content:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1{display:flex;align-items:center}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-name,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-name{flex-grow:1;font-size:14px;line-height:22px;color:#303030}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-subtext,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .item-subtext{color:#b2bccd}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .quick-menu-item-submenu-icon,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-1 .quick-menu-item-submenu-icon{display:flex;align-items:center;margin-left:12px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2{margin-top:5px}[data-command-bar-id=quick-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2 .item-markdown,[data-command-bar-id=empty-block-menu] .command-item.menu-item .quick-menu-item .quick-menu-item-content .item-line-2 .item-markdown{color:#b2bccd}[data-command-bar-id=quick-menu] .command-item.menu-item[data-id=placeholder] .quick-menu-item-icon-container,[data-command-bar-id=empty-block-menu] .command-item.menu-item[data-id=placeholder] .quick-menu-item-icon-container{display:none}[data-command-bar-id=quick-menu] .command-item.menu-item[data-id=placeholder] .item-name.text,[data-command-bar-id=empty-block-menu] .command-item.menu-item[data-id=placeholder] .item-name.text{color:#909090!important;padding:5px 0}[data-command-bar-id=block-menu]{width:240px}[data-command-bar-id=quick-menu] div.command-item>div.menu-item-name{color:#303030}[data-command-bar-id=quick-menu] div.command-item>div.menu-item-icon{color:#606060}[data-command-bar-id=quick-menu] div.command-item.section:first-of-type{margin-top:0}div.tippy-box[data-theme=editor-tooltip]{background-color:#303030;opacity:.8;font-size:12px;border-radius:3px}div.tippy-box[data-theme=editor-tooltip] .editor-tooltip-desc{display:block;margin-top:2px;color:#fff;opacity:.5}div.tippy-box[data-theme=editor-tooltip]>.tippy-arrow:before{transform:scale(.8)}div.tippy-box[data-theme=editor-tooltip]>.tippy-content{padding:4px 10px}:root div.tippy-box[data-theme=editor-tooltip]>.tippy-content{font-weight:500}:root div.tippy-box[data-theme=editor-tooltip]>.tippy-content>div>span:nth-of-type(2){font-weight:400}.link-popup-content{padding:10px 7px}.link-popup-content .link-popup-gap{margin-top:16px}.link-popup-content .editor-input-container{padding:4px 0}.link-popup-content .editor-input-container .editor-input{width:330px;line-height:1.5}.link-popup-content .editor-input-wrap .editor-input-label{margin-bottom:4px}.link-popup-content .link-popup-footer{margin:10px 0 5px;text-align:right}.link-popup-content .link-popup-footer button{min-height:30px;border-radius:3px;font-size:14px}:root{--mindmap-bg-color: #f0f2f4}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.focused [data-type=block-tools] .editor-mindmap-svg{border-radius:3px;outline:1px solid #338FE5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.editor-in-mindmap-first{height:600px;min-width:150px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-content]{margin-right:24px;transition:background-color .25s linear}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .editor-mindmap-svg{position:absolute;left:0;top:0;right:0;bottom:0;z-index:2;font-size:14px;background-color:var(--mindmap-bg-color)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar{position:absolute;top:8px;right:8px;height:24px;z-index:3}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar .editor-button.mindmap-button{background-color:transparent;outline:none;border:none;fill:none;color:#c1c1c1;cursor:pointer;min-width:initial;margin-right:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-tools] .mindmap-toolbar .editor-button.mindmap-button:hover{color:#5587f0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.to-mindmap-highlight [data-type=block-content],.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block.to-mindmap-highlight:hover [data-type=block-content]{background-color:#eaf3fc}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-to-mindmap-wrap,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .mention-button-wrap{position:absolute;right:0;top:2px;display:flex;align-items:center;height:calc(var(--font-size) * var(--line-height))}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-to-mindmap],.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=mention-button]{flex-grow:0;flex-shrink:0;width:24px;height:24px;min-width:24px;min-height:24px;padding:0;border:0;outline:0;display:flex;align-items:center;justify-content:end;background-color:transparent;color:#07142a;margin-right:8px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-to-mindmap] svg,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=mention-button] svg{width:16px;height:16px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button[data-button-id=list-block-mention]:hover>svg{cursor:initial;background-color:#eee}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block button+button[data-button-id=list-block-mention]{right:20px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="1"]{padding-left:24px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="1"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="2"]{padding-left:48px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="2"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="3"]{padding-left:72px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="3"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="4"]{padding-left:96px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="4"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="5"]{padding-left:120px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="5"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="6"]{padding-left:144px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="6"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="7"]{padding-left:168px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="7"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="8"]{padding-left:192px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="8"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="9"]{padding-left:216px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="9"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="10"]{padding-left:240px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="10"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="11"]{padding-left:264px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="11"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="12"]{padding-left:288px}div.editor-root div.editor-content div[data-block-type=text][block-padding-level="12"]>div[data-type=block-content]{position:relative}div.editor-root div.editor-content div[data-block-type=list][data-list-level="1"]{padding-left:0}div.editor-root div.editor-content div[data-block-type=list][data-list-level="2"]{padding-left:24px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="3"]{padding-left:48px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="4"]{padding-left:72px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="5"]{padding-left:96px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="6"]{padding-left:120px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="7"]{padding-left:144px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="8"]{padding-left:168px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="9"]{padding-left:192px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="10"]{padding-left:216px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="11"]{padding-left:240px}div.editor-root div.editor-content div[data-block-type=list][data-list-level="12"]{padding-left:264px}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="1"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="2"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="3"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="4"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="5"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="6"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="7"]>div.list-container>button.list-marker{font-weight:700}div.editor-root div.editor-content div[data-block-type=list][data-style-heading="8"]>div.list-container>button.list-marker{font-weight:700}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block+div[data-type=editor-block].list-block{margin-top:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block{display:flex;padding-bottom:2px;padding-top:2px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=text-only] .list-container{pointer-events:none}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] div[data-type=block-content] span.text{color:#c7c7c7}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unordered] .list-container .list-marker{font-family:PingFangSC-Regular,PingFang SC;justify-content:space-around}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper{font-feature-settings:"tnum";align-items:baseline;box-sizing:border-box;color:var(--gray-120);cursor:pointer;display:inline-flex;font-size:14px;font-variant:tabular-nums;line-height:1.5715;line-height:unset;list-style:none;margin:0;padding:0}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper>span.editor-check-box>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper>span.editor-check-box>span.editor-check-box-inner{border:1px solid #c7c7c7;border-collapse:initial;border-radius:3px;direction:ltr;display:block;height:14px;left:0;position:relative;top:0;transition:all .3s;width:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box{position:relative}@keyframes editorCheckboxEffect{0%{transform:scale(1);opacity:.5}to{transform:scale(1.6);opacity:0}}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box:after,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box:after{animation:editorCheckboxEffect .36s ease-in-out;animation-fill-mode:backwards;border:1px solid #338fe5;border-radius:3px;content:"";height:100%;left:0;position:absolute;top:0;width:100%;box-sizing:border-box}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner{border-color:#338fe5;background-color:#338fe5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner:after,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper.editor-check-list-wrapper-checked>span.editor-check-box>span.editor-check-box-inner:after{width:5px;height:10px;left:2px;top:5px;border:2px solid #fff;border-left:0;border-top:0;content:" ";display:table;opacity:1;position:absolute;box-sizing:border-box;transform:rotate(45deg) scale(1) translate(-50%,-50%)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=checked] .list-container .editor-check-list-wrapper:not(.editor-check-list-wrapper-checked)>span.editor-check-box:hover>span.editor-check-box-inner,.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container .editor-check-list-wrapper:not(.editor-check-list-wrapper-checked)>span.editor-check-box:hover>span.editor-check-box-inner{border-color:#338fe5}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block [data-type=block-content]{position:relative;flex-grow:1;padding-left:2px;margin-right:29px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-container{display:flex;min-width:24px;align-items:center;justify-content:center;flex-shrink:0;border-radius:3px;height:calc(var(--font-size) * var(--line-height))}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block .list-container .list-marker{min-width:16px;border:none;background-color:transparent;outline:none;display:flex;align-items:center;justify-content:flex-end;padding:0;overflow:visible;color:var(--primary-color);font-size:var(--font-size)}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block div[data-type=block-tools] .block-helper{top:2px}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=center]{justify-content:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=center]>div[data-type=block-content]{flex-grow:initial}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=right]{justify-content:flex-end}.editor-root [data-type=editor-container].root div[data-type=editor-block].list-block[data-style-align=right]>div[data-type=block-content]{flex-grow:initial}.editor-root.readonly button[data-button-id=mindmap-close]{display:none}.editor-root:not(.readonly) div[data-type=editor-block].list-block.active,.editor-root:not(.readonly) div[data-type=editor-block].list-block.hover{background-color:#f8f8f8}.editor-root:not(.readonly) div[data-type=editor-block].list-block.active .list-container,.editor-root:not(.readonly) div[data-type=editor-block].list-block.hover .list-container{cursor:pointer}.editor-root:not(.readonly) div[data-type=editor-block].list-block .list-container:hover .list-marker{cursor:pointer}.editor-root:not(.readonly) div[data-type=editor-block].list-block:not([data-list-type=unchecked]):not([data-list-type=checked]):not([data-list-type=unordered]) .list-container:hover{background-color:var(--background-selection)}.editor-root:not(.readonly) div[data-type=editor-block].list-block[data-list-type=unordered] .list-container:hover .list-marker{cursor:initial}.editor-root:not(.readonly) div[data-type=editor-block].list-block[data-list-type=unchecked] .list-container:hover .list-marker svg>*{fill:var(--background-selection)}[data-tippy-root] .customize-start-panel{max-width:350px;padding:0 16px;color:#333;font-size:14px;line-height:21px;user-select:none;background-color:#fff!important}[data-tippy-root] .customize-start-panel-input{width:64px;margin:0 8px;border:1px solid #cfd6e1;height:24px;border-radius:3px;padding:1px 0 1px 8px;outline:none;color:inherit;background-color:#fff}[data-tippy-root] .customize-start-panel-button{min-width:40px;font-size:12px;min-height:30px;margin:0 8px 0 0;background-color:var(--primary-color);color:#fff;outline:none;border:none;padding:4px 8px;border-radius:4px;cursor:pointer}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block].list-block [data-type=block-content][data-content-placeholder]:before{left:2px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.math-box{display:inline-flex}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content]>span.math-box .mathjax-tex-text.mathjax-error{color:var(--color-0)}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] img.mathjax{max-width:100%}div.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-embed-type=math]>div[data-type=block-content]{align-items:center;justify-content:center;min-height:40px}div.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-embed-type=math]>div[data-type=block-content] img{margin:auto;padding:8px}.mathjax-editor-textarea{border:none;outline:none;width:400px;height:128px}.editor-text-button{border:0;color:var(--text-button-color, #c1c1c1);background-color:var(--text-button-bg-color, transparent);cursor:pointer;border-radius:var(--editor-border-radius, 3px);font-size:14px;padding:1px 6px;display:flex;align-items:center}.editor-text-button:hover{color:var(--text-button-color-hover, #5587F0);background-color:var(--text-button-bg-color-hover, transparent)}div[data-type=editor-block].table-block{--table-bar-width: 6px;--table-bar-left: -6px;--table-bar-top: -6px}div[data-type=editor-block].table-block>div[data-type=block-content]{position:relative;left:-26px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-resize-gripper,div[data-type=editor-block].table-block div[data-type=table-tools] .table-resize-gripper{position:absolute;background-color:transparent;cursor:col-resize;padding:0 2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-resize-gripper>.table-resize-gripper-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-resize-gripper>.table-resize-gripper-indicator{pointer-events:none;background-color:var(--primary-color);width:100%;height:100%}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container{position:absolute;background-color:transparent;z-index:10}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container.top{left:0;top:var(--table-bar-top);right:0;height:var(--table-bar-width);flex-direction:row}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container.left{top:20px;left:var(--table-bar-left);width:var(--table-bar-width);bottom:0;flex-direction:column}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar{position:absolute;left:0;top:0;right:0;bottom:0;cursor:pointer;display:flex}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar.left{flex-direction:column}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell{background-color:#e8e8e8;position:relative;flex-grow:0;flex-shrink:0}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.corner,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.corner{width:var(--table-bar-width);height:var(--table-bar-width)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.top{height:100%}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell:hover,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell:hover{background-color:#dedede}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.selected,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.selected{background-color:var(--primary-color)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.danger,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .table-border-bar-cell.danger{background-color:#e52727}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root{position:relative}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.top{max-width:0;width:0;overflow:visible}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.top:last-child,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.top:last-child{margin-left:-2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.left{max-height:0;height:0;overflow:visible}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root.left:last-child,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root.left:last-child{margin-top:-2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container{position:absolute;width:26px;height:26px;display:flex;align-items:center;justify-content:center;z-index:1}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container.top,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container.top{right:-14px;top:-22px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container.left,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container.left{transform:rotate(270deg);left:-22px;bottom:-14px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .insert-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .insert-indicator{position:absolute;width:3px;height:3px;background:#e8e8e8;border-radius:50%;margin-top:6px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-indicator,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-indicator{display:none}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button{display:unset}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button span.icon,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .insert-column-button span.icon{margin-top:2px}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .drop-marker,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container:hover .drop-marker{opacity:1;transform:scale(.7)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker{width:26px;height:26px;border-radius:3px;background:var(--primary-color);cursor:pointer;opacity:0;transform:scale(.4);transition:transform .2s ease-in,opacity .2s ease-in}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:after,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:after{content:"";display:block;width:10px;height:2px;background-color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:before,div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root .button-container .drop-marker:before{content:"";display:block;width:2px;height:10px;background-color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%)}div[data-type=editor-block].table-block div[data-type=block-tools] .editor-table-chart,div[data-type=editor-block].table-block div[data-type=table-tools] .editor-table-chart{padding-top:16px}div[data-type=editor-block].table-block div[data-type=table-content]{position:relative}div[data-type=editor-block].table-block div[data-type=table-content]>.error{color:red;border:1px solid red;padding:8px}div[data-type=editor-block].table-block div[data-type=table-content]>table{border-collapse:collapse;width:max-content;border-spacing:0}div[data-type=editor-block].table-block div[data-type=table-content]>table colgroup col{min-width:40px}div[data-type=editor-block].table-block div[data-type=table-content]>table,div[data-type=editor-block].table-block div[data-type=table-content]>table td,div[data-type=editor-block].table-block div[data-type=table-content]>table th{border:1px solid #c7c7c7;background-color:transparent;background-clip:padding-box}div[data-type=editor-block].table-block div[data-type=table-content]>table tr td.danger{background-color:#fce9e9!important}div[data-type=editor-block].table-block div[data-type=table-content]>table td{min-width:40px;padding:0;position:relative}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn{display:none;position:absolute;right:2px;top:2px;padding:0;width:16px;height:16px;border:none;border-radius:3px;cursor:pointer;transform:rotate(0);transition:transform .2s;background-color:transparent;color:#909090}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn:hover{background-color:#e8e8e8}div[data-type=editor-block].table-block div[data-type=table-content]>table td .table-cell-menu-btn.active{transform:rotate(180deg);color:#338fe5;background:#eaf3fc}div[data-type=editor-block].table-block div[data-type=table-content]>table td>div[data-type=editor-container].child>div.container-blocks>*+*{margin-top:5px}div[data-type=editor-block].table-block div[data-type=table-content] .child{padding:8px}div[data-type=editor-block].table-block div[data-type=table-content] .child div[data-type=editor-block].table-block>div[data-type=block-content]{pointer-events:none}div[data-type=editor-block].table-block div[data-type=table-content] .child div[data-type=editor-block].table-block>div[data-type=block-content] div[data-type=table-content]{pointer-events:auto}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-0{background-color:var(--background-color-0)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-1{background-color:var(--background-color-1)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-2{background-color:var(--background-color-2)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-3{background-color:var(--background-color-3)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-4{background-color:var(--background-color-4)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-5{background-color:var(--background-color-5)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-6{background-color:var(--background-color-6)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-7{background-color:var(--background-color-7)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-8{background-color:var(--background-color-8)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-9{background-color:var(--background-color-9)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-10{background-color:var(--background-color-10)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-11{background-color:var(--background-color-11)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-12{background-color:var(--background-color-12)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-13{background-color:var(--background-color-13)}div[data-type=editor-block].table-block div[data-type=table-content]>table td.style-bg-color-14{background-color:var(--background-color-14)}div[data-type=editor-block].table-block div[data-type=table-content]>table.row-title>tbody>tr:first-child>td,div[data-type=editor-block].table-block div[data-type=table-content]>table.col-title td.col-title-item{background-color:#f8f8f8}div[data-type=editor-block].table-block div[data-type=table-content]>table.stripe:not(.row-title)>tbody>tr:nth-of-type(2n),div[data-type=editor-block].table-block div[data-type=table-content]>table.stripe.row-title>tbody>tr:nth-of-type(2n + 1){background-color:#f5f8fb}div[data-type=editor-block].table-block div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block div[data-type=table-content]>.no-border>tbody>tr>td{border:1px dashed;border-color:transparent}div[data-type=editor-block].table-block.focused div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block.focused div[data-type=table-content]>table.no-border>tbody>tr>td,div[data-type=editor-block].table-block.child-focused div[data-type=table-content]>table.no-border,div[data-type=editor-block].table-block.child-focused div[data-type=table-content]>table.no-border>tbody>tr>td{border-color:#b9bfc8}div[data-type=editor-block].table-block.full-selected>div[data-type=block-content]>.scroll-container-root>.scroll-container>.scroll-area>div[data-type=table-content]>table{background-color:var(--background-selection)}div[data-type=editor-block].table-block.full-selected>div[data-type=block-content]>.scroll-container-root>.scroll-container>.scroll-area>div[data-type=table-content]>table td,div[data-type=editor-block].table-block.full-selected>div[data-type=block-content]>.scroll-container-root>.scroll-container>.scroll-area>div[data-type=table-content]>table th,div[data-type=editor-block].table-block.full-selected>div[data-type=block-content]>.scroll-container-root>.scroll-container>.scroll-area>div[data-type=table-content]>table tr{background-color:transparent}div[data-type=editor-block].table-block div[data-type=table-content]>table tbody tr td.selected,div[data-type=editor-block].table-block div[data-type=table-content]>table.row-title tbody tr td.selected,div[data-type=editor-block].table-block div[data-type=table-content]>table.col-title tbody tr td.selected{background-color:var(--background-selection)}div[data-type=editor-block].table-block div[data-type=table-content]>table td div[data-type=editor-block].table-block div[data-type=table-content]>table{max-width:100%}.command-item.menu-item .table-creator{background-color:#fff;padding:0 5px}.command-item.menu-item .table-creator .table-creator-row{display:flex}.command-item.menu-item .table-creator .table-creator-row .table-creator-cell{width:16px;height:16px;margin:3px;border:solid 1px #ddd}.command-item.menu-item .table-creator .table-creator-row .table-creator-cell.active{background-color:#99c7f2}div.editor-root div.editor-content div[data-type=editor-container].root div[data-type=editor-block].table-block{margin-top:0}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color]{width:100%}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .bar-desc{display:none}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item{box-sizing:border-box;width:100%;height:32px;padding:5px 10px;display:flex;align-items:center;justify-content:space-between;color:var(--text-color)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-sub-indicator{display:flex;align-items:center;margin-left:5px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-sub-indicator svg{height:16px;width:16px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button{width:24px;height:24px;border:none;outline:none;cursor:pointer;border-radius:3px;position:relative;margin-left:auto}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]{position:relative;background-color:#fff;border:1px solid #e8e8e8}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]:after{transform:scale(1.2)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="-1"]:before{content:"";position:absolute;width:1px;height:56px;top:2px;left:22px;background-color:#c7c7c7;transform:rotate(45deg) scale(.5);transform-origin:-1px -2px}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="0"]{background-color:var(--background-color-0)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="1"]{background-color:var(--background-color-1)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="2"]{background-color:var(--background-color-2)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="3"]{background-color:var(--background-color-3)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="4"]{background-color:var(--background-color-4)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="5"]{background-color:var(--background-color-5)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="6"]{background-color:var(--background-color-6)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="7"]{background-color:var(--background-color-7)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="8"]{background-color:var(--background-color-8)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="9"]{background-color:var(--background-color-9)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="10"]{background-color:var(--background-color-10)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="11"]{background-color:var(--background-color-11)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="12"]{background-color:var(--background-color-12)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="13"]{background-color:var(--background-color-13)}div.tippy-box[data-theme=menu] .tippy-content div[data-id=cell-background-color] .cell-background-color-item .item-button[data-color-index="14"]{background-color:var(--background-color-14)}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table]{background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.row-title>tbody>tr:first-child>td,div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.col-title td.col-title-item{background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.stripe:not(.row-title)>tbody>tr:nth-of-type(2n),div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-block-type=table] table.stripe.row-title>tbody>tr:nth-of-type(2n + 1){background-color:transparent}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment{box-shadow:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment table{box-shadow:0 2px #f8e6ab}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment table table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment table table{box-shadow:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active{outline:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active table{border-bottom:none;outline:4px solid #f8e6ab}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-block-type=table].comment.active table table,div.editor-root div.editor-content div[data-type=editor-container].child div[data-type=editor-block][data-block-type=table].comment.active table table{box-shadow:none;outline:none}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content]:after,div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content]:after{display:none}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content] div[data-type=table-content],div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content] div[data-type=table-content]{position:relative}div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-self>[data-type=block-content] div[data-type=table-content]:after,div.editor-root:not(.readonly) div[data-type=editor-block].table-block.locked-by-others>[data-type=block-content] div[data-type=table-content]:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#303030;opacity:.1}.editor-root .editor-content div[data-type=editor-block].table-block div[data-type=block-tools] .block-helper{right:calc(100% + 5px);top:35px}[data-command-bar-id=table-row-column-toolbar] .editor-command-bar.toolbar{padding:4px}div.comment-editor-root div[data-type=editor-block].table-block>div[data-type=block-content]{left:0px}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=center] [data-type=block-content][data-content-placeholder]:before{justify-content:center}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block][data-style-align=right] [data-type=block-content][data-content-placeholder]:before{justify-content:right}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-title-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-title-placeholder);color:#c7c7c7}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-content-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-content-placeholder);color:#c7c7c7;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;display:flex;align-items:center}div.editor-root:not(.readonly) div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-tools] .block-placeholder-container{position:absolute;left:0;top:0;right:0}div.editor-root.readonly div.editor-content div[data-type=editor-container] div[data-type=editor-block] [data-type=block-content][data-title-placeholder]:before{position:absolute;left:0;top:0;right:0;bottom:0;content:attr(data-title-placeholder-readonly);color:#c7c7c7}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block{min-width:360px;counter-reset:code-line}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.full-selected{background-color:var(--background-selection)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.editing-language div[data-type=block-tools] .code-block-header,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.child-focused div[data-type=block-tools] .code-block-header,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:hover div[data-type=block-tools] .code-block-header{opacity:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.wrap>div[data-type=block-tools] .code-block-header button[data-id=wrap] *{color:var(--primary-color)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child{overflow-x:auto}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]{word-break:keep-all;overflow:visible;white-space:pre}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]>span.text,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block:not(.wrap)>div[data-type=block-content] div[data-type=editor-container].child div[data-type=block-content]>span.inputting-insertion{white-space:pre}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header{opacity:0;transition:opacity .3s ease-in 0s;position:absolute;top:0;display:flex;padding-left:16px;padding-right:4px;align-items:center;left:0;right:0;height:32px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .language-select{font-size:14px;color:#999;cursor:pointer;display:flex;align-items:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .language-select .arrow-icon{width:16px;height:16px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-spacer{flex-grow:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button{display:flex;justify-content:center;align-items:center;border:none;border-radius:2px;margin-left:4px;padding:0;background:none;outline:none;color:#c1c1c1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button:not(.disabled){cursor:pointer}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button:not(.disabled):hover{color:#5587f0}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button.disabled{cursor:not-allowed}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{margin-right:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-icon{height:24px;display:flex;align-items:center;justify-content:center}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-icon>svg{width:24px;height:24px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button .button-label{margin-left:4px;font-size:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{display:none}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block.full-selected>div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:unset}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:var(--background-code)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container]{padding-left:32px;padding-top:32px;padding-bottom:24px;border-radius:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container].selected{background-color:var(--background-selection)}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] *{font-family:Consolas,Monaco,Andale Mono,Ubuntu Mono,monospace;font-size:14px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block+div.text-block{margin-top:4px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block:before{content:counter(code-line);counter-increment:code-line;position:absolute;left:-48px;top:10px;z-index:1;margin-top:-4px;display:block;width:48px;padding-right:8px;text-align:right;color:#aaa;box-sizing:border-box;font-size:12px;font-weight:400;line-height:12px;letter-spacing:0;white-space:nowrap;opacity:1}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-comment,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-prolog,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-doctype,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-cdata{color:#708090}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-punctuation{color:#999}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-namespace{opacity:.7}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-property,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-tag,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-boolean,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-number,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-constant,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-symbol,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-deleted{color:#905}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-selector,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-attr-name,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-string,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-char,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-builtin,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-inserted{color:#690}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-operator,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-entity,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-url,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-string{color:#9a6e3a}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-atrule,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-attr-value,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-keyword{color:#07a}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-function,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-class-name{color:#dd4a68}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-regex,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-important,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-variable{color:#e90}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-important,.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-bold{font-weight:700}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-italic{font-style:italic}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-text-root>div.child[data-type=editor-container] div.text-block>div[data-type=block-content] span.style-code-entity{cursor:help}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-caption-root{padding:8px}.editor-root [data-type=editor-container].root div[data-type=editor-block].code-block>div[data-type=block-content]>div.editor-code-root>div.code-caption-root *{color:#aaa}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .code-header-button[data-id=wrap],div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .code-header-button[data-id=caption]{display:none}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .language-select{cursor:default!important}div.editor-root.readonly .container-blocks div[data-block-type=code] div[data-type=block-tools] .code-block-header .language-select .arrow-icon{display:none}div.editor-root div.editor-content div[data-type=editor-container].root.select-all div[data-type=block-content]>div.editor-code-root>div.code-text-root{background-color:unset}div.comment-editor-root [data-type=editor-container].root div[data-type=editor-block].code-block{min-width:0}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer{position:absolute;background-color:transparent;border:1px solid #338FE5;pointer-events:none;z-index:1;display:none}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer.active{display:block}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper{position:absolute;width:16px;height:16px;border:2px solid white;background-color:#338fe5;border-radius:50%;pointer-events:all}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom{left:calc(50% - 8px);bottom:-8px;cursor:ns-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.top-left{left:-8px;top:-8px;cursor:nwse-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.top-right{right:-8px;top:-8px;cursor:nesw-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom-left{left:-8px;bottom:-8px;cursor:nesw-resize}div.editor-root div.editor-content div[data-type=editor-block] [data-type=block-tools] .block-resizer .resize-gripper.bottom-right{right:-8px;bottom:-8px;cursor:nwse-resize}div.editor-root.readonly div.editor-content div[data-type=editor-block]>[data-type=block-tools] .block-resizer{display:none}.before-content,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content] .images .image-container.active:before,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected:not(.focused) [data-type=block-content] .images .image-container:before{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#338fe5;opacity:.1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image]{display:flex}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].block-hidden{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=left]{justify-content:flex-start}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=center]{justify-content:center}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image][data-style-align=right]{justify-content:flex-end}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content]{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content] .images .image-container.empty:hover,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].hover [data-type=block-content] .images .image-container.error:hover{outline:1px solid #338FE5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content]:before{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content]{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].selected [data-type=block-content] .images .image-container.active .image-warning{opacity:0;z-index:-1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].multi [data-type=block-tools] .block-resizer{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image]:not(.multi) [data-type=block-content] .images.empty{min-height:400px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content]{cursor:default}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images{width:100%;display:flex;align-items:flex-start}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter{width:10px;flex-grow:0;flex-shrink:0;padding:0 4px;cursor:col-resize;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter .image-splitter-indicator{width:100%;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter:active .image-splitter-indicator,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-splitter:hover .image-splitter-indicator{background-color:#d9d9d9}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container{position:relative;flex:1;background-color:#f8f8f8;display:flex;min-height:inherit;overflow:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container img{max-width:100%;width:100%;height:auto}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty .upload-image-icon{display:flex;color:#c7c7c7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.error{height:100%;outline:1px solid #DEDEDE;border-radius:3px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.error img{display:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error{display:flex;flex:1;flex-direction:column;align-items:center;justify-content:center;z-index:1}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-icon,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-icon{display:flex;color:#c7c7c7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message{display:flex;flex-direction:column;align-items:center;overflow:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-1,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-1{margin-top:10px;font-size:18px;font-weight:500;color:#303030;height:26px;vertical-align:middle;line-height:26px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;flex-shrink:0}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-2,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-3,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-2,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-3{font-size:14px;color:#606060;vertical-align:middle;height:22px;line-height:22px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;flex-shrink:0}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-2 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .error-message .line-3 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-2 a,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .upload-error .error-message .line-3 a{text-decoration:none;color:#338fe5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .line-3 a{display:inline-flex;align-items:center;text-decoration:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .load-error .line-3 a:after{content:" ";display:inline-block;width:16px;height:16px;margin-left:5px;background-image:url("data:image/svg+xml,%3Csvg width='17' height='16' viewBox='0 0 17 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6.5 2H3.5C2.94772 2 2.5 2.44772 2.5 3V13C2.5 13.5523 2.94772 14 3.5 14H13.5C14.0523 14 14.5 13.5523 14.5 13V10' stroke='%23338FE5'/%3E%3Cpath d='M14.5 2L9 7.5' stroke='%23338FE5'/%3E%3Cpath d='M8.5 2H14.5V8' stroke='%23338FE5'/%3E%3C/svg%3E%0A")}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask{position:absolute;top:0;left:0;right:0;bottom:0;background-color:#303030;opacity:.8;display:flex;align-items:center;justify-content:center}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask .uploading-progress-bar{width:75%;height:6px;border-radius:3px;display:flex;background-color:#fff}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value{background-color:#338fe5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container .image-warning{position:absolute;right:5px;top:5px;color:#fff;background-color:#333;width:24px;height:24px;display:flex;align-items:center;justify-content:center;border-radius:3px;z-index:2;transition:opacity linear .2s;opacity:.7}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty{display:flex;flex-direction:column;align-items:center;outline:1px solid #DEDEDE;border-radius:3px;justify-content:center;height:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-content] .images .image-container.empty svg{width:48px;height:48px}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-tools] .drag-container{display:flex;box-sizing:content-box;pointer-events:none;position:fixed;z-index:100;background-color:#fff;border:1px solid #338FE5}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image] [data-type=block-tools] .drag-container .drag-target{width:100%}.editor-root[readonly=true] .image-splitter{visibility:hidden}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment{box-shadow:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment [data-type=block-content]{box-shadow:0 2px #f8e6ab}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment.active{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=image].comment.active [data-type=block-content]{box-shadow:none;outline:4px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block].dragging div[data-type=block-tools] .block-helper{opacity:0}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper{position:absolute;right:100%;top:0;padding-right:5px;display:flex;align-items:center}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .helper-sizer{width:0;opacity:0;pointer-events:none}div[data-type=editor-block].block-exclusive:after{content:attr(data-exclusive-tips);position:absolute;top:0px;left:0px;width:100%;background:#f8f8f8;border-radius:var(--editor-border-radius);white-space:nowrap;text-overflow:ellipsis;overflow:hidden;font-size:14px;line-height:22px;color:#909090;text-align:center;padding:9px 0;z-index:1000}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self>[data-type=block-content],.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others>[data-type=block-content]{position:relative}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others>[data-type=block-content]:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;z-index:1;background-color:#303030;opacity:.1}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.locked-by-self>[data-type=block-content]:after{pointer-events:none}.editor-root:not(.readonly) div[data-type=editor-block].locked-by-self.text-block>[data-type=block-content]:after,.editor-root:not(.readonly) div[data-type=editor-block].locked-by-others.text-block>[data-type=block-content]:after{outline:2px solid #303030}.editor-root{--selected-color: #e8e8e8}.editor-root .editor-content.dragging *{cursor:grabbing!important}.editor-root .editor-content.dragging div[data-type=editor-block] iframe{pointer-events:none}.editor-root .editor-content .editor-drop-indicator{position:absolute;background-color:var(--primary-color);pointer-events:none;transition:top .2s linear,left .2s linear,width .2s linear}.editor-root .editor-content div[data-type=editor-block].text-block.highlighted{outline:2px solid var(--background-selection);background-color:var(--background-selection)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button{width:24px;height:24px;cursor:pointer;margin:0;padding:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;border-radius:3px}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button[data-type=move]{cursor:grab}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button:hover{background-color:var(--selected-color)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .block-button svg{width:16px;height:16px;color:#909090}.drag-image-container{position:fixed;z-index:100;box-shadow:0 3px 20px #00000026;background-color:#fff;opacity:.4}.drag-image-container.drag-placeholder{width:500px;height:200px;border:1px solid #dedede;border-radius:3px;background:#e8e8e8}.drag-image-container .drag-image{width:100%;display:none}.drag-image-container[data-status=loaded] .drag-image{display:block}.drag-image-container[data-status=loaded] .drag-loading{display:none}.editor-command-bar-root .editor-command-bar .command-item.menu-item{display:flex;align-items:center;flex:none}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles{padding:5px 10px;background-color:#fff}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section+.text-style-section{margin-top:5px}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section{display:grid;grid-template-columns:repeat(7,24px);grid-row-gap:10px;grid-column-gap:5px}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon{height:24px;padding:0;margin:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;outline:none;cursor:pointer;border-radius:3px;color:#606060}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon:hover{background-color:var(--selected-color)}.editor-command-bar-root .editor-command-bar .command-item.menu-item .text-styles .text-style-section .style-icon.active{color:#338fe5}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-anchor[data-id=paste-special-button-anchor]{z-index:unset}[data-command-bar-id=paste-special-button] .editor-command-bar.toolbar{padding:0}[data-command-bar-id=paste-special-button] .editor-command-bar.toolbar .command-item[data-dropdown=true]{padding-left:5px;padding-right:5px}.editor-find-dialog{--popover-input-border: 1px solid #CFD6E1;--editor-find-dialog-input-container-border-color: #CFD6E1;--editor-find-dialog-input-container-bg-color: transparent;--editor-border-radius-big: 3px;--editor-color: #07142A;--button-black-text-color: #333;--editor-find-dialog-button-color: #333;--editor-find-dialog-icon-button-color: #333;--editor-find-dialog-button-border-bg-color: rgba(255, 255, 255, .56);--editor-find-dialog-input-placeholder-color: #b9bfc8;--editor-find-dialog-button-disabled-color: #ccc !important;--editor-find-dialog-button-hover-color: rgba(150, 150, 150, .2);--editor-find-dialog-button-border: solid 1px #ccc;box-sizing:border-box;width:400px;background-color:var(--editor-find-dialog-bg-color);border:var(--editor-find-dialog-border);border-radius:var(--editor-border-radius-big);display:flex;padding:8px 8px 0 16px;align-items:flex-start;font-size:14px;font-family:var(--editor-font-family)}.editor-find-dialog .editor-find-content{display:flex;flex-direction:column;flex-grow:1;font-family:inherit}.editor-find-dialog .editor-find-dialog-row{display:flex;margin-bottom:8px;align-items:center}.editor-find-dialog .editor-find-dialog-label{width:80px;flex-grow:0;flex-shrink:0;align-self:center}.editor-find-dialog .editor-find-dialog-input-container{border:var(--popover-input-border);border-color:var(--editor-find-dialog-input-container-border-color);background-color:var(--editor-find-dialog-input-container-bg-color);border-radius:var(--editor-border-radius-big);flex-grow:1;display:flex;padding:2px;align-items:center;height:32px;box-sizing:border-box}.editor-find-dialog .editor-find-dialog-input{border:none;flex-grow:1;width:80px;outline:none;background-color:transparent;color:var(--editor-color)}.editor-find-dialog .editor-find-dialog-input::placeholder{color:var(--editor-find-dialog-input-placeholder-color);opacity:1}.editor-find-dialog .editor-find-dialog-prev{width:24px}.editor-find-dialog .editor-find-dialog-curr{flex-grow:0;text-align:center;flex-shrink:1;display:flex;align-items:center;margin-bottom:2px}.editor-find-dialog .editor-find-dialog-next{width:24px}.editor-find-dialog .editor-find-dialog-icon-button{cursor:pointer;border-radius:4px;color:var(--editor-find-dialog-icon-button-color);background-color:var(--editor-find-dialog-button-border-bg-color);border:none;display:flex;padding:0}.editor-find-dialog .editor-find-dialog-button{padding:6px 16px;cursor:pointer;border-radius:4px;color:var(--editor-find-dialog-button-color);background-color:var(--editor-find-dialog-button-border-bg-color);margin:0 4px;border:none;font-family:inherit;line-height:21px}.editor-find-dialog .editor-find-dialog-button.icon-button{width:32px;height:32px}.editor-find-dialog .editor-find-dialog-button.active,.editor-find-dialog .editor-find-dialog-button:hover{background-color:var(--editor-find-dialog-button-hover-color)}.editor-find-dialog .editor-find-dialog-button:disabled{color:var(--editor-find-dialog-button-disabled-color);cursor:default}.editor-find-dialog .editor-find-dialog-button:disabled:hover{background-color:transparent}.editor-find-dialog .editor-find-dialog-button svg{fill:currentColor}.editor-find-dialog .editor-find-dialog-space{flex-grow:1}.editor-find-dialog .editor-find-dialog-icon-button-border{margin:0 0 0 8px;cursor:pointer;border-radius:4px;color:var(--button-black-text-color);border:var(--editor-find-dialog-button-border);background-color:var(--editor-find-dialog-button-border-bg-color);padding:0;width:32px;display:flex;justify-content:center;align-items:center}.editor-find-dialog .editor-find-dialog-button-close{margin:0 0 0 8px;cursor:pointer;border-radius:4px;color:var(--button-black-text-color);background-color:var(--editor-find-dialog-button-border-bg-color);border:none;padding:0;width:32px;height:32px;display:flex;justify-content:center;align-items:center}.editor-find-dialog .editor-find-dialog-icon-button-border svg,.editor-find-dialog .editor-find-dialog-button-close svg{fill:currentColor}.editor-find-dialog .editor-highlight{opacity:.6;pointer-events:none}.editor-find-dialog .editor-highlight .editor-highlight-child{position:absolute;background-color:bisque}.editor-find-dialog .editor-highlight.active .editor-highlight-child{position:absolute;background-color:tomato}.editor-find-dialog .editor-search-result-highlight{opacity:.6;pointer-events:none}.editor-find-dialog .editor-search-result-highlight .editor-highlight-child{position:absolute;background-color:#40e0d0}.editor-find-dialog .editor-find-dialog-status{display:flex}.editor-highlight{opacity:.6;pointer-events:none}.editor-highlight .editor-highlight-child{position:absolute;background-color:bisque}.editor-highlight.active .editor-highlight-child{position:absolute;background-color:tomato}.editor-search-result-highlight{opacity:.6;pointer-events:none}.editor-search-result-highlight .editor-highlight-child{position:absolute;background-color:#40e0d0}.editor-find-dialog-status{display:flex}.comment-editor{font-size:14px;border:1px solid #c7c7c7;border-radius:3px;padding:1px 10px;margin:6px 10px 0}.comment-editor:after{content:"";height:0;display:block;clear:both}.comment-editor-root{display:inline-block;min-width:calc(100% - 40px);padding-top:2px}.comment-editor-root div.editor-root div.editor-content{padding:0}.comment-editor-root div.editor-root div.editor-content>div[data-type=editor-container].root>div.container-blocks>*+*{margin-top:0}.comment-editor-img{float:right;color:#c1c1c1;padding:0;margin-top:2px;width:24px;height:24px;justify-content:center}.comment-editor-root:not(.comment-editor-readonly) .editor-root .editor-content [data-type=editor-block]:not([data-block-type=text]){width:248px}.comment-editor-editing{border:1px solid #338fe5}.comment-editor-readonly{border:none;padding-left:37px;margin:0}.comment-editor-readonly .comment-editor-img{display:none}.comment-item-root{position:relative;margin-top:10px}.comment-item-root:not(.last-comment-item):before{content:" ";display:block;position:absolute;left:20px;width:1px;background-color:var(--editor-border-color, #e8e8e8);overflow:hidden;opacity:.8;top:21px;bottom:-12px;transform:scaleX(.5)}.comment-item-root .item-head{padding:0 10px;position:relative;display:flex;align-items:center}.comment-item-root .item-head-avatar{margin-right:5px;width:var(--editor-comment-avatar-width, 21px);height:var(--editor-comment-avatar-width, 21px);border-radius:100%}.comment-item-root .item-head-avatar-string{display:flex;align-items:center;justify-content:center;font-size:12px;color:#fff;background-color:var(--comment-avatar-color);flex-shrink:0}.comment-item-root .item-head-username{font-size:var(--editor-comment-username-font-size, 12px);color:var(--editor-comment-username-color, #07142a);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.comment-item-root .item-head-modified{margin-left:8px;font-size:12px;color:var(--editor-comment-modified-color, #808080);flex-grow:1;white-space:nowrap}.comment-item-root .item-head-tools{display:flex;align-items:center;visibility:hidden}.comment-item-root .item-head-tools .editor-text-button svg{width:20px;height:20px}.comment-item-root .item-head-tools.active{visibility:visible}.comment-item-root .item-actions{margin-top:10px;display:flex;justify-content:flex-end;padding:0 10px}.comment-item-root .item-actions.hidden{display:none}.comment-item-root:hover:not(.comment-item-editing) .item-head-tools{visibility:visible}.comment-item-root.readonly .item-head-tools{display:none}.mobile-comment-item{margin-top:4px;background-color:var(--editor-comment-layer-bg-color);padding-bottom:20px;color:var(--editor-comment-username-color)}.mobile-comment-item .item-head{padding:12px;display:flex;align-items:center}.mobile-comment-item .item-head-avatar{width:var(--editor-comment-avatar-size);height:var(--editor-comment-avatar-size);flex-grow:0}.mobile-comment-item .item-head-username{margin-left:12px}.mobile-comment-item .item-head-modified{margin-left:12px;color:#999}.mobile-comment-item .item-editor .comment-editor-readonly{padding-left:18px}.mini-comment-item{position:relative;line-height:16px;width:20px;height:16px;text-align:center;font-size:12px;border-radius:1px;background-color:var(--editor-comment-active-color, #FFC328);color:var(--editor-comment-mini-text-color, #ffffff);cursor:pointer}.mini-comment-item:after{content:"";position:absolute;left:50%;bottom:-4px;width:6px;height:6px;background-color:var(--editor-comment-active-color, #FFC328);border-radius:1px;transform:matrix(.71,.61,.82,-.71,0,0) translate(-50%);z-index:-1}.comment-quick-reply .quick-reply-button{position:absolute;left:8px;bottom:3px;z-index:2;color:var(--editor-comment-quick-reply-color, #7084A4);font-size:12px}.comment-quick-reply .quick-reply-button.editor-text-button:hover{color:var(--text-button-color-hover, #5587F0);background-color:var(--text-button-bg-color-hover, transparent)}.comment-quick-reply .quick-reply-editor{display:none}.comment-quick-reply .quick-reply-editor .reply-editor-actions{display:flex;justify-content:flex-end;margin-top:10px;padding:0 10px}.comment-quick-reply.hidden,.comment-quick-reply.reply-editor-editing .quick-reply-button{display:none}.comment-quick-reply.reply-editor-editing .quick-reply-editor{display:block}:root{--editor-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Robot, "Helvetica Neue", Helvetica, Arial, sans-serif;--editor-comment-layer-bg-color:#ffffff;--editor-comment-group-bg-color: #ffffff;--comment-root-border-color: #eaeaea;--editor-comment-layer-active-border-color: #cecece;--editor-box-shadow: 0px 3px 20px rgba(0, 0, 0, .15);--wiz-editor-z-comment-group-active-top-before: 29;--editor-comment-quote-color: #909090;--editor-comment-quote-before-bg-color: #909090;--editor-comment-switch-button-width: 12px;--editor-comment-active-color: #FFC328;--editor-bg-color: #ffffff;--wiz-editor-z-comment-head:11;--text-button-color-hover:#5587f0;--editor-comment-username-color:#07142A;--editor-comment-avatar-size: 32px}.disabled-scroll{overflow:hidden}.editor-root .editor-content div[data-type=editor-block].text-block.comment{box-shadow:none}.editor-root .editor-content div[data-type=editor-block].text-block.comment>div[data-type=block-content]>span{border-bottom:2px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block].text-block.comment.active{box-shadow:none;outline:none}.editor-root .editor-content div[data-type=editor-block].text-block.comment.active>div[data-type=block-content] span{background-color:#f8e6ab}.editor-root .editor-content div[data-type=editor-block] span.text.comment{border-bottom:2px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block] span.text.comment.active{background-color:#faf1d1}.editor-root .editor-content div[data-type=editor-block].comment{box-shadow:0 2px #f8e6ab}.editor-root .editor-content div[data-type=editor-block].comment.active{box-shadow:none;outline:4px solid #f8e6ab}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-comment-button{all:unset;position:absolute;right:-28px;top:0;width:24px;height:24px;display:flex;align-items:center;justify-content:center;padding:0;border-radius:3px;color:#07142a;cursor:pointer}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-comment-button:hover{background:#eaeaea}.editor-web-comment-root{position:absolute;right:0;width:300px;top:0;bottom:0;transition:width .16s ease-in;will-change:width;font-family:var(--editor-font-family)}.editor-web-comment-root .comment-groups-container .comment-group-item-root{position:absolute;left:50%;right:0;width:290px;transform:translate(-50%);background-color:var(--editor-comment-group-bg-color);border-radius:2px;border-color:var(--editor-comment-layer-active-border-color);box-shadow:var(--editor-box-shadow);padding-bottom:18px}.editor-web-comment-root .comment-groups-container .comment-group-item-root:not(.no-animation){transition:top .2s ease-in,opacity .35s ease-in}.editor-web-comment-root .comment-groups-container .comment-group-item-root:before{content:"";position:absolute;left:0;right:0;height:6px;background-color:#fff;border-radius:2px 2px 0 0;z-index:var(--wiz-editor-z-comment-group-active-top-before)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head{display:flex;align-items:center}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-quote{box-sizing:content-box;font-size:12px;line-height:12px;height:12px;color:var(--editor-comment-quote-color);padding:18px 12px 10px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;width:100%;max-width:calc(100% - 80px)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-quote:before{content:"";display:block;width:2px;height:100%;background-color:var(--editor-comment-quote-before-bg-color);margin-right:6px;float:left;border-radius:10px}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch{display:flex;align-items:center;height:22px;padding-top:6px;visibility:hidden}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button{padding:0;width:var(--editor-comment-switch-button-width);margin:3px 0;color:#606060}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button[data-button-id=switch-up]{margin-right:16px}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button:not(.disabled):hover{color:var(--text-button-color-hover)}.editor-web-comment-root .comment-groups-container .comment-group-item-root .comment-item-head .item-head-switch .editor-text-button.disabled{color:#60606080;cursor:not-allowed}.editor-web-comment-root .comment-groups-container .comment-group-item-root.active:before{background-color:var(--editor-comment-active-color)}.editor-web-comment-root .comment-groups-container .comment-group-item-root.active .item-head-switch{visibility:visible}.editor-web-comment-root .comment-groups-container .comment-group-item-root.readonly .comment-quick-reply{display:none}.editor-mobile-comments-root{position:fixed;left:0;right:0;bottom:0;top:0;overflow:hidden;z-index:11}.editor-mobile-comments-root .mobile-comment-mask{position:absolute;left:0;right:0;bottom:0;top:0;background-color:#00000073}.editor-mobile-comments-root .mobile-comment-groups-container{position:absolute;width:100%;height:100vh;z-index:1;overflow:hidden}.editor-mobile-comments-root .mobile-comment-groups-container .mobile-comment-groups-scroll-container{padding:0 12px}.editor-mobile-comments-root .mobile-comment-pull-info-container{position:absolute;right:0;left:0;bottom:100px;z-index:2;text-align:center;display:none}.editor-mobile-comments-root .mobile-comment-pull-info-container .mobile-comment-pull-info{display:inline-block;padding:12px;border-radius:36px;margin:0 auto;background-color:#000c;color:#fff;font-size:12px;opacity:0;transition:opacity .25s cubic-bezier(.65,.05,.36,1)}.editor-mobile-comments-root .mobile-comment-pull-info-container.active{display:block}.editor-mobile-comments-root .mobile-comment-pull-info-container.active .mobile-comment-pull-info{opacity:1}.editor-mobile-comments-root .mobile-group-item-root{margin:0 auto;width:100%;height:100vh;overflow:hidden}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item{min-height:calc(100vh + 1px);padding-bottom:50px}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item-space{height:50vh}.editor-mobile-comments-root .mobile-group-item-root .mobile-group-item-abstract{background-color:var(--editor-comment-layer-bg-color);padding:12px;color:#999;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.editor-mini-comment-root{position:absolute;right:0;top:0;bottom:0;width:48px;border-left:1px solid #f0f0f0;transition:width .16s ease-in;will-change:width;font-family:var(--editor-font-family);border:none;background-color:transparent;z-index:11}.editor-mini-comment-root .comment-groups-container{width:100%;height:100%}.editor-mini-comment-root .comment-groups-container .mini-group-item{position:absolute;top:0;left:50%;margin-left:-10px;transition:top .2s cubic-bezier(.65,.05,.36,1)}:is(.editor-web-comment-root,.editor-mobile-comments-root,.editor-mini-comment-root).hidden{display:none}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content]{margin:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content] span.file-icon{display:inline-flex;vertical-align:text-bottom}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=file] span[data-type=box-content] .file-name{color:var(--primary-color);padding:0;border-radius:12px;margin-right:4px;white-space:wrap;word-break:break-all;cursor:pointer}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office]{justify-content:start}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office].hover [data-type=block-content]{border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content]{max-width:360px;min-width:360px;height:48px;cursor:pointer}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root{display:flex;align-items:center;min-width:360px;max-width:100%;background-color:#f5f6f7;border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root:before{border-radius:3px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details{display:flex;flex-direction:column;justify-content:center;font-size:14px;flex-grow:1}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-name{color:#1f2329;max-width:185px;display:flex;flex-direction:row;align-items:center;white-space:nowrap}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-size{color:#646a73;font-size:12px;margin-top:2px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-details .file-name-pre{text-overflow:ellipsis;overflow:hidden}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-actions button{width:34px;height:34px;background-color:#fff;border:1px solid #dee0e3;border-radius:50%;margin:0 8px;padding:0;background-repeat:no-repeat;background-position:50%;cursor:pointer;display:flex;align-items:center;justify-content:center;flex-shrink:0}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-actions button svg{width:16px;height:16px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-icon{display:flex;width:36px;height:36px;margin:6px 6px 6px 12px}div.editor-root div.editor-content div[data-type=editor-container] div.embed-block[data-type=editor-block][data-embed-type=office] [data-type=block-content] .card-root .file-icon>svg{width:100%;height:100%}:root{--editor-version-button-border: black;--editor-bg-color: #ffffff;--editor-version-list-bg-color: white;--editor-version-select-bg-color: #F5F9FD}.version-dialog{display:flex;background-color:var(--editor-bg-color);width:100%;height:100%;color:var(--editor-color)}.version-dialog *{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;box-sizing:border-box}.version-dialog .version-item-latest{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;border-radius:3px;display:inline-flex;align-items:center;font-size:12px;font-weight:400;margin-left:10px}.version-dialog .version-viewer{flex:1;display:flex;flex-direction:column;width:0;padding:0}.version-dialog .version-viewer .version-dialog-editor{flex-grow:1;overflow-y:auto}.version-dialog .version-viewer .version-info-container{height:50px;border-bottom:#E8E8E8 1px solid;display:flex;align-items:center;flex-shrink:0;padding-left:20px;font-size:14px;color:#303030}.version-dialog .version-viewer .version-info-container .version-info-right .text-3{color:#909090}.version-dialog .version-viewer .version-info-container .version-info-left{display:flex;align-items:center}.version-dialog .version-viewer .version-info-container .version-info-left .text-1,.version-dialog .version-viewer .version-info-container .version-info-left .text-2{color:#909090}.version-dialog .version-viewer .version-info-container .version-info-left .name{padding-left:5px;padding-right:10px;font-weight:500}.version-dialog .version-viewer .version-info-container .version-info-left .name .version-item-latest{margin-left:5px}.version-dialog .version-viewer .version-info-container .editor-dropdown{margin-left:10px;margin-right:10px}.version-dialog .version-viewer .version-info-container .command-item[data-id=current-version]{min-width:200px;border:1px solid #f0f0f0}.version-dialog .version-viewer .version-info-container .command-item[data-id=current-version] .toolbar-item-name-container{flex-grow:1}.version-dialog .version-viewer .dialog-button-text{margin-top:1px;margin-left:-4px}.version-dialog .version-viewer .dialog-text-button{outline:none;background:transparent;border:none;display:flex;align-items:center;color:var(--editor-color);font-size:16px;font-weight:500;padding:4px 0;cursor:pointer}.version-dialog .version-viewer .dialog-text-button .dialog-button-icon{margin-right:0;width:24px;height:24px}.version-dialog .version-viewer .dialog-text-button .dialog-button-icon svg{fill:currentColor}.editor-root.history .root-container .editor-block .text-element .inline-plugin.editor-box-loading{display:none}.editor-root.history .editor-content{padding:30px 75px}.editor-root.history .history-inserted-block[data-type=editor-block] [data-type=block-content]{border:4px solid var(--op-selected-color)}.editor-root.history .history-inserted-block[data-type=editor-block]{position:relative}.editor-root.history .history-inserted-block[data-type=editor-block]:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-inserted-block[data-type=editor-block].table-block table{border:4px solid var(--op-selected-color)}.editor-root.history .history-inserted-block[data-type=editor-block].table-block table .child{pointer-events:none}.editor-root.history .history-inserted-block[data-type=editor-block].table-block{position:relative}.editor-root.history .history-inserted-block[data-type=editor-block].table-block:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-inserted-block[data-type=editor-block].table-block:hover:after{top:0}.editor-root.history .history-deleted-block [data-type=block-content]{border:4px solid var(--op-selected-color)}.editor-root.history .history-deleted-block [data-type=block-content]{position:relative}.editor-root.history .history-deleted-block [data-type=block-content]:after,.editor-root.history .history-deleted-block [data-type=block-content]:before{content:" ";position:absolute;display:flex;z-index:var(--wiz-editor-z-history-delete-marker);color:var(--op-color);justify-items:center;align-items:center;justify-content:center;align-content:center;pointer-events:none;overflow:visible;max-width:100%;max-height:100%;left:calc(50% - 16px);top:calc(50% - 2px);width:32px;height:4px;background-color:var(--op-color);transform:rotate(45deg);opacity:1}.editor-root.history .history-deleted-block [data-type=block-content]:before{transform:rotate(135deg)}.editor-root.history .history-deleted-block{position:relative}.editor-root.history .history-deleted-block:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-deleted-block .history-deleted-box{background-color:unset!important;text-decoration:unset!important}.editor-root.history .history-deleted-block .history-deleted-box:hover:after{opacity:0}.editor-root.history .history-inserted-text{line-height:revert!important;background-color:var(--op-selected-color)}.editor-root.history .history-inserted-text{position:relative}.editor-root.history .history-inserted-text:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history .history-deleted-box{background-color:var(--op-selected-color);text-decoration:line-through}.editor-root.history .history-deleted-box{position:relative}.editor-root.history .history-deleted-box:hover:after{content:attr(data-op-description);position:absolute;top:-26px;left:0;line-height:24px;background-color:var(--op-color);min-width:20px;opacity:1;color:#fff;padding:0 8px;z-index:var(--wiz-editor-z-history-op-description, 10);font-size:14px;font-weight:400;white-space:nowrap;border-radius:3px}.editor-root.history [data-box-type=history-deleted-box]>span[data-type=box-content]{border:none!important;margin:0!important}.editor-root.history [data-type=editor-block].table-block div[data-type=block-content]{overflow-x:revert}.editor-dialog-root{position:absolute;left:0;top:0;bottom:0;right:0;background-color:#639;z-index:100}.size-limit-textarea{display:inline-block;position:relative}.size-limit-textarea .size-limit-textarea-input{width:100%;resize:none;overflow:hidden;color:#303030;outline:none;border:1px solid #f0f0f0;border-radius:3px}.size-limit-textarea .size-limit-textarea-input:focus,.size-limit-textarea .size-limit-textarea-input:hover{border-color:#338fe5}.size-limit-textarea .size-limit-textarea-input:focus{box-shadow:0 0 0 2px #338fe533}.size-limit-textarea .size-limit-textarea-warning{position:absolute;right:0;bottom:10px;color:#909090;z-index:1;font-size:12px;pointer-events:none}.version-list-root{width:350px;background:var(--editor-version-list-bg-color);overflow-y:auto;padding:0;border-left:#E8E8E8 1px solid;display:flex;flex-direction:column}.version-list-root .version-list-header{padding:0 6px 0 20px;font-size:14px;display:flex;align-items:center;margin-top:8px;margin-bottom:8px;flex-shrink:0;color:#909090}.version-list-root .version-list-header .version-count{flex-grow:1}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item{cursor:pointer}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item:not(.disabled):hover{color:#338fe5}.version-list-root .version-list-header .version-list-filter .editor-command-bar.toolbar .command-item.selected:not(.disabled){background-color:transparent}.version-list-root .version-list-empty{height:100%;display:flex;align-items:center;justify-content:center;font-size:14px;color:#909090}.version-list-root .version-list-content{flex-grow:1;overflow-y:auto}.version-list-root .version-list-content .version-item{padding:15px 10px;cursor:pointer}.version-list-root .version-list-content .version-item:not(:last-child):after{content:"";display:block;position:relative;top:15px;border-bottom:1px solid #E8E8E8}.version-list-root .version-list-content .version-item:not(:last-child):hover:after,.version-list-root .version-list-content .version-item:not(:last-child).active:after{left:-10px;width:106%}.version-list-root .version-list-content .version-item.child{padding-left:32px}.version-list-root .version-list-content .version-item:not(.active):hover{background:#F8F8F8}.version-list-root .version-list-content .version-item.active{background-color:var(--editor-version-select-bg-color)}.version-list-root .version-list-content .version-item.active .version-item-title .version-actions{display:flex}.version-list-root .version-list-content .version-item.active .version-item-title .version-item-date{color:#338fe5}.version-list-root .version-list-content .version-item.editing .version-item-memo{display:none}.version-list-root .version-list-content .version-item.active .version-item-memo{cursor:text}.version-list-root .version-list-content .version-item.active .version-item-memo:hover{outline:1px solid #338FE5}.version-list-root .version-list-content .version-item .version-item-restore-from{color:#909090;font-size:12px;line-height:1.5em;height:20px;padding:0 10px 10px}.version-list-root .version-list-content .version-item .version-item-restore-from:empty{display:none}.version-list-root .version-list-content .version-item .memo-input.size-limit-textarea{width:100%;min-height:60px;display:flex}.version-list-root .version-list-content .version-item .memo-input.size-limit-textarea textarea{padding:4px 10px;box-sizing:border-box;font-size:14px}.version-list-root .version-list-content .version-item .version-item-title{display:flex;align-items:center;padding-left:10px;padding-right:10px;height:24px}.version-list-root .version-list-content .version-item .version-item-title .version-item-date{font-size:14px;font-weight:500;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;color:#303030}.version-list-root .version-list-content .version-item .version-item-title .spacer{flex-grow:1}.version-list-root .version-list-content .version-item .version-item-title .version-actions{display:none}.version-list-root .version-list-content .version-item .version-item-title .version-actions button{display:flex;align-items:center;justify-content:center;height:16px;cursor:pointer;border:none;outline:none;background:transparent;padding:0 0 0 10px;color:#909090}.version-list-root .version-list-content .version-item .version-item-title .version-actions button:hover{color:#338fe5}.version-list-root .version-list-content .version-item .version-item-title .version-actions button.disabled,.version-list-root .version-list-content .version-item .version-item-title .version-actions button.disabled:hover{color:#c7c7c7}.version-list-root .version-list-content .version-item .version-item-title .version-actions .revert-button{border-left:1px solid #E8E8E8;margin-left:10px}.version-list-root .version-list-content .version-item .version-item-authors{list-style:none;margin:0;font-size:12px;padding-left:10px}.version-list-root .version-list-content .version-item .version-item-author{display:flex;align-items:center;margin-top:10px;color:#606060}.version-list-root .version-list-content .version-item .version-item-author-mark{width:6px;height:6px;border-radius:3px;margin-right:5px}.version-list-root .version-list-content .version-item .version-item-memo{font-size:14px;color:#303030;padding:5px 10px;border-radius:3px}.version-list-root .version-list-content .version-item .version-item-memo:empty{display:none}.versions-dropdown-header{color:var(--text-color);padding:10px;border-bottom:1px solid #f0f0f0}.versions-dropdown-header .versions-dropdown-header-info{color:#909090}.versions-dropdown-header .versions-dropdown-header-icon{display:inline-flex;vertical-align:middle;height:19px;padding-left:5px;padding-right:5px;cursor:pointer;color:#909090}.versions-dropdown-header .versions-dropdown-header-icon svg{vertical-align:baseline}.editor-command-bar.menu .command-item.standard[data-id=prev-version]{height:44px}[data-command-bar-id=versions-dropdown-popup]{width:320px}[data-command-bar-id=versions-dropdown-popup] .tippy-box{color:var(--text-color)}[data-command-bar-id=versions-dropdown-popup] .tippy-box .version-item-empty{width:100%}[data-command-bar-id=versions-dropdown-popup] .tippy-box .version-item-name{color:var(--text-color)}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar.menu .command-item.standard.disabled{color:#909090}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar{--text-color: #303030}[data-command-bar-id=versions-dropdown-popup] .tippy-box .editor-command-bar.menu .command-item.section{padding:0;font-size:inherit;color:inherit}[data-command-bar-id=versions-dropdown-popup] *{box-sizing:border-box}[data-command-bar-id=versions-dropdown-popup] .editor-command-bar-header{width:100%;margin-bottom:5px}[data-command-bar-id=versions-dropdown-popup] .command-item{width:100%;cursor:pointer}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container{padding:6px 10px;width:100%}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-memo{font-size:12px;color:#909090;line-height:20px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-line1{line-height:22px;display:flex;align-items:center;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-container .version-item-line1 .version-item-latest{color:#338fe5;background-color:#eaf3fc;height:20px;padding:0 5px;margin-left:10px;border-radius:3px;font-size:12px;display:inline-flex;align-items:center}[data-command-bar-id=versions-dropdown-popup] .command-item .version-item-empty{display:flex;height:34px;color:#909090;padding-left:10px;justify-content:left;align-items:center}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item{width:100%}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-info{height:24px;color:#909090;display:flex;align-items:center;padding-left:10px;background-color:#f8f8f8;width:100%;box-sizing:border-box;margin:5px 0}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container{height:34px;display:flex;align-items:center;padding-left:10px;color:#303030}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container .filter-item-input{position:relative;top:-1px;left:-2px;cursor:pointer;accent-color:#338FE5}[data-command-bar-id=versions-dropdown-popup] .command-item .filter-memoed-version-item .filter-item-input-container .filter-item-label{user-select:none;cursor:pointer;line-height:1em}.editor-root.readonly .editor-content div[data-type=editor-block].focused div[data-type=block-tools] .block-helper .heading-marker,.editor-root.readonly .editor-content div[data-type=editor-block].highlighted div[data-type=block-tools] .block-helper .heading-marker{display:flex}.editor-root .editor-content div[data-type=editor-block].heading-collapsed div[data-type=block-tools] .block-helper .heading-collapse-button svg{transform:rotate(270deg)}.editor-root .editor-content div[data-type=editor-block].focused div[data-type=block-tools] .block-helper .heading-marker,.editor-root .editor-content div[data-type=editor-block].highlighted div[data-type=block-tools] .block-helper .heading-marker{display:none}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button{width:24px;height:24px;cursor:grab;margin:0;padding:0;display:flex;align-items:center;justify-content:center;background-color:transparent;border:none;border-radius:3px;box-sizing:content-box}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker:hover,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button:hover{background-color:var(--selected-color)}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker svg,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button svg{transform:rotate(360deg);transition:transform .2s linear}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker svg,.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-collapse-button svg{width:16px;height:16px}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker{color:#c7c7c7}.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-helper .heading-marker:hover{background-color:transparent}.embed-block div[data-type=block-content] .editor-toc-container{display:block;width:100%;background-color:#f0f0f0;padding:20px;text-align:start}.embed-block div[data-type=block-content] .editor-toc-container.loading{margin:0;min-height:100px}.embed-block div[data-type=block-content] .editor-toc-container .toc-node+.toc-node{margin-top:10px}.embed-block div[data-type=block-content] .editor-toc-container .toc-node .toc-text{cursor:pointer;color:var(--primary-color)}.embed-block div[data-type=block-content] .editor-toc-container .toc-node .toc-children{margin-top:10px;padding-left:20px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=mention] span[data-type=box-content]{margin:0}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block] div[data-type=block-content] [data-box-type=mention] span[data-type=box-content] .mention-name{color:var(--primary-color);padding:0;border-radius:12px;margin-left:4px;margin-right:4px;white-space:wrap;word-break:break-all;cursor:pointer}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon{width:20px;height:20px;border-radius:50%;overflow:hidden}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon img{width:100%;height:100%}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-icon .mention-user-avatar-string{align-items:center;display:flex;justify-content:center;overflow:hidden;height:100%;width:100%;font-size:12px;color:#fff;flex-shrink:0}[data-command-bar-id=editor-mention] .editor-command-bar.menu .command-item.menu-item .menu-item-name{flex-grow:0;margin-right:5px}.editor-root .editor-templates{position:fixed;bottom:26px;height:256px;width:auto;max-width:100%;padding-left:30px;padding-right:44px;overflow:hidden}.editor-root .editor-templates .editor-templates-title{color:#909090;font-size:14px;margin-left:0;margin-bottom:20px;line-height:19.6px}.editor-root .editor-templates .editor-templates-cards{display:flex;margin-left:0}.editor-root .editor-templates .editor-templates-cards .editor-template-card{box-sizing:border-box;display:flex;flex-direction:column;justify-content:center;cursor:pointer;flex-shrink:0;height:192px;width:188px;background:none;border:1px solid #e8e8e8;border-radius:3px;margin:0 0 0 15px;padding:0;align-items:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card:first-child{margin-left:0}.editor-root .editor-templates .editor-templates-cards .editor-template-card:hover{box-shadow:0 0 1px #30303033,0 8px 16px #30303026}.editor-root .editor-templates .editor-templates-cards .editor-template-card:hover>.editor-template-name{color:#338fe5}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-name{display:flex;align-items:center;height:40px;width:100%;border-top:1px solid #dedede;padding-left:20px;padding-right:20px;flex:0 0 50px;font-size:14px;font-weight:500;line-height:22px;color:#303030}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-name span{display:block;width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-name{border-top:none}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-name span{padding-left:0;text-align:center}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-thumb-container{display:flex;align-items:center;justify-content:center;padding:16px 39px 14px}.editor-root .editor-templates .editor-templates-cards .editor-template-card.more .editor-template-thumb-container>img{width:110px;height:112px;max-width:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-thumb-container{flex:1;position:relative;padding:10px 5px 0;height:142px;margin:0;overflow:revert}.editor-root .editor-templates .editor-templates-cards .editor-template-card .editor-template-thumb-container>img{max-width:100%}:root div[data-command-bar-id=webpage]>div.tippy-box{max-width:500px}:root div[data-command-bar-id=webpage]>div.tippy-box div.tippy-content{width:500px;padding:0}.editor-dialog-container{width:500px}.editor-dialog-container .dialog-header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;padding:0 20px;height:50px;border-bottom:1px solid #e8e8e8;margin-bottom:20px}.editor-dialog-container .dialog-header .close-icon{display:flex;cursor:pointer}.editor-dialog-container .dialog-header .dialog-header-title{padding:8px 0 11px;font-size:18px;font-weight:700;flex-grow:1}.editor-dialog-container .dialog-content{padding:0 20px 20px;border-bottom:1px solid #e8e8e8}.editor-dialog-container .dialog-footer{margin:10px 0;padding:0 20px;text-align:right}.editor-dialog-container .dialog-footer button{min-height:30px;border-radius:3px;font-size:14px}.editor-disable-scroll.editor-disable-scroll-dark{background-color:#00000080}.embed-block[data-embed-type=webpage]{height:400px;min-height:100px;max-height:1000px}.embed-block[data-embed-type=webpage] .webpage-mask{position:absolute;left:0;right:0;top:0;bottom:0;z-index:1;background-color:transparent}.embed-block[data-embed-type=webpage].resizing [data-type=block-tools] .block-resizer{pointer-events:all!important}.embed-block[data-embed-type=webpage].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=webpage].selected>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=webpage]>div[data-type=block-content]{justify-content:center;height:100%}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed{width:100%}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed .editor-preview-iframe{width:100%;max-height:500px;height:100%;border:none;position:relative}.embed-block[data-embed-type=webpage]>div[data-type=block-content]>.editor-embed .editor-preview-iframe-loading{position:absolute;top:0;left:0;bottom:0;right:0;display:flex;justify-content:center;align-items:center;background-color:#fff}.webpage-content .help-container{color:#303030;border:1px solid #dedede;padding:10px;border-radius:4px;border-left:4px solid #338fe5;margin-top:16px;margin-bottom:16px}.webpage-content .help-container .help-content{display:flex;align-items:center}.webpage-content .help-container .help-content .help-icon{display:flex;align-items:center;height:20px;color:#338fe5;margin-right:12px}.webpage-content .help-link-container{margin-top:8px;display:flex;align-items:center}.webpage-content .help-link-container .help-link-content{display:flex;align-items:center;color:#338fe5;text-decoration:none}.webpage-content .help-link-container .help-link-content .help-link-icon{width:16px;height:16px;margin-left:8px}div.editor-root div.editor-content div[data-type=editor-container].root.select-all>.container-blocks>div[data-type=editor-block][data-embed-type=webpage]>div[data-type=block-content]:before{display:block}:root{--editor-quoted-color: #7084a4;--editor-drawio-empty-svg: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDgiIGhlaWdodD0iNDgiIHZpZXdCb3g9IjAgMCA0OCA0OCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZmlsbC1ydWxlPSJldmVub2RkIiBjbGlwLXJ1bGU9ImV2ZW5vZGQiIGQ9Ik0zOC43MjAzIDI4LjcwOTdIMjUuOTIzM0MyNS4yMTY1IDI4LjcwOTcgMjQuNjQzNSAyOC4xNDgxIDI0LjY0MzUgMjcuNDU1MlYyNS43MzMzSDIwLjUyODNDMjAuNDk4NiAyNS43Njk2IDIwLjQ2NjkgMjUuODA0MiAyMC40MzMzIDI1LjgzN0wxNS45MTkyIDMwLjI2MjFWMzQuNzU1NkgyNC42NDM1VjMzLjcyNzZDMjQuNjQzNSAzMy4wMzQ4IDI1LjIxNjUgMzIuNDczMiAyNS45MjMzIDMyLjQ3MzJIMzguNzIwM0MzOS40MjcgMzIuNDczMiA0MCAzMy4wMzQ4IDQwIDMzLjcyNzZWMzguNzQ1NUM0MCAzOS40MzgzIDM5LjQyNyA0MCAzOC43MjAzIDQwSDI1LjkyMzNDMjUuMjE2NSA0MCAyNC42NDM1IDM5LjQzODMgMjQuNjQzNSAzOC43NDU1VjM3LjMzMzNIMTQuNjI2M0MxMy45MTIyIDM3LjMzMzMgMTMuMzMzMyAzNi43NTYyIDEzLjMzMzMgMzYuMDQ0NFYzMC42OTQxTDguMzc4NTIgMjUuODM3QzguMTM2MjYgMjUuNjAxNCA4IDI1LjI4MDggOCAyNC45NDYzQzggMjQuNjExOCA4LjEzNjI2IDI0LjI5MTEgOC4zNzg1MiAyNC4wNTU2TDEzLjMzMzMgMTkuMTk4NVYxNS43NzJDMTEuNzc5OCAxNS4yMjI5IDEwLjY2NjcgMTMuNzQxNiAxMC42NjY3IDEyQzEwLjY2NjcgOS43OTA4NSAxMi40NTc1IDggMTQuNjY2NyA4QzE2Ljg3NTggOCAxOC42NjY2IDkuNzkwODUgMTguNjY2NiAxMkMxOC42NjY2IDEzLjcyNjUgMTcuNTU4OCAxNS4yNTgxIDE1LjkxOTEgMTUuNzk4OFYxOS4yODg4QzE1LjkxOTEgMTkuMzkxOCAxNS45MDY4IDE5LjQ5NDMgMTUuODgyMyAxOS41OTQzTDE5LjUxNTEgMjMuMTU1NUgyNC42NDM1VjIyLjQzNzNDMjQuNjQzNSAyMS43NDQ1IDI1LjIxNjUgMjEuMTgyOSAyNS45MjMzIDIxLjE4MjlIMzguNzIwM0MzOS40MjcgMjEuMTgyOSA0MCAyMS43NDQ1IDQwIDIyLjQzNzNWMjcuNDU1MkM0MCAyOC4xNDgxIDM5LjQyNyAyOC43MDk3IDM4LjcyMDMgMjguNzA5N1pNMjcuMjAzIDM3LjQ5MUgzNy40NDA2VjM0Ljk4MjFIMjcuMjAzVjM3LjQ5MVpNMTQuNDA1OSAyOC4xOTU0TDExLjA5MTUgMjQuOTQ2M0wxNC40MDU5IDIxLjY5NzJMMTcuNzIwNCAyNC45NDYzTDE0LjQwNTkgMjguMTk1NFpNMjcuMjAzIDI2LjIwMDhIMzcuNDQwNlYyMy42OTE4SDI3LjIwM1YyNi4yMDA4WiIgZmlsbD0iIzA3MTQyQSIvPgo8L3N2Zz4K)}.flex-center,.editor-drawio-iframe-container.loading:before{display:flex;align-items:center;justify-content:center}.full-screen,.editor-drawio-iframe-container.loading:before,.drawio-iframe-element,.editor-drawio-iframe-container{width:100%;height:100%}.editor-drawio-iframe-container{position:fixed;top:0;left:0;z-index:1000}div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content]{outline:1px solid #dedede}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio].drawio-load-error>div[data-type=block-content]{padding:0;min-height:200px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio].drawio-load-error>div[data-type=block-content] .editor-drawio-content{width:100%;height:100%}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content]{justify-content:center;border-radius:3px;padding:10px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content{display:flex;flex-direction:column;align-items:center;justify-content:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content{width:100%;height:100%;background-color:#f8f8f8;display:flex;flex-direction:column;justify-content:center;text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-brand-icon>svg{width:48px;height:48px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-title{font-weight:500;font-size:18px;line-height:26px;text-align:center;color:#303030;margin:23px 0 5px}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-sub-title{font-size:14px;line-height:22px;text-align:center;color:#606060}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .editor-drawio-content>div.drawio-error-content>div.drawio-error-sub-title>span.drawio-error-retry-button{cursor:pointer;margin-left:4px;color:#338fe5}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .drawio-empty-content{display:flex;flex-direction:column;align-items:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-type=editor-block].embed-block[data-embed-type=drawio]>div[data-type=block-content] .drawio-empty-content>span{font-size:14px;line-height:22px;text-align:center;color:#606060;margin-top:23px}.embed-block .editor-empty-drawio.editor-drawio-content.editor-embed{width:240px;height:80px;display:inline-block;text-align:center}div.editor-root div.editor-content div[data-type=editor-container] div[data-embed-type=drawio].embed-block>div[data-type=block-content] img{max-width:100%;max-height:100%}.editor-drawio-iframe-container.loading:before{content:attr(data-placeholder);position:absolute;top:0;left:0;background-color:#f7f6f3;z-index:2}.editor-content .editing{background-color:#cdcdcd40}.editor-content div[data-type=block-tools] .embed-code-editor-container{position:absolute;top:0;left:0px;right:0px;bottom:0;background-color:#cdcdcd40;z-index:var(--wiz-editor-z-embed-code-editor-mask);padding:8px}.editor-content div[data-type=block-tools] .embed-code-editor-container textarea{width:100%;height:100%;resize:none;outline:none;padding:12px;border:1px solid #b9bfc8;border-radius:4px;background-color:#fff;color:#333}.flex-row-center,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=mermaid],.embed-block[data-embed-type=flowchart],.embed-block[data-embed-type=plantuml]{display:flex;flex-direction:row;align-items:center;justify-content:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content],.embed-block[data-embed-type=flowchart] div[data-type=block-content],.embed-block[data-embed-type=plantuml] div[data-type=block-content]{width:100%;position:relative;border:1px solid #e5e5e5;border-radius:3px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed{width:100%;min-height:106px;background-color:#cdcdcd40}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .empty-embed:after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .empty-embed:after{content:attr(data-empty-tips);position:absolute;top:0;right:0;width:100%;height:100%;color:#07142a;white-space:nowrap}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed),.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed){width:100%;height:100px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed) img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed) img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed) img{display:none}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .invalid-code:not(.empty-embed):after,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .invalid-code:not(.empty-embed):after,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .invalid-code:not(.empty-embed):after{content:attr(data-invalid-text);position:absolute;top:0;right:0;width:100%;height:100%;outline:1px solid red;display:flex;flex-direction:row;align-items:center;justify-content:center;color:red}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-img-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-img-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-img-content{width:100%;text-align:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .mermaid-embed-img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .mermaid-embed-img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .mermaid-embed-img{max-width:100%;min-width:200px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .editor-plantuml-img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .editor-plantuml-img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .editor-plantuml-img{max-width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-graph-img-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-graph-img-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-graph-img-content{width:100%;text-align:center;padding:10px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .embed-graph-img-content img,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .embed-graph-img-content img,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .embed-graph-img-content img{max-width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed{width:100%}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content{width:100%;height:100%;min-height:200px;background-color:#f8f8f8;display:flex;flex-direction:column;justify-content:center;text-align:center}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-brand-icon>svg{width:48px;height:48px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-title{font-weight:500;font-size:18px;line-height:26px;text-align:center;color:#303030;margin:23px 0 5px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title{font-size:14px;line-height:22px;text-align:center;color:#606060}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-error-content>div.graph-error-sub-title>span.graph-error-retry-button,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-error-sub-title>span.graph-error-retry-button{cursor:pointer;margin-left:4px;color:#338fe5}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content{background-color:#fff}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-brand-icon>svg{width:48px;height:48px}.embed-block[data-embed-type=mermaid] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title,.embed-block[data-embed-type=flowchart] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title,.embed-block[data-embed-type=plantuml] div[data-type=block-content] .graph-embed>div.graph-empty-content>div.graph-empty-title{font-weight:400;font-size:14px;line-height:22px;text-align:center;color:#606060;margin-top:23px}.hr-transition,.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container .editor-embed-hr{transition:border-top ease-in-out .4s}.embed-block[data-type=editor-block][data-embed-type=hr].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-type=editor-block][data-embed-type=hr].selected>div[data-type=block-content]{outline:none!important}.embed-block[data-type=editor-block][data-embed-type=hr]:is(.focused) div[data-type=block-content] .editor-embed-container .editor-embed-hr{caret-color:transparent}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container{display:flex;align-items:center;width:100%;height:24px;cursor:pointer}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-content] .editor-embed-container .editor-embed-hr{display:block;width:100%;border:none;margin:0;border-top:2px dashed #cccccc}.embed-block[data-type=editor-block][data-embed-type=hr] div[data-type=block-tools]>div.block-helper{height:100%}:root{--hover-color: #40a9ff}.flex-column-center,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{display:flex;justify-content:center;align-items:center;flex-flow:column}.common{width:400px;height:180px;background-color:#fafafa;border:1px dashed #d9d9d9;border-radius:2px;transition:border-color .3s}.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{height:200px}.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty .media-error-icon,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .media-error-icon{display:flex}.editor-root .editor-content div[data-type=editor-block].embed-block.media-block-uploading div[data-type=block-tools] .block-helper{display:none}.embed-block[data-embed-type=video]{display:flex}.embed-block[data-embed-type=video][data-style-align=left]>div[data-type=block-content]{justify-content:flex-start}.embed-block[data-embed-type=video][data-style-align=center]>div[data-type=block-content]{justify-content:center}.embed-block[data-embed-type=video][data-style-align=right]>div[data-type=block-content]{justify-content:flex-end}.embed-block[data-embed-type=video]>div[data-type=block-content]{border:none}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error{height:400px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty .media-error-icon,.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .media-error-icon{display:flex}.embed-block[data-embed-type=video].hover>div[data-type=block-content],.embed-block[data-embed-type=audio].hover>div[data-type=block-content]{outline:none!important}.embed-block[data-embed-type=video].selected>div[data-type=block-content]:before,.embed-block[data-embed-type=audio].selected>div[data-type=block-content]:before{display:none}.embed-block[data-embed-type=video]>div[data-type=block-content],.embed-block[data-embed-type=audio]>div[data-type=block-content]{justify-content:center;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media.full-screen,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media.full-screen{width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media{display:flex;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress{position:relative;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress audio,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress audio{display:block;width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress video,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress video{display:block;max-width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask{position:absolute;top:0;left:0;right:0;bottom:0;background-color:#303030;opacity:.8;display:flex;align-items:center;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar{width:75%;height:6px;border-radius:3px;display:flex;background-color:#fff;overflow:hidden}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-progress .uploading-progress-mask .uploading-progress-bar .uploading-progress-bar-value{background-color:#338fe5}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error{width:100%;background:#F8F8F8;outline:1px solid #DEDEDE;border-radius:3px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error-icon svg,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error-icon svg{width:48px;height:48px;color:#c7c7c7}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .line-1,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .line-1{margin-top:10px;font-size:18px;text-align:center;color:#303030}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .line-2,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .line-2{margin-top:5px;font-size:14px;text-align:center;color:#606060}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-error .retry-upload,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-error .retry-upload{margin-left:4px;color:#338fe5;cursor:pointer;text-decoration:none}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty{width:100%;background:#FFFFFF;outline:1px solid #DEDEDE;border-radius:3px}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-empty svg,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-empty svg{width:48px;height:48px;color:#c7c7c7}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element{width:100%;display:flex;justify-content:center}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .video-container video,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .video-container video{display:block;min-width:50px;max-width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .audio-container,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .audio-container{width:100%}.embed-block[data-embed-type=video]>div[data-type=block-content] .media-element .audio-container audio,.embed-block[data-embed-type=audio]>div[data-type=block-content] .media-element .audio-container audio{display:block;width:100%}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment{box-shadow:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment .media,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment .media{box-shadow:0 2px #f8e6ab}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment.active,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment.active{outline:none}.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=video].comment.active .media,.editor-root div.editor-content div[data-type=editor-container] .embed-block[data-type=editor-block][data-embed-type=audio].comment.active .media{box-shadow:none;outline:4px solid #f8e6ab}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content]:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content]:after{display:none}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content] .media,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content] .media{position:relative}.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-self>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=video].locked-by-others>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-self>[data-type=block-content] .media:after,.editor-root:not(.readonly) .embed-block[data-embed-type=audio].locked-by-others>[data-type=block-content] .media:after{content:" ";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;z-index:1;background-color:#303030;opacity:.1}`)),document.head.appendChild(t)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
2
  (function(b,Un){typeof exports=="object"&&typeof module<"u"?Un(exports,require("kiwi-intl"),require("lodash.merge"),require("string-template"),require("nanoid"),require("events"),require("query-string"),require("js-base64"),require("snabbdom"),require("lodash.clonedeep"),require("lodash.isequal"),require("quill-delta"),require("tiny-typed-emitter"),require("lodash.intersection"),require("ot-json1"),require("axios"),require("lodash.findlastindex"),require("reconnecting-websocket"),require("fast-sha256"),require("lodash.debounce"),require("tippy.js"),require("blueimp-md5"),require("css-color-converter"),require("markmap-view"),require("lodash.throttle"),require("prismjs"),require("prismjs/components/prism-c"),require("prismjs/components/prism-cpp"),require("prismjs/components/prism-abap"),require("prismjs/components/prism-arduino"),require("prismjs/components/prism-bash"),require("prismjs/components/prism-basic"),require("prismjs/components/prism-clojure"),require("prismjs/components/prism-coffeescript"),require("prismjs/components/prism-csharp"),require("prismjs/components/prism-css"),require("prismjs/components/prism-dart"),require("prismjs/components/prism-diff"),require("prismjs/components/prism-docker"),require("prismjs/components/prism-elixir"),require("prismjs/components/prism-elm"),require("prismjs/components/prism-erlang"),require("prismjs/components/prism-flow"),require("prismjs/components/prism-fortran"),require("prismjs/components/prism-fsharp"),require("prismjs/components/prism-gherkin"),require("prismjs/components/prism-glsl"),require("prismjs/components/prism-go"),require("prismjs/components/prism-graphql"),require("prismjs/components/prism-groovy"),require("prismjs/components/prism-haskell"),require("prismjs/components/prism-java"),require("prismjs/components/prism-javascript"),require("prismjs/components/prism-json"),require("prismjs/components/prism-julia"),require("prismjs/components/prism-kotlin"),require("prismjs/components/prism-latex"),require("prismjs/components/prism-less"),require("prismjs/components/prism-lisp"),require("prismjs/components/prism-livescript"),require("prismjs/components/prism-lua"),require("prismjs/components/prism-makefile"),require("prismjs/components/prism-markdown"),require("prismjs/components/prism-markup"),require("prismjs/components/prism-matlab"),require("prismjs/components/prism-mermaid"),require("prismjs/components/prism-nix"),require("prismjs/components/prism-objectivec"),require("prismjs/components/prism-ocaml"),require("prismjs/components/prism-pascal"),require("prismjs/components/prism-perl"),require("prismjs/components/prism-php"),require("prismjs/components/prism-powershell"),require("prismjs/components/prism-prolog"),require("prismjs/components/prism-protobuf"),require("prismjs/components/prism-python"),require("prismjs/components/prism-r"),require("prismjs/components/prism-reason"),require("prismjs/components/prism-ruby"),require("prismjs/components/prism-rust"),require("prismjs/components/prism-sass"),require("prismjs/components/prism-scala"),require("prismjs/components/prism-scheme"),require("prismjs/components/prism-scss"),require("prismjs/components/prism-solidity"),require("prismjs/components/prism-sql"),require("prismjs/components/prism-swift"),require("prismjs/components/prism-typescript"),require("prismjs/components/prism-vbnet"),require("prismjs/components/prism-verilog"),require("prismjs/components/prism-vhdl"),require("prismjs/components/prism-visual-basic"),require("prismjs/components/prism-wasm"),require("prismjs/components/prism-yaml"),require("mime-db"),require("dom-to-image"),require("@guyplusplus/turndown-plugin-gfm"),require("turndown"),require("marked"),require("@better-scroll/core"),require("plantuml-encoder"),require("docx")):typeof define=="function"&&define.amd?define(["exports","kiwi-intl","lodash.merge","string-template","nanoid","events","query-string","js-base64","snabbdom","lodash.clonedeep","lodash.isequal","quill-delta","tiny-typed-emitter","lodash.intersection","ot-json1","axios","lodash.findlastindex","reconnecting-websocket","fast-sha256","lodash.debounce","tippy.js","blueimp-md5","css-color-converter","markmap-view","lodash.throttle","prismjs","prismjs/components/prism-c","prismjs/components/prism-cpp","prismjs/components/prism-abap","prismjs/components/prism-arduino","prismjs/components/prism-bash","prismjs/components/prism-basic","prismjs/components/prism-clojure","prismjs/components/prism-coffeescript","prismjs/components/prism-csharp","prismjs/components/prism-css","prismjs/components/prism-dart","prismjs/components/prism-diff","prismjs/components/prism-docker","prismjs/components/prism-elixir","prismjs/components/prism-elm","prismjs/components/prism-erlang","prismjs/components/prism-flow","prismjs/components/prism-fortran","prismjs/components/prism-fsharp","prismjs/components/prism-gherkin","prismjs/components/prism-glsl","prismjs/components/prism-go","prismjs/components/prism-graphql","prismjs/components/prism-groovy","prismjs/components/prism-haskell","prismjs/components/prism-java","prismjs/components/prism-javascript","prismjs/components/prism-json","prismjs/components/prism-julia","prismjs/components/prism-kotlin","prismjs/components/prism-latex","prismjs/components/prism-less","prismjs/components/prism-lisp","prismjs/components/prism-livescript","prismjs/components/prism-lua","prismjs/components/prism-makefile","prismjs/components/prism-markdown","prismjs/components/prism-markup","prismjs/components/prism-matlab","prismjs/components/prism-mermaid","prismjs/components/prism-nix","prismjs/components/prism-objectivec","prismjs/components/prism-ocaml","prismjs/components/prism-pascal","prismjs/components/prism-perl","prismjs/components/prism-php","prismjs/components/prism-powershell","prismjs/components/prism-prolog","prismjs/components/prism-protobuf","prismjs/components/prism-python","prismjs/components/prism-r","prismjs/components/prism-reason","prismjs/components/prism-ruby","prismjs/components/prism-rust","prismjs/components/prism-sass","prismjs/components/prism-scala","prismjs/components/prism-scheme","prismjs/components/prism-scss","prismjs/components/prism-solidity","prismjs/components/prism-sql","prismjs/components/prism-swift","prismjs/components/prism-typescript","prismjs/components/prism-vbnet","prismjs/components/prism-verilog","prismjs/components/prism-vhdl","prismjs/components/prism-visual-basic","prismjs/components/prism-wasm","prismjs/components/prism-yaml","mime-db","dom-to-image","@guyplusplus/turndown-plugin-gfm","turndown","marked","@better-scroll/core","plantuml-encoder","docx"],Un):(b=typeof globalThis<"u"?globalThis:b||self,Un(b["oneseditor-editor"]={},b.KiwiIntl,b.merge,b.stringFormat,b.nanoid$1,b.events,b.queryString,b.jsBase64,b.snabbdom,b.cloneDeep,b.isEqual,b.Delta,b.tinyTypedEmitter,b.intersection,b.json1,b.axios,b.findLastIndex,b.ReconnectingWebSocket,b.sha256,b.debounce,b.tippy$1,b.md5,b.cssColorConverter,b.markmap,b.throttle,b.Prism,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,b.mime,b.domToImage,b.turndownPluginGfm,b.TurndownService,b.marked,b.BetterScroll,b.plantumlEncoder,b.docx))})(this,function(b,Un,ps,lB,cB,V5,aB,la,Ti,uB,dB,hB,ve,fB,mB,gB,pB,CB,AB,bB,am,vB,um,yB,kB,wB,Ztt,Qtt,Ytt,Jtt,Ktt,Xtt,tet,eet,net,oet,ret,iet,set,cet,aet,uet,det,het,fet,met,get,pet,Cet,Aet,bet,vet,yet,ket,wet,Bet,Eet,xet,Iet,Tet,Det,Let,Met,Ret,Oet,_et,Fet,Pet,Net,$et,Het,jet,Uet,zet,Vet,Wet,qet,Get,Zet,Qet,Yet,Jet,Ket,Xet,tnt,ent,nnt,ont,rnt,int,snt,lnt,cnt,ant,BB,EB,xB,IB,W5,TB,DB,gt){"use strict";var qtt=Object.defineProperty;var Gtt=(b,Un,ps)=>Un in b?qtt(b,Un,{enumerable:!0,configurable:!0,writable:!0,value:ps}):b[Un]=ps;var m=(b,Un,ps)=>(Gtt(b,typeof Un!="symbol"?Un+"":Un,ps),ps);const xe=n=>n&&typeof n=="object"&&"default"in n?n:{default:n};function _d(n){if(n&&n.__esModule)return n;const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const e in n)if(e!=="default"){const o=Object.getOwnPropertyDescriptor(n,e);Object.defineProperty(t,e,o.get?o:{enumerable:!0,get:()=>n[e]})}}return t.default=n,Object.freeze(t)}const SB=xe(Un),dm=xe(ps),LB=xe(lB),q5=xe(V5),mt=xe(uB),ca=xe(dB),on=xe(hB),hm=xe(fB),Fd=_d(mB),MB=xe(gB),RB=xe(pB),OB=xe(CB),_B=_d(AB),Le=xe(bB),FB=xe(am),PB=_d(am),Pd=xe(vB),NB=_d(yB),$B=xe(kB),aa=xe(wB),fm=xe(BB),G5=xe(EB),HB=xe(IB),Z5=xe(TB),jB=xe(DB);function UB(n){const t=o=>o<10?`0${String(o)}`:String(o),e=o=>o<10?`00${String(o)}`:o<100?`0${String(o)}`:String(o);return`${n.getFullYear()}-${t(n.getMonth()+1)}-${t(n.getDate())} ${t(n.getHours())}:${t(n.getMinutes())}:${t(n.getSeconds())}.${e(n.getMilliseconds())}`}var ua=(n=>(n.DEBUG="DEBUG",n.INFO="INFO ",n.WARN="WARN ",n.ERROR="ERROR",n))(ua||{});const Q5=new Map,Oc=class{constructor(t){m(this,"times",new Map);this.category=t}shouldLog(t){const e=Object.values(ua).indexOf(t),o=Object.values(ua).indexOf(Oc.level);return e>=o}_log(t,e,o,r){var B;if(!this.shouldLog(t))return;const i=typeof process>"u"?{}:process;let s="";if(typeof e=="object")try{s="message"in e?e.message:JSON.stringify(e,null,4)}catch{s=""}else typeof e=="string"?e&&(s=e):s=JSON.stringify(e);s=r?`${s} - ${r}`:s;const l=`${this.category}`;let a=console.log;t==="WARN "&&(a=console.warn),t==="ERROR"&&(a=console.error);const d=`${UB(new Date)}`,h=t,p=l,A=Oc.extParams?"[{date}] {level}: [{module} {extParams}] - {msg}":"[{date}] {level}: [{module}] - {msg}",v=[LB.default(((B=i.env)==null?void 0:B.LOG_TEMPLATE)||A,{date:d,level:h,module:p,msg:s,extParams:Oc.extParams})];if(typeof e=="object"){const D=e.stack;D&&v.push(D)}if(a===console.error&&Oc.debugMode){const D=new Error().stack;D&&v.push(D)}a(...v),o&&this._log(t,o)}log(t,e){this._log("INFO ",t,void 0,e)}debug(t,e){this._log("DEBUG",t,void 0,e)}info(t,e){this._log("INFO ",t,void 0,e)}warn(t,e,o){this._log("WARN ",t,e,o)}error(t,e,o){this._log("ERROR",t,e,o)}time(t){this.times.set(t,Date.now())}timeEnd(t){this.timeLog(t),this.times.delete(t)}timeLog(t){const e=this.times.get(t);if(!e){this.warn(`no time label: ${t}`);return}this.debug(`${t}: ${Date.now()-e}`)}static setExtParams(t){this.extParams=t}};let Di=Oc;m(Di,"debugMode",!1),m(Di,"level","DEBUG"),m(Di,"extParams","");function S(n){const t=Q5.get(n);if(t)return t;const e=new Di(n);return Q5.set(n,e),e}const zB={name:"ONES Editor",date:{dateFromFuture:"From the future",dateJustNow:"Just now",dateYesterday:"Yesterday",dateMinutesAgo:"{num} minutes ago",date1HourAgo:"1 hour ago",dateHoursAgo:"{num} hours ago",dateDaysAgo:"{num} days ago",dateWeeksAgo:"{num} weeks ago"},common:{cancel:"Cancel"},docx:{imageExportFailed:"Failed to load image"}},VB={name:"Ones Editor",date:{dateFromFuture:"\u6765\u81EA\u672A\u6765",dateJustNow:"\u521A\u521A",dateYesterday:"\u6628\u5929",dateMinutesAgo:"{num}\u5206\u949F\u524D",date1HourAgo:"1\u5C0F\u65F6\u524D",dateHoursAgo:"{num}\u5C0F\u65F6\u524D",dateDaysAgo:"{num}\u5929\u524D",dateWeeksAgo:"{num}\u5468\u524D"},common:{cancel:"\u53D6\u6D88"},docx:{imageExportFailed:"\u56FE\u7247\u52A0\u8F7D\u5931\u8D25"}},WB={name:"ONES \u30A8\u30C7\u30A3\u30BF\u30FC",date:{dateFromFuture:"\u672A\u6765\u304B\u3089",dateJustNow:"\u305F\u3060\u4ECA",dateYesterday:"\u6628\u65E5",dateMinutesAgo:"{num}\u5206\u524D",date1HourAgo:"1\u6642\u9593\u524D",dateHoursAgo:"{num}\u6642\u9593\u524D",dateDaysAgo:"{num}\u65E5\u524D",dateWeeksAgo:"{num}\u9031\u524D"},common:{cancel:"\u30AD\u30E3\u30F3\u30BB\u30EB"},docx:{imageExportFailed:"\u753B\u50CF\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F"}},qB=S("i18n"),GB={"en-US":zB,"zh-CN":VB,"ja-JP":WB},Nd=SB.default.init("en-US",GB);function ZB(n=void 0){Nd.setLang&&Nd.setLang(n||"en-US")}function QB(n){dm.default(Nd.__metas__,n)}function YB(n,t){const e=Nd.get(n,t);return e===n&&qB.warn(`no locale value for key ${n}`),e}const R=Object.freeze(Object.defineProperty({__proto__:null,setLang:ZB,mergeLang:QB,t:YB},Symbol.toStringTag,{value:"Module"})),unt="";class Y5{constructor(t,e){this.editor=t,this.data=e}getData(){return this.data}getEditor(){return this.editor}destroy(){}}class JB extends Error{constructor(t){if(super(t),this.code="Assert",this.stack){const e=this.stack.split(`
3
3
  `);if(e.length>1)if(this.lineNumber&&this.columnNumber){const o=e[1].match(/(.*)@(.*):(\d+):(\d+)/);o&&(this.lineNumber=+o[3],this.columnNumber=+o[4],this.fileName=o[2]),e.splice(0,1)}else e.splice(1,1);this.stack=e.join(`
4
4
  `)}}}function g(n,t,e){if(!t)throw n.error(`assert failed: ${e}`),new JB(e)}const KB=cB.customAlphabet("1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_",8),J5="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";function XB(){return J5[Date.now()%J5.length]}const K=()=>`${XB()}${KB()}`;class K5 extends q5.default.EventEmitter{constructor(e=60){super();m(this,"cache",new Map);m(this,"expiredSeconds");this.expiredSeconds=e,this.startAutoClear()}delete(e){const o=this.cache.get(e);o&&this.emit("delete",o.data),this.cache.delete(e)}getSync(e,o){const r=this.cache.get(e),i=Date.now();if(r&&(i-r.lastRead)/1e3<this.expiredSeconds)return r.lastRead=i,r.data;const s=o(e);return this.cache.set(e,{lastRead:i,data:s}),s}async get(e,o){const r=this.cache.get(e),i=Date.now();if(r&&(i-r.lastRead)/1e3<this.expiredSeconds)return r.lastRead=i,r.data;const s=await o(e);return this.cache.set(e,{lastRead:i,data:s}),s}startAutoClear(){setInterval(()=>{const e=Date.now();Array.from(this.cache.entries()).forEach(([o,r])=>{(e-r.lastRead)/1e3>this.expiredSeconds&&this.delete(o)})},10*1e3)}}class da{constructor(){m(this,"_callbacks",new Set)}get callbacks(){return Array.from(this._callbacks)}registerCallback(t){this._callbacks.add(t)}unregisterCallback(t){this._callbacks.delete(t)}clearCallbacks(){this._callbacks.clear()}}const tE=S("await-locker");class eE{constructor(){m(this,"_acquired",!1);m(this,"_waitingResolvers",[]);this._acquired=!1,this._waitingResolvers=[]}acquireAsync(t){return this._acquired?new Promise((e,o)=>{this._waitingResolvers.push(e),t&&t>0&&setTimeout(()=>{const r=this._waitingResolvers.indexOf(e);if(r!==-1){this._waitingResolvers.splice(r,1);const i=new Error(`lock timeout: ${t}, waiting resolves: ${this._waitingResolvers.length}`);o(i)}},t)}):(this._acquired=!0,Promise.resolve())}tryAcquire(){return this._acquired?!1:(this._acquired=!0,!0)}release(){if(!this._acquired)throw new Error("Cannot release an unacquired lock");if(this._waitingResolvers.length>0){const t=this._waitingResolvers.shift();g(tE,t,"Resolver missing"),t(void 0)}else this._acquired=!1}acquired(){return this._acquired}debug(){const t=this._waitingResolvers.length;return console.log(`waiting resolves: ${t}`),{waitingCount:t}}}class nE{constructor(){m(this,"_map");this._map=new Map}getLocker(t){let e=this._map.get(t);return e||(e=new eE,this._map.set(t,e)),e}async lock(t,e){await this.getLocker(t).acquireAsync(e)}release(t){this.getLocker(t).release()}remove(t){this.isLocking(t)||this._map.delete(t)}isLocking(t){return this._map.has(t)?this.getLocker(t).acquired():!1}}const Eo=new nE;/**
@@ -394,13 +394,13 @@ xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24">
394
394
  <path d="M1 10.0039H5.99738L5.99608 15" stroke="currentColor" stroke-width="2"/>
395
395
  <path d="M14.9971 5.99611H9.99969L10.001 1" stroke="currentColor" stroke-width="2"/>
396
396
  </svg>`;async function oO(n,t,e){const o=te(t),r=o.querySelector('[data-button-id="mindmap-fullscreen"]');g(we,r,"no full screen button");const i=()=>{setTimeout(()=>{e.toMindmap(n,t,{},{reset:!0,mindmapTools:e})},300)},s=()=>{ot(o,"fullscreen"),r.innerHTML=c9,Qb(r,"Full screen",n.clientId),u9(t)&&setTimeout(()=>{i()},300)};if(document.fullscreenElement===o){try{await a9()}catch(l){we.error(l)}s()}else{try{W(o,"fullscreen"),await tO(o),i()}catch(l){we.error(l)}r.innerHTML=nO,Qb(r,R.t("mindmap.exitFullscreen"),n.clientId)}o.onfullscreenchange=()=>{document.fullscreenElement||s()}}function c0(n,t,e,o,r){if(t.querySelector(`[data-button-id="${e}"]`))return null;const s=uo(e,o,r,[],n.clientId);return W(s,"mindmap-button"),t.appendChild(s),s}function a0(n,t){return n.querySelector(`[data-button-id="${t}"]`)}function rO(n){return a0(n,"mindmap-fullscreen")}function iO(n){return a0(n,"mindmap-fit")}function sO(n){return a0(n,"mindmap-close")}function lO(n,t,e,o){const r=c0(n,t,"mindmap-close",R.t("mindmap.close"),KR);!r||n.domEvents.addEventListener(r,"click",()=>{o.closeMindmap(n,e)})}function cO(n,t,e,o){const r=c0(n,t,"mindmap-fit",R.t("mindmap.autoFit"),XR);!r||n.domEvents.addEventListener(r,"click",()=>{o.fitMindmap(n,e)})}function aO(n,t,e,o){if(navigator.userAgent.includes("Mobile")&&!navigator.userAgent.includes("iPad"))return;const i=c0(n,t,"mindmap-fullscreen",R.t("mindmap.fullScreen"),c9);!i||n.domEvents.addEventListener(i,"click",()=>{oO(n,e,o)})}function uO(n,t){const e=Xd(t);if(!e)return;const o=iO(e);o&&(o.remove(),n.domEvents.removeAllListeners(o));const r=sO(e);r&&(r.remove(),n.domEvents.removeAllListeners(r));const i=rO(e);i&&(i.remove(),n.domEvents.removeAllListeners(i))}const dc=new Map;function u0(n,t,e){const o=(s,l)=>{s.forEach(a=>{l?W(a.block,"to-mindmap-highlight"):ot(a.block,"to-mindmap-highlight"),o(a.children,l)})},r=l9(n,t);if(r.length===0)return;const i=r[0].block;if(e){const s=dc.get(i);s&&(s.forEach(l=>l.cancel()),dc.delete(i)),o(r,!0)}else{const s=setTimeout(()=>{o(r,!1),dc.delete(i)},300),l=()=>{clearTimeout(s),dc.delete(i)},a=dc.get(i);a?a.push({cancel:l}):dc.set(i,[{cancel:l}])}}const{Markmap:dO}=NB;function hO(n,t){Fe(t);const e=l9(n,t),o=e[0].block,r=d=>({t:"text",v:Lt(d.block).textContent,d:1,c:d.children.length>0?d.children.map(p=>r(p)):void 0});let i=null;e.length>1?i={t:"root",v:"root",d:0,c:e.length>0?e.map(d=>r(d)):void 0}:i=r(e[0]);const l=d=>{if(d.length===0)return null;const h=d[d.length-1];return h.children&&h.children.length>0?l(h.children):h},a=l(e);return{root:i,block:o,nodes:e,last:a}}function df(n,t,e,o){const{root:r,block:i,last:s}=hO(n,t);o.selectBlock&&n.selection.selectBlock(i,0,0),u0(n,i,!1),o.saveData&&n.updateBlockData(i,{viewAsMindmap:!0});const l=te(i);let a=l.querySelector(".editor-mindmap-svg");if(o.reset&&(a&&a.remove(),a=null),a)a.innerHTML="";else{const _="http://www.w3.org/2000/svg",M=l.getBoundingClientRect(),H=document.fullscreenElement===l,z=H?`${M.width}`:`${t.getBoundingClientRect().width}`,q=H?`${M.height}`:"600",rt=document.createElementNS(_,"svg");rt.setAttributeNS(null,"viewBox",`0 0 ${z} ${q}`),rt.setAttributeNS(null,"width","100%"),rt.setAttributeNS(null,"height",q),rt.style.display="block",rt.style.width="100%",rt.style.height=`${q}px`,rt.classList.add("editor-mindmap-svg"),l.appendChild(rt),a=rt}const d=i,p=`editor-mindmap-root-${it(i)}`;W(d,"editor-in-mindmap-first",p,"readonly"),d.contentEditable="false";const A=Zt(i);A&&bt(A)<=bt(s.block)&&eO(A,s.block,["block-hidden",p]);const v=(_,M)=>{if(M.length>0){const H=M[0].parentElement;H&&(H.style.width="100vw",H.style.maxWidth="200px")}M.forEach(H=>{W(H,"editor-mindmap-node")})},B=new dO(a,{...e,autoFit:!0});B.viewHooks.transformHtml.tap(v),B.setData(r),B.fit();const D=te(i);let x=D.querySelector(".mindmap-toolbar");x||(x=w("div",["mindmap-toolbar"],D)),cO(n,x,d,o.mindmapTools),aO(n,x,d,o.mindmapTools),lO(n,x,d,o.mindmapTools),n.domEvents.addEventListener(a,"click",()=>{n.selection.selectBlock(i,0),n.input.focus()}),d.mindMap=B}function fO(n){const t=w("div",["list-to-mindmap-wrap"],null),e=uo("list-to-mindmap",R.t("mindmap.viewAsMindMap"),UR,[],n.clientId);return t.appendChild(e),t}async function d9(n,t){const e=`editor-mindmap-root-${t.id}`,o=nt(t);fe(o).forEach(l=>{xt(l,e)&&ot(l,e,"editor-in-mindmap-first","block-hidden")});const i=te(t);document.fullscreenElement===i&&await a9();const s=i.querySelector(".editor-mindmap-svg");!s||(g(we,s,"no mindmap svg"),s.remove(),n.domEvents.removeAllListeners(s),uO(n,t))}function mO(n){const t=n.classList,e="editor-mindmap-root-";return Array.from(t).find(r=>{if(r.startsWith(e))return r})}async function h9(n,t){!mO(t)||(n.updateBlockData(t,{viewAsMindmap:null}),d9(n,t),n.selection.selectBlock(t,0))}function gO(n,t){const e=t.mindMap;e&&e.fit()}const d0={toMindmap:df,closeMindmap:h9,fitMindmap:gO},Ent="";class hf{constructor(t){m(this,"toMindmapButton");m(this,"currentBlock",null);m(this,"handleHoveringBlock",t=>{!this.editor.isWritable()||(t&&Ht(t)&&Zn(t)!=="unchecked"&&Zn(t)!=="checked"?te(t).appendChild(this.toMindmapButton):this.toMindmapButton.remove())});m(this,"handleMouseEnter",()=>{const t=et(this.toMindmapButton);g(we,t&&Ht(t),"no parent list"),u0(this.editor,t,!0),this.currentBlock=t});m(this,"handleMouseLeave",()=>{this.currentBlock&&(u0(this.editor,this.currentBlock,!1),this.currentBlock=null)});m(this,"handleClick",()=>{const t=et(this.toMindmapButton);g(we,t&&Ht(t),"no parent list"),df(this.editor,t,{},{saveData:!0,selectBlock:!0,mindmapTools:d0})});this.editor=t,Ce.get(this.editor).addListener("change",this.handleHoveringBlock),this.toMindmapButton=fO(t),t.domEvents.addEventListener(this.toMindmapButton,"mouseenter",this.handleMouseEnter),t.domEvents.addEventListener(this.toMindmapButton,"mouseleave",this.handleMouseLeave),t.domEvents.addEventListener(this.toMindmapButton,"click",this.handleClick)}static get(t){return t.findCustomByType(hf)}destroy(){Ce.get(this.editor).removeListener("change",this.handleHoveringBlock)}hide(){this.currentBlock&&(this.currentBlock=null),this.toMindmapButton.remove()}}function pO(n,t,e){var o;t==="beginDrag"&&((o=hf.get(n))==null||o.hide())}function hc(n,t,e,o){var i;const r=(i=o==null?void 0:o.groupId)!=null?i:K();t.forEach(s=>{const l=n.getBlockData(s);if(l.start!==e||(o==null?void 0:o.resetGroupId)){const a={...l,start:e};o!=null&&o.resetGroupId&&(a.groupId=r),n.updateBlockData(s,a)}l.textOnly||(e+=1)})}function h0(n,t,e,o){const r=s9(t,{withSelf:!0});r.length!==0&&hc(n,r,e,o)}class ff{constructor(t,e){m(this,"listStart",0);m(this,"listBrother",null);if(this.editor=t,uf(e))return;const o=Cu(e),r=mo(o);this.listStart=r,o===e?this.listBrother=qs(o):this.listBrother=o}fix(){!this.listBrother||h0(this.editor,this.listBrother,this.listStart)}}class Gs{constructor(t,e,o){m(this,"listStart");m(this,"listBrother",null);this.editor=t,this.options=o;const r=Cu(e),i=mo(r);this.listStart=i,this.listBrother=r,o!=null&&o.resetStart&&(this.listStart=1)}fix(){!this.listBrother||h0(this.editor,this.listBrother,this.listStart,this.options)}}class CO{constructor(t,e,o){m(this,"listStart");m(this,"listNextBrothers",[]);this.editor=t,this.listNextBrothers=uc(e);const{start:r,resetStart:i}=o||{};this.listStart=i?1:r!=null?r:1}fix(){!this.listNextBrothers.length||hc(this.editor,this.listNextBrothers,this.listStart)}}function AO(n,t,e){n.getBlockData(t).quoted&&(e.quoted=!0)}function f0(n,t,e,o){if(we.debug("drag a block on a list block"),!tt(n,t))return!1;g(we,Ht(e),"target is not a list block");const{type:r,start:i,level:s,groupId:l}=qi(e),a=o==="after"?i+1:i,d=n.getBlockData(t),h={id:K(),type:"list",groupId:l,level:s,start:a,text:d.text,...s0(r)};AO(n,e,h);let p=bt(e);const A=nt(e);o==="after"&&(p+=1);let v=null;Ht(t)&&(v=new ff(n,t));const B=n.insertBlock(ct(A),p,h,ph(h.id,0));return n.deleteBlock(t),new Gs(n,B).fix(),v==null||v.fix(),!0}function bO(n,t,e,o){if(we.debug("drag a list between text blocks"),o==="after"){const d=Zt(e);if(d&&Ht(d))return f0(n,t,d,"before")}if(o==="before"){const d=ce(e);if(d&&Ht(d))return f0(n,t,d,"after")}const i={...n.getBlockData(t),groupId:K(),start:1,level:1};let s=bt(e);const l=nt(e);o==="after"&&(s+=1),n.insertBlock(ct(l),s,i,ph(i.id,0));const a=new ff(n,t);return n.deleteBlock(t),a.fix(),!0}function vO(n,t,e,o,r){if(Gd(e))return!1;const{blockId:i}=e,s=n.getBlockById(i);g(we,s,"no dragged block");const{isSourceBlock:l,targetBlock:a}=r;return!l&&a?(g(we,t===a,"block !== target block"),g(we,Ht(a),"target is not a list block"),f0(n,s,a,o)):bO(n,s,a,o)}function mf(n){const t=n.getAttribute("block-padding-level");return t?Number(t):null}function yO(n,t){let e;const o=mf(t);if(!o)e=1;else{if(o>=12)return e=12,!1;e=o+1}return n.updateBlockData(t,{...n.getBlockData(t),padding:e}),!0}function f9(n,t){const e=mf(t);if(!e)return!1;const o=n.getBlockData(t);return e>1?(n.updateBlockData(t,{...o,padding:e-1}),!0):(n.updateBlockData(t,{...o,padding:null}),!0)}function m0(n){return n.readonly||!n.isWritable()}function kO(n){return n.selection.range.getSelectedBlocks().forEach(e=>{const o=e.block;tt(n,o)&&yO(n,o)}),!0}function wO(n){return n.selection.range.getSelectedBlocks().forEach(e=>{const o=e.block;tt(n,o)&&f9(n,o)}),!0}function BO(n){return m0(n)?!1:n.undoManager.runInGroup(()=>(kO(n),!0))}function EO(n){return m0(n)?!1:n.undoManager.runInGroup(()=>(wO(n),!0))}function xO(n){if(m0(n))return!1;if(!n.selection.range.isCollapsed())return;const t=n.selection.focusedBlock;if(!tt(n,t))return;const e=n.selection.range.focus;if(!(!e.isSimple()||e.offset!==0||!mf(t)))return f9(n,t),!0}class g0{renderBlock(t,e,o){const{padding:r}=o;return r?{attributes:{"block-padding-level":r}}:{}}}const xnt="",IO={Tab:BO,"Shift+Tab":EO,Backspace:xO};function TO(n,t,e=1){if(!t)return null;let o=ce(n);for(;o;){const r=o.getAttribute("data-style-heading"),i=Number(o.getAttribute("data-list-level"));if(r){if(r<t)return null;if(r===t&&i===e)return Ht(o)?o:null}o=ce(o)}return null}function DO(n,t){const e=n.getAttribute("data-style-heading"),o=TO(n,e);if(o)return o;const r=ce(n);if(r&&Ht(r)&&Zn(r)===t)return r;const i=Zt(n);return i&&Ht(i)&&Zn(i)===t?i:null}function SO(n,t,e){var D,x,_;const o=(D=e.data)!=null?D:{};let r=1;if(Ht(t))r=vn(t);else{const M=mf(t);M&&(r=M+1),r>8&&(r=8)}const i=(x=o.listType)!=null?x:"ordered";if(i==="text-only")return null;const s=n.getBlockData(t);let l=(_=s.text)!=null?_:[],d=ie(l);const h=e.offset||0;h<=rn(l)&&(l=Tn(l,h).right,d=d.substring(0,h));let p=1;i==="ordered"&&(p=Number.parseInt(d,10)||1);let A=K();const v=DO(t,i);if(v){if(bt(t)>bt(v))p=mo(v)+1;else{const H=mo(v);H>1&&(p=H-1)}A=ac(v),new CO(n,v,{start:p+1}).fix()}const B={id:K(),type:"list",level:r,start:p,groupId:A,ordered:!1,text:l};return s.quoted&&(B.quoted=!0),s.heading&&(B.heading=s.heading),i==="ordered"?B.ordered=!0:(i==="checked"||i==="unchecked")&&(B.checkbox=i),{blockData:B,onConverted:(M,H)=>{new Gs(M,H).fix()}}}function fc(n){return n.textOnly?"text-only":n.checkbox?n.checkbox:n.ordered?"ordered":"unordered"}function LO(n){var e,o;if(n.checkbox||n.textOnly)return"";const t=(e=n.level)!=null?e:1;return n.ordered?`${GR(t,(o=n.start)!=null?o:1)}.`:ZR(t)}function gf(n){return n==="checked"||n==="unchecked"}function m9(n,t,e,o){const r=t,{containerId:i,blockIndex:s}=o[o.length-1];if(s===0)return!0;const l=e.blocks[i][s-1];if(l.type!=="list")return!0;const a=fc(r),d=fc(l);return a!==d&&(!gf(a)||!gf(d))||r.level>l.level}function g9(n,t,e,o){const r=t,{containerId:i,blockIndex:s}=o[o.length-1];if(s===e.blocks[i].length-1)return!0;const l=e.blocks[i][s+1];if(l.type!=="list")return!0;const a=fc(r),d=fc(l);return a!==d&&(!gf(a)||!gf(d))||r.level>l.level}function MO(n,t,e,o,r){var s,l,a;const i=t;if(o==="text")return((s=Dn.convertTo)==null?void 0:s.call(Dn,n,t,e,"text",r))||"";if(o==="markdown"){let d=((l=Dn.convertTo)==null?void 0:l.call(Dn,n,t,e,"markdown",r))||"";i.checkbox==="checked"?d=`[x] ${d}`:i.checkbox==="unchecked"&&(d=`[ ] ${d}`),i.ordered?d=`${i.start}. ${d}`:d=`- ${d}`;const h=i.level||0;return d=(h>0?" ".repeat(h-1):"")+d,m9(n,t,e,r)&&(d=`${d}`),g9(n,t,e,r)&&(d=`${d}`,h<=1&&(d+=`
397
- `)),d}if(o==="html"){let d=((a=Dn.convertTo)==null?void 0:a.call(Dn,n,t,e,"html",r))||"";d=d.replace("<p>","").replace("</p>",""),i.checkbox==="checked"?d=`<input type="checkbox" checked="checked" disabled="disabled" /> ${d}`:i.checkbox==="unchecked"&&(d=`<input type="checkbox" disabled="disabled" /> ${d}`);let h="ul";return i.ordered?(d=`<li value="${i.start}">${d}</li>`,h="ol"):d=`<li>${d}</li>`,m9(n,t,e,r)&&(d=`<${h}>${d}`),g9(n,t,e,r)&&(d=`${d}</${h}>`),d}return""}function p9(n){const t=w("label",["editor-check-list-wrapper"],null);n&&W(t,"editor-check-list-wrapper-checked");const e=w("span",["editor-check-box"],t);return w("span",["editor-check-box-inner"],e),t}function RO(n,t){const e=fc(t);if(e!=="text-only"){if(e==="checked"){n.append(p9(!0));return}if(e==="unchecked"){n.append(p9(!1));return}n.innerText=LO(t)}}function OO(n){const t=w("div",["list-container"],null),e=w("button",["list-marker"],t);return RO(e,n),t}function C9(n){let t=Zt(n);if(!t)return null;const e=qs(n);for(;t!==e;){if(g(we,t,"no next block"),Ht(t))return vn(t)>vn(n)?t:null;if(t=Zt(t),!t)return null}return null}function p0(n){const t=[];let e=C9(n);if(!e)return t;for(;e;){const o=qs(e);t.push({block:e,children:p0(e)}),e=o}return t}function _O(n){const t=(o,r)=>{r.push(o.block),o.children.forEach(i=>t(i,r))},e=[];return n.forEach(o=>t(o,e)),e}function A9(n,t){return vn(t)!==1}function b9(n,t,e){t.forEach(o=>{const r=n.getBlockData(o.block);n.updateBlockData(o.block,{...r,groupId:e,level:r.level-1}),o.children.length&&b9(n,o.children,r.groupId)})}function C0(n,t){if(!A9(n,t))return!1;const e=vn(t);if(e===1)return!1;let o=K(),r=1,i=Zn(t);const s=e-1,l=l0(t);l&&(o=ac(l),r=mo(l)+1,i!=="text-only"&&(i=Zn(l)));const a=p0(t),d=n.getBlockData(t),h={...d,groupId:o,level:s,start:r,...s0(i)};n.updateBlockData(t,h),n.doc.beginBatchUpdate(),b9(n,a,d.groupId),n.doc.endBatchUpdate(),new Gs(n,t).fix();const A=C9(t);return A&&new Gs(n,A,{resetStart:!0,resetGroupId:!0}).fix(),!0}function mc(n,t){Fe(t);const e=n.getBlockData(t),o={id:K(),type:"text",text:e.text};e.heading&&(o.heading=e.heading),e.heading&&(o.heading=e.heading);const r=new ff(n,t),i=nt(t),s=bt(t);n.deleteBlock(t);const l=ph(o.id,0);if(wa(n,i)&&!Yt(i)){n.insertBlock(ct(i),s,o,l);const a=ye(i);n.deleteBlock(a)}else n.insertBlock(ct(i),s,o,l);r.fix()}function FO(n){if(!n.selection.range.isCollapsed())return!1;const t=n.selection.focusedBlock;if(!Ht(t))return!1;const e=n.selection.range.focus;return!e.isSimple()||e.offset!==0?!1:vn(t)===1?(mc(n,t),!0):(C0(n,t),!0)}const PO=S("list-block");function NO(n,t,e){g(PO,Ht(t),"not a list block");const o={...n.getBlockData(t),id:K()};return e!=null&&e.level&&(o.level=e.level),e!=null&&e.start&&(o.start=e.start),e!=null&&e.keepText||delete o.text,(o==null?void 0:o.checkbox)==="checked"&&(o.checkbox="unchecked"),o}function $O(n){if(Fe(n),!uf(n))return n;let t=Gi(n);for(;t;){if(!uf(t))return t;t=Gi(t)}return null}function HO(n,t,e,o){const r=new Gs(n,o),i=mo(o)+1;Ql(n,t,e,{forceInsertAfter:!0,newBlockData:NO(n,o,{start:i})}),r.fix()}function jO(n){var s;if(n.selection.range.isCollapsed()){const l=n.selection.focusedBlock;if(Ht(l)&&ut(n,l)===0)return mc(n,l),!0}n.clearSelectedContents();const t=n.selection.focusedBlock;if(!Ht(t))return!1;const e=n.selection.range.focus;if(!e.isSimple())return!1;const o=e.offset,i=(s=o===ut(n,t)?$O(t):t)!=null?s:t;return HO(n,t,o,i),!0}function v9(n){g(we,Ht(n),"not a list block");const{level:t}=qi(n);let e=ce(n);for(;e;){if(Ht(e)){const{level:o}=qi(e);if(t===o)return e;if(o<t)return null}e=ce(e)}return null}function y9(n,t){return Fe(t),v9(t)?vn(t)<zR:!1}function UO(n,t,e){let o=ce(t);g(we,o,"no prev brother");const r=vn(e);for(;o;){if(o===e)return null;if(Ht(o)&&vn(o)===r+1)return o;o=ce(o)}return null}function k9(n,t){if(!y9(n,t))return!1;Fe(t);const e=v9(t);g(we,e,"no list prev brother");const o=e,r=UO(n,t,o),i=vn(o)+1;let s=K(),l=1,a=Zn(t);r&&(s=ac(r),l=mo(r)+1,a=Zn(r));const d=p0(t),p={...n.getBlockData(t),groupId:s,level:i,start:l,...s0(a)};return n.updateBlockData(t,p),n.doc.beginBatchUpdate(),_O(d).forEach(v=>{const B=n.getBlockData(v);n.updateBlockData(v,{...B,level:B.level+1})}),n.doc.endBatchUpdate(),!0}function zO(n,t,e){return t.length===0||!t.every(o=>Ht(o.block))?!1:e==="increase"?y9(n,t[0].block):A9(n,t[0].block)}function w9(n,t,e){if(!zO(n,t,e))return!1;const o=t[0].block,r=vn(o),i=t.filter(d=>vn(d.block)<=r),s=s9(o,{withSelf:!1}),l=new Set(i.map(d=>d.block)),a=s.filter(d=>!l.has(d));return n.undoManager.runInGroup(()=>{let d=null;a.length>0&&(d=new Gs(n,a[0])),i.forEach(h=>{e==="increase"?k9(n,h.block):C0(n,h.block)}),d==null||d.fix()}),!0}function VO(n,t){return k9(n,t)}function WO(n,t){return C0(n,t)}function qO(n){const t=n.selection.range.getSelectedBlocks();if(t.length>1)return w9(n,t,"increase"),!0;const e=t[0].block;if(!Ht(e))return!1;const o=new ff(n,e);return VO(n,e)&&(o.fix(),new Gs(n,e).fix()),!0}function GO(n){const t=n.selection.range.getSelectedBlocks();if(t.length>1)return w9(n,t,"decrease"),!0;const e=t[0].block;return Ht(e)?(WO(n,e),!0):!1}class ZO{constructor(t){this.editor=t}handleBeforeKeyDown(t,e){const o=t.selection.range.getSelectedBlocks();if(o.length===0||!o.some(i=>Ht(i.block)))return!1;switch(e.key){case"Enter":return this.handleEnter(e);case"Backspace":return this.handleBackspace();case"Tab":return this.handleTab(e);default:return!1}}handleEnter(t){const e=this.editor.selection.range.getSelectedBlocks()[0];return!e.block||!Ht(e.block)||or(t,"Shift+Enter")?!1:this.editor.undoManager.runInGroup(()=>jO(this.editor))}handleBackspace(){return this.editor.undoManager.runInGroup(()=>FO(this.editor))}handleTab(t){return or(t,"Shift+Tab")?this.editor.undoManager.runInGroup(()=>GO(this.editor)):this.editor.undoManager.runInGroup(()=>qO(this.editor))}}class QO{constructor(t){m(this,"effectedBlockIds",new Map);m(this,"handleBeforeClearSelection",()=>{this.effectedBlockIds.clear();const t=this.editor.selection.range.getSelectedBlocks();if(t.length===0)return;const e=new Set;t.forEach(r=>{const i=r.block;Ht(i)&&e.add(i)});const o=new Map;Array.from(e.values()).forEach(r=>{var a;const i=Cu(r),{start:s}=qi(i);o.set(it(i),s);const l=(a=QR(r))!=null?a:r;o.set(it(l),s)}),this.effectedBlockIds=o});m(this,"handleAfterClearSelection",()=>{Array.from(this.effectedBlockIds.entries()).forEach(([t,e])=>{const o=this.editor.findBlockById(t);!o||h0(this.editor,o,e)}),this.effectedBlockIds.clear()});this.editor=t,this.editor.addListener("beforeClearSelection",this.handleBeforeClearSelection),this.editor.addListener("afterClearSelection",this.handleAfterClearSelection)}destroy(){this.editor.removeListener("beforeClearSelection",this.handleBeforeClearSelection),this.editor.removeListener("afterClearSelection",this.handleAfterClearSelection)}}const YO=S("customize-list-start-menu");class JO{constructor(t){m(this,"popup");m(this,"block",null);m(this,"show",(t,e)=>{const o=e.querySelector("div.list-container");g(YO,o,"list-block mark does not exist"),this.block=e,this.popup.manualShow(o,{theme:"light"})});m(this,"createDialogContent",()=>{const t=w("div",["customize-start-panel"],null);w("span",["customize-start-panel-title"],t,R.t("list.numberLabel"));const e=this.createNumericInput();t.appendChild(e);const o=w("button",["customize-start-panel-button"],t,R.t("list.confirm"));return this.editor.domEvents.addEventListener(t,"keydown",this.handleKeydown),this.editor.domEvents.addEventListener(o,"click",this.handleOk),t});m(this,"handleDialogShow",()=>{const t=this.block;if(!t)return;const e=this.popup.popupContent,o=e.querySelector("button.customize-start-panel-button"),r=e.querySelector("input.customize-start-panel-input"),i=mo(t);!o||!r||requestAnimationFrame(()=>{r.focus(),r.value=String(i)})});m(this,"handleOk",()=>{const e=this.popup.popupContent.querySelector("input.customize-start-panel-input"),o=this.block;if(!o)return;const r=Number(e.value);!r||(this.editor.undoManager.runInGroup(()=>{hc(this.editor,[o,...uc(o)],r,{resetGroupId:!0})}),this.popup.close("clickItem"))});m(this,"handleKeydown",(t,e)=>{const o=e;o.isComposing||(o.key==="Escape"?this.popup.close("cancelBar"):o.key==="Enter"&&this.handleOk())});this.editor=t,this.popup=new Xa(this.createDialogContent()),this.popup.on("show",this.handleDialogShow)}destroy(){this.popup.destroy()}createNumericInput(){const t=w("input",["customize-start-panel-input"],null);t.type="number",t.min="1";const e=()=>{const r=t.value.replace(/[^\d]/g,"").replace(/^0+/,""),i=parseInt(r,10);i<=0||Number.isNaN(i)?t.value="":t.value=r};return this.editor.domEvents.addEventListener(t,"input",e),t}}function KO(n,t){return ac(n)===ac(t)}function XO(n,t){const e=r9(t);return e?KO(e,t)?mo(e)!==mo(t)-1:!0:!1}function t_(n,t){return Gi(t)?!0:mo(t)!==1}function e_(n,t){return Fe(t),[{id:"continue-numbering",name:R.t("list.continueList"),states:XO(n,t)?[]:["disabled"]},{id:"start-new-list",name:R.t("list.restartList"),states:t_(n,t)?[]:["disabled"]},{id:"set-numbering-value",name:R.t("list.changeNumber")}]}function n_(n,t,e){var o,r;if(Fe(t),e.id==="continue-numbering"){const i=r9(t);i&&hc(n,[t,...uc(t)],mo(i)+1,{resetGroupId:!0,groupId:ac(i)})}if(e.id==="start-new-list"&&n.undoManager.runInGroup(()=>{hc(n,[t,...uc(t)],1,{resetGroupId:!0})}),e.id==="set-numbering-value"){const i=(o=n.options.componentsOptions)==null?void 0:o.list;if((r=i==null?void 0:i.onChangeStart)!=null&&r.call(i,n,t,e))return;n.addCustom("list-customize-start-dialog",()=>new JO(n)).show(n,t)}}class o_{constructor(t){m(this,"menu");m(this,"handleClick",(t,e)=>{const o=Hl(e,"div.list-container");if(o&&this.editor.isWritable()){const r=et(o);g(we,r,"no parent block"),Fe(r);const i=t.getBlockData(r);if(i&&i.checkbox){t.updateBlockData(r,{...i,checkbox:i.checkbox==="checked"?"unchecked":"checked"});return}if(Zn(r)==="unordered")return;this.menu.updateItems(this.getCommandItems(r)),this.menu.manualShow(o),this.activeList(o,!0)}});m(this,"handleMenuClose",()=>{var e;const t=(e=this.menu.tippyInstance)==null?void 0:e.reference;t&&this.activeList(t,!1)});m(this,"handleMenuClick",(t,e)=>{var r;const o=(r=this.menu.tippyInstance)==null?void 0:r.reference;if(o){const i=et(o);i&&n_(this.editor,i,e)}});this.editor=t,this.editor.addListener("click",this.handleClick),this.menu=new Us([]),this.menu.addListener("close",this.handleMenuClose),this.menu.addListener("click",this.handleMenuClick)}destroy(){this.editor.removeListener("click",this.handleClick),this.menu.removeListener("close",this.handleMenuClose)}getCommandItems(t){return e_(this.editor,t)}activeList(t,e){const o=et(t);!o||(e?(W(t,"active"),W(o,"active")):(ot(t,"active"),ot(o,"active")))}}class r_{constructor(t){this.editor=t}handleBeforeKeyDown(t,e){const o=t.selection.range.getSelectedBlocks();if(o.length===0)return!1;const r=o[0].block;if(!Ht(r)||!u9(r))return!1;if(e.key==="ArrowUp"||e.key==="ArrowLeft"){const i=Is(r);return i&&t.selection.selectBlock(i,ut(t,i)),!0}if(e.key==="ArrowDown"||e.key==="ArrowRight"){const i=Ts(r);return i&&t.selection.selectBlock(i,0),!0}return(e.key==="Delete"||e.key==="Backspace"||e.key==="Escape")&&h9(t,r),!0}}function i_(n,t,e,o,r){tp(n,"list-block-init",()=>{setTimeout(()=>{n.input.addHandler(new r_(n)),n.input.addHandler(new ZO(n)),n.addCustom("list-clear-selection-handler",()=>new QO(n)),n.addCustom("list-marker-menu",()=>new o_(n))})});const i=Dn.createBlockContent(n,t,e,o,r),s=r,{level:l,start:a,groupId:d}=s,h=fc(s);o.setAttribute("data-list-level",`${l}`),o.setAttribute("data-list-start",`${a||1}`),o.setAttribute("data-list-group-id",`${d}`),o.setAttribute("data-list-type",h);const p=OO(s);return o.insertBefore(p,i),s.viewAsMindmap?setTimeout(()=>{const A=n.getBlockById(r.id);A&&df(n,A,{},{mindmapTools:d0,saveData:!1})}):setTimeout(()=>{const A=n.getBlockById(r.id);A&&d9(n,A)}),i}const s_={list:{confirm:"\u786E\u5B9A",setStart:"\u8BBE\u7F6E\u7F16\u53F7",continueList:"\u7EE7\u7EED\u7F16\u53F7",restartList:"\u5F00\u59CB\u65B0\u5217\u8868",changeNumber:"\u4FEE\u6539\u7F16\u53F7\u503C",numberLabel:"\u7F16\u53F7\u987A\u5E8F",mention:{tooltip:"\u63D0\u53CA\u4EBA\u5458\u5E76\u901A\u77E5"}},mindmap:{viewAsMindMap:"\u663E\u793A\u4E3A\u8111\u56FE",autoFit:"\u81EA\u52A8\u7F29\u653E",fullScreen:"\u5168\u5C4F\u67E5\u770B",close:"\u5173\u95ED",exitFullscreen:"\u9000\u51FA\u5168\u5C4F"}},l_={list:{confirm:"Confirm",setStart:"Set number",continueList:"Continue numbering",restartList:"Start a new list",changeNumber:"Set numbering value",numberLabel:"Numbering order",mention:{tooltip:"Mention and notify users"}},mindmap:{viewAsMindMap:"View as MindMap",autoFit:"Auto zoom",fullScreen:"Full screen",close:"Close",exitFullscreen:"Exit full screen"}},c_={list:{confirm:"OK",setStart:"\u756A\u53F7\u3092\u8A2D\u5B9A",continueList:"\u9023\u756A\u3092\u8A2D\u5B9A",restartList:"\u65B0\u3057\u3044\u30EA\u30B9\u30C8\u3092\u4F5C\u6210",changeNumber:"\u756A\u53F7\u3092\u7DE8\u96C6",numberLabel:"\u756A\u53F7",mention:{tooltip:"\u30E1\u30F3\u30B7\u30E7\u30F3\u304A\u3088\u3073\u901A\u77E5"}},mindmap:{viewAsMindMap:"\u30DE\u30A4\u30F3\u30C9\u30DE\u30C3\u30D7\u3067\u8868\u793A",autoFit:"\u81EA\u52D5\u30D5\u30A3\u30C3\u30C8",fullScreen:"\u5168\u753B\u9762\u8868\u793A\u306E\u30AA\u30F3",close:"\u9589\u3058\u308B",exitFullscreen:"\u5168\u753B\u9762\u8868\u793A\u306E\u30AA\u30D5"}};R.mergeLang({"zh-CN":s_,"en-US":l_,"ja-JP":c_});const Int="",B9={...Dn,blockType:"list",createBlockContent:i_,convertFrom:SO,convertTo:MO,handleDrop:vO,notify:pO},A0=S("paragraph");class a_{constructor(t){m(this,"id","BlockParagraphProvider");this.editor=t}isChecked(t,e){return!!(t[e]||t.level&&(t.ordered===!0&&!t.checkbox&&e==="ordered-list"||t.ordered===!1&&!t.checkbox&&e==="unordered-list")||e==="check-list"&&t.checkbox)}getAvailableCommands(t,e){const o=[],r={"unordered-list":[R.t("commands.unordered"),xo("CtrlOrCmd+Shift+L"),CL],"ordered-list":[R.t("commands.ordered"),xo("CtrlOrCmd+Shift+U"),pL],"check-list":[R.t("commands.check"),void 0,AL],link:[R.t("commands.link"),xo("CtrlOrCmd+K"),av],quoted:[R.t("commands.quote"),void 0,bL]};if(tt(t,e)){const i=it(e),s=Dt(e),l=Do(t,e),a=t.getBlockData(e);Object.entries(r).forEach(([d,[h,p,A]])=>{const v=[];if(this.isChecked(a,d)&&v.push("checked"),d==="link"){if(!t.selection.range.isSimple())return;t.selection.range.getSelectedBlocks().length!==1&&v.push("disabled")}o.push({blockId:i,blockType:s,blockKind:l,id:d,name:h,desc:p,states:v,icon:A,groupIndex:600})})}return o}convertLink(t,e,o){g(A0,Ur(e.start),""),g(A0,Ur(e.start),"");const r="bottom-start",i=e.start.offset,s=e.end.offset,l=(v,B)=>{t.undoManager.runInGroup(()=>{try{const D=t.selection.range.isCollapsed();let x;if(D){x=Vr(t.getBlockText(o),s,v,{link:B}),t.setBlockText(o,x);return}x=fh(t.getBlockText(o),i,s,v),x=Ia(i,v.length,x,"link",B),t.setBlockText(o,x),t.selection.selectBlock(o,i+v.length),t.focus()}catch(D){A0.error(D)}})},a=()=>{t.selection.selectBlock(o,s),t.focus()},d=Nr(t,o,e)[0];if(!d)return;const h=zr(t,o,"link-button-anchor",d),p=t.getBlockText(o),A=Ta(p,i);gu(t,{target:h,linkText:t.getSelectedText(),linkUrl:(A==null?void 0:A.link)||"",onFinished:l,onClose:a,placement:r})}convertToList(t,e,o){const r=th(t,e,"list",{offset:0,data:{listType:o}});r&&t.undoManager.runInGroup(()=>{const i=bt(e),s=nt(e);t.insertBlock(ct(s),i,r.blockData),t.deleteBlock(e),t.focus()})}executeCommand(t,e,o,r){var a;if(!tt(t,e))return!1;const i=r.id,s=(a=r.states)==null?void 0:a.includes("checked");let l=!1;if(i==="unordered-list"&&(s?mc(t,e):this.convertToList(t,e,"unordered"),l=!0),i==="ordered-list"&&(s?mc(t,e):this.convertToList(t,e,"ordered"),l=!0),i==="check-list"&&(s?mc(t,e):this.convertToList(t,e,"unchecked"),l=!0),i==="quoted"){const h=t.getBlockData(e).quoted;t.updateBlockData(e,{quoted:h?void 0:!0}),t.focus(),l=!0}if(i==="link"){const d=lf(t);d==null||d.disableTextToolbar(),d==null||d.hide(),setTimeout(()=>{d==null||d.enableTextToolbar()},1e3),this.convertLink(t,o,e),l=!0}return l}}const u_={left:tu,right:Ip,center:Tp};class d_{constructor(t){m(this,"id","BlockAlignProvider");this.editor=t}applyAlignStyle(t,e,o){Object.keys(u_).includes(o)?t.updateBlockData(e,{align:o}):t.updateBlockData(e,{align:null})}isChecked(t,e){return t.align===e}getAvailableCommands(t,e,o){if(tt(t,e)){const r=it(e),i=Dt(e),s=Do(t,e),l=t.getBlockData(e),a=d=>{var p;const h=w("span",["toolbar-item-name-container"],null);for(const A of d.children)if((p=A.states)!=null&&p.includes("checked"))return h.innerHTML=A.icon||tu,h;return h.innerHTML=tu,h};return[{id:"align",name:R.t("commands.alignGroup"),blockId:r,blockType:i,blockKind:s,groupIndex:700,dropdown:!0,element:a,manualShowChildren:!0,childrenPlacement:"bottom-start",defaultCheckedChildren:["align-left"],children:[{id:"align-left",name:R.t("commands.alignLeft"),icon:tu,states:this.isChecked(l,"left")?["checked"]:[]},{id:"align-center",name:R.t("commands.alignCenter"),icon:Tp,states:this.isChecked(l,"center")?["checked"]:[]},{id:"align-right",name:R.t("commands.alignRight"),icon:Ip,states:this.isChecked(l,"right")?["checked"]:[]}],childrenType:"menu"}]}return[]}executeCommand(t,e,o,r){if(!tt(t,e))return!1;if(r.id.startsWith("align")){const i=r.id.replace(/^align-/,"");return this.applyAlignStyle(t,e,i),this.editor.focus(),!0}return!1}}function h_(n){const e=n.selection.range;if(e.isCollapsed()||e.start.blockId!==e.end.blockId||!e.start.isSimple()||!e.end.isSimple()||e.end.offset-e.start.offset!==1)return!1;const o=n.getBlockById(e.start.blockId);return Sa(n,o,e.start.offset).charType==="box"}const f_=S("toolbar-handler"),m_={id:"",name:"",type:"separator"};class gc{constructor(t){m(this,"toolbar");m(this,"toolbarType","object");m(this,"mouseDown",!1);m(this,"oldRange",null);m(this,"hoveringBlock",null);m(this,"hoveringTextChild",null);m(this,"_disableTextToolbar",!1);m(this,"handleButtonClick",(t,e)=>{this.toolbarType==="text"?(this.editor.editorCommandProviders.executeCommand(this.editor.selection.range,e,{}),this.showTextToolbar("click")):this.hoveringBlock&&$R(this.editor,this.hoveringBlock,this.hoveringTextChild,e)});m(this,"handleClose",()=>{Op(this.editor)&&this.editor.focus()});m(this,"handleClosing",(t,e)=>{if(this.toolbarType==="object"){const o=oC(e);if(this.hoveringBlock===o)return!1}return!0});m(this,"handleDocumentMouseDown",t=>{t.button===0&&(document.addEventListener("mouseup",this.handleDocumentMouseUp),this.mouseDown=!0)});m(this,"handleDocumentMouseUp",()=>{document.removeEventListener("mouseup",this.handleDocumentMouseUp),this.mouseDown=!1,this.handleSelectionChange(this.editor)});m(this,"handleHoveringBlockChildChange",(t,e,o,r)=>{if(!(this.hoveringBlock===t&&this.hoveringTextChild===e)&&(this.hoveringBlock=t,this.hoveringTextChild=e,!(this.toolbar.isVisible&&this.toolbarType==="text"))){if(!t){this.toolbar.close("fromHover");return}this.showObjectToolbar(r)}});m(this,"handleSelectionChange",Le.default(t=>{var o;if(g(f_,t===this.editor,"editor mismatch"),t.selection.range.isCollapsed()||this.mouseDown){if(this.toolbarType==="object"){const r=(o=this.toolbar.tippyInstance)==null?void 0:o.reference,i=this.editor.selection.focusedBlock;if(r&&Xt(r,i))return}this.toolbar.close("selectionChange"),this.oldRange=null;return}if(!this.editor.isWritable()){this.toolbar.close("selectionChange"),this.oldRange=null;return}if(t.selection.range.getSelectedBlocks().length===0){this.toolbar.close("selectionChange"),this.oldRange=null;return}this.oldRange&&this.oldRange.isEqual(t.selection.range)||(this.oldRange=t.selection.range,this.showTextToolbar("selectionChange"))},50));this.editor=t;const e=t.options.componentsOptions.popover;this.toolbar=new ou([],void 0,{tooltipId:t.clientId,id:"editor-toolbar",overflowBoundary:e==null?void 0:e.overflowBoundary,refuseOverflow:!0,padding:20}),this.toolbar.on("click",this.handleButtonClick),this.toolbar.on("close",this.handleClose),this.toolbar.on("closing",this.handleClosing),this.bindEvents(),t.addListener("selectionChanged",this.handleSelectionChange),Ce.get(t).addListener("childChange",this.handleHoveringBlockChildChange),Ce.get(t).addFilter(this),t.editorCommandProviders.registerCommandProvider(new jR(t)),t.editorCommandProviders.registerCommandProvider(new a_(t)),t.editorCommandProviders.registerCommandProvider(new d_(t))}disableTextToolbar(){this._disableTextToolbar=!0}enableTextToolbar(){this._disableTextToolbar=!1}hide(){this.toolbar.close("selectionChange")}destroy(){this.unbindEvents(),this.toolbar.destroy(),this.editor.removeListener("selectionChanged",this.handleSelectionChange),Ce.get(this.editor).removeListener("childChange",this.handleHoveringBlockChildChange)}isInBlock(t,e){return t!==this.hoveringBlock?!1:!!(e.target&&e.target instanceof Node&&this.toolbar.popper&&Xt(this.toolbar.popper,e.target))}bindEvents(){document.addEventListener("mousedown",this.handleDocumentMouseDown)}unbindEvents(){document.removeEventListener("mousedown",this.handleDocumentMouseDown)}update(t){this.showTextToolbar(t)}showTextToolbar(t){var D,x;if(this._disableTextToolbar||!this.editor.isWritable())return;const o=this.editor.selection.range.getSelectedBlocks();if(o.length===0)return;const r=o[0];if(!r)return;if(o.length===1&&Me(r.block)){t==="click"&&this.showObjectToolbar(null);return}if(h_(this.editor))return;if(nt(r.block)===this.editor.rootContainer&&bt(r.block)===0){this.toolbar.close("selectionChange");return}const i=this.editor.editorCommandProviders.getCommands(this.editor.selection.range),s=new Map;i.forEach(_=>{const M=_.groupIndex,H=s.get(M);H?H.push(_):s.set(M,[_])});const l=[[]],a=Array.from(s.entries()).sort((_,M)=>_[0]-M[0]);for(let _=0;_<a.length;_++){const[,M]=a[_];if(M.length===0)continue;let H=l[l.length-1];H.length>0&&H[H.length-1].groupIndex!==M[M.length-1].groupIndex&&(H=[],l.push(H)),H.push(...sf(M))}if(l.length===0){this.toolbar.close("selectionChange");return}this.toolbarType="text";const d=[];if(l.forEach((_,M)=>{const H=_.sort((z,q)=>{var rt,ft;return((rt=z.order)!=null?rt:0)-((ft=q.order)!=null?ft:0)});d.push(...H),M!==l.length-1&&d.push(m_)}),d.length===0){this.toolbar.close("selectionChange");return}this.toolbar.updateItems(d);const h=o[o.length-1],p=!this.editor.selection.range.isReverse()&&h!==r,A=p?h:r,v=LR(this.editor,A),B=zr(this.editor,A.block,"editor-quick-menu",v);this.toolbar.manualShow(B,{placement:p?"bottom":"top",offset:[0,p?5:10]}),(x=(D=this.toolbar.tippyInstance)==null?void 0:D.popperInstance)==null||x.update()}showObjectToolbar(t){var l,a,d;if(!this.hoveringBlock||this.mouseDown)return;const e=this.hoveringBlock,o=this.hoveringTextChild,{commands:r,element:i}=FR(this.editor,e,o);if(!r.length||!i){this.toolbar.close("fromHover");return}this.toolbarType="object",this.toolbar.isVisible&&((a=(l=this.toolbar)==null?void 0:l.tippyInstance)==null?void 0:a.reference)!==i&&this.toolbar.close("fromHover");const s=()=>{let h;const p=i.getClientRects();if(p.length>1){if(h=o?p[p.length-1]:p[0],t)for(let A=0;A<p.length;A++){const v=p[A],B=new DOMRect(v.x-4,v.y-4,v.width+8,v.height+8);if(B.x<t.clientX&&t.clientX<B.right&&B.y<t.clientY&&t.clientY<B.bottom){h=v;break}}}else{if(h=i.getBoundingClientRect(),o){const A=o.getBoundingClientRect();return new DOMRect(A.x,A.y,A.width,A.height)}return new DOMRect(p[0].x,p[0].y,p[0].width,p[0].height)}if(t){const A=h.y,v=t.clientX;return new DOMRect(v,A,10,h.height)}return h};this.toolbar.updateItems(r),this.toolbar.isVisible||(this.toolbar.manualShow(i,{placement:o?"bottom":"top",getReferenceClientRect:s}),(d=this.toolbar.tippyInstance)!=null&&d.popper&&(this.toolbar.tippyInstance.popper.style.paddingTop="10px",this.toolbar.tippyInstance.popper.style.paddingBottom="5px"))}static register(t){return t.addCustom("toolbar-handler",e=>new gc(e))}static get(t){return t.getCustom("toolbar-handler")}}function pf(n,t,e){n.getBlockData(t).heading===e?n.updateBlockData(t,{heading:null}):n.updateBlockData(t,{heading:e})}function E9(n,t,e){["left","center","right"].includes(e)?n.updateBlockData(t,{align:e}):n.updateBlockData(t,{align:null})}function b0(n,t){const o=n.getBlockData(t).quoted;n.updateBlockData(t,{quoted:o?void 0:!0})}function v0(n,t){return!!(n[t]||n.level&&(n.ordered===!0&&!n.checkbox&&t==="ordered-list"||n.ordered===!1&&!n.checkbox&&t==="unordered-list")||t==="check-list"&&n.checkbox)}function y0(n,t,e){if(!n.selection.range.focus.isSimple())return;const r=n.getBlockData(t);let i;switch(e){case"unordered-list":i=v0(r,"unordered-list")?void 0:"unordered";break;case"ordered-list":i=v0(r,"ordered-list")?void 0:"ordered";break;case"check-list":i=v0(r,"check-list")?void 0:"unchecked";break}if(i){const s=th(n,t,"list",{offset:0,data:{listType:i}});s&&n.undoManager.runInGroup(()=>{const l=bt(t),a=nt(t);n.deleteBlock(t),n.insertBlock(ct(a),l,s.blockData)})}else mc(n,t)}const g_=Object.freeze(Object.defineProperty({__proto__:null,applyHeadingStyle:pf,applyAlignStyle:E9,applyQuoteStyle:b0,applyList:y0},Symbol.toStringTag,{value:"Module"})),p_=[bp,vp,yp,kp,wp,Bp,Ep,xp],C_={Unordered:hv,Ordered:fv,Checkbox:uv,Quote:dv};function x9(n,t){const e=n;e.blockOptions=t,e.itemType="insert-block",n.children&&n.children.forEach(o=>x9(o,t))}function A_(){return{name:"basic",insertBlockCommandItems:[{id:"text",icon:nu,name:R.t("commands.text"),order:0,group:"basics",value:"text"}]}}function k0(n=1){var r;const t={name:"basic",insertBlockCommandItems:[]};let e=cf();e<=4?e=5:e<8&&(e+=1);let o=n;for(;o<=e;){const i=`heading-${o}`;(r=t.insertBlockCommandItems)==null||r.push({id:i,icon:p_[o-1],name:R.t("quickMenu.basic.heading.title",{heading:String(o)}),order:o,group:"basics",value:String(o),subText:An(i)}),o++}return t}function b_(){const n={name:"basic",insertBlockCommandItems:[]};return["Unordered","Ordered","Checkbox","Quote"].forEach((e,o)=>{var i;const r=`insert-${e.toLocaleLowerCase()}`;(i=n.insertBlockCommandItems)==null||i.push({id:r,name:R.t(`quickMenu.basic.${e.toLocaleLowerCase()}`),icon:C_[e],value:e.toLocaleLowerCase(),group:"basics",order:10+o,subText:An(r)})}),n}class I9{constructor(t){this.withPlainText=t}getCommands(){const t=A_(),e=k0(),o=b_();return[...this.withPlainText?t.insertBlockCommandItems||[]:[],...e.insertBlockCommandItems||[],...o.insertBlockCommandItems||[]]}updateBlock(t,e,o,r){const{value:i,id:s}=r;return s.startsWith("heading-")?pf(t,o,Number.parseInt(i!=null?i:"1",10)||1):i==="ordered"||i==="unordered"||i==="checkbox"?y0(t,o,{ordered:"ordered-list",unordered:"unordered-list",checkbox:"check-list"}[i]):i==="quote"&&b0(t,o),null}async handleUpdateBlockCore(t,e){const o=t.getBlockByIndex(e.containerId,e.blockIndex);return this.updateBlock(t,e.containerId,o,e.item)}async handleInsertEmptyBlockCore(t,e){const{containerId:o,blockIndex:r}=e,i=t.insertTextBlock(void 0,o,r);return this.updateBlock(t,e.containerId,i,e.item)}async executeCommand(t,e,o){if(o.from==="quick-menu"){const r=t.getBlockById(o.blockId),i=t.getParentContainer(r),s=ct(i),l=t.getBlockIndex(r);t.undoManager.runInGroup(()=>this.handleUpdateBlockCore(t,{item:e,containerId:s,blockIndex:l})),t.focus()}else o.from==="block-menu"&&(t.undoManager.runInGroup(()=>this.handleInsertEmptyBlockCore(t,{item:e,containerId:o.containerId,blockIndex:o.blockIndex})),t.focus());return null}}const T9={basics:100,system:200,common:300,thirdParty:400};class w0{constructor(){m(this,"dataUrl","");m(this,"error",null)}destroy(){}setDataUrl(t){this.error=null,this.dataUrl=t}setError(t){this.dataUrl="",this.error=t}}const v_=S("mathjax-converter"),y_="MathJax-script";async function k_(n){var o;window.MathJax||(window.MathJax={options:{skipHtmlTags:["script","noscript","style","textarea","pre","code","annotation","annotation-xml","body"]}});const t=n.getComponentOptions("mathjax"),e=((o=t==null?void 0:t.cdn)==null?void 0:o.mathjax)||"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js";await bs(e,y_)}function w_(){try{window.MathJax&&window.MathJax.texReset()}catch{}}async function D9(n,t){const e="mathjax2Svg";try{await Eo.lock(e),w_(),await k_(n);const o=await window.MathJax.tex2svgPromise(t),r=o.querySelector("merror");if(r)throw new Error(r.textContent);return o.querySelector("svg").outerHTML}catch(o){throw v_.error(o),o}finally{Eo.release(e)}}async function S9(n,t){const e=await D9(n,t);return e?await Im(e,"image/svg+xml"):""}async function B0(n,t){const o=await D9(n,t),r=new File([o],"math.svg");return(await n.doc.uploadResource(r)).resourceId}const L9=S("edit-mathjax");class B_{constructor(){m(this,"editMathjaxPopup",null);m(this,"onChange",null);m(this,"tex","");m(this,"handleShow",()=>{setTimeout(()=>{this.getTextarea().focus()})});m(this,"handleClose",t=>{var o;const e=t.content.querySelector("textarea");if(e){const r=e.value;r!==this.tex&&((o=this.onChange)==null||o.call(this,r,!0))}});m(this,"handleKeyup",t=>{var e;t.isComposing||(t.key==="Escape"&&((e=this.editMathjaxPopup)==null||e.close("cancelBar")),this.handleChange(t.target.value))});m(this,"handleChange",Le.default(t=>{var e;(e=this.onChange)==null||e.call(this,t,!1)},300))}editMathjax(t,e,o){if(!this.editMathjaxPopup)this.editMathjaxPopup=new Xa(this.createPopupContent(e));else{const r=this.getTextarea();r.value=e}this.tex=e,this.editMathjaxPopup.addListener("show",this.handleShow),this.editMathjaxPopup.manualShow(t,{theme:"light"}),this.editMathjaxPopup.removeAllListeners("close"),this.editMathjaxPopup.addListener("close",this.handleClose),this.onChange=o}createPopupContent(t){const e=w("textarea",["mathjax-editor-textarea"],null);return e.value=t,e.addEventListener("keyup",this.handleKeyup),e}getTextarea(){g(L9,this.editMathjaxPopup,"no exists mathjax editor popup");const t=this.editMathjaxPopup.content.querySelector("textarea");return g(L9,t,"no textarea"),t}destroy(){var t;this.onChange=null,(t=this.editMathjaxPopup)==null||t.removeAllListeners()}}function M9(n,t,e,o){n.addCustom("mathjax-editor",()=>new B_).editMathjax(t,e.trim(),o)}function R9(){return{insert:" ",attributes:{id:K(),box:!0,type:"math",tex:" ",src:"",created:Date.now()}}}function Cf(n,t){const e=n.getBoxData(t),o=et(t);if(!o)return;const r=Os(o,t);n.selection.selectBlock(o,r.start,r.end);const i=async(s,l)=>{if(!s.trim()){n.updateBoxData({...e,tex:s,src:null});return}try{await Eo.lock("convertAndUploadMathjax");const a=await B0(n,s);n.updateBoxData({...e,tex:s,src:a})}catch(a){const d=n.getBoxData(t);n.addCustom(`mathjax-box-${d.id}`,()=>new w0).setError(a),n.updateBoxData({...e,tex:s,src:""})}finally{Eo.release("convertAndUploadMathjax"),l&&n.focus()}};M9(n,t,e.tex,i)}const O9=S("mathjax-box");function E0(n,t){n.selection.updateSelection(null);const e=t.target;!e||!(e instanceof HTMLElement)||n.domEvents.removeEventListener(e,null,E0)}async function E_(n,t,e){try{if(!t.tex.trim())return;const o=await S9(n,t.tex),r=n.findBoxById(t.id);if(!r)return;const i=Pm(r);i.innerHTML="";const s=w("img",["mathjax"],i);s.src=o,e.setDataUrl(o),n.domEvents.addEventListener(s,"load",E0)}catch(o){e.setError(o);const r=n.findBoxById(t.id);if(!r)return;const i=r.querySelector(".mathjax-tex-text");W(i,"mathjax-error"),i.innerText=o.message,n.selection.updateSelection(null)}}function x_(n,t,e,o){const r=o,i=n.addCustom(`mathjax-box-${r.id}`,()=>new w0);if(r.src||i.dataUrl){const a=w("img",["mathjax"],e);a.src=n.doc.buildResourceUrl(r.src||i.dataUrl),n.domEvents.addEventListener(a,"load",E0);return}const s=["mathjax-tex-text"];let l=r.tex;l.trim()?i.error&&(l=i.error.message,s.push("mathjax-error")):l=R.t("mathjax.emptyText"),w("span",s,e,l),E_(n,r,i)}function I_(n,t){const e={id:K(),box:!0,type:"math",tex:t,src:"",created:Date.now()};return B0(n,t).then(o=>{if(!n.findBoxById(e.id))return;const i={...e,src:o};n.updateBoxData(i)}).catch(o=>{O9.error(`failed to convert and upload mathjax: ${JSON.stringify(o)}`)}),e}function T_(n,t,e,o){const r=t;return o==="text"?r.tex:o==="markdown"?` $${r.tex}$ `:r.src?`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`:`<code>$${r.tex}$</code>`}function D_(n,t,e){const o=et(t);g(O9,o,"failed to get block"),!(n.readonly||!n.isBlockWritable(o))&&Cf(n,t)}function S_(){return{abstract:R.t("mathjax.abstract")}}const _9={boxType:"math",updateBoxContent:x_,convertFrom:I_,convertTo:T_,handleClickBox:D_,getBoxProperties:S_};async function L_(n,t,e){try{const o=t.embedData,r=await S9(n,o.mathjaxText),i=n.findBlockById(t.id);if(!i)return;const s=Lt(i);s.innerHTML="";const l=w("img",["mathjax"],s);l.src=r,e.setDataUrl(r)}catch(o){e.setError(o)}}function M_(n,t){if(n.readonly||!t.target||!(t.target instanceof Node))return;const e=et(t.target);if(!e||!Me(e)||fn(e)!=="math")return;const o=Lt(e),r=o.querySelector("img")||o.querySelector("span.mathjax-tex-text");if(!r||!Xt(r,t.target))return;const s=n.getBlockData(e).embedData;M9(n,r,s.mathjaxText,async l=>{const a=await B0(n,l),d={mathjaxText:l,src:a};n.updateEmbedData(e,d)})}function R_(n,t,e){const o=e.embedData,r=n.addCustom(`mathjax-block-${e.id}`,()=>new w0);if(n.domEvents.addEventListener(t,"click",M_),o.src||r.dataUrl){const i=w("img",["mathjax"],t);i.src=n.doc.buildResourceUrl(o.src||r.dataUrl);return}r.error,w("span",["mathjax-tex-text"],t,o.mathjaxText),L_(n,e,r)}function O_(n,t,e){if(!tt(n,t))return null;const o=n.getBlockString(t).trim();if(!o||!o.startsWith("$$")||!o.endsWith("$$"))return null;const r=km(o,"$");if(!r)return null;const i={mathjaxText:r,src:""};return{blockData:{id:K(),type:"embed",embedType:"math",embedData:i}}}function __(n){return{name:"Mathjax"}}function F_(n,t){const e=Lt(t);n.domEvents.removeAllListeners(e)}function P_(n,t,e,o){const r=t.embedData;return o==="html"?`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`:o==="markdown"?`
397
+ `)),d}if(o==="html"){let d=((a=Dn.convertTo)==null?void 0:a.call(Dn,n,t,e,"html",r))||"";d=d.replace("<p>","").replace("</p>",""),i.checkbox==="checked"?d=`<input type="checkbox" checked="checked" disabled="disabled" /> ${d}`:i.checkbox==="unchecked"&&(d=`<input type="checkbox" disabled="disabled" /> ${d}`);let h="ul";return i.ordered?(d=`<li value="${i.start}">${d}</li>`,h="ol"):d=`<li>${d}</li>`,m9(n,t,e,r)&&(d=`<${h}>${d}`),g9(n,t,e,r)&&(d=`${d}</${h}>`),d}return""}function p9(n){const t=w("label",["editor-check-list-wrapper"],null);n&&W(t,"editor-check-list-wrapper-checked");const e=w("span",["editor-check-box"],t);return w("span",["editor-check-box-inner"],e),t}function RO(n,t){const e=fc(t);if(e!=="text-only"){if(e==="checked"){n.append(p9(!0));return}if(e==="unchecked"){n.append(p9(!1));return}n.innerText=LO(t)}}function OO(n){const t=w("div",["list-container"],null),e=w("button",["list-marker"],t);return RO(e,n),t}function C9(n){let t=Zt(n);if(!t)return null;const e=qs(n);for(;t!==e;){if(g(we,t,"no next block"),Ht(t))return vn(t)>vn(n)?t:null;if(t=Zt(t),!t)return null}return null}function p0(n){const t=[];let e=C9(n);if(!e)return t;for(;e;){const o=qs(e);t.push({block:e,children:p0(e)}),e=o}return t}function _O(n){const t=(o,r)=>{r.push(o.block),o.children.forEach(i=>t(i,r))},e=[];return n.forEach(o=>t(o,e)),e}function A9(n,t){return vn(t)!==1}function b9(n,t,e){t.forEach(o=>{const r=n.getBlockData(o.block);n.updateBlockData(o.block,{...r,groupId:e,level:r.level-1}),o.children.length&&b9(n,o.children,r.groupId)})}function C0(n,t){if(!A9(n,t))return!1;const e=vn(t);if(e===1)return!1;let o=K(),r=1,i=Zn(t);const s=e-1,l=l0(t);l&&(o=ac(l),r=mo(l)+1,i!=="text-only"&&(i=Zn(l)));const a=p0(t),d=n.getBlockData(t),h={...d,groupId:o,level:s,start:r,...s0(i)};n.updateBlockData(t,h),n.doc.beginBatchUpdate(),b9(n,a,d.groupId),n.doc.endBatchUpdate(),new Gs(n,t).fix();const A=C9(t);return A&&new Gs(n,A,{resetStart:!0,resetGroupId:!0}).fix(),!0}function mc(n,t){Fe(t);const e=n.getBlockData(t),o={id:K(),type:"text",text:e.text};e.heading&&(o.heading=e.heading),e.heading&&(o.heading=e.heading);const r=new ff(n,t),i=nt(t),s=bt(t);n.deleteBlock(t);const l=ph(o.id,0);if(wa(n,i)&&!Yt(i)){n.insertBlock(ct(i),s,o,l);const a=ye(i);n.deleteBlock(a)}else n.insertBlock(ct(i),s,o,l);r.fix()}function FO(n){if(!n.selection.range.isCollapsed())return!1;const t=n.selection.focusedBlock;if(!Ht(t))return!1;const e=n.selection.range.focus;return!e.isSimple()||e.offset!==0?!1:vn(t)===1?(mc(n,t),!0):(C0(n,t),!0)}const PO=S("list-block");function NO(n,t,e){g(PO,Ht(t),"not a list block");const o={...n.getBlockData(t),id:K()};return e!=null&&e.level&&(o.level=e.level),e!=null&&e.start&&(o.start=e.start),e!=null&&e.keepText||delete o.text,(o==null?void 0:o.checkbox)==="checked"&&(o.checkbox="unchecked"),o}function $O(n){if(Fe(n),!uf(n))return n;let t=Gi(n);for(;t;){if(!uf(t))return t;t=Gi(t)}return null}function HO(n,t,e,o){const r=new Gs(n,o),i=mo(o)+1;Ql(n,t,e,{forceInsertAfter:!0,newBlockData:NO(n,o,{start:i})}),r.fix()}function jO(n){var s;if(n.selection.range.isCollapsed()){const l=n.selection.focusedBlock;if(Ht(l)&&ut(n,l)===0)return mc(n,l),!0}n.clearSelectedContents();const t=n.selection.focusedBlock;if(!Ht(t))return!1;const e=n.selection.range.focus;if(!e.isSimple())return!1;const o=e.offset,i=(s=o===ut(n,t)?$O(t):t)!=null?s:t;return HO(n,t,o,i),!0}function v9(n){g(we,Ht(n),"not a list block");const{level:t}=qi(n);let e=ce(n);for(;e;){if(Ht(e)){const{level:o}=qi(e);if(t===o)return e;if(o<t)return null}e=ce(e)}return null}function y9(n,t){return Fe(t),v9(t)?vn(t)<zR:!1}function UO(n,t,e){let o=ce(t);g(we,o,"no prev brother");const r=vn(e);for(;o;){if(o===e)return null;if(Ht(o)&&vn(o)===r+1)return o;o=ce(o)}return null}function k9(n,t){if(!y9(n,t))return!1;Fe(t);const e=v9(t);g(we,e,"no list prev brother");const o=e,r=UO(n,t,o),i=vn(o)+1;let s=K(),l=1,a=Zn(t);r&&(s=ac(r),l=mo(r)+1,a=Zn(r));const d=p0(t),p={...n.getBlockData(t),groupId:s,level:i,start:l,...s0(a)};return n.updateBlockData(t,p),n.doc.beginBatchUpdate(),_O(d).forEach(v=>{const B=n.getBlockData(v);n.updateBlockData(v,{...B,level:B.level+1})}),n.doc.endBatchUpdate(),!0}function zO(n,t,e){return t.length===0||!t.every(o=>Ht(o.block))?!1:e==="increase"?y9(n,t[0].block):A9(n,t[0].block)}function w9(n,t,e){if(!zO(n,t,e))return!1;const o=t[0].block,r=vn(o),i=t.filter(d=>vn(d.block)<=r),s=s9(o,{withSelf:!1}),l=new Set(i.map(d=>d.block)),a=s.filter(d=>!l.has(d));return n.undoManager.runInGroup(()=>{let d=null;a.length>0&&(d=new Gs(n,a[0])),i.forEach(h=>{e==="increase"?k9(n,h.block):C0(n,h.block)}),d==null||d.fix()}),!0}function VO(n,t){return k9(n,t)}function WO(n,t){return C0(n,t)}function qO(n){const t=n.selection.range.getSelectedBlocks();if(t.length>1)return w9(n,t,"increase"),!0;const e=t[0].block;if(!Ht(e))return!1;const o=new ff(n,e);return VO(n,e)&&(o.fix(),new Gs(n,e).fix()),!0}function GO(n){const t=n.selection.range.getSelectedBlocks();if(t.length>1)return w9(n,t,"decrease"),!0;const e=t[0].block;return Ht(e)?(WO(n,e),!0):!1}class ZO{constructor(t){this.editor=t}handleBeforeKeyDown(t,e){const o=t.selection.range.getSelectedBlocks();if(o.length===0||!o.some(i=>Ht(i.block)))return!1;switch(e.key){case"Enter":return this.handleEnter(e);case"Backspace":return this.handleBackspace();case"Tab":return this.handleTab(e);default:return!1}}handleEnter(t){const e=this.editor.selection.range.getSelectedBlocks()[0];return!e.block||!Ht(e.block)||or(t,"Shift+Enter")?!1:this.editor.undoManager.runInGroup(()=>jO(this.editor))}handleBackspace(){return this.editor.undoManager.runInGroup(()=>FO(this.editor))}handleTab(t){return or(t,"Shift+Tab")?this.editor.undoManager.runInGroup(()=>GO(this.editor)):this.editor.undoManager.runInGroup(()=>qO(this.editor))}}class QO{constructor(t){m(this,"effectedBlockIds",new Map);m(this,"handleBeforeClearSelection",()=>{this.effectedBlockIds.clear();const t=this.editor.selection.range.getSelectedBlocks();if(t.length===0)return;const e=new Set;t.forEach(r=>{const i=r.block;Ht(i)&&e.add(i)});const o=new Map;Array.from(e.values()).forEach(r=>{var a;const i=Cu(r),{start:s}=qi(i);o.set(it(i),s);const l=(a=QR(r))!=null?a:r;o.set(it(l),s)}),this.effectedBlockIds=o});m(this,"handleAfterClearSelection",()=>{Array.from(this.effectedBlockIds.entries()).forEach(([t,e])=>{const o=this.editor.findBlockById(t);!o||h0(this.editor,o,e)}),this.effectedBlockIds.clear()});this.editor=t,this.editor.addListener("beforeClearSelection",this.handleBeforeClearSelection),this.editor.addListener("afterClearSelection",this.handleAfterClearSelection)}destroy(){this.editor.removeListener("beforeClearSelection",this.handleBeforeClearSelection),this.editor.removeListener("afterClearSelection",this.handleAfterClearSelection)}}const YO=S("customize-list-start-menu");class JO{constructor(t){m(this,"popup");m(this,"block",null);m(this,"show",(t,e)=>{const o=e.querySelector("div.list-container");g(YO,o,"list-block mark does not exist"),this.block=e,this.popup.manualShow(o,{theme:"light"})});m(this,"createDialogContent",()=>{const t=w("div",["customize-start-panel"],null);w("span",["customize-start-panel-title"],t,R.t("list.numberLabel"));const e=this.createNumericInput();t.appendChild(e);const o=w("button",["customize-start-panel-button"],t,R.t("list.confirm"));return this.editor.domEvents.addEventListener(t,"keydown",this.handleKeydown),this.editor.domEvents.addEventListener(o,"click",this.handleOk),t});m(this,"handleDialogShow",()=>{const t=this.block;if(!t)return;const e=this.popup.popupContent,o=e.querySelector("button.customize-start-panel-button"),r=e.querySelector("input.customize-start-panel-input"),i=mo(t);!o||!r||requestAnimationFrame(()=>{r.focus(),r.value=String(i)})});m(this,"handleOk",()=>{const e=this.popup.popupContent.querySelector("input.customize-start-panel-input"),o=this.block;if(!o)return;const r=Number(e.value);!r||(this.editor.undoManager.runInGroup(()=>{hc(this.editor,[o,...uc(o)],r,{resetGroupId:!0})}),this.popup.close("clickItem"))});m(this,"handleKeydown",(t,e)=>{const o=e;o.isComposing||(o.key==="Escape"?this.popup.close("cancelBar"):o.key==="Enter"&&this.handleOk())});this.editor=t,this.popup=new Xa(this.createDialogContent()),this.popup.on("show",this.handleDialogShow)}destroy(){this.popup.destroy()}createNumericInput(){const t=w("input",["customize-start-panel-input"],null);t.type="number",t.min="1";const e=()=>{const r=t.value.replace(/[^\d]/g,"").replace(/^0+/,""),i=parseInt(r,10);i<=0||Number.isNaN(i)?t.value="":t.value=r};return this.editor.domEvents.addEventListener(t,"input",e),t}}function KO(n,t){return ac(n)===ac(t)}function XO(n,t){const e=r9(t);return e?KO(e,t)?mo(e)!==mo(t)-1:!0:!1}function t_(n,t){return Gi(t)?!0:mo(t)!==1}function e_(n,t){return Fe(t),[{id:"continue-numbering",name:R.t("list.continueList"),states:XO(n,t)?[]:["disabled"]},{id:"start-new-list",name:R.t("list.restartList"),states:t_(n,t)?[]:["disabled"]},{id:"set-numbering-value",name:R.t("list.changeNumber")}]}function n_(n,t,e){var o,r;if(Fe(t),e.id==="continue-numbering"){const i=r9(t);i&&hc(n,[t,...uc(t)],mo(i)+1,{resetGroupId:!0,groupId:ac(i)})}if(e.id==="start-new-list"&&n.undoManager.runInGroup(()=>{hc(n,[t,...uc(t)],1,{resetGroupId:!0})}),e.id==="set-numbering-value"){const i=(o=n.options.componentsOptions)==null?void 0:o.list;if((r=i==null?void 0:i.onChangeStart)!=null&&r.call(i,n,t,e))return;n.addCustom("list-customize-start-dialog",()=>new JO(n)).show(n,t)}}class o_{constructor(t){m(this,"menu");m(this,"handleClick",(t,e)=>{const o=Hl(e,"div.list-container");if(o&&this.editor.isWritable()){const r=et(o);g(we,r,"no parent block"),Fe(r);const i=t.getBlockData(r);if(i&&i.checkbox){t.updateBlockData(r,{...i,checkbox:i.checkbox==="checked"?"unchecked":"checked"});return}if(Zn(r)==="unordered")return;this.menu.updateItems(this.getCommandItems(r)),this.menu.manualShow(o),this.activeList(o,!0)}});m(this,"handleMenuClose",()=>{var e;const t=(e=this.menu.tippyInstance)==null?void 0:e.reference;t&&this.activeList(t,!1)});m(this,"handleMenuClick",(t,e)=>{var r;const o=(r=this.menu.tippyInstance)==null?void 0:r.reference;if(o){const i=et(o);i&&n_(this.editor,i,e)}});this.editor=t,this.editor.addListener("click",this.handleClick),this.menu=new Us([]),this.menu.addListener("close",this.handleMenuClose),this.menu.addListener("click",this.handleMenuClick)}destroy(){this.editor.removeListener("click",this.handleClick),this.menu.removeListener("close",this.handleMenuClose)}getCommandItems(t){return e_(this.editor,t)}activeList(t,e){const o=et(t);!o||(e?(W(t,"active"),W(o,"active")):(ot(t,"active"),ot(o,"active")))}}class r_{constructor(t){this.editor=t}handleBeforeKeyDown(t,e){const o=t.selection.range.getSelectedBlocks();if(o.length===0)return!1;const r=o[0].block;if(!Ht(r)||!u9(r))return!1;if(e.key==="ArrowUp"||e.key==="ArrowLeft"){const i=Is(r);return i&&t.selection.selectBlock(i,ut(t,i)),!0}if(e.key==="ArrowDown"||e.key==="ArrowRight"){const i=Ts(r);return i&&t.selection.selectBlock(i,0),!0}return(e.key==="Delete"||e.key==="Backspace"||e.key==="Escape")&&h9(t,r),!0}}function i_(n,t,e,o,r){tp(n,"list-block-init",()=>{setTimeout(()=>{n.input.addHandler(new r_(n)),n.input.addHandler(new ZO(n)),n.addCustom("list-clear-selection-handler",()=>new QO(n)),n.addCustom("list-marker-menu",()=>new o_(n))})});const i=Dn.createBlockContent(n,t,e,o,r),s=r,{level:l,start:a,groupId:d}=s,h=fc(s);o.setAttribute("data-list-level",`${l}`),o.setAttribute("data-list-start",`${a||1}`),o.setAttribute("data-list-group-id",`${d}`),o.setAttribute("data-list-type",h);const p=OO(s);return o.insertBefore(p,i),s.viewAsMindmap?setTimeout(()=>{const A=n.getBlockById(r.id);A&&df(n,A,{},{mindmapTools:d0,saveData:!1})}):setTimeout(()=>{const A=n.getBlockById(r.id);A&&d9(n,A)}),i}const s_={list:{confirm:"\u786E\u5B9A",setStart:"\u8BBE\u7F6E\u7F16\u53F7",continueList:"\u7EE7\u7EED\u7F16\u53F7",restartList:"\u5F00\u59CB\u65B0\u5217\u8868",changeNumber:"\u4FEE\u6539\u7F16\u53F7\u503C",numberLabel:"\u7F16\u53F7\u987A\u5E8F",mention:{tooltip:"\u63D0\u53CA\u4EBA\u5458\u5E76\u901A\u77E5"}},mindmap:{viewAsMindMap:"\u663E\u793A\u4E3A\u8111\u56FE",autoFit:"\u81EA\u52A8\u7F29\u653E",fullScreen:"\u5168\u5C4F\u67E5\u770B",close:"\u5173\u95ED",exitFullscreen:"\u9000\u51FA\u5168\u5C4F"}},l_={list:{confirm:"Confirm",setStart:"Set number",continueList:"Continue numbering",restartList:"Start a new list",changeNumber:"Set numbering value",numberLabel:"Numbering order",mention:{tooltip:"Mention and notify users"}},mindmap:{viewAsMindMap:"View as MindMap",autoFit:"Auto zoom",fullScreen:"Full screen",close:"Close",exitFullscreen:"Exit full screen"}},c_={list:{confirm:"OK",setStart:"\u756A\u53F7\u3092\u8A2D\u5B9A",continueList:"\u9023\u756A\u3092\u8A2D\u5B9A",restartList:"\u65B0\u3057\u3044\u30EA\u30B9\u30C8\u3092\u4F5C\u6210",changeNumber:"\u756A\u53F7\u3092\u7DE8\u96C6",numberLabel:"\u756A\u53F7",mention:{tooltip:"\u30E1\u30F3\u30B7\u30E7\u30F3\u304A\u3088\u3073\u901A\u77E5"}},mindmap:{viewAsMindMap:"\u30DE\u30A4\u30F3\u30C9\u30DE\u30C3\u30D7\u3067\u8868\u793A",autoFit:"\u81EA\u52D5\u30D5\u30A3\u30C3\u30C8",fullScreen:"\u5168\u753B\u9762\u8868\u793A\u306E\u30AA\u30F3",close:"\u9589\u3058\u308B",exitFullscreen:"\u5168\u753B\u9762\u8868\u793A\u306E\u30AA\u30D5"}};R.mergeLang({"zh-CN":s_,"en-US":l_,"ja-JP":c_});const Int="",B9={...Dn,blockType:"list",createBlockContent:i_,convertFrom:SO,convertTo:MO,handleDrop:vO,notify:pO},A0=S("paragraph");class a_{constructor(t){m(this,"id","BlockParagraphProvider");this.editor=t}isChecked(t,e){return!!(t[e]||t.level&&(t.ordered===!0&&!t.checkbox&&e==="ordered-list"||t.ordered===!1&&!t.checkbox&&e==="unordered-list")||e==="check-list"&&t.checkbox)}getAvailableCommands(t,e){const o=[],r={"unordered-list":[R.t("commands.unordered"),xo("CtrlOrCmd+Shift+L"),CL],"ordered-list":[R.t("commands.ordered"),xo("CtrlOrCmd+Shift+U"),pL],"check-list":[R.t("commands.check"),void 0,AL],link:[R.t("commands.link"),xo("CtrlOrCmd+K"),av],quoted:[R.t("commands.quote"),void 0,bL]};if(tt(t,e)){const i=it(e),s=Dt(e),l=Do(t,e),a=t.getBlockData(e);Object.entries(r).forEach(([d,[h,p,A]])=>{const v=[];if(this.isChecked(a,d)&&v.push("checked"),d==="link"){if(!t.selection.range.isSimple())return;t.selection.range.getSelectedBlocks().length!==1&&v.push("disabled")}o.push({blockId:i,blockType:s,blockKind:l,id:d,name:h,desc:p,states:v,icon:A,groupIndex:600})})}return o}convertLink(t,e,o){g(A0,Ur(e.start),""),g(A0,Ur(e.start),"");const r="bottom-start",i=e.start.offset,s=e.end.offset,l=(v,B)=>{t.undoManager.runInGroup(()=>{try{const D=t.selection.range.isCollapsed();let x;if(D){x=Vr(t.getBlockText(o),s,v,{link:B}),t.setBlockText(o,x);return}x=fh(t.getBlockText(o),i,s,v),x=Ia(i,v.length,x,"link",B),t.setBlockText(o,x),t.selection.selectBlock(o,i+v.length),t.focus()}catch(D){A0.error(D)}})},a=()=>{t.selection.selectBlock(o,s),t.focus()},d=Nr(t,o,e)[0];if(!d)return;const h=zr(t,o,"link-button-anchor",d),p=t.getBlockText(o),A=Ta(p,i);gu(t,{target:h,linkText:t.getSelectedText(),linkUrl:(A==null?void 0:A.link)||"",onFinished:l,onClose:a,placement:r})}convertToList(t,e,o){const r=th(t,e,"list",{offset:0,data:{listType:o}});r&&t.undoManager.runInGroup(()=>{const i=bt(e),s=nt(e);t.insertBlock(ct(s),i,r.blockData),t.deleteBlock(e),t.focus()})}executeCommand(t,e,o,r){var a;if(!tt(t,e))return!1;const i=r.id,s=(a=r.states)==null?void 0:a.includes("checked");let l=!1;if(i==="unordered-list"&&(s?mc(t,e):this.convertToList(t,e,"unordered"),l=!0),i==="ordered-list"&&(s?mc(t,e):this.convertToList(t,e,"ordered"),l=!0),i==="check-list"&&(s?mc(t,e):this.convertToList(t,e,"unchecked"),l=!0),i==="quoted"){const h=t.getBlockData(e).quoted;t.updateBlockData(e,{quoted:h?void 0:!0}),t.focus(),l=!0}if(i==="link"){const d=lf(t);d==null||d.disableTextToolbar(),d==null||d.hide(),setTimeout(()=>{d==null||d.enableTextToolbar()},1e3),this.convertLink(t,o,e),l=!0}return l}}const u_={left:tu,right:Ip,center:Tp};class d_{constructor(t){m(this,"id","BlockAlignProvider");this.editor=t}applyAlignStyle(t,e,o){Object.keys(u_).includes(o)?t.updateBlockData(e,{align:o}):t.updateBlockData(e,{align:null})}isChecked(t,e){return t.align===e}getAvailableCommands(t,e,o){if(tt(t,e)){const r=it(e),i=Dt(e),s=Do(t,e),l=t.getBlockData(e),a=d=>{var p;const h=w("span",["toolbar-item-name-container"],null);for(const A of d.children)if((p=A.states)!=null&&p.includes("checked"))return h.innerHTML=A.icon||tu,h;return h.innerHTML=tu,h};return[{id:"align",name:R.t("commands.alignGroup"),blockId:r,blockType:i,blockKind:s,groupIndex:700,dropdown:!0,element:a,manualShowChildren:!0,childrenPlacement:"bottom-start",defaultCheckedChildren:["align-left"],children:[{id:"align-left",name:R.t("commands.alignLeft"),icon:tu,states:this.isChecked(l,"left")?["checked"]:[]},{id:"align-center",name:R.t("commands.alignCenter"),icon:Tp,states:this.isChecked(l,"center")?["checked"]:[]},{id:"align-right",name:R.t("commands.alignRight"),icon:Ip,states:this.isChecked(l,"right")?["checked"]:[]}],childrenType:"menu"}]}return[]}executeCommand(t,e,o,r){if(!tt(t,e))return!1;if(r.id.startsWith("align")){const i=r.id.replace(/^align-/,"");return this.applyAlignStyle(t,e,i),this.editor.focus(),!0}return!1}}function h_(n){const e=n.selection.range;if(e.isCollapsed()||e.start.blockId!==e.end.blockId||!e.start.isSimple()||!e.end.isSimple()||e.end.offset-e.start.offset!==1)return!1;const o=n.getBlockById(e.start.blockId);return Sa(n,o,e.start.offset).charType==="box"}const f_=S("toolbar-handler"),m_={id:"",name:"",type:"separator"};class gc{constructor(t){m(this,"toolbar");m(this,"toolbarType","object");m(this,"mouseDown",!1);m(this,"oldRange",null);m(this,"hoveringBlock",null);m(this,"hoveringTextChild",null);m(this,"_disableTextToolbar",!1);m(this,"handleButtonClick",(t,e)=>{this.toolbarType==="text"?(this.editor.editorCommandProviders.executeCommand(this.editor.selection.range,e,{}),this.showTextToolbar("click")):this.hoveringBlock&&$R(this.editor,this.hoveringBlock,this.hoveringTextChild,e)});m(this,"handleClose",()=>{Op(this.editor)&&this.editor.focus()});m(this,"handleClosing",(t,e)=>{if(this.toolbarType==="object"){const o=oC(e);if(this.hoveringBlock===o)return!1}return!0});m(this,"handleDocumentMouseDown",t=>{t.button===0&&(document.addEventListener("mouseup",this.handleDocumentMouseUp),this.mouseDown=!0)});m(this,"handleDocumentMouseUp",()=>{document.removeEventListener("mouseup",this.handleDocumentMouseUp),this.mouseDown=!1,this.handleSelectionChange(this.editor)});m(this,"handleHoveringBlockChildChange",(t,e,o,r)=>{if(!(this.hoveringBlock===t&&this.hoveringTextChild===e)&&(this.hoveringBlock=t,this.hoveringTextChild=e,!(this.toolbar.isVisible&&this.toolbarType==="text"))){if(!t){this.toolbar.close("fromHover");return}this.showObjectToolbar(r)}});m(this,"handleSelectionChange",Le.default(t=>{var o;if(g(f_,t===this.editor,"editor mismatch"),t.selection.range.isCollapsed()||this.mouseDown){if(this.toolbarType==="object"){const r=(o=this.toolbar.tippyInstance)==null?void 0:o.reference,i=this.editor.selection.focusedBlock;if(r&&Xt(r,i))return}this.toolbar.close("selectionChange"),this.oldRange=null;return}if(!this.editor.isWritable()){this.toolbar.close("selectionChange"),this.oldRange=null;return}if(t.selection.range.getSelectedBlocks().length===0){this.toolbar.close("selectionChange"),this.oldRange=null;return}this.oldRange&&this.oldRange.isEqual(t.selection.range)||(this.oldRange=t.selection.range,this.showTextToolbar("selectionChange"))},50));this.editor=t;const e=t.options.componentsOptions.popover;this.toolbar=new ou([],void 0,{tooltipId:t.clientId,id:"editor-toolbar",overflowBoundary:e==null?void 0:e.overflowBoundary,refuseOverflow:!0,padding:20}),this.toolbar.on("click",this.handleButtonClick),this.toolbar.on("close",this.handleClose),this.toolbar.on("closing",this.handleClosing),this.bindEvents(),t.addListener("selectionChanged",this.handleSelectionChange),Ce.get(t).addListener("childChange",this.handleHoveringBlockChildChange),Ce.get(t).addFilter(this),t.editorCommandProviders.registerCommandProvider(new jR(t)),t.editorCommandProviders.registerCommandProvider(new a_(t)),t.editorCommandProviders.registerCommandProvider(new d_(t))}disableTextToolbar(){this._disableTextToolbar=!0}enableTextToolbar(){this._disableTextToolbar=!1}hide(){this.toolbar.close("selectionChange")}destroy(){this.unbindEvents(),this.toolbar.destroy(),this.editor.removeListener("selectionChanged",this.handleSelectionChange),Ce.get(this.editor).removeListener("childChange",this.handleHoveringBlockChildChange)}isInBlock(t,e){return t!==this.hoveringBlock?!1:!!(e.target&&e.target instanceof Node&&this.toolbar.popper&&Xt(this.toolbar.popper,e.target))}bindEvents(){document.addEventListener("mousedown",this.handleDocumentMouseDown)}unbindEvents(){document.removeEventListener("mousedown",this.handleDocumentMouseDown)}update(t){this.showTextToolbar(t)}showTextToolbar(t){var D,x;if(this._disableTextToolbar||!this.editor.isWritable())return;const o=this.editor.selection.range.getSelectedBlocks();if(o.length===0)return;const r=o[0];if(!r)return;if(o.length===1&&Me(r.block)){t==="click"&&this.showObjectToolbar(null);return}if(h_(this.editor))return;if(nt(r.block)===this.editor.rootContainer&&bt(r.block)===0){this.toolbar.close("selectionChange");return}const i=this.editor.editorCommandProviders.getCommands(this.editor.selection.range),s=new Map;i.forEach(_=>{const M=_.groupIndex,H=s.get(M);H?H.push(_):s.set(M,[_])});const l=[[]],a=Array.from(s.entries()).sort((_,M)=>_[0]-M[0]);for(let _=0;_<a.length;_++){const[,M]=a[_];if(M.length===0)continue;let H=l[l.length-1];H.length>0&&H[H.length-1].groupIndex!==M[M.length-1].groupIndex&&(H=[],l.push(H)),H.push(...sf(M))}if(l.length===0){this.toolbar.close("selectionChange");return}this.toolbarType="text";const d=[];if(l.forEach((_,M)=>{const H=_.sort((z,q)=>{var rt,ft;return((rt=z.order)!=null?rt:0)-((ft=q.order)!=null?ft:0)});d.push(...H),M!==l.length-1&&d.push(m_)}),d.length===0){this.toolbar.close("selectionChange");return}this.toolbar.updateItems(d);const h=o[o.length-1],p=!this.editor.selection.range.isReverse()&&h!==r,A=p?h:r,v=LR(this.editor,A),B=zr(this.editor,A.block,"editor-quick-menu",v);this.toolbar.manualShow(B,{placement:p?"bottom":"top",offset:[0,p?5:10]}),(x=(D=this.toolbar.tippyInstance)==null?void 0:D.popperInstance)==null||x.update()}showObjectToolbar(t){var l,a,d;if(!this.hoveringBlock||this.mouseDown)return;const e=this.hoveringBlock,o=this.hoveringTextChild,{commands:r,element:i}=FR(this.editor,e,o);if(!r.length||!i){this.toolbar.close("fromHover");return}this.toolbarType="object",this.toolbar.isVisible&&((a=(l=this.toolbar)==null?void 0:l.tippyInstance)==null?void 0:a.reference)!==i&&this.toolbar.close("fromHover");const s=()=>{let h;const p=i.getClientRects();if(p.length>1){if(h=o?p[p.length-1]:p[0],t)for(let A=0;A<p.length;A++){const v=p[A],B=new DOMRect(v.x-4,v.y-4,v.width+8,v.height+8);if(B.x<t.clientX&&t.clientX<B.right&&B.y<t.clientY&&t.clientY<B.bottom){h=v;break}}}else{if(h=i.getBoundingClientRect(),o){const A=o.getBoundingClientRect();return new DOMRect(A.x,A.y,A.width,A.height)}return new DOMRect(p[0].x,p[0].y,p[0].width,p[0].height)}if(t){const A=h.y,v=t.clientX;return new DOMRect(v,A,10,h.height)}return h};this.toolbar.updateItems(r),this.toolbar.isVisible||(this.toolbar.manualShow(i,{placement:o?"bottom":"top",getReferenceClientRect:s}),(d=this.toolbar.tippyInstance)!=null&&d.popper&&(this.toolbar.tippyInstance.popper.style.paddingTop="10px",this.toolbar.tippyInstance.popper.style.paddingBottom="5px"))}static register(t){return t.addCustom("toolbar-handler",e=>new gc(e))}static get(t){return t.getCustom("toolbar-handler")}}function pf(n,t,e){n.getBlockData(t).heading===e?n.updateBlockData(t,{heading:null}):n.updateBlockData(t,{heading:e})}function E9(n,t,e){["left","center","right"].includes(e)?n.updateBlockData(t,{align:e}):n.updateBlockData(t,{align:null})}function b0(n,t){const o=n.getBlockData(t).quoted;n.updateBlockData(t,{quoted:o?void 0:!0})}function v0(n,t){return!!(n[t]||n.level&&(n.ordered===!0&&!n.checkbox&&t==="ordered-list"||n.ordered===!1&&!n.checkbox&&t==="unordered-list")||t==="check-list"&&n.checkbox)}function y0(n,t,e){if(!n.selection.range.focus.isSimple())return;const r=n.getBlockData(t);let i;switch(e){case"unordered-list":i=v0(r,"unordered-list")?void 0:"unordered";break;case"ordered-list":i=v0(r,"ordered-list")?void 0:"ordered";break;case"check-list":i=v0(r,"check-list")?void 0:"unchecked";break}if(i){const s=th(n,t,"list",{offset:0,data:{listType:i}});s&&n.undoManager.runInGroup(()=>{const l=bt(t),a=nt(t);n.deleteBlock(t),n.insertBlock(ct(a),l,s.blockData)})}else mc(n,t)}const g_=Object.freeze(Object.defineProperty({__proto__:null,applyHeadingStyle:pf,applyAlignStyle:E9,applyQuoteStyle:b0,applyList:y0},Symbol.toStringTag,{value:"Module"})),p_=[bp,vp,yp,kp,wp,Bp,Ep,xp],C_={Unordered:hv,Ordered:fv,Checkbox:uv,Quote:dv};function x9(n,t){const e=n;e.blockOptions=t,e.itemType="insert-block",n.children&&n.children.forEach(o=>x9(o,t))}function A_(){return{name:"basic",insertBlockCommandItems:[{id:"text",icon:nu,name:R.t("commands.text"),order:0,group:"basics",value:"text"}]}}function k0(n=1){var r;const t={name:"basic",insertBlockCommandItems:[]};let e=cf();e<=4?e=5:e<8&&(e+=1);let o=n;for(;o<=e;){const i=`heading-${o}`;(r=t.insertBlockCommandItems)==null||r.push({id:i,icon:p_[o-1],name:R.t("quickMenu.basic.heading.title",{heading:String(o)}),order:o,group:"basics",value:String(o),subText:An(i)}),o++}return t}function b_(){const n={name:"basic",insertBlockCommandItems:[]};return["Unordered","Ordered","Checkbox","Quote"].forEach((e,o)=>{var i;const r=`insert-${e.toLocaleLowerCase()}`;(i=n.insertBlockCommandItems)==null||i.push({id:r,name:R.t(`quickMenu.basic.${e.toLocaleLowerCase()}`),icon:C_[e],value:e.toLocaleLowerCase(),group:"basics",order:10+o,subText:An(r)})}),n}class I9{constructor(t){this.withPlainText=t}getCommands(){const t=A_(),e=k0(),o=b_();return[...this.withPlainText?t.insertBlockCommandItems||[]:[],...e.insertBlockCommandItems||[],...o.insertBlockCommandItems||[]]}updateBlock(t,e,o,r){const{value:i,id:s}=r;return s.startsWith("heading-")?pf(t,o,Number.parseInt(i!=null?i:"1",10)||1):i==="ordered"||i==="unordered"||i==="checkbox"?y0(t,o,{ordered:"ordered-list",unordered:"unordered-list",checkbox:"check-list"}[i]):i==="quote"&&b0(t,o),null}async handleUpdateBlockCore(t,e){const o=t.getBlockByIndex(e.containerId,e.blockIndex);return this.updateBlock(t,e.containerId,o,e.item)}async handleInsertEmptyBlockCore(t,e){const{containerId:o,blockIndex:r}=e,i=t.insertTextBlock(void 0,o,r);return this.updateBlock(t,e.containerId,i,e.item)}async executeCommand(t,e,o){if(o.from==="quick-menu"){const r=t.getBlockById(o.blockId),i=t.getParentContainer(r),s=ct(i),l=t.getBlockIndex(r);t.undoManager.runInGroup(()=>this.handleUpdateBlockCore(t,{item:e,containerId:s,blockIndex:l})),t.focus()}else o.from==="block-menu"&&(t.undoManager.runInGroup(()=>this.handleInsertEmptyBlockCore(t,{item:e,containerId:o.containerId,blockIndex:o.blockIndex})),t.focus());return null}}const T9={basics:100,system:200,common:300,thirdParty:400};class w0{constructor(){m(this,"dataUrl","");m(this,"error",null)}destroy(){}setDataUrl(t){this.error=null,this.dataUrl=t}setError(t){this.dataUrl="",this.error=t}}const v_=S("mathjax-converter"),y_="MathJax-script";async function k_(n){var o;window.MathJax||(window.MathJax={options:{skipHtmlTags:["script","noscript","style","textarea","pre","code","annotation","annotation-xml","body"]}});const t=n.getComponentOptions("mathjax"),e=((o=t==null?void 0:t.cdn)==null?void 0:o.mathjax)||"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-svg.js";await bs(e,y_)}function w_(){try{window.MathJax&&window.MathJax.texReset()}catch{}}async function D9(n,t){const e="mathjax2Svg";try{await Eo.lock(e),w_(),await k_(n);const o=await window.MathJax.tex2svgPromise(t),r=o.querySelector("merror");if(r)throw new Error(r.textContent);return o.querySelector("svg").outerHTML}catch(o){throw v_.error(o),o}finally{Eo.release(e)}}async function S9(n,t){const e=await D9(n,t);return e?await Im(e,"image/svg+xml"):""}async function B0(n,t){const o=await D9(n,t),r=new File([o],"math.svg");return(await n.doc.uploadResource(r)).resourceId}const L9=S("edit-mathjax");class B_{constructor(){m(this,"editMathjaxPopup",null);m(this,"onChange",null);m(this,"tex","");m(this,"observer",null);m(this,"handleClose",t=>{var o;const e=t.content.querySelector("textarea");if(e){const r=e.value;r!==this.tex&&((o=this.onChange)==null||o.call(this,r,!0))}});m(this,"handleKeyup",t=>{var e;t.isComposing||(t.key==="Escape"&&((e=this.editMathjaxPopup)==null||e.close("cancelBar")),this.handleChange(t.target.value))});m(this,"handleChange",Le.default(t=>{var e;(e=this.onChange)==null||e.call(this,t,!1)},300))}editMathjax(t,e,o){if(!this.editMathjaxPopup)this.editMathjaxPopup=new Xa(this.createPopupContent(e));else{const r=this.getTextarea();r.value=e}this.tex=e,this.editMathjaxPopup.manualShow(t,{theme:"light"}),this.editMathjaxPopup.removeAllListeners("close"),this.editMathjaxPopup.addListener("close",this.handleClose),this.onChange=o}createPopupContent(t){const e=w("textarea",["mathjax-editor-textarea"],null);return e.value=t,e.addEventListener("keyup",this.handleKeyup),this.textareaWatcher(e),e}textareaWatcher(t){const e=t;e.onblur=()=>{var r;(r=this.editMathjaxPopup)!=null&&r.isVisible&&t.focus()};const o=()=>{setTimeout(()=>{t.focus()})};this.observer=new IntersectionObserver(o,{}),this.observer.observe(t)}getTextarea(){g(L9,this.editMathjaxPopup,"no exists mathjax editor popup");const t=this.editMathjaxPopup.content.querySelector("textarea");return g(L9,t,"no textarea"),t}destroy(){var t,e;this.onChange=null,(t=this.observer)==null||t.disconnect(),(e=this.editMathjaxPopup)==null||e.removeAllListeners()}}function M9(n,t,e,o){n.addCustom("mathjax-editor",()=>new B_).editMathjax(t,e.trim(),o)}function R9(){return{insert:" ",attributes:{id:K(),box:!0,type:"math",tex:" ",src:"",created:Date.now()}}}function Cf(n,t){const e=n.getBoxData(t),o=et(t);if(!o)return;const r=Os(o,t);n.selection.selectBlock(o,r.start,r.end);const i=async(s,l)=>{if(!s.trim()){n.updateBoxData({...e,tex:s,src:null});return}try{await Eo.lock("convertAndUploadMathjax");const a=await B0(n,s);n.updateBoxData({...e,tex:s,src:a})}catch(a){const d=n.getBoxData(t);n.addCustom(`mathjax-box-${d.id}`,()=>new w0).setError(a),n.updateBoxData({...e,tex:s,src:""})}finally{Eo.release("convertAndUploadMathjax"),l&&n.focus()}};M9(n,t,e.tex,i)}const O9=S("mathjax-box");function E0(n,t){n.selection.updateSelection(null);const e=t.target;!e||!(e instanceof HTMLElement)||n.domEvents.removeEventListener(e,null,E0)}async function E_(n,t,e){try{if(!t.tex.trim())return;const o=await S9(n,t.tex),r=n.findBoxById(t.id);if(!r)return;const i=Pm(r);i.innerHTML="";const s=w("img",["mathjax"],i);s.src=o,e.setDataUrl(o),n.domEvents.addEventListener(s,"load",E0)}catch(o){e.setError(o);const r=n.findBoxById(t.id);if(!r)return;const i=r.querySelector(".mathjax-tex-text");W(i,"mathjax-error"),i.innerText=o.message,n.selection.updateSelection(null)}}function x_(n,t,e,o){const r=o,i=n.addCustom(`mathjax-box-${r.id}`,()=>new w0);if(r.src||i.dataUrl){const a=w("img",["mathjax"],e);a.src=n.doc.buildResourceUrl(r.src||i.dataUrl),n.domEvents.addEventListener(a,"load",E0);return}const s=["mathjax-tex-text"];let l=r.tex;l.trim()?i.error&&(l=i.error.message,s.push("mathjax-error")):l=R.t("mathjax.emptyText"),w("span",s,e,l),E_(n,r,i)}function I_(n,t){const e={id:K(),box:!0,type:"math",tex:t,src:"",created:Date.now()};return B0(n,t).then(o=>{if(!n.findBoxById(e.id))return;const i={...e,src:o};n.updateBoxData(i)}).catch(o=>{O9.error(`failed to convert and upload mathjax: ${JSON.stringify(o)}`)}),e}function T_(n,t,e,o){const r=t;return o==="text"?r.tex:o==="markdown"?` $${r.tex}$ `:r.src?`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`:`<code>$${r.tex}$</code>`}function D_(n,t,e){const o=et(t);g(O9,o,"failed to get block"),!(n.readonly||!n.isBlockWritable(o))&&Cf(n,t)}function S_(){return{abstract:R.t("mathjax.abstract")}}const _9={boxType:"math",updateBoxContent:x_,convertFrom:I_,convertTo:T_,handleClickBox:D_,getBoxProperties:S_};async function L_(n,t,e){try{const o=t.embedData,r=await S9(n,o.mathjaxText),i=n.findBlockById(t.id);if(!i)return;const s=Lt(i);s.innerHTML="";const l=w("img",["mathjax"],s);l.src=r,e.setDataUrl(r)}catch(o){e.setError(o)}}function M_(n,t){if(n.readonly||!t.target||!(t.target instanceof Node))return;const e=et(t.target);if(!e||!Me(e)||fn(e)!=="math")return;const o=Lt(e),r=o.querySelector("img")||o.querySelector("span.mathjax-tex-text");if(!r||!Xt(r,t.target))return;const s=n.getBlockData(e).embedData;M9(n,r,s.mathjaxText,async l=>{const a=await B0(n,l),d={mathjaxText:l,src:a};n.updateEmbedData(e,d)})}function R_(n,t,e){const o=e.embedData,r=n.addCustom(`mathjax-block-${e.id}`,()=>new w0);if(n.domEvents.addEventListener(t,"click",M_),!o.mathjaxText.trim()){w("span",["mathjax-tex-text"],t,R.t("mathjax.emptyText"));return}if(o.src||r.dataUrl){const i=w("img",["mathjax"],t);i.src=n.doc.buildResourceUrl(o.src||r.dataUrl);return}r.error,w("span",["mathjax-tex-text"],t,o.mathjaxText),L_(n,e,r)}function O_(n,t,e){if(!tt(n,t))return null;const o=n.getBlockString(t).trim();if(!o||!o.startsWith("$$")||!o.endsWith("$$"))return null;const r=km(o,"$");if(!r)return null;const i={mathjaxText:r,src:""};return{blockData:{id:K(),type:"embed",embedType:"math",embedData:i}}}function __(n){return{name:"Mathjax"}}function F_(n,t){var o;const e=Lt(t);n.domEvents.removeAllListeners(e),n.findCustom("mathjax-editor")&&((o=n.getCustom("mathjax-editor").editMathjaxPopup)==null||o.close("cancelBar"))}function P_(n,t,e,o){const r=t.embedData;return o==="html"?`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`:o==="markdown"?`
398
398
  $$${r.mathjaxText}$$
399
- `:r.mathjaxText}function N_(){return{abstract:R.t("mathjax.abstract")}}const $_={embedType:"math",createEmbedContent:R_,getOptions:__,convertFrom:O_,handleDeleteBlock:F_,convertTo:P_,getBlockProperties:N_},Tnt="",H_={mathjax:{emptyText:"\u7A7A\u7684\u516C\u5F0F",abstract:"\u516C\u5F0F"}},j_={mathjax:{emptyText:"Empty formula",abstract:"Formula"}},U_={mathjax:{emptyText:"\u6570\u5F0F\u306A\u3057",abstract:"\u6570\u5F0F"}};R.mergeLang({"zh-CN":H_,"en-US":j_,"ja-JP":U_});function z_(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o);if(!ie(s).endsWith("$$$$"))return!1;const a=o-4,d=o,h={id:K(),box:!0,type:"math",tex:" ",src:"",created:Date.now()};return n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,a,d-a),n.insertBoxToBlock(r,a,h),setTimeout(()=>{const p=n.getBoxById(h.id);Cf(n,p)})}),!0}class V_{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&z_(t,e,o,r))}}const pc=S("inline-box-items");function W_(n,t,e){return n.undoManager.runInGroup(()=>{var s;let o=n.getBlockByIndex(t,e);ae(n,o)||(o=n.insertTextBlock([],t,e));const r=R9();n.setBlockText(o,[r]);const i=(s=r.attributes)==null?void 0:s.id;return g(pc,i,"mathjax box id is empty"),setTimeout(()=>{const l=n.getBoxById(i);Cf(n,l)},100),o})}function q_(n,t,e){let o=n.getBlockByIndex(t,e),r="bottom-start";return ae(n,o)||(r="top-start"),gu(n,{target:o,linkText:"",linkUrl:"",onFinished:(l,a)=>{n.undoManager.runInGroup(()=>{try{ae(n,o)||(o=n.insertTextBlock([],t,e));const d=co(l,{link:a}),h=co(" ",null),p=[d,h];n.insertTextToBlock(o,0,p),n.selection.selectBlock(o,rn(p)),n.focus()}catch(d){pc.error(d)}})},onClose:()=>{n.focus()},placement:r}),o}function G_(n,t,e){return n.undoManager.runInGroup(()=>{var l;const o=n.getBlockByIndex(t,e),r=n.selection.range;g(pc,Ur(r.start),"invalid block position");const i=R9();n.insertBoxToBlock(o,r.start.offset,i.attributes);const s=(l=i.attributes)==null?void 0:l.id;return g(pc,s,"mathjax box id is empty"),setTimeout(()=>{const a=n.getBoxById(s);Cf(n,a)},100),o})}function Z_(n,t,e){const o=n.getBlockByIndex(t,e),r=n.selection.range;g(pc,Ur(r.start),"invalid block position");const i=Nr(n,o,r);if(i.length===0)return;const s=i[0],l=zr(n,o,"quick-menu-inline-link",s);gu(n,{target:l,linkText:"",linkUrl:"",onFinished:(h,p)=>{n.undoManager.runInGroup(()=>{try{const A=n.getBlockText(o),v=Vr(A,r.start.offset,h,{link:p});n.setBlockText(o,v),n.selection.selectBlock(o,r.start.offset+h.length),n.focus()}catch(A){pc.error(A)}})},onClose:()=>{n.focus()},placement:"bottom-start"})}class F9{getCommands(){return[{id:"insert-math",name:R.t("quickMenu.inlineBox.math"),icon:EL,order:900,group:"common",subText:An("insert-math")},{id:"insert-link",name:R.t("quickMenu.inlineBox.link"),icon:av,order:400,group:"common",subText:An("insert-link")}]}async handleUpdateBlockCore(t,e){switch(e.item.id){case"insert-math":return G_(t,e.containerId,e.blockIndex);case"insert-link":return Z_(t,e.containerId,e.blockIndex);default:return null}}async handleInsertEmptyBlockCore(t,e){switch(e.item.id){case"insert-math":return W_(t,e.containerId,e.blockIndex);case"insert-link":return q_(t,e.containerId,e.blockIndex);default:return null}}async executeCommand(t,e,o){if(o.from==="quick-menu"){const r=t.getBlockById(o.blockId),i=t.getParentContainer(r),s=ct(i),l=t.getBlockIndex(r);t.undoManager.runInGroup(()=>this.handleUpdateBlockCore(t,{item:e,containerId:s,blockIndex:l}))}else o.from==="block-menu"&&t.undoManager.runInGroup(()=>this.handleInsertEmptyBlockCore(t,{item:e,containerId:o.containerId,blockIndex:o.blockIndex}));return null}}function Q_(n,t={withPlainText:!1}){var i,s;const{withPlainText:e}=t,o=(s=(i=n.options.componentsOptions)==null?void 0:i.quickMenu)==null?void 0:s.commandProviders;if(!o)return[];const r=[];return[...o,new I9(e),new F9].forEach(l=>{const a=l.getCommands(n);r.push(...a.map(d=>({...d,itemType:"insert-block",commandProvider:l})))}),r}function Y_(n,t={withPlainText:!1}){const e=[];return n.editorBlocks.forEach(o=>{if(!o.getOptions)return;const r=o.getOptions(n);!r.insertBlockCommandItems||(r.insertBlockCommandItems.forEach(i=>{x9(i,r)}),e.push(...r.insertBlockCommandItems))}),e.push(...Q_(n,t)),e}function x0(n,t={withPlainText:!1}){const e=Y_(n,t),o=new Map;e.forEach(s=>{var d;const l=(d=s.group)!=null?d:"";let a=o.get(l);a?a.items.push(s):(a={group:l,order:s.groupOrder||T9[l]||1e3,items:[s]},o.set(l,a))});const r=Array.from(o.values());r.sort((s,l)=>s.order-l.order),r.forEach(s=>{s.items.sort((l,a)=>{var d,h;return((d=l.order)!=null?d:0)-((h=a.order)!=null?h:0)})});const i=[];return r.forEach((s,l)=>{const a=`blockMenu.section.${s.group||"common"}`,d=R.t(a),h=d===a?s.group:d;i.push({id:`section-${l}`,name:h,type:"section",group:s.group,itemType:"insert-block"}),i.push(...s.items.map(p=>({...p})))}),i}function J_(n,t,e){const o=n.getFocusedBlock();if(!o)return;const r=n.getParentContainer(o),i=ct(r);let l=n.getBlockIndex(o);if(ae(n,o)||(l+=1),t.commandProvider){t.commandProvider.executeCommand(n,t,{from:"quick-menu",...e});return}!t.blockOptions||!t.blockOptions.handleInsertEmptyBlock||t.blockOptions.handleInsertEmptyBlock(n,{containerId:i,blockIndex:l,item:t})}const P9=S("quick-menu"),K_={id:"quick-menu",trigger:["/"]},X_=5;class Af{constructor(t,e=K_){m(this,"suggest");m(this,"items");m(this,"maxHeading");m(this,"firstEmptyOffset",-1);m(this,"queryItems",async(t,e)=>{if(this.items.length===0?this.initMenuItems():this.refreshMenuItems(),e){const o=new Set,r=e.toLocaleLowerCase().replace(/^\s+|\s+$/g,""),i=this.items.filter(s=>{if(s.type==="section")return!0;if(s.name.toLocaleLowerCase().indexOf(r)!==-1||pM(s).toLocaleLowerCase().indexOf(r)!==-1)return o.add(s.group),!0;const l=`blockMenu.section.${s.group||"common"}`,a=R.t(l),d=a===l?s.group:a;return(d==null?void 0:d.toLocaleLowerCase().indexOf(r))!==-1?(o.add(s.group),!0):!1}).filter(s=>s.type==="section"?o.has(s.group):!0);return i.length?this.firstEmptyOffset=-1:this.handleEmptySearch(),i}return this.items});m(this,"onClose",()=>{this.firstEmptyOffset=-1});m(this,"onShow",(t,e,o,r)=>{const i=this.editor.getBlockByIndex(e,o);if(!io(i)){const s=et(nt(i));if(s&&Dt(s)==="code")return!1}return!0});m(this,"onClickItem",(t,e)=>{const o=e;o.itemType==="insert-block"&&(g(P9,o.blockOptions||o.commandProvider,"invalid quick item, no block options or command provider"),g(P9,this.suggest.anchor,"invalid suggest, no anchor"),this.options.id==="empty-block-menu"&&this.editor.focus(),J_(this.editor,o,this.suggest.anchor))});this.editor=t,this.options=e,this.items=[],this.maxHeading=cf(),this.suggest=new Fp(t,{id:e.id||"quick-menu",trigger:e.trigger,needSpaceBeforeTrigger:!0,autoDeleteTrigger:!0,highlight:!0,onClose:this.onClose,onShow:this.onShow,onClickItem:this.onClickItem,queryItems:this.queryItems})}get menu(){return this.suggest.menu.menu}destroy(){this.suggest.destroy()}initMenuItems(){const t=x0(this.editor);this.items=t}refreshMenuItems(){let t=null,e=0;const o=cf();if(o!==this.maxHeading){const r=new I9,s=r.getCommands().map(l=>({...l,itemType:"insert-block",commandProvider:r}));for(let l=0;l<this.items.length;l++)this.items[l].group==="basics"&&(t||(t=l),t&&e++);t&&e&&this.items.splice(t,e,...s),this.maxHeading=o}}handleEmptySearch(){const t=this.editor.selection.getFocusedPos();if(this.firstEmptyOffset===-1){if(t.isSimple()){const{offset:e}=t;this.firstEmptyOffset=e-1}}else if(t.isSimple()){const{offset:e}=t;e-this.firstEmptyOffset>X_&&(this.suggest.close(),this.firstEmptyOffset=-1)}}}class bf{constructor(t){m(this,"instance");m(this,"mousedown",!1);m(this,"currentInstance",null);m(this,"attributeName",[]);m(this,"attributeDesc","");m(this,"observer",null);m(this,"observerCallback",null);m(this,"createContent",t=>{let e="",o=0;for(;o<this.attributeName.length&&!e;)t.hasAttribute(this.attributeName[o])&&(e=t.getAttribute(this.attributeName[o])||""),o++;const r=t.getAttribute(this.attributeDesc);if(!r)return e;const i=w("div",[],null);return w("span",[],i,e),r&&w("span",["editor-tooltip-desc"],i,r),i});m(this,"handleDocumentMouseDown",()=>{this.mousedown=!0,this.editor.domEvents.addEventListener(document,"mouseup",this.handleDocumentMouseUp)});m(this,"handleDocumentMouseUp",()=>{this.mousedown=!1,this.editor.domEvents.removeEventListener(document,"mouseup",this.handleDocumentMouseUp)});m(this,"handleShown",t=>{this.currentInstance&&this.hide(),this.currentInstance=t,this.createObserver()});m(this,"handleHidden",()=>{this.destroyObserver(),this.currentInstance=null});m(this,"handleShow",t=>{var r;const e=t.reference;if(!e||!Xt(document.body,e)||window.isDragging||this.mousedown)return!1;const o=Number.parseInt((r=e.getAttribute("data-tooltip-hide-at"))!=null?r:"",10);if(o&&Date.now()-o<1e3)return!1;if(t.reference){const i={};if(t.reference.hasAttribute("data-editor-tooltip-placement")&&(i.placement=t.reference.getAttribute("data-editor-tooltip-placement")||"top"),t.reference.hasAttribute("data-editor-tooltip-offset-x")||t.reference.hasAttribute("data-editor-tooltip-offset-y")){const s=t.reference.getAttribute("data-editor-tooltip-offset-x"),l=t.reference.getAttribute("data-editor-tooltip-offset-y");i.offset=[s?Number.parseInt(s,10):0,l?Number.parseInt(l,10):0]}if(t.reference.hasAttribute("data-editor-tooltip-maxwidth")&&(i.maxWidth=Number.parseInt(t.reference.getAttribute("data-editor-tooltip-maxwidth")||"350",10)),t.reference.hasAttribute("data-editor-tooltip-allow-markdown")&&(i.allowHTML=!0),Object.keys(i).length&&t.setProps(i),t.reference.hasAttribute(`data-editor-tooltip-${this.editor.clientId}-dynamic`)){const s=t.reference.getAttribute(`data-editor-tooltip-${this.editor.clientId}-dynamic`);t.setContent(s||"")}}return!0});this.editor=t;const e=t.clientId;this.attributeName=[`data-editor-tooltip-${e}`,`data-editor-tooltip-${e}-dynamic`,"data-editor-tooltip-common"],this.attributeDesc=`data-editor-tooltip-desc-${e}`,this.instance=am.delegate(document.body,{theme:"editor-tooltip",maxWidth:400,delay:200,target:this.attributeName.map(o=>`[${o}]`).join(","),content:this.createContent,onShow:this.handleShow,onShown:this.handleShown,onHide:this.handleHidden}),t.domEvents.addEventListener(document,"mousedown",this.handleDocumentMouseDown)}visible(){var t;return(t=this.currentInstance)==null?void 0:t.state.isVisible}hide(){var t;(t=this.currentInstance)!=null&&t.state.isVisible&&this.currentInstance.hide()}destroy(){this.destroyObserver(),this.instance.destroy(),this.editor.domEvents.removeEventListener(document,"mousedown",this.handleDocumentMouseDown),this.editor.domEvents.removeEventListener(document,"mouseup",this.handleDocumentMouseUp)}createObserver(){this.destroyObserver();const t=this.currentInstance;if(!t||!t.reference)return;this.observerCallback=Le.default(()=>{t.reference.closest("body")||(t.hide(),this.destroyObserver())},200),this.observer=new MutationObserver(this.observerCallback);const e=document.body,o={childList:!0,attributes:!1,subtree:!0};this.observer.observe(e,o)}destroyObserver(){this.observer&&(this.observer.disconnect(),this.observer=null),this.observerCallback&&(this.observerCallback.cancel(),this.observerCallback=null)}}const tF={"text/style-bold":"bold","text/style-italic":"italic","text/style-underline":"underline","text/style-strikethrough":"line-through","text/style-code":"code","text/style-sub":"subscript","text/style-super":"superscript"};function eF(n,t){const e=new Set(Object.keys(tF)),o=t.filter(i=>e.has(i.id));return sf(o)}function vf(n,t){if(!n.isWritable())return!1;const e=n.selection.range,o=n.editorCommandProviders.getCommands(e),i=eF(n,o).find(s=>s.id===`text/${t}`);return i?(n.editorCommandProviders.executeCommand(e,i,{}),gc.get(n).update("selectionChange"),!0):!1}const I0={"CtrlOrCmd+B":n=>vf(n,"style-bold"),"CtrlOrCmd+I":n=>vf(n,"style-italic"),"CtrlOrCmd+U":n=>vf(n,"style-underline"),"CtrlOrCmd+D":n=>vf(n,"style-strikethrough")},nF={quickMenu:{basic:{heading:{title:"\u6807\u9898 {heading}",space:"{markdown}\u7A7A\u683C"},unordered:"\u65E0\u5E8F\u5217\u8868",ordered:"\u6709\u5E8F\u5217\u8868",checkbox:"\u5F85\u529E\u4E8B\u9879",quote:"\u5F15\u7528"},inlineBox:{math:"\u516C\u5F0F",link:"\u94FE\u63A5"}},link:{textLabel:"\u6587\u672C",urlLabel:"\u94FE\u63A5\u5730\u5740",textPlaceholder:"\u8BF7\u8F93\u5165\u6587\u672C",urlPlaceholder:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740",submitText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",edit:"\u7F16\u8F91",remove:"\u53D6\u6D88\u94FE\u63A5"},commands:{unordered:"\u65E0\u5E8F\u5217\u8868",ordered:"\u6709\u5E8F\u5217\u8868",check:"\u5F85\u529E\u5217\u8868",link:"\u94FE\u63A5",quote:"\u5F15\u7528",alignLeft:"\u5DE6\u5BF9\u9F50",alignRight:"\u53F3\u5BF9\u9F50",alignCenter:"\u5C45\u4E2D\u5BF9\u9F50",alignGroup:"\u5BF9\u9F50\u65B9\u5F0F",heading:"\u6807\u9898 {name}",headingGroup:"\u6807\u9898\u6837\u5F0F",text:"\u6B63\u6587"}},oF={quickMenu:{basic:{heading:{title:"Title {heading}",space:"{markdown}space"},unordered:"Bulleted list",ordered:"Numbered list",checkbox:"To-do list",quote:"Quote"},inlineBox:{math:"Formula",link:"Link"}},link:{textLabel:"Text",urlLabel:"Link address",textPlaceholder:"Please enter text",urlPlaceholder:"Please enter link",submitText:"Confirm",cancelText:"Cancel",edit:"Edit",remove:"Remove link"},commands:{unordered:"Bulleted list",ordered:"Numberer list",check:"To-do list",link:"Link",quote:"Quote",alignLeft:"Align left",alignRight:"Align right",alignCenter:"Center text",alignGroup:"Alignment",heading:"Title {name}",headingGroup:"Text style",text:"Text"}},rF={quickMenu:{basic:{heading:{title:"\u898B\u51FA\u3057{heading}",space:"{markdown}\u30B9\u30DA\u30FC\u30B9"},unordered:"\u7B87\u6761\u66F8\u304D\u30EA\u30B9\u30C8",ordered:"\u756A\u53F7\u4ED8\u304D\u30EA\u30B9\u30C8",checkbox:"\u30D0\u30C3\u30AF\u30ED\u30B0",quote:"\u5F15\u7528"},inlineBox:{math:"\u6570\u5F0F",link:"URL"}},link:{textLabel:"\u30C6\u30AD\u30B9\u30C8",urlLabel:"URL",textPlaceholder:"\u30C6\u30AD\u30B9\u30C8\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",urlPlaceholder:"URL \u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",submitText:"OK",cancelText:"\u30AD\u30E3\u30F3\u30BB\u30EB",edit:"\u7DE8\u96C6",remove:"\u30EA\u30F3\u30AF\u3092\u89E3\u9664"},commands:{unordered:"\u7B87\u6761\u66F8\u304D\u30EA\u30B9\u30C8",ordered:"\u756A\u53F7\u4ED8\u304D\u30EA\u30B9\u30C8",check:"\u30D0\u30C3\u30AF\u30ED\u30B0",link:"URL",quote:"\u5F15\u7528",alignLeft:"\u5DE6\u63C3\u3048",alignRight:"\u53F3\u63C3\u3048",alignCenter:"\u4E2D\u592E\u63C3\u3048",alignGroup:"\u5BF9\u9F50\u65B9\u5F0F",heading:"\u898B\u51FA\u3057{name}",headingGroup:"\u30BF\u30A4\u30C8\u30EB\u30B9\u30BF\u30A4\u30EB",text:"\u672C\u6587"}};R.mergeLang({"zh-CN":nF,"en-US":oF,"ja-JP":rF});const Dnt="";function Zs(n,...t){const e=uo(...t);return e.classList.remove("editor-button"),e.classList.add("editor-text-button"),n.append(e),e}function N9(n){const t=lf(n);t==null||t.hide();const e=n.findCustom("table-border-bar");e==null||e.closeToolbar()}function iF(n){return w("div",["insert-column-button","drop-marker"],n)}const sF=S("row-height");function $9(n){const t=Tt.fromTable(n),e=n.rows;g(sF,e.length===t.rowCount,"row count mismatch");const o=Array(t.rowCount).fill(0);for(let r=0;r<e.length;){let i=1,l=e[r].getBoundingClientRect().height,a=r+1;for(;a<e.length;){const d=e[a];if(d.cells.length!==0)break;i++,a++,l+=d.getBoundingClientRect().height}for(let d=0;d<i;d++)o[r+d]=l/i;r=a}return o}const lF=S("table-border-bar-dom");function H9(n){var a;const t=et(n.contentElement);g(lF,t,"no block");const o=te(t).querySelector(".table-border-bar-container.left"),i=Lt(t).offsetLeft-ic,s=((a=n.scrollOptions.paddingLeft)!=null?a:0)+i,l=Math.min(n.contentElement.offsetLeft-i,n.rootElement.scrollLeft-s);o&&(o.style.left=`${-l}px`)}const Zi=S("table-border-bar-dom");function Cc(n,t){g(Zi,Ve(t),"invalid table block");const e=_e(t),o=gr(n,t),r=te(t),i=(p,A,v)=>{const B=w("div",["button-root",A],p),D=w("div",["button-container",A],B);B.setAttribute(`data-${A}-index`,`${v}`),D.setAttribute(`data-editor-tooltip-${n.clientId}`,A==="left"?R.t("table.insertRow"):R.t("table.insertCol")),w("span",["insert-indicator"],D),iF(D)},{selectedRows:s,selectedColumns:l}=Np(n,t),a=()=>{const p=o.querySelector(".table-border-bar-container.top");g(Zi,p,"no top border bar container");const A=w("div",["table-border-bar-container","top"],null),v=w("div",["table-border-bar","top"],A),B=gR(e),x=Tt.fromTable(e).colCount;n.selection.range.isSimple()&&i(v,"top",0);for(let _=0;_<x;_++){const M=_===x-1?B[_]+2:B[_],H=w("span",["table-border-bar-cell","top"],v);l.has(_)&&H.classList.add("selected"),H.setAttribute("data-top-index",`${_}`),H.style.width=`${M}px`,n.selection.range.isSimple()&&i(v,"top",_+1)}pa(p,A)},d=()=>{const p=r.querySelector(".table-border-bar-container.left");g(Zi,p,"no left border bar container");const A=w("div",["table-border-bar-container","left"],null),v=w("div",["table-border-bar","left"],A);w("span",["table-border-bar-cell","corner"],v);const B=$9(e);n.selection.range.isSimple()&&i(v,"left",0),Array.from(e.rows).forEach((D,x,_)=>{const M=w("span",["table-border-bar-cell","left"],v);s.has(x)&&M.classList.add("selected"),M.setAttribute("data-left-index",`${x}`);const H=x===_.length-1?B[x]+2:B[x];M.style.height=`${H}px`,n.selection.range.isSimple()&&i(v,"left",x+1)}),pa(p,A)};a(),d();const h=n.findCustom(mr(t));h&&H9(h)}function j9(n,t){const e=t.target;if(!(e instanceof Element))return;const o=et(e);g(Zi,o&&Ve(o),"invalid table block"),Cc(n,o),n.selection.caret.update()}function yf(n,t){const e=t.target;if(!(e instanceof Element))return;const o=et(e);g(Zi,o&&Ve(o),"invalid table block");const r=e.closest(".button-root");if(r){if(r.classList.contains("top")){const i=parseInt(r.getAttribute("data-top-index")||"0",10);Yv(n,o,i),Cc(n,o)}else if(r.classList.contains("left")){const i=parseInt(r.getAttribute("data-left-index")||"0",10);Jv(n,o,i),Cc(n,o)}}}function kf(n,t){var s;N9(n),t.preventDefault(),t.stopPropagation();let e=null,o,r;const i=l=>{var a;if(l.target instanceof HTMLElement&&o&&e&&r!==void 0){const d=et(l.target),h=l.target.closest(".table-border-bar");if(d===e&&h){const p=parseInt((a=l.target.getAttribute(`data-${o}-index`))!=null?a:"0",10),A=Math.min(r,p),v=Math.abs(r-p)+1;xt(l.target,"top")&&o==="top"?DR(n,d,A,v,{reverse:!0}):xt(l.target,"left")&&o==="left"&&SR(n,d,A,v,{reverse:!0})}}l.type==="mouseup"&&(e=null,r=void 0,o=void 0,document.body.removeEventListener("mousemove",i),document.body.removeEventListener("mouseup",i))};t.target instanceof HTMLElement&&xt(t.target,"table-border-bar-cell")&&(e=et(t.target),xt(t.target,"top")?o="top":xt(t.target,"left")&&(o="left"),o&&e&&(r=parseInt((s=t.target.getAttribute(`data-${o}-index`))!=null?s:"0",10),document.body.addEventListener("mousemove",i),document.body.addEventListener("mouseup",i)))}function U9(n){const t=n.selection.range,e=su(n,t);e&&Cc(n,e)}function cF(n,t){g(Zi,Ve(t),"invalid table block");const e=gr(n,t),o=te(t),r=w("div",["table-border-bar-container","top"],e),i=w("div",["table-border-bar-container","left"],o);Cc(n,t),n.domEvents.addEventListener(Lt(t),"scroll",j9),n.domEvents.addEventListener(r,"click",yf),n.domEvents.addEventListener(i,"click",yf),n.domEvents.addEventListener(r,"mousedown",kf),n.domEvents.addEventListener(i,"mousedown",kf),n.addListener("afterClearSelection",U9)}function z9(n,t){if(!n.isWritable())return;if(gr(n,t).querySelector(".table-border-bar-container")){Cc(n,t);return}cF(n,t)}function V9(n,t){g(Zi,Ve(t),"invalid table block");const e=gr(n,t),o=te(t),r=e.querySelectorAll(".table-border-bar-container"),i=o.querySelectorAll(".table-border-bar-container");r.forEach(s=>{n.domEvents.removeEventListener(s,"click",yf),n.domEvents.removeEventListener(s,"mousedown",kf),s.remove()}),i.forEach(s=>{n.domEvents.removeEventListener(s,"click",yf),n.domEvents.removeEventListener(s,"mousedown",kf),s.remove()}),n.domEvents.removeEventListener(Lt(t),"scroll",j9),n.addListener("afterClearSelection",U9)}function aF(n,t){g(Zi,Ve(t),"invalid table block");const o=gr(n,t).querySelector(".table-border-bar-container.top");return o?o.getBoundingClientRect().height:0}class uF{constructor(t,e){m(this,"toolbar");m(this,"handleSelectionChange",(t,e)=>{!t.isVisible||(e==="delete-columns"?(zi(this.editor,this.tableBlock,!0,!0),Vi(this.editor,this.tableBlock,!0,!0)):e==="delete-rows"?(zi(this.editor,this.tableBlock,!0,!1),Vi(this.editor,this.tableBlock,!0,!1)):(zi(this.editor,this.tableBlock,!1),Vi(this.editor,this.tableBlock,!1)))});m(this,"handleClick",(t,e,o)=>{e.id==="delete-columns"?$p(this.editor.selection.range):e.id==="delete-rows"&&Hp(this.editor.selection.range)});m(this,"handleToolbarClose",()=>{this.tableBlock&&su(this.editor,this.editor.selection.range)===this.tableBlock&&(zi(this.editor,this.tableBlock,!1),Vi(this.editor,this.tableBlock,!1))});this.editor=t,this.tableBlock=e;const o=t.options.componentsOptions.popover;this.toolbar=new ou([],void 0,{id:"table-row-column-toolbar",overflowBoundary:o==null?void 0:o.overflowBoundary,refuseOverflow:!0,tooltipId:this.editor.clientId}),this.toolbar.addListener("selectionChange",this.handleSelectionChange),this.toolbar.addListener("click",this.handleClick),this.toolbar.addListener("close",this.handleToolbarClose)}close(){this.toolbar.close("cancelBar")}update(){var r,i,s;const{selectedColumns:t,selectedRows:e}=Np(this.editor,this.tableBlock);if(!this.editor.isWritable())return;if(t.size>0&&e.size>0){this.toolbar.close("cancelBar");return}if(t.size===0&&e.size===0){this.toolbar.close("cancelBar");return}const o=Nr(this.editor,this.tableBlock,this.editor.selection.range)[0];if(!o){this.toolbar.close("cancelBar");return}if(t.size>0){const l={id:"delete-columns",name:R.t("table.deleteCol"),icon:hL};this.toolbar.updateItems([l]);const a=zr(this.editor,this.tableBlock,"table-row-column-delete",o);this.toolbar.manualShow(a,{placement:"top",offset:[0,5]})}else{const l={id:"delete-rows",name:R.t("table.deleteRow"),icon:dL};this.toolbar.updateItems([l]);const h=te(this.tableBlock).querySelector(".table-border-bar-container.left").getBoundingClientRect(),p=new DOMRect(Math.max(h.left,o.left-ic),o.top,ic,o.height),A=zr(this.editor,this.tableBlock,"table-row-column-delete",p);this.toolbar.manualShow(A,{placement:"left",offset:[0,5]});const v=this.editor.options.componentsOptions.popover;(r=this.toolbar.tippyInstance)==null||r.setProps({popperOptions:{modifiers:[{name:"flip",options:{boundary:v==null?void 0:v.overflowBoundary,fallbackPlacements:["left","right"]}}]}})}(s=(i=this.toolbar.tippyInstance)==null?void 0:i.popperInstance)==null||s.update()}destroy(){this.toolbar.destroy(),this.toolbar.removeAllListeners()}}const T0=S("table-border-bar");class dF{constructor(t,e){m(this,"toolbar");m(this,"resizeObserver");m(this,"handleReadonlyChanged",t=>{t.isWritable()?this.update():V9(this.editor,this.tableBlock)});m(this,"handleBlockUpdated",()=>{this.resizeObserver.disconnect(),setTimeout(()=>{const t=this.editor.getBlockById(it(this.tableBlock));this.resizeObserver.observe(_e(t))})});m(this,"handleScroll",()=>{this.toolbar.update()});m(this,"handleTableResize",()=>{!this.editor.isWritable()||(console.log("resize"),this.update())});this.editor=t,this.tableBlock=e,g(T0,this.tableBlock,"no table block"),T0.debug("create table border bar"),z9(this.editor,this.tableBlock),this.resizeObserver=new ResizeObserver(this.handleTableResize),this.resizeObserver.observe(_e(this.tableBlock)),this.toolbar=new uF(this.editor,this.tableBlock),this.editor.addListener("readonlyChanged",this.handleReadonlyChanged)}close(){this.toolbar.close()}destroy(){T0.debug("destroy table border bar"),this.resizeObserver.disconnect(),V9(this.editor,this.tableBlock),this.toolbar.destroy(),this.editor.removeListener("readonlyChanged",this.handleReadonlyChanged)}update(){z9(this.editor,this.tableBlock),this.toolbar.update()}}const hF=S("table-border-bar");class fF{constructor(t){m(this,"activeTableBar",null);m(this,"handleBlockDeleted",(t,e)=>{!this.activeTableBar||(e===this.activeTableBar.tableBlock||Xt(e,this.activeTableBar.tableBlock))&&(this.activeTableBar.destroy(),this.activeTableBar=null)});m(this,"handleSelectionChanged",t=>{var r;const e=t.selection.range,o=su(t,e);((r=this.activeTableBar)==null?void 0:r.tableBlock)!==o&&this.activeTableBar&&this.hide(),o&&this.show(o)});m(this,"handleScroll",()=>{var t;(t=this.activeTableBar)==null||t.handleScroll()});this.editor=t,this.editor.addListener("blockDeleted",this.handleBlockDeleted),this.editor.addListener("selectionChanged",this.handleSelectionChanged)}destroy(){this.editor.removeListener("blockDeleted",this.handleBlockDeleted),this.editor.removeListener("selectionChanged",this.handleSelectionChanged)}show(t){this.activeTableBar?(this.activeTableBar.tableBlock!==t&&this.hide(),this.activeTableBar.update()):this.activeTableBar=new dF(this.editor,t)}update(){var t;(t=this.activeTableBar)==null||t.handleBlockUpdated()}closeToolbar(){var t;(t=this.activeTableBar)==null||t.close()}hide(){!this.activeTableBar||(g(hF,this.activeTableBar,"no active table bar"),this.activeTableBar.destroy(),this.activeTableBar=null)}}function W9(n,t){const e=n.addCustom("table-border-bar",o=>new fF(o));t==="update"&&e.update()}const Mn=S("table-cell-menu"),mF="style-bg-color-";class gF{constructor(t){m(this,"activeTableBlock",null);m(this,"targetButton",null);m(this,"manualMenu",null);m(this,"colorPaletteItem",null);m(this,"handlePrevent",(t,e)=>{e.stopPropagation()});m(this,"handleReadonlyChanged",t=>{t.isWritable()||this.hide()});m(this,"handleSelectionChanged",t=>{const e=t.selection.range,o=su(t,e);if(this.hide(),this.activeTableBlock!==o&&(this.activeTableBlock=o),this.activeTableBlock){const r=Tt.fromBlock(this.activeTableBlock),i=e.isReverse()?e.start:e.end;let s=null;i instanceof Mo?t.getBlockById(i.blockId)===this.activeTableBlock?s=r.getCellByContainerId(i.childContainerId):s=this.getCellByChildBlockId(r,i.blockId):i.blockId!==this.activeTableBlock.id&&(s=this.getCellByChildBlockId(r,i.blockId)),s&&this.editor.isWritable()&&this.showCellMenuButton(s)}});m(this,"handleBeforePopupPalette",()=>{var e;const t=this.getSelectedBkgColorIndex();(e=this.colorPaletteItem)==null||e.palette.setColor("backgroundColor",t)});m(this,"createBkgColorItem",()=>{const t=w("div",["cell-background-color-item"],null);w("span",[],t,R.t("table.cellBackground"));const e=this.getSelectedBkgColorIndex();w("button",["item-button"],t).setAttribute("data-color-index",`${e}`);const r=w("span",["item-sub-indicator"],t);return r.innerHTML=rv,t});m(this,"handleCommand",t=>{var r;g(Mn,this.activeTableBlock,"no target table block");const e=((r=t.states)==null?void 0:r.includes("checked"))||!1,o=t.value;switch(t.id){case"delete-select-row":Hp(Lv(this.editor,this.activeTableBlock,!1));break;case"delete-select-col":$p(Lv(this.editor,this.activeTableBlock,!0));break;case"merge-cell":Tv(this.editor.selection.range);break;case"split-cell":this.handleSplitCell();break;case"row-title":this.handleRowTitle(e);break;case"col-title":this.handleColTitle(e);break;case"stripe-style":this.handleStripeStyle(e);break;case"hide-border":PM(this.editor,this.activeTableBlock,o==="show-border");break;case"show-chart":UM(this.editor,this.activeTableBlock,o==="show-chart"),Qp(this.editor,this.activeTableBlock,{updateNow:!0});break}});m(this,"handleToolbarClose",()=>{this.targetButton&&ot(this.targetButton,"active"),this.activeTableBlock&&su(this.editor,this.editor.selection.range)===this.activeTableBlock&&(zi(this.editor,this.activeTableBlock,!1),Vi(this.editor,this.activeTableBlock,!1)),this.editor.focus()});m(this,"handleSelectionChange",(t,e)=>{!t.isVisible||(g(Mn,this.activeTableBlock,"no target table block"),e==="cell-background-color"&&this.handleBeforePopupPalette(),e==="delete-select-row"?(zi(this.editor,this.activeTableBlock,!0,!1),Vi(this.editor,this.activeTableBlock,!0,!1)):e==="delete-select-col"?(zi(this.editor,this.activeTableBlock,!0,!0),Vi(this.editor,this.activeTableBlock,!0,!0)):(zi(this.editor,this.activeTableBlock,!1),Vi(this.editor,this.activeTableBlock,!1)))});m(this,"handleClick",(t,e)=>{var o;g(Mn,this.activeTableBlock,"no target table block"),g(Mn,this.targetButton,"no target button"),N9(this.editor),xt(this.targetButton,"active")?(ot(this.targetButton,"active"),(o=this.manualMenu)==null||o.close("clickItem")):(W(this.targetButton,"active"),this.manualMenu?this.manualMenu.updateItems(this.createCommandMenu()):(this.manualMenu=new Us(this.createCommandMenu()),this.manualMenu.on("click",(r,i)=>{var s;this.handleCommand(i),(s=this.manualMenu)==null||s.close("clickItem")}),this.manualMenu.on("selectionChange",this.handleSelectionChange),this.manualMenu.on("close",this.handleToolbarClose)),this.manualMenu.manualShow(this.targetButton,{placement:"right-start"})),e.stopPropagation()});this.editor=t,this.editor.addListener("selectionChanged",this.handleSelectionChanged),this.editor.addListener("readonlyChanged",this.handleReadonlyChanged)}destroy(){var t,e;this.activeTableBlock=null,this.targetButton=null,this.editor.removeListener("selectionChanged",this.handleSelectionChanged),this.editor.removeListener("readonlyChanged",this.handleReadonlyChanged),(t=this.manualMenu)==null||t.destroy(),(e=this.colorPaletteItem)==null||e.destroy()}hide(){var t;(t=this.manualMenu)==null||t.close("cancelBar"),this.targetButton&&(ot(this.targetButton,"active"),this.targetButton.style.display="none")}getCellByChildBlockId(t,e){let o=this.editor.getBlockById(e);for(;o;){const r=o.closest("td");g(Mn,r,"no parent cell");const i=et(r);if(g(Mn,i,"no parent block"),_e(i)===t.table)return t.getCellByCellElement(r);o=i}return g(Mn,!1,"filed to get cell by child block id"),null}createTargetButton(t){this.targetButton?t.querySelector(`:scope > .${Wp}`)||t.appendChild(this.targetButton):(this.targetButton=w("button",[Wp],t),this.targetButton.innerHTML=Qh,this.editor.domEvents.addEventListener(this.targetButton,"click",this.handleClick),this.editor.domEvents.addEventListener(this.targetButton,"mousedown",this.handlePrevent),this.editor.domEvents.addEventListener(this.targetButton,"dblclick",this.handlePrevent))}showCellMenuButton(t){this.createTargetButton(t.cell),g(Mn,this.targetButton,"no target button"),this.targetButton.style.display="inline-block"}handleSplitCell(){if(this.activeTableBlock){const t=Tt.fromBlock(this.activeTableBlock),e=this.editor.selection.range;if(e.isSimple()){const{col:o,row:r}=this.getCellByChildBlockId(t,e.start.blockId);Up(this.editor,this.activeTableBlock,{col:o,row:r})}else zp(this.editor.selection.range)}}getSelectedBkgColorIndex(){var r;g(Mn,this.activeTableBlock,"no target table block");const t=HM(this.editor,this.activeTableBlock),e=this.editor.getBlockData(this.activeTableBlock),o=new Set;for(const i of t){if(o.size>1)break;const s=ct(i),l=e[`${s}_background`];if(l)o.add(Number.parseInt((r=l.substring(mF.length))!=null?r:"0",10));else{o.add(-1);break}}return o.size===1&&[...o][0]!==-1?[...o][0]:-1}createCommandMenu(){g(Mn,this.activeTableBlock,"no target table block");const t=this.editor.getBlockData(this.activeTableBlock),e=Iv(this.editor,this.activeTableBlock,this.editor.selection.range);let o=this.editor.selection.range;if(o.isSimple()){const h=Jr(this.editor,this.activeTableBlock,o.start);o=Ue(this.editor,{anchor:h,focus:h})}const r=xv(this.editor,this.activeTableBlock,o),i=t.hasRowTitle,s=t.hasColTitle,l=t.isStripeStyle,a=t.noBorder,d=t.chart;return this.colorPaletteItem=new vv("cell-background-color",{color:!1}),this.colorPaletteItem.palette.on("onClick",(h,p)=>{var A;switch(g(Mn,this.activeTableBlock,"no target table block"),h){case"clearColor":Ov(this.editor,this.activeTableBlock,-1);break;case"backgroundColor":Ov(this.editor,this.activeTableBlock,p);break}(A=this.manualMenu)==null||A.close("clickItem")}),[{id:"cell-background-color",name:R.t("table.cellBackground"),element:this.createBkgColorItem(),children:[this.colorPaletteItem]},{id:"separator",name:"",type:"separator"},{id:"merge-cell",name:R.t("table.mergeCell"),states:e?[]:["disabled"]},{id:"split-cell",name:R.t("table.splitCell"),states:r?[]:["disabled"]},{id:"separator",name:"",type:"separator"},{id:"delete-select-row",name:R.t("table.deleteSelectRow")},{id:"delete-select-col",name:R.t("table.deleteSelectCol")},{id:"separator",name:"",type:"separator"},{id:"table-config",name:R.t("table.tableConfigKey"),children:[{id:"row-title",name:R.t("table.tableConfig.rowTitle"),states:i?["checked"]:[]},{id:"col-title",name:R.t("table.tableConfig.colTitle"),states:s?["checked"]:[]},{id:"stripe-style",name:R.t("table.tableConfig.stripeStyle"),states:l?["checked"]:[]},{id:"hide-border",name:a?R.t("table.tableConfig.showBorder"):R.t("table.tableConfig.hideBorder"),value:a?"show-border":"hide-border"},{id:"show-chart",name:d?R.t("table.tableConfig.hideChart"):R.t("table.tableConfig.showChart"),value:d?"hide-chart":"show-chart"}]}]}handleRowTitle(t){g(Mn,this.activeTableBlock,"no target table block"),t?OM(this.editor,this.activeTableBlock):RM(this.editor,this.activeTableBlock)}handleColTitle(t){g(Mn,this.activeTableBlock,"no target table block"),t?MM(this.editor,this.activeTableBlock):LM(this.editor,this.activeTableBlock)}handleStripeStyle(t){g(Mn,this.activeTableBlock,"no target table block"),t?FM(this.editor,this.activeTableBlock):_M(this.editor,this.activeTableBlock)}}function q9(n){n.addCustom("table-cell-menu",t=>new gF(t))}const wf=S("table-container");function D0(n){const t=n.closest("td");return g(wf,t,"no parent cell for a table cell container"),t}function G9(n){const t=_e(n);return Array.from(t.querySelectorAll(':scope > tbody > tr > td > [data-type="editor-container"].child'))}function S0(n,t,e,o){const r=Tt.fromBlock(n),i=r.getCellByContainerId(ct(t));if(e==="ArrowDown"){const s=r.getBottomCell(i);return s?s.container:null}if(e==="ArrowUp"){const s=r.getTopCell(i);return s?s.container:null}if(e==="ArrowLeft"){const s=r.getAllContainers(),l=s.indexOf(t);if(g(wf,l>=0,"not a valid child container"),l===0)return null;const a=s[l-1];return o!=null&&o.noWrap&&r.getCellByContainerId(ct(a)).row!==i.row?null:a}if(e==="ArrowRight"){const s=r.getAllContainers(),l=s.indexOf(t);if(g(wf,l>=0,"not a valid child container"),l===s.length-1)return null;const a=s[l+1];return o!=null&&o.noWrap&&r.getCellByContainerId(ct(a)).row!==i.row?null:a}g(wf,!1,`invalid navigation type: ${e}`)}const pF=12,CF=90,Bf=23,Z9=2;class AF{constructor(t){m(this,"scrollTableBlock",null);m(this,"autoScrollDir",null);m(this,"autoScrollTimer",null);m(this,"handleMouseDown",t=>{const e=document.elementFromPoint(t.clientX,t.clientY);if(e&&e instanceof HTMLElement){const o=et(e);if(o&&Xt(this.editor.rootContainer,o)){const r=Yr(o);r&&(this.scrollTableBlock=r,document.addEventListener("mousemove",this.handleAutoScroll))}}});m(this,"handleAutoScroll",$B.default(t=>{if(this.scrollTableBlock){const e=this.editor.getCustom(mr(this.scrollTableBlock)),o=e.rootElement,r=e.scrollOptions.parentContainer,i=o.getBoundingClientRect(),s=window.innerHeight-this.getBarFloatWindowBottom(e),l=r.getBoundingClientRect(),a=Math.min(l.bottom,s),d=Math.max(l.top,0);i.bottom>a&&t.clientY>=a?this.setAutoScroll("bottom"):i.top<d&&t.clientY<=d?this.setAutoScroll("top"):o.scrollLeft>0&&t.clientX<i.left?this.setAutoScroll("left"):o.scrollLeft<o.scrollWidth-o.offsetWidth&&t.clientX>i.right?this.setAutoScroll("right"):this.clearAutoScroll()}},15));m(this,"handleMouseUp",()=>{document.removeEventListener("mousemove",this.handleAutoScroll),setTimeout(()=>{this.scrollTableBlock=null})});m(this,"handleSelectionChanged",t=>{const e=t.selection.range;if(e.isCollapsed()&&e.isSimple()){const o=t.getBlockById(e.start.blockId),r=Yr(o);if(r){const i=t.getCustom(mr(r)),s=i.rootElement.getBoundingClientRect(),l=So(t,o,e.start);if(s.left>l.left){const a=e.start.offset===0?pF:Z9;i.rootElement.scrollLeft-=s.left-l.left+a}else if(l.right>s.right){const a=e.start.offset===0?CF:Z9;i.rootElement.scrollLeft+=l.right-s.right+a}}}else{const o=t.getBlockById(e.start.blockId),r=Yr(o),i=t.getBlockById(e.end.blockId),s=Yr(i);if(r&&r===s){const l=t.getCustom(mr(r)),a=l.rootElement.getBoundingClientRect();let d=null;if(e.isSimple())d=e.isReverse()?So(t,o,e.start):So(t,i,e.end);else{const h=D0(jr(t,e.start.childContainerId)),p=D0(jr(t,e.end.childContainerId));d=e.isReverse()?h.getBoundingClientRect():p.getBoundingClientRect()}a.left>d.left&&e.isReverse()?l.rootElement.scrollLeft-=a.left-d.left:a.right<d.right&&!e.isReverse()&&(l.rootElement.scrollLeft+=d.right-a.right)}}});m(this,"handleScroll",t=>{wv(t),this.editor.selection.caret.update()});m(this,"handleReset",t=>{wv(t),this.editor.selection.caret.update();const e=this.editor.findCustom("table-border-bar");e&&e.handleScroll(),H9(t)});this.editor=t,this.editor.addListener("selectionChanged",this.handleSelectionChanged),document.addEventListener("mousedown",this.handleMouseDown),document.addEventListener("mouseup",this.handleMouseUp)}getBarFloatWindowBottom(t){return t.scrollOptions.barFloatWindowBottom?typeof t.scrollOptions.barFloatWindowBottom=="number"?t.scrollOptions.barFloatWindowBottom:t.scrollOptions.barFloatWindowBottom():0}clearAutoScroll(){this.autoScrollTimer&&(clearInterval(this.autoScrollTimer),this.autoScrollTimer=null,this.autoScrollDir=null)}setAutoScroll(t){this.autoScrollDir&&this.autoScrollDir!==t&&this.clearAutoScroll(),this.autoScrollTimer||(this.autoScrollDir=t,this.autoScrollTimer=window.setInterval(()=>{if(this.scrollTableBlock){const e=this.editor.getCustom(mr(this.scrollTableBlock)),o=e.rootElement,r=e.scrollOptions.parentContainer,i=o.getBoundingClientRect(),s=r===document.documentElement?window.innerHeight:r.offsetHeight,l=window.innerHeight-this.getBarFloatWindowBottom(e),a=r.getBoundingClientRect(),d=Math.min(a.bottom,l),h=Math.max(a.top,0);this.autoScrollDir==="left"&&(o.scrollLeft-=Bf,o.scrollLeft<=0&&this.clearAutoScroll()),this.autoScrollDir==="right"&&(o.scrollLeft+=Bf,o.scrollLeft>=o.scrollWidth-o.offsetWidth&&this.clearAutoScroll()),this.autoScrollDir==="bottom"&&(r.scrollTop+=Bf,(r.scrollTop>=r.scrollHeight-s||i.bottom<=d)&&this.clearAutoScroll()),this.autoScrollDir==="top"&&(r.scrollTop-=Bf,(r.scrollTop<=0||i.top>=h)&&this.clearAutoScroll())}},100))}destroy(){document.removeEventListener("mousedown",this.handleMouseDown),document.removeEventListener("mouseup",this.handleMouseUp),this.editor.removeListener("selectionChanged",this.handleSelectionChanged)}}function Q9(n){return n.addCustom("table-scroll-events",t=>new AF(t))}const pr=S("create-content");function Y9(n,t,e){const o=new Yh(e),r=e.rows,i=e.cols;g(pr,r>=1,`invalid rows: ${r}`),g(pr,i>=1,`invalid cols: ${i}`),g(pr,e.children,"no table children");const s=w("table",[],null),l=e.colsWidth,a=w("colgroup",[],s);for(let p=0;p<o.colCount;p++){const A=w("col",[],a);l[p]&&(A.style.width=`${l[p]}px`)}const d=w("tbody",[],s);let h=0;for(let p=0;p<r;p++){const A=w("tr",[],d);for(let v=0;v<i;v++){const B=o.getCell({col:v,row:p});if(B.virtual)g(pr,B.colSpan>1||B.rowSpan>1,"virtual cell should have colSpan or rowSpan");else{const D=e.children[h],x=w("td",[],A);B.colSpan>1&&(x.colSpan=B.colSpan),B.rowSpan>1&&(x.rowSpan=B.rowSpan);const _=e[au(D)];_&&W(x,_),v===0&&e.hasColTitle&&W(x,Dv.COL_TITLE_ITEM),n.createChildContainer(t,x,D),h+=1}}}return g(pr,h===e.children.length,"container count mismatch"),e.noBorder&&W(s,"no-border"),e.chart&&W(s,"editor-table-chart"),e.isStripeStyle&&W(s,"stripe"),e.hasRowTitle&&W(s,"row-title"),e.hasColTitle&&W(s,"col-title"),s}function bF(n,t,e,o,r){g(pr,r.type==="table","not table data"),g(pr,ct(e)===t[t.length-1].containerId,"invalid path");const i=r,s=xs(o,"div");try{const l=w("div",[],null);l.setAttribute("data-type","table-content");const a=Y9(n,t,i);a.classList.add("drag-preview-element"),l.appendChild(a),Zv(n),Xv(n),W9(n,"create"),q9(n),XS(n,Yp);const d=n.getComponentOptions("table"),h=n.addCustom(mr(o),()=>fR());h.init({parentElement:s,childElement:l,safeRightSpace:50,safeLeftSpace:40,parentContainer:Yt(e)?n.scrollContainer:e,locatingContainer:Yt(e)?(d==null?void 0:d.locatingContainer)||n.parent:e,paddingLeft:ic+cu,paddingTop:ic+cu,paddingBottom:cu/2,paddingRight:cu/2,barFloatWindowBottom:d==null?void 0:d.barFloatWindowBottom,allowScrollBarFixed:d==null?void 0:d.allowScrollBarFixed,isSetScale:d==null?void 0:d.isSetScale});const p=Q9(n);h.on("scroll",p.handleReset),h.on("resize",p.handleReset),setTimeout(()=>{WM(n,o)})}catch{const a=`invalid table data: ${JSON.stringify(i)}`;pr.error(a);const d=w("div",["error"],s);d.innerText=a}return s}function vF(n,t,e){g(pr,e.type==="table","not table data");const o=e,r=Lt(t);try{const i=_e(t),s=Li(t),l=Y9(n,s,o);l.classList.add("drag-preview-element"),i.insertAdjacentElement("afterend",l),i.remove(),Zv(n),Xv(n),W9(n,"update"),q9(n),Yp(n,t)}catch{const s=`invalid table data: ${JSON.stringify(o)}`;pr.error(s);const l=w("div",["error"],r);l.innerText=s}}function yF(n,t){let e,o,r=!1;if([...t].every(A=>A==="|")?(o=t.length,e=Array(o).fill(""),r=!0):(e=km(t,"|").split("|"),o=e.length),o<2)return null;const i=3,s=o,l=[];for(let A=0;A<3;A++)e.forEach(v=>{l.push(qr(n.doc,A===0?v:""))});const a=Array(s).fill(Xp),d=l[r?0:s],h=n.doc.getContainerBlocks(d)[0].id;return{blockData:{id:K(),type:"table",rows:i,cols:s,children:l,colsWidth:a},focusBlockId:h}}function kF(n,t){const e=t.rows,o=t.cols;if(e<1||o<1)return null;const r=[];for(let d=0;d<e;d++)for(let h=0;h<o;h++)r.push(qr(n.doc));const i=Array(o).fill(Xp),s=r[0],l=n.doc.getContainerBlocks(s)[0].id;return{blockData:{id:K(),type:"table",rows:e,cols:o,children:r,colsWidth:i},focusBlockId:l}}const J9=S("table-selection-to-doc");function wF(n,t){const{start:e,end:o,block:r}=t,i=Dt(r);g(J9,i==="table",`invalid block type: ${i}`);const s=n.getBlockData(r);if(e.isSimple()&&o.isSimple())return Fi(n.editorBlocks,n.doc.toJSON(),s);g(J9,!e.isSimple()&&!o.isSimple(),"invalid block pos type");const l=Tt.fromBlock(r),{fromCol:a,toCol:d,fromRow:h,toRow:p}=Uo(r,e,o),A={},v=[],B=n.doc.toJSON();let D={};l.sub({row:h,col:a},{row:p,col:d}).forEach((rt,ft)=>{rt.forEach((Bt,jt)=>{const Ut=Bt.containerId;if(v.indexOf(Ut)!==-1)return;v.push(Ut);let ne;if(Bt.virtual){const $e=l.getCellByContainerId(Bt.containerId),Rn=a+jt;let wr=$e.col+$e.colSpan-1;wr>d&&(wr=d);const kn=wr-Rn+1;kn>1&&(A[`${Ut}_colSpan`]=kn);const an=h+ft;let Br=$e.row+$e.rowSpan-1;Br>p&&(Br=p);const oi=Br-an+1;oi>1&&(A[`${Ut}_rowSpan`]=oi),ne=Wr()}else{if(ne=Og(n.editorBlocks,B,Ut),Bt.col+Bt.colSpan>d+1){const $e=d-Bt.col+1;$e>1&&(A[`${Ut}_colSpan`]=$e)}else Bt.colSpan>1&&(A[`${Ut}_colSpan`]=Bt.colSpan);if(Bt.row+Bt.rowSpan>p+1){const $e=p-Bt.row+1;$e>1&&(A[`${Ut}_rowSpan`]=$e)}else Bt.rowSpan>1&&(A[`${Ut}_rowSpan`]=Bt.rowSpan)}const{root:qe,...Yn}=ne.blocks;D={...D,...Yn,[Ut]:qe}})});const _=mu(_e(r)).slice(a,d+1);return{blocks:{root:[{id:K(),type:i,children:v,colsWidth:_,rows:p-h+1,cols:d-a+1,...A}],...D},meta:{},comments:{}}}function BF(n,t){if(t.top===0)return!0;for(let e=t.left;e<=t.right;e++)if(n[t.top-1][e]===n[t.top][e])return!1;return!0}function EF(n,t){if(t.left===0)return!0;for(let e=t.top;e<=t.bottom;e++)if(n[e][t.left-1]===n[e][t.left])return!1;return!0}function xF(n,t){if(t.bottom===n.length-1)return!0;for(let e=t.left;e<=t.right;e++)if(n[t.bottom][e]===n[t.bottom+1][e])return!1;return!0}function IF(n,t){if(t.right===n[0].length-1)return!0;for(let e=t.top;e<=t.bottom;e++)if(n[e][t.right]===n[e][t.right+1])return!1;return!0}function TF(n,t,e){const o=t.col,r=t.row,i=e.col,s=e.row,l={left:o,top:r,right:i,bottom:s};let a=!1;do{if(a=!1,!BF(n,l)){l.top--,a=!0;continue}if(!EF(n,l)){l.left--,a=!0;continue}if(!xF(n,l)){l.bottom++,a=!0;continue}if(!IF(n,l)){l.right++,a=!0;continue}}while(a);return l}function DF(n,t,e,o){if(e.custom!==void 0||o.custom!==void 0)return{anchor:e,focus:o};const r=Tt.fromBlock(t),i=r.map(H=>H.containerId),s=r.getCellByContainerId(e.childContainerId),l=r.getCellByContainerId(o.childContainerId),a=Math.min(s.row,l.row),d=Math.max(s.row,l.row),h=Math.min(s.col,l.col),p=Math.max(s.col,l.col),A=TF(i,{row:a,col:h},{row:d,col:p}),v=r.getCell({row:A.top,col:A.left}),B=r.getCell({row:A.bottom,col:A.right}),D=r.getCell({row:A.top,col:A.right}),x=r.getCell({row:A.bottom,col:A.left});let _,M;return s.row<=l.row?s.col<=l.col?(_=v,M=B):(_=D,M=x):s.col<l.col?(_=x,M=D):(_=B,M=v),console.log(`move ${_.col}, ${_.row}, -> ${M.col}, ${M.row}`),{anchor:me(t,_.containerId),focus:me(t,M.containerId)}}function K9(n,t,e){if(e.isSimple())return[_e(t).getBoundingClientRect()];const o=_e(t),r=o.getBoundingClientRect(),{fromCol:i,fromRow:s,toCol:l,toRow:a}=Uo(t,e.start,e.end),d=mu(o),h=d.slice(0,i).reduce((D,x)=>D+x,0),p=h+d.slice(i,l+1).reduce((D,x)=>D+x,0),A=$9(o);let v=A.slice(0,s).reduce((D,x)=>D+x,0);const B=v+A.slice(s,a+1).reduce((D,x)=>D+x,0);if(s===0){const D=aF(n,t);v-=D}return[new DOMRect(r.left+h,r.top+v,p-h,B-v)]}S("table-size");const SF=40;function Ef(n){const t=n.querySelector("td");if(!t)return 0;const e=window.getComputedStyle(t),o=Number.parseInt(e.borderLeft,10),r=Number.parseInt(e.borderRight,10);return(o+r)/2}function LF(n,t,e){const o=qm(n,e.container);return o!==void 0?o+Ef(t):SF*e.colSpan-Ef(t)}function MF(n,t,e,o){let r=0;const i=e.colCount;for(let s=0;s<i;s++){const l=e.getCell({col:s,row:o});if(l.virtual)continue;let a=LF(n,t,l);const d=A4(l.container,{withPadding:!0});d&&d>a&&(a=d),r+=a+Ef(t)}return r}function RF(n,t){const e=_e(t),o=Tt.fromTable(e);let r=0;for(let s=0;s<o.rowCount;s++)r=Math.max(r,MF(n,e,o,s));const i=Ef(e);return r+=i,r}const Kr=S("table-creator");async function OF(n,t){return n.undoManager.runInGroup(()=>{var a,d;const e=t.item,o=(a=e.colCount)!=null?a:5,r=(d=e.rowCount)!=null?d:3,i=kF(n,{cols:o,rows:r});if(!i)return null;const{blockData:s,focusBlockId:l}=i;return n.insertBlock(t.containerId,t.blockIndex,s,ke(n,l,0))})}class _F{constructor(){m(this,"id","insert-table");m(this,"name","Create table");m(this,"element");m(this,"closeable",null);m(this,"colCount");m(this,"rowCount");m(this,"setCloseable",t=>{this.closeable=t});m(this,"destroy",()=>{this.closeable=null});m(this,"getTableCreatorCellId",(t,e)=>`table-creator-cell-${t}-${e}`);m(this,"handleTableCreatorClick",t=>{var A,v;t.preventDefault(),t.stopPropagation();const e=t.target;g(Kr,e instanceof HTMLElement,"invalid event target");const o=e.closest(".table-creator");g(Kr,o,"no table creator");const r=o.querySelectorAll(".active");if(r.length===0)return;const s=r[r.length-1].id;g(Kr,s,"no cell id");const l="table-creator-cell-";if(!s.startsWith(l))return;const d=s.substring(l.length).split("-");g(Kr,d.length===2,"invalid cell id");const h=Number.parseInt(d[0],10)+1,p=Number.parseInt(d[1],10)+1;Kr.debug(`${h}, ${p}`),this.colCount=p,this.rowCount=h,(A=this.closeable)==null||A.click(this,this.element),(v=this.closeable)==null||v.close("clickItem"),this.handleTableCreatorLeave()});m(this,"handleTableCreatorLeave",()=>{for(let t=0;t<9;t++)for(let e=0;e<9;e++){const o=this.getTableCreatorCellId(t,e),r=document.getElementById(o);r&&ot(r,"active")}});m(this,"handleTableCreatorCellEnter",t=>{const e=t.target;g(Kr,e instanceof HTMLElement,"invalid event target");const o=e.id,r="table-creator-cell-";g(Kr,o.startsWith(r),"invalid cell id");const s=o.substring(r.length).split("-");g(Kr,s.length===2,"invalid cell id");let l=Number.parseInt(s[0],10),a=Number.parseInt(s[1],10);l===0&&a===0&&(l=-1,a=-1);for(let d=0;d<9;d++)for(let h=0;h<9;h++){const p=this.getTableCreatorCellId(d,h),A=document.getElementById(p);g(Kr,A,"no cell"),d<=l&&h<=a?W(A,"active"):ot(A,"active")}});this.element=this.createTableCreatorElement()}createTableCreatorElement(){const t=w("div",["table-creator"],null),e=(o,r,i)=>{const s=w("div",["table-creator-cell"],o);return s.id=this.getTableCreatorCellId(r,i),s};t.addEventListener("click",this.handleTableCreatorClick),t.addEventListener("mouseleave",this.handleTableCreatorLeave);for(let o=0;o<9;o++){const r=w("div",["table-creator-row"],t);for(let i=0;i<9;i++)e(r,o,i).addEventListener("mouseenter",this.handleTableCreatorCellEnter)}return t}}function FF(){return new _F}function PF(n){const t=/[\u4e00-\u9fff\u3040-\u309f\u30a0-\u30ff\uac00-\ud7af]/g,e=n.match(t);return e?e.length:0}function X9(n){const t=PF(n);return n.length+t}function NF(n,t){const e=X9(n),o=t-e;return o>0?n+" ".repeat(o):n}function $F(n,t,e,o,r){const i=t,s=new Yh(i);if(o==="markdown"||o==="text"){const l=x=>e.blocks[x].map((H,z)=>o==="markdown"?Bg(n,H,e,[...r,{containerId:x,blockIndex:z}]):vh(n,H,e,[...r,{containerId:x,blockIndex:z}])),a=x=>l(x).join(" ").replace(/\n/g," ").trim(),d=new Map,h=new Map;for(let x=0;x<s.colCount;x++){let _=0;for(let M=0;M<s.rowCount;M++){const H=s.getCell({row:M,col:x});let z="";H.virtual||(z=a(H.containerId)),d.set(`${M},${x}`,z),_=Math.max(_,X9(z))}h.set(x,_)}const p=x=>{const _=d.get(`${x.row},${x.col}`)||"",M=h.get(x.col)||0;return NF(_,M)},A=[];let v="|",B="|";for(let x=0;x<s.colCount;x++){const _=p({row:0,col:x});v+=` ${_} |`;const M="-".repeat((h.get(x)||0)+2);B+=`${M}|`}A.push(v),A.push(B);for(let x=1;x<s.rowCount;x++){let _="|";for(let M=0;M<s.colCount;M++){const H=p({row:x,col:M});_+=` ${H} |`}A.push(_)}return`${A.join(`
399
+ `:r.mathjaxText}function N_(){return{abstract:R.t("mathjax.abstract")}}const $_={embedType:"math",createEmbedContent:R_,getOptions:__,convertFrom:O_,handleDeleteBlock:F_,convertTo:P_,getBlockProperties:N_},Tnt="",H_={mathjax:{emptyText:"\u7A7A\u7684\u516C\u5F0F",abstract:"\u516C\u5F0F"}},j_={mathjax:{emptyText:"Empty formula",abstract:"Formula"}},U_={mathjax:{emptyText:"\u6570\u5F0F\u306A\u3057",abstract:"\u6570\u5F0F"}};R.mergeLang({"zh-CN":H_,"en-US":j_,"ja-JP":U_});function z_(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o);if(!ie(s).endsWith("$$$$"))return!1;const a=o-4,d=o,h={id:K(),box:!0,type:"math",tex:" ",src:"",created:Date.now()};return n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,a,d-a),n.insertBoxToBlock(r,a,h),setTimeout(()=>{const p=n.getBoxById(h.id);Cf(n,p)})}),!0}class V_{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&z_(t,e,o,r))}}const pc=S("inline-box-items");function W_(n,t,e){return n.undoManager.runInGroup(()=>{var s;let o=n.getBlockByIndex(t,e);ae(n,o)||(o=n.insertTextBlock([],t,e));const r=R9();n.setBlockText(o,[r]);const i=(s=r.attributes)==null?void 0:s.id;return g(pc,i,"mathjax box id is empty"),setTimeout(()=>{const l=n.getBoxById(i);Cf(n,l)},100),o})}function q_(n,t,e){let o=n.getBlockByIndex(t,e),r="bottom-start";return ae(n,o)||(r="top-start"),gu(n,{target:o,linkText:"",linkUrl:"",onFinished:(l,a)=>{n.undoManager.runInGroup(()=>{try{ae(n,o)||(o=n.insertTextBlock([],t,e));const d=co(l,{link:a}),h=co(" ",null),p=[d,h];n.insertTextToBlock(o,0,p),n.selection.selectBlock(o,rn(p)),n.focus()}catch(d){pc.error(d)}})},onClose:()=>{n.focus()},placement:r}),o}function G_(n,t,e){return n.undoManager.runInGroup(()=>{var l;const o=n.getBlockByIndex(t,e),r=n.selection.range;g(pc,Ur(r.start),"invalid block position");const i=R9();n.insertBoxToBlock(o,r.start.offset,i.attributes);const s=(l=i.attributes)==null?void 0:l.id;return g(pc,s,"mathjax box id is empty"),setTimeout(()=>{const a=n.getBoxById(s);Cf(n,a)},100),o})}function Z_(n,t,e){const o=n.getBlockByIndex(t,e),r=n.selection.range;g(pc,Ur(r.start),"invalid block position");const i=Nr(n,o,r);if(i.length===0)return;const s=i[0],l=zr(n,o,"quick-menu-inline-link",s);gu(n,{target:l,linkText:"",linkUrl:"",onFinished:(h,p)=>{n.undoManager.runInGroup(()=>{try{const A=n.getBlockText(o),v=Vr(A,r.start.offset,h,{link:p});n.setBlockText(o,v),n.selection.selectBlock(o,r.start.offset+h.length),n.focus()}catch(A){pc.error(A)}})},onClose:()=>{n.focus()},placement:"bottom-start"})}class F9{getCommands(){return[{id:"insert-math",name:R.t("quickMenu.inlineBox.math"),icon:EL,order:900,group:"common",subText:An("insert-math")},{id:"insert-link",name:R.t("quickMenu.inlineBox.link"),icon:av,order:400,group:"common",subText:An("insert-link")}]}async handleUpdateBlockCore(t,e){switch(e.item.id){case"insert-math":return G_(t,e.containerId,e.blockIndex);case"insert-link":return Z_(t,e.containerId,e.blockIndex);default:return null}}async handleInsertEmptyBlockCore(t,e){switch(e.item.id){case"insert-math":return W_(t,e.containerId,e.blockIndex);case"insert-link":return q_(t,e.containerId,e.blockIndex);default:return null}}async executeCommand(t,e,o){if(o.from==="quick-menu"){const r=t.getBlockById(o.blockId),i=t.getParentContainer(r),s=ct(i),l=t.getBlockIndex(r);t.undoManager.runInGroup(()=>this.handleUpdateBlockCore(t,{item:e,containerId:s,blockIndex:l}))}else o.from==="block-menu"&&t.undoManager.runInGroup(()=>this.handleInsertEmptyBlockCore(t,{item:e,containerId:o.containerId,blockIndex:o.blockIndex}));return null}}function Q_(n,t={withPlainText:!1}){var i,s;const{withPlainText:e}=t,o=(s=(i=n.options.componentsOptions)==null?void 0:i.quickMenu)==null?void 0:s.commandProviders;if(!o)return[];const r=[];return[...o,new I9(e),new F9].forEach(l=>{const a=l.getCommands(n);r.push(...a.map(d=>({...d,itemType:"insert-block",commandProvider:l})))}),r}function Y_(n,t={withPlainText:!1}){const e=[];return n.editorBlocks.forEach(o=>{if(!o.getOptions)return;const r=o.getOptions(n);!r.insertBlockCommandItems||(r.insertBlockCommandItems.forEach(i=>{x9(i,r)}),e.push(...r.insertBlockCommandItems))}),e.push(...Q_(n,t)),e}function x0(n,t={withPlainText:!1}){const e=Y_(n,t),o=new Map;e.forEach(s=>{var d;const l=(d=s.group)!=null?d:"";let a=o.get(l);a?a.items.push(s):(a={group:l,order:s.groupOrder||T9[l]||1e3,items:[s]},o.set(l,a))});const r=Array.from(o.values());r.sort((s,l)=>s.order-l.order),r.forEach(s=>{s.items.sort((l,a)=>{var d,h;return((d=l.order)!=null?d:0)-((h=a.order)!=null?h:0)})});const i=[];return r.forEach((s,l)=>{const a=`blockMenu.section.${s.group||"common"}`,d=R.t(a),h=d===a?s.group:d;i.push({id:`section-${l}`,name:h,type:"section",group:s.group,itemType:"insert-block"}),i.push(...s.items.map(p=>({...p})))}),i}function J_(n,t,e){const o=n.getFocusedBlock();if(!o)return;const r=n.getParentContainer(o),i=ct(r);let l=n.getBlockIndex(o);if(ae(n,o)||(l+=1),t.commandProvider){t.commandProvider.executeCommand(n,t,{from:"quick-menu",...e});return}!t.blockOptions||!t.blockOptions.handleInsertEmptyBlock||t.blockOptions.handleInsertEmptyBlock(n,{containerId:i,blockIndex:l,item:t})}const P9=S("quick-menu"),K_={id:"quick-menu",trigger:["/"]},X_=5;class Af{constructor(t,e=K_){m(this,"suggest");m(this,"items");m(this,"maxHeading");m(this,"firstEmptyOffset",-1);m(this,"queryItems",async(t,e)=>{if(this.items.length===0?this.initMenuItems():this.refreshMenuItems(),e){const o=new Set,r=e.toLocaleLowerCase().replace(/^\s+|\s+$/g,""),i=this.items.filter(s=>{if(s.type==="section")return!0;if(s.name.toLocaleLowerCase().indexOf(r)!==-1||pM(s).toLocaleLowerCase().indexOf(r)!==-1)return o.add(s.group),!0;const l=`blockMenu.section.${s.group||"common"}`,a=R.t(l),d=a===l?s.group:a;return(d==null?void 0:d.toLocaleLowerCase().indexOf(r))!==-1?(o.add(s.group),!0):!1}).filter(s=>s.type==="section"?o.has(s.group):!0);return i.length?this.firstEmptyOffset=-1:this.handleEmptySearch(),i}return this.items});m(this,"onClose",()=>{this.firstEmptyOffset=-1});m(this,"onShow",(t,e,o,r)=>{const i=this.editor.getBlockByIndex(e,o);if(!io(i)){const s=et(nt(i));if(s&&Dt(s)==="code")return!1}return!0});m(this,"onClickItem",(t,e)=>{const o=e;o.itemType==="insert-block"&&(g(P9,o.blockOptions||o.commandProvider,"invalid quick item, no block options or command provider"),g(P9,this.suggest.anchor,"invalid suggest, no anchor"),this.options.id==="empty-block-menu"&&this.editor.focus(),J_(this.editor,o,this.suggest.anchor))});this.editor=t,this.options=e,this.items=[],this.maxHeading=cf(),this.suggest=new Fp(t,{id:e.id||"quick-menu",trigger:e.trigger,needSpaceBeforeTrigger:!0,autoDeleteTrigger:!0,highlight:!0,onClose:this.onClose,onShow:this.onShow,onClickItem:this.onClickItem,queryItems:this.queryItems})}get menu(){return this.suggest.menu.menu}destroy(){this.suggest.destroy()}initMenuItems(){const t=x0(this.editor);this.items=t}refreshMenuItems(){let t=null,e=0;const o=cf();if(o!==this.maxHeading){const r=new I9,s=r.getCommands().map(l=>({...l,itemType:"insert-block",commandProvider:r}));for(let l=0;l<this.items.length;l++)this.items[l].group==="basics"&&(t||(t=l),t&&e++);t&&e&&this.items.splice(t,e,...s),this.maxHeading=o}}handleEmptySearch(){const t=this.editor.selection.getFocusedPos();if(this.firstEmptyOffset===-1){if(t.isSimple()){const{offset:e}=t;this.firstEmptyOffset=e-1}}else if(t.isSimple()){const{offset:e}=t;e-this.firstEmptyOffset>X_&&(this.suggest.close(),this.firstEmptyOffset=-1)}}}class bf{constructor(t){m(this,"instance");m(this,"mousedown",!1);m(this,"currentInstance",null);m(this,"attributeName",[]);m(this,"attributeDesc","");m(this,"observer",null);m(this,"observerCallback",null);m(this,"createContent",t=>{let e="",o=0;for(;o<this.attributeName.length&&!e;)t.hasAttribute(this.attributeName[o])&&(e=t.getAttribute(this.attributeName[o])||""),o++;const r=t.getAttribute(this.attributeDesc);if(!r)return e;const i=w("div",[],null);return w("span",[],i,e),r&&w("span",["editor-tooltip-desc"],i,r),i});m(this,"handleDocumentMouseDown",()=>{this.mousedown=!0,this.editor.domEvents.addEventListener(document,"mouseup",this.handleDocumentMouseUp)});m(this,"handleDocumentMouseUp",()=>{this.mousedown=!1,this.editor.domEvents.removeEventListener(document,"mouseup",this.handleDocumentMouseUp)});m(this,"handleShown",t=>{this.currentInstance&&this.hide(),this.currentInstance=t,this.createObserver()});m(this,"handleHidden",()=>{this.destroyObserver(),this.currentInstance=null});m(this,"handleShow",t=>{var r;const e=t.reference;if(!e||!Xt(document.body,e)||window.isDragging||this.mousedown)return!1;const o=Number.parseInt((r=e.getAttribute("data-tooltip-hide-at"))!=null?r:"",10);if(o&&Date.now()-o<1e3)return!1;if(t.reference){const i={};if(t.reference.hasAttribute("data-editor-tooltip-placement")&&(i.placement=t.reference.getAttribute("data-editor-tooltip-placement")||"top"),t.reference.hasAttribute("data-editor-tooltip-offset-x")||t.reference.hasAttribute("data-editor-tooltip-offset-y")){const s=t.reference.getAttribute("data-editor-tooltip-offset-x"),l=t.reference.getAttribute("data-editor-tooltip-offset-y");i.offset=[s?Number.parseInt(s,10):0,l?Number.parseInt(l,10):0]}if(t.reference.hasAttribute("data-editor-tooltip-maxwidth")&&(i.maxWidth=Number.parseInt(t.reference.getAttribute("data-editor-tooltip-maxwidth")||"350",10)),t.reference.hasAttribute("data-editor-tooltip-allow-markdown")&&(i.allowHTML=!0),Object.keys(i).length&&t.setProps(i),t.reference.hasAttribute(`data-editor-tooltip-${this.editor.clientId}-dynamic`)){const s=t.reference.getAttribute(`data-editor-tooltip-${this.editor.clientId}-dynamic`);t.setContent(s||"")}}return!0});this.editor=t;const e=t.clientId;this.attributeName=[`data-editor-tooltip-${e}`,`data-editor-tooltip-${e}-dynamic`,"data-editor-tooltip-common"],this.attributeDesc=`data-editor-tooltip-desc-${e}`,this.instance=am.delegate(document.body,{theme:"editor-tooltip",maxWidth:400,delay:200,target:this.attributeName.map(o=>`[${o}]`).join(","),content:this.createContent,onShow:this.handleShow,onShown:this.handleShown,onHide:this.handleHidden}),t.domEvents.addEventListener(document,"mousedown",this.handleDocumentMouseDown)}visible(){var t;return(t=this.currentInstance)==null?void 0:t.state.isVisible}hide(){var t;(t=this.currentInstance)!=null&&t.state.isVisible&&this.currentInstance.hide()}destroy(){this.destroyObserver(),this.instance.destroy(),this.editor.domEvents.removeEventListener(document,"mousedown",this.handleDocumentMouseDown),this.editor.domEvents.removeEventListener(document,"mouseup",this.handleDocumentMouseUp)}createObserver(){this.destroyObserver();const t=this.currentInstance;if(!t||!t.reference)return;this.observerCallback=Le.default(()=>{t.reference.closest("body")||(t.hide(),this.destroyObserver())},200),this.observer=new MutationObserver(this.observerCallback);const e=document.body,o={childList:!0,attributes:!1,subtree:!0};this.observer.observe(e,o)}destroyObserver(){this.observer&&(this.observer.disconnect(),this.observer=null),this.observerCallback&&(this.observerCallback.cancel(),this.observerCallback=null)}}const tF={"text/style-bold":"bold","text/style-italic":"italic","text/style-underline":"underline","text/style-strikethrough":"line-through","text/style-code":"code","text/style-sub":"subscript","text/style-super":"superscript"};function eF(n,t){const e=new Set(Object.keys(tF)),o=t.filter(i=>e.has(i.id));return sf(o)}function vf(n,t){if(!n.isWritable())return!1;const e=n.selection.range,o=n.editorCommandProviders.getCommands(e),i=eF(n,o).find(s=>s.id===`text/${t}`);return i?(n.editorCommandProviders.executeCommand(e,i,{}),gc.get(n).update("selectionChange"),!0):!1}const I0={"CtrlOrCmd+B":n=>vf(n,"style-bold"),"CtrlOrCmd+I":n=>vf(n,"style-italic"),"CtrlOrCmd+U":n=>vf(n,"style-underline"),"CtrlOrCmd+D":n=>vf(n,"style-strikethrough")},nF={quickMenu:{basic:{heading:{title:"\u6807\u9898 {heading}",space:"{markdown}\u7A7A\u683C"},unordered:"\u65E0\u5E8F\u5217\u8868",ordered:"\u6709\u5E8F\u5217\u8868",checkbox:"\u5F85\u529E\u4E8B\u9879",quote:"\u5F15\u7528"},inlineBox:{math:"\u516C\u5F0F",link:"\u94FE\u63A5"}},link:{textLabel:"\u6587\u672C",urlLabel:"\u94FE\u63A5\u5730\u5740",textPlaceholder:"\u8BF7\u8F93\u5165\u6587\u672C",urlPlaceholder:"\u8BF7\u8F93\u5165\u94FE\u63A5\u5730\u5740",submitText:"\u786E\u5B9A",cancelText:"\u53D6\u6D88",edit:"\u7F16\u8F91",remove:"\u53D6\u6D88\u94FE\u63A5"},commands:{unordered:"\u65E0\u5E8F\u5217\u8868",ordered:"\u6709\u5E8F\u5217\u8868",check:"\u5F85\u529E\u5217\u8868",link:"\u94FE\u63A5",quote:"\u5F15\u7528",alignLeft:"\u5DE6\u5BF9\u9F50",alignRight:"\u53F3\u5BF9\u9F50",alignCenter:"\u5C45\u4E2D\u5BF9\u9F50",alignGroup:"\u5BF9\u9F50\u65B9\u5F0F",heading:"\u6807\u9898 {name}",headingGroup:"\u6807\u9898\u6837\u5F0F",text:"\u6B63\u6587"}},oF={quickMenu:{basic:{heading:{title:"Title {heading}",space:"{markdown}space"},unordered:"Bulleted list",ordered:"Numbered list",checkbox:"To-do list",quote:"Quote"},inlineBox:{math:"Formula",link:"Link"}},link:{textLabel:"Text",urlLabel:"Link address",textPlaceholder:"Please enter text",urlPlaceholder:"Please enter link",submitText:"Confirm",cancelText:"Cancel",edit:"Edit",remove:"Remove link"},commands:{unordered:"Bulleted list",ordered:"Numberer list",check:"To-do list",link:"Link",quote:"Quote",alignLeft:"Align left",alignRight:"Align right",alignCenter:"Center text",alignGroup:"Alignment",heading:"Title {name}",headingGroup:"Text style",text:"Text"}},rF={quickMenu:{basic:{heading:{title:"\u898B\u51FA\u3057{heading}",space:"{markdown}\u30B9\u30DA\u30FC\u30B9"},unordered:"\u7B87\u6761\u66F8\u304D\u30EA\u30B9\u30C8",ordered:"\u756A\u53F7\u4ED8\u304D\u30EA\u30B9\u30C8",checkbox:"\u30D0\u30C3\u30AF\u30ED\u30B0",quote:"\u5F15\u7528"},inlineBox:{math:"\u6570\u5F0F",link:"URL"}},link:{textLabel:"\u30C6\u30AD\u30B9\u30C8",urlLabel:"URL",textPlaceholder:"\u30C6\u30AD\u30B9\u30C8\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",urlPlaceholder:"URL \u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",submitText:"OK",cancelText:"\u30AD\u30E3\u30F3\u30BB\u30EB",edit:"\u7DE8\u96C6",remove:"\u30EA\u30F3\u30AF\u3092\u89E3\u9664"},commands:{unordered:"\u7B87\u6761\u66F8\u304D\u30EA\u30B9\u30C8",ordered:"\u756A\u53F7\u4ED8\u304D\u30EA\u30B9\u30C8",check:"\u30D0\u30C3\u30AF\u30ED\u30B0",link:"URL",quote:"\u5F15\u7528",alignLeft:"\u5DE6\u63C3\u3048",alignRight:"\u53F3\u63C3\u3048",alignCenter:"\u4E2D\u592E\u63C3\u3048",alignGroup:"\u5BF9\u9F50\u65B9\u5F0F",heading:"\u898B\u51FA\u3057{name}",headingGroup:"\u30BF\u30A4\u30C8\u30EB\u30B9\u30BF\u30A4\u30EB",text:"\u672C\u6587"}};R.mergeLang({"zh-CN":nF,"en-US":oF,"ja-JP":rF});const Dnt="";function Zs(n,...t){const e=uo(...t);return e.classList.remove("editor-button"),e.classList.add("editor-text-button"),n.append(e),e}function N9(n){const t=lf(n);t==null||t.hide();const e=n.findCustom("table-border-bar");e==null||e.closeToolbar()}function iF(n){return w("div",["insert-column-button","drop-marker"],n)}const sF=S("row-height");function $9(n){const t=Tt.fromTable(n),e=n.rows;g(sF,e.length===t.rowCount,"row count mismatch");const o=Array(t.rowCount).fill(0);for(let r=0;r<e.length;){let i=1,l=e[r].getBoundingClientRect().height,a=r+1;for(;a<e.length;){const d=e[a];if(d.cells.length!==0)break;i++,a++,l+=d.getBoundingClientRect().height}for(let d=0;d<i;d++)o[r+d]=l/i;r=a}return o}const lF=S("table-border-bar-dom");function H9(n){var a;const t=et(n.contentElement);g(lF,t,"no block");const o=te(t).querySelector(".table-border-bar-container.left"),i=Lt(t).offsetLeft-ic,s=((a=n.scrollOptions.paddingLeft)!=null?a:0)+i,l=Math.min(n.contentElement.offsetLeft-i,n.rootElement.scrollLeft-s);o&&(o.style.left=`${-l}px`)}const Zi=S("table-border-bar-dom");function Cc(n,t){g(Zi,Ve(t),"invalid table block");const e=_e(t),o=gr(n,t),r=te(t),i=(p,A,v)=>{const B=w("div",["button-root",A],p),D=w("div",["button-container",A],B);B.setAttribute(`data-${A}-index`,`${v}`),D.setAttribute(`data-editor-tooltip-${n.clientId}`,A==="left"?R.t("table.insertRow"):R.t("table.insertCol")),w("span",["insert-indicator"],D),iF(D)},{selectedRows:s,selectedColumns:l}=Np(n,t),a=()=>{const p=o.querySelector(".table-border-bar-container.top");g(Zi,p,"no top border bar container");const A=w("div",["table-border-bar-container","top"],null),v=w("div",["table-border-bar","top"],A),B=gR(e),x=Tt.fromTable(e).colCount;n.selection.range.isSimple()&&i(v,"top",0);for(let _=0;_<x;_++){const M=_===x-1?B[_]+2:B[_],H=w("span",["table-border-bar-cell","top"],v);l.has(_)&&H.classList.add("selected"),H.setAttribute("data-top-index",`${_}`),H.style.width=`${M}px`,n.selection.range.isSimple()&&i(v,"top",_+1)}pa(p,A)},d=()=>{const p=r.querySelector(".table-border-bar-container.left");g(Zi,p,"no left border bar container");const A=w("div",["table-border-bar-container","left"],null),v=w("div",["table-border-bar","left"],A);w("span",["table-border-bar-cell","corner"],v);const B=$9(e);n.selection.range.isSimple()&&i(v,"left",0),Array.from(e.rows).forEach((D,x,_)=>{const M=w("span",["table-border-bar-cell","left"],v);s.has(x)&&M.classList.add("selected"),M.setAttribute("data-left-index",`${x}`);const H=x===_.length-1?B[x]+2:B[x];M.style.height=`${H}px`,n.selection.range.isSimple()&&i(v,"left",x+1)}),pa(p,A)};a(),d();const h=n.findCustom(mr(t));h&&H9(h)}function j9(n,t){const e=t.target;if(!(e instanceof Element))return;const o=et(e);g(Zi,o&&Ve(o),"invalid table block"),Cc(n,o),n.selection.caret.update()}function yf(n,t){const e=t.target;if(!(e instanceof Element))return;const o=et(e);g(Zi,o&&Ve(o),"invalid table block");const r=e.closest(".button-root");if(r){if(r.classList.contains("top")){const i=parseInt(r.getAttribute("data-top-index")||"0",10);Yv(n,o,i),Cc(n,o)}else if(r.classList.contains("left")){const i=parseInt(r.getAttribute("data-left-index")||"0",10);Jv(n,o,i),Cc(n,o)}}}function kf(n,t){var s;N9(n),t.preventDefault(),t.stopPropagation();let e=null,o,r;const i=l=>{var a;if(l.target instanceof HTMLElement&&o&&e&&r!==void 0){const d=et(l.target),h=l.target.closest(".table-border-bar");if(d===e&&h){const p=parseInt((a=l.target.getAttribute(`data-${o}-index`))!=null?a:"0",10),A=Math.min(r,p),v=Math.abs(r-p)+1;xt(l.target,"top")&&o==="top"?DR(n,d,A,v,{reverse:!0}):xt(l.target,"left")&&o==="left"&&SR(n,d,A,v,{reverse:!0})}}l.type==="mouseup"&&(e=null,r=void 0,o=void 0,document.body.removeEventListener("mousemove",i),document.body.removeEventListener("mouseup",i))};t.target instanceof HTMLElement&&xt(t.target,"table-border-bar-cell")&&(e=et(t.target),xt(t.target,"top")?o="top":xt(t.target,"left")&&(o="left"),o&&e&&(r=parseInt((s=t.target.getAttribute(`data-${o}-index`))!=null?s:"0",10),document.body.addEventListener("mousemove",i),document.body.addEventListener("mouseup",i)))}function U9(n){const t=n.selection.range,e=su(n,t);e&&Cc(n,e)}function cF(n,t){g(Zi,Ve(t),"invalid table block");const e=gr(n,t),o=te(t),r=w("div",["table-border-bar-container","top"],e),i=w("div",["table-border-bar-container","left"],o);Cc(n,t),n.domEvents.addEventListener(Lt(t),"scroll",j9),n.domEvents.addEventListener(r,"click",yf),n.domEvents.addEventListener(i,"click",yf),n.domEvents.addEventListener(r,"mousedown",kf),n.domEvents.addEventListener(i,"mousedown",kf),n.addListener("afterClearSelection",U9)}function z9(n,t){if(!n.isWritable())return;if(gr(n,t).querySelector(".table-border-bar-container")){Cc(n,t);return}cF(n,t)}function V9(n,t){g(Zi,Ve(t),"invalid table block");const e=gr(n,t),o=te(t),r=e.querySelectorAll(".table-border-bar-container"),i=o.querySelectorAll(".table-border-bar-container");r.forEach(s=>{n.domEvents.removeEventListener(s,"click",yf),n.domEvents.removeEventListener(s,"mousedown",kf),s.remove()}),i.forEach(s=>{n.domEvents.removeEventListener(s,"click",yf),n.domEvents.removeEventListener(s,"mousedown",kf),s.remove()}),n.domEvents.removeEventListener(Lt(t),"scroll",j9),n.addListener("afterClearSelection",U9)}function aF(n,t){g(Zi,Ve(t),"invalid table block");const o=gr(n,t).querySelector(".table-border-bar-container.top");return o?o.getBoundingClientRect().height:0}class uF{constructor(t,e){m(this,"toolbar");m(this,"handleSelectionChange",(t,e)=>{!t.isVisible||(e==="delete-columns"?(zi(this.editor,this.tableBlock,!0,!0),Vi(this.editor,this.tableBlock,!0,!0)):e==="delete-rows"?(zi(this.editor,this.tableBlock,!0,!1),Vi(this.editor,this.tableBlock,!0,!1)):(zi(this.editor,this.tableBlock,!1),Vi(this.editor,this.tableBlock,!1)))});m(this,"handleClick",(t,e,o)=>{e.id==="delete-columns"?$p(this.editor.selection.range):e.id==="delete-rows"&&Hp(this.editor.selection.range)});m(this,"handleToolbarClose",()=>{this.tableBlock&&su(this.editor,this.editor.selection.range)===this.tableBlock&&(zi(this.editor,this.tableBlock,!1),Vi(this.editor,this.tableBlock,!1))});this.editor=t,this.tableBlock=e;const o=t.options.componentsOptions.popover;this.toolbar=new ou([],void 0,{id:"table-row-column-toolbar",overflowBoundary:o==null?void 0:o.overflowBoundary,refuseOverflow:!0,tooltipId:this.editor.clientId}),this.toolbar.addListener("selectionChange",this.handleSelectionChange),this.toolbar.addListener("click",this.handleClick),this.toolbar.addListener("close",this.handleToolbarClose)}close(){this.toolbar.close("cancelBar")}update(){var r,i,s;const{selectedColumns:t,selectedRows:e}=Np(this.editor,this.tableBlock);if(!this.editor.isWritable())return;if(t.size>0&&e.size>0){this.toolbar.close("cancelBar");return}if(t.size===0&&e.size===0){this.toolbar.close("cancelBar");return}const o=Nr(this.editor,this.tableBlock,this.editor.selection.range)[0];if(!o){this.toolbar.close("cancelBar");return}if(t.size>0){const l={id:"delete-columns",name:R.t("table.deleteCol"),icon:hL};this.toolbar.updateItems([l]);const a=zr(this.editor,this.tableBlock,"table-row-column-delete",o);this.toolbar.manualShow(a,{placement:"top",offset:[0,5]})}else{const l={id:"delete-rows",name:R.t("table.deleteRow"),icon:dL};this.toolbar.updateItems([l]);const h=te(this.tableBlock).querySelector(".table-border-bar-container.left").getBoundingClientRect(),p=new DOMRect(Math.max(h.left,o.left-ic),o.top,ic,o.height),A=zr(this.editor,this.tableBlock,"table-row-column-delete",p);this.toolbar.manualShow(A,{placement:"left",offset:[0,5]});const v=this.editor.options.componentsOptions.popover;(r=this.toolbar.tippyInstance)==null||r.setProps({popperOptions:{modifiers:[{name:"flip",options:{boundary:v==null?void 0:v.overflowBoundary,fallbackPlacements:["left","right"]}}]}})}(s=(i=this.toolbar.tippyInstance)==null?void 0:i.popperInstance)==null||s.update()}destroy(){this.toolbar.destroy(),this.toolbar.removeAllListeners()}}const T0=S("table-border-bar");class dF{constructor(t,e){m(this,"toolbar");m(this,"resizeObserver");m(this,"handleReadonlyChanged",t=>{t.isWritable()?this.update():V9(this.editor,this.tableBlock)});m(this,"handleBlockUpdated",()=>{this.resizeObserver.disconnect(),setTimeout(()=>{const t=this.editor.getBlockById(it(this.tableBlock));this.resizeObserver.observe(_e(t))})});m(this,"handleScroll",()=>{var t;(t=this.toolbar)==null||t.update()});m(this,"handleTableResize",()=>{!this.editor.isWritable()||(console.log("resize"),this.update())});this.editor=t,this.tableBlock=e,g(T0,this.tableBlock,"no table block"),T0.debug("create table border bar"),z9(this.editor,this.tableBlock),this.resizeObserver=new ResizeObserver(this.handleTableResize),this.resizeObserver.observe(_e(this.tableBlock));const o=t.getComponentOptions("table");o!=null&&o.hideToolbar||(this.toolbar=new uF(this.editor,this.tableBlock)),this.editor.addListener("readonlyChanged",this.handleReadonlyChanged)}close(){var t;(t=this.toolbar)==null||t.close()}destroy(){var t;T0.debug("destroy table border bar"),this.resizeObserver.disconnect(),V9(this.editor,this.tableBlock),(t=this.toolbar)==null||t.destroy(),this.editor.removeListener("readonlyChanged",this.handleReadonlyChanged)}update(){var t;z9(this.editor,this.tableBlock),(t=this.toolbar)==null||t.update()}}const hF=S("table-border-bar");class fF{constructor(t){m(this,"activeTableBar",null);m(this,"handleBlockDeleted",(t,e)=>{!this.activeTableBar||(e===this.activeTableBar.tableBlock||Xt(e,this.activeTableBar.tableBlock))&&(this.activeTableBar.destroy(),this.activeTableBar=null)});m(this,"handleSelectionChanged",t=>{var r;const e=t.selection.range,o=su(t,e);((r=this.activeTableBar)==null?void 0:r.tableBlock)!==o&&this.activeTableBar&&this.hide(),o&&this.show(o)});m(this,"handleScroll",()=>{var t;(t=this.activeTableBar)==null||t.handleScroll()});this.editor=t,this.editor.addListener("blockDeleted",this.handleBlockDeleted),this.editor.addListener("selectionChanged",this.handleSelectionChanged)}destroy(){this.editor.removeListener("blockDeleted",this.handleBlockDeleted),this.editor.removeListener("selectionChanged",this.handleSelectionChanged)}show(t){this.activeTableBar?(this.activeTableBar.tableBlock!==t&&this.hide(),this.activeTableBar.update()):this.activeTableBar=new dF(this.editor,t)}update(){var t;(t=this.activeTableBar)==null||t.handleBlockUpdated()}closeToolbar(){var t;(t=this.activeTableBar)==null||t.close()}hide(){!this.activeTableBar||(g(hF,this.activeTableBar,"no active table bar"),this.activeTableBar.destroy(),this.activeTableBar=null)}}function W9(n,t){const e=n.addCustom("table-border-bar",o=>new fF(o));t==="update"&&e.update()}const Mn=S("table-cell-menu"),mF="style-bg-color-";class gF{constructor(t){m(this,"activeTableBlock",null);m(this,"targetButton",null);m(this,"manualMenu",null);m(this,"colorPaletteItem",null);m(this,"handlePrevent",(t,e)=>{e.stopPropagation()});m(this,"handleReadonlyChanged",t=>{t.isWritable()||this.hide()});m(this,"handleSelectionChanged",t=>{const e=t.selection.range,o=su(t,e);if(this.hide(),this.activeTableBlock!==o&&(this.activeTableBlock=o),this.activeTableBlock){const r=Tt.fromBlock(this.activeTableBlock),i=e.isReverse()?e.start:e.end;let s=null;i instanceof Mo?t.getBlockById(i.blockId)===this.activeTableBlock?s=r.getCellByContainerId(i.childContainerId):s=this.getCellByChildBlockId(r,i.blockId):i.blockId!==this.activeTableBlock.id&&(s=this.getCellByChildBlockId(r,i.blockId)),s&&this.editor.isWritable()&&this.showCellMenuButton(s)}});m(this,"handleBeforePopupPalette",()=>{var e;const t=this.getSelectedBkgColorIndex();(e=this.colorPaletteItem)==null||e.palette.setColor("backgroundColor",t)});m(this,"createBkgColorItem",()=>{const t=w("div",["cell-background-color-item"],null);w("span",[],t,R.t("table.cellBackground"));const e=this.getSelectedBkgColorIndex();w("button",["item-button"],t).setAttribute("data-color-index",`${e}`);const r=w("span",["item-sub-indicator"],t);return r.innerHTML=rv,t});m(this,"handleCommand",t=>{var r;g(Mn,this.activeTableBlock,"no target table block");const e=((r=t.states)==null?void 0:r.includes("checked"))||!1,o=t.value;switch(t.id){case"delete-select-row":Hp(Lv(this.editor,this.activeTableBlock,!1));break;case"delete-select-col":$p(Lv(this.editor,this.activeTableBlock,!0));break;case"merge-cell":Tv(this.editor.selection.range);break;case"split-cell":this.handleSplitCell();break;case"row-title":this.handleRowTitle(e);break;case"col-title":this.handleColTitle(e);break;case"stripe-style":this.handleStripeStyle(e);break;case"hide-border":PM(this.editor,this.activeTableBlock,o==="show-border");break;case"show-chart":UM(this.editor,this.activeTableBlock,o==="show-chart"),Qp(this.editor,this.activeTableBlock,{updateNow:!0});break}});m(this,"handleToolbarClose",()=>{this.targetButton&&ot(this.targetButton,"active"),this.activeTableBlock&&su(this.editor,this.editor.selection.range)===this.activeTableBlock&&(zi(this.editor,this.activeTableBlock,!1),Vi(this.editor,this.activeTableBlock,!1)),this.editor.focus()});m(this,"handleSelectionChange",(t,e)=>{!t.isVisible||(g(Mn,this.activeTableBlock,"no target table block"),e==="cell-background-color"&&this.handleBeforePopupPalette(),e==="delete-select-row"?(zi(this.editor,this.activeTableBlock,!0,!1),Vi(this.editor,this.activeTableBlock,!0,!1)):e==="delete-select-col"?(zi(this.editor,this.activeTableBlock,!0,!0),Vi(this.editor,this.activeTableBlock,!0,!0)):(zi(this.editor,this.activeTableBlock,!1),Vi(this.editor,this.activeTableBlock,!1)))});m(this,"handleClick",(t,e)=>{var o;g(Mn,this.activeTableBlock,"no target table block"),g(Mn,this.targetButton,"no target button"),N9(this.editor),xt(this.targetButton,"active")?(ot(this.targetButton,"active"),(o=this.manualMenu)==null||o.close("clickItem")):(W(this.targetButton,"active"),this.manualMenu?this.manualMenu.updateItems(this.createCommandMenu()):(this.manualMenu=new Us(this.createCommandMenu()),this.manualMenu.on("click",(r,i)=>{var s;this.handleCommand(i),(s=this.manualMenu)==null||s.close("clickItem")}),this.manualMenu.on("selectionChange",this.handleSelectionChange),this.manualMenu.on("close",this.handleToolbarClose)),this.manualMenu.manualShow(this.targetButton,{placement:"right-start"})),e.stopPropagation()});this.editor=t,this.editor.addListener("selectionChanged",this.handleSelectionChanged),this.editor.addListener("readonlyChanged",this.handleReadonlyChanged)}destroy(){var t,e;this.activeTableBlock=null,this.targetButton=null,this.editor.removeListener("selectionChanged",this.handleSelectionChanged),this.editor.removeListener("readonlyChanged",this.handleReadonlyChanged),(t=this.manualMenu)==null||t.destroy(),(e=this.colorPaletteItem)==null||e.destroy()}hide(){var t;(t=this.manualMenu)==null||t.close("cancelBar"),this.targetButton&&(ot(this.targetButton,"active"),this.targetButton.style.display="none")}getCellByChildBlockId(t,e){let o=this.editor.getBlockById(e);for(;o;){const r=o.closest("td");g(Mn,r,"no parent cell");const i=et(r);if(g(Mn,i,"no parent block"),_e(i)===t.table)return t.getCellByCellElement(r);o=i}return g(Mn,!1,"filed to get cell by child block id"),null}createTargetButton(t){this.targetButton?t.querySelector(`:scope > .${Wp}`)||t.appendChild(this.targetButton):(this.targetButton=w("button",[Wp],t),this.targetButton.innerHTML=Qh,this.editor.domEvents.addEventListener(this.targetButton,"click",this.handleClick),this.editor.domEvents.addEventListener(this.targetButton,"mousedown",this.handlePrevent),this.editor.domEvents.addEventListener(this.targetButton,"dblclick",this.handlePrevent))}showCellMenuButton(t){this.createTargetButton(t.cell),g(Mn,this.targetButton,"no target button"),this.targetButton.style.display="inline-block"}handleSplitCell(){if(this.activeTableBlock){const t=Tt.fromBlock(this.activeTableBlock),e=this.editor.selection.range;if(e.isSimple()){const{col:o,row:r}=this.getCellByChildBlockId(t,e.start.blockId);Up(this.editor,this.activeTableBlock,{col:o,row:r})}else zp(this.editor.selection.range)}}getSelectedBkgColorIndex(){var r;g(Mn,this.activeTableBlock,"no target table block");const t=HM(this.editor,this.activeTableBlock),e=this.editor.getBlockData(this.activeTableBlock),o=new Set;for(const i of t){if(o.size>1)break;const s=ct(i),l=e[`${s}_background`];if(l)o.add(Number.parseInt((r=l.substring(mF.length))!=null?r:"0",10));else{o.add(-1);break}}return o.size===1&&[...o][0]!==-1?[...o][0]:-1}createCommandMenu(){g(Mn,this.activeTableBlock,"no target table block");const t=this.editor.getBlockData(this.activeTableBlock),e=Iv(this.editor,this.activeTableBlock,this.editor.selection.range);let o=this.editor.selection.range;if(o.isSimple()){const h=Jr(this.editor,this.activeTableBlock,o.start);o=Ue(this.editor,{anchor:h,focus:h})}const r=xv(this.editor,this.activeTableBlock,o),i=t.hasRowTitle,s=t.hasColTitle,l=t.isStripeStyle,a=t.noBorder,d=t.chart;return this.colorPaletteItem=new vv("cell-background-color",{color:!1}),this.colorPaletteItem.palette.on("onClick",(h,p)=>{var A;switch(g(Mn,this.activeTableBlock,"no target table block"),h){case"clearColor":Ov(this.editor,this.activeTableBlock,-1);break;case"backgroundColor":Ov(this.editor,this.activeTableBlock,p);break}(A=this.manualMenu)==null||A.close("clickItem")}),[{id:"cell-background-color",name:R.t("table.cellBackground"),element:this.createBkgColorItem(),children:[this.colorPaletteItem]},{id:"separator",name:"",type:"separator"},{id:"merge-cell",name:R.t("table.mergeCell"),states:e?[]:["disabled"]},{id:"split-cell",name:R.t("table.splitCell"),states:r?[]:["disabled"]},{id:"separator",name:"",type:"separator"},{id:"delete-select-row",name:R.t("table.deleteSelectRow")},{id:"delete-select-col",name:R.t("table.deleteSelectCol")},{id:"separator",name:"",type:"separator"},{id:"table-config",name:R.t("table.tableConfigKey"),children:[{id:"row-title",name:R.t("table.tableConfig.rowTitle"),states:i?["checked"]:[]},{id:"col-title",name:R.t("table.tableConfig.colTitle"),states:s?["checked"]:[]},{id:"stripe-style",name:R.t("table.tableConfig.stripeStyle"),states:l?["checked"]:[]},{id:"hide-border",name:a?R.t("table.tableConfig.showBorder"):R.t("table.tableConfig.hideBorder"),value:a?"show-border":"hide-border"},{id:"show-chart",name:d?R.t("table.tableConfig.hideChart"):R.t("table.tableConfig.showChart"),value:d?"hide-chart":"show-chart"}]}]}handleRowTitle(t){g(Mn,this.activeTableBlock,"no target table block"),t?OM(this.editor,this.activeTableBlock):RM(this.editor,this.activeTableBlock)}handleColTitle(t){g(Mn,this.activeTableBlock,"no target table block"),t?MM(this.editor,this.activeTableBlock):LM(this.editor,this.activeTableBlock)}handleStripeStyle(t){g(Mn,this.activeTableBlock,"no target table block"),t?FM(this.editor,this.activeTableBlock):_M(this.editor,this.activeTableBlock)}}function q9(n){n.addCustom("table-cell-menu",t=>new gF(t))}const wf=S("table-container");function D0(n){const t=n.closest("td");return g(wf,t,"no parent cell for a table cell container"),t}function G9(n){const t=_e(n);return Array.from(t.querySelectorAll(':scope > tbody > tr > td > [data-type="editor-container"].child'))}function S0(n,t,e,o){const r=Tt.fromBlock(n),i=r.getCellByContainerId(ct(t));if(e==="ArrowDown"){const s=r.getBottomCell(i);return s?s.container:null}if(e==="ArrowUp"){const s=r.getTopCell(i);return s?s.container:null}if(e==="ArrowLeft"){const s=r.getAllContainers(),l=s.indexOf(t);if(g(wf,l>=0,"not a valid child container"),l===0)return null;const a=s[l-1];return o!=null&&o.noWrap&&r.getCellByContainerId(ct(a)).row!==i.row?null:a}if(e==="ArrowRight"){const s=r.getAllContainers(),l=s.indexOf(t);if(g(wf,l>=0,"not a valid child container"),l===s.length-1)return null;const a=s[l+1];return o!=null&&o.noWrap&&r.getCellByContainerId(ct(a)).row!==i.row?null:a}g(wf,!1,`invalid navigation type: ${e}`)}const pF=12,CF=90,Bf=23,Z9=2;class AF{constructor(t){m(this,"scrollTableBlock",null);m(this,"autoScrollDir",null);m(this,"autoScrollTimer",null);m(this,"handleMouseDown",t=>{const e=document.elementFromPoint(t.clientX,t.clientY);if(e&&e instanceof HTMLElement){const o=et(e);if(o&&Xt(this.editor.rootContainer,o)){const r=Yr(o);r&&(this.scrollTableBlock=r,document.addEventListener("mousemove",this.handleAutoScroll))}}});m(this,"handleAutoScroll",$B.default(t=>{if(this.scrollTableBlock){const e=this.editor.getCustom(mr(this.scrollTableBlock)),o=e.rootElement,r=e.scrollOptions.parentContainer,i=o.getBoundingClientRect(),s=window.innerHeight-this.getBarFloatWindowBottom(e),l=r.getBoundingClientRect(),a=Math.min(l.bottom,s),d=Math.max(l.top,0);i.bottom>a&&t.clientY>=a?this.setAutoScroll("bottom"):i.top<d&&t.clientY<=d?this.setAutoScroll("top"):o.scrollLeft>0&&t.clientX<i.left?this.setAutoScroll("left"):o.scrollLeft<o.scrollWidth-o.offsetWidth&&t.clientX>i.right?this.setAutoScroll("right"):this.clearAutoScroll()}},15));m(this,"handleMouseUp",()=>{document.removeEventListener("mousemove",this.handleAutoScroll),setTimeout(()=>{this.scrollTableBlock=null})});m(this,"handleSelectionChanged",t=>{const e=t.selection.range;if(e.isCollapsed()&&e.isSimple()){const o=t.getBlockById(e.start.blockId),r=Yr(o);if(r){const i=t.getCustom(mr(r)),s=i.rootElement.getBoundingClientRect(),l=So(t,o,e.start);if(s.left>l.left){const a=e.start.offset===0?pF:Z9;i.rootElement.scrollLeft-=s.left-l.left+a}else if(l.right>s.right){const a=e.start.offset===0?CF:Z9;i.rootElement.scrollLeft+=l.right-s.right+a}}}else{const o=t.getBlockById(e.start.blockId),r=Yr(o),i=t.getBlockById(e.end.blockId),s=Yr(i);if(r&&r===s){const l=t.getCustom(mr(r)),a=l.rootElement.getBoundingClientRect();let d=null;if(e.isSimple())d=e.isReverse()?So(t,o,e.start):So(t,i,e.end);else{const h=D0(jr(t,e.start.childContainerId)),p=D0(jr(t,e.end.childContainerId));d=e.isReverse()?h.getBoundingClientRect():p.getBoundingClientRect()}a.left>d.left&&e.isReverse()?l.rootElement.scrollLeft-=a.left-d.left:a.right<d.right&&!e.isReverse()&&(l.rootElement.scrollLeft+=d.right-a.right)}}});m(this,"handleScroll",t=>{wv(t),this.editor.selection.caret.update()});m(this,"handleReset",t=>{wv(t),this.editor.selection.caret.update();const e=this.editor.findCustom("table-border-bar");e&&e.handleScroll(),H9(t)});this.editor=t,this.editor.addListener("selectionChanged",this.handleSelectionChanged),document.addEventListener("mousedown",this.handleMouseDown),document.addEventListener("mouseup",this.handleMouseUp)}getBarFloatWindowBottom(t){return t.scrollOptions.barFloatWindowBottom?typeof t.scrollOptions.barFloatWindowBottom=="number"?t.scrollOptions.barFloatWindowBottom:t.scrollOptions.barFloatWindowBottom():0}clearAutoScroll(){this.autoScrollTimer&&(clearInterval(this.autoScrollTimer),this.autoScrollTimer=null,this.autoScrollDir=null)}setAutoScroll(t){this.autoScrollDir&&this.autoScrollDir!==t&&this.clearAutoScroll(),this.autoScrollTimer||(this.autoScrollDir=t,this.autoScrollTimer=window.setInterval(()=>{if(this.scrollTableBlock){const e=this.editor.getCustom(mr(this.scrollTableBlock)),o=e.rootElement,r=e.scrollOptions.parentContainer,i=o.getBoundingClientRect(),s=r===document.documentElement?window.innerHeight:r.offsetHeight,l=window.innerHeight-this.getBarFloatWindowBottom(e),a=r.getBoundingClientRect(),d=Math.min(a.bottom,l),h=Math.max(a.top,0);this.autoScrollDir==="left"&&(o.scrollLeft-=Bf,o.scrollLeft<=0&&this.clearAutoScroll()),this.autoScrollDir==="right"&&(o.scrollLeft+=Bf,o.scrollLeft>=o.scrollWidth-o.offsetWidth&&this.clearAutoScroll()),this.autoScrollDir==="bottom"&&(r.scrollTop+=Bf,(r.scrollTop>=r.scrollHeight-s||i.bottom<=d)&&this.clearAutoScroll()),this.autoScrollDir==="top"&&(r.scrollTop-=Bf,(r.scrollTop<=0||i.top>=h)&&this.clearAutoScroll())}},100))}destroy(){document.removeEventListener("mousedown",this.handleMouseDown),document.removeEventListener("mouseup",this.handleMouseUp),this.editor.removeListener("selectionChanged",this.handleSelectionChanged)}}function Q9(n){return n.addCustom("table-scroll-events",t=>new AF(t))}const pr=S("create-content");function Y9(n,t,e){const o=new Yh(e),r=e.rows,i=e.cols;g(pr,r>=1,`invalid rows: ${r}`),g(pr,i>=1,`invalid cols: ${i}`),g(pr,e.children,"no table children");const s=w("table",[],null),l=e.colsWidth,a=w("colgroup",[],s);for(let p=0;p<o.colCount;p++){const A=w("col",[],a);l[p]&&(A.style.width=`${l[p]}px`)}const d=w("tbody",[],s);let h=0;for(let p=0;p<r;p++){const A=w("tr",[],d);for(let v=0;v<i;v++){const B=o.getCell({col:v,row:p});if(B.virtual)g(pr,B.colSpan>1||B.rowSpan>1,"virtual cell should have colSpan or rowSpan");else{const D=e.children[h],x=w("td",[],A);B.colSpan>1&&(x.colSpan=B.colSpan),B.rowSpan>1&&(x.rowSpan=B.rowSpan);const _=e[au(D)];_&&W(x,_),v===0&&e.hasColTitle&&W(x,Dv.COL_TITLE_ITEM),n.createChildContainer(t,x,D),h+=1}}}return g(pr,h===e.children.length,"container count mismatch"),e.noBorder&&W(s,"no-border"),e.chart&&W(s,"editor-table-chart"),e.isStripeStyle&&W(s,"stripe"),e.hasRowTitle&&W(s,"row-title"),e.hasColTitle&&W(s,"col-title"),s}function bF(n,t,e,o,r){g(pr,r.type==="table","not table data"),g(pr,ct(e)===t[t.length-1].containerId,"invalid path");const i=r,s=xs(o,"div");try{const l=w("div",[],null);l.setAttribute("data-type","table-content");const a=Y9(n,t,i);a.classList.add("drag-preview-element"),l.appendChild(a);const d=n.getComponentOptions("table");Zv(n),Xv(n),W9(n,"create"),d!=null&&d.hideCellMenu||q9(n),XS(n,Yp);const h=n.addCustom(mr(o),()=>fR());h.init({parentElement:s,childElement:l,safeRightSpace:50,safeLeftSpace:40,parentContainer:Yt(e)?n.scrollContainer:e,locatingContainer:Yt(e)?(d==null?void 0:d.locatingContainer)||n.parent:e,paddingLeft:ic+cu,paddingTop:ic+cu,paddingBottom:cu/2,paddingRight:cu/2,barFloatWindowBottom:d==null?void 0:d.barFloatWindowBottom,allowScrollBarFixed:d==null?void 0:d.allowScrollBarFixed,isSetScale:d==null?void 0:d.isSetScale});const p=Q9(n);h.on("scroll",p.handleReset),h.on("resize",p.handleReset),setTimeout(()=>{WM(n,o)})}catch{const a=`invalid table data: ${JSON.stringify(i)}`;pr.error(a);const d=w("div",["error"],s);d.innerText=a}return s}function vF(n,t,e){g(pr,e.type==="table","not table data");const o=e,r=Lt(t);try{const i=_e(t),s=Li(t),l=Y9(n,s,o);l.classList.add("drag-preview-element"),i.insertAdjacentElement("afterend",l),i.remove();const a=n.getComponentOptions("table");Zv(n),Xv(n),W9(n,"update"),a!=null&&a.hideCellMenu||q9(n),Yp(n,t)}catch{const s=`invalid table data: ${JSON.stringify(o)}`;pr.error(s);const l=w("div",["error"],r);l.innerText=s}}function yF(n,t){let e,o,r=!1;if([...t].every(A=>A==="|")?(o=t.length,e=Array(o).fill(""),r=!0):(e=km(t,"|").split("|"),o=e.length),o<2)return null;const i=3,s=o,l=[];for(let A=0;A<3;A++)e.forEach(v=>{l.push(qr(n.doc,A===0?v:""))});const a=Array(s).fill(Xp),d=l[r?0:s],h=n.doc.getContainerBlocks(d)[0].id;return{blockData:{id:K(),type:"table",rows:i,cols:s,children:l,colsWidth:a},focusBlockId:h}}function kF(n,t){const e=t.rows,o=t.cols;if(e<1||o<1)return null;const r=[];for(let d=0;d<e;d++)for(let h=0;h<o;h++)r.push(qr(n.doc));const i=Array(o).fill(Xp),s=r[0],l=n.doc.getContainerBlocks(s)[0].id;return{blockData:{id:K(),type:"table",rows:e,cols:o,children:r,colsWidth:i},focusBlockId:l}}const J9=S("table-selection-to-doc");function wF(n,t){const{start:e,end:o,block:r}=t,i=Dt(r);g(J9,i==="table",`invalid block type: ${i}`);const s=n.getBlockData(r);if(e.isSimple()&&o.isSimple())return Fi(n.editorBlocks,n.doc.toJSON(),s);g(J9,!e.isSimple()&&!o.isSimple(),"invalid block pos type");const l=Tt.fromBlock(r),{fromCol:a,toCol:d,fromRow:h,toRow:p}=Uo(r,e,o),A={},v=[],B=n.doc.toJSON();let D={};l.sub({row:h,col:a},{row:p,col:d}).forEach((rt,ft)=>{rt.forEach((Bt,jt)=>{const Ut=Bt.containerId;if(v.indexOf(Ut)!==-1)return;v.push(Ut);let ne;if(Bt.virtual){const $e=l.getCellByContainerId(Bt.containerId),Rn=a+jt;let wr=$e.col+$e.colSpan-1;wr>d&&(wr=d);const kn=wr-Rn+1;kn>1&&(A[`${Ut}_colSpan`]=kn);const an=h+ft;let Br=$e.row+$e.rowSpan-1;Br>p&&(Br=p);const oi=Br-an+1;oi>1&&(A[`${Ut}_rowSpan`]=oi),ne=Wr()}else{if(ne=Og(n.editorBlocks,B,Ut),Bt.col+Bt.colSpan>d+1){const $e=d-Bt.col+1;$e>1&&(A[`${Ut}_colSpan`]=$e)}else Bt.colSpan>1&&(A[`${Ut}_colSpan`]=Bt.colSpan);if(Bt.row+Bt.rowSpan>p+1){const $e=p-Bt.row+1;$e>1&&(A[`${Ut}_rowSpan`]=$e)}else Bt.rowSpan>1&&(A[`${Ut}_rowSpan`]=Bt.rowSpan)}const{root:qe,...Yn}=ne.blocks;D={...D,...Yn,[Ut]:qe}})});const _=mu(_e(r)).slice(a,d+1);return{blocks:{root:[{id:K(),type:i,children:v,colsWidth:_,rows:p-h+1,cols:d-a+1,...A}],...D},meta:{},comments:{}}}function BF(n,t){if(t.top===0)return!0;for(let e=t.left;e<=t.right;e++)if(n[t.top-1][e]===n[t.top][e])return!1;return!0}function EF(n,t){if(t.left===0)return!0;for(let e=t.top;e<=t.bottom;e++)if(n[e][t.left-1]===n[e][t.left])return!1;return!0}function xF(n,t){if(t.bottom===n.length-1)return!0;for(let e=t.left;e<=t.right;e++)if(n[t.bottom][e]===n[t.bottom+1][e])return!1;return!0}function IF(n,t){if(t.right===n[0].length-1)return!0;for(let e=t.top;e<=t.bottom;e++)if(n[e][t.right]===n[e][t.right+1])return!1;return!0}function TF(n,t,e){const o=t.col,r=t.row,i=e.col,s=e.row,l={left:o,top:r,right:i,bottom:s};let a=!1;do{if(a=!1,!BF(n,l)){l.top--,a=!0;continue}if(!EF(n,l)){l.left--,a=!0;continue}if(!xF(n,l)){l.bottom++,a=!0;continue}if(!IF(n,l)){l.right++,a=!0;continue}}while(a);return l}function DF(n,t,e,o){if(e.custom!==void 0||o.custom!==void 0)return{anchor:e,focus:o};const r=Tt.fromBlock(t),i=r.map(H=>H.containerId),s=r.getCellByContainerId(e.childContainerId),l=r.getCellByContainerId(o.childContainerId),a=Math.min(s.row,l.row),d=Math.max(s.row,l.row),h=Math.min(s.col,l.col),p=Math.max(s.col,l.col),A=TF(i,{row:a,col:h},{row:d,col:p}),v=r.getCell({row:A.top,col:A.left}),B=r.getCell({row:A.bottom,col:A.right}),D=r.getCell({row:A.top,col:A.right}),x=r.getCell({row:A.bottom,col:A.left});let _,M;return s.row<=l.row?s.col<=l.col?(_=v,M=B):(_=D,M=x):s.col<l.col?(_=x,M=D):(_=B,M=v),console.log(`move ${_.col}, ${_.row}, -> ${M.col}, ${M.row}`),{anchor:me(t,_.containerId),focus:me(t,M.containerId)}}function K9(n,t,e){if(e.isSimple())return[_e(t).getBoundingClientRect()];const o=_e(t),r=o.getBoundingClientRect(),{fromCol:i,fromRow:s,toCol:l,toRow:a}=Uo(t,e.start,e.end),d=mu(o),h=d.slice(0,i).reduce((D,x)=>D+x,0),p=h+d.slice(i,l+1).reduce((D,x)=>D+x,0),A=$9(o);let v=A.slice(0,s).reduce((D,x)=>D+x,0);const B=v+A.slice(s,a+1).reduce((D,x)=>D+x,0);if(s===0){const D=aF(n,t);v-=D}return[new DOMRect(r.left+h,r.top+v,p-h,B-v)]}S("table-size");const SF=40;function Ef(n){const t=n.querySelector("td");if(!t)return 0;const e=window.getComputedStyle(t),o=Number.parseInt(e.borderLeft,10),r=Number.parseInt(e.borderRight,10);return(o+r)/2}function LF(n,t,e){const o=qm(n,e.container);return o!==void 0?o+Ef(t):SF*e.colSpan-Ef(t)}function MF(n,t,e,o){let r=0;const i=e.colCount;for(let s=0;s<i;s++){const l=e.getCell({col:s,row:o});if(l.virtual)continue;let a=LF(n,t,l);const d=A4(l.container,{withPadding:!0});d&&d>a&&(a=d),r+=a+Ef(t)}return r}function RF(n,t){const e=_e(t),o=Tt.fromTable(e);let r=0;for(let s=0;s<o.rowCount;s++)r=Math.max(r,MF(n,e,o,s));const i=Ef(e);return r+=i,r}const Kr=S("table-creator");async function OF(n,t){return n.undoManager.runInGroup(()=>{var a,d;const e=t.item,o=(a=e.colCount)!=null?a:5,r=(d=e.rowCount)!=null?d:3,i=kF(n,{cols:o,rows:r});if(!i)return null;const{blockData:s,focusBlockId:l}=i;return n.insertBlock(t.containerId,t.blockIndex,s,ke(n,l,0))})}class _F{constructor(){m(this,"id","insert-table");m(this,"name","Create table");m(this,"element");m(this,"closeable",null);m(this,"colCount");m(this,"rowCount");m(this,"setCloseable",t=>{this.closeable=t});m(this,"destroy",()=>{this.closeable=null});m(this,"getTableCreatorCellId",(t,e)=>`table-creator-cell-${t}-${e}`);m(this,"handleTableCreatorClick",t=>{var A,v;t.preventDefault(),t.stopPropagation();const e=t.target;g(Kr,e instanceof HTMLElement,"invalid event target");const o=e.closest(".table-creator");g(Kr,o,"no table creator");const r=o.querySelectorAll(".active");if(r.length===0)return;const s=r[r.length-1].id;g(Kr,s,"no cell id");const l="table-creator-cell-";if(!s.startsWith(l))return;const d=s.substring(l.length).split("-");g(Kr,d.length===2,"invalid cell id");const h=Number.parseInt(d[0],10)+1,p=Number.parseInt(d[1],10)+1;Kr.debug(`${h}, ${p}`),this.colCount=p,this.rowCount=h,(A=this.closeable)==null||A.click(this,this.element),(v=this.closeable)==null||v.close("clickItem"),this.handleTableCreatorLeave()});m(this,"handleTableCreatorLeave",()=>{for(let t=0;t<9;t++)for(let e=0;e<9;e++){const o=this.getTableCreatorCellId(t,e),r=document.getElementById(o);r&&ot(r,"active")}});m(this,"handleTableCreatorCellEnter",t=>{const e=t.target;g(Kr,e instanceof HTMLElement,"invalid event target");const o=e.id,r="table-creator-cell-";g(Kr,o.startsWith(r),"invalid cell id");const s=o.substring(r.length).split("-");g(Kr,s.length===2,"invalid cell id");let l=Number.parseInt(s[0],10),a=Number.parseInt(s[1],10);l===0&&a===0&&(l=-1,a=-1);for(let d=0;d<9;d++)for(let h=0;h<9;h++){const p=this.getTableCreatorCellId(d,h),A=document.getElementById(p);g(Kr,A,"no cell"),d<=l&&h<=a?W(A,"active"):ot(A,"active")}});this.element=this.createTableCreatorElement()}createTableCreatorElement(){const t=w("div",["table-creator"],null),e=(o,r,i)=>{const s=w("div",["table-creator-cell"],o);return s.id=this.getTableCreatorCellId(r,i),s};t.addEventListener("click",this.handleTableCreatorClick),t.addEventListener("mouseleave",this.handleTableCreatorLeave);for(let o=0;o<9;o++){const r=w("div",["table-creator-row"],t);for(let i=0;i<9;i++)e(r,o,i).addEventListener("mouseenter",this.handleTableCreatorCellEnter)}return t}}function FF(){return new _F}function PF(n){const t=/[\u4e00-\u9fff\u3040-\u309f\u30a0-\u30ff\uac00-\ud7af]/g,e=n.match(t);return e?e.length:0}function X9(n){const t=PF(n);return n.length+t}function NF(n,t){const e=X9(n),o=t-e;return o>0?n+" ".repeat(o):n}function $F(n,t,e,o,r){const i=t,s=new Yh(i);if(o==="markdown"||o==="text"){const l=x=>e.blocks[x].map((H,z)=>o==="markdown"?Bg(n,H,e,[...r,{containerId:x,blockIndex:z}]):vh(n,H,e,[...r,{containerId:x,blockIndex:z}])),a=x=>l(x).join(" ").replace(/\n/g," ").trim(),d=new Map,h=new Map;for(let x=0;x<s.colCount;x++){let _=0;for(let M=0;M<s.rowCount;M++){const H=s.getCell({row:M,col:x});let z="";H.virtual||(z=a(H.containerId)),d.set(`${M},${x}`,z),_=Math.max(_,X9(z))}h.set(x,_)}const p=x=>{const _=d.get(`${x.row},${x.col}`)||"",M=h.get(x.col)||0;return NF(_,M)},A=[];let v="|",B="|";for(let x=0;x<s.colCount;x++){const _=p({row:0,col:x});v+=` ${_} |`;const M="-".repeat((h.get(x)||0)+2);B+=`${M}|`}A.push(v),A.push(B);for(let x=1;x<s.rowCount;x++){let _="|";for(let M=0;M<s.colCount;M++){const H=p({row:x,col:M});_+=` ${H} |`}A.push(_)}return`${A.join(`
400
400
  `)}
401
401
  `}if(o==="html"){const l=d=>e.blocks[d].map((A,v)=>wg(n,A,e,[...r,{containerId:d,blockIndex:v}])).join(`
402
402
  `),a=[];a.push("<table>");for(let d=0;d<s.rowCount;d++){let h="<tr>";for(let p=0;p<s.colCount;p++){const A=s.getCell({row:d,col:p});if(!A.virtual){const v=l(A.containerId);h+=`<td colSpan="${A.colSpan}" rowSpan="${A.rowSpan}">${v}</td>`}}h+="</tr>",a.push(h)}return a.push("</table>"),a.join(`
403
- `)}return""}const Au=S("table-block");function HF(n){return 1}function jF(n){return!!n.closest(`.${Wp}`)}function UF(n,t,e,o){const r=document.elementsFromPoint(e,o)[0];if(!r||!t.contains(r)||!n.contains(t))return null;let i=r;if(jF(r)&&(i=r.closest("td"),g(Au,i instanceof HTMLTableCellElement,"invalid element")),i instanceof HTMLTableCellElement){const a=_e(t);if(yv(a).indexOf(i)!==-1){const h=iu(i),p=me(t,ct(h));return new ir(n,{anchor:p,focus:p})}}if(!Pr(r))return null;const s=r;if(G9(t).indexOf(s)===-1)return null;const l=me(t,ct(s));return new ir(n,{anchor:l,focus:l})}function zF(n,t,e,o){return null}function VF(n,t){return n.getBoundingClientRect()}function t7(n,t,e,o){if(e.isSimple()){g(Au,o.isSimple(),"from is simple position but to is not simple position"),Au.debug("full select table"),W(t,"full-selected");return}g(Au,!o.isSimple(),"from is complex position but end is simple position");const r=Jr(n,t,e),i=Jr(n,t,o);g(Au,r.blockId===i.blockId,"only allow update one table selection"),NM(n,r,i).forEach(l=>{const a=D0(l);W(a,"selected")})}function WF(n){n.rootContainer.querySelectorAll('[data-type="editor-block"][data-block-type="table"]').forEach(t=>{ot(t,"full-selected"),t.querySelectorAll("td.selected").forEach(e=>{ot(e,"selected")})})}function qF(n,t){return kv(t)?G9(t):[]}function GF(n,t,e,o,r){return S0(t,e,o,r)}function ZF(n,t){return RF(n,t)}function QF(n,t){return tt(n,t)?yF(n,n.getBlockString(t).trim()):null}function YF(n){return{name:"TableBlock",insertBlockCommandItems:[{id:"insert-table",name:R.t("table.title"),order:200,icon:xL,children:[FF()],group:"common",subText:An("insert-table")}],handleInsertEmptyBlock:OF}}function JF(n,t,e){return vF(n,t,e),setTimeout(()=>{const o=n.selection.range;o.isSimple()?n.selection.caret.update():t7(n,t,o.start,o.end)}),!0}function KF(n,t){let e=0;const{selectedColumns:o}=Np(n,t);if(o.size>0){const{fromCol:i,toCol:s}=Uo(t,n.selection.range.start,n.selection.range.end),l=Tt.fromBlock(t);(i!==0||s!==l.colCount-1)&&(e=60)}const r=K9(n,t,n.selection.range)[0];return new DOMRect(r.left,r.top+e,r.width,Math.max(r.height-e*2,0))}function XF(n,t){tL(n,Yp);const e=n.findCustom(mr(t));if(e){const o=Q9(n);e.off("scroll",o.handleReset),e.off("resize",o.handleReset),e.destroy()}}function tP(){return{abstract:`${R.t("table.abstract")}`}}const L0={blockType:"table",blockKind:"complex",enableKeyboardSelect:!0,createBlockContent:bF,getBlockTextLength:HF,getRangeFromPoint:UF,moveCaret:zF,getCaretRect:VF,updateSelection:t7,clearSelection:WF,getChildContainers:qF,getNextContainer:GF,getMinWidth:ZF,getSelectedContainers:Gp,convertFrom:QF,convertTo:$F,adjustSelectionPos:DF,getClientRects:K9,selectionToDoc:wF,getOptions:YF,getTextToolbarReferenceClient:KF,handleUpdateBlock:JF,handleDeleteBlock:XF,getBlockProperties:tP},eP={table:{cellBackground:"\u5355\u5143\u683C\u80CC\u666F\u8272",deleteSelectRow:"\u5220\u9664\u6240\u9009\u884C",deleteSelectCol:"\u5220\u9664\u6240\u9009\u5217",mergeCell:"\u5408\u5E76\u5355\u5143\u683C",splitCell:"\u62C6\u5206\u5355\u5143\u683C",tableConfigKey:"\u8868\u683C\u8BBE\u7F6E",deleteTable:"\u5220\u9664\u8868\u683C",insertCol:"\u63D2\u5165\u5217",insertRow:"\u63D2\u5165\u884C",deleteCol:"\u5220\u9664\u5217",deleteRow:"\u5220\u9664\u884C",tableConfig:{rowTitle:"\u884C\u6807\u9898",colTitle:"\u5217\u6807\u9898",stripeStyle:"\u6761\u7EB9\u6837\u5F0F",hideBorder:"\u9690\u85CF\u8868\u683C\u7EBF",showBorder:"\u663E\u793A\u8868\u683C\u7EBF",showChart:"\u663E\u793A\u56FE\u8868",hideChart:"\u9690\u85CF\u56FE\u8868"},title:"\u8868\u683C",abstract:"\u8868\u683C"}},nP={table:{cellBackground:"Cell background color",deleteSelectRow:"Delete selected rows",deleteSelectCol:"Delete selected columns",mergeCell:"Merge cells",splitCell:"Split cell",tableConfigKey:"Table settings",deleteTable:"Delete table",insertCol:"Insert column",insertRow:"Insert row",deleteCol:"Delete column",deleteRow:"Delete row",tableConfig:{rowTitle:"Row header",colTitle:"Column header",stripeStyle:"Stripe style",hideBorder:"Hide border",showBorder:"Show border",showChart:"Show chart",hideChart:"Hide chart"},title:"Table",abstract:"Table"}},oP={table:{cellBackground:"\u30BB\u30EB\u306E\u80CC\u666F\u8272",deleteSelectRow:"\u9078\u629E\u3057\u305F\u884C\u3092\u524A\u9664",deleteSelectCol:"\u9078\u629E\u3057\u305F\u5217\u3092\u524A\u9664",mergeCell:"\u30BB\u30EB\u3092\u7D50\u5408",splitCell:"\u30BB\u30EB\u306E\u7D50\u5408\u3092\u89E3\u9664",tableConfigKey:"\u30C6\u30FC\u30D6\u30EB\u8A2D\u5B9A",deleteTable:"\u30C6\u30FC\u30D6\u30EB\u3092\u524A\u9664",insertCol:"\u5217\u3092\u633F\u5165",insertRow:"\u884C\u3092\u633F\u5165",deleteCol:"\u5217\u3092\u524A\u9664",deleteRow:"\u884C\u3092\u524A\u9664",tableConfig:{rowTitle:"\u884C\u898B\u51FA\u3057",colTitle:"\u5217\u898B\u51FA\u3057",stripeStyle:"\u7E1E\u6A21\u69D8",hideBorder:"\u67A0\u7DDA\u3092\u975E\u8868\u793A",showBorder:"\u67A0\u7DDA\u3092\u8868\u793A",showChart:"\u30B0\u30E9\u30D5\u3092\u8868\u793A",hideChart:"\u30B0\u30E9\u30D5\u3092\u975E\u8868\u793A"},title:"\u30C6\u30FC\u30D6\u30EB",abstract:"\u30C6\u30FC\u30D6\u30EB"}};R.mergeLang({"zh-CN":eP,"en-US":nP,"ja-JP":oP});const Lnt="",e7=S("table");function n7(n,t){const e=Pp(t);if(!e)return;const o=et(e);g(e7,o&&Ve(o),"not a table block");const r=S0(o,e,"ArrowRight");if(!r){const s=Zt(o);return s?(n.selection.selectBlock(s,0),!0):n7(n,o)}const i=ye(r);return n.selection.selectBlock(i,0),!0}function rP(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!!t)return n7(n,t)}function o7(n,t){const e=Pp(t);if(!e)return;const o=et(e);g(e7,o&&Ve(o),"not a table block");const r=S0(o,e,"ArrowLeft");if(!r){const s=ce(o);return s?(n.selection.selectBlock(s,ut(n,s)),!0):o7(n,o)}const i=Qe(r);return n.selection.selectBlock(i,ut(n,i)),!0}function iP(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!!t)return o7(n,t)}const M0={Tab:rP,"Shift+Tab":iP};function sP(n,t,e,o){const r=n.getBlockByIndex(t,e);if(ut(n,r)!==o)return!1;const i=ie(n.getBlockText(r));if(![...i].every(h=>h==="|")||i.length<3||!n.editorBlocks.hasBlock("table"))return!1;const s=n.editorBlocks.getBlockClass("table");if(!s.convertFrom)return!1;const l=s.convertFrom(n,r,{offset:o});if(!l)return!1;const{blockData:a,focusBlockId:d}=l;return a?(n.undoManager.runInGroup(()=>{var p;const h=n.insertBlock(t,e,a,ke(n,d!=null?d:a.id,0));n.deleteBlock(r),(p=l.onConverted)==null||p.call(l,n,h)}),!0):!1}const lP={mermaid:{blockType:"embed",reg:/^```mermaid$/,data:{embedType:"mermaid"}},flowchart:{blockType:"embed",reg:/^```flowchart$/,data:{embedType:"flowchart"}},plantuml:{blockType:"embed",reg:/^```plantuml$/,data:{embedType:"plantuml"}},code:{blockType:"code",reg:/^```\S+$/},code2:{blockType:"code",reg:/^```$/},table:{blockType:"table",reg:/^\|.+\|.+\|$/},math:{blockType:"embed",reg:/^\$\$.+\$\$$/},image:{blockType:"embed",reg:/^!\[[^\]]*\]\((?<filename>.*?)(?="|\))(?<optionalPart>".*")?\)/,data:{embedType:"image"}},dividing:{blockType:"embed",reg:/^-{3,}$/,data:{embedType:"dividing-line"}},toc:{blockType:"embed",reg:/^\[toc\]/,data:{embedType:"toc"}}},cP={orderedList:{reg:/^(\d)+(\.|。)$/,blockType:"list",data:{listType:"ordered"}},unorderedList1:{reg:/^\*$/,blockType:"list",data:{listType:"unordered"}},unorderedList2:{reg:/^-$/,blockType:"list",data:{listType:"unordered"}},checkList1:{reg:/^\[\s?\]$/,blockType:"list",data:{listType:"unchecked"}},checkList2:{reg:/^\[X\]$/i,blockType:"list",data:{listType:"checked"}},image:{blockType:"embed",reg:/^!\[[^\]]*\]\((?<filename>.*?)(?="|\))(?<optionalPart>".*")?\)/,data:{embedType:"image"}}};function r7(n,t,e,o,r){if(r==="enter"&&sP(n,t,e,o))return!0;const i=n.getBlockByIndex(t,e),s=ie(Tn(n.getBlockText(i),o).left).trim(),l=r==="enter"?lP:cP;for(const[,a]of Object.entries(l)){if(!s.match(a.reg))continue;return!!n.undoManager.runInGroup(()=>{var B;const h=th(n,i,a.blockType,{offset:o,data:a.data});if(!h)return null;const{blockData:p,focusBlockId:A}=h;if(!p)return null;const v=n.insertBlock(t,e,p,ke(n,A!=null?A:p.id,0));return n.deleteBlock(i),(B=h.onConverted)==null||B.call(h,n,v),{newBlock:v,focusBlockId:A}})}return!1}function aP(n,t,e,o){const r=n.getBlockByIndex(t,e);return n.getBlockString(r,{boxReplacement:" "}).substring(0,o)!==">"?!1:(n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,0,o+1),n.updateBlockData(r,{quoted:!0},ke(n,r,0))}),!0)}const uP={"#":1,"##":2,"###":3,"####":4,"#####":5,"######":6,"#######":7,"########":8};function dP(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockString(r,{boxReplacement:" "}).substring(0,o);let s=uP[i];if(!s)return!1;const l=n.getBlockData(r).heading;return l&&l==s&&(s=null),n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,0,o+1),n.updateBlockData(r,{heading:s},ke(n,r,0))}),!0}function hP(n,t,e,o){return!!(dP(n,t,e,o)||aP(n,t,e,o))}const fP=S("match-text-style");function mP(n,t){if(n.length<t.length*2+1||!n.endsWith(t)||n.substring(0,n.length-1).endsWith(t))return-1;const e=n.substring(0,n.length-t.length),o=e.lastIndexOf(t);return o===-1?-1:o===0?0:e.substring(o-1).startsWith(t)?-1:o}const gP={"*":{type:"style",styles:["style-italic"],boxType:""},"**":{type:"style",styles:["style-bold"],boxType:""},"***":{type:"style",styles:["style-bold","style-italic"],boxType:""},"~~":{type:"style",styles:["style-strikethrough"],boxType:""},"`":{type:"style",styles:["style-code"],boxType:""},$$:{type:"box",styles:[],boxType:"math"}};function pP(n,t,e,o){var A,v;const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o),l=hg(s),a=rn(s)-l.length,d=Object.entries(gP);for(const[B,D]of d){const x=mP(l,B);if(x===-1)continue;const _=a+x,M=o,H=B.length,z=ie(ze(i,_+H,M-_-H*2).middle);if(D.type==="style"){const q={};D.styles.forEach(ft=>{q[ft]=!0});const rt=Oi(z,q);n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertTextToBlock(r,_,rt)})}else if(D.type==="box")try{const q=(v=(A=n.editorBoxes.getBoxClass(D.boxType)).convertFrom)==null?void 0:v.call(A,n,z);if(!q)continue;n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertBoxToBlock(r,_,q)})}catch(q){fP.warn(`failed to convert to box, ${q.message}`);continue}return!0}const h=/\[([^\]]+)\]\((https?:\/\/\S+)\)\s*$/,p=l.match(h);if(p){const B=p.index,D=p[1],x=p[2],_=B,M=o,z={...Ta(i,_),link:x};return n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertTextToBlock(r,_,Oi(D,z))}),!0}return!1}class xf{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&(hP(t,e,o,r)||pP(t,e,o,r)))}handleBeforeKeyDown(t,e){if(!t.selection.range.isSimple())return!1;const{containerId:r,blockIndex:i,offset:s}=t.getTextPosition();if(tt(t,t.getBlockByIndex(r,i))){if(or(e,"Enter")){if(r7(t,r,i,s,"enter"))return!0}else if(or(e,"Space")&&r7(t,r,i,s,"space"))return!0}return!1}}const CP={"en-US":{placeholder:{default:"Type / for commands",heading:"Title {heading}",list:"List",mention:"Quickly assign tasks and use @ to mention yourself or others",quote:"Quote",title:"Enter document title"}},"zh-CN":{placeholder:{default:"\u8F93\u5165\u300C/\u300D\u5FEB\u901F\u63D2\u5165",heading:"\u6807\u9898{heading}",list:"\u5217\u8868",mention:"\u5FEB\u901F\u5206\u914D\u4EFB\u52A1\uFF0C@\u63D0\u53CA\u81EA\u5DF1\u6216\u4ED6\u4EBA",quote:"\u5F15\u7528",title:"\u8BF7\u8F93\u5165\u6587\u6863\u6807\u9898"}},"ja-JP":{placeholder:{default:"\u300C/\u300D\u3092\u5165\u529B\u3057\u3066\u7D20\u65E9\u304F\u633F\u5165\u3059\u308B",heading:"\u898B\u51FA\u3057{heading}",list:"\u30EA\u30B9\u30C8",mention:"\u81EA\u5206\u3084\u30E1\u30F3\u30D0\u30FC\u3092\uFF20\u3057\u3001\u30BF\u30B9\u30AF\u3092\u7D20\u65E9\u304F\u5272\u308A\u5F53\u3066\u307E\u3059",quote:"\u5F15\u7528",title:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}}};R.mergeLang(CP);function bu(n,t){const e=_i(n,t);return!!(e.text&&rn(e.text)===0&&!t.querySelector(".inputting-insertion"))}function i7(n,t){var o;Lt(t).removeAttribute("data-content-placeholder"),(o=t.querySelector("[data-type=block-tools] .block-placeholder-container"))==null||o.remove()}function If(n,t,e){var r;if(!bu(n,t)){i7(n,t);return}const o=Lt(t);if(typeof e=="string")o.setAttribute("data-content-placeholder",e);else{const i=te(t),s=(r=i.querySelector(".block-placeholder-container"))!=null?r:w("div",["block-placeholder-container"],i);s.innerHTML="",s.appendChild(e)}}function AP(n){const t=n.getAttribute("data-style-heading");return t?R.t("placeholder.heading",{heading:t}):n.getAttribute("data-style-quoted")?R.t("placeholder.quote"):null}function bP(n){const t=n.getAttribute("data-list-type");return t?t==="ordered"||t==="unordered"?R.t("placeholder.list"):R.t("placeholder.mention"):null}function s7(n){switch(Dt(n)){case"text":return AP(n);case"list":return bP(n);default:return null}}function vP(n){if(io(n))return!1;const t=et(nt(n));return t?Dt(t)==="code":!1}function yP(n){return!io(n)}function kP(n,t){var h,p;const e=n.selection.focusedBlock,o=Dt(e),r=t.contentPlaceholder||R.t("placeholder.default");let i=r;if(o&&va(n,o)&&e){if(!n.isBlockWritable(e)||vP(e))return;yP(e)&&(i=R.t("placeholder.common.contentInTable")),i=(h=s7(e))!=null?h:i}const s=n.getFirstBlock(),l=Zt(s);if(!l)return;const a=Zt(l);if(a&&!t.addPlaceholderToAllCurrentEmptyBlock)return;if(!a&&bu(n,l)){If(n,l,(p=s7(l))!=null?p:r);return}const d=n.getFocusedBlock();!bu(n,d)||d!==s&&If(n,d,i)}function wP(n,t){var r,i;const e=n.getFirstBlock(),o=Lt(e);bu(n,e)?(o.setAttribute("data-title-placeholder",(r=t.titlePlaceholder)!=null?r:R.t("placeholder.title")),o.setAttribute("data-title-placeholder-readonly",(i=t.readonlyTitlePlaceholder)!=null?i:"")):(o.removeAttribute("data-title-placeholder"),o.removeAttribute("data-title-placeholder-readonly"))}function BP(n){n.rootContainer.querySelectorAll("[data-content-placeholder").forEach(t=>{t.removeAttribute("data-content-placeholder")}),n.rootContainer.querySelectorAll("[data-type=block-tools] .block-placeholder-container").forEach(t=>{t.remove()})}function EP(n,t){BP(n),n.selection.range.isCollapsed()&&(wP(n,t),kP(n,t))}const _nt="";function xP(n){for(let t=1;t<n.length;t++){const e=n[t];if(e.attributes&&Object.keys(e.attributes).length)return!0}return!1}const l7=S("enforce-title");class vu{constructor(t,e={headingLevel:1}){m(this,"handleSelectionChange",t=>{setTimeout(()=>{this.applyPlaceholder(t)})});this.options=e,this.handleChanged(t),this.applyPlaceholder(t),t.addListener("selectionChanged",this.handleSelectionChange)}destroy(t){t.removeListener("selectionChanged",this.handleSelectionChange)}handleBeforeKeyDown(t,e){if(!t.selection.range.isSimple())return!1;const{containerId:r,blockIndex:i,offset:s}=t.getTextPosition();if(!vu.isDocumentTitleBlock(r,i)||!or(e,"Enter"))return!1;let l=!1,a=null;Io(t.rootContainer)===2&&(a=Fr(t.rootContainer,1),ut(t,a)===0&&(l=!0));const d=t.getFirstBlock();return t.undoManager.runInGroup(()=>{t.breakTextBlock(d,s,{forceInsertAfter:!0}),l&&a&&t.deleteBlock(a)}),!0}handleChanged(t){var e,o;try{const r=t.doc.getContainerBlocks(ct(t.rootContainer));g(l7,r.length>0,"root container is empty");const i=r[0];if(i.type!=="text"){const s=cr("",{heading:(e=this.options.headingLevel)!=null?e:1});t.insertBlock(ct(t.rootContainer),0,s,t.selection.range.toDocRange());return}if(g(l7,i.text,"invalid text block"),xP(i.text)||i.quoted||i.heading!==this.options.headingLevel){const s=t.getBlockById(i.id),l=t.getBlockString(s),a=cr(l,{heading:(o=this.options.headingLevel)!=null?o:1,quoted:!1}),d=t.selection.focusedBlock;let h=t.selection.range;const p=t.insertBlock(ct(t.rootContainer),0,a);d===s&&(h=ke(t,a.id,ut(t,p))),Bh(t,s,h)}if(r.length>1)return;t.insertTextBlock("",ct(t.rootContainer),1,{newRange:t.selection.range.toDocRange()})}finally{this.applyPlaceholder(t)}}handleRemoteChanged(t){setTimeout(()=>{this.applyPlaceholder(t)})}handleUpdateCompositionText(t){this.applyPlaceholder(t)}applyPlaceholder(t){var e,o;!((e=this.options)!=null&&e.titlePlaceholder)&&!((o=this.options)!=null&&o.contentPlaceholder)||EP(t,this.options)}static isDocumentTitleBlock(t,e){return t==="root"&&e===0}}const c7=S("code-dom");function Qi(n){return Dt(n)==="code"}function a7(n,t,e){e.language?t.setAttribute("data-language",e.language):t.removeAttribute("data-language"),e.nowrap?ot(t,"wrap"):W(t,"wrap")}function R0(n){const t=n.closest("div[data-type=editor-block][data-block-type=code]");return g(c7,t,"no parent code block"),g(c7,Qi(t),"not a code block"),t}const yu={plain:{name:"Plain Text",aliases:["txt","text"]},abap:{name:"ABAP",aliases:["abap"]},arduino:{name:"Arduino",aliases:["ino"]},bash:{name:"Bash",aliases:["sh","shell"]},basic:{name:"BASIC",aliases:["bas"]},c:{name:"C",aliases:["c"]},clojure:{name:"Clojure",aliases:["clj"]},cofeescript:{name:"CoffeeScript",aliases:["coffee"]},cpp:{name:"C++",aliases:["cpp","cxx"]},csharp:{name:"C#",aliases:["cs"]},css:{name:"CSS",aliases:["css"]},dart:{name:"Dart",aliases:["dart"]},diff:{name:"Diff",aliases:["diff","patch"]},docker:{name:"Docker",aliases:["dockerfile"]},elixir:{name:"Elixir",aliases:["ex","exs"]},elm:{name:"Elm",aliases:["elm"]},erlang:{name:"Erlang",aliases:["erl"]},flow:{name:"Flow",aliases:["flow"]},fortran:{name:"Fortran",aliases:["f","for","f77","f90"]},fsharp:{name:"F#",aliases:["fsharp"]},gherkin:{name:"Gherkin",aliases:["feature"]},glsl:{name:"GLSL",aliases:["glsl"]},go:{name:"Go",aliases:["go"]},graphql:{name:"GraphQL",aliases:["graphql"]},groovy:{name:"Groovy",aliases:["groovy"]},haskell:{name:"Haskell",aliases:["hs"]},java:{name:"Java",aliases:["java"]},js:{name:"JavaScript",aliases:["js","jsx"]},json:{name:"JSON",aliases:["json"]},julia:{name:"Julia",aliases:["jl"]},kotlin:{name:"Kotlin",aliases:["kt","ktm","kts"]},latex:{name:"LaTeX",aliases:["tex"]},less:{name:"LESS",aliases:["less"]},lisp:{name:"Lisp",aliases:["lisp"]},livescript:{name:"LiveScript",aliases:["ls"]},lua:{name:"Lua",aliases:["lua"]},makefile:{name:"Makefile",aliases:["mk","mak"]},markdown:{name:"Markdown",aliases:["md","mkdown","mkd"]},markup:{name:"HTML / XML",aliases:["html","htm","xml","xsd","xsl","xslt","wsdl"]},matlab:{name:"MATLAB",aliases:["matlab"]},mermaid:{name:"Mermaid",aliases:["mermaid"]},nix:{name:"Nix",aliases:["nix"]},objectivec:{name:"Objective-C",aliases:["m","mm"]},ocaml:{name:"OCaml",aliases:["ml"]},pascal:{name:"Pascal",aliases:["pas"]},perl:{name:"Perl",aliases:["pl","pm"]},php:{name:"PHP",aliases:["php"]},powershell:{name:"PowerShell",aliases:["ps","ps1"]},prolog:{name:"Prolog",aliases:["plg"]},protobuf:{name:"Protocol Buffers",aliases:["proto"]},python:{name:"Python",aliases:["py"]},r:{name:"R",aliases:["r"]},reason:{name:"Reason",aliases:["re","rei"]},ruby:{name:"Ruby",aliases:["rb"]},rust:{name:"Rust",aliases:["rs"]},sass:{name:"Sass",aliases:["sass"]},scala:{name:"Scala",aliases:["scala"]},scheme:{name:"Scheme",aliases:["scm","sm"]},scss:{name:"SCSS",aliases:["scss"]},solidity:{name:"Solidity",aliases:["sol"]},sql:{name:"SQL",aliases:["sql"]},swift:{name:"Swift",aliases:["swift"]},typescript:{name:"TypeScript",aliases:["ts","tsx"]},vbnet:{name:"VB.Net",aliases:["vbnet"]},verilog:{name:"Verilog",aliases:["v"]},vhdl:{name:"VHDL",aliases:["vhdl"]},"visual-basic":{name:"Visual Basic",aliases:["vb","vba"]},wasm:{name:"WebAssembly",aliases:["wasm"]},yaml:{name:"YAML",aliases:["yaml"]}};function u7(n){const t=n.toLocaleLowerCase();let e="";return Object.entries(yu).forEach(([o,r])=>{(o===t||r.aliases.includes(t)||r.name.toLocaleLowerCase()===t)&&(e=o)}),e}function d7(n){const t=n.settingsProvider.getItem("editor-code-lang");return t!=null?t:"plain"}function IP(n,t){return n.settingsProvider.setItem("editor-code-lang",t)}const TP=S("convert-to-code");function DP(n,t){if(!tt(n,t))return null;const e={id:K(),type:"text",text:[]},o=K();n.doc.localInsertChildContainer(o,[e]);const r=n.getBlockData(t).text;g(TP,r,"no text");let i=ie(r);i.startsWith("```")&&(i=i.substring(3));const s=u7(i)||d7(n)||"plain";return{blockData:{id:K(),type:"code",language:s,children:[o]},focusBlockId:e.id}}const Fnt="",O0=S("code-block-child-container");function Ac(n){g(O0,Qi(n),"not a code block");const e=Lt(n).querySelector(":scope > div.editor-code-root > div.code-text-root [data-type=editor-container].child");return g(O0,e,"no code text container"),e}function Qs(n){g(O0,Qi(n),"not a code block");const e=Lt(n).querySelector(":scope > div.editor-code-root > div.code-caption-root [data-type=editor-container].child");return e||null}function Tf(n){const t=[Ac(n)],e=Qs(n);return e&&t.push(e),t}function bc(n,t){if(!tt(n,t))return!1;const e=nt(t),o=et(e);return o?Qi(o)?e===Ac(o):Dt(t)==="code":!1}const _0=S("code-caption");function SP(n,t){if(n.readonly)return;const e=Qs(t);if(e){const a=ye(e);n.selection.selectBlock(a,0);return}const o=qr(n.doc),r=n.getBlockData(t);g(_0,r.children.length===1,"code block should have only one child");const i={...r,children:[r.children[0],o]};n.updateBlockData(t,i);const s=n.getContainerById(o),l=ye(s);n.selection.selectBlock(l,0)}function h7(n,t){const e=nt(t);if(Yt(e))return!1;const o=et(e);if(g(_0,o,"no parent block"),!Qi(o))return!1;const i=Qs(o);return e===i}function LP(n,t){if(n.readonly||!Qs(t))return;const o=Ac(t),r=Qe(o);n.selection.selectBlock(r,ut(n,r));const i=n.getBlockData(t);g(_0,i.children.length===2,"code block should have only one child");const s=i.children[1],l={...i,children:[i.children[0]]};n.updateBlockData(t,l),n.deleteChildContainers([s])}const MP=S("paste-in-table-block");class RP{constructor(t){this.editor=t,setTimeout(()=>{t.input.addHandler(this)})}destroy(){}async handleBeforePaste(t,e,o){if(!t.selection.range.isSimple())return!1;const r=t.selection.range.start,i=t.getBlockById(r.blockId),s=nt(i);if(Yt(s))return!1;const l=et(s);if(g(MP,l,"no parent block"),!Qi(l)||h7(t,i))return!1;const a=o["text/x-ones-editor-doc"];let d=null;if(a){const p=La(t,a);d=Wr(p)}else d=o["text/plain"];if(!d)return!0;const h=d;return t.undoManager.runInGroup(()=>{t.clearSelectedContents(),t.insertDoc(i,r.offset,h)}),!0}}function OP(n){n.addCustom("code-block-paste-event",t=>new RP(t))}class _P{constructor(t){m(this,"id","CodeBlockCommandProvider");setTimeout(()=>{t.editorCommandProviders.registerCommandProvider(this)})}destroy(){}getAvailableCommands(){return[]}executeCommand(){return!1}filterCommands(t,e,o,r){if(bc(t,e))return[]}beforeExecuteCommand(t,e,o,r,i){return!!bc(t,e)}}function FP(n){n.addCustom("code-block-command-provider",t=>new _P(t))}const PP=S("code-caption-input-handler");function F0(n){if(!n.selection.range.isSimple())return null;const t=n.selection.range.start;if(!t.isSimple())return null;const e=n.getBlockById(t.blockId);return h7(n,e)?e:null}function NP(n){const t=F0(n);if(!t)return!1;const e=R0(t),o=Zt(e);return o?(n.selection.selectBlock(o,0),!0):(n.insertTextBlock("",ct(nt(e)),bt(e)+1),!0)}function $P(n,t){if(ae(n,t)){const e=R0(t);return LP(n,e),!0}return!1}function HP(n){var e;const{start:t}=n.selection.range;if(t.isSimple()){const o=n.getBlockById(t.blockId),r=(e=o.closest("div[data-type=editor-block][data-block-type=code]"))!=null?e:null;if(!r)return!1;const i=Qs(r),s=i&&!ae(n,ye(i));if(!r||!ae(n,o)||s)return!1;const l=gn(n,r)[0],a=fe(l);if(a.length>1)return!1;if(l&&a[0]===o)return n.deleteBlock(r),!0}return!1}function jP(n){const t=F0(n);return t?$P(n,t):HP(n)}class P0{constructor(t){setTimeout(()=>{t.input.addHandler(this)})}destroy(){}handleBeforeKeyDown(t,e){return e.key==="Enter"?or(e,"Shift+Enter")?!0:NP(t):e.key==="Backspace"?jP(t):!1}async handleBeforePaste(t,e,o){const r=F0(t);if(!r)return!1;const i=o["text/plain"];if(!i)return!0;const s=La(t,i);return s&&t.undoManager.runInGroup(()=>{t.clearSelectedContents();const l=t.selection.range.start;g(PP,l.isSimple(),"not simple position"),t.insertTextToBlock(r,l.offset,s)}),!0}static init(t){t.addCustom("code-block-caption-input-handler",e=>new P0(e))}}function UP(n){const o=new DOMParser().parseFromString(n,"text/html").querySelector("svg");if(!o)return null;const r=o.getAttribute("viewBox");if(!r)return null;const i=r.split(" ");if(i.length===4){const s=i[2],l=i[3];return o.setAttribute("width",s),o.setAttribute("height",l),o.outerHTML}return null}function N0(n,t,e=!0){const o=new Image,r=document.createElement("canvas"),i=r.getContext("2d");if(!i){t(new Error("failed to get context"),null);return}o.onload=()=>{if(r.width=o.naturalWidth,r.height=o.naturalHeight,e&&(r.width===0||r.height===0)){const s=n.substring(26);if(s){const l=atob(s),a=UP(l);if(a){Im(a,"image/svg+xml").then(d=>{N0(d,t,!1)});return}}t(null,null);return}i.drawImage(o,0,0),r.toBlob(s=>{t(null,s)},"image/png")},o.src=n}function zP(n){return new Promise((t,e)=>{N0(n,(o,r)=>{if(o){e(o);return}if(!r){e(new Error("Failed to get image blob"));return}t(r)})})}async function f7(n){const t=await jl(n);return new Promise((e,o)=>{N0(t,(r,i)=>{if(r){o(r);return}if(!i){o(new Error("Failed to get image blob"));return}e(i)})})}const m7="Untitled";function g7(n){const t=ye(n.rootContainer);return!t||!tt(n,t)?m7:n.getBlockString(t)||m7}function $0(){return Object.prototype.hasOwnProperty.bind(window,"isSecureContext")?window.isSecureContext:window.location.protocol==="https:"||window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"}function VP(n){let t;return n.forEach((e,o)=>{o.toLocaleLowerCase()==="content-type"&&(t=e)}),t!=null?t:""}async function p7(n){try{const t=await fetch(n,{credentials:"same-origin"}),e=await t.blob(),o=VP(t.headers).toLocaleLowerCase();let r="";if(o){const s=fm.default[o].extensions;s&&s.length>0&&(r=s[0])}return new File([e],`${Date.now()}.${r}`,{type:o})}catch{return null}}const WP=`
403
+ `)}return""}const Au=S("table-block");function HF(n){return 1}function jF(n){return!!n.closest(`.${Wp}`)}function UF(n,t,e,o){const r=document.elementsFromPoint(e,o)[0];if(!r||!t.contains(r)||!n.contains(t))return null;let i=r;if(jF(r)&&(i=r.closest("td"),g(Au,i instanceof HTMLTableCellElement,"invalid element")),i instanceof HTMLTableCellElement){const a=_e(t);if(yv(a).indexOf(i)!==-1){const h=iu(i),p=me(t,ct(h));return new ir(n,{anchor:p,focus:p})}}if(!Pr(r))return null;const s=r;if(G9(t).indexOf(s)===-1)return null;const l=me(t,ct(s));return new ir(n,{anchor:l,focus:l})}function zF(n,t,e,o){return null}function VF(n,t){return n.getBoundingClientRect()}function t7(n,t,e,o){if(e.isSimple()){g(Au,o.isSimple(),"from is simple position but to is not simple position"),Au.debug("full select table"),W(t,"full-selected");return}g(Au,!o.isSimple(),"from is complex position but end is simple position");const r=Jr(n,t,e),i=Jr(n,t,o);g(Au,r.blockId===i.blockId,"only allow update one table selection"),NM(n,r,i).forEach(l=>{const a=D0(l);W(a,"selected")})}function WF(n){n.rootContainer.querySelectorAll('[data-type="editor-block"][data-block-type="table"]').forEach(t=>{ot(t,"full-selected"),t.querySelectorAll("td.selected").forEach(e=>{ot(e,"selected")})})}function qF(n,t){return kv(t)?G9(t):[]}function GF(n,t,e,o,r){return S0(t,e,o,r)}function ZF(n,t){return RF(n,t)}function QF(n,t){return tt(n,t)?yF(n,n.getBlockString(t).trim()):null}function YF(n){return{name:"TableBlock",insertBlockCommandItems:[{id:"insert-table",name:R.t("table.title"),order:200,icon:xL,children:[FF()],group:"common",subText:An("insert-table")}],handleInsertEmptyBlock:OF}}function JF(n,t,e){return vF(n,t,e),setTimeout(()=>{const o=n.selection.range;o.isSimple()?n.selection.caret.update():t7(n,t,o.start,o.end)}),!0}function KF(n,t){let e=0;const{selectedColumns:o}=Np(n,t);if(o.size>0){const{fromCol:i,toCol:s}=Uo(t,n.selection.range.start,n.selection.range.end),l=Tt.fromBlock(t);(i!==0||s!==l.colCount-1)&&(e=60)}const r=K9(n,t,n.selection.range)[0];return new DOMRect(r.left,r.top+e,r.width,Math.max(r.height-e*2,0))}function XF(n,t){tL(n,Yp);const e=n.findCustom(mr(t));if(e){const o=Q9(n);e.off("scroll",o.handleReset),e.off("resize",o.handleReset),e.destroy()}}function tP(){return{abstract:`${R.t("table.abstract")}`}}const L0={blockType:"table",blockKind:"complex",enableKeyboardSelect:!0,createBlockContent:bF,getBlockTextLength:HF,getRangeFromPoint:UF,moveCaret:zF,getCaretRect:VF,updateSelection:t7,clearSelection:WF,getChildContainers:qF,getNextContainer:GF,getMinWidth:ZF,getSelectedContainers:Gp,convertFrom:QF,convertTo:$F,adjustSelectionPos:DF,getClientRects:K9,selectionToDoc:wF,getOptions:YF,getTextToolbarReferenceClient:KF,handleUpdateBlock:JF,handleDeleteBlock:XF,getBlockProperties:tP},eP={table:{cellBackground:"\u5355\u5143\u683C\u80CC\u666F\u8272",deleteSelectRow:"\u5220\u9664\u6240\u9009\u884C",deleteSelectCol:"\u5220\u9664\u6240\u9009\u5217",mergeCell:"\u5408\u5E76\u5355\u5143\u683C",splitCell:"\u62C6\u5206\u5355\u5143\u683C",tableConfigKey:"\u8868\u683C\u8BBE\u7F6E",deleteTable:"\u5220\u9664\u8868\u683C",insertCol:"\u63D2\u5165\u5217",insertRow:"\u63D2\u5165\u884C",deleteCol:"\u5220\u9664\u5217",deleteRow:"\u5220\u9664\u884C",tableConfig:{rowTitle:"\u884C\u6807\u9898",colTitle:"\u5217\u6807\u9898",stripeStyle:"\u6761\u7EB9\u6837\u5F0F",hideBorder:"\u9690\u85CF\u8868\u683C\u7EBF",showBorder:"\u663E\u793A\u8868\u683C\u7EBF",showChart:"\u663E\u793A\u56FE\u8868",hideChart:"\u9690\u85CF\u56FE\u8868"},title:"\u8868\u683C",abstract:"\u8868\u683C"}},nP={table:{cellBackground:"Cell background color",deleteSelectRow:"Delete selected rows",deleteSelectCol:"Delete selected columns",mergeCell:"Merge cells",splitCell:"Split cell",tableConfigKey:"Table settings",deleteTable:"Delete table",insertCol:"Insert column",insertRow:"Insert row",deleteCol:"Delete column",deleteRow:"Delete row",tableConfig:{rowTitle:"Row header",colTitle:"Column header",stripeStyle:"Stripe style",hideBorder:"Hide border",showBorder:"Show border",showChart:"Show chart",hideChart:"Hide chart"},title:"Table",abstract:"Table"}},oP={table:{cellBackground:"\u30BB\u30EB\u306E\u80CC\u666F\u8272",deleteSelectRow:"\u9078\u629E\u3057\u305F\u884C\u3092\u524A\u9664",deleteSelectCol:"\u9078\u629E\u3057\u305F\u5217\u3092\u524A\u9664",mergeCell:"\u30BB\u30EB\u3092\u7D50\u5408",splitCell:"\u30BB\u30EB\u306E\u7D50\u5408\u3092\u89E3\u9664",tableConfigKey:"\u30C6\u30FC\u30D6\u30EB\u8A2D\u5B9A",deleteTable:"\u30C6\u30FC\u30D6\u30EB\u3092\u524A\u9664",insertCol:"\u5217\u3092\u633F\u5165",insertRow:"\u884C\u3092\u633F\u5165",deleteCol:"\u5217\u3092\u524A\u9664",deleteRow:"\u884C\u3092\u524A\u9664",tableConfig:{rowTitle:"\u884C\u898B\u51FA\u3057",colTitle:"\u5217\u898B\u51FA\u3057",stripeStyle:"\u7E1E\u6A21\u69D8",hideBorder:"\u67A0\u7DDA\u3092\u975E\u8868\u793A",showBorder:"\u67A0\u7DDA\u3092\u8868\u793A",showChart:"\u30B0\u30E9\u30D5\u3092\u8868\u793A",hideChart:"\u30B0\u30E9\u30D5\u3092\u975E\u8868\u793A"},title:"\u30C6\u30FC\u30D6\u30EB",abstract:"\u30C6\u30FC\u30D6\u30EB"}};R.mergeLang({"zh-CN":eP,"en-US":nP,"ja-JP":oP});const Lnt="",e7=S("table");function n7(n,t){const e=Pp(t);if(!e)return;const o=et(e);g(e7,o&&Ve(o),"not a table block");const r=S0(o,e,"ArrowRight");if(!r){const s=Zt(o);return s?(n.selection.selectBlock(s,0),!0):n7(n,o)}const i=ye(r);return n.selection.selectBlock(i,0),!0}function rP(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!!t)return n7(n,t)}function o7(n,t){const e=Pp(t);if(!e)return;const o=et(e);g(e7,o&&Ve(o),"not a table block");const r=S0(o,e,"ArrowLeft");if(!r){const s=ce(o);return s?(n.selection.selectBlock(s,ut(n,s)),!0):o7(n,o)}const i=Qe(r);return n.selection.selectBlock(i,ut(n,i)),!0}function iP(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!!t)return o7(n,t)}const M0={Tab:rP,"Shift+Tab":iP};function sP(n,t,e,o){const r=n.getBlockByIndex(t,e);if(ut(n,r)!==o)return!1;const i=ie(n.getBlockText(r));if(![...i].every(h=>h==="|")||i.length<3||!n.editorBlocks.hasBlock("table"))return!1;const s=n.editorBlocks.getBlockClass("table");if(!s.convertFrom)return!1;const l=s.convertFrom(n,r,{offset:o});if(!l)return!1;const{blockData:a,focusBlockId:d}=l;return a?(n.undoManager.runInGroup(()=>{var p;const h=n.insertBlock(t,e,a,ke(n,d!=null?d:a.id,0));n.deleteBlock(r),(p=l.onConverted)==null||p.call(l,n,h)}),!0):!1}const lP={mermaid:{blockType:"embed",reg:/^```mermaid$/,data:{embedType:"mermaid"}},flowchart:{blockType:"embed",reg:/^```flowchart$/,data:{embedType:"flowchart"}},plantuml:{blockType:"embed",reg:/^```plantuml$/,data:{embedType:"plantuml"}},code:{blockType:"code",reg:/^```\S+$/},code2:{blockType:"code",reg:/^```$/},table:{blockType:"table",reg:/^\|.+\|.+\|$/},math:{blockType:"embed",reg:/^\$\$.+\$\$$/},image:{blockType:"embed",reg:/^!\[[^\]]*\]\((?<filename>.*?)(?="|\))(?<optionalPart>".*")?\)/,data:{embedType:"image"}},dividing:{blockType:"embed",reg:/^-{3,}$/,data:{embedType:"dividing-line"}},toc:{blockType:"embed",reg:/^\[toc\]/,data:{embedType:"toc"}}},cP={orderedList:{reg:/^(\d)+(\.|。)$/,blockType:"list",data:{listType:"ordered"}},unorderedList1:{reg:/^\*$/,blockType:"list",data:{listType:"unordered"}},unorderedList2:{reg:/^-$/,blockType:"list",data:{listType:"unordered"}},checkList1:{reg:/^\[\s?\]$/,blockType:"list",data:{listType:"unchecked"}},checkList2:{reg:/^\[X\]$/i,blockType:"list",data:{listType:"checked"}},image:{blockType:"embed",reg:/^!\[[^\]]*\]\((?<filename>.*?)(?="|\))(?<optionalPart>".*")?\)/,data:{embedType:"image"}}};function r7(n,t,e,o,r){if(r==="enter"&&sP(n,t,e,o))return!0;const i=n.getBlockByIndex(t,e),s=ie(Tn(n.getBlockText(i),o).left).trim(),l=r==="enter"?lP:cP;for(const[,a]of Object.entries(l)){if(!s.match(a.reg))continue;return!!n.undoManager.runInGroup(()=>{var B;const h=th(n,i,a.blockType,{offset:o,data:a.data});if(!h)return null;const{blockData:p,focusBlockId:A}=h;if(!p)return null;const v=n.insertBlock(t,e,p,ke(n,A!=null?A:p.id,0));return n.deleteBlock(i),(B=h.onConverted)==null||B.call(h,n,v),{newBlock:v,focusBlockId:A}})}return!1}function aP(n,t,e,o){const r=n.getBlockByIndex(t,e);return n.getBlockString(r,{boxReplacement:" "}).substring(0,o)!==">"?!1:(n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,0,o+1),n.updateBlockData(r,{quoted:!0},ke(n,r,0))}),!0)}const uP={"#":1,"##":2,"###":3,"####":4,"#####":5,"######":6,"#######":7,"########":8};function dP(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockString(r,{boxReplacement:" "}).substring(0,o);let s=uP[i];if(!s)return!1;const l=n.getBlockData(r).heading;return l&&l==s&&(s=null),n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,0,o+1),n.updateBlockData(r,{heading:s},ke(n,r,0))}),!0}function hP(n,t,e,o){return!!(dP(n,t,e,o)||aP(n,t,e,o))}const fP=S("match-text-style");function mP(n,t){if(n.length<t.length*2+1||!n.endsWith(t)||n.substring(0,n.length-1).endsWith(t))return-1;const e=n.substring(0,n.length-t.length),o=e.lastIndexOf(t);return o===-1?-1:o===0?0:e.substring(o-1).startsWith(t)?-1:o}const gP={"*":{type:"style",styles:["style-italic"],boxType:""},"**":{type:"style",styles:["style-bold"],boxType:""},"***":{type:"style",styles:["style-bold","style-italic"],boxType:""},"~~":{type:"style",styles:["style-strikethrough"],boxType:""},"`":{type:"style",styles:["style-code"],boxType:""},$$:{type:"box",styles:[],boxType:"math"}};function pP(n,t,e,o){var A,v;const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o),l=hg(s),a=rn(s)-l.length,d=Object.entries(gP);for(const[B,D]of d){const x=mP(l,B);if(x===-1)continue;const _=a+x,M=o,H=B.length,z=ie(ze(i,_+H,M-_-H*2).middle);if(D.type==="style"){const q={};D.styles.forEach(ft=>{q[ft]=!0});const rt=Oi(z,q);n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertTextToBlock(r,_,rt)})}else if(D.type==="box")try{const q=(v=(A=n.editorBoxes.getBoxClass(D.boxType)).convertFrom)==null?void 0:v.call(A,n,z);if(!q)continue;n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertBoxToBlock(r,_,q)})}catch(q){fP.warn(`failed to convert to box, ${q.message}`);continue}return!0}const h=/\[([^\]]+)\]\((https?:\/\/\S+)\)\s*$/,p=l.match(h);if(p){const B=p.index,D=p[1],x=p[2],_=B,M=o,z={...Ta(i,_),link:x};return n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,_,M-_),n.insertTextToBlock(r,_,Oi(D,z))}),!0}return!1}class xf{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&(hP(t,e,o,r)||pP(t,e,o,r)))}handleBeforeKeyDown(t,e){if(!t.selection.range.isSimple())return!1;const{containerId:r,blockIndex:i,offset:s}=t.getTextPosition();if(tt(t,t.getBlockByIndex(r,i))){if(or(e,"Enter")){if(r7(t,r,i,s,"enter"))return!0}else if(or(e,"Space")&&r7(t,r,i,s,"space"))return!0}return!1}}const CP={"en-US":{placeholder:{default:"Type / for commands",heading:"Title {heading}",list:"List",mention:"Quickly assign tasks and use @ to mention yourself or others",quote:"Quote",title:"Enter document title"}},"zh-CN":{placeholder:{default:"\u8F93\u5165\u300C/\u300D\u5FEB\u901F\u63D2\u5165",heading:"\u6807\u9898{heading}",list:"\u5217\u8868",mention:"\u5FEB\u901F\u5206\u914D\u4EFB\u52A1\uFF0C@\u63D0\u53CA\u81EA\u5DF1\u6216\u4ED6\u4EBA",quote:"\u5F15\u7528",title:"\u8BF7\u8F93\u5165\u6587\u6863\u6807\u9898"}},"ja-JP":{placeholder:{default:"\u300C/\u300D\u3092\u5165\u529B\u3057\u3066\u7D20\u65E9\u304F\u633F\u5165\u3059\u308B",heading:"\u898B\u51FA\u3057{heading}",list:"\u30EA\u30B9\u30C8",mention:"\u81EA\u5206\u3084\u30E1\u30F3\u30D0\u30FC\u3092\uFF20\u3057\u3001\u30BF\u30B9\u30AF\u3092\u7D20\u65E9\u304F\u5272\u308A\u5F53\u3066\u307E\u3059",quote:"\u5F15\u7528",title:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044"}}};R.mergeLang(CP);function bu(n,t){const e=_i(n,t);return!!(e.text&&rn(e.text)===0&&!t.querySelector(".inputting-insertion"))}function i7(n,t){var o;Lt(t).removeAttribute("data-content-placeholder"),(o=t.querySelector("[data-type=block-tools] .block-placeholder-container"))==null||o.remove()}function If(n,t,e){var r;if(!bu(n,t)){i7(n,t);return}const o=Lt(t);if(typeof e=="string")o.setAttribute("data-content-placeholder",e);else{const i=te(t),s=(r=i.querySelector(".block-placeholder-container"))!=null?r:w("div",["block-placeholder-container"],i);s.innerHTML="",s.appendChild(e)}}function AP(n){const t=n.getAttribute("data-style-heading");return t?R.t("placeholder.heading",{heading:t}):n.getAttribute("data-style-quoted")?R.t("placeholder.quote"):null}function bP(n){const t=n.getAttribute("data-list-type");return t?t==="ordered"||t==="unordered"?R.t("placeholder.list"):R.t("placeholder.mention"):null}function s7(n){switch(Dt(n)){case"text":return AP(n);case"list":return bP(n);default:return null}}function vP(n){if(io(n))return!1;const t=et(nt(n));return t?Dt(t)==="code":!1}function yP(n){return!io(n)}function kP(n,t){var h,p;const e=n.selection.focusedBlock,o=Dt(e),r=t.contentPlaceholder||R.t("placeholder.default");let i=r;if(o&&va(n,o)&&e){if(!n.isBlockWritable(e)||vP(e))return;yP(e)&&(i=R.t("placeholder.common.contentInTable")),i=(h=s7(e))!=null?h:i}const s=n.getFirstBlock(),l=Zt(s);if(!l)return;const a=Zt(l);if(a&&!t.addPlaceholderToAllCurrentEmptyBlock)return;if(!a&&bu(n,l)){If(n,l,(p=s7(l))!=null?p:r);return}const d=n.getFocusedBlock();!bu(n,d)||d!==s&&If(n,d,i)}function wP(n,t){var r,i;const e=n.getFirstBlock(),o=Lt(e);bu(n,e)?(o.setAttribute("data-title-placeholder",(r=t.titlePlaceholder)!=null?r:R.t("placeholder.title")),o.setAttribute("data-title-placeholder-readonly",(i=t.readonlyTitlePlaceholder)!=null?i:"")):(o.removeAttribute("data-title-placeholder"),o.removeAttribute("data-title-placeholder-readonly"))}function BP(n){n.rootContainer.querySelectorAll("[data-content-placeholder").forEach(t=>{t.removeAttribute("data-content-placeholder")}),n.rootContainer.querySelectorAll("[data-type=block-tools] .block-placeholder-container").forEach(t=>{t.remove()})}function EP(n,t){BP(n),n.selection.range.isCollapsed()&&(wP(n,t),kP(n,t))}const _nt="";function xP(n){for(let t=1;t<n.length;t++){const e=n[t];if(e.attributes&&Object.keys(e.attributes).length)return!0}return!1}const l7=S("enforce-title");class vu{constructor(t,e={headingLevel:1}){m(this,"handleSelectionChange",t=>{setTimeout(()=>{this.applyPlaceholder(t)})});this.options=e,this.handleChanged(t),this.applyPlaceholder(t),t.addListener("selectionChanged",this.handleSelectionChange)}destroy(t){t.removeListener("selectionChanged",this.handleSelectionChange)}handleBeforeKeyDown(t,e){if(!t.selection.range.isSimple())return!1;const{containerId:r,blockIndex:i,offset:s}=t.getTextPosition();if(!vu.isDocumentTitleBlock(r,i)||!or(e,"Enter"))return!1;let l=!1,a=null;Io(t.rootContainer)===2&&(a=Fr(t.rootContainer,1),ut(t,a)===0&&(l=!0));const d=t.getFirstBlock();return t.undoManager.runInGroup(()=>{t.breakTextBlock(d,s,{forceInsertAfter:!0}),l&&a&&t.deleteBlock(a)}),!0}handleChanged(t){var e,o;try{const r=t.doc.getContainerBlocks(ct(t.rootContainer));g(l7,r.length>0,"root container is empty");const i=r[0];if(i.type!=="text"){const s=cr("",{heading:(e=this.options.headingLevel)!=null?e:1});t.insertBlock(ct(t.rootContainer),0,s,t.selection.range.toDocRange());return}if(g(l7,i.text,"invalid text block"),xP(i.text)||i.quoted||i.heading!==this.options.headingLevel){const s=t.getBlockById(i.id),l=t.getBlockString(s),a=cr(l,{heading:(o=this.options.headingLevel)!=null?o:1,quoted:!1}),d=t.selection.focusedBlock;let h=t.selection.range;const p=t.insertBlock(ct(t.rootContainer),0,a);d===s&&(h=ke(t,a.id,ut(t,p))),Bh(t,s,h)}if(r.length>1)return;t.insertTextBlock("",ct(t.rootContainer),1,{newRange:t.selection.range.toDocRange()})}finally{this.applyPlaceholder(t)}}handleRemoteChanged(t){setTimeout(()=>{this.applyPlaceholder(t)})}handleUpdateCompositionText(t){this.applyPlaceholder(t)}applyPlaceholder(t){var e,o;!((e=this.options)!=null&&e.titlePlaceholder)&&!((o=this.options)!=null&&o.contentPlaceholder)||EP(t,this.options)}static isDocumentTitleBlock(t,e){return t==="root"&&e===0}}const c7=S("code-dom");function Qi(n){return Dt(n)==="code"}function a7(n,t,e){e.language?t.setAttribute("data-language",e.language):t.removeAttribute("data-language"),e.nowrap?ot(t,"wrap"):W(t,"wrap")}function R0(n){const t=n.closest("div[data-type=editor-block][data-block-type=code]");return g(c7,t,"no parent code block"),g(c7,Qi(t),"not a code block"),t}const yu={plain:{name:"Plain Text",aliases:["txt","text"]},abap:{name:"ABAP",aliases:["abap"]},arduino:{name:"Arduino",aliases:["ino"]},bash:{name:"Bash",aliases:["sh","shell"]},basic:{name:"BASIC",aliases:["bas"]},c:{name:"C",aliases:["c"]},clojure:{name:"Clojure",aliases:["clj"]},cofeescript:{name:"CoffeeScript",aliases:["coffee"]},cpp:{name:"C++",aliases:["cpp","cxx"]},csharp:{name:"C#",aliases:["cs"]},css:{name:"CSS",aliases:["css"]},dart:{name:"Dart",aliases:["dart"]},diff:{name:"Diff",aliases:["diff","patch"]},docker:{name:"Docker",aliases:["dockerfile"]},elixir:{name:"Elixir",aliases:["ex","exs"]},elm:{name:"Elm",aliases:["elm"]},erlang:{name:"Erlang",aliases:["erl"]},flow:{name:"Flow",aliases:["flow"]},fortran:{name:"Fortran",aliases:["f","for","f77","f90"]},fsharp:{name:"F#",aliases:["fsharp"]},gherkin:{name:"Gherkin",aliases:["feature"]},glsl:{name:"GLSL",aliases:["glsl"]},go:{name:"Go",aliases:["go"]},graphql:{name:"GraphQL",aliases:["graphql"]},groovy:{name:"Groovy",aliases:["groovy"]},haskell:{name:"Haskell",aliases:["hs"]},java:{name:"Java",aliases:["java"]},js:{name:"JavaScript",aliases:["js","jsx"]},json:{name:"JSON",aliases:["json"]},julia:{name:"Julia",aliases:["jl"]},kotlin:{name:"Kotlin",aliases:["kt","ktm","kts"]},latex:{name:"LaTeX",aliases:["tex"]},less:{name:"LESS",aliases:["less"]},lisp:{name:"Lisp",aliases:["lisp"]},livescript:{name:"LiveScript",aliases:["ls"]},lua:{name:"Lua",aliases:["lua"]},makefile:{name:"Makefile",aliases:["mk","mak"]},markdown:{name:"Markdown",aliases:["md","mkdown","mkd"]},markup:{name:"HTML / XML",aliases:["html","htm","xml","xsd","xsl","xslt","wsdl"]},matlab:{name:"MATLAB",aliases:["matlab"]},mermaid:{name:"Mermaid",aliases:["mermaid"]},nix:{name:"Nix",aliases:["nix"]},objectivec:{name:"Objective-C",aliases:["m","mm"]},ocaml:{name:"OCaml",aliases:["ml"]},pascal:{name:"Pascal",aliases:["pas"]},perl:{name:"Perl",aliases:["pl","pm"]},php:{name:"PHP",aliases:["php"]},powershell:{name:"PowerShell",aliases:["ps","ps1"]},prolog:{name:"Prolog",aliases:["plg"]},protobuf:{name:"Protocol Buffers",aliases:["proto"]},python:{name:"Python",aliases:["py"]},r:{name:"R",aliases:["r"]},reason:{name:"Reason",aliases:["re","rei"]},ruby:{name:"Ruby",aliases:["rb"]},rust:{name:"Rust",aliases:["rs"]},sass:{name:"Sass",aliases:["sass"]},scala:{name:"Scala",aliases:["scala"]},scheme:{name:"Scheme",aliases:["scm","sm"]},scss:{name:"SCSS",aliases:["scss"]},solidity:{name:"Solidity",aliases:["sol"]},sql:{name:"SQL",aliases:["sql"]},swift:{name:"Swift",aliases:["swift"]},typescript:{name:"TypeScript",aliases:["ts","tsx"]},vbnet:{name:"VB.Net",aliases:["vbnet"]},verilog:{name:"Verilog",aliases:["v"]},vhdl:{name:"VHDL",aliases:["vhdl"]},"visual-basic":{name:"Visual Basic",aliases:["vb","vba"]},wasm:{name:"WebAssembly",aliases:["wasm"]},yaml:{name:"YAML",aliases:["yaml"]}};function u7(n){const t=n.toLocaleLowerCase();let e="";return Object.entries(yu).forEach(([o,r])=>{(o===t||r.aliases.includes(t)||r.name.toLocaleLowerCase()===t)&&(e=o)}),e}function d7(n){const t=n.settingsProvider.getItem("editor-code-lang");return t!=null?t:"plain"}function IP(n,t){return n.settingsProvider.setItem("editor-code-lang",t)}const TP=S("convert-to-code");function DP(n,t){if(!tt(n,t))return null;const e={id:K(),type:"text",text:[]},o=K();n.doc.localInsertChildContainer(o,[e]);const r=n.getBlockData(t).text;g(TP,r,"no text");let i=ie(r);i.startsWith("```")&&(i=i.substring(3));const s=u7(i)||d7(n)||"plain";return{blockData:{id:K(),type:"code",language:s,children:[o]},focusBlockId:e.id}}const Fnt="",O0=S("code-block-child-container");function Ac(n){g(O0,Qi(n),"not a code block");const e=Lt(n).querySelector(":scope > div.editor-code-root > div.code-text-root [data-type=editor-container].child");return g(O0,e,"no code text container"),e}function Qs(n){g(O0,Qi(n),"not a code block");const e=Lt(n).querySelector(":scope > div.editor-code-root > div.code-caption-root [data-type=editor-container].child");return e||null}function Tf(n){const t=[Ac(n)],e=Qs(n);return e&&t.push(e),t}function bc(n,t){if(!tt(n,t))return!1;const e=nt(t),o=et(e);return o?Qi(o)?e===Ac(o):Dt(t)==="code":!1}const _0=S("code-caption");function SP(n,t){if(n.readonly)return;const e=Qs(t);if(e){const a=ye(e);n.selection.selectBlock(a,0);return}const o=qr(n.doc),r=n.getBlockData(t);g(_0,r.children.length===1,"code block should have only one child");const i={...r,children:[r.children[0],o]};n.updateBlockData(t,i);const s=n.getContainerById(o),l=ye(s);n.selection.selectBlock(l,0)}function h7(n,t){const e=nt(t);if(Yt(e))return!1;const o=et(e);if(g(_0,o,"no parent block"),!Qi(o))return!1;const i=Qs(o);return e===i}function LP(n,t){if(n.readonly||!Qs(t))return;const o=Ac(t),r=Qe(o);n.selection.selectBlock(r,ut(n,r));const i=n.getBlockData(t);g(_0,i.children.length===2,"code block should have only one child");const s=i.children[1],l={...i,children:[i.children[0]]};n.updateBlockData(t,l),n.deleteChildContainers([s])}const MP=S("paste-in-table-block");class RP{constructor(t){this.editor=t,setTimeout(()=>{t.input.addHandler(this)})}destroy(){}async handleBeforePaste(t,e,o){if(!t.selection.range.isSimple())return!1;const r=t.selection.range.start,i=t.getBlockById(r.blockId),s=nt(i);if(Yt(s))return!1;const l=et(s);if(g(MP,l,"no parent block"),!Qi(l)||h7(t,i))return!1;const a=o["text/x-ones-editor-doc"];let d=null;if(a){const p=La(t,a);d=Wr(p)}else d=o["text/plain"];if(!d)return!0;const h=d;return t.undoManager.runInGroup(()=>{t.clearSelectedContents(),t.insertDoc(i,r.offset,h)}),!0}}function OP(n){n.addCustom("code-block-paste-event",t=>new RP(t))}class _P{constructor(t){m(this,"id","CodeBlockCommandProvider");setTimeout(()=>{t.editorCommandProviders.registerCommandProvider(this)})}destroy(){}getAvailableCommands(){return[]}executeCommand(){return!1}filterCommands(t,e,o,r){if(bc(t,e))return[]}beforeExecuteCommand(t,e,o,r,i){return!!bc(t,e)}}function FP(n){n.addCustom("code-block-command-provider",t=>new _P(t))}const PP=S("code-caption-input-handler");function F0(n){if(!n.selection.range.isSimple())return null;const t=n.selection.range.start;if(!t.isSimple())return null;const e=n.getBlockById(t.blockId);return h7(n,e)?e:null}function NP(n,t){var i;const e=F0(n);if(or(t,"Shift+Enter")){const s=n.selection.range.start;return!!((i=n.getBlockById(s.blockId).closest("div[data-type=editor-block][data-block-type=code]"))!=null?i:null)}if(!e)return!1;const o=R0(e),r=Zt(o);return r?(n.selection.selectBlock(r,0),!0):(n.insertTextBlock("",ct(nt(o)),bt(o)+1),!0)}function $P(n,t){if(ae(n,t)){const e=R0(t);return LP(n,e),!0}return!1}function HP(n){var e;const{start:t}=n.selection.range;if(t.isSimple()){const o=n.getBlockById(t.blockId),r=(e=o.closest("div[data-type=editor-block][data-block-type=code]"))!=null?e:null;if(!r)return!1;const i=Qs(r),s=i&&!ae(n,ye(i));if(!r||!ae(n,o)||s)return!1;const l=gn(n,r)[0],a=fe(l);if(a.length>1)return!1;if(l&&a[0]===o)return n.deleteBlock(r),!0}return!1}function jP(n){const t=F0(n);return t?$P(n,t):HP(n)}class P0{constructor(t){setTimeout(()=>{t.input.addHandler(this)})}destroy(){}handleBeforeKeyDown(t,e){return e.key==="Enter"?NP(t,e):e.key==="Backspace"?jP(t):!1}async handleBeforePaste(t,e,o){const r=F0(t);if(!r)return!1;const i=o["text/plain"];if(!i)return!0;const s=La(t,i);return s&&t.undoManager.runInGroup(()=>{t.clearSelectedContents();const l=t.selection.range.start;g(PP,l.isSimple(),"not simple position"),t.insertTextToBlock(r,l.offset,s)}),!0}static init(t){t.addCustom("code-block-caption-input-handler",e=>new P0(e))}}function UP(n){const o=new DOMParser().parseFromString(n,"text/html").querySelector("svg");if(!o)return null;const r=o.getAttribute("viewBox");if(!r)return null;const i=r.split(" ");if(i.length===4){const s=i[2],l=i[3];return o.setAttribute("width",s),o.setAttribute("height",l),o.outerHTML}return null}function N0(n,t,e=!0){const o=new Image,r=document.createElement("canvas"),i=r.getContext("2d");if(!i){t(new Error("failed to get context"),null);return}o.onload=()=>{if(r.width=o.naturalWidth,r.height=o.naturalHeight,e&&(r.width===0||r.height===0)){const s=n.substring(26);if(s){const l=atob(s),a=UP(l);if(a){Im(a,"image/svg+xml").then(d=>{N0(d,t,!1)});return}}t(null,null);return}i.drawImage(o,0,0),r.toBlob(s=>{t(null,s)},"image/png")},o.src=n}function zP(n){return new Promise((t,e)=>{N0(n,(o,r)=>{if(o){e(o);return}if(!r){e(new Error("Failed to get image blob"));return}t(r)})})}async function f7(n){const t=await jl(n);return new Promise((e,o)=>{N0(t,(r,i)=>{if(r){o(r);return}if(!i){o(new Error("Failed to get image blob"));return}e(i)})})}const m7="Untitled";function g7(n){const t=ye(n.rootContainer);return!t||!tt(n,t)?m7:n.getBlockString(t)||m7}function $0(){return Object.prototype.hasOwnProperty.bind(window,"isSecureContext")?window.isSecureContext:window.location.protocol==="https:"||window.location.hostname==="localhost"||window.location.hostname==="127.0.0.1"}function VP(n){let t;return n.forEach((e,o)=>{o.toLocaleLowerCase()==="content-type"&&(t=e)}),t!=null?t:""}async function p7(n){try{const t=await fetch(n,{credentials:"same-origin"}),e=await t.blob(),o=VP(t.headers).toLocaleLowerCase();let r="";if(o){const s=fm.default[o].extensions;s&&s.length>0&&(r=s[0])}return new File([e],`${Date.now()}.${r}`,{type:o})}catch{return null}}const WP=`
404
404
  <svg fill="currentColor" focusable="false" viewBox="0 0 24 24" aria-hidden="true" tabindex="-1">
405
405
  <path d="M8.12 9.29 12 13.17l3.88-3.88c.39-.39 1.02-.39 1.41 0 .39.39.39 1.02 0 1.41l-4.59 4.59c-.39.39-1.02.39-1.41 0L6.7 10.7a.9959.9959 0 0 1 0-1.41c.39-.38 1.03-.39 1.42 0z"></path>
406
406
  </svg>`,qP=`
@@ -420,7 +420,7 @@ ${s}
420
420
  <p>${l}</p>`}const j0={blockType:"code",blockKind:"complex",createBlockContent:iN,getBlockTextLength:sN,getRangeFromPoint:lN,moveCaret:cN,getCaretRect:aN,updateSelection:uN,clearSelection:dN,getChildContainers:hN,getNextContainer:fN,getSelectedContainers:mN,convertFrom:DP,handleBlockElementUpdated:gN,getOptions:CN,getBlockProperties:AN,convertTo:bN},U0={...Dn,blockType:"code-line"};class vN{constructor(t){m(this,"handleSelectionChange",()=>{const t=this.editor.selection;if(!t.range.isCollapsed())return;const e=t.focusedBlock;if(!bc(this.editor,e))return;const o=e,r=t.range.focus.offset,i=L4(this.editor,o,r,"code-caret");i.scrollIntoView({block:"nearest"}),setTimeout(()=>{i.remove(),this.editor.selection.caret.update()})});this.editor=t,t.addListener("selectionChanged",this.handleSelectionChange)}destroy(){this.editor.removeListener("selectionChanged",this.handleSelectionChange)}}function A7(n,t){const e=n.split(`
421
421
  `).map(s=>({id:K(),type:"text",text:Oi(s)})),o=K();return{blocks:{root:[{children:[o],type:"code",id:K(),...t}],[o]:e},meta:{},comments:{}}}class yN{handleBeforeCopy(t,e,o){const r=t.getFocusedBlock();if(!bc(t,r))return;const i=R0(r),s=t.getBlockData(i),{language:l,nowrap:a}=s;if(t.selection.range.isCollapsed()){const h=t.getBlockString(r);return A7(h,{language:l,nowrap:a})}const d=t.getSelectedText();return A7(d,{language:l,nowrap:a})}}function kN(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!!bc(n,t)){if(n.selection.range.isCollapsed()){const e=n.selection.range.start;return n.insertTextToBlock(t,e.offset," "),!0}return n.undoManager.runInGroup(()=>{Ro(n).forEach(o=>{n.insertTextToBlock(o.block,0," ")})}),!0}}function wN(n){if(!n.isWritable())return!1;const t=n.getFocusedBlock();if(!bc(n,t))return;const e=[" "," "];return n.undoManager.runInGroup(()=>{Ro(n).forEach(r=>{const i=ie(n.getBlockText(r.block));for(let s=0;s<e.length;s++){const l=e[s];if(i.startsWith(l)){n.deleteTextFromBlock(r.block,0,l.length);break}}})}),!0}function BN(n){const t=n.getFocusedBlock(),e=nt(t);if(Yt(e))return;const o=et(e);if(!o||Dt(o)!=="code")return;const r=n.selection.range;if(!!r.isSimple()&&!SA(e,r))return Gg(n,e),!0}const EN={Tab:kN,"Shift+Tab":wN,"CtrlOrCmd+A":BN},ku=S("code-text-decorate");class Df{decorateText(t,e,o){var v;if(g(ku,e.length>0,"invalid path"),e.length===1)return{};const r=e[e.length-2];if(t.doc.getBlockData(r.containerId,r.blockIndex).type!=="code")return{};const s=o;if(s.length===0)return{};const l=ie(s),a=t.doc.getBlockData(r.containerId,r.blockIndex),d=aa.default.tokenize(l,(v=aa.default.languages[a.language])!=null?v:aa.default.languages.plain),h=(B,D)=>{if(g(ku,B,"no token"),typeof B=="string")return[{insert:B,attributes:mt.default(D)}];g(ku,B instanceof aa.default.Token,"invalid token type");const x=B.content,_=mt.default(D);return _[`style-code-${B.type}`]=!0,typeof x=="string"?[{insert:x,attributes:_}]:Array.isArray(x)?x.map(z=>h(z,_)).flat():(g(ku,x instanceof aa.default.Token,"invalid token"),h(x,_))},A=d.map(B=>h(B,{})).flat();return g(ku,rn(A)===rn(s),"failed to highlight code, text length mismatch"),{text:A}}}const xN={code:{title:"\u4EE3\u7801",abstract:"\u4EE3\u7801",wrap:"\u6362\u884C",copy:"\u590D\u5236",caption:"\u8BF4\u660E",search:"\u8F93\u5165\u5173\u952E\u8BCD\u641C\u7D22",copySuccess:"\u590D\u5236\u6210\u529F"}},IN={code:{title:"Code",abstract:"Code",wrap:"Wrap",copy:"Copy",caption:"Caption",search:"Search",copySuccess:"Copied successfully"}},TN={code:{title:"\u30B3\u30FC\u30C9",abstract:"\u30B3\u30FC\u30C9",wrap:"\u6298\u308A\u8FD4\u3059",copy:"\u8907\u88FD",caption:"\u4F8B\u8A3C\u3059\u308B",search:"\u30AD\u30FC\u30EF\u30FC\u30C9\u3067\u691C\u7D22",copySuccess:"\u30B3\u30D4\u30FC\u3055\u308C\u307E\u3057\u305F"}};R.mergeLang({"zh-CN":xN,"en-US":IN,"ja-JP":TN});const DN=S("image-data"),b7=1e3,z0=400,SN=10;function vc(n){return n.src.startsWith("empty:")||!n.src}function LN(n){return n.src.startsWith("http:")||n.src.startsWith("https:")}function v7(n){return`${Pd.default(n)}_width`}function y7(n){return`${Pd.default(n)}_height`}function k7(n){return`${n}_flex`}function w7(n){let t=n.getBoundingClientRect().width;return t-=Number.parseFloat(window.getComputedStyle(n).paddingLeft)+Number.parseFloat(window.getComputedStyle(n).paddingRight),t}function wu(n){if(n.every(r=>typeof r.flex=="number"&&r.flex))return;const t=100,o=n.map(r=>{const i=r.height==="auto"?r.width/t:r.height/t;return r.width/i}).reduce((r,i)=>r+i,0);n.forEach(r=>{const i=r.height==="auto"?r.width/t:r.height/t,s=r.width/i;r.flex=s/o})}function yc(n){const t=(r,i)=>{r||(r=`empty:${i}`);const s=v7(r),l=y7(r),a=k7(i);let d=n[s],h=n[l],p=n[a];return typeof d=="string"&&(d=Number.parseInt(d,10)),typeof h=="string"&&(h=Number.parseInt(h,10)),typeof p=="string"&&(p=Number.parseInt(p,10)),d&&h?{src:r,width:d,height:h,flex:p,virtualSize:!1}:d&&!h?{src:r,width:d,height:"auto",flex:p,virtualSize:!1}:(d=b7,h=z0,{src:r,width:d,height:h,flex:p,virtualSize:!0})};let e=[];const o=n.src;return Array.isArray(o)?e=o.map(t):typeof o=="string"&&(e=o.split("|").map(t)),wu(e),e}function Vo(n){const t=n.embedData;return yc(n.embedData).length>1?100:t.widthPercent}function MN(n,t,e,o){const r=yc(t.embedData);if(r.length>1||o)return"100%";const i=Vo(t),s=n.rootContainer.getBoundingClientRect().width;if(i){const l=w7(e);return`${Math.min(s*i/100,l)}px`}return r[0].width?`${r[0].width}px`:"auto"}function cn(n,t){const o={src:n.map(r=>r.src).join("|"),widthPercent:t};return n.forEach((r,i)=>{if(r.width&&r.height&&!r.virtualSize){const l=r.src||`empty:${i}`,a=v7(l);o[a]=r.width;const d=y7(l);r.height!=="auto"&&(o[d]=r.height)}g(DN,r.flex,"no image flex");const s=k7(i);o[s]=r.flex}),o}function RN(n,t,e,o){const r=yc(t.embedData),i=r.length===1?n.rootContainer:e;if(r.length===1&&o)return`${z0}px`;if(r.some(h=>h.height==="auto"))return"auto";const s=Vo(t);if(!s)return"";let l=i.getBoundingClientRect().width*(s/100);if(l-=Number.parseFloat(window.getComputedStyle(i).paddingLeft)+Number.parseFloat(window.getComputedStyle(i).paddingRight),i===n.rootContainer&&i!==e&&(l=Math.min(l,w7(e))),r.length===1){const h=r[0];return h.virtualSize?"":`${h.height/(h.width/l)}px`}l-=(r.length-1)*SN;const a=r.reduce((h,p)=>h+p.flex,0);let d=0;for(const h of r){const A=l*h.flex/a/h.width*h.height;d=Math.max(A,d)}return`${d}px`}function ON(n){return n.reduce((e,o)=>e+o.flex,0)}function _N(n,t){w("div",["resize-gripper",t],n).setAttribute("data-resize-type",t)}function V0(n){return te(n).querySelector(".block-resizer")}function FN(n){const t=V0(n);t&&ot(t,"active")}function B7(n,t,e){const o=n.getBoundingClientRect(),r=t.getBoundingClientRect(),i=r.top-o.top,s=r.left-o.left,l=r.width,a=r.height;e.style.top=`${i}px`,e.style.left=`${s}px`,e.style.width=`${l}px`,e.style.height=`${a}px`}function PN(n,t,e,o){const r=V0(n);if(r)return W(r,"active"),B7(n,t,r),r;const i=te(n),s=w("div",["block-resizer"],i);return B7(n,t,s),e.resize.forEach(l=>{_N(s,l)}),s.addEventListener("mousedown",o),W(s,"active"),s}function W0(n,t){const e=V0(n);if(!e||!Xt(n,t))return;const o=n.getBoundingClientRect(),r=t.getBoundingClientRect(),i=r.top-o.top,s=r.left-o.left,l=r.width,a=r.height;e.style.top=`${i}px`,e.style.left=`${s}px`,e.style.width=`${l}px`,e.style.height=`${a}px`}const Pnt="",NN=S("block-resizer");class Bu extends ve.TypedEmitter{constructor(e,o){super();m(this,"resizableElement");m(this,"block",null);m(this,"startRect",null);m(this,"startPos",null);m(this,"resizeType",null);m(this,"enabled",!1);m(this,"handleMouseDown",e=>{e.preventDefault(),e.stopPropagation();const o=this.getResizableElement();if(!o||e.button!==0)return;const r=e.target;if(!r||!(r instanceof HTMLElement))return;const i=r.getAttribute("data-resize-type");!i||(this.bindEvents(),this.startRect=o.getBoundingClientRect(),this.startPos=e,this.resizeType=i,ma(window.getComputedStyle(r).cursor),this.block&&this.editor.selection.selectBlock(this.block,0))});m(this,"handleMouseMove",e=>{if(!this.startPos||!this.startRect||!this.resizeType||!this.getResizableElement()||!this.block)return;const r=e.x-this.startPos.x,i=e.y-this.startPos.y,s=this.startRect;let{top:l,left:a,right:d,bottom:h}=s;(this.resizeType==="bottom"||this.resizeType==="bottom-left"||this.resizeType==="bottom-right")&&(h+=i),(this.resizeType==="top"||this.resizeType==="top-left"||this.resizeType==="top-right")&&(l+=i),(this.resizeType==="left"||this.resizeType==="top-left"||this.resizeType==="bottom-left")&&(a+=r),(this.resizeType==="right"||this.resizeType==="top-right"||this.resizeType==="bottom-right")&&(d+=r);const p=d>a?d-a:0,A=h>l?h-l:0,v=new DOMRect(a,l,p,A);this.emit("resizing",this,v);const B=this.getResizableElement();B&&W0(this.block,B)});m(this,"handleMouseUp",e=>{if(e.button!==0)return;ma(""),this.unbindEvents(),this.emit("resized",this);const o=this.getResizableElement();!o||!this.block||W0(this.block,o)});this.editor=e,this.options=o}enableResize(e,o){this.block=e,this.resizableElement=o,this.createResizer(),this.enabled=!0}disableResize(){!this.block||(FN(this.block),this.enabled=!1)}update(e,o){this.block=e,this.resizableElement=o,this.getResizableElement()&&this.enabled&&this.createResizer()}updateResizer(){const e=this.getResizableElement();e&&this.block&&W0(this.block,e)}getBlock(){return this.block}destroy(){}getResizableElement(){return this.resizableElement?this.resizableElement:this.block?Lt(this.block):null}createResizer(){const e=this.getResizableElement();!e||!this.block||(g(NN,Xt(this.block,e),"not a block child element"),PN(this.block,e,this.options,this.handleMouseDown))}bindEvents(){document.addEventListener("mousemove",this.handleMouseMove),document.addEventListener("mouseup",this.handleMouseUp)}unbindEvents(){document.removeEventListener("mousemove",this.handleMouseMove),document.removeEventListener("mouseup",this.handleMouseUp)}}const $N=S("image-dom");function E7(n){return n.querySelector(".uploading-progress-mask")}function HN(n){const t=E7(n);if(t)return t;const e=w("div",["uploading-progress-mask"],n),o=w("div",["uploading-progress-bar"],e);return w("div",["uploading-progress-bar-value"],o),o}function jN(n){const e=HN(n).querySelector(".uploading-progress-bar-value");return g($N,e,"no progress value"),e}function x7(n,t){const e=jN(n);e.style.width=`${t}%`}function UN(n){var t;(t=E7(n))==null||t.remove()}function Eu(n,t,e,o){const r=e!=null?e:n.findBlockById(t.id);if(!r)return;const i=o||nt(r),s=!!r.querySelector(".images > .image-container.error, .images > .image-container.empty "),l=MN(n,t,i,s),a=RN(n,t,i,s),d=Lt(r);l==="auto"?d.style.width=l:(d.style.maxWidth=l,d.style.width="100%");const h=r.querySelector(".images");!h||(h.style.height=a||"none")}function zN(n){let t;return n.forEach((e,o)=>{o.toLocaleLowerCase()==="content-type"&&(t=e)}),t!=null?t:""}async function VN(n){try{const t=await fetch(n,{credentials:"same-origin"}),e=await t.blob(),o=zN(t.headers).toLocaleLowerCase();let r="";if(o){const s=fm.default[o].extensions;s&&s.length>0&&(r=s[0])}return new File([e],`${Date.now()}.${r}`,{type:o})}catch{return null}}function Yi(n,t){const e=typeof t=="string"?t:it(t);return n.getCustom(`image-${e}`)}function Sf(n,t){if(!t||!(t instanceof Node))return null;const e=et(t);return e?Yi(n,e):null}function Ar(n){return Array.from(n.querySelectorAll(".image-container"))}const q0=S("table-resize-drag-drop");class WN{constructor(t,e,o,r){m(this,"cursor","col-resize");m(this,"initWidths");this.editor=t,this.elem=e,this.data=o,this.mouseDownEvent=r;const i=this.data.block,l=Yi(this.editor,i).getImages(),a=this.data.splitterIndex;g(q0,a>=0&&a<l.length-1,`invalid splitter index: ${a}`);const h=Ar(i).map(p=>p.getBoundingClientRect().width);this.initWidths=h}onDragStart(t,e,o){if(!this.editor.isWritable())return;const r=this.data.block;Yi(this.editor,r).setResizing(!0)}onDragging(t,e,o,r,i){const s=this.data.block,l=Yi(this.editor,s),a=mt.default(l.getImages()),d=this.data.splitterIndex;g(q0,d>=0&&d<a.length-1,`invalid splitter index: ${d}`);const h=this.initWidths[d],p=this.initWidths[d+1];if(h+p<100)return;let A=r;h+A<50&&(A=50-h),p-A<50&&(A=p-50);const D=[...this.initWidths];D[d]+=A,D[d+1]-=A;const x=Ar(s);g(q0,x.length===a.length,"invalid image data");const _=D.reduce((z,q)=>z+q,0);for(let z=0;z<a.length;z++){const q=D[z]/_;a[z].flex=q,x[z].style.flexGrow=`${q}`}const M=mt.default(this.editor.getBlockData(s)),H=cn(a,Vo(M));M.embedData=H,Eu(this.editor,M,s,null)}onDragEnd(t,e,o,r,i){const s=this.data.block,l=Yi(this.editor,s),d=Ar(s).map(h=>Number.parseFloat(h.style.flexGrow));l.updateFlex(d),l.setResizing(!1)}}function I7(n){var t;return!n||!(n instanceof HTMLElement)?null:xt(n,"image-splitter")?n:(t=n.closest(".image-splitter"))!=null?t:null}function qN(n,t){var s;const e=I7(t.target);if(!e)return;const o=et(e);if(!o)return;Yi(n,o).setSelectedIndex(-1),n.selection.selectBlock(o,0);const r=Number.parseInt((s=e.getAttribute("data-index"))!=null?s:"",10);if(Number.isNaN(r)||typeof r!="number")return;const i={block:o,splitterIndex:r};ym(new WN(n,e,i,t))}function GN(n,t){t.preventDefault(),t.stopPropagation();const e=I7(t.target);if(!e)return;const o=et(e);!o||Yi(n,o).resetFlex()}function ZN(n,t,e,o){const r=w("div",["image-splitter"],e);w("div",["image-splitter-indicator"],r),r.setAttribute("data-index",`${o}`),n.domEvents.addEventListener(r,"mousedown",qN),n.domEvents.addEventListener(r,"dblclick",GN)}const QN=S("image-item");function T7(n){return!n||!(n instanceof Node)?null:et(n)}function D7(n){const t=T7(n);return t?Ar(t):[]}function G0(n){if(!n||!(n instanceof Node))return null;const t=n instanceof Element?n:n.parentElement;if(!t)return null;const e=t.closest(".image-container");return e||null}function xu(n){const t=G0(n);return t?D7(n).indexOf(t):-1}async function YN(n,t){const e=Sf(n,t.target);if(!e)return;const o=xu(t.target);if(o===-1)return;const r=t.target;if(!(r instanceof HTMLImageElement))return;const i=e.getImages()[o];if(vc(i)||n.readonly||!e.isAutoFix()||(setTimeout(()=>{e.setAutoFix(!1)},400),i.height==="auto"&&e.fixImageSize(o,r),i.virtualSize&&e.fixImageSize(o,r),!i||!LN(i)||i.downloading))return;i.downloading=!0;const s=await VN(i.src);s?e.replaceImage(o,s):QN.warn(`failed to download image: ${i.src}`)}function JN(n,t,e){if(t.querySelector(".load-error"))return;const r=e.src.startsWith("http:")||e.src.startsWith("https:"),i=w("div",["load-error"],t),s=w("div",["error-icon"],i);s.innerHTML=sv;const l=w("div",["error-message"],i);r?(l.innerHTML=R.t("image.load.remote.failed"),n.domEvents.addEventListener(i,"click",(a,d)=>{d.preventDefault(),d.target instanceof HTMLElement&&d.target.tagName==="A"&&window.open(e.src,"_blank")})):(l.innerHTML=R.t("image.load.failed"),n.domEvents.addEventListener(i,"click",(a,d)=>{d.preventDefault(),d.stopPropagation(),d.target instanceof HTMLElement&&d.target.tagName==="A"&&e$(a,d.target)}))}function Z0(n,t){setTimeout(()=>{if(Xt(n.rootContainer,t)){const e=n.getBlockData(t);Eu(n,e,null,null)}})}function KN(n,t){const e=Sf(n,t.target);if(!e)return;const o=xu(t.target);if(o===-1)return;const r=e.getImages()[o];if(!r)return;const i=G0(t.target);if(!i)return;W(i,"error","error-load");const s=et(i);s&&Z0(n,s),i.innerHTML="",JN(n,i,r)}function XN(n,t,e){if(t.querySelector(".upload-error"))return;const r=w("div",["upload-error"],t),i=w("div",["error-icon"],r);i.innerHTML=sv;const s=w("div",["error-message"],r);s.innerHTML=R.t("image.upload.failed"),n.domEvents.addEventListener(r,"click",(l,a)=>{if(a.preventDefault(),!a.target||!(a.target instanceof Element)||a.target.tagName!=="A")return;const d=Sf(l,a.target),h=xu(a.target);!d||h===-1||d.replaceImage(h,e)})}function S7(n,t,e,o,r){const i=Ar(t)[e];!i||(W(i,"error","error-upload"),Z0(n,t),i.innerHTML="",XN(n,i,r))}function L7(n,t,e,o,r,i,s){const l=w("div",["image-container"],e);if(l.setAttribute("data-src",o.src),s.length>1&&(l.style.flexShrink=`${o.flex}`,l.style.flexGrow=`${o.flex}`),i===r&&W(l,"active"),vc(o)){W(l,"empty");const d=w("div",["upload-image-icon"],l);return d.innerHTML=wL,l}const a=w("img",["editor-image"],l);if(a.src=n.doc.buildResourceUrl(o.src),n.domEvents.addEventListener(a,"load",YN),n.domEvents.addEventListener(a,"error",KN),o.src.startsWith("https:")||o.src.startsWith("http:")){const d=w("div",["image-warning"],l);d.innerHTML=iv,d.setAttribute(`data-editor-tooltip-${n.clientId}`,R.t("image.load.remote.tooltip"))}return l}function t$(n,t,e,o,r){const i=w("div",["images"],e);return o.forEach((s,l)=>{l>0&&ZN(n,t,i,l-1),L7(n,t,i,s,l,r,o)}),o.length>1&&W(t,"multi"),i}function M7(n,t,e,o,r,i){const l=Array.from(t.querySelectorAll(".image-container"))[o];if(!l)return;const a=L7(n,t,null,e,o,r,i);l.insertAdjacentElement("beforebegin",a),l.remove(),Z0(n,t)}function Iu(n,t){return Ar(n)[t]}function e$(n,t){const e=T7(t);if(!e)return;const o=xu(t);if(o===-1)return;const r=Sf(n,t);if(!r)return;const i=r.getImages()[o];M7(n,e,i,o,r.getSelectedIndex(),r.getImages())}function Wo(n){return Dt(n)==="embed"&&fn(n)==="image"}async function R7(n){return new Promise((t,e)=>{const o=new Image;o.onload=()=>{t({width:o.naturalWidth,height:o.naturalHeight})},o.onerror=e,o.src=n})}async function n$(n){const t=await jl(n);return R7(t)}function O7(n){var o;let t="image/*";const e=(o=n.getComponentOptions("image"))==null?void 0:o.allowedMedias;return e&&(t=e.map(r=>`.${r}`).join(",")),t}function _7(n,t){var s;const{maxSize:e,allowedMedias:o,callbacks:r}=(s=n.getComponentOptions("image"))!=null?s:{};if(e&&t.size>e){const l=new Error("image is too large");throw l.code="MaxMediaSize",r!=null&&r.onError&&(r==null||r.onError(n,l)),l}const i=Ca(t.name);if(o&&!o.includes(i)){const l=new Error(`media file is not allowed: ${i}`);throw l.code="NotAllowedFile",r!=null&&r.onError&&(r==null||r.onError(n,l)),l}}function F7(n){return n.startsWith("image/")}const P7=S("image-object");class Ie{constructor(t,e){m(this,"images",[]);m(this,"selectedIndex",-1);m(this,"blockResizer");m(this,"resizing",!1);m(this,"parentContainerResizerObserver",null);m(this,"autoFix",!1);m(this,"handleMouseDown",async(t,e)=>{const o=xu(e.target);if(o===-1)return;const r=this.images[o];vc(r)||this.setSelectedIndex(o)});m(this,"handleRootContainerResize",()=>{this.handleEditorResize(this.editor.rootContainer)});m(this,"handleEditorResize",t=>{if(this.isEmpty()||this.resizing)return;const e=this.editor.findBlockById(this.blockData.id);!e||nt(e)===t&&Eu(this.editor,this.blockData,e,null)});m(this,"handleResizing",(t,e)=>{const o=this.editor.findBlockById(this.blockData.id);if(!o)return;this.autoFix||this.setAutoFix(!0);const i=this.editor.rootContainer.getBoundingClientRect().width,s=o.getBoundingClientRect();let l=e.width>s.width?s.width:e.width;l<50&&(l=50);const a=l*100/i;this.blockData.embedData.widthPercent=a,Eu(this.editor,this.blockData,o,null)});m(this,"handleResized",t=>{const e=this.editor.findBlockById(this.blockData.id);if(!e)return;const o=cn(this.images,Vo(this.blockData));this.editor.updateEmbedData(e,o),this.blockResizer.enableResize(e)});m(this,"fixImageSizes",Le.default(()=>{const t=this.editor.findBlockById(this.blockData.id);if(!t)return;const e=cn(this.images,Vo(this.blockData));this.editor.updateEmbedData(t,e)},1e3));this.editor=t,this.blockData=e,this.blockResizer=new Bu(this.editor,{resize:["top-left","top-right","bottom-left","bottom-right"]}),this.blockResizer.addListener("resizing",this.handleResizing),this.blockResizer.addListener("resized",this.handleResized),this.images=yc(this.blockData.embedData)}destroy(){var t;this.blockResizer.removeAllListeners(),this.blockResizer.destroy(),this.editor.domEvents.removeEventListener(null,null,this.handleMouseDown),(t=this.parentContainerResizerObserver)==null||t.disconnect()}setAutoFix(t){this.autoFix=t}isAutoFix(){return this.autoFix}createContent(t,e,o){const r=t$(this.editor,e,o,this.images,this.selectedIndex);if(this.editor.domEvents.addEventListener(o,"mousedown",this.handleMouseDown),this.editor.addListener("resize",this.handleRootContainerResize),Lo(t)){const s=()=>{this.handleEditorResize(t)};this.parentContainerResizerObserver=new ResizeObserver(s),this.parentContainerResizerObserver.observe(t)}const i=()=>!!(this.images.length===1&&this.images[0].virtualSize);this.isEmpty()&&i()&&W(r,"empty"),Eu(this.editor,this.blockData,e,t),setTimeout(()=>{const s=this.editor.findBlockById(this.blockData.id);s&&this.blockResizer.update(s)})}getImages(){return this.images}getWidthPercent(){return Vo(this.blockData)}isEmpty(){return this.images.length===1&&vc(this.images[0])}setResizing(t){this.resizing=t}getSelectedIndex(){return this.selectedIndex}getBlock(){return this.editor.findBlockById(this.blockData.id)}setSelectedIndex(t){const e=this.getBlock();if(!e||t===this.selectedIndex)return;if(this.selectedIndex!==-1){const r=Iu(e,this.selectedIndex);r&&ot(r,"active")}this.selectedIndex=t;const o=Iu(e,t);o&&W(o,"active")}async requestUploadImage(t){const e=this.editor.findBlockById(this.blockData.id);if(!e)return;const o=Iu(e,t);if(xt(o,"error"))return;const r=O7(this.editor),i=await Ul(r);await this.replaceImage(t,i)}tryEnableResizer(){const t=this.editor.findBlockById(this.blockData.id);if(!t||!this.editor.isWritable())return;const e=Iu(t,0);!this.isEmpty()&&this.images.length===1&&!xt(e,"error")&&this.blockResizer.enableResize(t)}disableResizer(){this.blockResizer.disableResize()}fixImageSize(t,e){const o=this.images[t];vc(o)||(o.height==="auto"&&(o.height=e.height),o.width=e.naturalWidth,o.height=e.naturalHeight,o.virtualSize=!1,this.fixImageSizes())}removeImage(t){const e=this.editor.findBlockById(this.blockData.id);if(!e||t===-1||t>=this.images.length)return!1;const o=mt.default(this.images);if(o.splice(t,1),o.length===0)return this.editor.deleteBlock(e),!0;o[0].flex=NaN,wu(o),this.selectedIndex>=o.length&&(this.selectedIndex=o.length-1);const r=cn(o,Vo(this.blockData));return this.editor.updateEmbedData(e,r),!0}async replaceImage(t,e){const o=this.editor.findBlockById(this.blockData.id);if(!o)return!1;try{const i=await jl(e),s=this.images[t];if(s.virtualSize){const{width:a,height:d}=await R7(i);s.width=a,s.height=d,s.virtualSize=!1;const h=cn(this.images,Vo(this.blockData));this.editor.updateEmbedData(o,h)}const l={...s,src:i};M7(this.editor,o,l,t,this.selectedIndex,this.images),setTimeout(()=>{this.blockResizer.update(o)})}catch(i){return S7(this.editor,o,t,i,e),!1}const r=Iu(o,t);if(!r)return!1;W(r,"uploading"),x7(r,0),W(o,"media-block-uploading");try{const i=await this.editor.doc.uploadResource(e,{onProgress:a=>{x7(r,a)}});ot(r,"uploading"),this.images[t].src=i.resourceId;const s=this.editor.findBlockById(this.blockData.id);if(!s)return!1;ot(s,"media-block-uploading");const l=cn(this.images,Vo(this.blockData));return this.editor.updateEmbedData(s,l),!0}catch(i){P7.error(i);const s=this.editor.findBlockById(this.blockData.id);return s&&(ot(r,"uploading"),UN(r),S7(this.editor,s,t,i,e),ot(s,"media-block-uploading")),!1}}updateFlex(t){const e=this.editor.findBlockById(this.blockData.id);if(!e)return;g(P7,t.length===this.images.length,"invalid flex");for(let r=0;r<this.images.length;r++)this.images[r].flex=t[r];const o=cn(this.images,Vo(this.blockData));this.editor.updateEmbedData(e,o)}resetFlex(){const t=this.editor.findBlockById(this.blockData.id);if(!t)return;const e=mt.default(this.images);e[0].flex=NaN,wu(e);const o=cn(e,Vo(this.blockData));this.editor.updateEmbedData(t,o)}setData(t){this.blockData=t,this.images=yc(t.embedData)}static create(t,e){const o=t.addCustom(`image-${e.id}`,()=>new Ie(t,e));return o.setData(e),o}static getImageObject(t,e){let o;return typeof e=="string"?o=e:o=it(e),t.getCustom(`image-${o}`)}}const Nnt="",$nt="";function Lf(n){const t=te(n);let e=t.querySelector(":scope > .block-helper");return e||(e=w("div",["block-helper"],t),w("span",["helper-sizer"],e,"A")),e}function Q0(n,t,e){const o=Lf(n),i=Array.from(o.children).find(s=>{var a;return Number.parseInt((a=s.getAttribute("data-index"))!=null?a:"0",10)>e});o.insertBefore(t,i!=null?i:null)}const N7=40,o$=20;class r${findTargetBlock(t,e){const o=e.target;if(o&&o instanceof Element){const a=et(o);if(a&&Xt(t.rootContainer,a))return a}let r=e.clientX,i=e.clientY;const s=t.rootContainer.getBoundingClientRect().left;r<s&&s-r<N7&&(r+=N7);let l=document.elementFromPoint(r,i);if(l){const a=et(l);if(a&&Xt(t.rootContainer,a))return a}if(i-=o$,l=document.elementFromPoint(r,i),l){const a=et(l);if(a&&Xt(t.rootContainer,a))return a}return null}destroy(){}}class i$ extends Af{constructor(e){super(e,{trigger:[],id:"empty-block-menu"});m(this,"currentBlock",null)}get isVisible(){return this.suggest.menu.isVisible}isInMenu(e){return this.menu.isInCommandBar(e)}show(){const o=this.editor.selection.focusedBlock;this.suggest.popup(o,0,"","")}setBlock(e){this.currentBlock=e}}function s$(n,t,e){const o=Um(n,t);if(!o)return[];const r=[];return Object.values(o).forEach(i=>{e!=null&&e.has(i.group)||r.push(...i.commands.map(s=>({...s,source:"block-command",blockMenuItemCustomData:i.group})))}),r}function Y0(n,t,e={withPlainText:!1}){const o=x0(n,e),r=i=>{i.forEach(s=>{s.source=t,s.children&&r(s.children)})};return r(o),o}function l$(n,t,e,o=!1){var d,h;const r=nt(t);let s=bt(t);ae(n,t)||o||(s+=1);const l=ct(r),a=e;return a.commandProvider?a.commandProvider.executeCommand(n,e,{from:"block-menu",containerId:l,blockIndex:s}):(h=(d=a.blockOptions)==null?void 0:d.handleInsertEmptyBlock)==null?void 0:h.call(d,n,{containerId:l,blockIndex:s,item:e})}function c$(n,t){const e=Do(n,t),o=n.getBlockData(t);return!(e!=="text"||o.heading)}class $7{constructor(t,e,o){m(this,"source","text-style");m(this,"id","text-style-item");m(this,"name","Text styles");m(this,"element");m(this,"createHeadingItemElement",(t,e,o)=>{var i;const r=k0();this.createItem("text",nu,e,c$(this.editor,t)),(i=r.insertBlockCommandItems)==null||i.forEach(s=>{s.id&&s.icon&&this.createItem(s.id,s.icon,e,o?o===Number(s.value):!1)})});m(this,"createListItemElement",(t,e,o)=>{const{checkbox:r,ordered:i}=o,l=Dt(t)==="list",a=l&&i===!1&&!r,d=l&&i,h=l&&!!r;this.createItem("unordered-list",hv,e,a),this.createItem("ordered-list",fv,e,d),this.createItem("check-list",uv,e,h)});m(this,"handleClick",(t,e)=>{var l,a;if(!e.target||!(e.target instanceof Node))return;const o=e.target instanceof Element?e.target:e.target.parentElement;if(!o)return;const r=o.closest(".text-style-item");if(!r)return;const i=r.id,s="heading-";if(i==="text"&&pf(t,this.block,null),i.startsWith(s)){const d=Number.parseInt(i.substring(s.length),10);d&&pf(t,this.block,d)}if(i==="blockquote"&&b0(t,this.block),i.startsWith("align")){const d=i.replace(/^align-/,"");E9(t,this.block,d)}(i==="unordered-list"||i==="ordered-list"||i==="check-list")&&y0(t,this.block,i),(a=(l=this.options).onAfterStyleItemClick)==null||a.call(l)});this.editor=t,this.block=e,this.options=o,this.element=this.createItemElement(t,e),t.domEvents.addEventListener(this.element,"click",this.handleClick)}createItemElement(t,e){const o=w("div",["text-styles"],null),r=w("div",["text-style-section"],o),i=t.getBlockData(e);if(!this.options.fromEmbed){const l=i.heading,a=i.quoted;this.createHeadingItemElement(e,r,l),this.createListItemElement(e,r,i),this.createItem("blockquote",dv,r,!!a)}const s=i.align||"left";return this.createItem("align-left",tu,r,s==="left"),this.createItem("align-center",Tp,r,s==="center"),this.createItem("align-right",Ip,r,s==="right"),o}createItem(t,e,o,r=!1){const i=["style-icon","text-style-item"];r&&i.push("active");const s=$l(e,i,o);s.id=t}}function H7(){return{source:"separator",type:"separator",id:`section-${K()}`,name:""}}const j7={copy:HL,cut:jL,delete:UL,"lock-block":zL,"unlock-block":VL,comment:eu},a$=["image","video"];function u$(n,t,e){const o=[],r=tt(n,t),i=Me(t)&&a$.includes(fn(t)),s=i&&(fn(t)!=="image"||fn(t)==="image"&&Ar(t).length===1);if(r?o.push(new $7(n,t,e)):i&&s&&o.push(new $7(n,t,{...e,fromEmbed:!0})),!ae(n,t)){(r||i&&s)&&o.push(H7());const l=s$(n,t,new Set(["hovering-toolbar"]));l.sort((a,d)=>{var h,p;return((h=a.order)!=null?h:0)-((p=d.order)!=null?p:0)}),l.forEach(a=>{a.id in j7&&(a.icon=j7[a.id])}),o.push(...l)}return ae(n,t)?o.push(...Y0(n,"insert-block")):o.push(H7(),{id:"insert-block-before",icon:WL,name:R.t("blockMenu.command.insertAbove"),children:Y0(n,"insert-block-before",{withPlainText:!0}),childrenMenuId:"quick-menu",source:"insert-block-before"},{id:"insert-block-after",icon:qL,name:R.t("blockMenu.command.insertAfter"),children:Y0(n,"insert-block",{withPlainText:!0}),source:"insert-block",childrenMenuId:"quick-menu"}),o}function d$(n,t,e){if(e.source==="block-command"){const o=e.blockMenuItemCustomData;a4(n,t,o,e)}else(e.source==="insert-block"||e.source==="insert-block-before")&&l$(n,t,e,e.source==="insert-block-before")}const h$=S("exclusive-block");function J0(n,t,e,o){var l;W(t,"block-exclusive");const r=Qt(n,t),i=(l=r.getBlockProperties)==null?void 0:l.call(r,n,t),{abstract:s}=i||{};t.setAttribute("data-user-name",o),t.setAttribute("data-user-id",e),t.setAttribute("data-exclusive-tips",R.t("exclusive.tips",{editor:o,embedType:s||R.t("exclusive.fallbackAbstract")}))}function U7(n){ot(n,"block-exclusive"),n.removeAttribute("data-user-name"),n.removeAttribute("data-user-id"),n.removeAttribute("data-exclusive-tips")}function f$(n,t,e,o,r){h$.debug(`block ${it(t)} ${e?"exclusive":"unexclusive"}, ${o}, ${r}`),e?J0(n,t,o,r):U7(t)}function Mf(n){return n.classList.contains("block-exclusive")}function z7(n,t){t.blockIds.forEach(e=>{const o=n.findBlockById(e);o&&f$(n,o,t.exclusive,t.userId,t.displayName)})}class Ji{constructor(t){m(this,"exclusiveBlockIds",new Set);m(this,"exclusiveBlockTimer",0);m(this,"remoteExclusiveBlockIds",new Map);m(this,"handleUserChanged",t=>{const e=new Set(t.map(r=>r.userId));Array.from(this.remoteExclusiveBlockIds.entries()).forEach(([r,i])=>{if(!e.has(i.userId)){this.remoteExclusiveBlockIds.delete(r);const s={...i,exclusive:!1};z7(this.editor,s)}});const o=Array.from(this.exclusiveBlockIds).map(r=>this.editor.findBlockById(r)).filter(r=>!!r);o.length>0&&this.broadcastExclusiveBlockMessage(o,!0)});this.editor=t,t.doc.registerCallback(this),t.doc.getRemoteUsers().addListener("change",this.handleUserChanged)}destroy(){this.stopExclusiveBlockTimer(),this.editor.doc.unregisterCallback(this),this.editor.doc.getRemoteUsers().addListener("change",this.handleUserChanged)}onCustomMessage(t){if(t.type==="exclusiveBlock"){const e=t;z7(this.editor,e),e.blockIds.forEach(o=>{e.exclusive?this.remoteExclusiveBlockIds.set(o,e):this.remoteExclusiveBlockIds.delete(o)})}}getExclusiveMessage(t){return this.remoteExclusiveBlockIds.get(t)}broadcastExclusiveBlockMessage(t,e){if(this.editor.readonly||t.length===0)return;const o=this.editor.doc.getUser(),r={type:"exclusiveBlock",userId:o.userId,displayName:o.displayName,blockIds:t.map(i=>it(i)),exclusive:e};this.editor.doc.broadcastMessage(r)}exclusiveBlock(t){this.exclusiveBlockIds.has(it(t))||(this.broadcastExclusiveBlockMessage([t],!0),this.exclusiveBlockIds.add(it(t)),this.exclusiveBlockIds.size===1&&this.startExclusiveBlockTimer())}unexclusiveBlock(t){!this.exclusiveBlockIds.has(it(t))||(this.exclusiveBlockIds.delete(it(t)),this.broadcastExclusiveBlockMessage([t],!1),this.exclusiveBlockIds.size===0&&this.stopExclusiveBlockTimer())}startExclusiveBlockTimer(){this.exclusiveBlockTimer=window.setInterval(()=>{Array.from(this.exclusiveBlockIds.keys()).forEach(t=>{this.broadcastExclusiveBlockMessage([this.editor.getBlockById(t)],!0)})},30*1e3)}stopExclusiveBlockTimer(){clearInterval(this.exclusiveBlockTimer),this.exclusiveBlockTimer=0}static get(t){return t.addCustom("exclusiveBlock",()=>new Ji(t))}static register(t){return this.get(t)}}function K0(n,t){Ji.get(n).exclusiveBlock(t)}function X0(n,t){Ji.get(n).unexclusiveBlock(t)}class V7{writable(t,e){if(Mf(e))return!1}create(t,e,o,r,i){const s=Ji.get(t).getExclusiveMessage(i.id);s&&J0(t,r,s.userId,s.displayName)}update(t,e,o,r,i){const s=Ji.get(t).getExclusiveMessage(i.id);s?J0(t,r,s.userId,s.displayName):U7(r)}}const Hnt="",m$={exclusive:{tips:"\u300C{editor}\u300D\u6B63\u5728\u7F16\u8F91\uFF0C\u300C{embedType}\u300D\u4E0D\u652F\u6301\u591A\u4EBA\u7F16\u8F91",fallbackAbstract:"\u8BE5 Block"}},g$={exclusive:{tips:"\u300C{editor}\u300Dis editing\uFF0C\u300C{embedType}\u300Ddoes not support multi-person editing",fallbackAbstract:"This Block"}},p$={exclusive:{tips:"\u300C{editor}\u300D\u306F\u7DE8\u96C6\u4E2D\u3067\u3059\u3002\u300C{embedType}\u300D\u306F\u8907\u6570\u4EBA\u3067\u540C\u6642\u7DE8\u96C6\u3067\u304D\u307E\u305B\u3093",fallbackAbstract:"\u3053\u306E\u8981\u7D20"}};R.mergeLang({"zh-CN":m$,"en-US":g$,"ja-JP":p$});function Tu(n,t){return n.getBlockData(t).lock}function Rf(n,t){return!!Tu(n,t)}function Du(n,t){const e=Tu(n,t);return e?e.userId===n.doc.getUser().userId:!1}function t2(n,t){const e=Tu(n,t);return e?e.userId!==n.doc.getUser().userId:!1}function C$(n,t){if(n.readonly||!n.isBlockWritable(t)||Rf(n,t)&&!Du(n,t))return;const e=n.doc.getUser(),o={userId:e.userId,displayName:e.displayName,locked:Date.now()},i={...n.getBlockData(t),lock:o};n.updateBlockData(t,i)}function A$(n,t){if(!Du(n,t))return;const e={lock:null};n.updateBlockData(t,e)}const b$=10,v$=80;class e2{constructor(){m(this,"executeCommand",(t,e,o)=>{const r=o.data;if(!r||!r.blockId)return;const i=t.getBlockById(r.blockId);r.type==="lock"?C$(t,i):r.type==="unlock"&&A$(t,i)})}create(t,e,o,r,i){const s=i.lock;s&&(s.userId!==t.doc.getUser().userId?W(r,"locked-by-others"):W(r,"locked-by-self"))}update(t,e,o,r,i){const s=i.lock;if(s)if(s.userId!==t.doc.getUser().userId){W(r,"locked-by-others");const l=t.selection.focusedBlock;(l===r||Xt(r,l))&&(tt(t,r)||Dt(r)==="code")&&t.insertTextBlock("",ct(o),bt(r)+1)}else W(r,"locked-by-self");else ot(r,"locked-by-others"),ot(r,"locked-by-self")}writable(t,e){if(t2(t,e))return!1;if(io(e))return;let o=Es(e);for(;o;){if(t2(t,o))return!1;o=Es(o)}}commands(t,e){const o=Rf(t,e),r=Du(t,e),i=Mf(e),s={blockId:it(e),type:"lock"},l={id:"lock-block",name:"",data:s,order:10};if(o)if(r)l.id="unlock-block",l.name=R.t("locker.unlock"),s.type="unlock";else{const a=Tu(t,e);let d=(a==null?void 0:a.displayName)||"";const h=MC(d,b$,v$);(h==null?void 0:h.length)!==d.length&&(l.ellipsisTooltip=a==null?void 0:a.displayName,d=h||""),l.name=R.t("locker.lockedBy",{name:d}),l.states=["disabled"]}else i?(l.name=R.t("locker.lock"),l.states=["disabled"]):l.name=R.t("locker.lock");return{group:"block-locker",commands:[l],executeCommand:this.executeCommand}}}const jnt="",y$={locker:{lock:"\u9501\u5B9A",unlock:"\u89E3\u9664\u9501\u5B9A",lockedBy:"\u88AB {name} \u9501\u5B9A"}},k$={locker:{lock:"Lock",unlock:"Unlock",lockedBy:"Locked by {name}"}},w$={locker:{lock:"\u30ED\u30C3\u30AF",unlock:"\u30ED\u30C3\u30AF\u89E3\u9664",lockedBy:"{name}\u304C\u30ED\u30C3\u30AF\u3057\u307E\u3057\u305F"}};R.mergeLang({"zh-CN":y$,"en-US":k$,"ja-JP":w$});class Of{async handleBeforePasteDoc(t,e){return Object.values(e.blocks).forEach(o=>{o.forEach(r=>{delete r.lock})}),!1}}const B$=S("standard-block-actions");class E${constructor(){m(this,"executeCommand",(t,e,o)=>{const r=o.data;try{const i=t.getBlockById(r);if(o.id==="delete"){t.deleteBlock(i);return}o.id==="copy"&&_h(t,i),o.id==="cut"&&(_h(t,i),t.deleteBlock(i))}catch(i){B$.error(`failed to execute block command: ${JSON.stringify(i)}`)}})}commands(t,e){const o=Rf(t,e),r=o&&Du(t,e),i=it(e),s=$0(),l=Mf(e),a={id:"copy",name:R.t("blockMenu.command.copy"),data:i,order:1,states:s?[]:["disabled"],disableReason:s?void 0:R.t("copyCutProperty.unsafeEnvTips",{shortCut:xo("CtrlOrCmd+C"),operation:R.t("copyCutProperty.copy")})},d={id:"cut",name:R.t("blockMenu.command.cut"),data:i,order:2,states:o&&!r||!s||l?["disabled"]:[],disableReason:s?void 0:R.t("copyCutProperty.unsafeEnvTips",{shortCut:xo("CtrlOrCmd+X"),operation:R.t("copyCutProperty.cut")})},h={id:"delete",name:R.t("blockMenu.command.delete"),data:i,order:3,states:o&&!r||l?["disabled"]:[]};return{group:"standard-block-actions",commands:[a,d,h],executeCommand:this.executeCommand}}}const W7=S("block-menu");class x${constructor(t){m(this,"menu");m(this,"currentBlock",null);m(this,"commandBlock",null);m(this,"handleShow",()=>{g(W7,this.currentBlock,"no target block before show block menu");const t=u$(this.editor,this.currentBlock,{onAfterStyleItemClick:this.close});this.menu.updateItems(t),this.commandBlock=this.currentBlock});m(this,"handleClose",()=>{Op(this.editor)&&this.editor.focus()});m(this,"handleItemClick",(t,e)=>{g(W7,this.commandBlock,"no command block before show block menu"),d$(this.editor,this.commandBlock,e),e.element||this.close()});m(this,"close",()=>{this.menu.close("clickItem")});this.editor=t,this.menu=new Us([],void 0,{id:"block-menu"}),this.menu.on("show",this.handleShow),this.menu.on("close",this.handleClose),this.menu.on("click",this.handleItemClick),t.blockHooks.push(new E$)}show(t,e){this.menu.manualShow(t,{placement:"bottom-start",...e})}isInMenu(t){return this.menu.isInCommandBar(t)}setBlock(t){this.currentBlock=t}get isVisible(){return this.menu.isVisible}destroy(){this.menu.destroy()}}const I$=1e3;async function T$(n,t){const{width:e}=n.rootContainer.getBoundingClientRect(),o=t.getBoundingClientRect();return o.width>e||o.height>=I$?"":(await G5.default.toSvg(t)).replace(/margin-block:.*?;/,"").replace(/margin:.*?;/,"")}const D$=S("drag-preview-image");class S${constructor(t){m(this,"startPosition",null);m(this,"dragContainer",null);m(this,"handleDragStart",async(t,e)=>{const o=t.target;g(D$,o instanceof Element,`Invalid Drag target:${o}`);const{x:r,y:i}=t;this.startPosition={x:r,y:i};const s=w("div",["drag-image-container"],this.editor.rootContainer),l=w("img",["drag-image"],s),a=w("span",["drag-loading"],s);a.innerHTML=YL;const{x:d,width:h,height:p,y:A}=o.getBoundingClientRect(),v=this.editor.rootContainer.getBoundingClientRect(),B=e.getBoundingClientRect();s.style.left=`${d+h}px`,s.style.top=`${A+p}px`,s.style.width=`${Math.min(v.width/2,B.width)}px`,this.dragContainer=s;const x=await T$(this.editor,e);x?l.src=x:W(s,"drag-placeholder"),Cm(s,{status:"loaded"})});m(this,"handleDrag",t=>{if(this.startPosition&&this.dragContainer){const{x:e,y:o}=t;if(e===0&&o===0){this.dragContainer.style.transition="transform 0.15s, opacity .15s",this.dragContainer.style.transform="",this.dragContainer.style.opacity="0";return}const{x:r,y:i}=this.startPosition,s=e-r,l=o-i;this.dragContainer.style.transform=`translate(${s}px, ${l}px)`}});m(this,"handleDragEnd",()=>{this.dragContainer&&(this.dragContainer.remove(),this.startPosition=null,this.dragContainer=null)});this.editor=t}}const q7="drag-preview-element";function L$(n){if(xt(n,q7))return n;const t=n.querySelector(`.${q7}`);return t||(Me(n)?Lt(n):n)}const _f=S("block-menu-drag-handler");function n2(n,t){return new DragEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:n.screenX,screenY:n.screenY,dataTransfer:new DataTransfer,clientX:n.clientX,clientY:n.clientY})}class M${constructor(t,e){m(this,"dragPreview");m(this,"autoScroll");m(this,"oldPos",{x:0,y:0});m(this,"handleMouseDown",t=>{const e=this.button.blockMenu.currentBlock;if(g(_f,e,"no dragged block"),t.button!==0)return;if(!this.editor.isBlockWritable(e)){t.preventDefault(),t.stopPropagation();return}const{x:o,y:r}=t;this.oldPos={x:o,y:r},document.addEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.addEventListener("mousemove",this.handleDrag)});m(this,"handleDragStart",t=>{var s,l;const e=ro(this.button.buttonElement);this.autoScroll||(this.autoScroll=new Qd({scrollElement:e,trackMouseEvent:"mousemove",edge:{top:50,bottom:50}}));const o=this.button.blockMenu.currentBlock;g(_f,o,"no dragged block"),(l=(s=Qt(this.editor,o)).notify)==null||l.call(s,this.editor,"beginDrag");const r=n2(t,"dragstart");P$(this.editor,r,o),window.isDragging=!0,this.button.buttonElement.style.opacity="0";const i=L$(o);this.dragPreview.handleDragStart(t,i),this.autoScroll.active(),W(o,"dragging"),W(this.editor.contentElement,"dragging")});m(this,"handleDrag",t=>{const{target:e,x:o,y:r}=t;if(this.oldPos.x===o&&this.oldPos.y===r)return;window.isDragging||this.handleDragStart(t),this.oldPos={x:o,y:r},g(_f,e instanceof Element,"target is invalid"),this.dragPreview.handleDrag(t);const i=n2(t,"dragover");this.editor.contentElement.dispatchEvent(i)});m(this,"handleDragEnd",t=>{var r;const e=this.button.blockMenu.currentBlock;g(_f,e,"no dragged block"),window.isDragging=!1,this.button.buttonElement.style.opacity="1",this.dragPreview.handleDragEnd(),(r=this.autoScroll)==null||r.inactive(),ot(e,"dragging"),ot(this.editor.contentElement,"dragging"),document.removeEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.removeEventListener("mousemove",this.handleDrag);const o=n2(t,"drop");this.editor.contentElement.dispatchEvent(o)});this.editor=t,this.button=e,this.button.buttonElement.addEventListener("mousedown",this.handleMouseDown),this.dragPreview=new S$(t)}destroy(){this.button.buttonElement.removeEventListener("mousedown",this.handleMouseDown)}}class Su{constructor(t){m(this,"highlightedBlockId","");m(this,"handleSelectionChange",()=>{this.clearHighlightedBlock()});this.editor=t,this.editor.addListener("selectionChanged",this.handleSelectionChange)}highlightBlock(t){this.clearHighlightedBlock(),this.highlightedBlockId=it(t),W(t,"highlighted")}clearHighlightedBlock(){if(this.highlightedBlockId){const t=this.editor.findBlockById(this.highlightedBlockId);t&&ot(t,"highlighted"),this.highlightedBlockId=""}}destroy(){}static register(t){return t.addCustom("editor-block-highlighter",()=>new Su(t))}static get(t){return t.getCustom("editor-block-highlighter")}}class G7{constructor(t){m(this,"buttonElement");m(this,"emptyBlockMenu");m(this,"blockMenu");m(this,"dragHandler");m(this,"handleHoverBlock",(t,e,o)=>{if(this.emptyBlockMenu.isVisible||this.blockMenu.isVisible||!this.editor.isWritable())return;const r=this.editor.getCustom("editor-tooltip");if(r&&r.visible()&&(r.hide(),this.buttonElement.setAttribute("data-tooltip-hide-at",`${Date.now()}`)),!t){this.buttonElement.parentElement&&(this.blockMenu.isInMenu(o.target)||this.buttonElement.remove());return}const i=jm(t);this.editor.getBlockIndex(i)===0&&this.editor.getBlockData(i).heading===1||(this.updateButton(i),Q0(i,this.buttonElement,Number.MAX_SAFE_INTEGER))});m(this,"handleButtonClick",()=>{if(this.buttonElement.getAttribute("data-type")==="move"){const o=this.blockMenu.currentBlock;if(!o)return;this.editor.selection.selectBlock(o,0),this.blockMenu.show(this.buttonElement,{placement:"bottom-end"}),setTimeout(()=>{Su.get(this.editor).highlightBlock(o)});return}const e=this.emptyBlockMenu.currentBlock;!e||(this.editor.selection.selectBlock(e,0),setTimeout(()=>{this.editor.focus(),this.updatePlaceholder(e),this.emptyBlockMenu.show()}))});m(this,"updatePlaceholder",t=>{Lt(t).setAttribute("data-content-placeholder",R.t("blockMenu.button.searchPlaceholder"))});m(this,"handleChanged",()=>{const t=this.emptyBlockMenu.currentBlock;if(!t)return;const e=ae(this.editor,t)?"insert":"move";this.buttonElement.getAttribute("data-type")!==e&&this.setButtonType(e)});this.editor=t,this.buttonElement=this.createButton(),this.emptyBlockMenu=new i$(t),this.blockMenu=new x$(t),this.editor.addListener("docChanged",this.handleChanged),this.buttonElement.addEventListener("click",this.handleButtonClick),this.dragHandler=new M$(this.editor,this);const e=Ce.get(t);e.addListener("change",this.handleHoverBlock),e.addFinder(new r$),Su.register(this.editor)}destroy(){Ce.get(this.editor).removeListener("change",this.handleHoverBlock),this.buttonElement.removeEventListener("click",this.handleButtonClick),this.editor.removeListener("docChanged",this.handleChanged),this.emptyBlockMenu.destroy(),this.blockMenu.destroy(),this.buttonElement.remove(),this.dragHandler.destroy()}createButton(){const t=w("button",["block-button"],null);return t.setAttribute(`data-editor-tooltip-${this.editor.clientId}`,R.t("blockMenu.button.tips")),t.innerHTML=mv,t}setButtonType(t){this.buttonElement.setAttribute("data-type",t);const e=`data-editor-tooltip-${this.editor.clientId}-dynamic`;this.buttonElement.hasAttribute(e)&&this.buttonElement.removeAttribute(e),t==="insert"?(this.buttonElement.innerHTML=QL,this.buttonElement.setAttribute(e,R.t("blockMenu.button.insertTips"))):(this.buttonElement.innerHTML=mv,this.buttonElement.setAttribute(e,R.t("blockMenu.button.tips")))}updateButton(t){this.emptyBlockMenu.setBlock(t),this.blockMenu.setBlock(t),ae(this.editor,t)?this.setButtonType("insert"):this.setButtonType("move")}}const R$={blockMenu:{section:{basics:"\u57FA\u7840",system:"\u7CFB\u7EDF",styles:"\u6837\u5F0F",common:"\u901A\u7528",actions:"\u64CD\u4F5C",thirdParty:"\u7B2C\u4E09\u65B9\u5185\u5BB9"},command:{insertAbove:"\u5728\u4E0A\u65B9\u63D2\u5165",insertAfter:"\u5728\u4E0B\u65B9\u63D2\u5165",copy:"\u590D\u5236",cut:"\u526A\u5207",delete:"\u5220\u9664"},button:{searchPlaceholder:"\u8F93\u5165\u5173\u952E\u8BCD\u641C\u7D22",tips:`\u957F\u6309\u62D6\u62FD
422
422
  \u70B9\u51FB\u6253\u5F00\u83DC\u5355`,insertTips:"\u70B9\u51FB\u6DFB\u52A0\u533A\u5757"}}},O$={blockMenu:{section:{basics:"Basic",system:"System",styles:"Styles",common:"Common",actions:"Actions",thirdParty:"Third-party content"},command:{insertAbove:"Insert above",insertAfter:"Insert below",copy:"Copy",cut:"Cut",delete:"Delete"},button:{searchPlaceholder:"Search",tips:`Hold to drag
423
- Click to open the menu`,insertTips:"Click to add block"}}},_$={blockMenu:{section:{basics:"\u4E00\u822C",system:"\u30B7\u30B9\u30C6\u30E0",styles:"\u30B9\u30BF\u30A4\u30EB",common:"\u4E00\u822C",actions:"\u64CD\u4F5C",thirdParty:"\u5916\u90E8\u30B3\u30F3\u30C6\u30F3\u30C4"},command:{insertAbove:"\u4E0A\u306B\u633F\u5165",insertAfter:"\u4E0B\u306B\u633F\u5165",copy:"\u8907\u88FD",cut:"\u5207\u308B",delete:"\u524A\u9664"},button:{searchPlaceholder:"\u30AD\u30FC\u30EF\u30FC\u30C9\u3067\u691C\u7D22",tips:"\u3092\u30C9\u30E9\u30C3\u30B0\u3057\u3066\u30AF\u30EA\u30C3\u30AF\u3067\u30E1\u30CB\u30E5\u30FC\u3092\u8868\u793A",insertTips:"\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u30D6\u30ED\u30C3\u30AF\u3092\u8FFD\u52A0"}}};R.mergeLang({"zh-CN":R$,"en-US":O$,"ja-JP":_$});const Unt="";class F${constructor(){m(this,"dragObject",null)}setData(t){this.dragObject=t}getData(){return this.dragObject}clearData(){this.dragObject=null}destroy(){}}function Ff(n){return n.addCustom("drag-data",()=>new F$)}function o2(n,t){if(!t)return null;const e=Ff(n).getData();return!e||e.editorId!==n.id?null:e}function Z7(n,t){const e=o2(n,t);return e?n.findBlockById(e.blockId):null}function P$(n,t,e){if(!t.dataTransfer)return;const r=nt(e),i=ct(r),s=it(e),l={type:"block",editorId:n.id,containerId:i,blockId:s};Ff(n).setData(l)}function N$(n,t,e,o,r){if(!t.dataTransfer)return;const s=nt(e),l=ct(s),a=it(e),d={type:"custom",customType:o,editorId:n.id,containerId:l,blockId:a,data:r};Ff(n).setData(d)}function $$(n){Ff(n).clearData()}const H$=S("drop-indicator"),Pf=2;class j${constructor(t){m(this,"indicator");m(this,"target",null);this.editor=t,this.indicator=w("div",["editor-drop-indicator"],this.editor.contentElement)}show(t,e){const o=this.getIndicatorRect(t,e),r=this.editor.rootElement.getBoundingClientRect(),i=o.top-r.top,s=o.left-r.left;this.indicator.style.top=`${i}px`,this.indicator.style.left=`${s}px`,this.indicator.style.width=`${o.width}px`,this.indicator.style.height=`${o.height}px`,this.indicator.style.display="",this.target={block:t,insertPos:e}}hide(){this.indicator.style.display="none",this.target=null}getIndicatorRect(t,e){if(typeof e!="string")return e.rect;if(e==="before"){const s=Is(t);if(!s){g(H$,Lo(nt(t)),"block does not in a child container");const d=t.getBoundingClientRect();return new DOMRect(d.x,d.y,d.width,Pf)}const l=s.getBoundingClientRect(),a=t.getBoundingClientRect();return new DOMRect(l.x,(l.bottom+a.top)/2,l.width,Pf)}const o=Ts(t);if(!o){const s=t.getBoundingClientRect();return new DOMRect(s.x,s.bottom,s.width,Pf)}const r=t.getBoundingClientRect(),i=o.getBoundingClientRect();return new DOMRect(r.x,(r.bottom+i.top)/2,r.width,Pf)}}const U$=S("find-drop-target");function z$(n,t){const e=document.elementFromPoint(n,t);if(!e)return null;if(Pr(e)&&Lo(e))return e;const o=e.firstElementChild;return o&&Pr(o)&&Lo(o)?o:null}function V$(n,t){const s=t,l=n;for(let a=0;a<2;a++){const d=l+a*50;for(let h=0;h<5;h++){const p=s+h*8,A=document.elementFromPoint(d,p);if(A){const D=et(A);if(D)return D}if(h===0)continue;const v=s-h*8,B=document.elementFromPoint(d,v);if(B){const D=et(B);if(D)return D}}}return null}function W$(n,t,e){const o=document.elementFromPoint(t,e);if(o){const h=et(o);if(h&&!Mt(n,h))return h}const r=new Set,i=z$(t,e);if(i){const h=i.getBoundingClientRect();e<h.top+h.height/2?r.add(ye(i)):r.add(Qe(i))}const s=V$(t,e);s&&r.add(s);const l=Array.from(r),a=h=>{for(let p=0;p<l.length;p++){const A=l[p];if(h!==A&&Xt(h,A))return!0}return!1},d=l.filter(h=>!a(h));return d.length>0?d[0]:null}function r2(n,t){if(n.readonly)return!1;const e=nt(t);if(Yt(e))return!0;const o=et(e);return g(U$,o,"no parent block"),n.isBlockWritable(o)?r2(n,o):!1}const q$=S("drop-target");function G$(n,t){let e={};return/image/.test(t.type)?e=n.editorEmbeds.getEmbedClass("image"):/audio/.test(t.type)?e=n.editorEmbeds.getEmbedClass("audio"):/video/.test(t.type)&&(e=n.editorEmbeds.getEmbedClass("video")),g(q$,e,`unSupport file type ${t.type}`),e}async function Q7(n,t,e,o){var i,s;let r=o;for(const l of t){const a=G$(n,l);a.getOptions&&await((s=(i=a.getOptions(n)).handleInsertEmptyEmbed)==null?void 0:s.call(i,n,{containerId:e,blockIndex:r,data:{file:l}}))&&(r+=1)}}class Z${constructor(t){m(this,"handleDrop",(t,e,o,r)=>{if(Array.isArray(e)){const i=e;if(i.length>0){const s=ct(o);return Q7(t,i,s,r),!0}}return!1});this.editor=t}}class Lu{constructor(t){m(this,"indicator");m(this,"lastDropOverResult");m(this,"handlers",[]);m(this,"handleDragOver",t=>{if(!this.editor.isWritable())return;const e=i=>{var d,h;const s=o2(this.editor,i.dataTransfer),l=Z7(this.editor,i.dataTransfer),a=this.findTargetBlock(l,i.x,i.y);if(a&&Xt(this.editor.rootContainer,a)){const p=this.findInsertPos(l,a,i.x,i.y,(h=s!=null?s:(d=i.dataTransfer)==null?void 0:d.items)!=null?h:null);if(p)return this.indicator.show(a,p),"move"}return this.indicator.hide(),"none"},o=(i,s)=>{i.dataTransfer&&(i.dataTransfer.dropEffect=s),s==="move"&&i.preventDefault()};if(this.lastDropOverResult&&t.x===this.lastDropOverResult.x&&t.y===this.lastDropOverResult.y){const i=this.lastDropOverResult.dropEffect;o(t,i);return}const r=e(t);o(t,r),this.lastDropOverResult={x:t.x,y:t.y,dropEffect:r}});m(this,"handleDrop",t=>{var i,s;t.stopPropagation(),setTimeout(()=>{this.indicator.hide()});const e=o2(this.editor,t.dataTransfer),o=Array.from((s=(i=t.dataTransfer)==null?void 0:i.files)!=null?s:[]);if(!e&&o.length===0){t.dataTransfer&&(t.dataTransfer.dropEffect="none");return}const r=this.indicator.target;if(r){const{block:l,insertPos:a}=r,d=Z7(this.editor,t.dataTransfer);this.editor.undoManager.runInGroup(()=>{const h=Qt(this.editor,l);if(h.handleDrop&&h.handleDrop(this.editor,l,e!=null?e:o,a,{isSourceBlock:!1,targetBlock:l})){t.preventDefault(),this.editor.focus();return}if(d){const p=Qt(this.editor,d);if(p.handleDrop&&p.handleDrop(this.editor,d,e!=null?e:o,a,{isSourceBlock:!0,targetBlock:l})){t.preventDefault(),this.editor.focus();return}}if(typeof a=="string"){const p=nt(l);let A=bt(l);a==="after"&&(A+=1),t.preventDefault();for(let v=0;v<this.handlers.length;v++)if(this.handlers[v].handleDrop(this.editor,d!=null?d:o,p,A)){this.editor.focus();return}if(d){const v=this.editor.getBlockData(d),B=Fi(this.editor.editorBlocks,this.editor.doc.toJSON(),v),[D]=this.editor.insertDocAt(p,A,B);this.editor.selection.selectBlock(D,0),Su.get(this.editor).highlightBlock(D),this.editor.deleteBlock(d),this.editor.focus()}}}),$$(this.editor)}});m(this,"handleDragLeave",()=>{this.indicator.hide()});this.editor=t,this.indicator=new j$(this.editor),this.handlers.push(new Z$(this.editor)),this.editor.contentElement.addEventListener("dragover",this.handleDragOver),this.editor.contentElement.addEventListener("dragleave",this.handleDragLeave),this.editor.contentElement.addEventListener("drop",this.handleDrop)}destroy(){this.editor.contentElement.removeEventListener("dragover",this.handleDragOver),this.editor.contentElement.removeEventListener("dragleave",this.handleDragLeave),this.editor.contentElement.removeEventListener("drop",this.handleDrop),this.handlers=[]}addHandler(t){this.handlers.push(t)}static register(t){return t.addCustom("drop-target",()=>new Lu(t))}static get(t){return t.getCustom("drop-target")}static find(t){return t.findCustom("drop-target")}canInsertAfter(t,e){return!(this.editor.readonly||Ts(e)===t&&t||!r2(this.editor,e))}canInsertBefore(t,e){return!(this.editor.readonly||Is(e)===t&&t||!r2(this.editor,e)||Yt(nt(e))&&bt(e)===0)}canDrop(t,e){return t===null||t===e?!0:!Xt(t,e)}findTargetBlock(t,e,o){let r=W$(this.editor,e,o);if(!r||!Xt(this.editor.rootContainer,r))return null;const i=nt(r),s=et(i);return s&&Dt(s)==="code"&&(r=s),this.canDrop(t,r)?r:null}findInsertPos(t,e,o,r,i){let s=e;for(;s;){const a=Qt(this.editor,s);if(a.handleDropOver){const d=a.handleDropOver(this.editor,s,i,o,r);if(d)return d;if(d===!1)return null}s=Es(s)}if(t===e)return"";const l=e.getBoundingClientRect();if(l.top<=r&&r<=l.bottom){if(r<l.top+l.height/2){if(this.canInsertBefore(t,e))return"before";if(this.canInsertAfter(t,e))return"after"}else{if(this.canInsertAfter(t,e))return"after";if(this.canInsertBefore(t,e))return"before"}return""}return r<l.top&&this.canInsertBefore(t,e)?"before":l.bottom<r&&this.canInsertAfter(t,e)?"after":""}}function Y7(n,t,e){const o=Ie.getImageObject(n,t),r=mt.default(o.getImages());if(r.length===1){n.deleteBlock(t);return}if(e===-1||e>=r.length)return;const i=ON(r);if(r.splice(e,1),r.length===1){const l=r[0],a=100*(l.flex/i);l.flex=1;const d=cn([l],a);n.updateEmbedData(t,d);return}r[0].flex=NaN,wu(r);const s=cn(r,o.getWidthPercent());n.updateEmbedData(t,s)}function Q$(n,t,e,o){if(t.length===0||o==="after"||o==="before")return!1;let r=o.data;const i=Ie.getImageObject(n,e),s=mt.default(i.getImages()),l=[],a=[];t.forEach(p=>{F7(p.type)&&s.length+l.length<6?l.push(p):a.push(p)}),l.forEach(p=>{try{_7(n,p)}catch{return}const A={src:"",flex:1,width:0,height:0,virtualSize:!0};s.splice(r,0,A);const v=cn(s,i.getWidthPercent());n.updateEmbedData(e,v),i.replaceImage(r,p),r+=1});const d=n.getBlockIndex(e)+1,h=ct(nt(e));return Q7(n,a,h,d),!0}function Y$(n,t,e,o,r){var s,l,a;if(Gd(e))return Q$(n,e,t,o);if(e.type!=="custom"||e.customType!=="image"||!e.data)return;const i=e.data;if(r.isSourceBlock){const d=r.targetBlock,h=nt(d);let p=bt(d);o==="after"&&(p+=1);const v=100*(i.boundingRect.width/n.rootContainer.getBoundingClientRect().width),B=cn([i.image],v),D={id:K(),type:"embed",embedType:"image",embedData:B},x=(l=(s=n.options.componentsOptions)==null?void 0:s.image)==null?void 0:l.defaultAlign;x&&(D.align=x),n.insertBlock(ct(h),p,D),Y7(n,t,i.index),(a=n.findCustom("drag-handler"))==null||a.handleDragEnd()}else{if(typeof o=="string")return;const d=t;let h=o.data;const p=Ie.getImageObject(n,d),A=mt.default(p.getImages());h>A.length&&(h=A.length),n.undoManager.runInGroup(()=>{var B,D;p.setAutoFix(!0);const v=n.getBlockById(e.blockId);if(v===d){const x=i.index,_=h,M=i.image;if(x===_||_===x+1)return;let H=_;x<_?(A.splice(_,0,M),A.splice(x,1),H-=1):(A.splice(x,1),A.splice(_,0,M));const z=cn(A,p.getWidthPercent());n.updateEmbedData(d,z),p.setSelectedIndex(H),(B=n.findCustom("drag-handler"))==null||B.handleDragEnd()}else{A.splice(h,0,i.image),A[0].flex=NaN,wu(A);const x=cn(A,p.getWidthPercent());n.updateEmbedData(d,x),Y7(n,v,i.index),(D=n.findCustom("drag-handler"))==null||D.handleDragEnd(),p.setSelectedIndex(h),n.selection.selectBlock(d,0)}})}return!0}const J$=2;function Nf(n,t,e){const o=Ar(t);if(e<=0){const s=o[0].getBoundingClientRect();return new DOMRect(s.left-4,s.top,2,s.height)}if(e===o.length){const s=o[e-1].getBoundingClientRect();return new DOMRect(s.right+2,s.top,2,s.height)}const r=o[e-1].getBoundingClientRect(),i=o[e].getBoundingClientRect();return new DOMRect((i.left+r.right)/2-1,r.top,J$,r.height)}function K$(n,t,e,o,r){for(let i=0;i<e.length;i++){const l=e[i].getBoundingClientRect();if(o<=l.right)return o<=l.left+l.width/2?{rect:Nf(n,t,i),data:i}:{rect:Nf(n,t,i+1),data:i+1}}return o>e[e.length-1].getBoundingClientRect().right?{rect:Nf(n,t,e.length),data:e.length}:{rect:Nf(n,t,e.length),data:0}}function X$(n,t,e,o,r){const i=Ar(t);if(e instanceof DataTransferItemList){if(!Array.from(e).some(s=>F7(s.type))||i.length>=6)return}else{if((e==null?void 0:e.type)==="block"||i.length>=6&&(e==null?void 0:e.blockId)!==it(t))return;const s=it(t);if(i.length===1&&s===(e==null?void 0:e.blockId))return}return K$(n,t,i,o)}async function tH(n){return await G5.default.toSvg(n)}function i2(n,t){return new DragEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:n.screenX,screenY:n.screenY,dataTransfer:new DataTransfer,clientX:n.clientX,clientY:n.clientY})}class eH{constructor(t){m(this,"img");m(this,"dragContainer",null);m(this,"autoScroll",null);m(this,"imageContainer",null);m(this,"startPosition",null);m(this,"handleMouseDown",t=>{const e=t.target;if(!e||!(e instanceof HTMLImageElement)||t.button!==0)return;const o=et(e);if(!o||!Wo(o)||!this.editor.isBlockWritable(o)||this.editor.readonly)return;const r=Ie.getImageObject(this.editor,o);if(this.imageContainer=G0(t.target),!this.imageContainer)return;const s=D7(t.target).indexOf(this.imageContainer);if(s===-1)return;const l=r.getImages()[s];if(!l)return;const{x:a,y:d}=t;this.startPosition={x:a,y:d};const h={image:l,index:s,boundingRect:this.imageContainer.getBoundingClientRect()},p=i2(t,"dragstart");N$(this.editor,p,o,"image",h),document.addEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.addEventListener("mousemove",this.handleDrag),t.preventDefault()});m(this,"handleDragStart",async t=>{if(!this.imageContainer)return;const e=et(this.imageContainer);if(!e)return;const{x:o,y:r}=t,{width:i,height:s}=t.target.getBoundingClientRect(),l=te(e),a=w("div",["drag-container"],l);a.style.left=`${o-i/4}px`,a.style.top=`${r-s/4}px`,a.style.width=`${Math.max(i/2,16)}px`,a.style.height=`${s/2}px`,this.dragContainer=a,W(this.editor.contentElement,"dragging");const d=ro(e);this.autoScroll=new Qd({scrollElement:d,trackMouseEvent:"mousemove",edge:{top:50,bottom:50}}),this.autoScroll.active();const h=w("img",["drag-target"],a),A=await tH(this.imageContainer);A&&(h.src=A)});m(this,"handleDrag",t=>{var i;const{x:e,y:o}=t;if(((i=this.startPosition)==null?void 0:i.x)===e&&this.startPosition.y===o)return;if(window.isDragging||(window.isDragging=!0,this.handleDragStart(t)),this.startPosition&&this.dragContainer){const{x:s,y:l}=t;if(s===0&&l===0){this.dragContainer.style.transform="",this.dragContainer.style.opacity="0";return}const{x:a,y:d}=this.startPosition,h=s-a,p=l-d;this.dragContainer.style.transform=`translate(${h}px, ${p}px)`,this.dragContainer.style.opacity="0.5"}const r=i2(t,"dragover");this.editor.contentElement.dispatchEvent(r)});m(this,"handleDragEnd",t=>{var e;if(window.isDragging=!1,this.dragContainer&&this.dragContainer.remove(),this.dragContainer=null,this.startPosition=null,this.imageContainer=null,(e=this.autoScroll)==null||e.inactive(),ot(this.editor.contentElement,"dragging"),document.removeEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.removeEventListener("mousemove",this.handleDrag),t){const o=i2(t,"drop");this.editor.contentElement.dispatchEvent(o)}});this.editor=t,this.editor.rootContainer.addEventListener("mousedown",this.handleMouseDown),this.img=new Image,this.img.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"}destroy(){this.editor.rootContainer.removeEventListener("mousedown",this.handleMouseDown)}}class nH{constructor(t){m(this,"handleFocusBlockChanged",(t,e,o)=>{const i=this.editor.getFocusedBlock();if(i&&Wo(i)){const s=Ie.getImageObject(this.editor,i);s.getImages().length>0&&s.getSelectedIndex()===-1&&s.setSelectedIndex(0)}o&&Wo(o)&&Ie.getImageObject(this.editor,o).blockResizer.disableResize()});this.editor=t,this.editor.addListener("focusBlockChanged",this.handleFocusBlockChanged)}destroy(){this.editor.removeListener("focusBlockChanged",this.handleFocusBlockChanged)}}class oH{constructor(t){m(this,"currentResizer",null);m(this,"handleHoveringBlockChange",(t,e)=>{window.isDragging||(e&&this.disable(e),t&&(this.currentResizer=t,this.enable(t)))});this.editor=t,Ce.get(t).addListener("change",this.handleHoveringBlockChange)}destroy(){Ce.get(this.editor).removeListener("change",this.handleHoveringBlockChange)}disable(t){Wo(t)&&Ie.getImageObject(this.editor,t).disableResizer()}enable(t){if(Wo(t)){const e=Ie.getImageObject(this.editor,t);this.editor.isBlockWritable(t)&&e.tryEnableResizer()}}}const rH={image:{title:"\u56FE\u7247",upload:{failed:'<div class="line-1">\u56FE\u7247\u4E0A\u4F20\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <a href="" class="retry-upload">\u91CD\u8BD5</a></div>'},load:{failed:'<div class="line-1">\u56FE\u7247\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <a href="" class="retry-upload">\u91CD\u8BD5</a></div>',remote:{failed:'<div class="line-1">\u56FE\u7247\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u8BE5\u56FE\u7247\u6765\u81EA\u5916\u90E8\u94FE\u63A5\uFF0C\u5916\u90E8\u94FE\u63A5\u5DF2\u5931\u6548</div><div class="line-3">\u8BF7\u5C06\u539F\u56FE\u4FDD\u5B58\u5230\u672C\u5730\u540E\u4E0A\u4F20\uFF0C <a href="" class="retry-upload">\u6253\u5F00\u56FE\u7247\u94FE\u63A5</a></div>',tooltip:"\u8BE5\u56FE\u7247\u6765\u81EA\u5916\u90E8\u94FE\u63A5\uFF0C\u5982\u679C\u94FE\u63A5\u5931\u6548\u56FE\u7247\u5C06\u65E0\u6CD5\u67E5\u770B\uFF0C\u5EFA\u8BAE\u4FDD\u5B58\u5230\u672C\u5730\u540E\u6DFB\u52A0\u5230\u9875\u9762\u4E2D"}},abstract:"\u56FE\u7247"}},iH={image:{title:"Image",upload:{failed:'<div class="line-1">Image upload failed</div><div class="line-2">Network error, you can <a href="" class="retry-upload">Retry</a></div>'},load:{failed:'<div class="line-1">Image failed to load</div><div class="line-2">Network error, you can <a href="" class="retry-upload">Retry</a></div>',remote:{failed:'<div class="line-1">Failed to load image</div><div class="line-2">This picture is from an expired external link</div><div class="line-3">Please save the original image to local drives and upload it. <a href="" class="retry-upload">Open image link</a></div>',tooltip:"This picture is from an external link. If the link expires, the picture will not be available. It's recommended to save it to local drives and add it to the page."}},abstract:"Image"}},sH={image:{title:"\u753B\u50CF",upload:{failed:'<div class="line-1">\u753B\u50CF\u3092\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <a href="" class="retry-upload">\u518D\u8A66\u884C</a></div>'},load:{failed:'<div class="line-1">\u753B\u50CF\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <a href="" class="retry-upload">\u518D\u8A66\u884C</a></div>',remote:{failed:'<div class="line-1">\u753B\u50CF\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u3053\u306E\u753B\u50CF\u306B\u30EA\u30F3\u30AF\u3057\u3066\u3044\u308B URL \u304C\u7121\u52B9\u306B\u306A\u3063\u3066\u3044\u307E\u3059\u306E\u3067\u3001\u8868\u793A\u3067\u304D\u307E\u305B\u3093</div><div class="line-3">\u753B\u50CF\u3092\u30ED\u30FC\u30AB\u30EB\u306B\u4FDD\u5B58\u3057\u3066\u30A2\u30C3\u30D7\u30ED\u30FC\u30C0\u3057\u3066\u304F\u3060\u3055\u3044 <a href="" class="retry-upload">\u753B\u50CF\u30EA\u30F3\u30AF\u3092\u958B\u304F</a></div>',tooltip:"\u3053\u306E\u753B\u50CF\u306F\u5916\u90E8\u306B\u30EA\u30F3\u30AF\u3057\u3066\u3044\u308B\u305F\u3081\u3001\u30EA\u30F3\u30AF\u304C\u7121\u52B9\u306B\u306A\u308B\u3068\u3001\u8868\u793A\u3067\u304D\u306A\u304F\u306A\u308A\u307E\u3059\u306E\u3067\u3001\u30ED\u30FC\u30AB\u30EB\u306B\u4FDD\u5B58\u3057\u3001\u30DA\u30FC\u30B8\u306B\u633F\u5165\u3059\u308B\u3053\u3068\u3092\u304A\u52E7\u3081\u3057\u307E\u3059"}},abstract:"\u753B\u50CF"}};R.mergeLang({"zh-CN":rH,"en-US":iH,"ja-JP":sH});function lH(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o),l=ie(s);let a=o;if(l.endsWith("![]()"))a-=5;else if(l.endsWith("![]"))a-=3;else return!1;const d=o;return Ul("image/*").then(h=>{n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,a,d-a);let p=e+1;ie(n.getBlockText(r)).trim()?(Ql(n,r,a,{forceInsertAfter:!0}),a===0&&(n.deleteBlock(r),p--)):(n.deleteBlock(r),p--),zm(n,"image",t,p,{file:h})})}),!0}class cH{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&lH(t,e,o,r))}}function aH(n){const t=n.getFocusedBlock(),e=Ts(t);if(e&&Wo(e)){n.selection.selectBlock(e,0);const o=Ie.getImageObject(n,e);return o.getImages().length>0&&o.setSelectedIndex(0),!0}}function uH(n){const t=n.getFocusedBlock(),e=Is(t);if(e&&Wo(e)){n.selection.selectBlock(e,0);const o=Ie.getImageObject(n,e);return o.getImages().length>0&&o.setSelectedIndex(0),!0}}function dH(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e),r=o.getImages();if(r.length>0){const i=o.getSelectedIndex();if(i===-1)return o.setSelectedIndex(r.length-1),!0;if(i>0)return o.setSelectedIndex(i-1),!0}}}function hH(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e),r=o.getImages();if(r.length>0){const i=o.getSelectedIndex();if(i===-1)return o.setSelectedIndex(0),!0;if(i<r.length-1)return o.setSelectedIndex(i+1),!0}}}function s2(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e);if(o.getImages().length>0){const i=o.getSelectedIndex();if(i!==-1)return o.removeImage(i),!0}}}const fH={ArrowLeft:dH,ArrowRight:hH,ArrowUp:uH,ArrowDown:aH,Delete:s2,Backspace:s2},mH=S("copy-image");function gH(n,t,e,o){const r=e.getImages()[o],i=e.getImages().length===1?e.getWidthPercent():r.flex*100,s=cn([r],i),l={id:K(),type:"embed",embedType:"image",embedData:s},a=n.options.componentsOptions.image;a!=null&&a.defaultAlign&&(l.align=a.defaultAlign);const d={blocks:{root:[l]},comments:{},meta:{}},h=document.createElement("canvas");h.width=t.naturalWidth,h.height=t.naturalHeight;const p=h.getContext("2d");if(!p)return;const A={},v={};try{p.drawImage(t,0,0,h.width,h.height);const z=h.toDataURL("image/png").replace(/^data:image\/(png|jpg);base64,/,""),q=xm(z),rt=new File([q],`${Date.now()}.png`,{type:"image/png"});A["image/png"]=rt}catch(H){mH.error(H)}Oh(n,d);const D=`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`,x=Rh(D,d),_=Ma(n,d);A["text/plain"]=new Blob([_],{type:"text/plain"}),v["text/plain"]=_;const M=new Blob([x],{type:"text/html"});return A["text/html"]=M,v["text/html"]=x,[A,v]}function pH(n,t,e,o,r){const i=gH(n,t,e,o);if(!i)return;const[s,l]=i;if(s){const a=Object.entries(s).map(([d,h])=>({type:d,data:h}));return Dm(a).then(d=>{if(!d&&r){const h=r.clipboardData;h&&(h.setData("text/plain",l["text/plain"]),h.setData("text/html",l["text/html"]))}}),!0}}function J7(n,t){const e=n.selection.range;if(e.start.blockId!==e.end.blockId)return;const r=n.getFocusedBlock();if(r&&Wo(r)){const i=Ie.getImageObject(n,r);if(i.getImages().length>0){const l=i.getSelectedIndex();if(l!==-1){const d=Ar(r)[l].querySelector("img");if(d)return pH(n,d,i,l,t)}}}}class CH{constructor(t){this.editor=t,setTimeout(()=>{this.editor.input.addHandler(this)})}handleBeforeCopy(t,e,o){if(J7(t,e))return!0}handleBeforeCut(t,e){if(J7(t,e))return s2(t),!0}destroy(){}}class l2{constructor(t){this.editor=t,setTimeout(()=>{this.editor.input.addHandler(this)})}async handleAfterPasteDoc(t,e,o){return Object.values(e.blocks).forEach(r=>{r.forEach(i=>{if(i.type==="embed"&&i.embedType==="image"){const s=i.embedData;if(Array.isArray(s.src))return;if(s.src.startsWith("https:")||s.src.startsWith("http:")){const l=o.blockIdMap.get(i.id);l&&Yi(t,l).setAutoFix(!0)}}})}),!1}destroy(){}}const AH=S("image-embed");function bH(n,t,e,o,r,i){Ie.create(n,e).createContent(r,i,t),n.addCustom("image-select-handler",()=>new nH(n)),n.addCustom("image-copy-handler",()=>new CH(n)),setTimeout(()=>{n.addCustom("drag-handler",()=>new eH(n));const l=n.addCustom("image-resizer",()=>new oH(n)),a=e.embedData;vc(a)?l.disable(i):l.currentResizer===i&&l.enable(i)})}function vH(n,t,e,o){const r=t.embedData,i=yc(r);return o==="html"?i.map(s=>`<img src="${n.doc.buildResourceUrl(s.src,{withToken:!0})}">`).join(""):o==="markdown"?`${i.map(l=>`![img](${n.doc.buildResourceUrl(l.src,{withToken:!0})})`).join(`
423
+ Click to open the menu`,insertTips:"Click to add block"}}},_$={blockMenu:{section:{basics:"\u4E00\u822C",system:"\u30B7\u30B9\u30C6\u30E0",styles:"\u30B9\u30BF\u30A4\u30EB",common:"\u4E00\u822C",actions:"\u64CD\u4F5C",thirdParty:"\u5916\u90E8\u30B3\u30F3\u30C6\u30F3\u30C4"},command:{insertAbove:"\u4E0A\u306B\u633F\u5165",insertAfter:"\u4E0B\u306B\u633F\u5165",copy:"\u8907\u88FD",cut:"\u5207\u308B",delete:"\u524A\u9664"},button:{searchPlaceholder:"\u30AD\u30FC\u30EF\u30FC\u30C9\u3067\u691C\u7D22",tips:"\u3092\u30C9\u30E9\u30C3\u30B0\u3057\u3066\u30AF\u30EA\u30C3\u30AF\u3067\u30E1\u30CB\u30E5\u30FC\u3092\u8868\u793A",insertTips:"\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u30D6\u30ED\u30C3\u30AF\u3092\u8FFD\u52A0"}}};R.mergeLang({"zh-CN":R$,"en-US":O$,"ja-JP":_$});const Unt="";class F${constructor(){m(this,"dragObject",null)}setData(t){this.dragObject=t}getData(){return this.dragObject}clearData(){this.dragObject=null}destroy(){}}function Ff(n){return n.addCustom("drag-data",()=>new F$)}function o2(n,t){if(!t)return null;const e=Ff(n).getData();return!e||e.editorId!==n.id?null:e}function Z7(n,t){const e=o2(n,t);return e?n.findBlockById(e.blockId):null}function P$(n,t,e){if(!t.dataTransfer)return;const r=nt(e),i=ct(r),s=it(e),l={type:"block",editorId:n.id,containerId:i,blockId:s};Ff(n).setData(l)}function N$(n,t,e,o,r){if(!t.dataTransfer)return;const s=nt(e),l=ct(s),a=it(e),d={type:"custom",customType:o,editorId:n.id,containerId:l,blockId:a,data:r};Ff(n).setData(d)}function $$(n){Ff(n).clearData()}const H$=S("drop-indicator"),Pf=2;class j${constructor(t){m(this,"indicator");m(this,"target",null);this.editor=t,this.indicator=w("div",["editor-drop-indicator"],this.editor.contentElement)}show(t,e){const o=this.getIndicatorRect(t,e),r=this.editor.rootElement.getBoundingClientRect(),i=o.top-r.top,s=o.left-r.left;this.indicator.style.top=`${i}px`,this.indicator.style.left=`${s}px`,this.indicator.style.width=`${o.width}px`,this.indicator.style.height=`${o.height}px`,this.indicator.style.display="",this.target={block:t,insertPos:e}}hide(){this.indicator.style.display="none",this.target=null}getIndicatorRect(t,e){if(typeof e!="string")return e.rect;if(e==="before"){const s=Is(t);if(!s){g(H$,Lo(nt(t)),"block does not in a child container");const d=t.getBoundingClientRect();return new DOMRect(d.x,d.y,d.width,Pf)}const l=s.getBoundingClientRect(),a=t.getBoundingClientRect();return new DOMRect(l.x,(l.bottom+a.top)/2,l.width,Pf)}const o=Ts(t);if(!o){const s=t.getBoundingClientRect();return new DOMRect(s.x,s.bottom,s.width,Pf)}const r=t.getBoundingClientRect(),i=o.getBoundingClientRect();return new DOMRect(r.x,(r.bottom+i.top)/2,r.width,Pf)}}const U$=S("find-drop-target");function z$(n,t){const e=document.elementFromPoint(n,t);if(!e)return null;if(Pr(e)&&Lo(e))return e;const o=e.firstElementChild;return o&&Pr(o)&&Lo(o)?o:null}function V$(n,t){const s=t,l=n;for(let a=0;a<2;a++){const d=l+a*50;for(let h=0;h<5;h++){const p=s+h*8,A=document.elementFromPoint(d,p);if(A){const D=et(A);if(D)return D}if(h===0)continue;const v=s-h*8,B=document.elementFromPoint(d,v);if(B){const D=et(B);if(D)return D}}}return null}function W$(n,t,e){const o=document.elementFromPoint(t,e);if(o){const h=et(o);if(h&&!Mt(n,h))return h}const r=new Set,i=z$(t,e);if(i){const h=i.getBoundingClientRect();e<h.top+h.height/2?r.add(ye(i)):r.add(Qe(i))}const s=V$(t,e);s&&r.add(s);const l=Array.from(r),a=h=>{for(let p=0;p<l.length;p++){const A=l[p];if(h!==A&&Xt(h,A))return!0}return!1},d=l.filter(h=>!a(h));return d.length>0?d[0]:null}function r2(n,t){if(n.readonly)return!1;const e=nt(t);if(Yt(e))return!0;const o=et(e);return g(U$,o,"no parent block"),n.isBlockWritable(o)?r2(n,o):!1}const q$=S("drop-target");function G$(n,t){let e={};return/image/.test(t.type)?e=n.editorEmbeds.getEmbedClass("image"):/audio/.test(t.type)?e=n.editorEmbeds.getEmbedClass("audio"):/video/.test(t.type)&&(e=n.editorEmbeds.getEmbedClass("video")),g(q$,e,`unSupport file type ${t.type}`),e}async function Q7(n,t,e,o){var i,s;let r=o;for(const l of t){const a=G$(n,l);a.getOptions&&await((s=(i=a.getOptions(n)).handleInsertEmptyEmbed)==null?void 0:s.call(i,n,{containerId:e,blockIndex:r,data:{file:l}}))&&(r+=1)}}class Z${constructor(t){m(this,"handleDrop",(t,e,o,r)=>{if(Array.isArray(e)){const i=e;if(i.length>0){const s=ct(o);return Q7(t,i,s,r),!0}}return!1});this.editor=t}}class Lu{constructor(t){m(this,"indicator");m(this,"lastDropOverResult");m(this,"handlers",[]);m(this,"handleDragOver",t=>{if(!this.editor.isWritable())return;const e=i=>{var d,h;const s=o2(this.editor,i.dataTransfer),l=Z7(this.editor,i.dataTransfer),a=this.findTargetBlock(l,i.x,i.y);if(a&&Xt(this.editor.rootContainer,a)){const p=this.findInsertPos(l,a,i.x,i.y,(h=s!=null?s:(d=i.dataTransfer)==null?void 0:d.items)!=null?h:null);if(p)return this.indicator.show(a,p),"move"}return this.indicator.hide(),"none"},o=(i,s)=>{i.dataTransfer&&(i.dataTransfer.dropEffect=s),s==="move"&&i.preventDefault()};if(this.lastDropOverResult&&t.x===this.lastDropOverResult.x&&t.y===this.lastDropOverResult.y){const i=this.lastDropOverResult.dropEffect;o(t,i);return}const r=e(t);o(t,r),this.lastDropOverResult={x:t.x,y:t.y,dropEffect:r}});m(this,"handleDrop",t=>{var i,s;t.stopPropagation(),setTimeout(()=>{this.indicator.hide()});const e=o2(this.editor,t.dataTransfer),o=Array.from((s=(i=t.dataTransfer)==null?void 0:i.files)!=null?s:[]);if(!e&&o.length===0){t.dataTransfer&&(t.dataTransfer.dropEffect="none");return}const r=this.indicator.target;if(r){const{block:l,insertPos:a}=r,d=Z7(this.editor,t.dataTransfer);this.editor.undoManager.runInGroup(()=>{const h=Qt(this.editor,l);if(h.handleDrop&&h.handleDrop(this.editor,l,e!=null?e:o,a,{isSourceBlock:!1,targetBlock:l})){t.preventDefault(),this.editor.focus();return}if(d){const p=Qt(this.editor,d);if(p.handleDrop&&p.handleDrop(this.editor,d,e!=null?e:o,a,{isSourceBlock:!0,targetBlock:l})){t.preventDefault(),this.editor.focus();return}}if(typeof a=="string"){const p=nt(l);let A=bt(l);a==="after"&&(A+=1),t.preventDefault();for(let v=0;v<this.handlers.length;v++)if(this.handlers[v].handleDrop(this.editor,d!=null?d:o,p,A)){this.editor.focus();return}if(d){const v=this.editor.getBlockData(d),B=Fi(this.editor.editorBlocks,this.editor.doc.toJSON(),v),[D]=this.editor.insertDocAt(p,A,B);this.editor.selection.selectBlock(D,0),Su.get(this.editor).highlightBlock(D),this.editor.deleteBlock(d),this.editor.focus()}}}),$$(this.editor)}});m(this,"handleDragLeave",()=>{this.indicator.hide()});this.editor=t,this.indicator=new j$(this.editor),this.handlers.push(new Z$(this.editor)),this.editor.contentElement.addEventListener("dragover",this.handleDragOver),this.editor.contentElement.addEventListener("dragleave",this.handleDragLeave),this.editor.contentElement.addEventListener("drop",this.handleDrop)}destroy(){this.editor.contentElement.removeEventListener("dragover",this.handleDragOver),this.editor.contentElement.removeEventListener("dragleave",this.handleDragLeave),this.editor.contentElement.removeEventListener("drop",this.handleDrop),this.handlers=[]}addHandler(t){this.handlers.push(t)}static register(t){return t.addCustom("drop-target",()=>new Lu(t))}static get(t){return t.getCustom("drop-target")}static find(t){return t.findCustom("drop-target")}canInsertAfter(t,e){return!(this.editor.readonly||Ts(e)===t&&t||!r2(this.editor,e))}canInsertBefore(t,e){return!(this.editor.readonly||Is(e)===t&&t||!r2(this.editor,e)||Yt(nt(e))&&bt(e)===0)}canDrop(t,e){return t===null||t===e?!0:!Xt(t,e)}findTargetBlock(t,e,o){let r=W$(this.editor,e,o);if(!r||!Xt(this.editor.rootContainer,r))return null;const i=nt(r),s=et(i);return s&&Dt(s)==="code"&&(r=s),this.canDrop(t,r)?r:null}findInsertPos(t,e,o,r,i){let s=e;for(;s;){const a=Qt(this.editor,s);if(a.handleDropOver){const d=a.handleDropOver(this.editor,s,i,o,r);if(d)return d;if(d===!1)return null}s=Es(s)}if(t===e)return"";const l=e.getBoundingClientRect();if(l.top<=r&&r<=l.bottom){if(r<l.top+l.height/2){if(this.canInsertBefore(t,e))return"before";if(this.canInsertAfter(t,e))return"after"}else{if(this.canInsertAfter(t,e))return"after";if(this.canInsertBefore(t,e))return"before"}return""}return r<l.top&&this.canInsertBefore(t,e)?"before":l.bottom<r&&this.canInsertAfter(t,e)?"after":""}}function Y7(n,t,e){const o=Ie.getImageObject(n,t),r=mt.default(o.getImages());if(r.length===1){n.deleteBlock(t);return}if(e===-1||e>=r.length)return;const i=ON(r);if(r.splice(e,1),r.length===1){const l=r[0],a=100*(l.flex/i);l.flex=1;const d=cn([l],a);n.updateEmbedData(t,d);return}r[0].flex=NaN,wu(r);const s=cn(r,o.getWidthPercent());n.updateEmbedData(t,s)}function Q$(n,t,e,o){if(t.length===0||o==="after"||o==="before")return!1;let r=o.data;const i=Ie.getImageObject(n,e),s=mt.default(i.getImages()),l=[],a=[];t.forEach(p=>{F7(p.type)&&s.length+l.length<6?l.push(p):a.push(p)}),l.forEach(p=>{try{_7(n,p)}catch{return}const A={src:"",flex:1,width:0,height:0,virtualSize:!0};s.splice(r,0,A);const v=cn(s,i.getWidthPercent());n.updateEmbedData(e,v),i.replaceImage(r,p),r+=1});const d=n.getBlockIndex(e)+1,h=ct(nt(e));return Q7(n,a,h,d),!0}function Y$(n,t,e,o,r){var s,l,a;if(Gd(e))return Q$(n,e,t,o);if(e.type!=="custom"||e.customType!=="image"||!e.data)return;const i=e.data;if(r.isSourceBlock){const d=r.targetBlock,h=nt(d);let p=bt(d);o==="after"&&(p+=1);const v=100*(i.boundingRect.width/n.rootContainer.getBoundingClientRect().width),B=cn([i.image],v),D={id:K(),type:"embed",embedType:"image",embedData:B},x=(l=(s=n.options.componentsOptions)==null?void 0:s.image)==null?void 0:l.defaultAlign;x&&(D.align=x),n.insertBlock(ct(h),p,D),Y7(n,t,i.index),(a=n.findCustom("drag-handler"))==null||a.handleDragEnd()}else{if(typeof o=="string")return;const d=t;let h=o.data;const p=Ie.getImageObject(n,d),A=mt.default(p.getImages());h>A.length&&(h=A.length),n.undoManager.runInGroup(()=>{var B,D;p.setAutoFix(!0);const v=n.getBlockById(e.blockId);if(v===d){const x=i.index,_=h,M=i.image;if(x===_||_===x+1)return;let H=_;x<_?(A.splice(_,0,M),A.splice(x,1),H-=1):(A.splice(x,1),A.splice(_,0,M));const z=cn(A,p.getWidthPercent());n.updateEmbedData(d,z),p.setSelectedIndex(H),(B=n.findCustom("drag-handler"))==null||B.handleDragEnd()}else{A.splice(h,0,i.image),A[0].flex=NaN,wu(A);const x=cn(A,p.getWidthPercent());n.updateEmbedData(d,x),Y7(n,v,i.index),(D=n.findCustom("drag-handler"))==null||D.handleDragEnd(),p.setSelectedIndex(h),n.selection.selectBlock(d,0)}})}return!0}const J$=2;function Nf(n,t,e){const o=Ar(t);if(e<=0){const s=o[0].getBoundingClientRect();return new DOMRect(s.left-4,s.top,2,s.height)}if(e===o.length){const s=o[e-1].getBoundingClientRect();return new DOMRect(s.right+2,s.top,2,s.height)}const r=o[e-1].getBoundingClientRect(),i=o[e].getBoundingClientRect();return new DOMRect((i.left+r.right)/2-1,r.top,J$,r.height)}function K$(n,t,e,o,r){for(let i=0;i<e.length;i++){const l=e[i].getBoundingClientRect();if(o<=l.right)return o<=l.left+l.width/2?{rect:Nf(n,t,i),data:i}:{rect:Nf(n,t,i+1),data:i+1}}return o>e[e.length-1].getBoundingClientRect().right?{rect:Nf(n,t,e.length),data:e.length}:{rect:Nf(n,t,e.length),data:0}}function X$(n,t,e,o,r){const i=Ar(t);if(e instanceof DataTransferItemList){if(!Array.from(e).some(s=>F7(s.type))||i.length>=6)return}else{if((e==null?void 0:e.type)==="block"||i.length>=6&&(e==null?void 0:e.blockId)!==it(t))return;const s=it(t);if(i.length===1&&s===(e==null?void 0:e.blockId))return}return K$(n,t,i,o)}async function tH(n){return await G5.default.toSvg(n)}function i2(n,t){return new DragEvent(t,{bubbles:!0,cancelable:!0,view:window,screenX:n.screenX,screenY:n.screenY,dataTransfer:new DataTransfer,clientX:n.clientX,clientY:n.clientY})}class eH{constructor(t){m(this,"img");m(this,"dragContainer",null);m(this,"autoScroll",null);m(this,"imageContainer",null);m(this,"startPosition",null);m(this,"handleMouseDown",t=>{const e=t.target;if(!e||!(e instanceof HTMLImageElement)||t.button!==0)return;const o=et(e);if(!o||!Wo(o)||!this.editor.isBlockWritable(o)||this.editor.readonly)return;const r=Ie.getImageObject(this.editor,o);if(this.imageContainer=G0(t.target),!this.imageContainer)return;const s=D7(t.target).indexOf(this.imageContainer);if(s===-1)return;const l=r.getImages()[s];if(!l)return;const{x:a,y:d}=t;this.startPosition={x:a,y:d};const h={image:l,index:s,boundingRect:this.imageContainer.getBoundingClientRect()},p=i2(t,"dragstart");N$(this.editor,p,o,"image",h),document.addEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.addEventListener("mousemove",this.handleDrag),t.preventDefault()});m(this,"handleDragStart",async t=>{if(!this.imageContainer)return;const e=et(this.imageContainer);if(!e)return;const{x:o,y:r}=t,{width:i,height:s}=t.target.getBoundingClientRect(),l=te(e),a=w("div",["drag-container"],l);a.style.left=`${o-i/4}px`,a.style.top=`${r-s/4}px`,a.style.width=`${Math.max(i/2,16)}px`,a.style.height=`${s/2}px`,this.dragContainer=a,W(this.editor.contentElement,"dragging");const d=ro(e);this.autoScroll=new Qd({scrollElement:d,trackMouseEvent:"mousemove",edge:{top:50,bottom:50}}),this.autoScroll.active();const h=w("img",["drag-target"],a),A=await tH(this.imageContainer);A&&(h.src=A)});m(this,"handleDrag",t=>{var i;const{x:e,y:o}=t;if(((i=this.startPosition)==null?void 0:i.x)===e&&this.startPosition.y===o)return;if(window.isDragging||(window.isDragging=!0,this.handleDragStart(t)),this.startPosition&&this.dragContainer){const{x:s,y:l}=t;if(s===0&&l===0){this.dragContainer.style.transform="",this.dragContainer.style.opacity="0";return}const{x:a,y:d}=this.startPosition,h=s-a,p=l-d;this.dragContainer.style.transform=`translate(${h}px, ${p}px)`,this.dragContainer.style.opacity="0.5"}const r=i2(t,"dragover");this.editor.contentElement.dispatchEvent(r)});m(this,"handleDragEnd",t=>{var e;if(window.isDragging=!1,this.dragContainer&&this.dragContainer.remove(),this.dragContainer=null,this.startPosition=null,this.imageContainer=null,(e=this.autoScroll)==null||e.inactive(),ot(this.editor.contentElement,"dragging"),document.removeEventListener("mouseup",this.handleDragEnd),this.editor.contentElement.removeEventListener("mousemove",this.handleDrag),t){const o=i2(t,"drop");this.editor.contentElement.dispatchEvent(o)}});this.editor=t,this.editor.rootContainer.addEventListener("mousedown",this.handleMouseDown),this.img=new Image,this.img.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"}destroy(){this.editor.rootContainer.removeEventListener("mousedown",this.handleMouseDown)}}class nH{constructor(t){m(this,"handleFocusBlockChanged",(t,e,o)=>{const i=this.editor.getFocusedBlock();if(i&&Wo(i)){const s=Ie.getImageObject(this.editor,i);s.getImages().length>0&&s.getSelectedIndex()===-1&&s.setSelectedIndex(0)}o&&Wo(o)&&t.findCustom(`image-${o.id}`)&&Ie.getImageObject(this.editor,o).blockResizer.disableResize()});this.editor=t,this.editor.addListener("focusBlockChanged",this.handleFocusBlockChanged)}destroy(){this.editor.removeListener("focusBlockChanged",this.handleFocusBlockChanged)}}class oH{constructor(t){m(this,"currentResizer",null);m(this,"handleHoveringBlockChange",(t,e)=>{window.isDragging||(e&&this.disable(e),t&&(this.currentResizer=t,this.enable(t)))});this.editor=t,Ce.get(t).addListener("change",this.handleHoveringBlockChange)}destroy(){Ce.get(this.editor).removeListener("change",this.handleHoveringBlockChange)}disable(t){Wo(t)&&Ie.getImageObject(this.editor,t).disableResizer()}enable(t){if(Wo(t)){const e=Ie.getImageObject(this.editor,t);this.editor.isBlockWritable(t)&&e.tryEnableResizer()}}}const rH={image:{title:"\u56FE\u7247",upload:{failed:'<div class="line-1">\u56FE\u7247\u4E0A\u4F20\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <a href="" class="retry-upload">\u91CD\u8BD5</a></div>'},load:{failed:'<div class="line-1">\u56FE\u7247\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <a href="" class="retry-upload">\u91CD\u8BD5</a></div>',remote:{failed:'<div class="line-1">\u56FE\u7247\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u8BE5\u56FE\u7247\u6765\u81EA\u5916\u90E8\u94FE\u63A5\uFF0C\u5916\u90E8\u94FE\u63A5\u5DF2\u5931\u6548</div><div class="line-3">\u8BF7\u5C06\u539F\u56FE\u4FDD\u5B58\u5230\u672C\u5730\u540E\u4E0A\u4F20\uFF0C <a href="" class="retry-upload">\u6253\u5F00\u56FE\u7247\u94FE\u63A5</a></div>',tooltip:"\u8BE5\u56FE\u7247\u6765\u81EA\u5916\u90E8\u94FE\u63A5\uFF0C\u5982\u679C\u94FE\u63A5\u5931\u6548\u56FE\u7247\u5C06\u65E0\u6CD5\u67E5\u770B\uFF0C\u5EFA\u8BAE\u4FDD\u5B58\u5230\u672C\u5730\u540E\u6DFB\u52A0\u5230\u9875\u9762\u4E2D"}},abstract:"\u56FE\u7247"}},iH={image:{title:"Image",upload:{failed:'<div class="line-1">Image upload failed</div><div class="line-2">Network error, you can <a href="" class="retry-upload">Retry</a></div>'},load:{failed:'<div class="line-1">Image failed to load</div><div class="line-2">Network error, you can <a href="" class="retry-upload">Retry</a></div>',remote:{failed:'<div class="line-1">Failed to load image</div><div class="line-2">This picture is from an expired external link</div><div class="line-3">Please save the original image to local drives and upload it. <a href="" class="retry-upload">Open image link</a></div>',tooltip:"This picture is from an external link. If the link expires, the picture will not be available. It's recommended to save it to local drives and add it to the page."}},abstract:"Image"}},sH={image:{title:"\u753B\u50CF",upload:{failed:'<div class="line-1">\u753B\u50CF\u3092\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <a href="" class="retry-upload">\u518D\u8A66\u884C</a></div>'},load:{failed:'<div class="line-1">\u753B\u50CF\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <a href="" class="retry-upload">\u518D\u8A66\u884C</a></div>',remote:{failed:'<div class="line-1">\u753B\u50CF\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u3053\u306E\u753B\u50CF\u306B\u30EA\u30F3\u30AF\u3057\u3066\u3044\u308B URL \u304C\u7121\u52B9\u306B\u306A\u3063\u3066\u3044\u307E\u3059\u306E\u3067\u3001\u8868\u793A\u3067\u304D\u307E\u305B\u3093</div><div class="line-3">\u753B\u50CF\u3092\u30ED\u30FC\u30AB\u30EB\u306B\u4FDD\u5B58\u3057\u3066\u30A2\u30C3\u30D7\u30ED\u30FC\u30C0\u3057\u3066\u304F\u3060\u3055\u3044 <a href="" class="retry-upload">\u753B\u50CF\u30EA\u30F3\u30AF\u3092\u958B\u304F</a></div>',tooltip:"\u3053\u306E\u753B\u50CF\u306F\u5916\u90E8\u306B\u30EA\u30F3\u30AF\u3057\u3066\u3044\u308B\u305F\u3081\u3001\u30EA\u30F3\u30AF\u304C\u7121\u52B9\u306B\u306A\u308B\u3068\u3001\u8868\u793A\u3067\u304D\u306A\u304F\u306A\u308A\u307E\u3059\u306E\u3067\u3001\u30ED\u30FC\u30AB\u30EB\u306B\u4FDD\u5B58\u3057\u3001\u30DA\u30FC\u30B8\u306B\u633F\u5165\u3059\u308B\u3053\u3068\u3092\u304A\u52E7\u3081\u3057\u307E\u3059"}},abstract:"\u753B\u50CF"}};R.mergeLang({"zh-CN":rH,"en-US":iH,"ja-JP":sH});function lH(n,t,e,o){const r=n.getBlockByIndex(t,e),i=n.getBlockText(r),{left:s}=Tn(i,o),l=ie(s);let a=o;if(l.endsWith("![]()"))a-=5;else if(l.endsWith("![]"))a-=3;else return!1;const d=o;return Ul("image/*").then(h=>{n.undoManager.runInGroup(()=>{n.deleteTextFromBlock(r,a,d-a);let p=e+1;ie(n.getBlockText(r)).trim()?(Ql(n,r,a,{forceInsertAfter:!0}),a===0&&(n.deleteBlock(r),p--)):(n.deleteBlock(r),p--),zm(n,"image",t,p,{file:h})})}),!0}class cH{handleAfterInsertText(t,e,o,r,i){return!!(i===" "&&lH(t,e,o,r))}}function aH(n){const t=n.getFocusedBlock(),e=Ts(t);if(e&&Wo(e)){n.selection.selectBlock(e,0);const o=Ie.getImageObject(n,e);return o.getImages().length>0&&o.setSelectedIndex(0),!0}}function uH(n){const t=n.getFocusedBlock(),e=Is(t);if(e&&Wo(e)){n.selection.selectBlock(e,0);const o=Ie.getImageObject(n,e);return o.getImages().length>0&&o.setSelectedIndex(0),!0}}function dH(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e),r=o.getImages();if(r.length>0){const i=o.getSelectedIndex();if(i===-1)return o.setSelectedIndex(r.length-1),!0;if(i>0)return o.setSelectedIndex(i-1),!0}}}function hH(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e),r=o.getImages();if(r.length>0){const i=o.getSelectedIndex();if(i===-1)return o.setSelectedIndex(0),!0;if(i<r.length-1)return o.setSelectedIndex(i+1),!0}}}function s2(n){const e=n.getFocusedBlock();if(e&&Wo(e)){const o=Ie.getImageObject(n,e);if(o.getImages().length>0){const i=o.getSelectedIndex();if(i!==-1)return o.removeImage(i),!0}}}const fH={ArrowLeft:dH,ArrowRight:hH,ArrowUp:uH,ArrowDown:aH,Delete:s2,Backspace:s2},mH=S("copy-image");function gH(n,t,e,o){const r=e.getImages()[o],i=e.getImages().length===1?e.getWidthPercent():r.flex*100,s=cn([r],i),l={id:K(),type:"embed",embedType:"image",embedData:s},a=n.options.componentsOptions.image;a!=null&&a.defaultAlign&&(l.align=a.defaultAlign);const d={blocks:{root:[l]},comments:{},meta:{}},h=document.createElement("canvas");h.width=t.naturalWidth,h.height=t.naturalHeight;const p=h.getContext("2d");if(!p)return;const A={},v={};try{p.drawImage(t,0,0,h.width,h.height);const z=h.toDataURL("image/png").replace(/^data:image\/(png|jpg);base64,/,""),q=xm(z),rt=new File([q],`${Date.now()}.png`,{type:"image/png"});A["image/png"]=rt}catch(H){mH.error(H)}Oh(n,d);const D=`<img src="${n.doc.buildResourceUrl(r.src,{withToken:!0})}" />`,x=Rh(D,d),_=Ma(n,d);A["text/plain"]=new Blob([_],{type:"text/plain"}),v["text/plain"]=_;const M=new Blob([x],{type:"text/html"});return A["text/html"]=M,v["text/html"]=x,[A,v]}function pH(n,t,e,o,r){const i=gH(n,t,e,o);if(!i)return;const[s,l]=i;if(s){const a=Object.entries(s).map(([d,h])=>({type:d,data:h}));return Dm(a).then(d=>{if(!d&&r){const h=r.clipboardData;h&&(h.setData("text/plain",l["text/plain"]),h.setData("text/html",l["text/html"]))}}),!0}}function J7(n,t){const e=n.selection.range;if(e.start.blockId!==e.end.blockId)return;const r=n.getFocusedBlock();if(r&&Wo(r)){const i=Ie.getImageObject(n,r);if(i.getImages().length>0){const l=i.getSelectedIndex();if(l!==-1){const d=Ar(r)[l].querySelector("img");if(d)return pH(n,d,i,l,t)}}}}class CH{constructor(t){this.editor=t,setTimeout(()=>{this.editor.input.addHandler(this)})}handleBeforeCopy(t,e,o){if(J7(t,e))return!0}handleBeforeCut(t,e){if(J7(t,e))return s2(t),!0}destroy(){}}class l2{constructor(t){this.editor=t,setTimeout(()=>{this.editor.input.addHandler(this)})}async handleAfterPasteDoc(t,e,o){return Object.values(e.blocks).forEach(r=>{r.forEach(i=>{if(i.type==="embed"&&i.embedType==="image"){const s=i.embedData;if(Array.isArray(s.src))return;if(s.src.startsWith("https:")||s.src.startsWith("http:")){const l=o.blockIdMap.get(i.id);l&&Yi(t,l).setAutoFix(!0)}}})}),!1}destroy(){}}const AH=S("image-embed");function bH(n,t,e,o,r,i){Ie.create(n,e).createContent(r,i,t),n.addCustom("image-select-handler",()=>new nH(n)),n.addCustom("image-copy-handler",()=>new CH(n)),setTimeout(()=>{n.addCustom("drag-handler",()=>new eH(n));const l=n.addCustom("image-resizer",()=>new oH(n)),a=e.embedData;vc(a)?l.disable(i):l.currentResizer===i&&l.enable(i)})}function vH(n,t,e,o){const r=t.embedData,i=yc(r);return o==="html"?i.map(s=>`<img src="${n.doc.buildResourceUrl(s.src,{withToken:!0})}">`).join(""):o==="markdown"?`${i.map(l=>`![img](${n.doc.buildResourceUrl(l.src,{withToken:!0})})`).join(`
424
424
  `)}
425
425
  `:i.map(s=>n.doc.buildResourceUrl(s.src,{withToken:!0})).join(`
426
426
  `)}class yH{constructor(){m(this,"group","image");m(this,"commands",[])}executeCommand(t,e,o){if(o.id==="replace-image"){const{block:r,image:i}=o.data;Ie.getImageObject(t,r).replaceImage(0,i)}}}function kH(){return{blockCommands:{image:new yH},abstract:`${R.t("image.abstract")}`}}function wH(){return{name:"Image",insertEmbedCommandItems:[{id:"insert-image",name:R.t("image.abstract"),icon:yL,group:"common",subText:"/image",order:100}],handleInsertEmptyEmbed:async(n,t)=>{var v;let e;(v=t.data)!=null&&v.file&&(e=t.data.file);const o=O7(n);if(e=e!=null?e:await Ul(o),!e)return null;try{_7(n,e)}catch{return null}let r={width:b7,height:z0};try{r=await n$(e)}catch(B){AH.error(B)}const i=n.rootContainer.clientWidth,s=r.width<i?Math.min(100,r.width/i*100):100,l={src:"",width:r.width,height:r.height,flex:1,virtualSize:!1},a=cn([l],s),d={id:K(),type:"embed",embedType:"image",embedData:a},h=n.options.componentsOptions.image;h!=null&&h.defaultAlign&&(d.align=h.defaultAlign);const p=n.insertBlock(t.containerId,t.blockIndex,d);return Ie.getImageObject(n,p).replaceImage(0,e),p}}}function BH(n,t,e){var h;const{data:o}=e,r=n.getBlockString(t).trim();if(!o||o.embedType!=="image"||!tt(n,t))return null;const i=r.match(/^!\[[^\]]*\]\((?<filename>.*?)(?="|\))(?<optionalPart>".*")?\)/),s=(h=i==null?void 0:i.groups)==null?void 0:h.filename;if(!s)return null;const l={src:s},a={id:K(),type:"embed",embedType:"image",embedData:l};Ie.create(n,a).setAutoFix(!0);const d=n.options.componentsOptions.image.defaultAlign;return d&&(a.align=d),{blockData:a}}function EH(n,t){const e=it(t);n.destroyCustom(`image-${e}`)}const xH={embedType:"image",createEmbedContent:bH,convertTo:vH,convertFrom:BH,getBlockProperties:kH,getOptions:wH,handleDrop:Y$,handleDropOver:X$,handleDeleteBlock:EH};class IH{constructor(t,e){m(this,"toolbar");m(this,"anchor",null);m(this,"item");m(this,"docs",null);m(this,"checkedId");m(this,"handlePasteSpecial",(t,e)=>{!e.data||(this.checkedId===e.id?this.checkedId=void 0:this.checkedId=e.id,this.onPasteSpecial(e.data),setTimeout(()=>{this.docs&&this.show(this.docs),this.editor.focus()}))});m(this,"handleClose",()=>{this.editor.focus()});m(this,"handleSelectionChange",()=>{this.handleClose()});this.editor=t,this.onPasteSpecial=e,this.item={id:"paste-special",name:"",icon:kL,dropdown:!0,manualShowChildren:!0,childrenPlacement:"bottom-start",childrenOffset:[-4,4],children:[]},this.toolbar=new ou([this.item],void 0,{id:"paste-special-button",tooltipId:this.editor.clientId,refuseOverflow:!0}),this.toolbar.addListener("click",this.handlePasteSpecial),this.toolbar.addListener("close",this.handleClose),this.editor.addListener("selectionChanged",this.handleSelectionChange)}show(t){this.docs=t;const e=this.editor,o=e.selection.range;if(!o.isCollapsed())return;const r=e.getBlockById(o.start.blockId);if(!tt(e,r))return;const i=Nr(e,r,o)[0];if(!i)return;this.anchor&&this.anchor.remove(),this.anchor=zr(e,r,"paste-special-button-anchor",i);const s=this.getCommandItems(t);this.item.children=s,this.toolbar.manualShow(this.anchor)}hide(){this.toolbar.close("selectionChange")}clearCheckedState(){this.checkedId=void 0}destroy(){this.toolbar.destroy(),this.editor.removeListener("selectionChanged",this.handleSelectionChange)}getCommandItems(t){const e=i=>({id:i,states:this.checkedId===i?["checked"]:void 0,name:R.t("pasteSpecial.originFormats"),data:t[i]}),o=[];let r=!0;return t["text/x-ones-editor-doc"]?o.push(e("text/x-ones-editor-doc")):t["text/office-html"]?o.push(e("text/office-html")):t["text/html"]?o.push(e("text/html")):t["text/plain"]&&(o.push(e("text/plain")),r=!1),t["text/plain"]&&(r&&o.push({id:"text/plain",states:this.checkedId==="text/plain"?["checked"]:void 0,name:R.t("pasteSpecial.plainText"),data:t["text/plain"]}),o.push({id:"text/markdown",states:this.checkedId==="text/markdown"?["checked"]:void 0,name:R.t("pasteSpecial.markdown"),data:t["text/markdown"]})),o}}const TH=S("paste-special");class c2{constructor(t){m(this,"button");m(this,"lastUndoAction",null);m(this,"event",null);m(this,"handlePasteSpecial",t=>{this.editor.undoManager.runInGroup(()=>{this.editor.undoManager.undoTo(this.lastUndoAction),this.editor.pasteDoc(t)})});this.editor=t,this.button=new IH(t,this.handlePasteSpecial)}destroy(){this.event=null,this.button.destroy()}handleChanged(t,e){this.event=null,this.button.hide()}async handleBeforePaste(t,e){return TH.debug("before paste"),this.lastUndoAction=t.undoManager.lastAction(),!1}async handleAfterPaste(t,e,o){if(Object.keys(o).length<=1)return!1;const r=t.selection.range;if(r.isCollapsed()){const i=t.getBlockById(r.start.blockId);if(!tt(t,i))return!1;this.button.clearCheckedState(),this.button.show(o),this.event=e}return!1}}const DH={pasteSpecial:{originFormats:"\u4FDD\u6301\u539F\u6837\u5F0F",plainText:"\u7C98\u8D34\u7EAF\u6587\u672C",markdown:"\u7C98\u8D34\u4E3A Markdown"}},SH={pasteSpecial:{originFormats:"Keep origin formats",plainText:"Paste as plain text",markdown:"Paste as markdown"}},LH={pasteSpecial:{originFormats:"\u5143\u306E\u30B9\u30BF\u30A4\u30EB\u3092\u7DAD\u6301\u3059\u308B",plainText:"\u30D7\u30EC\u30FC\u30F3\u30C6\u30AD\u30B9\u30C8\u3092\u8CBC\u308A\u4ED8\u3051\u308B",markdown:"Markdown \u3068\u3057\u3066\u8CBC\u308A\u4ED8\u3051"}};R.mergeLang({"zh-CN":DH,"en-US":SH,"ja-JP":LH});const znt="",MH=S("html-to-doc");function RH(n){const t=new RegExp('(?<=<canvas data-editor-doc=")[\\s\\S]*(?=" id="ones-editor-doc">)',"g"),e=n.match(t);if(!e||!e.length)return null;const o=e[0],r=ga(o);return JSON.parse(r)}function OH(n){const t="ones-editor-doc::",e="::ones-editor-doc";let o=n.indexOf(t);if(o!==-1){o+=t.length;const i=n.indexOf(e,o);if(i!==-1){const s=n.substr(o,i-o);try{const l=ga(s);return JSON.parse(l)}catch(l){MH.error(`invalid doc data: ${l}, ${s}`)}}}const r=RH(n);return r||null}const K7="latex-b172fea480b",_H=n=>({name:"latex-block",level:"block",start(t){var e,o;return(o=(e=t.match(/\$\$[^\$]/))==null?void 0:e.index)!=null?o:-1},tokenizer(t,e){const o=/^\$\$([^\$]+)\$\$/.exec(t);return o?{type:"latex-block",raw:o[0],formula:o[1]}:void 0},renderer(t){return n.lazy?`<span class="${K7}" block>${t.formula}</span>`:n.render(t.formula,!0)}}),FH=n=>({name:"latex",level:"inline",start(t){var e,o;return(o=(e=t.match(/\$[^\$]/))==null?void 0:e.index)!=null?o:-1},tokenizer(t,e){const o=/^\$([^\$]+)\$/.exec(t);return o?{type:"latex",raw:o[0],formula:o[1]}:void 0},renderer(t){return n.lazy?`<span class="${K7}">${t.formula}</span>`:n.render(t.formula,!1)}});var PH=(n={})=>(n.lazy&&n.env!=="test"&&new IntersectionObserver((t,e)=>{for(const o of t){if(!o.isIntersecting)continue;const r=o.target;e.unobserve(r),Promise.resolve(n.render(r.innerText,r.hasAttribute("block"))).then(i=>{r.innerHTML=i}),r.classList.add("latex-rendered")}},{threshold:1}),{extensions:[_H(n),FH(n)]});function kc(n){const t=n.type;if(t==="link")return!!n.tokens.some(kc);switch(t){case"code":case"table":case"hr":case"blockquote":case"list":case"list_item":case"image":case"paragraph":return!0;default:return!1}}function NH(n){return!kc(n)}function $H(n){if(n.length===0)return[];if(n.length===1)return[n];const t=[];let e=[n[0]],o=kc(n[0]);for(let r=1;r<n.length;r++){const i=n[r];o===kc(i)?e.push(i):(t.push(e),e=[i],o=kc(i))}return t.push(e),t}function HH(n,t,e){const o=n.href;let r=e.tokensToText(n.tokens,t,e);return r.length===0&&(r=Oi(o,t)),r=hh(r,"link",o),r}let Mu;function a2(n){Mu||(Mu=document.createElement("textarea")),Mu.innerHTML=n;const t=Mu.childNodes.length===0?"":Mu.childNodes[0].nodeValue;return t!=null?t:""}function jH(n,t){const e=a2(n.text);return[co(e,{...t,"style-code":!0})]}function UH(n,t,e){const r=n.tokens;return r?e.tokensToText(r,t,e):ig(a2(n.text),t)}const zH=S("token-to-text");function u2(n,t,e){return n.map(r=>r.type==="text"?UH(r,t,e):r.type==="strong"?e.tokensToText(r.tokens,{...t,"style-bold":!0},e):r.type==="em"?e.tokensToText(r.tokens,{...t,"style-italic":!0},e):r.type==="del"?e.tokensToText(r.tokens,{...t,"style-strikethrough":!0},e):r.type==="link"?HH(r,t,e):r.type==="codespan"?jH(r,t):r.type==="br"?[{insert:" ",attributes:{id:K(),created:Date.now(),box:!0,type:"br"}}]:r.type==="escape"?ig(a2(r.text),t):r.type==="latex"?[{insert:" ",attributes:{id:K(),created:Date.now(),box:!0,type:"math",tex:r.formula}}]:(zH.warn(`unknown token in text: ${JSON.stringify(r)}`),[])).flat()}function VH(n,t){const e=u2(n.tokens,{},t);return[{id:K(),type:"text",text:e,heading:n.depth}]}function WH(n,t){const{text:e,children:o}=t.tokensToTextWithChildren(n.tokens,t),r=[];return e.length>0&&r.push({id:K(),type:"text",text:e}),r.push(...o),r}function qH(n,t){const{text:e,children:o}=t.tokensToTextWithChildren([n],t),r=[];return e.length>0&&r.push({id:K(),type:"text",text:e}),r.push(...o),r}function GH(n,t){const e=typeof n.start=="number"?n.start:1,o=n.ordered,r=K(),i=[];return n.items.forEach((l,a)=>{const d={...t,listLevel:t.listLevel+1},{text:h,children:p}=t.tokensToTextWithChildren(l.tokens,d);let A;typeof l.checked=="boolean"&&(A=l.checked?"checked":"unchecked");const v={id:K(),type:"list",groupId:r,ordered:o,checkbox:A,start:e+a,text:h,level:t.listLevel};i.push(v),i.push(...p)}),i}function ZH(n,t){const e=t.tokensToBlocks(n.tokens,t);return e.forEach(o=>{o.quoted=!0}),e}const X7=100,QH=20,YH=600;function JH(n,t){const e=t.text;if(e){const o=ie(e);return Math.min(qd(o,n)+QH,YH)}return X7}function ty(n,t){let e=X7;return t.forEach(o=>{e=Math.max(e,JH(n,o))}),e}function KH(n,t){var l,a;const e=n.header.length,o=n.rows.length+1,r=[],i=Array(e).fill(100);for(let d=0;d<o;d++){let h;d===0?h=n.header:h=n.rows[d-1];for(let p=0;p<e;p++){const A=h[p],v=(l=A==null?void 0:A.tokens)!=null?l:[],B=K();r.push(B);let D;if(v.length===0)D=[mh()];else if(kc(v[0]))D=t.tokensToBlocks(A.tokens,t),D.length===0&&D.push(mh());else{const{text:x,children:_}=t.tokensToTextWithChildren(A.tokens,t);D=[{id:K(),type:"text",text:x},..._]}t.doc.blocks[B]=D,i[p]=Math.max(i[p],ty((a=t.font)!=null?a:"",D))}}return[{id:K(),type:"table",cols:e,rows:o,colsWidth:i,children:r}]}function XH(n){return[{id:K(),type:"embed",embedType:"hr",embedData:{}}]}function tj(n,t){var a;const e=n.text;if(!e)return[];try{const d=n.text,h=ga(d),p=JSON.parse(h);if(p){const{root:A,...v}=p.blocks;return t.doc.blocks={...t.doc.blocks,...v},A}}catch{}const o=(a=n.lang)!=null?a:"Plain Text";if(o==="mermaid")return[{id:K(),type:"embed",embedType:"mermaid",embedData:{mermaidText:e}}];if(o==="plantuml")return[{id:K(),type:"embed",embedType:"plantuml",embedData:{plantumlText:e}}];if(o==="flow"||o==="flowchart")return[{id:K(),type:"embed",embedType:"flowchart",embedData:{flowchartText:e}}];const i=e.split(`
@@ -750,4 +750,4 @@ ${i.mermaidText}
750
750
  ${i.flowchartText}
751
751
  \`\`\`\`\`\``}return"[flowchart]"}const mG={embedType:"flowchart",convertFrom:dG,handleUpdateBlock:uG,createEmbedContent:aG,getBlockProperties:hG,convertTo:fG},gG=S("plantuml-helper");function sk(n,t){var l;let o=((l=(n.getComponentOptions("plantuml")||{}).cdn)==null?void 0:l.plantuml)||qq;o.endsWith("/")||(o+="/");const r=jB.default.encode(t);g(gG,r,r),o+=r;const s=new URLSearchParams(document.location.search).get("doc");return Em(o,{id:`${s}-${K()}`})}async function pG(n,t){try{const e=await H2(n,t);return(await n.doc.uploadResource(e)).resourceId}catch{return Promise.resolve(t)}}class Rc extends W2{constructor(t){super(t,"plantuml","plantumlText")}static get(t,e){return t.addCustom(`plantuml-${e.id}`,()=>new Rc(t))}code2ObjectUrl(t){return Promise.resolve(sk(this.editor,t))}code2ResourceId(t){const e=sk(this.editor,t);return pG(this.editor,e)}destroy(){}}function CG(n,t,e){Rc.get(n,e).createEmbedContent(t,e)}function AG(n,t,e){const o=Rc.get(n,e),r=Lt(t);return o.updateEmbedContent(r,e),!0}function bG(n,t,e){const{data:o}=e,r=n.getBlockString(t).trim();if(!o||o.embedType!=="plantuml"||r!=="```plantuml"||!tt(n,t))return null;const i={src:"",plantumlText:""};return{blockData:{id:K(),type:"embed",embedType:"plantuml",embedData:i},onConverted:(a,d)=>{Rc.get(a,a.getBlockData(d)).editGraph(Lt(d))}}}function vG(n,t){return Rc.get(n,n.getBlockData(t)).getBlockProperties(t)}function yG(n,t,e,o){const{embedData:r}=t,i=r;if(o==="html")return i.src?`<img src="${n.doc.buildResourceUrl(i.src,{withToken:!0})}" />`:i.flowchartText?`<div>${i.flowchartText}</div>`:"<p>[plantuml]</p>";if(o==="markdown"){if(i.src)return`![plantuml](${n.doc.buildResourceUrl(i.src,{withToken:!0})})`;if(i.flowchartText)return`\`\`\`plantuml\`\`\`
752
752
  ${i.flowchartText}
753
- \`\`\`\`\`\``}return"[plantuml]"}const kG={embedType:"plantuml",convertFrom:bG,handleUpdateBlock:AG,createEmbedContent:CG,getBlockProperties:vG,convertTo:yG},got="",wG="hr",BG={dividingLine:{type:"\u5206\u5272\u7EBF",abstract:"\u5206\u5272\u7EBF"}},EG={dividingLine:{type:"Separation line",abstract:"Separation line"}},xG={dividingLine:{type:"\u533A\u5207\u308A\u7DDA",abstract:"\u533A\u5207\u308A\u7DDA"}};R.mergeLang({"zh-CN":BG,"en-US":EG,"ja-JP":xG});function IG(n,t){const e=w("div",["editor-embed-container"],t);w("hr",["editor-embed-hr"],e)}function TG(n,t,e,o){return o==="html"?"<hr />":o==="markdown"?"---":"------------"}function DG(){return{name:"hr",insertEmbedCommandItems:[{id:"insert-hr",name:R.t("dividingLine.type"),icon:NL,order:500,group:"common",subText:An("insert-hr")}],handleInsertEmptyEmbed:async(n,t)=>{const{containerId:e,blockIndex:o}=t;return n.insertEmbed(e,o,wG,{})}}}function SG(n,t,e){const{data:o}=e;if(!o||o.embedType!=="dividing-line"||!tt(n,t))return null;const r={};return{blockData:{id:K(),type:"embed",embedType:"hr",embedData:r}}}function LG(){return{abstract:R.t("dividingLine.abstract")}}const MG={embedType:"hr",createEmbedContent:IG,convertTo:TG,getOptions:DG,convertFrom:SG,getBlockProperties:LG},pot="",Cot="",RG={media:{upload:{failed:'<div class="line-1">{name}\u4E0A\u4F20\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <span class="retry-upload">\u91CD\u8BD5</span></div>'},load:{failed:'<div class="line-1">{name}\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <span class="retry-upload">\u91CD\u8BD5</span></div>'},audio:{menuItem:"\u97F3\u9891",abstract:"\u97F3\u9891"},video:{menuItem:"\u89C6\u9891",abstract:"\u89C6\u9891"}}},OG={media:{upload:{failed:'<div class="line-1">{name} upload failed</div><div class="line-2">Network error, you can <span class="retry-upload">Retry</span></div>'},load:{failed:'<div class="line-1">{name} loading failed</div><div class="line-2">Network error, you can <span class="retry-upload">Retry</span></div>'},audio:{menuItem:"Audio",abstract:"Audio"},video:{menuItem:"Video",abstract:"Video"}}},_G={media:{upload:{failed:'<div class="line-1">{name}\u306E\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9\u306B\u5931\u6557\u3057\u307E\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <span class="retry-upload">\u518D\u8A66\u884C</span></div>'},load:{failed:'<div class="line-1">{name}\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <span class="retry-upload">\u518D\u8A66\u884C</span></div>'},audio:{menuItem:"\u97F3\u58F0",abstract:"\u97F3\u58F0"},video:{menuItem:"\u52D5\u753B",abstract:"\u52D5\u753B"}}};R.mergeLang({"zh-CN":RG,"en-US":OG,"ja-JP":_G});var qo=(n=>(n.AUDIO="audio",n.VIDEO="video",n))(qo||{}),$u=(n=>(n.Empty="empty",n.Progress="progress",n.Error="error",n))($u||{});const lk=10*1024*1024,FG=["wav","mp3","aac","ogg","webm","flac"],PG=["ogg","mp4","webm"],NG=()=>{};function ck(n){var h,p,A,v,B,D;const t=(h=n.getComponentOptions("media"))!=null?h:{},{allowedMedias:e,maxSize:o,callbacks:r}=t,i=(p=e==null?void 0:e.audio)!=null?p:FG,s=(A=e==null?void 0:e.video)!=null?A:PG,l=(v=o==null?void 0:o.audio)!=null?v:lk,a=(B=o==null?void 0:o.video)!=null?B:lk,d=(D=r==null?void 0:r.onError)!=null?D:NG;return{allowedMedias:{audio:i,video:s},maxSize:{audio:l,video:a},callbacks:{onError:d}}}function $G(n,t){const e=i=>i.map(s=>`.${s}`).join(","),{allowedMedias:o}=ck(n),r=o[t];return r?e(r):"*"}function HG(n,t,e){const{maxSize:o,callbacks:r,allowedMedias:i}=ck(t),{[e]:s}=o,{[e]:l}=i;if(s&&n.size>s){const d=new Error("media is too large");throw d.code=`MaxMediaSize-${e}`,r!=null&&r.onError&&(r==null||r.onError(t,d)),d}const a=Ca(n.name);if(l&&!l.includes(a)){const d=new Error(`media file is not allowed: ${a}`);throw d.code="NotAllowedFile",r!=null&&r.onError&&(r==null||r.onError(t,d)),d}}function jG(n){return n===$u.Empty||n===$u.Error}const Ne=S("media");class UG extends ve.TypedEmitter{constructor(e){super();m(this,"mediaContainer",null);m(this,"media",null);m(this,"abstract",null);m(this,"handleMediaLoadError",(e,o)=>{if(!o.target||!(o.target instanceof Node)||!(o.target instanceof Element?o.target:o.target.parentElement))return;const i=et(o.target);if(!i||!i.contains(this.mediaContainer))return;const s=this.renderError();this.updateMediaContent(s),this.emit("mediaError",e,"load_error",it(i))});m(this,"handleUploadFile",async e=>{g(Ne,this.abstract,"no abstract"),g(Ne,this.mediaContainer,"The media element not exist");const{editor:o}=this.options,r=et(this.mediaContainer);g(Ne,r,"The block element not exist");const i=o.getBlockData(r);try{const{resourceId:s}=await o.doc.uploadResource(e,{onProgress:p=>{this.renderProgress(p,e)}}),{name:l,type:a,size:d}=e,h={...i,embedData:{...i.embedData,src:s,fileName:l,fileSize:d,fileType:a}};o.updateBlockData(r,h)}catch(s){Ne.error(s),this.emit("mediaError",o,"upload_error",i.id),this.renderRetry(e)}ot(r,"media-block-uploading")});m(this,"destroy",()=>{this.mediaContainer=null});this.options=e}bindMediaEvent(){const{editor:e}=this.options;this.media&&e.domEvents.addEventListener(this.media,"error",this.handleMediaLoadError)}unbindMediaEvent(){const{editor:e}=this.options;this.media&&e.domEvents.removeEventListener(this.media,"error",this.handleMediaLoadError)}updateMediaContent(e){g(Ne,this.mediaContainer,"The media element not exist"),this.mediaContainer.innerHTML="",this.mediaContainer.append(e)}renderError(){g(Ne,this.abstract,"no abstract");const{editor:e,createMediaElement:o}=this.options,{mediaIcon:r,mediaName:i}=this.abstract;g(Ne,this.mediaContainer,"The media element not exist");const s=et(this.mediaContainer);g(Ne,s,"The block element not exist");const l=e.getBlockData(s),a=l.embedData.src,d=w("div",["media-error","embed-selected-content","embed-hover-content"],null),h=w("span",["media-error-icon"],d);h.innerHTML=r;const p=w("div",[],d);p.innerHTML=R.t("media.load.failed",{name:i}),d.appendChild(p);const A=p.querySelector(".retry-upload");return g(Ne,A,"The element not exist"),e.domEvents.addEventListener(A,"click",(v,B)=>{const D=w("div",["media-element"],null),x=this.getResourceUrl(a),_=o(v,D,l,x);this.unbindMediaEvent(),this.media=_,this.bindMediaEvent(),this.updateMediaContent(D)}),this.setFullScreen(),d}renderRetry(e){g(Ne,this.abstract,"no abstract");const{editor:o}=this.options,{mediaIcon:r,mediaName:i}=this.abstract,s=w("div",["media-error","embed-selected-content","embed-hover-content"],null),l=w("span",["media-error-icon"],s);l.innerHTML=r;const a=w("div",[],s);a.innerHTML=R.t("media.upload.failed",{name:i}),s.appendChild(a);const d=a.querySelector(".retry-upload");g(Ne,d,"The element not exist"),o.domEvents.addEventListener(d,"click",()=>{o.readonly||(g(Ne,this.abstract,"no abstract"),this.handleUploadFile(e))}),this.updateMediaContent(s),this.setFullScreen()}renderProgress(e,o){g(Ne,this.mediaContainer,"The media element not exist");const r=this.mediaContainer.querySelector(":scope .media-progress"),i=e===-1||e===100?100:e;if(r){const{updateProgressElement:s}=this.options;s(r,i)}else{const{createProgressElement:s}=this.options,l=et(this.mediaContainer);g(Ne,l,"The element not exist"),W(l,"media-block-uploading");const a=w("div",["media-progress"],null);s(a,i,o),this.updateMediaContent(a)}this.setFullScreen()}renderMediaElement(e){g(Ne,this.mediaContainer,"The media element not exist");const o=this.mediaContainer.querySelector(":scope > .media-element"),{createMediaElement:r,updateMediaElement:i,editor:s}=this.options,l=this.getResourceUrl(e.embedData.src);if(o){const a=i(s,o,e,l);this.unbindMediaEvent(),this.media=a,this.bindMediaEvent()}else{const a=w("div",["media-element"],null),d=r(s,a,e,l);this.unbindMediaEvent(),this.media=d,this.bindMediaEvent(),this.updateMediaContent(a)}}renderEmpty(e){g(Ne,this.abstract,"no abstract"),g(Ne,this.mediaContainer,"The media element not exist");const o=w("div",["media-empty","embed-selected-content","embed-hover-content"],this.mediaContainer);o.innerHTML=this.abstract.mediaIcon,this.updateMediaContent(o);const{editor:r}=this.options;r.findBlockById(e.id)&&this.emit("mediaError",r,"empty",e.id),this.setFullScreen()}getResourceUrl(e){const{editor:o}=this.options;return o.doc.buildResourceUrl(e)}setFullScreen(){g(Ne,this.mediaContainer,"The media element not exist"),W(this.mediaContainer,"full-screen")}removeFullScreen(){g(Ne,this.mediaContainer,"The media element not exist"),ot(this.mediaContainer,"full-screen")}updateBlockAlign(e,o){const r=et(o);g(Ne,r,"The block element not exist");const{align:i}=e;e.embedType==="video"&&(r.hasAttribute("data-style-align")&&r.removeAttribute("data-style-align"),r.setAttribute("data-style-align",i))}render(e,o){const{src:r}=e.embedData;(!this.mediaContainer||!o.contains(this.mediaContainer))&&(this.mediaContainer=w("div",["media"],o)),this.updateBlockAlign(e,o),jG(r)?r===$u.Empty&&this.renderEmpty(e):this.renderMediaElement(e)}setAbstract(e){this.abstract=e}}S("media-embed");const zG="left";class ak{constructor(){m(this,"handleInsertEmptyEmbed",async(t,e)=>{var p;const{containerId:o,blockIndex:r}=e;let i;(p=e.data)!=null&&p.file&&(i=e.data.file);const s=$G(t,this.embedType);if(i=i!=null?i:await Ul(s,{}),!i)return null;const{mediaType:l}=this.getAbstract();try{HG(i,t,l)}catch{return null}const a={id:K(),type:"embed",embedType:this.embedType,embedData:{src:$u.Empty}};l==="video"&&(a.align=zG);const d=t.insertBlock(o,r,a);return await this.getMedia(t,a.id).handleUploadFile(i),d})}getMedia(t,e){const o=t.addCustom(`media-${e}`,()=>new UG({editor:t,createMediaElement:this.createMediaElement,updateMediaElement:this.updateMediaElement,createProgressElement:this.createProgressElement,updateProgressElement:this.updateProgressElement}));return o.setAbstract({...this.getAbstract()}),o}getOptions(){const{menuItem:t,mediaIcon:e,mediaName:o,order:r,group:i}=this.getAbstract();return{name:o,insertEmbedCommandItems:[{id:`insert-${this.embedType}`,name:t,icon:e,order:r,group:i,subText:An(`insert-${this.embedType}`)}],handleInsertEmptyEmbed:this.handleInsertEmptyEmbed}}createEmbedContent(t,e,o){const{id:r}=o;this.getMedia(t,r).render(o,e)}handleUpdateBlock(t,e,o){const{id:r}=o,i=this.getMedia(t,r),s=Lt(e);return i.render(o,s),!0}handleDeleteBlock(t,e){const o=e.id,r=this.getMedia(t,o);r.removeAllListeners(),r.destroy()}convertTo(t,e,o,r){const i=e.embedData,s=t.doc.buildResourceUrl(i.src,{withToken:!0});return r==="html"?`<${i.type} src="${s}" />`:r==="markdown"?`![${i.src}](${s})`:s}}function uk(n,t){const e=w("div",["uploading-progress-mask"],n),o=w("div",["uploading-progress-bar"],e),r=w("div",["uploading-progress-bar-value"],o);r.style.width=`${t}%`}function dk(n,t){const e=n.querySelector(".uploading-progress-bar-value");e&&(e.style.width=`${t}%`)}const VG=S("media-audio");class WG extends ak{constructor(){super(...arguments);m(this,"embedType",qo.AUDIO);m(this,"updateProgressElement",dk);m(this,"createMediaElement",(e,o,r,i)=>{const s=w("div",["audio-container","embed-hover-content","embed-selected-content"],o),l=w("audio",[],s);return l.innerHTML="Your browser does not support the <code>audio</code> element.",l.controls=!0,l.src=i,setTimeout(()=>{this.getMedia(e,r.id).setFullScreen()}),l})}getAbstract(){return{mediaIcon:_L,mediaName:R.t(`media.${qo.AUDIO}.menuItem`),menuItem:R.t(`media.${qo.AUDIO}.menuItem`),order:800,mediaType:qo.AUDIO,group:"common"}}getBlockProperties(){return{abstract:`${R.t(`media.${qo.AUDIO}.abstract`)}`}}updateMediaElement(e,o,r,i){const s=o.querySelector(":scope .audio-container > audio");return g(VG,s,"The media element not exist"),s.src!==i&&(s.src=i),s}createProgressElement(e,o){const r=w("audio",[],e);r.innerHTML="Your browser does not support the <code>audio</code> element.",r.controls=!0,r.src="about:blank",uk(e,o)}}const qG=new WG;S("video-resizer");function hk(n){return n&&Me(n)&&fn(n)==="video"}const GG=50;class q2{constructor(t){m(this,"currentResizableElement",null);m(this,"resizing",!1);m(this,"handleHoveringBlockChange",(t,e)=>{if(!this.resizing&&!window.isDragging&&(e&&hk(e)&&this.disableBlockResize(e),t&&hk(t))){const o=this.getVideoElement(t);if(!o)return;this.enableBlockResize(t,o)}});m(this,"handleResizing",(t,e)=>{if(this.resizing=!0,!this.currentResizableElement)return;const o=t.getBlock();if(!o)return;const r=o.getBoundingClientRect().width,i=Math.min(Math.max(e.width,GG),r);this.currentResizableElement.style.width=`${i}px`,this.currentResizableElement.style.pointerEvents="none"});m(this,"handleResized",t=>{this.resizing=!1;const e=t.getBlock();if(!this.currentResizableElement||!e)return;const o=this.editor.getBlockData(e),{width:r}=this.currentResizableElement.getBoundingClientRect();this.currentResizableElement.style.pointerEvents="auto",this.editor.updateBlockData(e,{...o,width:r})});this.editor=t,Ce.get(t).addListener("change",this.handleHoveringBlockChange)}destroy(){this.currentResizableElement=null,Ce.get(this.editor).removeListener("change",this.handleHoveringBlockChange)}getVideoElement(t){return Lt(t).querySelector(":scope .video-container > video")}updateResizer(t){const e=this.editor.findCustom(`${it(t)}-resizer`);e&&e.updateResizer()}disableBlockResize(t){const e=this.editor.findCustom(`${it(t)}-resizer`);e&&e.disableResize()}enableBlockResize(t,e){const o=this.editor.addCustom(`${it(t)}-resizer`,()=>new Bu(this.editor,{resize:["top-left","top-right","bottom-left","bottom-right"]}));o.enableResize(t,e),o.removeListener("resizing",this.handleResizing),o.removeListener("resized",this.handleResized),o.addListener("resizing",this.handleResizing),o.addListener("resized",this.handleResized),this.currentResizableElement=e}}const ZG=S("video");class QG extends ak{constructor(){super(...arguments);m(this,"embedType",qo.VIDEO);m(this,"updateProgressElement",dk);m(this,"createMediaElement",(e,o,r,i)=>{const s=w("div",["video-container","embed-selected-content","drag-preview-element"],o),l=w("video",[],s);return l.innerHTML="Your browser does not support the <code>video</code> element.",l.controls=!0,l.src=i,l.addEventListener("canplay",()=>{e.addCustom("video-resizer",()=>new q2(e)),this.getMedia(e,r.id).removeListener("mediaError",this.handleMediaError),this.getMedia(e,r.id).addListener("mediaError",this.handleMediaError),this.getMedia(e,r.id).removeFullScreen()}),r.width&&(l.style.width=`${r.width}px`),l});m(this,"createProgressElement",(e,o,r)=>{const i=w("video",["progress-video"],e);i.innerHTML="Your browser does not support the <code>audio</code> element.",i.controls=!0,uk(e,o),jl(r).then(s=>{const l=e.querySelector(".progress-video");l&&$m(e)&&(l.src=s)})})}getAbstract(){return{mediaName:R.t(`media.${qo.VIDEO}.menuItem`),mediaIcon:FL,menuItem:R.t(`media.${qo.VIDEO}.menuItem`),order:700,mediaType:qo.VIDEO,group:"common"}}getBlockProperties(){return{abstract:`[${R.t(`media.${qo.VIDEO}.abstract`)}]`}}handleMediaError(e,o,r){const i=e.addCustom("video-resizer",()=>new q2(e)),s=e.getBlockById(r);i.disableBlockResize(s)}updateMediaElement(e,o,r,i){const s=o.querySelector(":scope .video-container > video");g(ZG,s,"The media element not exist"),s.src!==i&&(s.src=i),r.width?s.style.width=`${r.width}px`:s.style.width="";const l=e.getBlockById(r.id);return setTimeout(()=>{e.addCustom("video-resizer",()=>new q2(e)).updateResizer(l)}),s}}const YG=new QG,fk=[L0,j0,U0,B9],G2=[nk,JW,iG,mG,kG,$_,MG,YG,qG,xH,N8,Qz],mk=[_9,j8,c8];function JG(n,t,e){var r,i,s;const o=Ha(n,t,{components:{blocks:[...fk,...((r=e==null?void 0:e.components)==null?void 0:r.blocks)||[]],embeds:[...G2,...((i=e.components)==null?void 0:i.embeds)||[]],boxes:[...mk,...((s=e.components)==null?void 0:s.boxes)||[]],textRenders:[new g0],options:{...e.componentsOptions}}});return o.readonly=!0,o.addCustom("heading-collapse",()=>new R2(o)),o.addCustom("editor-tooltip",()=>new bf(o)),o.addListener("clickLink",(l,a,d)=>{var p;if((p=e==null?void 0:e.events)!=null&&p.onClickLink){e.events.onClickLink(l,a,d);return}const h=d.getAttribute("link");h&&(l.readonly||a.ctrlKey||a.metaKey)&&window.open(h,"_blank")}),o}class gk{constructor(t){this.createOptions=t,t.lang&&R.setLang(t.lang)}createHistoryEditor(t,e){return JG(t,e,this.createOptions)}}S("create-editor");function pk(n,{root:t,childDoc:e,doc:o}){var d,h;e.uploadResource=o.uploadResource.bind(o),e.buildResourceUrl=o.buildResourceUrl.bind(o);const r={image:{defaultAlign:"left"},toc:{showFirstBlock:!0}},i=[];n.editorBlocks.forEach(p=>{p.blockType==="text"||p.blockType==="embed"||i.push(p)});const s=[];n.editorEmbeds.forEach(p=>{s.push(p)});const l=[];n.editorBoxes.forEach(p=>{p.boxType==="text"||p.boxType==="br"||p.boxType==="image"||p.boxType==="anchor"||l.push(p)});const a=Ha(t,e,{shortcuts:[Mh],components:{blocks:i,commandProviders:[new tf],decorators:[new Df],embeds:s,boxes:l,options:r}});if(a.input.addHandler(new xf),a.input.addHandler(new c2(a)),a.input.addHandler(new f2(a)),a.input.addHandler(new tz(a)),a.input.addHandler(new Of),a.addCustom("image-paste-handler",()=>new l2(a)),(d=n.options.componentsOptions)!=null&&d.mention){const p=n.options.componentsOptions.mention;a.addCustom("mention",()=>new H8(a,{...p,enableFirstBlock:!0}))}if((h=n.options.componentsOptions)!=null&&h.comment){const p=n.options.componentsOptions.comment;p.onCommentEditorClick&&a.addListener("click",p.onCommentEditorClick)}return a}function KG(n,t){const e=Array.from(n.rootContainer.querySelectorAll(`[comment-${t.toLocaleLowerCase()}="${t}"]`)),o=new Set;e.forEach(r=>{const i=et(r);i&&o.add(i)}),o.forEach(r=>{ez(n,r,t)})}class XG{constructor(t){m(this,"listeners",new Set);m(this,"doc");this.editor=t,this.doc=this.editor.doc.externalDoc,this.doc.registerCallback(this)}getComments(){return this.doc.getComments()}getComment(t){return this.doc.getComment(t)}getCommentDoc(t){return this.doc.getCommentDoc(t)}localCreateComment(t,e){this.doc.localCreateComment(t,e)}localDeleteComment(t){const e=this.getComment(t);this.doc.localDeleteComment(t);const o=e.groupId;this.getComments().filter(i=>i.groupId===o).length===0&&KG(this.editor,o)}localUpdateComment(t,e){this.doc.localUpdateComment(t,e)}onCreateComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onCreateComment(t,e))}onDeleteComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onDeleteComment(t,e))}onUpdateComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onUpdateComment(t,e))}addListener(t){this.listeners.add(t)}removeListener(t){this.listeners.delete(t)}createCommentEditor(t,e){return pk(this.editor,{root:t,childDoc:e,doc:this.doc})}allowEdit(t){return t.userId===this.doc.getUser().userId}}class tZ{constructor(t,e){m(this,"listeners",new Set);this.editor=t,this.localDoc=e}get doc(){return this.localDoc.toJSON()}getComments(){return Object.values(this.doc.comments)}getComment(t){return this.doc.comments[t]}getCommentDoc(t){const e=this.doc.comments[t];return pp(e)}addListener(t){this.listeners.add(t)}removeListener(t){this.listeners.delete(t)}localCreateComment(t,e){}localDeleteComment(t){}localUpdateComment(t,e){}createCommentEditor(t,e){return pk(this.editor,{root:t,childDoc:e,doc:this.localDoc})}allowEdit(t){return t.userId===this.localDoc.getUser().userId}}const eZ={placeholder:{common:{title:"\u8BF7\u8F93\u5165\u6807\u9898",readonlyTitle:"\u8BF7\u8F93\u5165\u6807\u9898",content:"\u70B9\u51FB + \uFF0C\u6216\u8F93\u5165 / \u5FEB\u6377\u63D2\u5165\u7EC4\u4EF6",contentInTable:"\u8F93\u5165 / \u5FEB\u6377\u63D2\u5165\u7EC4\u4EF6"},local:{readonlyTitle:"\u672A\u547D\u540D"}},copyCutProperty:{copy:"\u590D\u5236",cut:"\u526A\u5207",unsafeEnvTips:"\u7531\u4E8E\u5F53\u524D http \u8BBF\u95EE\u73AF\u5883\u4E0B\u7684\u9650\u5236\uFF0C\u8BF7\u4F7F\u7528\u5FEB\u6377\u952E({shortCut}) {operation}"}},nZ={placeholder:{common:{title:"Enter a title",readonlyTitle:"Enter a title",content:"Click + or enter / to insert components quickly",contentInTable:"Enter / to insert components quickly"},local:{readonlyTitle:"Untitled"}},copyCutProperty:{copy:"Copy",cut:"Cut",unsafeEnvTips:"Due to the limitations of the current http access environment, please use the shortcut ({shortCut}) {operation}"}},oZ={placeholder:{common:{title:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",readonlyTitle:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",content:"\u300C+\u300D\u3092\u30AF\u30EA\u30C3\u30AF\u3059\u308B\u304B\u3001\u300C/\u300D\u3092\u5165\u529B\u3059\u308B\u3068\u3001\u30B3\u30F3\u30DD\u30FC\u30CD\u30F3\u30C8\u304C\u7D20\u65E9\u304F\u633F\u5165\u3067\u304D\u307E\u3059",contentInTable:"\u300C/\u300D\u3092\u5165\u529B\u3059\u308B\u3068\u3001\u30B3\u30F3\u30DD\u30FC\u30CD\u30F3\u30C8\u304C\u7D20\u65E9\u304F\u633F\u5165\u3067\u304D\u307E\u3059"},local:{readonlyTitle:"\u7121\u984C"}},copyCutProperty:{copy:"\u8907\u88FD",cut:"\u5207\u308B",unsafeEnvTips:"HTTP\u74B0\u5883\u306E\u5236\u7D04\u306B\u3088\u308A\u3001{operation}\u3059\u308B\u306B\u306F\u3001\u30B7\u30E7\u30FC\u30C8\u30AB\u30C3\u30C8({shortCut}) \u3092\u3054\u4F7F\u7528\u304F\u3060\u3055\u3044"}};R.mergeLang({"zh-CN":eZ,"en-US":nZ,"ja-JP":oZ});const rZ="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",iZ=()=>xm(rZ);async function sZ(n){return new Promise((t,e)=>{const o=new Image;o.onload=()=>{t({width:o.naturalWidth,height:o.naturalHeight})},o.onerror=e,o.src=n})}async function Ck(n,t){if(n.width&&n.height)return{width:n.width,height:n.height,buffer:t};const e=await jl(new File([t],"",{})),o=await sZ(e);return o.width===void 0||o.height===void 0?{width:345,height:230,buffer:t}:n.width||n.height?{width:n.width||o.width*n.height/o.height,height:n.height||o.height*n.width/o.width,buffer:t}:{width:o.width,height:o.height,buffer:t}}function lZ(n,t){let e=n.filter(s=>s!=null);const o=t-(e.length-1)*20,r=.87,i=e.reduce((s,l)=>s+l.width,0);return i>o&&(e=e.map(s=>({width:s.width*o/i,height:s.height*o/i,buffer:s.buffer}))),e.map(s=>({width:s.width*r,height:s.height*r,buffer:s.buffer}))}function Ak(n=[0,1,2,3,4,5,6,7],t=1){return n.map(e=>{let o;switch(e%3){case 0:o=gt.LevelFormat.DECIMAL;break;case 1:o=gt.LevelFormat.LOWER_LETTER;break;default:o=gt.LevelFormat.LOWER_ROMAN;break}return{level:e,format:o,text:`%${e+1}. `,alignment:gt.AlignmentType.START,start:t,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(e+1)),hanging:gt.convertInchesToTwip(.2)}}}}})}function cZ(){return[0,1,2,3,4,5,6,7].map(n=>{let t;switch(n%3){case 0:t="\u2022";break;case 1:t="\u25E6";break;default:t="\u25AA";break}return{level:n,format:gt.LevelFormat.BULLET,text:t,alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}})}function aZ(){return[0,1,2,3,4,5,6,7].map(n=>({level:n,format:gt.LevelFormat.BULLET,text:"\u2611",alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}))}function uZ(){return[0,1,2,3,4,5,6,7].map(n=>({level:n,format:gt.LevelFormat.BULLET,text:"\u2610",alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}))}var Hu=(n=>(n.NUMBERING="number-numbering-reference",n.BULLET="number-bullet-reference",n.CHECKED="checked-bullet-reference",n.UNCHECKED="unchecked-bullet-reference",n))(Hu||{});const dZ=[{levels:Ak(),reference:"number-numbering-reference"},{levels:cZ(),reference:"number-bullet-reference"},{levels:aZ(),reference:"checked-bullet-reference"},{levels:uZ(),reference:"unchecked-bullet-reference"}];function hZ(n){switch(n){case"style-color-0":return"d83931";case"style-color-1":return"de7802";case"style-color-2":return"dc9b04";case"style-color-3":return"2ea121";case"style-color-4":return"245bdb";case"style-color-5":return"6425d0";case"style-color-6":return"8f959e";default:return}}function fZ(n){switch(n){case"style-bg-color-1":case"style-bg-color-2":case"style-bg-color-8":case"style-bg-color-9":return"yellow";case"style-bg-color-0":case"style-bg-color-5":return"magenta";case"style-bg-color-3":return"green";case"style-bg-color-4":case"style-bg-color-11":return"blue";case"style-bg-color-6":return"lightGray";case"style-bg-color-7":return"red";case"style-bg-color-10":return"darkGreen";case"style-bg-color-12":return"darkMagenta";case"style-bg-color-13":return"darkGray";default:return}}function mZ(n){switch(n){case"style-bg-color-0":return"fbbab6";case"style-bg-color-1":return"ffdcb0";case"style-bg-color-2":return"fff7a0";case"style-bg-color-3":return"ceefc5";case"style-bg-color-4":return"d1ddfb";case"style-bg-color-5":return"d9cbf8";case"style-bg-color-6":return"eaeaea";case"style-bg-color-7":return"fe837c";case"style-bg-color-8":return"ffbd6a";case"style-bg-color-9":return"ffe662";case"style-bg-color-10":return"a8f393";case"style-bg-color-11":return"98b5ff";case"style-bg-color-12":return"b394f8";case"style-bg-color-13":return"b1b1b1";default:return}}const gZ=/rgb\((\d+),\s*(\d+),\s*(\d+)\)/;function bk(n){if(typeof n=="string"&&n.length>0){if(n[0]==="#")return n.substring(1);const t=n.match(gZ);if(t){const e=s=>{let l=Number(s).toString(16);return l.length<2&&(l=`0${l}`),l},o=e(t[1]),r=e(t[2]),i=e(t[3]);return`${o}${r}${i}`}if(n==="red")return"FF0000";if(n==="green")return"00FF00";if(n==="blue")return"0000FF"}}function tn(n,t){if(n&&n.attributes&&n.attributes[t])return n.attributes[t];if(n&&n.attributes&&n.attributes.box&&n.attributes.inputType&&t==="style-underline")return!0}function vk(n,t,e){for(let o=0;o<=e;++o){const r=`${t}${o}`;if(tn(n,r))return r}}function o1(n,t,e){n.attributes=n.attributes||{},n.attributes[t]=e}function Z2(n){return n==="image"||n==="drawio"||n==="plantuml"||n==="mermaid"||n==="flowchart"}function yk(n){return n&&n.startsWith("//")?`https:${n}`:n&&!n.startsWith("http://")&&!n.startsWith("https://")?`https://${n}`:n}function pZ(n){const t=tn(n,"inlineStyle");if(t==null)return;const e=t.split(";");for(const o of e){const r=o.split(":");if(r.length!==2)continue;const i=r[0].trim().toLowerCase(),s=r[1].trim().toLowerCase();i==="font-size"&&o1(n,"inline-style-font-size",s),i==="color"&&o1(n,"inline-style-color",s),i==="background-color"&&o1(n,"inline-style-background-color",s),i==="font-family"&&o1(n,"inline-style-font-family",s)}}function CZ(n,t){if(t==null)return n==null?void 0:n.normal;if(n)return n[`heading${t}`]}function AZ(n){const t=`${tn(n,"inline-style-font-size")}`;if(t&&t.indexOf("px")>0)return+t.replace(/px/g,"")}function bZ(n){if(n.attributes&&n.attributes.box&&n.attributes.text)return` ${n.attributes.text} `;if(n.attributes&&n.attributes.box&&n.attributes.inputType)return n.attributes.value?`${n.attributes.value}`:" "}function vZ(n){if(n.attributes&&n.attributes.box&&n.attributes.text)return` @${n.attributes.text} `}function yZ(n){return tn(n,"inline-style-font-family")}function kZ(n){const t=tn(n,"inline-style-background-color");return bk(t)}function wZ(n){const t=tn(n,"inline-style-color");return bk(t)}function BZ(n){pZ(n);const t=tn(n,"type")==="mention";return{box:n.attributes&&n.attributes.box?n.attributes:void 0,inlineCode:!!tn(n,"style-code"),link:yk(tn(n,"link")),size:AZ(n),text:t?vZ(n):bZ(n)||n.insert,bold:!!tn(n,"style-bold"),underline:!!tn(n,"style-underline"),italics:!!tn(n,"style-italic"),strike:!!tn(n,"style-strikethrough"),superScript:!!tn(n,"style-super"),subScript:!!tn(n,"style-sub"),math:tn(n,"type")==="math"?tn(n,"src"):void 0,mention:t,fontFamily:yZ(n),background:kZ(n),color:t?"338fe5":hZ(vk(n,"style-color-",6))||wZ(n),highlight:vk(n,"style-bg-color-",13)}}function EZ(){return[new gt.Paragraph({border:{top:{color:"auto",style:gt.BorderStyle.DASHED,size:4,space:1}},spacing:{before:300}}),new gt.Paragraph({spacing:{line:0}})]}function xZ(){return new gt.Paragraph({children:[new gt.TextRun({text:"[\u89C6\u9891\u6682\u4E0D\u652F\u6301\u5BFC\u51FA]",shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}})]})}function IZ(){return new gt.Paragraph({children:[new gt.TextRun({text:"[\u97F3\u9891\u6682\u4E0D\u652F\u6301\u5BFC\u51FA]",shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}})]})}function TZ(n,t){return new gt.Paragraph({children:[new gt.ExternalHyperlink({children:[new gt.TextRun({style:"Hyperlink",text:t||n})],link:n})]})}function kk(n){if(n.heading!=null)return`Heading${n.heading}`}function wk(n){if(n.alignment!=null){if(n.alignment==="center")return gt.AlignmentType.CENTER;if(n.alignment==="right")return gt.AlignmentType.RIGHT;if(n.alignment==="left")return gt.AlignmentType.LEFT}}function DZ(n){if(n.indent)return{left:gt.convertInchesToTwip(.3*n.indent-.2)};if(n.padding)return{left:gt.convertInchesToTwip(.3*n.padding)}}function SZ(n){return{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:n}}function LZ(n){const t=n.split(",");if(t.length!==0)return t[0].trim()}function Bk(n,t){let e;e=n.inlineCode?"InlineCode":void 0,e=n.link?"Hyperlink":e;const o=n.size||t,r=o!=null?Math.floor(o*1.5+.5):void 0;return new gt.TextRun({text:n.text,bold:n.bold||void 0,underline:n.underline?{type:gt.UnderlineType.SINGLE}:void 0,italics:n.italics||void 0,strike:n.strike||void 0,superScript:n.superScript||void 0,subScript:n.subScript||void 0,size:r,style:e,font:n.fontFamily?LZ(n.fontFamily):void 0,shading:n.background?SZ(n.background):void 0,color:n.color,highlight:fZ(n.highlight)})}function MZ(n,t){if(n.link)return new gt.ExternalHyperlink({children:[Bk(n,t)],link:n.link})}async function Ek(n,t,e,o,r){const i=await r(n,t,e);if(i==null)return;const s=await Ck({width:o||0,height:0,src:e},i);return new gt.ImageRun({data:i,transformation:{width:s.width||100,height:s.height||20}})}function RZ(n){if(n.heading||n.heading)return n.heading}function OZ(n){if(n.align&&(n.align==="center"||n.align==="right"||n.align==="left"))return n.align}function _Z(n){if(n.textOnly===!0&&n.level!=null)return n.level}async function FZ(n,t){var o;const e=[];if(n.text&&Array.isArray(n.text)){for(let r=0;r<n.text.length;r++){const i=n.text[r];if(((o=i.attributes)==null?void 0:o.box)===!0&&t){const s=await t(i);if(s){n.text.splice(r+1,0,...s);continue}}e.push(BZ(i))}return e}}function PZ(n){if(n.type==="list"&&n.textOnly!==!0)return{checkbox:n.checkbox,groupId:n.groupId,ordered:!!n.ordered,level:n.level||1,start:n.start||0}}function NZ(n,t){if(n.type==="embed"&&n.embedType&&Z2(n.embedType)&&n.embedData&&n.embedData.src)return n.embedData.src.split("|").map(o=>{const r=t(o),i=n.embedData[`${r}_width`],s=n.embedData[`${r}_height`];return{src:o,width:i,height:s}})}function $Z(n){if(n.padding)return n.padding}function HZ(n){return!!(n.type==="embed"&&n.embedType&&Z2(n.embedType)&&n.embedData&&n.embedData.src)}async function r1(n,t,e){return{quoted:!!n.quoted,heading:RZ(n),alignment:OZ(n),indent:_Z(n),padding:$Z(n),texts:await FZ(n,e),list:PZ(n),images:NZ(n,t),border:HZ(n)}}async function jZ(n,t,e,o){const r=[];if(!n.children)return[];for(const i of n.children){const s=[];for(const l of t.blocks[i])s.push(await r1(l,e,o));r.push(s)}return r}const UZ=S("to-docx");function zZ(n,t){return Array(n).fill(0).map(()=>Array(t).fill(0).map(()=>({cellId:void 0,color:void 0,from:void 0,rowSpan:1,colSpan:1,width:0,originalWidth:void 0,align:void 0})))}function VZ(n,t,e,o){const r=!!n.hasColTitle,i=!!n.hasRowTitle,s=!!n.isStripeStyle,l="F5F8FB";for(let a=0;a<t;a++)for(let d=0;d<e;d++)(r&&d===0||i&&a===0||s&&a%2===1)&&(o[a][d].color=l)}function WZ(n){g(UZ,n.children,"no table children");const t=n.rows,e=n.cols,o=n.colsWidth;if(o)for(let s=0;s<o.length;s++)o[s]===0&&(o[s]=100);const r=zZ(t,e);let i=0;for(let s=0;s<t;++s)for(let l=0;l<e;++l){if(r[s][l].originalWidth=o?o[l]:void 0,r[s][l].from!==void 0)continue;const a=n.children[i];i+=1,r[s][l].cellId=a,r[s][l].color=mZ(n[`${a}_background`]),r[s][l].width=o?o[l]:100,r[s][l].align=n[`${a}_align`];const d=n[`${a}_rowSpan`]||1,h=n[`${a}_colSpan`]||1;if(r[s][l].rowSpan=d,r[s][l].colSpan=h,d>1||h>1){let p=0;for(let A=0;A<d;A++)for(let v=0;v<h;v++)A===0&&(p+=o?o[l+v]:80),!(A===0&&v===0)&&(r[s+A][l+v].from=[s,l]);r[s][l].width=p}}return VZ(n,t,e,r),r}async function qZ(n,t,e,o,r,i,s,l,a,d){async function h(v){if(l){const B=await l(r,i,v);if(B){await o.addDoc(n,B,d);return}}if(v.type==="text"||v.textOnly===!0){const B=await r1(v,s,a);await o.addTextBlock(B);return}if(v.type==="code"){const B=await jZ(v,e,s,a);await o.addCodeBlockObject(B);return}if(v.type==="list"&&v.textOnly!==!0){const B=await r1(v,s,a);await o.addListBlockObject(n,B);return}if(v.type==="embed"&&v.embedType){const B=v,D=B.embedData,x=B.embedType;if(Z2(x)){const _=await r1(v,s,a);await o.addImagesBlockObject(v,_,d)}else v.embedType==="hr"?o.addSeparatorBlock():v.embedType==="video"?o.addVideoPlaceholder():v.embedType==="audio"?o.addAudioPlaceholder():v.embedType==="webpage"?o.addHyperlinkParagraph(yk(D.src),D.title):o.addOtherEmbedBlock(x,v.embedData);return}if(v.type==="table"){let B=[];if(v.colsWidth)B=v.colsWidth;else{const x=v.cols;B=new Array(x);for(let _=0;_<B.length;_++)B[_]=100;v.colsWidth=B}const D=WZ(v);await o.addTableMatrix(B,D,e),o.addEmptyParagraph()}}function p(v){const B=[];for(const{type:D,data:x}of v.embedData.exportSpec){if(D==="text"){const _={id:K(),text:[{insert:x}],type:"text"};B.push(_);continue}if(D==="image"){const _={id:K(),type:"embed",embedType:"image",align:"left",embedData:{src:x}};B.push(_);continue}if(D==="link"){const _={id:K(),type:"embed",embedType:"webpage",embedData:{src:x.url,title:x.title}};B.push(_);continue}}return B}function A(v){var B;return(B=v==null?void 0:v.embedData)!=null&&B.exportSpec?p(v):[v]}for(const v of t)for(const B of A(v))await h(B)}function GZ(){return{listMaxInst:1,listInstMap:{},listRefMap:{},levelConfigs:[]}}const ZZ=S("to-docx");class QZ{constructor(t,e,o,r,i,s){m(this,"paragraphs");this.appId=t,this.docId=e,this.state=o,this.readImageFunc=r,this.convertBlocksFunc=i,this.defaultFontSize=s,this.paragraphs=[]}async addTextBlock(t){this.paragraphs.push(new gt.Paragraph({heading:kk(t),alignment:wk(t),children:await this.paragraphsFromBlockTexts(t),indent:DZ(t)}))}async addEmptyImagePlaceHolder(){this.paragraphs.push(new gt.Paragraph({text:`[${R.t("docx.imageExportFailed")}]`,shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}}))}async paragraphsFromBlockTexts(t){if(t.texts==null)return;const e=CZ(this.defaultFontSize,t.heading),o=[];for(const r of t.texts){if(r.link){const i=MZ(r,e);i&&o.push(i);continue}if(r.box&&r.box.type&&r.box.type==="br"){o.push(new gt.TextRun({text:"",break:1}));continue}if(r.box&&r.box.type&&r.box.type==="image"){const i=await Ek(this.appId,this.docId,r.box.src,r.box.width,this.readImageFunc);i&&o.push(i);continue}if(r.math){const i=await Ek(this.appId,this.docId,r.math,0,this.readImageFunc);i&&o.push(i);continue}o.push(Bk(r,e))}return o}async addCodeBlockObject(t){for(const e of t)for(const o of e){const r={style:gt.BorderStyle.SINGLE,color:"#DEDEDE"};this.paragraphs.push(new gt.Paragraph({style:"Code",border:{left:{...r},right:{...r},top:{...r},bottom:{...r}},children:await this.paragraphsFromBlockTexts(o)}))}}async addListBlockObject(t,e){if(e.list==null)return;let o;const r=e.list.checkbox?`${t}-${e.list.groupId}-${e.list.checkbox}`:`${t}-${e.list.groupId}`;if(this.state.listInstMap[r])o=this.state.listInstMap[r];else if(o=this.state.listMaxInst,this.state.listMaxInst+=1,this.state.listInstMap[r]=o,e.list.start>0&&e.list.ordered){const s=`number-numbering-reference-${o}`,l=Ak([e.list.level-1],e.list.start);this.state.levelConfigs.push({levels:l,reference:s,inst:o}),this.state.listRefMap[r]=s}else e.list.ordered?this.state.listRefMap[r]=Hu.NUMBERING:e.list.checkbox&&e.list.checkbox==="checked"?this.state.listRefMap[r]=Hu.CHECKED:e.list.checkbox&&e.list.checkbox==="unchecked"?this.state.listRefMap[r]=Hu.UNCHECKED:this.state.listRefMap[r]=Hu.BULLET;const i=kk(e);e.texts&&this.paragraphs.push(new gt.Paragraph({heading:i,children:await this.paragraphsFromBlockTexts(e),numbering:{reference:this.state.listRefMap[r],level:e.list.level-1,instance:o}}))}imageDimWithBufferToImageRun(t){return new gt.ImageRun({data:t.buffer,transformation:{width:t.width,height:t.height}})}async addImagesBlockObject(t,e,o){if(e.images==null){if(t.type==="embed"&&t.embedType==="image"){const{src:a}=t.embedData;a||this.addEmptyImagePlaceHolder()}return}const r=[],i=await Promise.all(e.images.map(async a=>{const d=await this.readImageFunc(this.appId,this.docId,a.src);if(d)return Ck(a,d);r.push(a.src)})),s=lZ(i,o),l={style:gt.BorderStyle.SINGLE,color:"#DEDEDE"};s.length&&this.paragraphs.push(new gt.Paragraph({border:e.border?{left:{...l},right:{...l},top:{...l},bottom:{...l}}:void 0,alignment:wk(e)||gt.AlignmentType.CENTER,children:s.map(a=>this.imageDimWithBufferToImageRun(a)).flatMap((a,d,h)=>a==null?[]:h.length-1!==d?[a,new gt.TextRun({text:" "})]:a)})),r.forEach(a=>{this.addHyperlinkParagraph(a)})}addSeparatorBlock(){EZ().forEach(t=>this.paragraphs.push(t))}addEmptyParagraph(){this.paragraphs.push(new gt.Paragraph(""))}addVideoPlaceholder(){this.paragraphs.push(xZ())}addAudioPlaceholder(){this.paragraphs.push(IZ())}addHyperlinkParagraph(t,e){t!=null&&this.paragraphs.push(TZ(t,e))}async addTableMatrix(t,e,o){const r=t.map(i=>i!==0?i*15:1500);this.paragraphs.push(new gt.Table({rows:await this.generateTableRows(e,o),columnWidths:r}))}async generateRowCells(t,e){const o=[];for(const r of t){const i=r.cellId;if(i===void 0)continue;const s=r.width*.9;o.push(new gt.TableCell({children:await this.convertBlocksFunc(i,e.blocks[i],e,this.appId,this.docId,this.state,s),columnSpan:r.colSpan,rowSpan:r.rowSpan,width:{type:gt.WidthType.DXA,size:r.width*15},shading:r.color?{fill:r.color,type:gt.ShadingType.CLEAR,color:"auto"}:void 0}))}return o}async generateTableRows(t,e){const o=[];for(const r of t)o.push(new gt.TableRow({children:await this.generateRowCells(r,e)}));return o}async addDoc(t,e,o){const r=await this.convertBlocksFunc(t,e.blocks.root,e,this.appId,this.docId,this.state,o);r&&(this.paragraphs=this.paragraphs.concat(r))}async addOtherEmbedBlock(){}}class YZ{constructor(t,e,o,r,i,s,l,a){m(this,"convertBlocks",async(t,e,o,r,i,s,l=720)=>{const a=new QZ(r,i,s,this.readImage,this.convertBlocks,this.defaultFontSize);return await qZ(t,e,o,a,r,i,this.md5HexFunc,this.getDocByBlock,this.getTextsByBox,l||720),a.paragraphs});this.templateData=t,this.docData=e,this.md5HexFunc=o,this.readImage=r,this.defaultFontSize=i,this.getDocByBlock=s,this.getTextsByBox=l,this.backgroundImageOptions=a}async convert(t,e){return this.snapshot2docx(this.docData,t,e)}async snapshot2docx(t,e,o){const r=new gt.ImportDotx,i=this.templateData?await r.extract(this.templateData):void 0,s=t.blocks.root;g(ZZ,s,"data must have blocks");const l=GZ(),a=await this.convertBlocks("blocks",s,t,e,o,l),d=this.backgroundImageOptions?{default:new gt.Header({children:[new gt.Paragraph({children:[new gt.ImageRun(this.backgroundImageOptions)]})]})}:{},h=new gt.Document({numbering:{config:[...dZ,...l.levelConfigs]},sections:[{headers:d,children:a,properties:{page:{size:{width:12240,height:15840},margin:{top:1440,bottom:1440,left:1440,right:1440}}}}]},{template:i});return gt.Packer.toBlob(h)}}async function JZ(n,t,e,o){const r=n.doc.buildResourceUrl(o,{withToken:!0});let i=await p7(r);if(!i)return;if(i.type.indexOf("/svg")!==-1){const l=await f7(i);l&&(i=new File([l],i.name))}return await i.arrayBuffer()}async function KZ(n,t,e){const o=n.editorBlocks.getBlockClass(e.type);if(o.toStandardDoc)return o.toStandardDoc(n,e,t)}async function XZ(n,t){const e=t.attributes,o=n.editorBoxes.getBoxClass(e.type);if(o.toStandardText)return o.toStandardText(n,e)}async function tQ(n,t){let{template:e,download:o,backgroundImageOptions:r}=t!=null?t:{};e||(e=iZ());const i=n.doc.toJSON(),s=(p,A,v)=>JZ(n,p,A,v),l=async(p,A,v)=>KZ(n,i,v),a=async p=>XZ(n,p),h=await new YZ(e,i,Pd.default,s,void 0,l,a,r).convert("_appId","_docId");if(o){const p=URL.createObjectURL(h),A=document.createElement("a");A.setAttribute("download",`${g7(n)}.docx`),A.setAttribute("href",`${p}`),A.click(),A.remove()}return h}const Q2=S("create-editor");async function eQ(n,t){var s,l,a,d,h,p,A,v,B,D,x,_,M,H;g(Q2,n,"app does not exists"),t.lang&&R.setLang(t.lang),Di.level=(s=t.logLevel)!=null?s:ua.DEBUG;const e=t.onReauth?async()=>{var ft;const z=t.user.userId,q=t.docId,rt=await((ft=t.onReauth)==null?void 0:ft.call(t,z,q,t.permission));return{userId:z,docId:q,permission:t.permission,appId:t.appId,token:rt,displayName:t.user.displayName,avatarUrl:t.user.avatarUrl}}:void 0,o={auth:{appId:t.appId,docId:t.docId,userId:t.user.userId,permission:t.permission,token:t.token,displayName:t.user.displayName,avatarUrl:t.user.avatarUrl},serverUrl:t.serverUrl,reauthFunc:e,disableLogout:t.disableLogout},r=await Ka.load(o),i=Ha(n,r,{id:t.id,scrollContainer:t==null?void 0:t.scrollContainer,enableComments:t==null?void 0:t.enableComments,components:{blocks:[...fk,...((l=t==null?void 0:t.components)==null?void 0:l.blocks)||[]],embeds:[...G2,...((a=t.components)==null?void 0:a.embeds)||[]],boxes:[...mk,...((d=t.components)==null?void 0:d.boxes)||[]],commandProviders:[new tf,...((h=t.components)==null?void 0:h.commandProviders)||[]],decorators:[new Df,new Ap],insertions:[bg],blockHooks:[new e2,new V7,...((p=t.components)==null?void 0:p.blockHooks)||[]],textRenders:[new e8,new g0],options:{...t.componentsOptions}},shortcuts:[bz,EN,fH,M0,Ly,IO,I0,eV,Mh,...t.shortcuts||[]],colors:["#338FE5","#24B47E","#F0A100","#E52727","#9678D3","#2CB2AE","#EB6414","#8AAB3F"]});if(i.editorCommandProviders.registerCommandProvider(new vr(i)),i.input.addHandler(new WV),i.input.addHandler(new xf),i.input.addHandler(new V_),i.input.addHandler(new cH),i.input.addHandler(new vu(i,{headingLevel:1,titlePlaceholder:R.t("placeholder.common.title"),contentPlaceholder:R.t("placeholder.common.content"),readonlyTitlePlaceholder:R.t("placeholder.common.readonlyTitle"),addPlaceholderToAllCurrentEmptyBlock:!0})),i.input.addHandler(new Af(i,(A=t.componentsOptions)==null?void 0:A.quickMenu)),i.input.addHandler(new c2(i)),i.input.addHandler(new f2(i)),i.input.addHandler(new yN),i.input.addHandler(new Of),i.doc.registerCallback(new qV(i)),i.addCustom("remote-cursor",()=>new qb(i)),i.addCustom("block-menu",z=>new G7(z)),i.addCustom("editor-tooltip",()=>new bf(i)),t!=null&&t.enableComments&&i.addCustom("editor-comments",z=>new t8(z,new XG(z))),i.addCustom("create-options",()=>new Y5(i,t)),i.addCustom("drop-target",()=>new Lu(i)),i.addCustom("list-to-mindmap",()=>new hf(i)),i.addCustom("list-to-mention",()=>new hW(i)),i.addCustom("mobile-helper",()=>new DW(i)),i.addCustom("code-caret",()=>new vN(i)),i.addCustom("image-paste-handler",()=>new l2(i)),(v=t.componentsOptions)!=null&&v.mention){const z=t.componentsOptions.mention;i.addCustom("mention",()=>new H8(i,z))}if(i.addCustom("heading-collapse",()=>new R2(i)),gc.register(i),Lu.register(i),ts.register(i),Ji.register(i),i.addListener("clickLink",(z,q,rt)=>{var Bt;if((Bt=t==null?void 0:t.events)!=null&&Bt.onClickLink){t.events.onClickLink(z,q,rt);return}const ft=rt.getAttribute("link");ft&&(z.readonly||q.ctrlKey||q.metaKey)&&window.open(ft,"_blank")}),(D=(B=t.componentsOptions)==null?void 0:B.remoteCarets)!=null&&D.onUserChanged){const z=(_=(x=t.componentsOptions)==null?void 0:x.remoteCarets)==null?void 0:_.onUserChanged;i.doc.getRemoteUsers().on("change",q=>{z(i,q)})}return(H=(M=t.componentsOptions)==null?void 0:M.templates)!=null&&H.templates.length&&(i.addListener("docChanged",()=>{e1(i)}),i.addListener("resize",()=>{e1(i,{reset:!0})}),setTimeout(()=>{e1(i)},100)),i.doc.registerCallback({onError:async z=>{if(z.code==="ResetDoc"){Q2.error(`reset doc: ${z.message}`);const q=await Ka.load(o);i.doc.reset(q)}}}),i}function nQ(n){return n.toJSON!==void 0}async function oQ(n,t,e){var i,s,l,a,d;g(Q2,n,"app does not exists");const o=nQ(t)?t:new Xg(t,{serverUrl:e.serverUrl||""});e.lang&&R.setLang(e.lang);const r=Ha(n,o,{id:e.id,scrollContainer:e==null?void 0:e.scrollContainer,components:{blocks:[L0,j0,U0,B9],commandProviders:[new tf],decorators:[new Df,new Ap],embeds:[...G2,...((i=e.components)==null?void 0:i.embeds)||[]],boxes:[_9,j8,c8,...((s=e.components)==null?void 0:s.boxes)||[]],insertions:[bg],blockHooks:[new e2,...((l=e.components)==null?void 0:l.blockHooks)||[]],textRenders:[new e8,new g0,...((a=e.components)==null?void 0:a.textRenders)||[]],options:{...e.componentsOptions}},shortcuts:[M0,Ly,I0,Mh]});return r.editorCommandProviders.registerCommandProvider(new vr(r)),r.input.addHandler(new xf),r.input.addHandler(new vu(r,{headingLevel:1,titlePlaceholder:R.t("placeholder.common.title"),contentPlaceholder:R.t("placeholder.common.content"),readonlyTitlePlaceholder:R.t("placeholder.local.readonlyTitle"),addPlaceholderToAllCurrentEmptyBlock:!0})),r.input.addHandler(new Af(r,(d=e.componentsOptions)==null?void 0:d.quickMenu)),r.input.addHandler(new c2(r)),r.input.addHandler(new f2(r)),r.input.addHandler(new Of),r.addCustom("block-menu",h=>new G7(h)),r.addCustom("editor-tooltip",()=>new bf(r)),r.addCustom("image-paste-handler",()=>new l2(r)),e!=null&&e.enableComments&&r.addCustom("editor-comments",h=>new t8(h,new tZ(h,o))),r.addCustom("heading-collapse",()=>new R2(r)),r.addListener("clickLink",(h,p,A)=>{var B;if((B=e==null?void 0:e.events)!=null&&B.onClickLink){e.events.onClickLink(h,p,A);return}const v=A.getAttribute("link");v&&(h.readonly||p.ctrlKey||p.metaKey)&&window.open(v,"_blank")}),gc.register(r),r}function rQ(n,t){var a;const e=n.doc;if(!((a=e.getVersionHelper)==null?void 0:a.call(e)))throw new Error("the editor does not support to show versions");const r=n.getCustom("create-options");if(!r)throw new Error("the editor does not support to show versions");const i=r.getData(),s=new gk(i),l=n.addCustom("version-dialog",()=>new E8(n.doc,s));return l.show(t),l}b.tippy=PB,b.AnchorBox=C6,b.AuthError=Wh,b.AuthHeader=Ja,b.AutoScroll=Qd,b.BaseURLHeader=qh,b.BasicCommands=g_,b.BlockExclusiveHook=V7,b.BlockLockerHook=e2,b.BlockLockerPasteHandler=Of,b.BlockResizer=Bu,b.BrBox=f6,b.CodeBlock=j0,b.CodeLineBlock=U0,b.CodeTextDecorator=Df,b.DefaultShortcuts=Mh,b.DocIdError=NS,b.DragDrop=uC,b.DrawioEmbed=nk,b.EditorBlocks=b4,b.EditorBoxes=g6,b.EditorCommandProviders=rb,b.EditorComplexBlockPosition=Mo,b.EditorComplexSelectionRange=ir,b.EditorDecorators=y6,b.EditorEmbeds=y4,b.EditorInsertions=v6,b.EditorSimpleBlockPosition=je,b.EditorSimpleSelectionRange=Ye,b.EmbedBlock=w4,b.EmbedBlockResizer=Pu,b.EnforceWithDocumentTitleHandler=vu,b.EventCallbacks=da,b.FILL_CHAR=sI,b.FileExtError=$S,b.GroupOrder=T9,b.HeadingBlockScrollListener=sW,b.ImageBox=p6,b.InlineBoxCommandProvider=F9,b.InputtingInsertion=A6,b.LocalDoc=Xg,b.LogLevel=ua,b.Logger=Di,b.MIN_DISTANCE_THRESHOLD=cC,b.ManualCloseDialog=ru,b.ManualMenu=Us,b.ManualToolbar=ou,b.MarkdownInputHandler=xf,b.MaxUserError=dp,b.Mindmap=d0,b.OnesEditorAutoSuggest=Fp,b.OnesEditorCustomDataWrapper=Y5,b.OnesEditorExclusiveBlock=Ji,b.OnesEditorHoveringBlock=Ce,b.OnesEditorQuickMenu=Af,b.OnesEditorToc=Nu,b.OnesEditorTocProvider=ts,b.OnesEditorToolbar=gc,b.OnesEditorTooltip=bf,b.OnesEditorVersionsDialog=E8,b.PermissionError=PS,b.Popup=Xa,b.RemoteCarets=qb,b.RemoteCaretsDecorator=Ap,b.RemoteCaretsInsertion=bg,b.RemoteUsers=Ph,b.RequestReloadError=Ya,b.RichText=ln,b.ShareDBDoc=Ka,b.ShareDBDocVersionsProvider=gk,b.SimpleCache=K5,b.StandardEmbedBlockCommands=I2,b.TEXT_STYLE_BACKGROUND_COLOR_PREFIX=ag,b.TEXT_STYLE_COLOR_PREFIX=cg,b.TableBlock=L0,b.TableBlockCommandProvider=tf,b.TableShortcuts=M0,b.TextBlock=Dn,b.TextBox=h6,b.TextStyleShortcuts=I0,b.TocEmbed=N8,b.ZERO_WIDTH_SPACE_CHAR=ha,b.abbreviation=Yd,b.addAttribute=hh,b.addClass=W,b.addCommentToBlock=Jf,b.addDays=xE,b.addMetaToDoc=Oh,b.addMonths=EE,b.animateScrollTo=vm,b.applyPlaceholderToBlock=If,b.assert=g,b.autoShowHideTemplates=e1,b.blockToDoc=Qg,b.blockToHtml=wg,b.blockToMarkdown=Bg,b.blockToText=vh,b.blocksToDoc=ET,b.clearAllSelection=t4,b.clientType=Ze,b.cloneBlock=Fi,b.cloneChildContainer=Og,b.cloneDoc=_g,b.cloneText=n6,b.commentToShareDbComment=Cp,b.compareElement=jd,b.comparePosition=Qm,b.complexBlockAdjustSelectionPos=rh,b.complexBlockFindNearestChildBlock=I4,b.complexBlockGeFirstSimpleChild=Jm,b.complexBlockGetAllChildContainers=gn,b.complexBlockGetBottomChildContainers=x4,b.complexBlockGetLastSimpleChild=zl,b.complexBlockGetSelectedContainers=Ms,b.complexBlockGetTopChildContainers=E4,b.containerToDoc=OA,b.continuousScroll=TC,b.convertBlockFrom=th,b.convertImageFileToPng=f7,b.convertImageSrcToPng=zP,b.copyBlockAttributes=O6,b.createBlockAnchor=zr,b.createBlockCaretAnchor=L4,b.createBlockContentElement=xs,b.createBlockElement=zC,b.createBlockSimpleDocRange=ph,b.createBlockSimpleRange=ke,b.createBoxContentElement=qC,b.createBoxElement=VC,b.createBoxOp=G4,b.createChildContainer=C4,b.createComplexBlockPosition=me,b.createComplexDocPos=c6,b.createComplexDocRange=aI,b.createContainer=i6,b.createContainerElement=Vm,b.createDeleteOps=z4,b.createEditor=Ha,b.createEditorSelectionRange=Ue,b.createElement=w,b.createEmptyContainer=qr,b.createEmptyDoc=Wr,b.createEmptyTextBlockData=mh,b.createExpandedRange=$d,b.createIconButton=$l,b.createImage=gm,b.createInsertOps=uh,b.createInsertionContentElement=QC,b.createInsertionElement=GC,b.createLocalEditor=oQ,b.createOnesEditor=eQ,b.createRange=X5,b.createRichText=Oi,b.createRootContainer=p4,b.createSimpleBlockPosition=st,b.createSimpleDocPos=l6,b.createTextBlockData=cr,b.createTextButton=Zs,b.createTextOp=co,b.createTextWithReplaceSoftReturn=ig,b.daysAfter=Sm,b.deleteText=lg,b.diffDays=IE,b.disablePageScroll=kC,b.docToHtml=D6,b.docToHtmlFragment=yh,b.docToMarkdown=Ma,b.docToText=La,b.downloadImageToFile=p7,b.downloadObjectToFile=H2,b.downloadSvgToString=G8,b.editLink=gu,b.editorAddComment=oz,b.editorAddTextAttribute=W6,b.editorAutoInsertBlock=_6,b.editorBreakTextBlock=Ql,b.editorClearCompositionText=R6,b.editorClearSelectedContents=Mg,b.editorCopyBlock=_h,b.editorDeleteBlock=Sg,b.editorDeleteBlockText=Tg,b.editorDeleteBlockWithoutChildren=Bh,b.editorDeleteChildContainer=oT,b.editorDeleteChildContainers=F6,b.editorFocusToBlock=Rg,b.editorFocusToEnd=wT,b.editorGetBlockData=_i,b.editorGetBlockText=pn,b.editorGetBlockTextEx=Ah,b.editorGetBoxData=u6,b.editorHandleKeyboardEvent=NA,b.editorInsertBlock=Zl,b.editorInsertBoxToBlock=L6,b.editorInsertDoc=z6,b.editorInsertDocAt=Fg,b.editorInsertText=Ig,b.editorInsertTextToBlock=S6,b.editorInsertTextToBlockEx=xg,b.editorMergeTextBlock=P6,b.editorMoveDown=oA,b.editorMoveEnd=Vg,b.editorMoveHome=fA,b.editorMoveLeft=tA,b.editorMoveLineEnd=yA,b.editorMoveLineHome=vA,b.editorMovePageDown=IA,b.editorMovePageUp=xA,b.editorMoveRight=eA,b.editorMoveUp=nA,b.editorMoveWordEnd=uA,b.editorMoveWordLeft=aA,b.editorRangeClearColor=G6,b.editorRangeGetColor=Pg,b.editorRangeSetColor=q6,b.editorRemoveTextAttribute=lT,b.editorReplaceBlockText=xh,b.editorReplaceContainer=V6,b.editorRunOnce=tp,b.editorSelectAll=MA,b.editorSelectContainer=Gg,b.editorSelectDown=rA,b.editorSelectEnd=Wg,b.editorSelectHome=mA,b.editorSelectLeft=iA,b.editorSelectLineEnd=bA,b.editorSelectLineHome=AA,b.editorSelectPageDown=DA,b.editorSelectPageUp=TA,b.editorSelectRight=sA,b.editorSelectUp=lA,b.editorSelectWordEnd=hA,b.editorSelectWordLeft=dA,b.editorSetTextColor=Yl,b.editorShowFindDialog=aU,b.editorToDocx=tQ,b.editorUpdateBlockData=Ih,b.editorUpdateCompositionText=M6,b.editorUpdateEmbedData=j6,b.enablePageScroll=wC,b.escapeHtmlText=iC,b.escapeRegExp=Om,b.escapeSpace=aE,b.exclusiveBlock=K0,b.executeBlockCommand=a4,b.executeEmbedBlockCommand=c4,b.executeRangeCommand=ob,b.fileToDataUrl=jl,b.findAfterOffsetNotType=pg,b.findAllText=fg,b.findEventTargetBlock=oC,b.findInsertionById=ZC,b.findNextOffset=xI,b.findNextVisibleSimpleBlock=ab,b.findPrevOffset=EI,b.findPrevOffsetNotType=gg,b.findPrevSimpleBlockBeforeChildContainer=B4,b.findPrevVisibleSimpleBlock=cb,b.findTarget=Hl,b.findWordEnd=Ag,b.findWordLeft=Cg,b.format=Aa,b.formatBytes=DC,b.formatDate=Mm,b.fragmentToHtml=BC,b.fromBase64=ga,b.fromBase64ToBlob=xm,b.fromBase64ToUint8Array=vE,b.fromDocRange=Mi,b.fromNowString=Rm,b.genId=K,b.getAllChildBlocks=Xm,b.getAllQuickMenuItems=x0,b.getAllSelectedBlocks=Ro,b.getAttributesAt=Ta,b.getBlockBackground=UC,b.getBlockByIndex=Fr,b.getBlockCaretRect=So,b.getBlockClass=Qt,b.getBlockClassByType=Ss,b.getBlockClientRects=Nr,b.getBlockCommandsWithHook=Um,b.getBlockContent=Lt,b.getBlockId=it,b.getBlockIndex=bt,b.getBlockInfo=Tu,b.getBlockKind=Do,b.getBlockMinWidth=n4,b.getBlockNearestRangeFromPoint=S4,b.getBlockOptions=NE,b.getBlockPath=Li,b.getBlockProperties=i4,b.getBlockRangeFromPoint=ih,b.getBlockStyles=PE,b.getBlockTextLength=ut,b.getBlockTools=te,b.getBlockType=Dt,b.getBoxContent=Pm,b.getBoxId=WC,b.getBoxTypeFromElement=ba,b.getChildBlockCount=Io,b.getChildBlocks=fe,b.getChildOffset=Os,b.getColorFromAttributes=dg,b.getColorFromContent=Jd,b.getComplexBlockClass=zn,b.getContainerBlockPath=f4,b.getContainerBlocks=XC,b.getContainerBlocksElement=nh,b.getContainerById=jr,b.getContainerId=ct,b.getContainerMinWidth=qm,b.getContainerToolsElement=zE,b.getContainerWidth=A4,b.getDistanceSquare=nr,b.getElementOffset=fa,b.getElementScale=vs,b.getEmbedType=fn,b.getExistsBlockTools=Xd,b.getExistsContainerById=h4,b.getFileExt=Ca,b.getFirstChildBlock=ye,b.getFirstClientRect=Hd,b.getHeadingMenuOptions=k0,b.getHorizontalPadding=pm,b.getInsertionContent=Nm,b.getLastChildBlock=Qe,b.getLastClientRect=As,b.getListAllNextBrothers=uc,b.getLogger=S,b.getNextBlock=Zt,b.getNextValidOffset=_s,b.getNextVisibleBlock=Ts,b.getOffsetInfoAfter=Sa,b.getOffsetInfoBefore=bh,b.getOpAt=Q4,b.getOpLength=dh,b.getParentBlock=et,b.getParentBlockExcludeSelf=Es,b.getParentBox=Fm,b.getParentContainer=nt,b.getPrevBlock=ce,b.getPrevValidOffset=Ri,b.getPrevVisibleBlock=Is,b.getRangeCommands=eb,b.getRootBlock=jm,b.getScrollContainer=ro,b.getSpecialBlockCommands=s4,b.getStandardEmbedBlockProperties=T2,b.getTextAfterOffset=wI,b.getTextAttributes=Eg,b.getTextBeforeOffset=BI,b.getTextBlockChild=eh,b.getTextBlockClass=JC,b.getTextBlockContentChildTextLength=lo,b.getTextBlockContentChildType=u4,b.getTextBlockContentChildren=rr,b.getTextLength=rn,b.getTextOpLength=tg,b.getTextWidth=qd,b.getToolbar=lf,b.handleBlockElementUpdated=o4,b.hasAltOnly=gE,b.hasClass=xt,b.hasCtrlOrCmd=CC,b.hasCtrlOrCmdOnly=mE,b.hashCode=FC,b.hideBlock=HC,b.htmlToFragment=Wd,b.i18n=R,b.injectDocToHtmlFragment=Rh,b.injectStyle=lC,b.insertEmptyBlock=jE,b.insertEmptyEmbedBlock=zm,b.insertText=Vr,b.intersectionCommands=SD,b.isBackspace=bC,b.isBlock=Bs,b.isBlockLocked=Rf,b.isBlockLockedByOthers=t2,b.isBlockLockedBySelf=Du,b.isBlockTools=$C,b.isBox=_m,b.isCJK=mC,b.isChildContainer=Lo,b.isChildNode=Xt,b.isCollapsedRange=cI,b.isComplexBlockPosition=Zm,b.isComplexKindBlock=Mt,b.isContainer=Pr,b.isContainerSelectedAllChildBlocks=SA,b.isControlEvent=ks,b.isDelete=CE,b.isDraggingFiles=Gd,b.isElementVisible=bm,b.isEmbedBlock=Me,b.isEmptyContainer=wa,b.isEmptyDoc=mg,b.isEmptyTextBlock=ae,b.isEmptyTextBlockWithoutCompositionText=bu,b.isEnterOnly=AC,b.isEscape=Bm,b.isExclusiveBlock=Mf,b.isFirefox=Vd,b.isFirstChildBlockInComplexBlock=yx,b.isHighSurrogate=oE,b.isInBlock=$m,b.isInBlockTools=Ds,b.isLetter=fC,b.isLowSurrogate=mm,b.isMatchShortcut=or,b.isMoveForward=hE,b.isNavigationEvent=dE,b.isNavigationKey=pC,b.isNodeRemoved=eC,b.isNumber=hC,b.isPrintableKey=wm,b.isRootBlock=io,b.isRootContainer=Yt,b.isSafari=gC,b.isSameDay=Lm,b.isSecureEnv=$0,b.isShiftEnter=pE,b.isShiftTab=bE,b.isShortcutEvent=fE,b.isSimpleBlock=FE,b.isSimpleBlockPosition=Ur,b.isSimplePos=s6,b.isSimpleRange=gh,b.isSpace=zd,b.isTab=AE,b.isTextBlockContentBoxChild=so,b.isTextBlockContentChild=ya,b.isTextBlockContentInsertionChild=Hr,b.isTextBlockContentTextChild=ka,b.isTextKindBlock=tt,b.isTextKindBlockType=va,b.isToday=SC,b.isValidOffset=sn,b.isVisibleBlock=Kd,b.isYesterday=LC,b.loadJs=nC,b.loadJsPromise=bs,b.lockers=Eo,b.mergeCommands=sf,b.mergeDocs=Ns,b.mergeOps=sg,b.mergeText=nI,b.multiSplitText=O4,b.overflowText=MC,b.parseShortcut=vC,b.patchNode=pa,b.pointInRect=ys,b.rangeAddAttribute=Ia,b.rangeGetTextColor=e6,b.rangeRemoveAttribute=Wl,b.rangeSetTextColor=K4,b.rangeTransformText=Y4,b.registerDragDrop=ym,b.removeAttribute=ug,b.removeClass=ot,b.removeLastBr=Kx,b.removePlaceholderFromBlock=i7,b.removeStyle=sC,b.replaceAll=TE,b.replaceAllCaseInsensitive=DE,b.replaceAllText=r6,b.replaceText=fh,b.requestDownload=Zd,b.resetListStart=hc,b.scrollable=IC,b.selectFile=Ul,b.selectedBlockToDoc=Dh,b.selectionToDoc=Sh,b.setAttributes=Ud,b.setClipboardData=Dm,b.setClipboardDataByEvent=BE,b.setColorToAttributes=X4,b.setDataset=Cm,b.setDefaultCursor=ma,b.setStyles=Am,b.shareDBCommentToDocObject=pp,b.shareDBDocCommentToComment=Vb,b.shortcutToDisplayText=xo,b.showBlock=jC,b.showDocVersions=rQ,b.splitText=Tn,b.splitToThree=ze,b.stringToDataUrl=Im,b.stringToObjectUrl=Tm,b.subText=_4,b.textNodeOffsetFromPoint=tC,b.titleFromEditor=g7,b.toBase64URL=Si,b.toMindmap=df,b.toPlainText=ie,b.toPlainTextKeepLength=hg,b.trimChar=km,b.unexclusiveBlock=X0,b.unicodeLength=rE,b.unicodeSubstr=iE,b.updateBlockSelection=e4,b.updateOpAttributes=o6,b.updateTextBlockContent=kI,b.updateUrl=Em;for(const n in ve)n!=="default"&&!b.hasOwnProperty(n)&&Object.defineProperty(b,n,{enumerable:!0,get:()=>ve[n]});Object.defineProperties(b,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
753
+ \`\`\`\`\`\``}return"[plantuml]"}const kG={embedType:"plantuml",convertFrom:bG,handleUpdateBlock:AG,createEmbedContent:CG,getBlockProperties:vG,convertTo:yG},got="",wG="hr",BG={dividingLine:{type:"\u5206\u5272\u7EBF",abstract:"\u5206\u5272\u7EBF"}},EG={dividingLine:{type:"Separation line",abstract:"Separation line"}},xG={dividingLine:{type:"\u533A\u5207\u308A\u7DDA",abstract:"\u533A\u5207\u308A\u7DDA"}};R.mergeLang({"zh-CN":BG,"en-US":EG,"ja-JP":xG});function IG(n,t){const e=w("div",["editor-embed-container"],t);w("hr",["editor-embed-hr"],e)}function TG(n,t,e,o){return o==="html"?"<hr />":o==="markdown"?"---":"------------"}function DG(){return{name:"hr",insertEmbedCommandItems:[{id:"insert-hr",name:R.t("dividingLine.type"),icon:NL,order:500,group:"common",subText:An("insert-hr")}],handleInsertEmptyEmbed:async(n,t)=>{const{containerId:e,blockIndex:o}=t;return n.insertEmbed(e,o,wG,{})}}}function SG(n,t,e){const{data:o}=e;if(!o||o.embedType!=="dividing-line"||!tt(n,t))return null;const r={};return{blockData:{id:K(),type:"embed",embedType:"hr",embedData:r}}}function LG(){return{abstract:R.t("dividingLine.abstract")}}const MG={embedType:"hr",createEmbedContent:IG,convertTo:TG,getOptions:DG,convertFrom:SG,getBlockProperties:LG},pot="",Cot="",RG={media:{upload:{failed:'<div class="line-1">{name}\u4E0A\u4F20\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <span class="retry-upload">\u91CD\u8BD5</span></div>'},load:{failed:'<div class="line-1">{name}\u52A0\u8F7D\u5931\u8D25</div><div class="line-2">\u7F51\u7EDC\u670D\u52A1\u5F02\u5E38\uFF0C\u4F60\u53EF\u4EE5 <span class="retry-upload">\u91CD\u8BD5</span></div>'},audio:{menuItem:"\u97F3\u9891",abstract:"\u97F3\u9891"},video:{menuItem:"\u89C6\u9891",abstract:"\u89C6\u9891"}}},OG={media:{upload:{failed:'<div class="line-1">{name} upload failed</div><div class="line-2">Network error, you can <span class="retry-upload">Retry</span></div>'},load:{failed:'<div class="line-1">{name} loading failed</div><div class="line-2">Network error, you can <span class="retry-upload">Retry</span></div>'},audio:{menuItem:"Audio",abstract:"Audio"},video:{menuItem:"Video",abstract:"Video"}}},_G={media:{upload:{failed:'<div class="line-1">{name}\u306E\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9\u306B\u5931\u6557\u3057\u307E\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <span class="retry-upload">\u518D\u8A66\u884C</span></div>'},load:{failed:'<div class="line-1">{name}\u3092\u8AAD\u307F\u8FBC\u3081\u307E\u305B\u3093\u3067\u3057\u305F</div><div class="line-2">\u304A\u4F7F\u3044\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u306B\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u64CD\u4F5C\u3092\u884C\u3063\u3066\u304F\u3060\u3055\u3044\u3002 <span class="retry-upload">\u518D\u8A66\u884C</span></div>'},audio:{menuItem:"\u97F3\u58F0",abstract:"\u97F3\u58F0"},video:{menuItem:"\u52D5\u753B",abstract:"\u52D5\u753B"}}};R.mergeLang({"zh-CN":RG,"en-US":OG,"ja-JP":_G});var qo=(n=>(n.AUDIO="audio",n.VIDEO="video",n))(qo||{}),$u=(n=>(n.Empty="empty",n.Progress="progress",n.Error="error",n))($u||{});const lk=10*1024*1024,FG=["wav","mp3","aac","ogg","webm","flac"],PG=["ogg","mp4","webm"],NG=()=>{};function ck(n){var h,p,A,v,B,D;const t=(h=n.getComponentOptions("media"))!=null?h:{},{allowedMedias:e,maxSize:o,callbacks:r}=t,i=(p=e==null?void 0:e.audio)!=null?p:FG,s=(A=e==null?void 0:e.video)!=null?A:PG,l=(v=o==null?void 0:o.audio)!=null?v:lk,a=(B=o==null?void 0:o.video)!=null?B:lk,d=(D=r==null?void 0:r.onError)!=null?D:NG;return{allowedMedias:{audio:i,video:s},maxSize:{audio:l,video:a},callbacks:{onError:d}}}function $G(n,t){const e=i=>i.map(s=>`.${s}`).join(","),{allowedMedias:o}=ck(n),r=o[t];return r?e(r):"*"}function HG(n,t,e){const{maxSize:o,callbacks:r,allowedMedias:i}=ck(t),{[e]:s}=o,{[e]:l}=i;if(s&&n.size>s){const d=new Error("media is too large");throw d.code=`MaxMediaSize-${e}`,r!=null&&r.onError&&(r==null||r.onError(t,d)),d}const a=Ca(n.name);if(l&&!l.includes(a)){const d=new Error(`media file is not allowed: ${a}`);throw d.code="NotAllowedFile",r!=null&&r.onError&&(r==null||r.onError(t,d)),d}}function jG(n){return n===$u.Empty||n===$u.Error}const Ne=S("media");class UG extends ve.TypedEmitter{constructor(e){super();m(this,"mediaContainer",null);m(this,"media",null);m(this,"abstract",null);m(this,"handleMediaLoadError",(e,o)=>{if(!o.target||!(o.target instanceof Node)||!(o.target instanceof Element?o.target:o.target.parentElement))return;const i=et(o.target);if(!i||!i.contains(this.mediaContainer))return;const s=this.renderError();this.updateMediaContent(s),this.emit("mediaError",e,"load_error",it(i))});m(this,"handleUploadFile",async e=>{g(Ne,this.abstract,"no abstract"),g(Ne,this.mediaContainer,"The media element not exist");const{editor:o}=this.options,r=et(this.mediaContainer);g(Ne,r,"The block element not exist");const i=o.getBlockData(r);try{const{resourceId:s}=await o.doc.uploadResource(e,{onProgress:p=>{this.renderProgress(p,e)}}),{name:l,type:a,size:d}=e,h={...i,embedData:{...i.embedData,src:s,fileName:l,fileSize:d,fileType:a}};o.updateBlockData(r,h)}catch(s){Ne.error(s),this.emit("mediaError",o,"upload_error",i.id),this.renderRetry(e)}ot(r,"media-block-uploading")});m(this,"destroy",()=>{this.mediaContainer=null});this.options=e}bindMediaEvent(){const{editor:e}=this.options;this.media&&e.domEvents.addEventListener(this.media,"error",this.handleMediaLoadError)}unbindMediaEvent(){const{editor:e}=this.options;this.media&&e.domEvents.removeEventListener(this.media,"error",this.handleMediaLoadError)}updateMediaContent(e){g(Ne,this.mediaContainer,"The media element not exist"),this.mediaContainer.innerHTML="",this.mediaContainer.append(e)}renderError(){g(Ne,this.abstract,"no abstract");const{editor:e,createMediaElement:o}=this.options,{mediaIcon:r,mediaName:i}=this.abstract;g(Ne,this.mediaContainer,"The media element not exist");const s=et(this.mediaContainer);g(Ne,s,"The block element not exist");const l=e.getBlockData(s),a=l.embedData.src,d=w("div",["media-error","embed-selected-content","embed-hover-content"],null),h=w("span",["media-error-icon"],d);h.innerHTML=r;const p=w("div",[],d);p.innerHTML=R.t("media.load.failed",{name:i}),d.appendChild(p);const A=p.querySelector(".retry-upload");return g(Ne,A,"The element not exist"),e.domEvents.addEventListener(A,"click",(v,B)=>{const D=w("div",["media-element"],null),x=this.getResourceUrl(a),_=o(v,D,l,x);this.unbindMediaEvent(),this.media=_,this.bindMediaEvent(),this.updateMediaContent(D)}),this.setFullScreen(),d}renderRetry(e){g(Ne,this.abstract,"no abstract");const{editor:o}=this.options,{mediaIcon:r,mediaName:i}=this.abstract,s=w("div",["media-error","embed-selected-content","embed-hover-content"],null),l=w("span",["media-error-icon"],s);l.innerHTML=r;const a=w("div",[],s);a.innerHTML=R.t("media.upload.failed",{name:i}),s.appendChild(a);const d=a.querySelector(".retry-upload");g(Ne,d,"The element not exist"),o.domEvents.addEventListener(d,"click",()=>{o.readonly||(g(Ne,this.abstract,"no abstract"),this.handleUploadFile(e))}),this.updateMediaContent(s),this.setFullScreen()}renderProgress(e,o){g(Ne,this.mediaContainer,"The media element not exist");const r=this.mediaContainer.querySelector(":scope .media-progress"),i=e===-1||e===100?100:e;if(r){const{updateProgressElement:s}=this.options;s(r,i)}else{const{createProgressElement:s}=this.options,l=et(this.mediaContainer);g(Ne,l,"The element not exist"),W(l,"media-block-uploading");const a=w("div",["media-progress"],null);s(a,i,o),this.updateMediaContent(a)}this.setFullScreen()}renderMediaElement(e){g(Ne,this.mediaContainer,"The media element not exist");const o=this.mediaContainer.querySelector(":scope > .media-element"),{createMediaElement:r,updateMediaElement:i,editor:s}=this.options,l=this.getResourceUrl(e.embedData.src);if(o){const a=i(s,o,e,l);this.unbindMediaEvent(),this.media=a,this.bindMediaEvent()}else{const a=w("div",["media-element"],null),d=r(s,a,e,l);this.unbindMediaEvent(),this.media=d,this.bindMediaEvent(),this.updateMediaContent(a)}}renderEmpty(e){g(Ne,this.abstract,"no abstract"),g(Ne,this.mediaContainer,"The media element not exist");const o=w("div",["media-empty","embed-selected-content","embed-hover-content"],this.mediaContainer);o.innerHTML=this.abstract.mediaIcon,this.updateMediaContent(o);const{editor:r}=this.options;r.findBlockById(e.id)&&this.emit("mediaError",r,"empty",e.id),this.setFullScreen()}getResourceUrl(e){const{editor:o}=this.options;return o.doc.buildResourceUrl(e)}setFullScreen(){g(Ne,this.mediaContainer,"The media element not exist"),W(this.mediaContainer,"full-screen")}removeFullScreen(){g(Ne,this.mediaContainer,"The media element not exist"),ot(this.mediaContainer,"full-screen")}updateBlockAlign(e,o){const r=et(o);g(Ne,r,"The block element not exist");const{align:i}=e;e.embedType==="video"&&(r.hasAttribute("data-style-align")&&r.removeAttribute("data-style-align"),r.setAttribute("data-style-align",i))}render(e,o){const{src:r}=e.embedData;(!this.mediaContainer||!o.contains(this.mediaContainer))&&(this.mediaContainer=w("div",["media"],o)),this.updateBlockAlign(e,o),jG(r)?r===$u.Empty&&this.renderEmpty(e):this.renderMediaElement(e)}setAbstract(e){this.abstract=e}}S("media-embed");const zG="left";class ak{constructor(){m(this,"handleInsertEmptyEmbed",async(t,e)=>{var p;const{containerId:o,blockIndex:r}=e;let i;(p=e.data)!=null&&p.file&&(i=e.data.file);const s=$G(t,this.embedType);if(i=i!=null?i:await Ul(s,{}),!i)return null;const{mediaType:l}=this.getAbstract();try{HG(i,t,l)}catch{return null}const a={id:K(),type:"embed",embedType:this.embedType,embedData:{src:$u.Empty}};l==="video"&&(a.align=zG);const d=t.insertBlock(o,r,a);return await this.getMedia(t,a.id).handleUploadFile(i),d})}getMedia(t,e){const o=t.addCustom(`media-${e}`,()=>new UG({editor:t,createMediaElement:this.createMediaElement,updateMediaElement:this.updateMediaElement,createProgressElement:this.createProgressElement,updateProgressElement:this.updateProgressElement}));return o.setAbstract({...this.getAbstract()}),o}getOptions(){const{menuItem:t,mediaIcon:e,mediaName:o,order:r,group:i}=this.getAbstract();return{name:o,insertEmbedCommandItems:[{id:`insert-${this.embedType}`,name:t,icon:e,order:r,group:i,subText:An(`insert-${this.embedType}`)}],handleInsertEmptyEmbed:this.handleInsertEmptyEmbed}}createEmbedContent(t,e,o){const{id:r}=o;this.getMedia(t,r).render(o,e)}handleUpdateBlock(t,e,o){const{id:r}=o,i=this.getMedia(t,r),s=Lt(e);return i.render(o,s),!0}handleDeleteBlock(t,e){const o=e.id,r=this.getMedia(t,o);r.removeAllListeners(),r.destroy()}convertTo(t,e,o,r){const i=e.embedData,s=t.doc.buildResourceUrl(i.src,{withToken:!0});return r==="html"?`<${i.type} src="${s}" />`:r==="markdown"?`![${i.src}](${s})`:s}}function uk(n,t){const e=w("div",["uploading-progress-mask"],n),o=w("div",["uploading-progress-bar"],e),r=w("div",["uploading-progress-bar-value"],o);r.style.width=`${t}%`}function dk(n,t){const e=n.querySelector(".uploading-progress-bar-value");e&&(e.style.width=`${t}%`)}const VG=S("media-audio");class WG extends ak{constructor(){super(...arguments);m(this,"embedType",qo.AUDIO);m(this,"updateProgressElement",dk);m(this,"createMediaElement",(e,o,r,i)=>{const s=w("div",["audio-container","embed-hover-content","embed-selected-content"],o),l=w("audio",[],s);return l.innerHTML="Your browser does not support the <code>audio</code> element.",l.controls=!0,l.src=i,setTimeout(()=>{this.getMedia(e,r.id).setFullScreen()}),l})}getAbstract(){return{mediaIcon:_L,mediaName:R.t(`media.${qo.AUDIO}.menuItem`),menuItem:R.t(`media.${qo.AUDIO}.menuItem`),order:800,mediaType:qo.AUDIO,group:"common"}}getBlockProperties(){return{abstract:`${R.t(`media.${qo.AUDIO}.abstract`)}`}}updateMediaElement(e,o,r,i){const s=o.querySelector(":scope .audio-container > audio");return g(VG,s,"The media element not exist"),s.src!==i&&(s.src=i),s}createProgressElement(e,o){const r=w("audio",[],e);r.innerHTML="Your browser does not support the <code>audio</code> element.",r.controls=!0,r.src="about:blank",uk(e,o)}}const qG=new WG;S("video-resizer");function hk(n){return n&&Me(n)&&fn(n)==="video"}const GG=50;class q2{constructor(t){m(this,"currentResizableElement",null);m(this,"resizing",!1);m(this,"handleHoveringBlockChange",(t,e)=>{if(!this.resizing&&!window.isDragging&&(e&&hk(e)&&this.disableBlockResize(e),t&&hk(t))){const o=this.getVideoElement(t);if(!o)return;this.enableBlockResize(t,o)}});m(this,"handleResizing",(t,e)=>{if(this.resizing=!0,!this.currentResizableElement)return;const o=t.getBlock();if(!o)return;const r=o.getBoundingClientRect().width,i=Math.min(Math.max(e.width,GG),r);this.currentResizableElement.style.width=`${i}px`,this.currentResizableElement.style.pointerEvents="none"});m(this,"handleResized",t=>{this.resizing=!1;const e=t.getBlock();if(!this.currentResizableElement||!e)return;const o=this.editor.getBlockData(e),{width:r}=this.currentResizableElement.getBoundingClientRect();this.currentResizableElement.style.pointerEvents="auto",this.editor.updateBlockData(e,{...o,width:r})});this.editor=t,Ce.get(t).addListener("change",this.handleHoveringBlockChange)}destroy(){this.currentResizableElement=null,Ce.get(this.editor).removeListener("change",this.handleHoveringBlockChange)}getVideoElement(t){return Lt(t).querySelector(":scope .video-container > video")}updateResizer(t){const e=this.editor.findCustom(`${it(t)}-resizer`);e&&e.updateResizer()}disableBlockResize(t){const e=this.editor.findCustom(`${it(t)}-resizer`);e&&e.disableResize()}enableBlockResize(t,e){const o=this.editor.addCustom(`${it(t)}-resizer`,()=>new Bu(this.editor,{resize:["top-left","top-right","bottom-left","bottom-right"]}));o.enableResize(t,e),o.removeListener("resizing",this.handleResizing),o.removeListener("resized",this.handleResized),o.addListener("resizing",this.handleResizing),o.addListener("resized",this.handleResized),this.currentResizableElement=e}}const ZG=S("video");class QG extends ak{constructor(){super(...arguments);m(this,"embedType",qo.VIDEO);m(this,"updateProgressElement",dk);m(this,"createMediaElement",(e,o,r,i)=>{const s=w("div",["video-container","embed-selected-content","drag-preview-element"],o),l=w("video",[],s);return l.innerHTML="Your browser does not support the <code>video</code> element.",l.controls=!0,l.src=i,l.addEventListener("canplay",()=>{e.addCustom("video-resizer",()=>new q2(e)),this.getMedia(e,r.id).removeListener("mediaError",this.handleMediaError),this.getMedia(e,r.id).addListener("mediaError",this.handleMediaError),this.getMedia(e,r.id).removeFullScreen()}),r.width&&(l.style.width=`${r.width}px`),l});m(this,"createProgressElement",(e,o,r)=>{const i=w("video",["progress-video"],e);i.innerHTML="Your browser does not support the <code>audio</code> element.",i.controls=!0,uk(e,o),jl(r).then(s=>{const l=e.querySelector(".progress-video");l&&$m(e)&&(l.src=s)})})}getAbstract(){return{mediaName:R.t(`media.${qo.VIDEO}.menuItem`),mediaIcon:FL,menuItem:R.t(`media.${qo.VIDEO}.menuItem`),order:700,mediaType:qo.VIDEO,group:"common"}}getBlockProperties(){return{abstract:`[${R.t(`media.${qo.VIDEO}.abstract`)}]`}}handleMediaError(e,o,r){const i=e.addCustom("video-resizer",()=>new q2(e)),s=e.getBlockById(r);i.disableBlockResize(s)}updateMediaElement(e,o,r,i){const s=o.querySelector(":scope .video-container > video");g(ZG,s,"The media element not exist"),s.src!==i&&(s.src=i),r.width?s.style.width=`${r.width}px`:s.style.width="";const l=e.getBlockById(r.id);return setTimeout(()=>{e.addCustom("video-resizer",()=>new q2(e)).updateResizer(l)}),s}}const YG=new QG,fk=[L0,j0,U0,B9],G2=[nk,JW,iG,mG,kG,$_,MG,YG,qG,xH,N8,Qz],mk=[_9,j8,c8];function JG(n,t,e){var r,i,s;const o=Ha(n,t,{components:{blocks:[...fk,...((r=e==null?void 0:e.components)==null?void 0:r.blocks)||[]],embeds:[...G2,...((i=e.components)==null?void 0:i.embeds)||[]],boxes:[...mk,...((s=e.components)==null?void 0:s.boxes)||[]],textRenders:[new g0],options:{...e.componentsOptions}}});return o.readonly=!0,o.addCustom("heading-collapse",()=>new R2(o)),o.addCustom("editor-tooltip",()=>new bf(o)),o.addListener("clickLink",(l,a,d)=>{var p;if((p=e==null?void 0:e.events)!=null&&p.onClickLink){e.events.onClickLink(l,a,d);return}const h=d.getAttribute("link");h&&(l.readonly||a.ctrlKey||a.metaKey)&&window.open(h,"_blank")}),o}class gk{constructor(t){this.createOptions=t,t.lang&&R.setLang(t.lang)}createHistoryEditor(t,e){return JG(t,e,this.createOptions)}}S("create-editor");function pk(n,{root:t,childDoc:e,doc:o}){var d,h;e.uploadResource=o.uploadResource.bind(o),e.buildResourceUrl=o.buildResourceUrl.bind(o);const r={image:{defaultAlign:"left"},toc:{showFirstBlock:!0},table:{locatingContainer:t,hideCellMenu:!0,hideToolbar:!0}},i=[];n.editorBlocks.forEach(p=>{p.blockType==="text"||p.blockType==="embed"||i.push(p)});const s=[];n.editorEmbeds.forEach(p=>{s.push(p)});const l=[];n.editorBoxes.forEach(p=>{p.boxType==="text"||p.boxType==="br"||p.boxType==="image"||p.boxType==="anchor"||l.push(p)});const a=Ha(t,e,{shortcuts:[Mh],components:{blocks:i,commandProviders:[new tf],decorators:[new Df],embeds:s,boxes:l,options:r}});if(a.input.addHandler(new xf),a.input.addHandler(new c2(a)),a.input.addHandler(new f2(a)),a.input.addHandler(new tz(a)),a.input.addHandler(new Of),a.addCustom("image-paste-handler",()=>new l2(a)),(d=n.options.componentsOptions)!=null&&d.mention){const p=n.options.componentsOptions.mention;a.addCustom("mention",()=>new H8(a,{...p,enableFirstBlock:!0}))}if((h=n.options.componentsOptions)!=null&&h.comment){const p=n.options.componentsOptions.comment;p.onCommentEditorClick&&a.addListener("click",p.onCommentEditorClick)}return a}function KG(n,t){const e=Array.from(n.rootContainer.querySelectorAll(`[comment-${t.toLocaleLowerCase()}="${t}"]`)),o=new Set;e.forEach(r=>{const i=et(r);i&&o.add(i)}),o.forEach(r=>{ez(n,r,t)})}class XG{constructor(t){m(this,"listeners",new Set);m(this,"doc");this.editor=t,this.doc=this.editor.doc.externalDoc,this.doc.registerCallback(this)}getComments(){return this.doc.getComments()}getComment(t){return this.doc.getComment(t)}getCommentDoc(t){return this.doc.getCommentDoc(t)}localCreateComment(t,e){this.doc.localCreateComment(t,e)}localDeleteComment(t){const e=this.getComment(t);this.doc.localDeleteComment(t);const o=e.groupId;this.getComments().filter(i=>i.groupId===o).length===0&&KG(this.editor,o)}localUpdateComment(t,e){this.doc.localUpdateComment(t,e)}onCreateComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onCreateComment(t,e))}onDeleteComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onDeleteComment(t,e))}onUpdateComment(t,e){Array.from(this.listeners.values()).forEach(o=>o.onUpdateComment(t,e))}addListener(t){this.listeners.add(t)}removeListener(t){this.listeners.delete(t)}createCommentEditor(t,e){return pk(this.editor,{root:t,childDoc:e,doc:this.doc})}allowEdit(t){return t.userId===this.doc.getUser().userId}}class tZ{constructor(t,e){m(this,"listeners",new Set);this.editor=t,this.localDoc=e}get doc(){return this.localDoc.toJSON()}getComments(){return Object.values(this.doc.comments)}getComment(t){return this.doc.comments[t]}getCommentDoc(t){const e=this.doc.comments[t];return pp(e)}addListener(t){this.listeners.add(t)}removeListener(t){this.listeners.delete(t)}localCreateComment(t,e){}localDeleteComment(t){}localUpdateComment(t,e){}createCommentEditor(t,e){return pk(this.editor,{root:t,childDoc:e,doc:this.localDoc})}allowEdit(t){return t.userId===this.localDoc.getUser().userId}}const eZ={placeholder:{common:{title:"\u8BF7\u8F93\u5165\u6807\u9898",readonlyTitle:"\u8BF7\u8F93\u5165\u6807\u9898",content:"\u70B9\u51FB + \uFF0C\u6216\u8F93\u5165 / \u5FEB\u6377\u63D2\u5165\u7EC4\u4EF6",contentInTable:"\u8F93\u5165 / \u5FEB\u6377\u63D2\u5165\u7EC4\u4EF6"},local:{readonlyTitle:"\u672A\u547D\u540D"}},copyCutProperty:{copy:"\u590D\u5236",cut:"\u526A\u5207",unsafeEnvTips:"\u7531\u4E8E\u5F53\u524D http \u8BBF\u95EE\u73AF\u5883\u4E0B\u7684\u9650\u5236\uFF0C\u8BF7\u4F7F\u7528\u5FEB\u6377\u952E({shortCut}) {operation}"}},nZ={placeholder:{common:{title:"Enter a title",readonlyTitle:"Enter a title",content:"Click + or enter / to insert components quickly",contentInTable:"Enter / to insert components quickly"},local:{readonlyTitle:"Untitled"}},copyCutProperty:{copy:"Copy",cut:"Cut",unsafeEnvTips:"Due to the limitations of the current http access environment, please use the shortcut ({shortCut}) {operation}"}},oZ={placeholder:{common:{title:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",readonlyTitle:"\u30BF\u30A4\u30C8\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044",content:"\u300C+\u300D\u3092\u30AF\u30EA\u30C3\u30AF\u3059\u308B\u304B\u3001\u300C/\u300D\u3092\u5165\u529B\u3059\u308B\u3068\u3001\u30B3\u30F3\u30DD\u30FC\u30CD\u30F3\u30C8\u304C\u7D20\u65E9\u304F\u633F\u5165\u3067\u304D\u307E\u3059",contentInTable:"\u300C/\u300D\u3092\u5165\u529B\u3059\u308B\u3068\u3001\u30B3\u30F3\u30DD\u30FC\u30CD\u30F3\u30C8\u304C\u7D20\u65E9\u304F\u633F\u5165\u3067\u304D\u307E\u3059"},local:{readonlyTitle:"\u7121\u984C"}},copyCutProperty:{copy:"\u8907\u88FD",cut:"\u5207\u308B",unsafeEnvTips:"HTTP\u74B0\u5883\u306E\u5236\u7D04\u306B\u3088\u308A\u3001{operation}\u3059\u308B\u306B\u306F\u3001\u30B7\u30E7\u30FC\u30C8\u30AB\u30C3\u30C8({shortCut}) \u3092\u3054\u4F7F\u7528\u304F\u3060\u3055\u3044"}};R.mergeLang({"zh-CN":eZ,"en-US":nZ,"ja-JP":oZ});const rZ="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",iZ=()=>xm(rZ);async function sZ(n){return new Promise((t,e)=>{const o=new Image;o.onload=()=>{t({width:o.naturalWidth,height:o.naturalHeight})},o.onerror=e,o.src=n})}async function Ck(n,t){if(n.width&&n.height)return{width:n.width,height:n.height,buffer:t};const e=await jl(new File([t],"",{})),o=await sZ(e);return o.width===void 0||o.height===void 0?{width:345,height:230,buffer:t}:n.width||n.height?{width:n.width||o.width*n.height/o.height,height:n.height||o.height*n.width/o.width,buffer:t}:{width:o.width,height:o.height,buffer:t}}function lZ(n,t){let e=n.filter(s=>s!=null);const o=t-(e.length-1)*20,r=.87,i=e.reduce((s,l)=>s+l.width,0);return i>o&&(e=e.map(s=>({width:s.width*o/i,height:s.height*o/i,buffer:s.buffer}))),e.map(s=>({width:s.width*r,height:s.height*r,buffer:s.buffer}))}function Ak(n=[0,1,2,3,4,5,6,7],t=1){return n.map(e=>{let o;switch(e%3){case 0:o=gt.LevelFormat.DECIMAL;break;case 1:o=gt.LevelFormat.LOWER_LETTER;break;default:o=gt.LevelFormat.LOWER_ROMAN;break}return{level:e,format:o,text:`%${e+1}. `,alignment:gt.AlignmentType.START,start:t,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(e+1)),hanging:gt.convertInchesToTwip(.2)}}}}})}function cZ(){return[0,1,2,3,4,5,6,7].map(n=>{let t;switch(n%3){case 0:t="\u2022";break;case 1:t="\u25E6";break;default:t="\u25AA";break}return{level:n,format:gt.LevelFormat.BULLET,text:t,alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}})}function aZ(){return[0,1,2,3,4,5,6,7].map(n=>({level:n,format:gt.LevelFormat.BULLET,text:"\u2611",alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}))}function uZ(){return[0,1,2,3,4,5,6,7].map(n=>({level:n,format:gt.LevelFormat.BULLET,text:"\u2610",alignment:gt.AlignmentType.START,style:{paragraph:{indent:{left:gt.convertInchesToTwip(.3*(n+1)),hanging:gt.convertInchesToTwip(.2)}}}}))}var Hu=(n=>(n.NUMBERING="number-numbering-reference",n.BULLET="number-bullet-reference",n.CHECKED="checked-bullet-reference",n.UNCHECKED="unchecked-bullet-reference",n))(Hu||{});const dZ=[{levels:Ak(),reference:"number-numbering-reference"},{levels:cZ(),reference:"number-bullet-reference"},{levels:aZ(),reference:"checked-bullet-reference"},{levels:uZ(),reference:"unchecked-bullet-reference"}];function hZ(n){switch(n){case"style-color-0":return"d83931";case"style-color-1":return"de7802";case"style-color-2":return"dc9b04";case"style-color-3":return"2ea121";case"style-color-4":return"245bdb";case"style-color-5":return"6425d0";case"style-color-6":return"8f959e";default:return}}function fZ(n){switch(n){case"style-bg-color-1":case"style-bg-color-2":case"style-bg-color-8":case"style-bg-color-9":return"yellow";case"style-bg-color-0":case"style-bg-color-5":return"magenta";case"style-bg-color-3":return"green";case"style-bg-color-4":case"style-bg-color-11":return"blue";case"style-bg-color-6":return"lightGray";case"style-bg-color-7":return"red";case"style-bg-color-10":return"darkGreen";case"style-bg-color-12":return"darkMagenta";case"style-bg-color-13":return"darkGray";default:return}}function mZ(n){switch(n){case"style-bg-color-0":return"fbbab6";case"style-bg-color-1":return"ffdcb0";case"style-bg-color-2":return"fff7a0";case"style-bg-color-3":return"ceefc5";case"style-bg-color-4":return"d1ddfb";case"style-bg-color-5":return"d9cbf8";case"style-bg-color-6":return"eaeaea";case"style-bg-color-7":return"fe837c";case"style-bg-color-8":return"ffbd6a";case"style-bg-color-9":return"ffe662";case"style-bg-color-10":return"a8f393";case"style-bg-color-11":return"98b5ff";case"style-bg-color-12":return"b394f8";case"style-bg-color-13":return"b1b1b1";default:return}}const gZ=/rgb\((\d+),\s*(\d+),\s*(\d+)\)/;function bk(n){if(typeof n=="string"&&n.length>0){if(n[0]==="#")return n.substring(1);const t=n.match(gZ);if(t){const e=s=>{let l=Number(s).toString(16);return l.length<2&&(l=`0${l}`),l},o=e(t[1]),r=e(t[2]),i=e(t[3]);return`${o}${r}${i}`}if(n==="red")return"FF0000";if(n==="green")return"00FF00";if(n==="blue")return"0000FF"}}function tn(n,t){if(n&&n.attributes&&n.attributes[t])return n.attributes[t];if(n&&n.attributes&&n.attributes.box&&n.attributes.inputType&&t==="style-underline")return!0}function vk(n,t,e){for(let o=0;o<=e;++o){const r=`${t}${o}`;if(tn(n,r))return r}}function o1(n,t,e){n.attributes=n.attributes||{},n.attributes[t]=e}function Z2(n){return n==="image"||n==="drawio"||n==="plantuml"||n==="mermaid"||n==="flowchart"}function yk(n){return n&&n.startsWith("//")?`https:${n}`:n&&!n.startsWith("http://")&&!n.startsWith("https://")?`https://${n}`:n}function pZ(n){const t=tn(n,"inlineStyle");if(t==null)return;const e=t.split(";");for(const o of e){const r=o.split(":");if(r.length!==2)continue;const i=r[0].trim().toLowerCase(),s=r[1].trim().toLowerCase();i==="font-size"&&o1(n,"inline-style-font-size",s),i==="color"&&o1(n,"inline-style-color",s),i==="background-color"&&o1(n,"inline-style-background-color",s),i==="font-family"&&o1(n,"inline-style-font-family",s)}}function CZ(n,t){if(t==null)return n==null?void 0:n.normal;if(n)return n[`heading${t}`]}function AZ(n){const t=`${tn(n,"inline-style-font-size")}`;if(t&&t.indexOf("px")>0)return+t.replace(/px/g,"")}function bZ(n){if(n.attributes&&n.attributes.box&&n.attributes.text)return` ${n.attributes.text} `;if(n.attributes&&n.attributes.box&&n.attributes.inputType)return n.attributes.value?`${n.attributes.value}`:" "}function vZ(n){if(n.attributes&&n.attributes.box&&n.attributes.text)return` @${n.attributes.text} `}function yZ(n){return tn(n,"inline-style-font-family")}function kZ(n){const t=tn(n,"inline-style-background-color");return bk(t)}function wZ(n){const t=tn(n,"inline-style-color");return bk(t)}function BZ(n){pZ(n);const t=tn(n,"type")==="mention";return{box:n.attributes&&n.attributes.box?n.attributes:void 0,inlineCode:!!tn(n,"style-code"),link:yk(tn(n,"link")),size:AZ(n),text:t?vZ(n):bZ(n)||n.insert,bold:!!tn(n,"style-bold"),underline:!!tn(n,"style-underline"),italics:!!tn(n,"style-italic"),strike:!!tn(n,"style-strikethrough"),superScript:!!tn(n,"style-super"),subScript:!!tn(n,"style-sub"),math:tn(n,"type")==="math"?tn(n,"src"):void 0,mention:t,fontFamily:yZ(n),background:kZ(n),color:t?"338fe5":hZ(vk(n,"style-color-",6))||wZ(n),highlight:vk(n,"style-bg-color-",13)}}function EZ(){return[new gt.Paragraph({border:{top:{color:"auto",style:gt.BorderStyle.DASHED,size:4,space:1}},spacing:{before:300}}),new gt.Paragraph({spacing:{line:0}})]}function xZ(){return new gt.Paragraph({children:[new gt.TextRun({text:"[\u89C6\u9891\u6682\u4E0D\u652F\u6301\u5BFC\u51FA]",shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}})]})}function IZ(){return new gt.Paragraph({children:[new gt.TextRun({text:"[\u97F3\u9891\u6682\u4E0D\u652F\u6301\u5BFC\u51FA]",shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}})]})}function TZ(n,t){return new gt.Paragraph({children:[new gt.ExternalHyperlink({children:[new gt.TextRun({style:"Hyperlink",text:t||n})],link:n})]})}function kk(n){if(n.heading!=null)return`Heading${n.heading}`}function wk(n){if(n.alignment!=null){if(n.alignment==="center")return gt.AlignmentType.CENTER;if(n.alignment==="right")return gt.AlignmentType.RIGHT;if(n.alignment==="left")return gt.AlignmentType.LEFT}}function DZ(n){if(n.indent)return{left:gt.convertInchesToTwip(.3*n.indent-.2)};if(n.padding)return{left:gt.convertInchesToTwip(.3*n.padding)}}function SZ(n){return{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:n}}function LZ(n){const t=n.split(",");if(t.length!==0)return t[0].trim()}function Bk(n,t){let e;e=n.inlineCode?"InlineCode":void 0,e=n.link?"Hyperlink":e;const o=n.size||t,r=o!=null?Math.floor(o*1.5+.5):void 0;return new gt.TextRun({text:n.text,bold:n.bold||void 0,underline:n.underline?{type:gt.UnderlineType.SINGLE}:void 0,italics:n.italics||void 0,strike:n.strike||void 0,superScript:n.superScript||void 0,subScript:n.subScript||void 0,size:r,style:e,font:n.fontFamily?LZ(n.fontFamily):void 0,shading:n.background?SZ(n.background):void 0,color:n.color,highlight:fZ(n.highlight)})}function MZ(n,t){if(n.link)return new gt.ExternalHyperlink({children:[Bk(n,t)],link:n.link})}async function Ek(n,t,e,o,r){const i=await r(n,t,e);if(i==null)return;const s=await Ck({width:o||0,height:0,src:e},i);return new gt.ImageRun({data:i,transformation:{width:s.width||100,height:s.height||20}})}function RZ(n){if(n.heading||n.heading)return n.heading}function OZ(n){if(n.align&&(n.align==="center"||n.align==="right"||n.align==="left"))return n.align}function _Z(n){if(n.textOnly===!0&&n.level!=null)return n.level}async function FZ(n,t){var o;const e=[];if(n.text&&Array.isArray(n.text)){for(let r=0;r<n.text.length;r++){const i=n.text[r];if(((o=i.attributes)==null?void 0:o.box)===!0&&t){const s=await t(i);if(s){n.text.splice(r+1,0,...s);continue}}e.push(BZ(i))}return e}}function PZ(n){if(n.type==="list"&&n.textOnly!==!0)return{checkbox:n.checkbox,groupId:n.groupId,ordered:!!n.ordered,level:n.level||1,start:n.start||0}}function NZ(n,t){if(n.type==="embed"&&n.embedType&&Z2(n.embedType)&&n.embedData&&n.embedData.src)return n.embedData.src.split("|").map(o=>{const r=t(o),i=n.embedData[`${r}_width`],s=n.embedData[`${r}_height`];return{src:o,width:i,height:s}})}function $Z(n){if(n.padding)return n.padding}function HZ(n){return!!(n.type==="embed"&&n.embedType&&Z2(n.embedType)&&n.embedData&&n.embedData.src)}async function r1(n,t,e){return{quoted:!!n.quoted,heading:RZ(n),alignment:OZ(n),indent:_Z(n),padding:$Z(n),texts:await FZ(n,e),list:PZ(n),images:NZ(n,t),border:HZ(n)}}async function jZ(n,t,e,o){const r=[];if(!n.children)return[];for(const i of n.children){const s=[];for(const l of t.blocks[i])s.push(await r1(l,e,o));r.push(s)}return r}const UZ=S("to-docx");function zZ(n,t){return Array(n).fill(0).map(()=>Array(t).fill(0).map(()=>({cellId:void 0,color:void 0,from:void 0,rowSpan:1,colSpan:1,width:0,originalWidth:void 0,align:void 0})))}function VZ(n,t,e,o){const r=!!n.hasColTitle,i=!!n.hasRowTitle,s=!!n.isStripeStyle,l="F5F8FB";for(let a=0;a<t;a++)for(let d=0;d<e;d++)(r&&d===0||i&&a===0||s&&a%2===1)&&(o[a][d].color=l)}function WZ(n){g(UZ,n.children,"no table children");const t=n.rows,e=n.cols,o=n.colsWidth;if(o)for(let s=0;s<o.length;s++)o[s]===0&&(o[s]=100);const r=zZ(t,e);let i=0;for(let s=0;s<t;++s)for(let l=0;l<e;++l){if(r[s][l].originalWidth=o?o[l]:void 0,r[s][l].from!==void 0)continue;const a=n.children[i];i+=1,r[s][l].cellId=a,r[s][l].color=mZ(n[`${a}_background`]),r[s][l].width=o?o[l]:100,r[s][l].align=n[`${a}_align`];const d=n[`${a}_rowSpan`]||1,h=n[`${a}_colSpan`]||1;if(r[s][l].rowSpan=d,r[s][l].colSpan=h,d>1||h>1){let p=0;for(let A=0;A<d;A++)for(let v=0;v<h;v++)A===0&&(p+=o?o[l+v]:80),!(A===0&&v===0)&&(r[s+A][l+v].from=[s,l]);r[s][l].width=p}}return VZ(n,t,e,r),r}async function qZ(n,t,e,o,r,i,s,l,a,d){async function h(v){if(l){const B=await l(r,i,v);if(B){await o.addDoc(n,B,d);return}}if(v.type==="text"||v.textOnly===!0){const B=await r1(v,s,a);await o.addTextBlock(B);return}if(v.type==="code"){const B=await jZ(v,e,s,a);await o.addCodeBlockObject(B);return}if(v.type==="list"&&v.textOnly!==!0){const B=await r1(v,s,a);await o.addListBlockObject(n,B);return}if(v.type==="embed"&&v.embedType){const B=v,D=B.embedData,x=B.embedType;if(Z2(x)){const _=await r1(v,s,a);await o.addImagesBlockObject(v,_,d)}else v.embedType==="hr"?o.addSeparatorBlock():v.embedType==="video"?o.addVideoPlaceholder():v.embedType==="audio"?o.addAudioPlaceholder():v.embedType==="webpage"?o.addHyperlinkParagraph(yk(D.src),D.title):o.addOtherEmbedBlock(x,v.embedData);return}if(v.type==="table"){let B=[];if(v.colsWidth)B=v.colsWidth;else{const x=v.cols;B=new Array(x);for(let _=0;_<B.length;_++)B[_]=100;v.colsWidth=B}const D=WZ(v);await o.addTableMatrix(B,D,e),o.addEmptyParagraph()}}function p(v){const B=[];for(const{type:D,data:x}of v.embedData.exportSpec){if(D==="text"){const _={id:K(),text:[{insert:x}],type:"text"};B.push(_);continue}if(D==="image"){const _={id:K(),type:"embed",embedType:"image",align:"left",embedData:{src:x}};B.push(_);continue}if(D==="link"){const _={id:K(),type:"embed",embedType:"webpage",embedData:{src:x.url,title:x.title}};B.push(_);continue}}return B}function A(v){var B;return(B=v==null?void 0:v.embedData)!=null&&B.exportSpec?p(v):[v]}for(const v of t)for(const B of A(v))await h(B)}function GZ(){return{listMaxInst:1,listInstMap:{},listRefMap:{},levelConfigs:[]}}const ZZ=S("to-docx");class QZ{constructor(t,e,o,r,i,s){m(this,"paragraphs");this.appId=t,this.docId=e,this.state=o,this.readImageFunc=r,this.convertBlocksFunc=i,this.defaultFontSize=s,this.paragraphs=[]}async addTextBlock(t){this.paragraphs.push(new gt.Paragraph({heading:kk(t),alignment:wk(t),children:await this.paragraphsFromBlockTexts(t),indent:DZ(t)}))}async addEmptyImagePlaceHolder(){this.paragraphs.push(new gt.Paragraph({text:`[${R.t("docx.imageExportFailed")}]`,shading:{type:gt.ShadingType.CLEAR,color:"FFFFFF",fill:"CCCCCC"}}))}async paragraphsFromBlockTexts(t){if(t.texts==null)return;const e=CZ(this.defaultFontSize,t.heading),o=[];for(const r of t.texts){if(r.link){const i=MZ(r,e);i&&o.push(i);continue}if(r.box&&r.box.type&&r.box.type==="br"){o.push(new gt.TextRun({text:"",break:1}));continue}if(r.box&&r.box.type&&r.box.type==="image"){const i=await Ek(this.appId,this.docId,r.box.src,r.box.width,this.readImageFunc);i&&o.push(i);continue}if(r.math){const i=await Ek(this.appId,this.docId,r.math,0,this.readImageFunc);i&&o.push(i);continue}o.push(Bk(r,e))}return o}async addCodeBlockObject(t){for(const e of t)for(const o of e){const r={style:gt.BorderStyle.SINGLE,color:"#DEDEDE"};this.paragraphs.push(new gt.Paragraph({style:"Code",border:{left:{...r},right:{...r},top:{...r},bottom:{...r}},children:await this.paragraphsFromBlockTexts(o)}))}}async addListBlockObject(t,e){if(e.list==null)return;let o;const r=e.list.checkbox?`${t}-${e.list.groupId}-${e.list.checkbox}`:`${t}-${e.list.groupId}`;if(this.state.listInstMap[r])o=this.state.listInstMap[r];else if(o=this.state.listMaxInst,this.state.listMaxInst+=1,this.state.listInstMap[r]=o,e.list.start>0&&e.list.ordered){const s=`number-numbering-reference-${o}`,l=Ak([e.list.level-1],e.list.start);this.state.levelConfigs.push({levels:l,reference:s,inst:o}),this.state.listRefMap[r]=s}else e.list.ordered?this.state.listRefMap[r]=Hu.NUMBERING:e.list.checkbox&&e.list.checkbox==="checked"?this.state.listRefMap[r]=Hu.CHECKED:e.list.checkbox&&e.list.checkbox==="unchecked"?this.state.listRefMap[r]=Hu.UNCHECKED:this.state.listRefMap[r]=Hu.BULLET;const i=kk(e);e.texts&&this.paragraphs.push(new gt.Paragraph({heading:i,children:await this.paragraphsFromBlockTexts(e),numbering:{reference:this.state.listRefMap[r],level:e.list.level-1,instance:o}}))}imageDimWithBufferToImageRun(t){return new gt.ImageRun({data:t.buffer,transformation:{width:t.width,height:t.height}})}async addImagesBlockObject(t,e,o){if(e.images==null){if(t.type==="embed"&&t.embedType==="image"){const{src:a}=t.embedData;a||this.addEmptyImagePlaceHolder()}return}const r=[],i=await Promise.all(e.images.map(async a=>{const d=await this.readImageFunc(this.appId,this.docId,a.src);if(d)return Ck(a,d);r.push(a.src)})),s=lZ(i,o),l={style:gt.BorderStyle.SINGLE,color:"#DEDEDE"};s.length&&this.paragraphs.push(new gt.Paragraph({border:e.border?{left:{...l},right:{...l},top:{...l},bottom:{...l}}:void 0,alignment:wk(e)||gt.AlignmentType.CENTER,children:s.map(a=>this.imageDimWithBufferToImageRun(a)).flatMap((a,d,h)=>a==null?[]:h.length-1!==d?[a,new gt.TextRun({text:" "})]:a)})),r.forEach(a=>{this.addHyperlinkParagraph(a)})}addSeparatorBlock(){EZ().forEach(t=>this.paragraphs.push(t))}addEmptyParagraph(){this.paragraphs.push(new gt.Paragraph(""))}addVideoPlaceholder(){this.paragraphs.push(xZ())}addAudioPlaceholder(){this.paragraphs.push(IZ())}addHyperlinkParagraph(t,e){t!=null&&this.paragraphs.push(TZ(t,e))}async addTableMatrix(t,e,o){const r=t.map(i=>i!==0?i*15:1500);this.paragraphs.push(new gt.Table({rows:await this.generateTableRows(e,o),columnWidths:r}))}async generateRowCells(t,e){const o=[];for(const r of t){const i=r.cellId;if(i===void 0)continue;const s=r.width*.9;o.push(new gt.TableCell({children:await this.convertBlocksFunc(i,e.blocks[i],e,this.appId,this.docId,this.state,s),columnSpan:r.colSpan,rowSpan:r.rowSpan,width:{type:gt.WidthType.DXA,size:r.width*15},shading:r.color?{fill:r.color,type:gt.ShadingType.CLEAR,color:"auto"}:void 0}))}return o}async generateTableRows(t,e){const o=[];for(const r of t)o.push(new gt.TableRow({children:await this.generateRowCells(r,e)}));return o}async addDoc(t,e,o){const r=await this.convertBlocksFunc(t,e.blocks.root,e,this.appId,this.docId,this.state,o);r&&(this.paragraphs=this.paragraphs.concat(r))}async addOtherEmbedBlock(){}}class YZ{constructor(t,e,o,r,i,s,l,a){m(this,"convertBlocks",async(t,e,o,r,i,s,l=720)=>{const a=new QZ(r,i,s,this.readImage,this.convertBlocks,this.defaultFontSize);return await qZ(t,e,o,a,r,i,this.md5HexFunc,this.getDocByBlock,this.getTextsByBox,l||720),a.paragraphs});this.templateData=t,this.docData=e,this.md5HexFunc=o,this.readImage=r,this.defaultFontSize=i,this.getDocByBlock=s,this.getTextsByBox=l,this.backgroundImageOptions=a}async convert(t,e){return this.snapshot2docx(this.docData,t,e)}async snapshot2docx(t,e,o){const r=new gt.ImportDotx,i=this.templateData?await r.extract(this.templateData):void 0,s=t.blocks.root;g(ZZ,s,"data must have blocks");const l=GZ(),a=await this.convertBlocks("blocks",s,t,e,o,l),d=this.backgroundImageOptions?{default:new gt.Header({children:[new gt.Paragraph({children:[new gt.ImageRun(this.backgroundImageOptions)]})]})}:{},h=new gt.Document({numbering:{config:[...dZ,...l.levelConfigs]},sections:[{headers:d,children:a,properties:{page:{size:{width:12240,height:15840},margin:{top:1440,bottom:1440,left:1440,right:1440}}}}]},{template:i});return gt.Packer.toBlob(h)}}async function JZ(n,t,e,o){const r=n.doc.buildResourceUrl(o,{withToken:!0});let i=await p7(r);if(!i)return;if(i.type.indexOf("/svg")!==-1){const l=await f7(i);l&&(i=new File([l],i.name))}return await i.arrayBuffer()}async function KZ(n,t,e){const o=n.editorBlocks.getBlockClass(e.type);if(o.toStandardDoc)return o.toStandardDoc(n,e,t)}async function XZ(n,t){const e=t.attributes,o=n.editorBoxes.getBoxClass(e.type);if(o.toStandardText)return o.toStandardText(n,e)}async function tQ(n,t){let{template:e,download:o,backgroundImageOptions:r}=t!=null?t:{};e||(e=iZ());const i=n.doc.toJSON(),s=(p,A,v)=>JZ(n,p,A,v),l=async(p,A,v)=>KZ(n,i,v),a=async p=>XZ(n,p),h=await new YZ(e,i,Pd.default,s,void 0,l,a,r).convert("_appId","_docId");if(o){const p=URL.createObjectURL(h),A=document.createElement("a");A.setAttribute("download",`${g7(n)}.docx`),A.setAttribute("href",`${p}`),A.click(),A.remove()}return h}const Q2=S("create-editor");async function eQ(n,t){var s,l,a,d,h,p,A,v,B,D,x,_,M,H;g(Q2,n,"app does not exists"),t.lang&&R.setLang(t.lang),Di.level=(s=t.logLevel)!=null?s:ua.DEBUG;const e=t.onReauth?async()=>{var ft;const z=t.user.userId,q=t.docId,rt=await((ft=t.onReauth)==null?void 0:ft.call(t,z,q,t.permission));return{userId:z,docId:q,permission:t.permission,appId:t.appId,token:rt,displayName:t.user.displayName,avatarUrl:t.user.avatarUrl}}:void 0,o={auth:{appId:t.appId,docId:t.docId,userId:t.user.userId,permission:t.permission,token:t.token,displayName:t.user.displayName,avatarUrl:t.user.avatarUrl},serverUrl:t.serverUrl,reauthFunc:e,disableLogout:t.disableLogout},r=await Ka.load(o),i=Ha(n,r,{id:t.id,scrollContainer:t==null?void 0:t.scrollContainer,enableComments:t==null?void 0:t.enableComments,components:{blocks:[...fk,...((l=t==null?void 0:t.components)==null?void 0:l.blocks)||[]],embeds:[...G2,...((a=t.components)==null?void 0:a.embeds)||[]],boxes:[...mk,...((d=t.components)==null?void 0:d.boxes)||[]],commandProviders:[new tf,...((h=t.components)==null?void 0:h.commandProviders)||[]],decorators:[new Df,new Ap],insertions:[bg],blockHooks:[new e2,new V7,...((p=t.components)==null?void 0:p.blockHooks)||[]],textRenders:[new e8,new g0],options:{...t.componentsOptions}},shortcuts:[bz,EN,fH,M0,Ly,IO,I0,eV,Mh,...t.shortcuts||[]],colors:["#338FE5","#24B47E","#F0A100","#E52727","#9678D3","#2CB2AE","#EB6414","#8AAB3F"]});if(i.editorCommandProviders.registerCommandProvider(new vr(i)),i.input.addHandler(new WV),i.input.addHandler(new xf),i.input.addHandler(new V_),i.input.addHandler(new cH),i.input.addHandler(new vu(i,{headingLevel:1,titlePlaceholder:R.t("placeholder.common.title"),contentPlaceholder:R.t("placeholder.common.content"),readonlyTitlePlaceholder:R.t("placeholder.common.readonlyTitle"),addPlaceholderToAllCurrentEmptyBlock:!0})),i.input.addHandler(new Af(i,(A=t.componentsOptions)==null?void 0:A.quickMenu)),i.input.addHandler(new c2(i)),i.input.addHandler(new f2(i)),i.input.addHandler(new yN),i.input.addHandler(new Of),i.doc.registerCallback(new qV(i)),i.addCustom("remote-cursor",()=>new qb(i)),i.addCustom("block-menu",z=>new G7(z)),i.addCustom("editor-tooltip",()=>new bf(i)),t!=null&&t.enableComments&&i.addCustom("editor-comments",z=>new t8(z,new XG(z))),i.addCustom("create-options",()=>new Y5(i,t)),i.addCustom("drop-target",()=>new Lu(i)),i.addCustom("list-to-mindmap",()=>new hf(i)),i.addCustom("list-to-mention",()=>new hW(i)),i.addCustom("mobile-helper",()=>new DW(i)),i.addCustom("code-caret",()=>new vN(i)),i.addCustom("image-paste-handler",()=>new l2(i)),(v=t.componentsOptions)!=null&&v.mention){const z=t.componentsOptions.mention;i.addCustom("mention",()=>new H8(i,z))}if(i.addCustom("heading-collapse",()=>new R2(i)),gc.register(i),Lu.register(i),ts.register(i),Ji.register(i),i.addListener("clickLink",(z,q,rt)=>{var Bt;if((Bt=t==null?void 0:t.events)!=null&&Bt.onClickLink){t.events.onClickLink(z,q,rt);return}const ft=rt.getAttribute("link");ft&&(z.readonly||q.ctrlKey||q.metaKey)&&window.open(ft,"_blank")}),(D=(B=t.componentsOptions)==null?void 0:B.remoteCarets)!=null&&D.onUserChanged){const z=(_=(x=t.componentsOptions)==null?void 0:x.remoteCarets)==null?void 0:_.onUserChanged;i.doc.getRemoteUsers().on("change",q=>{z(i,q)})}return(H=(M=t.componentsOptions)==null?void 0:M.templates)!=null&&H.templates.length&&(i.addListener("docChanged",()=>{e1(i)}),i.addListener("resize",()=>{e1(i,{reset:!0})}),setTimeout(()=>{e1(i)},100)),i.doc.registerCallback({onError:async z=>{if(z.code==="ResetDoc"){Q2.error(`reset doc: ${z.message}`);const q=await Ka.load(o);i.doc.reset(q)}}}),i}function nQ(n){return n.toJSON!==void 0}async function oQ(n,t,e){var i,s,l,a,d;g(Q2,n,"app does not exists");const o=nQ(t)?t:new Xg(t,{serverUrl:e.serverUrl||""});e.lang&&R.setLang(e.lang);const r=Ha(n,o,{id:e.id,scrollContainer:e==null?void 0:e.scrollContainer,components:{blocks:[L0,j0,U0,B9],commandProviders:[new tf],decorators:[new Df,new Ap],embeds:[...G2,...((i=e.components)==null?void 0:i.embeds)||[]],boxes:[_9,j8,c8,...((s=e.components)==null?void 0:s.boxes)||[]],insertions:[bg],blockHooks:[new e2,...((l=e.components)==null?void 0:l.blockHooks)||[]],textRenders:[new e8,new g0,...((a=e.components)==null?void 0:a.textRenders)||[]],options:{...e.componentsOptions}},shortcuts:[M0,Ly,I0,Mh]});return r.editorCommandProviders.registerCommandProvider(new vr(r)),r.input.addHandler(new xf),r.input.addHandler(new vu(r,{headingLevel:1,titlePlaceholder:R.t("placeholder.common.title"),contentPlaceholder:R.t("placeholder.common.content"),readonlyTitlePlaceholder:R.t("placeholder.local.readonlyTitle"),addPlaceholderToAllCurrentEmptyBlock:!0})),r.input.addHandler(new Af(r,(d=e.componentsOptions)==null?void 0:d.quickMenu)),r.input.addHandler(new c2(r)),r.input.addHandler(new f2(r)),r.input.addHandler(new Of),r.addCustom("block-menu",h=>new G7(h)),r.addCustom("editor-tooltip",()=>new bf(r)),r.addCustom("image-paste-handler",()=>new l2(r)),e!=null&&e.enableComments&&r.addCustom("editor-comments",h=>new t8(h,new tZ(h,o))),r.addCustom("heading-collapse",()=>new R2(r)),r.addListener("clickLink",(h,p,A)=>{var B;if((B=e==null?void 0:e.events)!=null&&B.onClickLink){e.events.onClickLink(h,p,A);return}const v=A.getAttribute("link");v&&(h.readonly||p.ctrlKey||p.metaKey)&&window.open(v,"_blank")}),gc.register(r),r}function rQ(n,t){var a;const e=n.doc;if(!((a=e.getVersionHelper)==null?void 0:a.call(e)))throw new Error("the editor does not support to show versions");const r=n.getCustom("create-options");if(!r)throw new Error("the editor does not support to show versions");const i=r.getData(),s=new gk(i),l=n.addCustom("version-dialog",()=>new E8(n.doc,s));return l.show(t),l}b.tippy=PB,b.AnchorBox=C6,b.AuthError=Wh,b.AuthHeader=Ja,b.AutoScroll=Qd,b.BaseURLHeader=qh,b.BasicCommands=g_,b.BlockExclusiveHook=V7,b.BlockLockerHook=e2,b.BlockLockerPasteHandler=Of,b.BlockResizer=Bu,b.BrBox=f6,b.CodeBlock=j0,b.CodeLineBlock=U0,b.CodeTextDecorator=Df,b.DefaultShortcuts=Mh,b.DocIdError=NS,b.DragDrop=uC,b.DrawioEmbed=nk,b.EditorBlocks=b4,b.EditorBoxes=g6,b.EditorCommandProviders=rb,b.EditorComplexBlockPosition=Mo,b.EditorComplexSelectionRange=ir,b.EditorDecorators=y6,b.EditorEmbeds=y4,b.EditorInsertions=v6,b.EditorSimpleBlockPosition=je,b.EditorSimpleSelectionRange=Ye,b.EmbedBlock=w4,b.EmbedBlockResizer=Pu,b.EnforceWithDocumentTitleHandler=vu,b.EventCallbacks=da,b.FILL_CHAR=sI,b.FileExtError=$S,b.GroupOrder=T9,b.HeadingBlockScrollListener=sW,b.ImageBox=p6,b.InlineBoxCommandProvider=F9,b.InputtingInsertion=A6,b.LocalDoc=Xg,b.LogLevel=ua,b.Logger=Di,b.MIN_DISTANCE_THRESHOLD=cC,b.ManualCloseDialog=ru,b.ManualMenu=Us,b.ManualToolbar=ou,b.MarkdownInputHandler=xf,b.MaxUserError=dp,b.Mindmap=d0,b.OnesEditorAutoSuggest=Fp,b.OnesEditorCustomDataWrapper=Y5,b.OnesEditorExclusiveBlock=Ji,b.OnesEditorHoveringBlock=Ce,b.OnesEditorQuickMenu=Af,b.OnesEditorToc=Nu,b.OnesEditorTocProvider=ts,b.OnesEditorToolbar=gc,b.OnesEditorTooltip=bf,b.OnesEditorVersionsDialog=E8,b.PermissionError=PS,b.Popup=Xa,b.RemoteCarets=qb,b.RemoteCaretsDecorator=Ap,b.RemoteCaretsInsertion=bg,b.RemoteUsers=Ph,b.RequestReloadError=Ya,b.RichText=ln,b.ShareDBDoc=Ka,b.ShareDBDocVersionsProvider=gk,b.SimpleCache=K5,b.StandardEmbedBlockCommands=I2,b.TEXT_STYLE_BACKGROUND_COLOR_PREFIX=ag,b.TEXT_STYLE_COLOR_PREFIX=cg,b.TableBlock=L0,b.TableBlockCommandProvider=tf,b.TableShortcuts=M0,b.TextBlock=Dn,b.TextBox=h6,b.TextStyleShortcuts=I0,b.TocEmbed=N8,b.ZERO_WIDTH_SPACE_CHAR=ha,b.abbreviation=Yd,b.addAttribute=hh,b.addClass=W,b.addCommentToBlock=Jf,b.addDays=xE,b.addMetaToDoc=Oh,b.addMonths=EE,b.animateScrollTo=vm,b.applyPlaceholderToBlock=If,b.assert=g,b.autoShowHideTemplates=e1,b.blockToDoc=Qg,b.blockToHtml=wg,b.blockToMarkdown=Bg,b.blockToText=vh,b.blocksToDoc=ET,b.clearAllSelection=t4,b.clientType=Ze,b.cloneBlock=Fi,b.cloneChildContainer=Og,b.cloneDoc=_g,b.cloneText=n6,b.commentToShareDbComment=Cp,b.compareElement=jd,b.comparePosition=Qm,b.complexBlockAdjustSelectionPos=rh,b.complexBlockFindNearestChildBlock=I4,b.complexBlockGeFirstSimpleChild=Jm,b.complexBlockGetAllChildContainers=gn,b.complexBlockGetBottomChildContainers=x4,b.complexBlockGetLastSimpleChild=zl,b.complexBlockGetSelectedContainers=Ms,b.complexBlockGetTopChildContainers=E4,b.containerToDoc=OA,b.continuousScroll=TC,b.convertBlockFrom=th,b.convertImageFileToPng=f7,b.convertImageSrcToPng=zP,b.copyBlockAttributes=O6,b.createBlockAnchor=zr,b.createBlockCaretAnchor=L4,b.createBlockContentElement=xs,b.createBlockElement=zC,b.createBlockSimpleDocRange=ph,b.createBlockSimpleRange=ke,b.createBoxContentElement=qC,b.createBoxElement=VC,b.createBoxOp=G4,b.createChildContainer=C4,b.createComplexBlockPosition=me,b.createComplexDocPos=c6,b.createComplexDocRange=aI,b.createContainer=i6,b.createContainerElement=Vm,b.createDeleteOps=z4,b.createEditor=Ha,b.createEditorSelectionRange=Ue,b.createElement=w,b.createEmptyContainer=qr,b.createEmptyDoc=Wr,b.createEmptyTextBlockData=mh,b.createExpandedRange=$d,b.createIconButton=$l,b.createImage=gm,b.createInsertOps=uh,b.createInsertionContentElement=QC,b.createInsertionElement=GC,b.createLocalEditor=oQ,b.createOnesEditor=eQ,b.createRange=X5,b.createRichText=Oi,b.createRootContainer=p4,b.createSimpleBlockPosition=st,b.createSimpleDocPos=l6,b.createTextBlockData=cr,b.createTextButton=Zs,b.createTextOp=co,b.createTextWithReplaceSoftReturn=ig,b.daysAfter=Sm,b.deleteText=lg,b.diffDays=IE,b.disablePageScroll=kC,b.docToHtml=D6,b.docToHtmlFragment=yh,b.docToMarkdown=Ma,b.docToText=La,b.downloadImageToFile=p7,b.downloadObjectToFile=H2,b.downloadSvgToString=G8,b.editLink=gu,b.editorAddComment=oz,b.editorAddTextAttribute=W6,b.editorAutoInsertBlock=_6,b.editorBreakTextBlock=Ql,b.editorClearCompositionText=R6,b.editorClearSelectedContents=Mg,b.editorCopyBlock=_h,b.editorDeleteBlock=Sg,b.editorDeleteBlockText=Tg,b.editorDeleteBlockWithoutChildren=Bh,b.editorDeleteChildContainer=oT,b.editorDeleteChildContainers=F6,b.editorFocusToBlock=Rg,b.editorFocusToEnd=wT,b.editorGetBlockData=_i,b.editorGetBlockText=pn,b.editorGetBlockTextEx=Ah,b.editorGetBoxData=u6,b.editorHandleKeyboardEvent=NA,b.editorInsertBlock=Zl,b.editorInsertBoxToBlock=L6,b.editorInsertDoc=z6,b.editorInsertDocAt=Fg,b.editorInsertText=Ig,b.editorInsertTextToBlock=S6,b.editorInsertTextToBlockEx=xg,b.editorMergeTextBlock=P6,b.editorMoveDown=oA,b.editorMoveEnd=Vg,b.editorMoveHome=fA,b.editorMoveLeft=tA,b.editorMoveLineEnd=yA,b.editorMoveLineHome=vA,b.editorMovePageDown=IA,b.editorMovePageUp=xA,b.editorMoveRight=eA,b.editorMoveUp=nA,b.editorMoveWordEnd=uA,b.editorMoveWordLeft=aA,b.editorRangeClearColor=G6,b.editorRangeGetColor=Pg,b.editorRangeSetColor=q6,b.editorRemoveTextAttribute=lT,b.editorReplaceBlockText=xh,b.editorReplaceContainer=V6,b.editorRunOnce=tp,b.editorSelectAll=MA,b.editorSelectContainer=Gg,b.editorSelectDown=rA,b.editorSelectEnd=Wg,b.editorSelectHome=mA,b.editorSelectLeft=iA,b.editorSelectLineEnd=bA,b.editorSelectLineHome=AA,b.editorSelectPageDown=DA,b.editorSelectPageUp=TA,b.editorSelectRight=sA,b.editorSelectUp=lA,b.editorSelectWordEnd=hA,b.editorSelectWordLeft=dA,b.editorSetTextColor=Yl,b.editorShowFindDialog=aU,b.editorToDocx=tQ,b.editorUpdateBlockData=Ih,b.editorUpdateCompositionText=M6,b.editorUpdateEmbedData=j6,b.enablePageScroll=wC,b.escapeHtmlText=iC,b.escapeRegExp=Om,b.escapeSpace=aE,b.exclusiveBlock=K0,b.executeBlockCommand=a4,b.executeEmbedBlockCommand=c4,b.executeRangeCommand=ob,b.fileToDataUrl=jl,b.findAfterOffsetNotType=pg,b.findAllText=fg,b.findEventTargetBlock=oC,b.findInsertionById=ZC,b.findNextOffset=xI,b.findNextVisibleSimpleBlock=ab,b.findPrevOffset=EI,b.findPrevOffsetNotType=gg,b.findPrevSimpleBlockBeforeChildContainer=B4,b.findPrevVisibleSimpleBlock=cb,b.findTarget=Hl,b.findWordEnd=Ag,b.findWordLeft=Cg,b.format=Aa,b.formatBytes=DC,b.formatDate=Mm,b.fragmentToHtml=BC,b.fromBase64=ga,b.fromBase64ToBlob=xm,b.fromBase64ToUint8Array=vE,b.fromDocRange=Mi,b.fromNowString=Rm,b.genId=K,b.getAllChildBlocks=Xm,b.getAllQuickMenuItems=x0,b.getAllSelectedBlocks=Ro,b.getAttributesAt=Ta,b.getBlockBackground=UC,b.getBlockByIndex=Fr,b.getBlockCaretRect=So,b.getBlockClass=Qt,b.getBlockClassByType=Ss,b.getBlockClientRects=Nr,b.getBlockCommandsWithHook=Um,b.getBlockContent=Lt,b.getBlockId=it,b.getBlockIndex=bt,b.getBlockInfo=Tu,b.getBlockKind=Do,b.getBlockMinWidth=n4,b.getBlockNearestRangeFromPoint=S4,b.getBlockOptions=NE,b.getBlockPath=Li,b.getBlockProperties=i4,b.getBlockRangeFromPoint=ih,b.getBlockStyles=PE,b.getBlockTextLength=ut,b.getBlockTools=te,b.getBlockType=Dt,b.getBoxContent=Pm,b.getBoxId=WC,b.getBoxTypeFromElement=ba,b.getChildBlockCount=Io,b.getChildBlocks=fe,b.getChildOffset=Os,b.getColorFromAttributes=dg,b.getColorFromContent=Jd,b.getComplexBlockClass=zn,b.getContainerBlockPath=f4,b.getContainerBlocks=XC,b.getContainerBlocksElement=nh,b.getContainerById=jr,b.getContainerId=ct,b.getContainerMinWidth=qm,b.getContainerToolsElement=zE,b.getContainerWidth=A4,b.getDistanceSquare=nr,b.getElementOffset=fa,b.getElementScale=vs,b.getEmbedType=fn,b.getExistsBlockTools=Xd,b.getExistsContainerById=h4,b.getFileExt=Ca,b.getFirstChildBlock=ye,b.getFirstClientRect=Hd,b.getHeadingMenuOptions=k0,b.getHorizontalPadding=pm,b.getInsertionContent=Nm,b.getLastChildBlock=Qe,b.getLastClientRect=As,b.getListAllNextBrothers=uc,b.getLogger=S,b.getNextBlock=Zt,b.getNextValidOffset=_s,b.getNextVisibleBlock=Ts,b.getOffsetInfoAfter=Sa,b.getOffsetInfoBefore=bh,b.getOpAt=Q4,b.getOpLength=dh,b.getParentBlock=et,b.getParentBlockExcludeSelf=Es,b.getParentBox=Fm,b.getParentContainer=nt,b.getPrevBlock=ce,b.getPrevValidOffset=Ri,b.getPrevVisibleBlock=Is,b.getRangeCommands=eb,b.getRootBlock=jm,b.getScrollContainer=ro,b.getSpecialBlockCommands=s4,b.getStandardEmbedBlockProperties=T2,b.getTextAfterOffset=wI,b.getTextAttributes=Eg,b.getTextBeforeOffset=BI,b.getTextBlockChild=eh,b.getTextBlockClass=JC,b.getTextBlockContentChildTextLength=lo,b.getTextBlockContentChildType=u4,b.getTextBlockContentChildren=rr,b.getTextLength=rn,b.getTextOpLength=tg,b.getTextWidth=qd,b.getToolbar=lf,b.handleBlockElementUpdated=o4,b.hasAltOnly=gE,b.hasClass=xt,b.hasCtrlOrCmd=CC,b.hasCtrlOrCmdOnly=mE,b.hashCode=FC,b.hideBlock=HC,b.htmlToFragment=Wd,b.i18n=R,b.injectDocToHtmlFragment=Rh,b.injectStyle=lC,b.insertEmptyBlock=jE,b.insertEmptyEmbedBlock=zm,b.insertText=Vr,b.intersectionCommands=SD,b.isBackspace=bC,b.isBlock=Bs,b.isBlockLocked=Rf,b.isBlockLockedByOthers=t2,b.isBlockLockedBySelf=Du,b.isBlockTools=$C,b.isBox=_m,b.isCJK=mC,b.isChildContainer=Lo,b.isChildNode=Xt,b.isCollapsedRange=cI,b.isComplexBlockPosition=Zm,b.isComplexKindBlock=Mt,b.isContainer=Pr,b.isContainerSelectedAllChildBlocks=SA,b.isControlEvent=ks,b.isDelete=CE,b.isDraggingFiles=Gd,b.isElementVisible=bm,b.isEmbedBlock=Me,b.isEmptyContainer=wa,b.isEmptyDoc=mg,b.isEmptyTextBlock=ae,b.isEmptyTextBlockWithoutCompositionText=bu,b.isEnterOnly=AC,b.isEscape=Bm,b.isExclusiveBlock=Mf,b.isFirefox=Vd,b.isFirstChildBlockInComplexBlock=yx,b.isHighSurrogate=oE,b.isInBlock=$m,b.isInBlockTools=Ds,b.isLetter=fC,b.isLowSurrogate=mm,b.isMatchShortcut=or,b.isMoveForward=hE,b.isNavigationEvent=dE,b.isNavigationKey=pC,b.isNodeRemoved=eC,b.isNumber=hC,b.isPrintableKey=wm,b.isRootBlock=io,b.isRootContainer=Yt,b.isSafari=gC,b.isSameDay=Lm,b.isSecureEnv=$0,b.isShiftEnter=pE,b.isShiftTab=bE,b.isShortcutEvent=fE,b.isSimpleBlock=FE,b.isSimpleBlockPosition=Ur,b.isSimplePos=s6,b.isSimpleRange=gh,b.isSpace=zd,b.isTab=AE,b.isTextBlockContentBoxChild=so,b.isTextBlockContentChild=ya,b.isTextBlockContentInsertionChild=Hr,b.isTextBlockContentTextChild=ka,b.isTextKindBlock=tt,b.isTextKindBlockType=va,b.isToday=SC,b.isValidOffset=sn,b.isVisibleBlock=Kd,b.isYesterday=LC,b.loadJs=nC,b.loadJsPromise=bs,b.lockers=Eo,b.mergeCommands=sf,b.mergeDocs=Ns,b.mergeOps=sg,b.mergeText=nI,b.multiSplitText=O4,b.overflowText=MC,b.parseShortcut=vC,b.patchNode=pa,b.pointInRect=ys,b.rangeAddAttribute=Ia,b.rangeGetTextColor=e6,b.rangeRemoveAttribute=Wl,b.rangeSetTextColor=K4,b.rangeTransformText=Y4,b.registerDragDrop=ym,b.removeAttribute=ug,b.removeClass=ot,b.removeLastBr=Kx,b.removePlaceholderFromBlock=i7,b.removeStyle=sC,b.replaceAll=TE,b.replaceAllCaseInsensitive=DE,b.replaceAllText=r6,b.replaceText=fh,b.requestDownload=Zd,b.resetListStart=hc,b.scrollable=IC,b.selectFile=Ul,b.selectedBlockToDoc=Dh,b.selectionToDoc=Sh,b.setAttributes=Ud,b.setClipboardData=Dm,b.setClipboardDataByEvent=BE,b.setColorToAttributes=X4,b.setDataset=Cm,b.setDefaultCursor=ma,b.setStyles=Am,b.shareDBCommentToDocObject=pp,b.shareDBDocCommentToComment=Vb,b.shortcutToDisplayText=xo,b.showBlock=jC,b.showDocVersions=rQ,b.splitText=Tn,b.splitToThree=ze,b.stringToDataUrl=Im,b.stringToObjectUrl=Tm,b.subText=_4,b.textNodeOffsetFromPoint=tC,b.titleFromEditor=g7,b.toBase64URL=Si,b.toMindmap=df,b.toPlainText=ie,b.toPlainTextKeepLength=hg,b.trimChar=km,b.unexclusiveBlock=X0,b.unicodeLength=rE,b.unicodeSubstr=iE,b.updateBlockSelection=e4,b.updateOpAttributes=o6,b.updateTextBlockContent=kI,b.updateUrl=Em;for(const n in ve)n!=="default"&&!b.hasOwnProperty(n)&&Object.defineProperty(b,n,{enumerable:!0,get:()=>ve[n]});Object.defineProperties(b,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});