feat: 添加op抽奖小工具。

This commit is contained in:
539943419 committed 2025-01-12 17:13:34 +08:00
1 parent faaa837783
commit 1b9f76e28b
10 files changed
+138 -30

No files matched your search

+2 -1
View File
@@ -1,5 +1,6 @@
{ {
"cSpell.words": [ "cSpell.words": [
"unplugin" "unplugin"
] ],
"vue3snippets.enable-compile-vue-file-on-did-save-code": false
} }
+9 -5
View File
@@ -1,14 +1,14 @@
<template> <template>
<main id="miao-main"> <main id="miao-main">
<n-scrollbar> <n-scrollbar>
<slot></slot> <div class="miao-main-slot-warpper">
<slot></slot>
</div>
</n-scrollbar> </n-scrollbar>
</main> </main>
</template> </template>
<script setup lang="ts"> <script setup lang="ts"></script>
</script>
<style lang="scss" scoped> <style lang="scss" scoped>
#miao-main { #miao-main {
@@ -16,9 +16,13 @@
height: calc(100vh - 60px); height: calc(100vh - 60px);
max-height: calc(100vh - 60px); max-height: calc(100vh - 60px);
width: 100%; width: 100%;
// max-width: 1200px;
margin: 0; margin: 0;
padding: 0; padding: 0;
box-sizing: border-box; box-sizing: border-box;
.miao-main-slot-warpper {
position: relative;
min-height: calc(100vh - 60px);
}
} }
</style> </style>
+1
View File
@@ -70,6 +70,7 @@ onMounted(() => {
position: relative; position: relative;
background-color: #fff; background-color: #fff;
user-select: none; user-select: none;
z-index: 70582140;
#miao-header { #miao-header {
box-sizing: border-box; box-sizing: border-box;
+21 -21
View File
@@ -5,25 +5,25 @@ import Components from "unplugin-vue-components/vite";
// https://nuxt.com/docs/api/configuration/nuxt-config // https://nuxt.com/docs/api/configuration/nuxt-config
// @ts-ignore // @ts-ignore
export default defineNuxtConfig({ export default defineNuxtConfig({
devtools: { enabled: true }, devtools: { enabled: true },
alias: { alias: {
"@": "/" "@": "/"
}, },
vite: { vite: {
server: {}, server: {},
plugins: [ plugins: [
AutoImport({ AutoImport({
imports: [ imports: [
{ {
"naive-ui": ["useDialog", "useMessage", "useNotification", "useLoadingBar"] "naive-ui": ["useDialog", "useMessage", "useNotification", "useLoadingBar"]
} }
] ]
}), }),
Components({ Components({
resolvers: [NaiveUiResolver()] resolvers: [NaiveUiResolver()]
}) })
] ]
}, },
modules: ["nuxtjs-naive-ui", "@pinia/nuxt"], modules: ["nuxtjs-naive-ui", "@pinia/nuxt"],
compatibilityDate: "2025-01-12" compatibilityDate: "2025-01-12"
}); });
+25 -3
View File
@@ -20,7 +20,8 @@
<div class="content-item-description">{{ cItem.description }}</div> <div class="content-item-description">{{ cItem.description }}</div>
<div class="content-item-link-warp"> <div class="content-item-link-warp">
<div>link:</div> <div>link:</div>
<a v-for="link in cItem.links" :href="link.url" target="_blank">{{ link.name }}</a> <a v-for="link in (cItem.links ?? [])" :href="link.url" target="_blank">{{ link.name }}</a>
<NuxtLink v-for="link in (cItem.nuxtLinks ?? [])" :to="link.to">{{ link.name }}</NuxtLink>
</div> </div>
</div> </div>
</div> </div>
@@ -42,9 +43,13 @@ type PageContent = {
type ContentItem = { type ContentItem = {
name: string, name: string,
description: string, description: string,
links: { links?: {
name: string, name: string,
url: string url: string
}[],
nuxtLinks?: {
name: string,
to: string
}[] }[]
} }
@@ -104,6 +109,21 @@ const PageContent = reactive<PageContent[]>([
] ]
}, },
] ]
}, {
subTitle: '小工具',
show: true,
content: [
{
name: 'genshin-gacha',
description: '通过模拟来计算抽卡成功率的小工具',
nuxtLinks: [
{
name: 'demo',
to: 'tool/genshin-gacha'
}
]
},
]
} }
]) ])
@@ -120,7 +140,8 @@ const switchItemShow = (item: PageContent) => {
<style lang="scss" scoped> <style lang="scss" scoped>
.main { .main {
box-sizing: border-box; box-sizing: border-box;
min-height: calc(100vh - 60px); // min-height: calc(100vh - 60px);
height: 100%;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
padding: 20px 10px; padding: 20px 10px;
@@ -255,6 +276,7 @@ const switchItemShow = (item: PageContent) => {
font-weight: 300; font-weight: 300;
text-decoration: none; text-decoration: none;
transition: color .15s linear; transition: color .15s linear;
cursor: pointer;
&:hover { &:hover {
color: #15aa87; color: #15aa87;
+27
View File
@@ -0,0 +1,27 @@
<template>
<div class="iframe-warpper">
<iframe src="/iframe-source/genshin-gacha/index.html" frameborder="0"></iframe>
</div>
</template>
<script setup lang="ts">
</script>
<style scoped>
.iframe-warpper {
width: 100%;
min-height: inherit;
padding: 0;
margin: 0;
display: flex;
flex-direction: column;
}
iframe {
flex: 1;
width: 100%;
/* height: 100%; */
padding: 0;
margin: 0;
}
</style>
@@ -0,0 +1 @@
body{margin:0;padding:0;min-height:100vh;width:100vw;position:relative}#root{min-height:100vh;width:100%;position:relative;display:flex;justify-content:center;align-items:center}#root .main{flex:1;min-height:100%;max-width:800px;width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}#root .main .card{width:100%;height:auto;border:1px solid #cdcdcd;border-radius:5px}#root .main .card .title{height:40px;background-color:#ececec;border-bottom:1px solid #cdcdcd;display:flex;align-items:center;padding-left:10px;font-size:larger;letter-spacing:1px}#root .main .card .container{padding:10px;display:flex;flex-direction:column;gap:10px}#root .main .card .container .controller{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:5px;padding-bottom:10px}#root .main .card .container .controller .target{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;flex-wrap:wrap;gap:5px}#root .main .card .container .controller .target .target-group,#root .main .card .container .controller .target .target-item{display:flex;gap:5px}#root .main .card .container .controller .target .target-item .target-name{display:flex;align-items:center;justify-content:flex-start;font-size:larger;margin-right:3px;text-wrap:nowrap}#root .main .card .container .controller .target .target-item .target-input{margin:0;height:auto;width:30px;padding:5px;border:1px solid #cdcdcd;border-radius:2px;transition:border-color .2s ease-in-out,box-shadow .2s ease-in-out;caret-color:#5eb19f;text-decoration-color:#93979b;color:#333639;text-align:center;font-size:1em}#root .main .card .container .controller .target .target-item .target-input:hover{border-color:#5eb19f}#root .main .card .container .controller .target .target-item .target-input:focus{border-color:#6dccb7;box-shadow:0 0 3px #5eb19f;outline:none}#root .main .card .container .controller .target .target-gap{width:5px}#root .main .card .container .controller .controller-btns{width:100%;display:flex;justify-content:center;gap:15px}#root .main .card .container .controller .controller-btns .controller-button{background-color:#fff;outline:none;border:1px solid #cdcdcd;padding:5px 10px;letter-spacing:3px;border-radius:2px;display:flex;justify-content:center;align-items:center;transition:border-color .2s ease-in-out;cursor:pointer;font-size:large}#root .main .card .container .controller .controller-btns .controller-button:hover{border-color:#5eb19f}#root .main .card .container .controller .controller-btns .controller-button:active{border-color:#6dccb7;outline:none}#root .main .card .container .result{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:10px;border-top:1px solid #cdcdcd;padding-top:10px}#root .main .card .container .result .result-title{font-size:larger;letter-spacing:2px;margin-bottom:10px}.echarts-container{width:100%;height:100%}.echarts-container .echarts{width:100%;height:500px}
@@ -0,0 +1,37 @@
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const o of a.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();const x1=(e,t)=>e===t,Yo={equals:x1};let bg=Dg;const zr=1,Xo=2,Tg={owned:null,cleanups:null,context:null,owner:null};var $t=null;let ou=null,b1=null,At=null,Ht=null,fr=null,Cs=0;function T1(e,t){const r=At,n=$t,i=e.length===0,a=t===void 0?n:t,o=i?Tg:{owned:null,cleanups:null,context:a?a.context:null,owner:a},s=i?e:()=>e(()=>Ms(()=>la(o)));$t=o,At=null;try{return Ia(s,!0)}finally{At=r,$t=n}}function ue(e,t){t=t?Object.assign({},Yo,t):Yo;const r={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0},n=i=>(typeof i=="function"&&(i=i(r.value)),Mg(r,i));return[Cg.bind(r),n]}function Ae(e,t,r){const n=Hf(e,t,!1,zr);La(n)}function C1(e,t,r){bg=L1;const n=Hf(e,t,!1,zr);n.user=!0,fr?fr.push(n):La(n)}function M1(e,t,r){r=r?Object.assign({},Yo,r):Yo;const n=Hf(e,t,!0,0);return n.observers=null,n.observerSlots=null,n.comparator=r.equals||void 0,La(n),Cg.bind(n)}function Ms(e){if(At===null)return e();const t=At;At=null;try{return e()}finally{At=t}}function Cg(){if(this.sources&&this.state)if(this.state===zr)La(this);else{const e=Ht;Ht=null,Ia(()=>Zo(this),!1),Ht=e}if(At){const e=this.observers?this.observers.length:0;At.sources?(At.sources.push(this),At.sourceSlots.push(e)):(At.sources=[this],At.sourceSlots=[e]),this.observers?(this.observers.push(At),this.observerSlots.push(At.sources.length-1)):(this.observers=[At],this.observerSlots=[At.sources.length-1])}return this.value}function Mg(e,t,r){let n=e.value;return(!e.comparator||!e.comparator(n,t))&&(e.value=t,e.observers&&e.observers.length&&Ia(()=>{for(let i=0;i<e.observers.length;i+=1){const a=e.observers[i],o=ou&&ou.running;o&&ou.disposed.has(a),(o?!a.tState:!a.state)&&(a.pure?Ht.push(a):fr.push(a),a.observers&&Ag(a)),o||(a.state=zr)}if(Ht.length>1e6)throw Ht=[],new Error},!1)),t}function La(e){if(!e.fn)return;la(e);const t=Cs;D1(e,e.value,t)}function D1(e,t,r){let n;const i=$t,a=At;At=$t=e;try{n=e.fn(t)}catch(o){return e.pure&&(e.state=zr,e.owned&&e.owned.forEach(la),e.owned=null),e.updatedAt=r+1,Lg(o)}finally{At=a,$t=i}(!e.updatedAt||e.updatedAt<=r)&&(e.updatedAt!=null&&"observers"in e?Mg(e,n):e.value=n,e.updatedAt=r)}function Hf(e,t,r,n=zr,i){const a={fn:e,state:n,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:$t,context:$t?$t.context:null,pure:r};return $t===null||$t!==Tg&&($t.owned?$t.owned.push(a):$t.owned=[a]),a}function qo(e){if(e.state===0)return;if(e.state===Xo)return Zo(e);if(e.suspense&&Ms(e.suspense.inFallback))return e.suspense.effects.push(e);const t=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt<Cs);)e.state&&t.push(e);for(let r=t.length-1;r>=0;r--)if(e=t[r],e.state===zr)La(e);else if(e.state===Xo){const n=Ht;Ht=null,Ia(()=>Zo(e,t[0]),!1),Ht=n}}function Ia(e,t){if(Ht)return e();let r=!1;t||(Ht=[]),fr?r=!0:fr=[],Cs++;try{const n=e();return A1(r),n}catch(n){r||(fr=null),Ht=null,Lg(n)}}function A1(e){if(Ht&&(Dg(Ht),Ht=null),e)return;const t=fr;fr=null,t.length&&Ia(()=>bg(t),!1)}function Dg(e){for(let t=0;t<e.length;t++)qo(e[t])}function L1(e){let t,r=0;for(t=0;t<e.length;t++){const n=e[t];n.user?e[r++]=n:qo(n)}for(t=0;t<r;t++)qo(e[t])}function Zo(e,t){e.state=0;for(let r=0;r<e.sources.length;r+=1){const n=e.sources[r];if(n.sources){const i=n.state;i===zr?n!==t&&(!n.updatedAt||n.updatedAt<Cs)&&qo(n):i===Xo&&Zo(n,t)}}}function Ag(e){for(let t=0;t<e.observers.length;t+=1){const r=e.observers[t];r.state||(r.state=Xo,r.pure?Ht.push(r):fr.push(r),r.observers&&Ag(r))}}function la(e){let t;if(e.sources)for(;e.sources.length;){const r=e.sources.pop(),n=e.sourceSlots.pop(),i=r.observers;if(i&&i.length){const a=i.pop(),o=r.observerSlots.pop();n<i.length&&(a.sourceSlots[o]=n,i[n]=a,r.observerSlots[n]=o)}}if(e.tOwned){for(t=e.tOwned.length-1;t>=0;t--)la(e.tOwned[t]);delete e.tOwned}if(e.owned){for(t=e.owned.length-1;t>=0;t--)la(e.owned[t]);e.owned=null}if(e.cleanups){for(t=e.cleanups.length-1;t>=0;t--)e.cleanups[t]();e.cleanups=null}e.state=0}function I1(e){return e instanceof Error?e:new Error(typeof e=="string"?e:"Unknown error",{cause:e})}function Lg(e,t=$t){throw I1(e)}function Ig(e,t){return Ms(()=>e(t||{}))}function P1(e,t,r){let n=r.length,i=t.length,a=n,o=0,s=0,u=t[i-1].nextSibling,l=null;for(;o<i||s<a;){if(t[o]===r[s]){o++,s++;continue}for(;t[i-1]===r[a-1];)i--,a--;if(i===o){const f=a<n?s?r[s-1].nextSiblLine truncated
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */var Bl=function(e,t){return Bl=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(r[i]=n[i])},Bl(e,t)};function H(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Bl(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var vb=function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e}(),cb=function(){function e(){this.browser=new vb,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return e}(),q=new cb;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(q.wxa=!0,q.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?q.worker=!0:!q.hasGlobalWindow||"Deno"in window?(q.node=!0,q.svgSupported=!0):db(navigator.userAgent,q);function db(e,t){var r=t.browser,n=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);n&&(r.firefox=!0,r.version=n[1]),i&&(r.ie=!0,r.version=i[1]),a&&(r.edge=!0,r.version=a[1],r.newEdge=+a[1].split(".")[0]>18),o&&(r.weChat=!0),t.svgSupported=typeof SVGRect<"u",t.touchEventsSupported="ontouchstart"in window&&!r.ie&&!r.edge,t.pointerEventsSupported="onpointerdown"in window&&(r.edge||r.ie&&+r.version>=11),t.domSupported=typeof document<"u";var s=document.documentElement.style;t.transform3dSupported=(r.ie&&"transition"in s||r.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),t.transformSupported=t.transform3dSupported||r.ie&&+r.version>=9}var jf=12,pb="sans-serif",_n=jf+"px "+pb,gb=20,yb=100,mb="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function _b(e){var t={};if(typeof JSON>"u")return t;for(var r=0;r<e.length;r++){var n=String.fromCharCode(r+32),i=(e.charCodeAt(r)-gb)/yb;t[n]=i}return t}var wb=_b(mb),li={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:function(){var e,t;return function(r,n){if(!e){var i=li.createCanvas();e=i&&i.getContext("2d")}if(e)return t!==n&&(t=e.font=n||_n),e.measureText(r);r=r||"",n=n||_n;var a=/((?:\d+)?\.?\d*)px/.exec(n),o=a&&+a[1]||jf,s=0;if(n.indexOf("mono")>=0)s=o*r.length;else for(var u=0;u<r.length;u++){var l=wb[r[u]];s+=l==null?o:l*o}return{width:s}}}(),loadImage:function(e,t,r){var n=new Image;return n.onload=t,n.onerror=r,n.src=e,n}},ty=Rr(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(e,t){return e["[object "+t+"]"]=!0,e},{}),ey=Rr(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(e,t){return e["[object "+t+"Array]"]=!0,e},{}),fi=Object.prototype.toString,Is=Array.prototype,Sb=Is.forEach,xb=Is.filter,Kf=Is.slice,bb=Is.map,Pv=(function(){}).constructor,$a=Pv?Pv.prototype:null,Qf="__proto__",Tb=2311;function ry(){return Tb++}function Jf(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];typeof console<"u"&&console.error.apply(console,e)}function nt(e){if(e==null||typeof e!="object")return e;var t=e,r=fi.call(e);if(r==="[object Array]"){if(!Zi(e)){t=[];for(var n=0,i=e.length;n<i;n++)t[n]=nt(e[n])}}else if(ey[r]){if(!Zi(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var n=0,i=e.length;n<i;n++)t[n]=e[n]}}}else if(!ty[r]&&!Zi(e)&&!va(e)){t={};for(var o in e)e.hasOwnProperty(o)&&o!==Qf&&(t[o]=nt(e[o]))}return t}function ft(e,t,r){if(!X(t)||!X(e))return r?nt(t):e;for(var n in t)if(t.hasOwnProperty(n)&&n!==Qf){var i=e[n],a=t[n];X(a)&&X(i)&&!z(a)&&!z(i)&&!va(a)&&!va(i)&&!Ev(a)&&!Ev(i)&&!Zi(a)&&!Zi(i)?ft(i,a,r):(r||!(n in e))&&(e[n]=nt(t[n]))}return e}function B(e,t){if(Object.assign)Object.assign(e,t);else for(var r in t)t.hasOwnProperty(r)&&r!==Qf&&(e[r]=t[r]);return e}function et(e,t,r){for(var n=gt(t),i=0,a=n.length;i<a;i++){var o=n[i];e[o]==null&&(e[o]=t[o])}return e}function lt(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r}return-1}function Cb(e,t){var r=e.prototype;function n(){}n.prototype=t.prototype,e.prototype=new n;for(var i in r)r.hasOwnProperty(i)&&(e.prototype[i]=r[i]);e.prototype.constructor=e,e.superClass=t}function Qe(e,t,r){if(e="prototype"in e?e.prototype:e,t="prototype"in t?t.prototype:t,Object.getOwnPropertyNames)for(var n=Object.getOwnPropertyNames(t),i=0;i<n.length;i++){var a=n[i];a!=="constructor"&&e[a]==null&&(e[a]=t[a])}else et(e,t)}function Xt(e){return!e||typeof e=="string"?!1:typeof e.length=="number"}function M(e,t,r){if(e&&t)if(e.forEach&&e.foLine truncated
`),a=i.length;if(a===1)return sc(i[0],t,r,n);for(var o=new it(0,0,0,0),s=0;s<i.length;s++){var u=sc(i[s],t,r,n);s===0?o.copy(u):o.union(u)}return o}function Hi(e,t,r){return r==="right"?e-=t:r==="center"&&(e-=t/2),e}function $n(e,t,r){return r==="middle"?e-=t/2:r==="bottom"&&(e-=t),e}function oh(e){return ae("国",e)}function kr(e,t){return typeof e=="string"?e.lastIndexOf("%")>=0?parseFloat(e)/100*t:parseFloat(e):e}function is(e,t,r){var n=t.position||"inside",i=t.distance!=null?t.distance:5,a=r.height,o=r.width,s=a/2,u=r.x,l=r.y,f="left",h="top";if(n instanceof Array)u+=kr(n[0],r.width),l+=kr(n[1],r.height),f=null,h=null;else switch(n){case"left":u-=i,l+=s,f="right",h="middle";break;case"right":u+=i+o,l+=s,h="middle";break;case"top":u+=o/2,l-=i,f="center",h="bottom";break;case"bottom":u+=o/2,l+=a+i,f="center";break;case"inside":u+=o/2,l+=s,f="center",h="middle";break;case"insideLeft":u+=i,l+=s,h="middle";break;case"insideRight":u+=o-i,l+=s,f="right",h="middle";break;case"insideTop":u+=o/2,l+=i,f="center";break;case"insideBottom":u+=o/2,l+=a-i,f="center",h="bottom";break;case"insideTopLeft":u+=i,l+=i;break;case"insideTopRight":u+=o-i,l+=i,f="right";break;case"insideBottomLeft":u+=i,l+=a-i,h="bottom";break;case"insideBottomRight":u+=o-i,l+=a-i,f="right",h="bottom";break}return e=e||{},e.x=u,e.y=l,e.align=f,e.verticalAlign=h,e}var Mu="__zr_normal__",Du=da.concat(["ignore"]),OT=Rr(da,function(e,t){return e[t]=!0,e},{ignore:!1}),Ln={},kT=new it(0,0,0,0),Os=function(){function e(t){this.id=ry(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return e.prototype._init=function(t){this.attr(t)},e.prototype.drift=function(t,r,n){switch(this.draggable){case"horizontal":r=0;break;case"vertical":t=0;break}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=t,i[5]+=r,this.decomposeTransform(),this.markRedraw()},e.prototype.beforeUpdate=function(){},e.prototype.afterUpdate=function(){},e.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},e.prototype.updateInnerText=function(t){var r=this._textContent;if(r&&(!r.ignore||t)){this.textConfig||(this.textConfig={});var n=this.textConfig,i=n.local,a=r.innerTransformable,o=void 0,s=void 0,u=!1;a.parent=i?this:null;var l=!1;if(a.copyTransform(r),n.position!=null){var f=kT;n.layoutRect?f.copy(n.layoutRect):f.copy(this.getBoundingRect()),i||f.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Ln,n,f):is(Ln,n,f),a.x=Ln.x,a.y=Ln.y,o=Ln.align,s=Ln.verticalAlign;var h=n.origin;if(h&&n.rotation!=null){var c=void 0,v=void 0;h==="center"?(c=f.width*.5,v=f.height*.5):(c=kr(h[0],f.width),v=kr(h[1],f.height)),l=!0,a.originX=-a.x+c+(i?0:f.x),a.originY=-a.y+v+(i?0:f.y)}}n.rotation!=null&&(a.rotation=n.rotation);var d=n.offset;d&&(a.x+=d[0],a.y+=d[1],l||(a.originX=-d[0],a.originY=-d[1]));var g=n.inside==null?typeof n.position=="string"&&n.position.indexOf("inside")>=0:n.inside,p=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,m=void 0,_=void 0;g&&this.canBeInsideText()?(y=n.insideFill,m=n.insideStroke,(y==null||y==="auto")&&(y=this.getInsideTextFill()),(m==null||m==="auto")&&(m=this.getInsideTextStroke(y),_=!0)):(y=n.outsideFill,m=n.outsideStroke,(y==null||y==="auto")&&(y=this.getOutsideFill()),(m==null||m==="auto")&&(m=this.getOutsideStroke(y),_=!0)),y=y||"#000",(y!==p.fill||m!==p.stroke||_!==p.autoStroke||o!==p.align||s!==p.verticalAlign)&&(u=!0,p.fill=y,p.stroke=m,p.autoStroke=_,p.align=o,p.verticalAlign=s,r.setDefaultTextStyle(p)),r.__dirty|=ie,u&&r.dirtyStyle(!0)}},e.prototype.canBeInsideText=function(){return!0},e.prototype.getInsideTextFill=function(){return"#fff"},e.prototype.getInsideTextStroke=function(t){return"#000"},e.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Ql:Kl},e.prototype.getOutsideStroke=function(t){var r=this.__zr&&this.__zr.getBackgroundColor(),n=typeof r=="string"&&Jn(r);n||(n=[255,255,255,1]);for(var i=n[3],a=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*i+(a?0:255)*(1-i);return n[3]=1,by(n,"rgba")},e.prototype.traverse=function(t,r){},e.prototype.attrKV=function(t,r){t==="textConfig"?this.setTextConfig(r):t==="textContent"?this.setTextContent(r):t==="clipPath"?this.setClipPath(r):t==="extra"?(this.extra=this.extra||{},B(this.extra,r)):this[t]=r},e.prototype.hide=function(){this.ignore=!0,this.markRedraw()},e.prototype.show=function(){this.ignore=!1,this.markRedraw()},e.prototype.attr=function(t,r){if(typeof t=="string")this.attrKV(t,r);else if(X(t))for(var n=t,i=gt(n),a=0;a<i.length;a++){var o=i[a];this.attrKV(o,t[o])}return this.markRedraw(),this},e.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var r=this._normalState,n=0;n<this.animators.length;n++){var i=this.animators[n],a=i.__fromStateTransition;if(!(i.getLoop()||a&&a!==Mu)){var o=i.targetName,s=o?r[o]:r;i.saveTo(s)}}},e.prototype._innerSaveToNormal=function(t){var r=this._normalState;r||(r=this._normalState={}),t.textConfi Line truncated
* ZRender, a high performance 2d drawing library.
*
* Copyright (c) 2013, Baidu Inc.
* All rights reserved.
*
* LICENSE
* https://github.com/ecomfe/zrender/blob/master/LICENSE.txt
*/var No={},Ay={};function GT(e){delete Ay[e]}function HT(e){if(!e)return!1;if(typeof e=="string")return rs(e,1)<jl;if(e.colorStops){for(var t=e.colorStops,r=0,n=t.length,i=0;i<n;i++)r+=rs(t[i].color,1);return r/=n,r<jl}return!1}var VT=function(){function e(t,r,n){var i=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,n=n||{},this.dom=r,this.id=t;var a=new fT,o=n.renderer||"canvas";No[o]||(o=gt(No)[0]),n.useDirtyRect=n.useDirtyRect==null?!1:n.useDirtyRect;var s=new No[o](r,a,n,t),u=n.ssr||s.ssrOnly;this.storage=a,this.painter=s;var l=!q.node&&!q.worker&&!u?new PT(s.getViewportRoot(),s.root):null,f=n.useCoarsePointer,h=f==null||f==="auto"?q.touchEventsSupported:!!f,c=44,v;h&&(v=K(n.pointerSize,c)),this.handler=new fy(a,s,l,s.root,v),this.animation=new TT({stage:{update:u?null:function(){return i._flush(!0)}}}),u||this.animation.start()}return e.prototype.add=function(t){this._disposed||!t||(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},e.prototype.remove=function(t){this._disposed||!t||(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},e.prototype.configLayer=function(t,r){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,r),this.refresh())},e.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=HT(t))},e.prototype.getBackgroundColor=function(){return this._backgroundColor},e.prototype.setDarkMode=function(t){this._darkMode=t},e.prototype.isDarkMode=function(){return this._darkMode},e.prototype.refreshImmediately=function(t){this._disposed||(t||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},e.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},e.prototype.flush=function(){this._disposed||this._flush(!1)},e.prototype._flush=function(t){var r,n=Yn();this._needsRefresh&&(r=!0,this.refreshImmediately(t)),this._needsRefreshHover&&(r=!0,this.refreshHoverImmediately());var i=Yn();r?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:i-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},e.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},e.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},e.prototype.refreshHover=function(){this._needsRefreshHover=!0},e.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},e.prototype.resize=function(t){this._disposed||(t=t||{},this.painter.resize(t.width,t.height),this.handler.resize())},e.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},e.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},e.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},e.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},e.prototype.findHover=function(t,r){if(!this._disposed)return this.handler.findHover(t,r)},e.prototype.on=function(t,r,n){return this._disposed||this.handler.on(t,r,n),this},e.prototype.off=function(t,r){this._disposed||this.handler.off(t,r)},e.prototype.trigger=function(t,r){this._disposed||this.handler.trigger(t,r)},e.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),r=0;r<t.length;r++)t[r]instanceof Ee&&t[r].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},e.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,GT(this.id))},e}();function uc(e,t){var r=new VT(ry(),e,t);return Ay[r.id]=r,r}function $T(e,t){No[e]=t}var lc=1e-4,Ly=20;function WT(e){return e.replace(/^\s+|\s+$/g,"")}function Jl(e,t,r,n){var i=t[0],a=t[1],o=r[0],s=r[1],u=a-i,l=s-o;if(u===0)return l===0?o:(o+s)/2;if(n)if(u>0){if(e<=i)return o;if(e>=a)return s}else{if(e>=i)return o;if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/u*l+o}function pt(e,t){switch(e){case"center":case"middle":e="50%";break;case"left":case"top":e="0%";break;case"right":case"bottom":e="100%";break}return W(e)?WT(e).match(/%$/)?parseFloat(e)/100*t:parseFloat(e):e==null?NaN:+e}function Lt(e,t,r){return t==null&&(t=10),t=Math.min(Math.max(0,t),Ly),e=(+e).toFixed(t),r?e:+e}function sr(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,r=0;r<15;r++,t*=10)if(Math.round(e*t)/t===e)return r}return UT(e)}function UT(e){var t=e.toString().toLowerCase(),r=t.indexOf("e"),n=r>0?+t.slice(r+1):0,i=r>0?r:t.length,a=t.indexOf("."),o=a<0?0:i-1-a;return Math.max(0,o-n)}function YT(e,t){var r=Math.log,n=Math.Line truncated
`);a=Hy(r,n,i,a);for(var s=!1,u={},l=0,f=o.length;l<f;l++)Vy(u,o[l],a),o[l]=u.textLine,s=s||u.isTruncated;e.text=o.join(`
`),e.isTruncated=s}function Hy(e,t,r,n){n=n||{};var i=B({},n);i.font=t,r=K(r,"..."),i.maxIterations=K(n.maxIterations,2);var a=i.minChar=K(n.minChar,0);i.cnCharWidth=ae("国",t);var o=i.ascCharWidth=ae("a",t);i.placeholder=K(n.placeholder,"");for(var s=e=Math.max(0,e-1),u=0;u<a&&s>=o;u++)s-=o;var l=ae(r,t);return l>s&&(r="",l=0),s=e-l,i.ellipsis=r,i.ellipsisWidth=l,i.contentWidth=s,i.containerWidth=e,i}function Vy(e,t,r){var n=r.containerWidth,i=r.font,a=r.contentWidth;if(!n){e.textLine="",e.isTruncated=!1;return}var o=ae(t,i);if(o<=n){e.textLine=t,e.isTruncated=!1;return}for(var s=0;;s++){if(o<=a||s>=r.maxIterations){t+=r.ellipsis;break}var u=s===0?MC(t,a,r.ascCharWidth,r.cnCharWidth):o>0?Math.floor(t.length*a/o):0;t=t.substr(0,u),o=ae(t,i)}t===""&&(t=r.placeholder),e.textLine=t,e.isTruncated=!0}function MC(e,t,r,n){for(var i=0,a=0,o=e.length;a<o&&i<t;a++){var s=e.charCodeAt(a);i+=0<=s&&s<=127?r:n}return a}function DC(e,t){e!=null&&(e+="");var r=t.overflow,n=t.padding,i=t.font,a=r==="truncate",o=oh(i),s=K(t.lineHeight,o),u=!!t.backgroundColor,l=t.lineOverflow==="truncate",f=!1,h=t.width,c;h!=null&&(r==="break"||r==="breakAll")?c=e?$y(e,t.font,h,r==="breakAll",0).lines:[]:c=e?e.split(`
`):[];var v=c.length*s,d=K(t.height,v);if(v>d&&l){var g=Math.floor(d/s);f=f||c.length>g,c=c.slice(0,g)}if(e&&a&&h!=null)for(var p=Hy(h,i,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),y={},m=0;m<c.length;m++)Vy(y,c[m],p),c[m]=y.textLine,f=f||y.isTruncated;for(var _=d,w=0,m=0;m<c.length;m++)w=Math.max(ae(c[m],i),w);h==null&&(h=w);var x=w;return n&&(_+=n[0]+n[2],x+=n[1]+n[3],h+=n[1]+n[3]),u&&(x=h),{lines:c,height:d,outerWidth:x,outerHeight:_,lineHeight:s,calculatedLineHeight:o,contentWidth:w,contentHeight:v,width:h,isTruncated:f}}var AC=function(){function e(){}return e}(),dc=function(){function e(t){this.tokens=[],t&&(this.tokens=t)}return e}(),LC=function(){function e(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return e}();function IC(e,t){var r=new LC;if(e!=null&&(e+=""),!e)return r;for(var n=t.width,i=t.height,a=t.overflow,o=(a==="break"||a==="breakAll")&&n!=null?{width:n,accumWidth:0,breakAll:a==="breakAll"}:null,s=Pu.lastIndex=0,u;(u=Pu.exec(e))!=null;){var l=u.index;l>s&&Eu(r,e.substring(s,l),t,o),Eu(r,u[2],t,o,u[1]),s=Pu.lastIndex}s<e.length&&Eu(r,e.substring(s,e.length),t,o);var f=[],h=0,c=0,v=t.padding,d=a==="truncate",g=t.lineOverflow==="truncate",p={};function y(F,G,V){F.width=G,F.lineHeight=V,h+=V,c=Math.max(c,G)}t:for(var m=0;m<r.lines.length;m++){for(var _=r.lines[m],w=0,x=0,S=0;S<_.tokens.length;S++){var b=_.tokens[S],T=b.styleName&&t.rich[b.styleName]||{},C=b.textPadding=T.padding,D=C?C[1]+C[3]:0,A=b.font=T.font||t.font;b.contentHeight=oh(A);var P=K(T.height,b.contentHeight);if(b.innerHeight=P,C&&(P+=C[0]+C[2]),b.height=P,b.lineHeight=qi(T.lineHeight,t.lineHeight,P),b.align=T&&T.align||t.align,b.verticalAlign=T&&T.verticalAlign||"middle",g&&i!=null&&h+b.lineHeight>i){var L=r.lines.length;S>0?(_.tokens=_.tokens.slice(0,S),y(_,x,w),r.lines=r.lines.slice(0,m+1)):r.lines=r.lines.slice(0,m),r.isTruncated=r.isTruncated||r.lines.length<L;break t}var I=T.width,E=I==null||I==="auto";if(typeof I=="string"&&I.charAt(I.length-1)==="%")b.percentWidth=I,f.push(b),b.contentWidth=ae(b.text,A);else{if(E){var O=T.backgroundColor,N=O&&O.image;N&&(N=TC(N),Bs(N)&&(b.width=Math.max(b.width,N.width*P/N.height)))}var R=d&&n!=null?n-x:null;R!=null&&R<b.width?!E||R<D?(b.text="",b.width=b.contentWidth=0):(CC(p,b.text,R-D,A,t.ellipsis,{minChar:t.truncateMinChar}),b.text=p.text,r.isTruncated=r.isTruncated||p.isTruncated,b.width=b.contentWidth=ae(b.text,A)):b.contentWidth=ae(b.text,A)}b.width+=D,x+=b.width,T&&(w=Math.max(w,b.lineHeight))}y(_,x,w)}r.outerWidth=r.width=K(n,c),r.outerHeight=r.height=K(i,h),r.contentHeight=h,r.contentWidth=c,v&&(r.outerWidth+=v[1]+v[3],r.outerHeight+=v[0]+v[2]);for(var m=0;m<f.length;m++){var b=f[m],k=b.percentWidth;b.width=parseInt(k,10)/100*r.width}return r}function Eu(e,t,r,n,i){var a=t==="",o=i&&r.rich[i]||{},s=e.lines,u=o.font||r.font,l=!1,f,h;if(n){var c=o.padding,v=c?c[1]+c[3]:0;if(o.width!=null&&o.width!=="auto"){var d=kr(o.width,n.width)+v;s.length>0&&d+n.accumWidth>n.width&&(f=t.split(`
`),l=!0),n.accumWidth=d}else{var g=$y(t,u,n.width,n.breakAll,n.accumWidth);n.accumWidth=g.accumWidth+v,h=g.linesWidths,f=g.lines}}else f=t.split(`
`);for(var p=0;p<f.length;p++){var y=f[p],m=new AC;if(m.styleName=i,m.text=y,m.isLineHolder=!y&&!a,typeof o.width=="number"?m.width=o.width:m.width=h?h[p]:ae(y,u),!p&&!l){var _=(s[s.length-1]||(s[0]=new dc)).tokens,w=_.length;w===1&&_[0].isLineHolder?_[0]=m:(y||!w||a)&&_.push(m)}else s.push(new dc([m]))}}function PC(e){var t=e.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var EC=Rr(",&?/;] ".split(""),function(e,t){return e[t]=!0,e},{});function RC(e){return PC(e)?!!EC[e]:!0}function $y(e,t,r,n,i){for(var a=[],o=[],s="",u="",l=0,f=0,h=0;h<e.length;h++){var c=e.charAt(h);if(c===`
`){u&&(s+=u,f+=l),a.push(s),o.push(f),s="",u="",l=0,f=0;continue}var v=ae(c,t),d=n?!1:!RC(c);if(a.length?f+v>r:i+f+v>r){f?(s||u)&&(d?(s||(s=u,u="",l=0,f=l),a.push(s),o.push(f-l),u+=c,l+=v,s="",f=l):(u&&(s+=u,u="",l=0),a.push(s),o.push(f),s=c,f=v)):d?(a.push(u),o.push(l),u=c,l=v):(a.push(c),o.push(v));continue}f+=v,d?(u+=c,l+=v):(u&&(s+=u,u="",l=0),s+=c)}return!a.length&&!s&&(s=e,u="",l=0),u&&(s+=u),s&&(a.push(s),o.push(f)),a.length===1&&(f+=i),{accumWidth:f,lines:a,linesWidths:o}}var rf="__zr_style_"+Math.round(Math.random()*10),gn={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},Ns={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};gn[rf]=!0;var pc=["z","z2","invisible"],OC=["invisible"],vi=function(e){H(t,e);function t(r){return e.call(this,r)||this}return t.prototype._init=function(r){for(var n=gt(r),i=0;i<n.length;i++){var a=n[i];a==="style"?this.useStyle(r[a]):e.prototype.attrKV.call(this,a,r[a])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(r,n,i,a){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&kC(this,r,n)||o&&!o[0]&&!o[3])return!1;if(i&&this.__clipPaths){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(a&&this.parent)for(var u=this.parent;u;){if(u.ignore)return!1;u=u.parent}return!0},t.prototype.contain=function(r,n){return this.rectContain(r,n)},t.prototype.traverse=function(r,n){r.call(n,this)},t.prototype.rectContain=function(r,n){var i=this.transformCoordToLocal(r,n),a=this.getBoundingRect();return a.contain(i[0],i[1])},t.prototype.getPaintRect=function(){var r=this._paintRect;if(!this._paintRect||this.__dirty){var n=this.transform,i=this.getBoundingRect(),a=this.style,o=a.shadowBlur||0,s=a.shadowOffsetX||0,u=a.shadowOffsetY||0;r=this._paintRect||(this._paintRect=new it(0,0,0,0)),n?it.applyTransform(r,i,n):r.copy(i),(o||s||u)&&(r.width+=o*2+Math.abs(s),r.height+=o*2+Math.abs(u),r.x=Math.min(r.x,r.x+s-o),r.y=Math.min(r.y,r.y+u-o));var l=this.dirtyRectTolerance;r.isZero()||(r.x=Math.floor(r.x-l),r.y=Math.floor(r.y-l),r.width=Math.ceil(r.width+1+l*2),r.height=Math.ceil(r.height+1+l*2))}return r},t.prototype.setPrevPaintRect=function(r){r?(this._prevPaintRect=this._prevPaintRect||new it(0,0,0,0),this._prevPaintRect.copy(r)):this._prevPaintRect=null},t.prototype.getPrevPaintRect=function(){return this._prevPaintRect},t.prototype.animateStyle=function(r){return this.animate("style",r)},t.prototype.updateDuringAnimation=function(r){r==="style"?this.dirtyStyle():this.markRedraw()},t.prototype.attrKV=function(r,n){r!=="style"?e.prototype.attrKV.call(this,r,n):this.style?this.setStyle(n):this.useStyle(n)},t.prototype.setStyle=function(r,n){return typeof r=="string"?this.style[r]=n:B(this.style,r),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(r){r||this.markRedraw(),this.__dirty|=zi,this._rect&&(this._rect=null)},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&zi)},t.prototype.styleUpdated=function(){this.__dirty&=~zi},t.prototype.createStyle=function(r){return Es(gn,r)},t.prototype.useStyle=function(r){r[rf]||(r=this.createStyle(r)),this.__inHover?this.__hoverStyle=r:this.style=r,this.dirtyStyle()},t.prototype.isStyleObject=function(r){return r[rf]},t.prototype._innerSaveToNormal=function(r){e.prototype._innerSaveToNormal.call(this,r);var n=this._normalState;r.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(r,n,pc)},t.prototype._applyStateObj=function(r,n,i,a,o,s){e.prototype._applyStateObj.call(this,r,n,i,a,o,s);var u=!(n&&a),l;if(n&&n.style?o?a?l=n.style:(l=this._mergeStyle(this.createStyle(),i.style),this._mergeStyle(l,n.style)):(l=this._mergeStyle(this.createStyle(),a?this.style:i.style),this._mergeStyle(l,n.style)):u&&(l=i.style),l)if(o){var f=this.style;if(this.style=this.createStyle(u?{}:f),u)for(var h=gt(f),c=0;c<h.length;c++){var v=h[c];v in l&&(l[v]=l[v],this.style[v]=f[v])}for(var d=gt(l),c=0;c<d.length;c++){var v=d[c];this.style[v]=this.style[v]}this._transitionState(r,{style:l},s,this.getAnimationStyleProps())}else this.useStyle(l);for(var g=this.__inHover?OC:pc,c=0;c<g.length;c++){var v=g[c];n&&n[v]!=null?this[v]=n[v]:u&&i[v]!=null&&(this[v]=i[v])}},t.prototype._mergeStates=function(r){for(var n=e.prototype._mergeStates.call(this,r),i,a=0;a<r.length;a++){var o=r[a];o.style&&(i=i||{},this._mergeStyle(i,o.style))}return i&&(n.style=i),n},t.prototype._mergeStyle=function(r,n){return B(r,n),r},t.prototype.getAnimationStyleProps=function(){return Ns},t.initDefaultProps=function(){var r=t.prototype;r.type="displayable",r.invisible=!1,r.z=0,r.z2=0,r.zlevel=0,r.culling=!1,r.cursor="pointer",r.rectHover=!1,r.incremental=!1,r._rect=null,r.dirty Line truncated
`,`
`,`
`];function ba(e,t){return t.type=e,t}function yf(e){return e.type==="section"}function p0(e){return yf(e)?tL:eL}function g0(e){if(yf(e)){var t=0,r=e.blocks.length,n=r>1||r>0&&!e.noHeader;return M(e.blocks,function(i){var a=g0(i);a>=t&&(t=a+ +(n&&(!a||yf(i)&&!i.noHeader)))}),t}return 0}function tL(e,t,r,n){var i=t.noHeader,a=rL(g0(t)),o=[],s=t.blocks||[];vr(!s||z(s)),s=s||[];var u=e.orderMode;if(t.sortBlocks&&u){s=s.slice();var l={valueAsc:"asc",valueDesc:"desc"};if(cr(l,u)){var f=new u0(l[u],null);s.sort(function(g,p){return f.evaluate(g.sortParam,p.sortParam)})}else u==="seriesDesc"&&s.reverse()}M(s,function(g,p){var y=t.valueFormatter,m=p0(g)(y?B(B({},e),{valueFormatter:y}):e,g,p>0?a.html:0,n);m!=null&&o.push(m)});var h=e.renderMode==="richText"?o.join(a.richText):mf(n,o.join(""),i?r:a.html);if(i)return h;var c=df(t.header,"ordinal",e.useUTC),v=d0(n,e.renderMode).nameStyle,d=c0(n);return e.renderMode==="richText"?y0(e,c,v)+a.richText+h:mf(n,'<div style="'+v+";"+d+';">'+Kt(c)+"</div>"+h,r)}function eL(e,t,r,n){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,u=t.name,l=e.useUTC,f=t.valueFormatter||e.valueFormatter||function(w){return w=z(w)?w:[w],$(w,function(x,S){return df(x,z(v)?v[S]:v,l)})};if(!(a&&o)){var h=s?"":e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||"#333",i),c=a?"":df(u,"ordinal",l),v=t.valueType,d=o?[]:f(t.value,t.dataIndex),g=!s||!a,p=!s&&a,y=d0(n,i),m=y.nameStyle,_=y.valueStyle;return i==="richText"?(s?"":h)+(a?"":y0(e,c,m))+(o?"":aL(e,d,g,p,_)):mf(n,(s?"":h)+(a?"":nL(c,!s,m))+(o?"":iL(d,g,p,_)),r)}}function Cd(e,t,r,n,i,a){if(e){var o=p0(e),s={useUTC:i,renderMode:r,orderMode:n,markupStyleCreator:t,valueFormatter:e.valueFormatter};return o(s,e,0,a)}}function rL(e){return{html:QA[e],richText:JA[e]}}function mf(e,t,r){var n='<div style="clear:both"></div>',i="margin: "+r+"px 0 0",a=c0(e);return'<div style="'+i+";"+a+';">'+t+n+"</div>"}function nL(e,t,r){var n=t?"margin-left:2px":"";return'<span style="'+r+";"+n+'">'+Kt(e)+"</span>"}function iL(e,t,r,n){var i=r?"10px":"20px",a=t?"float:right;margin-left:"+i:"";return e=z(e)?e:[e],'<span style="'+a+";"+n+'">'+$(e,function(o){return Kt(o)}).join("&nbsp;&nbsp;")+"</span>"}function y0(e,t,r){return e.markupStyleCreator.wrapRichTextStyle(t,r)}function aL(e,t,r,n,i){var a=[i],o=n?10:20;return r&&a.push({padding:[0,0,0,o],align:"right"}),e.markupStyleCreator.wrapRichTextStyle(z(t)?t.join(" "):t,a)}function oL(e,t){var r=e.getData().getItemVisual(t,"style"),n=r[e.visualDrawType];return _a(n)}function m0(e,t){var r=e.get("padding");return r??(t==="richText"?[8,10]:10)}var rl=function(){function e(){this.richTextStyles={},this._nextStyleNameId=Ey()}return e.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(t,r,n){var i=n==="richText"?this._generateStyleName():null,a=YD({color:r,type:t,renderMode:n,markerId:i});return W(a)?a:(this.richTextStyles[i]=a.style,a.content)},e.prototype.wrapRichTextStyle=function(t,r){var n={};z(r)?M(r,function(a){return B(n,a)}):B(n,r);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+t+"}"},e}();function sL(e){var t=e.series,r=e.dataIndex,n=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll("defaultedTooltip"),o=a.length,s=t.getRawValue(r),u=z(s),l=oL(t,r),f,h,c,v;if(o>1||u&&!o){var d=uL(s,t,r,a,l);f=d.inlineValues,h=d.inlineValueTypes,c=d.blocks,v=d.inlineValues[0]}else if(o){var g=i.getDimensionInfo(a[0]);v=f=oi(i,r,a[0]),h=g.type}else v=f=u?s[0]:s;var p=By(t),y=p&&t.name||"",m=i.getName(r),_=n?y:m;return ba("section",{header:y,noHeader:n||!p,sortParam:v,blocks:[ba("nameValue",{markerType:"item",markerColor:l,name:_,noName:!$e(_),value:f,valueType:h,dataIndex:r})].concat(c||[])})}function uL(e,t,r,n,i){var a=t.getData(),o=Rr(e,function(h,c,v){var d=a.getDimensionInfo(v);return h=h||d&&d.tooltip!==!1&&d.displayName!=null},!1),s=[],u=[],l=[];n.length?M(n,function(h){f(oi(a,r,h),h)}):M(e,f);function f(h,c){var v=a.getDimensionInfo(c);!v||v.otherDims.tooltip===!1||(o?l.push(ba("nameValue",{markerType:"subItem",markerColor:i,name:v.displayName,value:h,valueType:v.type})):(s.push(h),u.push(v.type)))}return{inlineValues:s,inlineValueTypes:u,blocks:l}}var xr=mt();function fo(e,t){return e.getName(t)||e.getId(t)}var $o="__universalTransitionEnabled",je=function(e){H(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r._selectedDataIndicesMap={},r}return t.prototype.init=function(r,n,i){this.seriesIndex=this.componentIndex,this.dataTask=ia({count:fL,reset:hL}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(r,i);var a=xr(this).sourceManager=new v0(this);a.prepareSource();var o=this.getInitialData(r,i);Dd(o,this),this.dataTask.context.data=o,xr(this).dataBeforeProcessed=o,Md(this),this._initSelectedMapFromData(o)},t.prototype.mergeDefaultAndTheme=function(r,n){var i=wa(this),a=i?Ih(r):{},o=this.subType;st.hasClass(o)&&(o+="Series"),ft(r,n.getTheme().get(this.subType)),ft(r, Line truncated
`:"<br/>",y=h.join(p);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(r,l)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,l):this._showTooltipContent(s,y,l,Math.random()+"",o[0],o[1],v,null,c)})},t.prototype._showSeriesItemTooltip=function(r,n,i){var a=this._ecModel,o=ut(n),s=o.seriesIndex,u=a.getSeriesByIndex(s),l=o.dataModel||u,f=o.dataIndex,h=o.dataType,c=l.getData(h),v=this._renderMode,d=r.positionDefault,g=Fi([c.getItemModel(f),l,u&&(u.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),p=g.get("trigger");if(!(p!=null&&p!=="item")){var y=l.getDataParams(f,h),m=new rl;y.marker=m.makeTooltipMarker("item",_a(y.color),v);var _=_d(l.formatTooltip(f,!1,h)),w=g.get("order"),x=g.get("valueFormatter"),S=_.frag,b=S?Cd(x?B({valueFormatter:x},S):S,m,v,w,a.get("useUTC"),g.get("textStyle")):_.text,T="item_"+l.name+"_"+f;this._showOrMove(g,function(){this._showTooltipContent(g,b,y,T,r.offsetX,r.offsetY,r.position,r.target,m)}),i({type:"showTip",dataIndexInside:f,dataIndex:c.getRawIndex(f),seriesIndex:s,from:this.uid})}},t.prototype._showComponentItemTooltip=function(r,n,i){var a=this._renderMode==="html",o=ut(n),s=o.tooltipConfig,u=s.option||{},l=u.encodeHTMLContent;if(W(u)){var f=u;u={content:f,formatter:f},l=!0}l&&a&&u.content&&(u=nt(u),u.content=Kt(u.content));var h=[u],c=this._ecModel.getComponent(o.componentMainType,o.componentIndex);c&&h.push(c),h.push({formatter:u.content});var v=r.positionDefault,d=Fi(h,this._tooltipModel,v?{position:v}:null),g=d.get("content"),p=Math.random()+"",y=new rl;this._showOrMove(d,function(){var m=nt(d.get("formatterParams")||{});this._showTooltipContent(d,g,m,p,r.offsetX,r.offsetY,r.position,n,y)}),i({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(r,n,i,a,o,s,u,l,f){if(this._ticket="",!(!r.get("showContent")||!r.get("show"))){var h=this._tooltipContent;h.setEnterable(r.get("enterable"));var c=r.get("formatter");u=u||r.get("position");var v=n,d=this._getNearestPoint([o,s],i,r.get("trigger"),r.get("borderColor")),g=d.color;if(c)if(W(c)){var p=r.ecModel.get("useUTC"),y=z(i)?i[0]:i,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;v=c,m&&(v=Us(y.axisValue,v,p)),v=Vm(v,i,!0)}else if(J(c)){var _=_t(function(w,x){w===this._ticket&&(h.setContent(x,f,r,g,u),this._updatePosition(r,u,o,s,h,i,l))},this);this._ticket=a,v=c(i,a,_)}else v=c;h.setContent(v,f,r,g,u),h.show(r,g),this._updatePosition(r,u,o,s,h,i,l)}},t.prototype._getNearestPoint=function(r,n,i,a){if(i==="axis"||z(n))return{color:a||(this._renderMode==="html"?"#fff":"none")};if(!z(n))return{color:a||n.color||n.borderColor}},t.prototype._updatePosition=function(r,n,i,a,o,s,u){var l=this._api.getWidth(),f=this._api.getHeight();n=n||r.get("position");var h=o.getSize(),c=r.get("align"),v=r.get("verticalAlign"),d=u&&u.getBoundingRect().clone();if(u&&d.applyTransform(u.transform),J(n)&&(n=n([i,a],s,o.el,d,{viewSize:[l,f],contentSize:h.slice()})),z(n))i=pt(n[0],l),a=pt(n[1],f);else if(X(n)){var g=n;g.width=h[0],g.height=h[1];var p=js(g,{width:l,height:f});i=p.x,a=p.y,c=null,v=null}else if(W(n)&&u){var y=dR(n,d,h,r.get("borderWidth"));i=y[0],a=y[1]}else{var y=vR(i,a,o,l,f,c?null:20,v?null:20);i=y[0],a=y[1]}if(c&&(i-=ng(c)?h[0]/2:c==="right"?h[0]:0),v&&(a-=ng(v)?h[1]/2:v==="bottom"?h[1]:0),Q_(r)){var y=cR(i,a,o,l,f);i=y[0],a=y[1]}o.moveTo(i,a)},t.prototype._updateContentNotChangedOnAxis=function(r,n){var i=this._lastDataByCoordSys,a=this._cbParamsList,o=!!i&&i.length===r.length;return o&&M(i,function(s,u){var l=s.dataByAxis||[],f=r[u]||{},h=f.dataByAxis||[];o=o&&l.length===h.length,o&&M(l,function(c,v){var d=h[v]||{},g=c.seriesDataIndices||[],p=d.seriesDataIndices||[];o=o&&c.value===d.value&&c.axisType===d.axisType&&c.axisId===d.axisId&&g.length===p.length,o&&M(g,function(y,m){var _=p[m];o=o&&y.seriesIndex===_.seriesIndex&&y.dataIndex===_.dataIndex}),a&&M(c.seriesDataIndices,function(y){var m=y.seriesIndex,_=n[m],w=a[m];_&&w&&w.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=r,this._cbParamsList=n,!!o},t.prototype._hide=function(r){this._lastDataByCoordSys=null,r({type:"hideTip",from:this.uid})},t.prototype.dispose=function(r,n){q.node||!n.getDom()||(wf(this,"_updatePosition"),this._tooltipContent.dispose(),Nf("itemTooltip",n))},t.type="tooltip",t}(Re);function Fi(e,t,r){var n=t.ecModel,i;r?(i=new Ct(r,n,n),i=new Ct(t.option,i,n)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof Ct&&(o=o.get("tooltip",!0)),W(o)&&(o={formatter:o}),o&&(i=new Ct(o,i,n)))}return i}function rg(e,t){return e.dispatchAction||_t(t.dispatchAction,t)}function vR(e,t,r,n,i,a,o){var s=r.getSize(),u=s[0],l=s[1];return a!=null&&(e+u+a+2>n?e-=u+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function cR(e,t,r,n,i){var a=r.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,n)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function dR(e,t,r,n){var i=r[0],a=r[1],o=Math.ceil(Math.SQRT2*n)+8,s=0,u=0,l=t.width,f=t.height;switch(e){case"inside":s=t.x+l/2-i/2,u=t.y+f/2-a/2;break;case"top":s=t Line truncated
@@ -0,0 +1 @@
(function(){"use strict";let p=!1,c={};const f=new Map,P=t=>.006+.06*Math.max(0,t-73),d=()=>{for(let t=1;t<=90;t++)f.set(t,P(t))},m=new Map,g=t=>.006+.06*Math.max(0,t-63),u=()=>{for(let t=1;t<=80;t++)m.set(t,g(t))},D=(()=>{let t=Date.now();return()=>{Date.now()-t>(p?500:10)&&(postMessage({type:"data",data:c}),c={},t=Date.now(),p=!0)}})(),y=({charter_count:t,weapon_count:i,isCharacterGuaranteed:s,isWeaponGuaranteed:n,isDiscount:l,consecutiveOffRate:a,cushioned_count:e,pinkBall_count:r})=>{let o=0,M=0;const h=()=>{o++,e=0,s=!1};for(l&&(r=Math.floor(r/.9));r>0;)r--,e++,o<t||M>=i?Math.random()<f.get(e)&&(e=0,s?h():a===3?(h(),a-=2):Math.random()<.5?(h(),a--):(s=!0,a++)):Math.random()<m.get(e)&&(n||Math.random()<.375?(M++,n=!1):n=!0);const w=(o<<8)+M;c[w]=(c[w]||0)+1,D()};addEventListener("message",t=>{const{charter_count:i,weapon_count:s,isCharacterGuaranteed:n,isWeaponGuaranteed:l,isDiscount:a,consecutiveOffRate:e,cushioned_count:r,pinkBall_count:o}=t.data;for(d(),u(),postMessage({type:"init"});;)y({charter_count:i,weapon_count:s,isCharacterGuaranteed:n,isWeaponGuaranteed:l,isDiscount:a,consecutiveOffRate:e,cushioned_count:r,pinkBall_count:o})})})();
@@ -0,0 +1,14 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="./vite.svg" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Vite + Solid + TS</title>
<script type="module" crossorigin src="./assets/index-DP99bbYD.js"></script>
<link rel="stylesheet" crossorigin href="./assets/index-0yRbVyE4.css">
</head>
<body>
<div id="root"></div>␍
</body>
</html>