mind-elixir 3.2.2 → 3.2.4
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/MindElixir.iife.js +9 -9
- package/dist/MindElixir.js +854 -839
- package/dist/MindElixirLite.iife.js +5 -5
- package/dist/MindElixirLite.js +169 -151
- package/dist/types/customLink.d.ts +1 -0
- package/dist/types/docs.d.ts +6 -0
- package/dist/types/index.d.ts +17 -16
- package/dist/types/linkDiv.d.ts +2 -1
- package/dist/types/methods.d.ts +20 -16
- package/dist/types/plugin/exportImage.d.ts +2 -2
- package/dist/types/types/dom.d.ts +2 -1
- package/dist/types/types/index.d.ts +4 -2
- package/package.json +1 -1
- package/readme.md +8 -11
package/dist/MindElixirLite.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".mind-elixir{--gap: 30px;--root-radius: 30px;--main-radius: 20px;--root-color: #ffffff;--root-bgcolor: #4c4f69;--main-color: #444446;--main-bgcolor: #ffffff;--topic-padding: 3px;--color: #777777;--bgcolor: #f6f6f6;--selected: #4dc4ff;--panel-color: #444446;--panel-bgcolor: #ffffff;--panel-border-color: #eaeaea;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0);font-family:-apple-system,BlinkMacSystemFont,Helvetica Neue,PingFang SC,Microsoft YaHei,Source Han Sans SC,Noto Sans CJK SC,WenQuanYi Micro Hei,sans-serif}.mind-elixir .hyper-link{text-decoration:none}.map-container{-webkit-user-select:none;user-select:none;height:100%;width:100%;overflow:scroll;font-size:15px}.map-container::-webkit-scrollbar{width:0px;height:0px}.map-container .selected{box-shadow:0 0 0 2px var(--selected)}.map-container .lhs{direction:rtl}.map-container .lhs me-tpc{direction:ltr}.map-container .map-canvas{height:20000px;width:20000px;position:relative;-webkit-user-select:none;user-select:none;transition:transform .3s;transform:scale(1);background-color:var(--bgcolor)}.map-container .map-canvas me-nodes{position:absolute;display:flex;justify-content:center;align-items:center;height:fit-content;width:fit-content}.map-container .map-canvas me-root{position:relative}.map-container .map-canvas me-root me-tpc{display:block;font-size:25px;line-height:1.2em;color:var(--root-color);padding:10px var(--gap);border-radius:var(--root-radius);white-space:pre-wrap;background-color:var(--root-bgcolor)}.map-container .map-canvas me-root me-tpc #input-box{padding:10px var(--gap)}.map-container me-main>me-wrapper{position:relative;margin:20px 65px}.map-container me-main>me-wrapper>me-parent{margin:var(--gap);padding:0}.map-container me-main>me-wrapper>me-parent>me-tpc{border-radius:var(--main-radius);background-color:var(--main-bgcolor);border:2px solid var(--main-color);color:var(--main-color);padding:8px var(--gap)}.map-container me-main>me-wrapper>me-parent>me-tpc #input-box{padding:8px var(--gap)}.map-container me-wrapper{display:block;pointer-events:none;width:fit-content}.map-container me-children,.map-container me-parent{display:inline-block;vertical-align:middle}.map-container me-parent{position:relative;cursor:pointer;padding:6px var(--gap);margin-top:10px}.map-container me-parent me-tpc{position:relative;display:block;border-radius:3px;color:var(--color);pointer-events:all;max-width:35em;white-space:pre-wrap;padding:var(--topic-padding);line-height:1.2em}.map-container me-parent me-tpc>div,.map-container me-parent me-tpc>span,.map-container me-parent me-tpc>img{pointer-events:none}.map-container me-parent me-tpc .insert-preview{position:absolute;width:100%;left:0;z-index:9}.map-container me-parent me-tpc .show{background:#7ad5ff;pointer-events:none;opacity:.7}.map-container me-parent me-tpc .before{height:14px;top:-14px}.map-container me-parent me-tpc .in{height:100%;top:0}.map-container me-parent me-tpc .after{height:14px;bottom:-14px}.map-container me-parent me-epd{position:absolute;height:18px;width:18px;opacity:.8;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgdD0iMTY1NjY1NDcxNzI0MiIgY2xhc3M9Imljb24iIHZpZXdCb3g9IjAgMCAxMDI0IDEwMjQiIHZlcnNpb249IjEuMSIKICAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+CiAgICA8cGF0aCBkPSJNNTEyIDc0LjY2NjY2N0MyNzAuOTMzMzMzIDc0LjY2NjY2NyA3NC42NjY2NjcgMjcwLjkzMzMzMyA3NC42NjY2NjcgNTEyUzI3MC45MzMzMzMgOTQ5LjMzMzMzMyA1MTIgOTQ5LjMzMzMzMyA5NDkuMzMzMzMzIDc1My4wNjY2NjcgOTQ5LjMzMzMzMyA1MTIgNzUzLjA2NjY2NyA3NC42NjY2NjcgNTEyIDc0LjY2NjY2N3oiIHN0cm9rZS13aWR0aD0iNTQiIHN0cm9rZT0nYmxhY2snIGZpbGw9J3doaXRlJyA+PC9wYXRoPgogICAgPHBhdGggZD0iTTY4Mi42NjY2NjcgNDgwaC0xMzguNjY2NjY3VjM0MS4zMzMzMzNjMC0xNy4wNjY2NjctMTQuOTMzMzMzLTMyLTMyLTMycy0zMiAxNC45MzMzMzMtMzIgMzJ2MTM4LjY2NjY2N0gzNDEuMzMzMzMzYy0xNy4wNjY2NjcgMC0zMiAxNC45MzMzMzMtMzIgMzJzMTQuOTMzMzMzIDMyIDMyIDMyaDEzOC42NjY2NjdWNjgyLjY2NjY2N2MwIDE3LjA2NjY2NyAxNC45MzMzMzMgMzIgMzIgMzJzMzItMTQuOTMzMzMzIDMyLTMydi0xMzguNjY2NjY3SDY4Mi42NjY2NjdjMTcuMDY2NjY3IDAgMzItMTQuOTMzMzMzIDMyLTMycy0xNC45MzMzMzMtMzItMzItMzJ6Ij48L3BhdGg+Cjwvc3ZnPg==);background-repeat:no-repeat;background-size:contain;background-position:center;pointer-events:all;z-index:9}.map-container me-parent me-epd.minus{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgdD0iMTY1NjY1NTU2NDk4NSIgY2xhc3M9Imljb24iIHZpZXdCb3g9IjAgMCAxMDI0IDEwMjQiIHZlcnNpb249IjEuMSIKICAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+CiAgICA8cGF0aCBkPSJNNTEyIDc0LjY2NjY2N0MyNzAuOTMzMzMzIDc0LjY2NjY2NyA3NC42NjY2NjcgMjcwLjkzMzMzMyA3NC42NjY2NjcgNTEyUzI3MC45MzMzMzMgOTQ5LjMzMzMzMyA1MTIgOTQ5LjMzMzMzMyA5NDkuMzMzMzMzIDc1My4wNjY2NjcgOTQ5LjMzMzMzMyA1MTIgNzUzLjA2NjY2NyA3NC42NjY2NjcgNTEyIDc0LjY2NjY2N3oiIHN0cm9rZS13aWR0aD0iNTQiIHN0cm9rZT0nYmxhY2snIGZpbGw9J3doaXRlJyA+PC9wYXRoPgogICAgPHBhdGggZD0iTTY4Mi42NjY2NjcgNTQ0SDM0MS4zMzMzMzNjLTE3LjA2NjY2NyAwLTMyLTE0LjkzMzMzMy0zMi0zMnMxNC45MzMzMzMtMzIgMzItMzJoMzQxLjMzMzMzNGMxNy4wNjY2NjcgMCAzMiAxNC45MzMzMzMgMzIgMzJzLTE0LjkzMzMzMyAzMi0zMiAzMnoiPjwvcGF0aD4KPC9zdmc+)!important;transition:opacity .3s;opacity:0}.map-container me-parent me-epd.minus:hover{opacity:.8}.map-container .icon{width:1em;height:1em;vertical-align:-.15em;fill:currentColor;overflow:hidden}.map-container .lines,.map-container .summary,.map-container .subLines,.map-container .topiclinks,.map-container .linkcontroller{position:absolute;height:102%;width:100%;top:0;left:0}.map-container .topiclinks,.map-container .linkcontroller,.map-container .summary{pointer-events:none}.map-container .topiclinks text,.map-container .linkcontroller text,.map-container .summary text{pointer-events:all}.map-container .topiclinks .selected,.map-container .linkcontroller .selected,.map-container .summary .selected{pointer-events:none}.map-container .lines,.map-container .subLines{pointer-events:none;z-index:-1}.map-container .topiclinks *,.map-container .linkcontroller *{z-index:100}.map-container .topiclinks g{cursor:pointer}.map-container #input-box{position:absolute;top:0;left:0;padding:var(--topic-padding);color:var(--color);background-color:var(--bgcolor);width:max-content;max-width:35em;z-index:11;direction:ltr;-webkit-user-select:auto;user-select:auto;pointer-events:all}.map-container me-tpc>img{pointer-events:none;display:block;margin-top:8px}.map-container .circle{position:absolute;height:10px;width:10px;margin-top:-5px;margin-left:-5px;border-radius:100%;background:#aaa;cursor:pointer}.map-container .tags{direction:ltr}.map-container .tags span{display:inline-block;border-radius:3px;padding:2px 4px;background:#d6f0f8;color:#276f86;margin:2px 3px 0 0;font-size:12px;line-height:1.3em}.map-container .icons{display:inline-block;direction:ltr;margin-right:10px}.map-container .icons span{display:inline-block}.map-container .mind-elixir-ghost{position:fixed;top:-100%;left:-100%;box-sizing:content-box;opacity:.5;background-color:#f6f6f6;max-width:200px;width:fit-content;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:8px 16px;border-radius:6px;border:#666666 2px solid}.selection-area{background:#4f90f22d;border:1px solid #4f90f2}.mind-elixir .context-menu{position:fixed;top:0;left:0;width:100%;height:100%;z-index:99}.mind-elixir .context-menu .menu-list{position:fixed;list-style:none;margin:0;padding:0;font:300 15px Roboto,sans-serif;color:var(--panel-color);box-shadow:0 12px 15px #0003}.mind-elixir .context-menu .menu-list li{min-width:200px;overflow:hidden;white-space:nowrap;padding:10px 14px;background:var(--panel-bgcolor);border-bottom:1px solid var(--panel-border-color)}.mind-elixir .context-menu .menu-list li a{color:#333;text-decoration:none}.mind-elixir .context-menu .menu-list li.disabled{display:none;color:#5e5e5e;background-color:#f7f7f7}.mind-elixir .context-menu .menu-list li.disabled:hover{cursor:default;background-color:#f7f7f7}.mind-elixir .context-menu .menu-list li:hover{cursor:pointer;filter:brightness(.9)}.mind-elixir .context-menu .menu-list li:first-child{border-radius:5px 5px 0 0}.mind-elixir .context-menu .menu-list li:last-child{border-bottom:0;border-radius:0 0 5px 5px}.mind-elixir .context-menu .menu-list li span:last-child{float:right}.mind-elixir .tips{position:absolute;bottom:20px;left:50%;transform:translate(-50%);color:var(--panel-color);font-weight:bolder}.mind-elixir .mobile-menu{position:absolute;left:20px;bottom:70px;z-index:99;margin:0;padding:0;color:#333;border-radius:5px;box-shadow:0 12px 15px #0003;overflow:hidden}.mind-elixir .mobile-menu *{transition:color .4s,background-color .4s}.mind-elixir .mobile-menu div{float:left;text-align:center;width:30px;overflow:hidden;white-space:nowrap;padding:8px;background-color:#fff;border-bottom:1px solid #ecf0f1}.mind-elixir .mobile-menu div a{color:#333;text-decoration:none}.mind-elixir .mobile-menu div.disabled{color:#5e5e5e;background-color:#f7f7f7}.mind-elixir .mobile-menu div.disabled:hover{cursor:default;background-color:#f7f7f7}.mind-elixir .mobile-menu div:hover{cursor:pointer;background-color:#ecf0f1}.mind-elixir-toolbar{font-family:iconfont;position:absolute;color:var(--panel-color);background:var(--panel-bgcolor);padding:10px;border-radius:5px;box-shadow:0 1px 2px #0003}.mind-elixir-toolbar svg{display:inline-block}.mind-elixir-toolbar span:active{opacity:.5}.mind-elixir-toolbar.rb{right:20px;bottom:20px}.mind-elixir-toolbar.rb span+span{margin-left:10px}.mind-elixir-toolbar.lt{font-size:20px;left:20px;top:20px}.mind-elixir-toolbar.lt span{display:block}.mind-elixir-toolbar.lt span+span{margin-top:10px}")),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
|
|
1
|
+
(function(){"use strict";try{if(typeof document<"u"){var i=document.createElement("style");i.appendChild(document.createTextNode(".mind-elixir{--gap: 30px;--root-radius: 30px;--main-radius: 20px;--root-color: #ffffff;--root-bgcolor: #4c4f69;--main-color: #444446;--main-bgcolor: #ffffff;--topic-padding: 3px;--color: #777777;--bgcolor: #f6f6f6;--selected: #4dc4ff;--panel-color: #444446;--panel-bgcolor: #ffffff;--panel-border-color: #eaeaea;position:relative;-webkit-tap-highlight-color:rgba(0,0,0,0);font-family:-apple-system,BlinkMacSystemFont,Helvetica Neue,PingFang SC,Microsoft YaHei,Source Han Sans SC,Noto Sans CJK SC,WenQuanYi Micro Hei,sans-serif}.mind-elixir .hyper-link{text-decoration:none}.map-container{-webkit-user-select:none;user-select:none;height:100%;width:100%;overflow:scroll;font-size:15px}.map-container::-webkit-scrollbar{width:0px;height:0px}.map-container .selected{box-shadow:0 0 0 2px var(--selected)}.map-container .lhs{direction:rtl}.map-container .lhs me-tpc{direction:ltr}.map-container .map-canvas{height:20000px;width:20000px;position:relative;-webkit-user-select:none;user-select:none;transition:transform .3s;transform:scale(1);background-color:var(--bgcolor)}.map-container .map-canvas me-nodes{position:absolute;display:flex;justify-content:center;align-items:center;height:fit-content;width:fit-content}.map-container .map-canvas me-root{position:relative}.map-container .map-canvas me-root me-tpc{display:block;font-size:25px;line-height:1.2em;color:var(--root-color);padding:10px var(--gap);border-radius:var(--root-radius);white-space:pre-wrap;background-color:var(--root-bgcolor)}.map-container .map-canvas me-root me-tpc #input-box{padding:10px var(--gap)}.map-container me-main>me-wrapper{position:relative;margin:20px 65px}.map-container me-main>me-wrapper>me-parent{margin:var(--gap);padding:0}.map-container me-main>me-wrapper>me-parent>me-tpc{border-radius:var(--main-radius);background-color:var(--main-bgcolor);border:2px solid var(--main-color);color:var(--main-color);padding:8px var(--gap)}.map-container me-main>me-wrapper>me-parent>me-tpc #input-box{padding:8px var(--gap)}.map-container me-wrapper{display:block;pointer-events:none;width:fit-content}.map-container me-children,.map-container me-parent{display:inline-block;vertical-align:middle}.map-container me-parent{position:relative;cursor:pointer;padding:6px var(--gap);margin-top:10px}.map-container me-parent me-tpc{position:relative;display:block;border-radius:3px;color:var(--color);pointer-events:all;max-width:35em;white-space:pre-wrap;padding:var(--topic-padding);line-height:1.2em}.map-container me-parent me-tpc .insert-preview{position:absolute;width:100%;left:0;z-index:9}.map-container me-parent me-tpc .show{background:#7ad5ff;pointer-events:none;opacity:.7}.map-container me-parent me-tpc .before{height:14px;top:-14px}.map-container me-parent me-tpc .in{height:100%;top:0}.map-container me-parent me-tpc .after{height:14px;bottom:-14px}.map-container me-parent me-epd{position:absolute;height:18px;width:18px;opacity:.8;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgdD0iMTY1NjY1NDcxNzI0MiIgY2xhc3M9Imljb24iIHZpZXdCb3g9IjAgMCAxMDI0IDEwMjQiIHZlcnNpb249IjEuMSIKICAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+CiAgICA8cGF0aCBkPSJNNTEyIDc0LjY2NjY2N0MyNzAuOTMzMzMzIDc0LjY2NjY2NyA3NC42NjY2NjcgMjcwLjkzMzMzMyA3NC42NjY2NjcgNTEyUzI3MC45MzMzMzMgOTQ5LjMzMzMzMyA1MTIgOTQ5LjMzMzMzMyA5NDkuMzMzMzMzIDc1My4wNjY2NjcgOTQ5LjMzMzMzMyA1MTIgNzUzLjA2NjY2NyA3NC42NjY2NjcgNTEyIDc0LjY2NjY2N3oiIHN0cm9rZS13aWR0aD0iNTQiIHN0cm9rZT0nYmxhY2snIGZpbGw9J3doaXRlJyA+PC9wYXRoPgogICAgPHBhdGggZD0iTTY4Mi42NjY2NjcgNDgwaC0xMzguNjY2NjY3VjM0MS4zMzMzMzNjMC0xNy4wNjY2NjctMTQuOTMzMzMzLTMyLTMyLTMycy0zMiAxNC45MzMzMzMtMzIgMzJ2MTM4LjY2NjY2N0gzNDEuMzMzMzMzYy0xNy4wNjY2NjcgMC0zMiAxNC45MzMzMzMtMzIgMzJzMTQuOTMzMzMzIDMyIDMyIDMyaDEzOC42NjY2NjdWNjgyLjY2NjY2N2MwIDE3LjA2NjY2NyAxNC45MzMzMzMgMzIgMzIgMzJzMzItMTQuOTMzMzMzIDMyLTMydi0xMzguNjY2NjY3SDY4Mi42NjY2NjdjMTcuMDY2NjY3IDAgMzItMTQuOTMzMzMzIDMyLTMycy0xNC45MzMzMzMtMzItMzItMzJ6Ij48L3BhdGg+Cjwvc3ZnPg==);background-repeat:no-repeat;background-size:contain;background-position:center;pointer-events:all;z-index:9}.map-container me-parent me-epd.minus{background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBzdGFuZGFsb25lPSJubyI/PjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgdD0iMTY1NjY1NTU2NDk4NSIgY2xhc3M9Imljb24iIHZpZXdCb3g9IjAgMCAxMDI0IDEwMjQiIHZlcnNpb249IjEuMSIKICAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCI+CiAgICA8cGF0aCBkPSJNNTEyIDc0LjY2NjY2N0MyNzAuOTMzMzMzIDc0LjY2NjY2NyA3NC42NjY2NjcgMjcwLjkzMzMzMyA3NC42NjY2NjcgNTEyUzI3MC45MzMzMzMgOTQ5LjMzMzMzMyA1MTIgOTQ5LjMzMzMzMyA5NDkuMzMzMzMzIDc1My4wNjY2NjcgOTQ5LjMzMzMzMyA1MTIgNzUzLjA2NjY2NyA3NC42NjY2NjcgNTEyIDc0LjY2NjY2N3oiIHN0cm9rZS13aWR0aD0iNTQiIHN0cm9rZT0nYmxhY2snIGZpbGw9J3doaXRlJyA+PC9wYXRoPgogICAgPHBhdGggZD0iTTY4Mi42NjY2NjcgNTQ0SDM0MS4zMzMzMzNjLTE3LjA2NjY2NyAwLTMyLTE0LjkzMzMzMy0zMi0zMnMxNC45MzMzMzMtMzIgMzItMzJoMzQxLjMzMzMzNGMxNy4wNjY2NjcgMCAzMiAxNC45MzMzMzMgMzIgMzJzLTE0LjkzMzMzMyAzMi0zMiAzMnoiPjwvcGF0aD4KPC9zdmc+)!important;transition:opacity .3s;opacity:0}.map-container me-parent me-epd.minus:hover{opacity:.8}.map-container .icon{width:1em;height:1em;vertical-align:-.15em;fill:currentColor;overflow:hidden}.map-container .lines,.map-container .summary,.map-container .subLines,.map-container .topiclinks,.map-container .linkcontroller{position:absolute;height:102%;width:100%;top:0;left:0}.map-container .topiclinks,.map-container .linkcontroller,.map-container .summary{pointer-events:none}.map-container .topiclinks text,.map-container .linkcontroller text,.map-container .summary text{pointer-events:all}.map-container .topiclinks .selected,.map-container .linkcontroller .selected,.map-container .summary .selected{pointer-events:none}.map-container .lines,.map-container .subLines{pointer-events:none;z-index:-1}.map-container .topiclinks *,.map-container .linkcontroller *{z-index:100}.map-container .topiclinks g{cursor:pointer}.map-container #input-box{position:absolute;top:0;left:0;padding:var(--topic-padding);color:var(--color);background-color:var(--bgcolor);width:max-content;max-width:35em;z-index:11;direction:ltr;-webkit-user-select:auto;user-select:auto;pointer-events:all}.map-container me-tpc>div,.map-container me-tpc>span,.map-container me-tpc>img{pointer-events:none}.map-container me-tpc>img{display:block;margin-bottom:8px;object-fit:cover}.map-container .circle{position:absolute;height:10px;width:10px;margin-top:-5px;margin-left:-5px;border-radius:100%;background:#aaa;cursor:pointer}.map-container .tags{direction:ltr}.map-container .tags span{display:inline-block;border-radius:3px;padding:2px 4px;background:#d6f0f8;color:#276f86;margin:2px 3px 0 0;font-size:12px;line-height:1.3em}.map-container .icons{display:inline-block;direction:ltr;margin-right:10px}.map-container .icons span{display:inline-block}.map-container .mind-elixir-ghost{position:fixed;top:-100%;left:-100%;box-sizing:content-box;opacity:.5;background-color:#f6f6f6;max-width:200px;width:fit-content;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:8px 16px;border-radius:6px;border:#666666 2px solid}.map-container .selection-area{background:#4f90f22d;border:1px solid #4f90f2}.mind-elixir .context-menu{position:fixed;top:0;left:0;width:100%;height:100%;z-index:99}.mind-elixir .context-menu .menu-list{position:fixed;list-style:none;margin:0;padding:0;font:300 15px Roboto,sans-serif;color:var(--panel-color);box-shadow:0 12px 15px #0003}.mind-elixir .context-menu .menu-list li{min-width:200px;overflow:hidden;white-space:nowrap;padding:10px 14px;background:var(--panel-bgcolor);border-bottom:1px solid var(--panel-border-color)}.mind-elixir .context-menu .menu-list li a{color:#333;text-decoration:none}.mind-elixir .context-menu .menu-list li.disabled{display:none;color:#5e5e5e;background-color:#f7f7f7}.mind-elixir .context-menu .menu-list li.disabled:hover{cursor:default;background-color:#f7f7f7}.mind-elixir .context-menu .menu-list li:hover{cursor:pointer;filter:brightness(.9)}.mind-elixir .context-menu .menu-list li:first-child{border-radius:5px 5px 0 0}.mind-elixir .context-menu .menu-list li:last-child{border-bottom:0;border-radius:0 0 5px 5px}.mind-elixir .context-menu .menu-list li span:last-child{float:right}.mind-elixir .tips{position:absolute;bottom:20px;left:50%;transform:translate(-50%);color:var(--panel-color);font-weight:bolder}.mind-elixir .mobile-menu{position:absolute;left:20px;bottom:70px;z-index:99;margin:0;padding:0;color:#333;border-radius:5px;box-shadow:0 12px 15px #0003;overflow:hidden}.mind-elixir .mobile-menu *{transition:color .4s,background-color .4s}.mind-elixir .mobile-menu div{float:left;text-align:center;width:30px;overflow:hidden;white-space:nowrap;padding:8px;background-color:#fff;border-bottom:1px solid #ecf0f1}.mind-elixir .mobile-menu div a{color:#333;text-decoration:none}.mind-elixir .mobile-menu div.disabled{color:#5e5e5e;background-color:#f7f7f7}.mind-elixir .mobile-menu div.disabled:hover{cursor:default;background-color:#f7f7f7}.mind-elixir .mobile-menu div:hover{cursor:pointer;background-color:#ecf0f1}.mind-elixir-toolbar{font-family:iconfont;position:absolute;color:var(--panel-color);background:var(--panel-bgcolor);padding:10px;border-radius:5px;box-shadow:0 1px 2px #0003}.mind-elixir-toolbar svg{display:inline-block}.mind-elixir-toolbar span:active{opacity:.5}.mind-elixir-toolbar.rb{right:20px;bottom:20px}.mind-elixir-toolbar.rb span+span{margin-left:10px}.mind-elixir-toolbar.lt{font-size:20px;left:20px;top:20px}.mind-elixir-toolbar.lt span{display:block}.mind-elixir-toolbar.lt span+span{margin-top:10px}")),document.head.appendChild(i)}}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
|
|
2
2
|
(function(e) {
|
|
3
3
|
var t, n, s, i, o, r, l = '<svg><symbol id="icon-edit" viewBox="0 0 1024 1024"><path d="M423.765333 128a42.666667 42.666667 0 0 1 3.2 85.205333L423.765333 213.333333H234.666667a64 64 0 0 0-63.872 60.245334L170.666667 277.333333v512a64 64 0 0 0 60.245333 63.872L234.666667 853.333333h512a64 64 0 0 0 63.872-60.245333L810.666667 789.333333v-189.098666a42.666667 42.666667 0 0 1 85.205333-3.2l0.128 3.2V789.333333a149.333333 149.333333 0 0 1-144.213333 149.248L746.666667 938.666667h-512a149.333333 149.333333 0 0 1-149.248-144.213334L85.333333 789.333333v-512a149.333333 149.333333 0 0 1 144.213334-149.248L234.666667 128h189.098666z m324.949334-53.248a42.666667 42.666667 0 0 1 60.330666 0l150.869334 150.869333a42.666667 42.666667 0 0 1 0 60.330667l-329.386667 329.386667a42.666667 42.666667 0 0 1-29.44 12.458666l-153.386667 2.517334a42.666667 42.666667 0 0 1-43.349333-43.349334l2.56-153.386666a42.666667 42.666667 0 0 1 12.458667-29.44z m30.165333 90.496L491.946667 452.266667l-1.493334 91.989333 92.032-1.493333 286.976-286.976-90.538666-90.538667z" ></path></symbol><symbol id="icon-rising" viewBox="0 0 1024 1024"><path d="M553.173333 803.84h-64l0.021334-474.581333-224.021334 224-45.269333-45.226667L521.6 206.293333l301.717333 301.696-45.269333 45.269334-224.853333-224.896v475.477333z" ></path></symbol><symbol id="icon-falling" viewBox="0 0 1024 1024"><path d="M553.173333 238.314667h-64l0.021334 474.602666-224.021334-224-45.269333 45.226667L521.6 835.861333l301.717333-301.717333-45.269333-45.226667-224.853333 224.853334V238.336z" ></path></symbol><symbol id="icon-shanchu2" viewBox="0 0 1024 1024"><path d="M516.60601807 107.93026734c-82.64382935 0-149.71865844 65.51751709-152.5729065 147.77160644H171.37136841c-21.40603638 0-38.92044068 17.38504028-38.92044068 38.92126465 0 21.40686036 17.38504028 38.92208862 38.92126466 38.92208862h42.94308471v435.40136719c0 81.73498536 55.39828492 148.55026245 123.90106201 148.55026245h348.99444581c68.37341309 0 123.90106201-66.42553711 123.901062-148.55026245V333.80477906h38.92126465c21.40686036 0 38.92126464-17.38586426 38.92126465-38.92208863 0-21.40686036-17.38504028-38.92126464-38.92126465-38.92126465H668.91854859C666.45321656 173.44860839 599.24902344 107.93109131 516.60601807 107.93109131z m-79.65939331 147.77160644c2.85424805-42.16442872 37.2354126-74.85809326 79.78875732-74.85809326s76.93450927 32.82302857 79.39984131 74.85809326H436.94662476z m-98.86047364 589.01165771c-24.2611084 0-50.98754883-31.13717651-50.98754883-75.76693725V333.80477906h450.97036744V769.33551026c0 44.50039673-26.72644043 75.76776123-50.98754884 75.76776122H338.08615112v-0.38973999z m0 0" ></path><path d="M390.37063599 751.17263794c17.77313232 0 32.43411255-17.7739563 32.43411255-40.08883667V482.35504151c0-22.31488037-14.53079224-40.08966065-32.43411255-40.08966065-17.77478027 0-32.43493653 17.77478027-32.43493653 40.08966065v228.72875976c0 22.18469239 14.27124023 40.08883667 32.43493653 40.08883667z m117.41308594 0c17.7739563 0 32.43411255-17.7739563 32.43411255-40.08883667V482.35504151c0-22.31488037-14.53079224-40.08966065-32.43411255-40.08966065-17.7739563 0-32.43493653 17.77478027-32.43493653 40.08966065v228.72875976c0 22.18469239 14.66098023 40.08883667 32.43493653 40.08883667z m123.51049804 0c17.7739563 0 32.43493653-17.7739563 32.43493652-40.08883667V482.35504151c0-22.31488037-14.53079224-40.08966065-32.43493652-40.08966065-17.7739563 0-32.43411255 17.77478027-32.43411255 40.08966065v228.72875976c0 22.18469239 14.14105224 40.08883667 32.43411255 40.08883667z m0 0" ></path></symbol><symbol id="icon-zijiedian" viewBox="0 0 1024 1024"><path d="M312.208 472c19.568-157.856 153.432-280 315.656-280 175.68 0 318.112 143.272 318.112 320S803.552 832 627.864 832c-162.224 0-296.08-122.144-315.656-280H120a40 40 0 0 1 0-80h192.208zM632 752c132.552 0 240-107.448 240-240 0-132.552-107.448-240-240-240-132.552 0-240 107.448-240 240 0 132.552 107.448 240 240 240z m-40-280v-80a40 40 0 0 1 80 0v80h80a40 40 0 0 1 0 80h-80v80a40 40 0 0 1-80 0v-80h-80a40 40 0 0 1 0-80h80z" ></path></symbol><symbol id="icon-tongjijiedian-" viewBox="0 0 1024 1024"><path d="M803.84 131.626667H410.24A59.733333 59.733333 0 0 0 350.506667 192v45.226667H199.68a51.626667 51.626667 0 0 0-51.626667 51.626666v465.92a51.626667 51.626667 0 0 0 51.626667 51.626667h187.52v-55.466667h-162.133333a21.333333 21.333333 0 0 1-21.333334-21.333333V313.386667a21.333333 21.333333 0 0 1 21.333334-21.333334h125.653333v64a59.733333 59.733333 0 0 0 59.733333 59.733334h393.386667a59.733333 59.733333 0 0 0 59.733333-59.733334V192a59.733333 59.733333 0 0 0-59.733333-60.373333z m4.266667 224.64a4.266667 4.266667 0 0 1-4.266667 4.266666H410.24a4.266667 4.266667 0 0 1-4.266667-4.266666V192a4.266667 4.266667 0 0 1 4.266667-4.266667h393.6a4.266667 4.266667 0 0 1 4.266667 4.266667zM716.16 749.44h-81.28v-81.493333a27.733333 27.733333 0 0 0-55.466667 0v81.28h-81.493333a27.733333 27.733333 0 1 0 0 55.466666h81.28v81.28a27.733333 27.733333 0 1 0 55.466667 0v-81.066666h81.28a27.733333 27.733333 0 0 0 0-55.466667z" ></path></symbol><symbol id="icon-close" viewBox="0 0 1024 1024"><path d="M557.312 513.248l265.28-263.904c12.544-12.48 12.608-32.704 0.128-45.248-12.512-12.576-32.704-12.608-45.248-0.128L512.128 467.904l-263.04-263.84c-12.448-12.48-32.704-12.544-45.248-0.064-12.512 12.48-12.544 32.736-0.064 45.28l262.976 263.776L201.6 776.8c-12.544 12.48-12.608 32.704-0.128 45.248a31.937 31.937 0 0 0 22.688 9.44c8.16 0 16.32-3.104 22.56-9.312l265.216-263.808 265.44 266.24c6.24 6.272 14.432 9.408 22.656 9.408a31.94 31.94 0 0 0 22.592-9.344c12.512-12.48 12.544-32.704 0.064-45.248L557.312 513.248z" fill="" ></path></symbol><symbol id="icon-menu" viewBox="0 0 1024 1024"><path d="M109.714 292.571h804.572c21.943 0 36.571-21.942 36.571-43.885 0-14.629-14.628-29.257-36.571-29.257H109.714c-21.943 0-36.571 14.628-36.571 36.571 0 14.629 14.628 36.571 36.571 36.571zM914.286 512H109.714c-21.943 0-36.571 14.629-36.571 36.571 0 14.629 14.628 36.572 36.571 36.572h804.572c21.943 0 36.571-21.943 36.571-43.886 0-14.628-14.628-29.257-36.571-29.257z m0 292.571H109.714c-21.943 0-36.571 14.629-36.571 36.572s14.628 36.571 36.571 36.571h804.572c21.943 0 36.571-21.943 36.571-36.571 0-21.943-14.628-36.572-36.571-36.572z" ></path></symbol><symbol id="icon-right" viewBox="0 0 1024 1024"><path d="M385 560.69999999L385 738.9c0 36.90000001 26.4 68.5 61.3 68.5l150.2 0c1.5 0 3-0.1 4.5-0.3 10.2 38.7 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-42 0-77.3 28.6-87.5 67.39999999-1.4-0.3-2.9-0.4-4.5-0.39999999L446.3 760.4c-6.8 0-14.3-8.9-14.3-21.49999999l0-427.00000001c0-12.7 7.40000001-21.5 14.30000001-21.5l150.19999999 0c1.5 0 3-0.2 4.5-0.4 10.2 38.8 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.4 0-49.9-40.5-90.6-90.5-90.59999999-42 0-77.3 28.6-87.5 67.39999999-1.4-0.2-2.9-0.4-4.49999999-0.4L446.3 243.3c-34.80000001 0-61.3 31.6-61.3 68.50000001L385 513.7l-79.1 0c-10.4-38.5-45.49999999-67-87.4-67-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c41.79999999 0 77.00000001-28.4 87.4-67L385 560.69999999z" fill="" ></path></symbol><symbol id="icon-left" viewBox="0 0 1024 1024"><path d="M639 463.30000001L639 285.1c0-36.90000001-26.4-68.5-61.3-68.5l-150.2 0c-1.5 0-3 0.1-4.5 0.3-10.2-38.7-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c42 0 77.3-28.6 87.5-67.39999999 1.4 0.3 2.9 0.4 4.5 0.39999999L577.7 263.6c6.8 0 14.3 8.9 14.3 21.49999999l0 427.00000001c0 12.7-7.40000001 21.5-14.30000001 21.5l-150.19999999 0c-1.5 0-3 0.2-4.5 0.4-10.2-38.8-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.4 0 49.9 40.5 90.6 90.5 90.59999999 42 0 77.3-28.6 87.5-67.39999999 1.4 0.2 2.9 0.4 4.49999999 0.4L577.7 780.7c34.80000001 0 61.3-31.6 61.3-68.50000001L639 510.3l79.1 0c10.4 38.5 45.49999999 67 87.4 67 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-41.79999999 0-77.00000001 28.4-87.4 67L639 463.30000001z" fill="" ></path></symbol><symbol id="icon-side" viewBox="0 0 1024 1024"><path d="M851.91168 328.45312c-59.97056 0-108.6208 48.47104-108.91264 108.36992l-137.92768 38.4a109.14304 109.14304 0 0 0-63.46752-46.58688l1.39264-137.11872c47.29344-11.86816 82.31936-54.66624 82.31936-105.64096 0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.76288-108.91776 108.91776c0 49.18784 32.60928 90.75712 77.38368 104.27392l-1.41312 138.87488a109.19936 109.19936 0 0 0-63.50336 48.55808l-138.93632-39.48544 0.01024-0.72704c0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.75776-108.91776 108.91776c0 60.15488 48.76288 108.91264 108.91776 108.91264 39.3984 0 73.91232-20.92032 93.03552-52.2496l139.19232 39.552-0.00512 0.2304c0 25.8304 9.00096 49.5616 24.02816 68.23424l-90.14272 132.63872a108.7488 108.7488 0 0 0-34.2528-5.504c-60.15488 0-108.91776 48.768-108.91776 108.91776 0 60.16 48.76288 108.91776 108.91776 108.91776 60.16 0 108.92288-48.75776 108.92288-108.91776 0-27.14624-9.9328-51.968-26.36288-71.04l89.04704-131.03104a108.544 108.544 0 0 0 37.6832 6.70208 108.672 108.672 0 0 0 36.48512-6.272l93.13792 132.57216a108.48256 108.48256 0 0 0-24.69888 69.0688c0 60.16 48.768 108.92288 108.91776 108.92288 60.16 0 108.91776-48.76288 108.91776-108.92288 0-60.14976-48.75776-108.91776-108.91776-108.91776a108.80512 108.80512 0 0 0-36.69504 6.3488l-93.07136-132.48a108.48768 108.48768 0 0 0 24.79616-72.22784l136.09984-37.888c18.99008 31.93856 53.84192 53.3504 93.69088 53.3504 60.16 0 108.92288-48.75776 108.92288-108.91264-0.00512-60.15488-48.77312-108.92288-108.92288-108.92288z" ></path></symbol><symbol id="icon-B" viewBox="0 0 1024 1024"><path d="M98.067692 65.457231H481.28c75.854769 0 132.411077 3.150769 169.668923 9.452307 37.336615 6.301538 70.656 19.534769 100.036923 39.620924 29.459692 20.007385 53.956923 46.710154 73.570462 80.029538 19.692308 33.398154 29.459692 70.734769 29.459692 112.167385 0 44.898462-12.130462 86.094769-36.233846 123.588923a224.886154 224.886154 0 0 1-98.461539 84.283077c58.368 17.092923 103.266462 46.08 134.695385 87.04 31.350154 40.96 47.025231 89.088 47.025231 144.462769 0 43.638154-10.082462 86.016-30.404923 127.212308-20.243692 41.196308-47.891692 74.043077-83.02277 98.697846-35.052308 24.654769-78.296615 39.778462-129.732923 45.449846-32.295385 3.465846-110.119385 5.671385-233.472 6.537846H98.067692V65.457231z m193.536 159.507692V446.621538h126.818462c75.460923 0 122.328615-1.024 140.603077-3.229538 33.083077-3.938462 59.155692-15.36 78.139077-34.343385 18.904615-18.904615 28.435692-43.874462 28.435692-74.830769 0-29.696-8.192-53.720615-24.497231-72.310154-16.384-18.510769-40.644923-29.696-72.940307-33.634461-19.140923-2.205538-74.279385-3.308308-165.415385-3.308308h-111.064615z m0 381.243077v256.315077h179.2c69.710769 0 113.979077-1.969231 132.726154-5.907692 28.750769-5.198769 52.145231-17.959385 70.262154-38.281847 18.116923-20.243692 27.096615-47.340308 27.096615-81.368615 0-28.750769-6.931692-53.169231-20.873846-73.255385a118.232615 118.232615 0 0 0-60.494769-43.795692c-26.387692-9.137231-83.574154-13.705846-171.638154-13.705846H291.603692z" ></path></symbol><symbol id="icon-a" viewBox="0 0 1024 1024"><path d="M757.76 665.6q0 20.48 1.536 34.304t7.68 22.016 18.944 12.288 34.304 4.096q-3.072 25.6-15.36 44.032-11.264 16.384-33.28 29.696t-62.976 13.312q-11.264 0-20.48-0.512t-17.408-2.56l-6.144-2.048-1.024 0q-4.096-1.024-10.24-4.096-2.048-2.048-4.096-2.048-1.024-1.024-2.048-1.024-14.336-8.192-23.552-17.408t-14.336-17.408q-6.144-10.24-9.216-20.48-63.488 75.776-178.176 75.776-48.128 0-88.064-15.36t-69.12-44.032-45.056-68.096-15.872-88.576 16.896-89.088 47.616-67.584 74.24-42.496 96.768-14.848q48.128 0 88.576 17.408t66.048 49.152q0-8.192 0.512-16.384t0.512-15.36q0-71.68-39.936-104.448t-128-32.768q-43.008 0-84.992 6.656t-84.992 17.92q14.336-28.672 25.088-47.616t24.064-29.184q30.72-24.576 158.72-24.576 79.872 0 135.168 13.824t90.624 43.52 51.2 75.264 15.872 108.032l0 200.704zM487.424 743.424q50.176 0 79.872-33.28t29.696-95.744q0-61.44-28.672-93.696t-76.8-32.256q-52.224 0-82.944 33.28t-30.72 94.72q0 58.368 31.744 92.672t77.824 34.304z" ></path></symbol><symbol id="icon-full" viewBox="0 0 1024 1024"><path d="M639.328 416c8.032 0 16.096-3.008 22.304-9.056l202.624-197.184-0.8 143.808c-0.096 17.696 14.144 32.096 31.808 32.192 0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808l1.248-222.208c0-0.672-0.352-1.248-0.384-1.92 0.032-0.512 0.288-0.896 0.288-1.408 0.032-17.664-14.272-32-31.968-32.032L671.552 96l-0.032 0c-17.664 0-31.968 14.304-32 31.968C639.488 145.632 653.824 160 671.488 160l151.872 0.224-206.368 200.8c-12.672 12.32-12.928 32.608-0.64 45.248C622.656 412.736 630.976 416 639.328 416z" ></path><path d="M896.032 639.552 896.032 639.552c-17.696 0-32 14.304-32.032 31.968l-0.224 151.872-200.832-206.4c-12.32-12.64-32.576-12.96-45.248-0.64-12.672 12.352-12.928 32.608-0.64 45.248l197.184 202.624-143.808-0.8c-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808-0.096 17.696 14.144 32.096 31.808 32.192l222.24 1.248c0.064 0 0.128 0 0.192 0 0.64 0 1.12-0.32 1.76-0.352 0.512 0.032 0.896 0.288 1.408 0.288l0.032 0c17.664 0 31.968-14.304 32-31.968L928 671.584C928.032 653.952 913.728 639.584 896.032 639.552z" ></path><path d="M209.76 159.744l143.808 0.8c0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808 0.096-17.696-14.144-32.096-31.808-32.192L131.68 95.328c-0.064 0-0.128 0-0.192 0-0.672 0-1.248 0.352-1.888 0.384-0.448 0-0.8-0.256-1.248-0.256 0 0-0.032 0-0.032 0-17.664 0-31.968 14.304-32 31.968L96 352.448c-0.032 17.664 14.272 32 31.968 32.032 0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968l0.224-151.936 200.832 206.4c6.272 6.464 14.624 9.696 22.944 9.696 8.032 0 16.096-3.008 22.304-9.056 12.672-12.32 12.96-32.608 0.64-45.248L209.76 159.744z" ></path><path d="M362.368 617.056l-202.624 197.184 0.8-143.808c0.096-17.696-14.144-32.096-31.808-32.192-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808l-1.248 222.24c0 0.704 0.352 1.312 0.384 2.016 0 0.448-0.256 0.832-0.256 1.312-0.032 17.664 14.272 32 31.968 32.032L352.448 928c0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968s-14.272-32-31.968-32.032l-151.936-0.224 206.4-200.832c12.672-12.352 12.96-32.608 0.64-45.248S375.008 604.704 362.368 617.056z" ></path></symbol><symbol id="icon-add" viewBox="0 0 1024 1024"><path d="M863.328 482.56l-317.344-1.12L545.984 162.816c0-17.664-14.336-32-32-32s-32 14.336-32 32l0 318.4L159.616 480.064c-0.032 0-0.064 0-0.096 0-17.632 0-31.936 14.24-32 31.904C127.424 529.632 141.728 544 159.392 544.064l322.592 1.152 0 319.168c0 17.696 14.336 32 32 32s32-14.304 32-32l0-318.944 317.088 1.12c0.064 0 0.096 0 0.128 0 17.632 0 31.936-14.24 32-31.904C895.264 496.992 880.96 482.624 863.328 482.56z" ></path></symbol><symbol id="icon-move" viewBox="0 0 1024 1024"><path d="M863.744 544 163.424 544c-17.664 0-32-14.336-32-32s14.336-32 32-32l700.32 0c17.696 0 32 14.336 32 32S881.44 544 863.744 544z" ></path></symbol><symbol id="icon-living" viewBox="0 0 1024 1024"><path d="M514.133333 488.533333m-106.666666 0a106.666667 106.666667 0 1 0 213.333333 0 106.666667 106.666667 0 1 0-213.333333 0Z" fill="" ></path><path d="M512 64C264.533333 64 64 264.533333 64 512c0 236.8 183.466667 428.8 416 445.866667v-134.4c-53.333333-59.733333-200.533333-230.4-200.533333-334.933334 0-130.133333 104.533333-234.666667 234.666666-234.666666s234.666667 104.533333 234.666667 234.666666c0 61.866667-49.066667 153.6-145.066667 270.933334l-59.733333 68.266666V960C776.533333 942.933333 960 748.8 960 512c0-247.466667-200.533333-448-448-448z" fill="" ></path></symbol></svg>', c = (c = document.getElementsByTagName("script"))[c.length - 1].getAttribute("data-injectcss");
|
|
4
4
|
if (c && !e.__iconfont__svg__cssinject__) {
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
i.readyState == "complete" && (i.onreadystatechange = null, u());
|
|
31
31
|
});
|
|
32
32
|
})(window);
|
|
33
|
-
const q = 0,
|
|
33
|
+
const q = 0, tt = 1, Q = 2, S = 30, L = 8, gt = {
|
|
34
34
|
name: "Latte",
|
|
35
35
|
palette: ["#dd7878", "#ea76cb", "#8839ef", "#e64553", "#fe640b", "#df8e1d", "#40a02b", "#209fb5", "#1e66f5", "#7287fd"],
|
|
36
36
|
cssVar: {
|
|
@@ -42,7 +42,7 @@ const q = 0, Z = 1, J = 2, S = 30, L = 8, mt = {
|
|
|
42
42
|
"--panel-bgcolor": "#ffffff",
|
|
43
43
|
"--panel-border-color": "#eaeaea"
|
|
44
44
|
}
|
|
45
|
-
},
|
|
45
|
+
}, vt = {
|
|
46
46
|
name: "Dark",
|
|
47
47
|
palette: ["#848FA0", "#748BE9", "#D2F9FE", "#4145A5", "#789AFA", "#706CF4", "#EF987F", "#775DD5", "#FCEECF", "#DA7FBC"],
|
|
48
48
|
cssVar: {
|
|
@@ -55,25 +55,25 @@ const q = 0, Z = 1, J = 2, S = 30, L = 8, mt = {
|
|
|
55
55
|
"--panel-border-color": "#696969"
|
|
56
56
|
}
|
|
57
57
|
};
|
|
58
|
-
function
|
|
58
|
+
function ot(e) {
|
|
59
59
|
return e.replace(/&/g, "&").replace(/</g, "<").replace(/"/g, """);
|
|
60
60
|
}
|
|
61
|
-
const
|
|
61
|
+
const U = function(e, t) {
|
|
62
62
|
if (t.id === e)
|
|
63
63
|
return t;
|
|
64
64
|
if (t.children && t.children.length) {
|
|
65
65
|
for (let n = 0; n < t.children.length; n++) {
|
|
66
|
-
const s =
|
|
66
|
+
const s = U(e, t.children[n]);
|
|
67
67
|
if (s)
|
|
68
68
|
return s;
|
|
69
69
|
}
|
|
70
70
|
return null;
|
|
71
71
|
} else
|
|
72
72
|
return null;
|
|
73
|
-
},
|
|
73
|
+
}, et = (e, t) => {
|
|
74
74
|
if (e.parent = t, e.children)
|
|
75
75
|
for (let n = 0; n < e.children.length; n++)
|
|
76
|
-
|
|
76
|
+
et(e.children[n], e);
|
|
77
77
|
};
|
|
78
78
|
function yt(e, t, n, s) {
|
|
79
79
|
const i = s - t, o = e - n;
|
|
@@ -87,11 +87,11 @@ function yt(e, t, n, s) {
|
|
|
87
87
|
y2: s - Math.sin(Math.PI * h / 180) * l
|
|
88
88
|
};
|
|
89
89
|
}
|
|
90
|
-
function
|
|
90
|
+
function nt() {
|
|
91
91
|
return ((/* @__PURE__ */ new Date()).getTime().toString(16) + Math.random().toString(16).substr(2)).substr(2, 16);
|
|
92
92
|
}
|
|
93
93
|
const $t = function() {
|
|
94
|
-
const e =
|
|
94
|
+
const e = nt();
|
|
95
95
|
return {
|
|
96
96
|
topic: this.newTopicName,
|
|
97
97
|
id: e
|
|
@@ -123,7 +123,7 @@ const $t = function() {
|
|
|
123
123
|
clear() {
|
|
124
124
|
this.moved = !1, this.mousedown = !1, this.lastX = 0, this.lastY = 0;
|
|
125
125
|
}
|
|
126
|
-
},
|
|
126
|
+
}, rt = (e) => e.tagName === "ME-TPC";
|
|
127
127
|
function Tt(e) {
|
|
128
128
|
e.map.addEventListener("click", (t) => {
|
|
129
129
|
if (N.moved) {
|
|
@@ -135,14 +135,14 @@ function Tt(e) {
|
|
|
135
135
|
if (n.tagName === "ME-EPD")
|
|
136
136
|
e.expandNode(n.previousSibling);
|
|
137
137
|
else if (e.editable)
|
|
138
|
-
|
|
138
|
+
rt(n) ? e.selectNode(n, !1, t) : n.tagName === "text" ? n.dataset.type === "custom-link" ? e.selectLink(n.parentElement) : e.selectSummary(n.parentElement) : n.className === "circle" || e.hideLinkController && e.hideLinkController();
|
|
139
139
|
else
|
|
140
140
|
return;
|
|
141
141
|
}), e.map.addEventListener("dblclick", (t) => {
|
|
142
142
|
if (t.preventDefault(), !e.editable)
|
|
143
143
|
return;
|
|
144
144
|
const n = t.target;
|
|
145
|
-
|
|
145
|
+
rt(n) ? e.beginEdit(n) : n.tagName === "text" && (n.dataset.type === "custom-link" ? e.editCutsomLinkLabel(n.parentElement) : e.editSummary(n.parentElement));
|
|
146
146
|
}), e.map.addEventListener("mousemove", (t) => {
|
|
147
147
|
t.target.contentEditable !== "true" && N.onMove(t, e.container);
|
|
148
148
|
}), e.map.addEventListener("mousedown", (t) => {
|
|
@@ -184,60 +184,71 @@ const Nt = {
|
|
|
184
184
|
}
|
|
185
185
|
};
|
|
186
186
|
}
|
|
187
|
-
},
|
|
187
|
+
}, K = document, Dt = function() {
|
|
188
188
|
console.time("layout"), this.nodes.innerHTML = "";
|
|
189
189
|
const e = this.createTopic(this.nodeData);
|
|
190
190
|
bt(e, this.nodeData), e.draggable = !1;
|
|
191
|
-
const t =
|
|
191
|
+
const t = K.createElement("me-root");
|
|
192
192
|
t.appendChild(e);
|
|
193
193
|
const n = this.nodeData.children || [];
|
|
194
|
-
if (this.direction ===
|
|
194
|
+
if (this.direction === Q) {
|
|
195
195
|
let s = 0, i = 0;
|
|
196
196
|
n.map((o) => {
|
|
197
|
-
o.direction === q ? s += 1 : o.direction ===
|
|
197
|
+
o.direction === q ? s += 1 : o.direction === tt ? i += 1 : s <= i ? (o.direction = q, s += 1) : (o.direction = tt, i += 1);
|
|
198
198
|
});
|
|
199
199
|
}
|
|
200
|
-
|
|
201
|
-
},
|
|
202
|
-
const s =
|
|
200
|
+
At(this, n, t), console.timeEnd("layout");
|
|
201
|
+
}, At = function(e, t, n) {
|
|
202
|
+
const s = K.createElement("me-main");
|
|
203
203
|
s.className = "lhs";
|
|
204
|
-
const i =
|
|
204
|
+
const i = K.createElement("me-main");
|
|
205
205
|
i.className = "rhs";
|
|
206
206
|
for (let o = 0; o < t.length; o++) {
|
|
207
207
|
const r = t[o], { grp: l } = e.createWrapper(r);
|
|
208
|
-
e.direction ===
|
|
208
|
+
e.direction === Q ? r.direction === q ? s.appendChild(l) : i.appendChild(l) : e.direction === q ? s.appendChild(l) : i.appendChild(l);
|
|
209
209
|
}
|
|
210
210
|
e.nodes.appendChild(s), e.nodes.appendChild(n), e.nodes.appendChild(i), e.nodes.appendChild(e.lines);
|
|
211
211
|
}, Ht = function(e, t) {
|
|
212
|
-
const n =
|
|
212
|
+
const n = K.createElement("me-children");
|
|
213
213
|
for (let s = 0; s < t.length; s++) {
|
|
214
214
|
const i = t[s], { grp: o } = e.createWrapper(i);
|
|
215
215
|
n.appendChild(o);
|
|
216
216
|
}
|
|
217
217
|
return n;
|
|
218
|
-
}, E = document, C = (e, t) =>
|
|
219
|
-
|
|
218
|
+
}, E = document, C = (e, t) => {
|
|
219
|
+
const s = (t ? t.mindElixirBox : E).querySelector(`[data-nodeid=me${e}]`);
|
|
220
|
+
if (!s)
|
|
221
|
+
throw new Error(`FindEle: Node ${e} not found, maybe it's collapsed.`);
|
|
222
|
+
return s;
|
|
223
|
+
}, bt = function(e, t) {
|
|
224
|
+
if (t.style && (e.style.color = t.style.color || "", e.style.background = t.style.background || "", e.style.fontSize = t.style.fontSize + "px", e.style.fontWeight = t.style.fontWeight || "normal"), t.branchColor && (e.style.borderColor = t.branchColor), t.image) {
|
|
220
225
|
const n = t.image;
|
|
221
226
|
if (n.url && n.width && n.height) {
|
|
222
227
|
const s = E.createElement("img");
|
|
223
228
|
s.src = n.url, s.style.width = n.width + "px", s.style.height = n.height + "px", e.appendChild(s), e.image = s;
|
|
224
229
|
} else
|
|
225
230
|
console.warn("image url/width/height are required");
|
|
231
|
+
} else
|
|
232
|
+
e.image && (e.image = void 0);
|
|
233
|
+
{
|
|
234
|
+
const n = E.createElement("span");
|
|
235
|
+
n.className = "text", n.textContent = t.topic, e.appendChild(n), e.text = n;
|
|
226
236
|
}
|
|
227
237
|
if (t.hyperLink) {
|
|
228
238
|
const n = E.createElement("a");
|
|
229
239
|
n.className = "hyper-link", n.target = "_blank", n.innerText = "🔗", n.href = t.hyperLink, e.appendChild(n), e.linkContainer = n;
|
|
230
240
|
} else
|
|
231
|
-
e.linkContainer && (e.linkContainer
|
|
241
|
+
e.linkContainer && (e.linkContainer = void 0);
|
|
232
242
|
if (t.icons && t.icons.length) {
|
|
233
243
|
const n = E.createElement("span");
|
|
234
|
-
n.className = "icons", n.innerHTML = t.icons.map((s) => `<span>${
|
|
235
|
-
}
|
|
244
|
+
n.className = "icons", n.innerHTML = t.icons.map((s) => `<span>${ot(s)}</span>`).join(""), e.appendChild(n), e.icons = n;
|
|
245
|
+
} else
|
|
246
|
+
e.icons && (e.icons = void 0);
|
|
236
247
|
if (t.tags && t.tags.length) {
|
|
237
248
|
const n = E.createElement("div");
|
|
238
|
-
n.className = "tags", n.innerHTML = t.tags.map((s) => `<span>${
|
|
239
|
-
}
|
|
240
|
-
|
|
249
|
+
n.className = "tags", n.innerHTML = t.tags.map((s) => `<span>${ot(s)}</span>`).join(""), e.appendChild(n), e.tags = n;
|
|
250
|
+
} else
|
|
251
|
+
e.tags && (e.tags = void 0);
|
|
241
252
|
}, Pt = function(e, t) {
|
|
242
253
|
const n = E.createElement("me-wrapper"), { p: s, tpc: i } = this.createParent(e);
|
|
243
254
|
if (n.appendChild(s), !t && e.children && e.children.length > 0) {
|
|
@@ -267,7 +278,7 @@ function xt(e) {
|
|
|
267
278
|
const qt = function(e) {
|
|
268
279
|
if (console.time("editTopic"), !e)
|
|
269
280
|
return;
|
|
270
|
-
const t = E.createElement("div"), n = e.
|
|
281
|
+
const t = E.createElement("div"), n = e.text.textContent;
|
|
271
282
|
e.appendChild(t), t.id = "input-box", t.textContent = n, t.contentEditable = "true", t.spellcheck = !1, t.style.cssText = `min-width:${e.offsetWidth - 8}px;`, this.direction === q && (t.style.right = "0"), t.focus(), xt(t), this.bus.fire("operation", {
|
|
272
283
|
name: "beginEdit",
|
|
273
284
|
obj: e.nodeObj
|
|
@@ -284,7 +295,7 @@ const qt = function(e) {
|
|
|
284
295
|
if (!t)
|
|
285
296
|
return;
|
|
286
297
|
const s = e.nodeObj, i = ((o = t.textContent) == null ? void 0 : o.trim()) || "";
|
|
287
|
-
console.log(i), i === "" ? s.topic = n : s.topic = i, t.remove(), i !== n && (e.
|
|
298
|
+
console.log(i), i === "" ? s.topic = n : s.topic = i, t.remove(), i !== n && (e.text.textContent = s.topic, this.linkDiv(), this.bus.fire("operation", {
|
|
288
299
|
name: "finishEdit",
|
|
289
300
|
obj: s,
|
|
290
301
|
origin: n
|
|
@@ -299,7 +310,7 @@ const qt = function(e) {
|
|
|
299
310
|
}, W = function(e) {
|
|
300
311
|
const t = H.createElementNS(P, "svg");
|
|
301
312
|
return t.setAttribute("class", e), t.setAttribute("overflow", "visible"), t;
|
|
302
|
-
},
|
|
313
|
+
}, lt = function() {
|
|
303
314
|
const e = H.createElementNS(P, "line");
|
|
304
315
|
return e.setAttribute("stroke", "#bbb"), e.setAttribute("fill", "none"), e.setAttribute("stroke-width", "2"), e;
|
|
305
316
|
}, jt = function(e, t) {
|
|
@@ -359,7 +370,7 @@ const Xt = function(e) {
|
|
|
359
370
|
const m = g + r.offsetHeight / 2;
|
|
360
371
|
let p = "";
|
|
361
372
|
if (this.mainLinkStyle === 2)
|
|
362
|
-
this.direction ===
|
|
373
|
+
this.direction === Q && (l === "lhs" ? c = c - t.offsetWidth / 6 : c = c + t.offsetWidth / 6), p = Yt({ x1: c, y1: u, x2: h, y2: m });
|
|
363
374
|
else {
|
|
364
375
|
const w = (1 - Math.abs(m - i.parentElement.offsetTop - i.parentElement.offsetHeight / 2) / i.parentElement.offsetHeight) * 0.25 * (t.offsetWidth / 2);
|
|
365
376
|
l === "lhs" ? c = c - t.offsetWidth / 10 - w : c = c + t.offsetWidth / 10 + w, p = Ft({ x1: c, y1: u, x2: h, y2: m });
|
|
@@ -412,14 +423,14 @@ function Ct({ pT: e, pL: t, pW: n, pH: s, cT: i, cL: o, cW: r, cH: l, direction:
|
|
|
412
423
|
const p = Math.min(Math.abs(h - a) / 800, 1.2) * S;
|
|
413
424
|
return c === "lhs" ? (m = t, f = m + S, g = m - S, d = o + S, `M ${f} ${h} C ${m} ${h} ${m + p} ${a} ${g} ${a} H ${d}`) : (m = t + n, f = m - S, g = m + S, d = o + r - S, `M ${f} ${h} C ${m} ${h} ${m - p} ${a} ${g} ${a} H ${d}`);
|
|
414
425
|
}
|
|
415
|
-
const
|
|
426
|
+
const A = (e, t) => {
|
|
416
427
|
const n = document.createElement("span");
|
|
417
428
|
return n.id = e, n.innerHTML = `<svg class="icon" aria-hidden="true">
|
|
418
429
|
<use xlink:href="#icon-${t}"></use>
|
|
419
430
|
</svg>`, n;
|
|
420
431
|
};
|
|
421
432
|
function Gt(e) {
|
|
422
|
-
const t = document.createElement("div"), n =
|
|
433
|
+
const t = document.createElement("div"), n = A("fullscreen", "full"), s = A("toCenter", "living"), i = A("zoomout", "move"), o = A("zoomin", "add"), r = document.createElement("span");
|
|
423
434
|
return r.innerText = "100%", t.appendChild(n), t.appendChild(s), t.appendChild(i), t.appendChild(o), t.className = "mind-elixir-toolbar rb", n.onclick = () => {
|
|
424
435
|
e.container.requestFullscreen();
|
|
425
436
|
}, s.onclick = () => {
|
|
@@ -431,7 +442,7 @@ function Gt(e) {
|
|
|
431
442
|
}, t;
|
|
432
443
|
}
|
|
433
444
|
function Ut(e) {
|
|
434
|
-
const t = document.createElement("div"), n =
|
|
445
|
+
const t = document.createElement("div"), n = A("tbltl", "left"), s = A("tbltr", "right"), i = A("tblts", "side");
|
|
435
446
|
return t.appendChild(n), t.appendChild(s), t.appendChild(i), t.className = "mind-elixir-toolbar lt", n.onclick = () => {
|
|
436
447
|
e.initLeft();
|
|
437
448
|
}, s.onclick = () => {
|
|
@@ -467,13 +478,13 @@ class Zt {
|
|
|
467
478
|
this._listeners.clear();
|
|
468
479
|
}
|
|
469
480
|
}
|
|
470
|
-
const
|
|
481
|
+
const ct = (e, t = "px") => typeof e == "number" ? e + t : e;
|
|
471
482
|
function $({ style: e }, t, n) {
|
|
472
483
|
if (typeof t == "object")
|
|
473
484
|
for (const [s, i] of Object.entries(t))
|
|
474
|
-
i !== void 0 && (e[s] =
|
|
485
|
+
i !== void 0 && (e[s] = ct(i));
|
|
475
486
|
else
|
|
476
|
-
n !== void 0 && (e[t] =
|
|
487
|
+
n !== void 0 && (e[t] = ct(n));
|
|
477
488
|
}
|
|
478
489
|
function Lt(e) {
|
|
479
490
|
return (t, n, s, i = {}) => {
|
|
@@ -489,7 +500,7 @@ const z = Lt("addEventListener"), T = Lt("removeEventListener"), I = (e) => {
|
|
|
489
500
|
const { clientX: n, clientY: s, target: i } = ((t = e.touches) == null ? void 0 : t[0]) ?? e;
|
|
490
501
|
return { x: n, y: s, target: i };
|
|
491
502
|
};
|
|
492
|
-
function
|
|
503
|
+
function at(e, t, n = "touch") {
|
|
493
504
|
switch (n) {
|
|
494
505
|
case "center": {
|
|
495
506
|
const s = t.left + t.width / 2, i = t.top + t.height / 2;
|
|
@@ -522,7 +533,7 @@ const te = () => matchMedia("(hover: none), (pointer: coarse)").matches, ee = ()
|
|
|
522
533
|
cancelAnimationFrame(n), s = !1;
|
|
523
534
|
}
|
|
524
535
|
};
|
|
525
|
-
}, { abs:
|
|
536
|
+
}, { abs: D, max: ht, min: dt, ceil: ut } = Math;
|
|
526
537
|
class se extends Zt {
|
|
527
538
|
constructor(t) {
|
|
528
539
|
var n, s, i, o, r;
|
|
@@ -600,7 +611,7 @@ class se extends Zt {
|
|
|
600
611
|
_onTapStart(t, n = !1) {
|
|
601
612
|
const { x: s, y: i, target: o } = I(t), { _options: r } = this, { document: l } = this._options, c = o.getBoundingClientRect(), u = B(r.startAreas, r.document), h = B(r.boundaries, r.document);
|
|
602
613
|
this._targetElement = h.find(
|
|
603
|
-
(f) =>
|
|
614
|
+
(f) => at(f.getBoundingClientRect(), c)
|
|
604
615
|
);
|
|
605
616
|
const d = t.composedPath();
|
|
606
617
|
if (!this._targetElement || !u.find((f) => d.includes(f)) || !h.find((f) => d.includes(f)) || !n && this._emitEvent("beforestart", t) === !1)
|
|
@@ -643,8 +654,8 @@ class se extends Zt {
|
|
|
643
654
|
const { container: n, document: s, behaviour: { startThreshold: i } } = this._options, { x1: o, y1: r } = this._areaLocation, { x: l, y: c } = I(t);
|
|
644
655
|
if (
|
|
645
656
|
// Single number for both coordinates
|
|
646
|
-
typeof i == "number" &&
|
|
647
|
-
typeof i == "object" &&
|
|
657
|
+
typeof i == "number" && D(l + c - (o + r)) >= i || // Different x and y threshold
|
|
658
|
+
typeof i == "object" && D(l - o) >= i.x || D(c - r) >= i.y
|
|
648
659
|
) {
|
|
649
660
|
if (T(s, ["mousemove", "touchmove"], this._delayedTapMove, { passive: !1 }), this._emitEvent("beforedrag", t) === !1) {
|
|
650
661
|
T(s, ["mouseup", "touchcancel", "touchend"], this._onTapStop);
|
|
@@ -684,7 +695,7 @@ class se extends Zt {
|
|
|
684
695
|
return;
|
|
685
696
|
}
|
|
686
697
|
const { scrollTop: d, scrollLeft: a } = u;
|
|
687
|
-
i.y && (u.scrollTop +=
|
|
698
|
+
i.y && (u.scrollTop += ut(i.y / c), o.y1 -= u.scrollTop - d), i.x && (u.scrollLeft += ut(i.x / c), o.x1 -= u.scrollLeft - a), l.next(t), requestAnimationFrame(h);
|
|
688
699
|
};
|
|
689
700
|
requestAnimationFrame(h);
|
|
690
701
|
} else
|
|
@@ -707,8 +718,8 @@ class se extends Zt {
|
|
|
707
718
|
const { _scrollSpeed: t, _areaLocation: n, _areaRect: s, _targetElement: i, _options: o } = this, { scrollTop: r, scrollHeight: l, clientHeight: c, scrollLeft: u, scrollWidth: h, clientWidth: d } = i, a = this._targetRect, { x1: f, y1: g } = n;
|
|
708
719
|
let { x2: m, y2: p } = n;
|
|
709
720
|
const { behaviour: { scrolling: { startScrollMargins: v } } } = o;
|
|
710
|
-
m < a.left + v.x ? (t.x = u ? -
|
|
711
|
-
const x =
|
|
721
|
+
m < a.left + v.x ? (t.x = u ? -D(a.left - m + v.x) : 0, m = m < a.left ? a.left : m) : m > a.right - v.x ? (t.x = h - u - d ? D(a.left + a.width - m - v.x) : 0, m = m > a.right ? a.right : m) : t.x = 0, p < a.top + v.y ? (t.y = r ? -D(a.top - p + v.y) : 0, p = p < a.top ? a.top : p) : p > a.bottom - v.y ? (t.y = l - r - c ? D(a.top + a.height - p - v.y) : 0, p = p > a.bottom ? a.bottom : p) : t.y = 0;
|
|
722
|
+
const x = dt(f, m), w = dt(g, p), _ = ht(f, m), k = ht(g, p);
|
|
712
723
|
s.x = x, s.y = w, s.width = _ - x, s.height = k - w;
|
|
713
724
|
}
|
|
714
725
|
_redrawSelectionArea() {
|
|
@@ -724,7 +735,7 @@ class se extends Zt {
|
|
|
724
735
|
const { _selectables: t, _options: n, _selection: s, _areaRect: i } = this, { stored: o, selected: r, touched: l } = s, { intersect: c, overlap: u } = n.behaviour, h = u === "invert", d = [], a = [], f = [];
|
|
725
736
|
for (let m = 0; m < t.length; m++) {
|
|
726
737
|
const p = t[m];
|
|
727
|
-
if (
|
|
738
|
+
if (at(i, p.getBoundingClientRect(), c)) {
|
|
728
739
|
if (r.includes(p))
|
|
729
740
|
o.includes(p) && !l.includes(p) && l.push(p);
|
|
730
741
|
else if (h && o.includes(p)) {
|
|
@@ -990,7 +1001,7 @@ const oe = function(e, t, n) {
|
|
|
990
1001
|
const n = e.nodeObj;
|
|
991
1002
|
typeof t == "boolean" ? n.expanded = t : n.expanded !== !1 ? n.expanded = !1 : n.expanded = !0, this.layout(), this.linkDiv(), this.bus.fire("expandNode", n);
|
|
992
1003
|
}, Me = function(e) {
|
|
993
|
-
e && (e = JSON.parse(JSON.stringify(e)), this.nodeData = e.nodeData, this.linkData = e.linkData || {}),
|
|
1004
|
+
e && (e = JSON.parse(JSON.stringify(e)), this.nodeData = e.nodeData, this.linkData = e.linkData || {}), et(this.nodeData), this.layout(), this.linkDiv();
|
|
994
1005
|
}, $e = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
995
1006
|
__proto__: null,
|
|
996
1007
|
cancelFocus: _e,
|
|
@@ -1050,10 +1061,10 @@ const oe = function(e, t, n) {
|
|
|
1050
1061
|
this.mousedown = !1, this.lastX = 0, this.lastY = 0;
|
|
1051
1062
|
}
|
|
1052
1063
|
};
|
|
1053
|
-
},
|
|
1064
|
+
}, ft = {
|
|
1054
1065
|
create: Te
|
|
1055
1066
|
};
|
|
1056
|
-
function
|
|
1067
|
+
function J(e, t, n) {
|
|
1057
1068
|
const { offsetLeft: s, offsetTop: i } = V(e.nodes, t), o = t.offsetWidth, r = t.offsetHeight, l = s + o / 2, c = i + r / 2, u = l + n.x, h = c + n.y;
|
|
1058
1069
|
return {
|
|
1059
1070
|
w: o,
|
|
@@ -1080,21 +1091,21 @@ const Ne = function(e, t, n, s) {
|
|
|
1080
1091
|
y: n + "",
|
|
1081
1092
|
fill: s || "#666"
|
|
1082
1093
|
}), i.dataset.type = "custom-link", i.innerHTML = e, i;
|
|
1083
|
-
},
|
|
1094
|
+
}, De = function(e, t, n, s) {
|
|
1084
1095
|
if (!e || !t)
|
|
1085
1096
|
return;
|
|
1086
1097
|
const i = performance.now();
|
|
1087
1098
|
this.hideLinkController();
|
|
1088
|
-
const o =
|
|
1099
|
+
const o = J(this, e, n.delta1), r = J(this, t, n.delta2), { x: l, y: c } = O(o), { ctrlX: u, ctrlY: h } = o, { ctrlX: d, ctrlY: a } = r, { x: f, y: g } = O(r), m = yt(d, a, f, g), p = Wt(
|
|
1089
1100
|
`M ${l} ${c} C ${u} ${h} ${d} ${a} ${f} ${g}`,
|
|
1090
1101
|
`M ${m.x1} ${m.y1} L ${f} ${g} L ${m.x2} ${m.y2}`
|
|
1091
1102
|
), v = l / 8 + u * 3 / 8 + d * 3 / 8 + f / 8, x = c / 8 + h * 3 / 8 + a * 3 / 8 + g / 8, w = Ne(n.label, v, x, this.theme.cssVar["--color"]);
|
|
1092
1103
|
p.appendChild(w), p.linkObj = n, p.dataset.linkid = n.id, this.linkSvgGroup.appendChild(p), s || (this.linkData[n.id] = n, this.currentLink = p, this.showLinkController(n, o, r));
|
|
1093
1104
|
const _ = performance.now();
|
|
1094
1105
|
console.log(`DrawCustomLink Execution time: ${_ - i} ms`);
|
|
1095
|
-
},
|
|
1106
|
+
}, Ae = function(e, t) {
|
|
1096
1107
|
const n = {
|
|
1097
|
-
id:
|
|
1108
|
+
id: nt(),
|
|
1098
1109
|
label: "Custom Link",
|
|
1099
1110
|
from: e.nodeObj.id,
|
|
1100
1111
|
to: t.nodeObj.id,
|
|
@@ -1114,10 +1125,10 @@ const Ne = function(e, t, n, s) {
|
|
|
1114
1125
|
return;
|
|
1115
1126
|
this.hideLinkController();
|
|
1116
1127
|
const n = t.linkObj.id;
|
|
1117
|
-
delete this.linkData[n], t.remove()
|
|
1128
|
+
delete this.linkData[n], t.remove();
|
|
1118
1129
|
}, Pe = function(e) {
|
|
1119
1130
|
this.currentLink = e;
|
|
1120
|
-
const t = e.linkObj, n = C(t.from), s = C(t.to), i =
|
|
1131
|
+
const t = e.linkObj, n = C(t.from), s = C(t.to), i = J(this, n, t.delta1), o = J(this, s, t.delta2);
|
|
1121
1132
|
this.showLinkController(t, i, o);
|
|
1122
1133
|
}, ze = function() {
|
|
1123
1134
|
this.currentLink = null, this.hideLinkController();
|
|
@@ -1136,7 +1147,7 @@ const Ne = function(e, t, n, s) {
|
|
|
1136
1147
|
y1: c + "",
|
|
1137
1148
|
x2: u + "",
|
|
1138
1149
|
y2: h + ""
|
|
1139
|
-
}), this.helper1 && (this.helper1.destory(this.map), this.helper2.destory(this.map)), this.helper1 =
|
|
1150
|
+
}), this.helper1 && (this.helper1.destory(this.map), this.helper2.destory(this.map)), this.helper1 = ft.create(this.P2), this.helper2 = ft.create(this.P3), this.helper1.init(this.map, (d, a) => {
|
|
1140
1151
|
var p;
|
|
1141
1152
|
o = o - d / this.scaleVal, r = r - a / this.scaleVal;
|
|
1142
1153
|
const f = O({ ...t, ctrlX: o, ctrlY: r });
|
|
@@ -1186,18 +1197,25 @@ function Ve(e) {
|
|
|
1186
1197
|
i === "" ? s.label = origin : s.label = i, n.remove(), i !== origin && (t.innerHTML = s.label, this.linkDiv());
|
|
1187
1198
|
}), console.timeEnd("editSummary");
|
|
1188
1199
|
}
|
|
1189
|
-
|
|
1200
|
+
function Re() {
|
|
1201
|
+
for (const e in this.linkData) {
|
|
1202
|
+
const t = this.linkData[e];
|
|
1203
|
+
(!U(t.from, this.nodeData) || !U(t.to, this.nodeData)) && delete this.linkData[t.id];
|
|
1204
|
+
}
|
|
1205
|
+
}
|
|
1206
|
+
const je = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1190
1207
|
__proto__: null,
|
|
1191
|
-
createLink:
|
|
1192
|
-
drawCustomLink:
|
|
1208
|
+
createLink: Ae,
|
|
1209
|
+
drawCustomLink: De,
|
|
1193
1210
|
editCutsomLinkLabel: Ve,
|
|
1194
1211
|
hideLinkController: Be,
|
|
1195
1212
|
removeLink: He,
|
|
1196
1213
|
renderCustomLink: qe,
|
|
1197
1214
|
selectLink: Pe,
|
|
1198
1215
|
showLinkController: Oe,
|
|
1216
|
+
tidyCustomLink: Re,
|
|
1199
1217
|
unselectLink: ze
|
|
1200
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1218
|
+
}, Symbol.toStringTag, { value: "Module" })), We = function(e) {
|
|
1201
1219
|
var c, u;
|
|
1202
1220
|
if (e.length === 0)
|
|
1203
1221
|
throw new Error("No selected node.");
|
|
@@ -1240,10 +1258,10 @@ const Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1240
1258
|
start: o,
|
|
1241
1259
|
end: r
|
|
1242
1260
|
};
|
|
1243
|
-
},
|
|
1261
|
+
}, Xe = function(e) {
|
|
1244
1262
|
const t = document.createElementNS("http://www.w3.org/2000/svg", "g");
|
|
1245
1263
|
return t.setAttribute("id", e), t;
|
|
1246
|
-
},
|
|
1264
|
+
}, pt = function(e, t) {
|
|
1247
1265
|
const n = document.createElementNS("http://www.w3.org/2000/svg", "path");
|
|
1248
1266
|
return b(n, {
|
|
1249
1267
|
d: e,
|
|
@@ -1252,7 +1270,7 @@ const Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1252
1270
|
"stroke-linecap": "round",
|
|
1253
1271
|
"stroke-width": "2"
|
|
1254
1272
|
}), n;
|
|
1255
|
-
},
|
|
1273
|
+
}, mt = function(e, t, n, s, i) {
|
|
1256
1274
|
const o = document.createElementNS("http://www.w3.org/2000/svg", "text");
|
|
1257
1275
|
return b(o, {
|
|
1258
1276
|
"text-anchor": s,
|
|
@@ -1260,37 +1278,37 @@ const Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1260
1278
|
y: n + "",
|
|
1261
1279
|
fill: i || "#666"
|
|
1262
1280
|
}), o.innerHTML = e, o;
|
|
1263
|
-
},
|
|
1281
|
+
}, Ye = (e) => C(e).parentElement.parentElement, Fe = function({ parent: e, start: t }) {
|
|
1264
1282
|
var o, r;
|
|
1265
1283
|
const n = C(e), s = n.nodeObj;
|
|
1266
1284
|
let i;
|
|
1267
1285
|
return s.root === !0 ? i = (o = C(s.children[t].id).closest("me-main")) == null ? void 0 : o.className : i = (r = n.closest("me-main")) == null ? void 0 : r.className, i;
|
|
1268
1286
|
}, kt = function(e, t) {
|
|
1269
1287
|
var X;
|
|
1270
|
-
const { id: n, text: s, parent: i, start: o, end: r } = t, l = e.nodes, u = C(i).nodeObj, h =
|
|
1288
|
+
const { id: n, text: s, parent: i, start: o, end: r } = t, l = e.nodes, u = C(i).nodeObj, h = Fe(t);
|
|
1271
1289
|
let d = 1 / 0, a = 0, f = 0, g = 0;
|
|
1272
1290
|
for (let R = o; R <= r; R++) {
|
|
1273
|
-
const
|
|
1274
|
-
if (!
|
|
1291
|
+
const st = (X = u.children) == null ? void 0 : X[R];
|
|
1292
|
+
if (!st)
|
|
1275
1293
|
return console.warn("Child not found"), e.removeSummary(n), null;
|
|
1276
|
-
const Y =
|
|
1277
|
-
R === o && (f =
|
|
1294
|
+
const Y = Ye(st.id), { offsetLeft: F, offsetTop: it } = V(l, Y);
|
|
1295
|
+
R === o && (f = it), R === r && (g = it + Y.offsetHeight), F < d && (d = F), Y.offsetWidth + F > a && (a = Y.offsetWidth + F);
|
|
1278
1296
|
}
|
|
1279
1297
|
let m, p;
|
|
1280
1298
|
const v = f + 10, x = g + 10, w = (v + x) / 2, _ = e.theme.cssVar["--color"];
|
|
1281
|
-
h === "lhs" ? (m =
|
|
1282
|
-
const k =
|
|
1299
|
+
h === "lhs" ? (m = pt(`M ${d + 10} ${v} c -5 0 -10 5 -10 10 L ${d} ${x - 10} c 0 5 5 10 10 10 M ${d} ${w} h -10`, _), p = mt(s, d - 20, w + 6, "end", _)) : (m = pt(`M ${a - 10} ${v} c 5 0 10 5 10 10 L ${a} ${x - 10} c 0 5 -5 10 -10 10 M ${a} ${w} h 10`, _), p = mt(s, a + 20, w + 6, "start", _));
|
|
1300
|
+
const k = Xe("s-" + n);
|
|
1283
1301
|
return k.appendChild(m), k.appendChild(p), k.summaryObj = t, e.summarySvg.appendChild(k), k;
|
|
1284
|
-
},
|
|
1302
|
+
}, Ie = function() {
|
|
1285
1303
|
let e = [];
|
|
1286
1304
|
this.currentNode ? e = [this.currentNode] : this.currentNodes && (e = this.currentNodes);
|
|
1287
|
-
const { parent: t, start: n, end: s } =
|
|
1305
|
+
const { parent: t, start: n, end: s } = We(e), i = { id: nt(), parent: t, start: n, end: s, text: "summary" }, o = kt(this, i);
|
|
1288
1306
|
this.summaries.push(i), this.editSummary(o);
|
|
1289
|
-
},
|
|
1307
|
+
}, Ge = function(e) {
|
|
1290
1308
|
var n;
|
|
1291
1309
|
const t = this.summaries.findIndex((s) => s.id === e);
|
|
1292
1310
|
t > -1 && (this.summaries.splice(t, 1), (n = document.querySelector("#s-" + e)) == null || n.remove());
|
|
1293
|
-
},
|
|
1311
|
+
}, Ue = function(e) {
|
|
1294
1312
|
const t = e.children[1].getBBox(), n = 6, s = 3, i = document.createElementNS("http://www.w3.org/2000/svg", "rect");
|
|
1295
1313
|
b(i, {
|
|
1296
1314
|
x: t.x - n + "",
|
|
@@ -1302,14 +1320,14 @@ const Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1302
1320
|
"stroke-width": "2",
|
|
1303
1321
|
fill: "none"
|
|
1304
1322
|
}), i.classList.add("selected"), e.appendChild(i), this.currentSummary = e;
|
|
1305
|
-
},
|
|
1323
|
+
}, Ke = function() {
|
|
1306
1324
|
var e, t;
|
|
1307
1325
|
(t = (e = this.currentSummary) == null ? void 0 : e.querySelector("rect")) == null || t.remove(), this.currentSummary = null;
|
|
1308
|
-
},
|
|
1326
|
+
}, Je = function() {
|
|
1309
1327
|
this.summarySvg.innerHTML = "", this.summaries.forEach((e) => {
|
|
1310
1328
|
kt(this, e);
|
|
1311
1329
|
}), this.nodes.insertAdjacentElement("beforeend", this.summarySvg);
|
|
1312
|
-
},
|
|
1330
|
+
}, Qe = function(e) {
|
|
1313
1331
|
if (console.time("editSummary"), !e)
|
|
1314
1332
|
return;
|
|
1315
1333
|
const t = e.childNodes[1];
|
|
@@ -1322,16 +1340,16 @@ const Re = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1322
1340
|
origin
|
|
1323
1341
|
}));
|
|
1324
1342
|
}), console.timeEnd("editSummary");
|
|
1325
|
-
},
|
|
1343
|
+
}, Ze = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1326
1344
|
__proto__: null,
|
|
1327
|
-
createSummary:
|
|
1328
|
-
editSummary:
|
|
1329
|
-
removeSummary:
|
|
1330
|
-
renderSummary:
|
|
1331
|
-
selectSummary:
|
|
1332
|
-
unselectSummary:
|
|
1345
|
+
createSummary: Ie,
|
|
1346
|
+
editSummary: Qe,
|
|
1347
|
+
removeSummary: Ge,
|
|
1348
|
+
renderSummary: Je,
|
|
1349
|
+
selectSummary: Ue,
|
|
1350
|
+
unselectSummary: Ke
|
|
1333
1351
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
1334
|
-
function
|
|
1352
|
+
function tn(e, t) {
|
|
1335
1353
|
const n = document.createElementNS("http://www.w3.org/2000/svg", "svg");
|
|
1336
1354
|
return b(n, {
|
|
1337
1355
|
version: "1.1",
|
|
@@ -1340,17 +1358,17 @@ function Ze(e, t) {
|
|
|
1340
1358
|
width: t
|
|
1341
1359
|
}), n;
|
|
1342
1360
|
}
|
|
1343
|
-
function
|
|
1361
|
+
function en(e, t) {
|
|
1344
1362
|
return (parseInt(e) - parseInt(t)) / 2;
|
|
1345
1363
|
}
|
|
1346
|
-
function
|
|
1364
|
+
function nn(e, t, n, s) {
|
|
1347
1365
|
const i = document.createElementNS("http://www.w3.org/2000/svg", "g");
|
|
1348
1366
|
return e.childNodes[0].textContent.split(`
|
|
1349
1367
|
`).forEach((l, c) => {
|
|
1350
1368
|
const u = document.createElementNS("http://www.w3.org/2000/svg", "text");
|
|
1351
1369
|
b(u, {
|
|
1352
1370
|
x: n + parseInt(t.paddingLeft) + "",
|
|
1353
|
-
y: s + parseInt(t.paddingTop) +
|
|
1371
|
+
y: s + parseInt(t.paddingTop) + en(t.lineHeight, t.fontSize) * (c + 1) + parseFloat(t.fontSize) * (c + 1) + "",
|
|
1354
1372
|
"text-anchor": "start",
|
|
1355
1373
|
"font-family": t.fontFamily,
|
|
1356
1374
|
"font-size": `${t.fontSize}`,
|
|
@@ -1359,7 +1377,7 @@ function en(e, t, n, s) {
|
|
|
1359
1377
|
}), u.innerHTML = l, i.appendChild(u);
|
|
1360
1378
|
}), i;
|
|
1361
1379
|
}
|
|
1362
|
-
function
|
|
1380
|
+
function sn(e, t, n, s) {
|
|
1363
1381
|
const i = e.childNodes[0].textContent, o = document.createElementNS("http://www.w3.org/2000/svg", "foreignObject");
|
|
1364
1382
|
b(o, {
|
|
1365
1383
|
x: n + parseInt(t.paddingLeft) + "",
|
|
@@ -1373,7 +1391,7 @@ function nn(e, t, n, s) {
|
|
|
1373
1391
|
style: `font-family: ${t.fontFamily}; font-size: ${t.fontSize}; font-weight: ${t.fontWeight}; color: ${t.color}; white-space: pre-wrap;`
|
|
1374
1392
|
}), r.innerHTML = i, o.appendChild(r), o;
|
|
1375
1393
|
}
|
|
1376
|
-
function
|
|
1394
|
+
function Z(e, t, n = !1) {
|
|
1377
1395
|
const s = getComputedStyle(t), { offsetLeft: i, offsetTop: o } = V(e.nodes, t), r = document.createElementNS("http://www.w3.org/2000/svg", "rect");
|
|
1378
1396
|
b(r, {
|
|
1379
1397
|
x: i + "",
|
|
@@ -1389,9 +1407,9 @@ function Q(e, t, n = !1) {
|
|
|
1389
1407
|
const l = document.createElementNS("http://www.w3.org/2000/svg", "g");
|
|
1390
1408
|
l.appendChild(r);
|
|
1391
1409
|
let c;
|
|
1392
|
-
return n ? c =
|
|
1410
|
+
return n ? c = sn(t, s, i, o) : c = nn(t, s, i, o), l.appendChild(c), l;
|
|
1393
1411
|
}
|
|
1394
|
-
function
|
|
1412
|
+
function on(e, t) {
|
|
1395
1413
|
const n = getComputedStyle(t), { offsetLeft: s, offsetTop: i } = V(e.nodes, t), o = document.createElementNS("http://www.w3.org/2000/svg", "a"), r = document.createElementNS("http://www.w3.org/2000/svg", "text");
|
|
1396
1414
|
return b(r, {
|
|
1397
1415
|
x: s + "",
|
|
@@ -1403,39 +1421,39 @@ function sn(e, t) {
|
|
|
1403
1421
|
fill: `${n.color}`
|
|
1404
1422
|
}), r.innerHTML = t.textContent, o.appendChild(r), o.setAttribute("href", t.href), o;
|
|
1405
1423
|
}
|
|
1406
|
-
const G = 100,
|
|
1407
|
-
var
|
|
1408
|
-
const
|
|
1409
|
-
b(
|
|
1424
|
+
const G = 100, rn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">', Mt = (e, t = !1) => {
|
|
1425
|
+
var d, a, f;
|
|
1426
|
+
const n = e.nodes, s = n.offsetHeight + G * 2, i = n.offsetWidth + G * 2, o = tn(s + "px", i + "px"), r = document.createElementNS("http://www.w3.org/2000/svg", "svg"), l = document.createElementNS("http://www.w3.org/2000/svg", "rect");
|
|
1427
|
+
b(l, {
|
|
1410
1428
|
x: "0",
|
|
1411
1429
|
y: "0",
|
|
1412
|
-
width: `${
|
|
1413
|
-
height: `${
|
|
1430
|
+
width: `${i}`,
|
|
1431
|
+
height: `${s}`,
|
|
1414
1432
|
fill: e.theme.cssVar["--bgcolor"]
|
|
1415
|
-
}),
|
|
1416
|
-
const
|
|
1417
|
-
|
|
1433
|
+
}), o.appendChild(l), n.querySelectorAll(".subLines").forEach((g) => {
|
|
1434
|
+
const m = g.cloneNode(!0), { offsetLeft: p, offsetTop: v } = V(n, g.parentElement);
|
|
1435
|
+
m.setAttribute("x", `${p}`), m.setAttribute("y", `${v}`), r.appendChild(m);
|
|
1418
1436
|
});
|
|
1419
|
-
const
|
|
1420
|
-
|
|
1421
|
-
const
|
|
1422
|
-
|
|
1423
|
-
const
|
|
1424
|
-
return
|
|
1425
|
-
|
|
1426
|
-
}),
|
|
1427
|
-
|
|
1428
|
-
}),
|
|
1429
|
-
|
|
1430
|
-
}),
|
|
1431
|
-
|
|
1432
|
-
}), b(
|
|
1437
|
+
const c = (d = n.querySelector(".lines")) == null ? void 0 : d.cloneNode(!0);
|
|
1438
|
+
c && r.appendChild(c);
|
|
1439
|
+
const u = (a = n.querySelector(".topiclinks")) == null ? void 0 : a.cloneNode(!0);
|
|
1440
|
+
u && r.appendChild(u);
|
|
1441
|
+
const h = (f = n.querySelector(".summary")) == null ? void 0 : f.cloneNode(!0);
|
|
1442
|
+
return h && r.appendChild(h), n.querySelectorAll("me-tpc").forEach((g) => {
|
|
1443
|
+
r.appendChild(Z(e, g.text, !t));
|
|
1444
|
+
}), n.querySelectorAll(".tags > span").forEach((g) => {
|
|
1445
|
+
r.appendChild(Z(e, g));
|
|
1446
|
+
}), n.querySelectorAll(".icons > span").forEach((g) => {
|
|
1447
|
+
r.appendChild(Z(e, g));
|
|
1448
|
+
}), n.querySelectorAll(".hyper-link").forEach((g) => {
|
|
1449
|
+
r.appendChild(on(e, g));
|
|
1450
|
+
}), b(r, {
|
|
1433
1451
|
x: G + "",
|
|
1434
1452
|
y: G + "",
|
|
1435
1453
|
overflow: "visible"
|
|
1436
|
-
}),
|
|
1454
|
+
}), o.appendChild(r), rn + o.outerHTML;
|
|
1437
1455
|
};
|
|
1438
|
-
function
|
|
1456
|
+
function ln(e) {
|
|
1439
1457
|
return new Promise((t, n) => {
|
|
1440
1458
|
const s = new FileReader();
|
|
1441
1459
|
s.onload = (i) => {
|
|
@@ -1445,26 +1463,26 @@ function rn(e) {
|
|
|
1445
1463
|
}, s.readAsDataURL(e);
|
|
1446
1464
|
});
|
|
1447
1465
|
}
|
|
1448
|
-
const
|
|
1449
|
-
const
|
|
1450
|
-
return new Blob([
|
|
1451
|
-
},
|
|
1452
|
-
const
|
|
1453
|
-
return new Promise((
|
|
1454
|
-
const
|
|
1455
|
-
|
|
1456
|
-
const
|
|
1457
|
-
|
|
1458
|
-
},
|
|
1466
|
+
const cn = function(e = !1) {
|
|
1467
|
+
const t = Mt(this, e);
|
|
1468
|
+
return new Blob([t], { type: "image/svg+xml" });
|
|
1469
|
+
}, an = async function(e = !1) {
|
|
1470
|
+
const t = Mt(this, e), n = new Blob([t], { type: "image/svg+xml" }), s = await ln(n);
|
|
1471
|
+
return new Promise((i, o) => {
|
|
1472
|
+
const r = new Image();
|
|
1473
|
+
r.setAttribute("crossOrigin", "anonymous"), r.onload = () => {
|
|
1474
|
+
const l = document.createElement("canvas");
|
|
1475
|
+
l.width = r.width, l.height = r.height, l.getContext("2d").drawImage(r, 0, 0), l.toBlob(i, "image/png", 1);
|
|
1476
|
+
}, r.src = s, r.onerror = o;
|
|
1459
1477
|
});
|
|
1460
|
-
},
|
|
1478
|
+
}, hn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1461
1479
|
__proto__: null,
|
|
1462
|
-
exportPng:
|
|
1463
|
-
exportSvg:
|
|
1464
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
1465
|
-
getObjById:
|
|
1480
|
+
exportPng: an,
|
|
1481
|
+
exportSvg: cn
|
|
1482
|
+
}, Symbol.toStringTag, { value: "Module" })), dn = {}, un = {
|
|
1483
|
+
getObjById: U,
|
|
1466
1484
|
generateNewObj: $t,
|
|
1467
|
-
layout:
|
|
1485
|
+
layout: Dt,
|
|
1468
1486
|
linkDiv: Xt,
|
|
1469
1487
|
editTopic: qt,
|
|
1470
1488
|
createWrapper: Pt,
|
|
@@ -1474,14 +1492,14 @@ const ln = function() {
|
|
|
1474
1492
|
findEle: C,
|
|
1475
1493
|
changeTheme: ie,
|
|
1476
1494
|
...$e,
|
|
1495
|
+
...dn,
|
|
1496
|
+
...je,
|
|
1497
|
+
...Ze,
|
|
1477
1498
|
...hn,
|
|
1478
|
-
...Re,
|
|
1479
|
-
...Qe,
|
|
1480
|
-
...an,
|
|
1481
1499
|
init(e) {
|
|
1482
1500
|
if (!e || !e.nodeData)
|
|
1483
1501
|
return new Error("MindElixir: `data` is required");
|
|
1484
|
-
e.direction !== void 0 && (this.direction = e.direction), this.changeTheme(e.theme || this.theme, !1), this.nodeData = e.nodeData,
|
|
1502
|
+
e.direction !== void 0 && (this.direction = e.direction), this.changeTheme(e.theme || this.theme, !1), this.nodeData = e.nodeData, et(this.nodeData), this.linkData = e.linkData || {}, this.summaries = e.summaries || [], this.tidyCustomLink(), this.toolBar && Kt(this), this.toCenter(), this.layout(), this.linkDiv();
|
|
1485
1503
|
}
|
|
1486
1504
|
}, j = document;
|
|
1487
1505
|
function M({
|
|
@@ -1510,17 +1528,17 @@ function M({
|
|
|
1510
1528
|
throw new Error("MindElixir: el is not a valid element");
|
|
1511
1529
|
v.className += " mind-elixir", v.innerHTML = "", v.style.setProperty("--gap", S + "px"), this.mindElixirBox = v, this.before = u || {}, this.locale = n || "en", this.contextMenuOption = r, this.contextMenu = o === void 0 ? !0 : o, this.toolBar = l === void 0 ? !0 : l, this.keypress = c === void 0 ? !0 : c, this.mobileMenu = m || !1, this.direction = typeof t == "number" ? t : 1, this.draggable = s === void 0 ? !0 : s, this.newTopicName = h || "new node", this.editable = i === void 0 ? !0 : i, this.allowUndo = d === void 0 ? !1 : d, this.currentNode = null, this.currentLink = null, this.scaleVal = 1, this.tempDirection = null, this.mainLinkStyle = a || 0, this.subLinkStyle = f || 0, this.overflowHidden = g || !1, this.bus = Nt.create(), this.container = j.createElement("div"), this.container.className = "map-container";
|
|
1512
1530
|
const w = window.matchMedia("(prefers-color-scheme: dark)");
|
|
1513
|
-
this.theme = p || (w.matches ?
|
|
1531
|
+
this.theme = p || (w.matches ? vt : gt);
|
|
1514
1532
|
const _ = j.createElement("div");
|
|
1515
|
-
_.className = "map-canvas", this.map = _, this.map.setAttribute("tabindex", "0"), this.container.appendChild(this.map), this.mindElixirBox.appendChild(this.container), this.nodes = j.createElement("me-nodes"), this.nodes.className = "main-node-container", this.lines = W("lines"), this.summarySvg = W("summary"), this.linkController = W("linkcontroller"), this.P2 = j.createElement("div"), this.P3 = j.createElement("div"), this.P2.className = this.P3.className = "circle", this.P2.style.display = this.P3.style.display = "none", this.line1 =
|
|
1533
|
+
_.className = "map-canvas", this.map = _, this.map.setAttribute("tabindex", "0"), this.container.appendChild(this.map), this.mindElixirBox.appendChild(this.container), this.nodes = j.createElement("me-nodes"), this.nodes.className = "main-node-container", this.lines = W("lines"), this.summarySvg = W("summary"), this.linkController = W("linkcontroller"), this.P2 = j.createElement("div"), this.P3 = j.createElement("div"), this.P2.className = this.P3.className = "circle", this.P2.style.display = this.P3.style.display = "none", this.line1 = lt(), this.line2 = lt(), this.linkController.appendChild(this.line1), this.linkController.appendChild(this.line2), this.linkSvgGroup = W("topiclinks"), this.map.appendChild(this.nodes), this.overflowHidden ? this.container.style.overflow = "hidden" : Tt(this);
|
|
1516
1534
|
}
|
|
1517
|
-
M.prototype =
|
|
1535
|
+
M.prototype = un;
|
|
1518
1536
|
M.LEFT = q;
|
|
1519
|
-
M.RIGHT =
|
|
1520
|
-
M.SIDE =
|
|
1521
|
-
M.THEME =
|
|
1522
|
-
M.DARK_THEME =
|
|
1523
|
-
M.version = "3.2.
|
|
1537
|
+
M.RIGHT = tt;
|
|
1538
|
+
M.SIDE = Q;
|
|
1539
|
+
M.THEME = gt;
|
|
1540
|
+
M.DARK_THEME = vt;
|
|
1541
|
+
M.version = "3.2.4";
|
|
1524
1542
|
M.E = C;
|
|
1525
1543
|
export {
|
|
1526
1544
|
M as default
|