Greasy Fork is available in English.
Bilibili 自定义首页
当前为
// ==UserScript==
// @name Bilibili-Gate
// @namespace https://magicdawn.fun
// @version 0.34.12
// @author magicdawn
// @description Bilibili 自定义首页
// @license MIT
// @icon https://www.bilibili.com/favicon.ico
// @homepageURL http://greasyfork.icu/zh-CN/scripts/443530-bilibili-gate
// @supportURL https://github.com/magicdawn/Bilibili-Gate/issues
// @match https://www.bilibili.com/
// @match https://www.bilibili.com/?*
// @match https://www.bilibili.com/index.html
// @match https://www.bilibili.com/index.html?*
// @match https://www.bilibili.com/video/*
// @match https://www.bilibili.com/list/watchlater?*
// @match https://www.bilibili.com/bangumi/play/*
// @match https://space.bilibili.com/*
// @match https://search.bilibili.com/*
// @require https://registry.npmmirror.com/axios/0.30.2/files/dist/axios.min.js
// @require https://registry.npmmirror.com/ua-parser-js/1.0.41/files/dist/ua-parser.min.js
// @require https://registry.npmmirror.com/localforage/1.10.0/files/dist/localforage.min.js
// @require https://registry.npmmirror.com/pinyin-match/1.2.10/files/dist/main.js
// @require https://registry.npmmirror.com/spark-md5/3.0.2/files/spark-md5.min.js
// @tag bilibili
// @connect app.bilibili.com
// @grant GM.deleteValue
// @grant GM.getValue
// @grant GM.listValues
// @grant GM.openInTab
// @grant GM.registerMenuCommand
// @grant GM.setClipboard
// @grant GM.setValue
// @grant GM.xmlHttpRequest
// @grant GM_addStyle
// @grant GM_addValueChangeListener
// @grant GM_download
// @grant GM_info
// @grant unsafeWindow
// @run-at document-body
// ==/UserScript==
(async function (zX, pM, sparkMd5, a5, kX) {
'use strict';
const d=new Set;const LX = async e=>{d.has(e)||(d.add(e),(t=>{typeof GM_addStyle=="function"?GM_addStyle(t):(document.head||document.documentElement).appendChild(document.createElement("style")).append(t);})(e));};
LX(' ._cls--gate-video-grid--divider_h4766_1 .ant-divider-inner-text{display:inline-flex;align-items:center;min-height:30px}._cls--gate-video-grid--divider_h4766_1 .ant-divider-inner-text a{color:var(--ant-color-link)}._cls--gate-video-grid--divider_h4766_1 .ant-divider-inner-text a:hover{color:var(--ant-color-primary)}._cls--gate-video-card--context-menu--root_h4766_13 .ant-dropdown-menu{--ant-dropdown-padding-block: 3px}._cls--gate-video-card--context-menu--root_h4766_13 .ant-dropdown-menu:has(:nth-child(12)){--ant-dropdown-padding-block: 2px}._video-grid_ucv12_1{display:grid;position:relative;width:100%;grid-gap:20px 12px;--bilibili-gate--video-card--border-radius: 15px}._grid-template-columns-using-var-col_ucv12_9{--col: 4;grid-template-columns:repeat(var(--col),minmax(0,1fr))}._grid-template-columns-using-card-min-width_ucv12_14{--card-min-width: 330px;grid-template-columns:repeat(auto-fill,minmax(var(--card-min-width),1fr))}._video-grid-addon-center-empty_ucv12_19:before{content:"";grid-column:3/-3;grid-row:1/span 9999;grid-auto-flow:dense}._video-grid-bili-feed4_ucv12_26{grid-gap:20px 20px}@media(max-width:1399px){._video-grid-bili-feed4_ucv12_26{--col: 4}}@media(min-width:1400px){._video-grid-bili-feed4_ucv12_26{--col: 5}}._video-grid-bili-feed4_ucv12_26 .ant-divider-horizontal.ant-divider-with-text{margin-bottom:-15px;margin-top:-15px}._video-grid-bili-feed4_ucv12_26 .ant-divider-horizontal.ant-divider-with-text:first-of-type{margin-top:0}._video-grid-custom_ucv12_47{--row-gap: clamp(20px, 1.4vw, 40px);column-gap:clamp(15px,1.1cqw,20px);row-gap:0}._video-grid-custom_ucv12_47 .bili-video-card{margin-bottom:var(--row-gap)}._video-grid-custom_ucv12_47 .ant-divider-horizontal.ant-divider-with-text{margin-top:calc(10px - var(--row-gap));margin-bottom:5px}._video-grid-custom_ucv12_47 .ant-divider-horizontal.ant-divider-with-text:first-of-type{margin-top:0}._narrow-mode_ucv12_63{--col: 2 !important}*,:before,:after{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / .5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }::backdrop{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / .5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: }.icon-only-round-button{width:32px;height:32px;display:flex;align-items:center;justify-content:center;border-radius:50%;padding:0}.inline-icon-only-round-button{width:32px;height:32px;display:inline-flex;align-items:center;justify-content:center;border-radius:50%;padding:0}.flex-center{display:flex;align-items:center;justify-content:center}.flex-v-center{display:flex;align-items:center}.inline-flex-center{display:inline-flex;align-items:center;justify-content:center}.\\[refresh\\:scroll\\]{refresh:scroll}.pointer-events-auto{pointer-events:auto}.\\[\\&_svg\\]\\:pointer-events-none svg,.pointer-events-none{pointer-events:none}.visible{visibility:visible}.invisible{visibility:hidden}.absolute{position:absolute}.fixed{position:fixed}.position-relative,.relative{position:relative}.sticky{position:sticky}.static{position:static}.inset-0{inset:0}.inset-x-0{left:0;right:0}.bottom--6px{bottom:-6px}.bottom-0{bottom:0}.left--2px{left:-2px}.left--30px{left:-30px}.left-0{left:0}.left-2,.left-8px{left:8px}.left-50\\%{left:50%}.right--30px{right:-30px}.right-\\[calc\\(8px\\+28px\\+5px\\)\\]{right:41px}.right-0{right:0}.right-10px{right:10px}.right-8px{right:8px}.top-\\[-0\\.5px\\]{top:-.5px}.top-\\[-1px\\]{top:-1px}.top-0{top:0}.top-0\\.5px{top:.5px}.top-10px{top:10px}.top-4px{top:4px}.top-50\\%{top:50%}.top-8px{top:8px}.hover\\:left-0:hover{left:0}.hover\\:right-0:hover{right:0}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-clamp:2}.line-clamp-3{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:3;line-clamp:3}.isolate{isolation:isolate}.z-10000{z-index:10000}.z-10004{z-index:10004}.z-10005{z-index:10005}.z-1001{z-index:1001}.z-11000{z-index:11000}.z-11200{z-index:11200}.z-11300{z-index:11300}.z-2{z-index:2}.z-3{z-index:3}.z-4{z-index:4}.z-5{z-index:5}.z-6{z-index:6}.z-90000{z-index:90000}.z-9999{z-index:9999}.grid{display:grid}.col-span-full,.grid-col-span-full{grid-column:1/-1}.grid-cols-\\[250px_1fr\\]{grid-template-columns:250px 1fr}.grid-cols-\\[repeat\\(2\\,max-content\\)_1fr\\]{grid-template-columns:repeat(2,max-content) 1fr}.grid-cols-\\[repeat\\(2\\,max-content\\)\\]{grid-template-columns:repeat(2,max-content)}.grid-cols-\\[repeat\\(auto-fill\\,minmax\\(225px\\,1fr\\)\\)\\]{grid-template-columns:repeat(auto-fill,minmax(225px,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.m10{margin:40px}.m12{margin:48px}.m13{margin:52px}.m14{margin:56px}.m15{margin:60px}.m16{margin:64px}.m16\\.52{margin:66.08px}.m160{margin:640px}.m19{margin:76px}.m19\\.833{margin:79.332px}.m239\\.82{margin:959.28px}.m24{margin:96px}.m27\\.952{margin:111.808px}.m29\\.756{margin:119.024px}.m3{margin:12px}.m33{margin:132px}.m434\\.8{margin:1739.2px}.m5{margin:20px}.m9{margin:36px}.\\[\\&_\\[role\\=\\"separator\\"\\]\\]\\:mx-0 [role=separator],.mx-0{margin-left:0;margin-right:0}.\\[\\&_\\[role\\=\\"separator\\"\\]\\]\\:my-2px [role=separator],.my-2px{margin-top:2px;margin-bottom:2px}.\\[\\&\\.ant-divider-horizontal\\.ant-divider-with-text\\]\\:my-5px.ant-divider-horizontal.ant-divider-with-text,.my-5px{margin-top:5px;margin-bottom:5px}.\\[\\&\\.ant-empty-normal\\]\\:my-1.ant-empty-normal,.my-1{margin-top:4px;margin-bottom:4px}.mx-1,.mx-4px{margin-left:4px;margin-right:4px}.mx-2px{margin-left:2px;margin-right:2px}.mx-5px{margin-left:5px;margin-right:5px}.mx-auto{margin-left:auto;margin-right:auto}.my-0{margin-top:0;margin-bottom:0}.my-7px{margin-top:7px;margin-bottom:7px}.my-auto{margin-top:auto;margin-bottom:auto}.\\[\\&_svg\\]\\:mr-5px svg,.mr-5px{margin-right:5px}.\\[\\&_svg\\]\\:mt--1px svg,.mt--1px{margin-top:-1px}.mb-0{margin-bottom:0}.mb-10px{margin-bottom:10px}.mb-20px{margin-bottom:20px}.mb-2px{margin-bottom:2px}.mb-40px{margin-bottom:40px}.mb-5px{margin-bottom:5px}.mb-8px{margin-bottom:8px}.ml-0{margin-left:0}.ml-1,.ml-4px{margin-left:4px}.ml-1\\.5,.ml-6px{margin-left:6px}.ml-10px{margin-left:10px}.ml-12px,.ml-3{margin-left:12px}.ml-15px{margin-left:15px}.ml-1px{margin-left:1px}.ml-20px,.ml-xl{margin-left:20px}.ml-25px{margin-left:25px}.ml-2px{margin-left:2px}.ml-30px{margin-left:30px}.ml-4{margin-left:16px}.ml-5px{margin-left:5px}.ml-8px{margin-left:8px}.ml-auto{margin-left:auto}.mr-0{margin-right:0}.mr-0\\!{margin-right:0!important}.mr-1,.mr-4px{margin-right:4px}.mr-10px{margin-right:10px}.mr-24px{margin-right:24px}.mr-2px{margin-right:2px}.mr-auto{margin-right:auto}.ms{margin-inline-start:16px}.mt--2px{margin-top:-2px}.mt-0{margin-top:0}.mt-0\\.5em{margin-top:.5em}.mt-1,.mt-4px{margin-top:4px}.mt-10px{margin-top:10px}.mt-15px{margin-top:15px}.mt-2,.mt-8px{margin-top:8px}.mt-20px{margin-top:20px}.mt-2px{margin-top:2px}.mt-3px{margin-top:3px}.mt-6px{margin-top:6px}.first\\:ml-0:first-child{margin-left:0}.first\\:mt-0:first-child,.first\\:mt-0px:first-child{margin-top:0}.box-content{box-sizing:content-box}.inline{display:inline}.block{display:block}.inline-block{display:inline-block}.contents{display:contents}.\\[\\&\\>\\.ant-checkbox-label\\]\\:hidden>.ant-checkbox-label,.hidden{display:none}.aspect-1{aspect-ratio:1}.aspect-16\\/9{aspect-ratio:16/9}.aspect-ratio-10\\/16{aspect-ratio:10/16}.\\[\\&_svg\\]\\:size-16px svg,.size-16px{width:16px;height:16px}.ant-spin .ant-spin-dot.\\[\\.ant-spin_\\.ant-spin-dot\\&\\]\\:size-25px,.size-25px{width:25px;height:25px}.size-1\\.1em{width:1.1em;height:1.1em}.size-1\\.3em{width:1.3em;height:1.3em}.size-12px{width:12px;height:12px}.size-13px{width:13px;height:13px}.size-14px{width:14px;height:14px}.size-15px{width:15px;height:15px}.size-17px{width:17px;height:17px}.size-18px{width:18px;height:18px}.size-1em{width:1em;height:1em}.size-2\\.5{width:10px;height:10px}.size-20px{width:20px;height:20px}.size-24px{width:24px;height:24px}.size-26px{width:26px;height:26px}.size-28px{width:28px;height:28px}.size-30px{width:30px;height:30px}.size-32px{width:32px;height:32px}.size-40px{width:40px;height:40px}.size-full{width:100%;height:100%}.h-\\[calc\\(100vh-30px\\)\\]{height:calc(100vh - 30px)}.h-0{height:0}.h-100\\%,.h-full{height:100%}.h-100vh{height:100vh}.h-14px{height:14px}.h-16px{height:16px}.h-19px{height:19px}.h-22px{height:22px}.h-24px{height:24px}.h-2px{height:2px}.h-34px{height:34px}.h-35px{height:35px}.h-3px{height:3px}.h-auto{height:auto}.h-fit{height:fit-content}.max-h-\\[calc\\(90vh-50px\\)\\]{max-height:calc(90vh - 50px)}.max-h-\\[max\\(362px\\,calc\\(90vh-50px-56px-15px\\)\\)\\]{max-height:max(362px,calc(90vh - 121px))}.max-h-130px{max-height:130px}.max-h-250px{max-height:250px}.max-h-50vh{max-height:50vh}.max-h-full{max-height:100%}.max-h-unset{max-height:unset}.max-w-\\[calc\\(100\\%-6px\\)\\]{max-width:calc(100% - 6px)}.max-w-130px{max-width:130px}.max-w-250px{max-width:250px}.max-w-288px{max-width:288px}.max-w-300px{max-width:300px}.max-w-350px{max-width:350px}.max-w-450px{max-width:450px}.min-h-100px{min-height:100px}.min-h-100vh{min-height:100vh}.min-h-25px{min-height:25px}.min-h-362px{min-height:362px}.min-h-40px{min-height:40px}.min-w-130px{min-width:130px}.min-w-180px{min-width:180px}.min-w-200px{min-width:200px}.min-w-24px{min-width:24px}.min-w-300px{min-width:300px}.min-w-32px{min-width:32px}.min-w-60px{min-width:60px}.min-w-95px{min-width:95px}.w-\\[calc\\(100vw-30px\\)\\]{width:calc(100vw - 30px)}.w-\\[max-content\\],.w-max{width:max-content}.w-0{width:0}.w-100\\%,.w-full{width:100%}.w-114px{width:114px}.w-130px{width:130px}.w-150px{width:150px}.w-160px{width:160px}.w-16px{width:16px}.w-215px{width:215px}.w-34px{width:34px}.w-500px{width:500px}.w-50px{width:50px}.w-55px{width:55px}.w-720px{width:720px}.w-740px{width:740px}.w-75px{width:75px}.flex{display:flex}.\\[\\&_\\.ant-checkbox-label\\]\\:inline-flex .ant-checkbox-label,.\\[\\&_\\.ant-radio-label\\]\\:inline-flex .ant-radio-label,.\\[\\&_\\.ant-radio-wrapper\\]\\:inline-flex .ant-radio-wrapper,.inline-flex{display:inline-flex}.flex-1{flex:1 1 0%}.flex-none{flex:none}.flex-shrink-0{flex-shrink:0}.flex-shrink-1{flex-shrink:1}.flex-grow-1{flex-grow:1}.flex-basis-100\\%{flex-basis:100%}.flex-row{flex-direction:row}.flex-row-reverse{flex-direction:row-reverse}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.translate-x--50\\%{--un-translate-x:-50%;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.translate-y--50\\%{--un-translate-y:-50%;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.translate-y-100\\%{--un-translate-y:100%;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.rotate-0{--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-rotate:0deg;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.rotate-180{--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-rotate:180deg;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.hover\\:rotate-90:hover{--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-rotate:90deg;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.rotate-z-0{--un-rotate:0;--un-rotate-z:0deg;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.rotate-z-180deg{--un-rotate:0;--un-rotate-z:180deg;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.hover\\:scale-105\\%:hover{--un-scale-x:1.05;--un-scale-y:1.05;transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}.transform{transform:translate(var(--un-translate-x)) translateY(var(--un-translate-y)) translateZ(var(--un-translate-z)) rotate(var(--un-rotate)) rotateX(var(--un-rotate-x)) rotateY(var(--un-rotate-y)) rotate(var(--un-rotate-z)) skew(var(--un-skew-x)) skewY(var(--un-skew-y)) scaleX(var(--un-scale-x)) scaleY(var(--un-scale-y)) scaleZ(var(--un-scale-z))}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-\\[edit\\]{cursor:edit}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.\\[\\&\\:disabled\\]\\:cursor-wait:disabled{cursor:wait}.cursor-text{cursor:text}.cursor-move{cursor:move}.cursor-grab{cursor:grab}.\\[\\&_\\.ant-checkbox-label\\]\\:select-none .ant-checkbox-label,.\\[\\&_svg\\]\\:select-none svg,.select-none{-webkit-user-select:none;user-select:none}.resize{resize:both}.list-circle{list-style-type:circle}.list-disc{list-style-type:disc}.content-start{align-content:flex-start}.items-start{align-items:flex-start}.\\[\\&_\\.ant-checkbox-label\\]\\:items-center .ant-checkbox-label,.\\[\\&_\\.ant-radio-label\\]\\:items-center .ant-radio-label,.\\[\\&_\\.ant-radio-wrapper\\]\\:items-center .ant-radio-wrapper,.items-center{align-items:center}.self-start{align-self:flex-start}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.justify-left{justify-content:left}.justify-right{justify-content:right}.gap-0{gap:0}.gap-10px{gap:10px}.gap-15px{gap:15px}.gap-1px{gap:1px}.gap-4px{gap:4px}.gap-x-1,.gap-x-4px{column-gap:4px}.gap-x-10px{column-gap:10px}.gap-x-12px{column-gap:12px}.gap-x-15px{column-gap:15px}.gap-x-2,.gap-x-8px{column-gap:8px}.gap-x-20px{column-gap:20px}.gap-x-25px{column-gap:25px}.gap-x-2px{column-gap:2px}.gap-x-40px{column-gap:40px}.gap-x-50px{column-gap:50px}.gap-x-5px{column-gap:5px}.gap-x-6px{column-gap:6px}.gap-y-0{row-gap:0}.gap-y-0\\.5em{row-gap:.5em}.gap-y-1,.gap-y-4px{row-gap:4px}.gap-y-10px{row-gap:10px}.gap-y-15px{row-gap:15px}.gap-y-2,.gap-y-8px{row-gap:8px}.gap-y-2px{row-gap:2px}.gap-y-3px{row-gap:3px}.gap-y-5px{row-gap:5px}.gap-y-6px{row-gap:6px}.overflow-hidden{overflow:hidden}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.text-ellipsis{text-overflow:ellipsis}.whitespace-normal{white-space:normal}.whitespace-nowrap{white-space:nowrap}.whitespace-pre-wrap{white-space:pre-wrap}.break-normal{overflow-wrap:normal;word-break:normal}.break-all{word-break:break-all}.b-1px,.border{border-width:1px}.b-2px{border-width:2px}.b-5px{border-width:5px}.b-b-1px{border-bottom-width:1px}.b-t-1px{border-top-width:1px}.border-b-0{border-bottom-width:0px}.b-\\#444{--un-border-opacity:1;border-color:rgb(68 68 68 / var(--un-border-opacity))}.b-gate-bg-lv-2{border-color:var(--bilibili-gate--bg--lv2)}.b-gate-border,.bilibili-gate-using-dark .dark\\:b-gate-border{border-color:var(--bilibili-gate--border-color)}.b-gate-primary{border-color:var(--bilibili-gate--primary-color)}.b-transparent{border-color:transparent}.b-white\\/20\\%{border-color:#fff3}.b-white\\/33\\%{border-color:#ffffff54}.border-white\\/40{border-color:#fff6}.bilibili-gate-using-light .light\\:hover\\:b-gate-primary:hover,.hover\\:b-gate-primary:hover{border-color:var(--bilibili-gate--primary-color)}.b-b-gate-bg-lv1{border-bottom-color:var(--bilibili-gate--bg--lv1)}.b-b-transparent{border-bottom-color:transparent}.b-t-\\$bilibili-gate--separator-color{border-top-color:var(--bilibili-gate--separator-color)}.rounded,.rounded-4px{border-radius:4px}.rounded-10px{border-radius:10px}.rounded-15px{border-radius:15px}.rounded-18px{border-radius:18px}.rounded-20px{border-radius:20px}.rounded-2px{border-radius:2px}.rounded-5px{border-radius:5px}.rounded-6px,.rounded-md{border-radius:6px}.rounded-8px,.rounded-lg{border-radius:8px}.rounded-9px{border-radius:9px}.rounded-full{border-radius:9999px}.rounded-b-none{border-bottom-left-radius:0;border-bottom-right-radius:0}.rounded-t-6px{border-top-left-radius:6px;border-top-right-radius:6px}.rounded-t-gate-video-card{border-top-left-radius:var(--bilibili-gate--video-card--border-radius);border-top-right-radius:var(--bilibili-gate--video-card--border-radius)}.b-solid{border-style:solid}.border-none{border-style:none}.b-b-solid{border-bottom-style:solid}.b-t-solid{border-top-style:solid}.\\[\\&\\:has\\(svg\\.peeking\\)\\]\\:bg-transparent:has(svg.peeking),.bg-transparent{background-color:transparent}.bg-\\[rgb\\(33_33_33_\\/_0\\.7\\)\\]{--un-bg-opacity:.7;background-color:rgb(33 33 33 / var(--un-bg-opacity))}.bg-\\$brand_blue{background-color:var(--brand_blue)}.bg-\\$brand_pink{background-color:var(--brand_pink)}.bg-black\\/10{background-color:#0000001a}.bg-black\\/50{background-color:#00000080}.bg-black\\/65{background-color:#000000a6}.bg-black\\/90\\%{background-color:#000000e6}.bg-gate-bg{background-color:var(--bilibili-gate--bg)}.bg-gate-bg-lv1{background-color:var(--bilibili-gate--bg--lv1)}.bg-gate-primary{background-color:var(--bilibili-gate--primary-color)}.bg-gate-primary-lv-3{background-color:var(--bilibili-gate--primary-color--lv3)}.bg-gate-primary\\!{background-color:var(--bilibili-gate--primary-color)!important}.bg-white\\/14\\%{background-color:#ffffff24}.bg-white\\/50\\%{background-color:#ffffff80}.hover\\:bg-gate-bg-lv-3:hover{background-color:var(--bilibili-gate--bg--lv3)}.hover\\:bg-gate-bg-lv1:hover{background-color:var(--bilibili-gate--bg--lv1)}.hover\\:bg-gate-primary-lv1\\!:hover{background-color:var(--bilibili-gate--primary-color--lv1)!important}.hover\\:bg-gate-primary:hover{background-color:var(--bilibili-gate--primary-color)}.hover\\:bg-white\\/40\\%:hover{background-color:#fff6}.\\[\\&_g\\]\\:fill-inherit g{fill:inherit}.\\[\\&_path\\]\\:fill-gate-primary path,.fill-gate-primary{fill:var(--bilibili-gate--primary-color)}.fill-none{fill:none}.\\[\\&_\\.circle\\]\\:stroke-current .circle{stroke:currentColor}.object-cover{object-fit:cover}.object-contain{object-fit:contain}.p-10px{padding:10px}.p-15px{padding:15px}.p-1px{padding:1px}.p-20px{padding:20px}.p-2px{padding:2px}.p-4px{padding:4px}.p-8px{padding:8px}.\\[\\&_\\.ant-radio-button-wrapper\\]\\:px-10px .ant-radio-button-wrapper{padding-left:10px;padding-right:10px}.\\[\\&\\.ant-empty-normal\\]\\:py-5px.ant-empty-normal,.py-5px{padding-top:5px;padding-bottom:5px}.p-x-2,.px-8px{padding-left:8px;padding-right:8px}.p-y-1,.py-4px{padding-top:4px;padding-bottom:4px}.px,.px-4{padding-left:16px;padding-right:16px}.px-0{padding-left:0;padding-right:0}.px-12px,.px-3{padding-left:12px;padding-right:12px}.px-15px{padding-left:15px;padding-right:15px}.px-24px{padding-left:24px;padding-right:24px}.px-2px{padding-left:2px;padding-right:2px}.px-4px{padding-left:4px;padding-right:4px}.px-5px{padding-left:5px;padding-right:5px}.px-6px{padding-left:6px;padding-right:6px}.py-0{padding-top:0;padding-bottom:0}.py-10px{padding-top:10px;padding-bottom:10px}.py-12px{padding-top:12px;padding-bottom:12px}.py-2,.py-8px{padding-top:8px;padding-bottom:8px}.py-2px{padding-top:2px;padding-bottom:2px}.py-30px{padding-top:30px;padding-bottom:30px}.py-3px{padding-top:3px;padding-bottom:3px}.py-6px{padding-top:6px;padding-bottom:6px}.\\!\\[\\&_\\.ant-radio-label\\]\\:pl-4px .ant-radio-label{padding-left:4px!important}.pb-15px{padding-bottom:15px}.pb-2px{padding-bottom:2px}.pb1257{padding-bottom:5028px}.pl-10px{padding-left:10px}.pl-16px{padding-left:16px}.pl-20px{padding-left:20px}.pl-2px{padding-left:2px}.pl-4px{padding-left:4px}.pl-6px{padding-left:6px}.pr-0{padding-right:0}.pr-10px{padding-right:10px}.pr-12px{padding-right:12px}.pr-15px{padding-right:15px}.pr-18px{padding-right:18px}.pr-6px{padding-right:6px}.ps{padding-inline-start:16px}.pt-0{padding-top:0}.pt-15px{padding-top:15px}.pt-5px{padding-top:5px}.text-center{text-align:center}.align-top{vertical-align:top}.\\[\\&\\.ant-divider-horizontal\\.ant-divider-with-text\\]\\:text-14px.ant-divider-horizontal.ant-divider-with-text,.text-14px,.text-size-14px{font-size:14px}.text-\\[1\\.5rem\\]{font-size:24px}.text-1\\.25em{font-size:1.25em}.text-1\\.2em{font-size:1.2em}.text-1\\.5em,.text-size-1\\.5em{font-size:1.5em}.text-12px,.text-size-12px{font-size:12px}.text-13px,.text-size-13px{font-size:13px}.text-15px{font-size:15px}.text-15px\\!{font-size:15px!important}.text-16px,.text-size-16px{font-size:16px}.font-size-20px,.text-20px,.text-size-20px{font-size:20px}.text-2em{font-size:2em}.text-size-0{font-size:0}.text-size-1\\.3em{font-size:1.3em}.text-size-120\\%{font-size:120%}.color-gate-primary,.text-gate-primary{color:var(--bilibili-gate--primary-color)}.text-gate-text{color:var(--bilibili-gate--text-color)}.text-red{--un-text-opacity:1;color:rgb(248 113 113 / var(--un-text-opacity))}.color-white,.text-white{--un-text-opacity:1;color:rgb(255 255 255 / var(--un-text-opacity))}.text-yellow-400{--un-text-opacity:1;color:rgb(250 204 21 / var(--un-text-opacity))}.hover\\:color-gate-primary:hover{color:var(--bilibili-gate--primary-color)}.color-inherit{color:inherit}.font-600{font-weight:600}.font-700{font-weight:700}.\\[\\&_\\.ant-btn-icon\\]\\:line-height-0 .ant-btn-icon,.line-height-\\[0\\]{line-height:0}.line-height-\\[1\\.2\\]{line-height:1.2}.line-height-\\[1\\]{line-height:1}.line-height-\\[unset\\],.line-height-unset{line-height:unset}.line-height-1\\.5{line-height:6px}.line-height-14px{line-height:14px}.line-height-17px{line-height:17px}.line-height-18px{line-height:18px}.line-height-normal{line-height:1.5}.line-height-snug{line-height:1.375}.line-height-tight{line-height:1.25}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.italic{font-style:italic}.tab{-moz-tab-size:4;-o-tab-size:4;tab-size:4}.\\[\\&\\:has\\(svg\\.peeking\\)\\]\\:opacity-10:has(svg.peeking){opacity:.1}.shadow{--un-shadow:var(--un-shadow-inset) 0 1px 3px 0 var(--un-shadow-color, rgb(0 0 0 / .1)),var(--un-shadow-inset) 0 1px 2px -1px var(--un-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--un-ring-offset-shadow),var(--un-ring-shadow),var(--un-shadow)}.\\[\\&\\.ant-btn\\:not\\(\\:disabled\\)\\:focus-visible\\]\\:outline-0.ant-btn:not(:disabled):focus-visible{outline-width:0px}.outline-none\\!{outline:2px solid transparent!important;outline-offset:2px!important}.ring-1px{--un-ring-width:1px;--un-ring-offset-shadow:var(--un-ring-inset) 0 0 0 var(--un-ring-offset-width) var(--un-ring-offset-color);--un-ring-shadow:var(--un-ring-inset) 0 0 0 calc(var(--un-ring-width) + var(--un-ring-offset-width)) var(--un-ring-color);box-shadow:var(--un-ring-offset-shadow),var(--un-ring-shadow),var(--un-shadow)}.ring-gate-border{--un-ring-color:var(--bilibili-gate--border-color) }.ring-gate-primary{--un-ring-color:var(--bilibili-gate--primary-color) }.backdrop-blur-10px{--un-backdrop-blur:blur(10px);-webkit-backdrop-filter:var(--un-backdrop-blur) var(--un-backdrop-brightness) var(--un-backdrop-contrast) var(--un-backdrop-grayscale) var(--un-backdrop-hue-rotate) var(--un-backdrop-invert) var(--un-backdrop-opacity) var(--un-backdrop-saturate) var(--un-backdrop-sepia);backdrop-filter:var(--un-backdrop-blur) var(--un-backdrop-brightness) var(--un-backdrop-contrast) var(--un-backdrop-grayscale) var(--un-backdrop-hue-rotate) var(--un-backdrop-invert) var(--un-backdrop-opacity) var(--un-backdrop-saturate) var(--un-backdrop-sepia)}.filter{filter:var(--un-blur) var(--un-brightness) var(--un-contrast) var(--un-drop-shadow) var(--un-grayscale) var(--un-hue-rotate) var(--un-invert) var(--un-saturate) var(--un-sepia)}.transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-200{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.2s}.transition-300{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-duration-150{transition-duration:.15s}.transition-duration-300{transition-duration:.3s}.ease,.ease-in-out,.transition-ease,.transition-ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}.transition-property-\\[border-color\\]{transition-property:border-color}.transition-property-all{transition-property:all}.transition-property-right\\,left{transition-property:right,left}.transition-property-transform{transition-property:transform}.\\@container,.\\@container-inline-size{container-type:inline-size}@media(min-width:1280px){.xl\\:gap-x-8px{column-gap:8px}}.bilibili-gate-root .bili-video-card__skeleton--cover,.bilibili-gate-root .bili-video-card__skeleton--text,.bilibili-gate-root .bili-video-card__skeleton--light,.bilibili-gate-root .bili-video-card__skeleton--avatar{background:linear-gradient(135deg,#0000000f 25%,#00000026 37%,#0000000f 63%)}.bilibili-gate-root .bili-video-card__skeleton--text.tiny{margin-top:4px;width:15%}html.bilibili-gate-using-dark .bilibili-gate-root .bili-video-card__skeleton--cover,html.bilibili-gate-using-dark .bilibili-gate-root .bili-video-card__skeleton--text,html.bilibili-gate-using-dark .bilibili-gate-root .bili-video-card__skeleton--light,html.bilibili-gate-using-dark .bilibili-gate-root .bili-video-card__skeleton--avatar{background-color:#444}._skeleton-active_wlycr_12 .bili-video-card__skeleton--cover,._skeleton-active_wlycr_12 .bili-video-card__skeleton--text,._skeleton-active_wlycr_12 .bili-video-card__skeleton--light,._skeleton-active_wlycr_12 .bili-video-card__skeleton--avatar{background-size:400% 100%;animation-name:_ant-skeleton-loading_wlycr_1;animation-duration:2s;animation-timing-function:ease;animation-iteration-count:infinite}@keyframes _ant-skeleton-loading_wlycr_1{0%{background-position:100% 50%}80%,to{background-position:0 50%}} ');
function FX(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in e)){const i=Object.getOwnPropertyDescriptor(r,o);i&&Object.defineProperty(e,o,i.get?i:{enumerable:true,get:()=>r[o]});}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const HX='@charset "UTF-8";:root{--bilibili-gate--font: "Alibaba PuHuiTi 3.0", "PingFang SC", "HarmonyOS_Regular", "Helvetica Neue", "Microsoft YaHei", sans-serif}:root{--bilibili-gate--primary-color--lv1: oklch(from var(--bilibili-gate--primary-color) calc(l - .04) c h/alpha);--bilibili-gate--primary-color--lv2: oklch(from var(--bilibili-gate--primary-color) calc(l - .08) c h/alpha);--bilibili-gate--primary-color--lv3: oklch(from var(--bilibili-gate--primary-color) calc(l - .12) c h/alpha);--bilibili-gate--border-color: oklch(from var(--bilibili-gate--bg) calc(l - .05) c h/alpha);--bilibili-gate--bg--lv1: oklch(from var(--bilibili-gate--bg) calc(l - .04) c h/alpha);--bilibili-gate--bg--lv2: oklch(from var(--bilibili-gate--bg) calc(l - .08) c h/alpha);--bilibili-gate--bg--lv3: oklch(from var(--bilibili-gate--bg) calc(l - .12) c h/alpha)}:root.bilibili-gate-using-dark{--bilibili-gate--border-color: oklch(from var(--bilibili-gate--bg) calc(l + .07) c h/alpha);--bilibili-gate--bg--lv1: oklch(from var(--bilibili-gate--bg) calc(l + .03) c h/alpha);--bilibili-gate--bg--lv2: oklch(from var(--bilibili-gate--bg) calc(l + .08) c h/alpha);--bilibili-gate--bg--lv3: oklch(from var(--bilibili-gate--bg) calc(l + .12) c h/alpha)}.bilibili-gate-root{font-family:var(--custom-font-family--options--font-family, var(--bilibili-gate--font))!important;font-size:14px;--back-top-right: 24px}.bilibili-gate-root button,.bilibili-gate-root dd,.bilibili-gate-root dl,.bilibili-gate-root ol,.bilibili-gate-root ul{font-size:inherit}.bilibili-gate-root li{list-style:unset}.bilibili-gate-root .bili-video-card .bili-video-card__info--tit:hover,.bilibili-gate-root .bili-video-card a:not(.disable-hover):hover{color:var(--bilibili-gate--primary-color)!important}.bilibili-gate-root .ant-btn{font-size:13px}.bilibili-gate-root img:-moz-loading{visibility:hidden}@media(max-width:1440px){.bilibili-gate-root{--back-top-right: 16px}}body .ant-tooltip a{color:#1677ff;transition:color .3s}body .ant-tooltip a:visited{color:#1677ff}body .ant-tooltip a:hover{color:#69b1ff}body .ant-tooltip a:active{color:#0958d9}body button:where(.ant-switch):focus,body button:where(.ant-switch):active{background-color:#00000040;outline:unset}body .ant-btn.ant-btn-variant-solid:focus,body .ant-btn.ant-btn-variant-solid:active{color:var(--ant-button-primary-color);background:var(--ant-color-primary)}';LX(HX);const VX="_cls--gate-video-grid--divider_h4766_1",jX="_cls--gate-video-card--context-menu--root_h4766_13",gM="_video-grid_ucv12_1",IB="_grid-template-columns-using-var-col_ucv12_9",OB="_grid-template-columns-using-card-min-width_ucv12_14",DB="_video-grid-addon-center-empty_ucv12_19",_B="_video-grid-bili-feed4_ucv12_26",BB="_video-grid-custom_ucv12_47",LB="_narrow-mode_ucv12_63",UX={videoGrid:gM,gridTemplateColumnsUsingVarCol:IB,gridTemplateColumnsUsingCardMinWidth:OB,videoGridAddonCenterEmpty:DB,videoGridBiliFeed4:_B,videoGridCustom:BB,narrowMode:LB},s5=Object.freeze(Object.defineProperty({__proto__:null,default:UX,gridTemplateColumnsUsingCardMinWidth:OB,gridTemplateColumnsUsingVarCol:IB,narrowMode:LB,videoGrid:gM,videoGridAddonCenterEmpty:DB,videoGridBiliFeed4:_B,videoGridCustom:BB},Symbol.toStringTag,{value:"Module"}));function WX(e,t){const n={};for(let r=0;r<e.length;r++){const o=e[r],i=t(o,r,e);n[i]=(n[i]??0)+1;}return n}function g0(e,t){const n=new Set(t);return e.filter(r=>!n.has(r))}function GX(e,t){const n={};for(let r=0;r<e.length;r++){const o=e[r],i=t(o,r,e);Object.hasOwn(n,i)||(n[i]=[]),n[i].push(o);}return n}function qX(e,t,n){return e<t?n==="asc"?-1:1:e>t?n==="asc"?1:-1:0}function xs(e,t,n){return e.slice().sort((r,o)=>{const i=n.length;for(let a=0;a<t.length;a++){const l=i>a?n[a]:n[i-1],u=t[a],d=typeof u=="function",m=d?u(r):r[u],p=d?u(o):o[u],g=qX(m,p,l);if(g!==0)return g}return 0})}function KX(e,t){if(t==null&&(t=e,e=0),e>=t)throw new Error("Invalid input: The maximum value must be greater than the minimum value.");return Math.random()*(t-e)+e}function YX(e,t){return Math.floor(KX(e,t))}function Si(e){const t=e.slice();for(let n=t.length-1;n>=1;n--){const r=Math.floor(Math.random()*(n+1));[t[n],t[r]]=[t[r],t[n]];}return t}function zB(e){return typeof e=="symbol"||e instanceof Symbol}function XX(e){return zB(e)?NaN:Number(e)}function QX(e){return e?(e=XX(e),e===1/0||e===-1/0?(e<0?-1:1)*Number.MAX_VALUE:e===e?e:0):e===0?e:0}function ZX(e){const t=QX(e),n=t%1;return n?t-n:t}function ky(e){return [...new Set(e)]}function Kl(e,t){const n=new Map;for(let r=0;r<e.length;r++){const o=e[r],i=t(o,r,e);n.has(i)||n.set(i,o);}return Array.from(n.values())}let JX=class extends Error{constructor(t="The operation was aborted"){super(t),this.name="AbortError";}};function eQ(e,t,{signal:n,edges:r}={}){let o,i=null;const a=r!=null&&r.includes("leading"),l=r==null||r.includes("trailing"),u=()=>{i!==null&&(e.apply(o,i),o=void 0,i=null);},d=()=>{l&&u(),b();};let m=null;const p=()=>{m!=null&&clearTimeout(m),m=setTimeout(()=>{m=null,d();},t);},g=()=>{m!==null&&(clearTimeout(m),m=null);},b=()=>{g(),o=void 0,i=null;},y=()=>{u();},S=function(...C){if(n?.aborted)return;o=this,i=C;const w=m==null;p(),a&&w&&u();};return S.schedule=p,S.cancel=b,S.flush=y,n?.addEventListener("abort",b,{once:true}),S}function kB(e){return e}function tQ(e,t={}){const{cache:n=new Map,getCacheKey:r}=t,o=function(i){const a=r?r(i):i;if(n.has(a))return n.get(a);const l=e.call(this,i);return n.set(a,l),l};return o.cache=n,o}function FB(){}function xf(e){let t=false,n;return function(...r){return t||(t=true,n=e(...r)),n}}function gn(e,{signal:t}={}){return new Promise((n,r)=>{const o=()=>{r(new JX);},i=()=>{clearTimeout(a),o();};if(t?.aborted)return o();const a=setTimeout(()=>{t?.removeEventListener("abort",i),n();},e);t?.addEventListener("abort",i,{once:true});})}function Yl(e,t,{signal:n,edges:r=["leading","trailing"]}={}){let o=null;const i=eQ(function(...l){o=Date.now(),e.apply(this,l);},t,{signal:n,edges:r}),a=function(...l){if(o==null&&(o=Date.now()),Date.now()-o>=t){o=Date.now(),e.apply(this,l),i.cancel(),i.schedule();return}i.apply(this,l);};return a.cancel=i.cancel,a.flush=i.flush,a}function HB(e,t,n=1){if(t==null&&(t=e,e=0),!Number.isInteger(n)||n===0)throw new Error("The step value must be a non-zero integer.");const r=Math.max(Math.ceil((t-e)/n),0),o=new Array(r);for(let i=0;i<r;i++)o[i]=e+i*n;return o}function VB(e){return e==null||typeof e!="object"&&typeof e!="function"}function jB(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function dx(e){if(VB(e))return e;if(Array.isArray(e)||jB(e)||e instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer)return e.slice(0);const t=Object.getPrototypeOf(e);if(t==null)return Object.assign(Object.create(t),e);const n=t.constructor;if(e instanceof Date||e instanceof Map||e instanceof Set)return new n(e);if(e instanceof RegExp){const r=new n(e);return r.lastIndex=e.lastIndex,r}if(e instanceof DataView)return new n(e.buffer.slice(0));if(e instanceof Error){let r;return e instanceof AggregateError?r=new n(e.errors,e.message,{cause:e.cause}):r=new n(e.message,{cause:e.cause}),r.stack=e.stack,Object.assign(r,e),r}if(typeof File<"u"&&e instanceof File)return new n([e],e.name,{type:e.type,lastModified:e.lastModified});if(typeof e=="object"){const r=Object.create(t);return Object.assign(r,e)}return e}function z$(e){return Object.getOwnPropertySymbols(e).filter(t=>Object.prototype.propertyIsEnumerable.call(e,t))}function k$(e){return e==null?e===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const UB="[object RegExp]",WB="[object String]",GB="[object Number]",qB="[object Boolean]",F$="[object Arguments]",KB="[object Symbol]",YB="[object Date]",XB="[object Map]",QB="[object Set]",ZB="[object Array]",nQ="[object Function]",JB="[object ArrayBuffer]",Pb="[object Object]",rQ="[object Error]",eL="[object DataView]",tL="[object Uint8Array]",nL="[object Uint8ClampedArray]",rL="[object Uint16Array]",oL="[object Uint32Array]",oQ="[object BigUint64Array]",iL="[object Int8Array]",aL="[object Int16Array]",sL="[object Int32Array]",iQ="[object BigInt64Array]",lL="[object Float32Array]",cL="[object Float64Array]";function Nd(e,t,n,r=new Map,o=void 0){const i=o?.(e,t,n,r);if(i!==void 0)return i;if(VB(e))return e;if(r.has(e))return r.get(e);if(Array.isArray(e)){const a=new Array(e.length);r.set(e,a);for(let l=0;l<e.length;l++)a[l]=Nd(e[l],l,n,r,o);return Object.hasOwn(e,"index")&&(a.index=e.index),Object.hasOwn(e,"input")&&(a.input=e.input),a}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){const a=new RegExp(e.source,e.flags);return a.lastIndex=e.lastIndex,a}if(e instanceof Map){const a=new Map;r.set(e,a);for(const[l,u]of e)a.set(l,Nd(u,l,n,r,o));return a}if(e instanceof Set){const a=new Set;r.set(e,a);for(const l of e)a.add(Nd(l,void 0,n,r,o));return a}if(typeof Buffer<"u"&&Buffer.isBuffer(e))return e.subarray();if(jB(e)){const a=new(Object.getPrototypeOf(e)).constructor(e.length);r.set(e,a);for(let l=0;l<e.length;l++)a[l]=Nd(e[l],l,n,r,o);return a}if(e instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&e instanceof SharedArrayBuffer)return e.slice(0);if(e instanceof DataView){const a=new DataView(e.buffer.slice(0),e.byteOffset,e.byteLength);return r.set(e,a),vl(a,e,n,r,o),a}if(typeof File<"u"&&e instanceof File){const a=new File([e],e.name,{type:e.type});return r.set(e,a),vl(a,e,n,r,o),a}if(typeof Blob<"u"&&e instanceof Blob){const a=new Blob([e],{type:e.type});return r.set(e,a),vl(a,e,n,r,o),a}if(e instanceof Error){const a=new e.constructor;return r.set(e,a),a.message=e.message,a.name=e.name,a.stack=e.stack,a.cause=e.cause,vl(a,e,n,r,o),a}if(e instanceof Boolean){const a=new Boolean(e.valueOf());return r.set(e,a),vl(a,e,n,r,o),a}if(e instanceof Number){const a=new Number(e.valueOf());return r.set(e,a),vl(a,e,n,r,o),a}if(e instanceof String){const a=new String(e.valueOf());return r.set(e,a),vl(a,e,n,r,o),a}if(typeof e=="object"&&aQ(e)){const a=Object.create(Object.getPrototypeOf(e));return r.set(e,a),vl(a,e,n,r,o),a}return e}function vl(e,t,n=e,r,o){const i=[...Object.keys(t),...z$(t)];for(let a=0;a<i.length;a++){const l=i[a],u=Object.getOwnPropertyDescriptor(e,l);(u==null||u.writable)&&(e[l]=Nd(t[l],l,n,r,o));}}function aQ(e){switch(k$(e)){case F$:case ZB:case JB:case eL:case qB:case YB:case lL:case cL:case iL:case aL:case sL:case XB:case GB:case Pb:case UB:case QB:case WB:case KB:case tL:case nL:case rL:case oL:return true;default:return false}}function ef(e){return Nd(e,void 0,e,new Map,void 0)}function tf(e){if(!e||typeof e!="object")return false;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype||Object.getPrototypeOf(t)===null?Object.prototype.toString.call(e)==="[object Object]":false}function Yh(e){return e==="__proto__"}function Ss(e,t,n){const r=Object.keys(t);for(let o=0;o<r.length;o++){const i=r[o];if(Yh(i))continue;const a=t[i],l=e[i],u=n(l,a,i,e,t);u!==void 0?e[i]=u:Array.isArray(a)?Array.isArray(l)?e[i]=Ss(l,a,n):e[i]=Ss([],a,n):tf(a)?tf(l)?e[i]=Ss(l,a,n):e[i]=Ss({},a,n):(l===void 0||a!==void 0)&&(e[i]=a);}return e}function uL(e,t){const n={...e};for(let r=0;r<t.length;r++){const o=t[r];delete n[o];}return n}function su(e,t){const n={};for(let r=0;r<t.length;r++){const o=t[r];Object.hasOwn(e,o)&&(n[o]=e[o]);}return n}const sQ=new RegExp("\\p{Lu}?\\p{Ll}+|[0-9]+|\\p{Lu}+(?!\\p{Ll})|\\p{Emoji_Presentation}|\\p{Extended_Pictographic}|\\p{L}+","gu");function lQ(e){return Array.from(e.match(sQ)??[])}function cQ(e,t){return Ss(dx(e),t,function n(r,o){if(Array.isArray(o))return Array.isArray(r)?Ss(dx(r),o,n):Ss([],o,n);if(tf(o))return tf(r)?Ss(dx(r),o,n):Ss({},o,n)})}function dL(e,t){return e===t||Number.isNaN(e)&&Number.isNaN(t)}function uQ(e,t,n){return ph(e,t,void 0,void 0,void 0,void 0,n)}function ph(e,t,n,r,o,i,a){const l=a(e,t,n,r,o,i);if(l!==void 0)return l;if(typeof e==typeof t)switch(typeof e){case "bigint":case "string":case "boolean":case "symbol":case "undefined":return e===t;case "number":return e===t||Object.is(e,t);case "function":return e===t;case "object":return Mh(e,t,i,a)}return Mh(e,t,i,a)}function Mh(e,t,n,r){if(Object.is(e,t))return true;let o=k$(e),i=k$(t);if(o===F$&&(o=Pb),i===F$&&(i=Pb),o!==i)return false;switch(o){case WB:return e.toString()===t.toString();case GB:{const u=e.valueOf(),d=t.valueOf();return dL(u,d)}case qB:case YB:case KB:return Object.is(e.valueOf(),t.valueOf());case UB:return e.source===t.source&&e.flags===t.flags;case nQ:return e===t}n=n??new Map;const a=n.get(e),l=n.get(t);if(a!=null&&l!=null)return a===t;n.set(e,t),n.set(t,e);try{switch(o){case XB:{if(e.size!==t.size)return !1;for(const[u,d]of e.entries())if(!t.has(u)||!ph(d,t.get(u),u,e,t,n,r))return !1;return !0}case QB:{if(e.size!==t.size)return !1;const u=Array.from(e.values()),d=Array.from(t.values());for(let m=0;m<u.length;m++){const p=u[m],g=d.findIndex(b=>ph(p,b,void 0,e,t,n,r));if(g===-1)return !1;d.splice(g,1);}return !0}case ZB:case tL:case nL:case rL:case oL:case oQ:case iL:case aL:case sL:case iQ:case lL:case cL:{if(typeof Buffer<"u"&&Buffer.isBuffer(e)!==Buffer.isBuffer(t)||e.length!==t.length)return !1;for(let u=0;u<e.length;u++)if(!ph(e[u],t[u],u,e,t,n,r))return !1;return !0}case JB:return e.byteLength!==t.byteLength?!1:Mh(new Uint8Array(e),new Uint8Array(t),n,r);case eL:return e.byteLength!==t.byteLength||e.byteOffset!==t.byteOffset?!1:Mh(new Uint8Array(e),new Uint8Array(t),n,r);case rQ:return e.name===t.name&&e.message===t.message;case Pb:{if(!(Mh(e.constructor,t.constructor,n,r)||tf(e)&&tf(t)))return !1;const d=[...Object.keys(e),...z$(e)],m=[...Object.keys(t),...z$(t)];if(d.length!==m.length)return !1;for(let p=0;p<d.length;p++){const g=d[p],b=e[g];if(!Object.hasOwn(t,g))return !1;const y=t[g];if(!ph(b,y,g,e,t,n,r))return !1}return !0}default:return !1}}finally{n.delete(e),n.delete(t);}}function fa(e,t){return uQ(e,t,FB)}function Ha(e){return e==null}function dQ(e){const t=lQ(e.trim());let n="";for(let r=0;r<t.length;r++){const o=t[r];n&&(n+=" "),n+=o[0].toUpperCase()+o.slice(1).toLowerCase();}return n}function wf(e){try{return [null,e()]}catch(t){return [t,null]}}async function Vp(e){try{return [null,await e()]}catch(t){return [t,null]}}function Ro(e,t){if(!e)throw typeof t=="string"?new Error(t):t}function fQ(e){switch(typeof e){case "number":case "symbol":return false;case "string":return e.includes(".")||e.includes("[")||e.includes("]")}}function vM(e){return typeof e=="string"||typeof e=="symbol"?e:Object.is(e?.valueOf?.(),-0)?"-0":String(e)}function fL(e){if(e==null)return "";if(typeof e=="string")return e;if(Array.isArray(e))return e.map(fL).join(",");const t=String(e);return t==="0"&&Object.is(Number(e),-0)?"-0":t}function mL(e){if(Array.isArray(e))return e.map(vM);if(typeof e=="symbol")return [e];e=fL(e);const t=[],n=e.length;if(n===0)return t;let r=0,o="",i="",a=false;for(e.charCodeAt(0)===46&&(t.push(""),r++);r<n;){const l=e[r];i?l==="\\"&&r+1<n?(r++,o+=e[r]):l===i?i="":o+=l:a?l==='"'||l==="'"?i=l:l==="]"?(a=false,t.push(o),o=""):o+=l:l==="["?(a=true,o&&(t.push(o),o="")):l==="."?o&&(t.push(o),o=""):o+=l,r++;}return o&&t.push(o),t}function To(e,t,n){if(e==null)return n;switch(typeof t){case "string":{if(Yh(t))return n;const r=e[t];return r===void 0?fQ(t)?To(e,mL(t),n):n:r}case "number":case "symbol":{typeof t=="number"&&(t=vM(t));const r=e[t];return r===void 0?n:r}default:{if(Array.isArray(t))return mQ(e,t,n);if(Object.is(t?.valueOf(),-0)?t="-0":t=String(t),Yh(t))return n;const r=e[t];return r===void 0?n:r}}}function mQ(e,t,n){if(t.length===0)return n;let r=e;for(let o=0;o<t.length;o++){if(r==null||Yh(t[o]))return n;r=r[t[o]];}return r===void 0?n:r}function l5(e){return e!==null&&(typeof e=="object"||typeof e=="function")}const hQ=/^(?:0|[1-9]\d*)$/;function pQ(e,t=Number.MAX_SAFE_INTEGER){switch(typeof e){case "number":return Number.isInteger(e)&&e>=0&&e<t;case "symbol":return false;case "string":return hQ.test(e)}}const gQ=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,vQ=/^\w*$/;function bQ(e,t){return Array.isArray(e)?false:typeof e=="number"||typeof e=="boolean"||e==null||zB(e)?true:typeof e=="string"&&(vQ.test(e)||!gQ.test(e))||t!=null&&Object.hasOwn(t,e)}const yQ=(e,t,n)=>{const r=e[t];(!(Object.hasOwn(e,t)&&dL(r,n))||n===void 0&&!(t in e))&&(e[t]=n);};function SQ(e,t,n,r){if(e==null&&!l5(e))return e;let o;bQ(t,e)?o=[t]:Array.isArray(t)?o=t:o=mL(t);const i=n(To(e,o));let a=e;for(let l=0;l<o.length&&a!=null;l++){const u=vM(o[l]);if(Yh(u))continue;let d;if(l===o.length-1)d=i;else {const m=a[u],p=r?.(m,u,e);d=p!==void 0?p:l5(m)?m:pQ(o[l+1])?[]:{};}yQ(a,u,d),a=a[u];}return e}function $f(e,t,n){return SQ(e,t,()=>n,()=>{})}function CQ(e,t){if(e=ZX(e),e<1||!Number.isSafeInteger(e))return [];const n=new Array(e);for(let r=0;r<e;r++)n[r]=typeof t=="function"?t(r):r;return n}const xQ=Symbol(),bM=Symbol(),gh="a",hL="f",c5="p",pL="c",gL="t",yM="h",Rh="w",SM="o",CM="k";let wQ=(e,t)=>new Proxy(e,t);const H$=Object.getPrototypeOf,V$=new WeakMap,vL=e=>e&&(V$.has(e)?V$.get(e):H$(e)===Object.prototype||H$(e)===Array.prototype),v0=e=>typeof e=="object"&&e!==null,$Q=e=>Object.values(Object.getOwnPropertyDescriptors(e)).some(t=>!t.configurable&&!t.writable),EQ=e=>{if(Array.isArray(e))return Array.from(e);const t=Object.getOwnPropertyDescriptors(e);return Object.values(t).forEach(n=>{n.configurable=true;}),Object.create(H$(e),t)},MQ=(e,t)=>{const n={[hL]:t};let r=false;const o=(l,u)=>{if(!r){let d=n[gh].get(e);if(d||(d={},n[gh].set(e,d)),l===Rh)d[Rh]=true;else {let m=d[l];m||(m=new Set,d[l]=m),m.add(u);}}},i=()=>{r=true,n[gh].delete(e);},a={get(l,u){return u===bM?e:(o(CM,u),bL(Reflect.get(l,u),n[gh],n[pL],n[gL]))},has(l,u){return u===xQ?(i(),true):(o(yM,u),Reflect.has(l,u))},getOwnPropertyDescriptor(l,u){return o(SM,u),Reflect.getOwnPropertyDescriptor(l,u)},ownKeys(l){return o(Rh),Reflect.ownKeys(l)}};return t&&(a.set=a.deleteProperty=()=>false),[a,n]},xM=e=>e[bM]||e,bL=(e,t,n,r)=>{if(!vL(e))return e;let o=r&&r.get(e);if(!o){const u=xM(e);$Q(u)?o=[u,EQ(u)]:o=[u],r?.set(e,o);}const[i,a]=o;let l=n&&n.get(i);return (!l||l[1][hL]!==!!a)&&(l=MQ(i,!!a),l[1][c5]=wQ(a||i,l[0]),n&&n.set(i,l)),l[1][gh]=t,l[1][pL]=n,l[1][gL]=r,l[1][c5]},RQ=(e,t)=>{const n=Reflect.ownKeys(e),r=Reflect.ownKeys(t);return n.length!==r.length||n.some((o,i)=>o!==r[i])},yL=(e,t,n,r,o=Object.is)=>{if(o(e,t))return false;if(!v0(e)||!v0(t))return true;const i=n.get(xM(e));if(!i)return true;if(r){if(r.get(e)===t)return false;r.set(e,t);}let a=null;for(const l of i[yM]||[])if(a=Reflect.has(e,l)!==Reflect.has(t,l),a)return a;if(i[Rh]===true){if(a=RQ(e,t),a)return a}else for(const l of i[SM]||[]){const u=!!Reflect.getOwnPropertyDescriptor(e,l),d=!!Reflect.getOwnPropertyDescriptor(t,l);if(a=u!==d,a)return a}for(const l of i[CM]||[])if(a=yL(e[l],t[l],n,r,o),a)return a;if(a===null)throw new Error("invalid used");return a},TQ=e=>vL(e)&&e[bM]||null,u5=(e,t=true)=>{V$.set(e,t);},AQ=(e,t,n)=>{const r=[],o=new WeakSet,i=(a,l)=>{var u,d,m;if(o.has(a))return;v0(a)&&o.add(a);const p=v0(a)&&t.get(xM(a));if(p){if((u=p[yM])===null||u===void 0||u.forEach(g=>{const b=`:has(${String(g)})`;r.push(l?[...l,b]:[b]);}),p[Rh]===true){const g=":ownKeys";r.push(l?[...l,g]:[g]);}else (d=p[SM])===null||d===void 0||d.forEach(g=>{const b=`:hasOwn(${String(g)})`;r.push(l?[...l,b]:[b]);});(m=p[CM])===null||m===void 0||m.forEach(g=>{"value"in(Object.getOwnPropertyDescriptor(a,g)||{})&&i(a[g],l?[...l,g]:[g]);});}else l&&r.push(l);};return i(e),r},b0={},wM=e=>typeof e=="object"&&e!==null,NQ=e=>wM(e)&&!jp.has(e)&&(Array.isArray(e)||!(Symbol.iterator in e))&&!(e instanceof WeakMap)&&!(e instanceof WeakSet)&&!(e instanceof Error)&&!(e instanceof Number)&&!(e instanceof Date)&&!(e instanceof String)&&!(e instanceof RegExp)&&!(e instanceof ArrayBuffer)&&!(e instanceof Promise),SL=(e,t)=>{const n=j$.get(e);if(n?.[0]===t)return n[1];const r=Array.isArray(e)?[]:Object.create(Object.getPrototypeOf(e));return u5(r,true),j$.set(e,[t,r]),Reflect.ownKeys(e).forEach(o=>{if(Object.getOwnPropertyDescriptor(r,o))return;const i=Reflect.get(e,o),{enumerable:a}=Reflect.getOwnPropertyDescriptor(e,o),l={value:i,enumerable:a,configurable:true};if(jp.has(i))u5(i,false);else if(As.has(i)){const[u,d]=As.get(i);l.value=SL(u,d());}Object.defineProperty(r,o,l);}),Object.preventExtensions(r)},PQ=(e,t,n,r)=>({deleteProperty(o,i){Reflect.get(o,i),n(i);const a=Reflect.deleteProperty(o,i);return a&&r(void 0),a},set(o,i,a,l){const u=!e()&&Reflect.has(o,i),d=Reflect.get(o,i,l);if(u&&(y0(d,a)||Xh.has(a)&&y0(d,Xh.get(a))))return true;n(i),wM(a)&&(a=TQ(a)||a);const m=!As.has(a)&&W$(a)?zn(a):a;return t(i,m),Reflect.set(o,i,m,l),r(void 0),true}}),As=new WeakMap,jp=new WeakSet,j$=new WeakMap,Ib=[1],Xh=new WeakMap;let y0=Object.is,U$=(e,t)=>new Proxy(e,t),W$=NQ,G$=SL,q$=PQ;function zn(e={}){if(!wM(e))throw new Error("object required");const t=Xh.get(e);if(t)return t;let n=Ib[0];const r=new Set,o=(C,w=++Ib[0])=>{n!==w&&(i=n=w,r.forEach($=>$(C,w)));};let i=n;const a=(C=Ib[0])=>(i!==C&&(i=C,u.forEach(([w])=>{const $=w[1](C);$>n&&(n=$);})),n),l=C=>(w,$)=>{let M;w&&(M=[...w],M[1]=[C,...M[1]]),o(M,$);},u=new Map,d=(C,w)=>{const $=!jp.has(w)&&As.get(w);if($){if((b0?"production":void 0)!=="production"&&u.has(C))throw new Error("prop listener already exists");if(r.size){const M=$[2](l(C));u.set(C,[$,M]);}else u.set(C,[$]);}},m=C=>{var w;const $=u.get(C);$&&(u.delete(C),(w=$[1])==null||w.call($));},p=C=>(r.add(C),r.size===1&&u.forEach(([$,M],T)=>{if((b0?"production":void 0)!=="production"&&M)throw new Error("remove already exists");const R=$[2](l(T));u.set(T,[$,R]);}),()=>{r.delete(C),r.size===0&&u.forEach(([$,M],T)=>{M&&(M(),u.set(T,[$]));});});let g=true;const b=q$(()=>g,d,m,o),y=U$(e,b);Xh.set(e,y);const S=[e,a,p];return As.set(y,S),Reflect.ownKeys(e).forEach(C=>{const w=Object.getOwnPropertyDescriptor(e,C);"value"in w&&w.writable&&(y[C]=e[C]);}),g=false,y}function d5(e){const t=As.get(e);return t?.[1]()}function Xa(e,t,n){const r=As.get(e);(b0?"production":void 0)!=="production"&&!r&&console.warn("Please use proxy object");let o;const i=[],a=r[2];let l=false;const d=a(m=>{if(m&&i.push(m),n){t(i.splice(0));return}o||(o=Promise.resolve().then(()=>{o=void 0,l&&t(i.splice(0));}));});return l=true,()=>{l=false,d();}}function Fr(e){const t=As.get(e);(b0?"production":void 0)!=="production"&&!t&&console.warn("Please use proxy object");const[n,r]=t;return G$(n,r())}function CL(e){return jp.add(e),e}function $M(){return {proxyStateMap:As,refSet:jp,snapCache:j$,versionHolder:Ib,proxyCache:Xh}}function IQ(e,t){switch(e){case "objectIs":y0=t(y0);break;case "newProxy":U$=t(U$);break;case "canProxy":W$=t(W$);break;case "createSnapshot":G$=t(G$);break;case "createHandler":q$=t(q$);break;default:throw new Error("unknown function")}}var qv=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Io(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function OQ(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var n=function r(){var o=false;try{o=this instanceof r;}catch{}return o?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype;}else n={};return Object.defineProperty(n,"__esModule",{value:true}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:true,get:function(){return e[r]}});}),n}var fx={exports:{}},Vt={};var f5;function DQ(){if(f5)return Vt;f5=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),g=Symbol.iterator;function b(D){return D===null||typeof D!="object"?null:(D=g&&D[g]||D["@@iterator"],typeof D=="function"?D:null)}var y={isMounted:function(){return false},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,C={};function w(D,L,K){this.props=D,this.context=L,this.refs=C,this.updater=K||y;}w.prototype.isReactComponent={},w.prototype.setState=function(D,L){if(typeof D!="object"&&typeof D!="function"&&D!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,D,L,"setState");},w.prototype.forceUpdate=function(D){this.updater.enqueueForceUpdate(this,D,"forceUpdate");};function $(){}$.prototype=w.prototype;function M(D,L,K){this.props=D,this.context=L,this.refs=C,this.updater=K||y;}var T=M.prototype=new $;T.constructor=M,S(T,w.prototype),T.isPureReactComponent=true;var R=Array.isArray;function I(){}var N={H:null,A:null,T:null,S:null},P=Object.prototype.hasOwnProperty;function O(D,L,K){var J=K.ref;return {$$typeof:e,type:D,key:L,ref:J!==void 0?J:null,props:K}}function _(D,L){return O(D.type,L,D.props)}function B(D){return typeof D=="object"&&D!==null&&D.$$typeof===e}function V(D){var L={"=":"=0",":":"=2"};return "$"+D.replace(/[=:]/g,function(K){return L[K]})}var U=/\/+/g;function G(D,L){return typeof D=="object"&&D!==null&&D.key!=null?V(""+D.key):L.toString(36)}function H(D){switch(D.status){case "fulfilled":return D.value;case "rejected":throw D.reason;default:switch(typeof D.status=="string"?D.then(I,I):(D.status="pending",D.then(function(L){D.status==="pending"&&(D.status="fulfilled",D.value=L);},function(L){D.status==="pending"&&(D.status="rejected",D.reason=L);})),D.status){case "fulfilled":return D.value;case "rejected":throw D.reason}}throw D}function z(D,L,K,J,ee){var te=typeof D;(te==="undefined"||te==="boolean")&&(D=null);var re=false;if(D===null)re=true;else switch(te){case "bigint":case "string":case "number":re=true;break;case "object":switch(D.$$typeof){case e:case t:re=true;break;case m:return re=D._init,z(re(D._payload),L,K,J,ee)}}if(re)return ee=ee(D),re=J===""?"."+G(D,0):J,R(ee)?(K="",re!=null&&(K=re.replace(U,"$&/")+"/"),z(ee,L,K,"",function(ne){return ne})):ee!=null&&(B(ee)&&(ee=_(ee,K+(ee.key==null||D&&D.key===ee.key?"":(""+ee.key).replace(U,"$&/")+"/")+re)),L.push(ee)),1;re=0;var ie=J===""?".":J+":";if(R(D))for(var de=0;de<D.length;de++)J=D[de],te=ie+G(J,de),re+=z(J,L,K,te,ee);else if(de=b(D),typeof de=="function")for(D=de.call(D),de=0;!(J=D.next()).done;)J=J.value,te=ie+G(J,de++),re+=z(J,L,K,te,ee);else if(te==="object"){if(typeof D.then=="function")return z(H(D),L,K,J,ee);throw L=String(D),Error("Objects are not valid as a React child (found: "+(L==="[object Object]"?"object with keys {"+Object.keys(D).join(", ")+"}":L)+"). If you meant to render a collection of children, use an array instead.")}return re}function j(D,L,K){if(D==null)return D;var J=[],ee=0;return z(D,J,"","",function(te){return L.call(K,te,ee++)}),J}function W(D){if(D._status===-1){var L=D._result;L=L(),L.then(function(K){(D._status===0||D._status===-1)&&(D._status=1,D._result=K);},function(K){(D._status===0||D._status===-1)&&(D._status=2,D._result=K);}),D._status===-1&&(D._status=0,D._result=L);}if(D._status===1)return D._result.default;throw D._result}var Y=typeof reportError=="function"?reportError:function(D){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var L=new window.ErrorEvent("error",{bubbles:true,cancelable:true,message:typeof D=="object"&&D!==null&&typeof D.message=="string"?String(D.message):String(D),error:D});if(!window.dispatchEvent(L))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",D);return}console.error(D);},Q={map:j,forEach:function(D,L,K){j(D,function(){L.apply(this,arguments);},K);},count:function(D){var L=0;return j(D,function(){L++;}),L},toArray:function(D){return j(D,function(L){return L})||[]},only:function(D){if(!B(D))throw Error("React.Children.only expected to receive a single React element child.");return D}};return Vt.Activity=p,Vt.Children=Q,Vt.Component=w,Vt.Fragment=n,Vt.Profiler=o,Vt.PureComponent=M,Vt.StrictMode=r,Vt.Suspense=u,Vt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=N,Vt.__COMPILER_RUNTIME={__proto__:null,c:function(D){return N.H.useMemoCache(D)}},Vt.cache=function(D){return function(){return D.apply(null,arguments)}},Vt.cacheSignal=function(){return null},Vt.cloneElement=function(D,L,K){if(D==null)throw Error("The argument must be a React element, but you passed "+D+".");var J=S({},D.props),ee=D.key;if(L!=null)for(te in L.key!==void 0&&(ee=""+L.key),L)!P.call(L,te)||te==="key"||te==="__self"||te==="__source"||te==="ref"&&L.ref===void 0||(J[te]=L[te]);var te=arguments.length-2;if(te===1)J.children=K;else if(1<te){for(var re=Array(te),ie=0;ie<te;ie++)re[ie]=arguments[ie+2];J.children=re;}return O(D.type,ee,J)},Vt.createContext=function(D){return D={$$typeof:a,_currentValue:D,_currentValue2:D,_threadCount:0,Provider:null,Consumer:null},D.Provider=D,D.Consumer={$$typeof:i,_context:D},D},Vt.createElement=function(D,L,K){var J,ee={},te=null;if(L!=null)for(J in L.key!==void 0&&(te=""+L.key),L)P.call(L,J)&&J!=="key"&&J!=="__self"&&J!=="__source"&&(ee[J]=L[J]);var re=arguments.length-2;if(re===1)ee.children=K;else if(1<re){for(var ie=Array(re),de=0;de<re;de++)ie[de]=arguments[de+2];ee.children=ie;}if(D&&D.defaultProps)for(J in re=D.defaultProps,re)ee[J]===void 0&&(ee[J]=re[J]);return O(D,te,ee)},Vt.createRef=function(){return {current:null}},Vt.forwardRef=function(D){return {$$typeof:l,render:D}},Vt.isValidElement=B,Vt.lazy=function(D){return {$$typeof:m,_payload:{_status:-1,_result:D},_init:W}},Vt.memo=function(D,L){return {$$typeof:d,type:D,compare:L===void 0?null:L}},Vt.startTransition=function(D){var L=N.T,K={};N.T=K;try{var J=D(),ee=N.S;ee!==null&&ee(K,J),typeof J=="object"&&J!==null&&typeof J.then=="function"&&J.then(I,Y);}catch(te){Y(te);}finally{L!==null&&K.types!==null&&(L.types=K.types),N.T=L;}},Vt.unstable_useCacheRefresh=function(){return N.H.useCacheRefresh()},Vt.use=function(D){return N.H.use(D)},Vt.useActionState=function(D,L,K){return N.H.useActionState(D,L,K)},Vt.useCallback=function(D,L){return N.H.useCallback(D,L)},Vt.useContext=function(D){return N.H.useContext(D)},Vt.useDebugValue=function(){},Vt.useDeferredValue=function(D,L){return N.H.useDeferredValue(D,L)},Vt.useEffect=function(D,L){return N.H.useEffect(D,L)},Vt.useEffectEvent=function(D){return N.H.useEffectEvent(D)},Vt.useId=function(){return N.H.useId()},Vt.useImperativeHandle=function(D,L,K){return N.H.useImperativeHandle(D,L,K)},Vt.useInsertionEffect=function(D,L){return N.H.useInsertionEffect(D,L)},Vt.useLayoutEffect=function(D,L){return N.H.useLayoutEffect(D,L)},Vt.useMemo=function(D,L){return N.H.useMemo(D,L)},Vt.useOptimistic=function(D,L){return N.H.useOptimistic(D,L)},Vt.useReducer=function(D,L,K){return N.H.useReducer(D,L,K)},Vt.useRef=function(D){return N.H.useRef(D)},Vt.useState=function(D){return N.H.useState(D)},Vt.useSyncExternalStore=function(D,L,K){return N.H.useSyncExternalStore(D,L,K)},Vt.useTransition=function(){return N.H.useTransition()},Vt.version="19.2.4",Vt}var m5;function Xl(){return m5||(m5=1,fx.exports=DQ()),fx.exports}var f=Xl();const q=Io(f),K$=FX({__proto__:null,default:q},[f]),_Q={},BQ=(e,t)=>{const n=f.useRef(void 0);f.useEffect(()=>{n.current=AQ(e,t);}),f.useDebugValue(n.current);},LQ=BQ,zQ=new WeakMap;function bt(e,t){const n=t?.sync,r=f.useMemo(()=>e&&new WeakMap,[e]),o=f.useRef(void 0),i=f.useRef(false),a=f.useSyncExternalStore(f.useCallback(u=>{i.current=true;const d=Xa(e,u,n);return u(),()=>{d(),i.current=false;}},[e,n]),()=>{const u=Fr(e);try{if(i.current&&o.current&&!yL(o.current,u,r,new WeakMap))return o.current}catch{}return u},()=>Fr(e));f.useLayoutEffect(()=>{o.current=a;}),(_Q?"production":void 0)!=="production"&&LQ(a,r);const l=f.useMemo(()=>new WeakMap,[]);return bL(a,r,l,zQ)}function kQ(e){return e instanceof Error?e.stack||e.message:e}function FQ(e,t){let n=0;for(let r=0;r<t.length;r++)n=(n<<5)-n+t.charCodeAt(r),n|=0;return e[Math.abs(n)%e.length]}function h5(e,t){let n=0,r=0,o=-1,i=0;for(;n<e.length;)if(r<t.length&&(t[r]===e[n]||t[r]==="*"))t[r]==="*"?(o=r,i=n,r++):(n++,r++);else if(o!==-1)r=o+1,i++,n=i;else return false;for(;r<t.length&&t[r]==="*";)r++;return r===t.length}function HQ(e){return e>=1e3?`${(e/1e3).toFixed(1)}s`:`${e}ms`}let S0="";function xL(e,t){let n,r,o,i;const a=(...l)=>{if(!a.enabled)return;const u=Date.now(),d=u-(n||u);n=u,l[0]=kQ(l[0]),typeof l[0]!="string"&&l.unshift("%O");let m=0;l[0]=l[0].replace(/%([a-z%])/gi,(p,g)=>{if(p==="%%")return "%";m++;const b=t.formatters[g];if(typeof b=="function"){const y=l[m];p=b.call(a,y),l.splice(m,1),m--;}return p}),t.formatArgs.call(a,d,l),a.log(...l);};return a.extend=function(l,u=":"){return xL(this.namespace+u+l,{useColors:this.useColors,color:this.color,formatArgs:this.formatArgs,formatters:this.formatters,inspectOpts:this.inspectOpts,log:this.log,humanize:this.humanize})},Object.assign(a,t),a.namespace=e,Object.defineProperty(a,"enabled",{enumerable:true,configurable:false,get:()=>r??(o!==S0&&(o=S0,i=jQ(e)),i),set:l=>{r=l;}}),a}let Y$=[],X$=[];function VQ(e){S0=e,Y$=[],X$=[];const t=S0.trim().replace(/\s+/g,",").split(",").filter(Boolean);for(const n of t)n[0]==="-"?X$.push(n.slice(1)):Y$.push(n);}function jQ(e){for(const t of X$)if(h5(e,t))return false;for(const t of Y$)if(h5(e,t))return true;return false}var UQ={};const WQ=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function GQ(e,t){const{useColors:n}=this;if(t[0]=`${(n?"%c":"")+this.namespace+(n?" %c":" ")+t[0]+(n?"%c ":" ")}+${this.humanize(e)}`,!n)return;const r=`color: ${this.color}`;t.splice(1,0,r,"color: inherit");let o=0,i=0;t[0].replace(/%[a-z%]/gi,a=>{a!=="%%"&&(o++,a==="%c"&&(i=o));}),t.splice(i,0,r);}const qQ=console.debug||console.log||(()=>{}),p5=XQ(),KQ={useColors:true,formatArgs:GQ,formatters:{j(e){try{return JSON.stringify(e)}catch(t){return `[UnexpectedJSONParseError]: ${t.message}`}}},inspectOpts:{},humanize:HQ,log:qQ};function YQ(e,t){var n;const r=(n=t)!==null&&n!==void 0?n:FQ(WQ,e);return xL(e,Object.assign(KQ,{color:r},t))}function XQ(){try{return localStorage}catch{}}function QQ(){let e;try{e=p5.getItem("debug")||p5.getItem("DEBUG");}catch{}return !e&&typeof process<"u"&&"env"in process&&(e=UQ.DEBUG),e||""}VQ(QQ());const Ao="Bilibili-Gate",io="bilibili-gate",EM="bilibili_gate",g5="bili-gate",ao=YQ(io),wL="https://api.bilibili.com",$L="https://app.bilibili.com",Qh={appkey:"4409e2ce8ffd12b8",appsec:"59b43e04ad6965f34319062b478f83dd"},$a=`${io}-root`,ZQ=`${io}-video-grid`,Dl=`${io}-video-card`,EL=`${io}-video-card-active`,ML=`${io}-video-card-cover`,RL=`${io}-tab-bar`,JQ=`${io}-video-card__recommend-reason`,Ef="请求失败, 请重试 !!!",Up="操作失败, 请重试 !!!",Kv="bilibili.com";var Ll=(e=>(e[e.Tld=Kv]="Tld",e.Main=`www.${Kv}`,e.Space=`space.${Kv}`,e.Search=`search.${Kv}`,e))(Ll||{});const{hostname:Zh,pathname:v5}=location;Zh===Ll.Tld||Zh.endsWith(`.${Ll.Tld}`);const TL=[Ll.Tld,Ll.Main].includes(Zh),eZ=Zh===Ll.Space,tZ=Zh===Ll.Search,_s=TL&&(v5==="/"||v5==="/index.html");function MM(e){return function(...n){const[r,...o]=n,i=`%c${Ao}%c`,a=["padding: 2px 4px; border-radius: 4px; color: #fff; background: #01847f; font-weight: bold;",""];return typeof r=="string"?e(`${i} ${r}`,...a,...o):e(`${i}`,...a,r,...o)}}const nZ=MM(console.log),Ko=MM(console.warn),rZ=MM(console.error);var Mf=(e=>(e.Pink="#f69",e.Blue="#00aeec",e))(Mf||{}),nt=(e=>(e.AppRecommend="app-recommend",e.PcRecommend="pc-recommend",e.KeepFollowOnly="keep-follow-only",e.DynamicFeed="dynamic-feed",e.Watchlater="watchlater",e.Fav="fav",e.Hot="hot",e.Live="live",e.SpaceUpload="space-upload",e.Liked="liked",e))(nt||{}),hr=(e=>(e.PopularGeneral="popular-general",e.PopularWeekly="popular-weekly",e.Rank="ranking",e))(hr||{});const Q$=Object.values(nt),oZ=["space-upload"],RM=g0(Q$,oZ);var mx={exports:{}},Wm={};var b5;function iZ(){if(b5)return Wm;b5=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,i){var a=null;if(i!==void 0&&(a=""+i),o.key!==void 0&&(a=""+o.key),"key"in o){i={};for(var l in o)l!=="key"&&(i[l]=o[l]);}else i=o;return o=i.ref,{$$typeof:e,type:r,key:a,ref:o!==void 0?o:null,props:i}}return Wm.Fragment=t,Wm.jsx=n,Wm.jsxs=n,Wm}var y5;function aZ(){return y5||(y5=1,mx.exports=iZ()),mx.exports}var qo=aZ();function sZ(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function lZ(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var cZ=(function(){function e(n){var r=this;this._insertTag=function(o){var i;r.tags.length===0?r.insertionPoint?i=r.insertionPoint.nextSibling:r.prepend?i=r.container.firstChild:i=r.before:i=r.tags[r.tags.length-1].nextSibling,r.container.insertBefore(o,i),r.tags.push(o);},this.isSpeedy=n.speedy===void 0?true:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null;}var t=e.prototype;return t.hydrate=function(r){r.forEach(this._insertTag);},t.insert=function(r){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(lZ(this));var o=this.tags[this.tags.length-1];if(this.isSpeedy){var i=sZ(o);try{i.insertRule(r,i.cssRules.length);}catch{}}else o.appendChild(document.createTextNode(r));this.ctr++;},t.flush=function(){this.tags.forEach(function(r){var o;return (o=r.parentNode)==null?void 0:o.removeChild(r)}),this.tags=[],this.ctr=0;},e})(),ho="-ms-",C0="-moz-",xn="-webkit-",AL="comm",TM="rule",AM="decl",uZ="@import",NL="@keyframes",dZ="@layer",fZ=Math.abs,Fy=String.fromCharCode,mZ=Object.assign;function hZ(e,t){return Qr(e,0)^45?(((t<<2^Qr(e,0))<<2^Qr(e,1))<<2^Qr(e,2))<<2^Qr(e,3):0}function PL(e){return e.trim()}function pZ(e,t){return (e=t.exec(e))?e[0]:e}function $n(e,t,n){return e.replace(t,n)}function Z$(e,t){return e.indexOf(t)}function Qr(e,t){return e.charCodeAt(t)|0}function Jh(e,t,n){return e.slice(t,n)}function Da(e){return e.length}function NM(e){return e.length}function Yv(e,t){return t.push(e),e}function gZ(e,t){return e.map(t).join("")}var Hy=1,nf=1,IL=0,Yo=0,xr=0,Rf="";function Vy(e,t,n,r,o,i,a){return {value:e,root:t,parent:n,type:r,props:o,children:i,line:Hy,column:nf,length:a,return:""}}function Gm(e,t){return mZ(Vy("",null,null,"",null,null,0),e,{length:-e.length},t)}function vZ(){return xr}function bZ(){return xr=Yo>0?Qr(Rf,--Yo):0,nf--,xr===10&&(nf=1,Hy--),xr}function Ci(){return xr=Yo<IL?Qr(Rf,Yo++):0,nf++,xr===10&&(nf=1,Hy++),xr}function Va(){return Qr(Rf,Yo)}function Ob(){return Yo}function Wp(e,t){return Jh(Rf,e,t)}function ep(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function OL(e){return Hy=nf=1,IL=Da(Rf=e),Yo=0,[]}function DL(e){return Rf="",e}function Db(e){return PL(Wp(Yo-1,J$(e===91?e+2:e===40?e+1:e)))}function yZ(e){for(;(xr=Va())&&xr<33;)Ci();return ep(e)>2||ep(xr)>3?"":" "}function SZ(e,t){for(;--t&&Ci()&&!(xr<48||xr>102||xr>57&&xr<65||xr>70&&xr<97););return Wp(e,Ob()+(t<6&&Va()==32&&Ci()==32))}function J$(e){for(;Ci();)switch(xr){case e:return Yo;case 34:case 39:e!==34&&e!==39&&J$(xr);break;case 40:e===41&&J$(e);break;case 92:Ci();break}return Yo}function CZ(e,t){for(;Ci()&&e+xr!==57;)if(e+xr===84&&Va()===47)break;return "/*"+Wp(t,Yo-1)+"*"+Fy(e===47?e:Ci())}function xZ(e){for(;!ep(Va());)Ci();return Wp(e,Yo)}function wZ(e){return DL(_b("",null,null,null,[""],e=OL(e),0,[0],e))}function _b(e,t,n,r,o,i,a,l,u){for(var d=0,m=0,p=a,g=0,b=0,y=0,S=1,C=1,w=1,$=0,M="",T=o,R=i,I=r,N=M;C;)switch(y=$,$=Ci()){case 40:if(y!=108&&Qr(N,p-1)==58){Z$(N+=$n(Db($),"&","&\f"),"&\f")!=-1&&(w=-1);break}case 34:case 39:case 91:N+=Db($);break;case 9:case 10:case 13:case 32:N+=yZ(y);break;case 92:N+=SZ(Ob()-1,7);continue;case 47:switch(Va()){case 42:case 47:Yv($Z(CZ(Ci(),Ob()),t,n),u);break;default:N+="/";}break;case 123*S:l[d++]=Da(N)*w;case 125*S:case 59:case 0:switch($){case 0:case 125:C=0;case 59+m:w==-1&&(N=$n(N,/\f/g,"")),b>0&&Da(N)-p&&Yv(b>32?C5(N+";",r,n,p-1):C5($n(N," ","")+";",r,n,p-2),u);break;case 59:N+=";";default:if(Yv(I=S5(N,t,n,d,m,o,l,M,T=[],R=[],p),i),$===123)if(m===0)_b(N,t,I,I,T,i,p,l,R);else switch(g===99&&Qr(N,3)===110?100:g){case 100:case 108:case 109:case 115:_b(e,I,I,r&&Yv(S5(e,I,I,0,0,o,l,M,o,T=[],p),R),o,R,p,l,r?T:R);break;default:_b(N,I,I,I,[""],R,0,l,R);}}d=m=b=0,S=w=1,M=N="",p=a;break;case 58:p=1+Da(N),b=y;default:if(S<1){if($==123)--S;else if($==125&&S++==0&&bZ()==125)continue}switch(N+=Fy($),$*S){case 38:w=m>0?1:(N+="\f",-1);break;case 44:l[d++]=(Da(N)-1)*w,w=1;break;case 64:Va()===45&&(N+=Db(Ci())),g=Va(),m=p=Da(M=N+=xZ(Ob())),$++;break;case 45:y===45&&Da(N)==2&&(S=0);}}return i}function S5(e,t,n,r,o,i,a,l,u,d,m){for(var p=o-1,g=o===0?i:[""],b=NM(g),y=0,S=0,C=0;y<r;++y)for(var w=0,$=Jh(e,p+1,p=fZ(S=a[y])),M=e;w<b;++w)(M=PL(S>0?g[w]+" "+$:$n($,/&\f/g,g[w])))&&(u[C++]=M);return Vy(e,t,n,o===0?TM:l,u,d,m)}function $Z(e,t,n){return Vy(e,t,n,AL,Fy(vZ()),Jh(e,2,-2),0)}function C5(e,t,n,r){return Vy(e,t,n,AM,Jh(e,0,r),Jh(e,r+1,-1),r)}function jd(e,t){for(var n="",r=NM(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function EZ(e,t,n,r){switch(e.type){case dZ:if(e.children.length)break;case uZ:case AM:return e.return=e.return||e.value;case AL:return "";case NL:return e.return=e.value+"{"+jd(e.children,r)+"}";case TM:e.value=e.props.join(",");}return Da(n=jd(e.children,r))?e.return=e.value+"{"+n+"}":""}function MZ(e){var t=NM(e);return function(n,r,o,i){for(var a="",l=0;l<t;l++)a+=e[l](n,r,o,i)||"";return a}}function RZ(e){return function(t){t.root||(t=t.return)&&e(t);}}function TZ(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var AZ=function(t,n,r){for(var o=0,i=0;o=i,i=Va(),o===38&&i===12&&(n[r]=1),!ep(i);)Ci();return Wp(t,Yo)},NZ=function(t,n){var r=-1,o=44;do switch(ep(o)){case 0:o===38&&Va()===12&&(n[r]=1),t[r]+=AZ(Yo-1,n,r);break;case 2:t[r]+=Db(o);break;case 4:if(o===44){t[++r]=Va()===58?"&\f":"",n[r]=t[r].length;break}default:t[r]+=Fy(o);}while(o=Ci());return t},PZ=function(t,n){return DL(NZ(OL(t),n))},x5=new WeakMap,IZ=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,r=t.parent,o=t.column===r.column&&t.line===r.line;r.type!=="rule";)if(r=r.parent,!r)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!x5.get(r))&&!o){x5.set(t,true);for(var i=[],a=PZ(n,i),l=r.props,u=0,d=0;u<a.length;u++)for(var m=0;m<l.length;m++,d++)t.props[d]=i[u]?a[u].replace(/&\f/g,l[m]):l[m]+" "+a[u];}}},OZ=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="");}};function _L(e,t){switch(hZ(e,t)){case 5103:return xn+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return xn+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return xn+e+C0+e+ho+e+e;case 6828:case 4268:return xn+e+ho+e+e;case 6165:return xn+e+ho+"flex-"+e+e;case 5187:return xn+e+$n(e,/(\w+).+(:[^]+)/,xn+"box-$1$2"+ho+"flex-$1$2")+e;case 5443:return xn+e+ho+"flex-item-"+$n(e,/flex-|-self/,"")+e;case 4675:return xn+e+ho+"flex-line-pack"+$n(e,/align-content|flex-|-self/,"")+e;case 5548:return xn+e+ho+$n(e,"shrink","negative")+e;case 5292:return xn+e+ho+$n(e,"basis","preferred-size")+e;case 6060:return xn+"box-"+$n(e,"-grow","")+xn+e+ho+$n(e,"grow","positive")+e;case 4554:return xn+$n(e,/([^-])(transform)/g,"$1"+xn+"$2")+e;case 6187:return $n($n($n(e,/(zoom-|grab)/,xn+"$1"),/(image-set)/,xn+"$1"),e,"")+e;case 5495:case 3959:return $n(e,/(image-set\([^]*)/,xn+"$1$`$1");case 4968:return $n($n(e,/(.+:)(flex-)?(.*)/,xn+"box-pack:$3"+ho+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+xn+e+e;case 4095:case 3583:case 4068:case 2532:return $n(e,/(.+)-inline(.+)/,xn+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Da(e)-1-t>6)switch(Qr(e,t+1)){case 109:if(Qr(e,t+4)!==45)break;case 102:return $n(e,/(.+:)(.+)-([^]+)/,"$1"+xn+"$2-$3$1"+C0+(Qr(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return ~Z$(e,"stretch")?_L($n(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Qr(e,t+1)!==115)break;case 6444:switch(Qr(e,Da(e)-3-(~Z$(e,"!important")&&10))){case 107:return $n(e,":",":"+xn)+e;case 101:return $n(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+xn+(Qr(e,14)===45?"inline-":"")+"box$3$1"+xn+"$2$3$1"+ho+"$2box$3")+e}break;case 5936:switch(Qr(e,t+11)){case 114:return xn+e+ho+$n(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return xn+e+ho+$n(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return xn+e+ho+$n(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return xn+e+ho+e+e}return e}var DZ=function(t,n,r,o){if(t.length>-1&&!t.return)switch(t.type){case AM:t.return=_L(t.value,t.length);break;case NL:return jd([Gm(t,{value:$n(t.value,"@","@"+xn)})],o);case TM:if(t.length)return gZ(t.props,function(i){switch(pZ(i,/(::plac\w+|:read-\w+)/)){case ":read-only":case ":read-write":return jd([Gm(t,{props:[$n(i,/:(read-\w+)/,":"+C0+"$1")]})],o);case "::placeholder":return jd([Gm(t,{props:[$n(i,/:(plac\w+)/,":"+xn+"input-$1")]}),Gm(t,{props:[$n(i,/:(plac\w+)/,":"+C0+"$1")]}),Gm(t,{props:[$n(i,/:(plac\w+)/,ho+"input-$1")]})],o)}return ""})}},_Z=[DZ],BL=function(t){var n=t.key;if(n==="css"){var r=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(r,function(S){var C=S.getAttribute("data-emotion");C.indexOf(" ")!==-1&&(document.head.appendChild(S),S.setAttribute("data-s",""));});}var o=t.stylisPlugins||_Z,i={},a,l=[];a=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(S){for(var C=S.getAttribute("data-emotion").split(" "),w=1;w<C.length;w++)i[C[w]]=true;l.push(S);});var u,d=[IZ,OZ];{var m,p=[EZ,RZ(function(S){m.insert(S);})],g=MZ(d.concat(o,p)),b=function(C){return jd(wZ(C),g)};u=function(C,w,$,M){m=$,b(C?C+"{"+w.styles+"}":w.styles),M&&(y.inserted[w.name]=true);};}var y={key:n,sheet:new cZ({key:n,container:a,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:i,registered:{},insert:u};return y.sheet.hydrate(l),y};function cr(){return cr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},cr.apply(null,arguments)}var hx={exports:{}},Mn={};var w5;function BZ(){if(w5)return Mn;w5=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,d=e?Symbol.for("react.concurrent_mode"):60111,m=e?Symbol.for("react.forward_ref"):60112,p=e?Symbol.for("react.suspense"):60113,g=e?Symbol.for("react.suspense_list"):60120,b=e?Symbol.for("react.memo"):60115,y=e?Symbol.for("react.lazy"):60116,S=e?Symbol.for("react.block"):60121,C=e?Symbol.for("react.fundamental"):60117,w=e?Symbol.for("react.responder"):60118,$=e?Symbol.for("react.scope"):60119;function M(R){if(typeof R=="object"&&R!==null){var I=R.$$typeof;switch(I){case t:switch(R=R.type,R){case u:case d:case r:case i:case o:case p:return R;default:switch(R=R&&R.$$typeof,R){case l:case m:case y:case b:case a:return R;default:return I}}case n:return I}}}function T(R){return M(R)===d}return Mn.AsyncMode=u,Mn.ConcurrentMode=d,Mn.ContextConsumer=l,Mn.ContextProvider=a,Mn.Element=t,Mn.ForwardRef=m,Mn.Fragment=r,Mn.Lazy=y,Mn.Memo=b,Mn.Portal=n,Mn.Profiler=i,Mn.StrictMode=o,Mn.Suspense=p,Mn.isAsyncMode=function(R){return T(R)||M(R)===u},Mn.isConcurrentMode=T,Mn.isContextConsumer=function(R){return M(R)===l},Mn.isContextProvider=function(R){return M(R)===a},Mn.isElement=function(R){return typeof R=="object"&&R!==null&&R.$$typeof===t},Mn.isForwardRef=function(R){return M(R)===m},Mn.isFragment=function(R){return M(R)===r},Mn.isLazy=function(R){return M(R)===y},Mn.isMemo=function(R){return M(R)===b},Mn.isPortal=function(R){return M(R)===n},Mn.isProfiler=function(R){return M(R)===i},Mn.isStrictMode=function(R){return M(R)===o},Mn.isSuspense=function(R){return M(R)===p},Mn.isValidElementType=function(R){return typeof R=="string"||typeof R=="function"||R===r||R===d||R===i||R===o||R===p||R===g||typeof R=="object"&&R!==null&&(R.$$typeof===y||R.$$typeof===b||R.$$typeof===a||R.$$typeof===l||R.$$typeof===m||R.$$typeof===C||R.$$typeof===w||R.$$typeof===$||R.$$typeof===S)},Mn.typeOf=M,Mn}var $5;function LZ(){return $5||($5=1,hx.exports=BZ()),hx.exports}var px,E5;function zZ(){if(E5)return px;E5=1;var e=LZ(),t={childContextTypes:true,contextType:true,contextTypes:true,defaultProps:true,displayName:true,getDefaultProps:true,getDerivedStateFromError:true,getDerivedStateFromProps:true,mixins:true,propTypes:true,type:true},n={name:true,length:true,prototype:true,caller:true,callee:true,arguments:true,arity:true},r={$$typeof:true,render:true,defaultProps:true,displayName:true,propTypes:true},o={$$typeof:true,compare:true,defaultProps:true,displayName:true,propTypes:true,type:true},i={};i[e.ForwardRef]=r,i[e.Memo]=o;function a(y){return e.isMemo(y)?o:i[y.$$typeof]||t}var l=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,m=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,g=Object.prototype;function b(y,S,C){if(typeof S!="string"){if(g){var w=p(S);w&&w!==g&&b(y,w,C);}var $=u(S);d&&($=$.concat(d(S)));for(var M=a(y),T=a(S),R=0;R<$.length;++R){var I=$[R];if(!n[I]&&!(C&&C[I])&&!(T&&T[I])&&!(M&&M[I])){var N=m(S,I);try{l(y,I,N);}catch{}}}}return y}return px=b,px}zZ();var kZ=true;function PM(e,t,n){var r="";return n.split(" ").forEach(function(o){e[o]!==void 0?t.push(e[o]+";"):o&&(r+=o+" ");}),r}var LL=function(t,n,r){var o=t.key+"-"+n.name;(r===false||kZ===false)&&t.registered[o]===void 0&&(t.registered[o]=n.styles);},IM=function(t,n,r){LL(t,n,r);var o=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var i=n;do t.insert(n===i?"."+o:"",i,t.sheet,true),i=i.next;while(i!==void 0)}};function FZ(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16);}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var HZ={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},VZ=/[A-Z]|^ms/g,jZ=/_EMO_([^_]+?)_([^]*?)_EMO_/g,zL=function(t){return t.charCodeAt(1)===45},M5=function(t){return t!=null&&typeof t!="boolean"},gx=TZ(function(e){return zL(e)?e:e.replace(VZ,"-$&").toLowerCase()}),R5=function(t,n){switch(t){case "animation":case "animationName":if(typeof n=="string")return n.replace(jZ,function(r,o,i){return _a={name:o,styles:i,next:_a},o})}return HZ[t]!==1&&!zL(t)&&typeof n=="number"&&n!==0?n+"px":n};function tp(e,t,n){if(n==null)return "";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case "boolean":return "";case "object":{var o=n;if(o.anim===1)return _a={name:o.name,styles:o.styles,next:_a},o.name;var i=n;if(i.styles!==void 0){var a=i.next;if(a!==void 0)for(;a!==void 0;)_a={name:a.name,styles:a.styles,next:_a},a=a.next;var l=i.styles+";";return l}return UZ(e,t,n)}case "function":{if(e!==void 0){var u=_a,d=n(e);return _a=u,tp(e,t,d)}break}}var m=n;if(t==null)return m;var p=t[m];return p!==void 0?p:m}function UZ(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=tp(e,t,n[o])+";";else for(var i in n){var a=n[i];if(typeof a!="object"){var l=a;t!=null&&t[l]!==void 0?r+=i+"{"+t[l]+"}":M5(l)&&(r+=gx(i)+":"+R5(i,l)+";");}else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var u=0;u<a.length;u++)M5(a[u])&&(r+=gx(i)+":"+R5(i,a[u])+";");else {var d=tp(e,t,a);switch(i){case "animation":case "animationName":{r+=gx(i)+":"+d+";";break}default:r+=i+"{"+d+"}";}}}return r}var T5=/label:\s*([^\s;{]+)\s*(;|$)/g,_a;function Ud(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=true,o="";_a=void 0;var i=e[0];if(i==null||i.raw===void 0)r=false,o+=tp(n,t,i);else {var a=i;o+=a[0];}for(var l=1;l<e.length;l++)if(o+=tp(n,t,e[l]),r){var u=i;o+=u[l];}T5.lastIndex=0;for(var d="",m;(m=T5.exec(o))!==null;)d+="-"+m[1];var p=FZ(o)+d;return {name:p,styles:o,next:_a}}var WZ=function(t){return t()},kL=K$.useInsertionEffect?K$.useInsertionEffect:false,GZ=kL||WZ,A5=kL||f.useLayoutEffect,FL=f.createContext(typeof HTMLElement<"u"?BL({key:"css"}):null),qZ=FL.Provider,HL=function(t){return f.forwardRef(function(n,r){var o=f.useContext(FL);return t(n,o,r)})},VL=f.createContext({}),Gp={}.hasOwnProperty,e2="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",OM=function(t,n){var r={};for(var o in n)Gp.call(n,o)&&(r[o]=n[o]);return r[e2]=t,r},KZ=function(t){var n=t.cache,r=t.serialized,o=t.isStringTag;return LL(n,r,o),GZ(function(){return IM(n,r,o)}),null},YZ=HL(function(e,t,n){var r=e.css;typeof r=="string"&&t.registered[r]!==void 0&&(r=t.registered[r]);var o=e[e2],i=[r],a="";typeof e.className=="string"?a=PM(t.registered,i,e.className):e.className!=null&&(a=e.className+" ");var l=Ud(i,void 0,f.useContext(VL));a+=t.key+"-"+l.name;var u={};for(var d in e)Gp.call(e,d)&&d!=="css"&&d!==e2&&(u[d]=e[d]);return u.className=a,n&&(u.ref=n),f.createElement(f.Fragment,null,f.createElement(KZ,{cache:t,serialized:l,isStringTag:typeof o=="string"}),f.createElement(o,u))}),DM=YZ,ze=qo.Fragment,x=function(t,n,r){return Gp.call(n,"css")?qo.jsx(DM,OM(t,n),r):qo.jsx(t,n,r)},F=function(t,n,r){return Gp.call(n,"css")?qo.jsxs(DM,OM(t,n),r):qo.jsxs(t,n,r)};const bl=new WeakMap,Oc=new WeakMap,Cs=new WeakMap;var XZ={};const x0=Symbol("anyProducer"),N5=Promise.resolve(),w0=Symbol("listenerAdded"),$0=Symbol("listenerRemoved");let E0=false,vx=false;const M0=e=>typeof e=="string"||typeof e=="symbol"||typeof e=="number";function dd(e){if(!M0(e))throw new TypeError("`eventName` must be a string, symbol, or number")}function Xv(e){if(typeof e!="function")throw new TypeError("listener must be a function")}function fd(e,t){const n=Oc.get(e);if(n.has(t))return n.get(t)}function Th(e,t){const n=M0(t)?t:x0,r=Cs.get(e);if(r.has(n))return r.get(n)}function QZ(e,t,n){const r=Cs.get(e);if(r.has(t))for(const o of r.get(t))o.enqueue(n);if(r.has(x0)){const o=Promise.all([t,n]);for(const i of r.get(x0))i.enqueue(o);}}function P5(e,t){t=Array.isArray(t)?t:[t];let n=false,r=()=>{},o=[];const i={enqueue(a){o.push(a),r();},finish(){n=true,r();}};for(const a of t){let l=Th(e,a);l||(l=new Set,Cs.get(e).set(a,l)),l.add(i);}return {async next(){return o?o.length===0?n?(o=void 0,this.next()):(await new Promise(a=>{r=a;}),this.next()):{done:false,value:await o.shift()}:{done:true}},async return(a){o=void 0;for(const l of t){const u=Th(e,l);u&&(u.delete(i),u.size===0&&Cs.get(e).delete(l));}return r(),arguments.length>0?{done:true,value:await a}:{done:true}},[Symbol.asyncIterator](){return this}}}function I5(e){if(e===void 0)return O5;if(!Array.isArray(e))throw new TypeError("`methodNames` must be an array of strings");for(const t of e)if(!O5.includes(t))throw typeof t!="string"?new TypeError("`methodNames` element must be a string"):new Error(`${t} is not Emittery method`);return e}const Rd=e=>e===w0||e===$0;function Qv(e,t,n){if(Rd(t))try{E0=!0,e.emit(t,n);}finally{E0=false;}}class Xo{static mixin(t,n){return n=I5(n),r=>{if(typeof r!="function")throw new TypeError("`target` must be function");for(const a of n)if(r.prototype[a]!==void 0)throw new Error(`The property \`${a}\` already exists on \`target\``);function o(){return Object.defineProperty(this,t,{enumerable:false,value:new Xo}),this[t]}Object.defineProperty(r.prototype,t,{enumerable:false,get:o});const i=a=>function(...l){return this[t][a](...l)};for(const a of n)Object.defineProperty(r.prototype,a,{enumerable:false,value:i(a)});return r}}static get isDebugEnabled(){if(typeof XZ!="object")return vx;const{env:t}=globalThis.process??{env:{}};return t.DEBUG==="emittery"||t.DEBUG==="*"||vx}static set isDebugEnabled(t){vx=t;}constructor(t={}){bl.set(this,new Set),Oc.set(this,new Map),Cs.set(this,new Map),Cs.get(this).set(x0,new Set),this.debug=t.debug??{},this.debug.enabled===void 0&&(this.debug.enabled=false),this.debug.logger||(this.debug.logger=(n,r,o,i)=>{try{i=JSON.stringify(i);}catch{i=`Object with the following keys failed to stringify: ${Object.keys(i).join(",")}`;}(typeof o=="symbol"||typeof o=="number")&&(o=o.toString());const a=new Date,l=`${a.getHours()}:${a.getMinutes()}:${a.getSeconds()}.${a.getMilliseconds()}`;console.log(`[${l}][emittery:${n}][${r}] Event Name: ${o}
data: ${i}`);});}logIfDebugEnabled(t,n,r){(Xo.isDebugEnabled||this.debug.enabled)&&this.debug.logger(t,this.debug.name,n,r);}on(t,n,{signal:r}={}){Xv(n),t=Array.isArray(t)?t:[t];for(const i of t){dd(i);let a=fd(this,i);a||(a=new Set,Oc.get(this).set(i,a)),a.add(n),this.logIfDebugEnabled("subscribe",i,void 0),Rd(i)||Qv(this,w0,{eventName:i,listener:n});}const o=()=>{this.off(t,n),r?.removeEventListener("abort",o);};return r?.addEventListener("abort",o,{once:true}),r?.aborted&&o(),o}off(t,n){Xv(n),t=Array.isArray(t)?t:[t];for(const r of t){dd(r);const o=fd(this,r);o&&(o.delete(n),o.size===0&&Oc.get(this).delete(r)),this.logIfDebugEnabled("unsubscribe",r,void 0),Rd(r)||Qv(this,$0,{eventName:r,listener:n});}}once(t,n){if(n!==void 0&&typeof n!="function")throw new TypeError("predicate must be a function");let r;const o=new Promise(i=>{r=this.on(t,a=>{n&&!n(a)||(r(),i(a));});});return o.off=r,o}events(t){t=Array.isArray(t)?t:[t];for(const n of t)dd(n);return P5(this,t)}async emit(t,n){if(dd(t),Rd(t)&&!E0)throw new TypeError("`eventName` cannot be meta event `listenerAdded` or `listenerRemoved`");this.logIfDebugEnabled("emit",t,n),QZ(this,t,n);const r=fd(this,t)??new Set,o=bl.get(this),i=[...r],a=Rd(t)?[]:[...o];await N5,await Promise.all([...i.map(async l=>{if(r.has(l))return l(n)}),...a.map(async l=>{if(o.has(l))return l(t,n)})]);}async emitSerial(t,n){if(dd(t),Rd(t)&&!E0)throw new TypeError("`eventName` cannot be meta event `listenerAdded` or `listenerRemoved`");this.logIfDebugEnabled("emitSerial",t,n);const r=fd(this,t)??new Set,o=bl.get(this),i=[...r],a=[...o];await N5;for(const l of i)r.has(l)&&await l(n);for(const l of a)o.has(l)&&await l(t,n);}onAny(t,{signal:n}={}){Xv(t),this.logIfDebugEnabled("subscribeAny",void 0,void 0),bl.get(this).add(t),Qv(this,w0,{listener:t});const r=()=>{this.offAny(t),n?.removeEventListener("abort",r);};return n?.addEventListener("abort",r,{once:true}),n?.aborted&&r(),r}anyEvent(){return P5(this)}offAny(t){Xv(t),this.logIfDebugEnabled("unsubscribeAny",void 0,void 0),Qv(this,$0,{listener:t}),bl.get(this).delete(t);}clearListeners(t){t=Array.isArray(t)?t:[t];for(const n of t)if(this.logIfDebugEnabled("clear",n,void 0),M0(n)){const r=fd(this,n);r&&r.clear();const o=Th(this,n);if(o){for(const i of o)i.finish();o.clear();}}else {bl.get(this).clear();for(const[r,o]of Oc.get(this).entries())o.clear(),Oc.get(this).delete(r);for(const[r,o]of Cs.get(this).entries()){for(const i of o)i.finish();o.clear(),Cs.get(this).delete(r);}}}listenerCount(t){t=Array.isArray(t)?t:[t];let n=0;for(const r of t){if(M0(r)){n+=bl.get(this).size+(fd(this,r)?.size??0)+(Th(this,r)?.size??0)+(Th(this)?.size??0);continue}r!==void 0&&dd(r),n+=bl.get(this).size;for(const o of Oc.get(this).values())n+=o.size;for(const o of Cs.get(this).values())n+=o.size;}return n}bindMethods(t,n){if(typeof t!="object"||t===null)throw new TypeError("`target` must be an object");n=I5(n);for(const r of n){if(t[r]!==void 0)throw new Error(`The property \`${r}\` already exists on \`target\``);Object.defineProperty(t,r,{enumerable:false,value:this[r].bind(this)});}}}const O5=Object.getOwnPropertyNames(Xo.prototype).filter(e=>e!=="constructor");Object.defineProperty(Xo,"listenerAdded",{value:w0,writable:false,enumerable:true,configurable:false});Object.defineProperty(Xo,"listenerRemoved",{value:$0,writable:false,enumerable:true,configurable:false});function Mt(e){const t=f.useRef(e);return t.current=e,f.useCallback((...r)=>t.current?.(...r),[])}function wi(){return !!(typeof window<"u"&&window.document&&window.document.createElement)}const D5=wi()?f.useLayoutEffect:f.useEffect,An=(e,t)=>{const n=f.useRef(true);D5(()=>e(n.current),t),D5(()=>(n.current=false,()=>{n.current=true;}),[]);},Bb=(e,t)=>{An(n=>{if(!n)return e()},t);},R0=e=>{const t=f.useRef(false),[n,r]=f.useState(e);f.useEffect(()=>(t.current=false,()=>{t.current=true;}),[]);function o(i,a){a&&t.current||r(i);}return [n,o]};function un(e,t){const[n,r]=f.useState(e),o=t!==void 0?t:n;return An(i=>{i||r(t);},[t]),[o,r]}var bx={exports:{}},Rn={};var _5;function ZZ(){if(_5)return Rn;_5=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),a=Symbol.for("react.context"),l=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),m=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),g=Symbol.for("react.lazy"),b=Symbol.for("react.offscreen"),y;y=Symbol.for("react.module.reference");function S(C){if(typeof C=="object"&&C!==null){var w=C.$$typeof;switch(w){case e:switch(C=C.type,C){case n:case o:case r:case d:case m:return C;default:switch(C=C&&C.$$typeof,C){case l:case a:case u:case g:case p:case i:return C;default:return w}}case t:return w}}}return Rn.ContextConsumer=a,Rn.ContextProvider=i,Rn.Element=e,Rn.ForwardRef=u,Rn.Fragment=n,Rn.Lazy=g,Rn.Memo=p,Rn.Portal=t,Rn.Profiler=o,Rn.StrictMode=r,Rn.Suspense=d,Rn.SuspenseList=m,Rn.isAsyncMode=function(){return false},Rn.isConcurrentMode=function(){return false},Rn.isContextConsumer=function(C){return S(C)===a},Rn.isContextProvider=function(C){return S(C)===i},Rn.isElement=function(C){return typeof C=="object"&&C!==null&&C.$$typeof===e},Rn.isForwardRef=function(C){return S(C)===u},Rn.isFragment=function(C){return S(C)===n},Rn.isLazy=function(C){return S(C)===g},Rn.isMemo=function(C){return S(C)===p},Rn.isPortal=function(C){return S(C)===t},Rn.isProfiler=function(C){return S(C)===o},Rn.isStrictMode=function(C){return S(C)===r},Rn.isSuspense=function(C){return S(C)===d},Rn.isSuspenseList=function(C){return S(C)===m},Rn.isValidElementType=function(C){return typeof C=="string"||typeof C=="function"||C===n||C===o||C===r||C===d||C===m||C===b||typeof C=="object"&&C!==null&&(C.$$typeof===g||C.$$typeof===p||C.$$typeof===i||C.$$typeof===a||C.$$typeof===u||C.$$typeof===y||C.getModuleId!==void 0)},Rn.typeOf=S,Rn}var B5;function JZ(){return B5||(B5=1,bx.exports=ZZ()),bx.exports}var yx=JZ();function Tf(e,t,n){const r=f.useRef({});return (!("value"in r.current)||n(r.current.condition,t))&&(r.current.value=e(),r.current.condition=t),r.current.value}const eJ=Symbol.for("react.element"),tJ=Symbol.for("react.transitional.element"),nJ=Symbol.for("react.fragment");function jL(e){return e&&typeof e=="object"&&(e.$$typeof===eJ||e.$$typeof===tJ)&&e.type===nJ}const rJ=Number(f.version.split(".")[0]),oJ=(e,t)=>{typeof e=="function"?e(t):typeof e=="object"&&e&&"current"in e&&(e.current=t);},Vr=(...e)=>{const t=e.filter(Boolean);return t.length<=1?t[0]:n=>{e.forEach(r=>{oJ(r,n);});}},Bs=(...e)=>Tf(()=>Vr(...e),e,(t,n)=>t.length!==n.length||t.every((r,o)=>r!==n[o])),Su=e=>{if(!e)return false;if(_M(e)&&rJ>=19)return true;const t=yx.isMemo(e)?e.type.type:e.type;return !(typeof t=="function"&&!t.prototype?.render&&t.$$typeof!==yx.ForwardRef||typeof e=="function"&&!e.prototype?.render&&e.$$typeof!==yx.ForwardRef)};function _M(e){return f.isValidElement(e)&&!jL(e)}const iJ=e=>_M(e)&&Su(e),Ql=e=>{if(e&&_M(e)){const t=e;return t.props.propertyIsEnumerable("ref")?t.props.ref:t.ref}return null};function la(e,t){let n=e;for(let r=0;r<t.length;r+=1){if(n==null)return;n=n[t[r]];}return n}function UL(e,t,n,r){if(!t.length)return n;const[o,...i]=t;let a;return !e&&typeof o=="number"?a=[]:Array.isArray(e)?a=[...e]:a={...e},r&&n===void 0&&i.length===1?delete a[o][i[0]]:a[o]=UL(a[o],i,n,r),a}function ki(e,t,n,r=false){return t.length&&r&&n===void 0&&!la(e,t.slice(0,-1))?e:UL(e,t,n,r)}function aJ(e){return typeof e=="object"&&e!==null&&Object.getPrototypeOf(e)===Object.prototype}function L5(e){return Array.isArray(e)?[]:{}}const sJ=typeof Reflect>"u"?Object.keys:Reflect.ownKeys;function WL(e,t={}){const{prepareArray:n}=t,r=n||(()=>[]);let o=L5(e[0]);return e.forEach(i=>{function a(l,u){const d=new Set(u),m=la(i,l),p=Array.isArray(m);if(p||aJ(m)){if(!d.has(m)){d.add(m);const g=la(o,l);p?o=ki(o,l,r(g,m)):(!g||typeof g!="object")&&(o=ki(o,l,L5(m))),sJ(m).forEach(b=>{Object.getOwnPropertyDescriptor(m,b).enumerable&&a([...l,b],d);});}}else o=ki(o,l,m);}a([]);}),o}function Pd(...e){return WL(e)}let t2={};const lJ=e=>{};function cJ(e,t){}function uJ(e,t){}function dJ(){t2={};}function GL(e,t,n){!t&&!t2[n]&&(e(false,n),t2[n]=true);}function Er(e,t){GL(cJ,e,t);}function fJ(e,t){GL(uJ,e,t);}Er.preMessage=lJ;Er.resetWarned=dJ;Er.noteOnce=fJ;function Ln(e,t){const n=Object.assign({},e);return Array.isArray(t)&&t.forEach(r=>{delete n[r];}),n}function Qo(e,t={}){let n=[];return q.Children.forEach(e,r=>{r==null&&!t.keepEmpty||(Array.isArray(r)?n=n.concat(Qo(r)):jL(r)&&r.props?n=n.concat(Qo(r.props.children,t)):n.push(r));}),n}const mJ=f.createContext({});function rf(e){return e instanceof HTMLElement||e instanceof SVGElement}function of(e){return e&&typeof e=="object"&&rf(e.nativeElement)?e.nativeElement:rf(e)?e:null}const n2=f.createContext(null);function hJ({children:e,onBatchResize:t}){const n=f.useRef(0),r=f.useRef([]),o=f.useContext(n2),i=f.useCallback((a,l,u)=>{n.current+=1;const d=n.current;r.current.push({size:a,element:l,data:u}),Promise.resolve().then(()=>{d===n.current&&(t?.(r.current),r.current=[]);}),o?.(a,l,u);},[t,o]);return f.createElement(n2.Provider,{value:i},e)}const Al=new Map;function pJ(e){e.forEach(t=>{const{target:n}=t;Al.get(n)?.forEach(r=>r(n));});}let Sx;function qL(){return Sx||(Sx=new ResizeObserver(pJ)),Sx}function gJ(e,t){Al.has(e)||(Al.set(e,new Set),qL().observe(e)),Al.get(e).add(t);}function vJ(e,t){Al.has(e)&&(Al.get(e).delete(t),Al.get(e).size||(qL().unobserve(e),Al.delete(e)));}function KL(e,t,n,r){const o=f.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),i=Mt(l=>{const{width:u,height:d}=l.getBoundingClientRect(),{offsetWidth:m,offsetHeight:p}=l,g=Math.floor(u),b=Math.floor(d);if(o.current.width!==g||o.current.height!==b||o.current.offsetWidth!==m||o.current.offsetHeight!==p){const y={width:g,height:b,offsetWidth:m,offsetHeight:p};o.current=y;const S=m===Math.round(u)?u:m,C=p===Math.round(d)?d:p,w={...y,offsetWidth:S,offsetHeight:C};r?.(w,l),Promise.resolve().then(()=>{n?.(w,l);});}}),a=typeof t=="function";f.useEffect(()=>{const l=a?t():t;return l&&e&&gJ(l,i),()=>{l&&vJ(l,i);}},[e,a?0:t]);}function bJ(e,t){const{children:n,disabled:r,onResize:o,data:i}=e,a=f.useRef(null),l=f.useContext(n2),u=typeof n=="function",d=u?n(a):n,m=!u&&f.isValidElement(d)&&Su(d),p=m?Ql(d):null,g=Bs(p,a),b=()=>of(a.current);return f.useImperativeHandle(t,()=>b()),KL(!r,b,o,(y,S)=>{l?.(y,S,i);}),m?f.cloneElement(d,{ref:g}):d}const yJ=f.forwardRef(bJ);function r2(){return r2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},r2.apply(this,arguments)}const SJ="rc-observer-key";function CJ(e,t){const{children:n}=e;return (typeof n=="function"?[n]:Qo(n)).map((o,i)=>{const a=o?.key||`${SJ}-${i}`;return f.createElement(yJ,r2({},e,{key:a,ref:i===0?t:void 0}),o)})}const ma=f.forwardRef(CJ);ma.Collection=hJ;function YL(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=YL(e[t]))&&(r&&(r+=" "),r+=n);}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function X(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=YL(e))&&(r&&(r+=" "),r+=t);return r}function o2(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function xJ(e){if(Array.isArray(e))return o2(e)}function wJ(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function BM(e,t){if(e){if(typeof e=="string")return o2(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o2(e,t):void 0}}function $J(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qt(e){return xJ(e)||wJ(e)||BM(e)||$J()}let XL=e=>+setTimeout(e,16),QL=e=>clearTimeout(e);typeof window<"u"&&"requestAnimationFrame"in window&&(XL=e=>window.requestAnimationFrame(e),QL=e=>window.cancelAnimationFrame(e));let z5=0;const LM=new Map;function ZL(e){LM.delete(e);}const Lt=(e,t=1)=>{z5+=1;const n=z5;function r(o){if(o===0)ZL(n),e();else {const i=XL(()=>{r(o-1);});LM.set(n,i);}}return r(t),n};Lt.cancel=e=>{const t=LM.get(e);return ZL(e),QL(t)};function EJ(e){let t=null;const n=o=>()=>{t=null,e.apply(void 0,qt(o));},r=(...o)=>{t===null&&(t=Lt(n(o)));};return r.cancel=()=>{Lt.cancel(t),t=null;},r}const np="ant",jy="anticon",MJ=["outlined","borderless","filled","underlined"],RJ=(e,t)=>t||(e?`${np}-${e}`:np),wt=f.createContext({getPrefixCls:RJ,iconPrefixCls:jy}),{Consumer:j4e}=wt,k5={};function jt(e){const t=f.useContext(wt),{getPrefixCls:n,direction:r,getPopupContainer:o,renderEmpty:i}=t,a=t[e];return {classNames:k5,styles:k5,...a,getPrefixCls:n,direction:r,getPopupContainer:o,renderEmpty:i}}function rp(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16);}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}function i2(e,t){if(!e)return false;if(e.contains)return e.contains(t);let n=t;for(;n;){if(n===e)return true;n=n.parentNode;}return false}const F5="data-rc-order",H5="data-rc-priority",TJ="rc-util-key",a2=new Map;function JL({mark:e}={}){return e?e.startsWith("data-")?e:`data-${e}`:TJ}function Uy(e){return e.attachTo?e.attachTo:document.querySelector("head")||document.body}function AJ(e){return e==="queue"?"prependQueue":e?"prepend":"append"}function zM(e){return Array.from((a2.get(e)||e).children).filter(t=>t.tagName==="STYLE")}function ez(e,t={}){if(!wi())return null;const{csp:n,prepend:r,priority:o=0}=t,i=AJ(r),a=i==="prependQueue",l=document.createElement("style");l.setAttribute(F5,i),a&&o&&l.setAttribute(H5,`${o}`),n?.nonce&&(l.nonce=n?.nonce),l.innerHTML=e;const u=Uy(t),{firstChild:d}=u;if(r){if(a){const m=(t.styles||zM(u)).filter(p=>{if(!["prepend","prependQueue"].includes(p.getAttribute(F5)))return false;const g=Number(p.getAttribute(H5)||0);return o>=g});if(m.length)return u.insertBefore(l,m[m.length-1].nextSibling),l}u.insertBefore(l,d);}else u.appendChild(l);return l}function tz(e,t={}){let{styles:n}=t;return n||=zM(Uy(t)),n.find(r=>r.getAttribute(JL(t))===e)}function op(e,t={}){const n=tz(e,t);n&&Uy(t).removeChild(n);}function NJ(e,t){const n=a2.get(e);if(!n||!i2(document,n)){const r=ez("",t),{parentNode:o}=r;a2.set(e,o),e.removeChild(r);}}function _l(e,t,n={}){const r=Uy(n),o=zM(r),i={...n,styles:o};NJ(r,i);const a=tz(t,i);if(a)return i.csp?.nonce&&a.nonce!==i.csp?.nonce&&(a.nonce=i.csp?.nonce),a.innerHTML!==e&&(a.innerHTML=e),a;const l=ez(e,i);return l.setAttribute(JL(i),t),l}function zl(e,t,n=false){const r=new Set;function o(i,a,l=1){const u=r.has(i);if(Er(!u,"Warning: There may be circular references"),u)return false;if(i===a)return true;if(n&&l>1)return false;r.add(i);const d=l+1;if(Array.isArray(i)){if(!Array.isArray(a)||i.length!==a.length)return false;for(let m=0;m<i.length;m++)if(!o(i[m],a[m],d))return false;return true}if(i&&a&&typeof i=="object"&&typeof a=="object"){const m=Object.keys(i);return m.length!==Object.keys(a).length?false:m.every(p=>o(i[p],a[p],d))}return false}return o(e,t)}const PJ="%";function s2(e){return e.join(PJ)}let V5=0;class IJ{instanceId;constructor(t){this.instanceId=t;}cache=new Map;updateTimes=new Map;extracted=new Set;get(t){return this.opGet(s2(t))}opGet(t){return this.cache.get(t)||null}update(t,n){return this.opUpdate(s2(t),n)}opUpdate(t,n){const r=this.cache.get(t),o=n(r);o===null?(this.cache.delete(t),this.updateTimes.delete(t)):(this.cache.set(t,o),this.updateTimes.set(t,V5),V5+=1);}}const OJ={},kM="data-token-hash",Rs="data-css-hash",qc="__cssinjs_instance__";function nz(){const e=Math.random().toString(12).slice(2);if(typeof document<"u"&&document.head&&document.body){const t=document.body.querySelectorAll(`style[${Rs}]`)||[],{firstChild:n}=document.head;Array.from(t).forEach(o=>{o[qc]||=e,o[qc]===e&&document.head.insertBefore(o,n);});const r={};Array.from(document.querySelectorAll(`style[${Rs}]`)).forEach(o=>{const i=o.getAttribute(Rs);r[i]?o[qc]===e&&o.parentNode?.removeChild(o):r[i]=true;});}return new IJ(e)}const lu=f.createContext({hashPriority:"low",cache:nz(),defaultCache:true,autoPrefix:false}),DJ=e=>{const{children:t,...n}=e,r=f.useContext(lu),o=Tf(()=>{const i={...r};Object.keys(n).forEach(u=>{const d=n[u];n[u]!==void 0&&(i[u]=d);});const{cache:a,transformers:l=[]}=n;return i.cache=i.cache||nz(),i.defaultCache=!a&&r.defaultCache,l.includes(OJ)&&(i.autoPrefix=true),i},[r,n],(i,a)=>!zl(i[0],a[0],true)||!zl(i[1],a[1],true));return f.createElement(lu.Provider,{value:o},t)};function _J(e,t){if(e.length!==t.length)return false;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return false;return true}class T0{static MAX_CACHE_SIZE=20;static MAX_CACHE_OFFSET=5;cache;keys;cacheCallTimes;constructor(){this.cache=new Map,this.keys=[],this.cacheCallTimes=0;}size(){return this.keys.length}internalGet(t,n=false){let r={map:this.cache};return t.forEach(o=>{r?r=r?.map?.get(o):r=void 0;}),r?.value&&n&&(r.value[1]=this.cacheCallTimes++),r?.value}get(t){return this.internalGet(t,true)?.[0]}has(t){return !!this.internalGet(t)}set(t,n){if(!this.has(t)){if(this.size()+1>T0.MAX_CACHE_SIZE+T0.MAX_CACHE_OFFSET){const[o]=this.keys.reduce((i,a)=>{const[,l]=i;return this.internalGet(a)[1]<l?[a,this.internalGet(a)[1]]:i},[this.keys[0],this.cacheCallTimes]);this.delete(o);}this.keys.push(t);}let r=this.cache;t.forEach((o,i)=>{if(i===t.length-1)r.set(o,{value:[n,this.cacheCallTimes++]});else {const a=r.get(o);a?a.map||(a.map=new Map):r.set(o,{map:new Map}),r=r.get(o).map;}});}deleteByPath(t,n){const r=t.get(n[0]);if(n.length===1)return r.map?t.set(n[0],{map:r.map}):t.delete(n[0]),r.value?.[0];const o=this.deleteByPath(r.map,n.slice(1));return (!r.map||r.map.size===0)&&!r.value&&t.delete(n[0]),o}delete(t){if(this.has(t))return this.keys=this.keys.filter(n=>!_J(n,t)),this.deleteByPath(this.cache,t)}}let j5=0;class rz{derivatives;id;constructor(t){this.derivatives=Array.isArray(t)?t:[t],this.id=j5,t.length===0&&(t.length>0,void 0),j5+=1;}getDerivativeToken(t){return this.derivatives.reduce((n,r)=>r(t,n),void 0)}}const Cx=new T0;function A0(e){const t=Array.isArray(e)?e:[e];return Cx.has(t)||Cx.set(t,new rz(t)),Cx.get(t)}const BJ=new WeakMap,xx={};function LJ(e,t){let n=BJ;for(let r=0;r<t.length;r+=1){const o=t[r];n.has(o)||n.set(o,new WeakMap),n=n.get(o);}return n.has(xx)||n.set(xx,e()),n.get(xx)}const U5=new WeakMap;function Ah(e){let t=U5.get(e)||"";return t||(Object.keys(e).forEach(n=>{const r=e[n];t+=n,r instanceof rz?t+=r.id:r&&typeof r=="object"?t+=Ah(r):t+=r;}),t=rp(t),U5.set(e,t)),t}function zJ(e,t){return rp(`${t}_${Ah(e)}`)}const l2=wi();function oe(e){return typeof e=="number"?`${e}px`:e}function oz(e){const{hashCls:t,hashPriority:n="low"}=e||{};if(!t)return "";const r=`.${t}`;return n==="low"?`:where(${r})`:r}const kJ=e=>e!=null,Lb=(e,t="")=>`--${t?`${t}-`:""}${e}`.replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g,"$1-$2").replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase(),FJ=(e,t,n)=>{const{hashCls:r,hashPriority:o="low",scope:i}=n||{};if(!Object.keys(e).length)return "";const a=`${oz({hashCls:r,hashPriority:o})}.${t}`,l=[i].flat().filter(Boolean);return `${l.length?l.map(d=>`${a}.${d}`).join(", "):a}{${Object.entries(e).map(([d,m])=>`${d}:${m};`).join("")}}`},iz=(e,t,n)=>{const{hashCls:r,hashPriority:o="low",prefix:i,unitless:a,ignore:l,preserve:u}=n||{},d={},m={};return Object.entries(e).forEach(([p,g])=>{if(u?.[p])m[p]=g;else if((typeof g=="string"||typeof g=="number")&&!l?.[p]){const b=Lb(p,i);d[b]=typeof g=="number"&&!a?.[p]?`${g}px`:String(g),m[p]=`var(${b})`;}}),[m,FJ(d,t,{scope:n?.scope,hashCls:r,hashPriority:o})]},Zv=new Map;function FM(e,t,n,r,o){const{cache:i}=f.useContext(lu),a=[e,...t],l=s2(a),u=p=>{i.opUpdate(l,g=>{const[b=0,y]=g||[void 0,void 0],C=y||n(),w=[b,C];return p?p(w):w});};f.useMemo(()=>{u();},[l]);const m=i.opGet(l)[1];return f.useInsertionEffect(()=>(u(([p,g])=>[p+1,g]),Zv.has(l)||(o?.(m),Zv.set(l,true),Promise.resolve().then(()=>{Zv.delete(l);})),()=>{i.opUpdate(l,p=>{const[g=0,b]=p||[];return g-1===0?(r?.(b,false),Zv.delete(l),null):[g-1,b]});}),[l]),m}const HJ={},VJ="css",Bc=new Map;function jJ(e){Bc.set(e,(Bc.get(e)||0)+1);}function UJ(e,t){typeof document<"u"&&document.querySelectorAll(`style[${kM}="${e}"]`).forEach(r=>{r[qc]===t&&r.parentNode?.removeChild(r);});}const WJ=-1;function GJ(e,t){Bc.set(e,(Bc.get(e)||0)-1);const n=new Set;Bc.forEach((r,o)=>{r<=0&&n.add(o);}),Bc.size-n.size>WJ&&n.forEach(r=>{UJ(r,t),Bc.delete(r);});}const az=(e,t,n,r)=>{let i={...n.getDerivativeToken(e),...t};return r&&(i=r(i)),i},qJ="token";function KJ(e,t,n){const{cache:{instanceId:r},container:o,hashPriority:i}=f.useContext(lu),{salt:a="",override:l=HJ,formatToken:u,getComputedToken:d,cssVar:m}=n,p=LJ(()=>Object.assign({},...t),t),g=Ah(p),b=Ah(l),y=Ah(m);return FM(qJ,[a,e.id,g,b,y],()=>{const C=d?d(p,l,e):az(p,l,e,u),w={...C},$=`${a}_${m.prefix}`,M=rp($),T=`${VJ}-${M}`;w._tokenKey=zJ(w,$);const[R,I]=iz(C,m.key,{prefix:m.prefix,ignore:m.ignore,unitless:m.unitless,preserve:m.preserve,hashPriority:i,hashCls:m.hashed?T:void 0});return R._hashId=M,jJ(m.key),[R,T,w,I,m.key]},([,,,,C])=>{GJ(C,r);},([,,,C,w])=>{if(!C)return;const $=_l(C,rp(`css-var-${w}`),{mark:Rs,prepend:"queue",attachTo:o,priority:-999});$[qc]=r,$.setAttribute(kM,w);})}var YJ={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Kn="-ms-",Nh="-moz-",wn="-webkit-",sz="comm",HM="rule",VM="decl",XJ="@import",QJ="@namespace",lz="@keyframes",ZJ="@layer",cz=Math.abs,jM=String.fromCharCode,c2=Object.assign;function JJ(e,t){return Tr(e,0)^45?(((t<<2^Tr(e,0))<<2^Tr(e,1))<<2^Tr(e,2))<<2^Tr(e,3):0}function uz(e){return e.trim()}function bs(e,t){return (e=t.exec(e))?e[0]:e}function Xt(e,t,n){return e.replace(t,n)}function zb(e,t,n){return e.indexOf(t,n)}function Tr(e,t){return e.charCodeAt(t)|0}function cu(e,t,n){return e.slice(t,n)}function aa(e){return e.length}function dz(e){return e.length}function vh(e,t){return t.push(e),e}function eee(e,t){return e.map(t).join("")}function W5(e,t){return e.filter(function(n){return !bs(n,t)})}var Wy=1,af=1,fz=0,qi=0,wr=0,Af="";function Gy(e,t,n,r,o,i,a,l){return {value:e,root:t,parent:n,type:r,props:o,children:i,line:Wy,column:af,length:a,return:"",siblings:l}}function Cl(e,t){return c2(Gy("",null,null,"",null,null,0,e.siblings),e,{length:-e.length},t)}function md(e){for(;e.root;)e=Cl(e.root,{children:[e]});vh(e,e.siblings);}function tee(){return wr}function nee(){return wr=qi>0?Tr(Af,--qi):0,af--,wr===10&&(af=1,Wy--),wr}function ha(){return wr=qi<fz?Tr(Af,qi++):0,af++,wr===10&&(af=1,Wy++),wr}function Nl(){return Tr(Af,qi)}function kb(){return qi}function qy(e,t){return cu(Af,e,t)}function ip(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ree(e){return Wy=af=1,fz=aa(Af=e),qi=0,[]}function oee(e){return Af="",e}function wx(e){return uz(qy(qi-1,u2(e===91?e+2:e===40?e+1:e)))}function iee(e){for(;(wr=Nl())&&wr<33;)ha();return ip(e)>2||ip(wr)>3?"":" "}function aee(e,t){for(;--t&&ha()&&!(wr<48||wr>102||wr>57&&wr<65||wr>70&&wr<97););return qy(e,kb()+(t<6&&Nl()==32&&ha()==32))}function u2(e){for(;ha();)switch(wr){case e:return qi;case 34:case 39:e!==34&&e!==39&&u2(wr);break;case 40:e===41&&u2(e);break;case 92:ha();break}return qi}function see(e,t){for(;ha()&&e+wr!==57;)if(e+wr===84&&Nl()===47)break;return "/*"+qy(t,qi-1)+"*"+jM(e===47?e:ha())}function lee(e){for(;!ip(Nl());)ha();return qy(e,qi)}function G5(e){return oee(Fb("",null,null,null,[""],e=ree(e),0,[0],e))}function Fb(e,t,n,r,o,i,a,l,u){for(var d=0,m=0,p=a,g=0,b=0,y=0,S=1,C=1,w=1,$=0,M="",T=o,R=i,I=r,N=M;C;)switch(y=$,$=ha()){case 40:if(y!=108&&Tr(N,p-1)==58){zb(N+=Xt(wx($),"&","&\f"),"&\f",cz(d?l[d-1]:0))!=-1&&(w=-1);break}case 34:case 39:case 91:N+=wx($);break;case 9:case 10:case 13:case 32:N+=iee(y);break;case 92:N+=aee(kb()-1,7);continue;case 47:switch(Nl()){case 42:case 47:vh(cee(see(ha(),kb()),t,n,u),u),(ip(y||1)==5||ip(Nl()||1)==5)&&aa(N)&&cu(N,-1,void 0)!==" "&&(N+=" ");break;default:N+="/";}break;case 123*S:l[d++]=aa(N)*w;case 125*S:case 59:case 0:switch($){case 0:case 125:C=0;case 59+m:w==-1&&(N=Xt(N,/\f/g,"")),b>0&&(aa(N)-p||S===0&&y===47)&&vh(b>32?K5(N+";",r,n,p-1,u):K5(Xt(N," ","")+";",r,n,p-2,u),u);break;case 59:N+=";";default:if(vh(I=q5(N,t,n,d,m,o,l,M,T=[],R=[],p,i),i),$===123)if(m===0)Fb(N,t,I,I,T,i,p,l,R);else {switch(g){case 99:if(Tr(N,3)===110)break;case 108:if(Tr(N,2)===97)break;default:m=0;case 100:case 109:case 115:}m?Fb(e,I,I,r&&vh(q5(e,I,I,0,0,o,l,M,o,T=[],p,R),R),o,R,p,l,r?T:R):Fb(N,I,I,I,[""],R,0,l,R);}}d=m=b=0,S=w=1,M=N="",p=a;break;case 58:p=1+aa(N),b=y;default:if(S<1){if($==123)--S;else if($==125&&S++==0&&nee()==125)continue}switch(N+=jM($),$*S){case 38:w=m>0?1:(N+="\f",-1);break;case 44:l[d++]=(aa(N)-1)*w,w=1;break;case 64:Nl()===45&&(N+=wx(ha())),g=Nl(),m=p=aa(M=N+=lee(kb())),$++;break;case 45:y===45&&aa(N)==2&&(S=0);}}return i}function q5(e,t,n,r,o,i,a,l,u,d,m,p){for(var g=o-1,b=o===0?i:[""],y=dz(b),S=0,C=0,w=0;S<r;++S)for(var $=0,M=cu(e,g+1,g=cz(C=a[S])),T=e;$<y;++$)(T=uz(C>0?b[$]+" "+M:Xt(M,/&\f/g,b[$])))&&(u[w++]=T);return Gy(e,t,n,o===0?HM:l,u,d,m,p)}function cee(e,t,n,r){return Gy(e,t,n,sz,jM(tee()),cu(e,2,-2),0,r)}function K5(e,t,n,r,o){return Gy(e,t,n,VM,cu(e,0,r),cu(e,r+1,-1),r,o)}function mz(e,t,n){switch(JJ(e,t)){case 5103:return wn+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:case 6391:case 5879:case 5623:case 6135:case 4599:return wn+e+e;case 4855:return wn+e.replace("add","source-over").replace("substract","source-out").replace("intersect","source-in").replace("exclude","xor")+e;case 4789:return Nh+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return wn+e+Nh+e+Kn+e+e;case 5936:switch(Tr(e,t+11)){case 114:return wn+e+Kn+Xt(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return wn+e+Kn+Xt(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return wn+e+Kn+Xt(e,/[svh]\w+-[tblr]{2}/,"lr")+e}case 6828:case 4268:case 2903:return wn+e+Kn+e+e;case 6165:return wn+e+Kn+"flex-"+e+e;case 5187:return wn+e+Xt(e,/(\w+).+(:[^]+)/,wn+"box-$1$2"+Kn+"flex-$1$2")+e;case 5443:return wn+e+Kn+"flex-item-"+Xt(e,/flex-|-self/g,"")+(bs(e,/flex-|baseline/)?"":Kn+"grid-row-"+Xt(e,/flex-|-self/g,""))+e;case 4675:return wn+e+Kn+"flex-line-pack"+Xt(e,/align-content|flex-|-self/g,"")+e;case 5548:return wn+e+Kn+Xt(e,"shrink","negative")+e;case 5292:return wn+e+Kn+Xt(e,"basis","preferred-size")+e;case 6060:return wn+"box-"+Xt(e,"-grow","")+wn+e+Kn+Xt(e,"grow","positive")+e;case 4554:return wn+Xt(e,/([^-])(transform)/g,"$1"+wn+"$2")+e;case 6187:return Xt(Xt(Xt(e,/(zoom-|grab)/,wn+"$1"),/(image-set)/,wn+"$1"),e,"")+e;case 5495:case 3959:return Xt(e,/(image-set\([^]*)/,wn+"$1$`$1");case 4968:return Xt(Xt(e,/(.+:)(flex-)?(.*)/,wn+"box-pack:$3"+Kn+"flex-pack:$3"),/space-between/,"justify")+wn+e+e;case 4200:if(!bs(e,/flex-|baseline/))return Kn+"grid-column-align"+cu(e,t)+e;break;case 2592:case 3360:return Kn+Xt(e,"template-","")+e;case 4384:case 3616:return n&&n.some(function(r,o){return t=o,bs(r.props,/grid-\w+-end/)})?~zb(e+(n=n[t].value),"span",0)?e:Kn+Xt(e,"-start","")+e+Kn+"grid-row-span:"+(~zb(n,"span",0)?bs(n,/\d+/):+bs(n,/\d+/)-+bs(e,/\d+/))+";":Kn+Xt(e,"-start","")+e;case 4896:case 4128:return n&&n.some(function(r){return bs(r.props,/grid-\w+-start/)})?e:Kn+Xt(Xt(e,"-end","-span"),"span ","")+e;case 4095:case 3583:case 4068:case 2532:return Xt(e,/(.+)-inline(.+)/,wn+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(aa(e)-1-t>6)switch(Tr(e,t+1)){case 109:if(Tr(e,t+4)!==45)break;case 102:return Xt(e,/(.+:)(.+)-([^]+)/,"$1"+wn+"$2-$3$1"+Nh+(Tr(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return ~zb(e,"stretch",0)?mz(Xt(e,"stretch","fill-available"),t,n)+e:e}break;case 5152:case 5920:return Xt(e,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(r,o,i,a,l,u,d){return Kn+o+":"+i+d+(a?Kn+o+"-span:"+(l?u:+u-+i)+d:"")+e});case 4949:if(Tr(e,t+6)===121)return Xt(e,":",":"+wn)+e;break;case 6444:switch(Tr(e,Tr(e,14)===45?18:11)){case 120:return Xt(e,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+wn+(Tr(e,14)===45?"inline-":"")+"box$3$1"+wn+"$2$3$1"+Kn+"$2box$3")+e;case 100:return Xt(e,":",":"+Kn)+e}break;case 5719:case 2647:case 2135:case 3927:case 2391:return Xt(e,"scroll-","scroll-snap-")+e}return e}function ap(e,t){for(var n="",r=0;r<e.length;r++)n+=t(e[r],r,e,t)||"";return n}function Y5(e,t,n,r){switch(e.type){case ZJ:if(e.children.length)break;case XJ:case QJ:case VM:return e.return=e.return||e.value;case sz:return "";case lz:return e.return=e.value+"{"+ap(e.children,r)+"}";case HM:if(!aa(e.value=e.props.join(",")))return ""}return aa(n=ap(e.children,r))?e.return=e.value+"{"+n+"}":""}function uee(e){var t=dz(e);return function(n,r,o,i){for(var a="",l=0;l<t;l++)a+=e[l](n,r,o,i)||"";return a}}function dee(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case VM:e.return=mz(e.value,e.length,n);return;case lz:return ap([Cl(e,{value:Xt(e.value,"@","@"+wn)})],r);case HM:if(e.length)return eee(n=e.props,function(o){switch(bs(o,r=/(::plac\w+|:read-\w+)/)){case ":read-only":case ":read-write":md(Cl(e,{props:[Xt(o,/:(read-\w+)/,":"+Nh+"$1")]})),md(Cl(e,{props:[o]})),c2(e,{props:W5(n,r)});break;case "::placeholder":md(Cl(e,{props:[Xt(o,/:(plac\w+)/,":"+wn+"input-$1")]})),md(Cl(e,{props:[Xt(o,/:(plac\w+)/,":"+Nh+"$1")]})),md(Cl(e,{props:[Xt(o,/:(plac\w+)/,Kn+"input-$1")]})),md(Cl(e,{props:[o]})),c2(e,{props:W5(n,r)});break}return ""})}}const X5="data-ant-cssinjs-cache-path",hz="_FILE_STYLE__";let Kc,pz=true;function fee(){if(!Kc&&(Kc={},wi())){const e=document.createElement("div");e.className=X5,e.style.position="fixed",e.style.visibility="hidden",e.style.top="-9999px",document.body.appendChild(e);let t=getComputedStyle(e).content||"";t=t.replace(/^"/,"").replace(/"$/,""),t.split(";").forEach(r=>{const[o,i]=r.split(":");Kc[o]=i;});const n=document.querySelector(`style[${X5}]`);n&&(pz=false,n.parentNode?.removeChild(n)),document.body.removeChild(e);}}function mee(e){return fee(),!!Kc[e]}function hee(e){const t=Kc[e];let n=null;if(t&&wi())if(pz)n=hz;else {const r=document.querySelector(`style[${Rs}="${Kc[e]}"]`);r?n=r.innerHTML:delete Kc[e];}return [n,t]}const pee="_skip_check_",gz="_multi_value_";function $x(e,t){return (t?ap(G5(e),uee([dee,Y5])):ap(G5(e),Y5)).replace(/\{%%%\:[^;];}/g,";")}function gee(e){return typeof e=="object"&&e&&(pee in e||gz in e)}function Q5(e,t,n="high"){if(!t)return e;const r=oz({hashCls:t,hashPriority:n});return e.split(",").map(i=>{const a=i.trim().split(/\s+/);let l=a[0]||"";const u=l.match(/^\w+/)?.[0]||"";return l=`${u}${r}${l.slice(u.length)}`,[l,...a.slice(1)].join(" ")}).join(",")}const d2=(e,t={},{root:n,injectHash:r,parentSelectors:o}={root:true,parentSelectors:[]})=>{const{hashId:i,layer:a,path:l,hashPriority:u,transformers:d=[],linters:m=[]}=t;let p="",g={};function b(C){const w=C.getName(i);if(!g[w]){const[$]=d2(C.style,t,{root:false,parentSelectors:o});g[w]=`@keyframes ${C.getName(i)}${$}`;}}function y(C,w=[]){return C.forEach($=>{Array.isArray($)?y($,w):$&&w.push($);}),w}return y(Array.isArray(e)?e:[e]).forEach(C=>{const w=typeof C=="string"&&!n?{}:C;if(typeof w=="string")p+=`${w}
`;else if(w._keyframe)b(w);else {const $=d.reduce((M,T)=>T?.visit?.(M)||M,w);Object.keys($).forEach(M=>{const T=$[M];if(typeof T=="object"&&T&&(M!=="animationName"||!T._keyframe)&&!gee(T)){let R=false,I=M.trim(),N=false;(n||r)&&i?I.startsWith("@")?R=true:I==="&"?I=Q5("",i,u):I=Q5(M,i,u):n&&!i&&(I==="&"||I==="")&&(I="",N=true);const[P,O]=d2(T,t,{root:N,injectHash:R,parentSelectors:[...o,I]});g={...g,...O},p+=`${I}${P}`;}else {let R=function(N,P){const O=N.replace(/[A-Z]/g,B=>`-${B.toLowerCase()}`);let _=P;!YJ[N]&&typeof _=="number"&&_!==0&&(_=`${_}px`),N==="animationName"&&P?._keyframe&&(b(P),_=P.getName(i)),p+=`${O}:${_};`;};const I=T?.value??T;typeof T=="object"&&T?.[gz]&&Array.isArray(I)?I.forEach(N=>{R(M,N);}):kJ(I)&&R(M,I);}});}}),n?a&&(p&&(p=`@layer ${a.name} {${p}}`),a.dependencies&&(g[`@layer ${a.name}`]=a.dependencies.map(C=>`@layer ${C}, ${a.name};`).join(`
`))):p=`{${p}}`,[p,g]};function vz(e,t){return rp(`${e.join("%")}${t}`)}const vee="style";function f2(e,t){const{path:n,hashId:r,layer:o,nonce:i,clientOnly:a,order:l=0}=e,{mock:u,hashPriority:d,container:m,transformers:p,linters:g,cache:b,layer:y,autoPrefix:S}=f.useContext(lu),C=[r||""];y&&C.push("layer"),C.push(...n);let w=l2;FM(vee,C,()=>{const $=C.join("|");if(mee($)){const[P,O]=hee($);if(P)return [P,O,{},a,l]}const M=t(),[T,R]=d2(M,{hashId:r,hashPriority:d,layer:y?o:void 0,path:n.join("-"),transformers:p,linters:g}),I=$x(T,S||false),N=vz(C,I);return [I,N,R,a,l]},($,M)=>{const[,T]=$;M&&l2&&op(T,{mark:Rs,attachTo:m});},$=>{const[M,T,R,,I]=$;if(w&&M!==hz){const N={mark:Rs,prepend:y?false:"queue",attachTo:m,priority:I},P=typeof i=="function"?i():i;P&&(N.csp={nonce:P});const O=[],_=[];Object.keys(R).forEach(V=>{V.startsWith("@layer")?O.push(V):_.push(V);}),O.forEach(V=>{_l($x(R[V],S||false),`_layer-${V}`,{...N,prepend:true});});const B=_l(M,T,N);B[qc]=b.instanceId,_.forEach(V=>{_l($x(R[V],S||false),`_effect-${V}`,N);});}});}const bee="cssVar",yee=(e,t)=>{const{key:n,prefix:r,unitless:o,ignore:i,token:a,hashId:l,scope:u}=e,{cache:{instanceId:d},container:m,hashPriority:p}=f.useContext(lu),{_tokenKey:g}=a,b=Array.isArray(u)?u.join("@@"):u,y=[...e.path,n,b,g];return FM(bee,y,()=>{const C=t(),[w,$]=iz(C,n,{prefix:r,unitless:o,ignore:i,scope:u,hashPriority:p,hashCls:l}),M=vz(y,$);return [w,$,M,n]},([,,C])=>{l2&&op(C,{mark:Rs,attachTo:m});},([,C,w])=>{if(!C)return;const $=_l(C,w,{mark:Rs,prepend:"queue",attachTo:m,priority:-999});$[qc]=d,$.setAttribute(kM,n);})};class zt{name;style;constructor(t,n){this.name=t,this.style=n;}getName(t=""){return t?`${t}-${this.name}`:this.name}_keyframe=true}function hd(e){return e.notSplit=true,e}hd(["borderTop","borderBottom"]),hd(["borderTop"]),hd(["borderBottom"]),hd(["borderLeft","borderRight"]),hd(["borderLeft"]),hd(["borderRight"]);function $r(e){"@babel/helpers - typeof";return $r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$r(e)}function See(e){if(Array.isArray(e))return e}function Cee(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,o,i,a,l=[],u=true,d=false;try{if(i=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;u=!1;}else for(;!(u=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);u=!0);}catch(m){d=true,o=m;}finally{try{if(!u&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(d)throw o}}return l}}function xee(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function UM(e,t){return See(e)||Cee(e,t)||BM(e,t)||xee()}function wee(e,t){if($r(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if($r(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}function bz(e){var t=wee(e,"string");return $r(t)=="symbol"?t:t+""}function Ct(e,t,n){return (t=bz(t))in e?Object.defineProperty(e,t,{value:n,enumerable:true,configurable:true,writable:true}):e[t]=n,e}function Z5(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r);}return n}function nr(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Z5(Object(n),true).forEach(function(r){Ct(e,r,n[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Z5(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r));});}return e}function Xi(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function J5(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||false,r.configurable=true,"value"in r&&(r.writable=true),Object.defineProperty(e,bz(r.key),r);}}function Qi(e,t,n){return t&&J5(e.prototype,t),n&&J5(e,n),Object.defineProperty(e,"prototype",{writable:false}),e}function Wd(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function sp(e,t){return sp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},sp(e,t)}function yz(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:true,configurable:true}}),Object.defineProperty(e,"prototype",{writable:false}),t&&sp(e,t);}function lp(e){return lp=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},lp(e)}function WM(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));}catch{}return (WM=function(){return !!e})()}function $ee(e,t){if(t&&($r(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Wd(e)}function Sz(e){var t=WM();return function(){var n,r=lp(e);if(t){var o=lp(this).constructor;n=Reflect.construct(r,arguments,o);}else n=r.apply(this,arguments);return $ee(this,n)}}var Eee=Qi(function e(){Xi(this,e);}),Cz="CALC_UNIT",Mee=new RegExp(Cz,"g");function Ex(e){return typeof e=="number"?"".concat(e).concat(Cz):e}var Ree=(function(e){yz(n,e);var t=Sz(n);function n(r,o){var i;Xi(this,n),i=t.call(this),Ct(Wd(i),"result",""),Ct(Wd(i),"unitlessCssVar",void 0),Ct(Wd(i),"lowPriority",void 0);var a=$r(r);return i.unitlessCssVar=o,r instanceof n?i.result="(".concat(r.result,")"):a==="number"?i.result=Ex(r):a==="string"&&(i.result=r),i}return Qi(n,[{key:"add",value:function(o){return o instanceof n?this.result="".concat(this.result," + ").concat(o.getResult()):(typeof o=="number"||typeof o=="string")&&(this.result="".concat(this.result," + ").concat(Ex(o))),this.lowPriority=true,this}},{key:"sub",value:function(o){return o instanceof n?this.result="".concat(this.result," - ").concat(o.getResult()):(typeof o=="number"||typeof o=="string")&&(this.result="".concat(this.result," - ").concat(Ex(o))),this.lowPriority=true,this}},{key:"mul",value:function(o){return this.lowPriority&&(this.result="(".concat(this.result,")")),o instanceof n?this.result="".concat(this.result," * ").concat(o.getResult(true)):(typeof o=="number"||typeof o=="string")&&(this.result="".concat(this.result," * ").concat(o)),this.lowPriority=false,this}},{key:"div",value:function(o){return this.lowPriority&&(this.result="(".concat(this.result,")")),o instanceof n?this.result="".concat(this.result," / ").concat(o.getResult(true)):(typeof o=="number"||typeof o=="string")&&(this.result="".concat(this.result," / ").concat(o)),this.lowPriority=false,this}},{key:"getResult",value:function(o){return this.lowPriority||o?"(".concat(this.result,")"):this.result}},{key:"equal",value:function(o){var i=this,a=o||{},l=a.unit,u=true;return typeof l=="boolean"?u=l:Array.from(this.unitlessCssVar).some(function(d){return i.result.includes(d)})&&(u=false),this.result=this.result.replace(Mee,u?"px":""),typeof this.lowPriority<"u"?"calc(".concat(this.result,")"):this.result}}]),n})(Eee),Tee=function(t,n){var r=Ree;return function(o){return new r(o,n)}},eI=function(t,n){return "".concat([n,t.replace(/([A-Z]+)([A-Z][a-z]+)/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2")].filter(Boolean).join("-"))};function tI(e,t,n,r){var o=nr({},t[e]);if(r!=null&&r.deprecatedTokens){var i=r.deprecatedTokens;i.forEach(function(l){var u=UM(l,2),d=u[0],m=u[1];if(o!=null&&o[d]||o!=null&&o[m]){var p;(p=o[m])!==null&&p!==void 0||(o[m]=o?.[d]);}});}var a=nr(nr({},n),o);return Object.keys(a).forEach(function(l){a[l]===t[l]&&delete a[l];}),a}var xz=typeof CSSINJS_STATISTIC<"u",m2=true;function Ft(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];if(!xz)return Object.assign.apply(Object,[{}].concat(t));m2=false;var r={};return t.forEach(function(o){if($r(o)==="object"){var i=Object.keys(o);i.forEach(function(a){Object.defineProperty(r,a,{configurable:true,enumerable:true,get:function(){return o[a]}});});}}),m2=true,r}var nI={};function Aee(){}var Nee=function(t){var n,r=t,o=Aee;return xz&&typeof Proxy<"u"&&(n=new Set,r=new Proxy(t,{get:function(a,l){if(m2){var u;(u=n)===null||u===void 0||u.add(l);}return a[l]}}),o=function(a,l){var u;nI[a]={global:Array.from(n),component:nr(nr({},(u=nI[a])===null||u===void 0?void 0:u.component),l)};}),{token:r,keys:n,flush:o}};function rI(e,t,n){if(typeof n=="function"){var r;return n(Ft(t,(r=t[e])!==null&&r!==void 0?r:{}))}return n??{}}function Pee(e){return {max:function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return "max(".concat(r.map(function(i){return oe(i)}).join(","),")")},min:function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return "min(".concat(r.map(function(i){return oe(i)}).join(","),")")}}}var Iee=1e3*60*10,Oee=(function(){function e(){Xi(this,e),Ct(this,"map",new Map),Ct(this,"objectIDMap",new WeakMap),Ct(this,"nextID",0),Ct(this,"lastAccessBeat",new Map),Ct(this,"accessBeat",0);}return Qi(e,[{key:"set",value:function(n,r){this.clear();var o=this.getCompositeKey(n);this.map.set(o,r),this.lastAccessBeat.set(o,Date.now());}},{key:"get",value:function(n){var r=this.getCompositeKey(n),o=this.map.get(r);return this.lastAccessBeat.set(r,Date.now()),this.accessBeat+=1,o}},{key:"getCompositeKey",value:function(n){var r=this,o=n.map(function(i){return i&&$r(i)==="object"?"obj_".concat(r.getObjectID(i)):"".concat($r(i),"_").concat(i)});return o.join("|")}},{key:"getObjectID",value:function(n){if(this.objectIDMap.has(n))return this.objectIDMap.get(n);var r=this.nextID;return this.objectIDMap.set(n,r),this.nextID+=1,r}},{key:"clear",value:function(){var n=this;if(this.accessBeat>1e4){var r=Date.now();this.lastAccessBeat.forEach(function(o,i){r-o>Iee&&(n.map.delete(i),n.lastAccessBeat.delete(i));}),this.accessBeat=0;}}}]),e})(),oI=new Oee;function Dee(e,t){return q.useMemo(function(){var n=oI.get(t);if(n)return n;var r=e();return oI.set(t,r),r},t)}var _ee=function(){return {}};function Bee(e){var t=e.useCSP,n=t===void 0?_ee:t,r=e.useToken,o=e.usePrefix,i=e.getResetStyles,a=e.getCommonStyle,l=e.getCompUnitless;function u(g,b,y,S){var C=Array.isArray(g)?g[0]:g;function w(P){return "".concat(String(C)).concat(P.slice(0,1).toUpperCase()).concat(P.slice(1))}var $=S?.unitless||{},M=typeof l=="function"?l(g):{},T=nr(nr({},M),{},Ct({},w("zIndexPopup"),true));Object.keys($).forEach(function(P){T[w(P)]=$[P];});var R=nr(nr({},S),{},{unitless:T,prefixToken:w}),I=m(g,b,y,R),N=d(C,y,R);return function(P){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:P,_=I(P,O),B=S?.extraCssVarPrefixCls,V=typeof B=="function"?B({prefixCls:P,rootCls:O}):B,U=N(V!=null&&V.length?[O].concat(qt(V)):O);return [_,U]}}function d(g,b,y){var S=y.unitless,C=y.prefixToken,w=y.ignore;return function($){var M=r(),T=M.cssVar,R=M.realToken;return yee({path:[g],prefix:T.prefix,key:T.key,unitless:S,ignore:w,token:R,scope:$},function(){var I=rI(g,R,b),N=tI(g,R,I,{deprecatedTokens:y?.deprecatedTokens});return I&&Object.keys(I).forEach(function(P){N[C(P)]=N[P],delete N[P];}),N}),T?.key}}function m(g,b,y){var S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},C=Array.isArray(g)?g:[g,g],w=UM(C,1),$=w[0],M=C.join("-"),T=e.layer||{name:"antd"};return function(R){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:R,N=r(),P=N.theme,O=N.realToken,_=N.hashId,B=N.token,V=N.cssVar,U=N.zeroRuntime,G=f.useMemo(function(){return U},[]);if(G)return _;var H=o(),z=H.rootPrefixCls,j=H.iconPrefixCls,W=n(),Y="css",Q=Dee(function(){var ee=new Set;return Object.keys(S.unitless||{}).forEach(function(te){ee.add(Lb(te,V.prefix)),ee.add(Lb(te,eI($,V.prefix)));}),Tee(Y,ee)},[Y,$,V?.prefix]),D=Pee(),L=D.max,K=D.min,J={theme:P,token:B,hashId:_,nonce:function(){return W.nonce},clientOnly:S.clientOnly,layer:T,order:S.order||-999};return typeof i=="function"&&f2(nr(nr({},J),{},{clientOnly:false,path:["Shared",z]}),function(){return i(B,{prefix:{rootPrefixCls:z,iconPrefixCls:j},csp:W})}),f2(nr(nr({},J),{},{path:[M,R,j]}),function(){if(S.injectStyle===false)return [];var ee=Nee(B),te=ee.token,re=ee.flush,ie=rI($,O,y),de=".".concat(R),ne=tI($,O,ie,{deprecatedTokens:S.deprecatedTokens});ie&&$r(ie)==="object"&&Object.keys(ie).forEach(function(Me){ie[Me]="var(".concat(Lb(Me,eI($,V.prefix)),")");});var ce=Ft(te,{componentCls:de,prefixCls:R,iconCls:".".concat(j),antCls:".".concat(z),calc:Q,max:L,min:K},ie),fe=b(ce,{hashId:_,prefixCls:R,rootPrefixCls:z,iconPrefixCls:j});re($,ne);var se=typeof a=="function"?a(ce,R,I,S.resetFont):null;return [S.resetStyle===false?null:se,fe]}),_}}function p(g,b,y){var S=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},C=m(g,b,y,nr({resetStyle:false,order:-998},S)),w=function(M){var T=M.prefixCls,R=M.rootCls,I=R===void 0?T:R;return C(T,I),null};return w}return {genStyleHooks:u,genSubStyleComponent:p,genComponentStyleHook:m}}const Wa=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"];function Hb(e){return (e+8)/e}function Lee(e){const t=Array.from({length:10}).map((n,r)=>{const o=r-1,i=e*Math.E**(o/5),a=r>1?Math.floor(i):Math.ceil(i);return Math.floor(a/2)*2});return t[1]=e,t.map(n=>({size:n,lineHeight:Hb(n)}))}const zee="6.3.0",qM={blue:"#1677FF",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#EB2F96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},sf={...qM,colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:`-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,
'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',
'Noto Color Emoji'`,fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:false,motion:true},kee={aliceblue:"9ehhb",antiquewhite:"9sgk7",aqua:"1ekf",aquamarine:"4zsno",azure:"9eiv3",beige:"9lhp8",bisque:"9zg04",black:"0",blanchedalmond:"9zhe5",blue:"73",blueviolet:"5e31e",brown:"6g016",burlywood:"8ouiv",cadetblue:"3qba8",chartreuse:"4zshs",chocolate:"87k0u",coral:"9yvyo",cornflowerblue:"3xael",cornsilk:"9zjz0",crimson:"8l4xo",cyan:"1ekf",darkblue:"3v",darkcyan:"rkb",darkgoldenrod:"776yz",darkgray:"6mbhl",darkgreen:"jr4",darkgrey:"6mbhl",darkkhaki:"7ehkb",darkmagenta:"5f91n",darkolivegreen:"3bzfz",darkorange:"9yygw",darkorchid:"5z6x8",darkred:"5f8xs",darksalmon:"9441m",darkseagreen:"5lwgf",darkslateblue:"2th1n",darkslategray:"1ugcv",darkslategrey:"1ugcv",darkturquoise:"14up",darkviolet:"5rw7n",deeppink:"9yavn",deepskyblue:"11xb",dimgray:"442g9",dimgrey:"442g9",dodgerblue:"16xof",firebrick:"6y7tu",floralwhite:"9zkds",forestgreen:"1cisi",fuchsia:"9y70f",gainsboro:"8m8kc",ghostwhite:"9pq0v",goldenrod:"8j4f4",gold:"9zda8",gray:"50i2o",green:"pa8",greenyellow:"6senj",grey:"50i2o",honeydew:"9eiuo",hotpink:"9yrp0",indianred:"80gnw",indigo:"2xcoy",ivory:"9zldc",khaki:"9edu4",lavenderblush:"9ziet",lavender:"90c8q",lawngreen:"4vk74",lemonchiffon:"9zkct",lightblue:"6s73a",lightcoral:"9dtog",lightcyan:"8s1rz",lightgoldenrodyellow:"9sjiq",lightgray:"89jo3",lightgreen:"5nkwg",lightgrey:"89jo3",lightpink:"9z6wx",lightsalmon:"9z2ii",lightseagreen:"19xgq",lightskyblue:"5arju",lightslategray:"4nwk9",lightslategrey:"4nwk9",lightsteelblue:"6wau6",lightyellow:"9zlcw",lime:"1edc",limegreen:"1zcxe",linen:"9shk6",magenta:"9y70f",maroon:"4zsow",mediumaquamarine:"40eju",mediumblue:"5p",mediumorchid:"79qkz",mediumpurple:"5r3rv",mediumseagreen:"2d9ip",mediumslateblue:"4tcku",mediumspringgreen:"1di2",mediumturquoise:"2uabw",mediumvioletred:"7rn9h",midnightblue:"z980",mintcream:"9ljp6",mistyrose:"9zg0x",moccasin:"9zfzp",navajowhite:"9zest",navy:"3k",oldlace:"9wq92",olive:"50hz4",olivedrab:"472ub",orange:"9z3eo",orangered:"9ykg0",orchid:"8iu3a",palegoldenrod:"9bl4a",palegreen:"5yw0o",paleturquoise:"6v4ku",palevioletred:"8k8lv",papayawhip:"9zi6t",peachpuff:"9ze0p",peru:"80oqn",pink:"9z8wb",plum:"8nba5",powderblue:"6wgdi",purple:"4zssg",rebeccapurple:"3zk49",red:"9y6tc",rosybrown:"7cv4f",royalblue:"2jvtt",saddlebrown:"5fmkz",salmon:"9rvci",sandybrown:"9jn1c",seagreen:"1tdnb",seashell:"9zje6",sienna:"6973h",silver:"7ir40",skyblue:"5arjf",slateblue:"45e4t",slategray:"4e100",slategrey:"4e100",snow:"9zke2",springgreen:"1egv",steelblue:"2r1kk",tan:"87yx8",teal:"pds",thistle:"8ggk8",tomato:"9yqfb",turquoise:"2j4r4",violet:"9b10u",wheat:"9ld4j",white:"9zldr",whitesmoke:"9lhpx",yellow:"9zl6o",yellowgreen:"61fzm"},_r=Math.round;function Mx(e,t){const n=e.replace(/^[^(]*\((.*)/,"$1").replace(/\).*/,"").match(/\d*\.?\d+%?/g)||[],r=n.map(o=>parseFloat(o));for(let o=0;o<3;o+=1)r[o]=t(r[o]||0,n[o]||"",o);return n[3]?r[3]=n[3].includes("%")?r[3]/100:r[3]:r[3]=1,r}const iI=(e,t,n)=>n===0?e:e/100;function qm(e,t){const n=t||255;return e>n?n:e<0?0:e}class cn{isValid=true;r=0;g=0;b=0;a=1;_h;_hsl_s;_hsv_s;_l;_v;_max;_min;_brightness;constructor(t){function n(r){return r[0]in t&&r[1]in t&&r[2]in t}if(t)if(typeof t=="string"){let o=function(i){return r.startsWith(i)};const r=t.trim();if(/^#?[A-F\d]{3,8}$/i.test(r))this.fromHexString(r);else if(o("rgb"))this.fromRgbString(r);else if(o("hsl"))this.fromHslString(r);else if(o("hsv")||o("hsb"))this.fromHsvString(r);else {const i=kee[r.toLowerCase()];i&&this.fromHexString(parseInt(i,36).toString(16).padStart(6,"0"));}}else if(t instanceof cn)this.r=t.r,this.g=t.g,this.b=t.b,this.a=t.a,this._h=t._h,this._hsl_s=t._hsl_s,this._hsv_s=t._hsv_s,this._l=t._l,this._v=t._v;else if(n("rgb"))this.r=qm(t.r),this.g=qm(t.g),this.b=qm(t.b),this.a=typeof t.a=="number"?qm(t.a,1):1;else if(n("hsl"))this.fromHsl(t);else if(n("hsv"))this.fromHsv(t);else throw new Error("@ant-design/fast-color: unsupported input "+JSON.stringify(t))}setR(t){return this._sc("r",t)}setG(t){return this._sc("g",t)}setB(t){return this._sc("b",t)}setA(t){return this._sc("a",t,1)}setHue(t){const n=this.toHsv();return n.h=t,this._c(n)}getLuminance(){function t(i){const a=i/255;return a<=.03928?a/12.92:Math.pow((a+.055)/1.055,2.4)}const n=t(this.r),r=t(this.g),o=t(this.b);return .2126*n+.7152*r+.0722*o}getHue(){if(typeof this._h>"u"){const t=this.getMax()-this.getMin();t===0?this._h=0:this._h=_r(60*(this.r===this.getMax()?(this.g-this.b)/t+(this.g<this.b?6:0):this.g===this.getMax()?(this.b-this.r)/t+2:(this.r-this.g)/t+4));}return this._h}getSaturation(){return this.getHSVSaturation()}getHSVSaturation(){if(typeof this._hsv_s>"u"){const t=this.getMax()-this.getMin();t===0?this._hsv_s=0:this._hsv_s=t/this.getMax();}return this._hsv_s}getHSLSaturation(){if(typeof this._hsl_s>"u"){const t=this.getMax()-this.getMin();if(t===0)this._hsl_s=0;else {const n=this.getLightness();this._hsl_s=t/255/(1-Math.abs(2*n-1));}}return this._hsl_s}getLightness(){return typeof this._l>"u"&&(this._l=(this.getMax()+this.getMin())/510),this._l}getValue(){return typeof this._v>"u"&&(this._v=this.getMax()/255),this._v}getBrightness(){return typeof this._brightness>"u"&&(this._brightness=(this.r*299+this.g*587+this.b*114)/1e3),this._brightness}darken(t=10){const n=this.getHue(),r=this.getSaturation();let o=this.getLightness()-t/100;return o<0&&(o=0),this._c({h:n,s:r,l:o,a:this.a})}lighten(t=10){const n=this.getHue(),r=this.getSaturation();let o=this.getLightness()+t/100;return o>1&&(o=1),this._c({h:n,s:r,l:o,a:this.a})}mix(t,n=50){const r=this._c(t),o=n/100,i=l=>(r[l]-this[l])*o+this[l],a={r:_r(i("r")),g:_r(i("g")),b:_r(i("b")),a:_r(i("a")*100)/100};return this._c(a)}tint(t=10){return this.mix({r:255,g:255,b:255,a:1},t)}shade(t=10){return this.mix({r:0,g:0,b:0,a:1},t)}onBackground(t){const n=this._c(t),r=this.a+n.a*(1-this.a),o=i=>_r((this[i]*this.a+n[i]*n.a*(1-this.a))/r);return this._c({r:o("r"),g:o("g"),b:o("b"),a:r})}isDark(){return this.getBrightness()<128}isLight(){return this.getBrightness()>=128}equals(t){return this.r===t.r&&this.g===t.g&&this.b===t.b&&this.a===t.a}clone(){return this._c(this)}toHexString(){let t="#";const n=(this.r||0).toString(16);t+=n.length===2?n:"0"+n;const r=(this.g||0).toString(16);t+=r.length===2?r:"0"+r;const o=(this.b||0).toString(16);if(t+=o.length===2?o:"0"+o,typeof this.a=="number"&&this.a>=0&&this.a<1){const i=_r(this.a*255).toString(16);t+=i.length===2?i:"0"+i;}return t}toHsl(){return {h:this.getHue(),s:this.getHSLSaturation(),l:this.getLightness(),a:this.a}}toHslString(){const t=this.getHue(),n=_r(this.getHSLSaturation()*100),r=_r(this.getLightness()*100);return this.a!==1?`hsla(${t},${n}%,${r}%,${this.a})`:`hsl(${t},${n}%,${r}%)`}toHsv(){return {h:this.getHue(),s:this.getHSVSaturation(),v:this.getValue(),a:this.a}}toRgb(){return {r:this.r,g:this.g,b:this.b,a:this.a}}toRgbString(){return this.a!==1?`rgba(${this.r},${this.g},${this.b},${this.a})`:`rgb(${this.r},${this.g},${this.b})`}toString(){return this.toRgbString()}_sc(t,n,r){const o=this.clone();return o[t]=qm(n,r),o}_c(t){return new this.constructor(t)}getMax(){return typeof this._max>"u"&&(this._max=Math.max(this.r,this.g,this.b)),this._max}getMin(){return typeof this._min>"u"&&(this._min=Math.min(this.r,this.g,this.b)),this._min}fromHexString(t){const n=t.replace("#","");function r(o,i){return parseInt(n[o]+n[i||o],16)}n.length<6?(this.r=r(0),this.g=r(1),this.b=r(2),this.a=n[3]?r(3)/255:1):(this.r=r(0,1),this.g=r(2,3),this.b=r(4,5),this.a=n[6]?r(6,7)/255:1);}fromHsl({h:t,s:n,l:r,a:o}){const i=(t%360+360)%360;if(this._h=i,this._hsl_s=n,this._l=r,this.a=typeof o=="number"?o:1,n<=0){const b=_r(r*255);this.r=b,this.g=b,this.b=b;return}let a=0,l=0,u=0;const d=i/60,m=(1-Math.abs(2*r-1))*n,p=m*(1-Math.abs(d%2-1));d>=0&&d<1?(a=m,l=p):d>=1&&d<2?(a=p,l=m):d>=2&&d<3?(l=m,u=p):d>=3&&d<4?(l=p,u=m):d>=4&&d<5?(a=p,u=m):d>=5&&d<6&&(a=m,u=p);const g=r-m/2;this.r=_r((a+g)*255),this.g=_r((l+g)*255),this.b=_r((u+g)*255);}fromHsv({h:t,s:n,v:r,a:o}){const i=(t%360+360)%360;this._h=i,this._hsv_s=n,this._v=r,this.a=typeof o=="number"?o:1;const a=_r(r*255);if(this.r=a,this.g=a,this.b=a,n<=0)return;const l=i/60,u=Math.floor(l),d=l-u,m=_r(r*(1-n)*255),p=_r(r*(1-n*d)*255),g=_r(r*(1-n*(1-d))*255);switch(u){case 0:this.g=g,this.b=m;break;case 1:this.r=p,this.b=m;break;case 2:this.r=m,this.b=g;break;case 3:this.r=m,this.g=p;break;case 4:this.r=g,this.g=m;break;default:this.g=m,this.b=p;break}}fromHsvString(t){const n=Mx(t,iI);this.fromHsv({h:n[0],s:n[1],v:n[2],a:n[3]});}fromHslString(t){const n=Mx(t,iI);this.fromHsl({h:n[0],s:n[1],l:n[2],a:n[3]});}fromRgbString(t){const n=Mx(t,(r,o)=>o.includes("%")?_r(r/100*255):r);this.r=n[0],this.g=n[1],this.b=n[2],this.a=n[3];}}const Jv=2,aI=.16,Fee=.05,Hee=.05,Vee=.15,wz=5,$z=4,jee=[{index:7,amount:15},{index:6,amount:25},{index:5,amount:30},{index:5,amount:45},{index:5,amount:65},{index:5,amount:85},{index:4,amount:90},{index:3,amount:95},{index:2,amount:97},{index:1,amount:98}];function sI(e,t,n){let r;return Math.round(e.h)>=60&&Math.round(e.h)<=240?r=n?Math.round(e.h)-Jv*t:Math.round(e.h)+Jv*t:r=n?Math.round(e.h)+Jv*t:Math.round(e.h)-Jv*t,r<0?r+=360:r>=360&&(r-=360),r}function lI(e,t,n){if(e.h===0&&e.s===0)return e.s;let r;return n?r=e.s-aI*t:t===$z?r=e.s+aI:r=e.s+Fee*t,r>1&&(r=1),n&&t===wz&&r>.1&&(r=.1),r<.06&&(r=.06),Math.round(r*100)/100}function cI(e,t,n){let r;return n?r=e.v+Hee*t:r=e.v-Vee*t,r=Math.max(0,Math.min(1,r)),Math.round(r*100)/100}function qp(e,t={}){const n=[],r=new cn(e),o=r.toHsv();for(let i=wz;i>0;i-=1){const a=new cn({h:sI(o,i,true),s:lI(o,i,true),v:cI(o,i,true)});n.push(a);}n.push(r);for(let i=1;i<=$z;i+=1){const a=new cn({h:sI(o,i),s:lI(o,i),v:cI(o,i)});n.push(a);}return t.theme==="dark"?jee.map(({index:i,amount:a})=>new cn(t.backgroundColor||"#141414").mix(n[i],a).toHexString()):n.map(i=>i.toHexString())}const Rx={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},h2=["#fff1f0","#ffccc7","#ffa39e","#ff7875","#ff4d4f","#f5222d","#cf1322","#a8071a","#820014","#5c0011"];h2.primary=h2[5];const p2=["#fff2e8","#ffd8bf","#ffbb96","#ff9c6e","#ff7a45","#fa541c","#d4380d","#ad2102","#871400","#610b00"];p2.primary=p2[5];const g2=["#fff7e6","#ffe7ba","#ffd591","#ffc069","#ffa940","#fa8c16","#d46b08","#ad4e00","#873800","#612500"];g2.primary=g2[5];const v2=["#fffbe6","#fff1b8","#ffe58f","#ffd666","#ffc53d","#faad14","#d48806","#ad6800","#874d00","#613400"];v2.primary=v2[5];const b2=["#feffe6","#ffffb8","#fffb8f","#fff566","#ffec3d","#fadb14","#d4b106","#ad8b00","#876800","#614700"];b2.primary=b2[5];const y2=["#fcffe6","#f4ffb8","#eaff8f","#d3f261","#bae637","#a0d911","#7cb305","#5b8c00","#3f6600","#254000"];y2.primary=y2[5];const S2=["#f6ffed","#d9f7be","#b7eb8f","#95de64","#73d13d","#52c41a","#389e0d","#237804","#135200","#092b00"];S2.primary=S2[5];const C2=["#e6fffb","#b5f5ec","#87e8de","#5cdbd3","#36cfc9","#13c2c2","#08979c","#006d75","#00474f","#002329"];C2.primary=C2[5];const N0=["#e6f4ff","#bae0ff","#91caff","#69b1ff","#4096ff","#1677ff","#0958d9","#003eb3","#002c8c","#001d66"];N0.primary=N0[5];const x2=["#f0f5ff","#d6e4ff","#adc6ff","#85a5ff","#597ef7","#2f54eb","#1d39c4","#10239e","#061178","#030852"];x2.primary=x2[5];const w2=["#f9f0ff","#efdbff","#d3adf7","#b37feb","#9254de","#722ed1","#531dab","#391085","#22075e","#120338"];w2.primary=w2[5];const $2=["#fff0f6","#ffd6e7","#ffadd2","#ff85c0","#f759ab","#eb2f96","#c41d7f","#9e1068","#780650","#520339"];$2.primary=$2[5];const E2=["#a6a6a6","#999999","#8c8c8c","#808080","#737373","#666666","#404040","#1a1a1a","#000000","#000000"];E2.primary=E2[5];const Tx={red:h2,volcano:p2,orange:g2,gold:v2,yellow:b2,lime:y2,green:S2,cyan:C2,blue:N0,geekblue:x2,purple:w2,magenta:$2,grey:E2};function Ez(e,{generateColorPalettes:t,generateNeutralColorPalettes:n}){const{colorSuccess:r,colorWarning:o,colorError:i,colorInfo:a,colorPrimary:l,colorBgBase:u,colorTextBase:d}=e,m=t(l),p=t(r),g=t(o),b=t(i),y=t(a),S=n(u,d),C=e.colorLink||e.colorInfo,w=t(C),$=new cn(b[1]).mix(new cn(b[3]),50).toHexString(),M={};return Wa.forEach(T=>{const R=e[T];if(R){const I=t(R);M[`${T}Hover`]=I[5],M[`${T}Active`]=I[7];}}),{...S,colorPrimaryBg:m[1],colorPrimaryBgHover:m[2],colorPrimaryBorder:m[3],colorPrimaryBorderHover:m[4],colorPrimaryHover:m[5],colorPrimary:m[6],colorPrimaryActive:m[7],colorPrimaryTextHover:m[8],colorPrimaryText:m[9],colorPrimaryTextActive:m[10],colorSuccessBg:p[1],colorSuccessBgHover:p[2],colorSuccessBorder:p[3],colorSuccessBorderHover:p[4],colorSuccessHover:p[4],colorSuccess:p[6],colorSuccessActive:p[7],colorSuccessTextHover:p[8],colorSuccessText:p[9],colorSuccessTextActive:p[10],colorErrorBg:b[1],colorErrorBgHover:b[2],colorErrorBgFilledHover:$,colorErrorBgActive:b[3],colorErrorBorder:b[3],colorErrorBorderHover:b[4],colorErrorHover:b[5],colorError:b[6],colorErrorActive:b[7],colorErrorTextHover:b[8],colorErrorText:b[9],colorErrorTextActive:b[10],colorWarningBg:g[1],colorWarningBgHover:g[2],colorWarningBorder:g[3],colorWarningBorderHover:g[4],colorWarningHover:g[4],colorWarning:g[6],colorWarningActive:g[7],colorWarningTextHover:g[8],colorWarningText:g[9],colorWarningTextActive:g[10],colorInfoBg:y[1],colorInfoBgHover:y[2],colorInfoBorder:y[3],colorInfoBorderHover:y[4],colorInfoHover:y[4],colorInfo:y[6],colorInfoActive:y[7],colorInfoTextHover:y[8],colorInfoText:y[9],colorInfoTextActive:y[10],colorLinkHover:w[4],colorLink:w[6],colorLinkActive:w[7],...M,colorBgMask:new cn("#000").setA(.45).toRgbString(),colorWhite:"#fff"}}const Uee=e=>{let t=e,n=e,r=e,o=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?n=4:e<8&&e>=7?n=5:e<14&&e>=8?n=6:e<16&&e>=14?n=7:e>=16&&(n=8),e<6&&e>=2?r=1:e>=6&&(r=2),e>4&&e<8?o=4:e>=8&&(o=6),{borderRadius:e,borderRadiusXS:r,borderRadiusSM:n,borderRadiusLG:t,borderRadiusOuter:o}};function Wee(e){const{motionUnit:t,motionBase:n,borderRadius:r,lineWidth:o}=e;return {motionDurationFast:`${(n+t).toFixed(1)}s`,motionDurationMid:`${(n+t*2).toFixed(1)}s`,motionDurationSlow:`${(n+t*3).toFixed(1)}s`,lineWidthBold:o+1,...Uee(r)}}const Mz=e=>{const{controlHeight:t}=e;return {controlHeightSM:t*.75,controlHeightXS:t*.5,controlHeightLG:t*1.25}},Rz=e=>{const t=Lee(e),n=t.map(m=>m.size),r=t.map(m=>m.lineHeight),o=n[1],i=n[0],a=n[2],l=r[1],u=r[0],d=r[2];return {fontSizeSM:i,fontSize:o,fontSizeLG:a,fontSizeXL:n[3],fontSizeHeading1:n[6],fontSizeHeading2:n[5],fontSizeHeading3:n[4],fontSizeHeading4:n[3],fontSizeHeading5:n[2],lineHeight:l,lineHeightLG:d,lineHeightSM:u,fontHeight:Math.round(l*o),fontHeightLG:Math.round(d*a),fontHeightSM:Math.round(u*i),lineHeightHeading1:r[6],lineHeightHeading2:r[5],lineHeightHeading3:r[4],lineHeightHeading4:r[3],lineHeightHeading5:r[2]}};function Gee(e){const{sizeUnit:t,sizeStep:n}=e;return {sizeXXL:t*(n+8),sizeXL:t*(n+4),sizeLG:t*(n+2),sizeMD:t*(n+1),sizeMS:t*n,size:t*n,sizeSM:t*(n-1),sizeXS:t*(n-2),sizeXXS:t*(n-3)}}const Bi=(e,t)=>new cn(e).setA(t).toRgbString(),pd=(e,t)=>new cn(e).darken(t).toHexString(),qee=e=>{const t=qp(e);return {1:t[0],2:t[1],3:t[2],4:t[3],5:t[4],6:t[5],7:t[6],8:t[4],9:t[5],10:t[6]}},Kee=(e,t)=>{const n=e||"#fff",r=t||"#000";return {colorBgBase:n,colorTextBase:r,colorText:Bi(r,.88),colorTextSecondary:Bi(r,.65),colorTextTertiary:Bi(r,.45),colorTextQuaternary:Bi(r,.25),colorFill:Bi(r,.15),colorFillSecondary:Bi(r,.06),colorFillTertiary:Bi(r,.04),colorFillQuaternary:Bi(r,.02),colorBgSolid:Bi(r,1),colorBgSolidHover:Bi(r,.75),colorBgSolidActive:Bi(r,.95),colorBgLayout:pd(n,4),colorBgContainer:pd(n,0),colorBgElevated:pd(n,0),colorBgSpotlight:Bi(r,.85),colorBgBlur:"transparent",colorBorder:pd(n,15),colorBorderDisabled:pd(n,15),colorBorderSecondary:pd(n,6)}};function Ky(e){Rx.pink=Rx.magenta,Tx.pink=Tx.magenta;const t=Object.keys(qM).map(n=>{const r=e[n]===Rx[n]?Tx[n]:qp(e[n]);return Array.from({length:10},()=>1).reduce((o,i,a)=>(o[`${n}-${a+1}`]=r[a],o[`${n}${a+1}`]=r[a],o),{})}).reduce((n,r)=>(n={...n,...r},n),{});return {...e,...t,...Ez(e,{generateColorPalettes:qee,generateNeutralColorPalettes:Kee}),...Rz(e.fontSize),...Gee(e),...Mz(e),...Wee(e)}}const KM=A0(Ky),cp={token:sf,override:{override:sf},hashed:true},YM=q.createContext(cp);function Ax(e){return e>=0&&e<=255}function bh(e,t){const{r:n,g:r,b:o,a:i}=new cn(e).toRgb();if(i<1)return e;const{r:a,g:l,b:u}=new cn(t).toRgb();for(let d=.01;d<=1;d+=.01){const m=Math.round((n-a*(1-d))/d),p=Math.round((r-l*(1-d))/d),g=Math.round((o-u*(1-d))/d);if(Ax(m)&&Ax(p)&&Ax(g))return new cn({r:m,g:p,b:g,a:Math.round(d*100)/100}).toRgbString()}return new cn({r:n,g:r,b:o,a:1}).toRgbString()}function Tz(e){const{override:t,...n}=e,r={...t};Object.keys(sf).forEach(b=>{delete r[b];});const o={...n,...r},i=480,a=576,l=768,u=992,d=1200,m=1600,p=1920;return o.motion===false&&(o.motionDurationFast="0s",o.motionDurationMid="0s",o.motionDurationSlow="0s"),{...o,colorFillContent:o.colorFillSecondary,colorFillContentHover:o.colorFill,colorFillAlter:o.colorFillQuaternary,colorBgContainerDisabled:o.colorFillTertiary,colorBorderBg:o.colorBgContainer,colorSplit:bh(o.colorBorderSecondary,o.colorBgContainer),colorTextPlaceholder:o.colorTextQuaternary,colorTextDisabled:o.colorTextQuaternary,colorTextHeading:o.colorText,colorTextLabel:o.colorTextSecondary,colorTextDescription:o.colorTextTertiary,colorTextLightSolid:o.colorWhite,colorHighlight:o.colorError,colorBgTextHover:o.colorFillSecondary,colorBgTextActive:o.colorFill,colorIcon:o.colorTextTertiary,colorIconHover:o.colorText,colorErrorOutline:bh(o.colorErrorBg,o.colorBgContainer),colorWarningOutline:bh(o.colorWarningBg,o.colorBgContainer),fontSizeIcon:o.fontSizeSM,lineWidthFocus:o.lineWidth*3,lineWidth:o.lineWidth,controlOutlineWidth:o.lineWidth*2,controlInteractiveSize:o.controlHeight/2,controlItemBgHover:o.colorFillTertiary,controlItemBgActive:o.colorPrimaryBg,controlItemBgActiveHover:o.colorPrimaryBgHover,controlItemBgActiveDisabled:o.colorFill,controlTmpOutline:o.colorFillQuaternary,controlOutline:bh(o.colorPrimaryBg,o.colorBgContainer),lineType:o.lineType,borderRadius:o.borderRadius,borderRadiusXS:o.borderRadiusXS,borderRadiusSM:o.borderRadiusSM,borderRadiusLG:o.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:o.sizeXXS,paddingXS:o.sizeXS,paddingSM:o.sizeSM,padding:o.size,paddingMD:o.sizeMD,paddingLG:o.sizeLG,paddingXL:o.sizeXL,paddingContentHorizontalLG:o.sizeLG,paddingContentVerticalLG:o.sizeMS,paddingContentHorizontal:o.sizeMS,paddingContentVertical:o.sizeSM,paddingContentHorizontalSM:o.size,paddingContentVerticalSM:o.sizeXS,marginXXS:o.sizeXXS,marginXS:o.sizeXS,marginSM:o.sizeSM,margin:o.size,marginMD:o.sizeMD,marginLG:o.sizeLG,marginXL:o.sizeXL,marginXXL:o.sizeXXL,boxShadow:`
0 6px 16px 0 rgba(0, 0, 0, 0.08),
0 3px 6px -4px rgba(0, 0, 0, 0.12),
0 9px 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowSecondary:`
0 6px 16px 0 rgba(0, 0, 0, 0.08),
0 3px 6px -4px rgba(0, 0, 0, 0.12),
0 9px 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowTertiary:`
0 1px 2px 0 rgba(0, 0, 0, 0.03),
0 1px 6px -1px rgba(0, 0, 0, 0.02),
0 2px 4px 0 rgba(0, 0, 0, 0.02)
`,screenXS:i,screenXSMin:i,screenXSMax:a-1,screenSM:a,screenSMMin:a,screenSMMax:l-1,screenMD:l,screenMDMin:l,screenMDMax:u-1,screenLG:u,screenLGMin:u,screenLGMax:d-1,screenXL:d,screenXLMin:d,screenXLMax:m-1,screenXXL:m,screenXXLMin:m,screenXXLMax:p-1,screenXXXL:p,screenXXXLMin:p,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:`
0 1px 2px -2px ${new cn("rgba(0, 0, 0, 0.16)").toRgbString()},
0 3px 6px 0 ${new cn("rgba(0, 0, 0, 0.12)").toRgbString()},
0 5px 12px 4px ${new cn("rgba(0, 0, 0, 0.09)").toRgbString()}
`,boxShadowDrawerRight:`
-6px 0 16px 0 rgba(0, 0, 0, 0.08),
-3px 0 6px -4px rgba(0, 0, 0, 0.12),
-9px 0 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowDrawerLeft:`
6px 0 16px 0 rgba(0, 0, 0, 0.08),
3px 0 6px -4px rgba(0, 0, 0, 0.12),
9px 0 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowDrawerUp:`
0 6px 16px 0 rgba(0, 0, 0, 0.08),
0 3px 6px -4px rgba(0, 0, 0, 0.12),
0 9px 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowDrawerDown:`
0 -6px 16px 0 rgba(0, 0, 0, 0.08),
0 -3px 6px -4px rgba(0, 0, 0, 0.12),
0 -9px 28px 8px rgba(0, 0, 0, 0.05)
`,boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)",...r}}const Az={lineHeight:true,lineHeightSM:true,lineHeightLG:true,lineHeightHeading1:true,lineHeightHeading2:true,lineHeightHeading3:true,lineHeightHeading4:true,lineHeightHeading5:true,opacityLoading:true,fontWeightStrong:true,zIndexPopupBase:true,zIndexBase:true,opacityImage:true},Yee={motionBase:true,motionUnit:true},Xee={screenXS:true,screenXSMin:true,screenXSMax:true,screenSM:true,screenSMMin:true,screenSMMax:true,screenMD:true,screenMDMin:true,screenMDMax:true,screenLG:true,screenLGMin:true,screenLGMax:true,screenXL:true,screenXLMin:true,screenXLMax:true,screenXXL:true,screenXXLMin:true},Nz=(e,t,n)=>{const r=n.getDerivativeToken(e),{override:o,...i}=t;let a={...r,override:o};return a=Tz(a),i&&Object.entries(i).forEach(([l,u])=>{const{theme:d,...m}=u;let p=m;d&&(p=Nz({...a,...m},{override:m},d)),a[l]=p;}),a};function jr(){const{token:e,hashed:t,theme:n,override:r,cssVar:o,zeroRuntime:i}=q.useContext(YM),a={prefix:o?.prefix??"ant",key:o?.key??"css-var-root"},l=`${zee}-${t||""}`,u=n||KM,[d,m,p]=KJ(u,[sf,e],{salt:l,override:r,getComputedToken:Nz,cssVar:{...a,unitless:Az,ignore:Yee,preserve:Xee}});return [u,p,t?m:"",d,a,!!i]}const Ga={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},dn=(e,t=false)=>({boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:t?"inherit":e.fontFamily}),Cu=()=>({display:"inline-flex",alignItems:"center",color:"inherit",fontStyle:"normal",lineHeight:0,textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizeLegibility","-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale","> *":{lineHeight:1},svg:{display:"inline-block"}}),P0=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),Qee=e=>({a:{color:e.colorLink,textDecoration:e.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:`color ${e.motionDurationSlow}`,"-webkit-text-decoration-skip":"objects","&:hover":{color:e.colorLinkHover},"&:active":{color:e.colorLinkActive},"&:active, &:hover":{textDecoration:e.linkHoverDecoration,outline:0},"&:focus":{textDecoration:e.linkFocusDecoration,outline:0},"&[disabled]":{color:e.colorTextDisabled,cursor:"not-allowed"}}}),Zee=(e,t,n,r)=>{const o=`[class^="${t}"], [class*=" ${t}"]`,i=n?`.${n}`:o,a={boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}};let l={};return r!==false&&(l={fontFamily:e.fontFamily,fontSize:e.fontSize}),{[i]:{...l,...a,[o]:a}}},ba=(e,t)=>({outline:`${oe(e.lineWidthFocus)} solid ${e.colorPrimaryBorder}`,outlineOffset:t??1,transition:["outline-offset","outline"].map(n=>`${n} 0s`).join(", ")}),$i=(e,t)=>({"&:focus-visible":ba(e,t)}),Pz=e=>({[`.${e}`]:{...Cu(),[`.${e} .${e}-icon`]:{display:"block"}}}),Jee=e=>({color:e.colorLink,textDecoration:e.linkDecoration,outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,border:0,padding:0,background:"none",userSelect:"none",...$i(e),"&:hover":{color:e.colorLinkHover,textDecoration:e.linkHoverDecoration},"&:focus":{color:e.colorLinkHover,textDecoration:e.linkFocusDecoration},"&:active":{color:e.colorLinkActive,textDecoration:e.linkHoverDecoration}}),{genStyleHooks:Wt,genComponentStyleHook:ete,genSubStyleComponent:Nf}=Bee({usePrefix:()=>{const{getPrefixCls:e,iconPrefixCls:t}=f.useContext(wt);return {rootPrefixCls:e(),iconPrefixCls:t}},useToken:()=>{const[e,t,n,r,o,i]=jr();return {theme:e,realToken:t,hashId:n,token:r,cssVar:o,zeroRuntime:i}},useCSP:()=>{const{csp:e}=f.useContext(wt);return e??{}},getResetStyles:(e,t)=>{const n=Qee(e);return [n,{"&":n},Pz(t?.prefix.iconPrefixCls??jy)]},getCommonStyle:Zee,getCompUnitless:()=>Az}),tr=(e,t)=>{const n=`--${e.replace(/\./g,"")}-${t}-`;return [i=>`${n}${i}`,(i,a)=>a?`var(${n}${i}, ${a})`:`var(${n}${i})`]};function Yy(e,t){return Wa.reduce((n,r)=>{const o=e[`${r}1`],i=e[`${r}3`],a=e[`${r}6`],l=e[`${r}7`];return {...n,...t(r,{lightColor:o,lightBorderColor:i,darkColor:a,textColor:l})}},{})}const tte=(e,t)=>(jr(),f2({hashId:"",path:["ant-design-icons",e],nonce:()=>t?.nonce,layer:{name:"antd"}},()=>Pz(e)));var nte={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"};const XM=f.createContext({});function Iz(e){return e?.getRootNode?.()}function rte(e){return Iz(e)instanceof ShadowRoot}function I0(e){return rte(e)?Iz(e):null}function ote(e){return e.replace(/-(.)/g,(t,n)=>n.toUpperCase())}function ite(e,t){Er(e,`[@ant-design/icons] ${t}`);}function uI(e){return typeof e=="object"&&typeof e.name=="string"&&typeof e.theme=="string"&&(typeof e.icon=="object"||typeof e.icon=="function")}function dI(e={}){return Object.keys(e).reduce((t,n)=>{const r=e[n];return n==="class"?(t.className=r,delete t.class):(delete t[n],t[ote(n)]=r),t},{})}function M2(e,t,n){return n?q.createElement(e.tag,{key:t,...dI(e.attrs),...n},(e.children||[]).map((r,o)=>M2(r,`${t}-${e.tag}-${o}`))):q.createElement(e.tag,{key:t,...dI(e.attrs)},(e.children||[]).map((r,o)=>M2(r,`${t}-${e.tag}-${o}`)))}function Oz(e){return qp(e)[0]}function Dz(e){return e?Array.isArray(e)?e:[e]:[]}const ate=`
.anticon {
display: inline-flex;
align-items: center;
color: inherit;
font-style: normal;
line-height: 0;
text-align: center;
text-transform: none;
vertical-align: -0.125em;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.anticon > * {
line-height: 1;
}
.anticon svg {
display: inline-block;
vertical-align: inherit;
}
.anticon::before {
display: none;
}
.anticon .anticon-icon {
display: block;
}
.anticon[tabindex] {
cursor: pointer;
}
.anticon-spin::before,
.anticon-spin {
display: inline-block;
-webkit-animation: loadingCircle 1s infinite linear;
animation: loadingCircle 1s infinite linear;
}
@-webkit-keyframes loadingCircle {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes loadingCircle {
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
`,ste=e=>{const{csp:t,prefixCls:n,layer:r}=f.useContext(XM);let o=ate;n&&(o=o.replace(/anticon/g,n)),r&&(o=`@layer ${r} {
${o}
}`),f.useEffect(()=>{const i=e.current,a=I0(i);_l(o,"@ant-design-icons",{prepend:!r,csp:t,attachTo:a});},[]);},Ph={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:false};function lte({primaryColor:e,secondaryColor:t}){Ph.primaryColor=e,Ph.secondaryColor=t||Oz(e),Ph.calculated=!!t;}function cte(){return {...Ph}}const Pf=e=>{const{icon:t,className:n,onClick:r,style:o,primaryColor:i,secondaryColor:a,...l}=e,u=f.useRef(null);let d=Ph;if(i&&(d={primaryColor:i,secondaryColor:a||Oz(i)}),ste(u),ite(uI(t),`icon should be icon definiton, but got ${t}`),!uI(t))return null;let m=t;return m&&typeof m.icon=="function"&&(m={...m,icon:m.icon(d.primaryColor,d.secondaryColor)}),M2(m.icon,`svg-${m.name}`,{className:n,onClick:r,style:o,"data-icon":m.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true",...l,ref:u})};Pf.displayName="IconReact";Pf.getTwoToneColors=cte;Pf.setTwoToneColors=lte;function _z(e){const[t,n]=Dz(e);return Pf.setTwoToneColors({primaryColor:t,secondaryColor:n})}function ute(){const e=Pf.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor}function R2(){return R2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},R2.apply(this,arguments)}_z(N0.primary);const Xn=f.forwardRef((e,t)=>{const{className:n,icon:r,spin:o,rotate:i,tabIndex:a,onClick:l,twoToneColor:u,...d}=e,{prefixCls:m="anticon",rootClassName:p}=f.useContext(XM),g=X(p,m,{[`${m}-${r.name}`]:!!r.name,[`${m}-spin`]:!!o||r.name==="loading"},n);let b=a;b===void 0&&l&&(b=-1);const y=i?{msTransform:`rotate(${i}deg)`,transform:`rotate(${i}deg)`}:void 0,[S,C]=Dz(u);return f.createElement("span",R2({role:"img","aria-label":r.name},d,{ref:t,tabIndex:b,onClick:l,className:g}),f.createElement(Pf,{icon:r,primaryColor:S,secondaryColor:C,style:y}))});Xn.getTwoToneColor=ute;Xn.setTwoToneColor=_z;function T2(){return T2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},T2.apply(this,arguments)}const dte=(e,t)=>f.createElement(Xn,T2({},e,{ref:t,icon:nte})),QM=f.forwardRef(dte);var fte={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"}}]},name:"close-circle",theme:"filled"};function A2(){return A2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},A2.apply(this,arguments)}const mte=(e,t)=>f.createElement(Xn,A2({},e,{ref:t,icon:fte})),Kp=f.forwardRef(mte);var hte={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"};function N2(){return N2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},N2.apply(this,arguments)}const pte=(e,t)=>f.createElement(Xn,N2({},e,{ref:t,icon:hte})),Ls=f.forwardRef(pte);var gte={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"};function P2(){return P2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},P2.apply(this,arguments)}const vte=(e,t)=>f.createElement(Xn,P2({},e,{ref:t,icon:gte})),Yp=f.forwardRef(vte);var bte={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"};function I2(){return I2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},I2.apply(this,arguments)}const yte=(e,t)=>f.createElement(Xn,I2({},e,{ref:t,icon:bte})),ZM=f.forwardRef(yte),Bz=f.createContext({});function Ste({children:e,...t}){return f.createElement(Bz.Provider,{value:t},e)}function Cte(e){const[,t]=f.useReducer(i=>i+1,0),n=f.useRef(e),r=Mt(()=>n.current),o=Mt(i=>{n.current=typeof i=="function"?i(n.current):i,t();});return [r,o]}const ys="none",eb="appear",tb="enter",nb="leave",fI="none",sa="prepare",Id="start",Od="active",JM="end",Lz="prepared";function mI(e,t){const n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit${e}`]=`webkit${t}`,n[`Moz${e}`]=`moz${t}`,n[`ms${e}`]=`MS${t}`,n[`O${e}`]=`o${t.toLowerCase()}`,n}function xte(e,t){const n={animationend:mI("Animation","AnimationEnd"),transitionend:mI("Transition","TransitionEnd")};return e&&("AnimationEvent"in t||delete n.animationend.animation,"TransitionEvent"in t||delete n.transitionend.transition),n}const wte=xte(wi(),typeof window<"u"?window:{});let zz={};wi()&&({style:zz}=document.createElement("div"));const rb={};function kz(e){if(rb[e])return rb[e];const t=wte[e];if(t){const n=Object.keys(t),r=n.length;for(let o=0;o<r;o+=1){const i=n[o];if(Object.prototype.hasOwnProperty.call(t,i)&&i in zz)return rb[e]=t[i],rb[e]}}return ""}const Fz=kz("animationend"),Hz=kz("transitionend"),$te=!!(Fz&&Hz),hI=Fz||"animationend",pI=Hz||"transitionend";function gI(e,t){if(!e)return null;if(typeof e=="object"){const n=t.replace(/-\w/g,r=>r[1].toUpperCase());return e[n]}return `${e}-${t}`}const Ete=(e=>{const t=f.useRef();function n(o){o&&(o.removeEventListener(pI,e),o.removeEventListener(hI,e));}function r(o){t.current&&t.current!==o&&n(t.current),o&&o!==t.current&&(o.addEventListener(pI,e),o.addEventListener(hI,e),t.current=o);}return f.useEffect(()=>()=>{n(t.current),t.current=null;},[]),[r,n]}),Vz=wi()?f.useLayoutEffect:f.useEffect,Mte=(()=>{const e=f.useRef(null);function t(){Lt.cancel(e.current);}function n(r,o=2){t();const i=Lt(()=>{o<=1?r({isCanceled:()=>i!==e.current}):n(r,o-1);});e.current=i;}return f.useEffect(()=>()=>{t();},[]),[n,t]}),Rte=[sa,Id,Od,JM],Tte=[sa,Lz],jz=false,Ate=true;function Uz(e){return e===Od||e===JM}const Nte=((e,t,n)=>{const[r,o]=R0(fI),[i,a]=Mte();function l(){o(sa,true);}const u=t?Tte:Rte;return Vz(()=>{if(r!==fI&&r!==JM){const d=u.indexOf(r),m=u[d+1],p=n(r);p===jz?o(m,true):m&&i(g=>{function b(){g.isCanceled()||o(m,true);}p===true?b():Promise.resolve(p).then(b);});}},[e,r]),f.useEffect(()=>()=>{a();},[]),[l,r]});function Pte(e,t,n,{motionEnter:r=true,motionAppear:o=true,motionLeave:i=true,motionDeadline:a,motionLeaveImmediately:l,onAppearPrepare:u,onEnterPrepare:d,onLeavePrepare:m,onAppearStart:p,onEnterStart:g,onLeaveStart:b,onAppearActive:y,onEnterActive:S,onLeaveActive:C,onAppearEnd:w,onEnterEnd:$,onLeaveEnd:M,onVisibleChanged:T}){const[R,I]=R0(),[N,P]=Cte(ys),[O,_]=R0(null),B=N(),V=f.useRef(false),U=f.useRef(null);function G(){return n()}const H=f.useRef(false);function z(){P(ys),_(null,true);}const j=Mt(re=>{const ie=N();if(ie===ys)return;const de=G();if(re&&!re.deadline&&re.target!==de)return;const ne=H.current;let ce;ie===eb&&ne?ce=w?.(de,re):ie===tb&&ne?ce=$?.(de,re):ie===nb&&ne&&(ce=M?.(de,re)),ne&&ce!==false&&z();}),[W]=Ete(j),Y=re=>{switch(re){case eb:return {[sa]:u,[Id]:p,[Od]:y};case tb:return {[sa]:d,[Id]:g,[Od]:S};case nb:return {[sa]:m,[Id]:b,[Od]:C};default:return {}}},Q=f.useMemo(()=>Y(B),[B]),[D,L]=Nte(B,!e,re=>{if(re===sa){const ie=Q[sa];return ie?ie(G()):jz}return L in Q&&_(Q[L]?.(G(),null)||null),L===Od&&B!==ys&&(W(G()),a>0&&(clearTimeout(U.current),U.current=setTimeout(()=>{j({deadline:true});},a))),L===Lz&&z(),Ate}),K=Uz(L);H.current=K;const J=f.useRef(null);Vz(()=>{if(V.current&&J.current===t)return;I(t);const re=V.current;V.current=true;let ie;!re&&t&&o&&(ie=eb),re&&t&&r&&(ie=tb),(re&&!t&&i||!re&&l&&!t&&i)&&(ie=nb);const de=Y(ie);ie&&(e||de[sa])?(P(ie),D()):P(ys),J.current=t;},[t]),f.useEffect(()=>{(B===eb&&!o||B===tb&&!r||B===nb&&!i)&&P(ys);},[o,r,i]),f.useEffect(()=>()=>{V.current=false,clearTimeout(U.current);},[]);const ee=f.useRef(false);f.useEffect(()=>{R&&(ee.current=true),R!==void 0&&B===ys&&((ee.current||R)&&T?.(R),ee.current=true);},[R,B]);let te=O;return Q[sa]&&L===Id&&(te={transition:"none",...te}),[N,L,te,R??t]}function Ite(e){let t=e;typeof e=="object"&&({transitionSupport:t}=e);function n(o,i){return !!(o.motionName&&t&&i!==false)}const r=f.forwardRef((o,i)=>{const{visible:a=true,removeOnLeave:l=true,forceRender:u,children:d,motionName:m,leavedClassName:p,eventProps:g}=o,{motion:b}=f.useContext(Bz),y=n(o,b),S=f.useRef();function C(){return of(S.current)}const[w,$,M,T]=Pte(y,a,C,o),R=w(),I=f.useRef(T);T&&(I.current=true);const N=f.useMemo(()=>{const _={};return Object.defineProperties(_,{nativeElement:{enumerable:true,get:C},inMotion:{enumerable:true,get:()=>()=>w()!==ys},enableMotion:{enumerable:true,get:()=>()=>y}}),_},[]);f.useImperativeHandle(i,()=>N,[]);let P;const O={...g,visible:a};if(!d)P=null;else if(R===ys)T?P=d({...O},S):!l&&I.current&&p?P=d({...O,className:p},S):u||!l&&!p?P=d({...O,style:{display:"none"}},S):P=null;else {let _;$===sa?_="prepare":Uz($)?_="active":$===Id&&(_="start");const B=gI(m,`${R}-${_}`);P=d({...O,className:X(gI(m,R),{[B]:B&&_,[m]:typeof m=="string"}),style:M},S);}return f.isValidElement(P)&&Su(P)&&(Ql(P)||(P=f.cloneElement(P,{ref:S}))),P});return r.displayName="CSSMotion",r}const Co=Ite($te),O2="add",D2="keep",_2="remove",Nx="removed";function Ote(e){let t;return e&&typeof e=="object"&&"key"in e?t=e:t={key:e},{...t,key:String(t.key)}}function B2(e=[]){return e.map(Ote)}function Dte(e=[],t=[]){let n=[],r=0;const o=t.length,i=B2(e),a=B2(t);i.forEach(d=>{let m=false;for(let p=r;p<o;p+=1){const g=a[p];if(g.key===d.key){r<p&&(n=n.concat(a.slice(r,p).map(b=>({...b,status:O2}))),r=p),n.push({...g,status:D2}),r+=1,m=true;break}}m||n.push({...d,status:_2});}),r<o&&(n=n.concat(a.slice(r).map(d=>({...d,status:O2}))));const l={};return n.forEach(({key:d})=>{l[d]=(l[d]||0)+1;}),Object.keys(l).filter(d=>l[d]>1).forEach(d=>{n=n.filter(({key:m,status:p})=>m!==d||p!==_2),n.forEach(m=>{m.key===d&&(m.status=D2);});}),n}function L2(){return L2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},L2.apply(this,arguments)}const _te=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"];function Bte(e,t=Co){class n extends f.Component{static defaultProps={component:"div"};state={keyEntities:[]};static getDerivedStateFromProps({keys:o},{keyEntities:i}){const a=B2(o);return {keyEntities:Dte(i,a).filter(u=>{const d=i.find(({key:m})=>u.key===m);return !(d&&d.status===Nx&&u.status===_2)})}}removeKey=o=>{this.setState(i=>({keyEntities:i.keyEntities.map(l=>l.key!==o?l:{...l,status:Nx})}),()=>{const{keyEntities:i}=this.state;i.filter(({status:l})=>l!==Nx).length===0&&this.props.onAllRemoved&&this.props.onAllRemoved();});};render(){const{keyEntities:o}=this.state,{component:i,children:a,onVisibleChanged:l,onAllRemoved:u,...d}=this.props,m=i||f.Fragment,p={};return _te.forEach(g=>{p[g]=d[g],delete d[g];}),delete d.keys,f.createElement(m,d,o.map(({status:g,...b},y)=>{const S=g===O2||g===D2;return f.createElement(t,L2({},p,{key:b.key,visible:S,eventProps:b,onVisibleChanged:C=>{l?.(C,{key:b.key}),C||this.removeKey(b.key);}}),(C,w)=>a({...C,index:y},w))}))}}return n}const Lte=Bte(),zte=`accept acceptCharset accessKey action allowFullScreen allowTransparency
alt async autoComplete autoFocus autoPlay capture cellPadding cellSpacing challenge
charSet checked classID className colSpan cols content contentEditable contextMenu
controls coords crossOrigin data dateTime default defer dir disabled download draggable
encType form formAction formEncType formMethod formNoValidate formTarget frameBorder
headers height hidden high href hrefLang htmlFor httpEquiv icon id inputMode integrity
is keyParams keyType kind label lang list loop low manifest marginHeight marginWidth max maxLength media
mediaGroup method min minLength multiple muted name noValidate nonce open
optimum pattern placeholder poster preload radioGroup readOnly rel required
reversed role rowSpan rows sandbox scope scoped scrolling seamless selected
shape size sizes span spellCheck src srcDoc srcLang srcSet start step style
summary tabIndex target title type useMap value width wmode wrap`,kte=`onCopy onCut onPaste onCompositionEnd onCompositionStart onCompositionUpdate onKeyDown
onKeyPress onKeyUp onFocus onBlur onChange onInput onSubmit onClick onContextMenu onDoubleClick
onDrag onDragEnd onDragEnter onDragExit onDragLeave onDragOver onDragStart onDrop onMouseDown
onMouseEnter onMouseLeave onMouseMove onMouseOut onMouseOver onMouseUp onSelect onTouchCancel
onTouchEnd onTouchMove onTouchStart onScroll onWheel onAbort onCanPlay onCanPlayThrough
onDurationChange onEmptied onEncrypted onEnded onError onLoadedData onLoadedMetadata
onLoadStart onPause onPlay onPlaying onProgress onRateChange onSeeked onSeeking onStalled onSuspend onTimeUpdate onVolumeChange onWaiting onLoad onError`,Fte=`${zte} ${kte}`.split(/[\s\n]+/),Hte="aria-",Vte="data-";function vI(e,t){return e.indexOf(t)===0}function yo(e,t=false){let n;t===false?n={aria:true,data:true,attr:true}:t===true?n={aria:true}:n={...t};const r={};return Object.keys(e).forEach(o=>{(n.aria&&(o==="role"||vI(o,Hte))||n.data&&vI(o,Vte)||n.attr&&Fte.includes(o))&&(r[o]=e[o]);}),r}const Wz={items_per_page:"/ page",jump_to:"Go to",jump_to_confirm:"confirm",page:"Page",prev_page:"Previous Page",next_page:"Next Page",prev_5:"Previous 5 Pages",next_5:"Next 5 Pages",prev_3:"Previous 3 Pages",next_3:"Next 3 Pages",page_size:"Page Size"};var jte={yearFormat:"YYYY",dayFormat:"D",cellMeridiemFormat:"A",monthBeforeYear:true};function up(e){"@babel/helpers - typeof";return up=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},up(e)}function bI(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r);}return n}function yI(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?bI(Object(n),true).forEach(function(r){Ute(e,r,n[r]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bI(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r));});}return e}function Ute(e,t,n){return t=Wte(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:true,configurable:true,writable:true}):e[t]=n,e}function Wte(e){var t=Gte(e,"string");return up(t)=="symbol"?t:String(t)}function Gte(e,t){if(up(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(up(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return (t==="string"?String:Number)(e)}var qte=yI(yI({},jte),{},{locale:"en_US",today:"Today",now:"Now",backToToday:"Back to today",ok:"OK",clear:"Clear",week:"Week",month:"Month",year:"Year",timeSelect:"select time",dateSelect:"select date",weekSelect:"Choose a week",monthSelect:"Choose a month",yearSelect:"Choose a year",decadeSelect:"Choose a decade",previousMonth:"Previous month (PageUp)",nextMonth:"Next month (PageDown)",previousYear:"Last year (Control + left)",nextYear:"Next year (Control + right)",previousDecade:"Last decade",nextDecade:"Next decade",previousCentury:"Last century",nextCentury:"Next century"});const Gz={placeholder:"Select time",rangePlaceholder:["Start time","End time"]},SI={lang:{placeholder:"Select date",yearPlaceholder:"Select year",quarterPlaceholder:"Select quarter",monthPlaceholder:"Select month",weekPlaceholder:"Select week",rangePlaceholder:["Start date","End date"],rangeYearPlaceholder:["Start year","End year"],rangeQuarterPlaceholder:["Start quarter","End quarter"],rangeMonthPlaceholder:["Start month","End month"],rangeWeekPlaceholder:["Start week","End week"],...qte},timePickerLocale:{...Gz}},li="${label} is not a valid ${type}",ya={locale:"en",Pagination:Wz,DatePicker:SI,TimePicker:Gz,Calendar:SI,global:{placeholder:"Please select",close:"Close",sortable:"sortable"},Table:{filterTitle:"Filter menu",filterConfirm:"OK",filterReset:"Reset",filterEmptyText:"No filters",filterCheckAll:"Select all items",filterSearchPlaceholder:"Search in filters",emptyText:"No data",selectAll:"Select current page",selectInvert:"Invert current page",selectNone:"Clear all data",selectionAll:"Select all data",sortTitle:"Sort",expand:"Expand row",collapse:"Collapse row",triggerDesc:"Click to sort descending",triggerAsc:"Click to sort ascending",cancelSort:"Click to cancel sorting"},Tour:{Next:"Next",Previous:"Previous",Finish:"Finish"},Modal:{okText:"OK",cancelText:"Cancel",justOkText:"OK"},Popconfirm:{okText:"OK",cancelText:"Cancel"},Transfer:{titles:["",""],searchPlaceholder:"Search here",itemUnit:"item",itemsUnit:"items",remove:"Remove",selectCurrent:"Select current page",removeCurrent:"Remove current page",selectAll:"Select all data",deselectAll:"Deselect all data",removeAll:"Remove all data",selectInvert:"Invert current page"},Upload:{uploading:"Uploading...",removeFile:"Remove file",uploadError:"Upload error",previewFile:"Preview file",downloadFile:"Download file"},Empty:{description:"No data"},Icon:{icon:"icon"},Text:{edit:"Edit",copy:"Copy",copied:"Copied",expand:"Expand",collapse:"Collapse"},Form:{optional:"(optional)",defaultValidateMessages:{default:"Field validation error for ${label}",required:"Please enter ${label}",enum:"${label} must be one of [${enum}]",whitespace:"${label} cannot be a blank character",date:{format:"${label} date format is invalid",parse:"${label} cannot be converted to a date",invalid:"${label} is an invalid date"},types:{string:li,method:li,array:li,object:li,number:li,date:li,boolean:li,integer:li,float:li,regexp:li,email:li,url:li,hex:li},string:{len:"${label} must be ${len} characters",min:"${label} must be at least ${min} characters",max:"${label} must be up to ${max} characters",range:"${label} must be between ${min}-${max} characters"},number:{len:"${label} must be equal to ${len}",min:"${label} must be minimum ${min}",max:"${label} must be maximum ${max}",range:"${label} must be between ${min}-${max}"},array:{len:"Must be ${len} ${label}",min:"At least ${min} ${label}",max:"At most ${max} ${label}",range:"The amount of ${label} must be between ${min}-${max}"},pattern:{mismatch:"${label} does not match the pattern ${pattern}"}}},QRCode:{expired:"QR code expired",refresh:"Refresh",scanned:"Scanned"},ColorPicker:{presetEmpty:"Empty",transparent:"Transparent",singleColor:"Single",gradientColor:"Gradient"}};let Vb={...ya.Modal},jb=[];const CI=()=>jb.reduce((e,t)=>({...e,...t}),ya.Modal);function Kte(e){if(e){const t={...e};return jb.push(t),Vb=CI(),()=>{jb=jb.filter(n=>n!==t),Vb=CI();}}Vb={...ya.Modal};}function qz(){return Vb}const eR=f.createContext(void 0),Oo=(e,t)=>{const n=f.useContext(eR),r=f.useMemo(()=>{const i=t||ya[e],a=n?.[e]??{};return {...typeof i=="function"?i():i,...a||{}}},[e,t,n]),o=f.useMemo(()=>{const i=n?.locale;return n?.exist&&!i?ya.locale:i},[n]);return [r,o]},Yte="internalMark",Xte=e=>{const{locale:t={},children:n,_ANT_MARK__:r}=e;f.useEffect(()=>Kte(t?.Modal),[t]);const o=f.useMemo(()=>({...t,exist:true}),[t]);return f.createElement(eR.Provider,{value:o},n)};function xI(...e){const t={};return e.forEach(n=>{n&&Object.keys(n).forEach(r=>{n[r]!==void 0&&(t[r]=n[r]);});}),t}const Jr=e=>e!=null,kl=e=>{if(!e)return;const{closable:t,closeIcon:n}=e;return {closable:t,closeIcon:n}},Kz={},wI=(e,t)=>{if(!e&&(e===false||t===false||t===null))return false;if(e===void 0&&t===void 0)return null;let n={closeIcon:typeof t!="boolean"&&t!==null?t:void 0};return e&&typeof e=="object"&&(n={...n,...e}),n},Qte=(e,t,n)=>e===false?false:e?xI(n,t,e):t===false?false:t?xI(n,t):n.closable?n:false,Zte=(e,t,n)=>{const{closeIconRender:r}=t,{closeIcon:o,...i}=e;let a=o;const l=yo(i,true);return Jr(a)&&(r&&(a=r(a)),a=q.isValidElement(a)?q.cloneElement(a,{"aria-label":n,...a.props,...l}):q.createElement("span",{"aria-label":n,...l},a)),[a,l]},Yz=(e,t,n=Kz,r="Close")=>{const o=wI(e?.closable,e?.closeIcon),i=wI(t?.closable,t?.closeIcon),a={closeIcon:q.createElement(Ls,null),...n},l=Qte(o,i,a),u=typeof l!="boolean"?!!l?.disabled:false;if(l===false)return [false,null,u,{}];const[d,m]=Zte(l,a,r);return [true,d,u,m]},tR=(e,t,n=Kz)=>{const[r]=Oo("global",ya.global);return q.useMemo(()=>Yz(e,t,{closeIcon:q.createElement(Ls,null),...n},r.close),[e,t,n,r.close])},Xz=()=>q.useReducer(e=>e+1,0),z2=(e,t)=>{let n={};return e&&typeof e=="object"&&(n=e),typeof e=="boolean"&&(n={enabled:e}),n.closable===void 0&&t!==void 0&&(n.closable=t),n},Jte=(e,t,n,r)=>f.useMemo(()=>{const o=z2(e,r),i=z2(t),a={blur:false,...i,...o,closable:o.closable??r??i.closable??true},l=a.blur?`${n}-mask-blur`:void 0;return [a.enabled!==false,{mask:l},!!a.closable]},[e,t,n,r]),Xy=(e,...t)=>{const n=e||{};return t.filter(Boolean).reduce((r,o)=>(Object.keys(o||{}).forEach(i=>{const a=n[i],l=o[i];if(a&&typeof a=="object")if(l&&typeof l=="object")r[i]=Xy(a,r[i],l);else {const{_default:u}=a;u&&(r[i]=r[i]||{},r[i][u]=X(r[i][u],l));}else r[i]=X(r[i],l);}),r),{})},ene=(e,...t)=>f.useMemo(()=>Xy.apply(void 0,[e].concat(t)),[e].concat(t)),nR=(...e)=>e.filter(Boolean).reduce((t,n={})=>(Object.keys(n).forEach(r=>{t[r]={...t[r],...n[r]};}),t),{}),tne=(...e)=>f.useMemo(()=>nR.apply(void 0,e),[].concat(e)),k2=(e,t)=>{const n={...e};return Object.keys(t).forEach(r=>{if(r!=="_default"){const o=t[r],i=n[r]||{};n[r]=o?k2(i,o):i;}}),n},Pl=(e,t)=>typeof e=="function"?e(t):e,Kt=(e,t,n,r)=>{const o=e.map(u=>u?Pl(u,n):void 0),i=t.map(u=>u?Pl(u,n):void 0),a=ene.apply(void 0,[r].concat(qt(o))),l=tne.apply(void 0,qt(i));return f.useMemo(()=>r?[k2(a,r),k2(l,r)]:[a,l],[a,l,r])},$I=e=>{const[t,n]=f.useState(null);return [f.useCallback((o,i,a)=>{const l=t??o,u=Math.min(l||0,o),d=Math.max(l||0,o),m=i.slice(u,d+1).map(e),p=m.some(b=>!a.has(b)),g=[];return m.forEach(b=>{p?(a.has(b)||g.push(b),a.add(b)):(a.delete(b),g.push(b));}),n(p?d:null),g},[t]),n]},EI=e=>e==="horizontal"||e==="vertical",xu=(e,t,n)=>f.useMemo(()=>{const r=EI(e);let o;return r?o=e:typeof t=="boolean"?o=t?"vertical":"horizontal":o=EI(n)?n:"horizontal",[o,o==="vertical"]},[n,e,t]),nne=()=>{const[e,t]=f.useState([]),n=f.useCallback(r=>(t(o=>[].concat(qt(o),[r])),()=>{t(o=>o.filter(i=>i!==r));}),[]);return [e,n]},Qy=q.createContext(void 0),xl=100,rne=10,rR=xl*rne,Qz={Modal:xl,Drawer:xl,Popover:xl,Popconfirm:xl,Tooltip:xl,Tour:xl,FloatButton:xl},one={SelectLike:50,Dropdown:50,DatePicker:50,Menu:50,ImagePreview:1},ine=e=>e in Qz,wu=(e,t)=>{const[,n]=jr(),r=q.useContext(Qy),o=ine(e);let i;if(t!==void 0)i=[t,t];else {let a=r??0;o?a+=(r?0:n.zIndexPopupBase)+Qz[e]:a+=one[e],i=[r===void 0?t:a,a];}return i};function F2(e){return Jr(e)&&e===e.window}const Zz=e=>{if(typeof window>"u")return 0;let t=0;return F2(e)?t=e.pageYOffset:e instanceof Document?t=e.documentElement.scrollTop:(e instanceof HTMLElement||e)&&(t=e.scrollTop),e&&!F2(e)&&typeof t!="number"&&(t=(e.ownerDocument??e).documentElement?.scrollTop),t};function ane(e,t,n,r){const o=n-t;return e/=r/2,e<1?o/2*e*e*e+t:o/2*((e-=2)*e*e+2)+t}function sne(e,t={}){const{getContainer:n=()=>window,callback:r,duration:o=450}=t,i=n(),a=Zz(i),l=Date.now();let u;const d=()=>{const p=Date.now()-l,g=ane(p>o?o:p,a,e,o);F2(i)?i.scrollTo(window.pageXOffset,g):i instanceof Document||i.constructor.name==="HTMLDocument"?i.documentElement.scrollTop=g:i.scrollTop=g,p<o?u=Lt(d):typeof r=="function"&&r();};return u=Lt(d),()=>{Lt.cancel(u);}}const Qn=e=>`${e}-css-var`,lne=f.createContext(void 0);var Px={exports:{}},uo={};var MI;function cne(){if(MI)return uo;MI=1;var e=Xl();function t(u){var d="https://react.dev/errors/"+u;if(1<arguments.length){d+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)d+="&args[]="+encodeURIComponent(arguments[m]);}return "Minified React error #"+u+"; visit "+d+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(){}var r={d:{f:n,r:function(){throw Error(t(522))},D:n,C:n,L:n,m:n,X:n,S:n,M:n},p:0,findDOMNode:null},o=Symbol.for("react.portal");function i(u,d,m){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return {$$typeof:o,key:p==null?null:""+p,children:u,containerInfo:d,implementation:m}}var a=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function l(u,d){if(u==="font")return "";if(typeof d=="string")return d==="use-credentials"?d:""}return uo.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,uo.createPortal=function(u,d){var m=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!d||d.nodeType!==1&&d.nodeType!==9&&d.nodeType!==11)throw Error(t(299));return i(u,d,null,m)},uo.flushSync=function(u){var d=a.T,m=r.p;try{if(a.T=null,r.p=2,u)return u()}finally{a.T=d,r.p=m,r.d.f();}},uo.preconnect=function(u,d){typeof u=="string"&&(d?(d=d.crossOrigin,d=typeof d=="string"?d==="use-credentials"?d:"":void 0):d=null,r.d.C(u,d));},uo.prefetchDNS=function(u){typeof u=="string"&&r.d.D(u);},uo.preinit=function(u,d){if(typeof u=="string"&&d&&typeof d.as=="string"){var m=d.as,p=l(m,d.crossOrigin),g=typeof d.integrity=="string"?d.integrity:void 0,b=typeof d.fetchPriority=="string"?d.fetchPriority:void 0;m==="style"?r.d.S(u,typeof d.precedence=="string"?d.precedence:void 0,{crossOrigin:p,integrity:g,fetchPriority:b}):m==="script"&&r.d.X(u,{crossOrigin:p,integrity:g,fetchPriority:b,nonce:typeof d.nonce=="string"?d.nonce:void 0});}},uo.preinitModule=function(u,d){if(typeof u=="string")if(typeof d=="object"&&d!==null){if(d.as==null||d.as==="script"){var m=l(d.as,d.crossOrigin);r.d.M(u,{crossOrigin:m,integrity:typeof d.integrity=="string"?d.integrity:void 0,nonce:typeof d.nonce=="string"?d.nonce:void 0});}}else d==null&&r.d.M(u);},uo.preload=function(u,d){if(typeof u=="string"&&typeof d=="object"&&d!==null&&typeof d.as=="string"){var m=d.as,p=l(m,d.crossOrigin);r.d.L(u,m,{crossOrigin:p,integrity:typeof d.integrity=="string"?d.integrity:void 0,nonce:typeof d.nonce=="string"?d.nonce:void 0,type:typeof d.type=="string"?d.type:void 0,fetchPriority:typeof d.fetchPriority=="string"?d.fetchPriority:void 0,referrerPolicy:typeof d.referrerPolicy=="string"?d.referrerPolicy:void 0,imageSrcSet:typeof d.imageSrcSet=="string"?d.imageSrcSet:void 0,imageSizes:typeof d.imageSizes=="string"?d.imageSizes:void 0,media:typeof d.media=="string"?d.media:void 0});}},uo.preloadModule=function(u,d){if(typeof u=="string")if(d){var m=l(d.as,d.crossOrigin);r.d.m(u,{as:typeof d.as=="string"&&d.as!=="script"?d.as:void 0,crossOrigin:m,integrity:typeof d.integrity=="string"?d.integrity:void 0});}else r.d.m(u);},uo.requestFormReset=function(u){r.d.r(u);},uo.unstable_batchedUpdates=function(u,d){return u(d)},uo.useFormState=function(u,d,m){return a.H.useFormState(u,d,m)},uo.useFormStatus=function(){return a.H.useHostTransitionStatus()},uo.version="19.2.4",uo}var RI;function Jz(){if(RI)return Px.exports;RI=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e);}catch(t){console.error(t);}}return e(),Px.exports=cne(),Px.exports}var $o=Jz();const ek=f.createContext(null);let une=false;function dne(e){return une}const TI=[];function fne(e,t){const[n]=f.useState(()=>wi()?document.createElement("div"):null),r=f.useRef(false),o=f.useContext(ek),[i,a]=f.useState(TI),l=o||(r.current?void 0:m=>{a(p=>[m,...p]);});function u(){n.parentElement||document.body.appendChild(n),r.current=true;}function d(){n.parentElement?.removeChild(n),r.current=false;}return An(()=>(e?o?o(u):u():d(),d),[e]),An(()=>{i.length&&(i.forEach(m=>m()),a(TI));},[i]),[n,l]}function mne(e){const t=`rc-scrollbar-measure-${Math.random().toString(36).substring(7)}`,n=document.createElement("div");n.id=t;const r=n.style;r.position="absolute",r.left="0",r.top="0",r.width="100px",r.height="100px",r.overflow="scroll";let o,i;if(e){const u=getComputedStyle(e);r.scrollbarColor=u.scrollbarColor,r.scrollbarWidth=u.scrollbarWidth;const d=getComputedStyle(e,"::-webkit-scrollbar"),m=parseInt(d.width,10),p=parseInt(d.height,10);try{const g=m?`width: ${d.width};`:"",b=p?`height: ${d.height};`:"";_l(`
#${t}::-webkit-scrollbar {
${g}
${b}
}`,t);}catch(g){console.error(g),o=m,i=p;}}document.body.appendChild(n);const a=e&&o&&!isNaN(o)?o:n.offsetWidth-n.clientWidth,l=e&&i&&!isNaN(i)?i:n.offsetHeight-n.clientHeight;return document.body.removeChild(n),op(t),{width:a,height:l}}function hne(e){return typeof document>"u"||!e||!(e instanceof Element)?{width:0,height:0}:mne(e)}function pne(){return document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth}const gne=`rc-util-locker-${Date.now()}`;let AI=0;function vne(e){const t=!!e,[n]=f.useState(()=>(AI+=1,`${gne}_${AI}`));An(()=>{if(t){const r=hne(document.body).width,o=pne();_l(`
html body {
overflow-y: hidden;
${o?`width: calc(100% - ${r}px);`:""}
}`,n);}else op(n);return ()=>{op(n);}},[t,n]);}function bne(){return {...K$}.useId}let NI=0;const PI=bne(),zs=PI?(function(t){const n=PI();return t||n}):(function(t){const[n,r]=f.useState("ssr-id");return f.useEffect(()=>{const o=NI;NI+=1,r(`rc_unique_${o}`);},[]),t||n});let kc=[];const yne=200;let tk=0;const nk=e=>{if(e.key==="Escape"&&!e.isComposing){if(Date.now()-tk<yne)return;const n=kc.length;for(let r=n-1;r>=0;r-=1)kc[r].onEsc({top:r===n-1,event:e});}},rk=()=>{tk=Date.now();};function Sne(){window.addEventListener("keydown",nk),window.addEventListener("compositionend",rk);}function Cne(){kc.length===0&&(window.removeEventListener("keydown",nk),window.removeEventListener("compositionend",rk));}function xne(e,t){const n=zs(),r=Mt(t),o=()=>{kc.find(a=>a.id===n)||kc.push({id:n,onEsc:r});},i=()=>{kc=kc.filter(a=>a.id!==n);};f.useMemo(()=>{e?o():e||i();},[e]),f.useEffect(()=>{if(e)return o(),Sne(),()=>{i(),Cne();}},[e]);}const II=e=>e===false?false:!wi()||!e?null:typeof e=="string"?document.querySelector(e):typeof e=="function"?e():e,Zy=f.forwardRef((e,t)=>{const{open:n,autoLock:r,getContainer:o,debug:i,autoDestroy:a=true,children:l,onEsc:u}=e,[d,m]=f.useState(n),p=d||n;f.useEffect(()=>{(a||n)&&m(n);},[n,a]);const[g,b]=f.useState(()=>II(o));f.useEffect(()=>{const R=II(o);b(()=>R??null);});const[y,S]=fne(p&&!g),C=g??y;vne(r&&n&&wi()&&(C===y||C===document.body)),xne(n,u);let w=null;l&&Su(l)&&t&&(w=Ql(l));const $=Bs(w,t);if(!p||!wi()||g===void 0)return null;const M=C===false||dne();let T=l;return t&&(T=f.cloneElement(l,{ref:$})),f.createElement(ek.Provider,{value:S},M?T:$o.createPortal(T,C))});function wne(e){const{prefixCls:t,align:n,arrow:r,arrowPos:o}=e,{className:i,content:a,style:l}=r||{},{x:u=0,y:d=0}=o,m=f.useRef(null);if(!n||!n.points)return null;const p={position:"absolute"};if(n.autoArrow!==false){const g=n.points[0],b=n.points[1],y=g[0],S=g[1],C=b[0],w=b[1];y===C||!["t","b"].includes(y)?p.top=d:y==="t"?p.top=0:p.bottom=0,S===w||!["l","r"].includes(S)?p.left=u:S==="l"?p.left=0:p.right=0;}return f.createElement("div",{ref:m,className:X(`${t}-arrow`,i),style:{...p,...l}},a)}function H2(){return H2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},H2.apply(this,arguments)}function $ne(e){const{prefixCls:t,open:n,zIndex:r,mask:o,motion:i,mobile:a}=e;return o?f.createElement(Co,H2({},i,{motionAppear:true,visible:n,removeOnLeave:true}),({className:l})=>f.createElement("div",{style:{zIndex:r},className:X(`${t}-mask`,a&&`${t}-mobile-mask`,l)})):null}const Ene=f.memo(({children:e})=>e,(e,t)=>t.cache);function ok(e,t,n,r,o,i,a,l){const u="auto",d=e?{}:{left:"-1000vw",top:"-1000vh",right:u,bottom:u};if(!e&&(t||!n)){const{points:m}=r,p=r.dynamicInset||r._experimental?.dynamicInset,g=p&&m[0][1]==="r",b=p&&m[0][0]==="b";g?(d.right=o,d.left=u):(d.left=a,d.right=u),b?(d.bottom=i,d.top=u):(d.top=l,d.bottom=u);}return d}function V2(){return V2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},V2.apply(this,arguments)}const ik=f.forwardRef((e,t)=>{const{onEsc:n,popup:r,className:o,prefixCls:i,style:a,target:l,onVisibleChanged:u,open:d,keepDom:m,fresh:p,onClick:g,mask:b,arrow:y,arrowPos:S,align:C,motion:w,maskMotion:$,mobile:M,forceRender:T,getPopupContainer:R,autoDestroy:I,portal:N,children:P,zIndex:O,onMouseEnter:_,onMouseLeave:B,onPointerEnter:V,onPointerDownCapture:U,ready:G,offsetX:H,offsetY:z,offsetR:j,offsetB:W,onAlign:Y,onPrepare:Q,onResize:D,stretch:L,targetWidth:K,targetHeight:J}=e,ee=typeof r=="function"?r():r,te=d||m,re=!!M,[ie,de,ne]=f.useMemo(()=>M?[M.mask,M.maskMotion,M.motion]:[b,$,w],[M,b,$,w]),ce=R?.length>0,[fe,se]=f.useState(!R||!ce);An(()=>{!fe&&ce&&l&&se(true);},[fe,ce,l]);const Me=Mt((Ce,xe)=>{D?.(Ce,xe),Y();}),ae=ok(re,G,d,C,j,W,H,z);if(!fe)return null;const pe={};return L&&(L.includes("height")&&J?pe.height=J:L.includes("minHeight")&&J&&(pe.minHeight=J),L.includes("width")&&K?pe.width=K:L.includes("minWidth")&&K&&(pe.minWidth=K)),d||(pe.pointerEvents="none"),f.createElement(N,{open:T||te,getContainer:R&&(()=>R(l)),autoDestroy:I,onEsc:n},f.createElement($ne,{prefixCls:i,open:d,zIndex:O,mask:ie,motion:de,mobile:re}),f.createElement(ma,{onResize:Me,disabled:!d},Ce=>f.createElement(Co,V2({motionAppear:true,motionEnter:true,motionLeave:true,removeOnLeave:false,forceRender:T,leavedClassName:`${i}-hidden`},ne,{onAppearPrepare:Q,onEnterPrepare:Q,visible:d,onVisibleChanged:xe=>{w?.onVisibleChanged?.(xe),u(xe);}}),({className:xe,style:Ae},Xe)=>{const Ne=X(i,xe,o,{[`${i}-mobile`]:re});return f.createElement("div",{ref:Vr(Ce,t,Xe),className:Ne,style:{"--arrow-x":`${S.x||0}px`,"--arrow-y":`${S.y||0}px`,...ae,...pe,...Ae,boxSizing:"border-box",zIndex:O,...a},onMouseEnter:_,onMouseLeave:B,onPointerEnter:V,onClick:g,onPointerDownCapture:U},y&&f.createElement(wne,{prefixCls:i,arrow:y,arrowPos:S,align:C}),f.createElement(Ene,{cache:!d&&!p},ee))})),P)}),O0=f.createContext(null),ak=f.createContext(null);function OI(e){return e?Array.isArray(e)?e:[e]:[]}function Mne(e,t,n){return f.useMemo(()=>{const r=OI(t??e),o=OI(n??e),i=new Set(r),a=new Set(o);return i.has("hover")&&!i.has("click")&&i.add("touch"),a.has("hover")&&!a.has("click")&&a.add("touch"),[i,a]},[e,t,n])}const oR=(e=>{if(!e)return false;if(e instanceof Element){if(e.offsetParent)return true;if(e.getBBox){const{width:t,height:n}=e.getBBox();if(t||n)return true}if(e.getBoundingClientRect){const{width:t,height:n}=e.getBoundingClientRect();if(t||n)return true}}return false});function Rne(e=[],t=[],n){const r=(o,i)=>o[i]||"";return n?r(e,0)===r(t,0):r(e,0)===r(t,0)&&r(e,1)===r(t,1)}function sk(e,t,n,r){const{points:o}=n,i=Object.keys(e);for(let a=0;a<i.length;a+=1){const l=i[a];if(Rne(e[l]?.points,o,r))return `${t}-placement-${l}`}return ""}function Xp(e){return e.ownerDocument.defaultView}function j2(e){const t=[];let n=e?.parentElement;const r=["hidden","scroll","clip","auto"];for(;n;){const{overflowX:o,overflowY:i,overflow:a}=Xp(n).getComputedStyle(n);[o,i,a].some(l=>r.includes(l))&&t.push(n),n=n.parentElement;}return t}function dp(e,t=1){return Number.isNaN(e)?t:e}function Km(e){return dp(parseFloat(e),0)}function DI(e,t){const n={...e};return (t||[]).forEach(r=>{if(r instanceof HTMLBodyElement||r instanceof HTMLHtmlElement)return;const{overflow:o,overflowClipMargin:i,borderTopWidth:a,borderBottomWidth:l,borderLeftWidth:u,borderRightWidth:d}=Xp(r).getComputedStyle(r),m=r.getBoundingClientRect(),{offsetHeight:p,clientHeight:g,offsetWidth:b,clientWidth:y}=r,S=Km(a),C=Km(l),w=Km(u),$=Km(d),M=dp(Math.round(m.width/b*1e3)/1e3),T=dp(Math.round(m.height/p*1e3)/1e3),R=(b-y-w-$)*M,I=(p-g-S-C)*T,N=S*T,P=C*T,O=w*M,_=$*M;let B=0,V=0;if(o==="clip"){const j=Km(i);B=j*M,V=j*T;}const U=m.x+O-B,G=m.y+N-V,H=U+m.width+2*B-O-_-R,z=G+m.height+2*V-N-P-I;n.left=Math.max(n.left,U),n.top=Math.max(n.top,G),n.right=Math.min(n.right,H),n.bottom=Math.min(n.bottom,z);}),n}function _I(e,t=0){const n=`${t}`,r=n.match(/^(.*)\%$/);return r?e*(parseFloat(r[1])/100):parseFloat(n)}function BI(e,t){const[n,r]=t||[];return [_I(e.width,n),_I(e.height,r)]}function LI(e=""){return [e[0],e[1]]}function gd(e,t){const n=t[0],r=t[1];let o,i;return n==="t"?i=e.y:n==="b"?i=e.y+e.height:i=e.y+e.height/2,r==="l"?o=e.x:r==="r"?o=e.x+e.width:o=e.x+e.width/2,{x:o,y:i}}function yl(e,t){const n={t:"b",b:"t",l:"r",r:"l"},r=[...e];return r[t]=n[e[t]]||"c",r}function zI(e){return e.join("")}function lk(e,t,n,r,o,i,a,l){const[u,d]=f.useState({ready:false,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:o[r]||{}}),m=f.useRef(0),p=f.useMemo(()=>!t||l?[]:j2(t),[t]),g=f.useRef({});e||(g.current={});const y=Mt(()=>{if(t&&n&&e&&!l){let Oe=function(kt,Ir,Or=Me){const Ra=U.x+kt,Ri=U.y+Ir,Bo=Ra+K,Ur=Ri+L,sc=Math.max(Ra,Or.left),_g=Math.max(Ri,Or.top),lc=Math.min(Bo,Or.right),Nu=Math.min(Ur,Or.bottom);return Math.max(0,(lc-sc)*(Nu-_g))},$e=function(){be=U.y+Be,Se=be+L,he=U.x+Ze,De=he+K;};const w=t,$=w.ownerDocument,M=Xp(w),{position:T}=M.getComputedStyle(w),R=w.style.left,I=w.style.top,N=w.style.right,P=w.style.bottom,O=w.style.overflow,_={...o[r],...i},B=$.createElement("div");w.parentElement?.appendChild(B),B.style.left=`${w.offsetLeft}px`,B.style.top=`${w.offsetTop}px`,B.style.position=T,B.style.height=`${w.offsetHeight}px`,B.style.width=`${w.offsetWidth}px`,w.style.left="0",w.style.top="0",w.style.right="auto",w.style.bottom="auto",w.style.overflow="hidden";let V;if(Array.isArray(n))V={x:n[0],y:n[1],width:0,height:0};else {const kt=n.getBoundingClientRect();kt.x=kt.x??kt.left,kt.y=kt.y??kt.top,V={x:kt.x,y:kt.y,width:kt.width,height:kt.height};}const U=w.getBoundingClientRect(),{height:G,width:H}=M.getComputedStyle(w);U.x=U.x??U.left,U.y=U.y??U.top;const{clientWidth:z,clientHeight:j,scrollWidth:W,scrollHeight:Y,scrollTop:Q,scrollLeft:D}=$.documentElement,L=U.height,K=U.width,J=V.height,ee=V.width,te={left:0,top:0,right:z,bottom:j},re={left:-D,top:-Q,right:W-D,bottom:Y-Q};let{htmlRegion:ie}=_;const de="visible",ne="visibleFirst";ie!=="scroll"&&ie!==ne&&(ie=de);const ce=ie===ne,fe=DI(re,p),se=DI(te,p),Me=ie===de?se:fe,ae=ce?se:Me;w.style.left="auto",w.style.top="auto",w.style.right="0",w.style.bottom="0";const pe=w.getBoundingClientRect();w.style.left=R,w.style.top=I,w.style.right=N,w.style.bottom=P,w.style.overflow=O,w.parentElement?.removeChild(B);const Ce=dp(Math.round(K/parseFloat(H)*1e3)/1e3),xe=dp(Math.round(L/parseFloat(G)*1e3)/1e3);if(Ce===0||xe===0||rf(n)&&!oR(n))return;const{offset:Ae,targetOffset:Xe}=_;let[Ne,ue]=BI(U,Ae);const[ge,Pe]=BI(V,Xe);V.x-=ge,V.y-=Pe;const[je,qe]=_.points||[],Ue=LI(qe),et=LI(je),rt=gd(V,Ue),Ke=gd(U,et),_e={..._};let We=[et,Ue],Ze=rt.x-Ke.x+Ne,Be=rt.y-Ke.y+ue;const lt=Oe(Ze,Be),It=Oe(Ze,Be,se),mt=gd(V,["t","l"]),Bt=gd(U,["t","l"]),xt=gd(V,["b","r"]),Tt=gd(U,["b","r"]),ut=_.overflow||{},{adjustX:dt,adjustY:gt,shiftX:Fe,shiftY:Qe}=ut,ye=kt=>typeof kt=="boolean"?kt:kt>=0;let be,Se,he,De;$e();const ke=ye(gt),Ge=et[0]===Ue[0];if(ke&&et[0]==="t"&&(Se>ae.bottom||g.current.bt)){let kt=Be;Ge?kt-=L-J:kt=mt.y-Tt.y-ue;const Ir=Oe(Ze,kt),Or=Oe(Ze,kt,se);Ir>lt||Ir===lt&&(!ce||Or>=It)?(g.current.bt=true,Be=kt,ue=-ue,We=[yl(We[0],0),yl(We[1],0)]):g.current.bt=false;}if(ke&&et[0]==="b"&&(be<ae.top||g.current.tb)){let kt=Be;Ge?kt+=L-J:kt=xt.y-Bt.y-ue;const Ir=Oe(Ze,kt),Or=Oe(Ze,kt,se);Ir>lt||Ir===lt&&(!ce||Or>=It)?(g.current.tb=true,Be=kt,ue=-ue,We=[yl(We[0],0),yl(We[1],0)]):g.current.tb=false;}const ot=ye(dt),ht=et[1]===Ue[1];if(ot&&et[1]==="l"&&(De>ae.right||g.current.rl)){let kt=Ze;ht?kt-=K-ee:kt=mt.x-Tt.x-Ne;const Ir=Oe(kt,Be),Or=Oe(kt,Be,se);Ir>lt||Ir===lt&&(!ce||Or>=It)?(g.current.rl=true,Ze=kt,Ne=-Ne,We=[yl(We[0],1),yl(We[1],1)]):g.current.rl=false;}if(ot&&et[1]==="r"&&(he<ae.left||g.current.lr)){let kt=Ze;ht?kt+=K-ee:kt=xt.x-Bt.x-Ne;const Ir=Oe(kt,Be),Or=Oe(kt,Be,se);Ir>lt||Ir===lt&&(!ce||Or>=It)?(g.current.lr=true,Ze=kt,Ne=-Ne,We=[yl(We[0],1),yl(We[1],1)]):g.current.lr=false;}_e.points=[zI(We[0]),zI(We[1])],$e();const $t=Fe===true?0:Fe;typeof $t=="number"&&(he<se.left&&(Ze-=he-se.left-Ne,V.x+ee<se.left+$t&&(Ze+=V.x-se.left+ee-$t)),De>se.right&&(Ze-=De-se.right-Ne,V.x>se.right-$t&&(Ze+=V.x-se.right+$t)));const Rt=Qe===true?0:Qe;typeof Rt=="number"&&(be<se.top&&(Be-=be-se.top-ue,V.y+J<se.top+Rt&&(Be+=V.y-se.top+J-Rt)),Se>se.bottom&&(Be-=Se-se.bottom-ue,V.y>se.bottom-Rt&&(Be+=V.y-se.bottom+Rt)));const Ot=U.x+Ze,Sn=Ot+K,Hn=U.y+Be,Re=Hn+L,ct=V.x,tt=ct+ee,yt=V.y,At=yt+J,en=Math.max(Ot,ct),Zt=Math.min(Sn,tt),Un=(en+Zt)/2-Ot,rr=Math.max(Hn,yt),vn=Math.min(Re,At),Za=(rr+vn)/2-Hn;a?.(t,_e);let Wn=pe.right-U.x-(Ze+U.width),_o=pe.bottom-U.y-(Be+U.height);Ce===1&&(Ze=Math.floor(Ze),Wn=Math.floor(Wn)),xe===1&&(Be=Math.floor(Be),_o=Math.floor(_o));const nm={ready:true,offsetX:Ze/Ce,offsetY:Be/xe,offsetR:Wn/Ce,offsetB:_o/xe,arrowX:Un/Ce,arrowY:Za/xe,scaleX:Ce,scaleY:xe,align:_e};d(nm);}}),S=()=>{m.current+=1;const w=m.current;Promise.resolve().then(()=>{m.current===w&&y();});},C=()=>{d(w=>({...w,ready:false}));};return An(C,[r]),An(()=>{e||C();},[e]),[u.ready,u.offsetX,u.offsetY,u.offsetR,u.offsetB,u.arrowX,u.arrowY,u.scaleX,u.scaleY,u.align,S]}function ck(){const e=f.useRef(null),t=()=>{e.current&&(clearTimeout(e.current),e.current=null);},n=(r,o)=>{t(),o===0?r():e.current=setTimeout(()=>{r();},o*1e3);};return f.useEffect(()=>()=>{t();},[]),n}function Tne(e,t,n,r,o){An(()=>{if(e&&t&&n){let p=function(){r(),o();};const i=t,a=n,l=j2(i),u=j2(a),d=Xp(a),m=new Set([d,...l,...u]);return m.forEach(g=>{g.addEventListener("scroll",p,{passive:true});}),d.addEventListener("resize",p,{passive:true}),r(),()=>{m.forEach(g=>{g.removeEventListener("scroll",p),d.removeEventListener("resize",p);});}}},[e,t,n]);}function Ane(e,t,n,r,o,i,a,l){const u=f.useRef(e);u.current=e;const d=f.useRef(false);f.useEffect(()=>{if(t&&r&&(!o||i)){const p=()=>{d.current=false;},g=S=>{u.current&&!a(S.composedPath?.()?.[0]||S.target)&&!d.current&&l(false);},b=Xp(r);b.addEventListener("pointerdown",p,true),b.addEventListener("mousedown",g,true),b.addEventListener("contextmenu",g,true);const y=I0(n);return y&&(y.addEventListener("mousedown",g,true),y.addEventListener("contextmenu",g,true)),()=>{b.removeEventListener("pointerdown",p,true),b.removeEventListener("mousedown",g,true),b.removeEventListener("contextmenu",g,true),y&&(y.removeEventListener("mousedown",g,true),y.removeEventListener("contextmenu",g,true));}}},[t,n,r,o,i]);function m(){d.current=true;}return m}function Nne(){const[e,t]=q.useState(null),[n,r]=q.useState(false),[o,i]=q.useState(false),a=q.useRef(null),l=Mt(d=>{d===false?(a.current=null,r(false)):o&&n?a.current=d:(r(true),t(d),a.current=null,n||i(true));}),u=Mt(d=>{d?(i(false),a.current&&(t(a.current),a.current=null)):(i(false),a.current=null);});return [l,n,e,u]}function U2(){return U2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},U2.apply(this,arguments)}const Pne=e=>{const{prefixCls:t,isMobile:n,ready:r,open:o,align:i,offsetR:a,offsetB:l,offsetX:u,offsetY:d,arrowPos:m,popupSize:p,motion:g,uniqueContainerClassName:b,uniqueContainerStyle:y}=e,S=`${t}-unique-container`,[C,w]=q.useState(false),$=ok(n,r,o,i,a,l,u,d),M=q.useRef($);r&&(M.current=$);const T={};return p&&(T.width=p.width,T.height=p.height),q.createElement(Co,U2({motionAppear:true,motionEnter:true,motionLeave:true,removeOnLeave:false,leavedClassName:`${S}-hidden`},g,{visible:o,onVisibleChanged:R=>{w(R);}}),({className:R,style:I})=>{const N=X(S,R,b,{[`${S}-visible`]:C});return q.createElement("div",{className:N,style:{"--arrow-x":`${m?.x||0}px`,"--arrow-y":`${m?.y||0}px`,...M.current,...T,...I,...y}})})},Ine=({children:e,postTriggerProps:t})=>{const[n,r,o,i]=Nne(),a=f.useMemo(()=>!o||!t?o:t(o),[o,t]),[l,u]=f.useState(null),[d,m]=f.useState(null),p=f.useRef(null),g=Mt(W=>{p.current=W,rf(W)&&l!==W&&u(W);}),b=f.useRef(null),y=ck(),S=Mt((W,Y)=>{b.current=Y,y(()=>{n(W);},W.delay);}),C=W=>{y(()=>{b.current?.()||n(false);},W);},w=Mt(W=>{i(W);}),[$,M,T,R,I,N,P,,,O,_]=lk(r,l,a?.target,a?.popupPlacement,a?.builtinPlacements||{},a?.popupAlign,void 0,false),B=f.useMemo(()=>{if(!a)return "";const W=sk(a.builtinPlacements||{},a.prefixCls||"",O,false);return X(W,a.getPopupClassNameFromAlign?.(O))},[O,a?.getPopupClassNameFromAlign,a?.builtinPlacements,a?.prefixCls]),V=f.useMemo(()=>({show:S,hide:C}),[]);f.useEffect(()=>{_();},[a?.target]);const U=Mt(()=>(_(),Promise.resolve())),G=f.useRef({}),H=f.useContext(O0),z=f.useMemo(()=>({registerSubPopup:(W,Y)=>{G.current[W]=Y,H?.registerSubPopup(W,Y);}}),[H]),j=a?.prefixCls;return f.createElement(ak.Provider,{value:V},e,a&&f.createElement(O0.Provider,{value:z},f.createElement(ik,{ref:g,portal:Zy,onEsc:a.onEsc,prefixCls:j,popup:a.popup,className:X(a.popupClassName,B,`${j}-unique-controlled`),style:a.popupStyle,target:a.target,open:r,keepDom:true,fresh:true,autoDestroy:false,onVisibleChanged:w,ready:$,offsetX:M,offsetY:T,offsetR:R,offsetB:I,onAlign:_,onPrepare:U,onResize:W=>m({width:W.offsetWidth,height:W.offsetHeight}),arrowPos:{x:N,y:P},align:O,zIndex:a.zIndex,mask:a.mask,arrow:a.arrow,motion:a.popupMotion,maskMotion:a.maskMotion,getPopupContainer:a.getPopupContainer},f.createElement(Pne,{prefixCls:j,isMobile:false,ready:$,open:r,align:O,offsetR:R,offsetB:I,offsetX:M,offsetY:T,arrowPos:{x:N,y:P},popupSize:d,motion:a.popupMotion,uniqueContainerClassName:X(a.uniqueContainerClassName,B),uniqueContainerStyle:a.uniqueContainerStyle}))))};function One(e=Zy){return f.forwardRef((n,r)=>{const{prefixCls:o="rc-trigger-popup",children:i,action:a="hover",showAction:l,hideAction:u,popupVisible:d,defaultPopupVisible:m,onOpenChange:p,afterOpenChange:g,onPopupVisibleChange:b,afterPopupVisibleChange:y,mouseEnterDelay:S,mouseLeaveDelay:C=.1,focusDelay:w,blurDelay:$,mask:M,maskClosable:T=true,getPopupContainer:R,forceRender:I,autoDestroy:N,popup:P,popupClassName:O,uniqueContainerClassName:_,uniqueContainerStyle:B,popupStyle:V,popupPlacement:U,builtinPlacements:G={},popupAlign:H,zIndex:z,stretch:j,getPopupClassNameFromAlign:W,fresh:Y,unique:Q,alignPoint:D,onPopupClick:L,onPopupAlign:K,arrow:J,popupMotion:ee,maskMotion:te,mobile:re,...ie}=n,de=N||false,ne=d===void 0,ce=!!re,fe=f.useRef({}),se=f.useContext(O0),Me=f.useMemo(()=>({registerSubPopup:(ft,Ht)=>{fe.current[ft]=Ht,se?.registerSubPopup(ft,Ht);}}),[se]),ae=f.useContext(ak),pe=zs(),[Ce,xe]=f.useState(null),Ae=f.useRef(null),Xe=Mt(ft=>{Ae.current=ft,rf(ft)&&Ce!==ft&&xe(ft),se?.registerSubPopup(pe,ft);}),[Ne,ue]=f.useState(null),ge=f.useRef(null),Pe=Mt(ft=>{const Ht=of(ft);rf(Ht)&&Ne!==Ht&&(ue(Ht),ge.current=Ht);}),je={},qe=Mt(ft=>{const Ht=Ne;return Ht?.contains(ft)||I0(Ht)?.host===ft||ft===Ht||Ce?.contains(ft)||I0(Ce)?.host===ft||ft===Ce||Object.values(fe.current).some(qs=>qs?.contains(ft)||ft===qs)}),Ue=J?{...J!==true?J:{}}:null,[et,rt]=un(m||false,d),Ke=et||false,_e=f.useMemo(()=>{const ft=typeof i=="function"?i({open:Ke}):i;return f.Children.only(ft)},[i,Ke]),We=_e?.props||{},Ze=Mt(()=>Ke),Be=Mt((ft=0)=>({popup:P,target:Ne,delay:ft,prefixCls:o,popupClassName:O,uniqueContainerClassName:_,uniqueContainerStyle:B,popupStyle:V,popupPlacement:U,builtinPlacements:G,popupAlign:H,zIndex:z,mask:M,maskClosable:T,popupMotion:ee,maskMotion:te,arrow:Ue,getPopupContainer:R,getPopupClassNameFromAlign:W,id:pe,onEsc:Bt}));An(()=>{ae&&Q&&Ne&&!ne&&!se&&(Ke?ae.show(Be(S),Ze):ae.hide(C));},[Ke,Ne]);const Oe=f.useRef(Ke);Oe.current=Ke;const lt=Mt(ft=>{$o.flushSync(()=>{Ke!==ft&&(rt(ft),p?.(ft),b?.(ft));});}),It=ck(),mt=(ft,Ht=0)=>{if(d!==void 0){It(()=>{lt(ft);},Ht);return}if(ae&&Q&&ne&&!se){ft?ae.show(Be(Ht),Ze):ae.hide(Ht);return}It(()=>{lt(ft);},Ht);};function Bt({top:ft}){ft&&mt(false);}const[xt,Tt]=f.useState(false);An(ft=>{(!ft||Ke)&&Tt(true);},[Ke]);const[ut,dt]=f.useState(null),[gt,Fe]=f.useState(null),Qe=ft=>{Fe([ft.clientX,ft.clientY]);},[ye,be,Se,he,De,$e,ke,Ge,ot,ht,$t]=lk(Ke,Ce,D&>!==null?gt:Ne,U,G,H,K,ce),[Rt,Ot]=Mne(a,l,u),Sn=Rt.has("click"),Hn=Ot.has("click")||Ot.has("contextMenu"),Re=Mt(()=>{xt||$t();});Tne(Ke,Ne,Ce,Re,()=>{Oe.current&&D&&Hn&&mt(false);}),An(()=>{Re();},[gt,U]),An(()=>{Ke&&!G?.[U]&&Re();},[JSON.stringify(H)]);const tt=f.useMemo(()=>{const ft=sk(G,o,ht,D);return X(ft,W?.(ht))},[ht,W,G,o,D]);f.useImperativeHandle(r,()=>({nativeElement:ge.current,popupElement:Ae.current,forceAlign:Re}));const[yt,At]=f.useState(0),[en,Zt]=f.useState(0),mn=()=>{if(j&&Ne){const ft=Ne.getBoundingClientRect();At(ft.width),Zt(ft.height);}},Un=()=>{mn(),Re();},rr=ft=>{Tt(false),$t(),g?.(ft),y?.(ft);},vn=()=>new Promise(ft=>{mn(),dt(()=>ft);});An(()=>{ut&&($t(),ut(),dt(null));},[ut]);function Mi(ft,Ht,qs,Bg,Iu){je[ft]=(Ja,...Lg)=>{(!Iu||!Iu())&&(Bg?.(Ja),mt(Ht,qs)),We[ft]?.(Ja,...Lg);};}const Za=Rt.has("touch"),Wn=Ot.has("touch"),_o=f.useRef(false);(Za||Wn)&&(je.onTouchStart=(...ft)=>{_o.current=true,Oe.current&&Wn?mt(false):!Oe.current&&Za&&mt(true),We.onTouchStart?.(...ft);}),(Sn||Hn)&&(je.onClick=(ft,...Ht)=>{Oe.current&&Hn?mt(false):!Oe.current&&Sn&&(Qe(ft),mt(true)),We.onClick?.(ft,...Ht),_o.current=false;});const nm=Ane(Ke,Hn||Wn,Ne,Ce,M,T,qe,mt),kt=Rt.has("hover"),Ir=Ot.has("hover");let Or,Ra;const Ri=()=>_o.current;if(kt){const ft=Ht=>{Qe(Ht);};Mi("onMouseEnter",true,S,ft,Ri),Mi("onPointerEnter",true,S,ft,Ri),Or=Ht=>{(Ke||xt)&&Ce?.contains(Ht.target)&&mt(true,S);},D&&(je.onMouseMove=Ht=>{We.onMouseMove?.(Ht);});}Ir&&(Mi("onMouseLeave",false,C,void 0,Ri),Mi("onPointerLeave",false,C,void 0,Ri),Ra=()=>{mt(false,C);}),Rt.has("focus")&&Mi("onFocus",true,w),Ot.has("focus")&&Mi("onBlur",false,$),Rt.has("contextMenu")&&(je.onContextMenu=(ft,...Ht)=>{Oe.current&&Ot.has("contextMenu")?mt(false):(Qe(ft),mt(true)),ft.preventDefault(),We.onContextMenu?.(ft,...Ht);});const Bo=f.useRef(false);Bo.current||=I||Ke||xt;const Ur={...We,...je},sc={};["onContextMenu","onClick","onMouseDown","onTouchStart","onMouseEnter","onMouseLeave","onFocus","onBlur"].forEach(ft=>{ie[ft]&&(sc[ft]=(...Ht)=>{Ur[ft]?.(...Ht),ie[ft](...Ht);});});const lc={x:$e,y:ke};KL(Ke,Ne,Un);const Nu=Bs(Pe,Ql(_e)),Pu=f.cloneElement(_e,{...Ur,...sc,ref:Nu});return f.createElement(f.Fragment,null,Pu,Bo.current&&(!ae||!Q)&&f.createElement(O0.Provider,{value:Me},f.createElement(ik,{portal:e,ref:Xe,prefixCls:o,popup:P,className:X(O,!ce&&tt),style:V,target:Ne,onMouseEnter:Or,onMouseLeave:Ra,onPointerEnter:Or,zIndex:z,open:Ke,keepDom:xt,fresh:Y,onClick:L,onPointerDownCapture:nm,mask:M,motion:ee,maskMotion:te,onVisibleChanged:rr,onPrepare:vn,forceRender:I,autoDestroy:de,getPopupContainer:R,onEsc:Bt,align:ht,arrow:Ue,arrowPos:lc,ready:ye,offsetX:be,offsetY:Se,offsetR:he,offsetB:De,onAlign:Re,stretch:j,targetWidth:yt/Ge,targetHeight:en/ot,mobile:re})))})}const Jy=One(Zy);function uk(e){return e&&q.isValidElement(e)&&e.type===q.Fragment}const dk=(e,t,n)=>q.isValidElement(e)?q.cloneElement(e,typeof n=="function"?n(e.props||{}):n):t;function Hr(e,t){return dk(e,e,t)}const Dne=({children:e})=>{const{getPrefixCls:t}=q.useContext(wt),n=t();return q.isValidElement(e)?q.createElement(Co,{visible:true,motionName:`${n}-fade`,motionAppear:true,motionEnter:true,motionLeave:false,removeOnLeave:false},({style:r,className:o})=>Hr(e,i=>({className:X(i.className,o),style:{...i.style,...r}}))):e},ob=[null,null];function _ne(e){if(ob[0]!==e){const t={};Object.keys(e).forEach(n=>{t[n]={...e[n],dynamicInset:false};}),ob[0]=e,ob[1]=t;}return ob[1]}const fk=({children:e})=>{const t=n=>{const{id:r,builtinPlacements:o,popup:i}=n,a=typeof i=="function"?i():i,l=_ne(o);return {...n,getPopupContainer:null,arrow:false,popup:q.createElement(Dne,{key:r},a),builtinPlacements:l}};return q.createElement(Ine,{postTriggerProps:t},e)},no=f.createContext(false),mk=({children:e,disabled:t})=>{const n=f.useContext(no);return f.createElement(no.Provider,{value:t??n},e)},lf=f.createContext(void 0),Bne=({children:e,size:t})=>{const n=f.useContext(lf);return f.createElement(lf.Provider,{value:t||n},e)};function Lne(){const e=f.useContext(no),t=f.useContext(lf);return {componentDisabled:e,componentSize:t}}function zne(e,t,n){const r=e||{},o=r.inherit===false||!t?{...cp,hashed:t?.hashed??cp.hashed,cssVar:t?.cssVar}:t,i=f.useId();return Tf(()=>{if(!e)return t;const a={...o.components};Object.keys(e.components||{}).forEach(d=>{a[d]={...a[d],...e.components[d]};});const l=`css-var-${i.replace(/:/g,"")}`,u={prefix:n?.prefixCls,...o.cssVar,...r.cssVar,key:r.cssVar?.key||l};return {...o,...r,token:{...o.token,...r.token},components:a,cssVar:u}},[r,o],(a,l)=>a.some((u,d)=>{const m=l[d];return !zl(u,m,true)}))}const kI=f.createContext(true);function kne(e){const t=f.useContext(kI),{children:n}=e,[,r]=jr(),{motion:o}=r,i=f.useRef(false);return i.current||(i.current=t!==o),i.current?f.createElement(kI.Provider,{value:o},f.createElement(Ste,{motion:o},n)):n}const Fne=()=>null,Hne=({iconPrefixCls:e,csp:t})=>(tte(e,t),null),Vne=["getTargetContainer","getPopupContainer","renderEmpty","input","pagination","form","select","button"];let D0,hk,pk,gk;function Ix(){return D0||np}function jne(){return hk||jy}const Une=e=>{const{prefixCls:t,iconPrefixCls:n,theme:r,holderRender:o}=e;t!==void 0&&(D0=t),n!==void 0&&(hk=n),"holderRender"in e&&(gk=o),r&&(pk=r);},iR=()=>({getPrefixCls:(e,t)=>t||(e?`${Ix()}-${e}`:Ix()),getIconPrefixCls:jne,getRootPrefixCls:()=>D0||Ix(),getTheme:()=>pk,holderRender:gk}),Wne=e=>{const{children:t,csp:n,autoInsertSpaceInButton:r,alert:o,affix:i,anchor:a,app:l,form:u,locale:d,componentSize:m,direction:p,space:g,splitter:b,virtual:y,dropdownMatchSelectWidth:S,popupMatchSelectWidth:C,popupOverflow:w,legacyLocale:$,parentContext:M,iconPrefixCls:T,theme:R,componentDisabled:I,segmented:N,statistic:P,spin:O,calendar:_,carousel:B,cascader:V,collapse:U,typography:G,checkbox:H,descriptions:z,divider:j,drawer:W,skeleton:Y,steps:Q,image:D,layout:L,list:K,mentions:J,modal:ee,progress:te,result:re,slider:ie,breadcrumb:de,masonry:ne,menu:ce,pagination:fe,input:se,textArea:Me,otp:ae,empty:pe,badge:Ce,radio:xe,rate:Ae,ribbon:Xe,switch:Ne,transfer:ue,avatar:ge,message:Pe,tag:je,table:qe,card:Ue,cardMeta:et,tabs:rt,timeline:Ke,timePicker:_e,upload:We,notification:Ze,tree:Be,colorPicker:Oe,datePicker:lt,rangePicker:It,flex:mt,wave:Bt,dropdown:xt,warning:Tt,tour:ut,tooltip:dt,popover:gt,popconfirm:Fe,qrcode:Qe,floatButton:ye,floatButtonGroup:be,variant:Se,inputNumber:he,treeSelect:De,watermark:$e}=e,ke=f.useCallback((yt,At)=>{const{prefixCls:en}=e;if(At)return At;const Zt=en||M.getPrefixCls("");return yt?`${Zt}-${yt}`:Zt},[M.getPrefixCls,e.prefixCls]),Ge=T||M.iconPrefixCls||jy,ot=n||M.csp,ht=zne(R,M.theme,{prefixCls:ke("")}),$t={csp:ot,autoInsertSpaceInButton:r,alert:o,affix:i,anchor:a,app:l,locale:d||$,direction:p,space:g,splitter:b,virtual:y,popupMatchSelectWidth:C??S,popupOverflow:w,getPrefixCls:ke,iconPrefixCls:Ge,theme:ht,segmented:N,statistic:P,spin:O,calendar:_,carousel:B,cascader:V,collapse:U,typography:G,checkbox:H,descriptions:z,divider:j,drawer:W,skeleton:Y,steps:Q,image:D,input:se,textArea:Me,otp:ae,layout:L,list:K,mentions:J,modal:ee,progress:te,result:re,slider:ie,breadcrumb:de,masonry:ne,menu:ce,pagination:fe,empty:pe,badge:Ce,radio:xe,rate:Ae,ribbon:Xe,switch:Ne,transfer:ue,avatar:ge,message:Pe,tag:je,table:qe,card:Ue,cardMeta:et,tabs:rt,timeline:Ke,timePicker:_e,upload:We,notification:Ze,tree:Be,colorPicker:Oe,datePicker:lt,rangePicker:It,flex:mt,wave:Bt,dropdown:xt,warning:Tt,tour:ut,tooltip:dt,popover:gt,popconfirm:Fe,qrcode:Qe,floatButton:ye,floatButtonGroup:be,variant:Se,inputNumber:he,treeSelect:De,watermark:$e},Rt={...M};Object.keys($t).forEach(yt=>{$t[yt]!==void 0&&(Rt[yt]=$t[yt]);}),Vne.forEach(yt=>{const At=e[yt];At&&(Rt[yt]=At);}),typeof r<"u"&&(Rt.button={autoInsertSpace:r,...Rt.button});const Ot=Tf(()=>Rt,Rt,(yt,At)=>{const en=Object.keys(yt),Zt=Object.keys(At);return en.length!==Zt.length||en.some(mn=>yt[mn]!==At[mn])}),{layer:Sn}=f.useContext(lu),Hn=f.useMemo(()=>({prefixCls:Ge,csp:ot,layer:Sn?"antd":void 0}),[Ge,ot,Sn]);let Re=f.createElement(f.Fragment,null,f.createElement(Hne,{iconPrefixCls:Ge,csp:ot}),f.createElement(Fne,{dropdownMatchSelectWidth:S}),t);const ct=f.useMemo(()=>Pd(ya.Form?.defaultValidateMessages||{},Ot.locale?.Form?.defaultValidateMessages||{},Ot.form?.validateMessages||{},u?.validateMessages||{}),[Ot,u?.validateMessages]);Object.keys(ct).length>0&&(Re=f.createElement(lne.Provider,{value:ct},Re)),d&&(Re=f.createElement(Xte,{locale:d,_ANT_MARK__:Yte},Re)),Re=f.createElement(XM.Provider,{value:Hn},Re),m&&(Re=f.createElement(Bne,{size:m},Re)),Re=f.createElement(kne,null,Re),dt?.unique&&(Re=f.createElement(fk,null,Re));const tt=f.useMemo(()=>{const{algorithm:yt,token:At,components:en,cssVar:Zt,...mn}=ht||{},Un=yt&&(!Array.isArray(yt)||yt.length>0)?A0(yt):KM,rr={};Object.entries(en||{}).forEach(([Mi,Za])=>{const Wn={...Za};"algorithm"in Wn&&(Wn.algorithm===true?Wn.theme=Un:(Array.isArray(Wn.algorithm)||typeof Wn.algorithm=="function")&&(Wn.theme=A0(Wn.algorithm)),delete Wn.algorithm),rr[Mi]=Wn;});const vn={...sf,...At};return {...mn,theme:Un,token:vn,components:rr,override:{override:vn,...rr},cssVar:Zt}},[ht]);return R&&(Re=f.createElement(YM.Provider,{value:tt},Re)),Ot.warning&&(Re=f.createElement(mJ.Provider,{value:Ot.warning},Re)),I!==void 0&&(Re=f.createElement(mk,{disabled:I},Re)),f.createElement(wt.Provider,{value:Ot},Re)},Do=e=>{const t=f.useContext(wt),n=f.useContext(eR);return f.createElement(Wne,{parentContext:t,legacyLocale:n,...e})};Do.ConfigContext=wt;Do.SizeContext=lf;Do.config=Une;Do.useConfig=Lne;Object.defineProperty(Do,"SizeContext",{get:()=>lf});const it={BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,N:78,P:80,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,SEMICOLON:186,EQUALS:187,WIN_KEY:224};function _0(){return _0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},_0.apply(this,arguments)}const aR=f.forwardRef((e,t)=>{const{prefixCls:n,style:r,className:o,duration:i=4.5,showProgress:a,pauseOnHover:l=true,eventKey:u,content:d,closable:m,props:p,onClick:g,onNoticeClose:b,times:y,hovering:S}=e,[C,w]=f.useState(false),[$,M]=f.useState(0),[T,R]=f.useState(0),I=S||C,N=typeof i=="number"?i:0,P=N>0&&a,O=()=>{b(u);},_=H=>{(H.key==="Enter"||H.code==="Enter"||H.keyCode===it.ENTER)&&O();};f.useEffect(()=>{if(!I&&N>0){const H=Date.now()-T,z=setTimeout(()=>{O();},N*1e3-T);return ()=>{l&&clearTimeout(z),R(Date.now()-H);}}},[N,I,y]),f.useEffect(()=>{if(!I&&P&&(l||T===0)){const H=performance.now();let z;const j=()=>{cancelAnimationFrame(z),z=requestAnimationFrame(W=>{const Y=W+T-H,Q=Math.min(Y/(N*1e3),1);M(Q*100),Q<1&&j();});};return j(),()=>{l&&cancelAnimationFrame(z);}}},[N,T,I,P,y]);const B=f.useMemo(()=>typeof m=="object"&&m!==null?m:{},[m]),V=yo(B,true),U=100-(!$||$<0?0:$>100?100:$),G=`${n}-notice`;return f.createElement("div",_0({},p,{ref:t,className:X(G,o,{[`${G}-closable`]:m}),style:r,onMouseEnter:H=>{w(true),p?.onMouseEnter?.(H);},onMouseLeave:H=>{w(false),p?.onMouseLeave?.(H);},onClick:g}),f.createElement("div",{className:`${G}-content`},d),m&&f.createElement("button",_0({className:`${G}-close`,onKeyDown:_,"aria-label":"Close"},V,{onClick:H=>{H.preventDefault(),H.stopPropagation(),O();}}),B.closeIcon??"x"),P&&f.createElement("progress",{className:`${G}-progress`,max:"100",value:U},U+"%"))}),vk=q.createContext({}),bk=({children:e,classNames:t})=>q.createElement(vk.Provider,{value:{classNames:t}},e),FI=8,HI=3,VI=16,Gne=e=>{const t={offset:FI,threshold:HI,gap:VI};return e&&typeof e=="object"&&(t.offset=e.offset??FI,t.threshold=e.threshold??HI,t.gap=e.gap??VI),[!!e,t]};function B0(){return B0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},B0.apply(this,arguments)}const qne=e=>{const{configList:t,placement:n,prefixCls:r,className:o,style:i,motion:a,onAllNoticeRemoved:l,onNoticeClose:u,stack:d}=e,{classNames:m}=f.useContext(vk),p=f.useRef({}),[g,b]=f.useState(null),[y,S]=f.useState([]),C=t.map(N=>({config:N,key:String(N.key)})),[w,{offset:$,threshold:M,gap:T}]=Gne(d),R=w&&(y.length>0||C.length<=M),I=typeof a=="function"?a(n):a;return f.useEffect(()=>{w&&y.length>1&&S(N=>N.filter(P=>C.some(({key:O})=>P===O)));},[y,C,w]),f.useEffect(()=>{w&&p.current[C[C.length-1]?.key]&&b(p.current[C[C.length-1]?.key]);},[C,w]),q.createElement(Lte,B0({key:n,className:X(r,`${r}-${n}`,m?.list,o,{[`${r}-stack`]:!!w,[`${r}-stack-expanded`]:R}),style:i,keys:C,motionAppear:true},I,{onAllRemoved:()=>{l(n);}}),({config:N,className:P,style:O,index:_},B)=>{const{key:V,times:U}=N,G=String(V),{className:H,style:z,classNames:j,styles:W,...Y}=N,Q=C.findIndex(L=>L.key===G),D={};if(w){const L=C.length-1-(Q>-1?Q:_-1),K=n==="top"||n==="bottom"?"-50%":"0";if(L>0){D.height=R?p.current[G]?.offsetHeight:g?.offsetHeight;let J=0;for(let re=0;re<L;re++)J+=p.current[C[C.length-1-re].key]?.offsetHeight+T;const ee=(R?J:L*$)*(n.startsWith("top")?1:-1),te=!R&&g?.offsetWidth&&p.current[G]?.offsetWidth?(g?.offsetWidth-$*2*(L<3?L:3))/p.current[G]?.offsetWidth:1;D.transform=`translate3d(${K}, ${ee}px, 0) scaleX(${te})`;}else D.transform=`translate3d(${K}, 0, 0)`;}return q.createElement("div",{ref:B,className:X(`${r}-notice-wrapper`,P,j?.wrapper),style:{...O,...D,...W?.wrapper},onMouseEnter:()=>S(L=>L.includes(G)?L:[...L,G]),onMouseLeave:()=>S(L=>L.filter(K=>K!==G))},q.createElement(aR,B0({},Y,{ref:L=>{Q>-1?p.current[G]=L:delete p.current[G];},prefixCls:r,classNames:j,styles:W,className:X(H,m?.notice),style:z,times:U,key:V,eventKey:V,onNoticeClose:u,hovering:w&&y.length>0})))})},Kne=f.forwardRef((e,t)=>{const{prefixCls:n="rc-notification",container:r,motion:o,maxCount:i,className:a,style:l,onAllRemoved:u,stack:d,renderNotifications:m}=e,[p,g]=f.useState([]),b=M=>{const T=p.find(P=>P.key===M),R=T?.closable,I=R&&typeof R=="object"?R:{},{onClose:N}=I;N?.(),T?.onClose?.(),g(P=>P.filter(O=>O.key!==M));};f.useImperativeHandle(t,()=>({open:M=>{g(T=>{let R=[...T];const I=R.findIndex(P=>P.key===M.key),N={...M};return I>=0?(N.times=(T[I]?.times||0)+1,R[I]=N):(N.times=0,R.push(N)),i>0&&R.length>i&&(R=R.slice(-i)),R});},close:M=>{b(M);},destroy:()=>{g([]);}}));const[y,S]=f.useState({});f.useEffect(()=>{const M={};p.forEach(T=>{const{placement:R="topRight"}=T;R&&(M[R]=M[R]||[],M[R].push(T));}),Object.keys(y).forEach(T=>{M[T]=M[T]||[];}),S(M);},[p]);const C=M=>{S(T=>{const R={...T};return (R[M]||[]).length||delete R[M],R});},w=f.useRef(false);if(f.useEffect(()=>{Object.keys(y).length>0?w.current=true:w.current&&(u?.(),w.current=false);},[y]),!r)return null;const $=Object.keys(y);return $o.createPortal(f.createElement(f.Fragment,null,$.map(M=>{const T=y[M],R=f.createElement(qne,{key:M,configList:T,placement:M,prefixCls:n,className:a?.(M),style:l?.(M),motion:o,onNoticeClose:b,onAllNoticeRemoved:C,stack:d});return m?m(R,{prefixCls:n,key:M}):R})),r)}),Yne=()=>document.body;let jI=0;function Xne(...e){const t={};return e.forEach(n=>{n&&Object.keys(n).forEach(r=>{const o=n[r];o!==void 0&&(t[r]=o);});}),t}function yk(e={}){const{getContainer:t=Yne,motion:n,prefixCls:r,maxCount:o,className:i,style:a,onAllRemoved:l,stack:u,renderNotifications:d,...m}=e,[p,g]=f.useState(),b=f.useRef(),y=f.createElement(Kne,{container:p,ref:b,prefixCls:r,motion:n,maxCount:o,className:i,style:a,onAllRemoved:l,stack:u,renderNotifications:d}),[S,C]=f.useState([]),w=Mt(M=>{const T=Xne(m,M);(T.key===null||T.key===void 0)&&(T.key=`rc-notification-${jI}`,jI+=1),C(R=>[...R,{type:"open",config:T}]);}),$=f.useMemo(()=>({open:w,close:M=>{C(T=>[...T,{type:"close",key:M}]);},destroy:()=>{C(M=>[...M,{type:"destroy"}]);}}),[]);return f.useEffect(()=>{g(t());}),f.useEffect(()=>{if(b.current&&S.length){S.forEach(R=>{switch(R.type){case "open":b.current.open(R.config);break;case "close":b.current.close(R.key);break;case "destroy":b.current.destroy();break}});let M,T;C(R=>((M!==R||!T)&&(M=R,T=R.filter(I=>!S.includes(I))),T));}},[S]),[$,y]}var Qne={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"};function W2(){return W2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},W2.apply(this,arguments)}const Zne=(e,t)=>f.createElement(Xn,W2({},e,{ref:t,icon:Qne})),e1=f.forwardRef(Zne),Jne=e=>{const{componentCls:t,iconCls:n,boxShadow:r,colorText:o,colorSuccess:i,colorError:a,colorWarning:l,colorInfo:u,fontSizeLG:d,motionEaseInOutCirc:m,motionDurationSlow:p,marginXS:g,paddingXS:b,borderRadiusLG:y,zIndexPopup:S,contentPadding:C,contentBg:w}=e,$=`${t}-notice`,M=new zt("MessageMoveIn",{"0%":{padding:0,transform:"translateY(-100%)",opacity:0},"100%":{padding:b,transform:"translateY(0)",opacity:1}}),T=new zt("MessageMoveOut",{"0%":{maxHeight:e.height,padding:b,opacity:1},"100%":{maxHeight:0,padding:0,opacity:0}}),R={padding:b,textAlign:"center",[`${t}-custom-content`]:{display:"flex",alignItems:"center"},[`${t}-custom-content > ${n}`]:{marginInlineEnd:g,fontSize:d},[`${$}-content`]:{display:"inline-block",padding:C,background:w,borderRadius:y,boxShadow:r,pointerEvents:"all"},[`${t}-success > ${n}`]:{color:i},[`${t}-error > ${n}`]:{color:a},[`${t}-warning > ${n}`]:{color:l},[`${t}-info > ${n},
${t}-loading > ${n}`]:{color:u}};return [{[t]:{...dn(e),color:o,position:"fixed",top:g,width:"100%",pointerEvents:"none",zIndex:S,[`${t}-move-up`]:{animationFillMode:"forwards"},[`
${t}-move-up-appear,
${t}-move-up-enter
`]:{animationName:M,animationDuration:p,animationPlayState:"paused",animationTimingFunction:m},[`
${t}-move-up-appear${t}-move-up-appear-active,
${t}-move-up-enter${t}-move-up-enter-active
`]:{animationPlayState:"running"},[`${t}-move-up-leave`]:{animationName:T,animationDuration:p,animationPlayState:"paused",animationTimingFunction:m},[`${t}-move-up-leave${t}-move-up-leave-active`]:{animationPlayState:"running"},"&-rtl":{direction:"rtl",span:{direction:"rtl"}}}},{[t]:{[`${$}-wrapper`]:{...R}}},{[`${t}-notice-pure-panel`]:{...R,padding:0,textAlign:"start"}}]},ere=e=>({zIndexPopup:e.zIndexPopupBase+rR+10,contentBg:e.colorBgElevated,contentPadding:`${(e.controlHeightLG-e.fontSize*e.lineHeight)/2}px ${e.paddingSM}px`}),Sk=Wt("Message",e=>{const t=Ft(e,{height:150});return Jne(t)},ere),tre={info:f.createElement(ZM,null),success:f.createElement(QM,null),error:f.createElement(Kp,null),warning:f.createElement(Yp,null),loading:f.createElement(e1,null)},Ck=e=>{const{prefixCls:t,type:n,icon:r,children:o,classNames:i,styles:a}=e,l=r||n&&tre[n],u=Hr(l,d=>{const m={...d?.style,...a?.icon};return {className:X(d.className,i?.icon),style:m}});return f.createElement("div",{className:X(`${t}-custom-content`,`${t}-${n}`)},u,f.createElement("span",{className:i?.content,style:a?.content},o))},nre=e=>{const{prefixCls:t,className:n,style:r,type:o,icon:i,content:a,classNames:l,styles:u,...d}=e,{getPrefixCls:m,className:p,style:g,classNames:b,styles:y}=jt("message"),S=t||m("message"),C=Qn(S),[w,$]=Sk(S,C),[M,T]=Kt([b,l],[y,u],{props:e});return f.createElement(aR,{...d,prefixCls:S,className:X(p,M.root,n,w,`${S}-notice-pure-panel`,$,C),style:{...T.root,...g,...r},eventKey:"pure",duration:null,content:f.createElement(Ck,{prefixCls:S,type:o,icon:i,classNames:M,styles:T},a)})};function rre(e,t){return {motionName:t??`${e}-move-up`}}function sR(e){let t;const n=new Promise(o=>{t=e(()=>{o(true);});}),r=()=>{t?.();};return r.then=(o,i)=>n.then(o,i),r.promise=n,r}const ore=8,ire=3,are=({children:e,prefixCls:t})=>{const n=Qn(t),[r,o]=Sk(t,n);return f.createElement(bk,{classNames:{list:X(r,o,n)}},e)},sre=(e,{prefixCls:t,key:n})=>f.createElement(are,{prefixCls:t,key:n},e),lre=f.forwardRef((e,t)=>{const{top:n,prefixCls:r,getContainer:o,maxCount:i,duration:a=ire,rtl:l,transitionName:u,onAllRemoved:d,pauseOnHover:m=true}=e,{getPrefixCls:p,direction:g,getPopupContainer:b}=jt("message"),{message:y}=f.useContext(wt),S=r||p("message"),C=()=>({left:"50%",transform:"translateX(-50%)",top:n??ore}),w=()=>X({[`${S}-rtl`]:l??g==="rtl"}),$=()=>rre(S,u),[M,T]=Kt([e?.classNames,y?.classNames],[e?.styles,y?.styles],{props:e}),[R,I]=yk({prefixCls:S,style:C,className:w,motion:$,closable:false,duration:a,getContainer:()=>o?.()||b?.()||document.body,maxCount:i,onAllRemoved:d,renderNotifications:sre,pauseOnHover:m});return f.useImperativeHandle(t,()=>({...R,prefixCls:S,message:y,classNames:M,styles:T})),I});let UI=0;function xk(e){const t=f.useRef(null);return [f.useMemo(()=>{const r=u=>{t.current?.close(u);},o=u=>{if(!t.current){const D=()=>{};return D.then=()=>{},D}const{open:d,prefixCls:m,message:p,classNames:g,styles:b}=t.current,y=p?.className||{},S=p?.style||{},C=p?.classNames||{},w=p?.styles||{},$=`${m}-notice`,{content:M,icon:T,type:R,key:I,className:N,style:P,onClose:O,classNames:_={},styles:B={},...V}=u;let U=I;Jr(U)||(UI+=1,U=`antd-message-${UI}`);const G={...e,...u},H=Pl(C,{props:G}),z=Pl(_,{props:G}),j=Pl(w,{props:G}),W=Pl(B,{props:G}),Y=Xy(void 0,H,z,g),Q=nR(j,W,b);return sR(D=>(d({...V,key:U,content:f.createElement(Ck,{prefixCls:m,type:R,icon:T,classNames:Y,styles:Q},M),placement:"top",className:X({[`${$}-${R}`]:R},N,y,Y.root),style:{...Q.root,...S,...P},onClose:()=>{O?.(),D();}}),()=>{r(U);}))},a={open:o,destroy:u=>{u!==void 0?r(u):t.current?.destroy();}};return ["info","success","warning","error","loading"].forEach(u=>{const d=(m,p,g)=>{let b;m&&typeof m=="object"&&"content"in m?b=m:b={content:m};let y,S;typeof p=="function"?S=p:(y=p,S=g);const C={onClose:S,duration:y,...b,type:u};return o(C)};a[u]=d;}),a},[]),f.createElement(lre,{key:"message-holder",...e,ref:t})]}function wk(e){return xk(e)}var Ox={exports:{}},Ym={},Dx={exports:{}},_x={};var WI;function cre(){return WI||(WI=1,(function(e){function t(z,j){var W=z.length;z.push(j);e:for(;0<W;){var Y=W-1>>>1,Q=z[Y];if(0<o(Q,j))z[Y]=j,z[W]=Q,W=Y;else break e}}function n(z){return z.length===0?null:z[0]}function r(z){if(z.length===0)return null;var j=z[0],W=z.pop();if(W!==j){z[0]=W;e:for(var Y=0,Q=z.length,D=Q>>>1;Y<D;){var L=2*(Y+1)-1,K=z[L],J=L+1,ee=z[J];if(0>o(K,W))J<Q&&0>o(ee,K)?(z[Y]=ee,z[J]=W,Y=J):(z[Y]=K,z[L]=W,Y=L);else if(J<Q&&0>o(ee,W))z[Y]=ee,z[J]=W,Y=J;else break e}}return j}function o(z,j){var W=z.sortIndex-j.sortIndex;return W!==0?W:z.id-j.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()};}else {var a=Date,l=a.now();e.unstable_now=function(){return a.now()-l};}var u=[],d=[],m=1,p=null,g=3,b=false,y=false,S=false,C=false,w=typeof setTimeout=="function"?setTimeout:null,$=typeof clearTimeout=="function"?clearTimeout:null,M=typeof setImmediate<"u"?setImmediate:null;function T(z){for(var j=n(d);j!==null;){if(j.callback===null)r(d);else if(j.startTime<=z)r(d),j.sortIndex=j.expirationTime,t(u,j);else break;j=n(d);}}function R(z){if(S=false,T(z),!y)if(n(u)!==null)y=true,I||(I=true,V());else {var j=n(d);j!==null&&H(R,j.startTime-z);}}var I=false,N=-1,P=5,O=-1;function _(){return C?true:!(e.unstable_now()-O<P)}function B(){if(C=false,I){var z=e.unstable_now();O=z;var j=true;try{e:{y=!1,S&&(S=!1,$(N),N=-1),b=!0;var W=g;try{t:{for(T(z),p=n(u);p!==null&&!(p.expirationTime>z&&_());){var Y=p.callback;if(typeof Y=="function"){p.callback=null,g=p.priorityLevel;var Q=Y(p.expirationTime<=z);if(z=e.unstable_now(),typeof Q=="function"){p.callback=Q,T(z),j=!0;break t}p===n(u)&&r(u),T(z);}else r(u);p=n(u);}if(p!==null)j=!0;else {var D=n(d);D!==null&&H(R,D.startTime-z),j=!1;}}break e}finally{p=null,g=W,b=!1;}j=void 0;}}finally{j?V():I=false;}}}var V;if(typeof M=="function")V=function(){M(B);};else if(typeof MessageChannel<"u"){var U=new MessageChannel,G=U.port2;U.port1.onmessage=B,V=function(){G.postMessage(null);};}else V=function(){w(B,0);};function H(z,j){N=w(function(){z(e.unstable_now());},j);}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(z){z.callback=null;},e.unstable_forceFrameRate=function(z){0>z||125<z?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):P=0<z?Math.floor(1e3/z):5;},e.unstable_getCurrentPriorityLevel=function(){return g},e.unstable_next=function(z){switch(g){case 1:case 2:case 3:var j=3;break;default:j=g;}var W=g;g=j;try{return z()}finally{g=W;}},e.unstable_requestPaint=function(){C=true;},e.unstable_runWithPriority=function(z,j){switch(z){case 1:case 2:case 3:case 4:case 5:break;default:z=3;}var W=g;g=z;try{return j()}finally{g=W;}},e.unstable_scheduleCallback=function(z,j,W){var Y=e.unstable_now();switch(typeof W=="object"&&W!==null?(W=W.delay,W=typeof W=="number"&&0<W?Y+W:Y):W=Y,z){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3;}return Q=W+Q,z={id:m++,callback:j,priorityLevel:z,startTime:W,expirationTime:Q,sortIndex:-1},W>Y?(z.sortIndex=W,t(d,z),n(u)===null&&z===n(d)&&(S?($(N),N=-1):S=true,H(R,W-Y))):(z.sortIndex=Q,t(u,z),y||b||(y=true,I||(I=true,V()))),z},e.unstable_shouldYield=_,e.unstable_wrapCallback=function(z){var j=g;return function(){var W=g;g=j;try{return z.apply(this,arguments)}finally{g=W;}}};})(_x)),_x}var GI;function ure(){return GI||(GI=1,Dx.exports=cre()),Dx.exports}var qI;function dre(){if(qI)return Ym;qI=1;var e=ure(),t=Xl(),n=Jz();function r(s){var c="https://react.dev/errors/"+s;if(1<arguments.length){c+="?args[]="+encodeURIComponent(arguments[1]);for(var h=2;h<arguments.length;h++)c+="&args[]="+encodeURIComponent(arguments[h]);}return "Minified React error #"+s+"; visit "+c+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(s){return !(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function i(s){var c=s,h=s;if(s.alternate)for(;c.return;)c=c.return;else {s=c;do c=s,(c.flags&4098)!==0&&(h=c.return),s=c.return;while(s)}return c.tag===3?h:null}function a(s){if(s.tag===13){var c=s.memoizedState;if(c===null&&(s=s.alternate,s!==null&&(c=s.memoizedState)),c!==null)return c.dehydrated}return null}function l(s){if(s.tag===31){var c=s.memoizedState;if(c===null&&(s=s.alternate,s!==null&&(c=s.memoizedState)),c!==null)return c.dehydrated}return null}function u(s){if(i(s)!==s)throw Error(r(188))}function d(s){var c=s.alternate;if(!c){if(c=i(s),c===null)throw Error(r(188));return c!==s?null:s}for(var h=s,v=c;;){var E=h.return;if(E===null)break;var A=E.alternate;if(A===null){if(v=E.return,v!==null){h=v;continue}break}if(E.child===A.child){for(A=E.child;A;){if(A===h)return u(E),s;if(A===v)return u(E),c;A=A.sibling;}throw Error(r(188))}if(h.return!==v.return)h=E,v=A;else {for(var k=false,Z=E.child;Z;){if(Z===h){k=true,h=E,v=A;break}if(Z===v){k=true,v=E,h=A;break}Z=Z.sibling;}if(!k){for(Z=A.child;Z;){if(Z===h){k=true,h=A,v=E;break}if(Z===v){k=true,v=A,h=E;break}Z=Z.sibling;}if(!k)throw Error(r(189))}}if(h.alternate!==v)throw Error(r(190))}if(h.tag!==3)throw Error(r(188));return h.stateNode.current===h?s:c}function m(s){var c=s.tag;if(c===5||c===26||c===27||c===6)return s;for(s=s.child;s!==null;){if(c=m(s),c!==null)return c;s=s.sibling;}return null}var p=Object.assign,g=Symbol.for("react.element"),b=Symbol.for("react.transitional.element"),y=Symbol.for("react.portal"),S=Symbol.for("react.fragment"),C=Symbol.for("react.strict_mode"),w=Symbol.for("react.profiler"),$=Symbol.for("react.consumer"),M=Symbol.for("react.context"),T=Symbol.for("react.forward_ref"),R=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),N=Symbol.for("react.memo"),P=Symbol.for("react.lazy"),O=Symbol.for("react.activity"),_=Symbol.for("react.memo_cache_sentinel"),B=Symbol.iterator;function V(s){return s===null||typeof s!="object"?null:(s=B&&s[B]||s["@@iterator"],typeof s=="function"?s:null)}var U=Symbol.for("react.client.reference");function G(s){if(s==null)return null;if(typeof s=="function")return s.$$typeof===U?null:s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case S:return "Fragment";case w:return "Profiler";case C:return "StrictMode";case R:return "Suspense";case I:return "SuspenseList";case O:return "Activity"}if(typeof s=="object")switch(s.$$typeof){case y:return "Portal";case M:return s.displayName||"Context";case $:return (s._context.displayName||"Context")+".Consumer";case T:var c=s.render;return s=s.displayName,s||(s=c.displayName||c.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case N:return c=s.displayName||null,c!==null?c:G(s.type)||"Memo";case P:c=s._payload,s=s._init;try{return G(s(c))}catch{}}return null}var H=Array.isArray,z=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,j=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,W={pending:false,data:null,method:null,action:null},Y=[],Q=-1;function D(s){return {current:s}}function L(s){0>Q||(s.current=Y[Q],Y[Q]=null,Q--);}function K(s,c){Q++,Y[Q]=s.current,s.current=c;}var J=D(null),ee=D(null),te=D(null),re=D(null);function ie(s,c){switch(K(te,c),K(ee,s),K(J,null),c.nodeType){case 9:case 11:s=(s=c.documentElement)&&(s=s.namespaceURI)?A4(s):0;break;default:if(s=c.tagName,c=c.namespaceURI)c=A4(c),s=N4(c,s);else switch(s){case "svg":s=1;break;case "math":s=2;break;default:s=0;}}L(J),K(J,s);}function de(){L(J),L(ee),L(te);}function ne(s){s.memoizedState!==null&&K(re,s);var c=J.current,h=N4(c,s.type);c!==h&&(K(ee,s),K(J,h));}function ce(s){ee.current===s&&(L(J),L(ee)),re.current===s&&(L(re),Fm._currentValue=W);}var fe,se;function Me(s){if(fe===void 0)try{throw Error()}catch(h){var c=h.stack.trim().match(/\n( *(at )?)/);fe=c&&c[1]||"",se=-1<h.stack.indexOf(`
at`)?" (<anonymous>)":-1<h.stack.indexOf("@")?"@unknown:0:0":"";}return `
`+fe+s+se}var ae=false;function pe(s,c){if(!s||ae)return "";ae=true;var h=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var v={DetermineComponentFrameRoot:function(){try{if(c){var Ve=function(){throw Error()};if(Object.defineProperty(Ve.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Ve,[]);}catch(Ie){var Te=Ie;}Reflect.construct(s,[],Ve);}else {try{Ve.call();}catch(Ie){Te=Ie;}s.call(Ve.prototype);}}else {try{throw Error()}catch(Ie){Te=Ie;}(Ve=s())&&typeof Ve.catch=="function"&&Ve.catch(function(){});}}catch(Ie){if(Ie&&Te&&typeof Ie.stack=="string")return [Ie.stack,Te.stack]}return [null,null]}};v.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var E=Object.getOwnPropertyDescriptor(v.DetermineComponentFrameRoot,"name");E&&E.configurable&&Object.defineProperty(v.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var A=v.DetermineComponentFrameRoot(),k=A[0],Z=A[1];if(k&&Z){var le=k.split(`
`),Ee=Z.split(`
`);for(E=v=0;v<le.length&&!le[v].includes("DetermineComponentFrameRoot");)v++;for(;E<Ee.length&&!Ee[E].includes("DetermineComponentFrameRoot");)E++;if(v===le.length||E===Ee.length)for(v=le.length-1,E=Ee.length-1;1<=v&&0<=E&&le[v]!==Ee[E];)E--;for(;1<=v&&0<=E;v--,E--)if(le[v]!==Ee[E]){if(v!==1||E!==1)do if(v--,E--,0>E||le[v]!==Ee[E]){var Le=`
`+le[v].replace(" at new "," at ");return s.displayName&&Le.includes("<anonymous>")&&(Le=Le.replace("<anonymous>",s.displayName)),Le}while(1<=v&&0<=E);break}}}finally{ae=false,Error.prepareStackTrace=h;}return (h=s?s.displayName||s.name:"")?Me(h):""}function Ce(s,c){switch(s.tag){case 26:case 27:case 5:return Me(s.type);case 16:return Me("Lazy");case 13:return s.child!==c&&c!==null?Me("Suspense Fallback"):Me("Suspense");case 19:return Me("SuspenseList");case 0:case 15:return pe(s.type,false);case 11:return pe(s.type.render,false);case 1:return pe(s.type,true);case 31:return Me("Activity");default:return ""}}function xe(s){try{var c="",h=null;do c+=Ce(s,h),h=s,s=s.return;while(s);return c}catch(v){return `
Error generating stack: `+v.message+`
`+v.stack}}var Ae=Object.prototype.hasOwnProperty,Xe=e.unstable_scheduleCallback,Ne=e.unstable_cancelCallback,ue=e.unstable_shouldYield,ge=e.unstable_requestPaint,Pe=e.unstable_now,je=e.unstable_getCurrentPriorityLevel,qe=e.unstable_ImmediatePriority,Ue=e.unstable_UserBlockingPriority,et=e.unstable_NormalPriority,rt=e.unstable_LowPriority,Ke=e.unstable_IdlePriority,_e=e.log,We=e.unstable_setDisableYieldValue,Ze=null,Be=null;function Oe(s){if(typeof _e=="function"&&We(s),Be&&typeof Be.setStrictMode=="function")try{Be.setStrictMode(Ze,s);}catch{}}var lt=Math.clz32?Math.clz32:Bt,It=Math.log,mt=Math.LN2;function Bt(s){return s>>>=0,s===0?32:31-(It(s)/mt|0)|0}var xt=256,Tt=262144,ut=4194304;function dt(s){var c=s&42;if(c!==0)return c;switch(s&-s){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return s&261888;case 262144:case 524288:case 1048576:case 2097152:return s&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return s&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return s}}function gt(s,c,h){var v=s.pendingLanes;if(v===0)return 0;var E=0,A=s.suspendedLanes,k=s.pingedLanes;s=s.warmLanes;var Z=v&134217727;return Z!==0?(v=Z&~A,v!==0?E=dt(v):(k&=Z,k!==0?E=dt(k):h||(h=Z&~s,h!==0&&(E=dt(h))))):(Z=v&~A,Z!==0?E=dt(Z):k!==0?E=dt(k):h||(h=v&~s,h!==0&&(E=dt(h)))),E===0?0:c!==0&&c!==E&&(c&A)===0&&(A=E&-E,h=c&-c,A>=h||A===32&&(h&4194048)!==0)?c:E}function Fe(s,c){return (s.pendingLanes&~(s.suspendedLanes&~s.pingedLanes)&c)===0}function Qe(s,c){switch(s){case 1:case 2:case 4:case 8:case 64:return c+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return c+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return -1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return -1;default:return -1}}function ye(){var s=ut;return ut<<=1,(ut&62914560)===0&&(ut=4194304),s}function be(s){for(var c=[],h=0;31>h;h++)c.push(s);return c}function Se(s,c){s.pendingLanes|=c,c!==268435456&&(s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0);}function he(s,c,h,v,E,A){var k=s.pendingLanes;s.pendingLanes=h,s.suspendedLanes=0,s.pingedLanes=0,s.warmLanes=0,s.expiredLanes&=h,s.entangledLanes&=h,s.errorRecoveryDisabledLanes&=h,s.shellSuspendCounter=0;var Z=s.entanglements,le=s.expirationTimes,Ee=s.hiddenUpdates;for(h=k&~h;0<h;){var Le=31-lt(h),Ve=1<<Le;Z[Le]=0,le[Le]=-1;var Te=Ee[Le];if(Te!==null)for(Ee[Le]=null,Le=0;Le<Te.length;Le++){var Ie=Te[Le];Ie!==null&&(Ie.lane&=-536870913);}h&=~Ve;}v!==0&&De(s,v,0),A!==0&&E===0&&s.tag!==0&&(s.suspendedLanes|=A&~(k&~c));}function De(s,c,h){s.pendingLanes|=c,s.suspendedLanes&=~c;var v=31-lt(c);s.entangledLanes|=c,s.entanglements[v]=s.entanglements[v]|1073741824|h&261930;}function $e(s,c){var h=s.entangledLanes|=c;for(s=s.entanglements;h;){var v=31-lt(h),E=1<<v;E&c|s[v]&c&&(s[v]|=c),h&=~E;}}function ke(s,c){var h=c&-c;return h=(h&42)!==0?1:Ge(h),(h&(s.suspendedLanes|c))!==0?0:h}function Ge(s){switch(s){case 2:s=1;break;case 8:s=4;break;case 32:s=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:s=128;break;case 268435456:s=134217728;break;default:s=0;}return s}function ot(s){return s&=-s,2<s?8<s?(s&134217727)!==0?32:268435456:8:2}function ht(){var s=j.p;return s!==0?s:(s=window.event,s===void 0?32:J4(s.type))}function $t(s,c){var h=j.p;try{return j.p=s,c()}finally{j.p=h;}}var Rt=Math.random().toString(36).slice(2),Ot="__reactFiber$"+Rt,Sn="__reactProps$"+Rt,Hn="__reactContainer$"+Rt,Re="__reactEvents$"+Rt,ct="__reactListeners$"+Rt,tt="__reactHandles$"+Rt,yt="__reactResources$"+Rt,At="__reactMarker$"+Rt;function en(s){delete s[Ot],delete s[Sn],delete s[Re],delete s[ct],delete s[tt];}function Zt(s){var c=s[Ot];if(c)return c;for(var h=s.parentNode;h;){if(c=h[Hn]||h[Ot]){if(h=c.alternate,c.child!==null||h!==null&&h.child!==null)for(s=L4(s);s!==null;){if(h=s[Ot])return h;s=L4(s);}return c}s=h,h=s.parentNode;}return null}function mn(s){if(s=s[Ot]||s[Hn]){var c=s.tag;if(c===5||c===6||c===13||c===31||c===26||c===27||c===3)return s}return null}function Un(s){var c=s.tag;if(c===5||c===26||c===27||c===6)return s.stateNode;throw Error(r(33))}function rr(s){var c=s[yt];return c||(c=s[yt]={hoistableStyles:new Map,hoistableScripts:new Map}),c}function vn(s){s[At]=true;}var Mi=new Set,Za={};function Wn(s,c){_o(s,c),_o(s+"Capture",c);}function _o(s,c){for(Za[s]=c,s=0;s<c.length;s++)Mi.add(c[s]);}var nm=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),kt={},Ir={};function Or(s){return Ae.call(Ir,s)?true:Ae.call(kt,s)?false:nm.test(s)?Ir[s]=true:(kt[s]=true,false)}function Ra(s,c,h){if(Or(c))if(h===null)s.removeAttribute(c);else {switch(typeof h){case "undefined":case "function":case "symbol":s.removeAttribute(c);return;case "boolean":var v=c.toLowerCase().slice(0,5);if(v!=="data-"&&v!=="aria-"){s.removeAttribute(c);return}}s.setAttribute(c,""+h);}}function Ri(s,c,h){if(h===null)s.removeAttribute(c);else {switch(typeof h){case "undefined":case "function":case "symbol":case "boolean":s.removeAttribute(c);return}s.setAttribute(c,""+h);}}function Bo(s,c,h,v){if(v===null)s.removeAttribute(h);else {switch(typeof v){case "undefined":case "function":case "symbol":case "boolean":s.removeAttribute(h);return}s.setAttributeNS(c,h,""+v);}}function Ur(s){switch(typeof s){case "bigint":case "boolean":case "number":case "string":case "undefined":return s;case "object":return s;default:return ""}}function sc(s){var c=s.type;return (s=s.nodeName)&&s.toLowerCase()==="input"&&(c==="checkbox"||c==="radio")}function _g(s,c,h){var v=Object.getOwnPropertyDescriptor(s.constructor.prototype,c);if(!s.hasOwnProperty(c)&&typeof v<"u"&&typeof v.get=="function"&&typeof v.set=="function"){var E=v.get,A=v.set;return Object.defineProperty(s,c,{configurable:true,get:function(){return E.call(this)},set:function(k){h=""+k,A.call(this,k);}}),Object.defineProperty(s,c,{enumerable:v.enumerable}),{getValue:function(){return h},setValue:function(k){h=""+k;},stopTracking:function(){s._valueTracker=null,delete s[c];}}}}function lc(s){if(!s._valueTracker){var c=sc(s)?"checked":"value";s._valueTracker=_g(s,c,""+s[c]);}}function Nu(s){if(!s)return false;var c=s._valueTracker;if(!c)return true;var h=c.getValue(),v="";return s&&(v=sc(s)?s.checked?"true":"false":s.value),s=v,s!==h?(c.setValue(s),true):false}function Pu(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}var ft=/[\n"\\]/g;function Ht(s){return s.replace(ft,function(c){return "\\"+c.charCodeAt(0).toString(16)+" "})}function qs(s,c,h,v,E,A,k,Z){s.name="",k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"?s.type=k:s.removeAttribute("type"),c!=null?k==="number"?(c===0&&s.value===""||s.value!=c)&&(s.value=""+Ur(c)):s.value!==""+Ur(c)&&(s.value=""+Ur(c)):k!=="submit"&&k!=="reset"||s.removeAttribute("value"),c!=null?Iu(s,k,Ur(c)):h!=null?Iu(s,k,Ur(h)):v!=null&&s.removeAttribute("value"),E==null&&A!=null&&(s.defaultChecked=!!A),E!=null&&(s.checked=E&&typeof E!="function"&&typeof E!="symbol"),Z!=null&&typeof Z!="function"&&typeof Z!="symbol"&&typeof Z!="boolean"?s.name=""+Ur(Z):s.removeAttribute("name");}function Bg(s,c,h,v,E,A,k,Z){if(A!=null&&typeof A!="function"&&typeof A!="symbol"&&typeof A!="boolean"&&(s.type=A),c!=null||h!=null){if(!(A!=="submit"&&A!=="reset"||c!=null)){lc(s);return}h=h!=null?""+Ur(h):"",c=c!=null?""+Ur(c):h,Z||c===s.value||(s.value=c),s.defaultValue=c;}v=v??E,v=typeof v!="function"&&typeof v!="symbol"&&!!v,s.checked=Z?s.checked:!!v,s.defaultChecked=!!v,k!=null&&typeof k!="function"&&typeof k!="symbol"&&typeof k!="boolean"&&(s.name=k),lc(s);}function Iu(s,c,h){c==="number"&&Pu(s.ownerDocument)===s||s.defaultValue===""+h||(s.defaultValue=""+h);}function Ja(s,c,h,v){if(s=s.options,c){c={};for(var E=0;E<h.length;E++)c["$"+h[E]]=true;for(h=0;h<s.length;h++)E=c.hasOwnProperty("$"+s[h].value),s[h].selected!==E&&(s[h].selected=E),E&&v&&(s[h].defaultSelected=true);}else {for(h=""+Ur(h),c=null,E=0;E<s.length;E++){if(s[E].value===h){s[E].selected=true,v&&(s[E].defaultSelected=true);return}c!==null||s[E].disabled||(c=s[E]);}c!==null&&(c.selected=true);}}function Lg(s,c,h){if(c!=null&&(c=""+Ur(c),c!==s.value&&(s.value=c),h==null)){s.defaultValue!==c&&(s.defaultValue=c);return}s.defaultValue=h!=null?""+Ur(h):"";}function E6(s,c,h,v){if(c==null){if(v!=null){if(h!=null)throw Error(r(92));if(H(v)){if(1<v.length)throw Error(r(93));v=v[0];}h=v;}h==null&&(h=""),c=h;}h=Ur(c),s.defaultValue=h,v=s.textContent,v===h&&v!==""&&v!==null&&(s.value=v),lc(s);}function Ou(s,c){if(c){var h=s.firstChild;if(h&&h===s.lastChild&&h.nodeType===3){h.nodeValue=c;return}}s.textContent=c;}var IK=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function M6(s,c,h){var v=c.indexOf("--")===0;h==null||typeof h=="boolean"||h===""?v?s.setProperty(c,""):c==="float"?s.cssFloat="":s[c]="":v?s.setProperty(c,h):typeof h!="number"||h===0||IK.has(c)?c==="float"?s.cssFloat=h:s[c]=(""+h).trim():s[c]=h+"px";}function R6(s,c,h){if(c!=null&&typeof c!="object")throw Error(r(62));if(s=s.style,h!=null){for(var v in h)!h.hasOwnProperty(v)||c!=null&&c.hasOwnProperty(v)||(v.indexOf("--")===0?s.setProperty(v,""):v==="float"?s.cssFloat="":s[v]="");for(var E in c)v=c[E],c.hasOwnProperty(E)&&h[E]!==v&&M6(s,E,v);}else for(var A in c)c.hasOwnProperty(A)&&M6(s,A,c[A]);}function sS(s){if(s.indexOf("-")===-1)return false;switch(s){case "annotation-xml":case "color-profile":case "font-face":case "font-face-src":case "font-face-uri":case "font-face-format":case "font-face-name":case "missing-glyph":return false;default:return true}}var OK=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),DK=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function zg(s){return DK.test(""+s)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":s}function es(){}var lS=null;function cS(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var Du=null,_u=null;function T6(s){var c=mn(s);if(c&&(s=c.stateNode)){var h=s[Sn]||null;e:switch(s=c.stateNode,c.type){case "input":if(qs(s,h.value,h.defaultValue,h.defaultValue,h.checked,h.defaultChecked,h.type,h.name),c=h.name,h.type==="radio"&&c!=null){for(h=s;h.parentNode;)h=h.parentNode;for(h=h.querySelectorAll('input[name="'+Ht(""+c)+'"][type="radio"]'),c=0;c<h.length;c++){var v=h[c];if(v!==s&&v.form===s.form){var E=v[Sn]||null;if(!E)throw Error(r(90));qs(v,E.value,E.defaultValue,E.defaultValue,E.checked,E.defaultChecked,E.type,E.name);}}for(c=0;c<h.length;c++)v=h[c],v.form===s.form&&Nu(v);}break e;case "textarea":Lg(s,h.value,h.defaultValue);break e;case "select":c=h.value,c!=null&&Ja(s,!!h.multiple,c,false);}}}var uS=false;function A6(s,c,h){if(uS)return s(c,h);uS=true;try{var v=s(c);return v}finally{if(uS=false,(Du!==null||_u!==null)&&(Ev(),Du&&(c=Du,s=_u,_u=Du=null,T6(c),s)))for(c=0;c<s.length;c++)T6(s[c]);}}function rm(s,c){var h=s.stateNode;if(h===null)return null;var v=h[Sn]||null;if(v===null)return null;h=v[c];e:switch(c){case "onClick":case "onClickCapture":case "onDoubleClick":case "onDoubleClickCapture":case "onMouseDown":case "onMouseDownCapture":case "onMouseMove":case "onMouseMoveCapture":case "onMouseUp":case "onMouseUpCapture":case "onMouseEnter":(v=!v.disabled)||(s=s.type,v=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!v;break e;default:s=false;}if(s)return null;if(h&&typeof h!="function")throw Error(r(231,c,typeof h));return h}var ts=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),dS=false;if(ts)try{var om={};Object.defineProperty(om,"passive",{get:function(){dS=!0;}}),window.addEventListener("test",om,om),window.removeEventListener("test",om,om);}catch{dS=false;}var Ks=null,fS=null,kg=null;function N6(){if(kg)return kg;var s,c=fS,h=c.length,v,E="value"in Ks?Ks.value:Ks.textContent,A=E.length;for(s=0;s<h&&c[s]===E[s];s++);var k=h-s;for(v=1;v<=k&&c[h-v]===E[A-v];v++);return kg=E.slice(s,1<v?1-v:void 0)}function Fg(s){var c=s.keyCode;return "charCode"in s?(s=s.charCode,s===0&&c===13&&(s=13)):s=c,s===10&&(s=13),32<=s||s===13?s:0}function Hg(){return true}function P6(){return false}function Lo(s){function c(h,v,E,A,k){this._reactName=h,this._targetInst=E,this.type=v,this.nativeEvent=A,this.target=k,this.currentTarget=null;for(var Z in s)s.hasOwnProperty(Z)&&(h=s[Z],this[Z]=h?h(A):A[Z]);return this.isDefaultPrevented=(A.defaultPrevented!=null?A.defaultPrevented:A.returnValue===false)?Hg:P6,this.isPropagationStopped=P6,this}return p(c.prototype,{preventDefault:function(){this.defaultPrevented=true;var h=this.nativeEvent;h&&(h.preventDefault?h.preventDefault():typeof h.returnValue!="unknown"&&(h.returnValue=false),this.isDefaultPrevented=Hg);},stopPropagation:function(){var h=this.nativeEvent;h&&(h.stopPropagation?h.stopPropagation():typeof h.cancelBubble!="unknown"&&(h.cancelBubble=true),this.isPropagationStopped=Hg);},persist:function(){},isPersistent:Hg}),c}var cc={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Vg=Lo(cc),im=p({},cc,{view:0,detail:0}),_K=Lo(im),mS,hS,am,jg=p({},im,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:gS,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return "movementX"in s?s.movementX:(s!==am&&(am&&s.type==="mousemove"?(mS=s.screenX-am.screenX,hS=s.screenY-am.screenY):hS=mS=0,am=s),mS)},movementY:function(s){return "movementY"in s?s.movementY:hS}}),I6=Lo(jg),BK=p({},jg,{dataTransfer:0}),LK=Lo(BK),zK=p({},im,{relatedTarget:0}),pS=Lo(zK),kK=p({},cc,{animationName:0,elapsedTime:0,pseudoElement:0}),FK=Lo(kK),HK=p({},cc,{clipboardData:function(s){return "clipboardData"in s?s.clipboardData:window.clipboardData}}),VK=Lo(HK),jK=p({},cc,{data:0}),O6=Lo(jK),UK={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},WK={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},GK={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function qK(s){var c=this.nativeEvent;return c.getModifierState?c.getModifierState(s):(s=GK[s])?!!c[s]:false}function gS(){return qK}var KK=p({},im,{key:function(s){if(s.key){var c=UK[s.key]||s.key;if(c!=="Unidentified")return c}return s.type==="keypress"?(s=Fg(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?WK[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:gS,charCode:function(s){return s.type==="keypress"?Fg(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?Fg(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),YK=Lo(KK),XK=p({},jg,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),D6=Lo(XK),QK=p({},im,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:gS}),ZK=Lo(QK),JK=p({},cc,{propertyName:0,elapsedTime:0,pseudoElement:0}),eY=Lo(JK),tY=p({},jg,{deltaX:function(s){return "deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return "deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),nY=Lo(tY),rY=p({},cc,{newState:0,oldState:0}),oY=Lo(rY),iY=[9,13,27,32],vS=ts&&"CompositionEvent"in window,sm=null;ts&&"documentMode"in document&&(sm=document.documentMode);var aY=ts&&"TextEvent"in window&&!sm,_6=ts&&(!vS||sm&&8<sm&&11>=sm),B6=" ",L6=false;function z6(s,c){switch(s){case "keyup":return iY.indexOf(c.keyCode)!==-1;case "keydown":return c.keyCode!==229;case "keypress":case "mousedown":case "focusout":return true;default:return false}}function k6(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var Bu=false;function sY(s,c){switch(s){case "compositionend":return k6(c);case "keypress":return c.which!==32?null:(L6=true,B6);case "textInput":return s=c.data,s===B6&&L6?null:s;default:return null}}function lY(s,c){if(Bu)return s==="compositionend"||!vS&&z6(s,c)?(s=N6(),kg=fS=Ks=null,Bu=false,s):null;switch(s){case "paste":return null;case "keypress":if(!(c.ctrlKey||c.altKey||c.metaKey)||c.ctrlKey&&c.altKey){if(c.char&&1<c.char.length)return c.char;if(c.which)return String.fromCharCode(c.which)}return null;case "compositionend":return _6&&c.locale!=="ko"?null:c.data;default:return null}}var cY={color:true,date:true,datetime:true,"datetime-local":true,email:true,month:true,number:true,password:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true};function F6(s){var c=s&&s.nodeName&&s.nodeName.toLowerCase();return c==="input"?!!cY[s.type]:c==="textarea"}function H6(s,c,h,v){Du?_u?_u.push(v):_u=[v]:Du=v,c=Iv(c,"onChange"),0<c.length&&(h=new Vg("onChange","change",null,h,v),s.push({event:h,listeners:c}));}var lm=null,cm=null;function uY(s){w4(s,0);}function Ug(s){var c=Un(s);if(Nu(c))return s}function V6(s,c){if(s==="change")return c}var j6=false;if(ts){var bS;if(ts){var yS="oninput"in document;if(!yS){var U6=document.createElement("div");U6.setAttribute("oninput","return;"),yS=typeof U6.oninput=="function";}bS=yS;}else bS=false;j6=bS&&(!document.documentMode||9<document.documentMode);}function W6(){lm&&(lm.detachEvent("onpropertychange",G6),cm=lm=null);}function G6(s){if(s.propertyName==="value"&&Ug(cm)){var c=[];H6(c,cm,s,cS(s)),A6(uY,c);}}function dY(s,c,h){s==="focusin"?(W6(),lm=c,cm=h,lm.attachEvent("onpropertychange",G6)):s==="focusout"&&W6();}function fY(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return Ug(cm)}function mY(s,c){if(s==="click")return Ug(c)}function hY(s,c){if(s==="input"||s==="change")return Ug(c)}function pY(s,c){return s===c&&(s!==0||1/s===1/c)||s!==s&&c!==c}var ti=typeof Object.is=="function"?Object.is:pY;function um(s,c){if(ti(s,c))return true;if(typeof s!="object"||s===null||typeof c!="object"||c===null)return false;var h=Object.keys(s),v=Object.keys(c);if(h.length!==v.length)return false;for(v=0;v<h.length;v++){var E=h[v];if(!Ae.call(c,E)||!ti(s[E],c[E]))return false}return true}function q6(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function K6(s,c){var h=q6(s);s=0;for(var v;h;){if(h.nodeType===3){if(v=s+h.textContent.length,s<=c&&v>=c)return {node:h,offset:c-s};s=v;}e:{for(;h;){if(h.nextSibling){h=h.nextSibling;break e}h=h.parentNode;}h=void 0;}h=q6(h);}}function Y6(s,c){return s&&c?s===c?true:s&&s.nodeType===3?false:c&&c.nodeType===3?Y6(s,c.parentNode):"contains"in s?s.contains(c):s.compareDocumentPosition?!!(s.compareDocumentPosition(c)&16):false:false}function X6(s){s=s!=null&&s.ownerDocument!=null&&s.ownerDocument.defaultView!=null?s.ownerDocument.defaultView:window;for(var c=Pu(s.document);c instanceof s.HTMLIFrameElement;){try{var h=typeof c.contentWindow.location.href=="string";}catch{h=false;}if(h)s=c.contentWindow;else break;c=Pu(s.document);}return c}function SS(s){var c=s&&s.nodeName&&s.nodeName.toLowerCase();return c&&(c==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||c==="textarea"||s.contentEditable==="true")}var gY=ts&&"documentMode"in document&&11>=document.documentMode,Lu=null,CS=null,dm=null,xS=false;function Q6(s,c,h){var v=h.window===h?h.document:h.nodeType===9?h:h.ownerDocument;xS||Lu==null||Lu!==Pu(v)||(v=Lu,"selectionStart"in v&&SS(v)?v={start:v.selectionStart,end:v.selectionEnd}:(v=(v.ownerDocument&&v.ownerDocument.defaultView||window).getSelection(),v={anchorNode:v.anchorNode,anchorOffset:v.anchorOffset,focusNode:v.focusNode,focusOffset:v.focusOffset}),dm&&um(dm,v)||(dm=v,v=Iv(CS,"onSelect"),0<v.length&&(c=new Vg("onSelect","select",null,c,h),s.push({event:c,listeners:v}),c.target=Lu)));}function uc(s,c){var h={};return h[s.toLowerCase()]=c.toLowerCase(),h["Webkit"+s]="webkit"+c,h["Moz"+s]="moz"+c,h}var zu={animationend:uc("Animation","AnimationEnd"),animationiteration:uc("Animation","AnimationIteration"),animationstart:uc("Animation","AnimationStart"),transitionrun:uc("Transition","TransitionRun"),transitionstart:uc("Transition","TransitionStart"),transitioncancel:uc("Transition","TransitionCancel"),transitionend:uc("Transition","TransitionEnd")},wS={},Z6={};ts&&(Z6=document.createElement("div").style,"AnimationEvent"in window||(delete zu.animationend.animation,delete zu.animationiteration.animation,delete zu.animationstart.animation),"TransitionEvent"in window||delete zu.transitionend.transition);function dc(s){if(wS[s])return wS[s];if(!zu[s])return s;var c=zu[s],h;for(h in c)if(c.hasOwnProperty(h)&&h in Z6)return wS[s]=c[h];return s}var J6=dc("animationend"),eN=dc("animationiteration"),tN=dc("animationstart"),vY=dc("transitionrun"),bY=dc("transitionstart"),yY=dc("transitioncancel"),nN=dc("transitionend"),rN=new Map,$S="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");$S.push("scrollEnd");function Zi(s,c){rN.set(s,c),Wn(c,[s]);}var Wg=typeof reportError=="function"?reportError:function(s){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var c=new window.ErrorEvent("error",{bubbles:true,cancelable:true,message:typeof s=="object"&&s!==null&&typeof s.message=="string"?String(s.message):String(s),error:s});if(!window.dispatchEvent(c))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",s);return}console.error(s);},Ti=[],ku=0,ES=0;function Gg(){for(var s=ku,c=ES=ku=0;c<s;){var h=Ti[c];Ti[c++]=null;var v=Ti[c];Ti[c++]=null;var E=Ti[c];Ti[c++]=null;var A=Ti[c];if(Ti[c++]=null,v!==null&&E!==null){var k=v.pending;k===null?E.next=E:(E.next=k.next,k.next=E),v.pending=E;}A!==0&&oN(h,E,A);}}function qg(s,c,h,v){Ti[ku++]=s,Ti[ku++]=c,Ti[ku++]=h,Ti[ku++]=v,ES|=v,s.lanes|=v,s=s.alternate,s!==null&&(s.lanes|=v);}function MS(s,c,h,v){return qg(s,c,h,v),Kg(s)}function fc(s,c){return qg(s,null,null,c),Kg(s)}function oN(s,c,h){s.lanes|=h;var v=s.alternate;v!==null&&(v.lanes|=h);for(var E=false,A=s.return;A!==null;)A.childLanes|=h,v=A.alternate,v!==null&&(v.childLanes|=h),A.tag===22&&(s=A.stateNode,s===null||s._visibility&1||(E=true)),s=A,A=A.return;return s.tag===3?(A=s.stateNode,E&&c!==null&&(E=31-lt(h),s=A.hiddenUpdates,v=s[E],v===null?s[E]=[c]:v.push(c),c.lane=h|536870912),A):null}function Kg(s){if(50<Om)throw Om=0,_C=null,Error(r(185));for(var c=s.return;c!==null;)s=c,c=s.return;return s.tag===3?s.stateNode:null}var Fu={};function SY(s,c,h,v){this.tag=s,this.key=h,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=c,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=v,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null;}function ni(s,c,h,v){return new SY(s,c,h,v)}function RS(s){return s=s.prototype,!(!s||!s.isReactComponent)}function ns(s,c){var h=s.alternate;return h===null?(h=ni(s.tag,c,s.key,s.mode),h.elementType=s.elementType,h.type=s.type,h.stateNode=s.stateNode,h.alternate=s,s.alternate=h):(h.pendingProps=c,h.type=s.type,h.flags=0,h.subtreeFlags=0,h.deletions=null),h.flags=s.flags&65011712,h.childLanes=s.childLanes,h.lanes=s.lanes,h.child=s.child,h.memoizedProps=s.memoizedProps,h.memoizedState=s.memoizedState,h.updateQueue=s.updateQueue,c=s.dependencies,h.dependencies=c===null?null:{lanes:c.lanes,firstContext:c.firstContext},h.sibling=s.sibling,h.index=s.index,h.ref=s.ref,h.refCleanup=s.refCleanup,h}function iN(s,c){s.flags&=65011714;var h=s.alternate;return h===null?(s.childLanes=0,s.lanes=c,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=h.childLanes,s.lanes=h.lanes,s.child=h.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=h.memoizedProps,s.memoizedState=h.memoizedState,s.updateQueue=h.updateQueue,s.type=h.type,c=h.dependencies,s.dependencies=c===null?null:{lanes:c.lanes,firstContext:c.firstContext}),s}function Yg(s,c,h,v,E,A){var k=0;if(v=s,typeof s=="function")RS(s)&&(k=1);else if(typeof s=="string")k=EX(s,h,J.current)?26:s==="html"||s==="head"||s==="body"?27:5;else e:switch(s){case O:return s=ni(31,h,c,E),s.elementType=O,s.lanes=A,s;case S:return mc(h.children,E,A,c);case C:k=8,E|=24;break;case w:return s=ni(12,h,c,E|2),s.elementType=w,s.lanes=A,s;case R:return s=ni(13,h,c,E),s.elementType=R,s.lanes=A,s;case I:return s=ni(19,h,c,E),s.elementType=I,s.lanes=A,s;default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case M:k=10;break e;case $:k=9;break e;case T:k=11;break e;case N:k=14;break e;case P:k=16,v=null;break e}k=29,h=Error(r(130,s===null?"null":typeof s,"")),v=null;}return c=ni(k,h,c,E),c.elementType=s,c.type=v,c.lanes=A,c}function mc(s,c,h,v){return s=ni(7,s,v,c),s.lanes=h,s}function TS(s,c,h){return s=ni(6,s,null,c),s.lanes=h,s}function aN(s){var c=ni(18,null,null,0);return c.stateNode=s,c}function AS(s,c,h){return c=ni(4,s.children!==null?s.children:[],s.key,c),c.lanes=h,c.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},c}var sN=new WeakMap;function Ai(s,c){if(typeof s=="object"&&s!==null){var h=sN.get(s);return h!==void 0?h:(c={value:s,source:c,stack:xe(c)},sN.set(s,c),c)}return {value:s,source:c,stack:xe(c)}}var Hu=[],Vu=0,Xg=null,fm=0,Ni=[],Pi=0,Ys=null,Ta=1,Aa="";function rs(s,c){Hu[Vu++]=fm,Hu[Vu++]=Xg,Xg=s,fm=c;}function lN(s,c,h){Ni[Pi++]=Ta,Ni[Pi++]=Aa,Ni[Pi++]=Ys,Ys=s;var v=Ta;s=Aa;var E=32-lt(v)-1;v&=~(1<<E),h+=1;var A=32-lt(c)+E;if(30<A){var k=E-E%5;A=(v&(1<<k)-1).toString(32),v>>=k,E-=k,Ta=1<<32-lt(c)+E|h<<E|v,Aa=A+s;}else Ta=1<<A|h<<E|v,Aa=s;}function NS(s){s.return!==null&&(rs(s,1),lN(s,1,0));}function PS(s){for(;s===Xg;)Xg=Hu[--Vu],Hu[Vu]=null,fm=Hu[--Vu],Hu[Vu]=null;for(;s===Ys;)Ys=Ni[--Pi],Ni[Pi]=null,Aa=Ni[--Pi],Ni[Pi]=null,Ta=Ni[--Pi],Ni[Pi]=null;}function cN(s,c){Ni[Pi++]=Ta,Ni[Pi++]=Aa,Ni[Pi++]=Ys,Ta=c.id,Aa=c.overflow,Ys=s;}var Wr=null,Gn=null,hn=false,Xs=null,Ii=false,IS=Error(r(519));function Qs(s){var c=Error(r(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw mm(Ai(c,s)),IS}function uN(s){var c=s.stateNode,h=s.type,v=s.memoizedProps;switch(c[Ot]=s,c[Sn]=v,h){case "dialog":nn("cancel",c),nn("close",c);break;case "iframe":case "object":case "embed":nn("load",c);break;case "video":case "audio":for(h=0;h<_m.length;h++)nn(_m[h],c);break;case "source":nn("error",c);break;case "img":case "image":case "link":nn("error",c),nn("load",c);break;case "details":nn("toggle",c);break;case "input":nn("invalid",c),Bg(c,v.value,v.defaultValue,v.checked,v.defaultChecked,v.type,v.name,true);break;case "select":nn("invalid",c);break;case "textarea":nn("invalid",c),E6(c,v.value,v.defaultValue,v.children);}h=v.children,typeof h!="string"&&typeof h!="number"&&typeof h!="bigint"||c.textContent===""+h||v.suppressHydrationWarning===true||R4(c.textContent,h)?(v.popover!=null&&(nn("beforetoggle",c),nn("toggle",c)),v.onScroll!=null&&nn("scroll",c),v.onScrollEnd!=null&&nn("scrollend",c),v.onClick!=null&&(c.onclick=es),c=true):c=false,c||Qs(s,true);}function dN(s){for(Wr=s.return;Wr;)switch(Wr.tag){case 5:case 31:case 13:Ii=false;return;case 27:case 3:Ii=true;return;default:Wr=Wr.return;}}function ju(s){if(s!==Wr)return false;if(!hn)return dN(s),hn=true,false;var c=s.tag,h;if((h=c!==3&&c!==27)&&((h=c===5)&&(h=s.type,h=!(h!=="form"&&h!=="button")||XC(s.type,s.memoizedProps)),h=!h),h&&Gn&&Qs(s),dN(s),c===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));Gn=B4(s);}else if(c===31){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(317));Gn=B4(s);}else c===27?(c=Gn,dl(s.type)?(s=tx,tx=null,Gn=s):Gn=c):Gn=Wr?Di(s.stateNode.nextSibling):null;return true}function hc(){Gn=Wr=null,hn=false;}function OS(){var s=Xs;return s!==null&&(Ho===null?Ho=s:Ho.push.apply(Ho,s),Xs=null),s}function mm(s){Xs===null?Xs=[s]:Xs.push(s);}var DS=D(null),pc=null,os=null;function Zs(s,c,h){K(DS,c._currentValue),c._currentValue=h;}function is(s){s._currentValue=DS.current,L(DS);}function _S(s,c,h){for(;s!==null;){var v=s.alternate;if((s.childLanes&c)!==c?(s.childLanes|=c,v!==null&&(v.childLanes|=c)):v!==null&&(v.childLanes&c)!==c&&(v.childLanes|=c),s===h)break;s=s.return;}}function BS(s,c,h,v){var E=s.child;for(E!==null&&(E.return=s);E!==null;){var A=E.dependencies;if(A!==null){var k=E.child;A=A.firstContext;e:for(;A!==null;){var Z=A;A=E;for(var le=0;le<c.length;le++)if(Z.context===c[le]){A.lanes|=h,Z=A.alternate,Z!==null&&(Z.lanes|=h),_S(A.return,h,s),v||(k=null);break e}A=Z.next;}}else if(E.tag===18){if(k=E.return,k===null)throw Error(r(341));k.lanes|=h,A=k.alternate,A!==null&&(A.lanes|=h),_S(k,h,s),k=null;}else k=E.child;if(k!==null)k.return=E;else for(k=E;k!==null;){if(k===s){k=null;break}if(E=k.sibling,E!==null){E.return=k.return,k=E;break}k=k.return;}E=k;}}function Uu(s,c,h,v){s=null;for(var E=c,A=false;E!==null;){if(!A){if((E.flags&524288)!==0)A=true;else if((E.flags&262144)!==0)break}if(E.tag===10){var k=E.alternate;if(k===null)throw Error(r(387));if(k=k.memoizedProps,k!==null){var Z=E.type;ti(E.pendingProps.value,k.value)||(s!==null?s.push(Z):s=[Z]);}}else if(E===re.current){if(k=E.alternate,k===null)throw Error(r(387));k.memoizedState.memoizedState!==E.memoizedState.memoizedState&&(s!==null?s.push(Fm):s=[Fm]);}E=E.return;}s!==null&&BS(c,s,h,v),c.flags|=262144;}function Qg(s){for(s=s.firstContext;s!==null;){if(!ti(s.context._currentValue,s.memoizedValue))return true;s=s.next;}return false}function gc(s){pc=s,os=null,s=s.dependencies,s!==null&&(s.firstContext=null);}function Gr(s){return fN(pc,s)}function Zg(s,c){return pc===null&&gc(s),fN(s,c)}function fN(s,c){var h=c._currentValue;if(c={context:c,memoizedValue:h,next:null},os===null){if(s===null)throw Error(r(308));os=c,s.dependencies={lanes:0,firstContext:c},s.flags|=524288;}else os=os.next=c;return h}var CY=typeof AbortController<"u"?AbortController:function(){var s=[],c=this.signal={aborted:false,addEventListener:function(h,v){s.push(v);}};this.abort=function(){c.aborted=true,s.forEach(function(h){return h()});};},xY=e.unstable_scheduleCallback,wY=e.unstable_NormalPriority,gr={$$typeof:M,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function LS(){return {controller:new CY,data:new Map,refCount:0}}function hm(s){s.refCount--,s.refCount===0&&xY(wY,function(){s.controller.abort();});}var pm=null,zS=0,Wu=0,Gu=null;function $Y(s,c){if(pm===null){var h=pm=[];zS=0,Wu=HC(),Gu={status:"pending",value:void 0,then:function(v){h.push(v);}};}return zS++,c.then(mN,mN),c}function mN(){if(--zS===0&&pm!==null){Gu!==null&&(Gu.status="fulfilled");var s=pm;pm=null,Wu=0,Gu=null;for(var c=0;c<s.length;c++)(0, s[c])();}}function EY(s,c){var h=[],v={status:"pending",value:null,reason:null,then:function(E){h.push(E);}};return s.then(function(){v.status="fulfilled",v.value=c;for(var E=0;E<h.length;E++)(0, h[E])(c);},function(E){for(v.status="rejected",v.reason=E,E=0;E<h.length;E++)(0, h[E])(void 0);}),v}var hN=z.S;z.S=function(s,c){QP=Pe(),typeof c=="object"&&c!==null&&typeof c.then=="function"&&$Y(s,c),hN!==null&&hN(s,c);};var vc=D(null);function kS(){var s=vc.current;return s!==null?s:kn.pooledCache}function Jg(s,c){c===null?K(vc,vc.current):K(vc,c.pool);}function pN(){var s=kS();return s===null?null:{parent:gr._currentValue,pool:s}}var qu=Error(r(460)),FS=Error(r(474)),ev=Error(r(542)),tv={then:function(){}};function gN(s){return s=s.status,s==="fulfilled"||s==="rejected"}function vN(s,c,h){switch(h=s[h],h===void 0?s.push(c):h!==c&&(c.then(es,es),c=h),c.status){case "fulfilled":return c.value;case "rejected":throw s=c.reason,yN(s),s;default:if(typeof c.status=="string")c.then(es,es);else {if(s=kn,s!==null&&100<s.shellSuspendCounter)throw Error(r(482));s=c,s.status="pending",s.then(function(v){if(c.status==="pending"){var E=c;E.status="fulfilled",E.value=v;}},function(v){if(c.status==="pending"){var E=c;E.status="rejected",E.reason=v;}});}switch(c.status){case "fulfilled":return c.value;case "rejected":throw s=c.reason,yN(s),s}throw yc=c,qu}}function bc(s){try{var c=s._init;return c(s._payload)}catch(h){throw h!==null&&typeof h=="object"&&typeof h.then=="function"?(yc=h,qu):h}}var yc=null;function bN(){if(yc===null)throw Error(r(459));var s=yc;return yc=null,s}function yN(s){if(s===qu||s===ev)throw Error(r(483))}var Ku=null,gm=0;function nv(s){var c=gm;return gm+=1,Ku===null&&(Ku=[]),vN(Ku,s,c)}function vm(s,c){c=c.props.ref,s.ref=c!==void 0?c:null;}function rv(s,c){throw c.$$typeof===g?Error(r(525)):(s=Object.prototype.toString.call(c),Error(r(31,s==="[object Object]"?"object with keys {"+Object.keys(c).join(", ")+"}":s)))}function SN(s){function c(ve,me){if(s){var we=ve.deletions;we===null?(ve.deletions=[me],ve.flags|=16):we.push(me);}}function h(ve,me){if(!s)return null;for(;me!==null;)c(ve,me),me=me.sibling;return null}function v(ve){for(var me=new Map;ve!==null;)ve.key!==null?me.set(ve.key,ve):me.set(ve.index,ve),ve=ve.sibling;return me}function E(ve,me){return ve=ns(ve,me),ve.index=0,ve.sibling=null,ve}function A(ve,me,we){return ve.index=we,s?(we=ve.alternate,we!==null?(we=we.index,we<me?(ve.flags|=67108866,me):we):(ve.flags|=67108866,me)):(ve.flags|=1048576,me)}function k(ve){return s&&ve.alternate===null&&(ve.flags|=67108866),ve}function Z(ve,me,we,He){return me===null||me.tag!==6?(me=TS(we,ve.mode,He),me.return=ve,me):(me=E(me,we),me.return=ve,me)}function le(ve,me,we,He){var Et=we.type;return Et===S?Le(ve,me,we.props.children,He,we.key):me!==null&&(me.elementType===Et||typeof Et=="object"&&Et!==null&&Et.$$typeof===P&&bc(Et)===me.type)?(me=E(me,we.props),vm(me,we),me.return=ve,me):(me=Yg(we.type,we.key,we.props,null,ve.mode,He),vm(me,we),me.return=ve,me)}function Ee(ve,me,we,He){return me===null||me.tag!==4||me.stateNode.containerInfo!==we.containerInfo||me.stateNode.implementation!==we.implementation?(me=AS(we,ve.mode,He),me.return=ve,me):(me=E(me,we.children||[]),me.return=ve,me)}function Le(ve,me,we,He,Et){return me===null||me.tag!==7?(me=mc(we,ve.mode,He,Et),me.return=ve,me):(me=E(me,we),me.return=ve,me)}function Ve(ve,me,we){if(typeof me=="string"&&me!==""||typeof me=="number"||typeof me=="bigint")return me=TS(""+me,ve.mode,we),me.return=ve,me;if(typeof me=="object"&&me!==null){switch(me.$$typeof){case b:return we=Yg(me.type,me.key,me.props,null,ve.mode,we),vm(we,me),we.return=ve,we;case y:return me=AS(me,ve.mode,we),me.return=ve,me;case P:return me=bc(me),Ve(ve,me,we)}if(H(me)||V(me))return me=mc(me,ve.mode,we,null),me.return=ve,me;if(typeof me.then=="function")return Ve(ve,nv(me),we);if(me.$$typeof===M)return Ve(ve,Zg(ve,me),we);rv(ve,me);}return null}function Te(ve,me,we,He){var Et=me!==null?me.key:null;if(typeof we=="string"&&we!==""||typeof we=="number"||typeof we=="bigint")return Et!==null?null:Z(ve,me,""+we,He);if(typeof we=="object"&&we!==null){switch(we.$$typeof){case b:return we.key===Et?le(ve,me,we,He):null;case y:return we.key===Et?Ee(ve,me,we,He):null;case P:return we=bc(we),Te(ve,me,we,He)}if(H(we)||V(we))return Et!==null?null:Le(ve,me,we,He,null);if(typeof we.then=="function")return Te(ve,me,nv(we),He);if(we.$$typeof===M)return Te(ve,me,Zg(ve,we),He);rv(ve,we);}return null}function Ie(ve,me,we,He,Et){if(typeof He=="string"&&He!==""||typeof He=="number"||typeof He=="bigint")return ve=ve.get(we)||null,Z(me,ve,""+He,Et);if(typeof He=="object"&&He!==null){switch(He.$$typeof){case b:return ve=ve.get(He.key===null?we:He.key)||null,le(me,ve,He,Et);case y:return ve=ve.get(He.key===null?we:He.key)||null,Ee(me,ve,He,Et);case P:return He=bc(He),Ie(ve,me,we,He,Et)}if(H(He)||V(He))return ve=ve.get(we)||null,Le(me,ve,He,Et,null);if(typeof He.then=="function")return Ie(ve,me,we,nv(He),Et);if(He.$$typeof===M)return Ie(ve,me,we,Zg(me,He),Et);rv(me,He);}return null}function pt(ve,me,we,He){for(var Et=null,bn=null,St=me,Yt=me=0,an=null;St!==null&&Yt<we.length;Yt++){St.index>Yt?(an=St,St=null):an=St.sibling;var yn=Te(ve,St,we[Yt],He);if(yn===null){St===null&&(St=an);break}s&&St&&yn.alternate===null&&c(ve,St),me=A(yn,me,Yt),bn===null?Et=yn:bn.sibling=yn,bn=yn,St=an;}if(Yt===we.length)return h(ve,St),hn&&rs(ve,Yt),Et;if(St===null){for(;Yt<we.length;Yt++)St=Ve(ve,we[Yt],He),St!==null&&(me=A(St,me,Yt),bn===null?Et=St:bn.sibling=St,bn=St);return hn&&rs(ve,Yt),Et}for(St=v(St);Yt<we.length;Yt++)an=Ie(St,ve,Yt,we[Yt],He),an!==null&&(s&&an.alternate!==null&&St.delete(an.key===null?Yt:an.key),me=A(an,me,Yt),bn===null?Et=an:bn.sibling=an,bn=an);return s&&St.forEach(function(gl){return c(ve,gl)}),hn&&rs(ve,Yt),Et}function Nt(ve,me,we,He){if(we==null)throw Error(r(151));for(var Et=null,bn=null,St=me,Yt=me=0,an=null,yn=we.next();St!==null&&!yn.done;Yt++,yn=we.next()){St.index>Yt?(an=St,St=null):an=St.sibling;var gl=Te(ve,St,yn.value,He);if(gl===null){St===null&&(St=an);break}s&&St&&gl.alternate===null&&c(ve,St),me=A(gl,me,Yt),bn===null?Et=gl:bn.sibling=gl,bn=gl,St=an;}if(yn.done)return h(ve,St),hn&&rs(ve,Yt),Et;if(St===null){for(;!yn.done;Yt++,yn=we.next())yn=Ve(ve,yn.value,He),yn!==null&&(me=A(yn,me,Yt),bn===null?Et=yn:bn.sibling=yn,bn=yn);return hn&&rs(ve,Yt),Et}for(St=v(St);!yn.done;Yt++,yn=we.next())yn=Ie(St,ve,Yt,yn.value,He),yn!==null&&(s&&yn.alternate!==null&&St.delete(yn.key===null?Yt:yn.key),me=A(yn,me,Yt),bn===null?Et=yn:bn.sibling=yn,bn=yn);return s&&St.forEach(function(BX){return c(ve,BX)}),hn&&rs(ve,Yt),Et}function Dn(ve,me,we,He){if(typeof we=="object"&&we!==null&&we.type===S&&we.key===null&&(we=we.props.children),typeof we=="object"&&we!==null){switch(we.$$typeof){case b:e:{for(var Et=we.key;me!==null;){if(me.key===Et){if(Et=we.type,Et===S){if(me.tag===7){h(ve,me.sibling),He=E(me,we.props.children),He.return=ve,ve=He;break e}}else if(me.elementType===Et||typeof Et=="object"&&Et!==null&&Et.$$typeof===P&&bc(Et)===me.type){h(ve,me.sibling),He=E(me,we.props),vm(He,we),He.return=ve,ve=He;break e}h(ve,me);break}else c(ve,me);me=me.sibling;}we.type===S?(He=mc(we.props.children,ve.mode,He,we.key),He.return=ve,ve=He):(He=Yg(we.type,we.key,we.props,null,ve.mode,He),vm(He,we),He.return=ve,ve=He);}return k(ve);case y:e:{for(Et=we.key;me!==null;){if(me.key===Et)if(me.tag===4&&me.stateNode.containerInfo===we.containerInfo&&me.stateNode.implementation===we.implementation){h(ve,me.sibling),He=E(me,we.children||[]),He.return=ve,ve=He;break e}else {h(ve,me);break}else c(ve,me);me=me.sibling;}He=AS(we,ve.mode,He),He.return=ve,ve=He;}return k(ve);case P:return we=bc(we),Dn(ve,me,we,He)}if(H(we))return pt(ve,me,we,He);if(V(we)){if(Et=V(we),typeof Et!="function")throw Error(r(150));return we=Et.call(we),Nt(ve,me,we,He)}if(typeof we.then=="function")return Dn(ve,me,nv(we),He);if(we.$$typeof===M)return Dn(ve,me,Zg(ve,we),He);rv(ve,we);}return typeof we=="string"&&we!==""||typeof we=="number"||typeof we=="bigint"?(we=""+we,me!==null&&me.tag===6?(h(ve,me.sibling),He=E(me,we),He.return=ve,ve=He):(h(ve,me),He=TS(we,ve.mode,He),He.return=ve,ve=He),k(ve)):h(ve,me)}return function(ve,me,we,He){try{gm=0;var Et=Dn(ve,me,we,He);return Ku=null,Et}catch(St){if(St===qu||St===ev)throw St;var bn=ni(29,St,null,ve.mode);return bn.lanes=He,bn.return=ve,bn}}}var Sc=SN(true),CN=SN(false),Js=false;function HS(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null};}function VS(s,c){s=s.updateQueue,c.updateQueue===s&&(c.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,callbacks:null});}function el(s){return {lane:s,tag:0,payload:null,callback:null,next:null}}function tl(s,c,h){var v=s.updateQueue;if(v===null)return null;if(v=v.shared,(Cn&2)!==0){var E=v.pending;return E===null?c.next=c:(c.next=E.next,E.next=c),v.pending=c,c=Kg(s),oN(s,null,h),c}return qg(s,v,c,h),Kg(s)}function bm(s,c,h){if(c=c.updateQueue,c!==null&&(c=c.shared,(h&4194048)!==0)){var v=c.lanes;v&=s.pendingLanes,h|=v,c.lanes=h,$e(s,h);}}function jS(s,c){var h=s.updateQueue,v=s.alternate;if(v!==null&&(v=v.updateQueue,h===v)){var E=null,A=null;if(h=h.firstBaseUpdate,h!==null){do{var k={lane:h.lane,tag:h.tag,payload:h.payload,callback:null,next:null};A===null?E=A=k:A=A.next=k,h=h.next;}while(h!==null);A===null?E=A=c:A=A.next=c;}else E=A=c;h={baseState:v.baseState,firstBaseUpdate:E,lastBaseUpdate:A,shared:v.shared,callbacks:v.callbacks},s.updateQueue=h;return}s=h.lastBaseUpdate,s===null?h.firstBaseUpdate=c:s.next=c,h.lastBaseUpdate=c;}var US=false;function ym(){if(US){var s=Gu;if(s!==null)throw s}}function Sm(s,c,h,v){US=false;var E=s.updateQueue;Js=false;var A=E.firstBaseUpdate,k=E.lastBaseUpdate,Z=E.shared.pending;if(Z!==null){E.shared.pending=null;var le=Z,Ee=le.next;le.next=null,k===null?A=Ee:k.next=Ee,k=le;var Le=s.alternate;Le!==null&&(Le=Le.updateQueue,Z=Le.lastBaseUpdate,Z!==k&&(Z===null?Le.firstBaseUpdate=Ee:Z.next=Ee,Le.lastBaseUpdate=le));}if(A!==null){var Ve=E.baseState;k=0,Le=Ee=le=null,Z=A;do{var Te=Z.lane&-536870913,Ie=Te!==Z.lane;if(Ie?(on&Te)===Te:(v&Te)===Te){Te!==0&&Te===Wu&&(US=true),Le!==null&&(Le=Le.next={lane:0,tag:Z.tag,payload:Z.payload,callback:null,next:null});e:{var pt=s,Nt=Z;Te=c;var Dn=h;switch(Nt.tag){case 1:if(pt=Nt.payload,typeof pt=="function"){Ve=pt.call(Dn,Ve,Te);break e}Ve=pt;break e;case 3:pt.flags=pt.flags&-65537|128;case 0:if(pt=Nt.payload,Te=typeof pt=="function"?pt.call(Dn,Ve,Te):pt,Te==null)break e;Ve=p({},Ve,Te);break e;case 2:Js=true;}}Te=Z.callback,Te!==null&&(s.flags|=64,Ie&&(s.flags|=8192),Ie=E.callbacks,Ie===null?E.callbacks=[Te]:Ie.push(Te));}else Ie={lane:Te,tag:Z.tag,payload:Z.payload,callback:Z.callback,next:null},Le===null?(Ee=Le=Ie,le=Ve):Le=Le.next=Ie,k|=Te;if(Z=Z.next,Z===null){if(Z=E.shared.pending,Z===null)break;Ie=Z,Z=Ie.next,Ie.next=null,E.lastBaseUpdate=Ie,E.shared.pending=null;}}while(true);Le===null&&(le=Ve),E.baseState=le,E.firstBaseUpdate=Ee,E.lastBaseUpdate=Le,A===null&&(E.shared.lanes=0),al|=k,s.lanes=k,s.memoizedState=Ve;}}function xN(s,c){if(typeof s!="function")throw Error(r(191,s));s.call(c);}function wN(s,c){var h=s.callbacks;if(h!==null)for(s.callbacks=null,s=0;s<h.length;s++)xN(h[s],c);}var Yu=D(null),ov=D(0);function $N(s,c){s=hs,K(ov,s),K(Yu,c),hs=s|c.baseLanes;}function WS(){K(ov,hs),K(Yu,Yu.current);}function GS(){hs=ov.current,L(Yu),L(ov);}var ri=D(null),Oi=null;function nl(s){var c=s.alternate;K(dr,dr.current&1),K(ri,s),Oi===null&&(c===null||Yu.current!==null||c.memoizedState!==null)&&(Oi=s);}function qS(s){K(dr,dr.current),K(ri,s),Oi===null&&(Oi=s);}function EN(s){s.tag===22?(K(dr,dr.current),K(ri,s),Oi===null&&(Oi=s)):rl();}function rl(){K(dr,dr.current),K(ri,ri.current);}function oi(s){L(ri),Oi===s&&(Oi=null),L(dr);}var dr=D(0);function iv(s){for(var c=s;c!==null;){if(c.tag===13){var h=c.memoizedState;if(h!==null&&(h=h.dehydrated,h===null||JC(h)||ex(h)))return c}else if(c.tag===19&&(c.memoizedProps.revealOrder==="forwards"||c.memoizedProps.revealOrder==="backwards"||c.memoizedProps.revealOrder==="unstable_legacy-backwards"||c.memoizedProps.revealOrder==="together")){if((c.flags&128)!==0)return c}else if(c.child!==null){c.child.return=c,c=c.child;continue}if(c===s)break;for(;c.sibling===null;){if(c.return===null||c.return===s)return null;c=c.return;}c.sibling.return=c.return,c=c.sibling;}return null}var as=0,Gt=null,In=null,vr=null,av=false,Xu=false,Cc=false,sv=0,Cm=0,Qu=null,MY=0;function or(){throw Error(r(321))}function KS(s,c){if(c===null)return false;for(var h=0;h<c.length&&h<s.length;h++)if(!ti(s[h],c[h]))return false;return true}function YS(s,c,h,v,E,A){return as=A,Gt=c,c.memoizedState=null,c.updateQueue=null,c.lanes=0,z.H=s===null||s.memoizedState===null?lP:uC,Cc=false,A=h(v,E),Cc=false,Xu&&(A=RN(c,h,v,E)),MN(s),A}function MN(s){z.H=$m;var c=In!==null&&In.next!==null;if(as=0,vr=In=Gt=null,av=false,Cm=0,Qu=null,c)throw Error(r(300));s===null||br||(s=s.dependencies,s!==null&&Qg(s)&&(br=true));}function RN(s,c,h,v){Gt=s;var E=0;do{if(Xu&&(Qu=null),Cm=0,Xu=false,25<=E)throw Error(r(301));if(E+=1,vr=In=null,s.updateQueue!=null){var A=s.updateQueue;A.lastEffect=null,A.events=null,A.stores=null,A.memoCache!=null&&(A.memoCache.index=0);}z.H=cP,A=c(h,v);}while(Xu);return A}function RY(){var s=z.H,c=s.useState()[0];return c=typeof c.then=="function"?xm(c):c,s=s.useState()[0],(In!==null?In.memoizedState:null)!==s&&(Gt.flags|=1024),c}function XS(){var s=sv!==0;return sv=0,s}function QS(s,c,h){c.updateQueue=s.updateQueue,c.flags&=-2053,s.lanes&=~h;}function ZS(s){if(av){for(s=s.memoizedState;s!==null;){var c=s.queue;c!==null&&(c.pending=null),s=s.next;}av=false;}as=0,vr=In=Gt=null,Xu=false,Cm=sv=0,Qu=null;}function xo(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vr===null?Gt.memoizedState=vr=s:vr=vr.next=s,vr}function fr(){if(In===null){var s=Gt.alternate;s=s!==null?s.memoizedState:null;}else s=In.next;var c=vr===null?Gt.memoizedState:vr.next;if(c!==null)vr=c,In=s;else {if(s===null)throw Gt.alternate===null?Error(r(467)):Error(r(310));In=s,s={memoizedState:In.memoizedState,baseState:In.baseState,baseQueue:In.baseQueue,queue:In.queue,next:null},vr===null?Gt.memoizedState=vr=s:vr=vr.next=s;}return vr}function lv(){return {lastEffect:null,events:null,stores:null,memoCache:null}}function xm(s){var c=Cm;return Cm+=1,Qu===null&&(Qu=[]),s=vN(Qu,s,c),c=Gt,(vr===null?c.memoizedState:vr.next)===null&&(c=c.alternate,z.H=c===null||c.memoizedState===null?lP:uC),s}function cv(s){if(s!==null&&typeof s=="object"){if(typeof s.then=="function")return xm(s);if(s.$$typeof===M)return Gr(s)}throw Error(r(438,String(s)))}function JS(s){var c=null,h=Gt.updateQueue;if(h!==null&&(c=h.memoCache),c==null){var v=Gt.alternate;v!==null&&(v=v.updateQueue,v!==null&&(v=v.memoCache,v!=null&&(c={data:v.data.map(function(E){return E.slice()}),index:0})));}if(c==null&&(c={data:[],index:0}),h===null&&(h=lv(),Gt.updateQueue=h),h.memoCache=c,h=c.data[c.index],h===void 0)for(h=c.data[c.index]=Array(s),v=0;v<s;v++)h[v]=_;return c.index++,h}function ss(s,c){return typeof c=="function"?c(s):c}function uv(s){var c=fr();return eC(c,In,s)}function eC(s,c,h){var v=s.queue;if(v===null)throw Error(r(311));v.lastRenderedReducer=h;var E=s.baseQueue,A=v.pending;if(A!==null){if(E!==null){var k=E.next;E.next=A.next,A.next=k;}c.baseQueue=E=A,v.pending=null;}if(A=s.baseState,E===null)s.memoizedState=A;else {c=E.next;var Z=k=null,le=null,Ee=c,Le=false;do{var Ve=Ee.lane&-536870913;if(Ve!==Ee.lane?(on&Ve)===Ve:(as&Ve)===Ve){var Te=Ee.revertLane;if(Te===0)le!==null&&(le=le.next={lane:0,revertLane:0,gesture:null,action:Ee.action,hasEagerState:Ee.hasEagerState,eagerState:Ee.eagerState,next:null}),Ve===Wu&&(Le=true);else if((as&Te)===Te){Ee=Ee.next,Te===Wu&&(Le=true);continue}else Ve={lane:0,revertLane:Ee.revertLane,gesture:null,action:Ee.action,hasEagerState:Ee.hasEagerState,eagerState:Ee.eagerState,next:null},le===null?(Z=le=Ve,k=A):le=le.next=Ve,Gt.lanes|=Te,al|=Te;Ve=Ee.action,Cc&&h(A,Ve),A=Ee.hasEagerState?Ee.eagerState:h(A,Ve);}else Te={lane:Ve,revertLane:Ee.revertLane,gesture:Ee.gesture,action:Ee.action,hasEagerState:Ee.hasEagerState,eagerState:Ee.eagerState,next:null},le===null?(Z=le=Te,k=A):le=le.next=Te,Gt.lanes|=Ve,al|=Ve;Ee=Ee.next;}while(Ee!==null&&Ee!==c);if(le===null?k=A:le.next=Z,!ti(A,s.memoizedState)&&(br=true,Le&&(h=Gu,h!==null)))throw h;s.memoizedState=A,s.baseState=k,s.baseQueue=le,v.lastRenderedState=A;}return E===null&&(v.lanes=0),[s.memoizedState,v.dispatch]}function tC(s){var c=fr(),h=c.queue;if(h===null)throw Error(r(311));h.lastRenderedReducer=s;var v=h.dispatch,E=h.pending,A=c.memoizedState;if(E!==null){h.pending=null;var k=E=E.next;do A=s(A,k.action),k=k.next;while(k!==E);ti(A,c.memoizedState)||(br=true),c.memoizedState=A,c.baseQueue===null&&(c.baseState=A),h.lastRenderedState=A;}return [A,v]}function TN(s,c,h){var v=Gt,E=fr(),A=hn;if(A){if(h===void 0)throw Error(r(407));h=h();}else h=c();var k=!ti((In||E).memoizedState,h);if(k&&(E.memoizedState=h,br=true),E=E.queue,oC(PN.bind(null,v,E,s),[s]),E.getSnapshot!==c||k||vr!==null&&vr.memoizedState.tag&1){if(v.flags|=2048,Zu(9,{destroy:void 0},NN.bind(null,v,E,h,c),null),kn===null)throw Error(r(349));A||(as&127)!==0||AN(v,c,h);}return h}function AN(s,c,h){s.flags|=16384,s={getSnapshot:c,value:h},c=Gt.updateQueue,c===null?(c=lv(),Gt.updateQueue=c,c.stores=[s]):(h=c.stores,h===null?c.stores=[s]:h.push(s));}function NN(s,c,h,v){c.value=h,c.getSnapshot=v,IN(c)&&ON(s);}function PN(s,c,h){return h(function(){IN(c)&&ON(s);})}function IN(s){var c=s.getSnapshot;s=s.value;try{var h=c();return !ti(s,h)}catch{return true}}function ON(s){var c=fc(s,2);c!==null&&Vo(c,s,2);}function nC(s){var c=xo();if(typeof s=="function"){var h=s;if(s=h(),Cc){Oe(true);try{h();}finally{Oe(false);}}}return c.memoizedState=c.baseState=s,c.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ss,lastRenderedState:s},c}function DN(s,c,h,v){return s.baseState=h,eC(s,In,typeof v=="function"?v:ss)}function TY(s,c,h,v,E){if(mv(s))throw Error(r(485));if(s=c.action,s!==null){var A={payload:E,action:s,next:null,isTransition:true,status:"pending",value:null,reason:null,listeners:[],then:function(k){A.listeners.push(k);}};z.T!==null?h(true):A.isTransition=false,v(A),h=c.pending,h===null?(A.next=c.pending=A,_N(c,A)):(A.next=h.next,c.pending=h.next=A);}}function _N(s,c){var h=c.action,v=c.payload,E=s.state;if(c.isTransition){var A=z.T,k={};z.T=k;try{var Z=h(E,v),le=z.S;le!==null&&le(k,Z),BN(s,c,Z);}catch(Ee){rC(s,c,Ee);}finally{A!==null&&k.types!==null&&(A.types=k.types),z.T=A;}}else try{A=h(E,v),BN(s,c,A);}catch(Ee){rC(s,c,Ee);}}function BN(s,c,h){h!==null&&typeof h=="object"&&typeof h.then=="function"?h.then(function(v){LN(s,c,v);},function(v){return rC(s,c,v)}):LN(s,c,h);}function LN(s,c,h){c.status="fulfilled",c.value=h,zN(c),s.state=h,c=s.pending,c!==null&&(h=c.next,h===c?s.pending=null:(h=h.next,c.next=h,_N(s,h)));}function rC(s,c,h){var v=s.pending;if(s.pending=null,v!==null){v=v.next;do c.status="rejected",c.reason=h,zN(c),c=c.next;while(c!==v)}s.action=null;}function zN(s){s=s.listeners;for(var c=0;c<s.length;c++)(0, s[c])();}function kN(s,c){return c}function FN(s,c){if(hn){var h=kn.formState;if(h!==null){e:{var v=Gt;if(hn){if(Gn){t:{for(var E=Gn,A=Ii;E.nodeType!==8;){if(!A){E=null;break t}if(E=Di(E.nextSibling),E===null){E=null;break t}}A=E.data,E=A==="F!"||A==="F"?E:null;}if(E){Gn=Di(E.nextSibling),v=E.data==="F!";break e}}Qs(v);}v=false;}v&&(c=h[0]);}}return h=xo(),h.memoizedState=h.baseState=c,v={pending:null,lanes:0,dispatch:null,lastRenderedReducer:kN,lastRenderedState:c},h.queue=v,h=iP.bind(null,Gt,v),v.dispatch=h,v=nC(false),A=cC.bind(null,Gt,false,v.queue),v=xo(),E={state:c,dispatch:null,action:s,pending:null},v.queue=E,h=TY.bind(null,Gt,E,A,h),E.dispatch=h,v.memoizedState=s,[c,h,false]}function HN(s){var c=fr();return VN(c,In,s)}function VN(s,c,h){if(c=eC(s,c,kN)[0],s=uv(ss)[0],typeof c=="object"&&c!==null&&typeof c.then=="function")try{var v=xm(c);}catch(k){throw k===qu?ev:k}else v=c;c=fr();var E=c.queue,A=E.dispatch;return h!==c.memoizedState&&(Gt.flags|=2048,Zu(9,{destroy:void 0},AY.bind(null,E,h),null)),[v,A,s]}function AY(s,c){s.action=c;}function jN(s){var c=fr(),h=In;if(h!==null)return VN(c,h,s);fr(),c=c.memoizedState,h=fr();var v=h.queue.dispatch;return h.memoizedState=s,[c,v,false]}function Zu(s,c,h,v){return s={tag:s,create:h,deps:v,inst:c,next:null},c=Gt.updateQueue,c===null&&(c=lv(),Gt.updateQueue=c),h=c.lastEffect,h===null?c.lastEffect=s.next=s:(v=h.next,h.next=s,s.next=v,c.lastEffect=s),s}function UN(){return fr().memoizedState}function dv(s,c,h,v){var E=xo();Gt.flags|=s,E.memoizedState=Zu(1|c,{destroy:void 0},h,v===void 0?null:v);}function fv(s,c,h,v){var E=fr();v=v===void 0?null:v;var A=E.memoizedState.inst;In!==null&&v!==null&&KS(v,In.memoizedState.deps)?E.memoizedState=Zu(c,A,h,v):(Gt.flags|=s,E.memoizedState=Zu(1|c,A,h,v));}function WN(s,c){dv(8390656,8,s,c);}function oC(s,c){fv(2048,8,s,c);}function NY(s){Gt.flags|=4;var c=Gt.updateQueue;if(c===null)c=lv(),Gt.updateQueue=c,c.events=[s];else {var h=c.events;h===null?c.events=[s]:h.push(s);}}function GN(s){var c=fr().memoizedState;return NY({ref:c,nextImpl:s}),function(){if((Cn&2)!==0)throw Error(r(440));return c.impl.apply(void 0,arguments)}}function qN(s,c){return fv(4,2,s,c)}function KN(s,c){return fv(4,4,s,c)}function YN(s,c){if(typeof c=="function"){s=s();var h=c(s);return function(){typeof h=="function"?h():c(null);}}if(c!=null)return s=s(),c.current=s,function(){c.current=null;}}function XN(s,c,h){h=h!=null?h.concat([s]):null,fv(4,4,YN.bind(null,c,s),h);}function iC(){}function QN(s,c){var h=fr();c=c===void 0?null:c;var v=h.memoizedState;return c!==null&&KS(c,v[1])?v[0]:(h.memoizedState=[s,c],s)}function ZN(s,c){var h=fr();c=c===void 0?null:c;var v=h.memoizedState;if(c!==null&&KS(c,v[1]))return v[0];if(v=s(),Cc){Oe(true);try{s();}finally{Oe(false);}}return h.memoizedState=[v,c],v}function aC(s,c,h){return h===void 0||(as&1073741824)!==0&&(on&261930)===0?s.memoizedState=c:(s.memoizedState=h,s=JP(),Gt.lanes|=s,al|=s,h)}function JN(s,c,h,v){return ti(h,c)?h:Yu.current!==null?(s=aC(s,h,v),ti(s,c)||(br=true),s):(as&42)===0||(as&1073741824)!==0&&(on&261930)===0?(br=true,s.memoizedState=h):(s=JP(),Gt.lanes|=s,al|=s,c)}function eP(s,c,h,v,E){var A=j.p;j.p=A!==0&&8>A?A:8;var k=z.T,Z={};z.T=Z,cC(s,false,c,h);try{var le=E(),Ee=z.S;if(Ee!==null&&Ee(Z,le),le!==null&&typeof le=="object"&&typeof le.then=="function"){var Le=EY(le,v);wm(s,c,Le,si(s));}else wm(s,c,v,si(s));}catch(Ve){wm(s,c,{then:function(){},status:"rejected",reason:Ve},si());}finally{j.p=A,k!==null&&Z.types!==null&&(k.types=Z.types),z.T=k;}}function PY(){}function sC(s,c,h,v){if(s.tag!==5)throw Error(r(476));var E=tP(s).queue;eP(s,E,c,W,h===null?PY:function(){return nP(s),h(v)});}function tP(s){var c=s.memoizedState;if(c!==null)return c;c={memoizedState:W,baseState:W,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ss,lastRenderedState:W},next:null};var h={};return c.next={memoizedState:h,baseState:h,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ss,lastRenderedState:h},next:null},s.memoizedState=c,s=s.alternate,s!==null&&(s.memoizedState=c),c}function nP(s){var c=tP(s);c.next===null&&(c=s.alternate.memoizedState),wm(s,c.next.queue,{},si());}function lC(){return Gr(Fm)}function rP(){return fr().memoizedState}function oP(){return fr().memoizedState}function IY(s){for(var c=s.return;c!==null;){switch(c.tag){case 24:case 3:var h=si();s=el(h);var v=tl(c,s,h);v!==null&&(Vo(v,c,h),bm(v,c,h)),c={cache:LS()},s.payload=c;return}c=c.return;}}function OY(s,c,h){var v=si();h={lane:v,revertLane:0,gesture:null,action:h,hasEagerState:false,eagerState:null,next:null},mv(s)?aP(c,h):(h=MS(s,c,h,v),h!==null&&(Vo(h,s,v),sP(h,c,v)));}function iP(s,c,h){var v=si();wm(s,c,h,v);}function wm(s,c,h,v){var E={lane:v,revertLane:0,gesture:null,action:h,hasEagerState:false,eagerState:null,next:null};if(mv(s))aP(c,E);else {var A=s.alternate;if(s.lanes===0&&(A===null||A.lanes===0)&&(A=c.lastRenderedReducer,A!==null))try{var k=c.lastRenderedState,Z=A(k,h);if(E.hasEagerState=!0,E.eagerState=Z,ti(Z,k))return qg(s,c,E,0),kn===null&&Gg(),!1}catch{}if(h=MS(s,c,E,v),h!==null)return Vo(h,s,v),sP(h,c,v),true}return false}function cC(s,c,h,v){if(v={lane:2,revertLane:HC(),gesture:null,action:v,hasEagerState:false,eagerState:null,next:null},mv(s)){if(c)throw Error(r(479))}else c=MS(s,h,v,2),c!==null&&Vo(c,s,2);}function mv(s){var c=s.alternate;return s===Gt||c!==null&&c===Gt}function aP(s,c){Xu=av=true;var h=s.pending;h===null?c.next=c:(c.next=h.next,h.next=c),s.pending=c;}function sP(s,c,h){if((h&4194048)!==0){var v=c.lanes;v&=s.pendingLanes,h|=v,c.lanes=h,$e(s,h);}}var $m={readContext:Gr,use:cv,useCallback:or,useContext:or,useEffect:or,useImperativeHandle:or,useLayoutEffect:or,useInsertionEffect:or,useMemo:or,useReducer:or,useRef:or,useState:or,useDebugValue:or,useDeferredValue:or,useTransition:or,useSyncExternalStore:or,useId:or,useHostTransitionStatus:or,useFormState:or,useActionState:or,useOptimistic:or,useMemoCache:or,useCacheRefresh:or};$m.useEffectEvent=or;var lP={readContext:Gr,use:cv,useCallback:function(s,c){return xo().memoizedState=[s,c===void 0?null:c],s},useContext:Gr,useEffect:WN,useImperativeHandle:function(s,c,h){h=h!=null?h.concat([s]):null,dv(4194308,4,YN.bind(null,c,s),h);},useLayoutEffect:function(s,c){return dv(4194308,4,s,c)},useInsertionEffect:function(s,c){dv(4,2,s,c);},useMemo:function(s,c){var h=xo();c=c===void 0?null:c;var v=s();if(Cc){Oe(true);try{s();}finally{Oe(false);}}return h.memoizedState=[v,c],v},useReducer:function(s,c,h){var v=xo();if(h!==void 0){var E=h(c);if(Cc){Oe(true);try{h(c);}finally{Oe(false);}}}else E=c;return v.memoizedState=v.baseState=E,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:E},v.queue=s,s=s.dispatch=OY.bind(null,Gt,s),[v.memoizedState,s]},useRef:function(s){var c=xo();return s={current:s},c.memoizedState=s},useState:function(s){s=nC(s);var c=s.queue,h=iP.bind(null,Gt,c);return c.dispatch=h,[s.memoizedState,h]},useDebugValue:iC,useDeferredValue:function(s,c){var h=xo();return aC(h,s,c)},useTransition:function(){var s=nC(false);return s=eP.bind(null,Gt,s.queue,true,false),xo().memoizedState=s,[false,s]},useSyncExternalStore:function(s,c,h){var v=Gt,E=xo();if(hn){if(h===void 0)throw Error(r(407));h=h();}else {if(h=c(),kn===null)throw Error(r(349));(on&127)!==0||AN(v,c,h);}E.memoizedState=h;var A={value:h,getSnapshot:c};return E.queue=A,WN(PN.bind(null,v,A,s),[s]),v.flags|=2048,Zu(9,{destroy:void 0},NN.bind(null,v,A,h,c),null),h},useId:function(){var s=xo(),c=kn.identifierPrefix;if(hn){var h=Aa,v=Ta;h=(v&~(1<<32-lt(v)-1)).toString(32)+h,c="_"+c+"R_"+h,h=sv++,0<h&&(c+="H"+h.toString(32)),c+="_";}else h=MY++,c="_"+c+"r_"+h.toString(32)+"_";return s.memoizedState=c},useHostTransitionStatus:lC,useFormState:FN,useActionState:FN,useOptimistic:function(s){var c=xo();c.memoizedState=c.baseState=s;var h={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return c.queue=h,c=cC.bind(null,Gt,true,h),h.dispatch=c,[s,c]},useMemoCache:JS,useCacheRefresh:function(){return xo().memoizedState=IY.bind(null,Gt)},useEffectEvent:function(s){var c=xo(),h={impl:s};return c.memoizedState=h,function(){if((Cn&2)!==0)throw Error(r(440));return h.impl.apply(void 0,arguments)}}},uC={readContext:Gr,use:cv,useCallback:QN,useContext:Gr,useEffect:oC,useImperativeHandle:XN,useInsertionEffect:qN,useLayoutEffect:KN,useMemo:ZN,useReducer:uv,useRef:UN,useState:function(){return uv(ss)},useDebugValue:iC,useDeferredValue:function(s,c){var h=fr();return JN(h,In.memoizedState,s,c)},useTransition:function(){var s=uv(ss)[0],c=fr().memoizedState;return [typeof s=="boolean"?s:xm(s),c]},useSyncExternalStore:TN,useId:rP,useHostTransitionStatus:lC,useFormState:HN,useActionState:HN,useOptimistic:function(s,c){var h=fr();return DN(h,In,s,c)},useMemoCache:JS,useCacheRefresh:oP};uC.useEffectEvent=GN;var cP={readContext:Gr,use:cv,useCallback:QN,useContext:Gr,useEffect:oC,useImperativeHandle:XN,useInsertionEffect:qN,useLayoutEffect:KN,useMemo:ZN,useReducer:tC,useRef:UN,useState:function(){return tC(ss)},useDebugValue:iC,useDeferredValue:function(s,c){var h=fr();return In===null?aC(h,s,c):JN(h,In.memoizedState,s,c)},useTransition:function(){var s=tC(ss)[0],c=fr().memoizedState;return [typeof s=="boolean"?s:xm(s),c]},useSyncExternalStore:TN,useId:rP,useHostTransitionStatus:lC,useFormState:jN,useActionState:jN,useOptimistic:function(s,c){var h=fr();return In!==null?DN(h,In,s,c):(h.baseState=s,[s,h.queue.dispatch])},useMemoCache:JS,useCacheRefresh:oP};cP.useEffectEvent=GN;function dC(s,c,h,v){c=s.memoizedState,h=h(v,c),h=h==null?c:p({},c,h),s.memoizedState=h,s.lanes===0&&(s.updateQueue.baseState=h);}var fC={enqueueSetState:function(s,c,h){s=s._reactInternals;var v=si(),E=el(v);E.payload=c,h!=null&&(E.callback=h),c=tl(s,E,v),c!==null&&(Vo(c,s,v),bm(c,s,v));},enqueueReplaceState:function(s,c,h){s=s._reactInternals;var v=si(),E=el(v);E.tag=1,E.payload=c,h!=null&&(E.callback=h),c=tl(s,E,v),c!==null&&(Vo(c,s,v),bm(c,s,v));},enqueueForceUpdate:function(s,c){s=s._reactInternals;var h=si(),v=el(h);v.tag=2,c!=null&&(v.callback=c),c=tl(s,v,h),c!==null&&(Vo(c,s,h),bm(c,s,h));}};function uP(s,c,h,v,E,A,k){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(v,A,k):c.prototype&&c.prototype.isPureReactComponent?!um(h,v)||!um(E,A):true}function dP(s,c,h,v){s=c.state,typeof c.componentWillReceiveProps=="function"&&c.componentWillReceiveProps(h,v),typeof c.UNSAFE_componentWillReceiveProps=="function"&&c.UNSAFE_componentWillReceiveProps(h,v),c.state!==s&&fC.enqueueReplaceState(c,c.state,null);}function xc(s,c){var h=c;if("ref"in c){h={};for(var v in c)v!=="ref"&&(h[v]=c[v]);}if(s=s.defaultProps){h===c&&(h=p({},h));for(var E in s)h[E]===void 0&&(h[E]=s[E]);}return h}function fP(s){Wg(s);}function mP(s){console.error(s);}function hP(s){Wg(s);}function hv(s,c){try{var h=s.onUncaughtError;h(c.value,{componentStack:c.stack});}catch(v){setTimeout(function(){throw v});}}function pP(s,c,h){try{var v=s.onCaughtError;v(h.value,{componentStack:h.stack,errorBoundary:c.tag===1?c.stateNode:null});}catch(E){setTimeout(function(){throw E});}}function mC(s,c,h){return h=el(h),h.tag=3,h.payload={element:null},h.callback=function(){hv(s,c);},h}function gP(s){return s=el(s),s.tag=3,s}function vP(s,c,h,v){var E=h.type.getDerivedStateFromError;if(typeof E=="function"){var A=v.value;s.payload=function(){return E(A)},s.callback=function(){pP(c,h,v);};}var k=h.stateNode;k!==null&&typeof k.componentDidCatch=="function"&&(s.callback=function(){pP(c,h,v),typeof E!="function"&&(sl===null?sl=new Set([this]):sl.add(this));var Z=v.stack;this.componentDidCatch(v.value,{componentStack:Z!==null?Z:""});});}function DY(s,c,h,v,E){if(h.flags|=32768,v!==null&&typeof v=="object"&&typeof v.then=="function"){if(c=h.alternate,c!==null&&Uu(c,h,E,true),h=ri.current,h!==null){switch(h.tag){case 31:case 13:return Oi===null?Mv():h.alternate===null&&ir===0&&(ir=3),h.flags&=-257,h.flags|=65536,h.lanes=E,v===tv?h.flags|=16384:(c=h.updateQueue,c===null?h.updateQueue=new Set([v]):c.add(v),zC(s,v,E)),false;case 22:return h.flags|=65536,v===tv?h.flags|=16384:(c=h.updateQueue,c===null?(c={transitions:null,markerInstances:null,retryQueue:new Set([v])},h.updateQueue=c):(h=c.retryQueue,h===null?c.retryQueue=new Set([v]):h.add(v)),zC(s,v,E)),false}throw Error(r(435,h.tag))}return zC(s,v,E),Mv(),false}if(hn)return c=ri.current,c!==null?((c.flags&65536)===0&&(c.flags|=256),c.flags|=65536,c.lanes=E,v!==IS&&(s=Error(r(422),{cause:v}),mm(Ai(s,h)))):(v!==IS&&(c=Error(r(423),{cause:v}),mm(Ai(c,h))),s=s.current.alternate,s.flags|=65536,E&=-E,s.lanes|=E,v=Ai(v,h),E=mC(s.stateNode,v,E),jS(s,E),ir!==4&&(ir=2)),false;var A=Error(r(520),{cause:v});if(A=Ai(A,h),Im===null?Im=[A]:Im.push(A),ir!==4&&(ir=2),c===null)return true;v=Ai(v,h),h=c;do{switch(h.tag){case 3:return h.flags|=65536,s=E&-E,h.lanes|=s,s=mC(h.stateNode,v,s),jS(h,s),false;case 1:if(c=h.type,A=h.stateNode,(h.flags&128)===0&&(typeof c.getDerivedStateFromError=="function"||A!==null&&typeof A.componentDidCatch=="function"&&(sl===null||!sl.has(A))))return h.flags|=65536,E&=-E,h.lanes|=E,E=gP(E),vP(E,s,h,v),jS(h,E),false}h=h.return;}while(h!==null);return false}var hC=Error(r(461)),br=false;function qr(s,c,h,v){c.child=s===null?CN(c,null,h,v):Sc(c,s.child,h,v);}function bP(s,c,h,v,E){h=h.render;var A=c.ref;if("ref"in v){var k={};for(var Z in v)Z!=="ref"&&(k[Z]=v[Z]);}else k=v;return gc(c),v=YS(s,c,h,k,A,E),Z=XS(),s!==null&&!br?(QS(s,c,E),ls(s,c,E)):(hn&&Z&&NS(c),c.flags|=1,qr(s,c,v,E),c.child)}function yP(s,c,h,v,E){if(s===null){var A=h.type;return typeof A=="function"&&!RS(A)&&A.defaultProps===void 0&&h.compare===null?(c.tag=15,c.type=A,SP(s,c,A,v,E)):(s=Yg(h.type,null,v,c,c.mode,E),s.ref=c.ref,s.return=c,c.child=s)}if(A=s.child,!xC(s,E)){var k=A.memoizedProps;if(h=h.compare,h=h!==null?h:um,h(k,v)&&s.ref===c.ref)return ls(s,c,E)}return c.flags|=1,s=ns(A,v),s.ref=c.ref,s.return=c,c.child=s}function SP(s,c,h,v,E){if(s!==null){var A=s.memoizedProps;if(um(A,v)&&s.ref===c.ref)if(br=false,c.pendingProps=v=A,xC(s,E))(s.flags&131072)!==0&&(br=true);else return c.lanes=s.lanes,ls(s,c,E)}return pC(s,c,h,v,E)}function CP(s,c,h,v){var E=v.children,A=s!==null?s.memoizedState:null;if(s===null&&c.stateNode===null&&(c.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),v.mode==="hidden"){if((c.flags&128)!==0){if(A=A!==null?A.baseLanes|h:h,s!==null){for(v=c.child=s.child,E=0;v!==null;)E=E|v.lanes|v.childLanes,v=v.sibling;v=E&~A;}else v=0,c.child=null;return xP(s,c,A,h,v)}if((h&536870912)!==0)c.memoizedState={baseLanes:0,cachePool:null},s!==null&&Jg(c,A!==null?A.cachePool:null),A!==null?$N(c,A):WS(),EN(c);else return v=c.lanes=536870912,xP(s,c,A!==null?A.baseLanes|h:h,h,v)}else A!==null?(Jg(c,A.cachePool),$N(c,A),rl(),c.memoizedState=null):(s!==null&&Jg(c,null),WS(),rl());return qr(s,c,E,h),c.child}function Em(s,c){return s!==null&&s.tag===22||c.stateNode!==null||(c.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),c.sibling}function xP(s,c,h,v,E){var A=kS();return A=A===null?null:{parent:gr._currentValue,pool:A},c.memoizedState={baseLanes:h,cachePool:A},s!==null&&Jg(c,null),WS(),EN(c),s!==null&&Uu(s,c,v,true),c.childLanes=E,null}function pv(s,c){return c=vv({mode:c.mode,children:c.children},s.mode),c.ref=s.ref,s.child=c,c.return=s,c}function wP(s,c,h){return Sc(c,s.child,null,h),s=pv(c,c.pendingProps),s.flags|=2,oi(c),c.memoizedState=null,s}function _Y(s,c,h){var v=c.pendingProps,E=(c.flags&128)!==0;if(c.flags&=-129,s===null){if(hn){if(v.mode==="hidden")return s=pv(c,v),c.lanes=536870912,Em(null,s);if(qS(c),(s=Gn)?(s=_4(s,Ii),s=s!==null&&s.data==="&"?s:null,s!==null&&(c.memoizedState={dehydrated:s,treeContext:Ys!==null?{id:Ta,overflow:Aa}:null,retryLane:536870912,hydrationErrors:null},h=aN(s),h.return=c,c.child=h,Wr=c,Gn=null)):s=null,s===null)throw Qs(c);return c.lanes=536870912,null}return pv(c,v)}var A=s.memoizedState;if(A!==null){var k=A.dehydrated;if(qS(c),E)if(c.flags&256)c.flags&=-257,c=wP(s,c,h);else if(c.memoizedState!==null)c.child=s.child,c.flags|=128,c=null;else throw Error(r(558));else if(br||Uu(s,c,h,false),E=(h&s.childLanes)!==0,br||E){if(v=kn,v!==null&&(k=ke(v,h),k!==0&&k!==A.retryLane))throw A.retryLane=k,fc(s,k),Vo(v,s,k),hC;Mv(),c=wP(s,c,h);}else s=A.treeContext,Gn=Di(k.nextSibling),Wr=c,hn=true,Xs=null,Ii=false,s!==null&&cN(c,s),c=pv(c,v),c.flags|=4096;return c}return s=ns(s.child,{mode:v.mode,children:v.children}),s.ref=c.ref,c.child=s,s.return=c,s}function gv(s,c){var h=c.ref;if(h===null)s!==null&&s.ref!==null&&(c.flags|=4194816);else {if(typeof h!="function"&&typeof h!="object")throw Error(r(284));(s===null||s.ref!==h)&&(c.flags|=4194816);}}function pC(s,c,h,v,E){return gc(c),h=YS(s,c,h,v,void 0,E),v=XS(),s!==null&&!br?(QS(s,c,E),ls(s,c,E)):(hn&&v&&NS(c),c.flags|=1,qr(s,c,h,E),c.child)}function $P(s,c,h,v,E,A){return gc(c),c.updateQueue=null,h=RN(c,v,h,E),MN(s),v=XS(),s!==null&&!br?(QS(s,c,A),ls(s,c,A)):(hn&&v&&NS(c),c.flags|=1,qr(s,c,h,A),c.child)}function EP(s,c,h,v,E){if(gc(c),c.stateNode===null){var A=Fu,k=h.contextType;typeof k=="object"&&k!==null&&(A=Gr(k)),A=new h(v,A),c.memoizedState=A.state!==null&&A.state!==void 0?A.state:null,A.updater=fC,c.stateNode=A,A._reactInternals=c,A=c.stateNode,A.props=v,A.state=c.memoizedState,A.refs={},HS(c),k=h.contextType,A.context=typeof k=="object"&&k!==null?Gr(k):Fu,A.state=c.memoizedState,k=h.getDerivedStateFromProps,typeof k=="function"&&(dC(c,h,k,v),A.state=c.memoizedState),typeof h.getDerivedStateFromProps=="function"||typeof A.getSnapshotBeforeUpdate=="function"||typeof A.UNSAFE_componentWillMount!="function"&&typeof A.componentWillMount!="function"||(k=A.state,typeof A.componentWillMount=="function"&&A.componentWillMount(),typeof A.UNSAFE_componentWillMount=="function"&&A.UNSAFE_componentWillMount(),k!==A.state&&fC.enqueueReplaceState(A,A.state,null),Sm(c,v,A,E),ym(),A.state=c.memoizedState),typeof A.componentDidMount=="function"&&(c.flags|=4194308),v=true;}else if(s===null){A=c.stateNode;var Z=c.memoizedProps,le=xc(h,Z);A.props=le;var Ee=A.context,Le=h.contextType;k=Fu,typeof Le=="object"&&Le!==null&&(k=Gr(Le));var Ve=h.getDerivedStateFromProps;Le=typeof Ve=="function"||typeof A.getSnapshotBeforeUpdate=="function",Z=c.pendingProps!==Z,Le||typeof A.UNSAFE_componentWillReceiveProps!="function"&&typeof A.componentWillReceiveProps!="function"||(Z||Ee!==k)&&dP(c,A,v,k),Js=false;var Te=c.memoizedState;A.state=Te,Sm(c,v,A,E),ym(),Ee=c.memoizedState,Z||Te!==Ee||Js?(typeof Ve=="function"&&(dC(c,h,Ve,v),Ee=c.memoizedState),(le=Js||uP(c,h,le,v,Te,Ee,k))?(Le||typeof A.UNSAFE_componentWillMount!="function"&&typeof A.componentWillMount!="function"||(typeof A.componentWillMount=="function"&&A.componentWillMount(),typeof A.UNSAFE_componentWillMount=="function"&&A.UNSAFE_componentWillMount()),typeof A.componentDidMount=="function"&&(c.flags|=4194308)):(typeof A.componentDidMount=="function"&&(c.flags|=4194308),c.memoizedProps=v,c.memoizedState=Ee),A.props=v,A.state=Ee,A.context=k,v=le):(typeof A.componentDidMount=="function"&&(c.flags|=4194308),v=false);}else {A=c.stateNode,VS(s,c),k=c.memoizedProps,Le=xc(h,k),A.props=Le,Ve=c.pendingProps,Te=A.context,Ee=h.contextType,le=Fu,typeof Ee=="object"&&Ee!==null&&(le=Gr(Ee)),Z=h.getDerivedStateFromProps,(Ee=typeof Z=="function"||typeof A.getSnapshotBeforeUpdate=="function")||typeof A.UNSAFE_componentWillReceiveProps!="function"&&typeof A.componentWillReceiveProps!="function"||(k!==Ve||Te!==le)&&dP(c,A,v,le),Js=false,Te=c.memoizedState,A.state=Te,Sm(c,v,A,E),ym();var Ie=c.memoizedState;k!==Ve||Te!==Ie||Js||s!==null&&s.dependencies!==null&&Qg(s.dependencies)?(typeof Z=="function"&&(dC(c,h,Z,v),Ie=c.memoizedState),(Le=Js||uP(c,h,Le,v,Te,Ie,le)||s!==null&&s.dependencies!==null&&Qg(s.dependencies))?(Ee||typeof A.UNSAFE_componentWillUpdate!="function"&&typeof A.componentWillUpdate!="function"||(typeof A.componentWillUpdate=="function"&&A.componentWillUpdate(v,Ie,le),typeof A.UNSAFE_componentWillUpdate=="function"&&A.UNSAFE_componentWillUpdate(v,Ie,le)),typeof A.componentDidUpdate=="function"&&(c.flags|=4),typeof A.getSnapshotBeforeUpdate=="function"&&(c.flags|=1024)):(typeof A.componentDidUpdate!="function"||k===s.memoizedProps&&Te===s.memoizedState||(c.flags|=4),typeof A.getSnapshotBeforeUpdate!="function"||k===s.memoizedProps&&Te===s.memoizedState||(c.flags|=1024),c.memoizedProps=v,c.memoizedState=Ie),A.props=v,A.state=Ie,A.context=le,v=Le):(typeof A.componentDidUpdate!="function"||k===s.memoizedProps&&Te===s.memoizedState||(c.flags|=4),typeof A.getSnapshotBeforeUpdate!="function"||k===s.memoizedProps&&Te===s.memoizedState||(c.flags|=1024),v=false);}return A=v,gv(s,c),v=(c.flags&128)!==0,A||v?(A=c.stateNode,h=v&&typeof h.getDerivedStateFromError!="function"?null:A.render(),c.flags|=1,s!==null&&v?(c.child=Sc(c,s.child,null,E),c.child=Sc(c,null,h,E)):qr(s,c,h,E),c.memoizedState=A.state,s=c.child):s=ls(s,c,E),s}function MP(s,c,h,v){return hc(),c.flags|=256,qr(s,c,h,v),c.child}var gC={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function vC(s){return {baseLanes:s,cachePool:pN()}}function bC(s,c,h){return s=s!==null?s.childLanes&~h:0,c&&(s|=ai),s}function RP(s,c,h){var v=c.pendingProps,E=false,A=(c.flags&128)!==0,k;if((k=A)||(k=s!==null&&s.memoizedState===null?false:(dr.current&2)!==0),k&&(E=true,c.flags&=-129),k=(c.flags&32)!==0,c.flags&=-33,s===null){if(hn){if(E?nl(c):rl(),(s=Gn)?(s=_4(s,Ii),s=s!==null&&s.data!=="&"?s:null,s!==null&&(c.memoizedState={dehydrated:s,treeContext:Ys!==null?{id:Ta,overflow:Aa}:null,retryLane:536870912,hydrationErrors:null},h=aN(s),h.return=c,c.child=h,Wr=c,Gn=null)):s=null,s===null)throw Qs(c);return ex(s)?c.lanes=32:c.lanes=536870912,null}var Z=v.children;return v=v.fallback,E?(rl(),E=c.mode,Z=vv({mode:"hidden",children:Z},E),v=mc(v,E,h,null),Z.return=c,v.return=c,Z.sibling=v,c.child=Z,v=c.child,v.memoizedState=vC(h),v.childLanes=bC(s,k,h),c.memoizedState=gC,Em(null,v)):(nl(c),yC(c,Z))}var le=s.memoizedState;if(le!==null&&(Z=le.dehydrated,Z!==null)){if(A)c.flags&256?(nl(c),c.flags&=-257,c=SC(s,c,h)):c.memoizedState!==null?(rl(),c.child=s.child,c.flags|=128,c=null):(rl(),Z=v.fallback,E=c.mode,v=vv({mode:"visible",children:v.children},E),Z=mc(Z,E,h,null),Z.flags|=2,v.return=c,Z.return=c,v.sibling=Z,c.child=v,Sc(c,s.child,null,h),v=c.child,v.memoizedState=vC(h),v.childLanes=bC(s,k,h),c.memoizedState=gC,c=Em(null,v));else if(nl(c),ex(Z)){if(k=Z.nextSibling&&Z.nextSibling.dataset,k)var Ee=k.dgst;k=Ee,v=Error(r(419)),v.stack="",v.digest=k,mm({value:v,source:null,stack:null}),c=SC(s,c,h);}else if(br||Uu(s,c,h,false),k=(h&s.childLanes)!==0,br||k){if(k=kn,k!==null&&(v=ke(k,h),v!==0&&v!==le.retryLane))throw le.retryLane=v,fc(s,v),Vo(k,s,v),hC;JC(Z)||Mv(),c=SC(s,c,h);}else JC(Z)?(c.flags|=192,c.child=s.child,c=null):(s=le.treeContext,Gn=Di(Z.nextSibling),Wr=c,hn=true,Xs=null,Ii=false,s!==null&&cN(c,s),c=yC(c,v.children),c.flags|=4096);return c}return E?(rl(),Z=v.fallback,E=c.mode,le=s.child,Ee=le.sibling,v=ns(le,{mode:"hidden",children:v.children}),v.subtreeFlags=le.subtreeFlags&65011712,Ee!==null?Z=ns(Ee,Z):(Z=mc(Z,E,h,null),Z.flags|=2),Z.return=c,v.return=c,v.sibling=Z,c.child=v,Em(null,v),v=c.child,Z=s.child.memoizedState,Z===null?Z=vC(h):(E=Z.cachePool,E!==null?(le=gr._currentValue,E=E.parent!==le?{parent:le,pool:le}:E):E=pN(),Z={baseLanes:Z.baseLanes|h,cachePool:E}),v.memoizedState=Z,v.childLanes=bC(s,k,h),c.memoizedState=gC,Em(s.child,v)):(nl(c),h=s.child,s=h.sibling,h=ns(h,{mode:"visible",children:v.children}),h.return=c,h.sibling=null,s!==null&&(k=c.deletions,k===null?(c.deletions=[s],c.flags|=16):k.push(s)),c.child=h,c.memoizedState=null,h)}function yC(s,c){return c=vv({mode:"visible",children:c},s.mode),c.return=s,s.child=c}function vv(s,c){return s=ni(22,s,null,c),s.lanes=0,s}function SC(s,c,h){return Sc(c,s.child,null,h),s=yC(c,c.pendingProps.children),s.flags|=2,c.memoizedState=null,s}function TP(s,c,h){s.lanes|=c;var v=s.alternate;v!==null&&(v.lanes|=c),_S(s.return,c,h);}function CC(s,c,h,v,E,A){var k=s.memoizedState;k===null?s.memoizedState={isBackwards:c,rendering:null,renderingStartTime:0,last:v,tail:h,tailMode:E,treeForkCount:A}:(k.isBackwards=c,k.rendering=null,k.renderingStartTime=0,k.last=v,k.tail=h,k.tailMode=E,k.treeForkCount=A);}function AP(s,c,h){var v=c.pendingProps,E=v.revealOrder,A=v.tail;v=v.children;var k=dr.current,Z=(k&2)!==0;if(Z?(k=k&1|2,c.flags|=128):k&=1,K(dr,k),qr(s,c,v,h),v=hn?fm:0,!Z&&s!==null&&(s.flags&128)!==0)e:for(s=c.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&TP(s,h,c);else if(s.tag===19)TP(s,h,c);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===c)break e;for(;s.sibling===null;){if(s.return===null||s.return===c)break e;s=s.return;}s.sibling.return=s.return,s=s.sibling;}switch(E){case "forwards":for(h=c.child,E=null;h!==null;)s=h.alternate,s!==null&&iv(s)===null&&(E=h),h=h.sibling;h=E,h===null?(E=c.child,c.child=null):(E=h.sibling,h.sibling=null),CC(c,false,E,h,A,v);break;case "backwards":case "unstable_legacy-backwards":for(h=null,E=c.child,c.child=null;E!==null;){if(s=E.alternate,s!==null&&iv(s)===null){c.child=E;break}s=E.sibling,E.sibling=h,h=E,E=s;}CC(c,true,h,null,A,v);break;case "together":CC(c,false,null,null,void 0,v);break;default:c.memoizedState=null;}return c.child}function ls(s,c,h){if(s!==null&&(c.dependencies=s.dependencies),al|=c.lanes,(h&c.childLanes)===0)if(s!==null){if(Uu(s,c,h,false),(h&c.childLanes)===0)return null}else return null;if(s!==null&&c.child!==s.child)throw Error(r(153));if(c.child!==null){for(s=c.child,h=ns(s,s.pendingProps),c.child=h,h.return=c;s.sibling!==null;)s=s.sibling,h=h.sibling=ns(s,s.pendingProps),h.return=c;h.sibling=null;}return c.child}function xC(s,c){return (s.lanes&c)!==0?true:(s=s.dependencies,!!(s!==null&&Qg(s)))}function BY(s,c,h){switch(c.tag){case 3:ie(c,c.stateNode.containerInfo),Zs(c,gr,s.memoizedState.cache),hc();break;case 27:case 5:ne(c);break;case 4:ie(c,c.stateNode.containerInfo);break;case 10:Zs(c,c.type,c.memoizedProps.value);break;case 31:if(c.memoizedState!==null)return c.flags|=128,qS(c),null;break;case 13:var v=c.memoizedState;if(v!==null)return v.dehydrated!==null?(nl(c),c.flags|=128,null):(h&c.child.childLanes)!==0?RP(s,c,h):(nl(c),s=ls(s,c,h),s!==null?s.sibling:null);nl(c);break;case 19:var E=(s.flags&128)!==0;if(v=(h&c.childLanes)!==0,v||(Uu(s,c,h,false),v=(h&c.childLanes)!==0),E){if(v)return AP(s,c,h);c.flags|=128;}if(E=c.memoizedState,E!==null&&(E.rendering=null,E.tail=null,E.lastEffect=null),K(dr,dr.current),v)break;return null;case 22:return c.lanes=0,CP(s,c,h,c.pendingProps);case 24:Zs(c,gr,s.memoizedState.cache);}return ls(s,c,h)}function NP(s,c,h){if(s!==null)if(s.memoizedProps!==c.pendingProps)br=true;else {if(!xC(s,h)&&(c.flags&128)===0)return br=false,BY(s,c,h);br=(s.flags&131072)!==0;}else br=false,hn&&(c.flags&1048576)!==0&&lN(c,fm,c.index);switch(c.lanes=0,c.tag){case 16:e:{var v=c.pendingProps;if(s=bc(c.elementType),c.type=s,typeof s=="function")RS(s)?(v=xc(s,v),c.tag=1,c=EP(null,c,s,v,h)):(c.tag=0,c=pC(null,c,s,v,h));else {if(s!=null){var E=s.$$typeof;if(E===T){c.tag=11,c=bP(null,c,s,v,h);break e}else if(E===N){c.tag=14,c=yP(null,c,s,v,h);break e}}throw c=G(s)||s,Error(r(306,c,""))}}return c;case 0:return pC(s,c,c.type,c.pendingProps,h);case 1:return v=c.type,E=xc(v,c.pendingProps),EP(s,c,v,E,h);case 3:e:{if(ie(c,c.stateNode.containerInfo),s===null)throw Error(r(387));v=c.pendingProps;var A=c.memoizedState;E=A.element,VS(s,c),Sm(c,v,null,h);var k=c.memoizedState;if(v=k.cache,Zs(c,gr,v),v!==A.cache&&BS(c,[gr],h,true),ym(),v=k.element,A.isDehydrated)if(A={element:v,isDehydrated:false,cache:k.cache},c.updateQueue.baseState=A,c.memoizedState=A,c.flags&256){c=MP(s,c,v,h);break e}else if(v!==E){E=Ai(Error(r(424)),c),mm(E),c=MP(s,c,v,h);break e}else for(s=c.stateNode.containerInfo,s.nodeType===9?s=s.body:s=s.nodeName==="HTML"?s.ownerDocument.body:s,Gn=Di(s.firstChild),Wr=c,hn=true,Xs=null,Ii=true,h=CN(c,null,v,h),c.child=h;h;)h.flags=h.flags&-3|4096,h=h.sibling;else {if(hc(),v===E){c=ls(s,c,h);break e}qr(s,c,v,h);}c=c.child;}return c;case 26:return gv(s,c),s===null?(h=H4(c.type,null,c.pendingProps,null))?c.memoizedState=h:hn||(h=c.type,s=c.pendingProps,v=Ov(te.current).createElement(h),v[Ot]=c,v[Sn]=s,Kr(v,h,s),vn(v),c.stateNode=v):c.memoizedState=H4(c.type,s.memoizedProps,c.pendingProps,s.memoizedState),null;case 27:return ne(c),s===null&&hn&&(v=c.stateNode=z4(c.type,c.pendingProps,te.current),Wr=c,Ii=true,E=Gn,dl(c.type)?(tx=E,Gn=Di(v.firstChild)):Gn=E),qr(s,c,c.pendingProps.children,h),gv(s,c),s===null&&(c.flags|=4194304),c.child;case 5:return s===null&&hn&&((E=v=Gn)&&(v=fX(v,c.type,c.pendingProps,Ii),v!==null?(c.stateNode=v,Wr=c,Gn=Di(v.firstChild),Ii=false,E=true):E=false),E||Qs(c)),ne(c),E=c.type,A=c.pendingProps,k=s!==null?s.memoizedProps:null,v=A.children,XC(E,A)?v=null:k!==null&&XC(E,k)&&(c.flags|=32),c.memoizedState!==null&&(E=YS(s,c,RY,null,null,h),Fm._currentValue=E),gv(s,c),qr(s,c,v,h),c.child;case 6:return s===null&&hn&&((s=h=Gn)&&(h=mX(h,c.pendingProps,Ii),h!==null?(c.stateNode=h,Wr=c,Gn=null,s=true):s=false),s||Qs(c)),null;case 13:return RP(s,c,h);case 4:return ie(c,c.stateNode.containerInfo),v=c.pendingProps,s===null?c.child=Sc(c,null,v,h):qr(s,c,v,h),c.child;case 11:return bP(s,c,c.type,c.pendingProps,h);case 7:return qr(s,c,c.pendingProps,h),c.child;case 8:return qr(s,c,c.pendingProps.children,h),c.child;case 12:return qr(s,c,c.pendingProps.children,h),c.child;case 10:return v=c.pendingProps,Zs(c,c.type,v.value),qr(s,c,v.children,h),c.child;case 9:return E=c.type._context,v=c.pendingProps.children,gc(c),E=Gr(E),v=v(E),c.flags|=1,qr(s,c,v,h),c.child;case 14:return yP(s,c,c.type,c.pendingProps,h);case 15:return SP(s,c,c.type,c.pendingProps,h);case 19:return AP(s,c,h);case 31:return _Y(s,c,h);case 22:return CP(s,c,h,c.pendingProps);case 24:return gc(c),v=Gr(gr),s===null?(E=kS(),E===null&&(E=kn,A=LS(),E.pooledCache=A,A.refCount++,A!==null&&(E.pooledCacheLanes|=h),E=A),c.memoizedState={parent:v,cache:E},HS(c),Zs(c,gr,E)):((s.lanes&h)!==0&&(VS(s,c),Sm(c,null,null,h),ym()),E=s.memoizedState,A=c.memoizedState,E.parent!==v?(E={parent:v,cache:v},c.memoizedState=E,c.lanes===0&&(c.memoizedState=c.updateQueue.baseState=E),Zs(c,gr,v)):(v=A.cache,Zs(c,gr,v),v!==E.cache&&BS(c,[gr],h,true))),qr(s,c,c.pendingProps.children,h),c.child;case 29:throw c.pendingProps}throw Error(r(156,c.tag))}function cs(s){s.flags|=4;}function wC(s,c,h,v,E){if((c=(s.mode&32)!==0)&&(c=false),c){if(s.flags|=16777216,(E&335544128)===E)if(s.stateNode.complete)s.flags|=8192;else if(r4())s.flags|=8192;else throw yc=tv,FS}else s.flags&=-16777217;}function PP(s,c){if(c.type!=="stylesheet"||(c.state.loading&4)!==0)s.flags&=-16777217;else if(s.flags|=16777216,!G4(c))if(r4())s.flags|=8192;else throw yc=tv,FS}function bv(s,c){c!==null&&(s.flags|=4),s.flags&16384&&(c=s.tag!==22?ye():536870912,s.lanes|=c,nd|=c);}function Mm(s,c){if(!hn)switch(s.tailMode){case "hidden":c=s.tail;for(var h=null;c!==null;)c.alternate!==null&&(h=c),c=c.sibling;h===null?s.tail=null:h.sibling=null;break;case "collapsed":h=s.tail;for(var v=null;h!==null;)h.alternate!==null&&(v=h),h=h.sibling;v===null?c||s.tail===null?s.tail=null:s.tail.sibling=null:v.sibling=null;}}function qn(s){var c=s.alternate!==null&&s.alternate.child===s.child,h=0,v=0;if(c)for(var E=s.child;E!==null;)h|=E.lanes|E.childLanes,v|=E.subtreeFlags&65011712,v|=E.flags&65011712,E.return=s,E=E.sibling;else for(E=s.child;E!==null;)h|=E.lanes|E.childLanes,v|=E.subtreeFlags,v|=E.flags,E.return=s,E=E.sibling;return s.subtreeFlags|=v,s.childLanes=h,c}function LY(s,c,h){var v=c.pendingProps;switch(PS(c),c.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return qn(c),null;case 1:return qn(c),null;case 3:return h=c.stateNode,v=null,s!==null&&(v=s.memoizedState.cache),c.memoizedState.cache!==v&&(c.flags|=2048),is(gr),de(),h.pendingContext&&(h.context=h.pendingContext,h.pendingContext=null),(s===null||s.child===null)&&(ju(c)?cs(c):s===null||s.memoizedState.isDehydrated&&(c.flags&256)===0||(c.flags|=1024,OS())),qn(c),null;case 26:var E=c.type,A=c.memoizedState;return s===null?(cs(c),A!==null?(qn(c),PP(c,A)):(qn(c),wC(c,E,null,v,h))):A?A!==s.memoizedState?(cs(c),qn(c),PP(c,A)):(qn(c),c.flags&=-16777217):(s=s.memoizedProps,s!==v&&cs(c),qn(c),wC(c,E,s,v,h)),null;case 27:if(ce(c),h=te.current,E=c.type,s!==null&&c.stateNode!=null)s.memoizedProps!==v&&cs(c);else {if(!v){if(c.stateNode===null)throw Error(r(166));return qn(c),null}s=J.current,ju(c)?uN(c):(s=z4(E,v,h),c.stateNode=s,cs(c));}return qn(c),null;case 5:if(ce(c),E=c.type,s!==null&&c.stateNode!=null)s.memoizedProps!==v&&cs(c);else {if(!v){if(c.stateNode===null)throw Error(r(166));return qn(c),null}if(A=J.current,ju(c))uN(c);else {var k=Ov(te.current);switch(A){case 1:A=k.createElementNS("http://www.w3.org/2000/svg",E);break;case 2:A=k.createElementNS("http://www.w3.org/1998/Math/MathML",E);break;default:switch(E){case "svg":A=k.createElementNS("http://www.w3.org/2000/svg",E);break;case "math":A=k.createElementNS("http://www.w3.org/1998/Math/MathML",E);break;case "script":A=k.createElement("div"),A.innerHTML="<script><\/script>",A=A.removeChild(A.firstChild);break;case "select":A=typeof v.is=="string"?k.createElement("select",{is:v.is}):k.createElement("select"),v.multiple?A.multiple=true:v.size&&(A.size=v.size);break;default:A=typeof v.is=="string"?k.createElement(E,{is:v.is}):k.createElement(E);}}A[Ot]=c,A[Sn]=v;e:for(k=c.child;k!==null;){if(k.tag===5||k.tag===6)A.appendChild(k.stateNode);else if(k.tag!==4&&k.tag!==27&&k.child!==null){k.child.return=k,k=k.child;continue}if(k===c)break e;for(;k.sibling===null;){if(k.return===null||k.return===c)break e;k=k.return;}k.sibling.return=k.return,k=k.sibling;}c.stateNode=A;e:switch(Kr(A,E,v),E){case "button":case "input":case "select":case "textarea":v=!!v.autoFocus;break e;case "img":v=true;break e;default:v=false;}v&&cs(c);}}return qn(c),wC(c,c.type,s===null?null:s.memoizedProps,c.pendingProps,h),null;case 6:if(s&&c.stateNode!=null)s.memoizedProps!==v&&cs(c);else {if(typeof v!="string"&&c.stateNode===null)throw Error(r(166));if(s=te.current,ju(c)){if(s=c.stateNode,h=c.memoizedProps,v=null,E=Wr,E!==null)switch(E.tag){case 27:case 5:v=E.memoizedProps;}s[Ot]=c,s=!!(s.nodeValue===h||v!==null&&v.suppressHydrationWarning===true||R4(s.nodeValue,h)),s||Qs(c,true);}else s=Ov(s).createTextNode(v),s[Ot]=c,c.stateNode=s;}return qn(c),null;case 31:if(h=c.memoizedState,s===null||s.memoizedState!==null){if(v=ju(c),h!==null){if(s===null){if(!v)throw Error(r(318));if(s=c.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(r(557));s[Ot]=c;}else hc(),(c.flags&128)===0&&(c.memoizedState=null),c.flags|=4;qn(c),s=false;}else h=OS(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=h),s=true;if(!s)return c.flags&256?(oi(c),c):(oi(c),null);if((c.flags&128)!==0)throw Error(r(558))}return qn(c),null;case 13:if(v=c.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(E=ju(c),v!==null&&v.dehydrated!==null){if(s===null){if(!E)throw Error(r(318));if(E=c.memoizedState,E=E!==null?E.dehydrated:null,!E)throw Error(r(317));E[Ot]=c;}else hc(),(c.flags&128)===0&&(c.memoizedState=null),c.flags|=4;qn(c),E=false;}else E=OS(),s!==null&&s.memoizedState!==null&&(s.memoizedState.hydrationErrors=E),E=true;if(!E)return c.flags&256?(oi(c),c):(oi(c),null)}return oi(c),(c.flags&128)!==0?(c.lanes=h,c):(h=v!==null,s=s!==null&&s.memoizedState!==null,h&&(v=c.child,E=null,v.alternate!==null&&v.alternate.memoizedState!==null&&v.alternate.memoizedState.cachePool!==null&&(E=v.alternate.memoizedState.cachePool.pool),A=null,v.memoizedState!==null&&v.memoizedState.cachePool!==null&&(A=v.memoizedState.cachePool.pool),A!==E&&(v.flags|=2048)),h!==s&&h&&(c.child.flags|=8192),bv(c,c.updateQueue),qn(c),null);case 4:return de(),s===null&&WC(c.stateNode.containerInfo),qn(c),null;case 10:return is(c.type),qn(c),null;case 19:if(L(dr),v=c.memoizedState,v===null)return qn(c),null;if(E=(c.flags&128)!==0,A=v.rendering,A===null)if(E)Mm(v,false);else {if(ir!==0||s!==null&&(s.flags&128)!==0)for(s=c.child;s!==null;){if(A=iv(s),A!==null){for(c.flags|=128,Mm(v,false),s=A.updateQueue,c.updateQueue=s,bv(c,s),c.subtreeFlags=0,s=h,h=c.child;h!==null;)iN(h,s),h=h.sibling;return K(dr,dr.current&1|2),hn&&rs(c,v.treeForkCount),c.child}s=s.sibling;}v.tail!==null&&Pe()>wv&&(c.flags|=128,E=true,Mm(v,false),c.lanes=4194304);}else {if(!E)if(s=iv(A),s!==null){if(c.flags|=128,E=true,s=s.updateQueue,c.updateQueue=s,bv(c,s),Mm(v,true),v.tail===null&&v.tailMode==="hidden"&&!A.alternate&&!hn)return qn(c),null}else 2*Pe()-v.renderingStartTime>wv&&h!==536870912&&(c.flags|=128,E=true,Mm(v,false),c.lanes=4194304);v.isBackwards?(A.sibling=c.child,c.child=A):(s=v.last,s!==null?s.sibling=A:c.child=A,v.last=A);}return v.tail!==null?(s=v.tail,v.rendering=s,v.tail=s.sibling,v.renderingStartTime=Pe(),s.sibling=null,h=dr.current,K(dr,E?h&1|2:h&1),hn&&rs(c,v.treeForkCount),s):(qn(c),null);case 22:case 23:return oi(c),GS(),v=c.memoizedState!==null,s!==null?s.memoizedState!==null!==v&&(c.flags|=8192):v&&(c.flags|=8192),v?(h&536870912)!==0&&(c.flags&128)===0&&(qn(c),c.subtreeFlags&6&&(c.flags|=8192)):qn(c),h=c.updateQueue,h!==null&&bv(c,h.retryQueue),h=null,s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(h=s.memoizedState.cachePool.pool),v=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(v=c.memoizedState.cachePool.pool),v!==h&&(c.flags|=2048),s!==null&&L(vc),null;case 24:return h=null,s!==null&&(h=s.memoizedState.cache),c.memoizedState.cache!==h&&(c.flags|=2048),is(gr),qn(c),null;case 25:return null;case 30:return null}throw Error(r(156,c.tag))}function zY(s,c){switch(PS(c),c.tag){case 1:return s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 3:return is(gr),de(),s=c.flags,(s&65536)!==0&&(s&128)===0?(c.flags=s&-65537|128,c):null;case 26:case 27:case 5:return ce(c),null;case 31:if(c.memoizedState!==null){if(oi(c),c.alternate===null)throw Error(r(340));hc();}return s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 13:if(oi(c),s=c.memoizedState,s!==null&&s.dehydrated!==null){if(c.alternate===null)throw Error(r(340));hc();}return s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 19:return L(dr),null;case 4:return de(),null;case 10:return is(c.type),null;case 22:case 23:return oi(c),GS(),s!==null&&L(vc),s=c.flags,s&65536?(c.flags=s&-65537|128,c):null;case 24:return is(gr),null;case 25:return null;default:return null}}function IP(s,c){switch(PS(c),c.tag){case 3:is(gr),de();break;case 26:case 27:case 5:ce(c);break;case 4:de();break;case 31:c.memoizedState!==null&&oi(c);break;case 13:oi(c);break;case 19:L(dr);break;case 10:is(c.type);break;case 22:case 23:oi(c),GS(),s!==null&&L(vc);break;case 24:is(gr);}}function Rm(s,c){try{var h=c.updateQueue,v=h!==null?h.lastEffect:null;if(v!==null){var E=v.next;h=E;do{if((h.tag&s)===s){v=void 0;var A=h.create,k=h.inst;v=A(),k.destroy=v;}h=h.next;}while(h!==E)}}catch(Z){Pn(c,c.return,Z);}}function ol(s,c,h){try{var v=c.updateQueue,E=v!==null?v.lastEffect:null;if(E!==null){var A=E.next;v=A;do{if((v.tag&s)===s){var k=v.inst,Z=k.destroy;if(Z!==void 0){k.destroy=void 0,E=c;var le=h,Ee=Z;try{Ee();}catch(Le){Pn(E,le,Le);}}}v=v.next;}while(v!==A)}}catch(Le){Pn(c,c.return,Le);}}function OP(s){var c=s.updateQueue;if(c!==null){var h=s.stateNode;try{wN(c,h);}catch(v){Pn(s,s.return,v);}}}function DP(s,c,h){h.props=xc(s.type,s.memoizedProps),h.state=s.memoizedState;try{h.componentWillUnmount();}catch(v){Pn(s,c,v);}}function Tm(s,c){try{var h=s.ref;if(h!==null){switch(s.tag){case 26:case 27:case 5:var v=s.stateNode;break;case 30:v=s.stateNode;break;default:v=s.stateNode;}typeof h=="function"?s.refCleanup=h(v):h.current=v;}}catch(E){Pn(s,c,E);}}function Na(s,c){var h=s.ref,v=s.refCleanup;if(h!==null)if(typeof v=="function")try{v();}catch(E){Pn(s,c,E);}finally{s.refCleanup=null,s=s.alternate,s!=null&&(s.refCleanup=null);}else if(typeof h=="function")try{h(null);}catch(E){Pn(s,c,E);}else h.current=null;}function _P(s){var c=s.type,h=s.memoizedProps,v=s.stateNode;try{e:switch(c){case "button":case "input":case "select":case "textarea":h.autoFocus&&v.focus();break e;case "img":h.src?v.src=h.src:h.srcSet&&(v.srcset=h.srcSet);}}catch(E){Pn(s,s.return,E);}}function $C(s,c,h){try{var v=s.stateNode;aX(v,s.type,h,c),v[Sn]=c;}catch(E){Pn(s,s.return,E);}}function BP(s){return s.tag===5||s.tag===3||s.tag===26||s.tag===27&&dl(s.type)||s.tag===4}function EC(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||BP(s.return))return null;s=s.return;}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.tag===27&&dl(s.type)||s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child;}if(!(s.flags&2))return s.stateNode}}function MC(s,c,h){var v=s.tag;if(v===5||v===6)s=s.stateNode,c?(h.nodeType===9?h.body:h.nodeName==="HTML"?h.ownerDocument.body:h).insertBefore(s,c):(c=h.nodeType===9?h.body:h.nodeName==="HTML"?h.ownerDocument.body:h,c.appendChild(s),h=h._reactRootContainer,h!=null||c.onclick!==null||(c.onclick=es));else if(v!==4&&(v===27&&dl(s.type)&&(h=s.stateNode,c=null),s=s.child,s!==null))for(MC(s,c,h),s=s.sibling;s!==null;)MC(s,c,h),s=s.sibling;}function yv(s,c,h){var v=s.tag;if(v===5||v===6)s=s.stateNode,c?h.insertBefore(s,c):h.appendChild(s);else if(v!==4&&(v===27&&dl(s.type)&&(h=s.stateNode),s=s.child,s!==null))for(yv(s,c,h),s=s.sibling;s!==null;)yv(s,c,h),s=s.sibling;}function LP(s){var c=s.stateNode,h=s.memoizedProps;try{for(var v=s.type,E=c.attributes;E.length;)c.removeAttributeNode(E[0]);Kr(c,v,h),c[Ot]=s,c[Sn]=h;}catch(A){Pn(s,s.return,A);}}var us=false,yr=false,RC=false,zP=typeof WeakSet=="function"?WeakSet:Set,Dr=null;function kY(s,c){if(s=s.containerInfo,KC=Fv,s=X6(s),SS(s)){if("selectionStart"in s)var h={start:s.selectionStart,end:s.selectionEnd};else e:{h=(h=s.ownerDocument)&&h.defaultView||window;var v=h.getSelection&&h.getSelection();if(v&&v.rangeCount!==0){h=v.anchorNode;var E=v.anchorOffset,A=v.focusNode;v=v.focusOffset;try{h.nodeType,A.nodeType;}catch{h=null;break e}var k=0,Z=-1,le=-1,Ee=0,Le=0,Ve=s,Te=null;t:for(;;){for(var Ie;Ve!==h||E!==0&&Ve.nodeType!==3||(Z=k+E),Ve!==A||v!==0&&Ve.nodeType!==3||(le=k+v),Ve.nodeType===3&&(k+=Ve.nodeValue.length),(Ie=Ve.firstChild)!==null;)Te=Ve,Ve=Ie;for(;;){if(Ve===s)break t;if(Te===h&&++Ee===E&&(Z=k),Te===A&&++Le===v&&(le=k),(Ie=Ve.nextSibling)!==null)break;Ve=Te,Te=Ve.parentNode;}Ve=Ie;}h=Z===-1||le===-1?null:{start:Z,end:le};}else h=null;}h=h||{start:0,end:0};}else h=null;for(YC={focusedElem:s,selectionRange:h},Fv=false,Dr=c;Dr!==null;)if(c=Dr,s=c.child,(c.subtreeFlags&1028)!==0&&s!==null)s.return=c,Dr=s;else for(;Dr!==null;){switch(c=Dr,A=c.alternate,s=c.flags,c.tag){case 0:if((s&4)!==0&&(s=c.updateQueue,s=s!==null?s.events:null,s!==null))for(h=0;h<s.length;h++)E=s[h],E.ref.impl=E.nextImpl;break;case 11:case 15:break;case 1:if((s&1024)!==0&&A!==null){s=void 0,h=c,E=A.memoizedProps,A=A.memoizedState,v=h.stateNode;try{var pt=xc(h.type,E);s=v.getSnapshotBeforeUpdate(pt,A),v.__reactInternalSnapshotBeforeUpdate=s;}catch(Nt){Pn(h,h.return,Nt);}}break;case 3:if((s&1024)!==0){if(s=c.stateNode.containerInfo,h=s.nodeType,h===9)ZC(s);else if(h===1)switch(s.nodeName){case "HEAD":case "HTML":case "BODY":ZC(s);break;default:s.textContent="";}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((s&1024)!==0)throw Error(r(163))}if(s=c.sibling,s!==null){s.return=c.return,Dr=s;break}Dr=c.return;}}function kP(s,c,h){var v=h.flags;switch(h.tag){case 0:case 11:case 15:fs(s,h),v&4&&Rm(5,h);break;case 1:if(fs(s,h),v&4)if(s=h.stateNode,c===null)try{s.componentDidMount();}catch(k){Pn(h,h.return,k);}else {var E=xc(h.type,c.memoizedProps);c=c.memoizedState;try{s.componentDidUpdate(E,c,s.__reactInternalSnapshotBeforeUpdate);}catch(k){Pn(h,h.return,k);}}v&64&&OP(h),v&512&&Tm(h,h.return);break;case 3:if(fs(s,h),v&64&&(s=h.updateQueue,s!==null)){if(c=null,h.child!==null)switch(h.child.tag){case 27:case 5:c=h.child.stateNode;break;case 1:c=h.child.stateNode;}try{wN(s,c);}catch(k){Pn(h,h.return,k);}}break;case 27:c===null&&v&4&&LP(h);case 26:case 5:fs(s,h),c===null&&v&4&&_P(h),v&512&&Tm(h,h.return);break;case 12:fs(s,h);break;case 31:fs(s,h),v&4&&VP(s,h);break;case 13:fs(s,h),v&4&&jP(s,h),v&64&&(s=h.memoizedState,s!==null&&(s=s.dehydrated,s!==null&&(h=KY.bind(null,h),hX(s,h))));break;case 22:if(v=h.memoizedState!==null||us,!v){c=c!==null&&c.memoizedState!==null||yr,E=us;var A=yr;us=v,(yr=c)&&!A?ms(s,h,(h.subtreeFlags&8772)!==0):fs(s,h),us=E,yr=A;}break;case 30:break;default:fs(s,h);}}function FP(s){var c=s.alternate;c!==null&&(s.alternate=null,FP(c)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(c=s.stateNode,c!==null&&en(c)),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null;}var Zn=null,zo=false;function ds(s,c,h){for(h=h.child;h!==null;)HP(s,c,h),h=h.sibling;}function HP(s,c,h){if(Be&&typeof Be.onCommitFiberUnmount=="function")try{Be.onCommitFiberUnmount(Ze,h);}catch{}switch(h.tag){case 26:yr||Na(h,c),ds(s,c,h),h.memoizedState?h.memoizedState.count--:h.stateNode&&(h=h.stateNode,h.parentNode.removeChild(h));break;case 27:yr||Na(h,c);var v=Zn,E=zo;dl(h.type)&&(Zn=h.stateNode,zo=false),ds(s,c,h),Lm(h.stateNode),Zn=v,zo=E;break;case 5:yr||Na(h,c);case 6:if(v=Zn,E=zo,Zn=null,ds(s,c,h),Zn=v,zo=E,Zn!==null)if(zo)try{(Zn.nodeType===9?Zn.body:Zn.nodeName==="HTML"?Zn.ownerDocument.body:Zn).removeChild(h.stateNode);}catch(A){Pn(h,c,A);}else try{Zn.removeChild(h.stateNode);}catch(A){Pn(h,c,A);}break;case 18:Zn!==null&&(zo?(s=Zn,O4(s.nodeType===9?s.body:s.nodeName==="HTML"?s.ownerDocument.body:s,h.stateNode),ud(s)):O4(Zn,h.stateNode));break;case 4:v=Zn,E=zo,Zn=h.stateNode.containerInfo,zo=true,ds(s,c,h),Zn=v,zo=E;break;case 0:case 11:case 14:case 15:ol(2,h,c),yr||ol(4,h,c),ds(s,c,h);break;case 1:yr||(Na(h,c),v=h.stateNode,typeof v.componentWillUnmount=="function"&&DP(h,c,v)),ds(s,c,h);break;case 21:ds(s,c,h);break;case 22:yr=(v=yr)||h.memoizedState!==null,ds(s,c,h),yr=v;break;default:ds(s,c,h);}}function VP(s,c){if(c.memoizedState===null&&(s=c.alternate,s!==null&&(s=s.memoizedState,s!==null))){s=s.dehydrated;try{ud(s);}catch(h){Pn(c,c.return,h);}}}function jP(s,c){if(c.memoizedState===null&&(s=c.alternate,s!==null&&(s=s.memoizedState,s!==null&&(s=s.dehydrated,s!==null))))try{ud(s);}catch(h){Pn(c,c.return,h);}}function FY(s){switch(s.tag){case 31:case 13:case 19:var c=s.stateNode;return c===null&&(c=s.stateNode=new zP),c;case 22:return s=s.stateNode,c=s._retryCache,c===null&&(c=s._retryCache=new zP),c;default:throw Error(r(435,s.tag))}}function Sv(s,c){var h=FY(s);c.forEach(function(v){if(!h.has(v)){h.add(v);var E=YY.bind(null,s,v);v.then(E,E);}});}function ko(s,c){var h=c.deletions;if(h!==null)for(var v=0;v<h.length;v++){var E=h[v],A=s,k=c,Z=k;e:for(;Z!==null;){switch(Z.tag){case 27:if(dl(Z.type)){Zn=Z.stateNode,zo=false;break e}break;case 5:Zn=Z.stateNode,zo=false;break e;case 3:case 4:Zn=Z.stateNode.containerInfo,zo=true;break e}Z=Z.return;}if(Zn===null)throw Error(r(160));HP(A,k,E),Zn=null,zo=false,A=E.alternate,A!==null&&(A.return=null),E.return=null;}if(c.subtreeFlags&13886)for(c=c.child;c!==null;)UP(c,s),c=c.sibling;}var Ji=null;function UP(s,c){var h=s.alternate,v=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:ko(c,s),Fo(s),v&4&&(ol(3,s,s.return),Rm(3,s),ol(5,s,s.return));break;case 1:ko(c,s),Fo(s),v&512&&(yr||h===null||Na(h,h.return)),v&64&&us&&(s=s.updateQueue,s!==null&&(v=s.callbacks,v!==null&&(h=s.shared.hiddenCallbacks,s.shared.hiddenCallbacks=h===null?v:h.concat(v))));break;case 26:var E=Ji;if(ko(c,s),Fo(s),v&512&&(yr||h===null||Na(h,h.return)),v&4){var A=h!==null?h.memoizedState:null;if(v=s.memoizedState,h===null)if(v===null)if(s.stateNode===null){e:{v=s.type,h=s.memoizedProps,E=E.ownerDocument||E;t:switch(v){case "title":A=E.getElementsByTagName("title")[0],(!A||A[At]||A[Ot]||A.namespaceURI==="http://www.w3.org/2000/svg"||A.hasAttribute("itemprop"))&&(A=E.createElement(v),E.head.insertBefore(A,E.querySelector("head > title"))),Kr(A,v,h),A[Ot]=s,vn(A),v=A;break e;case "link":var k=U4("link","href",E).get(v+(h.href||""));if(k){for(var Z=0;Z<k.length;Z++)if(A=k[Z],A.getAttribute("href")===(h.href==null||h.href===""?null:h.href)&&A.getAttribute("rel")===(h.rel==null?null:h.rel)&&A.getAttribute("title")===(h.title==null?null:h.title)&&A.getAttribute("crossorigin")===(h.crossOrigin==null?null:h.crossOrigin)){k.splice(Z,1);break t}}A=E.createElement(v),Kr(A,v,h),E.head.appendChild(A);break;case "meta":if(k=U4("meta","content",E).get(v+(h.content||""))){for(Z=0;Z<k.length;Z++)if(A=k[Z],A.getAttribute("content")===(h.content==null?null:""+h.content)&&A.getAttribute("name")===(h.name==null?null:h.name)&&A.getAttribute("property")===(h.property==null?null:h.property)&&A.getAttribute("http-equiv")===(h.httpEquiv==null?null:h.httpEquiv)&&A.getAttribute("charset")===(h.charSet==null?null:h.charSet)){k.splice(Z,1);break t}}A=E.createElement(v),Kr(A,v,h),E.head.appendChild(A);break;default:throw Error(r(468,v))}A[Ot]=s,vn(A),v=A;}s.stateNode=v;}else W4(E,s.type,s.stateNode);else s.stateNode=j4(E,v,s.memoizedProps);else A!==v?(A===null?h.stateNode!==null&&(h=h.stateNode,h.parentNode.removeChild(h)):A.count--,v===null?W4(E,s.type,s.stateNode):j4(E,v,s.memoizedProps)):v===null&&s.stateNode!==null&&$C(s,s.memoizedProps,h.memoizedProps);}break;case 27:ko(c,s),Fo(s),v&512&&(yr||h===null||Na(h,h.return)),h!==null&&v&4&&$C(s,s.memoizedProps,h.memoizedProps);break;case 5:if(ko(c,s),Fo(s),v&512&&(yr||h===null||Na(h,h.return)),s.flags&32){E=s.stateNode;try{Ou(E,"");}catch(pt){Pn(s,s.return,pt);}}v&4&&s.stateNode!=null&&(E=s.memoizedProps,$C(s,E,h!==null?h.memoizedProps:E)),v&1024&&(RC=true);break;case 6:if(ko(c,s),Fo(s),v&4){if(s.stateNode===null)throw Error(r(162));v=s.memoizedProps,h=s.stateNode;try{h.nodeValue=v;}catch(pt){Pn(s,s.return,pt);}}break;case 3:if(Bv=null,E=Ji,Ji=Dv(c.containerInfo),ko(c,s),Ji=E,Fo(s),v&4&&h!==null&&h.memoizedState.isDehydrated)try{ud(c.containerInfo);}catch(pt){Pn(s,s.return,pt);}RC&&(RC=false,WP(s));break;case 4:v=Ji,Ji=Dv(s.stateNode.containerInfo),ko(c,s),Fo(s),Ji=v;break;case 12:ko(c,s),Fo(s);break;case 31:ko(c,s),Fo(s),v&4&&(v=s.updateQueue,v!==null&&(s.updateQueue=null,Sv(s,v)));break;case 13:ko(c,s),Fo(s),s.child.flags&8192&&s.memoizedState!==null!=(h!==null&&h.memoizedState!==null)&&(xv=Pe()),v&4&&(v=s.updateQueue,v!==null&&(s.updateQueue=null,Sv(s,v)));break;case 22:E=s.memoizedState!==null;var le=h!==null&&h.memoizedState!==null,Ee=us,Le=yr;if(us=Ee||E,yr=Le||le,ko(c,s),yr=Le,us=Ee,Fo(s),v&8192)e:for(c=s.stateNode,c._visibility=E?c._visibility&-2:c._visibility|1,E&&(h===null||le||us||yr||wc(s)),h=null,c=s;;){if(c.tag===5||c.tag===26){if(h===null){le=h=c;try{if(A=le.stateNode,E)k=A.style,typeof k.setProperty=="function"?k.setProperty("display","none","important"):k.display="none";else {Z=le.stateNode;var Ve=le.memoizedProps.style,Te=Ve!=null&&Ve.hasOwnProperty("display")?Ve.display:null;Z.style.display=Te==null||typeof Te=="boolean"?"":(""+Te).trim();}}catch(pt){Pn(le,le.return,pt);}}}else if(c.tag===6){if(h===null){le=c;try{le.stateNode.nodeValue=E?"":le.memoizedProps;}catch(pt){Pn(le,le.return,pt);}}}else if(c.tag===18){if(h===null){le=c;try{var Ie=le.stateNode;E?D4(Ie,!0):D4(le.stateNode,!1);}catch(pt){Pn(le,le.return,pt);}}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===s)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===s)break e;for(;c.sibling===null;){if(c.return===null||c.return===s)break e;h===c&&(h=null),c=c.return;}h===c&&(h=null),c.sibling.return=c.return,c=c.sibling;}v&4&&(v=s.updateQueue,v!==null&&(h=v.retryQueue,h!==null&&(v.retryQueue=null,Sv(s,h))));break;case 19:ko(c,s),Fo(s),v&4&&(v=s.updateQueue,v!==null&&(s.updateQueue=null,Sv(s,v)));break;case 30:break;case 21:break;default:ko(c,s),Fo(s);}}function Fo(s){var c=s.flags;if(c&2){try{for(var h,v=s.return;v!==null;){if(BP(v)){h=v;break}v=v.return;}if(h==null)throw Error(r(160));switch(h.tag){case 27:var E=h.stateNode,A=EC(s);yv(s,A,E);break;case 5:var k=h.stateNode;h.flags&32&&(Ou(k,""),h.flags&=-33);var Z=EC(s);yv(s,Z,k);break;case 3:case 4:var le=h.stateNode.containerInfo,Ee=EC(s);MC(s,Ee,le);break;default:throw Error(r(161))}}catch(Le){Pn(s,s.return,Le);}s.flags&=-3;}c&4096&&(s.flags&=-4097);}function WP(s){if(s.subtreeFlags&1024)for(s=s.child;s!==null;){var c=s;WP(c),c.tag===5&&c.flags&1024&&c.stateNode.reset(),s=s.sibling;}}function fs(s,c){if(c.subtreeFlags&8772)for(c=c.child;c!==null;)kP(s,c.alternate,c),c=c.sibling;}function wc(s){for(s=s.child;s!==null;){var c=s;switch(c.tag){case 0:case 11:case 14:case 15:ol(4,c,c.return),wc(c);break;case 1:Na(c,c.return);var h=c.stateNode;typeof h.componentWillUnmount=="function"&&DP(c,c.return,h),wc(c);break;case 27:Lm(c.stateNode);case 26:case 5:Na(c,c.return),wc(c);break;case 22:c.memoizedState===null&&wc(c);break;case 30:wc(c);break;default:wc(c);}s=s.sibling;}}function ms(s,c,h){for(h=h&&(c.subtreeFlags&8772)!==0,c=c.child;c!==null;){var v=c.alternate,E=s,A=c,k=A.flags;switch(A.tag){case 0:case 11:case 15:ms(E,A,h),Rm(4,A);break;case 1:if(ms(E,A,h),v=A,E=v.stateNode,typeof E.componentDidMount=="function")try{E.componentDidMount();}catch(Ee){Pn(v,v.return,Ee);}if(v=A,E=v.updateQueue,E!==null){var Z=v.stateNode;try{var le=E.shared.hiddenCallbacks;if(le!==null)for(E.shared.hiddenCallbacks=null,E=0;E<le.length;E++)xN(le[E],Z);}catch(Ee){Pn(v,v.return,Ee);}}h&&k&64&&OP(A),Tm(A,A.return);break;case 27:LP(A);case 26:case 5:ms(E,A,h),h&&v===null&&k&4&&_P(A),Tm(A,A.return);break;case 12:ms(E,A,h);break;case 31:ms(E,A,h),h&&k&4&&VP(E,A);break;case 13:ms(E,A,h),h&&k&4&&jP(E,A);break;case 22:A.memoizedState===null&&ms(E,A,h),Tm(A,A.return);break;case 30:break;default:ms(E,A,h);}c=c.sibling;}}function TC(s,c){var h=null;s!==null&&s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(h=s.memoizedState.cachePool.pool),s=null,c.memoizedState!==null&&c.memoizedState.cachePool!==null&&(s=c.memoizedState.cachePool.pool),s!==h&&(s!=null&&s.refCount++,h!=null&&hm(h));}function AC(s,c){s=null,c.alternate!==null&&(s=c.alternate.memoizedState.cache),c=c.memoizedState.cache,c!==s&&(c.refCount++,s!=null&&hm(s));}function ea(s,c,h,v){if(c.subtreeFlags&10256)for(c=c.child;c!==null;)GP(s,c,h,v),c=c.sibling;}function GP(s,c,h,v){var E=c.flags;switch(c.tag){case 0:case 11:case 15:ea(s,c,h,v),E&2048&&Rm(9,c);break;case 1:ea(s,c,h,v);break;case 3:ea(s,c,h,v),E&2048&&(s=null,c.alternate!==null&&(s=c.alternate.memoizedState.cache),c=c.memoizedState.cache,c!==s&&(c.refCount++,s!=null&&hm(s)));break;case 12:if(E&2048){ea(s,c,h,v),s=c.stateNode;try{var A=c.memoizedProps,k=A.id,Z=A.onPostCommit;typeof Z=="function"&&Z(k,c.alternate===null?"mount":"update",s.passiveEffectDuration,-0);}catch(le){Pn(c,c.return,le);}}else ea(s,c,h,v);break;case 31:ea(s,c,h,v);break;case 13:ea(s,c,h,v);break;case 23:break;case 22:A=c.stateNode,k=c.alternate,c.memoizedState!==null?A._visibility&2?ea(s,c,h,v):Am(s,c):A._visibility&2?ea(s,c,h,v):(A._visibility|=2,Ju(s,c,h,v,(c.subtreeFlags&10256)!==0||false)),E&2048&&TC(k,c);break;case 24:ea(s,c,h,v),E&2048&&AC(c.alternate,c);break;default:ea(s,c,h,v);}}function Ju(s,c,h,v,E){for(E=E&&((c.subtreeFlags&10256)!==0||false),c=c.child;c!==null;){var A=s,k=c,Z=h,le=v,Ee=k.flags;switch(k.tag){case 0:case 11:case 15:Ju(A,k,Z,le,E),Rm(8,k);break;case 23:break;case 22:var Le=k.stateNode;k.memoizedState!==null?Le._visibility&2?Ju(A,k,Z,le,E):Am(A,k):(Le._visibility|=2,Ju(A,k,Z,le,E)),E&&Ee&2048&&TC(k.alternate,k);break;case 24:Ju(A,k,Z,le,E),E&&Ee&2048&&AC(k.alternate,k);break;default:Ju(A,k,Z,le,E);}c=c.sibling;}}function Am(s,c){if(c.subtreeFlags&10256)for(c=c.child;c!==null;){var h=s,v=c,E=v.flags;switch(v.tag){case 22:Am(h,v),E&2048&&TC(v.alternate,v);break;case 24:Am(h,v),E&2048&&AC(v.alternate,v);break;default:Am(h,v);}c=c.sibling;}}var Nm=8192;function ed(s,c,h){if(s.subtreeFlags&Nm)for(s=s.child;s!==null;)qP(s,c,h),s=s.sibling;}function qP(s,c,h){switch(s.tag){case 26:ed(s,c,h),s.flags&Nm&&s.memoizedState!==null&&MX(h,Ji,s.memoizedState,s.memoizedProps);break;case 5:ed(s,c,h);break;case 3:case 4:var v=Ji;Ji=Dv(s.stateNode.containerInfo),ed(s,c,h),Ji=v;break;case 22:s.memoizedState===null&&(v=s.alternate,v!==null&&v.memoizedState!==null?(v=Nm,Nm=16777216,ed(s,c,h),Nm=v):ed(s,c,h));break;default:ed(s,c,h);}}function KP(s){var c=s.alternate;if(c!==null&&(s=c.child,s!==null)){c.child=null;do c=s.sibling,s.sibling=null,s=c;while(s!==null)}}function Pm(s){var c=s.deletions;if((s.flags&16)!==0){if(c!==null)for(var h=0;h<c.length;h++){var v=c[h];Dr=v,XP(v,s);}KP(s);}if(s.subtreeFlags&10256)for(s=s.child;s!==null;)YP(s),s=s.sibling;}function YP(s){switch(s.tag){case 0:case 11:case 15:Pm(s),s.flags&2048&&ol(9,s,s.return);break;case 3:Pm(s);break;case 12:Pm(s);break;case 22:var c=s.stateNode;s.memoizedState!==null&&c._visibility&2&&(s.return===null||s.return.tag!==13)?(c._visibility&=-3,Cv(s)):Pm(s);break;default:Pm(s);}}function Cv(s){var c=s.deletions;if((s.flags&16)!==0){if(c!==null)for(var h=0;h<c.length;h++){var v=c[h];Dr=v,XP(v,s);}KP(s);}for(s=s.child;s!==null;){switch(c=s,c.tag){case 0:case 11:case 15:ol(8,c,c.return),Cv(c);break;case 22:h=c.stateNode,h._visibility&2&&(h._visibility&=-3,Cv(c));break;default:Cv(c);}s=s.sibling;}}function XP(s,c){for(;Dr!==null;){var h=Dr;switch(h.tag){case 0:case 11:case 15:ol(8,h,c);break;case 23:case 22:if(h.memoizedState!==null&&h.memoizedState.cachePool!==null){var v=h.memoizedState.cachePool.pool;v!=null&&v.refCount++;}break;case 24:hm(h.memoizedState.cache);}if(v=h.child,v!==null)v.return=h,Dr=v;else e:for(h=s;Dr!==null;){v=Dr;var E=v.sibling,A=v.return;if(FP(v),v===h){Dr=null;break e}if(E!==null){E.return=A,Dr=E;break e}Dr=A;}}}var HY={getCacheForType:function(s){var c=Gr(gr),h=c.data.get(s);return h===void 0&&(h=s(),c.data.set(s,h)),h},cacheSignal:function(){return Gr(gr).controller.signal}},VY=typeof WeakMap=="function"?WeakMap:Map,Cn=0,kn=null,tn=null,on=0,Nn=0,ii=null,il=false,td=false,NC=false,hs=0,ir=0,al=0,$c=0,PC=0,ai=0,nd=0,Im=null,Ho=null,IC=false,xv=0,QP=0,wv=1/0,$v=null,sl=null,Mr=0,ll=null,rd=null,ps=0,OC=0,DC=null,ZP=null,Om=0,_C=null;function si(){return (Cn&2)!==0&&on!==0?on&-on:z.T!==null?HC():ht()}function JP(){if(ai===0)if((on&536870912)===0||hn){var s=Tt;Tt<<=1,(Tt&3932160)===0&&(Tt=262144),ai=s;}else ai=536870912;return s=ri.current,s!==null&&(s.flags|=32),ai}function Vo(s,c,h){(s===kn&&(Nn===2||Nn===9)||s.cancelPendingCommit!==null)&&(od(s,0),cl(s,on,ai,false)),Se(s,h),((Cn&2)===0||s!==kn)&&(s===kn&&((Cn&2)===0&&($c|=h),ir===4&&cl(s,on,ai,false)),Pa(s));}function e4(s,c,h){if((Cn&6)!==0)throw Error(r(327));var v=!h&&(c&127)===0&&(c&s.expiredLanes)===0||Fe(s,c),E=v?WY(s,c):LC(s,c,true),A=v;do{if(E===0){td&&!v&&cl(s,c,0,false);break}else {if(h=s.current.alternate,A&&!jY(h)){E=LC(s,c,false),A=false;continue}if(E===2){if(A=c,s.errorRecoveryDisabledLanes&A)var k=0;else k=s.pendingLanes&-536870913,k=k!==0?k:k&536870912?536870912:0;if(k!==0){c=k;e:{var Z=s;E=Im;var le=Z.current.memoizedState.isDehydrated;if(le&&(od(Z,k).flags|=256),k=LC(Z,k,false),k!==2){if(NC&&!le){Z.errorRecoveryDisabledLanes|=A,$c|=A,E=4;break e}A=Ho,Ho=E,A!==null&&(Ho===null?Ho=A:Ho.push.apply(Ho,A));}E=k;}if(A=false,E!==2)continue}}if(E===1){od(s,0),cl(s,c,0,true);break}e:{switch(v=s,A=E,A){case 0:case 1:throw Error(r(345));case 4:if((c&4194048)!==c)break;case 6:cl(v,c,ai,!il);break e;case 2:Ho=null;break;case 3:case 5:break;default:throw Error(r(329))}if((c&62914560)===c&&(E=xv+300-Pe(),10<E)){if(cl(v,c,ai,!il),gt(v,0,true)!==0)break e;ps=c,v.timeoutHandle=P4(t4.bind(null,v,h,Ho,$v,IC,c,ai,$c,nd,il,A,"Throttled",-0,0),E);break e}t4(v,h,Ho,$v,IC,c,ai,$c,nd,il,A,null,-0,0);}}break}while(true);Pa(s);}function t4(s,c,h,v,E,A,k,Z,le,Ee,Le,Ve,Te,Ie){if(s.timeoutHandle=-1,Ve=c.subtreeFlags,Ve&8192||(Ve&16785408)===16785408){Ve={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:true,waitingForViewTransition:false,unsuspend:es},qP(c,A,Ve);var pt=(A&62914560)===A?xv-Pe():(A&4194048)===A?QP-Pe():0;if(pt=RX(Ve,pt),pt!==null){ps=A,s.cancelPendingCommit=pt(c4.bind(null,s,c,A,h,v,E,k,Z,le,Le,Ve,null,Te,Ie)),cl(s,A,k,!Ee);return}}c4(s,c,A,h,v,E,k,Z,le);}function jY(s){for(var c=s;;){var h=c.tag;if((h===0||h===11||h===15)&&c.flags&16384&&(h=c.updateQueue,h!==null&&(h=h.stores,h!==null)))for(var v=0;v<h.length;v++){var E=h[v],A=E.getSnapshot;E=E.value;try{if(!ti(A(),E))return !1}catch{return false}}if(h=c.child,c.subtreeFlags&16384&&h!==null)h.return=c,c=h;else {if(c===s)break;for(;c.sibling===null;){if(c.return===null||c.return===s)return true;c=c.return;}c.sibling.return=c.return,c=c.sibling;}}return true}function cl(s,c,h,v){c&=~PC,c&=~$c,s.suspendedLanes|=c,s.pingedLanes&=~c,v&&(s.warmLanes|=c),v=s.expirationTimes;for(var E=c;0<E;){var A=31-lt(E),k=1<<A;v[A]=-1,E&=~k;}h!==0&&De(s,h,c);}function Ev(){return (Cn&6)===0?(Dm(0),false):true}function BC(){if(tn!==null){if(Nn===0)var s=tn.return;else s=tn,os=pc=null,ZS(s),Ku=null,gm=0,s=tn;for(;s!==null;)IP(s.alternate,s),s=s.return;tn=null;}}function od(s,c){var h=s.timeoutHandle;h!==-1&&(s.timeoutHandle=-1,cX(h)),h=s.cancelPendingCommit,h!==null&&(s.cancelPendingCommit=null,h()),ps=0,BC(),kn=s,tn=h=ns(s.current,null),on=c,Nn=0,ii=null,il=false,td=Fe(s,c),NC=false,nd=ai=PC=$c=al=ir=0,Ho=Im=null,IC=false,(c&8)!==0&&(c|=c&32);var v=s.entangledLanes;if(v!==0)for(s=s.entanglements,v&=c;0<v;){var E=31-lt(v),A=1<<E;c|=s[E],v&=~A;}return hs=c,Gg(),h}function n4(s,c){Gt=null,z.H=$m,c===qu||c===ev?(c=bN(),Nn=3):c===FS?(c=bN(),Nn=4):Nn=c===hC?8:c!==null&&typeof c=="object"&&typeof c.then=="function"?6:1,ii=c,tn===null&&(ir=1,hv(s,Ai(c,s.current)));}function r4(){var s=ri.current;return s===null?true:(on&4194048)===on?Oi===null:(on&62914560)===on||(on&536870912)!==0?s===Oi:false}function o4(){var s=z.H;return z.H=$m,s===null?$m:s}function i4(){var s=z.A;return z.A=HY,s}function Mv(){ir=4,il||(on&4194048)!==on&&ri.current!==null||(td=true),(al&134217727)===0&&($c&134217727)===0||kn===null||cl(kn,on,ai,false);}function LC(s,c,h){var v=Cn;Cn|=2;var E=o4(),A=i4();(kn!==s||on!==c)&&($v=null,od(s,c)),c=false;var k=ir;e:do try{if(Nn!==0&&tn!==null){var Z=tn,le=ii;switch(Nn){case 8:BC(),k=6;break e;case 3:case 2:case 9:case 6:ri.current===null&&(c=!0);var Ee=Nn;if(Nn=0,ii=null,id(s,Z,le,Ee),h&&td){k=0;break e}break;default:Ee=Nn,Nn=0,ii=null,id(s,Z,le,Ee);}}UY(),k=ir;break}catch(Le){n4(s,Le);}while(true);return c&&s.shellSuspendCounter++,os=pc=null,Cn=v,z.H=E,z.A=A,tn===null&&(kn=null,on=0,Gg()),k}function UY(){for(;tn!==null;)a4(tn);}function WY(s,c){var h=Cn;Cn|=2;var v=o4(),E=i4();kn!==s||on!==c?($v=null,wv=Pe()+500,od(s,c)):td=Fe(s,c);e:do try{if(Nn!==0&&tn!==null){c=tn;var A=ii;t:switch(Nn){case 1:Nn=0,ii=null,id(s,c,A,1);break;case 2:case 9:if(gN(A)){Nn=0,ii=null,s4(c);break}c=function(){Nn!==2&&Nn!==9||kn!==s||(Nn=7),Pa(s);},A.then(c,c);break e;case 3:Nn=7;break e;case 4:Nn=5;break e;case 7:gN(A)?(Nn=0,ii=null,s4(c)):(Nn=0,ii=null,id(s,c,A,7));break;case 5:var k=null;switch(tn.tag){case 26:k=tn.memoizedState;case 5:case 27:var Z=tn;if(k?G4(k):Z.stateNode.complete){Nn=0,ii=null;var le=Z.sibling;if(le!==null)tn=le;else {var Ee=Z.return;Ee!==null?(tn=Ee,Rv(Ee)):tn=null;}break t}}Nn=0,ii=null,id(s,c,A,5);break;case 6:Nn=0,ii=null,id(s,c,A,6);break;case 8:BC(),ir=6;break e;default:throw Error(r(462))}}GY();break}catch(Le){n4(s,Le);}while(true);return os=pc=null,z.H=v,z.A=E,Cn=h,tn!==null?0:(kn=null,on=0,Gg(),ir)}function GY(){for(;tn!==null&&!ue();)a4(tn);}function a4(s){var c=NP(s.alternate,s,hs);s.memoizedProps=s.pendingProps,c===null?Rv(s):tn=c;}function s4(s){var c=s,h=c.alternate;switch(c.tag){case 15:case 0:c=$P(h,c,c.pendingProps,c.type,void 0,on);break;case 11:c=$P(h,c,c.pendingProps,c.type.render,c.ref,on);break;case 5:ZS(c);default:IP(h,c),c=tn=iN(c,hs),c=NP(h,c,hs);}s.memoizedProps=s.pendingProps,c===null?Rv(s):tn=c;}function id(s,c,h,v){os=pc=null,ZS(c),Ku=null,gm=0;var E=c.return;try{if(DY(s,E,c,h,on)){ir=1,hv(s,Ai(h,s.current)),tn=null;return}}catch(A){if(E!==null)throw tn=E,A;ir=1,hv(s,Ai(h,s.current)),tn=null;return}c.flags&32768?(hn||v===1?s=true:td||(on&536870912)!==0?s=false:(il=s=true,(v===2||v===9||v===3||v===6)&&(v=ri.current,v!==null&&v.tag===13&&(v.flags|=16384))),l4(c,s)):Rv(c);}function Rv(s){var c=s;do{if((c.flags&32768)!==0){l4(c,il);return}s=c.return;var h=LY(c.alternate,c,hs);if(h!==null){tn=h;return}if(c=c.sibling,c!==null){tn=c;return}tn=c=s;}while(c!==null);ir===0&&(ir=5);}function l4(s,c){do{var h=zY(s.alternate,s);if(h!==null){h.flags&=32767,tn=h;return}if(h=s.return,h!==null&&(h.flags|=32768,h.subtreeFlags=0,h.deletions=null),!c&&(s=s.sibling,s!==null)){tn=s;return}tn=s=h;}while(s!==null);ir=6,tn=null;}function c4(s,c,h,v,E,A,k,Z,le){s.cancelPendingCommit=null;do Tv();while(Mr!==0);if((Cn&6)!==0)throw Error(r(327));if(c!==null){if(c===s.current)throw Error(r(177));if(A=c.lanes|c.childLanes,A|=ES,he(s,h,A,k,Z,le),s===kn&&(tn=kn=null,on=0),rd=c,ll=s,ps=h,OC=A,DC=E,ZP=v,(c.subtreeFlags&10256)!==0||(c.flags&10256)!==0?(s.callbackNode=null,s.callbackPriority=0,XY(et,function(){return h4(),null})):(s.callbackNode=null,s.callbackPriority=0),v=(c.flags&13878)!==0,(c.subtreeFlags&13878)!==0||v){v=z.T,z.T=null,E=j.p,j.p=2,k=Cn,Cn|=4;try{kY(s,c,h);}finally{Cn=k,j.p=E,z.T=v;}}Mr=1,u4(),d4(),f4();}}function u4(){if(Mr===1){Mr=0;var s=ll,c=rd,h=(c.flags&13878)!==0;if((c.subtreeFlags&13878)!==0||h){h=z.T,z.T=null;var v=j.p;j.p=2;var E=Cn;Cn|=4;try{UP(c,s);var A=YC,k=X6(s.containerInfo),Z=A.focusedElem,le=A.selectionRange;if(k!==Z&&Z&&Z.ownerDocument&&Y6(Z.ownerDocument.documentElement,Z)){if(le!==null&&SS(Z)){var Ee=le.start,Le=le.end;if(Le===void 0&&(Le=Ee),"selectionStart"in Z)Z.selectionStart=Ee,Z.selectionEnd=Math.min(Le,Z.value.length);else {var Ve=Z.ownerDocument||document,Te=Ve&&Ve.defaultView||window;if(Te.getSelection){var Ie=Te.getSelection(),pt=Z.textContent.length,Nt=Math.min(le.start,pt),Dn=le.end===void 0?Nt:Math.min(le.end,pt);!Ie.extend&&Nt>Dn&&(k=Dn,Dn=Nt,Nt=k);var ve=K6(Z,Nt),me=K6(Z,Dn);if(ve&&me&&(Ie.rangeCount!==1||Ie.anchorNode!==ve.node||Ie.anchorOffset!==ve.offset||Ie.focusNode!==me.node||Ie.focusOffset!==me.offset)){var we=Ve.createRange();we.setStart(ve.node,ve.offset),Ie.removeAllRanges(),Nt>Dn?(Ie.addRange(we),Ie.extend(me.node,me.offset)):(we.setEnd(me.node,me.offset),Ie.addRange(we));}}}}for(Ve=[],Ie=Z;Ie=Ie.parentNode;)Ie.nodeType===1&&Ve.push({element:Ie,left:Ie.scrollLeft,top:Ie.scrollTop});for(typeof Z.focus=="function"&&Z.focus(),Z=0;Z<Ve.length;Z++){var He=Ve[Z];He.element.scrollLeft=He.left,He.element.scrollTop=He.top;}}Fv=!!KC,YC=KC=null;}finally{Cn=E,j.p=v,z.T=h;}}s.current=c,Mr=2;}}function d4(){if(Mr===2){Mr=0;var s=ll,c=rd,h=(c.flags&8772)!==0;if((c.subtreeFlags&8772)!==0||h){h=z.T,z.T=null;var v=j.p;j.p=2;var E=Cn;Cn|=4;try{kP(s,c.alternate,c);}finally{Cn=E,j.p=v,z.T=h;}}Mr=3;}}function f4(){if(Mr===4||Mr===3){Mr=0,ge();var s=ll,c=rd,h=ps,v=ZP;(c.subtreeFlags&10256)!==0||(c.flags&10256)!==0?Mr=5:(Mr=0,rd=ll=null,m4(s,s.pendingLanes));var E=s.pendingLanes;if(E===0&&(sl=null),ot(h),c=c.stateNode,Be&&typeof Be.onCommitFiberRoot=="function")try{Be.onCommitFiberRoot(Ze,c,void 0,(c.current.flags&128)===128);}catch{}if(v!==null){c=z.T,E=j.p,j.p=2,z.T=null;try{for(var A=s.onRecoverableError,k=0;k<v.length;k++){var Z=v[k];A(Z.value,{componentStack:Z.stack});}}finally{z.T=c,j.p=E;}}(ps&3)!==0&&Tv(),Pa(s),E=s.pendingLanes,(h&261930)!==0&&(E&42)!==0?s===_C?Om++:(Om=0,_C=s):Om=0,Dm(0);}}function m4(s,c){(s.pooledCacheLanes&=c)===0&&(c=s.pooledCache,c!=null&&(s.pooledCache=null,hm(c)));}function Tv(){return u4(),d4(),f4(),h4()}function h4(){if(Mr!==5)return false;var s=ll,c=OC;OC=0;var h=ot(ps),v=z.T,E=j.p;try{j.p=32>h?32:h,z.T=null,h=DC,DC=null;var A=ll,k=ps;if(Mr=0,rd=ll=null,ps=0,(Cn&6)!==0)throw Error(r(331));var Z=Cn;if(Cn|=4,YP(A.current),GP(A,A.current,k,h),Cn=Z,Dm(0,!1),Be&&typeof Be.onPostCommitFiberRoot=="function")try{Be.onPostCommitFiberRoot(Ze,A);}catch{}return !0}finally{j.p=E,z.T=v,m4(s,c);}}function p4(s,c,h){c=Ai(h,c),c=mC(s.stateNode,c,2),s=tl(s,c,2),s!==null&&(Se(s,2),Pa(s));}function Pn(s,c,h){if(s.tag===3)p4(s,s,h);else for(;c!==null;){if(c.tag===3){p4(c,s,h);break}else if(c.tag===1){var v=c.stateNode;if(typeof c.type.getDerivedStateFromError=="function"||typeof v.componentDidCatch=="function"&&(sl===null||!sl.has(v))){s=Ai(h,s),h=gP(2),v=tl(c,h,2),v!==null&&(vP(h,v,c,s),Se(v,2),Pa(v));break}}c=c.return;}}function zC(s,c,h){var v=s.pingCache;if(v===null){v=s.pingCache=new VY;var E=new Set;v.set(c,E);}else E=v.get(c),E===void 0&&(E=new Set,v.set(c,E));E.has(h)||(NC=true,E.add(h),s=qY.bind(null,s,c,h),c.then(s,s));}function qY(s,c,h){var v=s.pingCache;v!==null&&v.delete(c),s.pingedLanes|=s.suspendedLanes&h,s.warmLanes&=~h,kn===s&&(on&h)===h&&(ir===4||ir===3&&(on&62914560)===on&&300>Pe()-xv?(Cn&2)===0&&od(s,0):PC|=h,nd===on&&(nd=0)),Pa(s);}function g4(s,c){c===0&&(c=ye()),s=fc(s,c),s!==null&&(Se(s,c),Pa(s));}function KY(s){var c=s.memoizedState,h=0;c!==null&&(h=c.retryLane),g4(s,h);}function YY(s,c){var h=0;switch(s.tag){case 31:case 13:var v=s.stateNode,E=s.memoizedState;E!==null&&(h=E.retryLane);break;case 19:v=s.stateNode;break;case 22:v=s.stateNode._retryCache;break;default:throw Error(r(314))}v!==null&&v.delete(c),g4(s,h);}function XY(s,c){return Xe(s,c)}var Av=null,ad=null,kC=false,Nv=false,FC=false,ul=0;function Pa(s){s!==ad&&s.next===null&&(ad===null?Av=ad=s:ad=ad.next=s),Nv=true,kC||(kC=true,ZY());}function Dm(s,c){if(!FC&&Nv){FC=true;do for(var h=false,v=Av;v!==null;){if(s!==0){var E=v.pendingLanes;if(E===0)var A=0;else {var k=v.suspendedLanes,Z=v.pingedLanes;A=(1<<31-lt(42|s)+1)-1,A&=E&~(k&~Z),A=A&201326741?A&201326741|1:A?A|2:0;}A!==0&&(h=true,S4(v,A));}else A=on,A=gt(v,v===kn?A:0,v.cancelPendingCommit!==null||v.timeoutHandle!==-1),(A&3)===0||Fe(v,A)||(h=true,S4(v,A));v=v.next;}while(h);FC=false;}}function QY(){v4();}function v4(){Nv=kC=false;var s=0;ul!==0&&lX()&&(s=ul);for(var c=Pe(),h=null,v=Av;v!==null;){var E=v.next,A=b4(v,c);A===0?(v.next=null,h===null?Av=E:h.next=E,E===null&&(ad=h)):(h=v,(s!==0||(A&3)!==0)&&(Nv=true)),v=E;}Mr!==0&&Mr!==5||Dm(s),ul!==0&&(ul=0);}function b4(s,c){for(var h=s.suspendedLanes,v=s.pingedLanes,E=s.expirationTimes,A=s.pendingLanes&-62914561;0<A;){var k=31-lt(A),Z=1<<k,le=E[k];le===-1?((Z&h)===0||(Z&v)!==0)&&(E[k]=Qe(Z,c)):le<=c&&(s.expiredLanes|=Z),A&=~Z;}if(c=kn,h=on,h=gt(s,s===c?h:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),v=s.callbackNode,h===0||s===c&&(Nn===2||Nn===9)||s.cancelPendingCommit!==null)return v!==null&&v!==null&&Ne(v),s.callbackNode=null,s.callbackPriority=0;if((h&3)===0||Fe(s,h)){if(c=h&-h,c===s.callbackPriority)return c;switch(v!==null&&Ne(v),ot(h)){case 2:case 8:h=Ue;break;case 32:h=et;break;case 268435456:h=Ke;break;default:h=et;}return v=y4.bind(null,s),h=Xe(h,v),s.callbackPriority=c,s.callbackNode=h,c}return v!==null&&v!==null&&Ne(v),s.callbackPriority=2,s.callbackNode=null,2}function y4(s,c){if(Mr!==0&&Mr!==5)return s.callbackNode=null,s.callbackPriority=0,null;var h=s.callbackNode;if(Tv()&&s.callbackNode!==h)return null;var v=on;return v=gt(s,s===kn?v:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),v===0?null:(e4(s,v,c),b4(s,Pe()),s.callbackNode!=null&&s.callbackNode===h?y4.bind(null,s):null)}function S4(s,c){if(Tv())return null;e4(s,c,true);}function ZY(){uX(function(){(Cn&6)!==0?Xe(qe,QY):v4();});}function HC(){if(ul===0){var s=Wu;s===0&&(s=xt,xt<<=1,(xt&261888)===0&&(xt=256)),ul=s;}return ul}function C4(s){return s==null||typeof s=="symbol"||typeof s=="boolean"?null:typeof s=="function"?s:zg(""+s)}function x4(s,c){var h=c.ownerDocument.createElement("input");return h.name=c.name,h.value=c.value,s.id&&h.setAttribute("form",s.id),c.parentNode.insertBefore(h,c),s=new FormData(s),h.parentNode.removeChild(h),s}function JY(s,c,h,v,E){if(c==="submit"&&h&&h.stateNode===E){var A=C4((E[Sn]||null).action),k=v.submitter;k&&(c=(c=k[Sn]||null)?C4(c.formAction):k.getAttribute("formAction"),c!==null&&(A=c,k=null));var Z=new Vg("action","action",null,v,E);s.push({event:Z,listeners:[{instance:null,listener:function(){if(v.defaultPrevented){if(ul!==0){var le=k?x4(E,k):new FormData(E);sC(h,{pending:true,data:le,method:E.method,action:A},null,le);}}else typeof A=="function"&&(Z.preventDefault(),le=k?x4(E,k):new FormData(E),sC(h,{pending:true,data:le,method:E.method,action:A},A,le));},currentTarget:E}]});}}for(var VC=0;VC<$S.length;VC++){var jC=$S[VC],eX=jC.toLowerCase(),tX=jC[0].toUpperCase()+jC.slice(1);Zi(eX,"on"+tX);}Zi(J6,"onAnimationEnd"),Zi(eN,"onAnimationIteration"),Zi(tN,"onAnimationStart"),Zi("dblclick","onDoubleClick"),Zi("focusin","onFocus"),Zi("focusout","onBlur"),Zi(vY,"onTransitionRun"),Zi(bY,"onTransitionStart"),Zi(yY,"onTransitionCancel"),Zi(nN,"onTransitionEnd"),_o("onMouseEnter",["mouseout","mouseover"]),_o("onMouseLeave",["mouseout","mouseover"]),_o("onPointerEnter",["pointerout","pointerover"]),_o("onPointerLeave",["pointerout","pointerover"]),Wn("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Wn("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Wn("onBeforeInput",["compositionend","keypress","textInput","paste"]),Wn("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Wn("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Wn("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var _m="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),nX=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(_m));function w4(s,c){c=(c&4)!==0;for(var h=0;h<s.length;h++){var v=s[h],E=v.event;v=v.listeners;e:{var A=void 0;if(c)for(var k=v.length-1;0<=k;k--){var Z=v[k],le=Z.instance,Ee=Z.currentTarget;if(Z=Z.listener,le!==A&&E.isPropagationStopped())break e;A=Z,E.currentTarget=Ee;try{A(E);}catch(Le){Wg(Le);}E.currentTarget=null,A=le;}else for(k=0;k<v.length;k++){if(Z=v[k],le=Z.instance,Ee=Z.currentTarget,Z=Z.listener,le!==A&&E.isPropagationStopped())break e;A=Z,E.currentTarget=Ee;try{A(E);}catch(Le){Wg(Le);}E.currentTarget=null,A=le;}}}}function nn(s,c){var h=c[Re];h===void 0&&(h=c[Re]=new Set);var v=s+"__bubble";h.has(v)||($4(c,s,2,false),h.add(v));}function UC(s,c,h){var v=0;c&&(v|=4),$4(h,s,v,c);}var Pv="_reactListening"+Math.random().toString(36).slice(2);function WC(s){if(!s[Pv]){s[Pv]=true,Mi.forEach(function(h){h!=="selectionchange"&&(nX.has(h)||UC(h,false,s),UC(h,true,s));});var c=s.nodeType===9?s:s.ownerDocument;c===null||c[Pv]||(c[Pv]=true,UC("selectionchange",false,c));}}function $4(s,c,h,v){switch(J4(c)){case 2:var E=NX;break;case 8:E=PX;break;default:E=ax;}h=E.bind(null,c,h,s),E=void 0,!dS||c!=="touchstart"&&c!=="touchmove"&&c!=="wheel"||(E=true),v?E!==void 0?s.addEventListener(c,h,{capture:true,passive:E}):s.addEventListener(c,h,true):E!==void 0?s.addEventListener(c,h,{passive:E}):s.addEventListener(c,h,false);}function GC(s,c,h,v,E){var A=v;if((c&1)===0&&(c&2)===0&&v!==null)e:for(;;){if(v===null)return;var k=v.tag;if(k===3||k===4){var Z=v.stateNode.containerInfo;if(Z===E)break;if(k===4)for(k=v.return;k!==null;){var le=k.tag;if((le===3||le===4)&&k.stateNode.containerInfo===E)return;k=k.return;}for(;Z!==null;){if(k=Zt(Z),k===null)return;if(le=k.tag,le===5||le===6||le===26||le===27){v=A=k;continue e}Z=Z.parentNode;}}v=v.return;}A6(function(){var Ee=A,Le=cS(h),Ve=[];e:{var Te=rN.get(s);if(Te!==void 0){var Ie=Vg,pt=s;switch(s){case "keypress":if(Fg(h)===0)break e;case "keydown":case "keyup":Ie=YK;break;case "focusin":pt="focus",Ie=pS;break;case "focusout":pt="blur",Ie=pS;break;case "beforeblur":case "afterblur":Ie=pS;break;case "click":if(h.button===2)break e;case "auxclick":case "dblclick":case "mousedown":case "mousemove":case "mouseup":case "mouseout":case "mouseover":case "contextmenu":Ie=I6;break;case "drag":case "dragend":case "dragenter":case "dragexit":case "dragleave":case "dragover":case "dragstart":case "drop":Ie=LK;break;case "touchcancel":case "touchend":case "touchmove":case "touchstart":Ie=ZK;break;case J6:case eN:case tN:Ie=FK;break;case nN:Ie=eY;break;case "scroll":case "scrollend":Ie=_K;break;case "wheel":Ie=nY;break;case "copy":case "cut":case "paste":Ie=VK;break;case "gotpointercapture":case "lostpointercapture":case "pointercancel":case "pointerdown":case "pointermove":case "pointerout":case "pointerover":case "pointerup":Ie=D6;break;case "toggle":case "beforetoggle":Ie=oY;}var Nt=(c&4)!==0,Dn=!Nt&&(s==="scroll"||s==="scrollend"),ve=Nt?Te!==null?Te+"Capture":null:Te;Nt=[];for(var me=Ee,we;me!==null;){var He=me;if(we=He.stateNode,He=He.tag,He!==5&&He!==26&&He!==27||we===null||ve===null||(He=rm(me,ve),He!=null&&Nt.push(Bm(me,He,we))),Dn)break;me=me.return;}0<Nt.length&&(Te=new Ie(Te,pt,null,h,Le),Ve.push({event:Te,listeners:Nt}));}}if((c&7)===0){e:{if(Te=s==="mouseover"||s==="pointerover",Ie=s==="mouseout"||s==="pointerout",Te&&h!==lS&&(pt=h.relatedTarget||h.fromElement)&&(Zt(pt)||pt[Hn]))break e;if((Ie||Te)&&(Te=Le.window===Le?Le:(Te=Le.ownerDocument)?Te.defaultView||Te.parentWindow:window,Ie?(pt=h.relatedTarget||h.toElement,Ie=Ee,pt=pt?Zt(pt):null,pt!==null&&(Dn=i(pt),Nt=pt.tag,pt!==Dn||Nt!==5&&Nt!==27&&Nt!==6)&&(pt=null)):(Ie=null,pt=Ee),Ie!==pt)){if(Nt=I6,He="onMouseLeave",ve="onMouseEnter",me="mouse",(s==="pointerout"||s==="pointerover")&&(Nt=D6,He="onPointerLeave",ve="onPointerEnter",me="pointer"),Dn=Ie==null?Te:Un(Ie),we=pt==null?Te:Un(pt),Te=new Nt(He,me+"leave",Ie,h,Le),Te.target=Dn,Te.relatedTarget=we,He=null,Zt(Le)===Ee&&(Nt=new Nt(ve,me+"enter",pt,h,Le),Nt.target=we,Nt.relatedTarget=Dn,He=Nt),Dn=He,Ie&&pt)t:{for(Nt=rX,ve=Ie,me=pt,we=0,He=ve;He;He=Nt(He))we++;He=0;for(var Et=me;Et;Et=Nt(Et))He++;for(;0<we-He;)ve=Nt(ve),we--;for(;0<He-we;)me=Nt(me),He--;for(;we--;){if(ve===me||me!==null&&ve===me.alternate){Nt=ve;break t}ve=Nt(ve),me=Nt(me);}Nt=null;}else Nt=null;Ie!==null&&E4(Ve,Te,Ie,Nt,!1),pt!==null&&Dn!==null&&E4(Ve,Dn,pt,Nt,!0);}}e:{if(Te=Ee?Un(Ee):window,Ie=Te.nodeName&&Te.nodeName.toLowerCase(),Ie==="select"||Ie==="input"&&Te.type==="file")var bn=V6;else if(F6(Te))if(j6)bn=hY;else {bn=fY;var St=dY;}else Ie=Te.nodeName,!Ie||Ie.toLowerCase()!=="input"||Te.type!=="checkbox"&&Te.type!=="radio"?Ee&&sS(Ee.elementType)&&(bn=V6):bn=mY;if(bn&&(bn=bn(s,Ee))){H6(Ve,bn,h,Le);break e}St&&St(s,Te,Ee),s==="focusout"&&Ee&&Te.type==="number"&&Ee.memoizedProps.value!=null&&Iu(Te,"number",Te.value);}switch(St=Ee?Un(Ee):window,s){case "focusin":(F6(St)||St.contentEditable==="true")&&(Lu=St,CS=Ee,dm=null);break;case "focusout":dm=CS=Lu=null;break;case "mousedown":xS=!0;break;case "contextmenu":case "mouseup":case "dragend":xS=!1,Q6(Ve,h,Le);break;case "selectionchange":if(gY)break;case "keydown":case "keyup":Q6(Ve,h,Le);}var Yt;if(vS)e:{switch(s){case "compositionstart":var an="onCompositionStart";break e;case "compositionend":an="onCompositionEnd";break e;case "compositionupdate":an="onCompositionUpdate";break e}an=void 0;}else Bu?z6(s,h)&&(an="onCompositionEnd"):s==="keydown"&&h.keyCode===229&&(an="onCompositionStart");an&&(_6&&h.locale!=="ko"&&(Bu||an!=="onCompositionStart"?an==="onCompositionEnd"&&Bu&&(Yt=N6()):(Ks=Le,fS="value"in Ks?Ks.value:Ks.textContent,Bu=!0)),St=Iv(Ee,an),0<St.length&&(an=new O6(an,s,null,h,Le),Ve.push({event:an,listeners:St}),Yt?an.data=Yt:(Yt=k6(h),Yt!==null&&(an.data=Yt)))),(Yt=aY?sY(s,h):lY(s,h))&&(an=Iv(Ee,"onBeforeInput"),0<an.length&&(St=new O6("onBeforeInput","beforeinput",null,h,Le),Ve.push({event:St,listeners:an}),St.data=Yt)),JY(Ve,s,Ee,h,Le);}w4(Ve,c);});}function Bm(s,c,h){return {instance:s,listener:c,currentTarget:h}}function Iv(s,c){for(var h=c+"Capture",v=[];s!==null;){var E=s,A=E.stateNode;if(E=E.tag,E!==5&&E!==26&&E!==27||A===null||(E=rm(s,h),E!=null&&v.unshift(Bm(s,E,A)),E=rm(s,c),E!=null&&v.push(Bm(s,E,A))),s.tag===3)return v;s=s.return;}return []}function rX(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5&&s.tag!==27);return s||null}function E4(s,c,h,v,E){for(var A=c._reactName,k=[];h!==null&&h!==v;){var Z=h,le=Z.alternate,Ee=Z.stateNode;if(Z=Z.tag,le!==null&&le===v)break;Z!==5&&Z!==26&&Z!==27||Ee===null||(le=Ee,E?(Ee=rm(h,A),Ee!=null&&k.unshift(Bm(h,Ee,le))):E||(Ee=rm(h,A),Ee!=null&&k.push(Bm(h,Ee,le)))),h=h.return;}k.length!==0&&s.push({event:c,listeners:k});}var oX=/\r\n?/g,iX=/\u0000|\uFFFD/g;function M4(s){return (typeof s=="string"?s:""+s).replace(oX,`
`).replace(iX,"")}function R4(s,c){return c=M4(c),M4(s)===c}function On(s,c,h,v,E,A){switch(h){case "children":typeof v=="string"?c==="body"||c==="textarea"&&v===""||Ou(s,v):(typeof v=="number"||typeof v=="bigint")&&c!=="body"&&Ou(s,""+v);break;case "className":Ri(s,"class",v);break;case "tabIndex":Ri(s,"tabindex",v);break;case "dir":case "role":case "viewBox":case "width":case "height":Ri(s,h,v);break;case "style":R6(s,v,A);break;case "data":if(c!=="object"){Ri(s,"data",v);break}case "src":case "href":if(v===""&&(c!=="a"||h!=="href")){s.removeAttribute(h);break}if(v==null||typeof v=="function"||typeof v=="symbol"||typeof v=="boolean"){s.removeAttribute(h);break}v=zg(""+v),s.setAttribute(h,v);break;case "action":case "formAction":if(typeof v=="function"){s.setAttribute(h,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof A=="function"&&(h==="formAction"?(c!=="input"&&On(s,c,"name",E.name,E,null),On(s,c,"formEncType",E.formEncType,E,null),On(s,c,"formMethod",E.formMethod,E,null),On(s,c,"formTarget",E.formTarget,E,null)):(On(s,c,"encType",E.encType,E,null),On(s,c,"method",E.method,E,null),On(s,c,"target",E.target,E,null)));if(v==null||typeof v=="symbol"||typeof v=="boolean"){s.removeAttribute(h);break}v=zg(""+v),s.setAttribute(h,v);break;case "onClick":v!=null&&(s.onclick=es);break;case "onScroll":v!=null&&nn("scroll",s);break;case "onScrollEnd":v!=null&&nn("scrollend",s);break;case "dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error(r(61));if(h=v.__html,h!=null){if(E.children!=null)throw Error(r(60));s.innerHTML=h;}}break;case "multiple":s.multiple=v&&typeof v!="function"&&typeof v!="symbol";break;case "muted":s.muted=v&&typeof v!="function"&&typeof v!="symbol";break;case "suppressContentEditableWarning":case "suppressHydrationWarning":case "defaultValue":case "defaultChecked":case "innerHTML":case "ref":break;case "autoFocus":break;case "xlinkHref":if(v==null||typeof v=="function"||typeof v=="boolean"||typeof v=="symbol"){s.removeAttribute("xlink:href");break}h=zg(""+v),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",h);break;case "contentEditable":case "spellCheck":case "draggable":case "value":case "autoReverse":case "externalResourcesRequired":case "focusable":case "preserveAlpha":v!=null&&typeof v!="function"&&typeof v!="symbol"?s.setAttribute(h,""+v):s.removeAttribute(h);break;case "inert":case "allowFullScreen":case "async":case "autoPlay":case "controls":case "default":case "defer":case "disabled":case "disablePictureInPicture":case "disableRemotePlayback":case "formNoValidate":case "hidden":case "loop":case "noModule":case "noValidate":case "open":case "playsInline":case "readOnly":case "required":case "reversed":case "scoped":case "seamless":case "itemScope":v&&typeof v!="function"&&typeof v!="symbol"?s.setAttribute(h,""):s.removeAttribute(h);break;case "capture":case "download":v===true?s.setAttribute(h,""):v!==false&&v!=null&&typeof v!="function"&&typeof v!="symbol"?s.setAttribute(h,v):s.removeAttribute(h);break;case "cols":case "rows":case "size":case "span":v!=null&&typeof v!="function"&&typeof v!="symbol"&&!isNaN(v)&&1<=v?s.setAttribute(h,v):s.removeAttribute(h);break;case "rowSpan":case "start":v==null||typeof v=="function"||typeof v=="symbol"||isNaN(v)?s.removeAttribute(h):s.setAttribute(h,v);break;case "popover":nn("beforetoggle",s),nn("toggle",s),Ra(s,"popover",v);break;case "xlinkActuate":Bo(s,"http://www.w3.org/1999/xlink","xlink:actuate",v);break;case "xlinkArcrole":Bo(s,"http://www.w3.org/1999/xlink","xlink:arcrole",v);break;case "xlinkRole":Bo(s,"http://www.w3.org/1999/xlink","xlink:role",v);break;case "xlinkShow":Bo(s,"http://www.w3.org/1999/xlink","xlink:show",v);break;case "xlinkTitle":Bo(s,"http://www.w3.org/1999/xlink","xlink:title",v);break;case "xlinkType":Bo(s,"http://www.w3.org/1999/xlink","xlink:type",v);break;case "xmlBase":Bo(s,"http://www.w3.org/XML/1998/namespace","xml:base",v);break;case "xmlLang":Bo(s,"http://www.w3.org/XML/1998/namespace","xml:lang",v);break;case "xmlSpace":Bo(s,"http://www.w3.org/XML/1998/namespace","xml:space",v);break;case "is":Ra(s,"is",v);break;case "innerText":case "textContent":break;default:(!(2<h.length)||h[0]!=="o"&&h[0]!=="O"||h[1]!=="n"&&h[1]!=="N")&&(h=OK.get(h)||h,Ra(s,h,v));}}function qC(s,c,h,v,E,A){switch(h){case "style":R6(s,v,A);break;case "dangerouslySetInnerHTML":if(v!=null){if(typeof v!="object"||!("__html"in v))throw Error(r(61));if(h=v.__html,h!=null){if(E.children!=null)throw Error(r(60));s.innerHTML=h;}}break;case "children":typeof v=="string"?Ou(s,v):(typeof v=="number"||typeof v=="bigint")&&Ou(s,""+v);break;case "onScroll":v!=null&&nn("scroll",s);break;case "onScrollEnd":v!=null&&nn("scrollend",s);break;case "onClick":v!=null&&(s.onclick=es);break;case "suppressContentEditableWarning":case "suppressHydrationWarning":case "innerHTML":case "ref":break;case "innerText":case "textContent":break;default:if(!Za.hasOwnProperty(h))e:{if(h[0]==="o"&&h[1]==="n"&&(E=h.endsWith("Capture"),c=h.slice(2,E?h.length-7:void 0),A=s[Sn]||null,A=A!=null?A[h]:null,typeof A=="function"&&s.removeEventListener(c,A,E),typeof v=="function")){typeof A!="function"&&A!==null&&(h in s?s[h]=null:s.hasAttribute(h)&&s.removeAttribute(h)),s.addEventListener(c,v,E);break e}h in s?s[h]=v:v===true?s.setAttribute(h,""):Ra(s,h,v);}}}function Kr(s,c,h){switch(c){case "div":case "span":case "svg":case "path":case "a":case "g":case "p":case "li":break;case "img":nn("error",s),nn("load",s);var v=false,E=false,A;for(A in h)if(h.hasOwnProperty(A)){var k=h[A];if(k!=null)switch(A){case "src":v=true;break;case "srcSet":E=true;break;case "children":case "dangerouslySetInnerHTML":throw Error(r(137,c));default:On(s,c,A,k,h,null);}}E&&On(s,c,"srcSet",h.srcSet,h,null),v&&On(s,c,"src",h.src,h,null);return;case "input":nn("invalid",s);var Z=A=k=E=null,le=null,Ee=null;for(v in h)if(h.hasOwnProperty(v)){var Le=h[v];if(Le!=null)switch(v){case "name":E=Le;break;case "type":k=Le;break;case "checked":le=Le;break;case "defaultChecked":Ee=Le;break;case "value":A=Le;break;case "defaultValue":Z=Le;break;case "children":case "dangerouslySetInnerHTML":if(Le!=null)throw Error(r(137,c));break;default:On(s,c,v,Le,h,null);}}Bg(s,A,Z,le,Ee,k,E,false);return;case "select":nn("invalid",s),v=k=A=null;for(E in h)if(h.hasOwnProperty(E)&&(Z=h[E],Z!=null))switch(E){case "value":A=Z;break;case "defaultValue":k=Z;break;case "multiple":v=Z;default:On(s,c,E,Z,h,null);}c=A,h=k,s.multiple=!!v,c!=null?Ja(s,!!v,c,false):h!=null&&Ja(s,!!v,h,true);return;case "textarea":nn("invalid",s),A=E=v=null;for(k in h)if(h.hasOwnProperty(k)&&(Z=h[k],Z!=null))switch(k){case "value":v=Z;break;case "defaultValue":E=Z;break;case "children":A=Z;break;case "dangerouslySetInnerHTML":if(Z!=null)throw Error(r(91));break;default:On(s,c,k,Z,h,null);}E6(s,v,E,A);return;case "option":for(le in h)h.hasOwnProperty(le)&&(v=h[le],v!=null)&&(le==="selected"?s.selected=v&&typeof v!="function"&&typeof v!="symbol":On(s,c,le,v,h,null));return;case "dialog":nn("beforetoggle",s),nn("toggle",s),nn("cancel",s),nn("close",s);break;case "iframe":case "object":nn("load",s);break;case "video":case "audio":for(v=0;v<_m.length;v++)nn(_m[v],s);break;case "image":nn("error",s),nn("load",s);break;case "details":nn("toggle",s);break;case "embed":case "source":case "link":nn("error",s),nn("load",s);case "area":case "base":case "br":case "col":case "hr":case "keygen":case "meta":case "param":case "track":case "wbr":case "menuitem":for(Ee in h)if(h.hasOwnProperty(Ee)&&(v=h[Ee],v!=null))switch(Ee){case "children":case "dangerouslySetInnerHTML":throw Error(r(137,c));default:On(s,c,Ee,v,h,null);}return;default:if(sS(c)){for(Le in h)h.hasOwnProperty(Le)&&(v=h[Le],v!==void 0&&qC(s,c,Le,v,h,void 0));return}}for(Z in h)h.hasOwnProperty(Z)&&(v=h[Z],v!=null&&On(s,c,Z,v,h,null));}function aX(s,c,h,v){switch(c){case "div":case "span":case "svg":case "path":case "a":case "g":case "p":case "li":break;case "input":var E=null,A=null,k=null,Z=null,le=null,Ee=null,Le=null;for(Ie in h){var Ve=h[Ie];if(h.hasOwnProperty(Ie)&&Ve!=null)switch(Ie){case "checked":break;case "value":break;case "defaultValue":le=Ve;default:v.hasOwnProperty(Ie)||On(s,c,Ie,null,v,Ve);}}for(var Te in v){var Ie=v[Te];if(Ve=h[Te],v.hasOwnProperty(Te)&&(Ie!=null||Ve!=null))switch(Te){case "type":A=Ie;break;case "name":E=Ie;break;case "checked":Ee=Ie;break;case "defaultChecked":Le=Ie;break;case "value":k=Ie;break;case "defaultValue":Z=Ie;break;case "children":case "dangerouslySetInnerHTML":if(Ie!=null)throw Error(r(137,c));break;default:Ie!==Ve&&On(s,c,Te,Ie,v,Ve);}}qs(s,k,Z,le,Ee,Le,A,E);return;case "select":Ie=k=Z=Te=null;for(A in h)if(le=h[A],h.hasOwnProperty(A)&&le!=null)switch(A){case "value":break;case "multiple":Ie=le;default:v.hasOwnProperty(A)||On(s,c,A,null,v,le);}for(E in v)if(A=v[E],le=h[E],v.hasOwnProperty(E)&&(A!=null||le!=null))switch(E){case "value":Te=A;break;case "defaultValue":Z=A;break;case "multiple":k=A;default:A!==le&&On(s,c,E,A,v,le);}c=Z,h=k,v=Ie,Te!=null?Ja(s,!!h,Te,false):!!v!=!!h&&(c!=null?Ja(s,!!h,c,true):Ja(s,!!h,h?[]:"",false));return;case "textarea":Ie=Te=null;for(Z in h)if(E=h[Z],h.hasOwnProperty(Z)&&E!=null&&!v.hasOwnProperty(Z))switch(Z){case "value":break;case "children":break;default:On(s,c,Z,null,v,E);}for(k in v)if(E=v[k],A=h[k],v.hasOwnProperty(k)&&(E!=null||A!=null))switch(k){case "value":Te=E;break;case "defaultValue":Ie=E;break;case "children":break;case "dangerouslySetInnerHTML":if(E!=null)throw Error(r(91));break;default:E!==A&&On(s,c,k,E,v,A);}Lg(s,Te,Ie);return;case "option":for(var pt in h)Te=h[pt],h.hasOwnProperty(pt)&&Te!=null&&!v.hasOwnProperty(pt)&&(pt==="selected"?s.selected=false:On(s,c,pt,null,v,Te));for(le in v)Te=v[le],Ie=h[le],v.hasOwnProperty(le)&&Te!==Ie&&(Te!=null||Ie!=null)&&(le==="selected"?s.selected=Te&&typeof Te!="function"&&typeof Te!="symbol":On(s,c,le,Te,v,Ie));return;case "img":case "link":case "area":case "base":case "br":case "col":case "embed":case "hr":case "keygen":case "meta":case "param":case "source":case "track":case "wbr":case "menuitem":for(var Nt in h)Te=h[Nt],h.hasOwnProperty(Nt)&&Te!=null&&!v.hasOwnProperty(Nt)&&On(s,c,Nt,null,v,Te);for(Ee in v)if(Te=v[Ee],Ie=h[Ee],v.hasOwnProperty(Ee)&&Te!==Ie&&(Te!=null||Ie!=null))switch(Ee){case "children":case "dangerouslySetInnerHTML":if(Te!=null)throw Error(r(137,c));break;default:On(s,c,Ee,Te,v,Ie);}return;default:if(sS(c)){for(var Dn in h)Te=h[Dn],h.hasOwnProperty(Dn)&&Te!==void 0&&!v.hasOwnProperty(Dn)&&qC(s,c,Dn,void 0,v,Te);for(Le in v)Te=v[Le],Ie=h[Le],!v.hasOwnProperty(Le)||Te===Ie||Te===void 0&&Ie===void 0||qC(s,c,Le,Te,v,Ie);return}}for(var ve in h)Te=h[ve],h.hasOwnProperty(ve)&&Te!=null&&!v.hasOwnProperty(ve)&&On(s,c,ve,null,v,Te);for(Ve in v)Te=v[Ve],Ie=h[Ve],!v.hasOwnProperty(Ve)||Te===Ie||Te==null&&Ie==null||On(s,c,Ve,Te,v,Ie);}function T4(s){switch(s){case "css":case "script":case "font":case "img":case "image":case "input":case "link":return true;default:return false}}function sX(){if(typeof performance.getEntriesByType=="function"){for(var s=0,c=0,h=performance.getEntriesByType("resource"),v=0;v<h.length;v++){var E=h[v],A=E.transferSize,k=E.initiatorType,Z=E.duration;if(A&&Z&&T4(k)){for(k=0,Z=E.responseEnd,v+=1;v<h.length;v++){var le=h[v],Ee=le.startTime;if(Ee>Z)break;var Le=le.transferSize,Ve=le.initiatorType;Le&&T4(Ve)&&(le=le.responseEnd,k+=Le*(le<Z?1:(Z-Ee)/(le-Ee)));}if(--v,c+=8*(A+k)/(E.duration/1e3),s++,10<s)break}}if(0<s)return c/s/1e6}return navigator.connection&&(s=navigator.connection.downlink,typeof s=="number")?s:5}var KC=null,YC=null;function Ov(s){return s.nodeType===9?s:s.ownerDocument}function A4(s){switch(s){case "http://www.w3.org/2000/svg":return 1;case "http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function N4(s,c){if(s===0)switch(c){case "svg":return 1;case "math":return 2;default:return 0}return s===1&&c==="foreignObject"?0:s}function XC(s,c){return s==="textarea"||s==="noscript"||typeof c.children=="string"||typeof c.children=="number"||typeof c.children=="bigint"||typeof c.dangerouslySetInnerHTML=="object"&&c.dangerouslySetInnerHTML!==null&&c.dangerouslySetInnerHTML.__html!=null}var QC=null;function lX(){var s=window.event;return s&&s.type==="popstate"?s===QC?false:(QC=s,true):(QC=null,false)}var P4=typeof setTimeout=="function"?setTimeout:void 0,cX=typeof clearTimeout=="function"?clearTimeout:void 0,I4=typeof Promise=="function"?Promise:void 0,uX=typeof queueMicrotask=="function"?queueMicrotask:typeof I4<"u"?function(s){return I4.resolve(null).then(s).catch(dX)}:P4;function dX(s){setTimeout(function(){throw s});}function dl(s){return s==="head"}function O4(s,c){var h=c,v=0;do{var E=h.nextSibling;if(s.removeChild(h),E&&E.nodeType===8)if(h=E.data,h==="/$"||h==="/&"){if(v===0){s.removeChild(E),ud(c);return}v--;}else if(h==="$"||h==="$?"||h==="$~"||h==="$!"||h==="&")v++;else if(h==="html")Lm(s.ownerDocument.documentElement);else if(h==="head"){h=s.ownerDocument.head,Lm(h);for(var A=h.firstChild;A;){var k=A.nextSibling,Z=A.nodeName;A[At]||Z==="SCRIPT"||Z==="STYLE"||Z==="LINK"&&A.rel.toLowerCase()==="stylesheet"||h.removeChild(A),A=k;}}else h==="body"&&Lm(s.ownerDocument.body);h=E;}while(h);ud(c);}function D4(s,c){var h=s;s=0;do{var v=h.nextSibling;if(h.nodeType===1?c?(h._stashedDisplay=h.style.display,h.style.display="none"):(h.style.display=h._stashedDisplay||"",h.getAttribute("style")===""&&h.removeAttribute("style")):h.nodeType===3&&(c?(h._stashedText=h.nodeValue,h.nodeValue=""):h.nodeValue=h._stashedText||""),v&&v.nodeType===8)if(h=v.data,h==="/$"){if(s===0)break;s--;}else h!=="$"&&h!=="$?"&&h!=="$~"&&h!=="$!"||s++;h=v;}while(h)}function ZC(s){var c=s.firstChild;for(c&&c.nodeType===10&&(c=c.nextSibling);c;){var h=c;switch(c=c.nextSibling,h.nodeName){case "HTML":case "HEAD":case "BODY":ZC(h),en(h);continue;case "SCRIPT":case "STYLE":continue;case "LINK":if(h.rel.toLowerCase()==="stylesheet")continue}s.removeChild(h);}}function fX(s,c,h,v){for(;s.nodeType===1;){var E=h;if(s.nodeName.toLowerCase()!==c.toLowerCase()){if(!v&&(s.nodeName!=="INPUT"||s.type!=="hidden"))break}else if(v){if(!s[At])switch(c){case "meta":if(!s.hasAttribute("itemprop"))break;return s;case "link":if(A=s.getAttribute("rel"),A==="stylesheet"&&s.hasAttribute("data-precedence"))break;if(A!==E.rel||s.getAttribute("href")!==(E.href==null||E.href===""?null:E.href)||s.getAttribute("crossorigin")!==(E.crossOrigin==null?null:E.crossOrigin)||s.getAttribute("title")!==(E.title==null?null:E.title))break;return s;case "style":if(s.hasAttribute("data-precedence"))break;return s;case "script":if(A=s.getAttribute("src"),(A!==(E.src==null?null:E.src)||s.getAttribute("type")!==(E.type==null?null:E.type)||s.getAttribute("crossorigin")!==(E.crossOrigin==null?null:E.crossOrigin))&&A&&s.hasAttribute("async")&&!s.hasAttribute("itemprop"))break;return s;default:return s}}else if(c==="input"&&s.type==="hidden"){var A=E.name==null?null:""+E.name;if(E.type==="hidden"&&s.getAttribute("name")===A)return s}else return s;if(s=Di(s.nextSibling),s===null)break}return null}function mX(s,c,h){if(c==="")return null;for(;s.nodeType!==3;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!h||(s=Di(s.nextSibling),s===null))return null;return s}function _4(s,c){for(;s.nodeType!==8;)if((s.nodeType!==1||s.nodeName!=="INPUT"||s.type!=="hidden")&&!c||(s=Di(s.nextSibling),s===null))return null;return s}function JC(s){return s.data==="$?"||s.data==="$~"}function ex(s){return s.data==="$!"||s.data==="$?"&&s.ownerDocument.readyState!=="loading"}function hX(s,c){var h=s.ownerDocument;if(s.data==="$~")s._reactRetry=c;else if(s.data!=="$?"||h.readyState!=="loading")c();else {var v=function(){c(),h.removeEventListener("DOMContentLoaded",v);};h.addEventListener("DOMContentLoaded",v),s._reactRetry=v;}}function Di(s){for(;s!=null;s=s.nextSibling){var c=s.nodeType;if(c===1||c===3)break;if(c===8){if(c=s.data,c==="$"||c==="$!"||c==="$?"||c==="$~"||c==="&"||c==="F!"||c==="F")break;if(c==="/$"||c==="/&")return null}}return s}var tx=null;function B4(s){s=s.nextSibling;for(var c=0;s;){if(s.nodeType===8){var h=s.data;if(h==="/$"||h==="/&"){if(c===0)return Di(s.nextSibling);c--;}else h!=="$"&&h!=="$!"&&h!=="$?"&&h!=="$~"&&h!=="&"||c++;}s=s.nextSibling;}return null}function L4(s){s=s.previousSibling;for(var c=0;s;){if(s.nodeType===8){var h=s.data;if(h==="$"||h==="$!"||h==="$?"||h==="$~"||h==="&"){if(c===0)return s;c--;}else h!=="/$"&&h!=="/&"||c++;}s=s.previousSibling;}return null}function z4(s,c,h){switch(c=Ov(h),s){case "html":if(s=c.documentElement,!s)throw Error(r(452));return s;case "head":if(s=c.head,!s)throw Error(r(453));return s;case "body":if(s=c.body,!s)throw Error(r(454));return s;default:throw Error(r(451))}}function Lm(s){for(var c=s.attributes;c.length;)s.removeAttributeNode(c[0]);en(s);}var _i=new Map,k4=new Set;function Dv(s){return typeof s.getRootNode=="function"?s.getRootNode():s.nodeType===9?s:s.ownerDocument}var gs=j.d;j.d={f:pX,r:gX,D:vX,C:bX,L:yX,m:SX,X:xX,S:CX,M:wX};function pX(){var s=gs.f(),c=Ev();return s||c}function gX(s){var c=mn(s);c!==null&&c.tag===5&&c.type==="form"?nP(c):gs.r(s);}var sd=typeof document>"u"?null:document;function F4(s,c,h){var v=sd;if(v&&typeof c=="string"&&c){var E=Ht(c);E='link[rel="'+s+'"][href="'+E+'"]',typeof h=="string"&&(E+='[crossorigin="'+h+'"]'),k4.has(E)||(k4.add(E),s={rel:s,crossOrigin:h,href:c},v.querySelector(E)===null&&(c=v.createElement("link"),Kr(c,"link",s),vn(c),v.head.appendChild(c)));}}function vX(s){gs.D(s),F4("dns-prefetch",s,null);}function bX(s,c){gs.C(s,c),F4("preconnect",s,c);}function yX(s,c,h){gs.L(s,c,h);var v=sd;if(v&&s&&c){var E='link[rel="preload"][as="'+Ht(c)+'"]';c==="image"&&h&&h.imageSrcSet?(E+='[imagesrcset="'+Ht(h.imageSrcSet)+'"]',typeof h.imageSizes=="string"&&(E+='[imagesizes="'+Ht(h.imageSizes)+'"]')):E+='[href="'+Ht(s)+'"]';var A=E;switch(c){case "style":A=ld(s);break;case "script":A=cd(s);}_i.has(A)||(s=p({rel:"preload",href:c==="image"&&h&&h.imageSrcSet?void 0:s,as:c},h),_i.set(A,s),v.querySelector(E)!==null||c==="style"&&v.querySelector(zm(A))||c==="script"&&v.querySelector(km(A))||(c=v.createElement("link"),Kr(c,"link",s),vn(c),v.head.appendChild(c)));}}function SX(s,c){gs.m(s,c);var h=sd;if(h&&s){var v=c&&typeof c.as=="string"?c.as:"script",E='link[rel="modulepreload"][as="'+Ht(v)+'"][href="'+Ht(s)+'"]',A=E;switch(v){case "audioworklet":case "paintworklet":case "serviceworker":case "sharedworker":case "worker":case "script":A=cd(s);}if(!_i.has(A)&&(s=p({rel:"modulepreload",href:s},c),_i.set(A,s),h.querySelector(E)===null)){switch(v){case "audioworklet":case "paintworklet":case "serviceworker":case "sharedworker":case "worker":case "script":if(h.querySelector(km(A)))return}v=h.createElement("link"),Kr(v,"link",s),vn(v),h.head.appendChild(v);}}}function CX(s,c,h){gs.S(s,c,h);var v=sd;if(v&&s){var E=rr(v).hoistableStyles,A=ld(s);c=c||"default";var k=E.get(A);if(!k){var Z={loading:0,preload:null};if(k=v.querySelector(zm(A)))Z.loading=5;else {s=p({rel:"stylesheet",href:s,"data-precedence":c},h),(h=_i.get(A))&&nx(s,h);var le=k=v.createElement("link");vn(le),Kr(le,"link",s),le._p=new Promise(function(Ee,Le){le.onload=Ee,le.onerror=Le;}),le.addEventListener("load",function(){Z.loading|=1;}),le.addEventListener("error",function(){Z.loading|=2;}),Z.loading|=4,_v(k,c,v);}k={type:"stylesheet",instance:k,count:1,state:Z},E.set(A,k);}}}function xX(s,c){gs.X(s,c);var h=sd;if(h&&s){var v=rr(h).hoistableScripts,E=cd(s),A=v.get(E);A||(A=h.querySelector(km(E)),A||(s=p({src:s,async:true},c),(c=_i.get(E))&&rx(s,c),A=h.createElement("script"),vn(A),Kr(A,"link",s),h.head.appendChild(A)),A={type:"script",instance:A,count:1,state:null},v.set(E,A));}}function wX(s,c){gs.M(s,c);var h=sd;if(h&&s){var v=rr(h).hoistableScripts,E=cd(s),A=v.get(E);A||(A=h.querySelector(km(E)),A||(s=p({src:s,async:true,type:"module"},c),(c=_i.get(E))&&rx(s,c),A=h.createElement("script"),vn(A),Kr(A,"link",s),h.head.appendChild(A)),A={type:"script",instance:A,count:1,state:null},v.set(E,A));}}function H4(s,c,h,v){var E=(E=te.current)?Dv(E):null;if(!E)throw Error(r(446));switch(s){case "meta":case "title":return null;case "style":return typeof h.precedence=="string"&&typeof h.href=="string"?(c=ld(h.href),h=rr(E).hoistableStyles,v=h.get(c),v||(v={type:"style",instance:null,count:0,state:null},h.set(c,v)),v):{type:"void",instance:null,count:0,state:null};case "link":if(h.rel==="stylesheet"&&typeof h.href=="string"&&typeof h.precedence=="string"){s=ld(h.href);var A=rr(E).hoistableStyles,k=A.get(s);if(k||(E=E.ownerDocument||E,k={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},A.set(s,k),(A=E.querySelector(zm(s)))&&!A._p&&(k.instance=A,k.state.loading=5),_i.has(s)||(h={rel:"preload",as:"style",href:h.href,crossOrigin:h.crossOrigin,integrity:h.integrity,media:h.media,hrefLang:h.hrefLang,referrerPolicy:h.referrerPolicy},_i.set(s,h),A||$X(E,s,h,k.state))),c&&v===null)throw Error(r(528,""));return k}if(c&&v!==null)throw Error(r(529,""));return null;case "script":return c=h.async,h=h.src,typeof h=="string"&&c&&typeof c!="function"&&typeof c!="symbol"?(c=cd(h),h=rr(E).hoistableScripts,v=h.get(c),v||(v={type:"script",instance:null,count:0,state:null},h.set(c,v)),v):{type:"void",instance:null,count:0,state:null};default:throw Error(r(444,s))}}function ld(s){return 'href="'+Ht(s)+'"'}function zm(s){return 'link[rel="stylesheet"]['+s+"]"}function V4(s){return p({},s,{"data-precedence":s.precedence,precedence:null})}function $X(s,c,h,v){s.querySelector('link[rel="preload"][as="style"]['+c+"]")?v.loading=1:(c=s.createElement("link"),v.preload=c,c.addEventListener("load",function(){return v.loading|=1}),c.addEventListener("error",function(){return v.loading|=2}),Kr(c,"link",h),vn(c),s.head.appendChild(c));}function cd(s){return '[src="'+Ht(s)+'"]'}function km(s){return "script[async]"+s}function j4(s,c,h){if(c.count++,c.instance===null)switch(c.type){case "style":var v=s.querySelector('style[data-href~="'+Ht(h.href)+'"]');if(v)return c.instance=v,vn(v),v;var E=p({},h,{"data-href":h.href,"data-precedence":h.precedence,href:null,precedence:null});return v=(s.ownerDocument||s).createElement("style"),vn(v),Kr(v,"style",E),_v(v,h.precedence,s),c.instance=v;case "stylesheet":E=ld(h.href);var A=s.querySelector(zm(E));if(A)return c.state.loading|=4,c.instance=A,vn(A),A;v=V4(h),(E=_i.get(E))&&nx(v,E),A=(s.ownerDocument||s).createElement("link"),vn(A);var k=A;return k._p=new Promise(function(Z,le){k.onload=Z,k.onerror=le;}),Kr(A,"link",v),c.state.loading|=4,_v(A,h.precedence,s),c.instance=A;case "script":return A=cd(h.src),(E=s.querySelector(km(A)))?(c.instance=E,vn(E),E):(v=h,(E=_i.get(A))&&(v=p({},h),rx(v,E)),s=s.ownerDocument||s,E=s.createElement("script"),vn(E),Kr(E,"link",v),s.head.appendChild(E),c.instance=E);case "void":return null;default:throw Error(r(443,c.type))}else c.type==="stylesheet"&&(c.state.loading&4)===0&&(v=c.instance,c.state.loading|=4,_v(v,h.precedence,s));return c.instance}function _v(s,c,h){for(var v=h.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),E=v.length?v[v.length-1]:null,A=E,k=0;k<v.length;k++){var Z=v[k];if(Z.dataset.precedence===c)A=Z;else if(A!==E)break}A?A.parentNode.insertBefore(s,A.nextSibling):(c=h.nodeType===9?h.head:h,c.insertBefore(s,c.firstChild));}function nx(s,c){s.crossOrigin==null&&(s.crossOrigin=c.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=c.referrerPolicy),s.title==null&&(s.title=c.title);}function rx(s,c){s.crossOrigin==null&&(s.crossOrigin=c.crossOrigin),s.referrerPolicy==null&&(s.referrerPolicy=c.referrerPolicy),s.integrity==null&&(s.integrity=c.integrity);}var Bv=null;function U4(s,c,h){if(Bv===null){var v=new Map,E=Bv=new Map;E.set(h,v);}else E=Bv,v=E.get(h),v||(v=new Map,E.set(h,v));if(v.has(s))return v;for(v.set(s,null),h=h.getElementsByTagName(s),E=0;E<h.length;E++){var A=h[E];if(!(A[At]||A[Ot]||s==="link"&&A.getAttribute("rel")==="stylesheet")&&A.namespaceURI!=="http://www.w3.org/2000/svg"){var k=A.getAttribute(c)||"";k=s+k;var Z=v.get(k);Z?Z.push(A):v.set(k,[A]);}}return v}function W4(s,c,h){s=s.ownerDocument||s,s.head.insertBefore(h,c==="title"?s.querySelector("head > title"):null);}function EX(s,c,h){if(h===1||c.itemProp!=null)return false;switch(s){case "meta":case "title":return true;case "style":if(typeof c.precedence!="string"||typeof c.href!="string"||c.href==="")break;return true;case "link":if(typeof c.rel!="string"||typeof c.href!="string"||c.href===""||c.onLoad||c.onError)break;return c.rel==="stylesheet"?(s=c.disabled,typeof c.precedence=="string"&&s==null):true;case "script":if(c.async&&typeof c.async!="function"&&typeof c.async!="symbol"&&!c.onLoad&&!c.onError&&c.src&&typeof c.src=="string")return true}return false}function G4(s){return !(s.type==="stylesheet"&&(s.state.loading&3)===0)}function MX(s,c,h,v){if(h.type==="stylesheet"&&(typeof v.media!="string"||matchMedia(v.media).matches!==false)&&(h.state.loading&4)===0){if(h.instance===null){var E=ld(v.href),A=c.querySelector(zm(E));if(A){c=A._p,c!==null&&typeof c=="object"&&typeof c.then=="function"&&(s.count++,s=Lv.bind(s),c.then(s,s)),h.state.loading|=4,h.instance=A,vn(A);return}A=c.ownerDocument||c,v=V4(v),(E=_i.get(E))&&nx(v,E),A=A.createElement("link"),vn(A);var k=A;k._p=new Promise(function(Z,le){k.onload=Z,k.onerror=le;}),Kr(A,"link",v),h.instance=A;}s.stylesheets===null&&(s.stylesheets=new Map),s.stylesheets.set(h,c),(c=h.state.preload)&&(h.state.loading&3)===0&&(s.count++,h=Lv.bind(s),c.addEventListener("load",h),c.addEventListener("error",h));}}var ox=0;function RX(s,c){return s.stylesheets&&s.count===0&&kv(s,s.stylesheets),0<s.count||0<s.imgCount?function(h){var v=setTimeout(function(){if(s.stylesheets&&kv(s,s.stylesheets),s.unsuspend){var A=s.unsuspend;s.unsuspend=null,A();}},6e4+c);0<s.imgBytes&&ox===0&&(ox=62500*sX());var E=setTimeout(function(){if(s.waitingForImages=false,s.count===0&&(s.stylesheets&&kv(s,s.stylesheets),s.unsuspend)){var A=s.unsuspend;s.unsuspend=null,A();}},(s.imgBytes>ox?50:800)+c);return s.unsuspend=h,function(){s.unsuspend=null,clearTimeout(v),clearTimeout(E);}}:null}function Lv(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)kv(this,this.stylesheets);else if(this.unsuspend){var s=this.unsuspend;this.unsuspend=null,s();}}}var zv=null;function kv(s,c){s.stylesheets=null,s.unsuspend!==null&&(s.count++,zv=new Map,c.forEach(TX,s),zv=null,Lv.call(s));}function TX(s,c){if(!(c.state.loading&4)){var h=zv.get(s);if(h)var v=h.get(null);else {h=new Map,zv.set(s,h);for(var E=s.querySelectorAll("link[data-precedence],style[data-precedence]"),A=0;A<E.length;A++){var k=E[A];(k.nodeName==="LINK"||k.getAttribute("media")!=="not all")&&(h.set(k.dataset.precedence,k),v=k);}v&&h.set(null,v);}E=c.instance,k=E.getAttribute("data-precedence"),A=h.get(k)||v,A===v&&h.set(null,E),h.set(k,E),this.count++,v=Lv.bind(this),E.addEventListener("load",v),E.addEventListener("error",v),A?A.parentNode.insertBefore(E,A.nextSibling):(s=s.nodeType===9?s.head:s,s.insertBefore(E,s.firstChild)),c.state.loading|=4;}}var Fm={$$typeof:M,Provider:null,Consumer:null,_currentValue:W,_currentValue2:W,_threadCount:0};function AX(s,c,h,v,E,A,k,Z,le){this.tag=1,this.containerInfo=s,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=be(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=be(0),this.hiddenUpdates=be(null),this.identifierPrefix=v,this.onUncaughtError=E,this.onCaughtError=A,this.onRecoverableError=k,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=le,this.incompleteTransitions=new Map;}function q4(s,c,h,v,E,A,k,Z,le,Ee,Le,Ve){return s=new AX(s,c,h,k,le,Ee,Le,Ve,Z),c=1,A===true&&(c|=24),A=ni(3,null,null,c),s.current=A,A.stateNode=s,c=LS(),c.refCount++,s.pooledCache=c,c.refCount++,A.memoizedState={element:v,isDehydrated:h,cache:c},HS(A),s}function K4(s){return s?(s=Fu,s):Fu}function Y4(s,c,h,v,E,A){E=K4(E),v.context===null?v.context=E:v.pendingContext=E,v=el(c),v.payload={element:h},A=A===void 0?null:A,A!==null&&(v.callback=A),h=tl(s,v,c),h!==null&&(Vo(h,s,c),bm(h,s,c));}function X4(s,c){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var h=s.retryLane;s.retryLane=h!==0&&h<c?h:c;}}function ix(s,c){X4(s,c),(s=s.alternate)&&X4(s,c);}function Q4(s){if(s.tag===13||s.tag===31){var c=fc(s,67108864);c!==null&&Vo(c,s,67108864),ix(s,67108864);}}function Z4(s){if(s.tag===13||s.tag===31){var c=si();c=Ge(c);var h=fc(s,c);h!==null&&Vo(h,s,c),ix(s,c);}}var Fv=true;function NX(s,c,h,v){var E=z.T;z.T=null;var A=j.p;try{j.p=2,ax(s,c,h,v);}finally{j.p=A,z.T=E;}}function PX(s,c,h,v){var E=z.T;z.T=null;var A=j.p;try{j.p=8,ax(s,c,h,v);}finally{j.p=A,z.T=E;}}function ax(s,c,h,v){if(Fv){var E=sx(v);if(E===null)GC(s,c,v,Hv,h),e5(s,v);else if(OX(E,s,c,h,v))v.stopPropagation();else if(e5(s,v),c&4&&-1<IX.indexOf(s)){for(;E!==null;){var A=mn(E);if(A!==null)switch(A.tag){case 3:if(A=A.stateNode,A.current.memoizedState.isDehydrated){var k=dt(A.pendingLanes);if(k!==0){var Z=A;for(Z.pendingLanes|=2,Z.entangledLanes|=2;k;){var le=1<<31-lt(k);Z.entanglements[1]|=le,k&=~le;}Pa(A),(Cn&6)===0&&(wv=Pe()+500,Dm(0));}}break;case 31:case 13:Z=fc(A,2),Z!==null&&Vo(Z,A,2),Ev(),ix(A,2);}if(A=sx(v),A===null&&GC(s,c,v,Hv,h),A===E)break;E=A;}E!==null&&v.stopPropagation();}else GC(s,c,v,null,h);}}function sx(s){return s=cS(s),lx(s)}var Hv=null;function lx(s){if(Hv=null,s=Zt(s),s!==null){var c=i(s);if(c===null)s=null;else {var h=c.tag;if(h===13){if(s=a(c),s!==null)return s;s=null;}else if(h===31){if(s=l(c),s!==null)return s;s=null;}else if(h===3){if(c.stateNode.current.memoizedState.isDehydrated)return c.tag===3?c.stateNode.containerInfo:null;s=null;}else c!==s&&(s=null);}}return Hv=s,null}function J4(s){switch(s){case "beforetoggle":case "cancel":case "click":case "close":case "contextmenu":case "copy":case "cut":case "auxclick":case "dblclick":case "dragend":case "dragstart":case "drop":case "focusin":case "focusout":case "input":case "invalid":case "keydown":case "keypress":case "keyup":case "mousedown":case "mouseup":case "paste":case "pause":case "play":case "pointercancel":case "pointerdown":case "pointerup":case "ratechange":case "reset":case "resize":case "seeked":case "submit":case "toggle":case "touchcancel":case "touchend":case "touchstart":case "volumechange":case "change":case "selectionchange":case "textInput":case "compositionstart":case "compositionend":case "compositionupdate":case "beforeblur":case "afterblur":case "beforeinput":case "blur":case "fullscreenchange":case "focus":case "hashchange":case "popstate":case "select":case "selectstart":return 2;case "drag":case "dragenter":case "dragexit":case "dragleave":case "dragover":case "mousemove":case "mouseout":case "mouseover":case "pointermove":case "pointerout":case "pointerover":case "scroll":case "touchmove":case "wheel":case "mouseenter":case "mouseleave":case "pointerenter":case "pointerleave":return 8;case "message":switch(je()){case qe:return 2;case Ue:return 8;case et:case rt:return 32;case Ke:return 268435456;default:return 32}default:return 32}}var cx=false,fl=null,ml=null,hl=null,Hm=new Map,Vm=new Map,pl=[],IX="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function e5(s,c){switch(s){case "focusin":case "focusout":fl=null;break;case "dragenter":case "dragleave":ml=null;break;case "mouseover":case "mouseout":hl=null;break;case "pointerover":case "pointerout":Hm.delete(c.pointerId);break;case "gotpointercapture":case "lostpointercapture":Vm.delete(c.pointerId);}}function jm(s,c,h,v,E,A){return s===null||s.nativeEvent!==A?(s={blockedOn:c,domEventName:h,eventSystemFlags:v,nativeEvent:A,targetContainers:[E]},c!==null&&(c=mn(c),c!==null&&Q4(c)),s):(s.eventSystemFlags|=v,c=s.targetContainers,E!==null&&c.indexOf(E)===-1&&c.push(E),s)}function OX(s,c,h,v,E){switch(c){case "focusin":return fl=jm(fl,s,c,h,v,E),true;case "dragenter":return ml=jm(ml,s,c,h,v,E),true;case "mouseover":return hl=jm(hl,s,c,h,v,E),true;case "pointerover":var A=E.pointerId;return Hm.set(A,jm(Hm.get(A)||null,s,c,h,v,E)),true;case "gotpointercapture":return A=E.pointerId,Vm.set(A,jm(Vm.get(A)||null,s,c,h,v,E)),true}return false}function t5(s){var c=Zt(s.target);if(c!==null){var h=i(c);if(h!==null){if(c=h.tag,c===13){if(c=a(h),c!==null){s.blockedOn=c,$t(s.priority,function(){Z4(h);});return}}else if(c===31){if(c=l(h),c!==null){s.blockedOn=c,$t(s.priority,function(){Z4(h);});return}}else if(c===3&&h.stateNode.current.memoizedState.isDehydrated){s.blockedOn=h.tag===3?h.stateNode.containerInfo:null;return}}}s.blockedOn=null;}function Vv(s){if(s.blockedOn!==null)return false;for(var c=s.targetContainers;0<c.length;){var h=sx(s.nativeEvent);if(h===null){h=s.nativeEvent;var v=new h.constructor(h.type,h);lS=v,h.target.dispatchEvent(v),lS=null;}else return c=mn(h),c!==null&&Q4(c),s.blockedOn=h,false;c.shift();}return true}function n5(s,c,h){Vv(s)&&h.delete(c);}function DX(){cx=false,fl!==null&&Vv(fl)&&(fl=null),ml!==null&&Vv(ml)&&(ml=null),hl!==null&&Vv(hl)&&(hl=null),Hm.forEach(n5),Vm.forEach(n5);}function jv(s,c){s.blockedOn===c&&(s.blockedOn=null,cx||(cx=true,e.unstable_scheduleCallback(e.unstable_NormalPriority,DX)));}var Uv=null;function r5(s){Uv!==s&&(Uv=s,e.unstable_scheduleCallback(e.unstable_NormalPriority,function(){Uv===s&&(Uv=null);for(var c=0;c<s.length;c+=3){var h=s[c],v=s[c+1],E=s[c+2];if(typeof v!="function"){if(lx(v||h)===null)continue;break}var A=mn(h);A!==null&&(s.splice(c,3),c-=3,sC(A,{pending:true,data:E,method:h.method,action:v},v,E));}}));}function ud(s){function c(le){return jv(le,s)}fl!==null&&jv(fl,s),ml!==null&&jv(ml,s),hl!==null&&jv(hl,s),Hm.forEach(c),Vm.forEach(c);for(var h=0;h<pl.length;h++){var v=pl[h];v.blockedOn===s&&(v.blockedOn=null);}for(;0<pl.length&&(h=pl[0],h.blockedOn===null);)t5(h),h.blockedOn===null&&pl.shift();if(h=(s.ownerDocument||s).$$reactFormReplay,h!=null)for(v=0;v<h.length;v+=3){var E=h[v],A=h[v+1],k=E[Sn]||null;if(typeof A=="function")k||r5(h);else if(k){var Z=null;if(A&&A.hasAttribute("formAction")){if(E=A,k=A[Sn]||null)Z=k.formAction;else if(lx(E)!==null)continue}else Z=k.action;typeof Z=="function"?h[v+1]=Z:(h.splice(v,3),v-=3),r5(h);}}}function o5(){function s(A){A.canIntercept&&A.info==="react-transition"&&A.intercept({handler:function(){return new Promise(function(k){return E=k})},focusReset:"manual",scroll:"manual"});}function c(){E!==null&&(E(),E=null),v||setTimeout(h,20);}function h(){if(!v&&!navigation.transition){var A=navigation.currentEntry;A&&A.url!=null&&navigation.navigate(A.url,{state:A.getState(),info:"react-transition",history:"replace"});}}if(typeof navigation=="object"){var v=false,E=null;return navigation.addEventListener("navigate",s),navigation.addEventListener("navigatesuccess",c),navigation.addEventListener("navigateerror",c),setTimeout(h,100),function(){v=true,navigation.removeEventListener("navigate",s),navigation.removeEventListener("navigatesuccess",c),navigation.removeEventListener("navigateerror",c),E!==null&&(E(),E=null);}}}function ux(s){this._internalRoot=s;}Wv.prototype.render=ux.prototype.render=function(s){var c=this._internalRoot;if(c===null)throw Error(r(409));var h=c.current,v=si();Y4(h,v,s,c,null,null);},Wv.prototype.unmount=ux.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var c=s.containerInfo;Y4(s.current,2,null,s,null,null),Ev(),c[Hn]=null;}};function Wv(s){this._internalRoot=s;}Wv.prototype.unstable_scheduleHydration=function(s){if(s){var c=ht();s={blockedOn:null,target:s,priority:c};for(var h=0;h<pl.length&&c!==0&&c<pl[h].priority;h++);pl.splice(h,0,s),h===0&&t5(s);}};var i5=t.version;if(i5!=="19.2.4")throw Error(r(527,i5,"19.2.4"));j.findDOMNode=function(s){var c=s._reactInternals;if(c===void 0)throw typeof s.render=="function"?Error(r(188)):(s=Object.keys(s).join(","),Error(r(268,s)));return s=d(c),s=s!==null?m(s):null,s=s===null?null:s.stateNode,s};var _X={bundleType:0,version:"19.2.4",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.4"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Gv=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Gv.isDisabled&&Gv.supportsFiber)try{Ze=Gv.inject(_X),Be=Gv;}catch{}}return Ym.createRoot=function(s,c){if(!o(s))throw Error(r(299));var h=false,v="",E=fP,A=mP,k=hP;return c!=null&&(c.unstable_strictMode===true&&(h=true),c.identifierPrefix!==void 0&&(v=c.identifierPrefix),c.onUncaughtError!==void 0&&(E=c.onUncaughtError),c.onCaughtError!==void 0&&(A=c.onCaughtError),c.onRecoverableError!==void 0&&(k=c.onRecoverableError)),c=q4(s,1,false,null,null,h,v,null,E,A,k,o5),s[Hn]=c.current,WC(s),new ux(c)},Ym.hydrateRoot=function(s,c,h){if(!o(s))throw Error(r(299));var v=false,E="",A=fP,k=mP,Z=hP,le=null;return h!=null&&(h.unstable_strictMode===true&&(v=true),h.identifierPrefix!==void 0&&(E=h.identifierPrefix),h.onUncaughtError!==void 0&&(A=h.onUncaughtError),h.onCaughtError!==void 0&&(k=h.onCaughtError),h.onRecoverableError!==void 0&&(Z=h.onRecoverableError),h.formState!==void 0&&(le=h.formState)),c=q4(s,1,true,c,h??null,v,E,le,A,k,Z,o5),c.context=K4(null),h=c.current,v=si(),v=Ge(v),E=el(v),E.callback=null,tl(h,E,v),h=v,c.current.lanes=h,Se(c,h),Pa(c),s[Hn]=c.current,WC(s),new Wv(c)},Ym.version="19.2.4",Ym}var KI;function fre(){if(KI)return Ox.exports;KI=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e);}catch(t){console.error(t);}}return e(),Ox.exports=dre(),Ox.exports}var Qa=fre();const L0="__rc_react_root__";function t1(e,t){const n=t[L0]||Qa.createRoot(t);n.render(e),t[L0]=n;}async function $k(e){return Promise.resolve().then(()=>{e[L0]?.unmount(),delete e[L0];})}const Bx=()=>({height:0,opacity:0}),YI=e=>{const{scrollHeight:t}=e;return {height:t,opacity:1}},mre=e=>({height:e?e.offsetHeight:0}),Lx=(e,t)=>t?.deadline===true||t.propertyName==="height",Ek=(e=np)=>({motionName:`${e}-motion-collapse`,onAppearStart:Bx,onEnterStart:Bx,onAppearActive:YI,onEnterActive:YI,onLeaveStart:mre,onLeaveActive:Bx,onAppearEnd:Lx,onEnterEnd:Lx,onLeaveEnd:Lx,motionDeadline:500}),Fl=(e,t,n)=>n!==void 0?n:`${e}-${t}`,hre=e=>{const{componentCls:t,colorPrimary:n,motionDurationSlow:r,motionEaseInOut:o,motionEaseOutCirc:i,antCls:a}=e,[,l]=tr(a,"wave");return {[t]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:l("color",n),boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:["box-shadow 0.4s","opacity 2s"].map(u=>`${u} ${i}`).join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0},"&.wave-quick":{transition:["box-shadow","opacity"].map(u=>`${u} ${r} ${o}`).join(",")}}}}},pre=ete("Wave",hre),n1=`${np}-wave-target`;function XI(e){return e&&typeof e=="string"&&e!=="#fff"&&e!=="#ffffff"&&e!=="rgb(255, 255, 255)"&&e!=="rgba(255, 255, 255, 1)"&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&e!=="transparent"&&e!=="canvastext"}function gre(e,t=null){const n=getComputedStyle(e),{borderTopColor:r,borderColor:o,backgroundColor:i}=n;return t&&XI(n[t])?n[t]:[r,o,i].find(XI)??null}function zx(e){return Number.isNaN(e)?0:e}const vre=e=>{const{className:t,target:n,component:r,colorSource:o}=e,i=f.useRef(null),{getPrefixCls:a}=f.useContext(wt),l=a(),[u]=tr(l,"wave"),[d,m]=f.useState(null),[p,g]=f.useState([]),[b,y]=f.useState(0),[S,C]=f.useState(0),[w,$]=f.useState(0),[M,T]=f.useState(0),[R,I]=f.useState(false),N={left:b,top:S,width:w,height:M,borderRadius:p.map(_=>`${_}px`).join(" ")};d&&(N[u("color")]=d);function P(){const _=getComputedStyle(n);m(gre(n,o));const B=_.position==="static",{borderLeftWidth:V,borderTopWidth:U}=_;y(B?n.offsetLeft:zx(-Number.parseFloat(V))),C(B?n.offsetTop:zx(-Number.parseFloat(U))),$(n.offsetWidth),T(n.offsetHeight);const{borderTopLeftRadius:G,borderTopRightRadius:H,borderBottomLeftRadius:z,borderBottomRightRadius:j}=_;g([G,H,j,z].map(W=>zx(Number.parseFloat(W))));}if(f.useEffect(()=>{if(n){const _=Lt(()=>{P(),I(true);});let B;return typeof ResizeObserver<"u"&&(B=new ResizeObserver(P),B.observe(n)),()=>{Lt.cancel(_),B?.disconnect();}}},[n]),!R)return null;const O=(r==="Checkbox"||r==="Radio")&&n?.classList.contains(n1);return f.createElement(Co,{visible:true,motionAppear:true,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(_,B)=>{if(B.deadline||B.propertyName==="opacity"){const V=i.current?.parentElement;$k(V).then(()=>{V?.remove();});}return false}},({className:_},B)=>f.createElement("div",{ref:Vr(i,B),className:X(t,_,{"wave-quick":O}),style:N}))},bre=(e,t)=>{const{component:n}=t;if(n==="Checkbox"&&!e.querySelector("input")?.checked)return;const r=document.createElement("div");r.style.position="absolute",r.style.left="0px",r.style.top="0px",e?.insertBefore(r,e?.firstChild),t1(f.createElement(vre,{...t,target:e}),r);},yre=(e,t,n,r)=>{const{wave:o}=f.useContext(wt),[,i,a]=jr(),l=Mt(m=>{const p=e.current;if(o?.disabled||!p)return;const g=p.querySelector(`.${n1}`)||p,{showEffect:b}=o||{};(b||bre)(g,{className:t,token:i,component:n,event:m,hashId:a,colorSource:r});}),u=f.useRef(null);return f.useEffect(()=>()=>{Lt.cancel(u.current);},[]),m=>{Lt.cancel(u.current),u.current=Lt(()=>{l(m);});}},Qp=e=>{const{children:t,disabled:n,component:r,colorSource:o}=e,{getPrefixCls:i}=f.useContext(wt),a=f.useRef(null),l=i("wave"),u=pre(l),d=yre(a,X(l,u),r,o);if(q.useEffect(()=>{const p=a.current;if(!p||p.nodeType!==window.Node.ELEMENT_NODE||n)return;const g=b=>{!oR(b.target)||!p.getAttribute||p.getAttribute("disabled")||p.disabled||p.className.includes("disabled")&&!p.className.includes("disabled:")||p.getAttribute("aria-disabled")==="true"||p.className.includes("-leave")||d(b);};return p.addEventListener("click",g,true),()=>{p.removeEventListener("click",g,true);}},[n]),!q.isValidElement(t))return t??null;const m=Su(t)?Vr(Ql(t),a):a;return Hr(t,{ref:m})},so=e=>{const t=q.useContext(lf);return q.useMemo(()=>e?typeof e=="string"?e??t:typeof e=="function"?e(t):t:t,[e,t])},Sre=e=>{const{componentCls:t}=e;return {[t]:{display:"inline-flex","&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"},"&-rtl":{direction:"rtl"}}}},Cre=Wt(["Space","Compact"],e=>[Sre(e)],()=>({}),{resetStyle:false}),r1=f.createContext(null),ks=(e,t)=>{const n=f.useContext(r1),r=f.useMemo(()=>{if(!n)return "";const{compactDirection:o,isFirstItem:i,isLastItem:a}=n,l=o==="vertical"?"-vertical-":"-";return X(`${e}-compact${l}item`,{[`${e}-compact${l}first-item`]:i,[`${e}-compact${l}last-item`]:a,[`${e}-compact${l}item-rtl`]:t==="rtl"})},[e,t,n]);return {compactSize:n?.compactSize,compactDirection:n?.compactDirection,compactItemClassnames:r}},xre=e=>{const{children:t}=e;return f.createElement(r1.Provider,{value:null},t)},wre=e=>{const{children:t,...n}=e;return f.createElement(r1.Provider,{value:f.useMemo(()=>n,[n])},t)},lR=e=>{const{getPrefixCls:t,direction:n}=f.useContext(wt),{size:r,direction:o,orientation:i,block:a,prefixCls:l,className:u,rootClassName:d,children:m,vertical:p,...g}=e,[b,y]=xu(i,p,o),S=so(I=>r??I),C=t("space-compact",l),[w]=Cre(C),$=X(C,w,{[`${C}-rtl`]:n==="rtl",[`${C}-block`]:a,[`${C}-vertical`]:y},u,d),M=f.useContext(r1),T=Qo(m),R=f.useMemo(()=>T.map((I,N)=>{const P=I?.key||`${C}-item-${N}`;return f.createElement(wre,{key:P,compactSize:S,compactDirection:b,isFirstItem:N===0&&(!M||M?.isFirstItem),isLastItem:N===T.length-1&&(!M||M?.isLastItem)},I)}),[T,M,b,S,C]);return T.length===0?null:f.createElement("div",{className:$,...g},R)},Mk=f.createContext(void 0),$re=e=>{const{getPrefixCls:t,direction:n}=f.useContext(wt),{prefixCls:r,size:o,className:i,...a}=e,l=t("btn-group",r),[,,u]=jr(),d=f.useMemo(()=>{switch(o){case "large":return "lg";case "small":return "sm";default:return ""}},[o]),m=X(l,{[`${l}-${d}`]:d,[`${l}-rtl`]:n==="rtl"},i,u);return f.createElement(Mk.Provider,{value:o},f.createElement("div",{...a,className:m}))},QI=/^[\u4E00-\u9FA5]{2}$/,G2=QI.test.bind(QI);function cR(e){return e==="danger"?{danger:true}:{type:e}}function ZI(e){return typeof e=="string"}function kx(e){return e==="text"||e==="link"}function Ere(e,t,n,r){if(!Jr(e)||e==="")return;const o=t?" ":"";return typeof e!="string"&&typeof e!="number"&&ZI(e.type)&&G2(e.props.children)?Hr(e,i=>{const a=X(i.className,r)||void 0,l={...n,...i.style};return {...i,children:i.children.split("").join(o),className:a,style:l}}):ZI(e)?q.createElement("span",{className:r,style:n},G2(e)?e.split("").join(o):e):uk(e)?q.createElement("span",{className:r,style:n},e):Hr(e,i=>({...i,className:X(i.className,r)||void 0,style:{...i.style,...n}}))}function Mre(e,t,n,r){let o=false;const i=[];return q.Children.forEach(e,a=>{const l=typeof a,u=l==="string"||l==="number";if(o&&u){const d=i.length-1,m=i[d];i[d]=`${m}${a}`;}else i.push(a);o=u;}),q.Children.map(i,a=>Ere(a,t,n,r))}["default","primary","danger"].concat(qt(Wa));const Rk=f.forwardRef((e,t)=>{const{className:n,style:r,children:o,prefixCls:i}=e,a=X(`${i}-icon`,n);return q.createElement("span",{ref:t,className:a,style:r},o)}),JI=f.forwardRef((e,t)=>{const{prefixCls:n,className:r,style:o,iconClassName:i}=e,a=X(`${n}-loading-icon`,r);return q.createElement(Rk,{prefixCls:n,className:a,style:o,ref:t},q.createElement(e1,{className:i}))}),Fx=()=>({width:0,opacity:0,transform:"scale(0)"}),Hx=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"}),Rre=e=>{const{prefixCls:t,loading:n,existIcon:r,className:o,style:i,mount:a}=e,l=!!n;return r?q.createElement(JI,{prefixCls:t,className:o,style:i}):q.createElement(Co,{visible:l,motionName:`${t}-loading-icon-motion`,motionAppear:!a,motionEnter:!a,motionLeave:!a,removeOnLeave:true,onAppearStart:Fx,onAppearActive:Hx,onEnterStart:Fx,onEnterActive:Hx,onLeaveStart:Hx,onLeaveActive:Fx},({className:u,style:d},m)=>{const p={...i,...d};return q.createElement(JI,{prefixCls:t,className:X(o,u),style:p,ref:m})})},eO=(e,t)=>({[`> span, > ${e}`]:{"&:not(:last-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{[`&, & > ${e}`]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}}),Tre=e=>{const{componentCls:t,fontSize:n,lineWidth:r,groupBorderColor:o,colorErrorHover:i}=e;return {[`${t}-group`]:[{position:"relative",display:"inline-flex",[`> span, > ${t}`]:{"&:not(:last-child)":{[`&, & > ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:e.calc(r).mul(-1).equal(),[`&, & > ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,"&:hover, &:focus, &:active":{zIndex:2},"&[disabled]":{zIndex:0}},[`${t}-icon-only`]:{fontSize:n}},eO(`${t}-primary`,o),eO(`${t}-danger`,i)]}},Vx=e=>Math.round(Number(e||0)),Are=e=>{if(e instanceof cn)return e;if(e&&typeof e=="object"&&"h"in e&&"b"in e){const{b:t,...n}=e;return {...n,v:t}}return typeof e=="string"&&/hsb/.test(e)?e.replace(/hsb/,"hsv"):e};class Sa extends cn{constructor(t){super(Are(t));}toHsbString(){const t=this.toHsb(),n=Vx(t.s*100),r=Vx(t.b*100),o=Vx(t.h),i=t.a,a=`hsb(${o}, ${n}%, ${r}%)`,l=`hsba(${o}, ${n}%, ${r}%, ${i.toFixed(i===0?0:2)})`;return i===1?a:l}toHsb(){const{v:t,...n}=this.toHsv();return {...n,b:t,a:this.a}}}const Nre="rc-color-picker",Gd=e=>e instanceof Sa?e:new Sa(e),Pre=Gd("#1677ff"),Tk=e=>{const{offset:t,targetRef:n,containerRef:r,color:o,type:i}=e,{width:a,height:l}=r.current.getBoundingClientRect(),{width:u,height:d}=n.current.getBoundingClientRect(),m=u/2,p=d/2,g=(t.x+m)/a,b=1-(t.y+p)/l,y=o.toHsb(),S=g,C=(t.x+m)/a*360;if(i)switch(i){case "hue":return Gd({...y,h:C<=0?0:C});case "alpha":return Gd({...y,a:S<=0?0:S})}return Gd({h:y.h,s:g<=0?0:g,b:b>=1?1:b,a:y.a})},Ak=(e,t)=>{const n=e.toHsb();switch(t){case "hue":return {x:n.h/360*100,y:50};case "alpha":return {x:e.a*100,y:50};default:return {x:n.s*100,y:(1-n.b)*100}}},uR=({color:e,prefixCls:t,className:n,style:r,innerClassName:o,innerStyle:i,onClick:a})=>{const l=`${t}-color-block`;return q.createElement("div",{className:X(l,n),style:r,onClick:a},q.createElement("div",{className:X(`${l}-inner`,o),style:{background:e,...i}}))};function Ire(e){const t="touches"in e?e.touches[0]:e,n=document.documentElement.scrollLeft||document.body.scrollLeft||window.pageXOffset,r=document.documentElement.scrollTop||document.body.scrollTop||window.pageYOffset;return {pageX:t.pageX-n,pageY:t.pageY-r}}function Nk(e){const{targetRef:t,containerRef:n,direction:r,onDragChange:o,onDragChangeComplete:i,calculate:a,color:l,disabledDrag:u}=e,[d,m]=f.useState({x:0,y:0}),p=f.useRef(null),g=f.useRef(null);f.useEffect(()=>{m(a());},[l]),f.useEffect(()=>()=>{document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",g.current),document.removeEventListener("touchmove",p.current),document.removeEventListener("touchend",g.current),p.current=null,g.current=null;},[]);const b=w=>{const{pageX:$,pageY:M}=Ire(w),{x:T,y:R,width:I,height:N}=n.current.getBoundingClientRect(),{width:P,height:O}=t.current.getBoundingClientRect(),_=P/2,B=O/2,V=Math.max(0,Math.min($-T,I))-_,U=Math.max(0,Math.min(M-R,N))-B,G={x:V,y:r==="x"?d.y:U};if(P===0&&O===0||P!==O)return false;o?.(G);},y=w=>{w.preventDefault(),b(w);},S=w=>{w.preventDefault(),document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",g.current),document.removeEventListener("touchmove",p.current),document.removeEventListener("touchend",g.current),p.current=null,g.current=null,i?.();};return [d,w=>{document.removeEventListener("mousemove",p.current),document.removeEventListener("mouseup",g.current),!u&&(b(w),document.addEventListener("mousemove",y),document.addEventListener("mouseup",S),document.addEventListener("touchmove",y),document.addEventListener("touchend",S),p.current=y,g.current=S);}]}const Pk=({size:e="default",color:t,prefixCls:n})=>q.createElement("div",{className:X(`${n}-handler`,{[`${n}-handler-sm`]:e==="small"}),style:{backgroundColor:t}}),Ik=({children:e,style:t,prefixCls:n})=>q.createElement("div",{className:`${n}-palette`,style:{position:"relative",...t}},e),Ok=f.forwardRef((e,t)=>{const{children:n,x:r,y:o}=e;return q.createElement("div",{ref:t,style:{position:"absolute",left:`${r}%`,top:`${o}%`,zIndex:1,transform:"translate(-50%, -50%)"}},n)}),Ore=({color:e,onChange:t,prefixCls:n,onChangeComplete:r,disabled:o})=>{const i=f.useRef(),a=f.useRef(),l=f.useRef(e),u=Mt(p=>{const g=Tk({offset:p,targetRef:a,containerRef:i,color:e});l.current=g,t(g);}),[d,m]=Nk({color:e,containerRef:i,targetRef:a,calculate:()=>Ak(e),onDragChange:u,onDragChangeComplete:()=>r?.(l.current),disabledDrag:o});return q.createElement("div",{ref:i,className:`${n}-select`,onMouseDown:m,onTouchStart:m},q.createElement(Ik,{prefixCls:n},q.createElement(Ok,{x:d.x,y:d.y,ref:a},q.createElement(Pk,{color:e.toRgbString(),prefixCls:n})),q.createElement("div",{className:`${n}-saturation`,style:{backgroundColor:`hsl(${e.toHsb().h},100%, 50%)`,backgroundImage:"linear-gradient(0deg, #000, transparent),linear-gradient(90deg, #fff, hsla(0, 0%, 100%, 0))"}})))},Dre=(e,t)=>{const[n,r]=un(e,t);return [f.useMemo(()=>Gd(n),[n]),r]},_re=({colors:e,children:t,direction:n="to right",type:r,prefixCls:o})=>{const i=f.useMemo(()=>e.map((a,l)=>{let u=Gd(a);return r==="alpha"&&l===e.length-1&&(u=new Sa(u.setA(1))),u.toRgbString()}).join(","),[e,r]);return q.createElement("div",{className:`${o}-gradient`,style:{position:"absolute",inset:0,background:`linear-gradient(${n}, ${i})`}},t)},Bre=e=>{const{prefixCls:t,colors:n,disabled:r,onChange:o,onChangeComplete:i,color:a,type:l}=e,u=f.useRef(null),d=f.useRef(null),m=f.useRef(a),p=w=>l==="hue"?w.getHue():w.a*100,g=Mt(w=>{const $=Tk({offset:w,targetRef:d,containerRef:u,color:a,type:l});m.current=$,o(p($));}),[b,y]=Nk({color:a,targetRef:d,containerRef:u,calculate:()=>Ak(a,l),onDragChange:g,onDragChangeComplete(){i(p(m.current));},direction:"x",disabledDrag:r}),S=q.useMemo(()=>{if(l==="hue"){const w=a.toHsb();return w.s=1,w.b=1,w.a=1,new Sa(w)}return a},[a,l]),C=q.useMemo(()=>n.map(w=>`${w.color} ${w.percent}%`),[n]);return q.createElement("div",{ref:u,className:X(`${t}-slider`,`${t}-slider-${l}`),onMouseDown:y,onTouchStart:y},q.createElement(Ik,{prefixCls:t},q.createElement(Ok,{x:b.x,y:b.y,ref:d},q.createElement(Pk,{size:"small",color:S.toHexString(),prefixCls:t})),q.createElement(_re,{colors:C,type:l,prefixCls:t})))};function Lre(e){return f.useMemo(()=>{const{slider:t}=e||{};return [t||Bre]},[e])}function Ih(){return Ih=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Ih.apply(this,arguments)}const zre=[{color:"rgb(255, 0, 0)",percent:0},{color:"rgb(255, 255, 0)",percent:17},{color:"rgb(0, 255, 0)",percent:33},{color:"rgb(0, 255, 255)",percent:50},{color:"rgb(0, 0, 255)",percent:67},{color:"rgb(255, 0, 255)",percent:83},{color:"rgb(255, 0, 0)",percent:100}],kre=f.forwardRef((e,t)=>{const{value:n,defaultValue:r,prefixCls:o=Nre,onChange:i,onChangeComplete:a,className:l,style:u,panelRender:d,disabledAlpha:m=false,disabled:p=false,components:g}=e,[b]=Lre(g),[y,S]=Dre(r||Pre,n),C=f.useMemo(()=>y.setA(1).toRgbString(),[y]),w=(B,V)=>{n||S(B),i?.(B,V);},$=B=>new Sa(y.setHue(B)),M=B=>new Sa(y.setA(B/100)),T=B=>{w($(B),{type:"hue",value:B});},R=B=>{w(M(B),{type:"alpha",value:B});},I=B=>{a&&a($(B));},N=B=>{a&&a(M(B));},P=X(`${o}-panel`,l,{[`${o}-panel-disabled`]:p}),O={prefixCls:o,disabled:p,color:y},_=q.createElement(q.Fragment,null,q.createElement(Ore,Ih({onChange:w},O,{onChangeComplete:a})),q.createElement("div",{className:`${o}-slider-container`},q.createElement("div",{className:X(`${o}-slider-group`,{[`${o}-slider-group-disabled-alpha`]:m})},q.createElement(b,Ih({},O,{type:"hue",colors:zre,min:0,max:359,value:y.getHue(),onChange:T,onChangeComplete:I})),!m&&q.createElement(b,Ih({},O,{type:"alpha",colors:[{percent:0,color:"rgba(255, 0, 4, 0)"},{percent:100,color:C}],min:0,max:100,value:y.a*100,onChange:R,onChangeComplete:N}))),q.createElement(uR,{color:y.toRgbString(),prefixCls:o})));return q.createElement("div",{className:P,style:u,ref:t},typeof d=="function"?d(_):_)}),yh=(e,t)=>e?.replace(/[^0-9a-f]/gi,"").slice(0,t?8:6)||"",Fre=(e,t)=>e?yh(e,t):"";let Go=(function(){function e(t){if(Xi(this,e),this.cleared=false,t instanceof e){this.metaColor=t.metaColor.clone(),this.colors=t.colors?.map(r=>({color:new e(r.color),percent:r.percent})),this.cleared=t.cleared;return}const n=Array.isArray(t);n&&t.length?(this.colors=t.map(({color:r,percent:o})=>({color:new e(r),percent:o})),this.metaColor=new Sa(this.colors[0].color.metaColor)):this.metaColor=new Sa(n?"":t),(!t||n&&!this.colors)&&(this.metaColor=this.metaColor.setA(0),this.cleared=true);}return Qi(e,[{key:"toHsb",value:function(){return this.metaColor.toHsb()}},{key:"toHsbString",value:function(){return this.metaColor.toHsbString()}},{key:"toHex",value:function(){return Fre(this.toHexString(),this.metaColor.a<1)}},{key:"toHexString",value:function(){return this.metaColor.toHexString()}},{key:"toRgb",value:function(){return this.metaColor.toRgb()}},{key:"toRgbString",value:function(){return this.metaColor.toRgbString()}},{key:"isGradient",value:function(){return !!this.colors&&!this.cleared}},{key:"getColors",value:function(){return this.colors||[{color:this,percent:0}]}},{key:"toCssString",value:function(){const{colors:n}=this;return n?`linear-gradient(90deg, ${n.map(o=>`${o.color.toRgbString()} ${o.percent}%`).join(", ")})`:this.metaColor.toRgbString()}},{key:"equals",value:function(n){return !n||this.isGradient()!==n.isGradient()?false:this.isGradient()?this.colors.length===n.colors.length&&this.colors.every((r,o)=>{const i=n.colors[o];return r.percent===i.percent&&r.color.equals(i.color)}):this.toHexString()===n.toHexString()}}])})();var Hre={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M765.7 486.8L314.9 134.7A7.97 7.97 0 00302 141v77.3c0 4.9 2.3 9.6 6.1 12.6l360 281.1-360 281.1c-3.9 3-6.1 7.7-6.1 12.6V883c0 6.7 7.7 10.4 12.9 6.3l450.8-352.1a31.96 31.96 0 000-50.4z"}}]},name:"right",theme:"outlined"};function q2(){return q2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},q2.apply(this,arguments)}const Vre=(e,t)=>f.createElement(Xn,q2({},e,{ref:t,icon:Hre})),cf=f.forwardRef(Vre),jre=q.forwardRef((e,t)=>{const{prefixCls:n,forceRender:r,className:o,style:i,children:a,isActive:l,role:u,classNames:d,styles:m}=e,[p,g]=q.useState(l||r);return q.useEffect(()=>{(r||l)&&g(true);},[r,l]),p?q.createElement("div",{ref:t,className:X(`${n}-panel`,{[`${n}-panel-active`]:l,[`${n}-panel-inactive`]:!l},o),style:i,role:u},q.createElement("div",{className:X(`${n}-body`,d?.body),style:m?.body},a)):null}),Dk=q.forwardRef((e,t)=>{const{showArrow:n=true,headerClass:r,isActive:o,onItemClick:i,forceRender:a,className:l,classNames:u={},styles:d={},prefixCls:m,collapsible:p,accordion:g,panelKey:b,extra:y,header:S,expandIcon:C,openMotion:w,destroyOnHidden:$,children:M,...T}=e,R=p==="disabled",I=y!=null&&typeof y!="boolean",N={onClick:()=>{i?.(b);},onKeyDown:U=>{(U.key==="Enter"||U.keyCode===it.ENTER||U.which===it.ENTER)&&i?.(b);},role:g?"tab":"button","aria-expanded":o,"aria-disabled":R,tabIndex:R?-1:0},P=typeof C=="function"?C(e):q.createElement("i",{className:"arrow"}),O=P&&q.createElement("div",cr({className:X(`${m}-expand-icon`,u?.icon),style:d?.icon},["header","icon"].includes(p)?N:{}),P),_=X(`${m}-item`,{[`${m}-item-active`]:o,[`${m}-item-disabled`]:R},l),V={className:X(r,`${m}-header`,{[`${m}-collapsible-${p}`]:!!p},u?.header),style:d?.header,...["header","icon"].includes(p)?{}:N};return q.createElement("div",cr({},T,{ref:t,className:_}),q.createElement("div",V,n&&O,q.createElement("span",cr({className:X(`${m}-title`,u?.title),style:d?.title},p==="header"?N:{}),S),I&&q.createElement("div",{className:`${m}-extra`},y)),q.createElement(Co,cr({visible:o,leavedClassName:`${m}-panel-hidden`},w,{forceRender:a,removeOnLeave:$}),({className:U,style:G},H)=>q.createElement(jre,{ref:H,prefixCls:m,className:U,classNames:u,style:G,styles:d,isActive:o,forceRender:a,role:g?"tabpanel":void 0},M)))});function _k(e,t,n){if(!e||!t)return e||t;const r=Array.from(new Set([...Object.keys(e),...Object.keys(t)])),o={};return r.forEach(i=>{o[i]=n(e[i],t[i]);}),o}function Ure(e,t){return _k(e,t,(n,r)=>X(n,r))}function Wre(e,t){return _k(e,t,(n,r)=>({...n,...r}))}const Gre=(e,t)=>{const{prefixCls:n,accordion:r,collapsible:o,destroyOnHidden:i,onItemClick:a,activeKey:l,openMotion:u,expandIcon:d,classNames:m,styles:p}=t;return e.map((g,b)=>{const{children:y,label:S,key:C,collapsible:w,onItemClick:$,destroyOnHidden:M,classNames:T,styles:R,...I}=g,N=String(C??b),P=w??o,O=M??i,_=V=>{P!=="disabled"&&(a(V),$?.(V));};let B=false;return r?B=l[0]===N:B=l.indexOf(N)>-1,q.createElement(Dk,cr({},I,{classNames:Ure(m,T),styles:Wre(p,R),prefixCls:n,key:N,panelKey:N,isActive:B,accordion:r,openMotion:u,expandIcon:d,header:S,collapsible:P,onItemClick:_,destroyOnHidden:O}),y)})},qre=(e,t,n)=>{if(!e)return null;const{prefixCls:r,accordion:o,collapsible:i,destroyOnHidden:a,onItemClick:l,activeKey:u,openMotion:d,expandIcon:m,classNames:p,styles:g}=n,b=e.key||String(t),{header:y,headerClass:S,destroyOnHidden:C,collapsible:w,onItemClick:$}=e.props;let M=false;o?M=u[0]===b:M=u.indexOf(b)>-1;const T=w??i,R=N=>{T!=="disabled"&&(l(N),$?.(N));},I={key:b,panelKey:b,header:y,headerClass:S,classNames:p,styles:g,isActive:M,prefixCls:r,destroyOnHidden:C??a,openMotion:d,accordion:o,children:e.props.children,onItemClick:R,expandIcon:m,collapsible:T};return typeof e.type=="string"?e:(Object.keys(I).forEach(N=>{typeof I[N]>"u"&&delete I[N];}),q.cloneElement(e,I))};function Kre(e,t,n){return Array.isArray(e)?Gre(e,n):Qo(t).map((r,o)=>qre(r,o,n))}function tO(e){let t=e;if(!Array.isArray(t)){const n=typeof t;t=n==="number"||n==="string"?[t]:[];}return t.map(n=>String(n))}const Yre=q.forwardRef((e,t)=>{const{prefixCls:n="rc-collapse",destroyOnHidden:r=false,style:o,accordion:i,className:a,children:l,collapsible:u,openMotion:d,expandIcon:m,activeKey:p,defaultActiveKey:g,onChange:b,items:y,classNames:S,styles:C}=e,w=X(n,a),[$,M]=un(g,p),T=tO($),R=Mt(P=>{const O=tO(P);M(O),b?.(O);}),I=P=>{R(i?T[0]===P?[]:[P]:T.includes(P)?T.filter(O=>O!==P):[...T,P]);};Er(!l,"[rc-collapse] `children` will be removed in next major version. Please use `items` instead.");const N=Kre(y,l,{prefixCls:n,accordion:i,openMotion:d,expandIcon:m,collapsible:u,destroyOnHidden:r,onItemClick:I,activeKey:T,classNames:S,styles:C});return q.createElement("div",cr({ref:t,className:w,style:o,role:i?"tablist":void 0},yo(e,{aria:true,data:true})),N)}),dR=Object.assign(Yre,{Panel:Dk}),{Panel:U4e}=dR,Xre=f.forwardRef((e,t)=>{const{getPrefixCls:n}=f.useContext(wt),{prefixCls:r,className:o,showArrow:i=true}=e,a=n("collapse",r),l=X({[`${a}-no-arrow`]:!i},o);return f.createElement(dR.Panel,{ref:t,...e,prefixCls:a,className:l})}),Bk=e=>{const{componentCls:t,antCls:n,motionDurationMid:r,motionEaseInOut:o}=e;return {[t]:{[`${n}-motion-collapse-legacy`]:{overflow:"hidden","&-active":{transition:`${["height","opacity"].map(i=>`${i} ${r} ${o}`).join(", ")} !important`}},[`${n}-motion-collapse`]:{overflow:"hidden",transition:`${["height","opacity"].map(i=>`${i} ${r} ${o}`).join(", ")} !important`}}}},Qre=e=>({animationDuration:e,animationFillMode:"both"}),Zre=e=>({animationDuration:e,animationFillMode:"both"}),o1=(e,t,n,r,o=false)=>{const i=o?"&":"";return {[`
${i}${e}-enter,
${i}${e}-appear
`]:{...Qre(r),animationPlayState:"paused"},[`${i}${e}-leave`]:{...Zre(r),animationPlayState:"paused"},[`
${i}${e}-enter${e}-enter-active,
${i}${e}-appear${e}-appear-active
`]:{animationName:t,animationPlayState:"running"},[`${i}${e}-leave${e}-leave-active`]:{animationName:n,animationPlayState:"running",pointerEvents:"none"}}},Jre=new zt("antFadeIn",{"0%":{opacity:0},"100%":{opacity:1}}),eoe=new zt("antFadeOut",{"0%":{opacity:1},"100%":{opacity:0}}),fR=(e,t=false)=>{const{antCls:n}=e,r=`${n}-fade`,o=t?"&":"";return [o1(r,Jre,eoe,e.motionDurationMid,t),{[`
${o}${r}-enter,
${o}${r}-appear
`]:{opacity:0,animationTimingFunction:"linear"},[`${o}${r}-leave`]:{animationTimingFunction:"linear"}}]},toe=new zt("antMoveDownIn",{"0%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),noe=new zt("antMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0}}),roe=new zt("antMoveLeftIn",{"0%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),ooe=new zt("antMoveLeftOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),ioe=new zt("antMoveRightIn",{"0%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),aoe=new zt("antMoveRightOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),soe=new zt("antMoveUpIn",{"0%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),loe=new zt("antMoveUpOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0}}),coe={"move-up":{inKeyframes:soe,outKeyframes:loe},"move-down":{inKeyframes:toe,outKeyframes:noe},"move-left":{inKeyframes:roe,outKeyframes:ooe},"move-right":{inKeyframes:ioe,outKeyframes:aoe}},z0=(e,t)=>{const{antCls:n}=e,r=`${n}-${t}`,{inKeyframes:o,outKeyframes:i}=coe[t];return [o1(r,o,i,e.motionDurationMid),{[`
${r}-enter,
${r}-appear
`]:{opacity:0,animationTimingFunction:e.motionEaseOutCirc},[`${r}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},mR=new zt("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),hR=new zt("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),pR=new zt("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),gR=new zt("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),uoe=new zt("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),doe=new zt("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}}),foe=new zt("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),moe=new zt("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}}),hoe={"slide-up":{inKeyframes:mR,outKeyframes:hR},"slide-down":{inKeyframes:pR,outKeyframes:gR},"slide-left":{inKeyframes:uoe,outKeyframes:doe},"slide-right":{inKeyframes:foe,outKeyframes:moe}},Hl=(e,t)=>{const{antCls:n}=e,r=`${n}-${t}`,{inKeyframes:o,outKeyframes:i}=hoe[t];return [o1(r,o,i,e.motionDurationMid),{[`
${r}-enter,
${r}-appear
`]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:e.motionEaseOutQuint,"&-prepare":{transform:"scale(1)"}},[`${r}-leave`]:{animationTimingFunction:e.motionEaseInQuint}}]},poe=new zt("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),goe=new zt("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),nO=new zt("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),rO=new zt("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),voe=new zt("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),boe=new zt("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),yoe=new zt("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),Soe=new zt("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),Coe=new zt("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),xoe=new zt("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}}),woe=new zt("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),$oe=new zt("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}}),Eoe={zoom:{inKeyframes:poe,outKeyframes:goe},"zoom-big":{inKeyframes:nO,outKeyframes:rO},"zoom-big-fast":{inKeyframes:nO,outKeyframes:rO},"zoom-left":{inKeyframes:yoe,outKeyframes:Soe},"zoom-right":{inKeyframes:Coe,outKeyframes:xoe},"zoom-up":{inKeyframes:voe,outKeyframes:boe},"zoom-down":{inKeyframes:woe,outKeyframes:$oe}},Zp=(e,t)=>{const{antCls:n}=e,r=`${n}-${t}`,{inKeyframes:o,outKeyframes:i}=Eoe[t];return [o1(r,o,i,t==="zoom-big-fast"?e.motionDurationFast:e.motionDurationMid),{[`
${r}-enter,
${r}-appear
`]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},[`${r}-leave`]:{animationTimingFunction:e.motionEaseInOutCirc}}]},Moe=e=>{const{componentCls:t,contentBg:n,padding:r,headerBg:o,headerPadding:i,collapseHeaderPaddingSM:a,collapseHeaderPaddingLG:l,collapsePanelBorderRadius:u,lineWidth:d,lineType:m,colorBorder:p,colorText:g,colorTextHeading:b,colorTextDisabled:y,fontSizeLG:S,lineHeight:C,lineHeightLG:w,marginSM:$,paddingSM:M,paddingLG:T,paddingXS:R,motionDurationSlow:I,fontSizeIcon:N,contentPadding:P,fontHeight:O,fontHeightLG:_}=e,B=`${oe(d)} ${m} ${p}`;return {[t]:{...dn(e),backgroundColor:o,border:B,borderRadius:u,"&-rtl":{direction:"rtl"},[`& > ${t}-item`]:{borderBottom:B,"&:first-child":{[`
&,
& > ${t}-header`]:{borderRadius:`${oe(u)} ${oe(u)} 0 0`}},"&:last-child":{[`
&,
& > ${t}-header`]:{borderRadius:`0 0 ${oe(u)} ${oe(u)}`}},[`> ${t}-header`]:{position:"relative",display:"flex",flexWrap:"nowrap",alignItems:"flex-start",padding:i,color:b,lineHeight:C,cursor:"pointer",transition:`all ${I}, visibility 0s`,...$i(e),[`> ${t}-title`]:{flex:"auto"},[`${t}-expand-icon`]:{height:O,display:"flex",alignItems:"center",marginInlineEnd:$},[`${t}-arrow`]:{...Cu(),fontSize:N,transition:`transform ${I}`,svg:{transition:`transform ${I}`}},[`${t}-title`]:{marginInlineEnd:"auto"}},[`${t}-collapsible-header`]:{cursor:"default",[`${t}-title`]:{flex:"none",cursor:"pointer"},[`${t}-expand-icon`]:{cursor:"pointer"}},[`${t}-collapsible-icon`]:{cursor:"unset",[`${t}-expand-icon`]:{cursor:"pointer"}}},[`${t}-panel`]:{color:g,backgroundColor:n,borderTop:B,[`& > ${t}-body`]:{padding:P},"&-hidden":{display:"none"}},"&-small":{[`> ${t}-item`]:{[`> ${t}-header`]:{padding:a,paddingInlineStart:R,[`> ${t}-expand-icon`]:{marginInlineStart:e.calc(M).sub(R).equal()}},[`> ${t}-panel > ${t}-body`]:{padding:M}}},"&-large":{[`> ${t}-item`]:{fontSize:S,lineHeight:w,[`> ${t}-header`]:{padding:l,paddingInlineStart:r,[`> ${t}-expand-icon`]:{height:_,marginInlineStart:e.calc(T).sub(r).equal()}},[`> ${t}-panel > ${t}-body`]:{padding:T}}},[`${t}-item:last-child`]:{borderBottom:0,[`> ${t}-panel`]:{borderRadius:`0 0 ${oe(u)} ${oe(u)}`}},[`& ${t}-item-disabled > ${t}-header`]:{"\n &,\n & > .arrow\n ":{color:y,cursor:"not-allowed"}},[`&${t}-icon-placement-end`]:{[`& > ${t}-item`]:{[`> ${t}-header`]:{[`${t}-expand-icon`]:{order:1,marginInlineEnd:0,marginInlineStart:$}}}}}}},Roe=e=>{const{componentCls:t}=e,n=`> ${t}-item > ${t}-header ${t}-arrow`;return {[`${t}-rtl`]:{[n]:{transform:"rotate(180deg)"}}}},Toe=e=>{const{componentCls:t,headerBg:n,borderlessContentPadding:r,borderlessContentBg:o,colorBorder:i}=e;return {[`${t}-borderless`]:{backgroundColor:n,border:0,[`> ${t}-item`]:{borderBottom:`1px solid ${i}`},[`
> ${t}-item:last-child,
> ${t}-item:last-child ${t}-header
`]:{borderRadius:0},[`> ${t}-item:last-child`]:{borderBottom:0},[`> ${t}-item > ${t}-panel`]:{backgroundColor:o,borderTop:0},[`> ${t}-item > ${t}-panel > ${t}-body`]:{padding:r}}}},Aoe=e=>{const{componentCls:t,paddingSM:n}=e;return {[`${t}-ghost`]:{backgroundColor:"transparent",border:0,[`> ${t}-item`]:{borderBottom:0,[`> ${t}-panel`]:{backgroundColor:"transparent",border:0,[`> ${t}-body`]:{paddingBlock:n}}}}}},Noe=e=>({headerPadding:`${e.paddingSM}px ${e.padding}px`,headerBg:e.colorFillAlter,contentPadding:`${e.padding}px 16px`,contentBg:e.colorBgContainer,borderlessContentPadding:`${e.paddingXXS}px 16px ${e.padding}px`,borderlessContentBg:"transparent"}),Poe=Wt("Collapse",e=>{const t=Ft(e,{collapseHeaderPaddingSM:`${oe(e.paddingXS)} ${oe(e.paddingSM)}`,collapseHeaderPaddingLG:`${oe(e.padding)} ${oe(e.paddingLG)}`,collapsePanelBorderRadius:e.borderRadiusLG});return [Moe(t),Toe(t),Aoe(t),Roe(t),Bk(t)]},Noe),Ioe=f.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r,expandIcon:o,className:i,style:a,classNames:l,styles:u}=jt("collapse"),{prefixCls:d,className:m,rootClassName:p,style:g,bordered:b=true,ghost:y,size:S,expandIconPlacement:C,expandIconPosition:w,children:$,destroyInactivePanel:M,destroyOnHidden:T,expandIcon:R,classNames:I,styles:N}=e,P=so(L=>S??L??"middle"),O=n("collapse",d),_=n(),[B,V]=Poe(O),U=C??w??"start",G={...e,size:P,bordered:b,expandIconPlacement:U},[H,z]=Kt([l,I],[u,N],{props:G}),j=R??o,W=f.useCallback((L={})=>{const K=typeof j=="function"?j(L):f.createElement(cf,{rotate:L.isActive?r==="rtl"?-90:90:void 0,"aria-label":L.isActive?"expanded":"collapsed"});return Hr(K,J=>({className:X(J.className,`${O}-arrow`)}))},[j,O,r]),Y=X(`${O}-icon-placement-${U}`,{[`${O}-borderless`]:!b,[`${O}-rtl`]:r==="rtl",[`${O}-ghost`]:!!y,[`${O}-${P}`]:P!=="middle"},i,m,p,B,V,H.root),Q=f.useMemo(()=>({...Ek(_),motionAppear:false,leavedClassName:`${O}-panel-hidden`}),[_,O]),D=f.useMemo(()=>$?Qo($).map(L=>L):null,[$]);return f.createElement(dR,{ref:t,openMotion:Q,...Ln(e,["rootClassName"]),expandIcon:W,prefixCls:O,className:Y,style:{...z.root,...a,...g},classNames:H,styles:z,destroyOnHidden:T??M},D)}),Lk=Object.assign(Ioe,{Panel:Xre}),ro=e=>e instanceof Go?e:new Go(e),Ub=e=>Math.round(Number(e||0)),vR=e=>Ub(e.toHsb().a*100),Wb=(e,t)=>{const n=e.toRgb();if(!n.r&&!n.g&&!n.b){const r=e.toHsb();return r.a=1,ro(r)}return n.a=1,ro(n)},zk=(e,t)=>{const n=[{percent:0,color:e[0].color}].concat(qt(e),[{percent:100,color:e[e.length-1].color}]);for(let r=0;r<n.length-1;r+=1){const o=n[r].percent,i=n[r+1].percent,a=n[r].color,l=n[r+1].color;if(o<=t&&t<=i){const u=i-o;if(u===0)return a;const d=(t-o)/u*100,m=new Sa(a),p=new Sa(l);return m.mix(p,d).toRgbString()}}return ""},Ooe=e=>e.map(t=>(t.colors=t.colors.map(ro),t)),bR=(e,t)=>{const{r:n,g:r,b:o,a:i}=e.toRgb(),a=new Sa(e.toRgbString()).onBackground(t).toHsv();return i<=.5?a.v>.5:n*.299+r*.587+o*.114>192},oO=(e,t)=>`panel-${e.key??t}`,Doe=({prefixCls:e,presets:t,value:n,onChange:r})=>{const[o]=Oo("ColorPicker"),[,i]=jr(),a=f.useMemo(()=>Ooe(t),[t]),l=`${e}-presets`,u=f.useMemo(()=>a.reduce((p,g,b)=>{const{defaultOpen:y=true}=g;return y&&p.push(oO(g,b)),p},[]),[a]),d=p=>{r?.(p);},m=a.map((p,g)=>({key:oO(p,g),label:q.createElement("div",{className:`${l}-label`},p?.label),children:q.createElement("div",{className:`${l}-items`},Array.isArray(p?.colors)&&p.colors?.length>0?p.colors.map((b,y)=>{const S=ro(b);return q.createElement(uR,{key:`preset-${y}-${b.toHexString()}`,color:S.toCssString(),prefixCls:e,className:X(`${l}-color`,{[`${l}-color-checked`]:b.toCssString()===n?.toCssString(),[`${l}-color-bright`]:bR(b,i.colorBgElevated)}),onClick:()=>d(b)})}):q.createElement("span",{className:`${l}-empty`},o.presetEmpty))}));return q.createElement("div",{className:l},q.createElement(Lk,{defaultActiveKey:u,ghost:true,items:m}))},kk=e=>{const{paddingInline:t,onlyIconSize:n,borderColorDisabled:r}=e;return Ft(e,{buttonPaddingHorizontal:t,buttonPaddingVertical:0,buttonIconOnlyFontSize:n,colorBorderDisabled:r})},Fk=e=>{const t=e.contentFontSize??e.fontSize,n=e.contentFontSizeSM??e.fontSize,r=e.contentFontSizeLG??e.fontSizeLG,o=e.contentLineHeight??Hb(t),i=e.contentLineHeightSM??Hb(n),a=e.contentLineHeightLG??Hb(r),l=bR(new Go(e.colorBgSolid),"#fff")?"#000":"#fff",u=Wa.reduce((p,g)=>({...p,[`${g}ShadowColor`]:`0 ${oe(e.controlOutlineWidth)} 0 ${bh(e[`${g}1`],e.colorBgContainer)}`}),{}),d=e.colorBgContainerDisabled,m=e.colorBgContainerDisabled;return {...u,fontWeight:400,iconGap:e.marginXS,defaultShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlTmpOutline}`,primaryShadow:`0 ${e.controlOutlineWidth}px 0 ${e.controlOutline}`,dangerShadow:`0 ${e.controlOutlineWidth}px 0 ${e.colorErrorOutline}`,primaryColor:e.colorTextLightSolid,dangerColor:e.colorTextLightSolid,borderColorDisabled:e.colorBorderDisabled,defaultGhostColor:e.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:e.colorBgContainer,paddingInline:e.paddingContentHorizontal-e.lineWidth,paddingInlineLG:e.paddingContentHorizontal-e.lineWidth,paddingInlineSM:8-e.lineWidth,onlyIconSize:"inherit",onlyIconSizeSM:"inherit",onlyIconSizeLG:"inherit",groupBorderColor:e.colorPrimaryHover,linkHoverBg:"transparent",textTextColor:e.colorText,textTextHoverColor:e.colorText,textTextActiveColor:e.colorText,textHoverBg:e.colorFillTertiary,defaultColor:e.colorText,defaultBg:e.colorBgContainer,defaultBorderColor:e.colorBorder,defaultBorderColorDisabled:e.colorBorder,defaultHoverBg:e.colorBgContainer,defaultHoverColor:e.colorPrimaryHover,defaultHoverBorderColor:e.colorPrimaryHover,defaultActiveBg:e.colorBgContainer,defaultActiveColor:e.colorPrimaryActive,defaultActiveBorderColor:e.colorPrimaryActive,solidTextColor:l,contentFontSize:t,contentFontSizeSM:n,contentFontSizeLG:r,contentLineHeight:o,contentLineHeightSM:i,contentLineHeightLG:a,paddingBlock:Math.max((e.controlHeight-t*o)/2-e.lineWidth,0),paddingBlockSM:Math.max((e.controlHeightSM-n*i)/2-e.lineWidth,0),paddingBlockLG:Math.max((e.controlHeightLG-r*a)/2-e.lineWidth,0),defaultBgDisabled:d,dashedBgDisabled:m}},_oe=e=>{const{componentCls:t,antCls:n,lineWidth:r}=e,[o,i]=tr(n,"btn");return {[t]:[{[o("border-width")]:r,[o("border-color")]:"#000",[o("border-color-hover")]:i("border-color"),[o("border-color-active")]:i("border-color"),[o("border-color-disabled")]:i("border-color"),[o("border-style")]:"solid",[o("text-color")]:"#000",[o("text-color-hover")]:i("text-color"),[o("text-color-active")]:i("text-color"),[o("text-color-disabled")]:i("text-color"),[o("bg-color")]:"#ddd",[o("bg-color-hover")]:i("bg-color"),[o("bg-color-active")]:i("bg-color"),[o("bg-color-disabled")]:e.colorBgContainerDisabled,[o("bg-color-container")]:e.colorBgContainer,[o("shadow")]:"none"},{border:[i("border-width"),i("border-style"),i("border-color")].join(" "),color:i("text-color"),backgroundColor:i("bg-color"),[`&:not(:disabled):not(${t}-disabled)`]:{"&:hover":{border:[i("border-width"),i("border-style"),i("border-color-hover")].join(" "),color:i("text-color-hover"),backgroundColor:i("bg-color-hover")},"&:active":{border:[i("border-width"),i("border-style"),i("border-color-active")].join(" "),color:i("text-color-active"),backgroundColor:i("bg-color-active")}}},{[`&${t}-variant-solid`]:{[o("solid-bg-color")]:i("color-base"),[o("solid-bg-color-hover")]:i("color-hover"),[o("solid-bg-color-active")]:i("color-active"),[o("border-color")]:"transparent",[o("text-color")]:e.colorTextLightSolid,[o("bg-color")]:i("solid-bg-color"),[o("bg-color-hover")]:i("solid-bg-color-hover"),[o("bg-color-active")]:i("solid-bg-color-active"),boxShadow:i("shadow")},[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[o("border-color")]:i("color-base"),[o("border-color-hover")]:i("color-hover"),[o("border-color-active")]:i("color-active"),[o("bg-color")]:i("bg-color-container"),[o("text-color")]:i("color-base"),[o("text-color-hover")]:i("color-hover"),[o("text-color-active")]:i("color-active"),boxShadow:i("shadow")},[`&${t}-variant-dashed`]:{[o("border-style")]:"dashed",[o("bg-color-disabled")]:e.dashedBgDisabled},[`&${t}-variant-filled`]:{[o("border-color")]:"transparent",[o("text-color")]:i("color-base"),[o("bg-color")]:i("color-light"),[o("bg-color-hover")]:i("color-light-hover"),[o("bg-color-active")]:i("color-light-active")},[`&${t}-variant-text, &${t}-variant-link`]:{[o("border-color")]:"transparent",[o("text-color")]:i("color-base"),[o("text-color-hover")]:i("color-hover"),[o("text-color-active")]:i("color-active"),[o("bg-color")]:"transparent",[o("bg-color-hover")]:"transparent",[o("bg-color-active")]:"transparent",[`&:disabled, &${e.componentCls}-disabled`]:{background:"transparent",borderColor:"transparent"}},[`&${t}-variant-text`]:{[o("bg-color-hover")]:i("color-light"),[o("bg-color-active")]:i("color-light-active")}},{[`&${t}-variant-link`]:{[o("color-base")]:e.colorLink,[o("color-hover")]:e.colorLinkHover,[o("color-active")]:e.colorLinkActive,[o("bg-color-hover")]:e.linkHoverBg},[`&${t}-color-primary`]:{[o("color-base")]:e.colorPrimary,[o("color-hover")]:e.colorPrimaryHover,[o("color-active")]:e.colorPrimaryActive,[o("color-light")]:e.colorPrimaryBg,[o("color-light-hover")]:e.colorPrimaryBgHover,[o("color-light-active")]:e.colorPrimaryBorder,[o("shadow")]:e.primaryShadow,[`&${t}-variant-solid`]:{[o("text-color")]:e.primaryColor,[o("text-color-hover")]:i("text-color"),[o("text-color-active")]:i("text-color")}},[`&${t}-color-dangerous`]:{[o("color-base")]:e.colorError,[o("color-hover")]:e.colorErrorHover,[o("color-active")]:e.colorErrorActive,[o("color-light")]:e.colorErrorBg,[o("color-light-hover")]:e.colorErrorBgFilledHover,[o("color-light-active")]:e.colorErrorBgActive,[o("shadow")]:e.dangerShadow,[`&${t}-variant-solid`]:{[o("text-color")]:e.dangerColor,[o("text-color-hover")]:i("text-color"),[o("text-color-active")]:i("text-color")}},[`&${t}-color-default`]:{[o("solid-bg-color")]:e.colorBgSolid,[o("solid-bg-color-hover")]:e.colorBgSolidHover,[o("solid-bg-color-active")]:e.colorBgSolidActive,[o("color-base")]:e.defaultBorderColor,[o("color-hover")]:e.defaultHoverBorderColor,[o("color-active")]:e.defaultActiveBorderColor,[o("color-light")]:e.colorFillTertiary,[o("color-light-hover")]:e.colorFillSecondary,[o("color-light-active")]:e.colorFill,[o("text-color")]:e.defaultColor,[o("text-color-hover")]:e.defaultHoverColor,[o("text-color-active")]:e.defaultActiveColor,[o("shadow")]:e.defaultShadow,[`&${t}-variant-outlined`]:{[o("bg-color-disabled")]:e.defaultBgDisabled},[`&${t}-variant-solid`]:{[o("text-color")]:e.solidTextColor,[o("text-color-hover")]:i("text-color"),[o("text-color-active")]:i("text-color")},[`&${t}-variant-filled, &${t}-variant-text`]:{[o("text-color-hover")]:i("text-color"),[o("text-color-active")]:i("text-color")},[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[o("text-color")]:e.defaultColor,[o("text-color-hover")]:e.defaultHoverColor,[o("text-color-active")]:e.defaultActiveColor,[o("bg-color-container")]:e.defaultBg,[o("bg-color-hover")]:e.defaultHoverBg,[o("bg-color-active")]:e.defaultActiveBg},[`&${t}-variant-text`]:{[o("text-color")]:e.textTextColor,[o("text-color-hover")]:e.textTextHoverColor,[o("text-color-active")]:e.textTextActiveColor,[o("bg-color-hover")]:e.textHoverBg},[`&${t}-background-ghost`]:{[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[o("text-color")]:e.defaultGhostColor,[o("border-color")]:e.defaultGhostBorderColor}}}},Wa.map(a=>{const l=e[`${a}6`],u=e[`${a}1`],d=e[`${a}Hover`],m=e[`${a}2`],p=e[`${a}3`],g=e[`${a}Active`],b=e[`${a}ShadowColor`];return {[`&${t}-color-${a}`]:{[o("color-base")]:l,[o("color-hover")]:d,[o("color-active")]:g,[o("color-light")]:u,[o("color-light-hover")]:m,[o("color-light-active")]:p,[o("shadow")]:b}}}),{[`&:disabled, &${e.componentCls}-disabled`]:{cursor:"not-allowed",borderColor:e.colorBorderDisabled,background:i("bg-color-disabled"),color:e.colorTextDisabled,boxShadow:"none"}},{[`&${t}-background-ghost`]:{[o("bg-color")]:e.ghostBg,[o("bg-color-hover")]:e.ghostBg,[o("bg-color-active")]:e.ghostBg,[o("shadow")]:"none",[`&${t}-variant-outlined, &${t}-variant-dashed`]:{[o("bg-color-hover")]:e.ghostBg,[o("bg-color-active")]:e.ghostBg}}}]}},Boe=e=>{const{componentCls:t,iconCls:n,fontWeight:r,opacityLoading:o,motionDurationSlow:i,motionEaseInOut:a,iconGap:l,calc:u}=e;return {[t]:{outline:"none",position:"relative",display:"inline-flex",gap:l,alignItems:"center",justifyContent:"center",fontWeight:r,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",cursor:"pointer",transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,userSelect:"none",touchAction:"manipulation","&:disabled > *":{pointerEvents:"none"},[`${t}-icon > svg`]:Cu(),"> a":{color:"currentColor"},"&:not(:disabled)":$i(e),[`&${t}-two-chinese-chars::first-letter`]:{letterSpacing:"0.34em"},[`&${t}-two-chinese-chars > *:not(${n})`]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},[`&${t}-icon-only`]:{paddingInline:0,[`&${t}-compact-item`]:{flex:"none"}},[`&${t}-loading`]:{opacity:o,cursor:"default"},[`${t}-loading-icon`]:{transition:["width","opacity","margin"].map(d=>`${d} ${i} ${a}`).join(",")},[`&:not(${t}-icon-end)`]:{[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineEnd:u(l).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineEnd:0},"&-leave-start":{marginInlineEnd:0},"&-leave-active":{marginInlineEnd:u(l).mul(-1).equal()}}},"&-icon-end":{flexDirection:"row-reverse",[`${t}-loading-icon-motion`]:{"&-appear-start, &-enter-start":{marginInlineStart:u(l).mul(-1).equal()},"&-appear-active, &-enter-active":{marginInlineStart:0},"&-leave-start":{marginInlineStart:0},"&-leave-active":{marginInlineStart:u(l).mul(-1).equal()}}}}}},Loe=e=>({minWidth:e.controlHeight,paddingInline:0,borderRadius:"50%"}),yR=(e,t="")=>{const{componentCls:n,controlHeight:r,fontSize:o,borderRadius:i,buttonPaddingHorizontal:a,iconCls:l,buttonPaddingVertical:u,buttonIconOnlyFontSize:d}=e;return [{[t]:{fontSize:o,height:r,padding:`${oe(u)} ${oe(a)}`,borderRadius:i,[`&${n}-icon-only`]:{width:r,[l]:{fontSize:d}}}},{[`${n}${n}-circle${t}`]:Loe(e)},{[`${n}${n}-round${t}`]:{borderRadius:e.controlHeight,[`&:not(${n}-icon-only)`]:{paddingInline:e.buttonPaddingHorizontal}}}]},zoe=e=>{const t=Ft(e,{fontSize:e.contentFontSize});return yR(t,e.componentCls)},koe=e=>{const t=Ft(e,{controlHeight:e.controlHeightSM,fontSize:e.contentFontSizeSM,padding:e.paddingXS,buttonPaddingHorizontal:e.paddingInlineSM,buttonPaddingVertical:0,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.onlyIconSizeSM});return yR(t,`${e.componentCls}-sm`)},Foe=e=>{const t=Ft(e,{controlHeight:e.controlHeightLG,fontSize:e.contentFontSizeLG,buttonPaddingHorizontal:e.paddingInlineLG,buttonPaddingVertical:0,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.onlyIconSizeLG});return yR(t,`${e.componentCls}-lg`)},Hoe=e=>{const{componentCls:t}=e;return {[t]:{[`&${t}-block`]:{width:"100%"}}}},Voe=Wt("Button",e=>{const t=kk(e);return [Boe(t),zoe(t),koe(t),Foe(t),Hoe(t),_oe(t),Tre(t)]},Fk,{unitless:{fontWeight:true,contentLineHeight:true,contentLineHeightSM:true,contentLineHeightLG:true}});function joe(e,t,n,r){const{focusElCls:o,focus:i,borderElCls:a}=n,l=a?"> *":"",u=["hover",i?"focus":null,"active"].filter(Boolean).map(d=>`&:${d} ${l}`).join(",");return {[`&-item:not(${t}-last-item)`]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${r}-status-success)`]:{zIndex:2},"&-item":{[u]:{zIndex:3},...o?{[`&${o}`]:{zIndex:3}}:{},[`&[disabled] ${l}`]:{zIndex:0}}}}function Uoe(e,t,n){const{borderElCls:r}=n,o=r?`> ${r}`:"";return {[`&-item:not(${t}-first-item):not(${t}-last-item) ${o}`]:{borderRadius:0},[`&-item:not(${t}-last-item)${t}-first-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&-item:not(${t}-first-item)${t}-last-item`]:{[`& ${o}, &${e}-sm ${o}, &${e}-lg ${o}`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}function If(e,t={focus:true}){const{componentCls:n}=e,{componentCls:r}=t,o=r||n,i=`${o}-compact`;return {[i]:{...joe(e,i,t,o),...Uoe(o,i,t)}}}function Woe(e,t,n){return {[`&-item:not(${t}-last-item)`]:{marginBottom:e.calc(e.lineWidth).mul(-1).equal()},[`&-item:not(${n}-status-success)`]:{zIndex:2},"&-item":{"&:hover,&:focus,&:active":{zIndex:3},"&[disabled]":{zIndex:0}}}}function Goe(e,t){return {[`&-item:not(${t}-first-item):not(${t}-last-item)`]:{borderRadius:0},[`&-item${t}-first-item:not(${t}-last-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderEndEndRadius:0,borderEndStartRadius:0}},[`&-item${t}-last-item:not(${t}-first-item)`]:{[`&, &${e}-sm, &${e}-lg`]:{borderStartStartRadius:0,borderStartEndRadius:0}}}}function qoe(e){const t=`${e.componentCls}-compact-vertical`;return {[t]:{...Woe(e,t,e.componentCls),...Goe(e.componentCls,t)}}}const Koe=e=>{const{antCls:t,componentCls:n,lineWidth:r,calc:o,colorBgContainer:i}=e,a=`${n}-variant-solid:not([disabled])`,l=o(r).mul(-1).equal(),[u,d]=tr(t,"btn"),m=p=>({[`${n}-compact${p?"-vertical":""}-item`]:{[u("compact-connect-border-color")]:d("bg-color-hover"),[`&${a}`]:{transition:"none",[`& + ${a}:before`]:[{position:"absolute",backgroundColor:d("compact-connect-border-color"),content:'""'},p?{top:l,insetInline:l,height:r}:{insetBlock:l,insetInlineStart:l,width:r}],"&:hover:before":{display:"none"}}}});return [m(),m(true),{[`${a}${n}-color-default`]:{[u("compact-connect-border-color")]:`color-mix(in srgb, ${d("bg-color-hover")} 75%, ${i})`}}]},Yoe=Nf(["Button","compact"],e=>{const t=kk(e);return [If(t),qoe(t),Koe(t)]},Fk);function Xoe(e){if(typeof e=="object"&&e){let t=e?.delay;return t=!Number.isNaN(t)&&typeof t=="number"?t:0,{loading:t<=0,delay:t}}return {loading:!!e,delay:0}}const Qoe={default:["default","outlined"],primary:["primary","solid"],dashed:["default","dashed"],link:["link","link"],text:["default","text"]},Zoe=q.forwardRef((e,t)=>{const{_skipSemantic:n,loading:r=false,prefixCls:o,color:i,variant:a,type:l,danger:u=false,shape:d,size:m,disabled:p,className:g,rootClassName:b,children:y,icon:S,iconPosition:C,iconPlacement:w,ghost:$=false,block:M=false,htmlType:T="button",classNames:R,styles:I,style:N,autoInsertSpace:P,autoFocus:O,..._}=e,B=Qo(y),V=l||"default",{getPrefixCls:U,direction:G,autoInsertSpace:H,className:z,style:j,classNames:W,styles:Y,loadingIcon:Q,shape:D,color:L,variant:K}=jt("button"),J=d||D||"default",[ee,te]=f.useMemo(()=>{if(i&&a)return [i,a];if(l||u){const be=Qoe[V]||[];return u?["danger",be[1]]:be}return L&&K?[L,K]:["default","outlined"]},[i,a,l,u,L,K,V]),[re,ie]=f.useMemo(()=>$&&te==="solid"?[ee,"outlined"]:[ee,te],[ee,te,$]),de=re==="danger",ne=de?"dangerous":re,ce=P??H??true,fe=U("btn",o),[se,Me]=Voe(fe),ae=f.useContext(no),pe=p??ae,Ce=f.useContext(Mk),xe=f.useMemo(()=>Xoe(r),[r]),[Ae,Xe]=f.useState(xe.loading),[Ne,ue]=f.useState(false),ge=f.useRef(null),Pe=Bs(t,ge),je=B.length===1&&!S&&!kx(ie),qe=f.useRef(true);q.useEffect(()=>(qe.current=false,()=>{qe.current=true;}),[]),An(()=>{let be=null;xe.delay>0?be=setTimeout(()=>{be=null,Xe(true);},xe.delay):Xe(xe.loading);function Se(){be&&(clearTimeout(be),be=null);}return Se},[xe.delay,xe.loading]),f.useEffect(()=>{if(!ge.current||!ce)return;const be=ge.current.textContent||"";je&&G2(be)?Ne||ue(true):Ne&&ue(false);}),f.useEffect(()=>{O&&ge.current&&ge.current.focus();},[]);const Ue=q.useCallback(be=>{if(Ae||pe){be.preventDefault();return}e.onClick?.((be));},[e.onClick,Ae,pe]),{compactSize:et,compactItemClassnames:rt}=ks(fe,G),Ke={large:"lg",small:"sm",middle:void 0,medium:void 0},_e=so(be=>m??et??Ce??be),We=_e?Ke[_e]??"":"",Ze=Ae?"loading":S,Be=w??C??"start",Oe=Ln(_,["navigate"]),lt={...e,type:V,color:re,variant:ie,danger:de,shape:J,size:_e,disabled:pe,loading:Ae,iconPlacement:Be},[It,mt]=Kt([n?void 0:W,R],[n?void 0:Y,I],{props:lt}),Bt=X(fe,se,Me,{[`${fe}-${J}`]:J!=="default"&&J!=="square"&&J,[`${fe}-${V}`]:V,[`${fe}-dangerous`]:u,[`${fe}-color-${ne}`]:ne,[`${fe}-variant-${ie}`]:ie,[`${fe}-${We}`]:We,[`${fe}-icon-only`]:!y&&y!==0&&!!Ze,[`${fe}-background-ghost`]:$&&!kx(ie),[`${fe}-loading`]:Ae,[`${fe}-two-chinese-chars`]:Ne&&ce&&!Ae,[`${fe}-block`]:M,[`${fe}-rtl`]:G==="rtl",[`${fe}-icon-end`]:Be==="end"},rt,g,b,z,It.root),xt={...mt.root,...j,...N},Tt={className:It.icon,style:mt.icon},ut=be=>q.createElement(Rk,{prefixCls:fe,...Tt},be),dt=q.createElement(Rre,{existIcon:!!S,prefixCls:fe,loading:Ae,mount:qe.current,...Tt}),gt=r&&typeof r=="object"&&r.icon||Q;let Fe;S&&!Ae?Fe=ut(S):r&>?Fe=ut(gt):Fe=dt;const Qe=Jr(y)?Mre(y,je&&ce,mt.content,It.content):null;if(Oe.href!==void 0)return q.createElement("a",{...Oe,className:X(Bt,{[`${fe}-disabled`]:pe}),href:pe?void 0:Oe.href,style:xt,onClick:Ue,ref:Pe,tabIndex:pe?-1:0,"aria-disabled":pe},Fe,Qe);let ye=q.createElement("button",{..._,type:T,className:Bt,style:xt,onClick:Ue,disabled:pe,ref:Pe},Fe,Qe,rt&&q.createElement(Yoe,{prefixCls:fe}));return kx(ie)||(ye=q.createElement(Qp,{component:"Button",disabled:Ae},ye)),ye}),st=Zoe;st.Group=$re;st.__ANT_BUTTON=true;const jx=e=>typeof e?.then=="function",SR=e=>{const{type:t,children:n,prefixCls:r,buttonProps:o,close:i,autoFocus:a,emitEvent:l,isSilent:u,quitOnNullishReturnValue:d,actionFn:m}=e,p=f.useRef(false),g=f.useRef(null),[b,y]=R0(false),S=(...$)=>{i?.(...$);};f.useEffect(()=>{let $=null;return a&&($=setTimeout(()=>{g.current?.focus({preventScroll:true});})),()=>{$&&clearTimeout($);}},[a]);const C=$=>{jx($)&&(y(true),$.then((...M)=>{y(false,true),S.apply(void 0,M),p.current=false;},M=>{if(y(false,true),p.current=false,!u?.())return Promise.reject(M)}));},w=$=>{if(p.current)return;if(p.current=true,!m){S();return}let M;if(l){if(M=m($),d&&!jx(M)){p.current=false,S($);return}}else if(m.length)M=m(i),p.current=false;else if(M=m(),!jx(M)){S();return}C(M);};return f.createElement(st,{...cR(t),onClick:w,loading:b,prefixCls:r,...o,ref:g},n)},Jp=q.createContext({}),{Provider:Hk}=Jp,iO=()=>{const{autoFocusButton:e,cancelButtonProps:t,cancelTextLocale:n,isSilent:r,mergedOkCancel:o,rootPrefixCls:i,close:a,onCancel:l,onConfirm:u,onClose:d}=f.useContext(Jp);return o?q.createElement(SR,{isSilent:r,actionFn:l,close:(...m)=>{a?.(...m),u?.(false),d?.();},autoFocus:e==="cancel",buttonProps:t,prefixCls:`${i}-btn`},n):null},aO=()=>{const{autoFocusButton:e,close:t,isSilent:n,okButtonProps:r,rootPrefixCls:o,okTextLocale:i,okType:a,onConfirm:l,onOk:u,onClose:d}=f.useContext(Jp);return q.createElement(SR,{isSilent:n,type:a||"primary",actionFn:u,close:(...m)=>{t?.(...m),l?.(true),d?.();},autoFocus:e==="ok",buttonProps:r,prefixCls:`${o}-btn`},i)},Vk=f.createContext({});function sO(e,t,n){let r=t;return !r&&n&&(r=`${e}-${n}`),r}function lO(e,t){let n=e[`page${t?"Y":"X"}Offset`];const r=`scroll${t?"Top":"Left"}`;if(typeof n!="number"){const o=e.document;n=o.documentElement[r],typeof n!="number"&&(n=o.body[r]);}return n}function Joe(e){const t=e.getBoundingClientRect(),n={left:t.left,top:t.top},r=e.ownerDocument,o=r.defaultView||r.parentWindow;return n.left+=lO(o),n.top+=lO(o,true),n}function cO(e,t=false){if(oR(e)){const n=e.nodeName.toLowerCase(),r=["input","select","textarea","button"].includes(n)||e.isContentEditable||n==="a"&&!!e.getAttribute("href"),o=e.getAttribute("tabindex"),i=Number(o);let a=null;return o&&!Number.isNaN(i)?a=i:r&&a===null&&(a=0),r&&e.disabled&&(a=null),a!==null&&(a>=0||t&&a<0)}return false}function CR(e,t=false){const n=[...e.querySelectorAll("*")].filter(r=>cO(r,t));return cO(e,t)&&n.unshift(e),n}function xR(e,t){if(!e)return;e.focus(t);const{cursor:n}=t||{};if(n&&(e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement)){const r=e.value.length;switch(n){case "start":e.setSelectionRange(0,0);break;case "end":e.setSelectionRange(r,r);break;default:e.setSelectionRange(0,r);}}}let qd=null,$l=[];const K2=new Map,wR=new Map;function $R(){return $l[$l.length-1]}function eie(e){const t=$R();if(e&&t){let n;for(const[o,i]of K2.entries())if(i===t){n=o;break}const r=wR.get(n);return !!r&&(r===e||r.contains(e))}return false}function tie(e){const{activeElement:t}=document;return e===t||e.contains(t)}function Ux(){const e=$R(),{activeElement:t}=document;if(!eie(t))if(e&&!tie(e)){const n=CR(e);(n.includes(qd)?qd:n[0])?.focus({preventScroll:true});}else qd=t;}function uO(e){if(e.key==="Tab"){const{activeElement:t}=document,n=$R(),r=CR(n),o=r[r.length-1];e.shiftKey&&t===r[0]?qd=o:!e.shiftKey&&t===o&&(qd=r[0]);}}function nie(e,t){return e&&(K2.set(t,e),$l=$l.filter(n=>n!==e),$l.push(e),window.addEventListener("focusin",Ux),window.addEventListener("keydown",uO,true),Ux()),()=>{qd=null,$l=$l.filter(n=>n!==e),K2.delete(t),wR.delete(t),$l.length===0&&(window.removeEventListener("focusin",Ux),window.removeEventListener("keydown",uO,true));}}function rie(e,t){const n=zs();return f.useEffect(()=>{if(e){const o=t();if(o)return nie(o,n)}},[e,n]),[o=>{o&&wR.set(n,o);}]}const oie=f.memo(({children:e})=>e,(e,{shouldUpdate:t})=>!t);function k0(){return k0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},k0.apply(this,arguments)}const jk=q.forwardRef((e,t)=>{const{prefixCls:n,className:r,style:o,title:i,ariaId:a,footer:l,closable:u,closeIcon:d,onClose:m,children:p,bodyStyle:g,bodyProps:b,modalRender:y,onMouseDown:S,onMouseUp:C,holderRef:w,visible:$,forceRender:M,width:T,height:R,classNames:I,styles:N,isFixedPos:P,focusTrap:O}=e,{panel:_}=q.useContext(Vk),B=f.useRef(null),V=Bs(w,_,B),[U]=rie($&&P&&O!==false,()=>B.current);q.useImperativeHandle(t,()=>({focus:()=>{B.current?.focus({preventScroll:true});}}));const G={};T!==void 0&&(G.width=T),R!==void 0&&(G.height=R);const H=l?q.createElement("div",{className:X(`${n}-footer`,I?.footer),style:{...N?.footer}},l):null,z=i?q.createElement("div",{className:X(`${n}-header`,I?.header),style:{...N?.header}},q.createElement("div",{className:X(`${n}-title`,I?.title),id:a,style:{...N?.title}},i)):null,j=f.useMemo(()=>typeof u=="object"&&u!==null?u:u?{closeIcon:d??q.createElement("span",{className:`${n}-close-x`})}:{},[u,d,n]),W=yo(j,true),Y=typeof u=="object"&&u.disabled,Q=u?q.createElement("button",k0({type:"button",onClick:m,"aria-label":"Close"},W,{className:`${n}-close`,disabled:Y}),j.closeIcon):null,D=q.createElement("div",{className:X(`${n}-container`,I?.container),style:N?.container},Q,z,q.createElement("div",k0({className:X(`${n}-body`,I?.body),style:{...g,...N?.body}},b),p),H);return q.createElement("div",{key:"dialog-element",role:"dialog","aria-labelledby":i?a:null,"aria-modal":"true",ref:V,style:{...o,...G},className:X(n,r),onMouseDown:S,onMouseUp:C,tabIndex:-1,onFocus:L=>{U(L.target);}},q.createElement(oie,{shouldUpdate:$||M},y?y(D):D))});function Y2(){return Y2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Y2.apply(this,arguments)}const iie=f.forwardRef((e,t)=>{const{prefixCls:n,title:r,style:o,className:i,visible:a,forceRender:l,destroyOnHidden:u,motionName:d,ariaId:m,onVisibleChanged:p,mousePosition:g}=e,b=f.useRef(null),y=f.useRef(null);f.useImperativeHandle(t,()=>({...y.current,inMotion:b.current.inMotion,enableMotion:b.current.enableMotion}));const[S,C]=f.useState(),w={};S&&(w.transformOrigin=S);function $(){if(!b.current?.nativeElement)return;const M=Joe(b.current.nativeElement);C(g&&(g.x||g.y)?`${g.x-M.left}px ${g.y-M.top}px`:"");}return f.createElement(Co,{visible:a,onVisibleChanged:p,onAppearPrepare:$,onEnterPrepare:$,forceRender:l,motionName:d,removeOnLeave:u,ref:b},({className:M,style:T},R)=>f.createElement(jk,Y2({},e,{ref:y,title:r,ariaId:m,prefixCls:n,holderRef:R,style:{...T,...o,...w},className:X(i,M)})))});function X2(){return X2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},X2.apply(this,arguments)}const aie=e=>{const{prefixCls:t,style:n,visible:r,maskProps:o,motionName:i,className:a}=e;return f.createElement(Co,{key:"mask",visible:r,motionName:i,leavedClassName:`${t}-mask-hidden`},({className:l,style:u},d)=>f.createElement("div",X2({ref:d,style:{...u,...n},className:X(`${t}-mask`,l,a)},o)))};function Oh(){return Oh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Oh.apply(this,arguments)}const sie=e=>{const{prefixCls:t="rc-dialog",zIndex:n,visible:r=false,focusTriggerAfterClose:o=true,wrapStyle:i,wrapClassName:a,wrapProps:l,onClose:u,afterOpenChange:d,afterClose:m,transitionName:p,animation:g,closable:b=true,mask:y=true,maskTransitionName:S,maskAnimation:C,maskClosable:w=true,maskStyle:$,maskProps:M,rootClassName:T,rootStyle:R,classNames:I,styles:N}=e,P=f.useRef(null),O=f.useRef(null),_=f.useRef(null),[B,V]=f.useState(r),[U,G]=f.useState(false),H=zs();function z(){i2(O.current,document.activeElement)||(P.current=document.activeElement);}function j(){i2(O.current,document.activeElement)||_.current?.focus();}function W(){if(V(false),y&&P.current&&o){try{P.current.focus({preventScroll:!0});}catch{}P.current=null;}B&&m?.();}function Y(ee){ee?j():W(),d?.(ee);}function Q(ee){u?.(ee);}const D=f.useRef(false);let L=null;w&&(L=ee=>{O.current===ee.target&&D.current&&Q(ee);});function K(ee){D.current=ee.target===O.current;}f.useEffect(()=>{if(r){if(D.current=false,V(true),z(),O.current){const ee=getComputedStyle(O.current);G(ee.position==="fixed");}}else B&&_.current.enableMotion()&&!_.current.inMotion()&&W();},[r]);const J={zIndex:n,...i,...N?.wrapper,display:B?null:"none"};return f.createElement("div",Oh({className:X(`${t}-root`,T),style:R},yo(e,{data:true})),f.createElement(aie,{prefixCls:t,visible:y&&r,motionName:sO(t,S,C),style:{zIndex:n,...$,...N?.mask},maskProps:M,className:I?.mask}),f.createElement("div",Oh({className:X(`${t}-wrap`,a,I?.wrapper),ref:O,onClick:L,onMouseDown:K,style:J},l),f.createElement(iie,Oh({},e,{isFixedPos:U,ref:_,closable:b,ariaId:H,prefixCls:t,visible:r&&B,onClose:Q,onVisibleChanged:Y,motionName:sO(t,p,g)}))))};function Q2(){return Q2=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Q2.apply(this,arguments)}const lie=e=>{const{visible:t,getContainer:n,forceRender:r,destroyOnHidden:o=false,afterClose:i,closable:a,panelRef:l,keyboard:u=true,onClose:d}=e,[m,p]=f.useState(t),g=f.useMemo(()=>({panel:l}),[l]),b=({top:y,event:S})=>{if(y&&u){S.stopPropagation(),d?.(S);return}};return f.useEffect(()=>{t&&p(true);},[t]),!r&&o&&!m?null:f.createElement(Vk.Provider,{value:g},f.createElement(Zy,{open:t||r||m,onEsc:b,autoDestroy:false,getContainer:n,autoLock:t||m},f.createElement(sie,Q2({},e,{destroyOnHidden:o,afterClose:()=>{const y=a&&typeof a=="object"?a:{},{afterClose:S}=y||{};S?.(),i?.(),p(false);}}))))},Fc="RC_FORM_INTERNAL_HOOKS",_n=()=>{Er(false,"Can not find FormContext. Please make sure you wrap Field under Form.");},uf=f.createContext({getFieldValue:_n,getFieldsValue:_n,getFieldError:_n,getFieldWarning:_n,getFieldsError:_n,isFieldsTouched:_n,isFieldTouched:_n,isFieldValidating:_n,isFieldsValidating:_n,resetFields:_n,setFields:_n,setFieldValue:_n,setFieldsValue:_n,validateFields:_n,submit:_n,getInternalHooks:()=>(_n(),{dispatch:_n,initEntityValue:_n,registerField:_n,useSubscribe:_n,setInitialValues:_n,destroyForm:_n,setCallbacks:_n,registerWatch:_n,getFields:_n,setValidateMessages:_n,setPreserve:_n,getInitialValue:_n})}),F0=f.createContext(null);function Z2(e){return e==null?[]:Array.isArray(e)?e:[e]}function cie(e){return e&&!!e._init}function J2(){return {default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",tel:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var t=JSON.parse(JSON.stringify(this));return t.clone=this.clone,t}}}var eE=J2();function uie(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function die(e,t,n){if(WM())return Reflect.construct.apply(null,arguments);var r=[null];r.push.apply(r,t);var o=new(e.bind.apply(e,r));return n&&sp(o,n.prototype),o}function tE(e){var t=typeof Map=="function"?new Map:void 0;return tE=function(r){if(r===null||!uie(r))return r;if(typeof r!="function")throw new TypeError("Super expression must either be null or a function");if(t!==void 0){if(t.has(r))return t.get(r);t.set(r,o);}function o(){return die(r,arguments,lp(this).constructor)}return o.prototype=Object.create(r.prototype,{constructor:{value:o,enumerable:false,writable:true,configurable:true}}),sp(o,r)},tE(e)}var fie=/%[sdj%]/g,mie=function(){};function nE(e){if(!e||!e.length)return null;var t={};return e.forEach(function(n){var r=n.field;t[r]=t[r]||[],t[r].push(n);}),t}function bi(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=0,i=n.length;if(typeof e=="function")return e.apply(null,n);if(typeof e=="string"){var a=e.replace(fie,function(l){if(l==="%%")return "%";if(o>=i)return l;switch(l){case "%s":return String(n[o++]);case "%d":return Number(n[o++]);case "%j":try{return JSON.stringify(n[o++])}catch{return "[Circular]"}break;default:return l}});return a}return e}function hie(e){return e==="string"||e==="url"||e==="hex"||e==="email"||e==="date"||e==="pattern"||e==="tel"}function Pr(e,t){return !!(e==null||t==="array"&&Array.isArray(e)&&!e.length||hie(t)&&typeof e=="string"&&!e)}function pie(e,t,n){var r=[],o=0,i=e.length;function a(l){r.push.apply(r,qt(l||[])),o++,o===i&&n(r);}e.forEach(function(l){t(l,a);});}function dO(e,t,n){var r=0,o=e.length;function i(a){if(a&&a.length){n(a);return}var l=r;r=r+1,l<o?t(e[l],i):n([]);}i([]);}function gie(e){var t=[];return Object.keys(e).forEach(function(n){t.push.apply(t,qt(e[n]||[]));}),t}var fO=(function(e){yz(n,e);var t=Sz(n);function n(r,o){var i;return Xi(this,n),i=t.call(this,"Async Validation Error"),Ct(Wd(i),"errors",void 0),Ct(Wd(i),"fields",void 0),i.errors=r,i.fields=o,i}return Qi(n)})(tE(Error));function vie(e,t,n,r,o){if(t.first){var i=new Promise(function(g,b){var y=function(w){return r(w),w.length?b(new fO(w,nE(w))):g(o)},S=gie(e);dO(S,n,y);});return i.catch(function(g){return g}),i}var a=t.firstFields===true?Object.keys(e):t.firstFields||[],l=Object.keys(e),u=l.length,d=0,m=[],p=new Promise(function(g,b){var y=function(C){if(m.push.apply(m,C),d++,d===u)return r(m),m.length?b(new fO(m,nE(m))):g(o)};l.length||(r(m),g(o)),l.forEach(function(S){var C=e[S];a.indexOf(S)!==-1?dO(C,n,y):pie(C,n,y);});});return p.catch(function(g){return g}),p}function bie(e){return !!(e&&e.message!==void 0)}function yie(e,t){for(var n=e,r=0;r<t.length;r++){if(n==null)return n;n=n[t[r]];}return n}function mO(e,t){return function(n){var r;return e.fullFields?r=yie(t,e.fullFields):r=t[n.field||e.fullField],bie(n)?(n.field=n.field||e.fullField,n.fieldValue=r,n):{message:typeof n=="function"?n():n,fieldValue:r,field:n.field||e.fullField}}}function hO(e,t){if(t){for(var n in t)if(t.hasOwnProperty(n)){var r=t[n];$r(r)==="object"&&$r(e[n])==="object"?e[n]=nr(nr({},e[n]),r):e[n]=r;}}return e}var vd="enum",Sie=function(t,n,r,o,i){t[vd]=Array.isArray(t[vd])?t[vd]:[],t[vd].indexOf(n)===-1&&o.push(bi(i.messages[vd],t.fullField,t[vd].join(", ")));},Cie=function(t,n,r,o,i){if(t.pattern){if(t.pattern instanceof RegExp)t.pattern.lastIndex=0,t.pattern.test(n)||o.push(bi(i.messages.pattern.mismatch,t.fullField,n,t.pattern));else if(typeof t.pattern=="string"){var a=new RegExp(t.pattern);a.test(n)||o.push(bi(i.messages.pattern.mismatch,t.fullField,n,t.pattern));}}},xie=function(t,n,r,o,i){var a=typeof t.len=="number",l=typeof t.min=="number",u=typeof t.max=="number",d=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,m=n,p=null,g=typeof n=="number",b=typeof n=="string",y=Array.isArray(n);if(g?p="number":b?p="string":y&&(p="array"),!p)return false;y&&(m=n.length),b&&(m=n.replace(d,"_").length),a?m!==t.len&&o.push(bi(i.messages[p].len,t.fullField,t.len)):l&&!u&&m<t.min?o.push(bi(i.messages[p].min,t.fullField,t.min)):u&&!l&&m>t.max?o.push(bi(i.messages[p].max,t.fullField,t.max)):l&&u&&(m<t.min||m>t.max)&&o.push(bi(i.messages[p].range,t.fullField,t.min,t.max));},Uk=function(t,n,r,o,i,a){t.required&&(!r.hasOwnProperty(t.field)||Pr(n,a||t.type))&&o.push(bi(i.messages.required,t.fullField));},ib;const wie=(function(){if(ib)return ib;var e="[a-fA-F\\d:]",t=function(I){return I&&I.includeBoundaries?"(?:(?<=\\s|^)(?=".concat(e,")|(?<=").concat(e,")(?=\\s|$))"):""},n="(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}",r="[a-fA-F\\d]{1,4}",o=["(?:".concat(r,":){7}(?:").concat(r,"|:)"),"(?:".concat(r,":){6}(?:").concat(n,"|:").concat(r,"|:)"),"(?:".concat(r,":){5}(?::").concat(n,"|(?::").concat(r,"){1,2}|:)"),"(?:".concat(r,":){4}(?:(?::").concat(r,"){0,1}:").concat(n,"|(?::").concat(r,"){1,3}|:)"),"(?:".concat(r,":){3}(?:(?::").concat(r,"){0,2}:").concat(n,"|(?::").concat(r,"){1,4}|:)"),"(?:".concat(r,":){2}(?:(?::").concat(r,"){0,3}:").concat(n,"|(?::").concat(r,"){1,5}|:)"),"(?:".concat(r,":){1}(?:(?::").concat(r,"){0,4}:").concat(n,"|(?::").concat(r,"){1,6}|:)"),"(?::(?:(?::".concat(r,"){0,5}:").concat(n,"|(?::").concat(r,"){1,7}|:))")],i="(?:%[0-9a-zA-Z]{1,})?",a="(?:".concat(o.join("|"),")").concat(i),l=new RegExp("(?:^".concat(n,"$)|(?:^").concat(a,"$)")),u=new RegExp("^".concat(n,"$")),d=new RegExp("^".concat(a,"$")),m=function(I){return I&&I.exact?l:new RegExp("(?:".concat(t(I)).concat(n).concat(t(I),")|(?:").concat(t(I)).concat(a).concat(t(I),")"),"g")};m.v4=function(R){return R&&R.exact?u:new RegExp("".concat(t(R)).concat(n).concat(t(R)),"g")},m.v6=function(R){return R&&R.exact?d:new RegExp("".concat(t(R)).concat(a).concat(t(R)),"g")};var p="(?:(?:[a-z]+:)?//)",g="(?:\\S+(?::\\S*)?@)?",b=m.v4().source,y=m.v6().source,S="(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)",C="(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*",w="(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))",$="(?::\\d{2,5})?",M='(?:[/?#][^\\s"]*)?',T="(?:".concat(p,"|www\\.)").concat(g,"(?:localhost|").concat(b,"|").concat(y,"|").concat(S).concat(C).concat(w,")").concat($).concat(M);return ib=new RegExp("(?:^".concat(T,"$)"),"i"),ib});var Wx={email:/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,tel:/^(\+[0-9]{1,3}[-\s\u2011]?)?(\([0-9]{1,4}\)[-\s\u2011]?)?([0-9]+[-\s\u2011]?)*[0-9]+$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},Sh={integer:function(t){return Sh.number(t)&&parseInt(t,10)===t},float:function(t){return Sh.number(t)&&!Sh.integer(t)},array:function(t){return Array.isArray(t)},regexp:function(t){if(t instanceof RegExp)return true;try{return !!new RegExp(t)}catch{return false}},date:function(t){return typeof t.getTime=="function"&&typeof t.getMonth=="function"&&typeof t.getYear=="function"&&!isNaN(t.getTime())},number:function(t){return isNaN(t)?false:typeof t=="number"},object:function(t){return $r(t)==="object"&&!Sh.array(t)},method:function(t){return typeof t=="function"},email:function(t){return typeof t=="string"&&t.length<=320&&!!t.match(Wx.email)},tel:function(t){return typeof t=="string"&&t.length<=32&&!!t.match(Wx.tel)},url:function(t){return typeof t=="string"&&t.length<=2048&&!!t.match(wie())},hex:function(t){return typeof t=="string"&&!!t.match(Wx.hex)}},$ie=function(t,n,r,o,i){if(t.required&&n===void 0){Uk(t,n,r,o,i);return}var a=["integer","float","array","regexp","object","method","email","tel","number","date","url","hex"],l=t.type;a.indexOf(l)>-1?Sh[l](n)||o.push(bi(i.messages.types[l],t.fullField,t.type)):l&&$r(n)!==t.type&&o.push(bi(i.messages.types[l],t.fullField,t.type));},Eie=function(t,n,r,o,i){(/^\s+$/.test(n)||n==="")&&o.push(bi(i.messages.whitespace,t.fullField));};const sn={required:Uk,whitespace:Eie,type:$ie,range:xie,enum:Sie,pattern:Cie};var Mie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i);}r(a);},Rie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(n==null&&!t.required)return r();sn.required(t,n,o,a,i,"array"),n!=null&&(sn.type(t,n,o,a,i),sn.range(t,n,o,a,i));}r(a);},Tie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&sn.type(t,n,o,a,i);}r(a);},Aie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n,"date")&&!t.required)return r();if(sn.required(t,n,o,a,i),!Pr(n,"date")){var u;n instanceof Date?u=n:u=new Date(n),sn.type(t,u,o,a,i),u&&sn.range(t,u.getTime(),o,a,i);}}r(a);},Nie="enum",Pie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&sn[Nie](t,n,o,a,i);}r(a);},Iie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&(sn.type(t,n,o,a,i),sn.range(t,n,o,a,i));}r(a);},Oie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&(sn.type(t,n,o,a,i),sn.range(t,n,o,a,i));}r(a);},Die=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&sn.type(t,n,o,a,i);}r(a);},_ie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(n===""&&(n=void 0),Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&(sn.type(t,n,o,a,i),sn.range(t,n,o,a,i));}r(a);},Bie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),n!==void 0&&sn.type(t,n,o,a,i);}r(a);},Lie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n,"string")&&!t.required)return r();sn.required(t,n,o,a,i),Pr(n,"string")||sn.pattern(t,n,o,a,i);}r(a);},zie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n)&&!t.required)return r();sn.required(t,n,o,a,i),Pr(n)||sn.type(t,n,o,a,i);}r(a);},kie=function(t,n,r,o,i){var a=[],l=Array.isArray(n)?"array":$r(n);sn.required(t,n,o,a,i,l),r(a);},Fie=function(t,n,r,o,i){var a=[],l=t.required||!t.required&&o.hasOwnProperty(t.field);if(l){if(Pr(n,"string")&&!t.required)return r();sn.required(t,n,o,a,i,"string"),Pr(n,"string")||(sn.type(t,n,o,a,i),sn.range(t,n,o,a,i),sn.pattern(t,n,o,a,i),t.whitespace===true&&sn.whitespace(t,n,o,a,i));}r(a);},ab=function(t,n,r,o,i){var a=t.type,l=[],u=t.required||!t.required&&o.hasOwnProperty(t.field);if(u){if(Pr(n,a)&&!t.required)return r();sn.required(t,n,o,l,i,a),Pr(n,a)||sn.type(t,n,o,l,i);}r(l);};const Dh={string:Fie,method:Die,number:_ie,boolean:Tie,regexp:zie,integer:Oie,float:Iie,array:Rie,object:Bie,enum:Pie,pattern:Lie,date:Aie,url:ab,hex:ab,email:ab,tel:ab,required:kie,any:Mie};var eg=(function(){function e(t){Xi(this,e),Ct(this,"rules",null),Ct(this,"_messages",eE),this.define(t);}return Qi(e,[{key:"define",value:function(n){var r=this;if(!n)throw new Error("Cannot configure a schema with no rules");if($r(n)!=="object"||Array.isArray(n))throw new Error("Rules must be an object");this.rules={},Object.keys(n).forEach(function(o){var i=n[o];r.rules[o]=Array.isArray(i)?i:[i];});}},{key:"messages",value:function(n){return n&&(this._messages=hO(J2(),n)),this._messages}},{key:"validate",value:function(n){var r=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(){},a=n,l=o,u=i;if(typeof l=="function"&&(u=l,l={}),!this.rules||Object.keys(this.rules).length===0)return u&&u(null,a),Promise.resolve(a);function d(y){var S=[],C={};function w(M){if(Array.isArray(M)){var T;S=(T=S).concat.apply(T,qt(M));}else S.push(M);}for(var $=0;$<y.length;$++)w(y[$]);S.length?(C=nE(S),u(S,C)):u(null,a);}if(l.messages){var m=this.messages();m===eE&&(m=J2()),hO(m,l.messages),l.messages=m;}else l.messages=this.messages();var p={},g=l.keys||Object.keys(this.rules);g.forEach(function(y){var S=r.rules[y],C=a[y];S.forEach(function(w){var $=w;typeof $.transform=="function"&&(a===n&&(a=nr({},a)),C=a[y]=$.transform(C),C!=null&&($.type=$.type||(Array.isArray(C)?"array":$r(C)))),typeof $=="function"?$={validator:$}:$=nr({},$),$.validator=r.getValidationMethod($),$.validator&&($.field=y,$.fullField=$.fullField||y,$.type=r.getType($),p[y]=p[y]||[],p[y].push({rule:$,value:C,source:a,field:y}));});});var b={};return vie(p,l,function(y,S){var C=y.rule,w=(C.type==="object"||C.type==="array")&&($r(C.fields)==="object"||$r(C.defaultField)==="object");w=w&&(C.required||!C.required&&y.value),C.field=y.field;function $(N,P){return nr(nr({},P),{},{fullField:"".concat(C.fullField,".").concat(N),fullFields:C.fullFields?[].concat(qt(C.fullFields),[N]):[N]})}function M(){var N=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],P=Array.isArray(N)?N:[N];!l.suppressWarning&&P.length&&e.warning("async-validator:",P),P.length&&C.message!==void 0&&C.message!==null&&(P=[].concat(C.message));var O=P.map(mO(C,a));if(l.first&&O.length)return b[C.field]=1,S(O);if(!w)S(O);else {if(C.required&&!y.value)return C.message!==void 0?O=[].concat(C.message).map(mO(C,a)):l.error&&(O=[l.error(C,bi(l.messages.required,C.field))]),S(O);var _={};C.defaultField&&Object.keys(y.value).map(function(U){_[U]=C.defaultField;}),_=nr(nr({},_),y.rule.fields);var B={};Object.keys(_).forEach(function(U){var G=_[U],H=Array.isArray(G)?G:[G];B[U]=H.map($.bind(null,U));});var V=new e(B);V.messages(l.messages),y.rule.options&&(y.rule.options.messages=l.messages,y.rule.options.error=l.error),V.validate(y.value,y.rule.options||l,function(U){var G=[];O&&O.length&&G.push.apply(G,qt(O)),U&&U.length&&G.push.apply(G,qt(U)),S(G.length?G:null);});}}var T;if(C.asyncValidator)T=C.asyncValidator(C,y.value,M,y.source,l);else if(C.validator){try{T=C.validator(C,y.value,M,y.source,l);}catch(N){var R,I;(R=(I=console).error)===null||R===void 0||R.call(I,N),l.suppressValidatorError||setTimeout(function(){throw N},0),M(N.message);}T===true?M():T===false?M(typeof C.message=="function"?C.message(C.fullField||C.field):C.message||"".concat(C.fullField||C.field," fails")):T instanceof Array?M(T):T instanceof Error&&M(T.message);}T&&T.then&&T.then(function(){return M()},function(N){return M(N)});},function(y){d(y);},a)}},{key:"getType",value:function(n){if(n.type===void 0&&n.pattern instanceof RegExp&&(n.type="pattern"),typeof n.validator!="function"&&n.type&&!Dh.hasOwnProperty(n.type))throw new Error(bi("Unknown rule type %s",n.type));return n.type||"string"}},{key:"getValidationMethod",value:function(n){if(typeof n.validator=="function")return n.validator;var r=Object.keys(n),o=r.indexOf("message");return o!==-1&&r.splice(o,1),r.length===1&&r[0]==="required"?Dh.required:Dh[this.getType(n)]||void 0}}]),e})();Ct(eg,"register",function(t,n){if(typeof n!="function")throw new Error("Cannot register a validator by type, validator is not a function");Dh[t]=n;});Ct(eg,"warning",mie);Ct(eg,"messages",eE);Ct(eg,"validators",Dh);const jo="'${name}' is not a valid ${type}",Wk={default:"Validation error on field '${name}'",required:"'${name}' is required",enum:"'${name}' must be one of [${enum}]",whitespace:"'${name}' cannot be empty",date:{format:"'${name}' is invalid for format date",parse:"'${name}' could not be parsed as date",invalid:"'${name}' is invalid date"},types:{string:jo,method:jo,array:jo,object:jo,number:jo,date:jo,boolean:jo,integer:jo,float:jo,regexp:jo,email:jo,tel:jo,url:jo,hex:jo},string:{len:"'${name}' must be exactly ${len} characters",min:"'${name}' must be at least ${min} characters",max:"'${name}' cannot be longer than ${max} characters",range:"'${name}' must be between ${min} and ${max} characters"},number:{len:"'${name}' must equal ${len}",min:"'${name}' cannot be less than ${min}",max:"'${name}' cannot be greater than ${max}",range:"'${name}' must be between ${min} and ${max}"},array:{len:"'${name}' must be exactly ${len} in length",min:"'${name}' cannot be less than ${min} in length",max:"'${name}' cannot be greater than ${max} in length",range:"'${name}' must be between ${min} and ${max} in length"},pattern:{mismatch:"'${name}' does not match pattern ${pattern}"}},pO=eg;function Hie(e,t){return e.replace(/\\?\$\{\w+\}/g,n=>{if(n.startsWith("\\"))return n.slice(1);const r=n.slice(2,-1);return t[r]})}const gO="CODE_LOGIC_ERROR";async function rE(e,t,n,r,o){const i={...n};if(delete i.ruleIndex,pO.warning=()=>{},i.validator){const g=i.validator;i.validator=(...b)=>{try{return g(...b)}catch(y){return console.error(y),Promise.reject(gO)}};}let a=null;i&&i.type==="array"&&i.defaultField&&(a=i.defaultField,delete i.defaultField);const l=new pO({[e]:[i]}),u=Pd(Wk,r.validateMessages);l.messages(u);let d=[];try{await Promise.resolve(l.validate({[e]:t},{...r}));}catch(g){g.errors&&(d=g.errors.map(({message:b},y)=>{const S=b===gO?u.default:b;return f.isValidElement(S)?f.cloneElement(S,{key:`error_${y}`}):S}));}if(!d.length&&a&&Array.isArray(t)&&t.length>0)return (await Promise.all(t.map((b,y)=>rE(`${e}.${y}`,b,a,r,o)))).reduce((b,y)=>[...b,...y],[]);const m={...n,name:e,enum:(n.enum||[]).join(", "),...o};return d.map(g=>typeof g=="string"?Hie(g,m):g)}function Vie(e,t,n,r,o,i){const a=e.join("."),l=n.map((d,m)=>{const p=d.validator,g={...d,ruleIndex:m};return p&&(g.validator=(b,y,S)=>{let C=false;const $=p(b,y,(...M)=>{Promise.resolve().then(()=>{Er(!C,"Your validator function has already return a promise. `callback` will be ignored."),C||S(...M);});});C=$&&typeof $.then=="function"&&typeof $.catch=="function",Er(C,"`callback` is deprecated. Please return a promise instead."),C&&$.then(()=>{S();}).catch(M=>{S(M||" ");});}),g}).sort(({warningOnly:d,ruleIndex:m},{warningOnly:p,ruleIndex:g})=>!!d==!!p?m-g:d?1:-1);let u;if(o===true)u=new Promise(async(d,m)=>{for(let p=0;p<l.length;p+=1){const g=l[p],b=await rE(a,t,g,r,i);if(b.length){m([{errors:b,rule:g}]);return}}d([]);});else {const d=l.map(m=>rE(a,t,m,r,i).then(p=>({errors:p,rule:m})));u=(o?Uie(d):jie(d)).then(m=>Promise.reject(m));}return u.catch(d=>d),u}async function jie(e){return Promise.all(e).then(t=>[].concat(...t))}async function Uie(e){let t=0;return new Promise(n=>{e.forEach(r=>{r.then(o=>{o.errors.length&&n([o]),t+=1,t===e.length&&n([]);});});})}function ar(e){return Z2(e)}function vO(e,t){let n={};return t.forEach(r=>{const o=la(e,r);n=ki(n,r,o);}),n}function Kd(e,t,n=false){return e&&e.some(r=>H0(t,r,n))}function H0(e,t,n=false){return !e||!t||!n&&e.length!==t.length?false:t.every((r,o)=>e[o]===r)}function Wie(e,t){if(e===t)return true;if(!e&&t||e&&!t||!e||!t||typeof e!="object"||typeof t!="object")return false;const n=Object.keys(e),r=Object.keys(t);return [...new Set([...n,...r])].every(i=>{const a=e[i],l=t[i];return typeof a=="function"&&typeof l=="function"?true:a===l})}function Gie(e,...t){const n=t[0];return n&&n.target&&typeof n.target=="object"&&e in n.target?n.target[e]:n}function bO(e,t,n){const{length:r}=e;if(t<0||t>=r||n<0||n>=r)return e;const o=e[t],i=t-n;return i>0?[...e.slice(0,n),o,...e.slice(n,t),...e.slice(t+1,r)]:i<0?[...e.slice(0,t),...e.slice(t+1,n+1),o,...e.slice(n+1,r)]:e}function oE(){return oE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},oE.apply(this,arguments)}const Ec=[],Xm=[];function Gx(e,t,n,r,o,i){return typeof e=="function"?e(t,n,"source"in i?{source:i.source}:{}):r!==o}class qie extends f.Component{static contextType=uf;state={resetCount:0};cancelRegisterFunc=null;mounted=false;touched=false;dirty=false;validatePromise;prevValidating;errors=Ec;warnings=Xm;constructor(t){if(super(t),t.fieldContext){const{getInternalHooks:n}=t.fieldContext,{initEntityValue:r}=n(Fc);r(this);}}componentDidMount(){const{shouldUpdate:t,fieldContext:n}=this.props;if(this.mounted=true,n){const{getInternalHooks:r}=n,{registerField:o}=r(Fc);this.cancelRegisterFunc=o(this);}t===true&&this.reRender();}componentWillUnmount(){this.cancelRegister(),this.triggerMetaEvent(true),this.mounted=false;}cancelRegister=()=>{const{preserve:t,isListField:n,name:r}=this.props;this.cancelRegisterFunc&&this.cancelRegisterFunc(n,t,ar(r)),this.cancelRegisterFunc=null;};getNamePath=()=>{const{name:t,fieldContext:n}=this.props,{prefixName:r=[]}=n;return t!==void 0?[...r,...t]:[]};getRules=()=>{const{rules:t=[],fieldContext:n}=this.props;return t.map(r=>typeof r=="function"?r(n):r)};reRender(){this.mounted&&this.forceUpdate();}refresh=()=>{this.mounted&&this.setState(({resetCount:t})=>({resetCount:t+1}));};metaCache=null;triggerMetaEvent=t=>{const{onMetaChange:n}=this.props;if(n){const r={...this.getMeta(),destroy:t};zl(this.metaCache,r)||n(r),this.metaCache=r;}else this.metaCache=null;};onStoreChange=(t,n,r)=>{const{shouldUpdate:o,dependencies:i=[],onReset:a}=this.props,{store:l}=r,u=this.getNamePath(),d=this.getValue(t),m=this.getValue(l),p=n&&Kd(n,u);switch(r.type==="valueUpdate"&&r.source==="external"&&!zl(d,m)&&(this.touched=true,this.dirty=true,this.validatePromise=null,this.errors=Ec,this.warnings=Xm,this.triggerMetaEvent()),r.type){case "reset":if(!n||p){this.touched=false,this.dirty=false,this.validatePromise=void 0,this.errors=Ec,this.warnings=Xm,this.triggerMetaEvent(),a?.(),this.refresh();return}break;case "remove":{if(o&&Gx(o,t,l,d,m,r)){this.reRender();return}break}case "setField":{const{data:g}=r;if(p){"touched"in g&&(this.touched=g.touched),"validating"in g&&!("originRCField"in g)&&(this.validatePromise=g.validating?Promise.resolve([]):null),"errors"in g&&(this.errors=g.errors||Ec),"warnings"in g&&(this.warnings=g.warnings||Xm),this.dirty=true,this.triggerMetaEvent(),this.reRender();return}else if("value"in g&&Kd(n,u,true)){this.reRender();return}if(o&&!u.length&&Gx(o,t,l,d,m,r)){this.reRender();return}break}case "dependenciesUpdate":{if(i.map(ar).some(b=>Kd(r.relatedFields,b))){this.reRender();return}break}default:if(p||(!i.length||u.length||o)&&Gx(o,t,l,d,m,r)){this.reRender();return}break}o===true&&this.reRender();};validateRules=t=>{const n=this.getNamePath(),r=this.getValue(),{triggerName:o,validateOnly:i=false}=t||{},a=Promise.resolve().then(async()=>{if(!this.mounted)return [];const{validateFirst:l=false,messageVariables:u,validateDebounce:d}=this.props;let m=this.getRules();if(o&&(m=m.filter(g=>g).filter(g=>{const{validateTrigger:b}=g;return b?Z2(b).includes(o):true})),d&&o&&(await new Promise(g=>{setTimeout(g,d);}),this.validatePromise!==a))return [];const p=Vie(n,r,m,t,l,u);return p.catch(g=>g).then((g=Ec)=>{if(this.validatePromise===a){this.validatePromise=null;const b=[],y=[];g.forEach?.(({rule:{warningOnly:S},errors:C=Ec})=>{S?y.push(...C):b.push(...C);}),this.errors=b,this.warnings=y,this.triggerMetaEvent(),this.reRender();}}),p});return i||(this.validatePromise=a,this.dirty=true,this.errors=Ec,this.warnings=Xm,this.triggerMetaEvent(),this.reRender()),a};isFieldValidating=()=>!!this.validatePromise;isFieldTouched=()=>this.touched;isFieldDirty=()=>{if(this.dirty||this.props.initialValue!==void 0)return true;const{fieldContext:t}=this.props,{getInitialValue:n}=t.getInternalHooks(Fc);return n(this.getNamePath())!==void 0};getErrors=()=>this.errors;getWarnings=()=>this.warnings;isListField=()=>this.props.isListField;isList=()=>this.props.isList;isPreserve=()=>this.props.preserve;getMeta=()=>(this.prevValidating=this.isFieldValidating(),{touched:this.isFieldTouched(),validating:this.prevValidating,errors:this.errors,warnings:this.warnings,name:this.getNamePath(),validated:this.validatePromise===null});getOnlyChild=t=>{if(typeof t=="function"){const r=this.getMeta();return {...this.getOnlyChild(t(this.getControlled(),r,this.props.fieldContext)),isFunction:true}}const n=Qo(t);return n.length!==1||!f.isValidElement(n[0])?{child:n,isFunction:false}:{child:n[0],isFunction:false}};getValue=t=>{const{getFieldsValue:n}=this.props.fieldContext,r=this.getNamePath();return la(t||n(true),r)};getControlled=(t={})=>{const{name:n,trigger:r="onChange",validateTrigger:o,getValueFromEvent:i,normalize:a,valuePropName:l="value",getValueProps:u,fieldContext:d}=this.props,m=o!==void 0?o:d.validateTrigger,p=this.getNamePath(),{getInternalHooks:g,getFieldsValue:b}=d,{dispatch:y}=g(Fc),S=this.getValue(),C=u||(R=>({[l]:R})),w=t[r],$=n!==void 0?C(S):{},M={...t,...$};return M[r]=(...R)=>{this.touched=true,this.dirty=true,this.triggerMetaEvent();let I;i?I=i(...R):I=Gie(l,...R),a&&(I=a(I,S,b(true))),I!==S&&y({type:"updateValue",namePath:p,value:I}),w&&w(...R);},Z2(m||[]).forEach(R=>{const I=M[R];M[R]=(...N)=>{I&&I(...N);const{rules:P}=this.props;P&&P.length&&y({type:"validateField",namePath:p,triggerName:R});};}),M};render(){const{resetCount:t}=this.state,{children:n}=this.props,{child:r,isFunction:o}=this.getOnlyChild(n);let i;return o?i=r:f.isValidElement(r)?i=f.cloneElement(r,this.getControlled(r.props)):(Er(!r,"`children` of Field is not validate ReactElement."),i=r),f.createElement(f.Fragment,{key:t},i)}}function Gk({name:e,...t}){const n=f.useContext(uf),r=f.useContext(F0),o=e!==void 0?ar(e):void 0,i=t.isListField??!!r;let a="keep";return i||(a=`_${(o||[]).join("_")}`),f.createElement(qie,oE({key:a,name:o,isListField:i},t,{fieldContext:n}))}function Kie({name:e,initialValue:t,children:n,rules:r,validateTrigger:o,isListField:i}){const a=f.useContext(uf),l=f.useContext(F0),d=f.useRef({keys:[],id:0}).current,m=f.useMemo(()=>[...ar(a.prefixName)||[],...ar(e)],[a.prefixName,e]),p=f.useMemo(()=>({...a,prefixName:m}),[a,m]),g=f.useMemo(()=>({getKey:y=>{const S=m.length,C=y[S];return [d.keys[C],y.slice(S+1)]}}),[d,m]);if(typeof n!="function")return Er(false,"Form.List only accepts function as children."),null;const b=(y,S,{source:C})=>C==="internal"?false:y!==S;return f.createElement(F0.Provider,{value:g},f.createElement(uf.Provider,{value:p},f.createElement(Gk,{name:[],shouldUpdate:b,rules:r,validateTrigger:o,initialValue:t,isList:true,isListField:i??!!l},({value:y=[],onChange:S},C)=>{const{getFieldValue:w}=a,$=()=>w(m||[])||[],M={add:(R,I)=>{const N=$();I>=0&&I<=N.length?(d.keys=[...d.keys.slice(0,I),d.id,...d.keys.slice(I)],S([...N.slice(0,I),R,...N.slice(I)])):(d.keys=[...d.keys,d.id],S([...N,R])),d.id+=1;},remove:R=>{const I=$(),N=new Set(Array.isArray(R)?R:[R]);N.size<=0||(d.keys=d.keys.filter((P,O)=>!N.has(O)),S(I.filter((P,O)=>!N.has(O))));},move(R,I){if(R===I)return;const N=$();R<0||R>=N.length||I<0||I>=N.length||(d.keys=bO(d.keys,R,I),S(bO(N,R,I)));}};let T=y||[];return Array.isArray(T)||(T=[]),n(T.map((R,I)=>{let N=d.keys[I];return N===void 0&&(d.keys[I]=d.id,N=d.keys[I],d.id+=1),{name:I,key:N,isListField:true}}),M,C)})))}function Yie(e){let t=false,n=e.length;const r=[];return e.length?new Promise((o,i)=>{e.forEach((a,l)=>{a.catch(u=>(t=true,u)).then(u=>{n-=1,r[l]=u,!(n>0)&&(t&&i(r),o(r));});});}):Promise.resolve([])}const iE="__@field_split__";function sb(e){return e.map(t=>`${typeof t}:${t}`).join(iE)}class bd{kvs=new Map;set(t,n){this.kvs.set(sb(t),n);}get(t){return this.kvs.get(sb(t))}getAsPrefix(t){const n=sb(t),r=n+iE,o=[],i=this.kvs.get(n);return i!==void 0&&o.push(i),this.kvs.forEach((a,l)=>{l.startsWith(r)&&o.push(a);}),o}update(t,n){const r=this.get(t),o=n(r);o?this.set(t,o):this.delete(t);}delete(t){this.kvs.delete(sb(t));}map(t){return [...this.kvs.entries()].map(([n,r])=>{const o=n.split(iE);return t({key:o.map(i=>{const[,a,l]=i.match(/^([^:]*):(.*)$/);return a==="number"?Number(l):l}),value:r})})}toJSON(){const t={};return this.map(({key:n,value:r})=>(t[n.join(".")]=r,null)),t}}const Xie=e=>{const t=new MessageChannel;t.port1.onmessage=e,t.port2.postMessage(null);};class Qie{namePathList=[];taskId=0;watcherList=new Set;form;constructor(t){this.form=t;}register(t){return this.watcherList.add(t),()=>{this.watcherList.delete(t);}}notify(t){t.forEach(n=>{this.namePathList.every(r=>!H0(r,n))&&this.namePathList.push(n);}),this.doBatch();}doBatch(){this.taskId+=1;const t=this.taskId;Xie(()=>{if(t===this.taskId&&this.watcherList.size){const n=this.form.getForm(),r=n.getFieldsValue(),o=n.getFieldsValue(true);this.watcherList.forEach(i=>{i(r,o,this.namePathList);}),this.namePathList=[];}});}}class Zie{formHooked=false;forceRootUpdate;subscribable=true;store={};fieldEntities=[];initialValues={};callbacks={};validateMessages=null;preserve=null;lastValidatePromise=null;watcherCenter=new Qie(this);constructor(t){this.forceRootUpdate=t;}getForm=()=>({getFieldValue:this.getFieldValue,getFieldsValue:this.getFieldsValue,getFieldError:this.getFieldError,getFieldWarning:this.getFieldWarning,getFieldsError:this.getFieldsError,isFieldsTouched:this.isFieldsTouched,isFieldTouched:this.isFieldTouched,isFieldValidating:this.isFieldValidating,isFieldsValidating:this.isFieldsValidating,resetFields:this.resetFields,setFields:this.setFields,setFieldValue:this.setFieldValue,setFieldsValue:this.setFieldsValue,validateFields:this.validateFields,submit:this.submit,_init:true,getInternalHooks:this.getInternalHooks});getInternalHooks=t=>t===Fc?(this.formHooked=true,{dispatch:this.dispatch,initEntityValue:this.initEntityValue,registerField:this.registerField,useSubscribe:this.useSubscribe,setInitialValues:this.setInitialValues,destroyForm:this.destroyForm,setCallbacks:this.setCallbacks,setValidateMessages:this.setValidateMessages,getFields:this.getFields,setPreserve:this.setPreserve,getInitialValue:this.getInitialValue,registerWatch:this.registerWatch}):(Er(false,"`getInternalHooks` is internal usage. Should not call directly."),null);useSubscribe=t=>{this.subscribable=t;};prevWithoutPreserves=null;setInitialValues=(t,n)=>{if(this.initialValues=t||{},n){let r=Pd(t,this.store);this.prevWithoutPreserves?.map(({key:o})=>{r=ki(r,o,la(t,o));}),this.prevWithoutPreserves=null,this.updateStore(r);}};destroyForm=t=>{if(t)this.updateStore({});else {const n=new bd;this.getFieldEntities(true).forEach(r=>{this.isMergedPreserve(r.isPreserve())||n.set(r.getNamePath(),true);}),this.prevWithoutPreserves=n;}};getInitialValue=t=>{const n=la(this.initialValues,t);return t.length?Pd(n):n};setCallbacks=t=>{this.callbacks=t;};setValidateMessages=t=>{this.validateMessages=t;};setPreserve=t=>{this.preserve=t;};registerWatch=t=>this.watcherCenter.register(t);notifyWatch=(t=[])=>{this.watcherCenter.notify(t);};timeoutId=null;warningUnhooked=()=>{};updateStore=t=>{this.store=t;};getFieldEntities=(t=false)=>t?this.fieldEntities.filter(n=>n.getNamePath().length):this.fieldEntities;getFieldsMap=(t=false)=>{const n=new bd;return this.getFieldEntities(t).forEach(r=>{const o=r.getNamePath();n.set(o,r);}),n};getFieldEntitiesForNamePathList=(t,n=false)=>{if(!t)return this.getFieldEntities(true);const r=this.getFieldsMap(true);return n?t.flatMap(o=>{const i=ar(o),a=r.getAsPrefix(i);return a.length?a:[{INVALIDATE_NAME_PATH:i}]}):t.map(o=>{const i=ar(o);return r.get(i)||{INVALIDATE_NAME_PATH:ar(o)}})};getFieldsValue=(t,n)=>{this.warningUnhooked();let r,o;if(t===true||Array.isArray(t)?(r=t,o=n):t&&typeof t=="object"&&(o=t.filter),r===true&&!o)return this.store;const i=this.getFieldEntitiesForNamePathList(Array.isArray(r)?r:null,true),a=[],l=[];i.forEach(d=>{const m=d.INVALIDATE_NAME_PATH||d.getNamePath();if(d.isList?.()){l.push(m);return}if(!o)a.push(m);else {const p="getMeta"in d?d.getMeta():null;o(p)&&a.push(m);}});let u=vO(this.store,a.map(ar));return l.forEach(d=>{la(u,d)||(u=ki(u,d,[]));}),u};getFieldValue=t=>{this.warningUnhooked();const n=ar(t);return la(this.store,n)};getFieldsError=t=>(this.warningUnhooked(),this.getFieldEntitiesForNamePathList(t).map((r,o)=>r&&!r.INVALIDATE_NAME_PATH?{name:r.getNamePath(),errors:r.getErrors(),warnings:r.getWarnings()}:{name:ar(t[o]),errors:[],warnings:[]}));getFieldError=t=>{this.warningUnhooked();const n=ar(t);return this.getFieldsError([n])[0].errors};getFieldWarning=t=>{this.warningUnhooked();const n=ar(t);return this.getFieldsError([n])[0].warnings};isFieldsTouched=(...t)=>{this.warningUnhooked();const[n,r]=t;let o,i=false;t.length===0?o=null:t.length===1?Array.isArray(n)?(o=n.map(ar),i=false):(o=null,i=n):(o=n.map(ar),i=r);const a=this.getFieldEntities(true),l=p=>p.isFieldTouched();if(!o)return i?a.every(p=>l(p)||p.isList()):a.some(l);const u=new bd;o.forEach(p=>{u.set(p,[]);}),a.forEach(p=>{const g=p.getNamePath();o.forEach(b=>{b.every((y,S)=>g[S]===y)&&u.update(b,y=>[...y,p]);});});const d=p=>p.some(l),m=u.map(({value:p})=>p);return i?m.every(d):m.some(d)};isFieldTouched=t=>(this.warningUnhooked(),this.isFieldsTouched([t]));isFieldsValidating=t=>{this.warningUnhooked();const n=this.getFieldEntities();if(!t)return n.some(o=>o.isFieldValidating());const r=t.map(ar);return n.some(o=>{const i=o.getNamePath();return Kd(r,i)&&o.isFieldValidating()})};isFieldValidating=t=>(this.warningUnhooked(),this.isFieldsValidating([t]));resetWithFieldInitialValue=(t={})=>{const n=new bd,r=this.getFieldEntities(true);r.forEach(a=>{const{initialValue:l}=a.props,u=a.getNamePath();if(l!==void 0){const d=n.get(u)||new Set;d.add({entity:a,value:l}),n.set(u,d);}});const o=a=>{a.forEach(l=>{const{initialValue:u}=l.props;if(u!==void 0){const d=l.getNamePath();if(this.getInitialValue(d)!==void 0)Er(false,`Form already set 'initialValues' with path '${d.join(".")}'. Field can not overwrite it.`);else {const p=n.get(d);if(p&&p.size>1)Er(false,`Multiple Field with path '${d.join(".")}' set 'initialValue'. Can not decide which one to pick.`);else if(p){const g=this.getFieldValue(d);!l.isListField()&&(!t.skipExist||g===void 0)&&this.updateStore(ki(this.store,d,[...p][0].value));}}}});};let i;t.entities?i=t.entities:t.namePathList?(i=[],t.namePathList.forEach(a=>{const l=n.get(a);l&&i.push(...[...l].map(u=>u.entity));})):i=r,o(i);};resetFields=t=>{this.warningUnhooked();const n=this.store;if(!t){this.updateStore(Pd(this.initialValues)),this.resetWithFieldInitialValue(),this.notifyObservers(n,null,{type:"reset"}),this.notifyWatch();return}const r=t.map(ar);r.forEach(o=>{const i=this.getInitialValue(o);this.updateStore(ki(this.store,o,i));}),this.resetWithFieldInitialValue({namePathList:r}),this.notifyObservers(n,r,{type:"reset"}),this.notifyWatch(r);};setFields=t=>{this.warningUnhooked();const n=this.store,r=[];t.forEach(o=>{const{name:i,...a}=o,l=ar(i);r.push(l),"value"in a&&this.updateStore(ki(this.store,l,a.value)),this.notifyObservers(n,[l],{type:"setField",data:o});}),this.notifyWatch(r);};getFields=()=>this.getFieldEntities(true).map(r=>{const o=r.getNamePath(),a={...r.getMeta(),name:o,value:this.getFieldValue(o)};return Object.defineProperty(a,"originRCField",{value:true}),a});initEntityValue=t=>{const{initialValue:n}=t.props;if(n!==void 0){const r=t.getNamePath();la(this.store,r)===void 0&&this.updateStore(ki(this.store,r,n));}};isMergedPreserve=t=>(t!==void 0?t:this.preserve)??true;registerField=t=>{this.fieldEntities.push(t);const n=t.getNamePath();if(this.notifyWatch([n]),t.props.initialValue!==void 0){const r=this.store;this.resetWithFieldInitialValue({entities:[t],skipExist:true}),this.notifyObservers(r,[t.getNamePath()],{type:"valueUpdate",source:"internal"});}return (r,o,i=[])=>{if(this.fieldEntities=this.fieldEntities.filter(a=>a!==t),!this.isMergedPreserve(o)&&(!r||i.length>1)){const a=r?void 0:this.getInitialValue(n);if(n.length&&this.getFieldValue(n)!==a&&this.fieldEntities.every(l=>!H0(l.getNamePath(),n))){const l=this.store;this.updateStore(ki(l,n,a,true)),this.notifyObservers(l,[n],{type:"remove"}),this.triggerDependenciesUpdate(l,n);}}this.notifyWatch([n]);}};dispatch=t=>{switch(t.type){case "updateValue":{const{namePath:n,value:r}=t;this.updateValue(n,r);break}case "validateField":{const{namePath:n,triggerName:r}=t;this.validateFields([n],{triggerName:r});break}}};notifyObservers=(t,n,r)=>{if(this.subscribable){const o={...r,store:this.getFieldsValue(true)};this.getFieldEntities().forEach(({onStoreChange:i})=>{i(t,n,o);});}else this.forceRootUpdate();};triggerDependenciesUpdate=(t,n)=>{const r=this.getDependencyChildrenFields(n);return r.length&&this.validateFields(r),this.notifyObservers(t,r,{type:"dependenciesUpdate",relatedFields:[n,...r]}),r};updateValue=(t,n)=>{const r=ar(t),o=this.store;this.updateStore(ki(this.store,r,n)),this.notifyObservers(o,[r],{type:"valueUpdate",source:"internal"}),this.notifyWatch([r]);const i=this.triggerDependenciesUpdate(o,r),{onValuesChange:a}=this.callbacks;if(a){const l=this.getFieldsMap(true).get(r),u=vO(this.store,[r]),d=this.getFieldsValue(),m=WL([d,u],{prepareArray:p=>l?.isList()?[]:[...p||[]]});a(u,m);}this.triggerOnFieldsChange([r,...i]);};setFieldsValue=t=>{this.warningUnhooked();const n=this.store;if(t){const r=Pd(this.store,t);this.updateStore(r);}this.notifyObservers(n,null,{type:"valueUpdate",source:"external"}),this.notifyWatch();};setFieldValue=(t,n)=>{this.setFields([{name:t,value:n,errors:[],warnings:[],touched:true}]);};getDependencyChildrenFields=t=>{const n=new Set,r=[],o=new bd;this.getFieldEntities().forEach(a=>{const{dependencies:l}=a.props;(l||[]).forEach(u=>{const d=ar(u);o.update(d,(m=new Set)=>(m.add(a),m));});});const i=a=>{(o.get(a)||new Set).forEach(u=>{if(!n.has(u)){n.add(u);const d=u.getNamePath();u.isFieldDirty()&&d.length&&(r.push(d),i(d));}});};return i(t),r};triggerOnFieldsChange=(t,n)=>{const{onFieldsChange:r}=this.callbacks;if(r){const o=this.getFields();if(n){const a=new bd;n.forEach(({name:l,errors:u})=>{a.set(l,u);}),o.forEach(l=>{l.errors=a.get(l.name)||l.errors;});}const i=o.filter(({name:a})=>Kd(t,a));i.length&&r(i,o);}};validateFields=(t,n)=>{this.warningUnhooked();let r,o;Array.isArray(t)||typeof t=="string"||typeof n=="string"?(r=t,o=n):o=t;const i=!!r,a=i?r.map(ar):[],l=[...a],u=[],d=String(Date.now()),m=new Set,{recursive:p,dirty:g}=o||{};this.getFieldEntities(true).forEach(C=>{const w=C.getNamePath();if(i||((!C.isList()||!a.some($=>H0($,w,true)))&&l.push(w),a.push(w)),!(!C.props.rules||!C.props.rules.length)&&!(g&&!C.isFieldDirty())&&(m.add(w.join(d)),!i||Kd(a,w,p))){const $=C.validateRules({validateMessages:{...Wk,...this.validateMessages},...o});u.push($.then(()=>({name:w,errors:[],warnings:[]})).catch(M=>{const T=[],R=[];return M.forEach?.(({rule:{warningOnly:I},errors:N})=>{I?R.push(...N):T.push(...N);}),T.length?Promise.reject({name:w,errors:T,warnings:R}):{name:w,errors:T,warnings:R}}));}});const b=Yie(u);this.lastValidatePromise=b,b.catch(C=>C).then(C=>{const w=C.map(({name:$})=>$);this.notifyObservers(this.store,w,{type:"validateFinish"}),this.triggerOnFieldsChange(w,C);});const y=b.then(()=>this.lastValidatePromise===b?Promise.resolve(this.getFieldsValue(l)):Promise.reject([])).catch(C=>{const w=C.filter(M=>M&&M.errors.length),$=w[0]?.errors?.[0];return Promise.reject({message:$,values:this.getFieldsValue(a),errorFields:w,outOfDate:this.lastValidatePromise!==b})});y.catch(C=>C);const S=a.filter(C=>m.has(C.join(d)));return this.triggerOnFieldsChange(S),y};submit=()=>{this.warningUnhooked(),this.validateFields().then(t=>{const{onFinish:n}=this.callbacks;if(n)try{n(t);}catch(r){console.error(r);}}).catch(t=>{const{onFinishFailed:n}=this.callbacks;n&&n(t);});}}function qk(e){const t=f.useRef(null),[,n]=f.useState({});if(!t.current)if(e)t.current=e;else {const r=()=>{n({});},o=new Zie(r);t.current=o.getForm();}return [t.current]}const aE=f.createContext({triggerFormChange:()=>{},triggerFormFinish:()=>{},registerForm:()=>{},unregisterForm:()=>{}}),Jie=({validateMessages:e,onFormChange:t,onFormFinish:n,children:r})=>{const o=f.useContext(aE),i=f.useRef({});return f.createElement(aE.Provider,{value:{...o,validateMessages:{...o.validateMessages,...e},triggerFormChange:(a,l)=>{t&&t(a,{changedFields:l,forms:i.current}),o.triggerFormChange(a,l);},triggerFormFinish:(a,l)=>{n&&n(a,{values:l,forms:i.current}),o.triggerFormFinish(a,l);},registerForm:(a,l)=>{a&&(i.current={...i.current,[a]:l}),o.registerForm(a,l);},unregisterForm:a=>{const l={...i.current};delete l[a],i.current=l,o.unregisterForm(a);}}},r)};function sE(){return sE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},sE.apply(this,arguments)}const eae=({name:e,initialValues:t,fields:n,form:r,preserve:o,children:i,component:a="form",validateMessages:l,validateTrigger:u="onChange",onValuesChange:d,onFieldsChange:m,onFinish:p,onFinishFailed:g,clearOnDestroy:b,...y},S)=>{const C=f.useRef(null),w=f.useContext(aE),[$]=qk(r),{useSubscribe:M,setInitialValues:T,setCallbacks:R,setValidateMessages:I,setPreserve:N,destroyForm:P}=$.getInternalHooks(Fc);f.useImperativeHandle(S,()=>({...$,nativeElement:C.current})),f.useEffect(()=>(w.registerForm(e,$),()=>{w.unregisterForm(e);}),[w,$,e]),I({...w.validateMessages,...l}),R({onValuesChange:d,onFieldsChange:(H,...z)=>{w.triggerFormChange(e,H),m&&m(H,...z);},onFinish:H=>{w.triggerFormFinish(e,H),p&&p(H);},onFinishFailed:g}),N(o);const O=f.useRef(null);T(t,!O.current),O.current||(O.current=true),f.useEffect(()=>()=>P(b),[]);let _;const B=typeof i=="function";if(B){const H=$.getFieldsValue(true);_=i(H,$);}else _=i;M(!B);const V=f.useRef(null);f.useEffect(()=>{Wie(V.current||[],n||[])||$.setFields(n||[]),V.current=n;},[n,$]);const U=f.useMemo(()=>({...$,validateTrigger:u}),[$,u]),G=f.createElement(F0.Provider,{value:null},f.createElement(uf.Provider,{value:U},_));return a===false?G:f.createElement(a,sE({},y,{ref:C,onSubmit:H=>{H.preventDefault(),H.stopPropagation(),$.submit();},onReset:H=>{H.preventDefault(),$.resetFields(),y.onReset?.(H);}}),G)};function qx(e){try{return JSON.stringify(e)}catch{return Math.random()}}function tae(...e){const[t,n={}]=e,r=cie(n)?{form:n}:n,o=r.form,[i,a]=f.useState(()=>typeof t=="function"?t({}):void 0),l=f.useMemo(()=>qx(i),[i]),u=f.useRef(l);u.current=l;const d=f.useContext(uf),m=o||d,p=m&&m._init,{getFieldsValue:g,getInternalHooks:b}=m,{registerWatch:y}=b(Fc),S=Mt((w,$)=>{const M=r.preserve?$??g(true):w??g(),T=typeof t=="function"?t(M):la(M,ar(t));qx(i)!==qx(T)&&a(T);}),C=typeof t=="function"?t:JSON.stringify(t);return f.useEffect(()=>{p&&S();},[p,C]),f.useEffect(()=>p?y(($,M)=>{S($,M);}):void 0,[p]),i}const nae=f.forwardRef(eae),tg=nae;tg.FormProvider=Jie;tg.Field=Gk;tg.List=Kie;tg.useForm=qk;tg.useWatch=tae;const So=f.createContext({}),rae=({children:e,status:t,override:n})=>{const r=f.useContext(So),o=f.useMemo(()=>{const i={...r};return n&&delete i.isFormItemInput,t&&(delete i.status,delete i.hasFeedback,delete i.feedbackIcon),i},[t,n,r]);return f.createElement(So.Provider,{value:o},e)},oae=f.createContext(void 0),Vl=e=>{const{space:t,form:n,children:r}=e;if(!Jr(r))return null;let o=r;return n&&(o=q.createElement(rae,{override:true,status:true},o)),t&&(o=q.createElement(xre,null,o)),o},iae=()=>wi()&&window.document.documentElement;function aae(e,t,n){return f.useMemo(()=>({...{trap:t??true,focusTriggerAfterClose:n??true},...e}),[e,t,n])}const i1=e=>{const{prefixCls:t,className:n,style:r,size:o,shape:i}=e,a=X({[`${t}-lg`]:o==="large",[`${t}-sm`]:o==="small"}),l=X({[`${t}-circle`]:i==="circle",[`${t}-square`]:i==="square",[`${t}-round`]:i==="round"}),u=f.useMemo(()=>typeof o=="number"?{width:o,height:o,lineHeight:`${o}px`}:{},[o]);return f.createElement("span",{className:X(t,a,l,n),style:{...u,...r}})},sae=new zt("ant-skeleton-loading",{"0%":{backgroundPosition:"100% 50%"},"100%":{backgroundPosition:"0 50%"}}),ER=e=>({height:e,lineHeight:oe(e)}),Bl=e=>({width:e,...ER(e)}),lae=e=>({background:e.skeletonLoadingBackground,backgroundSize:"400% 100%",animationName:sae,animationDuration:e.skeletonLoadingMotionDuration,animationTimingFunction:"ease",animationIterationCount:"infinite"}),Kx=(e,t)=>({width:t(e).mul(5).equal(),minWidth:t(e).mul(5).equal(),...ER(e)}),cae=e=>{const{skeletonAvatarCls:t,gradientFromColor:n,controlHeight:r,controlHeightLG:o,controlHeightSM:i}=e;return {[t]:{display:"inline-block",verticalAlign:"top",background:n,...Bl(r)},[`${t}${t}-circle`]:{borderRadius:"50%"},[`${t}${t}-lg`]:{...Bl(o)},[`${t}${t}-sm`]:{...Bl(i)}}},uae=e=>{const{controlHeight:t,borderRadiusSM:n,skeletonInputCls:r,controlHeightLG:o,controlHeightSM:i,gradientFromColor:a,calc:l}=e;return {[r]:{display:"inline-block",verticalAlign:"top",background:a,borderRadius:n,...Kx(t,l)},[`${r}-lg`]:{...Kx(o,l)},[`${r}-sm`]:{...Kx(i,l)}}},Kk=e=>{const{gradientFromColor:t,borderRadiusSM:n,imageSizeBase:r,calc:o}=e;return {display:"inline-flex",alignItems:"center",justifyContent:"center",verticalAlign:"middle",background:t,borderRadius:n,...Bl(o(r).mul(2).equal())}},dae=e=>({[e.skeletonNodeCls]:{...Kk(e)}}),fae=e=>{const{skeletonImageCls:t,imageSizeBase:n,calc:r}=e;return {[t]:{...Kk(e),[`${t}-path`]:{fill:"#bfbfbf"},[`${t}-svg`]:{...Bl(n),maxWidth:r(n).mul(4).equal(),maxHeight:r(n).mul(4).equal()},[`${t}-svg${t}-svg-circle`]:{borderRadius:"50%"}},[`${t}${t}-circle`]:{borderRadius:"50%"}}},Yx=(e,t,n)=>{const{skeletonButtonCls:r}=e;return {[`${n}${r}-circle`]:{width:t,minWidth:t,borderRadius:"50%"},[`${n}${r}-round`]:{borderRadius:t}}},Xx=(e,t)=>({width:t(e).mul(2).equal(),minWidth:t(e).mul(2).equal(),...ER(e)}),mae=e=>{const{borderRadiusSM:t,skeletonButtonCls:n,controlHeight:r,controlHeightLG:o,controlHeightSM:i,gradientFromColor:a,calc:l}=e;return {[n]:{display:"inline-block",verticalAlign:"top",background:a,borderRadius:t,width:l(r).mul(2).equal(),minWidth:l(r).mul(2).equal(),...Xx(r,l)},...Yx(e,r,n),[`${n}-lg`]:{...Xx(o,l)},...Yx(e,o,`${n}-lg`),[`${n}-sm`]:{...Xx(i,l)},...Yx(e,i,`${n}-sm`)}},hae=e=>{const{componentCls:t,skeletonAvatarCls:n,skeletonTitleCls:r,skeletonParagraphCls:o,skeletonButtonCls:i,skeletonInputCls:a,skeletonNodeCls:l,skeletonImageCls:u,controlHeight:d,controlHeightLG:m,controlHeightSM:p,gradientFromColor:g,padding:b,marginSM:y,borderRadius:S,titleHeight:C,blockRadius:w,paragraphLiHeight:$,controlHeightXS:M,paragraphMarginTop:T}=e;return {[t]:{display:"table",width:"100%",[`${t}-header`]:{display:"table-cell",paddingInlineEnd:b,verticalAlign:"top",[n]:{display:"inline-block",verticalAlign:"top",background:g,...Bl(d)},[`${n}-circle`]:{borderRadius:"50%"},[`${n}-lg`]:{...Bl(m)},[`${n}-sm`]:{...Bl(p)}},[`${t}-section`]:{display:"table-cell",width:"100%",verticalAlign:"top",[r]:{width:"100%",height:C,background:g,borderRadius:w,[`+ ${o}`]:{marginBlockStart:p}},[o]:{padding:0,"> li":{width:"100%",height:$,listStyle:"none",background:g,borderRadius:w,"+ li":{marginBlockStart:M}}},[`${o}> li:last-child:not(:first-child):not(:nth-child(2))`]:{width:"61%"}},[`&-round ${t}-section`]:{[`${r}, ${o} > li`]:{borderRadius:S}}},[`${t}-with-avatar ${t}-section`]:{[r]:{marginBlockStart:y,[`+ ${o}`]:{marginBlockStart:T}}},[`${t}${t}-element`]:{display:"inline-block",width:"auto",...mae(e),...cae(e),...uae(e),...dae(e),...fae(e)},[`${t}${t}-block`]:{width:"100%",[i]:{width:"100%"},[a]:{width:"100%"}},[`${t}${t}-active`]:{[`
${r},
${o} > li,
${n},
${i},
${a},
${l},
${u}
`]:{...lae(e)}}}},pae=e=>{const{colorFillContent:t,colorFill:n}=e,r=t,o=n;return {color:r,colorGradientEnd:o,gradientFromColor:r,gradientToColor:o,titleHeight:e.controlHeight/2,blockRadius:e.borderRadiusSM,paragraphMarginTop:e.marginLG+e.marginXXS,paragraphLiHeight:e.controlHeight/2}},ng=Wt("Skeleton",e=>{const{componentCls:t,calc:n}=e,r=Ft(e,{skeletonAvatarCls:`${t}-avatar`,skeletonTitleCls:`${t}-title`,skeletonParagraphCls:`${t}-paragraph`,skeletonButtonCls:`${t}-button`,skeletonInputCls:`${t}-input`,skeletonNodeCls:`${t}-node`,skeletonImageCls:`${t}-image`,imageSizeBase:n(e.controlHeight).mul(1.5).equal(),borderRadius:100,skeletonLoadingBackground:`linear-gradient(90deg, ${e.gradientFromColor} 25%, ${e.gradientToColor} 37%, ${e.gradientFromColor} 63%)`,skeletonLoadingMotionDuration:"1.4s"});return hae(r)},pae,{deprecatedTokens:[["color","gradientFromColor"],["colorGradientEnd","gradientToColor"]]}),gae=e=>{const{prefixCls:t,className:n,classNames:r,rootClassName:o,active:i,style:a,styles:l,shape:u="circle",size:d="default",...m}=e,{getPrefixCls:p}=f.useContext(wt),g=p("skeleton",t),[b,y]=ng(g),S=X(g,`${g}-element`,{[`${g}-active`]:i},r?.root,n,o,b,y);return f.createElement("div",{className:S,style:l?.root},f.createElement(i1,{prefixCls:`${g}-avatar`,className:r?.content,style:{...l?.content,...a},shape:u,size:d,...m}))},vae=e=>{const{prefixCls:t,className:n,rootClassName:r,classNames:o,active:i,style:a,styles:l,block:u=false,size:d="default",...m}=e,{getPrefixCls:p}=f.useContext(wt),g=p("skeleton",t),[b,y]=ng(g),S=X(g,`${g}-element`,{[`${g}-active`]:i,[`${g}-block`]:u},o?.root,n,r,b,y);return f.createElement("div",{className:S,style:l?.root},f.createElement(i1,{prefixCls:`${g}-button`,className:o?.content,style:{...l?.content,...a},size:d,...m}))},Yk=e=>{const{prefixCls:t,className:n,classNames:r,rootClassName:o,internalClassName:i,style:a,styles:l,active:u,children:d}=e,{getPrefixCls:m}=f.useContext(wt),p=m("skeleton",t),[g,b]=ng(p),y=X(p,`${p}-element`,{[`${p}-active`]:u},g,r?.root,n,o,b);return f.createElement("div",{className:y,style:l?.root},f.createElement("div",{className:X(r?.content,i||`${p}-node`),style:{...l?.content,...a}},d))},bae=e=>{const{getPrefixCls:t}=f.useContext(wt),n=t("skeleton",e.prefixCls);return f.createElement(Yk,{...e,internalClassName:`${n}-image`},f.createElement("svg",{viewBox:"0 0 1098 1024",xmlns:"http://www.w3.org/2000/svg",className:`${n}-image-svg`},f.createElement("title",null,"Image placeholder"),f.createElement("path",{d:"M365.7 329.1q0 45.8-32 77.7t-77.7 32-77.7-32-32-77.7 32-77.6 77.7-32 77.7 32 32 77.6M951 548.6v256H146.3V694.9L329 512l91.5 91.4L713 311zm54.8-402.3H91.4q-7.4 0-12.8 5.4T73 164.6v694.8q0 7.5 5.5 12.9t12.8 5.4h914.3q7.5 0 12.9-5.4t5.4-12.9V164.6q0-7.5-5.4-12.9t-12.9-5.4m91.4 18.3v694.8q0 37.8-26.8 64.6t-64.6 26.9H91.4q-37.7 0-64.6-26.9T0 859.4V164.6q0-37.8 26.8-64.6T91.4 73h914.3q37.8 0 64.6 26.9t26.8 64.6",className:`${n}-image-path`})))},yae=e=>{const{prefixCls:t,className:n,classNames:r,rootClassName:o,active:i,block:a,style:l,styles:u,size:d="default",...m}=e,{getPrefixCls:p}=f.useContext(wt),g=p("skeleton",t),[b,y]=ng(g),S=X(g,`${g}-element`,{[`${g}-active`]:i,[`${g}-block`]:a},r?.root,n,o,b,y);return f.createElement("div",{className:S,style:u?.root},f.createElement(i1,{prefixCls:`${g}-input`,className:r?.content,style:{...u?.content,...l},size:d,...m}))},Sae=(e,t)=>{const{width:n,rows:r=2}=t;if(Array.isArray(n))return n[e];if(r-1===e)return n},Cae=e=>{const{prefixCls:t,className:n,style:r,rows:o=0}=e,i=Array.from({length:o}).map((a,l)=>f.createElement("li",{key:l,style:{width:Sae(l,e)}}));return f.createElement("ul",{className:X(t,n),style:r},i)},xae=({prefixCls:e,className:t,width:n,style:r})=>f.createElement("h3",{className:X(e,t),style:{width:n,...r}});function Qx(e){return e&&typeof e=="object"?e:{}}function wae(e,t){return e&&!t?{size:"large",shape:"square"}:{size:"large",shape:"circle"}}function $ae(e,t){return !e&&t?{width:"38%"}:e&&t?{width:"50%"}:{}}function Eae(e,t){const n={};return (!e||!t)&&(n.width="61%"),!e&&t?n.rows=3:n.rows=2,n}const Of=e=>{const{prefixCls:t,loading:n,className:r,rootClassName:o,classNames:i,style:a,styles:l,children:u,avatar:d=false,title:m=true,paragraph:p=true,active:g,round:b}=e,{getPrefixCls:y,direction:S,className:C,style:w,classNames:$,styles:M}=jt("skeleton"),T=y("skeleton",t),[R,I]=ng(T),N={...e,avatar:d,title:m,paragraph:p},[P,O]=Kt([$,i],[M,l],{props:N});if(n||!("loading"in e)){const _=!!d,B=!!m,V=!!p;let U;if(_){const z={className:P.avatar,prefixCls:`${T}-avatar`,...wae(B,V),...Qx(d),style:O.avatar};U=f.createElement("div",{className:X(P.header,`${T}-header`),style:O.header},f.createElement(i1,{...z}));}let G;if(B||V){let z;if(B){const W={className:P.title,prefixCls:`${T}-title`,...$ae(_,V),...Qx(m),style:O.title};z=f.createElement(xae,{...W});}let j;if(V){const W={className:P.paragraph,prefixCls:`${T}-paragraph`,...Eae(_,B),...Qx(p),style:O.paragraph};j=f.createElement(Cae,{...W});}G=f.createElement("div",{className:X(P.section,`${T}-section`),style:O.section},z,j);}const H=X(T,{[`${T}-with-avatar`]:_,[`${T}-active`]:g,[`${T}-rtl`]:S==="rtl",[`${T}-round`]:b},P.root,C,r,o,R,I);return f.createElement("div",{className:H,style:{...O.root,...w,...a}},U,G)}return u??null};Of.Button=vae;Of.Avatar=gae;Of.Input=yae;Of.Image=bae;Of.Node=Yk;function yO(){}const Mae=f.createContext({add:yO,remove:yO});function Rae(e){const t=f.useContext(Mae),n=f.useRef(null);return Mt(o=>{if(o){const i=e?o.querySelector(e):o;i&&(t.add(i),n.current=i);}else t.remove(n.current);})}const SO=()=>{const{cancelButtonProps:e,cancelTextLocale:t,onCancel:n}=f.useContext(Jp);return q.createElement(st,{onClick:n,...e},t)},CO=()=>{const{confirmLoading:e,okButtonProps:t,okType:n,okTextLocale:r,onOk:o}=f.useContext(Jp);return q.createElement(st,{...cR(n),loading:e,onClick:o,...t},r)};function Xk(e,t){return q.createElement("span",{className:`${e}-close-x`},t||q.createElement(Ls,{className:`${e}-close-icon`}))}const Qk=e=>{const{okText:t,okType:n="primary",cancelText:r,confirmLoading:o,onOk:i,onCancel:a,okButtonProps:l,cancelButtonProps:u,footer:d}=e,[m]=Oo("Modal",qz()),p=t||m?.okText,g=r||m?.cancelText,b=q.useMemo(()=>({confirmLoading:o,okButtonProps:l,cancelButtonProps:u,okTextLocale:p,cancelTextLocale:g,okType:n,onOk:i,onCancel:a}),[o,l,u,p,g,n,i,a]);let y;return typeof d=="function"||typeof d>"u"?(y=q.createElement(q.Fragment,null,q.createElement(SO,null),q.createElement(CO,null)),typeof d=="function"&&(y=d(y,{OkBtn:CO,CancelBtn:SO})),y=q.createElement(Hk,{value:b},y)):y=d,q.createElement(mk,{disabled:false},y)},Tae=e=>{const{componentCls:t}=e;return {[t]:{display:"flex",flexFlow:"row wrap",minWidth:0,"&::before, &::after":{display:"flex"},"&-no-wrap":{flexWrap:"nowrap"},"&-start":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"flex-end"},"&-space-between":{justifyContent:"space-between"},"&-space-around":{justifyContent:"space-around"},"&-space-evenly":{justifyContent:"space-evenly"},"&-top":{alignItems:"flex-start"},"&-middle":{alignItems:"center"},"&-bottom":{alignItems:"flex-end"}}}},Aae=e=>{const{componentCls:t}=e;return {[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},Nae=(e,t)=>{const{componentCls:n,gridColumns:r,antCls:o}=e,[i,a]=tr(o,"grid"),[,l]=tr(o,"col"),u={};for(let d=r;d>=0;d--)d===0?(u[`${n}${t}-${d}`]={display:"none"},u[`${n}-push-${d}`]={insetInlineStart:"auto"},u[`${n}-pull-${d}`]={insetInlineEnd:"auto"},u[`${n}${t}-push-${d}`]={insetInlineStart:"auto"},u[`${n}${t}-pull-${d}`]={insetInlineEnd:"auto"},u[`${n}${t}-offset-${d}`]={marginInlineStart:0},u[`${n}${t}-order-${d}`]={order:0}):(u[`${n}${t}-${d}`]=[{[i("display")]:"block",display:"block"},{display:a("display"),flex:`0 0 ${d/r*100}%`,maxWidth:`${d/r*100}%`}],u[`${n}${t}-push-${d}`]={insetInlineStart:`${d/r*100}%`},u[`${n}${t}-pull-${d}`]={insetInlineEnd:`${d/r*100}%`},u[`${n}${t}-offset-${d}`]={marginInlineStart:`${d/r*100}%`},u[`${n}${t}-order-${d}`]={order:d});return u[`${n}${t}-flex`]={flex:l(`${t.replace(/-/,"")}-flex`)},u},lE=(e,t)=>Nae(e,t),Pae=(e,t,n)=>({[`@media (min-width: ${oe(t)})`]:{...lE(e,n)}}),Iae=()=>({}),Oae=()=>({});Wt("Grid",Tae,Iae);const Zk=e=>({xs:e.screenXSMin,sm:e.screenSMMin,md:e.screenMDMin,lg:e.screenLGMin,xl:e.screenXLMin,xxl:e.screenXXLMin});Wt("Grid",e=>{const t=Ft(e,{gridColumns:24}),n=Zk(t);return delete n.xs,[Aae(t),lE(t,""),lE(t,"-xs"),Object.keys(n).map(r=>Pae(t,n[r],`-${r}`)).reduce((r,o)=>({...r,...o}),{})]},Oae);function xO(e){return {position:e,inset:0}}const Dae=e=>{const{componentCls:t,antCls:n}=e;return [{[`${t}-root`]:{[`${t}${n}-zoom-enter, ${t}${n}-zoom-appear`]:{transform:"none",opacity:0,animationDuration:e.motionDurationSlow,userSelect:"none"},[`${t}${n}-zoom-leave ${t}-container`]:{pointerEvents:"none"},[`${t}-mask`]:{...xO("fixed"),zIndex:e.zIndexPopupBase,height:"100%",backgroundColor:e.colorBgMask,pointerEvents:"none",[`&${t}-mask-blur`]:{backdropFilter:"blur(4px)"},[`${t}-hidden`]:{display:"none"}},[`${t}-wrap`]:{...xO("fixed"),zIndex:e.zIndexPopupBase,overflow:"auto",outline:0,WebkitOverflowScrolling:"touch"}}},{[`${t}-root`]:fR(e)}]},_ae=e=>{const{componentCls:t,motionDurationMid:n}=e;return [{[`${t}-root`]:{[`${t}-wrap-rtl`]:{direction:"rtl"},[`${t}-centered`]:{textAlign:"center","&::before":{display:"inline-block",width:0,height:"100%",verticalAlign:"middle",content:'""'},[t]:{top:0,display:"inline-block",paddingBottom:0,textAlign:"start",verticalAlign:"middle"}},[`@media (max-width: ${e.screenSMMax}px)`]:{[t]:{maxWidth:"calc(100vw - 16px)",margin:`${oe(e.marginXS)} auto`},[`${t}-centered`]:{[t]:{flex:1}}}}},{[t]:{...dn(e),pointerEvents:"none",position:"relative",top:100,width:"auto",maxWidth:`calc(100vw - ${oe(e.calc(e.margin).mul(2).equal())})`,margin:"0 auto","&:focus-visible":{borderRadius:e.borderRadiusLG,...ba(e)},[`${t}-title`]:{margin:0,color:e.titleColor,fontWeight:e.fontWeightStrong,fontSize:e.titleFontSize,lineHeight:e.titleLineHeight,wordWrap:"break-word"},[`${t}-container`]:{position:"relative",backgroundColor:e.contentBg,backgroundClip:"padding-box",border:0,borderRadius:e.borderRadiusLG,boxShadow:e.boxShadow,pointerEvents:"auto",padding:e.contentPadding},[`${t}-close`]:{position:"absolute",top:e.calc(e.modalHeaderHeight).sub(e.modalCloseBtnSize).div(2).equal(),insetInlineEnd:e.calc(e.modalHeaderHeight).sub(e.modalCloseBtnSize).div(2).equal(),zIndex:e.calc(e.zIndexPopupBase).add(10).equal(),padding:0,color:e.modalCloseIconColor,fontWeight:e.fontWeightStrong,lineHeight:1,textDecoration:"none",background:"transparent",borderRadius:e.borderRadiusSM,width:e.modalCloseBtnSize,height:e.modalCloseBtnSize,border:0,outline:0,cursor:"pointer",transition:["color","background-color"].map(r=>`${r} ${n}`).join(", "),"&-x":{display:"flex",fontSize:e.fontSizeLG,fontStyle:"normal",lineHeight:oe(e.modalCloseBtnSize),justifyContent:"center",textTransform:"none",textRendering:"auto"},"&:disabled":{pointerEvents:"none"},"&:hover":{color:e.modalCloseIconHoverColor,backgroundColor:e.colorBgTextHover,textDecoration:"none"},"&:active":{backgroundColor:e.colorBgTextActive},...$i(e)},[`${t}-header`]:{color:e.colorText,background:e.headerBg,borderRadius:`${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)} 0 0`,marginBottom:e.headerMarginBottom,padding:e.headerPadding,borderBottom:e.headerBorderBottom},[`${t}-body`]:{fontSize:e.fontSize,lineHeight:e.lineHeight,wordWrap:"break-word",padding:e.bodyPadding,[`${t}-body-skeleton`]:{width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",margin:`${oe(e.margin)} auto`}},[`${t}-footer`]:{textAlign:"end",background:e.footerBg,marginTop:e.footerMarginTop,padding:e.footerPadding,borderTop:e.footerBorderTop,borderRadius:e.footerBorderRadius,[`> ${e.antCls}-btn + ${e.antCls}-btn`]:{marginInlineStart:e.marginXS}},[`${t}-open`]:{overflow:"hidden"}}},{[`${t}-pure-panel`]:{top:"auto",padding:0,display:"flex",flexDirection:"column",[`${t}-container,
${t}-body,
${t}-confirm-body-wrapper`]:{display:"flex",flexDirection:"column",flex:"auto"},[`${t}-confirm-body`]:{marginBottom:"auto"}}}]},Bae=e=>{const{componentCls:t}=e;return {[`${t}-root`]:{[`${t}-wrap-rtl`]:{direction:"rtl",[`${t}-confirm-body`]:{direction:"rtl"}}}}},Lae=e=>{const{componentCls:t}=e,n=Zk(e),r={...n};delete r.xs;const o=`--${t.replace(".","")}-`,i=Object.keys(r).map(a=>({[`@media (min-width: ${oe(r[a])})`]:{width:`var(${o}${a}-width)`}}));return {[`${t}-root`]:{[t]:[].concat(qt(Object.keys(n).map((a,l)=>{const u=Object.keys(n)[l-1];return u?{[`${o}${a}-width`]:`var(${o}${u}-width)`}:null})),[{width:`var(${o}xs-width)`}],qt(i))}}},Jk=e=>{const t=e.padding,n=e.fontSizeHeading5,r=e.lineHeightHeading5;return Ft(e,{modalHeaderHeight:e.calc(e.calc(r).mul(n).equal()).add(e.calc(t).mul(2).equal()).equal(),modalFooterBorderColorSplit:e.colorSplit,modalFooterBorderStyle:e.lineType,modalFooterBorderWidth:e.lineWidth,modalCloseIconColor:e.colorIcon,modalCloseIconHoverColor:e.colorIconHover,modalCloseBtnSize:e.controlHeight,modalConfirmIconSize:e.fontHeight,modalTitleHeight:e.calc(e.titleFontSize).mul(e.titleLineHeight).equal()})},eF=e=>({footerBg:"transparent",headerBg:"transparent",titleLineHeight:e.lineHeightHeading5,titleFontSize:e.fontSizeHeading5,contentBg:e.colorBgElevated,titleColor:e.colorTextHeading,contentPadding:e.wireframe?0:`${oe(e.paddingMD)} ${oe(e.paddingContentHorizontalLG)}`,headerPadding:e.wireframe?`${oe(e.padding)} ${oe(e.paddingLG)}`:0,headerBorderBottom:e.wireframe?`${oe(e.lineWidth)} ${e.lineType} ${e.colorSplit}`:"none",headerMarginBottom:e.wireframe?0:e.marginXS,bodyPadding:e.wireframe?e.paddingLG:0,footerPadding:e.wireframe?`${oe(e.paddingXS)} ${oe(e.padding)}`:0,footerBorderTop:e.wireframe?`${oe(e.lineWidth)} ${e.lineType} ${e.colorSplit}`:"none",footerBorderRadius:e.wireframe?`0 0 ${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)}`:0,footerMarginTop:e.wireframe?0:e.marginSM,confirmBodyPadding:e.wireframe?`${oe(e.padding*2)} ${oe(e.padding*2)} ${oe(e.paddingLG)}`:0,confirmIconMarginInlineEnd:e.wireframe?e.margin:e.marginSM,confirmBtnsMarginTop:e.wireframe?e.marginLG:e.marginSM,mask:true}),tF=Wt("Modal",e=>{const t=Jk(e);return [_ae(t),Bae(t),Dae(t),Zp(t,"zoom"),Lae(t)]},eF,{unitless:{titleLineHeight:true}});let cE;const zae=e=>{cE={x:e.pageX,y:e.pageY},setTimeout(()=>{cE=null;},100);};iae()&&document.documentElement.addEventListener("click",zae,true);const nF=e=>{const{prefixCls:t,className:n,rootClassName:r,open:o,wrapClassName:i,centered:a,getContainer:l,style:u,width:d=520,footer:m,classNames:p,styles:g,children:b,loading:y,confirmLoading:S,zIndex:C,mousePosition:w,onOk:$,onCancel:M,okButtonProps:T,cancelButtonProps:R,destroyOnHidden:I,destroyOnClose:N,panelRef:P=null,closable:O,mask:_,modalRender:B,maskClosable:V,focusTriggerAfterClose:U,focusable:G,...H}=e,{getPopupContainer:z,getPrefixCls:j,direction:W,className:Y,style:Q,classNames:D,styles:L,centered:K,cancelButtonProps:J,okButtonProps:ee,mask:te}=jt("modal"),{modal:re}=f.useContext(wt),[ie,de]=f.useMemo(()=>typeof O=="boolean"?[void 0,void 0]:[O?.afterClose,O?.onClose],[O]),ne=j("modal",t),ce=j(),[fe,se,Me]=Jte(_,te,ne,V),ae=aae(G,fe,U),pe=xt=>{S||(M?.(xt),de?.());},Ce=xt=>{$?.(xt),de?.();},xe=Qn(ne),[Ae,Xe]=tF(ne,xe),Ne=X(i,{[`${ne}-centered`]:a??K,[`${ne}-wrap-rtl`]:W==="rtl"}),ue=m!==null&&!y?f.createElement(Qk,{...e,okButtonProps:{...ee,...T},onOk:Ce,cancelButtonProps:{...J,...R},onCancel:pe}):null,[ge,Pe,je,qe]=tR(kl(e),kl(re),{closable:true,closeIcon:f.createElement(Ls,{className:`${ne}-close-icon`}),closeIconRender:xt=>Xk(ne,xt)}),Ue=ge?{disabled:je,closeIcon:Pe,afterClose:ie,...qe}:false,et=B?xt=>f.createElement("div",{className:`${ne}-render`},B(xt)):void 0,rt=`.${ne}-${B?"render":"container"}`,Ke=Rae(rt),_e=Vr(P,Ke),[We,Ze]=wu("Modal",C),Be={...e,width:d,panelRef:P,focusTriggerAfterClose:ae.focusTriggerAfterClose,focusable:ae,mask:fe,maskClosable:Me,zIndex:We},[Oe,lt]=Kt([D,p,se],[L,g],{props:Be}),[It,mt]=f.useMemo(()=>d&&typeof d=="object"?[void 0,d]:[d,void 0],[d]),Bt=f.useMemo(()=>{const xt={};return mt&&Object.keys(mt).forEach(Tt=>{const ut=mt[Tt];ut!==void 0&&(xt[`--${ne}-${Tt}-width`]=typeof ut=="number"?`${ut}px`:ut);}),xt},[ne,mt]);return f.createElement(Vl,{form:true,space:true},f.createElement(Qy.Provider,{value:Ze},f.createElement(lie,{width:It,...H,zIndex:We,getContainer:l===void 0?z:l,prefixCls:ne,rootClassName:X(Ae,r,Xe,xe,Oe.root),rootStyle:lt.root,footer:ue,visible:o,mousePosition:w??cE,onClose:pe,closable:Ue,closeIcon:Pe,transitionName:Fl(ce,"zoom",e.transitionName),maskTransitionName:Fl(ce,"fade",e.maskTransitionName),mask:fe,maskClosable:Me,className:X(Ae,n,Y),style:{...Q,...u,...Bt},classNames:{...Oe,wrapper:X(Oe.wrapper,Ne)},styles:lt,panelRef:_e,destroyOnHidden:I??N,modalRender:et,focusTriggerAfterClose:ae.focusTriggerAfterClose,focusTrap:ae.trap},y?f.createElement(Of,{active:true,title:false,paragraph:{rows:4},className:`${ne}-body-skeleton`}):b)))},kae=e=>{const{componentCls:t,titleFontSize:n,titleLineHeight:r,modalConfirmIconSize:o,fontSize:i,lineHeight:a,modalTitleHeight:l,fontHeight:u,confirmBodyPadding:d}=e,m=`${t}-confirm`;return {[m]:{"&-rtl":{direction:"rtl"},[`${e.antCls}-modal-header`]:{display:"none"},[`${m}-body-wrapper`]:{...P0()},[`&${t} ${t}-body`]:{padding:d},[`${m}-body`]:{display:"flex",flexWrap:"nowrap",alignItems:"start",[`> ${e.iconCls}`]:{flex:"none",fontSize:o,marginInlineEnd:e.confirmIconMarginInlineEnd,marginTop:e.calc(e.calc(u).sub(o).equal()).div(2).equal()},[`&-has-title > ${e.iconCls}`]:{marginTop:e.calc(e.calc(l).sub(o).equal()).div(2).equal()}},[`${m}-paragraph`]:{display:"flex",flexDirection:"column",flex:"auto",rowGap:e.marginXS,maxWidth:`calc(100% - ${oe(e.marginSM)})`},[`${e.iconCls} + ${m}-paragraph`]:{maxWidth:`calc(100% - ${oe(e.calc(e.modalConfirmIconSize).add(e.marginSM).equal())})`},[`${m}-title`]:{color:e.colorTextHeading,fontWeight:e.fontWeightStrong,fontSize:n,lineHeight:r},[`${m}-container`]:{color:e.colorText,fontSize:i,lineHeight:a},[`${m}-btns`]:{textAlign:"end",marginTop:e.confirmBtnsMarginTop,[`${e.antCls}-btn + ${e.antCls}-btn`]:{marginBottom:0,marginInlineStart:e.marginXS}}},[`${m}-error ${m}-body > ${e.iconCls}`]:{color:e.colorError},[`${m}-warning ${m}-body > ${e.iconCls},
${m}-confirm ${m}-body > ${e.iconCls}`]:{color:e.colorWarning},[`${m}-info ${m}-body > ${e.iconCls}`]:{color:e.colorInfo},[`${m}-success ${m}-body > ${e.iconCls}`]:{color:e.colorSuccess}}},Fae=Nf(["Modal","confirm"],e=>{const t=Jk(e);return kae(t)},eF,{order:-1e3}),rF=e=>{const{prefixCls:t,icon:n,okText:r,cancelText:o,confirmPrefixCls:i,type:a,okCancel:l,footer:u,locale:d,autoFocusButton:m,focusable:p,...g}=e;let b=n;if(!n&&n!==null)switch(a){case "info":b=f.createElement(ZM,null);break;case "success":b=f.createElement(QM,null);break;case "error":b=f.createElement(Kp,null);break;default:b=f.createElement(Yp,null);}const y=l??a==="confirm",S=f.useMemo(()=>{const _=p?.autoFocusButton||m;return _||_===null?_:"ok"},[m,p?.autoFocusButton]),[C]=Oo("Modal"),w=d||C,$=r||(y?w?.okText:w?.justOkText),M=o||w?.cancelText,{closable:T}=g,{onClose:R}=T&&typeof T=="object"?T:{},I=f.useMemo(()=>({autoFocusButton:S,cancelTextLocale:M,okTextLocale:$,mergedOkCancel:y,onClose:R,...g}),[S,M,$,y,R,g]),N=f.createElement(f.Fragment,null,f.createElement(iO,null),f.createElement(aO,null)),P=e.title!==void 0&&e.title!==null,O=`${i}-body`;return f.createElement("div",{className:`${i}-body-wrapper`},f.createElement("div",{className:X(O,{[`${O}-has-title`]:P})},b,f.createElement("div",{className:`${i}-paragraph`},P&&f.createElement("span",{className:`${i}-title`},e.title),f.createElement("div",{className:`${i}-content`},e.content))),u===void 0||typeof u=="function"?f.createElement(Hk,{value:I},f.createElement("div",{className:`${i}-btns`},typeof u=="function"?u(N,{OkBtn:aO,CancelBtn:iO}):N)):u,f.createElement(Fae,{prefixCls:t}))},Hae=e=>{const{close:t,zIndex:n,maskStyle:r,direction:o,prefixCls:i,wrapClassName:a,rootPrefixCls:l,bodyStyle:u,closable:d=false,onConfirm:m,styles:p,title:g,mask:b,maskClosable:y,okButtonProps:S,cancelButtonProps:C}=e,{cancelButtonProps:w,okButtonProps:$}=jt("modal"),M=`${i}-confirm`,T=e.width||416,R=e.style||{},I=X(M,`${M}-${e.type}`,{[`${M}-rtl`]:o==="rtl"},e.className),N=f.useMemo(()=>{const _=z2(b,y);return _.closable??(_.closable=false),_},[b,y]),[,P]=jr(),O=f.useMemo(()=>n!==void 0?n:P.zIndexPopupBase+rR,[n,P]);return f.createElement(nF,{...e,className:I,wrapClassName:X({[`${M}-centered`]:!!e.centered},a),onCancel:()=>{t?.({triggerCancel:true}),m?.(false);},title:g,footer:null,transitionName:Fl(l||"","zoom",e.transitionName),maskTransitionName:Fl(l||"","fade",e.maskTransitionName),mask:N,style:R,styles:{body:u,mask:r,...p},width:T,zIndex:O,closable:d},f.createElement(rF,{...e,confirmPrefixCls:M,okButtonProps:{...$,...S},cancelButtonProps:{...w,...C}}))},oF=e=>{const{rootPrefixCls:t,iconPrefixCls:n,direction:r,theme:o}=e;return f.createElement(Do,{prefixCls:t,iconPrefixCls:n,direction:r,theme:o},f.createElement(Hae,{...e}))},Hc=[];let iF="";function aF(){return iF}const Vae=e=>{const{prefixCls:t,getContainer:n,direction:r}=e,o=qz(),i=f.useContext(wt),a=aF()||i.getPrefixCls(),l=t||`${a}-modal`;let u=n;return u===false&&(u=void 0),q.createElement(oF,{...e,rootPrefixCls:a,prefixCls:l,iconPrefixCls:i.iconPrefixCls,theme:i.theme,direction:r??i.direction,locale:i.locale?.Modal??o,getContainer:u})};function rg(e){const t=iR(),n=document.createDocumentFragment();let r={...e,close:l,open:true},o;function i(...d){d.some(p=>p?.triggerCancel)&&e.onCancel?.(()=>{},...d.slice(1));for(let p=0;p<Hc.length;p++)if(Hc[p]===l){Hc.splice(p,1);break}$k(n).then(()=>{});}const a=d=>{clearTimeout(o),o=setTimeout(()=>{const m=t.getPrefixCls(void 0,aF()),p=t.getIconPrefixCls(),g=t.getTheme(),b=q.createElement(Vae,{...d});t1(q.createElement(Do,{prefixCls:m,iconPrefixCls:p,theme:g},typeof t.holderRender=="function"?t.holderRender(b):b),n);});};function l(...d){r={...r,open:false,afterClose:()=>{typeof e.afterClose=="function"&&e.afterClose(),i.apply(this,d);}},a(r);}function u(d){typeof d=="function"?r=d(r):r={...r,...d},a(r);}return a(r),Hc.push(l),{destroy:l,update:u}}function sF(e){return {...e,type:"warning"}}function lF(e){return {...e,type:"info"}}function cF(e){return {...e,type:"success"}}function uF(e){return {...e,type:"error"}}function dF(e){return {...e,type:"confirm"}}function jae({rootPrefixCls:e}){iF=e;}const Uae=({afterClose:e,config:t,...n},r)=>{const[o,i]=f.useState(true),[a,l]=f.useState(t),{direction:u,getPrefixCls:d}=f.useContext(wt),m=d("modal"),p=d(),g=()=>{e(),a.afterClose?.();},b=(...C)=>{i(false),C.some($=>$?.triggerCancel)&&a.onCancel?.(()=>{},...C.slice(1));};f.useImperativeHandle(r,()=>({destroy:b,update:C=>{l(w=>{const $=typeof C=="function"?C(w):C;return {...w,...$}});}}));const y=a.okCancel??a.type==="confirm",[S]=Oo("Modal",ya.Modal);return f.createElement(oF,{prefixCls:m,rootPrefixCls:p,...a,close:b,open:o,afterClose:g,okText:a.okText||(y?S?.okText:S?.justOkText),direction:a.direction||u,cancelText:a.cancelText||S?.cancelText,...n})},Wae=f.forwardRef(Uae);let wO=0;const Gae=f.memo(f.forwardRef((e,t)=>{const[n,r]=nne();return f.useImperativeHandle(t,()=>({patchElement:r}),[r]),f.createElement(f.Fragment,null,n)}));function fF(){const e=f.useRef(null),[t,n]=f.useState([]);f.useEffect(()=>{t.length&&(qt(t).forEach(a=>{a();}),n([]));},[t]);const r=f.useCallback(i=>function(l){wO+=1;const u=f.createRef();let d;const m=new Promise(S=>{d=S;});let p=false,g;const b=f.createElement(Wae,{key:`modal-${wO}`,config:i(l),ref:u,afterClose:()=>{g?.();},isSilent:()=>p,onConfirm:S=>{d(S);}});return g=e.current?.patchElement(b),g&&Hc.push(g),{destroy:()=>{function S(){u.current?.destroy();}u.current?S():n(C=>[].concat(qt(C),[S]));},update:S=>{function C(){u.current?.update(S);}u.current?C():n(w=>[].concat(qt(w),[C]));},then:S=>(p=true,m.then(S))}},[]);return [f.useMemo(()=>({info:r(lF),success:r(cF),error:r(uF),warning:r(sF),confirm:r(dF)}),[r]),f.createElement(Gae,{key:"modal-holder",ref:e})]}const qae=e=>{const{componentCls:t,notificationMarginEdge:n,animationMaxHeight:r}=e,o=`${t}-notice`,i=new zt("antNotificationFadeIn",{"0%":{transform:"translate3d(100%, 0, 0)",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",opacity:1}}),a=new zt("antNotificationTopFadeIn",{"0%":{top:-r,opacity:0},"100%":{top:0,opacity:1}}),l=new zt("antNotificationBottomFadeIn",{"0%":{bottom:e.calc(r).mul(-1).equal(),opacity:0},"100%":{bottom:0,opacity:1}}),u=new zt("antNotificationLeftFadeIn",{"0%":{transform:"translate3d(-100%, 0, 0)",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",opacity:1}});return {[t]:{[`&${t}-top, &${t}-bottom`]:{marginInline:0,[o]:{marginInline:"auto auto"}},[`&${t}-top`]:{[`${t}-fade-enter${t}-fade-enter-active, ${t}-fade-appear${t}-fade-appear-active`]:{animationName:a}},[`&${t}-bottom`]:{[`${t}-fade-enter${t}-fade-enter-active, ${t}-fade-appear${t}-fade-appear-active`]:{animationName:l}},[`&${t}-topRight, &${t}-bottomRight`]:{[`${t}-fade-enter${t}-fade-enter-active, ${t}-fade-appear${t}-fade-appear-active`]:{animationName:i}},[`&${t}-topLeft, &${t}-bottomLeft`]:{marginRight:{value:0,_skip_check_:true},marginLeft:{value:n,_skip_check_:true},[o]:{marginInlineEnd:"auto",marginInlineStart:0},[`${t}-fade-enter${t}-fade-enter-active, ${t}-fade-appear${t}-fade-appear-active`]:{animationName:u}}}}},Kae=["top","topLeft","topRight","bottom","bottomLeft","bottomRight"],Yae={topLeft:"left",topRight:"right",bottomLeft:"left",bottomRight:"right",top:"left",bottom:"left"},Xae=(e,t)=>{const{componentCls:n}=e;return {[`${n}-${t}`]:{[`&${n}-stack > ${n}-notice-wrapper`]:{[t.startsWith("top")?"top":"bottom"]:0,[Yae[t]]:{value:0,_skip_check_:true}}}}},Qae=e=>{const t={};for(let n=1;n<e.notificationStackLayer;n++)t[`&:nth-last-child(${n+1})`]={overflow:"hidden",[`& > ${e.componentCls}-notice`]:{opacity:0,transition:`opacity ${e.motionDurationMid}`}};return {[`&:not(:nth-last-child(-n+${e.notificationStackLayer}))`]:{opacity:0,overflow:"hidden",color:"transparent",pointerEvents:"none"},...t}},Zae=e=>{const t={};for(let n=1;n<e.notificationStackLayer;n++)t[`&:nth-last-child(${n+1})`]={background:e.colorBgBlur,backdropFilter:"blur(10px)","-webkit-backdrop-filter":"blur(10px)"};return {...t}},Jae=e=>{const{componentCls:t}=e;return {[`${t}-stack`]:{[`& > ${t}-notice-wrapper`]:{transition:`transform ${e.motionDurationSlow}, backdrop-filter 0s`,willChange:"transform, opacity",position:"absolute",...Qae(e)}},[`${t}-stack:not(${t}-stack-expanded)`]:{[`& > ${t}-notice-wrapper`]:{...Zae(e)}},[`${t}-stack${t}-stack-expanded`]:{[`& > ${t}-notice-wrapper`]:{"&:not(:nth-last-child(-n + 1))":{opacity:1,overflow:"unset",color:"inherit",pointerEvents:"auto",[`& > ${e.componentCls}-notice`]:{opacity:1}},"&:after":{content:'""',position:"absolute",height:e.margin,width:"100%",insetInline:0,bottom:e.calc(e.margin).mul(-1).equal(),background:"transparent",pointerEvents:"auto"}}},...Kae.map(n=>Xae(e,n)).reduce((n,r)=>({...n,...r}),{})}},mF=e=>{const{iconCls:t,componentCls:n,boxShadow:r,fontSizeLG:o,notificationMarginBottom:i,borderRadiusLG:a,colorSuccess:l,colorInfo:u,colorWarning:d,colorError:m,colorTextHeading:p,notificationBg:g,notificationPadding:b,notificationMarginEdge:y,progressBg:S,notificationProgressHeight:C,fontSize:w,lineHeight:$,width:M,notificationIconSize:T,colorText:R,colorSuccessBg:I,colorErrorBg:N,colorInfoBg:P,colorWarningBg:O,motionDurationMid:_}=e,B=`${n}-notice`;return {position:"relative",marginBottom:i,marginInlineStart:"auto",background:g,borderRadius:a,boxShadow:r,[B]:{padding:b,width:M,maxWidth:`calc(100vw - ${oe(e.calc(y).mul(2).equal())})`,lineHeight:$,wordWrap:"break-word",borderRadius:a,overflow:"hidden","&-success":I?{background:I}:{},"&-error":N?{background:N}:{},"&-info":P?{background:P}:{},"&-warning":O?{background:O}:{}},[`${B}-title`]:{marginBottom:e.marginXS,color:p,fontSize:o,lineHeight:e.lineHeightLG},[`${B}-description`]:{fontSize:w,color:R,marginTop:e.marginXS},[`${B}-closable ${B}-title`]:{paddingInlineEnd:e.paddingLG},[`${B}-with-icon ${B}-title`]:{marginBottom:e.marginXS,marginInlineStart:e.calc(e.marginSM).add(T).equal(),fontSize:o},[`${B}-with-icon ${B}-description`]:{marginInlineStart:e.calc(e.marginSM).add(T).equal(),fontSize:w},[`${B}-icon`]:{position:"absolute",fontSize:T,lineHeight:1,[`&-success${t}`]:{color:l},[`&-info${t}`]:{color:u},[`&-warning${t}`]:{color:d},[`&-error${t}`]:{color:m}},[`${B}-close`]:{position:"absolute",top:e.notificationPaddingVertical,insetInlineEnd:e.notificationPaddingHorizontal,color:e.colorIcon,outline:"none",width:e.notificationCloseButtonSize,height:e.notificationCloseButtonSize,borderRadius:e.borderRadiusSM,transition:["color","background-color"].map(V=>`${V} ${_}`).join(", "),display:"flex",alignItems:"center",justifyContent:"center",background:"none",border:"none","&:hover":{color:e.colorIconHover,backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive},...$i(e)},[`${B}-progress`]:{position:"absolute",display:"block",appearance:"none",inlineSize:`calc(100% - ${oe(a)} * 2)`,left:{_skip_check_:true,value:a},right:{_skip_check_:true,value:a},bottom:0,blockSize:C,border:0,"&, &::-webkit-progress-bar":{borderRadius:a,backgroundColor:"rgba(0, 0, 0, 0.04)"},"&::-moz-progress-bar":{background:S},"&::-webkit-progress-value":{borderRadius:a,background:S}},[`${B}-actions`]:{float:"right",marginTop:e.marginSM}}},ese=e=>{const{componentCls:t,notificationMarginBottom:n,notificationMarginEdge:r,motionDurationMid:o,motionEaseInOut:i}=e,a=`${t}-notice`,l=new zt("antNotificationFadeOut",{"0%":{maxHeight:e.animationMaxHeight,marginBottom:n},"100%":{maxHeight:0,marginBottom:0,paddingTop:0,paddingBottom:0,opacity:0}});return [{[t]:{...dn(e),position:"fixed",zIndex:e.zIndexPopup,marginRight:{value:r,_skip_check_:true},[`${t}-hook-holder`]:{position:"relative"},[`${t}-fade-appear-prepare`]:{opacity:"0 !important"},[`${t}-fade-enter, ${t}-fade-appear`]:{animationDuration:e.motionDurationMid,animationTimingFunction:i,animationFillMode:"both",opacity:0,animationPlayState:"paused"},[`${t}-fade-leave`]:{animationTimingFunction:i,animationFillMode:"both",animationDuration:o,animationPlayState:"paused"},[`${t}-fade-enter${t}-fade-enter-active, ${t}-fade-appear${t}-fade-appear-active`]:{animationPlayState:"running"},[`${t}-fade-leave${t}-fade-leave-active`]:{animationName:l,animationPlayState:"running"},"&-rtl":{direction:"rtl",[`${a}-actions`]:{float:"left"}}}},{[t]:{[`${a}-wrapper`]:mF(e)}}]},hF=e=>({zIndexPopup:e.zIndexPopupBase+rR+50,width:384,progressBg:`linear-gradient(90deg, ${e.colorPrimaryBorderHover}, ${e.colorPrimary})`,colorSuccessBg:void 0,colorErrorBg:void 0,colorInfoBg:void 0,colorWarningBg:void 0}),pF=e=>{const t=e.paddingMD,n=e.paddingLG;return Ft(e,{notificationBg:e.colorBgElevated,notificationPaddingVertical:t,notificationPaddingHorizontal:n,notificationIconSize:e.calc(e.fontSizeLG).mul(e.lineHeightLG).equal(),notificationCloseButtonSize:e.calc(e.controlHeightLG).mul(.55).equal(),notificationMarginBottom:e.margin,notificationPadding:`${oe(e.paddingMD)} ${oe(e.paddingContentHorizontalLG)}`,notificationMarginEdge:e.marginLG,animationMaxHeight:150,notificationStackLayer:3,notificationProgressHeight:2})},gF=Wt("Notification",e=>{const t=pF(e);return [ese(t),qae(t),Jae(t)]},hF),tse=Nf(["Notification","PurePanel"],e=>{const t=`${e.componentCls}-notice`,n=pF(e);return {[`${t}-pure-panel`]:{...mF(n),width:n.width,maxWidth:`calc(100vw - ${oe(e.calc(n.notificationMarginEdge).mul(2).equal())})`,margin:0}}},hF);function MR(e,t){return t===null||t===false?null:t||f.createElement(Ls,{className:`${e}-close-icon`})}const nse={success:QM,info:ZM,error:Kp,warning:Yp},vF=e=>{const{prefixCls:t,icon:n,type:r,title:o,description:i,actions:a,role:l="alert",styles:u,classNames:d}=e;let m=null;return n?m=f.createElement("span",{className:X(`${t}-icon`,d.icon),style:u.icon},n):r&&(m=f.createElement(nse[r]||null,{className:X(`${t}-icon`,d.icon,`${t}-icon-${r}`),style:u.icon})),f.createElement("div",{className:X({[`${t}-with-icon`]:m}),role:l},m,f.createElement("div",{className:X(`${t}-title`,d.title),style:u.title},o),i&&f.createElement("div",{className:X(`${t}-description`,d.description),style:u.description},i),a&&f.createElement("div",{className:X(`${t}-actions`,d.actions),style:u.actions},a))},rse=e=>{const{prefixCls:t,icon:n,type:r,message:o,title:i,description:a,btn:l,actions:u,closeIcon:d,className:m,style:p,styles:g,classNames:b,closable:y,...S}=e,{getPrefixCls:C,className:w,style:$,classNames:M,styles:T}=jt("notification"),[R,I]=Kt([M,b],[T,g],{props:e}),{notification:N}=f.useContext(wt),P=u??l,O=i??o,_=t||C("notification"),B=`${_}-notice`,V=Qn(_),[U,G]=gF(_,V),[H,z,,j]=tR(kl(e),kl(N),{closable:true,closeIcon:f.createElement(Ls,{className:`${_}-close-icon`}),closeIconRender:Y=>MR(_,Y)}),W=H?{onClose:y&&typeof y=="object"?y?.onClose:void 0,closeIcon:z,...j}:false;return f.createElement("div",{className:X(`${B}-pure-panel`,U,m,G,V,R.root),style:I.root},f.createElement(tse,{prefixCls:_}),f.createElement(aR,{style:{...$,...p},...S,prefixCls:_,eventKey:"pure",duration:null,closable:W,className:X(m,w),content:f.createElement(vF,{classNames:R,styles:I,prefixCls:B,icon:n,type:r,title:O,description:a,actions:P})}))};function ose(e,t,n){let r;switch(e){case "top":r={left:"50%",transform:"translateX(-50%)",right:"auto",top:t,bottom:"auto"};break;case "topLeft":r={left:0,top:t,bottom:"auto"};break;case "topRight":r={right:0,top:t,bottom:"auto"};break;case "bottom":r={left:"50%",transform:"translateX(-50%)",right:"auto",top:"auto",bottom:n};break;case "bottomLeft":r={left:0,top:"auto",bottom:n};break;default:r={right:0,top:"auto",bottom:n};break}return r}function ise(e){return {motionName:`${e}-fade`}}function ase(e,t,n){return typeof e<"u"?e:typeof t?.closeIcon<"u"?t.closeIcon:n?.closeIcon}const $O=24,sse=4.5,lse="topRight",cse=({children:e,prefixCls:t})=>{const n=Qn(t),[r,o]=gF(t,n);return q.createElement(bk,{classNames:{list:X(r,o,n)}},e)},use=(e,{prefixCls:t,key:n})=>q.createElement(cse,{prefixCls:t,key:n},e),dse=q.forwardRef((e,t)=>{const{top:n,bottom:r,prefixCls:o,getContainer:i,maxCount:a,rtl:l,onAllRemoved:u,stack:d,duration:m=sse,pauseOnHover:p=true,showProgress:g}=e,{getPrefixCls:b,getPopupContainer:y,direction:S}=jt("notification"),{notification:C}=f.useContext(wt),[,w]=jr(),$=o||b("notification"),M=f.useMemo(()=>typeof m=="number"&&m>0?m:false,[m]),T=B=>ose(B,n??$O,r??$O),R=()=>X({[`${$}-rtl`]:l??S==="rtl"}),I=()=>ise($),[N,P]=yk({prefixCls:$,style:T,className:R,motion:I,closable:{closeIcon:MR($)},duration:M,getContainer:()=>i?.()||y?.()||document.body,maxCount:a,pauseOnHover:p,showProgress:g,onAllRemoved:u,renderNotifications:use,stack:d===false?false:{threshold:typeof d=="object"?d?.threshold:void 0,offset:8,gap:w.margin}}),[O,_]=Kt([C?.classNames,e?.classNames],[C?.styles,e?.styles],{props:e});return q.useImperativeHandle(t,()=>({...N,prefixCls:$,notification:C,classNames:O,styles:_})),P});function bF(e){const t=q.useRef(null),{notification:n}=q.useContext(wt);return [q.useMemo(()=>{const o=u=>{if(!t.current)return;const{open:d,prefixCls:m,notification:p,classNames:g,styles:b}=t.current,y=p?.className||{},S=p?.style||{},C=`${m}-notice`,{title:w,message:$,description:M,icon:T,type:R,btn:I,actions:N,className:P,style:O,role:_="alert",closeIcon:B,closable:V,classNames:U={},styles:G={},...H}=u,z=w??$,j=N??I,W=MR(C,ase(B,e,p)),[Y,Q,,D]=Yz(kl({...e||{},...u}),kl(n),{closable:true,closeIcon:W}),L=Y?{onClose:V&&typeof V=="object"?V.onClose:void 0,closeIcon:Q,...D}:false,K=Pl(U,{props:u}),J=Pl(G,{props:u}),ee=Xy(void 0,g,K),te=nR(b,J);return d({placement:e?.placement??lse,...H,content:q.createElement(vF,{prefixCls:C,icon:T,type:R,title:z,description:M,actions:j,role:_,classNames:ee,styles:te}),className:X({[`${C}-${R}`]:R},P,y,ee.root),style:{...S,...te.root,...O},closable:L})},a={open:o,destroy:u=>{u!==void 0?t.current?.close(u):t.current?.destroy();}};return ["success","info","warning","error"].forEach(u=>{a[u]=d=>o({...d,type:u});}),a},[e,n]),q.createElement(dse,{key:"notification-holder",...e,ref:t})]}function yF(e){return bF(e)}const V0=q.createContext({}),SF=q.createContext({message:{},notification:{},modal:{}}),fse=e=>{const{componentCls:t,colorText:n,fontSize:r,lineHeight:o,fontFamily:i}=e;return {[t]:{color:n,fontSize:r,lineHeight:o,fontFamily:i,[`&${t}-rtl`]:{direction:"rtl"}}}},mse=()=>({}),hse=Wt("App",fse,mse),pse=e=>{const{prefixCls:t,children:n,className:r,rootClassName:o,message:i,notification:a,style:l,component:u="div"}=e,{direction:d,getPrefixCls:m,className:p,style:g}=jt("app"),b=m("app",t),[y,S]=hse(b),C=X(y,b,r,o,S,{[`${b}-rtl`]:d==="rtl"}),w=f.useContext(V0),$=q.useMemo(()=>({message:{...w.message,...i},notification:{...w.notification,...a}}),[i,a,w.message,w.notification]),[M,T]=wk($.message),[R,I]=yF($.notification),[N,P]=fF(),O=q.useMemo(()=>({message:M,notification:R,modal:N}),[M,R,N]),_=u===false?q.Fragment:u,B={className:X(p,C),style:{...g,...l}};return q.createElement(SF.Provider,{value:O},q.createElement(V0.Provider,{value:$},q.createElement(_,{...u===false?void 0:B},P,T,I,n)))},gse=()=>q.useContext(SF),og=pse;og.useApp=gse;function CF(e){return t=>f.createElement(Do,{theme:{token:{motion:false,zIndexPopupBase:0}}},f.createElement(e,{...t}))}const RR=(e,t,n,r,o)=>CF(a=>{const{prefixCls:l,style:u}=a,d=f.useRef(null),[m,p]=f.useState(0),[g,b]=f.useState(0),[y,S]=un(false,a.open),{getPrefixCls:C}=f.useContext(wt),w=C(r||"select",l);f.useEffect(()=>{if(S(true),typeof ResizeObserver<"u"){const T=new ResizeObserver(I=>{const N=I[0].target;p(N.offsetHeight+8),b(N.offsetWidth);}),R=setInterval(()=>{const I=o?`.${o(w)}`:`.${w}-dropdown`,N=d.current?.querySelector(I);N&&(clearInterval(R),T.observe(N));},10);return ()=>{clearInterval(R),T.disconnect();}}},[w]);let $={...a,style:{...u,margin:0},open:y,getPopupContainer:()=>d.current};n&&($=n($)),t&&Object.assign($,{[t]:{overflow:{adjustX:false,adjustY:false}}});const M={paddingBottom:m,position:"relative",minWidth:g};return f.createElement("div",{ref:d,style:M},f.createElement(e,{...$}))}),vse=(e,t,n,r,o=false,i,a)=>{const l=f.useMemo(()=>typeof n=="boolean"?{allowClear:n}:n&&typeof n=="object"?n:{allowClear:false},[n]);return f.useMemo(()=>{const u=!o&&l.allowClear!==false&&(t.length||i)&&!(a==="combobox"&&i==="");return {allowClear:u,clearIcon:u?l.clearIcon||r||"×":null}},[l,r,o,t.length,i,a])},xF=f.createContext(null);function $u(){return f.useContext(xF)}function bse(e=250){const t=f.useRef(null),n=f.useRef(null);f.useEffect(()=>()=>{window.clearTimeout(n.current);},[]);function r(o){(o||t.current===null)&&(t.current=o),window.clearTimeout(n.current),n.current=window.setTimeout(()=>{t.current=null;},e);}return [()=>t.current,r]}function wF(e,t){return e.filter(n=>n).some(n=>n.contains(t)||n===t)}function yse(e,t,n,r){const o=Mt(i=>{if(r)return;let a=i.target;a.shadowRoot&&i.composed&&(a=i.composedPath()[0]||a),i._ori_target&&(a=i._ori_target),t&&!wF(e(),a)&&n(false);});f.useEffect(()=>(window.addEventListener("mousedown",o),()=>window.removeEventListener("mousedown",o)),[o]);}function uE(){return uE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},uE.apply(this,arguments)}const Sse=e=>{const t=e===true?0:1;return {bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"}}},Cse=(e,t)=>{const{prefixCls:n,disabled:r,visible:o,children:i,popupElement:a,animation:l,transitionName:u,popupStyle:d,popupClassName:m,direction:p="ltr",placement:g,builtinPlacements:b,popupMatchSelectWidth:y,popupRender:S,popupAlign:C,getPopupContainer:w,empty:$,onPopupVisibleChange:M,onPopupMouseEnter:T,onPopupMouseDown:R,onPopupBlur:I,...N}=e,P=`${n}-dropdown`;let O=a;S&&(O=S(a));const _=f.useMemo(()=>b||Sse(y),[b,y]),B=l?`${P}-${l}`:u,V=typeof y=="number",U=f.useMemo(()=>V?null:y===false?"minWidth":"width",[y,V]);let G=d;V&&(G={...d,width:y});const H=f.useRef(null);return f.useImperativeHandle(t,()=>({getPopupElement:()=>H.current?.popupElement})),f.createElement(Jy,uE({},N,{showAction:M?["click"]:[],hideAction:M?["click"]:[],popupPlacement:g||(p==="rtl"?"bottomRight":"bottomLeft"),builtinPlacements:_,prefixCls:P,popupMotion:{motionName:B},popup:f.createElement("div",{onMouseEnter:T,onMouseDown:R,onBlur:I},O),ref:H,stretch:U,popupAlign:C,popupVisible:o,getPopupContainer:w,popupClassName:X(m,{[`${P}-empty`]:$}),popupStyle:G,onPopupVisibleChange:M}),i)},xse=f.forwardRef(Cse);function EO(e,t){const{key:n}=e;let r;return "value"in e&&({value:r}=e),n??(r!==void 0?r:`rc-index-key-${t}`)}function dE(e){return typeof e<"u"&&!Number.isNaN(e)}function $F(e,t){const{label:n,value:r,options:o,groupLabel:i}=e||{},a=n||(t?"children":"label");return {label:a,value:r||"value",options:o||"options",groupLabel:i||a}}function wse(e,{fieldNames:t,childrenAsData:n}={}){const r=[],{label:o,value:i,options:a,groupLabel:l}=$F(t,false);function u(d,m){Array.isArray(d)&&d.forEach(p=>{if(m||!(a in p)){const g=p[i];r.push({key:EO(p,r.length),groupOption:m,data:p,label:p[o],value:g});}else {let g=p[l];g===void 0&&n&&(g=p.label),r.push({key:EO(p,r.length),group:true,data:p,label:g}),u(p[a],true);}});}return u(e,false),r}function fE(e){const t={...e};return "props"in t||Object.defineProperty(t,"props",{get(){return Er(false,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}const $se=(e,t,n)=>{if(!t||!t.length)return null;let r=false;const o=(a,[l,...u])=>{if(!l)return [a];const d=a.split(l);return r=r||d.length>1,d.reduce((m,p)=>[...m,...o(p,u)],[]).filter(Boolean)},i=o(e,t);return r?typeof n<"u"?i.slice(0,n):i:null};function Ese(e){const{visible:t,values:n}=e;if(!t)return null;const r=50;return f.createElement("span",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},`${n.slice(0,r).map(({label:o,value:i})=>["number","string"].includes(typeof o)?o:i).join(", ")}`,n.length>r?", ...":null)}const Mse=e=>{const t=new MessageChannel;t.port1.onmessage=e,t.port2.postMessage(null);},TR=(e,t=1)=>{if(t<=0){e();return}Mse(()=>{TR(e,t-1);});};function Rse(e,t,n,r){const[o,i]=f.useState(false);f.useEffect(()=>{i(true);},[]);const[a,l]=un(e,t),[u,d]=f.useState(false),m=o?a:false,p=r(m),g=f.useRef(0),b=Mt(S=>{n&&p!==S&&n(S),l(S);}),y=Mt((S,C={})=>{const{cancelFun:w}=C;g.current+=1;const $=g.current,M=typeof S=="boolean"?S:!p;d(!M);function T(){$===g.current&&!w?.()&&(b(M),d(false));}M?T():TR(()=>{T();});});return [m,p,y,u]}function Zx(e){const{children:t,...n}=e;return t?f.createElement("div",n,t):null}const EF=f.createContext(null);function ig(){return f.useContext(EF)}const MF=f.forwardRef((e,t)=>{const{onChange:n,onKeyDown:r,onBlur:o,style:i,syncWidth:a,value:l,className:u,autoComplete:d,...m}=e,{prefixCls:p,mode:g,onSearch:b,onSearchSubmit:y,onInputBlur:S,autoFocus:C,tokenWithEnter:w,placeholder:$,components:{input:M="input"}}=ig(),{id:T,classNames:R,styles:I,open:N,activeDescendantId:P,role:O,disabled:_}=$u()||{},B=X(`${p}-input`,R?.input,u),V=f.useRef(false),U=f.useRef(null),G=f.useRef(null);f.useImperativeHandle(t,()=>G.current);const H=ee=>{let{value:te}=ee.target;if(w&&U.current&&/[\r\n]/.test(U.current)){const re=U.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");te=te.replace(re,U.current);}U.current=null,b&&b(te,true,V.current),n?.(ee);},z=ee=>{const{key:te}=ee,{value:re}=ee.currentTarget;te==="Enter"&&g==="tags"&&!V.current&&y&&y(re),r?.(ee);},j=ee=>{S?.(),o?.(ee);},W=()=>{V.current=true;},Y=ee=>{if(V.current=false,g!=="combobox"){const{value:te}=ee.currentTarget;b?.(te,true,false);}},Q=ee=>{const{clipboardData:te}=ee,re=te?.getData("text");U.current=re||"";},[D,L]=f.useState(void 0);An(()=>{const ee=G.current;if(a&&ee){ee.style.width="0px";const te=ee.scrollWidth;L(te),ee.style.width="";}},[a,l]);const K={id:T,type:g==="combobox"?"text":"search",...m,ref:G,style:{...I?.input,...i,"--select-input-width":D},autoFocus:C,autoComplete:d||"off",className:B,disabled:_,value:l||"",onChange:H,onKeyDown:z,onBlur:j,onPaste:Q,onCompositionStart:W,onCompositionEnd:Y,role:O||"combobox","aria-expanded":N||false,"aria-haspopup":"listbox","aria-owns":N?`${T}_list`:void 0,"aria-autocomplete":"list","aria-controls":N?`${T}_list`:void 0,"aria-activedescendant":N?P:void 0};if(f.isValidElement(M)){const ee=M.props||{},te={placeholder:e.placeholder||$,...K,...ee};return Object.keys(ee).forEach(re=>{const ie=ee[re];typeof ie=="function"&&(te[re]=(...de)=>{ie(...de),K[re]?.(...de);});}),te.ref=Vr(M.ref,K.ref),f.cloneElement(M,te)}const J=M;return f.createElement(J,K)});function RF(e){const{prefixCls:t,placeholder:n,displayValues:r}=ig(),{classNames:o,styles:i}=$u(),{show:a=true}=e;return r.length?null:f.createElement("div",{className:X(`${t}-placeholder`,o?.placeholder),style:{visibility:a?"visible":"hidden",...i?.placeholder}},n)}const AR=f.createContext(null);function TF(e){return Array.isArray(e)?e:e!==void 0?[e]:[]}function Tse(e){return e!=null}function Ase(e){return !e&&e!==0}function MO(e){return ["string","number"].includes(typeof e)}function mE(e){let t;return e&&(MO(e.title)?t=e.title.toString():MO(e.label)&&(t=e.label.toString())),t}function hE(){return hE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},hE.apply(this,arguments)}const Nse=f.forwardRef(({inputProps:e},t)=>{const{prefixCls:n,searchValue:r,activeValue:o,displayValues:i,maxLength:a,mode:l}=ig(),{triggerOpen:u,title:d,showSearch:m,classNames:p,styles:g}=$u(),b=f.useContext(AR),[y,S]=f.useState(false),C=l==="combobox",w=i[0],$=f.useMemo(()=>C&&o&&!y&&u?o:m?r:"",[C,o,y,u,r,m]),[M,T,R,I]=f.useMemo(()=>{let O,_,B;if(w&&b?.flattenOptions){const U=b.flattenOptions.find(G=>G.value===w.value);U?.data&&(O=U.data.className,_=U.data.style,B=mE(U.data));}return w&&!B&&(B=mE(w)),d!==void 0&&(B=d),[O,_,B,!!O||!!_]},[w,b?.flattenOptions,d]);f.useEffect(()=>{C&&S(false);},[C,o]);const N=w&&w.label!==null&&w.label!==void 0&&String(w.label).trim()!=="",P=w?I?f.createElement("div",{className:X(`${n}-content-value`,M),style:{...$?{visibility:"hidden"}:{},...T},title:R},w.label):w.label:f.createElement(RF,{show:!$});return f.createElement("div",{className:X(`${n}-content`,N&&`${n}-content-has-value`,$&&`${n}-content-has-search-value`,I&&`${n}-content-has-option-style`,p?.content),style:g?.content,title:I?void 0:R},P,f.createElement(MF,hE({ref:t},e,{value:$,maxLength:l==="combobox"?a:void 0,onChange:O=>{S(true),e.onChange?.(O);}})))}),yd=void 0;function Pse(e,t){const{prefixCls:n,invalidate:r,item:o,renderItem:i,responsive:a,responsiveDisabled:l,registerSize:u,itemKey:d,className:m,style:p,children:g,display:b,order:y,component:S="div",...C}=e,w=a&&!b;function $(N){u(d,N);}f.useEffect(()=>()=>{$(null);},[]);const M=i&&o!==yd?i(o,{index:y}):g;let T;r||(T={opacity:w?0:1,height:w?0:yd,overflowY:w?"hidden":yd,order:a?y:yd,pointerEvents:w?"none":yd,position:w?"absolute":yd});const R={};w&&(R["aria-hidden"]=true);let I=f.createElement(S,cr({className:X(!r&&n,m),style:{...T,...p}},R,C,{ref:t}),M);return a&&(I=f.createElement(ma,{onResize:({offsetWidth:N})=>{$(N);},disabled:l},I)),I}const Ch=f.forwardRef(Pse);function Ise(e){if(typeof MessageChannel>"u")Lt(e);else {const t=new MessageChannel;t.port1.onmessage=()=>e(),t.port2.postMessage(void 0);}}function Ose(){const e=f.useRef(null);return n=>{e.current||(e.current=[],Ise(()=>{$o.unstable_batchedUpdates(()=>{e.current.forEach(r=>{r();}),e.current=null;});})),e.current.push(n);}}function Sd(e,t){const[n,r]=f.useState(t),o=Mt(i=>{e(()=>{r(i);});});return [n,o]}const j0=q.createContext(null),Dse=(e,t)=>{const n=f.useContext(j0);if(!n){const{component:l="div",...u}=e;return f.createElement(l,cr({},u,{ref:t}))}const{className:r,...o}=n,{className:i,...a}=e;return f.createElement(j0.Provider,{value:null},f.createElement(Ch,cr({ref:t,className:X(r,i)},o,a)))},_se=f.forwardRef(Dse),AF="responsive",NF="invalidate";function Bse(e){return `+ ${e.length} ...`}function Lse(e,t){const{prefixCls:n="rc-overflow",data:r=[],renderItem:o,renderRawItem:i,itemKey:a,itemWidth:l=10,ssr:u,style:d,className:m,maxCount:p,renderRest:g,renderRawRest:b,prefix:y,suffix:S,component:C="div",itemComponent:w,onVisibleChange:$,...M}=e,T=u==="full",R=Ose(),[I,N]=Sd(R,null),P=I||0,[O,_]=Sd(R,new Map),[B,V]=Sd(R,0),[U,G]=Sd(R,0),[H,z]=Sd(R,0),[j,W]=Sd(R,0),[Y,Q]=f.useState(null),[D,L]=f.useState(null),K=f.useMemo(()=>D===null&&T?Number.MAX_SAFE_INTEGER:D||0,[D,I]),[J,ee]=f.useState(false),te=`${n}-item`,re=Math.max(B,U),ie=p===AF,de=r.length&&ie,ne=p===NF,ce=de||typeof p=="number"&&r.length>p,fe=f.useMemo(()=>{let _e=r;return de?I===null&&T?_e=r:_e=r.slice(0,Math.min(r.length,P/l)):typeof p=="number"&&(_e=r.slice(0,p)),_e},[r,l,I,p,de]),se=f.useMemo(()=>de?r.slice(K+1):r.slice(fe.length),[r,fe,de,K]),Me=f.useCallback((_e,We)=>typeof a=="function"?a(_e):(a&&_e?.[a])??We,[a]),ae=f.useCallback(o||(_e=>_e),[o]);function pe(_e,We,Ze){D===_e&&(We===void 0||We===Y)||(L(_e),Ze||(ee(_e<r.length-1),$?.(_e)),We!==void 0&&Q(We));}function Ce(_e,We){N(We.clientWidth);}function xe(_e,We){_(Ze=>{const Be=new Map(Ze);return We===null?Be.delete(_e):Be.set(_e,We),Be});}function Ae(_e,We){G(We),V(U);}function Xe(_e,We){z(We);}function Ne(_e,We){W(We);}function ue(_e){return O.get(Me(fe[_e],_e))}An(()=>{if(P&&typeof re=="number"&&fe){let _e=H+j;const We=fe.length,Ze=We-1;if(!We){pe(0,null);return}for(let Be=0;Be<We;Be+=1){let Oe=ue(Be);if(T&&(Oe=Oe||0),Oe===void 0){pe(Be-1,void 0,true);break}if(_e+=Oe,Ze===0&&_e<=P||Be===Ze-1&&_e+ue(Ze)<=P){pe(Ze,null);break}else if(_e+re>P){pe(Be-1,_e-Oe-j+U);break}}S&&ue(0)+j>P&&Q(null);}},[P,O,U,H,j,Me,fe]);const ge=J&&!!se.length;let Pe={};Y!==null&&de&&(Pe={position:"absolute",left:Y,top:0});const je={prefixCls:te,responsive:de,component:w,invalidate:ne},qe=i?(_e,We)=>{const Ze=Me(_e,We);return f.createElement(j0.Provider,{key:Ze,value:{...je,order:We,item:_e,itemKey:Ze,registerSize:xe,display:We<=K}},i(_e,We))}:(_e,We)=>{const Ze=Me(_e,We);return f.createElement(Ch,cr({},je,{order:We,key:Ze,item:_e,renderItem:ae,itemKey:Ze,registerSize:xe,display:We<=K}))},Ue={order:ge?K:Number.MAX_SAFE_INTEGER,className:`${te}-rest`,registerSize:Ae,display:ge},et=g||Bse,rt=b?f.createElement(j0.Provider,{value:{...je,...Ue}},b(se)):f.createElement(Ch,cr({},je,Ue),typeof et=="function"?et(se):et),Ke=f.createElement(C,cr({className:X(!ne&&n,m),style:d,ref:t},M),y&&f.createElement(Ch,cr({},je,{responsive:ie,responsiveDisabled:!de,order:-1,className:`${te}-prefix`,registerSize:Xe,display:true}),y),fe.map(qe),ce?rt:null,S&&f.createElement(Ch,cr({},je,{responsive:ie,responsiveDisabled:!de,order:K,className:`${te}-suffix`,registerSize:Ne,display:true,style:Pe}),S));return ie?f.createElement(ma,{onResize:Ce,disabled:!de},Ke):Ke}const Ts=f.forwardRef(Lse);Ts.Item=_se;Ts.RESPONSIVE=AF;Ts.INVALIDATE=NF;const PF=e=>{const{className:t,style:n,customizeIcon:r,customizeIconProps:o,children:i,onMouseDown:a,onClick:l}=e,u=typeof r=="function"?r(o):r;return f.createElement("span",{className:t,onMouseDown:d=>{d.preventDefault(),a?.(d);},style:{userSelect:"none",WebkitUserSelect:"none",...n},unselectable:"on",onClick:l,"aria-hidden":true},u!==void 0?u:f.createElement("span",{className:X(t.split(/\s+/).map(d=>`${d}-icon`))},i))};function pE(){return pE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},pE.apply(this,arguments)}function zse(e){return e.key??e.value}const RO=e=>{e.preventDefault(),e.stopPropagation();},kse=f.forwardRef(function({inputProps:t},n){const{prefixCls:r,displayValues:o,searchValue:i,mode:a,onSelectorRemove:l,removeIcon:u}=ig(),{disabled:d,showSearch:m,triggerOpen:p,rawOpen:g,toggleOpen:b,autoClearSearchValue:y,tagRender:S,maxTagPlaceholder:C,maxTagTextLength:w,maxTagCount:$,classNames:M,styles:T}=$u(),R=`${r}-selection-item`;let I=i;!g&&a==="multiple"&&y!==false&&(I="");const N=m&&I||"",P=m&&!d,O=u??"×",_=C??(W=>`+ ${W.length} ...`),B=S,V=W=>{b(W);},U=W=>{l?.(W);},G=(W,Y,Q,D,L)=>f.createElement("span",{title:mE(W),className:X(R,{[`${R}-disabled`]:Q},M?.item),style:T?.item},f.createElement("span",{className:X(`${R}-content`,M?.itemContent),style:T?.itemContent},Y),D&&f.createElement(PF,{className:X(`${R}-remove`,M?.itemRemove),style:T?.itemRemove,onMouseDown:RO,onClick:L,customizeIcon:O},"×")),H=(W,Y,Q,D,L,K,J)=>{const ee=te=>{RO(te),V(!p);};return f.createElement("span",{onMouseDown:ee},B({label:Y,value:W,index:J?.index,disabled:Q,closable:D,onClose:L,isMaxTag:!!K}))},z=(W,Y)=>{const{disabled:Q,label:D,value:L}=W,K=!d&&!Q;let J=D;if(typeof w=="number"&&(typeof D=="string"||typeof D=="number")){const te=String(J);te.length>w&&(J=`${te.slice(0,w)}...`);}const ee=te=>{te&&te.stopPropagation(),U(W);};return typeof B=="function"?H(L,J,Q,K,ee,void 0,Y):G(W,J,Q,K,ee)},j=W=>{if(!o.length)return null;const Y=typeof _=="function"?_(W):_;return typeof B=="function"?H(void 0,Y,false,false,void 0,true):G({title:Y},Y,false)};return f.createElement(Ts,{prefixCls:`${r}-content`,className:M?.content,style:T?.content,prefix:!o.length&&!N&&f.createElement(RF,null),data:o,renderItem:z,renderRest:j,suffix:f.createElement(MF,pE({ref:n,disabled:d,readOnly:!P},t,{value:N||"",syncWidth:true})),itemKey:zse,maxCount:$})}),Fse=f.forwardRef(function(t,n){const{multiple:r,onInputKeyDown:o,tabIndex:i}=ig(),a=$u(),{showSearch:l}=a,d={...yo(a,{aria:true}),onKeyDown:o,readOnly:!l,tabIndex:i};return r?f.createElement(kse,{ref:n,inputProps:d}):f.createElement(Nse,{ref:n,inputProps:d})});function Hse(e){return e&&![it.ESC,it.SHIFT,it.BACKSPACE,it.TAB,it.WIN_KEY,it.ALT,it.META,it.WIN_KEY_RIGHT,it.CTRL,it.SEMICOLON,it.EQUALS,it.CAPS_LOCK,it.CONTEXT_MENU,it.UP,it.LEFT,it.RIGHT,it.F1,it.F2,it.F3,it.F4,it.F5,it.F6,it.F7,it.F8,it.F9,it.F10,it.F11,it.F12].includes(e)}function U0(){return U0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},U0.apply(this,arguments)}const Vse=["value","onChange","removeIcon","placeholder","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex","activeValue","onSelectorRemove","focused"],jse=f.forwardRef(function(t,n){const{prefixCls:r,className:o,style:i,prefix:a,suffix:l,clearIcon:u,children:d,multiple:m,displayValues:p,placeholder:g,mode:b,searchValue:y,onSearch:S,onSearchSubmit:C,onInputBlur:w,maxLength:$,autoFocus:M,onMouseDown:T,onClearMouseDown:R,onInputKeyDown:I,onSelectorRemove:N,tokenWithEnter:P,components:O,..._}=t,{triggerOpen:B,toggleOpen:V,showSearch:U,disabled:G,loading:H,classNames:z,styles:j}=$u(),W=f.useRef(null),Y=f.useRef(null),Q=Mt(re=>{const{which:ie}=re,de=Y.current instanceof HTMLTextAreaElement;if(!de&&B&&(ie===it.UP||ie===it.DOWN)&&re.preventDefault(),I&&I(re),de&&!B&&~[it.UP,it.DOWN,it.LEFT,it.RIGHT].indexOf(ie))return;!(re.ctrlKey||re.altKey||re.metaKey)&&Hse(ie)&&V(true);});f.useImperativeHandle(n,()=>({focus:re=>{(Y.current||W.current).focus?.(re);},blur:()=>{(Y.current||W.current).blur?.();},nativeElement:W.current}));const D=Mt(re=>{if(!G){const ie=of(Y.current);re.nativeEvent._ori_target=ie,ie&&re.target!==ie&&!ie.contains(re.target)&&re.preventDefault();const de=B&&!m&&(b==="combobox"||U);re.nativeEvent._select_lazy?B&&V(false):(Y.current?.focus(),de||V());}T?.(re);}),{root:L}=O,K=Ln(_,Vse),J=yo(K,{aria:true}),ee=Object.keys(J),te={...t,onInputKeyDown:Q};return L?f.isValidElement(L)?f.cloneElement(L,{...K,ref:Vr(L.ref,W)}):f.createElement(L,U0({},K,{ref:W})):f.createElement(EF.Provider,{value:te},f.createElement("div",U0({},Ln(K,ee),{ref:W,className:o,style:i,onMouseDown:D}),f.createElement(Zx,{className:X(`${r}-prefix`,z?.prefix),style:j?.prefix},a),f.createElement(Fse,{ref:Y}),f.createElement(Zx,{className:X(`${r}-suffix`,{[`${r}-suffix-loading`]:H},z?.suffix),style:j?.suffix},l),u&&f.createElement(Zx,{className:X(`${r}-clear`,z?.clear),style:j?.clear,onMouseDown:re=>{re.nativeEvent._select_lazy=true,R?.(re);}},u),d))});function Use(e,t,n){return f.useMemo(()=>{let{root:r,input:o}=e||{};return n&&(r=n()),t&&(o=t()),{root:r,input:o}},[e,t,n])}function gE(){return gE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},gE.apply(this,arguments)}const vE=e=>e==="tags"||e==="multiple",Wse=f.forwardRef((e,t)=>{const{id:n,prefixCls:r,className:o,styles:i,classNames:a,showSearch:l,tagRender:u,showScrollBar:d="optional",direction:m,omitDomProps:p,displayValues:g,onDisplayValuesChange:b,emptyOptions:y,notFoundContent:S="Not Found",onClear:C,maxCount:w,placeholder:$,mode:M,disabled:T,loading:R,getInputElement:I,getRawInputElement:N,open:P,defaultOpen:O,onPopupVisibleChange:_,activeValue:B,onActiveValueChange:V,activeDescendantId:U,searchValue:G,autoClearSearchValue:H,onSearch:z,onSearchSplit:j,tokenSeparators:W,allowClear:Y,prefix:Q,suffix:D,suffixIcon:L,clearIcon:K,OptionList:J,animation:ee,transitionName:te,popupStyle:re,popupClassName:ie,popupMatchSelectWidth:de,popupRender:ne,popupAlign:ce,placement:fe,builtinPlacements:se,getPopupContainer:Me,showAction:ae=[],onFocus:pe,onBlur:Ce,onKeyUp:xe,onKeyDown:Ae,onMouseDown:Xe,components:Ne,...ue}=e,ge=vE(M),Pe=f.useRef(null),je=f.useRef(null),qe=f.useRef(null),[Ue,et]=f.useState(false);f.useImperativeHandle(t,()=>({focus:Pe.current?.focus,blur:Pe.current?.blur,scrollTo:tt=>qe.current?.scrollTo(tt),nativeElement:of(Pe.current)}));const rt=Use(Ne,I,N),Ke=f.useMemo(()=>{if(M!=="combobox")return G;const tt=g[0]?.value;return typeof tt=="string"||typeof tt=="number"?String(tt):""},[G,M,g]),_e=M==="combobox"&&typeof I=="function"&&I()||null,We=!S&&y,[Ze,Be,Oe,lt]=Rse(O||false,P,_,tt=>T||We?false:tt),It=f.useMemo(()=>(W||[]).some(tt=>[`
`,`\r
`].includes(tt)),[W]),mt=(tt,yt,At)=>{if(ge&&dE(w)&&g.length>=w)return;let en=true,Zt=tt;V?.(null);const mn=$se(tt,W,dE(w)?w-g.length:void 0),Un=At?null:mn;return M!=="combobox"&&Un&&(Zt="",j?.(Un),Oe(false),en=false),z&&Ke!==Zt&&z(Zt,{source:yt?"typing":"effect"}),tt&&yt&&en&&Oe(true),en},Bt=tt=>{!tt||!tt.trim()||z(tt,{source:"submit"});};f.useEffect(()=>{!Ze&&!ge&&M!=="combobox"&&mt("",false,false);},[Ze]),f.useEffect(()=>{T&&(Oe(false),et(false));},[T,Be]);const[xt,Tt]=bse(),ut=f.useRef(false),dt=tt=>{const yt=xt(),{key:At}=tt,en=At==="Enter",Zt=At===" ";if(en||Zt){const mn=M==="combobox";(Zt&&!(mn||l)||en&&!mn)&&tt.preventDefault(),Be||Oe(true);}if(Tt(!!Ke),At==="Backspace"&&!yt&&ge&&!Ke&&g.length){const mn=[...g];let Un=null;for(let rr=mn.length-1;rr>=0;rr-=1){const vn=mn[rr];if(!vn.disabled){mn.splice(rr,1),Un=vn;break}}Un&&b(mn,{type:"remove",values:[Un]});}Be&&(!en||!ut.current)&&!Zt&&(en&&(ut.current=true),qe.current?.onKeyDown(tt)),Ae?.(tt);},gt=(tt,...yt)=>{Be&&qe.current?.onKeyUp(tt,...yt),tt.key==="Enter"&&(ut.current=false),xe?.(tt,...yt);},Fe=Mt(tt=>{const yt=g.filter(At=>At!==tt);b(yt,{type:"remove",values:[tt]});}),Qe=()=>{ut.current=false;},ye=()=>[of(Pe.current),je.current?.getPopupElement()];yse(ye,Be,Oe,!!rt.root);const be=f.useRef(false),Se=tt=>{et(true),T||(ae.includes("focus")&&Oe(true),pe?.(tt));},he=()=>{Be&&!be.current&&Oe(false,{cancelFun:()=>wF(ye(),document.activeElement)});},De=tt=>{et(false),Ke&&(M==="tags"?z(Ke,{source:"submit"}):M==="multiple"&&z("",{source:"blur"})),he(),T||Ce?.(tt);},$e=(tt,...yt)=>{const{target:At}=tt;je.current?.getPopupElement()?.contains(At)&&Oe&&Oe(true),Xe?.(tt,...yt),be.current=true,TR(()=>{be.current=false;});},[,ke]=f.useState({});function Ge(){ke({});}let ot;rt.root&&(ot=tt=>{Oe(tt);});const ht=f.useMemo(()=>({...e,notFoundContent:S,open:Be,triggerOpen:Be,rawOpen:Ze,id:n,showSearch:l,multiple:ge,toggleOpen:Oe,showScrollBar:d,styles:i,classNames:a,lockOptions:lt}),[e,S,Oe,n,l,ge,Be,Ze,d,i,a,lt]),$t=f.useMemo(()=>{const tt=D??L;return typeof tt=="function"?tt({searchValue:Ke,open:Be,focused:Ue,showSearch:l,loading:R}):tt},[D,L,Ke,Be,Ue,l,R]),Rt=()=>{C?.(),Pe.current?.focus(),b([],{type:"clear",values:g}),mt("",false,false);},{allowClear:Ot,clearIcon:Sn}=vse(r,g,Y,K,T,Ke,M),Hn=f.createElement(J,{ref:qe}),Re=X(r,o,{[`${r}-focused`]:Ue,[`${r}-multiple`]:ge,[`${r}-single`]:!ge,[`${r}-allow-clear`]:Ot,[`${r}-show-arrow`]:$t!=null,[`${r}-disabled`]:T,[`${r}-loading`]:R,[`${r}-open`]:Be,[`${r}-customize-input`]:_e,[`${r}-show-search`]:l});let ct=f.createElement(jse,gE({},ue,{ref:Pe,prefixCls:r,className:Re,focused:Ue,prefix:Q,suffix:$t,clearIcon:Sn,multiple:ge,mode:M,displayValues:g,placeholder:$,searchValue:Ke,activeValue:B,onSearch:mt,onSearchSubmit:Bt,onInputBlur:Qe,onFocus:Se,onBlur:De,onClearMouseDown:Rt,onKeyDown:dt,onKeyUp:gt,onSelectorRemove:Fe,tokenWithEnter:It,onMouseDown:$e,components:rt}));return ct=f.createElement(xse,{ref:je,disabled:T,prefixCls:r,visible:Be,popupElement:Hn,animation:ee,transitionName:te,popupStyle:re,popupClassName:ie,direction:m,popupMatchSelectWidth:de,popupRender:ne,popupAlign:ce,placement:fe,builtinPlacements:se,getPopupContainer:Me,empty:y,onPopupVisibleChange:ot,onPopupMouseEnter:Ge,onPopupMouseDown:$e,onPopupBlur:he},ct),f.createElement(xF.Provider,{value:ht},f.createElement(Ese,{visible:Ue&&!Be,values:g}),ct)}),NR=()=>null;NR.isSelectOptGroup=true;const PR=()=>null;PR.isSelectOption=true;const IF=f.forwardRef(({height:e,offsetY:t,offsetX:n,children:r,prefixCls:o,onInnerResize:i,innerProps:a,rtl:l,extra:u},d)=>{let m={},p={display:"flex",flexDirection:"column"};return t!==void 0&&(m={height:e,position:"relative",overflow:"hidden"},p={...p,transform:`translateY(${t}px)`,[l?"marginRight":"marginLeft"]:-n,position:"absolute",left:0,right:0,top:0}),f.createElement("div",{style:m},f.createElement(ma,{onResize:({offsetHeight:g})=>{g&&i&&i();}},f.createElement("div",cr({style:p,className:X({[`${o}-holder-inner`]:o}),ref:d},a),r,u)))});IF.displayName="Filler";function Gse({children:e,setRef:t}){const n=f.useCallback(r=>{t(r);},[]);return f.cloneElement(e,{ref:n})}function qse(e,t,n,r,o,i,a,{getKey:l}){return e.slice(t,n+1).map((u,d)=>{const m=t+d,p=a(u,m,{style:{width:r},offsetX:o}),g=l(u);return f.createElement(Gse,{key:g,setRef:b=>i(u,b)},p)})}function Kse(e,t,n){const r=e.length,o=t.length;let i,a;if(r===0&&o===0)return null;r<o?(i=e,a=t):(i=t,a=e);const l={__EMPTY_ITEM__:true};function u(p){return p!==void 0?n(p):l}let d=null,m=Math.abs(r-o)!==1;for(let p=0;p<a.length;p+=1){const g=u(i[p]),b=u(a[p]);if(g!==b){d=p,m=m||g!==u(a[p+1]);break}}return d===null?null:{index:d,multiple:m}}function Yse(e,t,n){const[r,o]=f.useState(e),[i,a]=f.useState(null);return f.useEffect(()=>{const l=Kse(r||[],e||[],t);l?.index!==void 0&&a(e[l.index]),o(e);},[e]),[i]}const TO=typeof navigator=="object"&&/Firefox/i.test(navigator.userAgent),OF=((e,t,n,r)=>{const o=f.useRef(false),i=f.useRef(null);function a(){clearTimeout(i.current),o.current=true,i.current=setTimeout(()=>{o.current=false;},50);}const l=f.useRef({top:e,bottom:t,left:n,right:r});return l.current.top=e,l.current.bottom=t,l.current.left=n,l.current.right=r,(u,d,m=false)=>{const p=u?d<0&&l.current.left||d>0&&l.current.right:d<0&&l.current.top||d>0&&l.current.bottom;return m&&p?(clearTimeout(i.current),o.current=false):(!p||o.current)&&a(),!o.current&&p}});function Xse(e,t,n,r,o,i,a){const l=f.useRef(0),u=f.useRef(null),d=f.useRef(null),m=f.useRef(false),p=OF(t,n,r,o);function g($,M){if(Lt.cancel(u.current),p(false,M))return;const T=$;if(!T._virtualHandled)T._virtualHandled=true;else return;l.current+=M,d.current=M,TO||T.preventDefault(),u.current=Lt(()=>{const R=m.current?10:1;a(l.current*R,false),l.current=0;});}function b($,M){a(M,true),TO||$.preventDefault();}const y=f.useRef(null),S=f.useRef(null);function C($){if(!e)return;Lt.cancel(S.current),S.current=Lt(()=>{y.current=null;},2);const{deltaX:M,deltaY:T,shiftKey:R}=$;let I=M,N=T;(y.current==="sx"||!y.current&&R&&T&&!M)&&(I=T,N=0,y.current="sx");const P=Math.abs(I),O=Math.abs(N);y.current===null&&(y.current=i&&P>O?"x":"y"),y.current==="y"?g($,N):b($,I);}function w($){e&&(m.current=$.detail===d.current);}return [C,w]}function Qse(e,t,n,r){const[o,i]=f.useMemo(()=>[new Map,[]],[e,n.id,r]);return (l,u=l)=>{let d=o.get(l),m=o.get(u);if(d===void 0||m===void 0){const p=e.length;for(let g=i.length;g<p;g+=1){const b=e[g],y=t(b);o.set(y,g);const S=n.get(y)??r;if(i[g]=(i[g-1]||0)+S,y===l&&(d=g),y===u&&(m=g),d!==void 0&&m!==void 0)break}}return {top:i[d-1]||0,bottom:i[m]}}}class Zse{maps;id=0;diffRecords=new Map;constructor(){this.maps=Object.create(null);}set(t,n){this.diffRecords.set(t,this.maps[t]),this.maps[t]=n,this.id+=1;}get(t){return this.maps[t]}resetRecord(){this.diffRecords.clear();}getRecord(){return this.diffRecords}}function AO(e){const t=parseFloat(e);return isNaN(t)?0:t}function Jse(e,t,n){const[r,o]=f.useState(0),i=f.useRef(new Map),a=f.useRef(new Zse),l=f.useRef(0);function u(){l.current+=1;}function d(p=false){u();const g=()=>{let b=false;i.current.forEach((y,S)=>{if(y&&y.offsetParent){const{offsetHeight:C}=y,{marginTop:w,marginBottom:$}=getComputedStyle(y),M=AO(w),T=AO($),R=C+M+T;a.current.get(S)!==R&&(a.current.set(S,R),b=true);}}),b&&o(y=>y+1);};if(p)g();else {l.current+=1;const b=l.current;Promise.resolve().then(()=>{b===l.current&&g();});}}function m(p,g){const b=e(p);i.current.get(b),g?(i.current.set(b,g),d()):i.current.delete(b);}return f.useEffect(()=>u,[]),[m,d,a.current,r]}const NO=14/15;function ele(e,t,n){const r=f.useRef(false),o=f.useRef(0),i=f.useRef(0),a=f.useRef(null),l=f.useRef(null);let u;const d=g=>{if(r.current){const b=Math.ceil(g.touches[0].pageX),y=Math.ceil(g.touches[0].pageY);let S=o.current-b,C=i.current-y;const w=Math.abs(S)>Math.abs(C);w?o.current=b:i.current=y;const $=n(w,w?S:C,false,g);$&&g.preventDefault(),clearInterval(l.current),$&&(l.current=setInterval(()=>{w?S*=NO:C*=NO;const M=Math.floor(w?S:C);(!n(w,M,true)||Math.abs(M)<=.1)&&clearInterval(l.current);},16));}},m=()=>{r.current=false,u();},p=g=>{u(),g.touches.length===1&&!r.current&&(r.current=true,o.current=Math.ceil(g.touches[0].pageX),i.current=Math.ceil(g.touches[0].pageY),a.current=g.target,a.current.addEventListener("touchmove",d,{passive:false}),a.current.addEventListener("touchend",m,{passive:true}));};u=()=>{a.current&&(a.current.removeEventListener("touchmove",d),a.current.removeEventListener("touchend",m));},An(()=>(e&&t.current.addEventListener("touchstart",p,{passive:true}),()=>{t.current?.removeEventListener("touchstart",p),u(),clearInterval(l.current);}),[e]);}function PO(e){return Math.floor(e**.5)}function bE(e,t){return ("touches"in e?e.touches[0]:e)[t?"pageX":"pageY"]-window[t?"scrollX":"scrollY"]}function tle(e,t,n){f.useEffect(()=>{const r=t.current;if(e&&r){let o=false,i,a;const l=()=>{Lt.cancel(i);},u=()=>{l(),i=Lt(()=>{n(a),u();});},d=()=>{o=false,l();},m=g=>{if(g.target.draggable||g.button!==0)return;const b=g;b._virtualHandled||(b._virtualHandled=true,o=true);},p=g=>{if(o){const b=bE(g,false),{top:y,bottom:S}=r.getBoundingClientRect();if(b<=y){const C=y-b;a=-PO(C),u();}else if(b>=S){const C=b-S;a=PO(C),u();}else l();}};return r.addEventListener("mousedown",m),r.ownerDocument.addEventListener("mouseup",d),r.ownerDocument.addEventListener("mousemove",p),r.ownerDocument.addEventListener("dragend",d),()=>{r.removeEventListener("mousedown",m),r.ownerDocument.removeEventListener("mouseup",d),r.ownerDocument.removeEventListener("mousemove",p),r.ownerDocument.removeEventListener("dragend",d),l();}}},[e]);}const nle=10;function rle(e,t,n,r,o,i,a,l){const u=f.useRef(),[d,m]=f.useState(null);return An(()=>{if(d&&d.times<nle){if(!e.current){m(M=>({...M}));return}i();const{targetAlign:p,originAlign:g,index:b,offset:y}=d,S=e.current.clientHeight;let C=false,w=p,$=null;if(S){const M=p||g;let T=0,R=0,I=0;const N=Math.min(t.length-1,b);for(let O=0;O<=N;O+=1){const _=o(t[O]);R=T;const B=n.get(_);I=R+(B===void 0?r:B),T=I;}let P=M==="top"?y:S-y;for(let O=N;O>=0;O-=1){const _=o(t[O]),B=n.get(_);if(B===void 0){C=true;break}if(P-=B,P<=0)break}switch(M){case "top":$=R-y;break;case "bottom":$=I-S+y;break;default:{const{scrollTop:O}=e.current,_=O+S;R<O?w="top":I>_&&(w="bottom");}}$!==null&&a($),$!==d.lastTop&&(C=true);}C&&m({...d,times:d.times+1,targetAlign:w,lastTop:$});}},[d,e.current]),p=>{if(p==null){l();return}if(Lt.cancel(u.current),typeof p=="number")a(p);else if(p&&typeof p=="object"){let g;const{align:b}=p;"index"in p?{index:g}=p:g=t.findIndex(S=>o(S)===p.key);const{offset:y=0}=p;m({times:0,index:g,offset:y,originAlign:b});}}}const IO=f.forwardRef((e,t)=>{const{prefixCls:n,rtl:r,scrollOffset:o,scrollRange:i,onStartMove:a,onStopMove:l,onScroll:u,horizontal:d,spinSize:m,containerSize:p,style:g,thumbStyle:b,showScrollBar:y}=e,[S,C]=f.useState(false),[w,$]=f.useState(null),[M,T]=f.useState(null),R=!r,I=f.useRef(),N=f.useRef(),[P,O]=f.useState(y),_=f.useRef(),B=()=>{y===true||y===false||(clearTimeout(_.current),O(true),_.current=setTimeout(()=>{O(false);},3e3));},V=i-p||0,U=p-m||0,G=f.useMemo(()=>o===0||V===0?0:o/V*U,[o,V,U]),H=K=>{K.stopPropagation(),K.preventDefault();},z=f.useRef({top:G,dragging:S,pageY:w,startTop:M});z.current={top:G,dragging:S,pageY:w,startTop:M};const j=K=>{C(true),$(bE(K,d)),T(z.current.top),a(),K.stopPropagation(),K.preventDefault();};f.useEffect(()=>{const K=te=>{te.preventDefault();},J=I.current,ee=N.current;return J.addEventListener("touchstart",K,{passive:false}),ee.addEventListener("touchstart",j,{passive:false}),()=>{J.removeEventListener("touchstart",K),ee.removeEventListener("touchstart",j);}},[]);const W=f.useRef();W.current=V;const Y=f.useRef();Y.current=U,f.useEffect(()=>{if(S){let K;const J=te=>{const{dragging:re,pageY:ie,startTop:de}=z.current;Lt.cancel(K);const ne=I.current.getBoundingClientRect(),ce=p/(d?ne.width:ne.height);if(re){const fe=(bE(te,d)-ie)*ce;let se=de;!R&&d?se-=fe:se+=fe;const Me=W.current,ae=Y.current,pe=ae?se/ae:0;let Ce=Math.ceil(pe*Me);Ce=Math.max(Ce,0),Ce=Math.min(Ce,Me),K=Lt(()=>{u(Ce,d);});}},ee=()=>{C(false),l();};return window.addEventListener("mousemove",J,{passive:true}),window.addEventListener("touchmove",J,{passive:true}),window.addEventListener("mouseup",ee,{passive:true}),window.addEventListener("touchend",ee,{passive:true}),()=>{window.removeEventListener("mousemove",J),window.removeEventListener("touchmove",J),window.removeEventListener("mouseup",ee),window.removeEventListener("touchend",ee),Lt.cancel(K);}}},[S]),f.useEffect(()=>(B(),()=>{clearTimeout(_.current);}),[o]),f.useImperativeHandle(t,()=>({delayHidden:B}));const Q=`${n}-scrollbar`,D={position:"absolute",visibility:P?null:"hidden"},L={position:"absolute",borderRadius:99,background:"var(--rc-virtual-list-scrollbar-bg, rgba(0, 0, 0, 0.5))",cursor:"pointer",userSelect:"none"};return d?(Object.assign(D,{height:8,left:0,right:0,bottom:0}),Object.assign(L,{height:"100%",width:m,[R?"left":"right"]:G})):(Object.assign(D,{width:8,top:0,bottom:0,[R?"right":"left"]:0}),Object.assign(L,{width:"100%",height:m,top:G})),f.createElement("div",{ref:I,className:X(Q,{[`${Q}-horizontal`]:d,[`${Q}-vertical`]:!d,[`${Q}-visible`]:P}),style:{...D,...g},onMouseDown:H,onMouseMove:B},f.createElement("div",{ref:N,className:X(`${Q}-thumb`,{[`${Q}-thumb-moving`]:S}),style:{...L,...b},onMouseDown:j}))}),ole=20;function OO(e=0,t=0){let n=e/t*e;return isNaN(n)&&(n=0),n=Math.max(n,ole),Math.floor(n)}const ile=[],ale={overflowY:"auto",overflowAnchor:"none"};function sle(e,t){const{prefixCls:n="rc-virtual-list",className:r,height:o,itemHeight:i,fullHeight:a=true,style:l,data:u,children:d,itemKey:m,virtual:p,direction:g,scrollWidth:b,component:y="div",onScroll:S,onVirtualScroll:C,onVisibleChange:w,innerProps:$,extraRender:M,styles:T,showScrollBar:R="optional",...I}=e,N=f.useCallback(Se=>typeof m=="function"?m(Se):Se?.[m],[m]),[P,O,_,B]=Jse(N),V=!!(p!==false&&o&&i),U=f.useMemo(()=>Object.values(_.maps).reduce((Se,he)=>Se+he,0),[_.id,_.maps]),G=V&&u&&(Math.max(i*u.length,U)>o||!!b),H=g==="rtl",z=X(n,{[`${n}-rtl`]:H},r),j=u||ile,W=f.useRef(),Y=f.useRef(),Q=f.useRef(),[D,L]=f.useState(0),[K,J]=f.useState(0),[ee,te]=f.useState(false),re=()=>{te(true);},ie=()=>{te(false);},de={getKey:N};function ne(Se){L(he=>{let De;typeof Se=="function"?De=Se(he):De=Se;const $e=Ue(De);return W.current.scrollTop=$e,$e});}const ce=f.useRef({start:0,end:j.length}),fe=f.useRef(),[se]=Yse(j,N);fe.current=se;const{scrollHeight:Me,start:ae,end:pe,offset:Ce}=f.useMemo(()=>{if(!V)return {scrollHeight:void 0,start:0,end:j.length-1,offset:void 0};if(!G)return {scrollHeight:Y.current?.offsetHeight||0,start:0,end:j.length-1,offset:void 0};let Se=0,he,De,$e;const ke=j.length;for(let Ge=0;Ge<ke;Ge+=1){const ot=j[Ge],ht=N(ot),$t=_.get(ht),Rt=Se+($t===void 0?i:$t);Rt>=D&&he===void 0&&(he=Ge,De=Se),Rt>D+o&&$e===void 0&&($e=Ge),Se=Rt;}return he===void 0&&(he=0,De=0,$e=Math.ceil(o/i)),$e===void 0&&($e=j.length-1),$e=Math.min($e+1,j.length-1),{scrollHeight:Se,start:he,end:$e,offset:De}},[G,V,D,j,B,o]);ce.current.start=ae,ce.current.end=pe,f.useLayoutEffect(()=>{const Se=_.getRecord();if(Se.size===1){const he=Array.from(Se.keys())[0],De=Se.get(he),$e=j[ae];if($e&&De===void 0&&N($e)===he){const ot=_.get(he)-i;ne(ht=>ht+ot);}}_.resetRecord();},[Me]);const[xe,Ae]=f.useState({width:0,height:o}),Xe=Se=>{Ae({width:Se.offsetWidth,height:Se.offsetHeight});},Ne=f.useRef(),ue=f.useRef(),ge=f.useMemo(()=>OO(xe.width,b),[xe.width,b]),Pe=f.useMemo(()=>OO(xe.height,Me),[xe.height,Me]),je=Me-o,qe=f.useRef(je);qe.current=je;function Ue(Se){let he=Se;return Number.isNaN(qe.current)||(he=Math.min(he,qe.current)),he=Math.max(he,0),he}const et=D<=0,rt=D>=je,Ke=K<=0,_e=K>=b,We=OF(et,rt,Ke,_e),Ze=()=>({x:H?-K:K,y:D}),Be=f.useRef(Ze()),Oe=Mt(Se=>{if(C){const he={...Ze(),...Se};(Be.current.x!==he.x||Be.current.y!==he.y)&&(C(he),Be.current=he);}});function lt(Se,he){const De=Se;he?($o.flushSync(()=>{J(De);}),Oe()):ne(De);}function It(Se){const{scrollTop:he}=Se.currentTarget;he!==D&&ne(he),S?.(Se),Oe();}const mt=Se=>{let he=Se;const De=b?b-xe.width:0;return he=Math.max(he,0),he=Math.min(he,De),he},Bt=Mt((Se,he)=>{he?($o.flushSync(()=>{J(De=>{const $e=De+(H?-Se:Se);return mt($e)});}),Oe()):ne(De=>De+Se);}),[xt,Tt]=Xse(V,et,rt,Ke,_e,!!b,Bt);ele(V,W,(Se,he,De,$e)=>{const ke=$e;return We(Se,he,De)?false:!ke||!ke._virtualHandled?(ke&&(ke._virtualHandled=true),xt({preventDefault(){},deltaX:Se?he:0,deltaY:Se?0:he}),true):false}),tle(G,W,Se=>{ne(he=>he+Se);}),An(()=>{function Se(De){const $e=et&&De.detail<0,ke=rt&&De.detail>0;V&&!$e&&!ke&&De.preventDefault();}const he=W.current;return he.addEventListener("wheel",xt,{passive:false}),he.addEventListener("DOMMouseScroll",Tt,{passive:true}),he.addEventListener("MozMousePixelScroll",Se,{passive:false}),()=>{he.removeEventListener("wheel",xt),he.removeEventListener("DOMMouseScroll",Tt),he.removeEventListener("MozMousePixelScroll",Se);}},[V,et,rt]),An(()=>{if(b){const Se=mt(K);J(Se),Oe({x:Se});}},[xe.width,b]);const ut=()=>{Ne.current?.delayHidden(),ue.current?.delayHidden();},dt=rle(W,j,_,i,N,()=>O(true),ne,ut);f.useImperativeHandle(t,()=>({nativeElement:Q.current,getScrollInfo:Ze,scrollTo:Se=>{function he(De){return De&&typeof De=="object"&&("left"in De||"top"in De)}he(Se)?(Se.left!==void 0&&J(mt(Se.left)),dt(Se.top)):dt(Se);}})),An(()=>{if(w){const Se=j.slice(ae,pe+1);w(Se,j);}},[ae,pe,j]);const gt=Qse(j,N,_,i),Fe=M?.({start:ae,end:pe,virtual:G,offsetX:K,offsetY:Ce,rtl:H,getSize:gt}),Qe=qse(j,ae,pe,b,K,P,d,de);let ye=null;o&&(ye={[a?"height":"maxHeight"]:o,...ale},V&&(ye.overflowY="hidden",b&&(ye.overflowX="hidden"),ee&&(ye.pointerEvents="none")));const be={};return H&&(be.dir="rtl"),f.createElement("div",cr({ref:Q,style:{...l,position:"relative"},className:z},be,I),f.createElement(ma,{onResize:Xe},f.createElement(y,{className:`${n}-holder`,style:ye,ref:W,onScroll:It,onMouseEnter:ut},f.createElement(IF,{prefixCls:n,height:Me,offsetX:K,offsetY:Ce,scrollWidth:b,onInnerResize:O,ref:Y,innerProps:$,rtl:H,extra:Fe},Qe))),G&&Me>o&&f.createElement(IO,{ref:Ne,prefixCls:n,scrollOffset:D,scrollRange:Me,rtl:H,onScroll:lt,onStartMove:re,onStopMove:ie,spinSize:Pe,containerSize:xe.height,style:T?.verticalScrollBar,thumbStyle:T?.verticalScrollBarThumb,showScrollBar:R}),G&&b>xe.width&&f.createElement(IO,{ref:ue,prefixCls:n,scrollOffset:K,scrollRange:b,rtl:H,onScroll:lt,onStartMove:re,onStopMove:ie,spinSize:ge,containerSize:xe.width,horizontal:true,style:T?.horizontalScrollBar,thumbStyle:T?.horizontalScrollBarThumb,showScrollBar:R}))}const DF=f.forwardRef(sle);DF.displayName="List";function lle(){return /(mac\sos|macintosh)/i.test(navigator.appVersion)}function _h(){return _h=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},_h.apply(this,arguments)}function DO(e){return typeof e=="string"||typeof e=="number"}const cle=(e,t)=>{const{prefixCls:n,id:r,open:o,multiple:i,mode:a,searchValue:l,toggleOpen:u,notFoundContent:d,onPopupScroll:m,showScrollBar:p,lockOptions:g}=$u(),{maxCount:b,flattenOptions:y,onActiveValue:S,defaultActiveFirstOption:C,onSelect:w,menuItemSelectedIcon:$,rawValues:M,fieldNames:T,virtual:R,direction:I,listHeight:N,listItemHeight:P,optionRender:O,classNames:_,styles:B}=f.useContext(AR),V=`${n}-item`,U=Tf(()=>y,[o,g],(ne,ce)=>ce[0]&&!ce[1]),G=f.useRef(null),H=f.useMemo(()=>i&&dE(b)&&M?.size>=b,[i,b,M?.size]),z=ne=>{ne.preventDefault();},j=ne=>{G.current?.scrollTo(typeof ne=="number"?{index:ne}:ne);},W=f.useCallback(ne=>a==="combobox"?false:M.has(ne),[a,[...M].toString(),M.size]),Y=(ne,ce=1)=>{const fe=U.length;for(let se=0;se<fe;se+=1){const Me=(ne+se*ce+fe)%fe,{group:ae,data:pe}=U[Me]||{};if(!ae&&!pe?.disabled&&(W(pe.value)||!H))return Me}return -1},[Q,D]=f.useState(()=>Y(0)),L=(ne,ce=false)=>{D(ne);const fe={source:ce?"keyboard":"mouse"},se=U[ne];if(!se){S(null,-1,fe);return}S(se.value,ne,fe);};f.useEffect(()=>{L(C!==false?Y(0):-1);},[U.length,l]);const K=f.useCallback(ne=>a==="combobox"?String(ne).toLowerCase()===l.toLowerCase():M.has(ne),[a,l,[...M].toString(),M.size]);f.useEffect(()=>{let ne;if(!i&&o&&M.size===1){const ce=Array.from(M)[0],fe=U.findIndex(({data:se})=>l?String(se.value).startsWith(l):se.value===ce);fe!==-1&&(L(fe),ne=setTimeout(()=>{j(fe);}));}return o&&G.current?.scrollTo(void 0),()=>clearTimeout(ne)},[o,l]);const J=ne=>{ne!==void 0&&w(ne,{selected:!M.has(ne)}),i||u(false);};if(f.useImperativeHandle(t,()=>({onKeyDown:ne=>{const{which:ce,ctrlKey:fe}=ne;switch(ce){case it.N:case it.P:case it.UP:case it.DOWN:{let se=0;if(ce===it.UP?se=-1:ce===it.DOWN?se=1:lle()&&fe&&(ce===it.N?se=1:ce===it.P&&(se=-1)),se!==0){const Me=Y(Q+se,se);j(Me),L(Me,true);}break}case it.TAB:case it.ENTER:{const se=U[Q];if(!se||se.data.disabled)return J(void 0);!H||M.has(se.value)?J(se.value):J(void 0),o&&ne.preventDefault();break}case it.ESC:u(false),o&&ne.stopPropagation();}},onKeyUp:()=>{},scrollTo:ne=>{j(ne);}})),U.length===0)return f.createElement("div",{role:"listbox",id:`${r}_list`,className:`${V}-empty`,onMouseDown:z},d);const ee=Object.keys(T).map(ne=>T[ne]),te=ne=>ne.label;function re(ne,ce){const{group:fe}=ne;return {role:fe?"presentation":"option",id:`${r}_list_${ce}`}}const ie=ne=>{const ce=U[ne];if(!ce)return null;const fe=ce.data||{},{value:se}=fe,{group:Me}=ce,ae=yo(fe,true),pe=te(ce);return ce?f.createElement("div",_h({"aria-label":typeof pe=="string"&&!Me?pe:null},ae,{key:ne},re(ce,ne),{"aria-selected":K(se)}),se):null},de={role:"listbox",id:`${r}_list`};return f.createElement(f.Fragment,null,R&&f.createElement("div",_h({},de,{style:{height:0,width:0,overflow:"hidden"}}),ie(Q-1),ie(Q),ie(Q+1)),f.createElement(DF,{itemKey:"key",ref:G,data:U,height:N,itemHeight:P,fullHeight:false,onMouseDown:z,onScroll:m,virtual:R,direction:I,innerProps:R?null:de,showScrollBar:p,className:_?.popup?.list,style:B?.popup?.list},(ne,ce)=>{const{group:fe,groupOption:se,data:Me,label:ae,value:pe}=ne,{key:Ce}=Me;if(fe){const Ze=Me.title??(DO(ae)?ae.toString():void 0);return f.createElement("div",{className:X(V,`${V}-group`,Me.className),title:Ze},ae!==void 0?ae:Ce)}const{disabled:xe,title:Ae,children:Xe,style:Ne,className:ue,...ge}=Me,Pe=Ln(ge,ee),je=W(pe),qe=xe||!je&&H,Ue=`${V}-option`,et=X(V,Ue,ue,_?.popup?.listItem,{[`${Ue}-grouped`]:se,[`${Ue}-active`]:Q===ce&&!qe,[`${Ue}-disabled`]:qe,[`${Ue}-selected`]:je}),rt=te(ne),Ke=!$||typeof $=="function"||je,_e=typeof rt=="number"?rt:rt||pe;let We=DO(_e)?_e.toString():void 0;return Ae!==void 0&&(We=Ae),f.createElement("div",_h({},yo(Pe),R?{}:re(ne,ce),{"aria-selected":R?void 0:K(pe),className:et,title:We,onMouseMove:()=>{Q===ce||qe||L(ce);},onClick:()=>{qe||J(pe);},style:{...B?.popup?.listItem,...Ne}}),f.createElement("div",{className:`${Ue}-content`},typeof O=="function"?O(ne,{index:ce}):_e),f.isValidElement($)||je,Ke&&f.createElement(PF,{className:`${V}-option-state`,customizeIcon:$,customizeIconProps:{value:pe,disabled:qe,isSelected:je}},je?"✓":null))}))},ule=f.forwardRef(cle),dle=((e,t)=>{const n=f.useRef({values:new Map,options:new Map}),r=f.useMemo(()=>{const{values:i,options:a}=n.current,l=e.map(m=>m.label===void 0?{...m,label:i.get(m.value)?.label}:m),u=new Map,d=new Map;return l.forEach(m=>{u.set(m.value,m),d.set(m.value,t.get(m.value)||a.get(m.value));}),n.current.values=u,n.current.options=d,l},[e,t]),o=f.useCallback(i=>t.get(i)||n.current.options.get(i),[t]);return [r,o]});function Jx(e,t){return TF(e).join("").toUpperCase().includes(t)}const fle=((e,t,n,r,o)=>f.useMemo(()=>{if(!n||r===false)return e;const{options:i,label:a,value:l}=t,u=[],d=typeof r=="function",m=n.toUpperCase(),p=d?r:(b,y)=>o&&o.length?o.some(S=>Jx(y[S],m)):y[i]?Jx(y[a!=="children"?a:"label"],m):Jx(y[l],m),g=d?b=>fE(b):b=>b;return e.forEach(b=>{if(b[i]){if(p(n,g(b)))u.push(b);else {const S=b[i].filter(C=>p(n,g(C)));S.length&&u.push({...b,[i]:S});}return}p(n,g(b))&&u.push(b);}),u},[e,r,o,n,t]));function mle(e){const{key:t,props:{children:n,value:r,...o}}=e;return {key:t,value:r!==void 0?r:t,children:n,...o}}function _F(e,t=false){return Qo(e).map((n,r)=>{if(!f.isValidElement(n)||!n.type)return null;const{type:{isSelectOptGroup:o},key:i,props:{children:a,...l}}=n;return t||!o?mle(n):{key:`__RC_SELECT_GRP__${i===null?r:i}__`,label:i,...l,options:_F(a)}}).filter(n=>n)}const hle=(e,t,n,r,o)=>f.useMemo(()=>{let i=e;!e&&(i=_F(t));const l=new Map,u=new Map,d=(p,g,b)=>{b&&typeof b=="string"&&p.set(g[b],g);},m=(p,g=false)=>{for(let b=0;b<p.length;b+=1){const y=p[b];!y[n.options]||g?(l.set(y[n.value],y),d(u,y,n.label),r.forEach(S=>{d(u,y,S);}),d(u,y,o)):m(y[n.options],true);}};return m(i),{options:i,valueOptions:l,labelOptions:u}},[e,t,n,r,o]);function _O(e){const t=f.useRef();return t.current=e,f.useCallback((...r)=>t.current(...r),[])}function ple(e,t,n){const{filterOption:r,searchValue:o,optionFilterProp:i,filterSort:a,onSearch:l,autoClearSearchValue:u}=t;return f.useMemo(()=>{const d=typeof e=="object",m={filterOption:r,searchValue:o,optionFilterProp:i,filterSort:a,onSearch:l,autoClearSearchValue:u,...d?e:{}};return [d||n==="combobox"||n==="tags"||n==="multiple"&&e===void 0?true:e,m]},[n,e,r,o,i,a,l,u])}function yE(){return yE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},yE.apply(this,arguments)}const gle=["inputValue"];function vle(e){return !e||typeof e!="object"}const ble=f.forwardRef((e,t)=>{const{id:n,mode:r,prefixCls:o="rc-select",backfill:i,fieldNames:a,showSearch:l,searchValue:u,onSearch:d,autoClearSearchValue:m,filterOption:p,optionFilterProp:g,filterSort:b,onSelect:y,onDeselect:S,onActive:C,popupMatchSelectWidth:w=true,optionLabelProp:$,options:M,optionRender:T,children:R,defaultActiveFirstOption:I,menuItemSelectedIcon:N,virtual:P,direction:O,listHeight:_=200,listItemHeight:B=20,labelRender:V,value:U,defaultValue:G,labelInValue:H,onChange:z,maxCount:j,classNames:W,styles:Y,...Q}=e,D={searchValue:u,onSearch:d,autoClearSearchValue:m,filterOption:p,optionFilterProp:g,filterSort:b},[L,K]=ple(l,D,r),{filterOption:J,searchValue:ee,optionFilterProp:te,filterSort:re,onSearch:ie,autoClearSearchValue:de=true}=K,ne=f.useMemo(()=>te?Array.isArray(te)?te:[te]:[],[te]),ce=zs(n),fe=vE(r),se=!!(!M&&R),Me=f.useMemo(()=>J===void 0&&r==="combobox"?false:J,[J,r]),ae=f.useMemo(()=>$F(a,se),[JSON.stringify(a),se]),[pe,Ce]=un("",ee),xe=pe||"",Ae=hle(M,R,ae,ne,$),{valueOptions:Xe,labelOptions:Ne,options:ue}=Ae,ge=f.useCallback($e=>TF($e).map(Ge=>{let ot,ht,$t,Rt;vle(Ge)?ot=Ge:(ht=Ge.label,ot=Ge.value);const Ot=Xe.get(ot);return Ot&&(ht===void 0&&(ht=Ot?.[$||ae.label]),$t=Ot?.disabled,Rt=Ot?.title),{label:ht,value:ot,key:ot,disabled:$t,title:Rt}}),[ae,$,Xe]),[Pe,je]=un(G,U),qe=f.useMemo(()=>{const ke=ge(fe&&Pe===null?[]:Pe);return r==="combobox"&&Ase(ke[0]?.value)?[]:ke},[Pe,ge,r,fe]),[Ue,et]=dle(qe,Xe),rt=f.useMemo(()=>{if(!r&&Ue.length===1){const $e=Ue[0];if($e.value===null&&($e.label===null||$e.label===void 0))return []}return Ue.map($e=>({...$e,label:(typeof V=="function"?V($e):$e.label)??$e.value}))},[r,Ue,V]),Ke=f.useMemo(()=>new Set(Ue.map($e=>$e.value)),[Ue]);f.useEffect(()=>{if(r==="combobox"){const $e=Ue[0]?.value;Ce(Tse($e)?String($e):"");}},[Ue]);const _e=_O(($e,ke)=>{const Ge=ke??$e;return {[ae.value]:$e,[ae.label]:Ge}}),We=f.useMemo(()=>{if(r!=="tags")return ue;const $e=[...ue],ke=Ge=>Xe.has(Ge);return [...Ue].sort((Ge,ot)=>Ge.value<ot.value?-1:1).forEach(Ge=>{const ot=Ge.value;ke(ot)||$e.push(_e(ot,Ge.label));}),$e},[_e,ue,Xe,Ue,r]),Ze=fle(We,ae,xe,Me,ne),Be=f.useMemo(()=>{const $e=ke=>ne.length?ne.some(Ge=>ke?.[Ge]===xe):ke?.value===xe;return r!=="tags"||!xe||Ze.some(ke=>$e(ke))||Ze.some(ke=>ke[ae.value]===xe)?Ze:[_e(xe),...Ze]},[_e,ne,r,Ze,xe,ae]),Oe=$e=>[...$e].sort((Ge,ot)=>re(Ge,ot,{searchValue:xe})).map(Ge=>Array.isArray(Ge.options)?{...Ge,options:Ge.options.length>0?Oe(Ge.options):Ge.options}:Ge),lt=f.useMemo(()=>re?Oe(Be):Be,[Be,re,xe]),It=f.useMemo(()=>wse(lt,{fieldNames:ae,childrenAsData:se}),[lt,ae,se]),mt=$e=>{const ke=ge($e);if(je(ke),z&&(ke.length!==Ue.length||ke.some((Ge,ot)=>Ue[ot]?.value!==Ge?.value))){const Ge=H?ke.map(({label:ht,value:$t})=>({label:ht,value:$t})):ke.map(ht=>ht.value),ot=ke.map(ht=>fE(et(ht.value)));z(fe?Ge:Ge[0],fe?ot:ot[0]);}},[Bt,xt]=f.useState(null),[Tt,ut]=f.useState(0),dt=I!==void 0?I:r!=="combobox",gt=f.useRef(),Fe=f.useCallback(($e,ke,{source:Ge="keyboard"}={})=>{ut(ke),i&&r==="combobox"&&$e!==null&&Ge==="keyboard"&&xt(String($e));const ot=Promise.resolve().then(()=>{gt.current===ot&&C?.($e);});gt.current=ot;},[i,r,C]),Qe=($e,ke,Ge)=>{const ot=()=>{const ht=et($e);return [H?{label:ht?.[ae.label],value:$e}:$e,fE(ht)]};if(ke&&y){const[ht,$t]=ot();y(ht,$t);}else if(!ke&&S&&Ge!=="clear"){const[ht,$t]=ot();S(ht,$t);}},ye=_O(($e,ke)=>{let Ge;const ot=fe?ke.selected:true;ot?Ge=fe?[...Ue,$e]:[$e]:Ge=Ue.filter(ht=>ht.value!==$e),mt(Ge),Qe($e,ot),r==="combobox"?xt(""):(!vE||de)&&(Ce(""),xt(""));}),be=($e,ke)=>{mt($e);const{type:Ge,values:ot}=ke;(Ge==="remove"||Ge==="clear")&&ot.forEach(ht=>{Qe(ht.value,false,Ge);});},Se=($e,ke)=>{if(Ce($e),xt(null),ke.source==="submit"){const Ge=($e||"").trim();if(Ge){const ot=Array.from(new Set([...Ke,Ge]));mt(ot),Qe(Ge,true),Ce("");}return}ke.source!=="blur"&&(r==="combobox"&&mt($e),ie?.($e));},he=$e=>{let ke=$e;r!=="tags"&&(ke=$e.map(ot=>Ne.get(ot)?.value).filter(ot=>ot!==void 0));const Ge=Array.from(new Set([...Ke,...ke]));mt(Ge),Ge.forEach(ot=>{Qe(ot,true);});},De=f.useMemo(()=>({...Ae,flattenOptions:It,onActiveValue:Fe,defaultActiveFirstOption:dt,onSelect:ye,menuItemSelectedIcon:N,rawValues:Ke,fieldNames:ae,virtual:P!==false&&w!==false,direction:O,listHeight:_,listItemHeight:B,childrenAsData:se,maxCount:j,optionRender:T,classNames:W,styles:Y}),[j,Ae,It,Fe,dt,ye,N,Ke,ae,P,w,O,_,B,se,T,W,Y]);return f.createElement(AR.Provider,{value:De},f.createElement(Wse,yE({},Q,{id:ce,prefixCls:o,ref:t,omitDomProps:gle,mode:r,classNames:W,styles:Y,displayValues:rt,onDisplayValuesChange:be,maxCount:j,direction:O,showSearch:L,searchValue:xe,onSearch:Se,autoClearSearchValue:de,onSearchSplit:he,popupMatchSelectWidth:w,OptionList:ule,emptyOptions:!It.length,activeValue:Bt,activeDescendantId:`${ce}_list_${Tt}`})))}),IR=ble;IR.Option=PR;IR.OptGroup=NR;const jl=(e,t,n)=>X({[`${e}-status-success`]:t==="success",[`${e}-status-warning`]:t==="warning",[`${e}-status-error`]:t==="error",[`${e}-status-validating`]:t==="validating",[`${e}-has-feedback`]:n}),Df=(e,t)=>t||e,yle=()=>{const[,e]=jr(),[t]=Oo("Empty"),r=new cn(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return f.createElement("svg",{style:r,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},f.createElement("title",null,t?.description||"Empty"),f.createElement("g",{fill:"none",fillRule:"evenodd"},f.createElement("g",{transform:"translate(24 31.7)"},f.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.8",cy:"106.9",rx:"67.8",ry:"12.7"}),f.createElement("path",{fill:"#aeb8c2",d:"M122 69.7 98.1 40.2a6 6 0 0 0-4.6-2.2H42.1a6 6 0 0 0-4.6 2.2l-24 29.5V85H122z"}),f.createElement("path",{fill:"#f5f5f7",d:"M33.8 0h68a4 4 0 0 1 4 4v93.3a4 4 0 0 1-4 4h-68a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4"}),f.createElement("path",{fill:"#dce0e6",d:"M42.7 10h50.2a2 2 0 0 1 2 2v25a2 2 0 0 1-2 2H42.7a2 2 0 0 1-2-2V12a2 2 0 0 1 2-2m.2 39.8h49.8a2.3 2.3 0 1 1 0 4.5H42.9a2.3 2.3 0 0 1 0-4.5m0 11.7h49.8a2.3 2.3 0 1 1 0 4.6H42.9a2.3 2.3 0 0 1 0-4.6m79 43.5a7 7 0 0 1-6.8 5.4H20.5a7 7 0 0 1-6.7-5.4l-.2-1.8V69.7h26.3c2.9 0 5.2 2.4 5.2 5.4s2.4 5.4 5.3 5.4h34.8c2.9 0 5.3-2.4 5.3-5.4s2.3-5.4 5.2-5.4H122v33.5q0 1-.2 1.8"})),f.createElement("path",{fill:"#dce0e6",d:"m149.1 33.3-6.8 2.6a1 1 0 0 1-1.3-1.2l2-6.2q-4.1-4.5-4.2-10.4c0-10 10.1-18.1 22.6-18.1S184 8.1 184 18.1s-10.1 18-22.6 18q-6.8 0-12.3-2.8"}),f.createElement("g",{fill:"#fff",transform:"translate(149.7 15.4)"},f.createElement("circle",{cx:"20.7",cy:"3.2",r:"2.8"}),f.createElement("path",{d:"M5.7 5.6H0L2.9.7zM9.3.7h5v5h-5z"}))))},Sle=()=>{const[,e]=jr(),[t]=Oo("Empty"),{colorFill:n,colorFillTertiary:r,colorFillQuaternary:o,colorBgContainer:i}=e,{borderColor:a,shadowColor:l,contentColor:u}=f.useMemo(()=>({borderColor:new cn(n).onBackground(i).toHexString(),shadowColor:new cn(r).onBackground(i).toHexString(),contentColor:new cn(o).onBackground(i).toHexString()}),[n,r,o,i]);return f.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},f.createElement("title",null,t?.description||"Empty"),f.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},f.createElement("ellipse",{fill:l,cx:"32",cy:"33",rx:"32",ry:"7"}),f.createElement("g",{fillRule:"nonzero",stroke:a},f.createElement("path",{d:"M55 12.8 44.9 1.3Q44 0 42.9 0H21.1q-1.2 0-2 1.3L9 12.8V22h46z"}),f.createElement("path",{d:"M41.6 16c0-1.7 1-3 2.2-3H55v18.1c0 2.2-1.3 3.9-3 3.9H12c-1.7 0-3-1.7-3-3.9V13h11.2c1.2 0 2.2 1.3 2.2 3s1 2.9 2.2 2.9h14.8c1.2 0 2.2-1.4 2.2-3",fill:u}))))},Cle=e=>{const{componentCls:t,margin:n,marginXS:r,marginXL:o,fontSize:i,lineHeight:a}=e;return {[t]:{marginInline:r,fontSize:i,lineHeight:a,textAlign:"center",[`${t}-image`]:{height:e.emptyImgHeight,marginBottom:r,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},[`${t}-description`]:{color:e.colorTextDescription},[`${t}-footer`]:{marginTop:n},"&-normal":{marginBlock:o,color:e.colorTextDescription,[`${t}-description`]:{color:e.colorTextDescription},[`${t}-image`]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:r,color:e.colorTextDescription,[`${t}-image`]:{height:e.emptyImgHeightSM}}}}},xle=Wt("Empty",e=>{const{componentCls:t,controlHeightLG:n,calc:r}=e,o=Ft(e,{emptyImgCls:`${t}-img`,emptyImgHeight:r(n).mul(2.5).equal(),emptyImgHeightMD:n,emptyImgHeightSM:r(n).mul(.875).equal()});return Cle(o)}),BF=f.createElement(yle,null),LF=f.createElement(Sle,null),Vi=e=>{const{className:t,rootClassName:n,prefixCls:r,image:o,description:i,children:a,imageStyle:l,style:u,classNames:d,styles:m,...p}=e,{getPrefixCls:g,direction:b,className:y,style:S,classNames:C,styles:w,image:$}=jt("empty"),M=g("empty",r),[T,R]=xle(M),[I,N]=Kt([C,d],[w,m],{props:e}),[P]=Oo("Empty"),O=typeof i<"u"?i:P?.description,_=typeof O=="string"?O:"empty",B=o??$??BF;let V=null;return typeof B=="string"?V=f.createElement("img",{draggable:false,alt:_,src:B}):V=B,f.createElement("div",{className:X(T,R,M,y,{[`${M}-normal`]:B===LF,[`${M}-rtl`]:b==="rtl"},t,n,I.root),style:{...N.root,...S,...u},...p},f.createElement("div",{className:X(`${M}-image`,I.image),style:{...l,...N.image}},V),O&&f.createElement("div",{className:X(`${M}-description`,I.description),style:N.description},O),a&&f.createElement("div",{className:X(`${M}-footer`,I.footer),style:N.footer},a))};Vi.PRESENTED_IMAGE_DEFAULT=BF;Vi.PRESENTED_IMAGE_SIMPLE=LF;const zF=e=>{const{componentName:t}=e,{getPrefixCls:n}=f.useContext(wt),r=n("empty");switch(t){case "Table":case "List":return q.createElement(Vi,{image:Vi.PRESENTED_IMAGE_SIMPLE});case "Select":case "TreeSelect":case "Cascader":case "Transfer":case "Mentions":return q.createElement(Vi,{image:Vi.PRESENTED_IMAGE_SIMPLE,className:`${r}-small`});case "Table.filter":return null;default:return q.createElement(Vi,null)}},a1=(e,t,n)=>{const{variant:r,[e]:o}=f.useContext(wt),i=f.useContext(oae),a=o?.variant;let l;typeof t<"u"?l=t:n===false?l="borderless":l=i??a??r??"outlined";const u=MJ.includes(l);return [l,u]},wle=e=>{const n={overflow:{adjustX:true,adjustY:true,shiftY:true},htmlRegion:e==="scroll"?"scroll":"visible",dynamicInset:true};return {bottomLeft:{...n,points:["tl","bl"],offset:[0,4]},bottomRight:{...n,points:["tr","br"],offset:[0,4]},topLeft:{...n,points:["bl","tl"],offset:[0,-4]},topRight:{...n,points:["br","tr"],offset:[0,-4]}}};function $le(e,t){return e||wle(t)}const BO=e=>{const{optionHeight:t,optionFontSize:n,optionLineHeight:r,optionPadding:o}=e;return {position:"relative",display:"block",minHeight:t,padding:o,color:e.colorText,fontWeight:"normal",fontSize:n,lineHeight:r,boxSizing:"border-box"}},Ele=e=>{const{antCls:t,componentCls:n}=e,r=`${n}-item`,o=`&${t}-slide-up-enter${t}-slide-up-enter-active`,i=`&${t}-slide-up-appear${t}-slide-up-appear-active`,a=`&${t}-slide-up-leave${t}-slide-up-leave-active`,l=`${n}-dropdown-placement-`,u=`${r}-option-selected`;return [{[`${n}-dropdown`]:{...dn(e),position:"absolute",top:-9999,zIndex:e.zIndexPopup,boxSizing:"border-box",padding:e.paddingXXS,overflow:"hidden",fontSize:e.fontSize,fontVariant:"initial",backgroundColor:e.colorBgElevated,borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,[`
${o}${l}bottomLeft,
${i}${l}bottomLeft
`]:{animationName:mR},[`
${o}${l}topLeft,
${i}${l}topLeft,
${o}${l}topRight,
${i}${l}topRight
`]:{animationName:pR},[`${a}${l}bottomLeft`]:{animationName:hR},[`
${a}${l}topLeft,
${a}${l}topRight
`]:{animationName:gR},"&-hidden":{display:"none"},[r]:{...BO(e),cursor:"pointer",transition:`background-color ${e.motionDurationSlow} ease`,borderRadius:e.borderRadiusSM,"&-group":{color:e.colorTextDescription,fontSize:e.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":{flex:"auto",...Ga},"&-state":{flex:"none",display:"flex",alignItems:"center"},[`&-active:not(${r}-option-disabled)`]:{backgroundColor:e.optionActiveBg},[`&-selected:not(${r}-option-disabled)`]:{color:e.optionSelectedColor,fontWeight:e.optionSelectedFontWeight,backgroundColor:e.optionSelectedBg,[`${r}-option-state`]:{color:e.colorPrimary}},"&-disabled":{[`&${r}-option-selected`]:{backgroundColor:e.colorBgContainerDisabled},color:e.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:e.calc(e.controlPaddingHorizontal).mul(2).equal()}},"&-empty":{...BO(e),color:e.colorTextDisabled}},[`${u}:has(+ ${u})`]:{borderEndStartRadius:0,borderEndEndRadius:0,[`& + ${u}`]:{borderStartStartRadius:0,borderStartEndRadius:0}},"&-rtl":{direction:"rtl"}}},Hl(e,"slide-up"),Hl(e,"slide-down"),z0(e,"move-up"),z0(e,"move-down")]},Mle=e=>{const{componentCls:t}=e;return {[`&${t}-customize`]:{border:0,padding:0,fontSize:"inherit",lineHeight:"inherit",[`${t}-placeholder`]:{display:"none"},[`${t}-content`]:{margin:0,padding:0,"&-value":{display:"none"}}}}},LO=4,Rle=e=>{const{componentCls:t,calc:n,iconCls:r,paddingXS:o,paddingXXS:i,INTERNAL_FIXED_ITEM_MARGIN:a,lineWidth:l,colorIcon:u,colorIconHover:d,inputPaddingHorizontalBase:m,antCls:p}=e,[g,b]=tr(p,"select");return {"&-multiple":{[g("multi-item-background")]:e.multipleItemBg,[g("multi-item-border-color")]:"transparent",[g("multi-item-border-radius")]:e.borderRadiusSM,[g("multi-item-height")]:e.multipleItemHeight,[g("multi-padding-base")]:`calc((${b("height")} - ${b("multi-item-height")}) / 2)`,[g("multi-padding-vertical")]:`calc(${b("multi-padding-base")} - ${a} - ${l})`,[g("multi-item-padding-horizontal")]:`calc(${m} - ${b("multi-padding-vertical")} - ${l} * 2)`,paddingBlock:b("multi-padding-vertical"),paddingInlineStart:`calc(${b("multi-padding-base")} - ${l})`,[`${t}-prefix`]:{marginInlineStart:b("multi-item-padding-horizontal")},[`${t}-prefix + ${t}-content`]:{[`${t}-placeholder`]:{insetInlineStart:0},[`${t}-content-item${t}-content-item-suffix`]:{marginInlineStart:0}},[`${t}-placeholder`]:{position:"absolute",lineHeight:b("line-height"),insetInlineStart:b("multi-item-padding-horizontal"),width:`calc(100% - ${b("multi-item-padding-horizontal")})`,top:"50%",transform:"translateY(-50%)"},[`${t}-content`]:{flexWrap:"wrap",alignItems:"center",lineHeight:1,"&-item-prefix":{height:b("font-size")},"&-item":{lineHeight:1,maxWidth:`calc(100% - ${LO}px)`},[`${t}-content-item-prefix + ${t}-content-item-suffix,
${t}-content-item-suffix:first-child`]:{marginInlineStart:b("multi-item-padding-horizontal")},[`${t}-selection-item`]:{lineHeight:`calc(${b("multi-item-height")} - ${l} * 2)`,border:`${l} solid ${b("multi-item-border-color")}`,display:"flex",marginBlock:a,marginInlineEnd:n(a).mul(2).equal(),background:b("multi-item-background"),borderRadius:b("multi-item-border-radius"),paddingInlineStart:o,paddingInlineEnd:i,transition:["height","line-height","padding"].map(y=>`${y} ${e.motionDurationSlow}`).join(","),"&-content":{...Ga,marginInlineEnd:i},"&-remove":{...Cu(),display:"inline-flex",alignItems:"center",color:u,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",[`> ${r}`]:{verticalAlign:"-0.2em"},"&:hover":{color:d}}},[`${t}-input`]:{lineHeight:n(a).mul(2).add(b("multi-item-height")).equal(),width:"calc(var(--select-input-width, 0) * 1px)",minWidth:LO,maxWidth:"100%",transition:`line-height ${e.motionDurationSlow}`}},[`&${t}-sm`]:{[g("multi-item-height")]:e.multipleItemHeightSM,[g("multi-item-border-radius")]:e.borderRadiusXS},[`&${t}-lg`]:{[g("multi-item-height")]:e.multipleItemHeightLG,[g("multi-item-border-radius")]:e.borderRadius},[`&${t}-filled`]:{[g("multi-item-border-color")]:e.colorSplit,[g("multi-item-background")]:e.colorBgContainer,[`&${t}-disabled`]:{[g("multi-item-border-color")]:"transparent"}}}}},ew=(e,t)=>{const{componentCls:n,antCls:r}=e,[o]=tr(r,"select"),{border:i,borderHover:a,borderActive:l,borderOutline:u}=t,d=t.background||e.selectorBg||e.colorBgContainer;return {[o("border-color")]:i,[o("background-color")]:d,[o("color")]:t.color||e.colorText,[`&:not(${n}-disabled)`]:{"&:hover":{[o("border-color")]:a,[o("background-color")]:t.backgroundHover||d},[`&${n}-focused`]:{[o("border-color")]:l,[o("background-color")]:t.backgroundActive||d,boxShadow:`0 0 0 ${oe(e.controlOutlineWidth)} ${u}`}},[`&${n}-disabled`]:{[o("border-color")]:t.borderDisabled||t.border,[o("background-color")]:t.backgroundDisabled||t.background}}},lb=(e,t,n,r={},o={},i)=>{const{componentCls:a}=e;return {[`&${a}-${t}`]:[ew(e,n),{[`&${a}-status-error`]:ew(e,{...n,color:r.color||e.colorError,...r}),[`&${a}-status-warning`]:ew(e,{...n,color:o.color||e.colorWarning,...o})},i]}},Tle=e=>{const{componentCls:t,fontHeight:n,controlHeight:r,iconCls:o,antCls:i,calc:a}=e,[l,u]=tr(i,"select");return {[t]:[{[l("border-radius")]:e.borderRadius,[l("border-color")]:"#000",[l("border-size")]:e.lineWidth,[l("background-color")]:e.colorBgContainer,[l("font-size")]:e.fontSize,[l("line-height")]:e.lineHeight,[l("font-height")]:n,[l("color")]:e.colorText,[l("height")]:r,[l("padding-horizontal")]:a(e.paddingSM).sub(e.lineWidth).equal(),[l("padding-vertical")]:`calc((${u("height")} - ${u("font-height")}) / 2 - ${u("border-size")})`,...dn(e,true),display:"inline-flex",flexWrap:"nowrap",position:"relative",transition:`all ${e.motionDurationSlow}`,alignItems:"flex-start",outline:0,cursor:"pointer",borderRadius:u("border-radius"),borderWidth:u("border-size"),borderStyle:e.lineType,borderColor:u("border-color"),background:u("background-color"),fontSize:u("font-size"),lineHeight:u("line-height"),color:u("color"),paddingInline:u("padding-horizontal"),paddingBlock:u("padding-vertical"),[`${t}-prefix`]:{flex:"none",lineHeight:1},[`${t}-placeholder`]:{...Ga,color:e.colorTextPlaceholder,pointerEvents:"none",zIndex:1},[`${t}-content`]:{flex:"auto",minWidth:0,position:"relative",display:"flex",marginInlineEnd:a(e.paddingXXS).mul(1.5).equal(),"&:before":{content:'"\\a0"',width:0,overflow:"hidden"},"input[readonly]":{cursor:"inherit",caretColor:"transparent"}},[`${t}-suffix`]:{flex:"none",color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,"> :not(:last-child)":{marginInlineEnd:e.marginXS}},[`${t}-prefix, ${t}-suffix`]:{alignSelf:"center",[o]:{verticalAlign:"top"}},"&-disabled":{background:e.colorBgContainerDisabled,color:e.colorTextDisabled,cursor:"not-allowed",input:{cursor:"not-allowed"}},"&-sm":{[l("height")]:e.controlHeightSM,[l("padding-horizontal")]:a(e.paddingXS).sub(e.lineWidth).equal(),[l("border-radius")]:e.borderRadiusSM,[`${t}-clear`]:{insetInlineEnd:u("padding-horizontal")}},"&-lg":{[l("height")]:e.controlHeightLG,[l("font-size")]:e.fontSizeLG,[l("line-height")]:e.lineHeightLG,[l("font-height")]:e.fontHeightLG,[l("border-radius")]:e.borderRadiusLG}},{[`&:not(${t}-customize)`]:{[`${t}-input`]:{outline:"none",background:"transparent",appearance:"none",border:0,margin:0,padding:0,color:u("color"),"&::-webkit-search-cancel-button":{display:"none",appearance:"none"}}}},{[`&-single:not(${t}-customize)`]:{[`${t}-input`]:{position:"absolute",insetInline:0,insetBlock:`calc(${u("padding-vertical")} * -1)`,lineHeight:`calc(${u("font-height")} + ${u("padding-vertical")} * 2)`},[`${t}-content`]:{...Ga,alignSelf:"center","&-has-value":{display:"block","&:before":{display:"none"}},"&-has-search-value":{color:"transparent"},"&-value":{transition:`all ${e.motionDurationMid} ${e.motionEaseInOut}`,zIndex:1}},[`&${t}-open ${t}-content`]:{color:e.colorTextPlaceholder}}},{[`&-show-search:not(${t}-customize-input):not(${t}-disabled)`]:{cursor:"text"}},Rle(e),lb(e,"outlined",{border:e.colorBorder,borderHover:e.hoverBorderColor,borderActive:e.activeBorderColor,borderOutline:e.activeOutlineColor,borderDisabled:e.colorBorderDisabled},{border:e.colorError,borderHover:e.colorErrorHover,borderActive:e.colorError,borderOutline:e.colorErrorOutline},{border:e.colorWarning,borderHover:e.colorWarningHover,borderActive:e.colorWarning,borderOutline:e.colorWarningOutline}),lb(e,"filled",{border:"transparent",borderHover:"transparent",borderActive:e.activeBorderColor,borderOutline:"transparent",borderDisabled:e.colorBorderDisabled,background:e.colorFillTertiary,backgroundHover:e.colorFillSecondary,backgroundActive:e.colorBgContainer},{background:e.colorErrorBg,backgroundHover:e.colorErrorBgHover,borderActive:e.colorError},{background:e.colorWarningBg,backgroundHover:e.colorWarningBgHover,borderActive:e.colorWarning}),lb(e,"borderless",{border:"transparent",borderHover:"transparent",borderActive:"transparent",borderOutline:"transparent",background:"transparent"}),lb(e,"underlined",{border:e.colorBorder,borderHover:e.hoverBorderColor,borderActive:e.activeBorderColor,borderOutline:"transparent"},{border:e.colorError,borderHover:e.colorErrorHover,borderActive:e.colorError},{border:e.colorWarning,borderHover:e.colorWarningHover,borderActive:e.colorWarning},{borderRadius:0,borderTopColor:"transparent",borderRightColor:"transparent",borderLeftColor:"transparent"}),Mle(e)]}},Ale=e=>{const{fontSize:t,lineHeight:n,lineWidth:r,controlHeight:o,controlHeightSM:i,controlHeightLG:a,paddingXXS:l,controlPaddingHorizontal:u,zIndexPopupBase:d,colorText:m,fontWeightStrong:p,controlItemBgActive:g,controlItemBgHover:b,colorBgContainer:y,colorFillSecondary:S,colorBgContainerDisabled:C,colorTextDisabled:w,colorPrimaryHover:$,colorPrimary:M,controlOutline:T}=e,R=l*2,I=r*2,N=Math.min(o-R,o-I),P=Math.min(i-R,i-I),O=Math.min(a-R,a-I);return {INTERNAL_FIXED_ITEM_MARGIN:Math.floor(l/2),zIndexPopup:d+50,optionSelectedColor:m,optionSelectedFontWeight:p,optionSelectedBg:g,optionActiveBg:b,optionPadding:`${(o-t*n)/2}px ${u}px`,optionFontSize:t,optionLineHeight:n,optionHeight:o,selectorBg:y,clearBg:y,singleItemHeightLG:a,multipleItemBg:S,multipleItemBorderColor:"transparent",multipleItemHeight:N,multipleItemHeightSM:P,multipleItemHeightLG:O,multipleSelectorBgDisabled:C,multipleItemColorDisabled:w,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(e.fontSize*1.25),hoverBorderColor:$,activeBorderColor:M,activeOutlineColor:T,selectAffixPadding:l}},Nle=e=>{const{antCls:t,componentCls:n,motionDurationMid:r,inputPaddingHorizontalBase:o}=e,i={[`${n}-clear`]:{opacity:1,background:e.colorBgBase,borderRadius:"50%"}};return {[n]:{...dn(e),[`${n}-selection-item`]:{flex:1,fontWeight:"normal",position:"relative",userSelect:"none",...Ga,[`> ${t}-typography`]:{display:"inline"}},[`${n}-prefix`]:{flex:"none",marginInlineEnd:e.selectAffixPadding},[`${n}-clear`]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:o,zIndex:1,display:"inline-block",width:e.fontSizeIcon,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:["color","opacity"].map(a=>`${a} ${r} ease`).join(", "),textRendering:"auto",transform:"translateZ(0)","&:before":{display:"block"},"&:hover":{color:e.colorIcon}},"@media(hover:none)":i,"&:hover":i},[`${n}-status`]:{"&-error, &-warning, &-success, &-validating":{[`&${n}-has-feedback`]:{[`${n}-clear`]:{insetInlineEnd:e.calc(o).add(e.fontSize).add(e.paddingXS).equal()}}}}}},Ple=e=>{const{componentCls:t}=e;return [{[t]:{[`&${t}-in-form-item`]:{width:"100%"}}},Nle(e),Ele(e),{[`${t}-rtl`]:{direction:"rtl"}},If(e,{focusElCls:`${t}-focused`})]},Ile=Wt("Select",(e,{rootPrefixCls:t})=>{const n=Ft(e,{rootPrefixCls:t,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(e.lineWidth).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return [Ple(n),Tle(n)]},Ale,{unitless:{optionLineHeight:true,optionSelectedFontWeight:true}});var Ole={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"};function SE(){return SE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},SE.apply(this,arguments)}const Dle=(e,t)=>f.createElement(Xn,SE({},e,{ref:t,icon:Ole})),_le=f.forwardRef(Dle);var Ble={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"};function CE(){return CE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},CE.apply(this,arguments)}const Lle=(e,t)=>f.createElement(Xn,CE({},e,{ref:t,icon:Ble})),OR=f.forwardRef(Lle);var zle={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"};function xE(){return xE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},xE.apply(this,arguments)}const kle=(e,t)=>f.createElement(Xn,xE({},e,{ref:t,icon:zle})),DR=f.forwardRef(kle);function Fle({suffixIcon:e,clearIcon:t,menuItemSelectedIcon:n,removeIcon:r,loading:o,loadingIcon:i,multiple:a,hasFeedback:l,showSuffixIcon:u,feedbackIcon:d,showArrow:m,componentName:p}){const g=t??f.createElement(Kp,null),b=w=>e===null&&!l&&!m?null:f.createElement(f.Fragment,null,u!==false&&w,l&&d);let y=null;e!==void 0?y=b(e):o?y=b(i??f.createElement(e1,{spin:true})):y=({open:w,showSearch:$})=>b(w&&$?f.createElement(DR,null):f.createElement(OR,null));let S=null;n!==void 0?S=n:a?S=f.createElement(_le,null):S=null;let C=null;return r!==void 0?C=r:C=f.createElement(Ls,null),{clearIcon:g,suffixIcon:y,itemIcon:S,removeIcon:C}}function Hle(e){return q.useMemo(()=>{if(e)return (...t)=>q.createElement(Vl,{space:true},e.apply(void 0,t))},[e])}function Vle(e,t){return t!==void 0?t:e!==null}const kF="SECRET_COMBOBOX_MODE_DO_NOT_USE",jle=(e,t)=>{const{prefixCls:n,bordered:r,className:o,rootClassName:i,getPopupContainer:a,popupClassName:l,dropdownClassName:u,listHeight:d=256,placement:m,listItemHeight:p,size:g,disabled:b,notFoundContent:y,status:S,builtinPlacements:C,dropdownMatchSelectWidth:w,popupMatchSelectWidth:$,direction:M,style:T,allowClear:R,variant:I,popupStyle:N,dropdownStyle:P,transitionName:O,tagRender:_,maxCount:B,prefix:V,dropdownRender:U,popupRender:G,onDropdownVisibleChange:H,onOpenChange:z,styles:j,classNames:W,...Y}=e,{getPopupContainer:Q,getPrefixCls:D,renderEmpty:L,direction:K,virtual:J,popupMatchSelectWidth:ee,popupOverflow:te}=f.useContext(wt),{showSearch:re,style:ie,styles:de,className:ne,classNames:ce}=jt("select"),[,fe]=jr(),se=p??fe?.controlHeight,Me=D("select",n),ae=D(),pe=M??K,{compactSize:Ce,compactItemClassnames:xe}=ks(Me,pe),[Ae,Xe]=a1("select",I,r),Ne=Qn(Me),[ue,ge]=Ile(Me,Ne),Pe=f.useMemo(()=>{const{mode:ke}=e;if(ke!=="combobox")return ke===kF?"combobox":ke},[e.mode]),je=Pe==="multiple"||Pe==="tags",qe=Vle(e.suffixIcon,e.showArrow),Ue=$??w??ee,et=Hle(G||U),rt=z||H,{status:Ke,hasFeedback:_e,isFormItemInput:We,feedbackIcon:Ze}=f.useContext(So),Be=Df(Ke,S);let Oe;y!==void 0?Oe=y:Pe==="combobox"?Oe=null:Oe=L?.("Select")||f.createElement(zF,{componentName:"Select"});const{suffixIcon:lt,itemIcon:It,removeIcon:mt,clearIcon:Bt}=Fle({...Y,multiple:je,hasFeedback:_e,feedbackIcon:Ze,showSuffixIcon:qe,componentName:"Select"}),xt=R===true?{clearIcon:Bt}:R,Tt=Ln(Y,["suffixIcon","itemIcon"]),ut=so(ke=>g??Ce??ke),dt=f.useContext(no),gt=b??dt,Fe={...e,variant:Ae,status:Be,disabled:gt,size:ut},[Qe,ye]=Kt([ce,W],[de,j],{props:Fe},{popup:{_default:"root"}}),be=X(Qe.popup?.root,l,u,{[`${Me}-dropdown-${pe}`]:pe==="rtl"},i,ge,Ne,ue),Se={...ye.popup?.root,...N??P},he=X({[`${Me}-lg`]:ut==="large",[`${Me}-sm`]:ut==="small",[`${Me}-rtl`]:pe==="rtl",[`${Me}-${Ae}`]:Xe,[`${Me}-in-form-item`]:We},jl(Me,Be,_e),xe,ne,o,Qe.root,i,ge,Ne,ue),De=f.useMemo(()=>m!==void 0?m:pe==="rtl"?"bottomRight":"bottomLeft",[m,pe]),[$e]=wu("SelectLike",ye.popup?.root?.zIndex??Se?.zIndex);return f.createElement(IR,{ref:t,virtual:J,classNames:Qe,styles:ye,showSearch:re,...Tt,style:{...ye.root,...ie,...T},popupMatchSelectWidth:Ue,transitionName:Fl(ae,"slide-up",O),builtinPlacements:$le(C,te),listHeight:d,listItemHeight:se,mode:Pe,prefixCls:Me,placement:De,direction:pe,prefix:V,suffixIcon:lt,menuItemSelectedIcon:It,removeIcon:mt,allowClear:xt,notFoundContent:Oe,className:he,getPopupContainer:a||Q,popupClassName:be,disabled:gt,popupStyle:{...ye.popup?.root,...Se,zIndex:$e},maxCount:je?B:void 0,tagRender:je?_:void 0,popupRender:et,onPopupVisibleChange:rt})},Zl=f.forwardRef(jle),Ule=RR(Zl,"popupAlign");Zl.SECRET_COMBOBOX_MODE_DO_NOT_USE=kF;Zl.Option=PR;Zl.OptGroup=NR;Zl._InternalPanelDoNotUseOrYouWillBeFired=Ule;const wE=["xxxl","xxl","xl","lg","md","sm","xs"],Wle=e=>({xs:`(max-width: ${e.screenXSMax}px)`,sm:`(min-width: ${e.screenSM}px)`,md:`(min-width: ${e.screenMD}px)`,lg:`(min-width: ${e.screenLG}px)`,xl:`(min-width: ${e.screenXL}px)`,xxl:`(min-width: ${e.screenXXL}px)`,xxxl:`(min-width: ${e.screenXXXL}px)`}),Gle=e=>{const t=e,n=[].concat(wE).reverse();return n.forEach((r,o)=>{const i=r.toUpperCase(),a=`screen${i}Min`,l=`screen${i}`;if(!(t[a]<=t[l]))throw new Error(`${a}<=${l} fails : !(${t[a]}<=${t[l]})`);if(o<n.length-1){const u=`screen${i}Max`;if(!(t[l]<=t[u]))throw new Error(`${l}<=${u} fails : !(${t[l]}<=${t[u]})`);const m=`screen${n[o+1].toUpperCase()}Min`;if(!(t[u]<=t[m]))throw new Error(`${u}<=${m} fails : !(${t[u]}<=${t[m]})`)}}),e},qle=()=>{const[,e]=jr(),t=Wle(Gle(e));return q.useMemo(()=>{const n=new Map;let r=-1,o={};return {responsiveMap:t,matchHandlers:{},dispatch(i){return o=i,n.forEach(a=>a(o)),n.size>=1},subscribe(i){return n.size||this.register(),r+=1,n.set(r,i),i(o),r},unsubscribe(i){n.delete(i),n.size||this.unregister();},register(){Object.entries(t).forEach(([i,a])=>{const l=({matches:d})=>{this.dispatch({...o,[i]:d});},u=window.matchMedia(a);typeof u?.addEventListener=="function"&&u.addEventListener("change",l),this.matchHandlers[a]={mql:u,listener:l},l(u);});},unregister(){Object.values(t).forEach(i=>{const a=this.matchHandlers[i];typeof a?.mql?.removeEventListener=="function"&&a.mql.removeEventListener("change",a?.listener);}),n.clear();}}},[t])};function FF(e=true,t={}){const n=f.useRef(t),[,r]=Xz(),o=qle();return An(()=>{const i=o.subscribe(a=>{n.current=a,e&&r();});return ()=>o.unsubscribe(i)},[]),n.current}const $E=f.createContext({}),Kle=e=>{const{antCls:t,componentCls:n,iconCls:r,avatarBg:o,avatarColor:i,containerSize:a,containerSizeLG:l,containerSizeSM:u,textFontSize:d,textFontSizeLG:m,textFontSizeSM:p,iconFontSize:g,iconFontSizeLG:b,iconFontSizeSM:y,borderRadius:S,borderRadiusLG:C,borderRadiusSM:w,lineWidth:$,lineType:M}=e,T=(R,I,N,P)=>({width:R,height:R,borderRadius:"50%",fontSize:I,[`&${n}-square`]:{borderRadius:P},[`&${n}-icon`]:{fontSize:N,[`> ${r}`]:{margin:0}}});return {[n]:{...dn(e),position:"relative",display:"inline-flex",justifyContent:"center",alignItems:"center",overflow:"hidden",color:i,whiteSpace:"nowrap",textAlign:"center",verticalAlign:"middle",background:o,border:`${oe($)} ${M} transparent`,"&-image":{background:"transparent"},[`${t}-image-img`]:{display:"block"},...T(a,d,g,S),"&-lg":{...T(l,m,b,C)},"&-sm":{...T(u,p,y,w)},"> img":{display:"block",width:"100%",height:"100%",objectFit:"cover"}}}},Yle=e=>{const{componentCls:t,groupBorderColor:n,groupOverlapping:r,groupSpace:o}=e;return {[`${t}-group`]:{display:"inline-flex",[t]:{borderColor:n},"> *:not(:first-child)":{marginInlineStart:r}},[`${t}-group-popover`]:{[`${t} + ${t}`]:{marginInlineStart:o}}}},Xle=e=>{const{controlHeight:t,controlHeightLG:n,controlHeightSM:r,fontSize:o,fontSizeLG:i,fontSizeXL:a,fontSizeHeading3:l,marginXS:u,marginXXS:d,colorBorderBg:m}=e;return {containerSize:t,containerSizeLG:n,containerSizeSM:r,textFontSize:o,textFontSizeLG:o,textFontSizeSM:o,iconFontSize:Math.round((i+a)/2),iconFontSizeLG:l,iconFontSizeSM:o,groupSpace:d,groupOverlapping:-u,groupBorderColor:m}},HF=Wt("Avatar",e=>{const{colorTextLightSolid:t,colorTextPlaceholder:n}=e,r=Ft(e,{avatarBg:n,avatarColor:t});return [Kle(r),Yle(r)]},Xle),VF=f.forwardRef((e,t)=>{const{prefixCls:n,shape:r,size:o,src:i,srcSet:a,icon:l,className:u,rootClassName:d,style:m,alt:p,draggable:g,children:b,crossOrigin:y,gap:S=4,onError:C,...w}=e,[$,M]=f.useState(1),[T,R]=f.useState(false),[I,N]=f.useState(true),P=f.useRef(null),O=f.useRef(null),_=Vr(t,P),{getPrefixCls:B,className:V,style:U}=jt("avatar"),G=f.useContext($E),H=()=>{if(!O.current||!P.current)return;const ce=O.current.offsetWidth,fe=P.current.offsetWidth;ce!==0&&fe!==0&&S*2<fe&&M(fe-S*2<ce?(fe-S*2)/ce:1);};f.useEffect(()=>{R(true);},[]),f.useEffect(()=>{N(true),M(1);},[i]),f.useEffect(H,[S]);const z=()=>{C?.()!==false&&N(false);},j=so(ce=>o??G?.size??ce??"medium"),W=Object.keys(typeof j=="object"?j||{}:{}).some(ce=>wE.includes(ce)),Y=FF(W),Q=f.useMemo(()=>{if(typeof j!="object")return {};const ce=wE.find(se=>Y[se]),fe=j[ce];return fe?{width:fe,height:fe,fontSize:fe&&(l||b)?fe/2:18}:{}},[Y,j,l,b]),D=B("avatar",n),L=Qn(D),[K,J]=HF(D,L),ee=X({[`${D}-lg`]:j==="large",[`${D}-sm`]:j==="small"}),te=f.isValidElement(i),re=r||G?.shape||"circle",ie=X(D,ee,V,`${D}-${re}`,{[`${D}-image`]:te||i&&I,[`${D}-icon`]:!!l},J,L,u,d,K),de=typeof j=="number"?{width:j,height:j,fontSize:l?j/2:18}:{};let ne;if(typeof i=="string"&&I)ne=f.createElement("img",{src:i,draggable:g,srcSet:a,onError:z,alt:p,crossOrigin:y});else if(te)ne=i;else if(l)ne=l;else if(T||$!==1){const ce=`scale(${$})`,fe={msTransform:ce,WebkitTransform:ce,transform:ce};ne=f.createElement(ma,{onResize:H},f.createElement("span",{className:`${D}-string`,ref:O,style:fe},b));}else ne=f.createElement("span",{className:`${D}-string`,style:{opacity:0},ref:O},b);return f.createElement("span",{...w,style:{...de,...Q,...U,...m},className:ie,ref:_},ne)}),df=e=>e?typeof e=="function"?e():e:null,_R=e=>{const{children:t,prefixCls:n,id:r,classNames:o,styles:i,className:a,style:l}=e;return f.createElement("div",{id:r,className:X(`${n}-container`,o?.container,a),style:{...i?.container,...l},role:"tooltip"},typeof t=="function"?t():t)},Cd={shiftX:64,adjustY:1},xd={adjustX:1,shiftY:true},Li=[0,0],Qle={left:{points:["cr","cl"],overflow:xd,offset:[-4,0],targetOffset:Li},right:{points:["cl","cr"],overflow:xd,offset:[4,0],targetOffset:Li},top:{points:["bc","tc"],overflow:Cd,offset:[0,-4],targetOffset:Li},bottom:{points:["tc","bc"],overflow:Cd,offset:[0,4],targetOffset:Li},topLeft:{points:["bl","tl"],overflow:Cd,offset:[0,-4],targetOffset:Li},leftTop:{points:["tr","tl"],overflow:xd,offset:[-4,0],targetOffset:Li},topRight:{points:["br","tr"],overflow:Cd,offset:[0,-4],targetOffset:Li},rightTop:{points:["tl","tr"],overflow:xd,offset:[4,0],targetOffset:Li},bottomRight:{points:["tr","br"],overflow:Cd,offset:[0,4],targetOffset:Li},rightBottom:{points:["bl","br"],overflow:xd,offset:[4,0],targetOffset:Li},bottomLeft:{points:["tl","bl"],overflow:Cd,offset:[0,4],targetOffset:Li},leftBottom:{points:["br","bl"],overflow:xd,offset:[-4,0],targetOffset:Li}};function EE(){return EE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},EE.apply(this,arguments)}const Zle=f.forwardRef((e,t)=>{const{trigger:n=["hover"],mouseEnterDelay:r=0,mouseLeaveDelay:o=.1,prefixCls:i="rc-tooltip",children:a,onVisibleChange:l,afterVisibleChange:u,motion:d,placement:m="right",align:p={},destroyOnHidden:g=false,defaultVisible:b,getTooltipContainer:y,arrowContent:S,overlay:C,id:w,showArrow:$=true,classNames:M,styles:T,...R}=e,I=zs(w),N=f.useRef(null);f.useImperativeHandle(t,()=>N.current);const P={...R};"visible"in e&&(P.popupVisible=e.visible);const O=f.useMemo(()=>{if(!$)return false;const B=$===true?{}:$;return {...B,className:X(B.className,M?.arrow),style:{...B.style,...T?.arrow},content:B.content??S}},[$,M?.arrow,T?.arrow,S]),_=({open:B})=>{const V=f.Children.only(a),U={"aria-describedby":C&&B?I:void 0};return f.cloneElement(V,U)};return f.createElement(Jy,EE({popupClassName:M?.root,prefixCls:i,popup:f.createElement(_R,{key:"content",prefixCls:i,id:I,classNames:M,styles:T},C),action:n,builtinPlacements:Qle,popupPlacement:m,ref:N,popupAlign:p,getPopupContainer:y,onOpenChange:l,afterOpenChange:u,popupMotion:d,defaultPopupVisible:b,autoDestroy:g,mouseLeaveDelay:o,popupStyle:T?.root,mouseEnterDelay:r,arrow:O,uniqueContainerClassName:M?.uniqueContainer,uniqueContainerStyle:T?.uniqueContainer},P),_)});function BR(e){const{sizePopupArrow:t,borderRadiusXS:n,borderRadiusOuter:r}=e,o=t/2,i=0,a=o,l=r*1/Math.sqrt(2),u=o-r*(1-1/Math.sqrt(2)),d=o-n*(1/Math.sqrt(2)),m=r*(Math.sqrt(2)-1)+n*(1/Math.sqrt(2)),p=2*o-d,g=m,b=2*o-l,y=u,S=2*o-i,C=a,w=o*Math.sqrt(2)+r*(Math.sqrt(2)-2),$=r*(Math.sqrt(2)-1),M=`polygon(${$}px 100%, 50% ${$}px, ${2*o-$}px 100%, ${$}px 100%)`,T=`path('M ${i} ${a} A ${r} ${r} 0 0 0 ${l} ${u} L ${d} ${m} A ${n} ${n} 0 0 1 ${p} ${g} L ${b} ${y} A ${r} ${r} 0 0 0 ${S} ${C} Z')`;return {arrowShadowWidth:w,arrowPath:T,arrowPolygon:M}}const Jle=(e,t,n)=>{const{sizePopupArrow:r,arrowPolygon:o,arrowPath:i,arrowShadowWidth:a,borderRadiusXS:l,calc:u}=e;return {pointerEvents:"none",width:r,height:r,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:r,height:u(r).div(2).equal(),background:t,clipPath:{_multi_value_:true,value:[o,i]},content:'""'},"&::after":{content:'""',position:"absolute",width:a,height:a,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:true,value:`0 0 ${oe(l)} 0`},transform:"translateY(50%) rotate(-135deg)",boxShadow:n,zIndex:0,background:"transparent"}}},jF=8;function s1(e){const{contentRadius:t,limitVerticalRadius:n}=e,r=t>12?t+2:12;return {arrowOffsetHorizontal:r,arrowOffsetVertical:n?jF:r}}function cb(e,t){return e?t:{}}const LR=(e,t,n)=>{const{componentCls:r,boxShadowPopoverArrow:o,arrowOffsetVertical:i,arrowOffsetHorizontal:a,antCls:l}=e,[u]=tr(l,"tooltip"),{arrowDistance:d=0,arrowPlacement:m={left:true,right:true,top:true,bottom:true}}=n||{};return {[r]:{[`${r}-arrow`]:[{position:"absolute",zIndex:1,display:"block",...Jle(e,t,o),"&:before":{background:t}}],...cb(!!m.top,{[[`&-placement-top > ${r}-arrow`,`&-placement-topLeft > ${r}-arrow`,`&-placement-topRight > ${r}-arrow`].join(",")]:{bottom:d,transform:"translateY(100%) rotate(180deg)"},[`&-placement-top > ${r}-arrow`]:{left:{_skip_check_:true,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},"&-placement-topLeft":{[u("arrow-offset-x")]:a,[`> ${r}-arrow`]:{left:{_skip_check_:true,value:a}}},"&-placement-topRight":{[u("arrow-offset-x")]:`calc(100% - ${oe(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:true,value:a}}}}),...cb(!!m.bottom,{[[`&-placement-bottom > ${r}-arrow`,`&-placement-bottomLeft > ${r}-arrow`,`&-placement-bottomRight > ${r}-arrow`].join(",")]:{top:d,transform:"translateY(-100%)"},[`&-placement-bottom > ${r}-arrow`]:{left:{_skip_check_:true,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},"&-placement-bottomLeft":{[u("arrow-offset-x")]:a,[`> ${r}-arrow`]:{left:{_skip_check_:true,value:a}}},"&-placement-bottomRight":{[u("arrow-offset-x")]:`calc(100% - ${oe(a)})`,[`> ${r}-arrow`]:{right:{_skip_check_:true,value:a}}}}),...cb(!!m.left,{[[`&-placement-left > ${r}-arrow`,`&-placement-leftTop > ${r}-arrow`,`&-placement-leftBottom > ${r}-arrow`].join(",")]:{right:{_skip_check_:true,value:d},transform:"translateX(100%) rotate(90deg)"},[`&-placement-left > ${r}-arrow`]:{top:{_skip_check_:true,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},[`&-placement-leftTop > ${r}-arrow`]:{top:i},[`&-placement-leftBottom > ${r}-arrow`]:{bottom:i}}),...cb(!!m.right,{[[`&-placement-right > ${r}-arrow`,`&-placement-rightTop > ${r}-arrow`,`&-placement-rightBottom > ${r}-arrow`].join(",")]:{left:{_skip_check_:true,value:d},transform:"translateX(-100%) rotate(-90deg)"},[`&-placement-right > ${r}-arrow`]:{top:{_skip_check_:true,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},[`&-placement-rightTop > ${r}-arrow`]:{top:i},[`&-placement-rightBottom > ${r}-arrow`]:{bottom:i}})}}};function ece(e,t,n,r){if(r===false)return {adjustX:false,adjustY:false};const o=r&&typeof r=="object"?r:{},i={};switch(e){case "top":case "bottom":i.shiftX=t.arrowOffsetHorizontal*2+n,i.shiftY=true,i.adjustY=true;break;case "left":case "right":i.shiftY=t.arrowOffsetVertical*2+n,i.shiftX=true,i.adjustX=true;break}const a={...i,...o};return a.shiftX||(a.adjustX=true),a.shiftY||(a.adjustY=true),a}const zO={left:{points:["cr","cl"]},right:{points:["cl","cr"]},top:{points:["bc","tc"]},bottom:{points:["tc","bc"]},topLeft:{points:["bl","tl"]},leftTop:{points:["tr","tl"]},topRight:{points:["br","tr"]},rightTop:{points:["tl","tr"]},bottomRight:{points:["tr","br"]},rightBottom:{points:["bl","br"]},bottomLeft:{points:["tl","bl"]},leftBottom:{points:["br","bl"]}},tce={topLeft:{points:["bl","tc"]},leftTop:{points:["tr","cl"]},topRight:{points:["br","tc"]},rightTop:{points:["tl","cr"]},bottomRight:{points:["tr","bc"]},rightBottom:{points:["bl","cr"]},bottomLeft:{points:["tl","bc"]},leftBottom:{points:["br","cl"]}},nce=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function UF(e){const{arrowWidth:t,autoAdjustOverflow:n,arrowPointAtCenter:r,offset:o,borderRadius:i,visibleFirst:a}=e,l=t/2,u={},d=s1({contentRadius:i,limitVerticalRadius:true});return Object.keys(zO).forEach(m=>{const g={...r&&tce[m]||zO[m],offset:[0,0],dynamicInset:true};switch(u[m]=g,nce.has(m)&&(g.autoArrow=false),m){case "top":case "topLeft":case "topRight":g.offset[1]=-l-o;break;case "bottom":case "bottomLeft":case "bottomRight":g.offset[1]=l+o;break;case "left":case "leftTop":case "leftBottom":g.offset[0]=-l-o;break;case "right":case "rightTop":case "rightBottom":g.offset[0]=l+o;break}if(r)switch(m){case "topLeft":case "bottomLeft":g.offset[0]=-d.arrowOffsetHorizontal-l;break;case "topRight":case "bottomRight":g.offset[0]=d.arrowOffsetHorizontal+l;break;case "leftTop":case "rightTop":g.offset[1]=-d.arrowOffsetHorizontal*2+l;break;case "leftBottom":case "rightBottom":g.offset[1]=d.arrowOffsetHorizontal*2-l;break}g.overflow=ece(m,d,t,n),a&&(g.htmlRegion="visibleFirst");}),u}const l1=(e,t)=>{const n=r=>typeof r=="boolean"?{show:r}:r||{};return q.useMemo(()=>{const r=n(e),o=n(t);return {...o,...r,show:r.show??o.show??true}},[e,t])},kO="50%",rce=e=>{const{calc:t,componentCls:n,tooltipMaxWidth:r,tooltipColor:o,tooltipBg:i,tooltipBorderRadius:a,zIndexPopup:l,controlHeight:u,boxShadowSecondary:d,paddingSM:m,paddingXS:p,arrowOffsetHorizontal:g,sizePopupArrow:b,antCls:y}=e,[S,C]=tr(y,"tooltip"),w=t(a).add(b).add(g).equal(),M={minWidth:t(a).mul(2).add(b).equal(),minHeight:u,padding:`${oe(e.calc(m).div(2).equal())} ${oe(p)}`,color:C("overlay-color",o),textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:i,borderRadius:a,boxShadow:d,boxSizing:"border-box"},T={[S("valid-offset-x")]:C("arrow-offset-x","var(--arrow-x)"),transformOrigin:[C("valid-offset-x",kO),`var(--arrow-y, ${kO})`].join(" ")};return [{[n]:{...dn(e),position:"absolute",zIndex:l,display:"block",width:"max-content",maxWidth:r,visibility:"visible",...T,"&-hidden":{display:"none"},[S("arrow-background-color")]:i,[`${n}-container`]:[M,fR(e,true)],[`&:has(~ ${n}-unique-container)`]:{[`${n}-container`]:{border:"none",background:"transparent",boxShadow:"none"}},[["&-placement-topLeft","&-placement-topRight","&-placement-bottomLeft","&-placement-bottomRight"].join(",")]:{minWidth:w},[["&-placement-left","&-placement-leftTop","&-placement-leftBottom","&-placement-right","&-placement-rightTop","&-placement-rightBottom"].join(",")]:{[`${n}-inner`]:{borderRadius:e.min(a,jF)}},[`${n}-content`]:{position:"relative"},...Yy(e,(R,{darkColor:I})=>({[`&${n}-${R}`]:{[`${n}-container`]:{backgroundColor:I},[`${n}-arrow`]:{[S("arrow-background-color")]:I}}})),"&-rtl":{direction:"rtl"}}},LR(e,C("arrow-background-color")),{[`${n}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}},{[`${n}-unique-container`]:{...M,...T,position:"absolute",zIndex:t(l).sub(1).equal(),"&-hidden":{display:"none"},"&-visible":{transition:`all ${e.motionDurationSlow}`}}}]},oce=e=>({zIndexPopup:e.zIndexPopupBase+70,maxWidth:250,...s1({contentRadius:e.borderRadius,limitVerticalRadius:true}),...BR(Ft(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)}))}),WF=(e,t,n=true)=>Wt("Tooltip",o=>{const{borderRadius:i,colorTextLightSolid:a,colorBgSpotlight:l,maxWidth:u}=o,d=Ft(o,{tooltipMaxWidth:u,tooltipColor:a,tooltipBorderRadius:i,tooltipBg:l});return [rce(d),Zp(o,"zoom-big-fast")]},oce,{resetStyle:false,injectStyle:n})(e,t),ice=Wa.map(e=>`${e}-inverse`),ace=["success","processing","error","default","warning"];function c1(e,t=true){return t?[].concat(qt(ice),qt(Wa)).includes(e):Wa.includes(e)}function sce(e){return ace.includes(e)}const GF=(e,t,n)=>{const r=c1(n),[o]=tr(e,"tooltip"),i=X({[`${t}-${n}`]:n&&r}),a={},l={},u=ro(n).toRgb(),m=(.299*u.r+.587*u.g+.114*u.b)/255<.5?"#FFF":"#000";return n&&!r&&(a.background=n,a[o("overlay-color")]=m,l[o("arrow-background-color")]=n),{className:i,overlayStyle:a,arrowStyle:l}},lce=e=>{const{prefixCls:t,className:n,placement:r="top",title:o,color:i,overlayInnerStyle:a,classNames:l,styles:u}=e,{getPrefixCls:d}=f.useContext(wt),m=d("tooltip",t),p=d(),g=Qn(m),[b,y]=WF(m,g),S=GF(p,m,i),C=S.arrowStyle,w=f.useMemo(()=>({container:{...a,...S.overlayStyle}}),[a,S.overlayStyle]),$={...e,placement:r},[M,T]=Kt([l],[w,u],{props:$}),R=X(g,b,y,m,`${m}-pure`,`${m}-placement-${r}`,n,S.className);return f.createElement("div",{className:R,style:C},f.createElement("div",{className:`${m}-arrow`}),f.createElement(_R,{...e,className:b,prefixCls:m,classNames:M,styles:T},o))},cce=f.forwardRef((e,t)=>{const{prefixCls:n,openClassName:r,getTooltipContainer:o,color:i,children:a,afterOpenChange:l,arrow:u,destroyTooltipOnHide:d,destroyOnHidden:m,title:p,overlay:g,trigger:b,builtinPlacements:y,autoAdjustOverflow:S=true,motion:C,getPopupContainer:w,placement:$="top",mouseEnterDelay:M=.1,mouseLeaveDelay:T=.1,rootClassName:R,styles:I,classNames:N,onOpenChange:P,overlayInnerStyle:O,overlayStyle:_,overlayClassName:B,...V}=e,[,U]=jr(),{getPopupContainer:G,getPrefixCls:H,direction:z,className:j,style:W,classNames:Y,styles:Q,arrow:D,trigger:L}=jt("tooltip"),K=l1(u,D),J=K.show,ee=b||L||"hover",te=f.useRef(null),re=()=>{te.current?.forceAlign();};f.useImperativeHandle(t,()=>({forceAlign:re,nativeElement:te.current?.nativeElement,popupElement:te.current?.popupElement}));const[ie,de]=un(e.defaultOpen??false,e.open),ne=!p&&!g&&p!==0,ce=lt=>{de(ne?false:lt),!ne&&P&&P(lt);},fe=f.useMemo(()=>y||UF({arrowPointAtCenter:K?.pointAtCenter??false,autoAdjustOverflow:S,arrowWidth:J?U.sizePopupArrow:0,borderRadius:U.borderRadius,offset:U.marginXXS,visibleFirst:true}),[K,y,U,J,S]),se=f.useMemo(()=>p===0?p:g||p||"",[g,p]),Me=f.createElement(Vl,{space:true,form:true},typeof se=="function"?se():se),ae={...e,trigger:ee,color:i,placement:$,builtinPlacements:y,openClassName:r,arrow:u,autoAdjustOverflow:S,getPopupContainer:w,children:a,destroyTooltipOnHide:d,destroyOnHidden:m},[pe,Ce]=Kt([Y,N],[Q,I],{props:ae}),xe=H("tooltip",n),Ae=H(),Xe=e["data-popover-inject"];let Ne=ie;!("open"in e)&&ne&&(Ne=false);const ue=f.isValidElement(a)&&!uk(a)?a:f.createElement("span",null,a),ge=ue.props,Pe=!ge.className||typeof ge.className=="string"?X(ge.className,r||`${xe}-open`):ge.className,je=Qn(xe),[qe,Ue]=WF(xe,je,!Xe),et=GF(Ae,xe,i),rt=et.arrowStyle,Ke=X(je,qe,Ue),_e=X(B,{[`${xe}-rtl`]:z==="rtl"},et.className,R,Ke,j,pe.root),[We,Ze]=wu("Tooltip",V.zIndex),Be={...Ce.container,...O,...et.overlayStyle},Oe=f.createElement(Zle,{unique:true,...V,trigger:ee,zIndex:We,showArrow:J,placement:$,mouseEnterDelay:M,mouseLeaveDelay:T,prefixCls:xe,classNames:{root:_e,container:pe.container,arrow:pe.arrow,uniqueContainer:X(Ke,pe.container)},styles:{root:{...rt,...Ce.root,...W,..._},container:Be,uniqueContainer:Be,arrow:Ce.arrow},getTooltipContainer:w||o||G,ref:te,builtinPlacements:fe,overlay:Me,visible:Ne,onVisibleChange:ce,afterVisibleChange:l,arrowContent:f.createElement("span",{className:`${xe}-arrow-content`}),motion:{motionName:Fl(Ae,"zoom-big-fast",typeof C?.motionName=="string"?C?.motionName:void 0),motionDeadline:1e3},destroyOnHidden:m??!!d},Ne?Hr(ue,{className:Pe}):ue);return f.createElement(Qy.Provider,{value:Ze},Oe)}),Jl=cce;Jl._InternalPanelDoNotUseOrYouWillBeFired=lce;Jl.UniqueProvider=fk;const FO="50%",uce=e=>{const{componentCls:t,popoverColor:n,titleMinWidth:r,fontWeightStrong:o,innerPadding:i,boxShadowSecondary:a,colorTextHeading:l,borderRadiusLG:u,zIndexPopup:d,titleMarginBottom:m,colorBgElevated:p,popoverBg:g,titleBorderBottom:b,innerContentPadding:y,titlePadding:S,antCls:C}=e,[w,$]=tr(C,"tooltip");return [{[t]:{...dn(e),position:"absolute",top:0,left:{_skip_check_:true,value:0},zIndex:d,fontWeight:"normal",whiteSpace:"normal",textAlign:"start",cursor:"auto",userSelect:"text",[w("valid-offset-x")]:$("arrow-offset-x","var(--arrow-x)"),transformOrigin:[$("valid-offset-x",FO),`var(--arrow-y, ${FO})`].join(" "),[w("arrow-background-color")]:p,width:"max-content",maxWidth:"100vw","&-rtl":{direction:"rtl"},"&-hidden":{display:"none"},[`${t}-content`]:{position:"relative"},[`${t}-container`]:{backgroundColor:g,backgroundClip:"padding-box",borderRadius:u,boxShadow:a,padding:i},[`${t}-title`]:{minWidth:r,marginBottom:m,color:l,fontWeight:o,borderBottom:b,padding:S},[`${t}-content`]:{color:n,padding:y}}},LR(e,$("arrow-background-color")),{[`${t}-pure`]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow,display:"inline-block"}}]},dce=e=>{const{componentCls:t,antCls:n}=e,[r]=tr(n,"tooltip");return {[t]:Wa.map(o=>{const i=e[`${o}6`];return {[`&${t}-${o}`]:{[r("arrow-background-color")]:i,[`${t}-inner`]:{backgroundColor:i},[`${t}-arrow`]:{background:"transparent"}}}})}},fce=e=>{const{lineWidth:t,controlHeight:n,fontHeight:r,padding:o,wireframe:i,zIndexPopupBase:a,borderRadiusLG:l,marginXS:u,lineType:d,colorSplit:m,paddingSM:p}=e,g=n-r,b=g/2,y=g/2-t,S=o;return {titleMinWidth:177,zIndexPopup:a+30,...BR(e),...s1({contentRadius:l,limitVerticalRadius:true}),innerPadding:i?0:12,titleMarginBottom:i?0:u,titlePadding:i?`${b}px ${S}px ${y}px`:0,titleBorderBottom:i?`${t}px ${d} ${m}`:"none",innerContentPadding:i?`${p}px ${S}px`:0}},qF=Wt("Popover",e=>{const{colorBgElevated:t,colorText:n}=e,r=Ft(e,{popoverBg:t,popoverColor:n});return [uce(r),dce(r),Zp(r,"zoom-big")]},fce,{resetStyle:false,deprecatedTokens:[["width","titleMinWidth"],["minWidth","titleMinWidth"]]}),KF=e=>{const{title:t,content:n,prefixCls:r,classNames:o,styles:i}=e;return !t&&!n?null:f.createElement(f.Fragment,null,t&&f.createElement("div",{className:X(`${r}-title`,o?.title),style:i?.title},t),n&&f.createElement("div",{className:X(`${r}-content`,o?.content),style:i?.content},n))},mce=e=>{const{hashId:t,prefixCls:n,className:r,style:o,placement:i="top",title:a,content:l,children:u,classNames:d,styles:m}=e,p=df(a),g=df(l),b={...e,placement:i},[y,S]=Kt([d],[m],{props:b}),C=X(t,n,`${n}-pure`,`${n}-placement-${i}`,r);return f.createElement("div",{className:C,style:o},f.createElement("div",{className:`${n}-arrow`}),f.createElement(_R,{...e,className:t,prefixCls:n,classNames:y,styles:S},u||f.createElement(KF,{prefixCls:n,title:p,content:g,classNames:y,styles:S})))},YF=e=>{const{prefixCls:t,className:n,...r}=e,{getPrefixCls:o}=f.useContext(wt),i=o("popover",t),[a,l]=qF(i);return f.createElement(mce,{...r,prefixCls:i,hashId:a,className:X(n,l)})},hce=f.forwardRef((e,t)=>{const{prefixCls:n,title:r,content:o,overlayClassName:i,placement:a="top",trigger:l,children:u,mouseEnterDelay:d=.1,mouseLeaveDelay:m=.1,onOpenChange:p,overlayStyle:g={},styles:b,classNames:y,motion:S,arrow:C,...w}=e,{getPrefixCls:$,className:M,style:T,classNames:R,styles:I,arrow:N,trigger:P}=jt("popover"),O=$("popover",n),[_,B]=qF(O),V=$(),U=l1(C,N),G=l||P||"hover",H={...e,placement:a,trigger:G,mouseEnterDelay:d,mouseLeaveDelay:m,overlayStyle:g,styles:b,classNames:y},[z,j]=Kt([R,y],[I,b],{props:H}),W=X(i,_,B,M,z.root),[Y,Q]=un(e.defaultOpen??false,e.open),D=J=>{Q(J),p?.(J);},L=df(r),K=df(o);return f.createElement(Jl,{unique:false,arrow:U,placement:a,trigger:G,mouseEnterDelay:d,mouseLeaveDelay:m,...w,prefixCls:O,classNames:{root:W,container:z.container,arrow:z.arrow},styles:{root:{...j.root,...T,...g},container:j.container,arrow:j.arrow},ref:t,open:Y,onOpenChange:D,overlay:L||K?f.createElement(KF,{prefixCls:O,title:L,content:K,classNames:z,styles:j}):null,motion:{motionName:Fl(V,"zoom-big",typeof S?.motionName=="string"?S?.motionName:void 0)},"data-popover-inject":true},u)}),Zo=hce;Zo._InternalPanelDoNotUseOrYouWillBeFired=YF;const HO=e=>{const{size:t,shape:n}=f.useContext($E),r=f.useMemo(()=>({size:e.size||t,shape:e.shape||n}),[e.size,e.shape,t,n]);return f.createElement($E.Provider,{value:r},e.children)},pce=e=>{const{getPrefixCls:t,direction:n}=f.useContext(wt),{prefixCls:r,className:o,rootClassName:i,style:a,maxCount:l,maxStyle:u,size:d,shape:m,maxPopoverPlacement:p,maxPopoverTrigger:g,children:b,max:y}=e,S=t("avatar",r),C=`${S}-group`,w=Qn(S),[$,M]=HF(S,w),T=X(C,{[`${C}-rtl`]:n==="rtl"},M,w,o,i,$),R=Qo(b).map((P,O)=>Hr(P,{key:`avatar-key-${O}`})),I=y?.count||l,N=R.length;if(I&&I<N){const P=R.slice(0,I),O=R.slice(I,N),_=y?.style||u,B=y?.popover?.trigger||g||"hover",V=y?.popover?.placement||p||"top",U={content:O,...y?.popover,placement:V,trigger:B,rootClassName:X(`${C}-popover`,y?.popover?.rootClassName)};return P.push(f.createElement(Zo,{key:"avatar-popover-key",destroyOnHidden:true,...U},f.createElement(VF,{style:_},`+${N-I}`))),f.createElement(HO,{shape:m,size:d},f.createElement("div",{className:T,style:a},P))}return f.createElement(HO,{shape:m,size:d},f.createElement("div",{className:T,style:a},R))},Yc=VF;Yc.Group=pce;var gce={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M859.9 168H164.1c-4.5 0-8.1 3.6-8.1 8v60c0 4.4 3.6 8 8.1 8h695.8c4.5 0 8.1-3.6 8.1-8v-60c0-4.4-3.6-8-8.1-8zM518.3 355a8 8 0 00-12.6 0l-112 141.7a7.98 7.98 0 006.3 12.9h73.9V848c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V509.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 355z"}}]},name:"vertical-align-top",theme:"outlined"};function ME(){return ME=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},ME.apply(this,arguments)}const vce=(e,t)=>f.createElement(Xn,ME({},e,{ref:t,icon:gce})),bce=f.forwardRef(vce),VO=e=>{const{prefixCls:t,value:n,current:r,offset:o=0}=e;let i;return o&&(i={position:"absolute",top:`${o}00%`,left:0}),f.createElement("span",{style:i,className:X(`${t}-only-unit`,{current:r})},n)};function yce(e,t,n){let r=e,o=0;for(;(r+10)%10!==t;)r+=n,o+=n;return o}const Sce=e=>{const{prefixCls:t,count:n,value:r}=e,o=Number(r),i=Math.abs(n),[a,l]=f.useState(o),[u,d]=f.useState(i),m=()=>{l(o),d(i);};f.useEffect(()=>{const b=setTimeout(m,1e3);return ()=>clearTimeout(b)},[o]);let p,g;if(a===o||Number.isNaN(o)||Number.isNaN(a))p=[f.createElement(VO,{...e,key:o,current:true})],g={transition:"none"};else {p=[];const b=o+10,y=[];for(let $=o;$<=b;$+=1)y.push($);const S=u<i?1:-1,C=y.findIndex($=>$%10===a);p=(S<0?y.slice(0,C+1):y.slice(C)).map(($,M)=>{const T=$%10;return f.createElement(VO,{...e,key:$,value:T,offset:S<0?M-C:M,current:M===C})}),g={transform:`translateY(${-yce(a,o,S)}00%)`};}return f.createElement("span",{className:`${t}-only`,style:g,onTransitionEnd:m},p)},Cce=f.forwardRef((e,t)=>{const{prefixCls:n,count:r,className:o,motionClassName:i,style:a,title:l,show:u,component:d="sup",children:m,...p}=e,{getPrefixCls:g}=f.useContext(wt),b=g("scroll-number",n),y={...p,"data-show":u,style:a,className:X(b,o,i),title:l};let S=r;if(r&&Number(r)%1===0){const C=String(r).split("");S=f.createElement("bdi",null,C.map((w,$)=>f.createElement(Sce,{prefixCls:b,count:Number(r),value:w,key:C.length-$})));}return a?.borderColor&&(y.style={...a,boxShadow:`0 0 0 1px ${a.borderColor} inset`}),m?Hr(m,C=>({className:X(`${b}-custom-component`,C?.className,i)})):f.createElement(d,{...y,ref:t},S)}),xce=new zt("antStatusProcessing",{"0%":{transform:"scale(0.8)",opacity:.5},"100%":{transform:"scale(2.4)",opacity:0}}),wce=new zt("antZoomBadgeIn",{"0%":{transform:"scale(0) translate(50%, -50%)",opacity:0},"100%":{transform:"scale(1) translate(50%, -50%)"}}),$ce=new zt("antZoomBadgeOut",{"0%":{transform:"scale(1) translate(50%, -50%)"},"100%":{transform:"scale(0) translate(50%, -50%)",opacity:0}}),Ece=new zt("antNoWrapperZoomBadgeIn",{"0%":{transform:"scale(0)",opacity:0},"100%":{transform:"scale(1)"}}),Mce=new zt("antNoWrapperZoomBadgeOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0)",opacity:0}}),Rce=new zt("antBadgeLoadingCircle",{"0%":{transformOrigin:"50%"},"100%":{transform:"translate(50%, -50%) rotate(360deg)",transformOrigin:"50%"}}),Tce=e=>{const{componentCls:t,iconCls:n,antCls:r,badgeShadowSize:o,textFontSize:i,textFontSizeSM:a,statusSize:l,dotSize:u,textFontWeight:d,indicatorHeight:m,indicatorHeightSM:p,marginXS:g,calc:b}=e,y=`${r}-scroll-number`,S=Yy(e,(C,{darkColor:w})=>({[`&${t} ${t}-color-${C}`]:{background:w,[`&:not(${t}-count)`]:{color:w},"a:hover &":{background:w}}}));return {[t]:{...dn(e),position:"relative",display:"inline-block",width:"fit-content",lineHeight:1,[`${t}-count`]:{display:"inline-flex",justifyContent:"center",zIndex:e.indicatorZIndex,minWidth:m,height:m,color:e.badgeTextColor,fontWeight:d,fontSize:i,lineHeight:oe(m),whiteSpace:"nowrap",textAlign:"center",background:e.badgeColor,borderRadius:b(m).div(2).equal(),boxShadow:`0 0 0 ${oe(o)} ${e.badgeShadowColor}`,transition:`background-color ${e.motionDurationMid}`,a:{color:e.badgeTextColor},"a:hover":{color:e.badgeTextColor},"a:hover &":{background:e.badgeColorHover}},[`${t}-count-sm`]:{minWidth:p,height:p,fontSize:a,lineHeight:oe(p),borderRadius:b(p).div(2).equal()},[`${t}-multiple-words`]:{padding:`0 ${oe(e.paddingXS)}`,bdi:{unicodeBidi:"plaintext"}},[`${t}-dot`]:{zIndex:e.indicatorZIndex,width:u,minWidth:u,height:u,background:e.badgeColor,borderRadius:"100%",boxShadow:`0 0 0 ${oe(o)} ${e.badgeShadowColor}`},[`${t}-count, ${t}-dot, ${y}-custom-component`]:{position:"absolute",top:0,insetInlineEnd:0,transform:"translate(50%, -50%)",transformOrigin:"100% 0%",[`&${n}-spin`]:{animationName:Rce,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear"}},[`&${t}-status`]:{lineHeight:"inherit",verticalAlign:"baseline",[`${t}-status-dot`]:{position:"relative",top:-1,display:"inline-block",width:l,height:l,verticalAlign:"middle",borderRadius:"50%"},[`${t}-status-success`]:{backgroundColor:e.colorSuccess},[`${t}-status-processing`]:{overflow:"visible",color:e.colorInfo,backgroundColor:e.colorInfo,borderColor:"currentcolor","&::after":{position:"absolute",top:0,insetInlineStart:0,width:"100%",height:"100%",borderWidth:o,borderStyle:"solid",borderColor:"inherit",borderRadius:"50%",animationName:xce,animationDuration:e.badgeProcessingDuration,animationIterationCount:"infinite",animationTimingFunction:"ease-in-out",content:'""'}},[`${t}-status-default`]:{backgroundColor:e.colorTextPlaceholder},[`${t}-status-error`]:{backgroundColor:e.colorError},[`${t}-status-warning`]:{backgroundColor:e.colorWarning},[`${t}-status-text`]:{marginInlineStart:g,color:e.colorText,fontSize:e.fontSize}},...S,[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:wce,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`${t}-zoom-leave`]:{animationName:$ce,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack,animationFillMode:"both"},[`&${t}-not-a-wrapper`]:{[`${t}-zoom-appear, ${t}-zoom-enter`]:{animationName:Ece,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`${t}-zoom-leave`]:{animationName:Mce,animationDuration:e.motionDurationSlow,animationTimingFunction:e.motionEaseOutBack},[`&:not(${t}-status)`]:{verticalAlign:"middle"},[`${y}-custom-component, ${t}-count`]:{transform:"none"},[`${y}-custom-component, ${y}`]:{position:"relative",top:"auto",display:"block",transformOrigin:"50% 50%"}},[y]:{overflow:"hidden",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack}`,[`${y}-only`]:{position:"relative",display:"inline-block",height:m,transition:`all ${e.motionDurationSlow} ${e.motionEaseOutBack}`,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden",[`> p${y}-only-unit`]:{height:m,margin:0,WebkitTransformStyle:"preserve-3d",WebkitBackfaceVisibility:"hidden"}},[`${y}-symbol`]:{verticalAlign:"top"}},"&-rtl":{direction:"rtl",[`${t}-count, ${t}-dot, ${y}-custom-component`]:{transform:"translate(-50%, -50%)"}}}}},XF=e=>{const{fontHeight:t,lineWidth:n,marginXS:r,colorBorderBg:o}=e,i=t,a=n,l=e.colorTextLightSolid,u=e.colorError,d=e.colorErrorHover;return Ft(e,{badgeFontHeight:i,badgeShadowSize:a,badgeTextColor:l,badgeColor:u,badgeColorHover:d,badgeShadowColor:o,badgeProcessingDuration:"1.2s",badgeRibbonOffset:r,badgeRibbonCornerTransform:"scaleY(0.75)",badgeRibbonCornerFilter:"brightness(75%)"})},QF=e=>{const{fontSize:t,lineHeight:n,fontSizeSM:r,lineWidth:o}=e;return {indicatorZIndex:"auto",indicatorHeight:Math.round(t*n)-2*o,indicatorHeightSM:t,dotSize:r/2,textFontSize:r,textFontSizeSM:r,textFontWeight:"normal",statusSize:r/2}},Ace=Wt("Badge",e=>{const t=XF(e);return Tce(t)},QF),Nce=f.forwardRef((e,t)=>{const{prefixCls:n,scrollNumberPrefixCls:r,children:o,status:i,text:a,color:l,count:u=null,overflowCount:d=99,dot:m=false,size:p="default",title:g,offset:b,style:y,className:S,rootClassName:C,classNames:w,styles:$,showZero:M=false,...T}=e,{getPrefixCls:R,direction:I,className:N,style:P,classNames:O,styles:_}=jt("badge"),B=R("badge",n),[V,U]=Ace(B),G={...e,overflowCount:d,size:p,dot:m,showZero:M},[H,z]=Kt([O,w],[_,$],{props:G}),j=u>d?`${d}+`:u,W=j==="0"||j===0||a==="0"||a===0,Y=u===null||W&&!M,Q=(Jr(i)||Jr(l))&&Y,D=Jr(i)||!W,L=m&&!W,K=L?"":j,J=f.useMemo(()=>((!Jr(K)||K==="")&&(!Jr(a)||a==="")||W&&!M)&&!L,[K,W,M,L,a]),ee=f.useRef(u);J||(ee.current=u);const te=ee.current,re=f.useRef(K);J||(re.current=K);const ie=re.current,de=f.useRef(L);J||(de.current=L);const ne=f.useMemo(()=>{if(!b)return {...P,...y};const Ae=Number.parseInt(b[0],10);return {...{marginTop:b[1],insetInlineEnd:-Ae},...P,...y}},[b,y,P]),ce=g??(typeof te=="string"||typeof te=="number"?te:void 0),fe=!J&&(a===0?M:!!a&&a!==true),se=fe?f.createElement("span",{className:`${B}-status-text`},a):null,Me=!te||typeof te!="object"?void 0:Hr(te,Ae=>({style:{...ne,...Ae.style}})),ae=c1(l,false),pe=X(H.indicator,{[`${B}-status-dot`]:Q,[`${B}-status-${i}`]:!!i,[`${B}-color-${l}`]:ae}),Ce={};l&&!ae&&(Ce.color=l,Ce.background=l);const xe=X(B,{[`${B}-status`]:Q,[`${B}-not-a-wrapper`]:!o,[`${B}-rtl`]:I==="rtl"},S,C,N,H.root,V,U);if(!o&&Q&&(a||D||!Y)){const Ae=ne.color;return f.createElement("span",{ref:t,...T,className:xe,style:{...z.root,...ne}},f.createElement("span",{className:pe,style:{...z.indicator,...Ce}}),fe&&f.createElement("span",{style:{color:Ae},className:`${B}-status-text`},a))}return f.createElement("span",{ref:t,...T,className:xe,style:z.root},o,f.createElement(Co,{visible:!J,motionName:`${B}-zoom`,motionAppear:false,motionDeadline:1e3},({className:Ae})=>{const Xe=R("scroll-number",r),Ne=de.current,ue=X(H.indicator,{[`${B}-dot`]:Ne,[`${B}-count`]:!Ne,[`${B}-count-sm`]:p==="small",[`${B}-multiple-words`]:!Ne&&ie&&ie.toString().length>1,[`${B}-status-${i}`]:!!i,[`${B}-color-${l}`]:ae});let ge={...z.indicator,...ne};return l&&!ae&&(ge=ge||{},ge.background=l),f.createElement(Cce,{prefixCls:Xe,show:!J,motionClassName:Ae,className:ue,count:ie,title:ce,style:ge,key:"scrollNumber"},Me)}),se)}),Pce=e=>{const{antCls:t,badgeFontHeight:n,marginXS:r,badgeRibbonOffset:o,calc:i}=e,a=`${t}-ribbon`,l=`${t}-ribbon-wrapper`,u=Yy(e,(d,{darkColor:m})=>({[`&${a}-color-${d}`]:{background:m,color:m}}));return {[l]:{position:"relative"},[a]:{...dn(e),position:"absolute",top:r,padding:`0 ${oe(e.paddingXS)}`,color:e.colorPrimary,lineHeight:oe(n),whiteSpace:"nowrap",backgroundColor:e.colorPrimary,borderRadius:e.borderRadiusSM,[`${a}-content`]:{color:e.badgeTextColor},[`${a}-corner`]:{position:"absolute",top:"100%",width:o,height:o,color:"currentcolor",border:`${oe(i(o).div(2).equal())} solid`,transform:e.badgeRibbonCornerTransform,transformOrigin:"top",filter:e.badgeRibbonCornerFilter},...u,[`&${a}-placement-end`]:{insetInlineEnd:i(o).mul(-1).equal(),borderEndEndRadius:0,[`${a}-corner`]:{insetInlineEnd:0,borderInlineEndColor:"transparent",borderBlockEndColor:"transparent"}},[`&${a}-placement-start`]:{insetInlineStart:i(o).mul(-1).equal(),borderEndStartRadius:0,[`${a}-corner`]:{insetInlineStart:0,borderBlockEndColor:"transparent",borderInlineStartColor:"transparent"}},"&-rtl":{direction:"rtl"}}}},Ice=Wt(["Badge","Ribbon"],e=>{const t=XF(e);return Pce(t)},QF),Oce=e=>{const{className:t,prefixCls:n,style:r,color:o,children:i,text:a,placement:l="end",rootClassName:u,styles:d,classNames:m}=e,{getPrefixCls:p,direction:g,className:b,style:y,classNames:S,styles:C}=jt("ribbon"),w=p("ribbon",n),$=`${w}-wrapper`,[M,T]=Ice(w,$),R={...e,placement:l},[I,N]=Kt([S,m],[C,d],{props:R}),P=c1(o,false),O=X(w,`${w}-placement-${l}`,{[`${w}-rtl`]:g==="rtl",[`${w}-color-${o}`]:P},t,b,I.indicator),_={},B={};return o&&!P&&(_.background=o,B.color=o),f.createElement("div",{className:X($,u,M,T,I.root),style:N.root},i,f.createElement("div",{className:X(O,M),style:{..._,...N.indicator,...y,...r}},f.createElement("span",{className:X(`${w}-content`,I.content),style:N.content},a),f.createElement("div",{className:`${w}-corner`,style:B})))},u1=Nce;u1.Ribbon=Oce;var Dce={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 000 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281 360-281.1c3.8-3 6.1-7.7 6.1-12.6z"}}]},name:"left",theme:"outlined"};function RE(){return RE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},RE.apply(this,arguments)}const _ce=(e,t)=>f.createElement(Xn,RE({},e,{ref:t,icon:Dce})),fp=f.forwardRef(_ce),{ESC:Bce,TAB:Lce}=it;function zce({visible:e,triggerRef:t,onVisibleChange:n,autoFocus:r,overlayRef:o}){const i=f.useRef(false),a=()=>{e&&(t.current?.focus?.(),n?.(false));},l=()=>o.current?.focus?(o.current.focus(),i.current=true,true):false,u=d=>{switch(d.keyCode){case Bce:a();break;case Lce:{let m=false;i.current||(m=l()),m?d.preventDefault():a();break}}};f.useEffect(()=>e?(window.addEventListener("keydown",u),r&&Lt(l,3),()=>{window.removeEventListener("keydown",u),i.current=false;}):()=>{i.current=false;},[e]);}const kce=f.forwardRef((e,t)=>{const{overlay:n,arrow:r,prefixCls:o}=e,i=f.useMemo(()=>{let l;return typeof n=="function"?l=n():l=n,l},[n]),a=Vr(t,Ql(i));return q.createElement(q.Fragment,null,r&&q.createElement("div",{className:`${o}-arrow`}),q.cloneElement(i,{ref:Su(i)?a:void 0}))}),wd={adjustX:1,adjustY:1},$d=[0,0],Fce={topLeft:{points:["bl","tl"],overflow:wd,offset:[0,-4],targetOffset:$d},top:{points:["bc","tc"],overflow:wd,offset:[0,-4],targetOffset:$d},topRight:{points:["br","tr"],overflow:wd,offset:[0,-4],targetOffset:$d},bottomLeft:{points:["tl","bl"],overflow:wd,offset:[0,4],targetOffset:$d},bottom:{points:["tc","bc"],overflow:wd,offset:[0,4],targetOffset:$d},bottomRight:{points:["tr","br"],overflow:wd,offset:[0,4],targetOffset:$d}};function TE(){return TE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},TE.apply(this,arguments)}const ZF=q.forwardRef((e,t)=>{const{arrow:n=false,prefixCls:r="rc-dropdown",transitionName:o,animation:i,align:a,placement:l="bottomLeft",placements:u=Fce,getPopupContainer:d,showAction:m,hideAction:p,overlayClassName:g,overlayStyle:b,visible:y,trigger:S=["hover"],autoFocus:C,overlay:w,children:$,onVisibleChange:M,...T}=e,[R,I]=q.useState(),N="visible"in e?y:R,P=i?`${r}-${i}`:o,O=q.useRef(null),_=q.useRef(null),B=q.useRef(null);q.useImperativeHandle(t,()=>O.current);const V=Q=>{I(Q),M?.(Q);};zce({visible:N,triggerRef:B,onVisibleChange:V,autoFocus:C,overlayRef:_});const U=Q=>{const{onOverlayClick:D}=e;I(false),D&&D(Q);},G=()=>q.createElement(kce,{ref:_,overlay:w,prefixCls:r,arrow:n}),H=()=>typeof w=="function"?G:G(),z=()=>{const{minOverlayWidthMatchTrigger:Q,alignPoint:D}=e;return "minOverlayWidthMatchTrigger"in e?Q:!D},j=()=>{const{openClassName:Q}=e;return Q!==void 0?Q:`${r}-open`},W=q.cloneElement($,{className:X($.props?.className,N&&j()),ref:Su($)?Vr(B,Ql($)):void 0});let Y=p;return !Y&&S.indexOf("contextMenu")!==-1&&(Y=["click"]),q.createElement(Jy,TE({builtinPlacements:u},T,{prefixCls:r,ref:O,popupClassName:X(g,{[`${r}-show-arrow`]:n}),popupStyle:b,action:S,showAction:m,hideAction:Y,popupPlacement:l,popupAlign:a,popupMotion:{motionName:P},popupVisible:N,stretch:z()?"minWidth":"",popup:H(),onOpenChange:V,onPopupClick:U,getPopupContainer:d}),W)}),Hce=e=>typeof e!="object"&&typeof e!="function"||e===null,JF=f.createContext(null);function e7(e,t){return `${e}-${t}`}function t7(e){const t=f.useContext(JF);return e7(t,e)}const Ca=f.createContext(null);function Vce(e,t){const n={...e};return Object.keys(t).forEach(r=>{const o=t[r];o!==void 0&&(n[r]=o);}),n}function mp({children:e,locked:t,...n}){const r=f.useContext(Ca),o=Tf(()=>Vce(r,n),[r,n],(i,a)=>!t&&(i[0]!==a[0]||!zl(i[1],a[1],true)));return f.createElement(Ca.Provider,{value:o},e)}const jce=[],n7=f.createContext(null);function d1(){return f.useContext(n7)}const r7=f.createContext(jce);function _f(e){const t=f.useContext(r7);return f.useMemo(()=>e!==void 0?[...t,e]:t,[t,e])}const o7=f.createContext(null),zR=f.createContext({}),{LEFT:AE,RIGHT:NE,UP:PE,DOWN:Gb,ENTER:qb,ESC:i7,HOME:Qm,END:Zm}=it,jO=[PE,Gb,AE,NE];function Uce(e,t,n,r){const o="prev",i="next",a="children",l="parent";if(e==="inline"&&r===qb)return {inlineTrigger:true};const u={[PE]:o,[Gb]:i},d={[AE]:n?i:o,[NE]:n?o:i,[Gb]:a,[qb]:a},m={[PE]:o,[Gb]:i,[qb]:a,[i7]:l,[AE]:n?a:l,[NE]:n?l:a};switch({inline:u,horizontal:d,vertical:m,inlineSub:u,horizontalSub:m,verticalSub:m}[`${e}${t?"":"Sub"}`]?.[r]){case o:return {offset:-1,sibling:true};case i:return {offset:1,sibling:true};case l:return {offset:-1,sibling:false};case a:return {offset:1,sibling:false};default:return null}}function Wce(e){let t=e;for(;t;){if(t.getAttribute("data-menu-list"))return t;t=t.parentElement;}return null}function Gce(e,t){let n=e||document.activeElement;for(;n;){if(t.has(n))return n;n=n.parentElement;}return null}function kR(e,t){return CR(e,true).filter(r=>t.has(r))}function UO(e,t,n,r=1){if(!e)return null;const o=kR(e,t),i=o.length;let a=o.findIndex(l=>n===l);return r<0?a===-1?a=i-1:a-=1:r>0&&(a+=1),a=(a+i)%i,o[a]}const W0=(e,t)=>{const n=new Set,r=new Map,o=new Map;return e.forEach(i=>{const a=document.querySelector(`[data-menu-id='${e7(t,i)}']`);a&&(n.add(a),o.set(a,i),r.set(i,a));}),{elements:n,key2element:r,element2key:o}};function qce(e,t,n,r,o,i,a,l,u,d){const m=f.useRef(),p=f.useRef();p.current=t;const g=()=>{Lt.cancel(m.current);};return f.useEffect(()=>()=>{g();},[]),b=>{const{which:y}=b;if([...jO,qb,i7,Qm,Zm].includes(y)){const S=i();let C=W0(S,r);const{elements:w,key2element:$,element2key:M}=C,T=$.get(t),R=Gce(T,w),I=M.get(R),N=Uce(e,a(I,true).length===1,n,y);if(!N&&y!==Qm&&y!==Zm)return;(jO.includes(y)||[Qm,Zm].includes(y))&&b.preventDefault();const P=O=>{if(O){let _=O;const B=O.querySelector("a");B?.getAttribute("href")&&(_=B);const V=M.get(O);l(V),g(),m.current=Lt(()=>{p.current===V&&_.focus();});}};if([Qm,Zm].includes(y)||N.sibling||!R){let O;!R||e==="inline"?O=o.current:O=Wce(R);let _;const B=kR(O,w);y===Qm?_=B[0]:y===Zm?_=B[B.length-1]:_=UO(O,w,R,N.offset),P(_);}else if(N.inlineTrigger)u(I);else if(N.offset>0)u(I,true),g(),m.current=Lt(()=>{C=W0(S,r);const O=R.getAttribute("aria-controls"),_=document.getElementById(O),B=UO(_,C.elements);P(B);},5);else if(N.offset<0){const O=a(I,true),_=O[O.length-2],B=$.get(_);u(_,false),P(B);}}d?.(b);}}function Kce(e){Promise.resolve().then(e);}const FR="__RC_UTIL_PATH_SPLIT__",WO=e=>e.join(FR),Yce=e=>e.split(FR),IE="rc-menu-more";function Xce(){const[,e]=f.useState({}),t=f.useRef(new Map),n=f.useRef(new Map),[r,o]=f.useState([]),i=f.useRef(0),a=f.useRef(false),l=()=>{a.current||e({});},u=f.useCallback((S,C)=>{const w=WO(C);n.current.set(w,S),t.current.set(S,w),i.current+=1;const $=i.current;Kce(()=>{$===i.current&&l();});},[]),d=f.useCallback((S,C)=>{const w=WO(C);n.current.delete(w),t.current.delete(S);},[]),m=f.useCallback(S=>{o(S);},[]),p=f.useCallback((S,C)=>{const w=t.current.get(S)||"",$=Yce(w);return C&&r.includes($[0])&&$.unshift(IE),$},[r]),g=f.useCallback((S,C)=>S.filter(w=>w!==void 0).some(w=>p(w,true).includes(C)),[p]),b=()=>{const S=[...t.current.keys()];return r.length&&S.push(IE),S},y=f.useCallback(S=>{const C=`${t.current.get(S)}${FR}`,w=new Set;return [...n.current.keys()].forEach($=>{$.startsWith(C)&&w.add(n.current.get($));}),w},[]);return f.useEffect(()=>()=>{a.current=true;},[]),{registerPath:u,unregisterPath:d,refreshOverflowKeys:m,isSubPathKey:g,getKeyPath:p,getKeys:b,getSubPathKeys:y}}function xh(e){const t=f.useRef(e);t.current=e;const n=f.useCallback((...r)=>t.current?.(...r),[]);return e?n:void 0}function a7(e,t,n,r){const{activeKey:o,onActive:i,onInactive:a}=f.useContext(Ca),l={active:o===e};return t||(l.onMouseEnter=u=>{n?.({key:e,domEvent:u}),i(e);},l.onMouseLeave=u=>{r?.({key:e,domEvent:u}),a(e);}),l}function s7(e){const{mode:t,rtl:n,inlineIndent:r}=f.useContext(Ca);if(t!=="inline")return null;const o=e;return n?{paddingRight:o*r}:{paddingLeft:o*r}}function l7({icon:e,props:t,children:n}){let r;return e===null||e===false?null:(typeof e=="function"?r=f.createElement(e,{...t}):typeof e!="boolean"&&(r=e),r||n||null)}function G0({item:e,...t}){return Object.defineProperty(t,"item",{get:()=>(Er(false,"`info.item` is deprecated since we will move to function component that not provides React Node instance in future."),e)}),t}function hp(){return hp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},hp.apply(this,arguments)}class Qce extends f.Component{render(){const{title:t,attribute:n,elementRef:r,...o}=this.props,i=Ln(o,["eventKey","popupClassName","popupOffset","onTitleClick"]);return Er(!n,"`attribute` of Menu.Item is deprecated. Please pass attribute directly."),f.createElement(Ts.Item,hp({},n,{title:typeof t=="string"?t:void 0},i,{ref:r}))}}const Zce=f.forwardRef((e,t)=>{const{style:n,className:r,eventKey:o,warnKey:i,disabled:a,itemIcon:l,children:u,role:d,onMouseEnter:m,onMouseLeave:p,onClick:g,onKeyDown:b,onFocus:y,...S}=e,C=t7(o),{prefixCls:w,onItemClick:$,disabled:M,overflowDisabled:T,itemIcon:R,selectedKeys:I,onActive:N}=f.useContext(Ca),{_internalRenderMenuItem:P}=f.useContext(zR),O=`${w}-item`,_=f.useRef(),B=f.useRef(),V=M||a,U=Bs(t,B),G=_f(o),H=te=>({key:o,keyPath:[...G].reverse(),item:_.current,domEvent:te}),z=l||R,{active:j,...W}=a7(o,V,m,p),Y=I.includes(o),Q=s7(G.length),D=te=>{if(V)return;const re=H(te);g?.(G0(re)),$(re);},L=te=>{if(b?.(te),te.which===it.ENTER){const re=H(te);g?.(G0(re)),$(re);}},K=te=>{N(o),y?.(te);},J={};e.role==="option"&&(J["aria-selected"]=Y);let ee=f.createElement(Qce,hp({ref:_,elementRef:U,role:d===null?"none":d||"menuitem",tabIndex:a?null:-1,"data-menu-id":T&&C?null:C},Ln(S,["extra"]),W,J,{component:"li","aria-disabled":a,style:{...Q,...n},className:X(O,{[`${O}-active`]:j,[`${O}-selected`]:Y,[`${O}-disabled`]:V},r),onClick:D,onKeyDown:L,onFocus:K}),u,f.createElement(l7,{props:{...e,isSelected:Y},icon:z}));return P&&(ee=P(ee,e,{selected:Y})),ee});function Jce(e,t){const{eventKey:n}=e,r=d1(),o=_f(n);return f.useEffect(()=>{if(r)return r.registerPath(n,o),()=>{r.unregisterPath(n,o);}},[o]),r?null:f.createElement(Zce,hp({},e,{ref:t}))}const ag=f.forwardRef(Jce);function OE(){return OE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},OE.apply(this,arguments)}const eue=({className:e,children:t,...n},r)=>{const{prefixCls:o,mode:i,rtl:a}=f.useContext(Ca);return f.createElement("ul",OE({className:X(o,a&&`${o}-rtl`,`${o}-sub`,`${o}-${i==="inline"?"inline":"vertical"}`,e),role:"menu"},n,{"data-menu-list":true,ref:r}),t)},c7=f.forwardRef(eue);function HR(e,t){return Qo(e).map((n,r)=>{if(f.isValidElement(n)){const{key:o}=n;let i=n.props?.eventKey??o;i==null&&(i=`tmp_key-${[...t,r].join("-")}`);const l={key:i,eventKey:i};return f.cloneElement(n,l)}return n})}const po={adjustX:1,adjustY:1},tue={topLeft:{points:["bl","tl"],overflow:po},topRight:{points:["br","tr"],overflow:po},bottomLeft:{points:["tl","bl"],overflow:po},bottomRight:{points:["tr","br"],overflow:po},leftTop:{points:["tr","tl"],overflow:po},leftBottom:{points:["br","bl"],overflow:po},rightTop:{points:["tl","tr"],overflow:po},rightBottom:{points:["bl","br"],overflow:po}},nue={topLeft:{points:["bl","tl"],overflow:po},topRight:{points:["br","tr"],overflow:po},bottomLeft:{points:["tl","bl"],overflow:po},bottomRight:{points:["tr","br"],overflow:po},rightTop:{points:["tr","tl"],overflow:po},rightBottom:{points:["br","bl"],overflow:po},leftTop:{points:["tl","tr"],overflow:po},leftBottom:{points:["bl","br"],overflow:po}};function u7(e,t,n){if(t)return t;if(n)return n[e]||n.other}const rue={horizontal:"bottomLeft",vertical:"rightTop","vertical-left":"rightTop","vertical-right":"leftTop"};function oue({prefixCls:e,visible:t,children:n,popup:r,popupStyle:o,popupClassName:i,popupOffset:a,disabled:l,mode:u,onVisibleChange:d}){const{getPopupContainer:m,rtl:p,subMenuOpenDelay:g,subMenuCloseDelay:b,builtinPlacements:y,triggerSubMenuAction:S,forceSubMenuRender:C,rootClassName:w,motion:$,defaultMotions:M}=f.useContext(Ca),[T,R]=f.useState(false),I=p?{...nue,...y}:{...tue,...y},N=rue[u],P=u7(u,$,M),O=f.useRef(P);u!=="inline"&&(O.current=P);const _={...O.current,leavedClassName:`${e}-hidden`,removeOnLeave:false,motionAppear:true},B=f.useRef();return f.useEffect(()=>(B.current=Lt(()=>{R(t);}),()=>{Lt.cancel(B.current);}),[t]),f.createElement(Jy,{prefixCls:e,popupClassName:X(`${e}-popup`,{[`${e}-rtl`]:p},i,w),stretch:u==="horizontal"?"minWidth":null,getPopupContainer:m,builtinPlacements:I,popupPlacement:N,popupVisible:T,popup:r,popupStyle:o,popupAlign:a&&{offset:a},action:l?[]:[S],mouseEnterDelay:g,mouseLeaveDelay:b,onPopupVisibleChange:d,forceRender:C,popupMotion:_,fresh:true},n)}function DE(){return DE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},DE.apply(this,arguments)}function iue({id:e,open:t,keyPath:n,children:r}){const o="inline",{prefixCls:i,forceSubMenuRender:a,motion:l,defaultMotions:u,mode:d}=f.useContext(Ca),m=f.useRef(false);m.current=d===o;const[p,g]=f.useState(!m.current),b=m.current?t:false;f.useEffect(()=>{m.current&&g(false);},[d]);const y={...u7(o,l,u)};n.length>1&&(y.motionAppear=false);const S=y.onVisibleChanged;return y.onVisibleChanged=C=>(!m.current&&!C&&g(true),S?.(C)),p?null:f.createElement(mp,{mode:o,locked:!m.current},f.createElement(Co,DE({visible:b},y,{forceRender:a,removeOnLeave:false,leavedClassName:`${i}-hidden`}),({className:C,style:w})=>f.createElement(c7,{id:e,className:C,style:w},r)))}function pp(){return pp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},pp.apply(this,arguments)}const aue=f.forwardRef((e,t)=>{const{style:n,className:r,styles:o,classNames:i,title:a,eventKey:l,warnKey:u,disabled:d,internalPopupClose:m,children:p,itemIcon:g,expandIcon:b,popupClassName:y,popupOffset:S,popupStyle:C,onClick:w,onMouseEnter:$,onMouseLeave:M,onTitleClick:T,onTitleMouseEnter:R,onTitleMouseLeave:I,popupRender:N,...P}=e,O=t7(l),{prefixCls:_,mode:B,openKeys:V,disabled:U,overflowDisabled:G,activeKey:H,selectedKeys:z,itemIcon:j,expandIcon:W,onItemClick:Y,onOpenChange:Q,onActive:D,popupRender:L}=f.useContext(Ca),{_internalRenderSubMenuItem:K}=f.useContext(zR),{isSubPathKey:J}=f.useContext(o7),ee=_f(),te=`${_}-submenu`,re=U||d,ie=f.useRef(),de=f.useRef(),ne=g??j,ce=b??W,fe=V.includes(l),se=!G&&fe,Me=J(z,l),{active:ae,...pe}=a7(l,re,R,I),[Ce,xe]=f.useState(false),Ae=Oe=>{re||xe(Oe);},Xe=Oe=>{Ae(true),$?.({key:l,domEvent:Oe});},Ne=Oe=>{Ae(false),M?.({key:l,domEvent:Oe});},ue=f.useMemo(()=>ae||(B!=="inline"?Ce||J([H],l):false),[B,ae,H,Ce,l,J]),ge=s7(ee.length),Pe=Oe=>{re||(T?.({key:l,domEvent:Oe}),B==="inline"&&Q(l,!fe));},je=xh(Oe=>{w?.(G0(Oe)),Y(Oe);}),qe=Oe=>{B!=="inline"&&Q(l,Oe);},Ue=()=>{D(l);},et=O&&`${O}-popup`,rt=f.useMemo(()=>f.createElement(l7,{icon:B!=="horizontal"?ce:void 0,props:{...e,isOpen:se,isSubMenu:true}},f.createElement("i",{className:`${te}-arrow`})),[B,ce,e,se,te]);let Ke=f.createElement("div",pp({role:"menuitem",style:ge,className:`${te}-title`,tabIndex:re?null:-1,ref:ie,title:typeof a=="string"?a:null,"data-menu-id":G&&O?null:O,"aria-expanded":se,"aria-haspopup":true,"aria-controls":et,"aria-disabled":re,onClick:Pe,onFocus:Ue},pe),a,rt);const _e=f.useRef(B);B!=="inline"&&ee.length>1?_e.current="vertical":_e.current=B;const We=_e.current,Ze=f.useMemo(()=>{const Oe=f.createElement(mp,{classNames:i,styles:o,mode:We==="horizontal"?"vertical":We},f.createElement(c7,{id:et,ref:de},p)),lt=N||L;return lt?lt(Oe,{item:e,keys:ee}):Oe},[N,L,ee,et,p,e,We]);if(!G){const Oe=_e.current;Ke=f.createElement(oue,{mode:Oe,prefixCls:te,visible:!m&&se&&B!=="inline",popupClassName:y,popupOffset:S,popupStyle:C,popup:Ze,disabled:re,onVisibleChange:qe},Ke);}let Be=f.createElement(Ts.Item,pp({ref:t,role:"none"},P,{component:"li",style:n,className:X(te,`${te}-${B}`,r,{[`${te}-open`]:se,[`${te}-active`]:ue,[`${te}-selected`]:Me,[`${te}-disabled`]:re}),onMouseEnter:Xe,onMouseLeave:Ne}),Ke,!G&&f.createElement(iue,{id:et,open:se,keyPath:ee},p));return K&&(Be=K(Be,e,{selected:Me,active:ue,open:se,disabled:re})),f.createElement(mp,{classNames:i,styles:o,onItemClick:je,mode:B==="horizontal"?"vertical":B,itemIcon:ne,expandIcon:ce},Be)}),f1=f.forwardRef((e,t)=>{const{eventKey:n,children:r}=e,o=_f(n),i=HR(r,o),a=d1();f.useEffect(()=>{if(a)return a.registerPath(n,o),()=>{a.unregisterPath(n,o);}},[o]);let l;return a?l=i:l=f.createElement(aue,pp({ref:t},e),i),f.createElement(r7.Provider,{value:o},l)});function VR({className:e,style:t}){const{prefixCls:n}=f.useContext(Ca);return d1()?null:f.createElement("li",{role:"separator",className:X(`${n}-item-divider`,e),style:t})}function q0(){return q0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},q0.apply(this,arguments)}const sue=f.forwardRef((e,t)=>{const{className:n,title:r,eventKey:o,children:i,...a}=e,{prefixCls:l,classNames:u,styles:d}=f.useContext(Ca),m=`${l}-item-group`;return f.createElement("li",q0({ref:t,role:"presentation"},a,{onClick:p=>p.stopPropagation(),className:X(m,n)}),f.createElement("div",{role:"presentation",className:X(`${m}-title`,u?.listTitle),style:d?.listTitle,title:typeof r=="string"?r:void 0},r),f.createElement("ul",{role:"group",className:X(`${m}-list`,u?.list),style:d?.list},i))}),jR=f.forwardRef((e,t)=>{const{eventKey:n,children:r}=e,o=_f(n),i=HR(r,o);return d1()?i:f.createElement(sue,q0({ref:t},Ln(e,["warnKey"])),i)});function Dd(){return Dd=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Dd.apply(this,arguments)}function _E(e,t,n){const{item:r,group:o,submenu:i,divider:a}=t;return (e||[]).map((l,u)=>{if(l&&typeof l=="object"){const{label:d,children:m,key:p,type:g,extra:b,...y}=l,S=p??`tmp-${u}`;return m||g==="group"?g==="group"?f.createElement(o,Dd({key:S},y,{title:d}),_E(m,t,n)):f.createElement(i,Dd({key:S},y,{title:d}),_E(m,t,n)):g==="divider"?f.createElement(a,Dd({key:S},y)):f.createElement(r,Dd({key:S},y,{extra:b}),d,(!!b||b===0)&&f.createElement("span",{className:`${n}-item-extra`},b))}return null}).filter(l=>l)}function GO(e,t,n,r,o){let i=e;const a={divider:VR,item:ag,group:jR,submenu:f1,...r};return t&&(i=_E(t,a,o)),HR(i,n)}function BE(){return BE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},BE.apply(this,arguments)}const Mc=[],lue=f.forwardRef((e,t)=>{const{prefixCls:n="rc-menu",rootClassName:r,style:o,className:i,styles:a,classNames:l,tabIndex:u=0,items:d,children:m,direction:p,id:g,mode:b="vertical",inlineCollapsed:y,disabled:S,disabledOverflow:C,subMenuOpenDelay:w=.1,subMenuCloseDelay:$=.1,forceSubMenuRender:M,defaultOpenKeys:T,openKeys:R,activeKey:I,defaultActiveFirst:N,selectable:P=true,multiple:O=false,defaultSelectedKeys:_,selectedKeys:B,onSelect:V,onDeselect:U,inlineIndent:G=24,motion:H,defaultMotions:z,triggerSubMenuAction:j="hover",builtinPlacements:W,itemIcon:Y,expandIcon:Q,overflowedIndicator:D="...",overflowedIndicatorPopupClassName:L,getPopupContainer:K,onClick:J,onOpenChange:ee,onKeyDown:te,openAnimation:re,openTransitionName:ie,_internalRenderMenuItem:de,_internalRenderSubMenuItem:ne,_internalComponents:ce,popupRender:fe,...se}=e,[Me,ae]=f.useMemo(()=>[GO(m,d,Mc,ce,n),GO(m,d,Mc,{},n)],[m,d,ce]),[pe,Ce]=f.useState(false),xe=f.useRef(),Ae=zs(g?`rc-menu-uuid-${g}`:"rc-menu-uuid"),Xe=p==="rtl",[Ne,ue]=un(T,R),ge=Ne||Mc,Pe=(Re,ct=false)=>{function tt(){ue(Re),ee?.(Re);}ct?$o.flushSync(tt):tt();},[je,qe]=f.useState(ge),Ue=f.useRef(false),[et,rt]=f.useMemo(()=>(b==="inline"||b==="vertical")&&y?["vertical",y]:[b,false],[b,y]),Ke=et==="inline",[_e,We]=f.useState(et),[Ze,Be]=f.useState(rt);f.useEffect(()=>{We(et),Be(rt),Ue.current&&(Ke?ue(je):Pe(Mc));},[et,rt]);const[Oe,lt]=f.useState(0),It=Oe>=Me.length-1||_e!=="horizontal"||C;f.useEffect(()=>{Ke&&qe(ge);},[ge]),f.useEffect(()=>(Ue.current=true,()=>{Ue.current=false;}),[]);const{registerPath:mt,unregisterPath:Bt,refreshOverflowKeys:xt,isSubPathKey:Tt,getKeyPath:ut,getKeys:dt,getSubPathKeys:gt}=Xce(),Fe=f.useMemo(()=>({registerPath:mt,unregisterPath:Bt}),[mt,Bt]),Qe=f.useMemo(()=>({isSubPathKey:Tt}),[Tt]);f.useEffect(()=>{xt(It?Mc:Me.slice(Oe+1).map(Re=>Re.key));},[Oe,It]);const[ye,be]=un(I||N&&Me[0]?.key,I),Se=xh(Re=>{be(Re);}),he=xh(()=>{be(void 0);});f.useImperativeHandle(t,()=>({list:xe.current,focus:Re=>{const ct=dt(),{elements:tt,key2element:yt,element2key:At}=W0(ct,Ae),en=kR(xe.current,tt);let Zt;ye&&ct.includes(ye)?Zt=ye:Zt=en[0]?At.get(en[0]):Me.find(Un=>!Un.props.disabled)?.key;const mn=yt.get(Zt);Zt&&mn&&mn?.focus?.(Re);},findItem:({key:Re})=>{const ct=dt(),{key2element:tt}=W0(ct,Ae);return tt.get(Re)||null}}));const[De,$e]=un(_||[],B),ke=f.useMemo(()=>Array.isArray(De)?De:De==null?Mc:[De],[De]),Ge=Re=>{if(P){const{key:ct}=Re,tt=ke.includes(ct);let yt;O?tt?yt=ke.filter(en=>en!==ct):yt=[...ke,ct]:yt=[ct],$e(yt);const At={...Re,selectedKeys:yt};tt?U?.(At):V?.(At);}!O&&ge.length&&_e!=="inline"&&Pe(Mc);},ot=xh(Re=>{J?.(G0(Re)),Ge(Re);}),ht=xh((Re,ct)=>{let tt=ge.filter(yt=>yt!==Re);if(ct)tt.push(Re);else if(_e!=="inline"){const yt=gt(Re);tt=tt.filter(At=>!yt.has(At));}zl(ge,tt,true)||Pe(tt,true);}),Rt=qce(_e,ye,Xe,Ae,xe,dt,ut,be,(Re,ct)=>{const tt=ct??!ge.includes(Re);ht(Re,tt);},te);f.useEffect(()=>{Ce(true);},[]);const Ot=f.useMemo(()=>({_internalRenderMenuItem:de,_internalRenderSubMenuItem:ne}),[de,ne]),Sn=_e!=="horizontal"||C?Me:Me.map((Re,ct)=>f.createElement(mp,{key:Re.key,overflowDisabled:ct>Oe,classNames:l,styles:a},Re)),Hn=f.createElement(Ts,BE({id:g,ref:xe,prefixCls:`${n}-overflow`,component:"ul",itemComponent:ag,className:X(n,`${n}-root`,`${n}-${_e}`,i,{[`${n}-inline-collapsed`]:Ze,[`${n}-rtl`]:Xe},r),dir:p,style:o,role:"menu",tabIndex:u,data:Sn,renderRawItem:Re=>Re,renderRawRest:Re=>{const ct=Re.length,tt=ct?Me.slice(-ct):null;return f.createElement(f1,{eventKey:IE,title:D,disabled:It,internalPopupClose:ct===0,popupClassName:L},tt)},maxCount:_e!=="horizontal"||C?Ts.INVALIDATE:Ts.RESPONSIVE,ssr:"full","data-menu-list":true,onVisibleChange:Re=>{lt(Re);},onKeyDown:Rt},se));return f.createElement(zR.Provider,{value:Ot},f.createElement(JF.Provider,{value:Ae},f.createElement(mp,{prefixCls:n,rootClassName:r,classNames:l,styles:a,mode:_e,openKeys:ge,rtl:Xe,disabled:S,motion:pe?H:null,defaultMotions:pe?z:null,activeKey:ye,onActive:Se,onInactive:he,selectedKeys:ke,inlineIndent:G,subMenuOpenDelay:w,subMenuCloseDelay:$,forceSubMenuRender:M,builtinPlacements:W,triggerSubMenuAction:j,getPopupContainer:K,itemIcon:Y,expandIcon:Q,onItemClick:ot,onOpenChange:ht,popupRender:fe},f.createElement(o7.Provider,{value:Qe},Hn),f.createElement("div",{style:{display:"none"},"aria-hidden":true},f.createElement(n7.Provider,{value:Fe},ae)))))}),Bf=lue;Bf.Item=ag;Bf.SubMenu=f1;Bf.ItemGroup=jR;Bf.Divider=VR;const d7=f.createContext({});var cue={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M176 511a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0zm280 0a56 56 0 10112 0 56 56 0 10-112 0z"}}]},name:"ellipsis",theme:"outlined"};function LE(){return LE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},LE.apply(this,arguments)}const uue=(e,t)=>f.createElement(Xn,LE({},e,{ref:t,icon:cue})),UR=f.forwardRef(uue),K0=f.createContext({prefixCls:"",firstLevel:true,inlineCollapsed:false,styles:null,classNames:null}),f7=e=>{const{prefixCls:t,className:n,dashed:r,...o}=e,{getPrefixCls:i}=f.useContext(wt),a=i("menu",t),l=X({[`${a}-item-divider-dashed`]:!!r},n);return f.createElement(VR,{className:l,...o})},m7=e=>{const{className:t,children:n,icon:r,title:o,danger:i,extra:a}=e,{prefixCls:l,firstLevel:u,direction:d,disableMenuItemTitleTooltip:m,tooltip:p,inlineCollapsed:g,styles:b,classNames:y}=f.useContext(K0),S=N=>{const P=n?.[0],O=f.createElement("span",{className:X(`${l}-title-content`,u?y?.itemContent:y?.subMenu?.itemContent,{[`${l}-title-content-with-extra`]:!!a||a===0}),style:u?b?.itemContent:b?.subMenu?.itemContent},n);return (!r||f.isValidElement(n)&&n.type==="span")&&n&&N&&u&&typeof P=="string"?f.createElement("div",{className:`${l}-inline-collapsed-noicon`},P.charAt(0)):O},{siderCollapsed:C}=f.useContext(d7);let w=o;typeof o>"u"?w=u?n:"":o===false&&(w="");const $=p===false?void 0:p,M=$&&$.title!==void 0?$.title:w,T={...$??null,title:M};!C&&!g&&(T.title=null,T.open=false);const R=Qo(n).length;let I=f.createElement(ag,{...Ln(e,["title","icon","danger"]),className:X(u?y?.item:y?.subMenu?.item,{[`${l}-item-danger`]:i,[`${l}-item-only-child`]:(r?R+1:R)===1},t),style:{...u?b?.item:b?.subMenu?.item,...e.style},title:typeof o=="string"?o:void 0},Hr(r,N=>({className:X(`${l}-item-icon`,u?y?.itemIcon:y?.subMenu?.itemIcon,N.className),style:{...u?b?.itemIcon:b?.subMenu?.itemIcon,...N.style}})),S(g));if(!m&&p!==false){const N=$&&$.placement?$.placement:d==="rtl"?"left":"right",P=`${l}-inline-collapsed-tooltip`,O=B=>({...B,root:X(P,B?.root)}),_=$&&typeof $.classNames=="function"?B=>{const V=$.classNames(B);return O(V)}:O($?.classNames);I=f.createElement(Jl,{...T,placement:N,classNames:_},I);}return I},Y0=f.createContext(null),due=f.forwardRef((e,t)=>{const{children:n,...r}=e,o=f.useContext(Y0),i=f.useMemo(()=>({...o,...r}),[o,r.prefixCls,r.mode,r.selectable,r.rootClassName]),a=iJ(n),l=Bs(t,a?Ql(n):null);return f.createElement(Y0.Provider,{value:i},f.createElement(Vl,{space:true},a?f.cloneElement(n,{ref:l}):n))}),fue=e=>{const{componentCls:t,motionDurationSlow:n,horizontalLineHeight:r,colorSplit:o,lineWidth:i,lineType:a,itemPaddingInline:l}=e;return {[`${t}-horizontal`]:{lineHeight:r,border:0,borderBottom:`${oe(i)} ${a} ${o}`,boxShadow:"none","&::after":{display:"block",clear:"both",height:0,content:'"\\20"'},[`${t}-item, ${t}-submenu`]:{position:"relative",display:"inline-block",verticalAlign:"bottom",paddingInline:l},[`> ${t}-item:hover,
> ${t}-item-active,
> ${t}-submenu ${t}-submenu-title:hover`]:{backgroundColor:"transparent"},[`${t}-item, ${t}-submenu-title`]:{transition:["border-color","background-color"].map(u=>`${u} ${n}`).join(",")},[`${t}-submenu-arrow`]:{display:"none"}}}},mue=({componentCls:e,menuArrowOffset:t,calc:n})=>({[`${e}-rtl`]:{direction:"rtl"},[`${e}-submenu-rtl`]:{transformOrigin:"100% 0"},[`${e}-rtl${e}-vertical,
${e}-submenu-rtl ${e}-vertical`]:{[`${e}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateY(${oe(n(t).mul(-1).equal())})`},"&::after":{transform:`rotate(45deg) translateY(${oe(t)})`}}}}),qO=e=>ba(e),KO=(e,t)=>{const{componentCls:n,itemColor:r,itemSelectedColor:o,subMenuItemSelectedColor:i,groupTitleColor:a,itemBg:l,subMenuItemBg:u,itemSelectedBg:d,activeBarHeight:m,activeBarWidth:p,activeBarBorderWidth:g,motionDurationSlow:b,motionEaseInOut:y,motionEaseOut:S,itemPaddingInline:C,motionDurationMid:w,itemHoverColor:$,lineType:M,colorSplit:T,itemDisabledColor:R,dangerItemColor:I,dangerItemHoverColor:N,dangerItemSelectedColor:P,dangerItemActiveBg:O,dangerItemSelectedBg:_,popupBg:B,itemHoverBg:V,itemActiveBg:U,menuSubMenuBg:G,horizontalItemSelectedColor:H,horizontalItemSelectedBg:z,horizontalItemBorderRadius:j,horizontalItemHoverBg:W}=e;return {[`${n}-${t}, ${n}-${t} > ${n}`]:{color:r,background:l,[`&${n}-root:focus-visible`]:{...qO(e)},[`${n}-item`]:{"&-group-title, &-extra":{color:a}},[`${n}-submenu-selected > ${n}-submenu-title`]:{color:i},[`${n}-item, ${n}-submenu-title`]:{color:r,[`&:not(${n}-item-disabled):focus-visible`]:{...qO(e)}},[`${n}-item-disabled, ${n}-submenu-disabled`]:{color:`${R} !important`},[`${n}-item:not(${n}-item-selected):not(${n}-submenu-selected)`]:{[`&:hover, > ${n}-submenu-title:hover`]:{color:$}},[`&:not(${n}-horizontal)`]:{[`${n}-item:not(${n}-item-selected)`]:{"&:hover":{backgroundColor:V},"&:active":{backgroundColor:U}},[`${n}-submenu-title`]:{"&:hover":{backgroundColor:V},"&:active":{backgroundColor:U}}},[`${n}-item-danger`]:{color:I,[`&${n}-item:hover`]:{[`&:not(${n}-item-selected):not(${n}-submenu-selected)`]:{color:N}},[`&${n}-item:active`]:{background:O}},[`${n}-item a`]:{"&, &:hover":{color:"inherit"}},[`${n}-item-selected`]:{color:o,[`&${n}-item-danger`]:{color:P},"a, a:hover":{color:"inherit"}},[`& ${n}-item-selected`]:{backgroundColor:d,[`&${n}-item-danger`]:{backgroundColor:_}},[`&${n}-submenu > ${n}`]:{backgroundColor:G},[`&${n}-popup > ${n}`]:{backgroundColor:B},[`&${n}-submenu-popup > ${n}`]:{backgroundColor:B},[`&${n}-horizontal`]:{...t==="dark"?{borderBottom:0}:{},[`> ${n}-item, > ${n}-submenu`]:{top:g,marginTop:e.calc(g).mul(-1).equal(),marginBottom:0,borderRadius:j,"&::after":{position:"absolute",insetInline:C,bottom:0,borderBottom:`${oe(m)} solid transparent`,transition:`border-color ${b} ${y}`,content:'""'},"&:hover, &-active, &-open":{background:W,"&::after":{borderBottomWidth:m,borderBottomColor:H}},"&-selected":{color:H,backgroundColor:z,"&:hover":{backgroundColor:z},"&::after":{borderBottomWidth:m,borderBottomColor:H}}}},[`&${n}-root`]:{[`&${n}-inline, &${n}-vertical`]:{borderInlineEnd:`${oe(g)} ${M} ${T}`}},[`&${n}-inline`]:{[`${n}-sub${n}-inline`]:{background:u},[`${n}-item`]:{position:"relative","&::after":{position:"absolute",insetBlock:0,insetInlineEnd:0,borderInlineEnd:`${oe(p)} solid ${o}`,transform:"scaleY(0.0001)",opacity:0,transition:["transform","opacity"].map(Y=>`${Y} ${w} ${S}`).join(","),content:'""'},[`&${n}-item-danger`]:{"&::after":{borderInlineEndColor:P}}},[`${n}-selected, ${n}-item-selected`]:{"&::after":{transform:"scaleY(1)",opacity:1,transition:["transform","opacity"].map(Y=>`${Y} ${w} ${y}`).join(",")}}}}}},YO=e=>{const{componentCls:t,itemHeight:n,itemMarginInline:r,padding:o,menuArrowSize:i,marginXS:a,itemMarginBlock:l,itemWidth:u,itemPaddingInline:d}=e,m=e.calc(i).add(o).add(a).equal();return {[`${t}-item`]:{position:"relative",overflow:"hidden"},[`${t}-item, ${t}-submenu-title`]:{height:n,lineHeight:oe(n),paddingInline:d,overflow:"hidden",textOverflow:"ellipsis",marginInline:r,marginBlock:l,width:u},[`> ${t}-item,
> ${t}-submenu > ${t}-submenu-title`]:{height:n,lineHeight:oe(n)},[`${t}-item-group-list ${t}-submenu-title,
${t}-submenu-title`]:{paddingInlineEnd:m}}},hue=e=>{const{componentCls:t,iconCls:n,itemHeight:r,colorTextLightSolid:o,dropdownWidth:i,controlHeightLG:a,motionEaseOut:l,paddingXL:u,itemMarginInline:d,fontSizeLG:m,motionDurationFast:p,motionDurationSlow:g,paddingXS:b,boxShadowSecondary:y,collapsedWidth:S,collapsedIconSize:C}=e,w={height:r,lineHeight:oe(r),listStylePosition:"inside",listStyleType:"disc"};return [{[t]:{"&-inline, &-vertical":{[`&${t}-root`]:{boxShadow:"none"},...YO(e)}},[`${t}-submenu-popup`]:{[`${t}-vertical`]:{...YO(e),boxShadow:y}}},{[`${t}-submenu-popup ${t}-vertical${t}-sub`]:{minWidth:i,maxHeight:`calc(100vh - ${oe(e.calc(a).mul(2.5).equal())})`,padding:"0",overflow:"hidden",borderInlineEnd:0,"&:not([class*='-active'])":{overflowX:"hidden",overflowY:"auto"}}},{[`${t}-inline`]:{width:"100%",[`&${t}-root`]:{[`${t}-item, ${t}-submenu-title`]:{display:"flex",alignItems:"center",transition:[`border-color ${g}`,`background-color ${g}`,`padding ${p} ${l}`].join(","),[`> ${t}-title-content`]:{flex:"auto",minWidth:0,overflow:"hidden",textOverflow:"ellipsis"},"> *":{flex:"none"}}},[`${t}-sub${t}-inline`]:{padding:0,border:0,borderRadius:0,boxShadow:"none",[`& > ${t}-submenu > ${t}-submenu-title`]:w,[`& ${t}-item-group-title`]:{paddingInlineStart:u}},[`${t}-item`]:w}},{[`${t}-inline-collapsed`]:{width:S,[`&${t}-root`]:{[`${t}-item, ${t}-submenu ${t}-submenu-title`]:{[`> ${t}-inline-collapsed-noicon`]:{fontSize:m,textAlign:"center"}}},[`> ${t}-item,
> ${t}-item-group > ${t}-item-group-list > ${t}-item,
> ${t}-item-group > ${t}-item-group-list > ${t}-submenu > ${t}-submenu-title,
> ${t}-submenu > ${t}-submenu-title`]:{insetInlineStart:0,paddingInline:`calc(50% - ${oe(e.calc(C).div(2).equal())} - ${oe(d)})`,textOverflow:"clip",[`
${t}-submenu-arrow,
${t}-submenu-expand-icon
`]:{opacity:0},[`${t}-item-icon, ${n}`]:{margin:0,fontSize:C,lineHeight:oe(r),"+ span":{display:"inline-block",opacity:0}}},[`${t}-item-icon, ${n}`]:{display:"inline-block"},"&-tooltip":{pointerEvents:"none",[`${t}-item-icon, ${n}`]:{display:"none"},"a, a:hover":{color:o}},[`${t}-item-group-title`]:{...Ga,paddingInline:b}}}]},XO=e=>{const{componentCls:t,motionDurationSlow:n,motionDurationMid:r,motionEaseInOut:o,motionEaseOut:i,iconCls:a,iconSize:l,iconMarginInlineEnd:u}=e;return {[`${t}-item, ${t}-submenu-title`]:{position:"relative",display:"block",margin:0,whiteSpace:"nowrap",cursor:"pointer",transition:[`border-color ${n}`,`background-color ${n}`,`padding calc(${n} + 0.1s) ${o}`].join(","),[`${t}-item-icon, ${a}`]:{minWidth:l,fontSize:l,transition:[`font-size ${r} ${i}`,`margin ${n} ${o}`,`color ${n}`].join(","),"+ span":{marginInlineStart:u,opacity:1,transition:[`opacity ${n} ${o}`,`margin ${n}`,`color ${n}`].join(",")}},[`${t}-item-icon`]:{...Cu()},[`&${t}-item-only-child`]:{[`> ${a}, > ${t}-item-icon`]:{marginInlineEnd:0}}},[`${t}-item-disabled, ${t}-submenu-disabled`]:{background:"none !important",cursor:"not-allowed","&::after":{borderColor:"transparent !important"},a:{color:"inherit !important",cursor:"not-allowed",pointerEvents:"none"},[`> ${t}-submenu-title`]:{color:"inherit !important",cursor:"not-allowed"}}}},QO=e=>{const{componentCls:t,motionDurationSlow:n,motionEaseInOut:r,borderRadius:o,menuArrowSize:i,menuArrowOffset:a}=e;return {[`${t}-submenu`]:{"&-expand-icon, &-arrow":{position:"absolute",top:"50%",insetInlineEnd:e.margin,width:i,color:"currentcolor",transform:"translateY(-50%)",transition:["transform","opacity"].map(l=>`${l} ${n}`).join(",")},"&-arrow":{"&::before, &::after":{position:"absolute",width:e.calc(i).mul(.6).equal(),height:e.calc(i).mul(.15).equal(),backgroundColor:"currentcolor",borderRadius:o,transition:["background-color","transform","top","color"].map(l=>`${l} ${n} ${r}`).join(","),content:'""'},"&::before":{transform:`rotate(45deg) translateY(${oe(e.calc(a).mul(-1).equal())})`},"&::after":{transform:`rotate(-45deg) translateY(${oe(a)})`}}}}},pue=e=>{const{antCls:t,componentCls:n,fontSize:r,motionDurationSlow:o,motionDurationMid:i,motionEaseInOut:a,paddingXS:l,padding:u,colorSplit:d,lineWidth:m,zIndexPopup:p,borderRadiusLG:g,subMenuItemBorderRadius:b,menuArrowSize:y,menuArrowOffset:S,lineType:C,groupTitleLineHeight:w,groupTitleFontSize:$}=e;return [{"":{[n]:{...P0(),"&-hidden":{display:"none"}}},[`${n}-submenu-hidden`]:{display:"none"}},{[n]:{...dn(e),...P0(),marginBottom:0,paddingInlineStart:0,fontSize:r,lineHeight:0,listStyle:"none",outline:"none",transition:`width ${o} cubic-bezier(0.2, 0, 0, 1) 0s`,"ul, ol":{margin:0,padding:0,listStyle:"none"},"&-overflow":{display:"flex",[`${n}-item`]:{flex:"none"}},[`${n}-item, ${n}-submenu, ${n}-submenu-title`]:{borderRadius:e.itemBorderRadius},[`${n}-item-group-title`]:{padding:`${oe(l)} ${oe(u)}`,fontSize:$,lineHeight:w,transition:`all ${o}`},[`&-horizontal ${n}-submenu`]:{transition:["border-color","background-color"].map(M=>`${M} ${o} ${a}`).join(",")},[`${n}-submenu, ${n}-submenu-inline`]:{transition:[`border-color ${o}`,`background-color ${o}`,`padding ${i}`].map(M=>`${M} ${a}`).join(",")},[`${n}-submenu ${n}-sub`]:{cursor:"initial",transition:["background-color","padding"].map(M=>`${M} ${o} ${a}`).join(",")},[`${n}-title-content`]:{transition:`color ${o}`,"&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},[`> ${t}-typography-ellipsis-single-line`]:{display:"inline",verticalAlign:"unset"},[`${n}-item-extra`]:{marginInlineStart:"auto",paddingInlineStart:e.padding}},[`${n}-item a`]:{"&::before":{position:"absolute",inset:0,backgroundColor:"transparent",content:'""'}},[`${n}-item-divider`]:{overflow:"hidden",lineHeight:0,borderColor:d,borderStyle:C,borderWidth:0,borderTopWidth:m,marginBlock:m,padding:0,"&-dashed":{borderStyle:"dashed"}},...XO(e),[`${n}-item-group`]:{[`${n}-item-group-list`]:{margin:0,padding:0,[`${n}-item, ${n}-submenu-title`]:{paddingInline:`${oe(e.calc(r).mul(2).equal())} ${oe(u)}`}}},"&-submenu":{"&-popup":{position:"absolute",zIndex:p,borderRadius:g,boxShadow:"none",transformOrigin:"0 0",[`&${n}-submenu`]:{background:"transparent"},"&::before":{position:"absolute",inset:0,zIndex:-1,width:"100%",height:"100%",opacity:0,content:'""'},[`> ${n}`]:{borderRadius:g,...XO(e),...QO(e),[`${n}-item, ${n}-submenu > ${n}-submenu-title`]:{borderRadius:b},[`${n}-submenu-title::after`]:{transition:`transform ${o} ${a}`}}},"\n &-placement-leftTop,\n &-placement-bottomRight,\n ":{transformOrigin:"100% 0"},"\n &-placement-leftBottom,\n &-placement-topRight,\n ":{transformOrigin:"100% 100%"},"\n &-placement-rightBottom,\n &-placement-topLeft,\n ":{transformOrigin:"0 100%"},"\n &-placement-bottomLeft,\n &-placement-rightTop,\n ":{transformOrigin:"0 0"},"\n &-placement-leftTop,\n &-placement-leftBottom\n ":{paddingInlineEnd:e.paddingXS},"\n &-placement-rightTop,\n &-placement-rightBottom\n ":{paddingInlineStart:e.paddingXS},"\n &-placement-topRight,\n &-placement-topLeft\n ":{paddingBottom:e.paddingXS},"\n &-placement-bottomRight,\n &-placement-bottomLeft\n ":{paddingTop:e.paddingXS}},...QO(e),[`&-inline-collapsed ${n}-submenu-arrow,
&-inline ${n}-submenu-arrow`]:{"&::before":{transform:`rotate(-45deg) translateX(${oe(S)})`},"&::after":{transform:`rotate(45deg) translateX(${oe(e.calc(S).mul(-1).equal())})`}},[`${n}-submenu-open${n}-submenu-inline > ${n}-submenu-title > ${n}-submenu-arrow`]:{transform:`translateY(${oe(e.calc(y).mul(.2).mul(-1).equal())})`,"&::after":{transform:`rotate(-45deg) translateX(${oe(e.calc(S).mul(-1).equal())})`},"&::before":{transform:`rotate(45deg) translateX(${oe(S)})`}}}},{[`${t}-layout-header`]:{[n]:{lineHeight:"inherit"}}}]},gue=e=>{const{colorPrimary:t,colorError:n,colorTextDisabled:r,colorErrorBg:o,colorText:i,colorTextDescription:a,colorBgContainer:l,colorFillAlter:u,colorFillContent:d,lineWidth:m,lineWidthBold:p,controlItemBgActive:g,colorBgTextHover:b,controlHeightLG:y,lineHeight:S,colorBgElevated:C,marginXXS:w,padding:$,fontSize:M,controlHeightSM:T,fontSizeLG:R,colorTextLightSolid:I,colorErrorHover:N}=e,P=e.activeBarWidth??0,O=e.activeBarBorderWidth??m,_=e.itemMarginInline??e.marginXXS,B=new cn(I).setA(.65).toRgbString();return {dropdownWidth:160,zIndexPopup:e.zIndexPopupBase+50,radiusItem:e.borderRadiusLG,itemBorderRadius:e.borderRadiusLG,radiusSubMenuItem:e.borderRadiusSM,subMenuItemBorderRadius:e.borderRadiusSM,colorItemText:i,itemColor:i,colorItemTextHover:i,itemHoverColor:i,colorItemTextHoverHorizontal:t,horizontalItemHoverColor:t,colorGroupTitle:a,groupTitleColor:a,colorItemTextSelected:t,itemSelectedColor:t,subMenuItemSelectedColor:t,colorItemTextSelectedHorizontal:t,horizontalItemSelectedColor:t,colorItemBg:l,itemBg:l,colorItemBgHover:b,itemHoverBg:b,colorItemBgActive:d,itemActiveBg:g,colorSubItemBg:u,subMenuItemBg:u,colorItemBgSelected:g,itemSelectedBg:g,colorItemBgSelectedHorizontal:"transparent",horizontalItemSelectedBg:"transparent",colorActiveBarWidth:0,activeBarWidth:P,colorActiveBarHeight:p,activeBarHeight:p,colorActiveBarBorderSize:m,activeBarBorderWidth:O,colorItemTextDisabled:r,itemDisabledColor:r,colorDangerItemText:n,dangerItemColor:n,colorDangerItemTextHover:n,dangerItemHoverColor:n,colorDangerItemTextSelected:n,dangerItemSelectedColor:n,colorDangerItemBgActive:o,dangerItemActiveBg:o,colorDangerItemBgSelected:o,dangerItemSelectedBg:o,itemMarginInline:_,horizontalItemBorderRadius:0,horizontalItemHoverBg:"transparent",itemHeight:y,groupTitleLineHeight:S,collapsedWidth:y*2,popupBg:C,itemMarginBlock:w,itemPaddingInline:$,horizontalLineHeight:`${y*1.15}px`,iconSize:M,iconMarginInlineEnd:T-M,collapsedIconSize:R,groupTitleFontSize:M,darkItemDisabledColor:new cn(I).setA(.25).toRgbString(),darkItemColor:B,darkDangerItemColor:n,darkItemBg:"#001529",darkPopupBg:"#001529",darkSubMenuItemBg:"#000c17",darkItemSelectedColor:I,darkItemSelectedBg:t,darkDangerItemSelectedBg:n,darkItemHoverBg:"transparent",darkGroupTitleColor:B,darkItemHoverColor:I,darkDangerItemHoverColor:N,darkDangerItemSelectedColor:I,darkDangerItemActiveBg:n,itemWidth:P?`calc(100% + ${O}px)`:`calc(100% - ${_*2}px)`}},vue=(e,t=e,n=true)=>Wt("Menu",o=>{const{colorBgElevated:i,controlHeightLG:a,fontSize:l,darkItemColor:u,darkDangerItemColor:d,darkItemBg:m,darkSubMenuItemBg:p,darkItemSelectedColor:g,darkItemSelectedBg:b,darkDangerItemSelectedBg:y,darkItemHoverBg:S,darkGroupTitleColor:C,darkItemHoverColor:w,darkItemDisabledColor:$,darkDangerItemHoverColor:M,darkDangerItemSelectedColor:T,darkDangerItemActiveBg:R,popupBg:I,darkPopupBg:N}=o,P=o.calc(l).div(7).mul(5).equal(),O=Ft(o,{menuArrowSize:P,menuHorizontalHeight:o.calc(a).mul(1.15).equal(),menuArrowOffset:o.calc(P).mul(.25).equal(),menuSubMenuBg:i,calc:o.calc,popupBg:I}),_=Ft(O,{itemColor:u,itemHoverColor:w,groupTitleColor:C,itemSelectedColor:g,subMenuItemSelectedColor:g,itemBg:m,popupBg:N,subMenuItemBg:p,itemActiveBg:"transparent",itemSelectedBg:b,activeBarHeight:0,activeBarBorderWidth:0,itemHoverBg:S,itemDisabledColor:$,dangerItemColor:d,dangerItemHoverColor:M,dangerItemSelectedColor:T,dangerItemActiveBg:R,dangerItemSelectedBg:y,menuSubMenuBg:p,horizontalItemSelectedColor:g,horizontalItemSelectedBg:b});return [pue(O),fue(O),hue(O),KO(O,"light"),KO(_,"dark"),mue(O),Bk(O),Hl(O,"slide-up"),Hl(O,"slide-down"),Zp(O,"zoom-big")]},gue,{deprecatedTokens:[["colorGroupTitle","groupTitleColor"],["radiusItem","itemBorderRadius"],["radiusSubMenuItem","subMenuItemBorderRadius"],["colorItemText","itemColor"],["colorItemTextHover","itemHoverColor"],["colorItemTextHoverHorizontal","horizontalItemHoverColor"],["colorItemTextSelected","itemSelectedColor"],["colorItemTextSelectedHorizontal","horizontalItemSelectedColor"],["colorItemTextDisabled","itemDisabledColor"],["colorDangerItemText","dangerItemColor"],["colorDangerItemTextHover","dangerItemHoverColor"],["colorDangerItemTextSelected","dangerItemSelectedColor"],["colorDangerItemBgActive","dangerItemActiveBg"],["colorDangerItemBgSelected","dangerItemSelectedBg"],["colorItemBg","itemBg"],["colorItemBgHover","itemHoverBg"],["colorSubItemBg","subMenuItemBg"],["colorItemBgActive","itemActiveBg"],["colorItemBgSelectedHorizontal","horizontalItemSelectedBg"],["colorActiveBarWidth","activeBarWidth"],["colorActiveBarHeight","activeBarHeight"],["colorActiveBarBorderSize","activeBarBorderWidth"],["colorItemBgSelected","itemSelectedBg"]],injectStyle:n,unitless:{groupTitleLineHeight:true}})(e,t),h7=e=>{const{popupClassName:t,icon:n,title:r,theme:o}=e,i=f.useContext(K0),{prefixCls:a,inlineCollapsed:l,theme:u,classNames:d,styles:m}=i,p=_f();let g;if(!n)g=l&&!p.length&&r&&typeof r=="string"?f.createElement("div",{className:`${a}-inline-collapsed-noicon`},r.charAt(0)):f.createElement("span",{className:`${a}-title-content`},r);else {const S=f.isValidElement(r)&&r.type==="span";g=f.createElement(f.Fragment,null,Hr(n,C=>({className:X(C.className,`${a}-item-icon`,d?.itemIcon),style:{...C.style,...m?.itemIcon}})),S?r:f.createElement("span",{className:`${a}-title-content`},r));}const b=f.useMemo(()=>({...i,firstLevel:false}),[i]),[y]=wu("Menu");return f.createElement(K0.Provider,{value:b},f.createElement(f1,{...Ln(e,["icon"]),title:g,classNames:{list:d?.subMenu?.list,listTitle:d?.subMenu?.itemTitle},styles:{list:m?.subMenu?.list,listTitle:m?.subMenu?.itemTitle},popupClassName:X(a,t,d?.popup?.root,`${a}-${o||u}`),popupStyle:{zIndex:y,...e.popupStyle,...m?.popup?.root}}))};function tw(e){return e===null||e===false}const bue={item:m7,submenu:h7,divider:f7},yue=f.forwardRef((e,t)=>{const n=f.useContext(Y0),r=n||{},{prefixCls:o,className:i,style:a,theme:l="light",expandIcon:u,_internalDisableMenuItemTitleTooltip:d,tooltip:m,inlineCollapsed:p,siderCollapsed:g,rootClassName:b,mode:y,selectable:S,onClick:C,overflowedIndicatorPopupClassName:w,classNames:$,styles:M,...T}=e,{menu:R}=f.useContext(wt),{getPrefixCls:I,getPopupContainer:N,direction:P,className:O,style:_,classNames:B,styles:V}=jt("menu"),U=I(),G=Ln(T,["collapsedWidth"]);r.validator?.({mode:y});const H=Mt((...ne)=>{C?.(...ne),r.onClick?.();}),z=r.mode||y,j=S??r.selectable,W=p??g,Y={...e,mode:z,inlineCollapsed:W,selectable:j,theme:l},[Q,D]=Kt([B,$],[V,M],{props:Y},{popup:{_default:"root"},subMenu:{_default:"item"}}),L={horizontal:{motionName:`${U}-slide-up`},inline:Ek(U),other:{motionName:`${U}-zoom-big`}},K=I("menu",o||r.prefixCls),J=Qn(K),[ee,te]=vue(K,J,!n),re=X(`${K}-${l}`,O,i),ie=f.useMemo(()=>{if(typeof u=="function"||tw(u))return u||null;if(typeof r.expandIcon=="function"||tw(r.expandIcon))return r.expandIcon||null;if(typeof R?.expandIcon=="function"||tw(R?.expandIcon))return R?.expandIcon||null;const ne=u??r?.expandIcon??R?.expandIcon;return Hr(ne,{className:X(`${K}-submenu-expand-icon`,f.isValidElement(ne)?ne.props?.className:void 0)})},[u,r?.expandIcon,R?.expandIcon,K]),de=f.useMemo(()=>({prefixCls:K,inlineCollapsed:W||false,direction:P,firstLevel:true,theme:l,mode:z,disableMenuItemTitleTooltip:d,tooltip:m,classNames:Q,styles:D}),[K,W,P,d,l,z,Q,D,m]);return f.createElement(Y0.Provider,{value:null},f.createElement(K0.Provider,{value:de},f.createElement(Bf,{getPopupContainer:N,overflowedIndicator:f.createElement(UR,null),overflowedIndicatorPopupClassName:X(K,`${K}-${l}`,w),classNames:{list:Q.list,listTitle:Q.itemTitle},styles:{list:D.list,listTitle:D.itemTitle},mode:z,selectable:j,onClick:H,...G,inlineCollapsed:W,style:{...D.root,..._,...a},className:re,prefixCls:K,direction:P,defaultMotions:L,expandIcon:ie,ref:t,rootClassName:X(b,ee,r.rootClassName,te,J,Q.root),_internalComponents:bue})))}),ec=f.forwardRef((e,t)=>{const n=f.useRef(null),r=f.useContext(d7);return f.useImperativeHandle(t,()=>({menu:n.current,focus:o=>{n.current?.focus(o);}})),f.createElement(yue,{ref:n,...e,...r})});ec.Item=m7;ec.SubMenu=h7;ec.Divider=f7;ec.ItemGroup=jR;const Sue=e=>{const{componentCls:t,menuCls:n,colorError:r,colorTextLightSolid:o}=e,i=`${n}-item`;return {[`${t}, ${t}-menu-submenu`]:{[`${n} ${i}`]:{[`&${i}-danger:not(${i}-disabled)`]:{color:r,"&:hover":{color:o,backgroundColor:r}}}}}},Cue=e=>{const{componentCls:t,menuCls:n,zIndexPopup:r,dropdownArrowDistance:o,sizePopupArrow:i,antCls:a,iconCls:l,motionDurationMid:u,paddingBlock:d,fontSize:m,dropdownEdgeChildPadding:p,colorTextDisabled:g,fontSizeIcon:b,controlPaddingHorizontal:y,colorBgElevated:S}=e;return [{[t]:{position:"absolute",top:-9999,left:{_skip_check_:true,value:-9999},zIndex:r,display:"block","&::before":{position:"absolute",insetBlock:e.calc(i).div(2).sub(o).equal(),zIndex:-9999,opacity:1e-4,content:'""'},"&-menu-vertical":{maxHeight:"100vh",overflowY:"auto"},[`&-trigger${a}-btn`]:{[`& > ${l}-down, & > ${a}-btn-icon > ${l}-down`]:{fontSize:b}},[`${t}-wrap`]:{position:"relative",[`${a}-btn > ${l}-down`]:{fontSize:b},[`${l}-down::before`]:{transition:`transform ${u}`}},[`${t}-wrap-open`]:{[`${l}-down::before`]:{transform:"rotate(180deg)"}},"\n &-hidden,\n &-menu-hidden,\n &-menu-submenu-hidden\n ":{display:"none"},[`&${a}-slide-down-enter${a}-slide-down-enter-active${t}-placement-bottomLeft,
&${a}-slide-down-appear${a}-slide-down-appear-active${t}-placement-bottomLeft,
&${a}-slide-down-enter${a}-slide-down-enter-active${t}-placement-bottom,
&${a}-slide-down-appear${a}-slide-down-appear-active${t}-placement-bottom,
&${a}-slide-down-enter${a}-slide-down-enter-active${t}-placement-bottomRight,
&${a}-slide-down-appear${a}-slide-down-appear-active${t}-placement-bottomRight`]:{animationName:mR},[`&${a}-slide-up-enter${a}-slide-up-enter-active${t}-placement-topLeft,
&${a}-slide-up-appear${a}-slide-up-appear-active${t}-placement-topLeft,
&${a}-slide-up-enter${a}-slide-up-enter-active${t}-placement-top,
&${a}-slide-up-appear${a}-slide-up-appear-active${t}-placement-top,
&${a}-slide-up-enter${a}-slide-up-enter-active${t}-placement-topRight,
&${a}-slide-up-appear${a}-slide-up-appear-active${t}-placement-topRight`]:{animationName:pR},[`&${a}-slide-down-leave${a}-slide-down-leave-active${t}-placement-bottomLeft,
&${a}-slide-down-leave${a}-slide-down-leave-active${t}-placement-bottom,
&${a}-slide-down-leave${a}-slide-down-leave-active${t}-placement-bottomRight`]:{animationName:hR},[`&${a}-slide-up-leave${a}-slide-up-leave-active${t}-placement-topLeft,
&${a}-slide-up-leave${a}-slide-up-leave-active${t}-placement-top,
&${a}-slide-up-leave${a}-slide-up-leave-active${t}-placement-topRight`]:{animationName:gR}}},LR(e,S,{arrowPlacement:{top:true,bottom:true}}),{[`${t} ${n}`]:{position:"relative",margin:0},[`${n}-submenu-popup`]:{position:"absolute",zIndex:r,background:"transparent",boxShadow:"none",transformOrigin:"0 0","ul, li":{listStyle:"none",margin:0}},[`${t}, ${t}-menu-submenu`]:{...dn(e),[n]:{padding:p,listStyleType:"none",backgroundColor:S,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,...$i(e),"&:empty":{padding:0,boxShadow:"none"},[`${n}-item-group-title`]:{padding:`${oe(d)} ${oe(y)}`,color:e.colorTextDescription,transition:`all ${u}`},[`${n}-item`]:{position:"relative",display:"flex",alignItems:"center"},[`${n}-item-icon`]:{minWidth:m,marginInlineEnd:e.marginXS,fontSize:e.fontSizeSM},[`${n}-title-content`]:{flex:"auto","&-with-extra":{display:"inline-flex",alignItems:"center",width:"100%"},"> a":{color:"inherit",transition:`all ${u}`,"&:hover":{color:"inherit"},"&::after":{position:"absolute",inset:0,content:'""'}},[`${n}-item-extra`]:{paddingInlineStart:e.padding,marginInlineStart:"auto",fontSize:e.fontSizeSM,color:e.colorTextDescription}},[`${n}-item, ${n}-submenu-title`]:{display:"flex",margin:0,padding:`${oe(d)} ${oe(y)}`,color:e.colorText,fontWeight:"normal",fontSize:m,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${u}`,borderRadius:e.borderRadiusSM,"&:hover, &-active":{backgroundColor:e.controlItemBgHover},...$i(e),"&-selected":{color:e.colorPrimary,backgroundColor:e.controlItemBgActive,"&:hover, &-active":{backgroundColor:e.controlItemBgActiveHover}},"&-disabled":{color:g,cursor:"not-allowed","&:hover":{color:g,backgroundColor:S,cursor:"not-allowed"},a:{pointerEvents:"none"}},"&-divider":{height:1,margin:`${oe(e.marginXXS)} 0`,overflow:"hidden",lineHeight:0,backgroundColor:e.colorSplit},[`${t}-menu-submenu-expand-icon`]:{position:"absolute",insetInlineEnd:e.paddingXS,[`${t}-menu-submenu-arrow-icon`]:{marginInlineEnd:"0 !important",color:e.colorIcon,fontSize:b,fontStyle:"normal"}}},[`${n}-item-group-list`]:{margin:`0 ${oe(e.marginXS)}`,padding:0,listStyle:"none"},[`${n}-submenu-title`]:{paddingInlineEnd:e.calc(y).add(e.fontSizeSM).equal()},[`${n}-submenu-vertical`]:{position:"relative"},[`${n}-submenu${n}-submenu-disabled ${t}-menu-submenu-title`]:{[`&, ${t}-menu-submenu-arrow-icon`]:{color:g,backgroundColor:S,cursor:"not-allowed"}},[`${n}-submenu-selected ${t}-menu-submenu-title`]:{color:e.colorPrimary}}}},[Hl(e,"slide-up"),Hl(e,"slide-down"),z0(e,"move-up"),z0(e,"move-down"),Zp(e,"zoom-big")]]},xue=e=>({zIndexPopup:e.zIndexPopupBase+50,paddingBlock:(e.controlHeight-e.fontSize*e.lineHeight)/2,...s1({contentRadius:e.borderRadiusLG,limitVerticalRadius:true}),...BR(e)}),wue=Wt("Dropdown",e=>{const{marginXXS:t,sizePopupArrow:n,paddingXXS:r,componentCls:o}=e,i=Ft(e,{menuCls:`${o}-menu`,dropdownArrowDistance:e.calc(n).div(2).add(t).equal(),dropdownEdgeChildPadding:r});return [Cue(i),Sue(i)]},xue,{resetStyle:false}),m1=e=>{const{menu:t,arrow:n,prefixCls:r,children:o,trigger:i,disabled:a,dropdownRender:l,popupRender:u,getPopupContainer:d,overlayClassName:m,rootClassName:p,overlayStyle:g,open:b,onOpenChange:y,mouseEnterDelay:S=.15,mouseLeaveDelay:C=.1,autoAdjustOverflow:w=true,placement:$="",transitionName:M,classNames:T,styles:R,destroyPopupOnHide:I,destroyOnHidden:N}=e,{getPrefixCls:P,direction:O,getPopupContainer:_,className:B,style:V,classNames:U,styles:G}=jt("dropdown"),H={...e,mouseEnterDelay:S,mouseLeaveDelay:C,autoAdjustOverflow:w},[z,j]=Kt([U,T],[G,R],{props:H}),W={...V,...g,...j.root},Y=u||l,Q=f.useMemo(()=>{const Ne=P();return M!==void 0?M:$.includes("top")?`${Ne}-slide-down`:`${Ne}-slide-up`},[P,$,M]),D=f.useMemo(()=>$?$.includes("Center")?$.slice(0,$.indexOf("Center")):$:O==="rtl"?"bottomRight":"bottomLeft",[$,O]),L=P("dropdown",r),K=Qn(L),[J,ee]=wue(L,K),[,te]=jr(),re=f.Children.only(Hce(o)?f.createElement("span",null,o):o),ie=Hr(re,{className:X(`${L}-trigger`,{[`${L}-rtl`]:O==="rtl"},re.props.className),disabled:re.props.disabled??a}),de=a?[]:i,ne=!!de?.includes("contextMenu"),[ce,fe]=un(false,b),se=Mt(Ne=>{y?.(Ne,{source:"trigger"}),fe(Ne);}),Me=X(m,p,J,ee,K,B,z.root,{[`${L}-rtl`]:O==="rtl"}),ae=UF({arrowPointAtCenter:typeof n=="object"&&n.pointAtCenter,autoAdjustOverflow:w,offset:te.marginXXS,arrowWidth:n?te.sizePopupArrow:0,borderRadius:te.borderRadius}),pe=Mt(()=>{t?.selectable&&t?.multiple||(y?.(false,{source:"menu"}),fe(false));}),Ce=()=>{const Ne=Ln(z,["root"]),ue=Ln(j,["root"]);let ge;return t?.items&&(ge=f.createElement(ec,{...t,classNames:{...Ne,subMenu:{...Ne}},styles:{...ue,subMenu:{...ue}}})),Y&&(ge=Y(ge)),ge=f.Children.only(typeof ge=="string"?f.createElement("span",null,ge):ge),f.createElement(due,{prefixCls:`${L}-menu`,rootClassName:X(ee,K),expandIcon:f.createElement("span",{className:`${L}-menu-submenu-arrow`},O==="rtl"?f.createElement(fp,{className:`${L}-menu-submenu-arrow-icon`}):f.createElement(cf,{className:`${L}-menu-submenu-arrow-icon`})),mode:"vertical",selectable:false,onClick:pe,validator:({mode:Pe})=>{}},ge)},[xe,Ae]=wu("Dropdown",W.zIndex);let Xe=f.createElement(ZF,{alignPoint:ne,...Ln(e,["rootClassName","onOpenChange"]),mouseEnterDelay:S,mouseLeaveDelay:C,visible:ce,builtinPlacements:ae,arrow:!!n,overlayClassName:Me,prefixCls:L,getPopupContainer:d||_,transitionName:Q,trigger:de,overlay:Ce,placement:D,onVisibleChange:se,overlayStyle:{...W,zIndex:xe},autoDestroy:N??I},ie);return xe&&(Xe=f.createElement(Qy.Provider,{value:Ae},Xe)),Xe},$ue=RR(m1,"align",void 0,"dropdown",e=>e),Eue=e=>f.createElement($ue,{...e},f.createElement("span",null));m1._InternalPanelDoNotUseOrYouWillBeFired=Eue;var Kb={exports:{}},Mue=Kb.exports,ZO;function Rue(){return ZO||(ZO=1,(function(e,t){(function(n,r){e.exports=r();})(Mue,(function(){var n=1e3,r=6e4,o=36e5,i="millisecond",a="second",l="minute",u="hour",d="day",m="week",p="month",g="quarter",b="year",y="date",S="Invalid Date",C=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,w=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,$={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(G){var H=["th","st","nd","rd"],z=G%100;return "["+G+(H[(z-20)%10]||H[z]||H[0])+"]"}},M=function(G,H,z){var j=String(G);return !j||j.length>=H?G:""+Array(H+1-j.length).join(z)+G},T={s:M,z:function(G){var H=-G.utcOffset(),z=Math.abs(H),j=Math.floor(z/60),W=z%60;return (H<=0?"+":"-")+M(j,2,"0")+":"+M(W,2,"0")},m:function G(H,z){if(H.date()<z.date())return -G(z,H);var j=12*(z.year()-H.year())+(z.month()-H.month()),W=H.clone().add(j,p),Y=z-W<0,Q=H.clone().add(j+(Y?-1:1),p);return +(-(j+(z-W)/(Y?W-Q:Q-W))||0)},a:function(G){return G<0?Math.ceil(G)||0:Math.floor(G)},p:function(G){return {M:p,y:b,w:m,d,D:y,h:u,m:l,s:a,ms:i,Q:g}[G]||String(G||"").toLowerCase().replace(/s$/,"")},u:function(G){return G===void 0}},R="en",I={};I[R]=$;var N="$isDayjsObject",P=function(G){return G instanceof V||!(!G||!G[N])},O=function G(H,z,j){var W;if(!H)return R;if(typeof H=="string"){var Y=H.toLowerCase();I[Y]&&(W=Y),z&&(I[Y]=z,W=Y);var Q=H.split("-");if(!W&&Q.length>1)return G(Q[0])}else {var D=H.name;I[D]=H,W=D;}return !j&&W&&(R=W),W||!j&&R},_=function(G,H){if(P(G))return G.clone();var z=typeof H=="object"?H:{};return z.date=G,z.args=arguments,new V(z)},B=T;B.l=O,B.i=P,B.w=function(G,H){return _(G,{locale:H.$L,utc:H.$u,x:H.$x,$offset:H.$offset})};var V=(function(){function G(z){this.$L=O(z.locale,null,true),this.parse(z),this.$x=this.$x||z.x||{},this[N]=true;}var H=G.prototype;return H.parse=function(z){this.$d=(function(j){var W=j.date,Y=j.utc;if(W===null)return new Date(NaN);if(B.u(W))return new Date;if(W instanceof Date)return new Date(W);if(typeof W=="string"&&!/Z$/i.test(W)){var Q=W.match(C);if(Q){var D=Q[2]-1||0,L=(Q[7]||"0").substring(0,3);return Y?new Date(Date.UTC(Q[1],D,Q[3]||1,Q[4]||0,Q[5]||0,Q[6]||0,L)):new Date(Q[1],D,Q[3]||1,Q[4]||0,Q[5]||0,Q[6]||0,L)}}return new Date(W)})(z),this.init();},H.init=function(){var z=this.$d;this.$y=z.getFullYear(),this.$M=z.getMonth(),this.$D=z.getDate(),this.$W=z.getDay(),this.$H=z.getHours(),this.$m=z.getMinutes(),this.$s=z.getSeconds(),this.$ms=z.getMilliseconds();},H.$utils=function(){return B},H.isValid=function(){return this.$d.toString()!==S},H.isSame=function(z,j){var W=_(z);return this.startOf(j)<=W&&W<=this.endOf(j)},H.isAfter=function(z,j){return _(z)<this.startOf(j)},H.isBefore=function(z,j){return this.endOf(j)<_(z)},H.$g=function(z,j,W){return B.u(z)?this[j]:this.set(W,z)},H.unix=function(){return Math.floor(this.valueOf()/1e3)},H.valueOf=function(){return this.$d.getTime()},H.startOf=function(z,j){var W=this,Y=!!B.u(j)||j,Q=B.p(z),D=function(de,ne){var ce=B.w(W.$u?Date.UTC(W.$y,ne,de):new Date(W.$y,ne,de),W);return Y?ce:ce.endOf(d)},L=function(de,ne){return B.w(W.toDate()[de].apply(W.toDate("s"),(Y?[0,0,0,0]:[23,59,59,999]).slice(ne)),W)},K=this.$W,J=this.$M,ee=this.$D,te="set"+(this.$u?"UTC":"");switch(Q){case b:return Y?D(1,0):D(31,11);case p:return Y?D(1,J):D(0,J+1);case m:var re=this.$locale().weekStart||0,ie=(K<re?K+7:K)-re;return D(Y?ee-ie:ee+(6-ie),J);case d:case y:return L(te+"Hours",0);case u:return L(te+"Minutes",1);case l:return L(te+"Seconds",2);case a:return L(te+"Milliseconds",3);default:return this.clone()}},H.endOf=function(z){return this.startOf(z,false)},H.$set=function(z,j){var W,Y=B.p(z),Q="set"+(this.$u?"UTC":""),D=(W={},W[d]=Q+"Date",W[y]=Q+"Date",W[p]=Q+"Month",W[b]=Q+"FullYear",W[u]=Q+"Hours",W[l]=Q+"Minutes",W[a]=Q+"Seconds",W[i]=Q+"Milliseconds",W)[Y],L=Y===d?this.$D+(j-this.$W):j;if(Y===p||Y===b){var K=this.clone().set(y,1);K.$d[D](L),K.init(),this.$d=K.set(y,Math.min(this.$D,K.daysInMonth())).$d;}else D&&this.$d[D](L);return this.init(),this},H.set=function(z,j){return this.clone().$set(z,j)},H.get=function(z){return this[B.p(z)]()},H.add=function(z,j){var W,Y=this;z=Number(z);var Q=B.p(j),D=function(J){var ee=_(Y);return B.w(ee.date(ee.date()+Math.round(J*z)),Y)};if(Q===p)return this.set(p,this.$M+z);if(Q===b)return this.set(b,this.$y+z);if(Q===d)return D(1);if(Q===m)return D(7);var L=(W={},W[l]=r,W[u]=o,W[a]=n,W)[Q]||1,K=this.$d.getTime()+z*L;return B.w(K,this)},H.subtract=function(z,j){return this.add(-1*z,j)},H.format=function(z){var j=this,W=this.$locale();if(!this.isValid())return W.invalidDate||S;var Y=z||"YYYY-MM-DDTHH:mm:ssZ",Q=B.z(this),D=this.$H,L=this.$m,K=this.$M,J=W.weekdays,ee=W.months,te=W.meridiem,re=function(ne,ce,fe,se){return ne&&(ne[ce]||ne(j,Y))||fe[ce].slice(0,se)},ie=function(ne){return B.s(D%12||12,ne,"0")},de=te||function(ne,ce,fe){var se=ne<12?"AM":"PM";return fe?se.toLowerCase():se};return Y.replace(w,(function(ne,ce){return ce||(function(fe){switch(fe){case "YY":return String(j.$y).slice(-2);case "YYYY":return B.s(j.$y,4,"0");case "M":return K+1;case "MM":return B.s(K+1,2,"0");case "MMM":return re(W.monthsShort,K,ee,3);case "MMMM":return re(ee,K);case "D":return j.$D;case "DD":return B.s(j.$D,2,"0");case "d":return String(j.$W);case "dd":return re(W.weekdaysMin,j.$W,J,2);case "ddd":return re(W.weekdaysShort,j.$W,J,3);case "dddd":return J[j.$W];case "H":return String(D);case "HH":return B.s(D,2,"0");case "h":return ie(1);case "hh":return ie(2);case "a":return de(D,L,true);case "A":return de(D,L,false);case "m":return String(L);case "mm":return B.s(L,2,"0");case "s":return String(j.$s);case "ss":return B.s(j.$s,2,"0");case "SSS":return B.s(j.$ms,3,"0");case "Z":return Q}return null})(ne)||Q.replace(":","")}))},H.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},H.diff=function(z,j,W){var Y,Q=this,D=B.p(j),L=_(z),K=(L.utcOffset()-this.utcOffset())*r,J=this-L,ee=function(){return B.m(Q,L)};switch(D){case b:Y=ee()/12;break;case p:Y=ee();break;case g:Y=ee()/3;break;case m:Y=(J-K)/6048e5;break;case d:Y=(J-K)/864e5;break;case u:Y=J/o;break;case l:Y=J/r;break;case a:Y=J/n;break;default:Y=J;}return W?Y:B.a(Y)},H.daysInMonth=function(){return this.endOf(p).$D},H.$locale=function(){return I[this.$L]},H.locale=function(z,j){if(!z)return this.$L;var W=this.clone(),Y=O(z,j,true);return Y&&(W.$L=Y),W},H.clone=function(){return B.w(this.$d,this)},H.toDate=function(){return new Date(this.valueOf())},H.toJSON=function(){return this.isValid()?this.toISOString():null},H.toISOString=function(){return this.$d.toISOString()},H.toString=function(){return this.$d.toUTCString()},G})(),U=V.prototype;return _.prototype=U,[["$ms",i],["$s",a],["$m",l],["$H",u],["$W",d],["$M",p],["$y",b],["$D",y]].forEach((function(G){U[G[1]]=function(H){return this.$g(H,G[0],G[1])};})),_.extend=function(G,H){return G.$i||(G(H,V,_),G.$i=true),_},_.locale=O,_.isDayjs=P,_.unix=function(G){return _(1e3*G)},_.en=I[R],_.Ls=I,_.p={},_}));})(Kb)),Kb.exports}var Tue=Rue();const Yn=Io(Tue);function Aue(e){return e===void 0||e===false?[]:Array.isArray(e)?e:[e]}function Nue(e){return Aue(e).join("_")}const p7=f.createContext(void 0),Pue=p7.Provider,g7=f.createContext(void 0),Iue=g7.Provider;function zE(){return zE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},zE.apply(this,arguments)}const v7=f.forwardRef((e,t)=>{const{prefixCls:n="rc-checkbox",className:r,style:o,checked:i,disabled:a,defaultChecked:l=false,type:u="checkbox",title:d,onChange:m,...p}=e,g=f.useRef(null),b=f.useRef(null),[y,S]=un(l,i);f.useImperativeHandle(t,()=>({focus:$=>{g.current?.focus($);},blur:()=>{g.current?.blur();},input:g.current,nativeElement:b.current}));const C=X(n,r,{[`${n}-checked`]:y,[`${n}-disabled`]:a}),w=$=>{a||("checked"in e||S($.target.checked),m?.({target:{...e,type:u,checked:$.target.checked},stopPropagation(){$.stopPropagation();},preventDefault(){$.preventDefault();},nativeEvent:$.nativeEvent}));};return f.createElement("span",{className:C,title:d,style:o,ref:b},f.createElement("input",zE({},p,{className:`${n}-input`,ref:g,onChange:w,disabled:a,checked:!!y,type:u})))});function b7(e){const t=q.useRef(null),n=()=>{Lt.cancel(t.current),t.current=null;};return [()=>{n(),t.current=Lt(()=>{t.current=null;});},i=>{t.current&&(i.stopPropagation(),n()),e?.(i);}]}const Oue=e=>{const{componentCls:t,antCls:n}=e,r=`${t}-group`;return {[r]:{...dn(e),display:"inline-block",fontSize:0,[`&${r}-rtl`]:{direction:"rtl"},[`&${r}-block`]:{display:"flex"},[`${n}-badge ${n}-badge-count`]:{zIndex:1},[`> ${n}-badge:not(:first-child) > ${n}-button-wrapper`]:{borderInlineStart:"none"},"&-vertical":{display:"flex",flexDirection:"column",rowGap:e.marginXS,[`${t}-wrapper`]:{marginInlineEnd:0}}}}},Due=e=>{const{componentCls:t,wrapperMarginInlineEnd:n,colorPrimary:r,colorPrimaryHover:o,radioSize:i,motionDurationSlow:a,motionDurationMid:l,motionEaseInOutCirc:u,colorBgContainer:d,colorBorder:m,lineWidth:p,colorBgContainerDisabled:g,colorTextDisabled:b,paddingXS:y,dotColorDisabled:S,dotSize:C,lineType:w,radioColor:$,radioBgColor:M}=e;return {[`${t}-wrapper`]:{...dn(e),display:"inline-flex",alignItems:"baseline",marginInlineStart:0,marginInlineEnd:n,cursor:"pointer","&:last-child":{marginInlineEnd:0},[`&${t}-wrapper-rtl`]:{direction:"rtl"},"&-disabled":{cursor:"not-allowed",color:e.colorTextDisabled},"&::after":{display:"inline-block",width:0,overflow:"hidden",content:'"\\a0"'},"&-block":{flex:1,justifyContent:"center"},[t]:{...dn(e),position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",boxSizing:"border-box",display:"block",width:`calc(${i} * 1px)`,height:`calc(${i} * 1px)`,backgroundColor:d,border:`${oe(p)} ${w} ${m}`,borderRadius:"50%",transition:`all ${l}`,"&:after":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%) scale(0)",width:`calc(${C} * 1px)`,height:`calc(${C} * 1px)`,backgroundColor:$,borderRadius:"50%",transformOrigin:"50% 50%",opacity:0,transition:`all ${a} ${u}`},[`${t}-input`]:{position:"absolute",inset:0,zIndex:1,cursor:"pointer",opacity:0,margin:0},[`&:has(${t}-input:focus-visible)`]:ba(e)},[`&:hover ${t}`]:{borderColor:r},[`&:hover ${t}-checked:not(${t}-disabled)`]:{backgroundColor:o,borderColor:"transparent"},[`${t}-checked`]:{backgroundColor:M,borderColor:r,"&::after":{transform:"translate(-50%, -50%)",opacity:1}},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},background:g,borderColor:m,"&::after":{backgroundColor:S}},[`${t}-disabled + span`]:{color:b,cursor:"not-allowed"},[`span${t} + *`]:{paddingInlineStart:y,paddingInlineEnd:y}}}},_ue=e=>{const{buttonColor:t,controlHeight:n,componentCls:r,lineWidth:o,lineType:i,colorBorder:a,motionDurationMid:l,buttonPaddingInline:u,fontSize:d,buttonBg:m,fontSizeLG:p,controlHeightLG:g,controlHeightSM:b,paddingXS:y,borderRadius:S,borderRadiusSM:C,borderRadiusLG:w,buttonCheckedBg:$,buttonSolidCheckedColor:M,colorTextDisabled:T,colorBgContainerDisabled:R,buttonCheckedBgDisabled:I,buttonCheckedColorDisabled:N,colorPrimary:P,colorPrimaryHover:O,colorPrimaryActive:_,buttonSolidCheckedBg:B,buttonSolidCheckedHoverBg:V,buttonSolidCheckedActiveBg:U,calc:G}=e;return {[`${r}-button-wrapper`]:{position:"relative",display:"inline-block",height:n,margin:0,paddingInline:u,paddingBlock:0,color:t,fontSize:d,lineHeight:oe(G(n).sub(G(o).mul(2)).equal()),background:m,border:`${oe(o)} ${i} ${a}`,borderBlockStartWidth:G(o).add(.02).equal(),borderInlineEndWidth:o,cursor:"pointer",transition:["color","background-color","box-shadow"].map(H=>`${H} ${l}`).join(","),a:{color:t},[`> ${r}-button`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:-1,width:"100%",height:"100%"},"&:not(:last-child)":{marginInlineEnd:G(o).mul(-1).equal()},"&:first-child":{borderInlineStart:`${oe(o)} ${i} ${a}`,borderStartStartRadius:S,borderEndStartRadius:S},"&:last-child":{borderStartEndRadius:S,borderEndEndRadius:S},"&:first-child:last-child":{borderRadius:S},[`${r}-group-large &`]:{height:g,fontSize:p,lineHeight:oe(G(g).sub(G(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:w,borderEndStartRadius:w},"&:last-child":{borderStartEndRadius:w,borderEndEndRadius:w}},[`${r}-group-small &`]:{height:b,paddingInline:G(y).sub(o).equal(),paddingBlock:0,lineHeight:oe(G(b).sub(G(o).mul(2)).equal()),"&:first-child":{borderStartStartRadius:C,borderEndStartRadius:C},"&:last-child":{borderStartEndRadius:C,borderEndEndRadius:C}},"&:hover":{position:"relative",color:P},"&:has(:focus-visible)":ba(e),[`${r}, input[type='checkbox'], input[type='radio']`]:{width:0,height:0,opacity:0,pointerEvents:"none"},[`&-checked:not(${r}-button-wrapper-disabled)`]:{zIndex:1,color:P,background:$,borderColor:P,"&::before":{backgroundColor:P},"&:first-child":{borderColor:P},"&:hover":{color:O,borderColor:O,"&::before":{backgroundColor:O}},"&:active":{color:_,borderColor:_,"&::before":{backgroundColor:_}}},[`${r}-group-solid &-checked:not(${r}-button-wrapper-disabled)`]:{color:M,background:B,borderColor:B,"&:hover":{color:M,background:V,borderColor:V},"&:active":{color:M,background:U,borderColor:U}},"&-disabled":{color:T,backgroundColor:R,borderColor:a,cursor:"not-allowed","&:first-child, &:hover":{color:T,backgroundColor:R,borderColor:a}},[`&-disabled${r}-button-wrapper-checked`]:{color:N,backgroundColor:I,borderColor:a,boxShadow:"none"},"&-block":{flex:1,textAlign:"center"}}}},Bue=e=>{const{wireframe:t,padding:n,marginXS:r,lineWidth:o,fontSizeLG:i,colorText:a,colorBgContainer:l,colorTextDisabled:u,controlItemBgActiveDisabled:d,colorTextLightSolid:m,colorPrimary:p,colorPrimaryHover:g,colorPrimaryActive:b,colorWhite:y}=e,S=4,C=i,w=t?C-S*2:C-(S+o)*2;return {radioSize:C,dotSize:w,dotColorDisabled:u,buttonSolidCheckedColor:m,buttonSolidCheckedBg:p,buttonSolidCheckedHoverBg:g,buttonSolidCheckedActiveBg:b,buttonBg:l,buttonCheckedBg:l,buttonColor:a,buttonCheckedBgDisabled:d,buttonCheckedColorDisabled:u,buttonPaddingInline:n-o,wrapperMarginInlineEnd:r,radioColor:t?p:y,radioBgColor:t?l:p}},y7=Wt("Radio",e=>{const{controlOutline:t,controlOutlineWidth:n}=e,r=`0 0 0 ${oe(n)} ${t}`,i=Ft(e,{radioFocusShadow:r,radioButtonFocusShadow:r});return [Oue(i),Due(i),_ue(i)]},Bue,{unitless:{radioSize:true,dotSize:true}}),Lue=(e,t)=>{const n=f.useContext(p7),r=f.useContext(g7),{getPrefixCls:o,direction:i,className:a,style:l,classNames:u,styles:d}=jt("radio"),m=f.useRef(null),p=Vr(t,m),{isFormItemInput:g}=f.useContext(So),b=L=>{e.onChange?.(L),n?.onChange?.(L);},{prefixCls:y,className:S,rootClassName:C,children:w,style:$,title:M,classNames:T,styles:R,...I}=e,N=o("radio",y),P=(n?.optionType||r)==="button",O=P?`${N}-button`:N,_=Qn(N),[B,V]=y7(N,_),U={...I},G=f.useContext(no);let H=U.checked;n&&(U.name=n.name,U.onChange=b,H=e.value===n.value,U.disabled=U.disabled??n.disabled),U.disabled=U.disabled??G;const z={...e,...U,checked:H},[j,W]=Kt([u,T],[d,R],{props:z}),Y=X(`${O}-wrapper`,{[`${O}-wrapper-checked`]:H,[`${O}-wrapper-disabled`]:U.disabled,[`${O}-wrapper-rtl`]:i==="rtl",[`${O}-wrapper-in-form-item`]:g,[`${O}-wrapper-block`]:!!n?.block},a,S,C,j.root,B,V,_),[Q,D]=b7(U.onClick);return f.createElement(Qp,{component:"Radio",disabled:U.disabled},f.createElement("label",{className:Y,style:{...W.root,...l,...$},onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,title:M,onClick:Q},f.createElement(v7,{...U,checked:H,className:X(j.icon,{[n1]:!P}),style:W.icon,type:"radio",prefixCls:O,ref:p,onClick:D}),w!==void 0?f.createElement("span",{className:X(`${O}-label`,j.label),style:W.label},w):null))},X0=f.forwardRef(Lue),zue=f.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r}=f.useContext(wt),{name:o}=f.useContext(So),i=zs(Nue(o)),{prefixCls:a,className:l,rootClassName:u,options:d,buttonStyle:m="outline",disabled:p,children:g,size:b,style:y,id:S,optionType:C,name:w=i,defaultValue:$,value:M,block:T=false,onChange:R,onMouseEnter:I,onMouseLeave:N,onFocus:P,onBlur:O,orientation:_,vertical:B,role:V="radiogroup"}=e,[U,G]=un($,M),H=f.useCallback(te=>{const re=U,ie=te.target.value;"value"in e||G(ie),ie!==re&&R?.(te);},[U,G,R]),z=n("radio",a),j=`${z}-group`,W=Qn(z),[Y,Q]=y7(z,W);let D=g;d&&d.length>0&&(D=d.map(te=>typeof te=="string"||typeof te=="number"?f.createElement(X0,{key:te.toString(),prefixCls:z,disabled:p,value:te,checked:U===te},te):f.createElement(X0,{key:`radio-group-value-options-${te.value}`,prefixCls:z,disabled:te.disabled||p,value:te.value,checked:U===te.value,title:te.title,style:te.style,className:te.className,id:te.id,required:te.required},te.label)));const L=so(b),[,K]=xu(_,B),J=X(j,`${j}-${m}`,{[`${j}-${L}`]:L,[`${j}-rtl`]:r==="rtl",[`${j}-block`]:T},l,u,Y,Q,W),ee=f.useMemo(()=>({onChange:H,value:U,disabled:p,name:w,optionType:C,block:T}),[H,U,p,w,C,T]);return f.createElement("div",{...yo(e,{aria:true,data:true}),role:V,className:X(J,{[`${z}-group-vertical`]:K}),style:y,onMouseEnter:I,onMouseLeave:N,onFocus:P,onBlur:O,id:S,ref:t},f.createElement(Pue,{value:ee},D))}),kue=f.memo(zue),Fue=(e,t)=>{const{getPrefixCls:n}=f.useContext(wt),{prefixCls:r,...o}=e,i=n("radio",r);return f.createElement(Iue,{value:"button"},f.createElement(X0,{prefixCls:i,...o,type:"radio",ref:t}))},Hue=f.forwardRef(Fue),to=X0;to.Button=Hue;to.Group=kue;to.__ANT_RADIO=true;function Lf(e){return Ft(e,{inputAffixPadding:e.paddingXXS})}const zf=e=>{const{controlHeight:t,fontSize:n,lineHeight:r,lineWidth:o,controlHeightSM:i,controlHeightLG:a,fontSizeLG:l,lineHeightLG:u,paddingSM:d,controlPaddingHorizontalSM:m,controlPaddingHorizontal:p,colorFillAlter:g,colorPrimaryHover:b,colorPrimary:y,controlOutlineWidth:S,controlOutline:C,colorErrorOutline:w,colorWarningOutline:$,colorBgContainer:M,inputFontSize:T,inputFontSizeLG:R,inputFontSizeSM:I}=e,N=T||n,P=I||N,O=R||l,_=Math.round((t-N*r)/2*10)/10-o,B=Math.round((i-P*r)/2*10)/10-o,V=Math.ceil((a-O*u)/2*10)/10-o;return {paddingBlock:Math.max(_,0),paddingBlockSM:Math.max(B,0),paddingBlockLG:Math.max(V,0),paddingInline:d-o,paddingInlineSM:m-o,paddingInlineLG:p-o,addonBg:g,activeBorderColor:y,hoverBorderColor:b,activeShadow:`0 0 0 ${S}px ${C}`,errorActiveShadow:`0 0 0 ${S}px ${w}`,warningActiveShadow:`0 0 0 ${S}px ${$}`,hoverBg:M,activeBg:M,inputFontSize:N,inputFontSizeLG:O,inputFontSizeSM:P}},Vue=e=>({borderColor:e.hoverBorderColor,backgroundColor:e.hoverBg}),h1=e=>({color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,boxShadow:"none",cursor:"not-allowed",opacity:1,"input[disabled], textarea[disabled]":{cursor:"not-allowed"},"&:hover:not([disabled])":{...Vue(Ft(e,{hoverBorderColor:e.colorBorder,hoverBg:e.colorBgContainerDisabled}))}}),WR=(e,t)=>({background:e.colorBgContainer,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:t.borderColor,"&:hover":{borderColor:t.hoverBorderColor,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:t.activeBorderColor,boxShadow:t.activeShadow,outline:0,backgroundColor:e.activeBg}}),JO=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...WR(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}},[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:t.borderColor}}),S7=(e,t)=>({"&-outlined":{...WR(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow}),[`&${e.componentCls}-disabled, &[disabled]`]:{...h1(e)},...JO(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError}),...JO(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning}),...t}}),e8=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{borderColor:t.addonBorderColor,color:t.addonColor}}}),jue=e=>({"&-outlined":{[`${e.componentCls}-group`]:{"&-addon":{background:e.addonBg,border:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}},...e8(e,{status:"error",addonBorderColor:e.colorError,addonColor:e.colorErrorText}),...e8(e,{status:"warning",addonBorderColor:e.colorWarning,addonColor:e.colorWarningText}),[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group-addon`]:{...h1(e)}}}}),C7=(e,t)=>{const{componentCls:n}=e;return {"&-borderless":{background:"transparent",border:"none","&:focus, &:focus-within":{outline:"none"},[`&${n}-disabled, &[disabled]`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${n}-status-error`]:{"&, & input, & textarea":{color:e.colorError}},[`&${n}-status-warning`]:{"&, & input, & textarea":{color:e.colorWarning}},...t}}},x7=(e,t)=>({background:t.bg,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:"transparent","input&, & input, textarea&, & textarea":{color:t?.inputColor??"unset"},"&:hover":{background:t.hoverBg},"&:focus, &:focus-within":{outline:0,borderColor:t.activeBorderColor,backgroundColor:e.activeBg}}),t8=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...x7(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}}}),w7=(e,t)=>({"&-filled":{...x7(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.activeBorderColor,inputColor:e.colorText}),[`&${e.componentCls}-disabled, &[disabled]`]:{...h1(e)},...t8(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,inputColor:e.colorErrorText,affixColor:e.colorError}),...t8(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,inputColor:e.colorWarningText,affixColor:e.colorWarning}),...t}}),n8=(e,t)=>({[`&${e.componentCls}-group-wrapper-status-${t.status}`]:{[`${e.componentCls}-group-addon`]:{background:t.addonBg,color:t.addonColor}}}),Uue=e=>({"&-filled":{[`${e.componentCls}-group-addon`]:{background:e.colorFillTertiary,"&:last-child":{position:"static"}},...n8(e,{status:"error",addonBg:e.colorErrorBg,addonColor:e.colorErrorText}),...n8(e,{status:"warning",addonBg:e.colorWarningBg,addonColor:e.colorWarningText}),[`&${e.componentCls}-group-wrapper-disabled`]:{[`${e.componentCls}-group`]:{"&-addon":{background:e.colorFillTertiary,color:e.colorTextDisabled},"&-addon:first-child":{borderInlineStart:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},"&-addon:last-child":{borderInlineEnd:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderTop:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderBottom:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`}}}}}),$7=(e,t)=>({background:e.colorBgContainer,borderWidth:`${oe(e.lineWidth)} 0`,borderStyle:`${e.lineType} none`,borderColor:`transparent transparent ${t.borderColor} transparent`,borderRadius:0,"&:hover":{borderColor:`transparent transparent ${t.hoverBorderColor} transparent`,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:`transparent transparent ${t.activeBorderColor} transparent`,outline:0,backgroundColor:e.activeBg}}),r8=(e,t)=>({[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]:{...$7(e,t),[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]:{color:t.affixColor}},[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]:{borderColor:`transparent transparent ${t.borderColor} transparent`}}),E7=(e,t)=>({"&-underlined":{...$7(e,{borderColor:e.colorBorder,hoverBorderColor:e.hoverBorderColor,activeBorderColor:e.activeBorderColor,activeShadow:e.activeShadow}),[`&${e.componentCls}-disabled, &[disabled]`]:{color:e.colorTextDisabled,boxShadow:"none",cursor:"not-allowed","&:hover":{borderColor:`transparent transparent ${e.colorBorder} transparent`}},"input[disabled], textarea[disabled]":{cursor:"not-allowed"},...r8(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError}),...r8(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning}),...t}}),M7=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),GR=e=>{const{paddingBlockLG:t,lineHeightLG:n,borderRadiusLG:r,paddingInlineLG:o}=e;return {padding:`${oe(t)} ${oe(o)}`,fontSize:e.inputFontSizeLG,lineHeight:n,borderRadius:r}},qR=e=>({padding:`${oe(e.paddingBlockSM)} ${oe(e.paddingInlineSM)}`,fontSize:e.inputFontSizeSM,borderRadius:e.borderRadiusSM}),p1=(e,t={})=>({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:`${oe(e.paddingBlock)} ${oe(e.paddingInline)}`,color:e.colorText,fontSize:e.inputFontSize,lineHeight:e.lineHeight,borderRadius:e.borderRadius,transition:`all ${e.motionDurationMid}`,...M7(e.colorTextPlaceholder),"&-lg":{...GR(e),...t.largeStyle},"&-sm":{...qR(e),...t.smallStyle},"&-rtl, &-textarea-rtl":{direction:"rtl"}}),Wue=e=>{const{componentCls:t,antCls:n}=e;return {position:"relative",display:"table",width:"100%",borderCollapse:"separate",borderSpacing:0,"&[class*='col-']":{paddingInlineEnd:e.paddingXS,"&:last-child":{paddingInlineEnd:0}},[`&-lg ${t}, &-lg > ${t}-group-addon`]:{...GR(e)},[`&-sm ${t}, &-sm > ${t}-group-addon`]:{...qR(e)},[`&-lg ${n}-select-single`]:{height:e.controlHeightLG},[`&-sm ${n}-select-single`]:{height:e.controlHeightSM},[`> ${t}`]:{display:"table-cell","&:not(:first-child):not(:last-child)":{borderRadius:0}},[`${t}-group`]:{"&-addon, &-wrap":{display:"table-cell",width:1,whiteSpace:"nowrap",verticalAlign:"middle","&:not(:first-child):not(:last-child)":{borderRadius:0}},"&-wrap > *":{display:"block !important"},"&-addon":{position:"relative",padding:`0 ${oe(e.paddingInline)}`,color:e.colorText,fontWeight:"normal",fontSize:e.inputFontSize,textAlign:"center",borderRadius:e.borderRadius,transition:`all ${e.motionDurationSlow}`,lineHeight:1,[`${n}-select`]:{margin:`${oe(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${oe(e.calc(e.paddingInline).mul(-1).equal())}`,[`&${n}-select-single:not(${n}-select-customize-input):not(${n}-pagination-size-changer)`]:{backgroundColor:"inherit",border:`${oe(e.lineWidth)} ${e.lineType} transparent`,boxShadow:"none"}},[`${n}-cascader-picker`]:{margin:`-9px ${oe(e.calc(e.paddingInline).mul(-1).equal())}`,backgroundColor:"transparent",[`${n}-cascader-input`]:{textAlign:"start",border:0,boxShadow:"none"}}}},[t]:{width:"100%",marginBottom:0,textAlign:"inherit","&:focus":{zIndex:1,borderInlineEndWidth:1},"&:hover":{zIndex:1,borderInlineEndWidth:1}},[`> ${t}:first-child, ${t}-group-addon:first-child`]:{borderStartEndRadius:0,borderEndEndRadius:0,[`${n}-select`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}-affix-wrapper`]:{[`&:not(:first-child) ${t}`]:{borderStartStartRadius:0,borderEndStartRadius:0},[`&:not(:last-child) ${t}`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`> ${t}:last-child, ${t}-group-addon:last-child`]:{borderStartStartRadius:0,borderEndStartRadius:0,[`${n}-select`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`${t}-affix-wrapper`]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0},"&:not(:first-child)":{borderStartStartRadius:0,borderEndStartRadius:0}},[`&${t}-group-compact`]:{display:"block",...P0(),[`${t}-group-addon, ${t}-group-wrap, > ${t}`]:{"&:not(:first-child):not(:last-child)":{borderInlineEndWidth:e.lineWidth,"&:hover, &:focus":{zIndex:1}}},"& > *":{display:"inline-flex",float:"none",verticalAlign:"top",borderRadius:0},[`
& > ${t}-affix-wrapper,
& > ${t}-number-affix-wrapper,
& > ${n}-picker-range
`]:{display:"inline-flex"},"& > *:not(:last-child)":{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderInlineEndWidth:e.lineWidth},[t]:{float:"none"},[`& > ${n}-select,
& > ${n}-select-auto-complete ${t},
& > ${n}-cascader-picker ${t},
& > ${t}-group-wrapper ${t}`]:{borderInlineEndWidth:e.lineWidth,borderRadius:0,"&:hover, &:focus":{zIndex:1}},[`& > ${n}-select-focused`]:{zIndex:1},[`& > ${n}-select > ${n}-select-arrow`]:{zIndex:1},[`& > *:first-child,
& > ${n}-select:first-child,
& > ${n}-select-auto-complete:first-child ${t},
& > ${n}-cascader-picker:first-child ${t}`]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius},[`& > *:last-child,
& > ${n}-select:last-child,
& > ${n}-cascader-picker:last-child ${t},
& > ${n}-cascader-picker-focused:last-child ${t}`]:{borderInlineEndWidth:e.lineWidth,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius},[`& > ${n}-select-auto-complete ${t}`]:{verticalAlign:"top"},[`${t}-group-wrapper + ${t}-group-wrapper`]:{marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),[`${t}-affix-wrapper`]:{}}}}},Gue=e=>{const{componentCls:t,controlHeightSM:n,lineWidth:r,calc:o}=e,a=o(n).sub(o(r).mul(2)).sub(16).div(2).equal();return {[t]:{...dn(e),...p1(e),...S7(e),...w7(e),...C7(e),...E7(e),'&[type="color"]':{height:e.controlHeight,[`&${t}-lg`]:{height:e.controlHeightLG},[`&${t}-sm`]:{height:n,paddingTop:a,paddingBottom:a}},'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration':{appearance:"none"}}}},que=e=>{const{componentCls:t}=e;return {[`${t}-clear-icon`]:{margin:0,padding:0,lineHeight:0,color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,verticalAlign:-1,cursor:"pointer",transition:`color ${e.motionDurationSlow}`,border:"none",outline:"none",backgroundColor:"transparent","&:hover":{color:e.colorIcon},"&:active":{color:e.colorText},"&-hidden":{visibility:"hidden"},"&-has-suffix":{margin:`0 ${oe(e.inputAffixPadding)}`}}}},Kue=e=>{const{componentCls:t,inputAffixPadding:n,colorTextDescription:r,motionDurationSlow:o,colorIcon:i,colorIconHover:a,iconCls:l}=e,u=`${t}-affix-wrapper`,d=`${t}-affix-wrapper-disabled`;return {[u]:{...p1(e),display:"inline-flex","&-focused, &:focus":{zIndex:1},[`> input${t}`]:{padding:0},[`> input${t}, > textarea${t}`]:{fontSize:"inherit",border:"none",borderRadius:0,outline:"none",background:"transparent",color:"inherit","&::-ms-reveal":{display:"none"},"&:focus":{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},[t]:{"&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center","> *:not(:last-child)":{marginInlineEnd:e.paddingXS}},"&-show-count-suffix":{color:r,direction:"ltr"},"&-show-count-has-suffix":{marginInlineEnd:e.paddingXXS},"&-prefix":{marginInlineEnd:n},"&-suffix":{marginInlineStart:n}},...que(e),[`${l}${t}-password-icon`]:{color:i,cursor:"pointer",transition:`all ${o}`,"&:hover":{color:a}}},[`${t}-underlined`]:{borderRadius:0},[d]:{[`${l}${t}-password-icon`]:{color:i,cursor:"not-allowed","&:hover":{color:i}}}}},Yue=e=>{const{componentCls:t,borderRadiusLG:n,borderRadiusSM:r}=e;return {[`${t}-group`]:{...dn(e),...Wue(e),"&-rtl":{direction:"rtl"},"&-wrapper":{display:"inline-block",width:"100%",textAlign:"start",verticalAlign:"top","&-rtl":{direction:"rtl"},"&-lg":{[`${t}-group-addon`]:{borderRadius:n,fontSize:e.inputFontSizeLG}},"&-sm":{[`${t}-group-addon`]:{borderRadius:r}},...jue(e),...Uue(e),[`&:not(${t}-compact-first-item):not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}, ${t}-group-addon`]:{borderRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-first-item`]:{[`${t}, ${t}-group-addon`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-last-item`]:{[`${t}, ${t}-group-addon`]:{borderStartStartRadius:0,borderEndStartRadius:0}},[`&:not(${t}-compact-last-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartEndRadius:0,borderEndEndRadius:0}},[`&:not(${t}-compact-first-item)${t}-compact-item`]:{[`${t}-affix-wrapper`]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}}},Xue=e=>{const{componentCls:t}=e;return {[`${t}-out-of-range`]:{[`&, & input, & textarea, ${t}-show-count-suffix, ${t}-data-count`]:{color:e.colorError}}}},R7=Wt(["Input","Shared"],e=>{const t=Ft(e,Lf(e));return [Gue(t),Kue(t)]},zf,{resetFont:false}),T7=Wt(["Input","Component"],e=>{const t=Ft(e,Lf(e));return [Yue(t),Xue(t),If(t,{focus:true,focusElCls:`${t.componentCls}-affix-wrapper-focused`})]},zf,{resetFont:false});var Que={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M482 152h60q8 0 8 8v704q0 8-8 8h-60q-8 0-8-8V160q0-8 8-8z"}},{tag:"path",attrs:{d:"M192 474h672q8 0 8 8v60q0 8-8 8H160q-8 0-8-8v-60q0-8 8-8z"}}]},name:"plus",theme:"outlined"};function kE(){return kE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},kE.apply(this,arguments)}const Zue=(e,t)=>f.createElement(Xn,kE({},e,{ref:t,icon:Que})),A7=f.forwardRef(Zue);var Jm={exports:{}},o8;function Jue(){if(o8)return Jm.exports;o8=1,Jm.exports=r,Jm.exports.isMobile=r,Jm.exports.default=r;const e=/(android|bb\d+|meego).+mobile|armv7l|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|redmi|series[46]0|samsungbrowser.*mobile|symbian|treo|up\.(browser|link)|vodafone|wap|windows (ce|phone)|xda|xiino/i,t=/CrOS/,n=/android|ipad|playbook|silk/i;function r(o){o||(o={});let i=o.ua;if(!i&&typeof navigator<"u"&&(i=navigator.userAgent),i&&i.headers&&typeof i.headers["user-agent"]=="string"&&(i=i.headers["user-agent"]),typeof i!="string")return false;let a=e.test(i)&&!t.test(i)||!!o.tablet&&n.test(i);return !a&&o.tablet&&o.featureDetect&&navigator&&navigator.maxTouchPoints>1&&i.indexOf("Macintosh")!==-1&&i.indexOf("Safari")!==-1&&(a=true),a}return Jm.exports}var ede=Jue();const tde=Io(ede);let nw;const nde=(()=>(typeof nw>"u"&&(nw=tde()),nw)),KR=f.createContext(null),rde=e=>{const{activeTabOffset:t,horizontal:n,rtl:r,indicator:o={}}=e,{size:i,align:a="center"}=o,[l,u]=f.useState(),d=f.useRef(),m=q.useCallback(g=>typeof i=="function"?i(g):typeof i=="number"?i:g,[i]);function p(){Lt.cancel(d.current);}return f.useEffect(()=>{const g={};if(t)if(n){g.width=m(t.width);const b=r?"right":"left";a==="start"&&(g[b]=t[b]),a==="center"&&(g[b]=t[b]+t.width/2,g.transform=r?"translateX(50%)":"translateX(-50%)"),a==="end"&&(g[b]=t[b]+t.width,g.transform="translateX(-100%)");}else g.height=m(t.height),a==="start"&&(g.top=t.top),a==="center"&&(g.top=t.top+t.height/2,g.transform="translateY(-50%)"),a==="end"&&(g.top=t.top+t.height,g.transform="translateY(-100%)");return p(),d.current=Lt(()=>{l&&g&&Object.keys(g).every(y=>{const S=g[y],C=l[y];return typeof S=="number"&&typeof C=="number"?Math.round(S)===Math.round(C):S===C})||u(g);}),p},[JSON.stringify(t),n,r,a,m]),{style:l}},i8={width:0,height:0,left:0,top:0};function ode(e,t,n){return f.useMemo(()=>{const r=new Map,o=t.get(e[0]?.key)||i8,i=o.left+o.width;for(let a=0;a<e.length;a+=1){const{key:l}=e[a];let u=t.get(l);u||(u=t.get(e[a-1]?.key)||i8);const d=r.get(l)||{...u};d.right=i-d.left-d.width,r.set(l,d);}return r},[e.map(r=>r.key).join("_"),t,n])}function a8(e,t){const n=f.useRef(e),[,r]=f.useState({});function o(i){const a=typeof i=="function"?i(n.current):i;a!==n.current&&t(a,n.current),n.current=a,r({});}return [n.current,o]}const ide=.1,s8=.01,Yb=20,l8=.995**Yb;function ade(e,t){const[n,r]=f.useState(),[o,i]=f.useState(0),[a,l]=f.useState(0),[u,d]=f.useState(),m=f.useRef();function p(w){const{screenX:$,screenY:M}=w.touches[0];r({x:$,y:M}),window.clearInterval(m.current);}function g(w){if(!n)return;const{screenX:$,screenY:M}=w.touches[0];r({x:$,y:M});const T=$-n.x,R=M-n.y;t(T,R);const I=Date.now();i(I),l(I-o),d({x:T,y:R});}function b(){if(n&&(r(null),d(null),u)){const w=u.x/a,$=u.y/a,M=Math.abs(w),T=Math.abs($);if(Math.max(M,T)<ide)return;let R=w,I=$;m.current=window.setInterval(()=>{if(Math.abs(R)<s8&&Math.abs(I)<s8){window.clearInterval(m.current);return}R*=l8,I*=l8,t(R*Yb,I*Yb);},Yb);}}const y=f.useRef();function S(w){const{deltaX:$,deltaY:M}=w;let T=0;const R=Math.abs($),I=Math.abs(M);R===I?T=y.current==="x"?$:M:R>I?(T=$,y.current="x"):(T=M,y.current="y"),t(-T,-T)&&w.preventDefault();}const C=f.useRef(null);C.current={onTouchStart:p,onTouchMove:g,onTouchEnd:b,onWheel:S},f.useEffect(()=>{function w(R){C.current.onTouchStart(R);}function $(R){C.current.onTouchMove(R);}function M(R){C.current.onTouchEnd(R);}function T(R){C.current.onWheel(R);}return document.addEventListener("touchmove",$,{passive:false}),document.addEventListener("touchend",M,{passive:true}),e.current.addEventListener("touchstart",w,{passive:true}),e.current.addEventListener("wheel",T,{passive:false}),()=>{document.removeEventListener("touchmove",$),document.removeEventListener("touchend",M);}},[]);}function N7(e){const[t,n]=f.useState(0),r=f.useRef(0),o=f.useRef();return o.current=e,Bb(()=>{o.current?.();},[t]),()=>{r.current===t&&(r.current+=1,n(r.current));}}function sde(e){const t=f.useRef([]),[,n]=f.useState({}),r=f.useRef(typeof e=="function"?e():e),o=N7(()=>{let a=r.current;t.current.forEach(l=>{a=l(a);}),t.current=[],r.current=a,n({});});function i(a){t.current.push(a),o();}return [r.current,i]}const c8={width:0,height:0,left:0,top:0,right:0};function lde(e,t,n,r,o,i,{tabs:a,tabPosition:l,rtl:u}){let d,m,p;return ["top","bottom"].includes(l)?(d="width",m=u?"right":"left",p=Math.abs(n)):(d="height",m="top",p=-n),f.useMemo(()=>{if(!a.length)return [0,0];const g=a.length;let b=g;for(let S=0;S<g;S+=1){const C=e.get(a[S].key)||c8;if(Math.floor(C[m]+C[d])>Math.floor(p+t)){b=S-1;break}}let y=0;for(let S=g-1;S>=0;S-=1)if((e.get(a[S].key)||c8)[m]<p){y=S+1;break}return y>b?[0,-1]:[y,b]},[e,t,r,o,i,p,l,a.map(g=>g.key).join("_"),u])}function u8(e){let t;return e instanceof Map?(t={},e.forEach((n,r)=>{t[r]=n;})):t=e,JSON.stringify(t)}const cde="TABS_DQ";function P7(e){return String(e).replace(/"/g,cde)}function YR(e,t,n,r){return !(!n||r||e===false||e===void 0&&(t===false||t===null))}const I7=f.forwardRef((e,t)=>{const{prefixCls:n,editable:r,locale:o,style:i}=e;return !r||r.showAdd===false?null:f.createElement("button",{ref:t,type:"button",className:`${n}-nav-add`,style:i,"aria-label":o?.addAriaLabel||"Add tab",onClick:a=>{r.onEdit("add",{event:a});}},r.addIcon||"+")}),d8=f.forwardRef((e,t)=>{const{position:n,prefixCls:r,extra:o}=e;if(!o)return null;let i,a={};return typeof o=="object"&&!f.isValidElement(o)?a=o:a.right=o,n==="right"&&(i=a.right),n==="left"&&(i=a.left),i?f.createElement("div",{className:`${r}-extra-content`,ref:t},i):null});function FE(){return FE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},FE.apply(this,arguments)}const ude=f.forwardRef((e,t)=>{const{prefixCls:n,id:r,tabs:o,locale:i,mobile:a,more:l={},style:u,className:d,editable:m,tabBarGutter:p,rtl:g,removeAriaLabel:b,onTabClick:y,getPopupContainer:S,popupClassName:C,popupStyle:w}=e,[$,M]=f.useState(false),[T,R]=f.useState(null),{icon:I="More"}=l,N=`${r}-more-popup`,P=`${n}-dropdown`,O=T!==null?`${N}-${T}`:null,_=i?.dropdownAriaLabel;function B(W,Y){W.preventDefault(),W.stopPropagation(),m.onEdit("remove",{key:Y,event:W});}const V=f.createElement(Bf,{onClick:({key:W,domEvent:Y})=>{y(W,Y),M(false);},prefixCls:`${P}-menu`,id:N,tabIndex:-1,role:"listbox","aria-activedescendant":O,selectedKeys:[T],"aria-label":_!==void 0?_:"expanded dropdown"},o.map(W=>{const{closable:Y,disabled:Q,closeIcon:D,key:L,label:K}=W,J=YR(Y,D,m,Q);return f.createElement(ag,{key:L,id:`${N}-${L}`,role:"option","aria-controls":r&&`${r}-panel-${L}`,disabled:Q},f.createElement("span",null,K),J&&f.createElement("button",{type:"button","aria-label":b||"remove",tabIndex:0,className:`${P}-menu-item-remove`,onClick:ee=>{ee.stopPropagation(),B(ee,L);}},D||m.removeIcon||"×"))}));function U(W){const Y=o.filter(L=>!L.disabled);let Q=Y.findIndex(L=>L.key===T)||0;const D=Y.length;for(let L=0;L<D;L+=1){Q=(Q+W+D)%D;const K=Y[Q];if(!K.disabled){R(K.key);return}}}function G(W){const{which:Y}=W;if(!$){[it.DOWN,it.SPACE,it.ENTER].includes(Y)&&(M(true),W.preventDefault());return}switch(Y){case it.UP:U(-1),W.preventDefault();break;case it.DOWN:U(1),W.preventDefault();break;case it.ESC:M(false);break;case it.SPACE:case it.ENTER:T!==null&&y(T,W);break}}f.useEffect(()=>{const W=document.getElementById(O);W?.scrollIntoView&&W.scrollIntoView(false);},[O,T]),f.useEffect(()=>{$||R(null);},[$]);const H={marginInlineStart:p};o.length||(H.visibility="hidden",H.order=1);const z=X(C,{[`${P}-rtl`]:g}),j=a?null:f.createElement(ZF,FE({prefixCls:P,overlay:V,visible:o.length?$:false,onVisibleChange:M,overlayClassName:z,overlayStyle:w,mouseEnterDelay:.1,mouseLeaveDelay:.1,getPopupContainer:S},l),f.createElement("button",{type:"button",className:`${n}-nav-more`,style:H,"aria-haspopup":"listbox","aria-controls":N,id:`${r}-more`,"aria-expanded":$,onKeyDown:G},I));return f.createElement("div",{className:X(`${n}-nav-operations`,d),style:u,ref:t},j,f.createElement(I7,{prefixCls:n,locale:i,editable:m}))}),dde=f.memo(ude,(e,t)=>t.tabMoving),fde=e=>{const{prefixCls:t,id:n,active:r,focus:o,tab:{key:i,label:a,disabled:l,closeIcon:u,icon:d},closable:m,renderWrapper:p,removeAriaLabel:g,editable:b,onClick:y,onFocus:S,onBlur:C,onKeyDown:w,onMouseDown:$,onMouseUp:M,style:T,className:R,tabCount:I,currentPosition:N}=e,P=`${t}-tab`,O=YR(m,u,b,l);function _(H){l||y(H);}function B(H){H.preventDefault(),H.stopPropagation(),b.onEdit("remove",{key:i,event:H});}const V=f.useMemo(()=>d&&typeof a=="string"?f.createElement("span",null,a):a,[a,d]),U=f.useRef(null);f.useEffect(()=>{o&&U.current&&U.current.focus();},[o]);const G=f.createElement("div",{key:i,"data-node-key":P7(i),className:X(P,R,{[`${P}-with-remove`]:O,[`${P}-active`]:r,[`${P}-disabled`]:l,[`${P}-focus`]:o}),style:T,onClick:_},f.createElement("div",{ref:U,role:"tab","aria-selected":r,id:n&&`${n}-tab-${i}`,className:`${P}-btn`,"aria-controls":n&&`${n}-panel-${i}`,"aria-disabled":l,tabIndex:l?null:r?0:-1,onClick:H=>{H.stopPropagation(),_(H);},onKeyDown:w,onMouseDown:$,onMouseUp:M,onFocus:S,onBlur:C},o&&f.createElement("div",{"aria-live":"polite",style:{width:0,height:0,position:"absolute",overflow:"hidden",opacity:0}},`Tab ${N} of ${I}`),d&&f.createElement("span",{className:`${P}-icon`},d),a&&V),O&&f.createElement("button",{type:"button","aria-label":g||"remove",tabIndex:r?0:-1,className:`${P}-remove`,onClick:H=>{H.stopPropagation(),B(H);}},u||b.removeIcon||"×"));return p?p(G):G};function HE(){return HE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},HE.apply(this,arguments)}const mde=(e,t)=>{const{offsetWidth:n,offsetHeight:r,offsetTop:o,offsetLeft:i}=e,{width:a,height:l,left:u,top:d}=e.getBoundingClientRect();return Math.abs(a-n)<1?[a,l,u-t.left,d-t.top]:[n,r,i,o]},Ed=e=>{const{offsetWidth:t=0,offsetHeight:n=0}=e.current||{};if(e.current){const{width:r,height:o}=e.current.getBoundingClientRect();if(Math.abs(r-t)<1)return [r,o]}return [t,n]},ub=(e,t)=>e[t?0:1],f8=f.forwardRef((e,t)=>{const{className:n,style:r,id:o,animated:i,activeKey:a,rtl:l,extra:u,editable:d,locale:m,tabPosition:p,tabBarGutter:g,children:b,onTabClick:y,onTabScroll:S,indicator:C,classNames:w,styles:$}=e,{prefixCls:M,tabs:T}=f.useContext(KR),R=f.useRef(null),I=f.useRef(null),N=f.useRef(null),P=f.useRef(null),O=f.useRef(null),_=f.useRef(null),B=f.useRef(null),V=p==="top"||p==="bottom",[U,G]=a8(0,(he,De)=>{V&&S&&S({direction:he>De?"left":"right"});}),[H,z]=a8(0,(he,De)=>{!V&&S&&S({direction:he>De?"top":"bottom"});}),[j,W]=f.useState([0,0]),[Y,Q]=f.useState([0,0]),[D,L]=f.useState([0,0]),[K,J]=f.useState([0,0]),[ee,te]=sde(new Map),re=ode(T,ee,Y[0]),ie=ub(j,V),de=ub(Y,V),ne=ub(D,V),ce=ub(K,V),fe=Math.floor(ie)<Math.floor(de+ne),se=fe?ie-ce:ie-ne,Me=`${M}-nav-operations-hidden`;let ae=0,pe=0;V&&l?(ae=0,pe=Math.max(0,de-se)):(ae=Math.min(0,se-de),pe=0);function Ce(he){return he<ae?ae:he>pe?pe:he}const xe=f.useRef(null),[Ae,Xe]=f.useState();function Ne(){Xe(Date.now());}function ue(){xe.current&&clearTimeout(xe.current);}ade(P,(he,De)=>{function $e(ke,Ge){ke(ot=>Ce(ot+Ge));}return fe?(V?$e(G,he):$e(z,De),ue(),Ne(),true):false}),f.useEffect(()=>(ue(),Ae&&(xe.current=setTimeout(()=>{Xe(0);},100)),ue),[Ae]);const[ge,Pe]=lde(re,se,V?U:H,de,ne,ce,{...e,tabs:T}),je=Mt((he=a)=>{const De=re.get(he)||{width:0,height:0,left:0,right:0,top:0};if(V){let $e=U;l?De.right<U?$e=De.right:De.right+De.width>U+se&&($e=De.right+De.width-se):De.left<-U?$e=-De.left:De.left+De.width>-U+se&&($e=-(De.left+De.width-se)),z(0),G(Ce($e));}else {let $e=H;De.top<-H?$e=-De.top:De.top+De.height>-H+se&&($e=-(De.top+De.height-se)),G(0),z(Ce($e));}}),[qe,Ue]=f.useState(),[et,rt]=f.useState(false),Ke=T.filter(he=>!he.disabled).map(he=>he.key),_e=he=>{const De=Ke.indexOf(qe||a),$e=Ke.length,ke=(De+he+$e)%$e,Ge=Ke[ke];Ue(Ge);},We=(he,De)=>{const $e=Ke.indexOf(he),ke=T.find(ot=>ot.key===he);YR(ke?.closable,ke?.closeIcon,d,ke?.disabled)&&(De.preventDefault(),De.stopPropagation(),d.onEdit("remove",{key:he,event:De}),$e===Ke.length-1?_e(-1):_e(1));},Ze=(he,De)=>{rt(true),De.button===1&&We(he,De);},Be=he=>{const{code:De}=he,$e=l&&V,ke=Ke[0],Ge=Ke[Ke.length-1];switch(De){case "ArrowLeft":{V&&_e($e?1:-1);break}case "ArrowRight":{V&&_e($e?-1:1);break}case "ArrowUp":{he.preventDefault(),V||_e(-1);break}case "ArrowDown":{he.preventDefault(),V||_e(1);break}case "Home":{he.preventDefault(),Ue(ke);break}case "End":{he.preventDefault(),Ue(Ge);break}case "Enter":case "Space":{he.preventDefault(),y(qe??a,he);break}case "Backspace":case "Delete":{We(qe,he);break}}},Oe={};V?Oe.marginInlineStart=g:Oe.marginTop=g;const lt=T.map((he,De)=>{const{key:$e}=he;return f.createElement(fde,{id:o,prefixCls:M,key:$e,tab:he,className:w?.item,style:De===0?$?.item:{...Oe,...$?.item},closable:he.closable,editable:d,active:$e===a,focus:$e===qe,renderWrapper:b,removeAriaLabel:m?.removeAriaLabel,tabCount:Ke.length,currentPosition:De+1,onClick:ke=>{y($e,ke);},onKeyDown:Be,onFocus:()=>{et||Ue($e),je($e),Ne(),P.current&&(l||(P.current.scrollLeft=0),P.current.scrollTop=0);},onBlur:()=>{Ue(void 0);},onMouseDown:ke=>Ze($e,ke),onMouseUp:()=>{rt(false);}})}),It=()=>te(()=>{const he=new Map,De=O.current?.getBoundingClientRect();return T.forEach(({key:$e})=>{const ke=O.current?.querySelector(`[data-node-key="${P7($e)}"]`);if(ke){const[Ge,ot,ht,$t]=mde(ke,De);he.set($e,{width:Ge,height:ot,left:ht,top:$t});}}),he});f.useEffect(()=>{It();},[T.map(he=>he.key).join("_")]);const mt=N7(()=>{const he=Ed(R),De=Ed(I),$e=Ed(N);W([he[0]-De[0]-$e[0],he[1]-De[1]-$e[1]]);const ke=Ed(B);L(ke);const Ge=Ed(_);J(Ge);const ot=Ed(O);Q([ot[0]-ke[0],ot[1]-ke[1]]),It();}),Bt=T.slice(0,ge),xt=T.slice(Pe+1),Tt=[...Bt,...xt],ut=re.get(a),{style:dt}=rde({activeTabOffset:ut,horizontal:V,indicator:C,rtl:l});f.useEffect(()=>{je();},[a,ae,pe,u8(ut),u8(re),V]),f.useEffect(()=>{mt();},[l]);const gt=!!Tt.length,Fe=`${M}-nav-wrap`;let Qe,ye,be,Se;return V?l?(ye=U>0,Qe=U!==pe):(Qe=U<0,ye=U!==ae):(be=H<0,Se=H!==ae),f.createElement(ma,{onResize:mt},f.createElement("div",{ref:Bs(t,R),role:"tablist","aria-orientation":V?"horizontal":"vertical",className:X(`${M}-nav`,n,w?.header),style:{...$?.header,...r},onKeyDown:()=>{Ne();}},f.createElement(d8,{ref:I,position:"left",extra:u,prefixCls:M}),f.createElement(ma,{onResize:mt},f.createElement("div",{className:X(Fe,{[`${Fe}-ping-left`]:Qe,[`${Fe}-ping-right`]:ye,[`${Fe}-ping-top`]:be,[`${Fe}-ping-bottom`]:Se}),ref:P},f.createElement(ma,{onResize:mt},f.createElement("div",{ref:O,className:`${M}-nav-list`,style:{transform:`translate(${U}px, ${H}px)`,transition:Ae?"none":void 0}},lt,f.createElement(I7,{ref:B,prefixCls:M,locale:m,editable:d,style:{...lt.length===0?void 0:Oe,visibility:gt?"hidden":null}}),f.createElement("div",{className:X(`${M}-ink-bar`,w?.indicator,{[`${M}-ink-bar-animated`]:i.inkBar}),style:{...dt,...$?.indicator}}))))),f.createElement(dde,HE({},e,{removeAriaLabel:m?.removeAriaLabel,ref:_,prefixCls:M,tabs:Tt,className:!gt&&Me,popupStyle:$?.popup,tabMoving:!!Ae})),f.createElement(d8,{ref:N,position:"right",extra:u,prefixCls:M})))}),hde=({renderTabBar:e,...t})=>e?e(t,f8):f.createElement(f8,t),pde=f.forwardRef((e,t)=>{const{prefixCls:n,className:r,style:o,id:i,active:a,tabKey:l,children:u}=e,d=f.Children.count(u)>0;return f.createElement("div",{id:i&&`${i}-panel-${l}`,role:"tabpanel",tabIndex:a&&d?0:-1,"aria-labelledby":i&&`${i}-tab-${l}`,"aria-hidden":!a,style:o,className:X(n,a&&`${n}-active`,r),ref:t},u)});function Q0(){return Q0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Q0.apply(this,arguments)}const gde=e=>{const{id:t,activeKey:n,animated:r,tabPosition:o,destroyOnHidden:i,contentStyle:a,contentClassName:l}=e,{prefixCls:u,tabs:d}=f.useContext(KR),m=r.tabPane,p=`${u}-tabpane`;return f.createElement("div",{className:X(`${u}-content-holder`)},f.createElement("div",{className:X(`${u}-content`,`${u}-content-${o}`,{[`${u}-content-animated`]:m})},d.map(g=>{const{key:b,forceRender:y,style:S,className:C,destroyOnHidden:w,...$}=g,M=b===n;return f.createElement(Co,Q0({key:b,visible:M,forceRender:y,removeOnLeave:!!(i??w),leavedClassName:`${p}-hidden`},r.tabPaneMotion),({style:T,className:R},I)=>f.createElement(pde,Q0({},$,{prefixCls:p,id:t,tabKey:b,animated:m,active:M,style:{...a,...S,...T},className:X(l,C,R),ref:I})))})))};function vde(e={inkBar:true,tabPane:false}){let t;return e===false?t={inkBar:false,tabPane:false}:e===true?t={inkBar:true,tabPane:false}:t={inkBar:true,...typeof e=="object"?e:{}},t.tabPaneMotion&&t.tabPane===void 0&&(t.tabPane=true),!t.tabPaneMotion&&t.tabPane&&(t.tabPane=false),t}function Bh(){return Bh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Bh.apply(this,arguments)}let m8=0;const bde=f.forwardRef((e,t)=>{const{id:n,prefixCls:r="rc-tabs",className:o,items:i,direction:a,activeKey:l,defaultActiveKey:u,editable:d,animated:m,tabPosition:p="top",tabBarGutter:g,tabBarStyle:b,tabBarExtraContent:y,locale:S,more:C,destroyOnHidden:w,renderTabBar:$,onChange:M,onTabClick:T,onTabScroll:R,getPopupContainer:I,popupClassName:N,indicator:P,classNames:O,styles:_,...B}=e,V=f.useMemo(()=>(i||[]).filter(re=>re&&typeof re=="object"&&"key"in re),[i]),U=a==="rtl",G=vde(m),[H,z]=f.useState(false);f.useEffect(()=>{z(nde());},[]);const[j,W]=un(u??V[0]?.key,l),[Y,Q]=f.useState(()=>V.findIndex(re=>re.key===j));f.useEffect(()=>{let re=V.findIndex(ie=>ie.key===j);re===-1&&(re=Math.max(0,Math.min(Y,V.length-1)),W(V[re]?.key)),Q(re);},[V.map(re=>re.key).join("_"),j,Y]);const[D,L]=un(null,n);f.useEffect(()=>{n||(L(`rc-tabs-${m8}`),m8+=1);},[]);function K(re,ie){T?.(re,ie);const de=re!==j;W(re),de&&M?.(re);}const J={id:D,activeKey:j,animated:G,tabPosition:p,rtl:U,mobile:H},ee={...J,editable:d,locale:S,more:C,tabBarGutter:g,onTabClick:K,onTabScroll:R,extra:y,style:b,getPopupContainer:I,popupClassName:X(N,O?.popup),indicator:P,styles:_,classNames:O},te=f.useMemo(()=>({tabs:V,prefixCls:r}),[V,r]);return f.createElement(KR.Provider,{value:te},f.createElement("div",Bh({ref:t,id:n,className:X(r,`${r}-${p}`,{[`${r}-mobile`]:H,[`${r}-editable`]:d,[`${r}-rtl`]:U},o)},B),f.createElement(hde,Bh({},ee,{renderTabBar:$})),f.createElement(gde,Bh({destroyOnHidden:w},J,{contentStyle:_?.content,contentClassName:O?.content,animated:G}))))}),yde={motionAppear:false,motionEnter:true,motionLeave:true};function Sde(e,t={inkBar:true,tabPane:false}){let n;return t===false?n={inkBar:false,tabPane:false}:t===true?n={inkBar:true,tabPane:true}:n={inkBar:true,...typeof t=="object"?t:{}},n.tabPane&&(n.tabPaneMotion={...yde,motionName:Fl(e,"switch")}),n}function Cde(e){return e.filter(t=>t)}function xde(e,t){if(e)return e.map(r=>({...r,destroyOnHidden:r.destroyOnHidden??r.destroyInactiveTabPane}));const n=Qo(t).map(r=>{if(f.isValidElement(r)){const{key:o,props:i}=r,{tab:a,...l}=i||{};return {key:String(o),...l,label:a}}return null});return Cde(n)}const wde=e=>{const{componentCls:t,motionDurationSlow:n}=e;return [{[t]:{[`${t}-switch`]:{"&-appear, &-enter":{transition:"none","&-start":{opacity:0},"&-active":{opacity:1,transition:`opacity ${n}`}},"&-leave":{position:"absolute",transition:"none",inset:0,"&-start":{opacity:1},"&-active":{opacity:0,transition:`opacity ${n}`}}}}},[Hl(e,"slide-up"),Hl(e,"slide-down")]]},$de=e=>{const{componentCls:t,tabsCardPadding:n,cardBg:r,cardGutter:o,colorBorderSecondary:i,itemSelectedColor:a}=e;return {[`${t}-card`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{margin:0,padding:n,background:r,border:`${oe(e.lineWidth)} ${e.lineType} ${i}`,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`},[`${t}-tab-active`]:{color:a,background:e.colorBgContainer},[`${t}-tab-focus:has(${t}-tab-btn:focus-visible)`]:ba(e,-3),[`& ${t}-tab${t}-tab-focus ${t}-tab-btn:focus-visible`]:{outline:"none"},[`${t}-ink-bar`]:{visibility:"hidden"}},[`&${t}-top, &${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginLeft:{_skip_check_:true,value:oe(o)}}}},[`&${t}-top`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)} 0 0`},[`${t}-tab-active`]:{borderBottomColor:e.colorBgContainer}}},[`&${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:`0 0 ${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)}`},[`${t}-tab-active`]:{borderTopColor:e.colorBgContainer}}},[`&${t}-left, &${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginTop:oe(o)}}},[`&${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:true,value:`${oe(e.borderRadiusLG)} 0 0 ${oe(e.borderRadiusLG)}`}},[`${t}-tab-active`]:{borderRightColor:{_skip_check_:true,value:e.colorBgContainer}}}},[`&${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab`]:{borderRadius:{_skip_check_:true,value:`0 ${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)} 0`}},[`${t}-tab-active`]:{borderLeftColor:{_skip_check_:true,value:e.colorBgContainer}}}}}}},Ede=e=>{const{componentCls:t,itemHoverColor:n,dropdownEdgeChildVerticalPadding:r}=e;return {[`${t}-dropdown`]:{...dn(e),position:"absolute",top:-9999,left:{_skip_check_:true,value:-9999},zIndex:e.zIndexPopup,display:"block","&-hidden":{display:"none"},[`${t}-dropdown-menu`]:{maxHeight:e.tabsDropdownHeight,margin:0,padding:`${oe(r)} 0`,overflowX:"hidden",overflowY:"auto",textAlign:{_skip_check_:true,value:"left"},listStyleType:"none",backgroundColor:e.colorBgContainer,backgroundClip:"padding-box",borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,"&-item":{...Ga,display:"flex",alignItems:"center",minWidth:e.tabsDropdownWidth,margin:0,padding:`${oe(e.paddingXXS)} ${oe(e.paddingSM)}`,color:e.colorText,fontWeight:"normal",fontSize:e.fontSize,lineHeight:e.lineHeight,cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"> span":{flex:1,whiteSpace:"nowrap"},"&-remove":{flex:"none",marginLeft:{_skip_check_:true,value:e.marginSM},color:e.colorIcon,fontSize:e.fontSizeSM,background:"transparent",border:0,cursor:"pointer","&:hover":{color:n}},"&:hover":{background:e.controlItemBgHover},"&-disabled":{"&, &:hover":{color:e.colorTextDisabled,background:"transparent",cursor:"not-allowed"}}}}}}},Mde=e=>{const{componentCls:t,margin:n,colorBorderSecondary:r,horizontalMargin:o,verticalItemPadding:i,verticalItemMargin:a,motionDurationSlow:l,calc:u}=e;return {[`${t}-top, ${t}-bottom`]:{flexDirection:"column",[`> ${t}-nav, > div > ${t}-nav`]:{margin:o,"&::before":{position:"absolute",right:{_skip_check_:true,value:0},left:{_skip_check_:true,value:0},borderBottom:`${oe(e.lineWidth)} ${e.lineType} ${r}`,content:"''"},[`${t}-ink-bar`]:{height:e.lineWidthBold,"&-animated":{transition:["width","left","right"].map(d=>`${d} ${l}`).join(", ")}},[`${t}-nav-wrap`]:{"&::before, &::after":{top:0,bottom:0,width:e.controlHeight},"&::before":{left:{_skip_check_:true,value:0},boxShadow:e.boxShadowTabsOverflowLeft},"&::after":{right:{_skip_check_:true,value:0},boxShadow:e.boxShadowTabsOverflowRight},[`&${t}-nav-wrap-ping-left::before`]:{opacity:1},[`&${t}-nav-wrap-ping-right::after`]:{opacity:1}}}},[`${t}-top`]:{[`> ${t}-nav,
> div > ${t}-nav`]:{"&::before":{bottom:0},[`${t}-ink-bar`]:{bottom:0}}},[`${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,marginTop:n,marginBottom:0,"&::before":{top:0},[`${t}-ink-bar`]:{top:0}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0}},[`${t}-left, ${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{flexDirection:"column",minWidth:u(e.controlHeight).mul(1.25).equal(),[`${t}-tab`]:{padding:i,textAlign:"center"},[`${t}-tab + ${t}-tab`]:{margin:a},[`${t}-nav-wrap`]:{flexDirection:"column","&::before, &::after":{right:{_skip_check_:true,value:0},left:{_skip_check_:true,value:0},height:e.controlHeight},"&::before":{top:0,boxShadow:e.boxShadowTabsOverflowTop},"&::after":{bottom:0,boxShadow:e.boxShadowTabsOverflowBottom},[`&${t}-nav-wrap-ping-top::before`]:{opacity:1},[`&${t}-nav-wrap-ping-bottom::after`]:{opacity:1}},[`${t}-ink-bar`]:{width:e.lineWidthBold,"&-animated":{transition:["height","top"].map(d=>`${d} ${l}`).join(", ")}},[`${t}-nav-list, ${t}-nav-operations`]:{flex:"1 0 auto",flexDirection:"column"}}},[`${t}-left`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-ink-bar`]:{right:{_skip_check_:true,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{marginLeft:{_skip_check_:true,value:oe(u(e.lineWidth).mul(-1).equal())},borderLeft:{_skip_check_:true,value:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingLeft:{_skip_check_:true,value:e.paddingLG}}}},[`${t}-right`]:{[`> ${t}-nav, > div > ${t}-nav`]:{order:1,[`${t}-ink-bar`]:{left:{_skip_check_:true,value:0}}},[`> ${t}-content-holder, > div > ${t}-content-holder`]:{order:0,marginRight:{_skip_check_:true,value:u(e.lineWidth).mul(-1).equal()},borderRight:{_skip_check_:true,value:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`},[`> ${t}-content > ${t}-tabpane`]:{paddingRight:{_skip_check_:true,value:e.paddingLG}}}}}},Rde=e=>{const{componentCls:t,cardPaddingSM:n,cardPaddingLG:r,cardHeightSM:o,cardHeightLG:i,horizontalItemPaddingSM:a,horizontalItemPaddingLG:l}=e;return {[t]:{"&-small":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:a,fontSize:e.titleFontSizeSM}}},"&-large":{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:l,fontSize:e.titleFontSizeLG,lineHeight:e.lineHeightLG}}}},[`${t}-card`]:{[`&${t}-small`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:n},[`${t}-nav-add`]:{minWidth:o,minHeight:o}},[`&${t}-bottom`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`0 0 ${oe(e.borderRadius)} ${oe(e.borderRadius)}`}},[`&${t}-top`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:`${oe(e.borderRadius)} ${oe(e.borderRadius)} 0 0`}},[`&${t}-right`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:true,value:`0 ${oe(e.borderRadius)} ${oe(e.borderRadius)} 0`}}},[`&${t}-left`]:{[`> ${t}-nav ${t}-tab`]:{borderRadius:{_skip_check_:true,value:`${oe(e.borderRadius)} 0 0 ${oe(e.borderRadius)}`}}}},[`&${t}-large`]:{[`> ${t}-nav`]:{[`${t}-tab`]:{padding:r},[`${t}-nav-add`]:{minWidth:i,minHeight:i}}}}}},Tde=e=>{const{componentCls:t,itemActiveColor:n,itemHoverColor:r,iconCls:o,tabsHorizontalItemMargin:i,horizontalItemPadding:a,itemSelectedColor:l,itemColor:u}=e,d=`${t}-tab`;return {[d]:{position:"relative",WebkitTouchCallout:"none",WebkitTapHighlightColor:"transparent",display:"inline-flex",alignItems:"center",padding:a,fontSize:e.titleFontSize,background:"transparent",border:0,outline:"none",cursor:"pointer",color:u,"&-btn, &-remove":{"&:focus:not(:focus-visible), &:active":{color:n}},"&-btn":{outline:"none",transition:`all ${e.motionDurationSlow}`,[`${d}-icon:not(:last-child)`]:{marginInlineEnd:e.marginSM}},"&-remove":{flex:"none",lineHeight:1,marginRight:{_skip_check_:true,value:e.calc(e.marginXXS).mul(-1).equal()},marginLeft:{_skip_check_:true,value:e.marginXS},color:e.colorIcon,fontSize:e.fontSizeSM,background:"transparent",border:"none",outline:"none",cursor:"pointer",transition:`all ${e.motionDurationSlow}`,"&:hover":{color:e.colorTextHeading},...$i(e)},"&:hover":{color:r},[`&${d}-active ${d}-btn`]:{color:l},[`&${d}-focus ${d}-btn:focus-visible`]:ba(e),[`&${d}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed"},[`&${d}-disabled ${d}-btn, &${d}-disabled ${t}-remove`]:{"&:focus, &:active":{color:e.colorTextDisabled}},[`& ${d}-remove ${o}`]:{margin:0,verticalAlign:"middle"},[`${o}:not(:last-child)`]:{marginRight:{_skip_check_:true,value:e.marginSM}}},[`${d} + ${d}`]:{margin:{_skip_check_:true,value:i}}}},Ade=e=>{const{componentCls:t,tabsHorizontalItemMarginRTL:n,iconCls:r,cardGutter:o,calc:i}=e;return {[`${t}-rtl`]:{direction:"rtl",[`${t}-nav`]:{[`${t}-tab`]:{margin:{_skip_check_:true,value:n},[`${t}-tab:last-of-type`]:{marginLeft:{_skip_check_:true,value:0}},[r]:{marginRight:{_skip_check_:true,value:0},marginLeft:{_skip_check_:true,value:oe(e.marginSM)}},[`${t}-tab-remove`]:{marginRight:{_skip_check_:true,value:oe(e.marginXS)},marginLeft:{_skip_check_:true,value:oe(i(e.marginXXS).mul(-1).equal())},[r]:{margin:0}}}},[`&${t}-left`]:{[`> ${t}-nav`]:{order:1},[`> ${t}-content-holder`]:{order:0}},[`&${t}-right`]:{[`> ${t}-nav`]:{order:0},[`> ${t}-content-holder`]:{order:1}},[`&${t}-card${t}-top, &${t}-card${t}-bottom`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-tab + ${t}-tab`]:{marginRight:{_skip_check_:true,value:o},marginLeft:{_skip_check_:true,value:0}}}}},[`${t}-dropdown-rtl`]:{direction:"rtl"},[`${t}-menu-item`]:{[`${t}-dropdown-rtl`]:{textAlign:{_skip_check_:true,value:"right"}}}}},Nde=e=>{const{componentCls:t,tabsCardPadding:n,cardHeight:r,cardGutter:o,itemHoverColor:i,itemActiveColor:a,colorBorderSecondary:l}=e;return {[t]:{...dn(e),display:"flex",[`> ${t}-nav, > div > ${t}-nav`]:{position:"relative",display:"flex",flex:"none",alignItems:"center",[`${t}-nav-wrap`]:{position:"relative",display:"flex",flex:"auto",alignSelf:"stretch",overflow:"hidden",whiteSpace:"nowrap",transform:"translate(0)","&::before, &::after":{position:"absolute",zIndex:1,opacity:0,transition:`opacity ${e.motionDurationSlow}`,content:"''",pointerEvents:"none"}},[`${t}-nav-list`]:{position:"relative",display:"flex",transition:`opacity ${e.motionDurationSlow}`},[`${t}-nav-operations`]:{display:"flex",alignSelf:"stretch"},[`${t}-nav-operations-hidden`]:{position:"absolute",visibility:"hidden",pointerEvents:"none"},[`${t}-nav-more`]:{position:"relative",padding:n,background:"transparent",border:0,color:e.colorText,"&::after":{position:"absolute",right:{_skip_check_:true,value:0},bottom:0,left:{_skip_check_:true,value:0},height:e.calc(e.controlHeightLG).div(8).equal(),transform:"translateY(100%)",content:"''"}},[`${t}-nav-add`]:{minWidth:r,minHeight:r,marginLeft:{_skip_check_:true,value:o},background:"transparent",border:`${oe(e.lineWidth)} ${e.lineType} ${l}`,borderRadius:`${oe(e.borderRadiusLG)} ${oe(e.borderRadiusLG)} 0 0`,outline:"none",cursor:"pointer",color:e.colorText,transition:`all ${e.motionDurationSlow} ${e.motionEaseInOut}`,"&:hover":{color:i},"&:active, &:focus:not(:focus-visible)":{color:a},...$i(e,-3)}},[`${t}-extra-content`]:{flex:"none"},[`${t}-ink-bar`]:{position:"absolute",background:e.inkBarColor,pointerEvents:"none"},...Tde(e),[`${t}-content`]:{position:"relative",width:"100%"},[`${t}-content-holder`]:{flex:"auto",minWidth:0,minHeight:0},[`${t}-tabpane`]:{...$i(e),"&-hidden":{display:"none"}}},[`${t}-centered`]:{[`> ${t}-nav, > div > ${t}-nav`]:{[`${t}-nav-wrap`]:{[`&:not([class*='${t}-nav-wrap-ping']) > ${t}-nav-list`]:{margin:"auto"}}}}}},Pde=e=>{const{cardHeight:t,cardHeightSM:n,cardHeightLG:r,controlHeight:o,controlHeightLG:i}=e,a=t||i,l=n||o,u=r||i+8;return {zIndexPopup:e.zIndexPopupBase+50,cardBg:e.colorFillAlter,cardHeight:a,cardHeightSM:l,cardHeightLG:u,cardPadding:`${(a-e.fontHeight)/2-e.lineWidth}px ${e.padding}px`,cardPaddingSM:`${(l-e.fontHeight)/2-e.lineWidth}px ${e.paddingXS}px`,cardPaddingLG:`${(u-e.fontHeightLG)/2-e.lineWidth}px ${e.padding}px`,titleFontSize:e.fontSize,titleFontSizeLG:e.fontSizeLG,titleFontSizeSM:e.fontSize,inkBarColor:e.colorPrimary,horizontalMargin:`0 0 ${e.margin}px 0`,horizontalItemGutter:32,horizontalItemMargin:"",horizontalItemMarginRTL:"",horizontalItemPadding:`${e.paddingSM}px 0`,horizontalItemPaddingSM:`${e.paddingXS}px 0`,horizontalItemPaddingLG:`${e.padding}px 0`,verticalItemPadding:`${e.paddingXS}px ${e.paddingLG}px`,verticalItemMargin:`${e.margin}px 0 0 0`,itemColor:e.colorText,itemSelectedColor:e.colorPrimary,itemHoverColor:e.colorPrimaryHover,itemActiveColor:e.colorPrimaryActive,cardGutter:e.marginXXS/2}},Ide=Wt("Tabs",e=>{const t=Ft(e,{tabsCardPadding:e.cardPadding,dropdownEdgeChildVerticalPadding:e.paddingXXS,tabsDropdownHeight:200,tabsDropdownWidth:120,tabsHorizontalItemMargin:`0 0 0 ${oe(e.horizontalItemGutter)}`,tabsHorizontalItemMarginRTL:`0 0 0 ${oe(e.horizontalItemGutter)}`});return [Rde(t),Ade(t),Mde(t),Ede(t),$de(t),Nde(t),wde(t)]},Pde),Ode=()=>null,Dde=f.forwardRef((e,t)=>{const{type:n,className:r,rootClassName:o,size:i,onEdit:a,hideAdd:l,centered:u,addIcon:d,removeIcon:m,moreIcon:p,more:g,popupClassName:b,children:y,items:S,animated:C,style:w,indicatorSize:$,indicator:M,classNames:T,styles:R,destroyInactiveTabPane:I,destroyOnHidden:N,tabPlacement:P,tabPosition:O,..._}=e,{prefixCls:B}=_,{getPrefixCls:V,direction:U,getPopupContainer:G,className:H,style:z,classNames:j,styles:W}=jt("tabs"),{tabs:Y}=f.useContext(wt),Q=V("tabs",B),D=Qn(Q),[L,K]=Ide(Q,D),J=f.useRef(null);f.useImperativeHandle(t,()=>({nativeElement:J.current}));let ee;n==="editable-card"&&(ee={onEdit:(ae,{key:pe,event:Ce})=>{a?.(ae==="add"?Ce:pe,ae);},removeIcon:m??Y?.removeIcon??f.createElement(Ls,null),addIcon:(d??Y?.addIcon)||f.createElement(A7,null),showAdd:l!==true});const te=V(),re=so(i),ie=xde(S,y),de=Sde(Q,C),ne={align:M?.align??Y?.indicator?.align,size:M?.size??$??Y?.indicator?.size??Y?.indicatorSize},ce=f.useMemo(()=>{const ae=P??O??void 0,pe=U==="rtl";switch(ae){case "start":return pe?"right":"left";case "end":return pe?"left":"right";default:return ae}},[P,O,U]),fe={...e,size:re,tabPlacement:ce,items:ie},[se,Me]=Kt([j,T],[W,R],{props:fe},{popup:{_default:"root"}});return f.createElement(bde,{ref:J,direction:U,getPopupContainer:G,..._,items:ie,className:X({[`${Q}-${re}`]:re,[`${Q}-card`]:["card","editable-card"].includes(n),[`${Q}-editable-card`]:n==="editable-card",[`${Q}-centered`]:u},H,r,o,se.root,L,K,D),classNames:{...se,popup:X(b,L,K,D,se.popup?.root)},styles:Me,style:{...Me.root,...z,...w},editable:ee,more:{icon:Y?.more?.icon??Y?.moreIcon??p??f.createElement(UR,null),transitionName:`${te}-slide-up`,...g},prefixCls:Q,animated:de,indicator:ne,destroyOnHidden:N??I,tabPosition:ce})}),XR=Dde;XR.TabPane=Ode;function _de(e,t){if(e==null)return {};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r];}return n}function O7(e,t){if(e==null)return {};var n,r,o=_de(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(o[n]=e[n]);}return o}function Bde(e,t,n){var r=n||{},o=r.noTrailing,i=o===void 0?false:o,a=r.noLeading,l=a===void 0?false:a,u=r.debounceMode,d=u===void 0?void 0:u,m,p=false,g=0;function b(){m&&clearTimeout(m);}function y(C){var w=C||{},$=w.upcomingOnly,M=$===void 0?false:$;b(),p=!M;}function S(){for(var C=arguments.length,w=new Array(C),$=0;$<C;$++)w[$]=arguments[$];var M=this,T=Date.now()-g;if(p)return;function R(){g=Date.now(),t.apply(M,w);}function I(){m=void 0;}!l&&d&&!m&&R(),b(),d===void 0&&T>e?l?(g=Date.now(),i||(m=setTimeout(d?I:R,e))):R():i!==true&&(m=setTimeout(d?I:R,d===void 0?e-T:e));}return S.cancel=y,S}function Lde(e,t,n){var r={},o=r.atBegin,i=o===void 0?false:o;return Bde(e,t,{debounceMode:i!==false})}const zde=e=>{const{checkboxCls:t,checkboxSize:n,lineWidth:r}=e,o=`${t}-wrapper`;return [{[`${t}-group`]:{...dn(e),display:"inline-flex",flexWrap:"wrap",columnGap:e.marginXS,[`> ${e.antCls}-row`]:{flex:1}},[o]:{...dn(e),display:"inline-flex",alignItems:"baseline",cursor:"pointer","&:after":{display:"inline-block",width:0,overflow:"hidden",content:"'\\a0'"},[`& + ${o}`]:{marginInlineStart:0},[`&${o}-in-form-item`]:{'input[type="checkbox"]':{width:14,height:14}}},[t]:{...dn(e),position:"relative",whiteSpace:"nowrap",lineHeight:1,cursor:"pointer",alignSelf:"center",boxSizing:"border-box",display:"block",width:n,height:n,direction:"ltr",backgroundColor:e.colorBgContainer,border:`${oe(r)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,borderCollapse:"separate",transition:`all ${e.motionDurationSlow}`,"&:after":{boxSizing:"border-box",position:"absolute",top:`calc(${n} / 2 - ${r})`,insetInlineStart:`calc(${n} / 4 - ${r})`,display:"table",width:e.calc(n).div(14).mul(5).equal(),height:e.calc(n).div(14).mul(8).equal(),border:`${oe(e.lineWidthBold)} solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`},[`${t}-input`]:{position:"absolute",inset:`calc(-1 * (${r}))`,zIndex:1,cursor:"pointer",opacity:0,margin:0},[`&:has(${t}-input:focus-visible)`]:ba(e),"& + span":{paddingInlineStart:e.paddingXS,paddingInlineEnd:e.paddingXS}}},{[`
${o}:not(${o}-disabled),
${t}:not(${t}-disabled)
`]:{[`&:hover ${t}`]:{borderColor:e.colorPrimary}},[`${o}:not(${o}-disabled)`]:{[`&:hover ${t}-checked:not(${t}-disabled)`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[`${t}-checked`]:{backgroundColor:e.colorPrimary,borderColor:e.colorPrimary,"&:after":{opacity:1,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`all ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`},[`&:not(${t}-disabled):hover`]:{backgroundColor:e.colorPrimaryHover,borderColor:"transparent"}}},{[t]:{"&-indeterminate":{backgroundColor:e.colorBgContainer,borderColor:e.colorBorder,"&:after":{top:"50%",insetInlineStart:"50%",width:e.calc(e.fontSizeLG).div(2).equal(),height:e.calc(e.fontSizeLG).div(2).equal(),backgroundColor:e.colorPrimary,border:0,transform:"translate(-50%, -50%) scale(1)",opacity:1,content:'""'},"&:hover":{backgroundColor:e.colorBgContainer,borderColor:e.colorPrimary}}}},{[`${o}-disabled`]:{cursor:"not-allowed"},[`${t}-disabled`]:{[`&, ${t}-input`]:{cursor:"not-allowed",pointerEvents:"none"},background:e.colorBgContainerDisabled,borderColor:e.colorBorder,"&:after":{borderColor:e.colorTextDisabled},"& + span":{color:e.colorTextDisabled},[`&${t}-indeterminate::after`]:{background:e.colorTextDisabled}}}]};function kde(e,t){const n=Ft(t,{checkboxCls:`.${e}`,checkboxSize:t.controlInteractiveSize});return zde(n)}const D7=Wt("Checkbox",(e,{prefixCls:t})=>[kde(t,e)]),_7=q.createContext(null),Fde=(e,t)=>{const{prefixCls:n,children:r,indeterminate:o=false,onMouseEnter:i,onMouseLeave:a,skipGroup:l=false,disabled:u,rootClassName:d,className:m,style:p,classNames:g,styles:b,name:y,value:S,checked:C,defaultChecked:w,onChange:$,...M}=e,{getPrefixCls:T,direction:R,className:I,style:N,classNames:P,styles:O}=jt("checkbox"),_=f.useContext(_7),{isFormItemInput:B}=f.useContext(So),V=f.useContext(no),U=(_?.disabled||u)??V,[G,H]=un(w,C);let z=G;const j=Mt(fe=>{H(fe.target.checked),$?.(fe),!l&&_?.toggleOption&&_.toggleOption({label:r,value:S});});_&&!l&&(z=_.value.includes(S));const W=f.useRef(null),Y=Bs(t,W);f.useEffect(()=>{if(!(l||!_))return _.registerValue(S),()=>{_.cancelValue(S);}},[S,l]),f.useEffect(()=>{W.current?.input&&(W.current.input.indeterminate=o);},[o]);const Q=T("checkbox",n),D=Qn(Q),[L,K]=D7(Q,D),J={...M},ee={...e,indeterminate:o,disabled:U,checked:z},[te,re]=Kt([P,g],[O,b],{props:ee}),ie=X(`${Q}-wrapper`,{[`${Q}-rtl`]:R==="rtl",[`${Q}-wrapper-checked`]:z,[`${Q}-wrapper-disabled`]:U,[`${Q}-wrapper-in-form-item`]:B},I,m,te.root,d,K,D,L),de=X(te.icon,{[`${Q}-indeterminate`]:o},n1,L),[ne,ce]=b7(J.onClick);return f.createElement(Qp,{component:"Checkbox",disabled:U},f.createElement("label",{className:ie,style:{...re.root,...N,...p},onMouseEnter:i,onMouseLeave:a,onClick:ne},f.createElement(v7,{...J,name:!l&&_?_.name:y,checked:z,onClick:ce,onChange:j,prefixCls:Q,className:de,style:re.icon,disabled:U,ref:Y,value:S}),Jr(r)&&f.createElement("span",{className:X(`${Q}-label`,te.label),style:re.label},r)))},B7=f.forwardRef(Fde),Hde=f.forwardRef((e,t)=>{const{defaultValue:n,children:r,options:o=[],prefixCls:i,className:a,rootClassName:l,style:u,onChange:d,role:m="group",...p}=e,{getPrefixCls:g,direction:b}=f.useContext(wt),[y,S]=f.useState(p.value||n||[]),[C,w]=f.useState([]);f.useEffect(()=>{"value"in p&&S(p.value||[]);},[p.value]);const $=f.useMemo(()=>o.map(H=>typeof H=="string"||typeof H=="number"?{label:H,value:H}:H),[o]),M=H=>{w(z=>z.filter(j=>j!==H));},T=H=>{w(z=>[].concat(qt(z),[H]));},R=H=>{const z=y.indexOf(H.value),j=qt(y);z===-1?j.push(H.value):j.splice(z,1),"value"in p||S(j),d?.(j.filter(W=>C.includes(W)).sort((W,Y)=>{const Q=$.findIndex(L=>L.value===W),D=$.findIndex(L=>L.value===Y);return Q-D}));},I=g("checkbox",i),N=`${I}-group`,P=Qn(I),[O,_]=D7(I,P),B=Ln(p,["value","disabled"]),V=o.length?$.map(H=>f.createElement(B7,{prefixCls:I,key:H.value.toString(),disabled:"disabled"in H?H.disabled:p.disabled,value:H.value,checked:y.includes(H.value),onChange:H.onChange,className:X(`${N}-item`,H.className),style:H.style,title:H.title,id:H.id,required:H.required},H.label)):r,U=f.useMemo(()=>({toggleOption:R,value:y,disabled:p.disabled,name:p.name,registerValue:T,cancelValue:M}),[R,y,p.disabled,p.name,T,M]),G=X(N,{[`${N}-rtl`]:b==="rtl"},a,l,_,P,O);return f.createElement("div",{className:G,style:u,role:m,...B,ref:t},f.createElement(_7.Provider,{value:U},V))}),Ki=B7;Ki.Group=Hde;Ki.__ANT_CHECKBOX=true;const Vde=e=>{const{componentCls:t}=e;return {[t]:{"&-horizontal":{[`&${t}`]:{"&-sm":{marginBlock:e.marginXS},"&-md":{marginBlock:e.margin}}}}}},jde=e=>{const{componentCls:t,sizePaddingEdgeHorizontal:n,colorSplit:r,lineWidth:o,textPaddingInline:i,orientationMargin:a,verticalMarginInline:l}=e,u=`${t}-rail`;return {[t]:{...dn(e),borderBlockStart:`${oe(o)} solid ${r}`,[u]:{borderBlockStart:`${oe(o)} solid ${r}`},"&-vertical":{position:"relative",top:"-0.06em",display:"inline-block",height:"0.9em",marginInline:l,marginBlock:0,verticalAlign:"middle",borderTop:0,borderInlineStart:`${oe(o)} solid ${r}`},"&-horizontal":{display:"flex",clear:"both",width:"100%",minWidth:"100%",margin:`${oe(e.marginLG)} 0`},[`&-horizontal${t}-with-text`]:{display:"flex",alignItems:"center",margin:`${oe(e.dividerHorizontalWithTextGutterMargin)} 0`,color:e.colorTextHeading,fontWeight:500,fontSize:e.fontSizeLG,whiteSpace:"nowrap",textAlign:"center",borderBlockStart:`0 ${r}`,[`${u}-start, ${u}-end`]:{width:"50%",borderBlockStartColor:"inherit",borderBlockEnd:0,content:"''"}},[`&-horizontal${t}-with-text-start`]:{[`${u}-start`]:{width:`calc(${a} * 100%)`},[`${u}-end`]:{width:`calc(100% - ${a} * 100%)`}},[`&-horizontal${t}-with-text-end`]:{[`${u}-start`]:{width:`calc(100% - ${a} * 100%)`},[`${u}-end`]:{width:`calc(${a} * 100%)`}},[`${t}-inner-text`]:{display:"inline-block",paddingBlock:0,paddingInline:i},"&-dashed":{background:"none",borderColor:r,borderStyle:"dashed",borderWidth:`${oe(o)} 0 0`,[u]:{borderBlockStart:`${oe(o)} dashed ${r}`}},[`&-horizontal${t}-with-text${t}-dashed`]:{[`${u}-start, ${u}-end`]:{borderStyle:"dashed none none"}},[`&-vertical${t}-dashed`]:{borderInlineStartWidth:o,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},"&-dotted":{background:"none",borderColor:r,borderStyle:"dotted",borderWidth:`${oe(o)} 0 0`,[u]:{borderBlockStart:`${oe(o)} dotted ${r}`}},[`&-horizontal${t}-with-text${t}-dotted`]:{"&::before, &::after":{borderStyle:"dotted none none"}},[`&-vertical${t}-dotted`]:{borderInlineStartWidth:o,borderInlineEnd:0,borderBlockStart:0,borderBlockEnd:0},[`&-plain${t}-with-text`]:{color:e.colorText,fontWeight:"normal",fontSize:e.fontSize},[`&-horizontal${t}-with-text-start${t}-no-default-orientation-margin-start`]:{[`${u}-start`]:{width:0},[`${u}-end`]:{width:"100%"},[`${t}-inner-text`]:{paddingInlineStart:n}},[`&-horizontal${t}-with-text-end${t}-no-default-orientation-margin-end`]:{[`${u}-start`]:{width:"100%"},[`${u}-end`]:{width:0},[`${t}-inner-text`]:{paddingInlineEnd:n}}}}},Ude=e=>({textPaddingInline:"1em",orientationMargin:.05,verticalMarginInline:e.marginXS}),Wde=Wt("Divider",e=>{const t=Ft(e,{dividerHorizontalWithTextGutterMargin:e.margin,sizePaddingEdgeHorizontal:0});return [jde(t),Vde(t)]},Ude,{unitless:{orientationMargin:true}}),Gde=["left","right","center","start","end"],qde={small:"sm",middle:"md"},Ul=e=>{const{getPrefixCls:t,direction:n,className:r,style:o,classNames:i,styles:a}=jt("divider"),{prefixCls:l,type:u,orientation:d,vertical:m,titlePlacement:p,orientationMargin:g,className:b,rootClassName:y,children:S,dashed:C,variant:w="solid",plain:$,style:M,size:T,classNames:R,styles:I,...N}=e,P=t("divider",l),O=`${P}-rail`,[_,B]=Wde(P),V=so(T),U=qde[V],G=!!S,H=Gde.includes(d||""),z=f.useMemo(()=>{const re=p??(H?d:"center");return re==="left"?n==="rtl"?"end":"start":re==="right"?n==="rtl"?"start":"end":re},[n,d,p,H]),j=z==="start"&&g!=null,W=z==="end"&&g!=null,[Y,Q]=xu(d,m,u),D={...e,orientation:Y,titlePlacement:z,size:V},[L,K]=Kt([i,R],[a,I],{props:D}),J=X(P,r,_,B,`${P}-${Y}`,{[`${P}-with-text`]:G,[`${P}-with-text-${z}`]:G,[`${P}-dashed`]:!!C,[`${P}-${w}`]:w!=="solid",[`${P}-plain`]:!!$,[`${P}-rtl`]:n==="rtl",[`${P}-no-default-orientation-margin-start`]:j,[`${P}-no-default-orientation-margin-end`]:W,[`${P}-${U}`]:!!U,[O]:!S,[L.rail]:L.rail&&!S},b,y,L.root),ee=f.useMemo(()=>typeof g=="number"?g:/^\d+$/.test(g)?Number(g):g,[g]),te={marginInlineStart:j?ee:void 0,marginInlineEnd:W?ee:void 0};return f.createElement("div",{className:J,style:{...o,...K.root,...S?{}:K.rail,...M},...N,role:"separator"},S&&!Q&&f.createElement(f.Fragment,null,f.createElement("div",{className:X(O,`${O}-start`,L.rail),style:K.rail}),f.createElement("span",{className:X(`${P}-inner-text`,L.content),style:{...te,...K.content}},S),f.createElement("div",{className:X(O,`${O}-end`,L.rail),style:K.rail})))},h8=(e,t)=>{if(!e)return null;const n={left:e.offsetLeft,right:e.parentElement.clientWidth-e.clientWidth-e.offsetLeft,width:e.clientWidth,top:e.offsetTop,bottom:e.parentElement.clientHeight-e.clientHeight-e.offsetTop,height:e.clientHeight};return t?{left:0,right:0,width:0,top:n.top,bottom:n.bottom,height:n.height}:{left:n.left,right:n.right,width:n.width,top:0,bottom:0,height:0}},Ia=e=>e!==void 0?`${e}px`:void 0;function Kde(e){const{prefixCls:t,containerRef:n,value:r,getValueIndex:o,motionName:i,onMotionStart:a,onMotionEnd:l,direction:u,vertical:d=false}=e,m=f.useRef(null),[p,g]=f.useState(r),b=N=>{const P=o(N),O=n.current?.querySelectorAll(`.${t}-item`)[P];return O?.offsetParent&&O},[y,S]=f.useState(null),[C,w]=f.useState(null);An(()=>{if(p!==r){const N=b(p),P=b(r),O=h8(N,d),_=h8(P,d);g(r),S(O),w(_),N&&P?a():l();}},[r]);const $=f.useMemo(()=>Ia(d?y?.top??0:u==="rtl"?-y?.right:y?.left),[d,u,y]),M=f.useMemo(()=>Ia(d?C?.top??0:u==="rtl"?-C?.right:C?.left),[d,u,C]),T=()=>d?{transform:"translateY(var(--thumb-start-top))",height:"var(--thumb-start-height)"}:{transform:"translateX(var(--thumb-start-left))",width:"var(--thumb-start-width)"},R=()=>d?{transform:"translateY(var(--thumb-active-top))",height:"var(--thumb-active-height)"}:{transform:"translateX(var(--thumb-active-left))",width:"var(--thumb-active-width)"},I=()=>{S(null),w(null),l();};return !y||!C?null:f.createElement(Co,{visible:true,motionName:i,motionAppear:true,onAppearStart:T,onAppearActive:R,onVisibleChanged:I},({className:N,style:P},O)=>{const _={...P,"--thumb-start-left":$,"--thumb-start-width":Ia(y?.width),"--thumb-active-left":M,"--thumb-active-width":Ia(C?.width),"--thumb-start-top":$,"--thumb-start-height":Ia(y?.height),"--thumb-active-top":M,"--thumb-active-height":Ia(C?.height)},B={ref:Vr(m,O),style:_,className:X(`${t}-thumb`,N)};return f.createElement("div",B)})}function Yde(e){if(typeof e.title<"u")return e.title;if(typeof e.label!="object")return e.label?.toString()}function Xde(e){return e.map(t=>{if(typeof t=="object"&&t!==null){const n=Yde(t);return {...t,title:n}}return {label:t?.toString(),title:t?.toString(),value:t}})}const Qde=({prefixCls:e,className:t,style:n,styles:r,classNames:o,data:i,disabled:a,checked:l,label:u,title:d,value:m,name:p,onChange:g,onFocus:b,onBlur:y,onKeyDown:S,onKeyUp:C,onMouseDown:w,itemRender:$=M=>M})=>{const M=R=>{a||g(R,m);},T=f.createElement("label",{className:X(t,{[`${e}-item-disabled`]:a}),style:n,onMouseDown:w},f.createElement("input",{name:p,className:`${e}-item-input`,type:"radio",disabled:a,checked:l,onChange:M,onFocus:b,onBlur:y,onKeyDown:S,onKeyUp:C}),f.createElement("div",{className:X(`${e}-item-label`,o?.label),title:d,style:r?.label},u));return $(T,{item:i})},Zde=f.forwardRef((e,t)=>{const{prefixCls:n="rc-segmented",direction:r,vertical:o,options:i=[],disabled:a,defaultValue:l,value:u,name:d,onChange:m,className:p="",style:g,styles:b,classNames:y,motionName:S="thumb-motion",itemRender:C,...w}=e,$=f.useRef(null),M=f.useMemo(()=>Vr($,t),[$,t]),T=f.useMemo(()=>Xde(i),[i]),[R,I]=un(l??T[0]?.value,u),[N,P]=f.useState(false),O=(L,K)=>{I(K),m?.(K);},_=Ln(w,["children"]),[B,V]=f.useState(false),[U,G]=f.useState(false),H=()=>{G(true);},z=()=>{G(false);},j=()=>{V(false);},W=L=>{L.key==="Tab"&&V(true);},Y=L=>{const K=T.findIndex(re=>re.value===R),J=T.length,ee=(K+L+J)%J,te=T[ee];te&&(I(te.value),m?.(te.value));},Q=L=>{switch(L.key){case "ArrowLeft":case "ArrowUp":Y(-1);break;case "ArrowRight":case "ArrowDown":Y(1);break}},D=L=>{const{value:K,disabled:J}=L;return f.createElement(Qde,cr({},L,{name:d,data:L,itemRender:C,key:K,prefixCls:n,className:X(L.className,`${n}-item`,y?.item,{[`${n}-item-selected`]:K===R&&!N,[`${n}-item-focused`]:U&&B&&K===R}),style:b?.item,classNames:y,styles:b,checked:K===R,onChange:O,onFocus:H,onBlur:z,onKeyDown:Q,onKeyUp:W,onMouseDown:j,disabled:!!a||!!J}))};return f.createElement("div",cr({role:"radiogroup","aria-label":"segmented control",tabIndex:a?void 0:0,"aria-orientation":o?"vertical":"horizontal",style:g},_,{className:X(n,{[`${n}-rtl`]:r==="rtl",[`${n}-disabled`]:a,[`${n}-vertical`]:o},p),ref:M}),f.createElement("div",{className:`${n}-group`},f.createElement(Kde,{vertical:o,prefixCls:n,value:R,containerRef:$,motionName:`${n}-${S}`,direction:r,getValueIndex:L=>T.findIndex(K=>K.value===L),onMotionStart:()=>{P(true);},onMotionEnd:()=>{P(false);}}),T.map(D)))}),Jde=Zde;function p8(e,t){return {[`${e}, ${e}:hover, ${e}:focus`]:{color:t.colorTextDisabled,cursor:"not-allowed"}}}function g8(e){return {background:e.itemSelectedBg,boxShadow:e.boxShadowTertiary}}const efe={overflow:"hidden",...Ga},tfe=e=>{const{componentCls:t,motionDurationSlow:n,motionEaseInOut:r,motionDurationMid:o}=e,i=e.calc(e.controlHeight).sub(e.calc(e.trackPadding).mul(2)).equal(),a=e.calc(e.controlHeightLG).sub(e.calc(e.trackPadding).mul(2)).equal(),l=e.calc(e.controlHeightSM).sub(e.calc(e.trackPadding).mul(2)).equal();return {[t]:{...dn(e),display:"inline-block",padding:e.trackPadding,color:e.itemColor,background:e.trackBg,borderRadius:e.borderRadius,transition:`all ${o}`,...$i(e),[`${t}-group`]:{position:"relative",display:"flex",alignItems:"stretch",justifyItems:"flex-start",flexDirection:"row",width:"100%"},[`&${t}-rtl`]:{direction:"rtl"},[`&${t}-vertical`]:{[`${t}-group`]:{flexDirection:"column"},[`${t}-thumb`]:{width:"100%",height:0,padding:`0 ${oe(e.paddingXXS)}`}},[`&${t}-block`]:{display:"flex"},[`&${t}-block ${t}-item`]:{flex:1,minWidth:0},[`${t}-item`]:{position:"relative",textAlign:"center",cursor:"pointer",transition:`color ${o}`,borderRadius:e.borderRadiusSM,transform:"translateZ(0)","&-selected":{...g8(e),color:e.itemSelectedColor},"&-focused":ba(e),"&::after":{content:'""',position:"absolute",zIndex:-1,width:"100%",height:"100%",top:0,insetInlineStart:0,borderRadius:"inherit",opacity:0,pointerEvents:"none",transition:["opacity","background-color"].map(u=>`${u} ${o}`).join(", ")},[`&:not(${t}-item-selected):not(${t}-item-disabled)`]:{"&:hover, &:active":{color:e.itemHoverColor},"&:hover::after":{opacity:1,backgroundColor:e.itemHoverBg},"&:active::after":{opacity:1,backgroundColor:e.itemActiveBg}},"&-label":{minHeight:i,lineHeight:oe(i),padding:`0 ${oe(e.segmentedPaddingHorizontal)}`,...efe},"&-icon + *":{marginInlineStart:e.calc(e.marginSM).div(2).equal()},"&-input":{position:"absolute",insetBlockStart:0,insetInlineStart:0,width:0,height:0,opacity:0,pointerEvents:"none"}},[`${t}-thumb`]:{...g8(e),position:"absolute",insetBlockStart:0,insetInlineStart:0,width:0,height:"100%",padding:`${oe(e.paddingXXS)} 0`,borderRadius:e.borderRadiusSM,[`& ~ ${t}-item:not(${t}-item-selected):not(${t}-item-disabled)::after`]:{backgroundColor:"transparent"}},[`&${t}-lg`]:{borderRadius:e.borderRadiusLG,[`${t}-item-label`]:{minHeight:a,lineHeight:oe(a),padding:`0 ${oe(e.segmentedPaddingHorizontal)}`,fontSize:e.fontSizeLG},[`${t}-item, ${t}-thumb`]:{borderRadius:e.borderRadius}},[`&${t}-sm`]:{borderRadius:e.borderRadiusSM,[`${t}-item-label`]:{minHeight:l,lineHeight:oe(l),padding:`0 ${oe(e.segmentedPaddingHorizontalSM)}`},[`${t}-item, ${t}-thumb`]:{borderRadius:e.borderRadiusXS}},...p8(`&-disabled ${t}-item`,e),...p8(`${t}-item-disabled`,e),[`${t}-thumb-motion-appear-active`]:{willChange:"transform, width",transition:["transform","width"].map(u=>`${u} ${n} ${r}`).join(", ")},[`&${t}-shape-round`]:{borderRadius:9999,[`${t}-item, ${t}-thumb`]:{borderRadius:9999}}}}},nfe=e=>{const{colorTextLabel:t,colorText:n,colorFillSecondary:r,colorBgElevated:o,colorFill:i,lineWidthBold:a,colorBgLayout:l}=e;return {trackPadding:a,trackBg:l,itemColor:t,itemHoverColor:n,itemHoverBg:r,itemSelectedBg:o,itemActiveBg:i,itemSelectedColor:n}},rfe=Wt("Segmented",e=>{const{lineWidth:t,calc:n}=e,r=Ft(e,{segmentedPaddingHorizontal:n(e.controlPaddingHorizontal).sub(t).equal(),segmentedPaddingHorizontalSM:n(e.controlPaddingHorizontalSM).sub(t).equal()});return tfe(r)},nfe);function ofe(e){return typeof e=="object"&&!!e?.icon}const ife=f.forwardRef((e,t)=>{const n=zs(),{prefixCls:r,className:o,rootClassName:i,block:a,options:l=[],size:u="middle",style:d,vertical:m,orientation:p,shape:g="default",name:b=n,styles:y,classNames:S,...C}=e,{getPrefixCls:w,direction:$,className:M,style:T,classNames:R,styles:I}=jt("segmented"),N={...e,options:l,size:u,shape:g},[P,O]=Kt([R,S],[I,y],{props:N}),_=w("segmented",r),[B,V]=rfe(_),U=so(u),G=f.useMemo(()=>l.map(Y=>{if(ofe(Y)){const{icon:Q,label:D,...L}=Y;return {...L,label:f.createElement(f.Fragment,null,f.createElement("span",{className:X(`${_}-item-icon`,P.icon),style:O.icon},Q),D&&f.createElement("span",null,D))}}return Y}),[l,_,P.icon,O.icon]),[,H]=xu(p,m),z=X(o,i,M,P.root,{[`${_}-block`]:a,[`${_}-sm`]:U==="small",[`${_}-lg`]:U==="large",[`${_}-vertical`]:H,[`${_}-shape-${g}`]:g==="round"},B,V),j={...O.root,...T,...d},W=(Y,{item:Q})=>{if(!Q.tooltip)return Y;const D=typeof Q.tooltip=="object"?Q.tooltip:{title:Q.tooltip};return f.createElement(Jl,{...D},Y)};return f.createElement(Jde,{...C,name:b,className:z,style:j,classNames:P,styles:O,itemRender:W,options:G,ref:t,prefixCls:_,direction:$,vertical:H})}),QR=ife,L7=q.createContext({}),z7=q.createContext({}),k7=({prefixCls:e,value:t,onChange:n,className:r,style:o})=>{const i=()=>{if(n&&t&&!t.cleared){const a=t.toHsb();a.a=0;const l=ro(a);l.cleared=true,n(l);}};return q.createElement("div",{className:X(`${e}-clear`,r),style:o,onClick:i})},F7="hex",H7="rgb",V7="hsb";var afe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M872 474H152c-4.4 0-8 3.6-8 8v60c0 4.4 3.6 8 8 8h720c4.4 0 8-3.6 8-8v-60c0-4.4-3.6-8-8-8z"}}]},name:"minus",theme:"outlined"};function VE(){return VE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},VE.apply(this,arguments)}const sfe=(e,t)=>f.createElement(Xn,VE({},e,{ref:t,icon:afe})),lfe=f.forwardRef(sfe);var cfe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z"}}]},name:"up",theme:"outlined"};function jE(){return jE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},jE.apply(this,arguments)}const ufe=(e,t)=>f.createElement(Xn,jE({},e,{ref:t,icon:cfe})),dfe=f.forwardRef(ufe);function UE(){return typeof BigInt=="function"}function j7(e){return !e&&e!==0&&!Number.isNaN(e)||!String(e).trim()}function Xc(e){var t=e.trim(),n=t.startsWith("-");n&&(t=t.slice(1)),t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,""),t.startsWith(".")&&(t="0".concat(t));var r=t||"0",o=r.split("."),i=o[0]||"0",a=o[1]||"0";i==="0"&&a==="0"&&(n=false);var l=n?"-":"";return {negative:n,negativeStr:l,trimStr:r,integerStr:i,decimalStr:a,fullStr:"".concat(l).concat(r)}}function ZR(e){var t=String(e);return !Number.isNaN(Number(t))&&t.includes("e")}function Vc(e){var t=String(e);if(ZR(e)){var n=Number(t.slice(t.indexOf("e-")+2)),r=t.match(/\.(\d+)/);return r!=null&&r[1]&&(n+=r[1].length),n}return t.includes(".")&&JR(t)?t.length-t.indexOf(".")-1:0}function g1(e){var t=String(e);if(ZR(e)){if(e>Number.MAX_SAFE_INTEGER)return String(UE()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(e<Number.MIN_SAFE_INTEGER)return String(UE()?BigInt(e).toString():Number.MIN_SAFE_INTEGER);t=e.toFixed(Vc(t));}return Xc(t).fullStr}function JR(e){return typeof e=="number"?!Number.isNaN(e):e?/^\s*-?\d+(\.\d+)?\s*$/.test(e)||/^\s*-?\d+\.\s*$/.test(e)||/^\s*-?\.\d+\s*$/.test(e):false}var ffe=(function(){function e(t){if(Xi(this,e),Ct(this,"origin",""),Ct(this,"negative",void 0),Ct(this,"integer",void 0),Ct(this,"decimal",void 0),Ct(this,"decimalLen",void 0),Ct(this,"empty",void 0),Ct(this,"nan",void 0),j7(t)){this.empty=true;return}if(this.origin=String(t),t==="-"||Number.isNaN(t)){this.nan=true;return}var n=t;if(ZR(n)&&(n=Number(n)),n=typeof n=="string"?n:g1(n),JR(n)){var r=Xc(n);this.negative=r.negative;var o=r.trimStr.split(".");this.integer=BigInt(o[0]);var i=o[1]||"0";this.decimal=BigInt(i),this.decimalLen=i.length;}else this.nan=true;}return Qi(e,[{key:"getMark",value:function(){return this.negative?"-":""}},{key:"getIntegerStr",value:function(){return this.integer.toString()}},{key:"getDecimalStr",value:function(){return this.decimal.toString().padStart(this.decimalLen,"0")}},{key:"alignDecimal",value:function(n){var r="".concat(this.getMark()).concat(this.getIntegerStr()).concat(this.getDecimalStr().padEnd(n,"0"));return BigInt(r)}},{key:"negate",value:function(){var n=new e(this.toString());return n.negative=!n.negative,n}},{key:"cal",value:function(n,r,o){var i=Math.max(this.getDecimalStr().length,n.getDecimalStr().length),a=this.alignDecimal(i),l=n.alignDecimal(i),u=r(a,l).toString(),d=o(i),m=Xc(u),p=m.negativeStr,g=m.trimStr,b="".concat(p).concat(g.padStart(d+1,"0"));return new e("".concat(b.slice(0,-d),".").concat(b.slice(-d)))}},{key:"add",value:function(n){if(this.isInvalidate())return new e(n);var r=new e(n);return r.isInvalidate()?this:this.cal(r,function(o,i){return o+i},function(o){return o})}},{key:"multi",value:function(n){var r=new e(n);return this.isInvalidate()||r.isInvalidate()?new e(NaN):this.cal(r,function(o,i){return o*i},function(o){return o*2})}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return this.nan}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(n){return this.toString()===n?.toString()}},{key:"lessEquals",value:function(n){return this.add(n.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:true;return n?this.isInvalidate()?"":Xc("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e})(),mfe=(function(){function e(t){if(Xi(this,e),Ct(this,"origin",""),Ct(this,"number",void 0),Ct(this,"empty",void 0),j7(t)){this.empty=true;return}this.origin=String(t),this.number=Number(t);}return Qi(e,[{key:"negate",value:function(){return new e(-this.toNumber())}},{key:"add",value:function(n){if(this.isInvalidate())return new e(n);var r=Number(n);if(Number.isNaN(r))return this;var o=this.number+r;if(o>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(o<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var i=Math.max(Vc(this.number),Vc(r));return new e(o.toFixed(i))}},{key:"multi",value:function(n){var r=Number(n);if(this.isInvalidate()||Number.isNaN(r))return new e(NaN);var o=this.number*r;if(o>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(o<Number.MIN_SAFE_INTEGER)return new e(Number.MIN_SAFE_INTEGER);var i=Math.max(Vc(this.number),Vc(r));return new e(o.toFixed(i))}},{key:"isEmpty",value:function(){return this.empty}},{key:"isNaN",value:function(){return Number.isNaN(this.number)}},{key:"isInvalidate",value:function(){return this.isEmpty()||this.isNaN()}},{key:"equals",value:function(n){return this.toNumber()===n?.toNumber()}},{key:"lessEquals",value:function(n){return this.add(n.negate().toString()).toNumber()<=0}},{key:"toNumber",value:function(){return this.number}},{key:"toString",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:true;return n?this.isInvalidate()?"":g1(this.number):this.origin}}]),e})();function oa(e){return UE()?new ffe(e):new mfe(e)}function Xb(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:false;if(e==="")return "";var o=Xc(e),i=o.negativeStr,a=o.integerStr,l=o.decimalStr,u="".concat(t).concat(l),d="".concat(i).concat(a);if(n>=0){var m=Number(l[n]);if(m>=5&&!r){var p=oa(e).add("".concat(i,"0.").concat("0".repeat(n)).concat(10-m));return Xb(p.toString(),t,n,r)}return n===0?d:"".concat(d).concat(t).concat(l.padEnd(n,"0").slice(0,n))}return u===".0"?d:"".concat(d).concat(u)}function hfe(e,t){return typeof Proxy<"u"&&e?new Proxy(e,{get(n,r){if(t[r])return t[r];const o=n[r];return typeof o=="function"?o.bind(n):o}}):e}function pfe(e,t){const n=f.useRef(null);function r(){try{const{selectionStart:i,selectionEnd:a,value:l}=e,u=l.substring(0,i),d=l.substring(a);n.current={start:i,end:a,value:l,beforeTxt:u,afterTxt:d};}catch{}}function o(){if(e&&n.current&&t)try{const{value:i}=e,{beforeTxt:a,afterTxt:l,start:u}=n.current;let d=i.length;if(i.startsWith(a))d=a.length;else if(i.endsWith(l))d=i.length-n.current.afterTxt.length;else {const m=a[u-1],p=i.indexOf(m,u-1);p!==-1&&(d=p+1);}e.setSelectionRange(d,d);}catch(i){Er(false,`Something warning of cursor restore. Please fire issue about this: ${i.message}`);}}return [r,o]}const gfe=200,vfe=600;function v8({prefixCls:e,action:t,children:n,disabled:r,className:o,style:i,onStep:a}){const l=t==="up",u=f.useRef(),d=f.useRef([]),m=()=>{clearTimeout(u.current);},p=S=>{S.preventDefault(),m(),a(l,"handler");function C(){a(l,"handler"),u.current=setTimeout(C,gfe);}u.current=setTimeout(C,vfe);};f.useEffect(()=>()=>{m(),d.current.forEach(S=>{Lt.cancel(S);});},[]);const g=`${e}-action`,b=X(g,`${g}-${t}`,{[`${g}-${t}-disabled`]:r},o),y=()=>d.current.push(Lt(m));return f.createElement("span",{unselectable:"on",role:"button",onMouseUp:y,onMouseLeave:y,onMouseDown:S=>{p(S);},"aria-label":l?"Increase Value":"Decrease Value","aria-disabled":r,className:b,style:i},n||f.createElement("span",{unselectable:"on",className:`${e}-action-${t}-inner`}))}function b8(e){const t=typeof e=="number"?g1(e):Xc(e).fullStr;return t.includes(".")?Xc(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}const bfe=(()=>{const e=f.useRef(0),t=()=>{Lt.cancel(e.current);};return f.useEffect(()=>t,[]),n=>{t(),e.current=Lt(()=>{n();});}});function Lh(){return Lh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},Lh.apply(this,arguments)}const y8=(e,t)=>e||t.isEmpty()?t.toString():t.toNumber(),S8=e=>{const t=oa(e);return t.isInvalidate()?null:t},yfe=f.forwardRef((e,t)=>{const{mode:n="input",prefixCls:r="rc-input-number",className:o,style:i,classNames:a,styles:l,min:u,max:d,step:m=1,defaultValue:p,value:g,disabled:b,readOnly:y,upHandler:S,downHandler:C,keyboard:w,changeOnWheel:$=false,controls:M=true,prefix:T,suffix:R,stringMode:I,parser:N,formatter:P,precision:O,decimalSeparator:_,onChange:B,onInput:V,onPressEnter:U,onStep:G,onMouseDown:H,onClick:z,onMouseUp:j,onMouseLeave:W,onMouseMove:Y,onMouseEnter:Q,onMouseOut:D,changeOnBlur:L=true,...K}=e,[J,ee]=f.useState(false),te=f.useRef(false),re=f.useRef(false),ie=f.useRef(false),de=f.useRef(null),ne=f.useRef(null);f.useImperativeHandle(t,()=>hfe(ne.current,{focus:Fe=>{xR(ne.current,Fe);},blur:()=>{ne.current?.blur();},nativeElement:de.current}));const[ce,fe]=f.useState(()=>oa(g??p));function se(Fe){g===void 0&&fe(Fe);}const Me=f.useCallback((Fe,Qe)=>{if(!Qe)return O>=0?O:Math.max(Vc(Fe),Vc(m))},[O,m]),ae=f.useCallback(Fe=>{const Qe=String(Fe);if(N)return N(Qe);let ye=Qe;return _&&(ye=ye.replace(_,".")),ye.replace(/[^\w.-]+/g,"")},[N,_]),pe=f.useRef(""),Ce=f.useCallback((Fe,Qe)=>{if(P)return P(Fe,{userTyping:Qe,input:String(pe.current)});let ye=typeof Fe=="number"?g1(Fe):Fe;if(!Qe){const be=Me(ye,Qe);JR(ye)&&(_||be>=0)&&(ye=Xb(ye,_||".",be));}return ye},[P,Me,_]),[xe,Ae]=f.useState(()=>{const Fe=p??g;return ce.isInvalidate()&&["string","number"].includes(typeof Fe)?Number.isNaN(Fe)?"":Fe:Ce(ce.toString(),false)});pe.current=xe;function Xe(Fe,Qe){Ae(Ce(Fe.isInvalidate()?Fe.toString(false):Fe.toString(!Qe),Qe));}const Ne=f.useMemo(()=>S8(d),[d,O]),ue=f.useMemo(()=>S8(u),[u,O]),ge=f.useMemo(()=>!Ne||!ce||ce.isInvalidate()?false:Ne.lessEquals(ce),[Ne,ce]),Pe=f.useMemo(()=>!ue||!ce||ce.isInvalidate()?false:ce.lessEquals(ue),[ue,ce]),[je,qe]=pfe(ne.current,J),Ue=Fe=>Ne&&!Fe.lessEquals(Ne)?Ne:ue&&!ue.lessEquals(Fe)?ue:null,et=Fe=>!Ue(Fe),rt=(Fe,Qe)=>{let ye=Fe,be=et(ye)||ye.isEmpty();if(!ye.isEmpty()&&!Qe&&(ye=Ue(ye)||ye,be=true),!y&&!b&&be){const Se=ye.toString(),he=Me(Se,Qe);return he>=0&&(ye=oa(Xb(Se,".",he)),et(ye)||(ye=oa(Xb(Se,".",he,true)))),ye.equals(ce)||(se(ye),B?.(ye.isEmpty()?null:y8(I,ye)),g===void 0&&Xe(ye,Qe)),ye}return ce},Ke=bfe(),_e=Fe=>{if(je(),pe.current=Fe,Ae(Fe),!re.current){const Qe=ae(Fe),ye=oa(Qe);ye.isNaN()||rt(ye,true);}V?.(Fe),Ke(()=>{let Qe=Fe;N||(Qe=Fe.replace(/。/g,".")),Qe!==Fe&&_e(Qe);});},We=()=>{re.current=true;},Ze=()=>{re.current=false,_e(ne.current.value);},Be=Fe=>{_e(Fe.target.value);},Oe=Mt((Fe,Qe)=>{if(Fe&&ge||!Fe&&Pe)return;te.current=false;let ye=oa(ie.current?b8(m):m);Fe||(ye=ye.negate());const be=(ce||oa(0)).add(ye.toString()),Se=rt(be,false);G?.(y8(I,Se),{offset:ie.current?b8(m):m,type:Fe?"up":"down",emitter:Qe}),ne.current?.focus();}),lt=Fe=>{const Qe=oa(ae(xe));let ye;Qe.isNaN()?ye=rt(ce,Fe):ye=rt(Qe,Fe),g!==void 0?Xe(ce,false):ye.isNaN()||Xe(ye,false);},It=()=>{te.current=true;},mt=Fe=>{const{key:Qe,shiftKey:ye}=Fe;te.current=true,ie.current=ye,Qe==="Enter"&&(re.current||(te.current=false),lt(false),U?.(Fe)),w!==false&&!re.current&&["Up","ArrowUp","Down","ArrowDown"].includes(Qe)&&(Oe(Qe==="Up"||Qe==="ArrowUp","keyboard"),Fe.preventDefault());},Bt=()=>{te.current=false,ie.current=false;};f.useEffect(()=>{if($&&J){const Fe=ye=>{Oe(ye.deltaY<0,"wheel"),ye.preventDefault();},Qe=ne.current;if(Qe)return Qe.addEventListener("wheel",Fe,{passive:false}),()=>Qe.removeEventListener("wheel",Fe)}});const xt=()=>{L&<(false),ee(false),te.current=false;},Tt=Fe=>{ne.current&&Fe.target!==ne.current&&(ne.current.focus(),Fe.preventDefault()),H?.(Fe);};Bb(()=>{ce.isInvalidate()||Xe(ce,false);},[O,P]),Bb(()=>{const Fe=oa(g);fe(Fe);const Qe=oa(ae(xe));(!Fe.equals(Qe)||!te.current||P)&&Xe(Fe,te.current);},[g]),Bb(()=>{P&&qe();},[xe]);const ut={prefixCls:r,onStep:Oe,className:a?.action,style:l?.action},dt=f.createElement(v8,Lh({},ut,{action:"up",disabled:ge}),S),gt=f.createElement(v8,Lh({},ut,{action:"down",disabled:Pe}),C);return f.createElement("div",{ref:de,className:X(r,`${r}-mode-${n}`,o,a?.root,{[`${r}-focused`]:J,[`${r}-disabled`]:b,[`${r}-readonly`]:y,[`${r}-not-a-number`]:ce.isNaN(),[`${r}-out-of-range`]:!ce.isInvalidate()&&!et(ce)}),style:{...l?.root,...i},onMouseDown:Tt,onMouseUp:j,onMouseLeave:W,onMouseMove:Y,onMouseEnter:Q,onMouseOut:D,onClick:z,onFocus:()=>{ee(true);},onBlur:xt,onKeyDown:mt,onKeyUp:Bt,onCompositionStart:We,onCompositionEnd:Ze,onBeforeInput:It},n==="spinner"&&M&>,T!==void 0&&f.createElement("div",{className:X(`${r}-prefix`,a?.prefix),style:l?.prefix},T),f.createElement("input",Lh({autoComplete:"off",role:"spinbutton","aria-valuemin":u,"aria-valuemax":d,"aria-valuenow":ce.isInvalidate()?null:ce.toString(),step:m,ref:ne,className:X(`${r}-input`,a?.input),style:l?.input,value:xe,onChange:Be,disabled:b,readOnly:y},K)),R!==void 0&&f.createElement("div",{className:X(`${r}-suffix`,a?.suffix),style:l?.suffix},R),n==="spinner"&&M&&dt,n==="input"&&M&&f.createElement("div",{className:X(`${r}-actions`,a?.actions),style:l?.actions},dt,gt))}),Sfe=e=>{const{componentCls:t,borderRadius:n,paddingSM:r,colorBorder:o,paddingXS:i,fontSizeLG:a,fontSizeSM:l,borderRadiusLG:u,borderRadiusSM:d,colorBgContainerDisabled:m,lineWidth:p,antCls:g}=e,[b,y]=tr(g,"space");return {[t]:[{display:"inline-flex",alignItems:"center",gap:0,paddingInline:r,margin:0,borderWidth:p,borderStyle:"solid",borderRadius:n,"&:hover":{zIndex:0},[`&${t}-disabled`]:{color:e.colorTextDisabled},"&-large":{fontSize:a,borderRadius:u},"&-small":{paddingInline:i,borderRadius:d,fontSize:l},"&-compact-last-item":{borderEndStartRadius:0,borderStartStartRadius:0},"&-compact-first-item":{borderEndEndRadius:0,borderStartEndRadius:0},"&-compact-item:not(:first-child):not(:last-child)":{borderRadius:0},"&-compact-item:not(:last-child)":{borderInlineEndWidth:0},"&-compact-item:not(:first-child)":{borderInlineStartWidth:0}},{[b("addon-border-color")]:o,[b("addon-background")]:m,[b("addon-border-color-outlined")]:o,[b("addon-background-filled")]:m,borderColor:y("addon-border-color"),background:y("addon-background"),"&-variant-outlined":{[b("addon-border-color")]:y("addon-border-color-outlined")},"&-variant-filled":{[b("addon-border-color")]:"transparent",[b("addon-background")]:y("addon-background-filled"),[`&${t}-disabled`]:{[b("addon-border-color")]:o,[b("addon-background")]:m}},"&-variant-borderless":{border:"none",background:"transparent"},"&-variant-underlined":{border:"none",background:"transparent"}},{"&-status-error":{[b("addon-border-color-outlined")]:e.colorError,[b("addon-background-filled")]:e.colorErrorBg,color:e.colorError},"&-status-warning":{[b("addon-border-color-outlined")]:e.colorWarning,[b("addon-background-filled")]:e.colorWarningBg,color:e.colorWarning}}]}},Cfe=Wt(["Space","Addon"],e=>[Sfe(e),If(e,{focus:false})]),U7=q.forwardRef((e,t)=>{const{className:n,children:r,style:o,prefixCls:i,variant:a="outlined",disabled:l,status:u,...d}=e,{getPrefixCls:m,direction:p}=q.useContext(wt),g=m("space-addon",i),[b,y]=Cfe(g),{compactItemClassnames:S,compactSize:C}=ks(g,p),w=jl(g,u),$=X(g,b,S,y,`${g}-variant-${a}`,w,{[`${g}-${C}`]:C,[`${g}-disabled`]:l},n);return q.createElement("div",{ref:t,className:$,style:o,...d},r)}),xfe=e=>{const t=e.handleVisible??"auto",n=e.controlHeightSM-e.lineWidth*2;return {...zf(e),controlWidth:90,handleWidth:n,handleFontSize:e.fontSize/2,handleVisible:t,handleActiveBg:e.colorFillAlter,handleBg:e.colorBgContainer,filledHandleBg:new cn(e.colorFillSecondary).onBackground(e.colorBgContainer).toHexString(),handleHoverColor:e.colorPrimary,handleBorderColor:e.colorBorder,handleOpacity:t===true?1:0,handleVisibleWidth:t===true?n:0}},wfe=e=>{const{componentCls:t,lineWidth:n,lineType:r,borderRadius:o,inputFontSizeSM:i,inputFontSizeLG:a,colorError:l,paddingInlineSM:u,paddingBlockSM:d,paddingBlockLG:m,paddingInlineLG:p,colorIcon:g,motionDurationMid:b,handleHoverColor:y,handleOpacity:S,paddingInline:C,paddingBlock:w,handleBg:$,handleActiveBg:M,inputAffixPadding:T,borderRadiusSM:R,controlWidth:I,handleBorderColor:N,filledHandleBg:P,lineHeightLG:O,antCls:_}=e,B=`${oe(n)} ${r} ${N}`,[V,U]=tr(_,"input-number");return [{[t]:{...dn(e),...p1(e),[V("input-padding-block")]:oe(w),[V("input-padding-inline")]:oe(C),display:"inline-flex",width:I,margin:0,paddingBlock:0,borderRadius:o,...S7(e,{[`${t}-actions`]:{background:$,[`${t}-action-down`]:{borderBlockStart:B}}}),...w7(e,{[`${t}-actions`]:{background:P,[`${t}-action-down`]:{borderBlockStart:B}},"&:focus-within":{[`${t}-actions`]:{background:$}}}),...E7(e,{[`${t}-actions`]:{background:$,[`${t}-action-down`]:{borderBlockStart:B}}}),...C7(e),"&-rtl":{direction:"rtl",[`${t}-input`]:{direction:"rtl"}},[`&${t}-out-of-range`]:{[`${t}-input`]:{color:l}},[`${t}-input`]:{...dn(e),width:"100%",paddingBlock:U("input-padding-block"),textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:o,outline:0,transition:`all ${b} linear`,appearance:"textfield",fontSize:"inherit",lineHeight:"inherit",...M7(e.colorTextPlaceholder),'&[type="number"]::-webkit-inner-spin-button, &[type="number"]::-webkit-outer-spin-button':{margin:0,appearance:"none"}},[`&:hover ${t}-handler-wrap, &-focused ${t}-handler-wrap`]:{width:e.handleWidth,opacity:1},[`&-disabled ${t}-input`]:{cursor:"not-allowed",color:e.colorTextDisabled}}},{[t]:{[`
${t}-action-up-disabled,
${t}-action-down-disabled
`]:{cursor:"not-allowed"},[`${t}-action`]:{...Cu(),userSelect:"none",overflow:"hidden",fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",transition:`all ${b} linear`,"&:active":{background:M},"&:hover":{color:y}},"&-mode-input":{overflow:"hidden",[`${t}-actions`]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleVisibleWidth,opacity:S,height:"100%",borderRadius:0,display:"flex",flexDirection:"column",alignItems:"stretch",transition:`all ${b}`,overflow:"hidden",[`${t}-action`]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",marginInlineEnd:0,fontSize:e.handleFontSize}},[`&:hover ${t}-actions, &-focused ${t}-actions`]:{width:e.handleWidth,opacity:1},[`${t}-action`]:{color:g,height:"50%",borderInlineStart:B,"&:hover":{height:"60%"}},[`&${t}-disabled, &${t}-readonly`]:{[`${t}-actions`]:{display:"none"}}},[`&${t}-mode-spinner`]:{padding:0,width:"auto",[`${t}-action`]:{flex:"none",paddingInline:U("input-padding-inline"),"&-up":{borderInlineStart:B},"&-down":{borderInlineEnd:B}},[`${t}-input`]:{textAlign:"center",paddingInline:U("input-padding-inline")}}}},{[t]:{"&-lg":{[V("input-padding-block")]:oe(m),[V("input-padding-inline")]:oe(p),paddingBlock:0,fontSize:a,lineHeight:O},"&-sm":{[V("input-padding-block")]:oe(d),[V("input-padding-inline")]:oe(u),paddingBlock:0,fontSize:i,borderRadius:R}}},{[t]:{[`${t}-prefix, ${t}-suffix`]:{display:"flex",flex:"none",alignItems:"center",alignSelf:"center",pointerEvents:"none"},[`${t}-prefix`]:{marginInlineEnd:T},[`${t}-suffix`]:{height:"100%",marginInlineStart:T,transition:`margin ${b}`},[`&:hover:not(${t}-without-controls)`]:{[`${t}-suffix`]:{marginInlineEnd:e.handleWidth}}}}]},$fe=e=>{const{componentCls:t,antCls:n}=e;return {[`${t}-addon`]:{[`&:has(${n}-select)`]:{border:0,padding:0}}}},Efe=Wt("InputNumber",e=>{const t=Ft(e,Lf(e));return [wfe(t),$fe(t),If(t)]},xfe,{unitless:{handleOpacity:true},resetFont:false}),Mfe=f.forwardRef((e,t)=>{const n=f.useRef(null);f.useImperativeHandle(t,()=>n.current);const{rootClassName:r,size:o,disabled:i,prefixCls:a,addonBefore:l,addonAfter:u,prefix:d,suffix:m,bordered:p,readOnly:g,status:b,controls:y=true,variant:S,className:C,style:w,classNames:$,styles:M,mode:T,...R}=e,{direction:I,className:N,style:P,styles:O,classNames:_}=jt("inputNumber"),B=f.useContext(no),V=i??B,U=f.useMemo(()=>!y||V||g?false:y,[y,V,g]),{compactSize:G,compactItemClassnames:H}=ks(a,I);let z=T==="spinner"?f.createElement(A7,null):f.createElement(dfe,null),j=T==="spinner"?f.createElement(lfe,null):f.createElement(OR,null);const W=typeof U=="boolean"?U:void 0;typeof U=="object"&&(z=U.upIcon||z,j=U.downIcon||j);const{hasFeedback:Y,isFormItemInput:Q,feedbackIcon:D}=f.useContext(So),L=so(de=>o??G??de),[K,J]=a1("inputNumber",S,p),ee=Y&&f.createElement(f.Fragment,null,D),te={...e,size:L,disabled:V,controls:U},[re,ie]=Kt([_,$],[O,M],{props:te});return f.createElement(yfe,{ref:n,mode:T,disabled:V,className:X(C,r,re.root,N,H,jl(a,b,Y),{[`${a}-${K}`]:J,[`${a}-lg`]:L==="large",[`${a}-sm`]:L==="small",[`${a}-rtl`]:I==="rtl",[`${a}-in-form-item`]:Q,[`${a}-without-controls`]:!U}),style:{...ie.root,...P,...w},upHandler:z,downHandler:j,prefixCls:a,readOnly:g,controls:W,prefix:d,suffix:ee||m,classNames:re,styles:ie,...R})}),W7=f.forwardRef((e,t)=>{const{addonBefore:n,addonAfter:r,prefixCls:o,className:i,status:a,rootClassName:l,...u}=e,{getPrefixCls:d}=jt("inputNumber"),m=d("input-number",o),{status:p}=f.useContext(So),g=Df(p,a),b=Qn(m),[y,S]=Efe(m,b),C=n||r,w=f.createElement(Mfe,{ref:t,...u,prefixCls:m,status:g,className:X(S,b,y,i),rootClassName:C?void 0:l});if(C){const $=R=>R?f.createElement(U7,{className:X(`${m}-addon`,S,y),variant:e.variant,disabled:e.disabled,status:g},f.createElement(Vl,{form:true},R)):null,M=$(n),T=$(r);return f.createElement(lR,{rootClassName:l},M,w,T)}return w}),Qc=W7,Rfe=e=>f.createElement(Do,{theme:{components:{InputNumber:{handleVisible:true}}}},f.createElement(W7,{...e}));Qc._InternalPanelDoNotUseOrYouWillBeFired=Rfe;const Zc=({prefixCls:e,min:t=0,max:n=100,value:r,onChange:o,className:i,formatter:a})=>{const l=`${e}-steppers`,[u,d]=f.useState(0),m=Number.isNaN(r)?u:r;return q.createElement(Qc,{className:X(l,i),min:t,max:n,value:m,formatter:a,size:"small",onChange:p=>{d(p||0),o?.(p);}})},Tfe=({prefixCls:e,value:t,onChange:n})=>{const r=`${e}-alpha-input`,[o,i]=f.useState(()=>ro(t||"#000")),a=t||o,l=u=>{const d=a.toHsb();d.a=(u||0)/100;const m=ro(d);i(m),n?.(m);};return q.createElement(Zc,{value:vR(a),prefixCls:e,formatter:u=>`${u}%`,className:r,onChange:l})};function Afe(e){return !!(e.addonBefore||e.addonAfter)}function Nfe(e){return !!(e.prefix||e.suffix||e.allowClear)}function C8(e,t,n){const r=t.cloneNode(true),o=Object.create(e,{target:{value:r},currentTarget:{value:r}});return r.value=n,typeof t.selectionStart=="number"&&typeof t.selectionEnd=="number"&&(r.selectionStart=t.selectionStart,r.selectionEnd=t.selectionEnd),r.setSelectionRange=(...i)=>{t.setSelectionRange(...i);},o}function Z0(e,t,n,r){if(!n)return;let o=t;if(t.type==="click"){o=C8(t,e,""),n(o);return}if(e.type!=="file"&&r!==void 0){o=C8(t,e,r),n(o);return}n(o);}function WE(){return WE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},WE.apply(this,arguments)}const G7=q.forwardRef((e,t)=>{const{inputElement:n,children:r,prefixCls:o,prefix:i,suffix:a,addonBefore:l,addonAfter:u,className:d,style:m,disabled:p,readOnly:g,focused:b,triggerFocus:y,allowClear:S,value:C,handleReset:w,hidden:$,classes:M,classNames:T,dataAttrs:R,styles:I,components:N,onClear:P}=e,O=r??n,_=N?.affixWrapper||"span",B=N?.groupWrapper||"span",V=N?.wrapper||"span",U=N?.groupAddon||"span",G=f.useRef(null),H=Y=>{G.current?.contains(Y.target)&&y?.();},z=Nfe(e);let j=f.cloneElement(O,{value:C,className:X(O.props?.className,!z&&T?.variant)||null});const W=f.useRef(null);if(q.useImperativeHandle(t,()=>({nativeElement:W.current||G.current})),z){let Y=null;if(S){const K=!p&&!g&&C,J=`${o}-clear-icon`,ee=typeof S=="object"&&S?.clearIcon?S.clearIcon:"✖";Y=q.createElement("button",{type:"button",tabIndex:-1,onClick:te=>{w?.(te),P?.();},onMouseDown:te=>te.preventDefault(),className:X(J,{[`${J}-hidden`]:!K,[`${J}-has-suffix`]:!!a})},ee);}const Q=`${o}-affix-wrapper`,D=X(Q,{[`${o}-disabled`]:p,[`${Q}-disabled`]:p,[`${Q}-focused`]:b,[`${Q}-readonly`]:g,[`${Q}-input-with-clear-btn`]:a&&S&&C},M?.affixWrapper,T?.affixWrapper,T?.variant),L=(a||S)&&q.createElement("span",{className:X(`${o}-suffix`,T?.suffix),style:I?.suffix},Y,a);j=q.createElement(_,WE({className:D,style:I?.affixWrapper,onClick:H},R?.affixWrapper,{ref:G}),i&&q.createElement("span",{className:X(`${o}-prefix`,T?.prefix),style:I?.prefix},i),j,L);}if(Afe(e)){const Y=`${o}-group`,Q=`${Y}-addon`,D=`${Y}-wrapper`,L=X(`${o}-wrapper`,Y,M?.wrapper,T?.wrapper),K=X(D,{[`${D}-disabled`]:p},M?.group,T?.groupWrapper);j=q.createElement(B,{className:K,ref:W},q.createElement(V,{className:L},l&&q.createElement(U,{className:Q},l),j,u&&q.createElement(U,{className:Q},u)));}return q.cloneElement(j,{className:X(j.props?.className,d)||null,style:{...j.props?.style,...m},hidden:$})});function q7(e,t){return f.useMemo(()=>{let n={};t&&(n.show=typeof t=="object"&&t.formatter?t.formatter:!!t),n={...n,...e};const{show:r,...o}=n;return {...o,show:!!r,showFormatter:typeof r=="function"?r:void 0,strategy:o.strategy||(i=>i.length)}},[e,t])}function J0(){return J0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},J0.apply(this,arguments)}const Pfe=f.forwardRef((e,t)=>{const{autoComplete:n,onChange:r,onFocus:o,onBlur:i,onPressEnter:a,onKeyDown:l,onKeyUp:u,prefixCls:d="rc-input",disabled:m,htmlSize:p,className:g,maxLength:b,suffix:y,showCount:S,count:C,type:w="text",classes:$,classNames:M,styles:T,onCompositionStart:R,onCompositionEnd:I,...N}=e,[P,O]=f.useState(false),_=f.useRef(false),B=f.useRef(false),V=f.useRef(null),U=f.useRef(null),G=ae=>{V.current&&xR(V.current,ae);},[H,z]=un(e.defaultValue,e.value),j=H==null?"":String(H),[W,Y]=f.useState(null),Q=q7(C,S),D=Q.max||b,L=Q.strategy(j),K=!!D&&L>D;f.useImperativeHandle(t,()=>({focus:G,blur:()=>{V.current?.blur();},setSelectionRange:(ae,pe,Ce)=>{V.current?.setSelectionRange(ae,pe,Ce);},select:()=>{V.current?.select();},input:V.current,nativeElement:U.current?.nativeElement||V.current})),f.useEffect(()=>{B.current&&(B.current=false),O(ae=>ae&&m?false:ae);},[m]);const J=(ae,pe,Ce)=>{let xe=pe;if(!_.current&&Q.exceedFormatter&&Q.max&&Q.strategy(pe)>Q.max)xe=Q.exceedFormatter(pe,{max:Q.max}),pe!==xe&&Y([V.current?.selectionStart||0,V.current?.selectionEnd||0]);else if(Ce.source==="compositionEnd")return;z(xe),V.current&&Z0(V.current,ae,r,xe);};f.useEffect(()=>{W&&V.current?.setSelectionRange(...W);},[W]);const ee=ae=>{J(ae,ae.target.value,{source:"change"});},te=ae=>{_.current=false,J(ae,ae.currentTarget.value,{source:"compositionEnd"}),I?.(ae);},re=ae=>{a&&ae.key==="Enter"&&!B.current&&!ae.nativeEvent.isComposing&&(B.current=true,a(ae)),l?.(ae);},ie=ae=>{ae.key==="Enter"&&(B.current=false),u?.(ae);},de=ae=>{O(true),o?.(ae);},ne=ae=>{B.current&&(B.current=false),O(false),i?.(ae);},ce=ae=>{z(""),G(),V.current&&Z0(V.current,ae,r);},fe=K&&`${d}-out-of-range`,se=()=>{const ae=Ln(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames","onClear"]);return q.createElement("input",J0({autoComplete:n},ae,{onChange:ee,onFocus:de,onBlur:ne,onKeyDown:re,onKeyUp:ie,className:X(d,{[`${d}-disabled`]:m},M?.input),style:T?.input,ref:V,size:p,type:w,onCompositionStart:pe=>{_.current=true,R?.(pe);},onCompositionEnd:te}))},Me=()=>{const ae=Number(D)>0;if(y||Q.show){const pe=Q.showFormatter?Q.showFormatter({value:j,count:L,maxLength:D}):`${L}${ae?` / ${D}`:""}`;return q.createElement(q.Fragment,null,Q.show&&q.createElement("span",{className:X(`${d}-show-count-suffix`,{[`${d}-show-count-has-suffix`]:!!y},M?.count),style:{...T?.count}},pe),y)}return null};return q.createElement(G7,J0({},N,{prefixCls:d,className:X(g,fe),handleReset:ce,value:j,focused:P,triggerFocus:G,suffix:Me(),disabled:m,classes:$,classNames:M,styles:T,ref:U}),se())}),K7=e=>{let t;return typeof e=="object"&&e?.clearIcon?t=e:e&&(t={clearIcon:q.createElement(Kp,null)}),t};function Y7(e,t){const n=f.useRef([]),r=()=>{n.current.push(setTimeout(()=>{e.current?.input&&e.current?.input.getAttribute("type")==="password"&&e.current?.input.hasAttribute("value")&&e.current?.input.removeAttribute("value");}));};return f.useEffect(()=>(t&&r(),()=>n.current.forEach(o=>{o&&clearTimeout(o);})),[]),r}function Ife(e){return !!(e.prefix||e.suffix||e.allowClear||e.showCount)}const kf=f.forwardRef((e,t)=>{const{prefixCls:n,bordered:r=true,status:o,size:i,disabled:a,onBlur:l,onFocus:u,suffix:d,allowClear:m,addonAfter:p,addonBefore:g,className:b,style:y,styles:S,rootClassName:C,onChange:w,classNames:$,variant:M,...T}=e,{getPrefixCls:R,direction:I,allowClear:N,autoComplete:P,className:O,style:_,classNames:B,styles:V}=jt("input"),U=R("input",n),G=f.useRef(null),H=Qn(U),[z,j]=R7(U,C);T7(U,H);const{compactSize:W,compactItemClassnames:Y}=ks(U,I),Q=so(Ae=>i??W??Ae),D=q.useContext(no),L=a??D,K={...e,size:Q,disabled:L},[J,ee]=Kt([B,$],[V,S],{props:K}),{status:te,hasFeedback:re,feedbackIcon:ie}=f.useContext(So),de=Df(te,o),ne=Ife(e)||!!re;f.useRef(ne);const ce=Y7(G,true),fe=Ae=>{ce(),l?.(Ae);},se=Ae=>{ce(),u?.(Ae);},Me=Ae=>{ce(),w?.(Ae);},ae=(re||d)&&q.createElement(q.Fragment,null,d,re&&ie),pe=K7(m??N),[Ce,xe]=a1("input",M,r);return q.createElement(Pfe,{ref:Vr(t,G),prefixCls:U,autoComplete:P,...T,disabled:L,onBlur:fe,onFocus:se,style:{...ee.root,..._,...y},styles:ee,suffix:ae,allowClear:pe,className:X(b,C,j,H,Y,O,J.root),onChange:Me,addonBefore:g&&q.createElement(Vl,{form:true,space:true},g),addonAfter:p&&q.createElement(Vl,{form:true,space:true},p),classNames:{...J,input:X({[`${U}-sm`]:Q==="small",[`${U}-lg`]:Q==="large",[`${U}-rtl`]:I==="rtl"},J.input,z),variant:X({[`${U}-${Ce}`]:xe},jl(U,de)),affixWrapper:X({[`${U}-affix-wrapper-sm`]:Q==="small",[`${U}-affix-wrapper-lg`]:Q==="large",[`${U}-affix-wrapper-rtl`]:I==="rtl"},z),wrapper:X({[`${U}-group-rtl`]:I==="rtl"},z),groupWrapper:X({[`${U}-group-wrapper-sm`]:Q==="small",[`${U}-group-wrapper-lg`]:Q==="large",[`${U}-group-wrapper-rtl`]:I==="rtl",[`${U}-group-wrapper-${Ce}`]:xe},jl(`${U}-group-wrapper`,de,re),z)}})}),Ofe=/(^#[\da-f]{6}$)|(^#[\da-f]{8}$)/i,Dfe=e=>Ofe.test(`#${e}`),_fe=({prefixCls:e,value:t,onChange:n})=>{const r=`${e}-hex-input`,[o,i]=f.useState(()=>t?yh(t.toHexString()):void 0);f.useEffect(()=>{t&&i(yh(t.toHexString()));},[t]);const a=l=>{const u=l.target.value;i(yh(u)),Dfe(yh(u,true))&&n?.(ro(u));};return q.createElement(kf,{className:r,value:o,prefix:"#",onChange:a,size:"small"})},Bfe=({prefixCls:e,value:t,onChange:n})=>{const r=`${e}-hsb-input`,[o,i]=f.useState(()=>ro(t||"#000")),a=t||o,l=(u,d)=>{const m=a.toHsb();m[d]=d==="h"?u:(u||0)/100;const p=ro(m);i(p),n?.(p);};return q.createElement("div",{className:r},q.createElement(Zc,{max:360,min:0,value:Number(a.toHsb().h),prefixCls:e,className:r,formatter:u=>Ub(u||0).toString(),onChange:u=>l(Number(u),"h")}),q.createElement(Zc,{max:100,min:0,value:Number(a.toHsb().s)*100,prefixCls:e,className:r,formatter:u=>`${Ub(u||0)}%`,onChange:u=>l(Number(u),"s")}),q.createElement(Zc,{max:100,min:0,value:Number(a.toHsb().b)*100,prefixCls:e,className:r,formatter:u=>`${Ub(u||0)}%`,onChange:u=>l(Number(u),"b")}))},Lfe=({prefixCls:e,value:t,onChange:n})=>{const r=`${e}-rgb-input`,[o,i]=f.useState(()=>ro(t||"#000")),a=t||o,l=(u,d)=>{const m=a.toRgb();m[d]=u||0;const p=ro(m);i(p),n?.(p);};return q.createElement("div",{className:r},q.createElement(Zc,{max:255,min:0,value:Number(a.toRgb().r),prefixCls:e,className:r,onChange:u=>l(Number(u),"r")}),q.createElement(Zc,{max:255,min:0,value:Number(a.toRgb().g),prefixCls:e,className:r,onChange:u=>l(Number(u),"g")}),q.createElement(Zc,{max:255,min:0,value:Number(a.toRgb().b),prefixCls:e,className:r,onChange:u=>l(Number(u),"b")}))},zfe=[F7,V7,H7].map(e=>({value:e,label:e.toUpperCase()})),kfe=e=>{const{prefixCls:t,format:n,value:r,disabledAlpha:o,onFormatChange:i,onChange:a,disabledFormat:l}=e,[u,d]=un(F7,n),m=`${t}-input`,p=b=>{d(b),i?.(b);},g=f.useMemo(()=>{const b={value:r,prefixCls:t,onChange:a};switch(u){case V7:return q.createElement(Bfe,{...b});case H7:return q.createElement(Lfe,{...b});default:return q.createElement(_fe,{...b})}},[u,t,r,a]);return q.createElement("div",{className:`${m}-container`},!l&&q.createElement(Zl,{value:u,variant:"borderless",getPopupContainer:b=>b,popupMatchSelectWidth:68,placement:"bottomRight",onChange:p,className:`${t}-format-select`,size:"small",options:zfe}),q.createElement("div",{className:m},g),!o&&q.createElement(Tfe,{prefixCls:t,value:r,onChange:a}))};function GE(e,t,n){return (e-t)/(n-t)}function eT(e,t,n,r){const o=GE(t,n,r),i={};switch(e){case "rtl":i.right=`${o*100}%`,i.transform="translateX(50%)";break;case "btt":i.bottom=`${o*100}%`,i.transform="translateY(50%)";break;case "ttb":i.top=`${o*100}%`,i.transform="translateY(-50%)";break;default:i.left=`${o*100}%`,i.transform="translateX(-50%)";break}return i}function Lc(e,t){return Array.isArray(e)?e[t]:e}const Eu=f.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:true,styles:{},classNames:{}}),X7=f.createContext({});function qE(){return qE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},qE.apply(this,arguments)}const x8=f.forwardRef((e,t)=>{const{prefixCls:n,value:r,valueIndex:o,onStartMove:i,onDelete:a,style:l,render:u,dragging:d,draggingDelete:m,onOffsetChange:p,onChangeComplete:g,onFocus:b,onMouseEnter:y,...S}=e,{min:C,max:w,direction:$,disabled:M,keyboard:T,range:R,tabIndex:I,ariaLabelForHandle:N,ariaLabelledByForHandle:P,ariaRequired:O,ariaValueTextFormatterForHandle:_,styles:B,classNames:V}=f.useContext(Eu),U=`${n}-handle`,G=L=>{M||i(L,o);},H=L=>{b?.(L,o);},z=L=>{y(L,o);},j=L=>{if(!M&&T){let K=null;switch(L.which||L.keyCode){case it.LEFT:K=$==="ltr"||$==="btt"?-1:1;break;case it.RIGHT:K=$==="ltr"||$==="btt"?1:-1;break;case it.UP:K=$!=="ttb"?1:-1;break;case it.DOWN:K=$!=="ttb"?-1:1;break;case it.HOME:K="min";break;case it.END:K="max";break;case it.PAGE_UP:K=2;break;case it.PAGE_DOWN:K=-2;break;case it.BACKSPACE:case it.DELETE:a?.(o);break}K!==null&&(L.preventDefault(),p(K,o));}},W=L=>{switch(L.which||L.keyCode){case it.LEFT:case it.RIGHT:case it.UP:case it.DOWN:case it.HOME:case it.END:case it.PAGE_UP:case it.PAGE_DOWN:g?.();break}},Y=eT($,r,C,w);let Q={};o!==null&&(Q={tabIndex:M?null:Lc(I,o),role:"slider","aria-valuemin":C,"aria-valuemax":w,"aria-valuenow":r,"aria-disabled":M,"aria-label":Lc(N,o),"aria-labelledby":Lc(P,o),"aria-required":Lc(O,o),"aria-valuetext":Lc(_,o)?.(r),"aria-orientation":$==="ltr"||$==="rtl"?"horizontal":"vertical",onMouseDown:G,onTouchStart:G,onFocus:H,onMouseEnter:z,onKeyDown:j,onKeyUp:W});let D=f.createElement("div",qE({ref:t,className:X(U,{[`${U}-${o+1}`]:o!==null&&R,[`${U}-dragging`]:d,[`${U}-dragging-delete`]:m},V.handle),style:{...Y,...l,...B.handle}},Q,S));return u&&(D=u(D,{index:o,prefixCls:n,value:r,dragging:d,draggingDelete:m})),D});function ey(){return ey=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},ey.apply(this,arguments)}const Ffe=f.forwardRef((e,t)=>{const{prefixCls:n,style:r,onStartMove:o,onOffsetChange:i,values:a,handleRender:l,activeHandleRender:u,draggingIndex:d,draggingDelete:m,onFocus:p,...g}=e,b=f.useRef({}),[y,S]=f.useState(false),[C,w]=f.useState(-1),$=I=>{w(I),S(true);},M=(I,N)=>{$(N),p?.(I);},T=(I,N)=>{$(N);};f.useImperativeHandle(t,()=>({focus:I=>{b.current[I]?.focus();},hideHelp:()=>{$o.flushSync(()=>{S(false);});}}));const R={prefixCls:n,onStartMove:o,onOffsetChange:i,render:l,onFocus:M,onMouseEnter:T,...g};return f.createElement(f.Fragment,null,a.map((I,N)=>{const P=d===N;return f.createElement(x8,ey({ref:O=>{O?b.current[N]=O:delete b.current[N];},dragging:P,draggingDelete:P&&m,style:Lc(r,N),key:N,value:I,valueIndex:N},R))}),u&&y&&f.createElement(x8,ey({key:"a11y"},R,{value:a[C],valueIndex:null,dragging:d!==-1,draggingDelete:m,render:u,style:{pointerEvents:"none"},tabIndex:null,"aria-hidden":true})))}),Hfe=e=>{const{prefixCls:t,style:n,children:r,value:o,onClick:i}=e,{min:a,max:l,direction:u,includedStart:d,includedEnd:m,included:p}=f.useContext(Eu),g=`${t}-text`,b=eT(u,o,a,l);return f.createElement("span",{className:X(g,{[`${g}-active`]:p&&d<=o&&o<=m}),style:{...b,...n},onMouseDown:y=>{y.stopPropagation();},onClick:()=>{i(o);}},r)},Vfe=e=>{const{prefixCls:t,marks:n,onClick:r}=e,o=`${t}-mark`;return n.length?f.createElement("div",{className:o},n.map(({value:i,style:a,label:l})=>f.createElement(Hfe,{key:i,prefixCls:o,style:a,value:i,onClick:r},l))):null},jfe=e=>{const{prefixCls:t,value:n,style:r,activeStyle:o}=e,{min:i,max:a,direction:l,included:u,includedStart:d,includedEnd:m}=f.useContext(Eu),p=`${t}-dot`,g=u&&d<=n&&n<=m;let b={...eT(l,n,i,a),...typeof r=="function"?r(n):r};return g&&(b={...b,...typeof o=="function"?o(n):o}),f.createElement("span",{className:X(p,{[`${p}-active`]:g}),style:b})},Ufe=e=>{const{prefixCls:t,marks:n,dots:r,style:o,activeStyle:i}=e,{min:a,max:l,step:u}=f.useContext(Eu),d=f.useMemo(()=>{const m=new Set;if(n.forEach(p=>{m.add(p.value);}),r&&u!==null){let p=a;for(;p<=l;)m.add(p),p+=u;}return Array.from(m)},[a,l,u,r,n]);return f.createElement("div",{className:`${t}-step`},d.map(m=>f.createElement(jfe,{prefixCls:t,key:m,value:m,style:o,activeStyle:i})))},w8=e=>{const{prefixCls:t,style:n,start:r,end:o,index:i,onStartMove:a,replaceCls:l}=e,{direction:u,min:d,max:m,disabled:p,range:g,classNames:b}=f.useContext(Eu),y=`${t}-track`,S=GE(r,d,m),C=GE(o,d,m),w=T=>{!p&&a&&a(T,-1);},$={};switch(u){case "rtl":$.right=`${S*100}%`,$.width=`${C*100-S*100}%`;break;case "btt":$.bottom=`${S*100}%`,$.height=`${C*100-S*100}%`;break;case "ttb":$.top=`${S*100}%`,$.height=`${C*100-S*100}%`;break;default:$.left=`${S*100}%`,$.width=`${C*100-S*100}%`;}const M=l||X(y,{[`${y}-${i+1}`]:i!==null&&g,[`${t}-track-draggable`]:a},b.track);return f.createElement("div",{className:M,style:{...$,...n},onMouseDown:w,onTouchStart:w})},Wfe=e=>{const{prefixCls:t,style:n,values:r,startPoint:o,onStartMove:i}=e,{included:a,range:l,min:u,styles:d,classNames:m}=f.useContext(Eu),p=f.useMemo(()=>{if(!l){if(r.length===0)return [];const y=o??u,S=r[0];return [{start:Math.min(y,S),end:Math.max(y,S)}]}const b=[];for(let y=0;y<r.length-1;y+=1)b.push({start:r[y],end:r[y+1]});return b},[r,l,o,u]);if(!a)return null;const g=p?.length&&(m.tracks||d.tracks)?f.createElement(w8,{index:null,prefixCls:t,start:p[0].start,end:p[p.length-1].end,replaceCls:X(m.tracks,`${t}-tracks`),style:d.tracks}):null;return f.createElement(f.Fragment,null,g,p.map(({start:b,end:y},S)=>f.createElement(w8,{index:S,prefixCls:t,style:{...Lc(n,S),...d.track},start:b,end:y,key:S,onStartMove:i})))},Gfe=130;function $8(e){const t="targetTouches"in e?e.targetTouches[0]:e;return {pageX:t.pageX,pageY:t.pageY}}function qfe(e,t,n,r,o,i,a,l,u,d,m){const[p,g]=f.useState(null),[b,y]=f.useState(-1),[S,C]=f.useState(false),[w,$]=f.useState(n),[M,T]=f.useState(n),R=f.useRef(null),I=f.useRef(null),N=f.useRef(null),{onDragStart:P,onDragChange:O}=f.useContext(X7);An(()=>{b===-1&&$(n);},[n,b]),f.useEffect(()=>()=>{document.removeEventListener("mousemove",R.current),document.removeEventListener("mouseup",I.current),N.current&&(N.current.removeEventListener("touchmove",R.current),N.current.removeEventListener("touchend",I.current));},[]);const _=(G,H,z)=>{H!==void 0&&g(H),$(G);let j=G;z&&(j=G.filter((W,Y)=>Y!==b)),a(j),O&&O({rawValues:G,deleteIndex:z?b:-1,draggingIndex:b,draggingValue:H});},B=Mt((G,H,z)=>{if(G===-1){const j=M[0],W=M[M.length-1],Y=r-j,Q=o-W;let D=H*(o-r);D=Math.max(D,Y),D=Math.min(D,Q),D=i(j+D)-j;const K=M.map(J=>J+D);_(K);}else {const j=(o-r)*H,W=[...w];W[G]=M[G];const Y=u(W,j,G,"dist");_(Y.values,Y.value,z);}}),V=(G,H,z)=>{G.stopPropagation();const j=z||n,W=j[H];y(H),g(W),T(j),$(j),C(false);const{pageX:Y,pageY:Q}=$8(G);let D=false;P&&P({rawValues:j,draggingIndex:H,draggingValue:W});const L=J=>{J.preventDefault();const{pageX:ee,pageY:te}=$8(J),re=ee-Y,ie=te-Q,{width:de,height:ne}=e.current.getBoundingClientRect();let ce,fe;switch(t){case "btt":ce=-ie/ne,fe=re;break;case "ttb":ce=ie/ne,fe=re;break;case "rtl":ce=-re/de,fe=ie;break;default:ce=re/de,fe=ie;}D=d?Math.abs(fe)>Gfe&&m<w.length:false,C(D),B(H,ce,D);},K=J=>{J.preventDefault(),document.removeEventListener("mouseup",K),document.removeEventListener("mousemove",L),N.current&&(N.current.removeEventListener("touchmove",R.current),N.current.removeEventListener("touchend",I.current)),R.current=null,I.current=null,N.current=null,l(D),y(-1),C(false);};document.addEventListener("mouseup",K),document.addEventListener("mousemove",L),G.currentTarget.addEventListener("touchend",K),G.currentTarget.addEventListener("touchmove",L),R.current=L,I.current=K,N.current=G.currentTarget;},U=f.useMemo(()=>{const G=[...n].sort((Y,Q)=>Y-Q),H=[...w].sort((Y,Q)=>Y-Q),z={};H.forEach(Y=>{z[Y]=(z[Y]||0)+1;}),G.forEach(Y=>{z[Y]=(z[Y]||0)-1;});const j=d?1:0;return Object.values(z).reduce((Y,Q)=>Y+Math.abs(Q),0)<=j?w:n},[n,w,d]);return [b,p,S,U,V]}function Kfe(e,t,n,r,o,i){const a=f.useCallback(b=>Math.max(e,Math.min(t,b)),[e,t]),l=f.useCallback(b=>{if(n!==null){const y=e+Math.round((a(b)-e)/n)*n,S=$=>(String($).split(".")[1]||"").length,C=Math.max(S(n),S(t),S(e)),w=Number(y.toFixed(C));return e<=w&&w<=t?w:null}return null},[n,e,t,a]),u=f.useCallback(b=>{const y=a(b),S=r.map($=>$.value);n!==null&&S.push(l(b)),S.push(e,t);let C=S[0],w=t-e;return S.forEach($=>{const M=Math.abs(y-$);M<=w&&(C=$,w=M);}),C},[e,t,r,n,a,l]),d=(b,y,S,C="unit")=>{if(typeof y=="number"){let w;const $=b[S],M=$+y;let T=[];r.forEach(P=>{T.push(P.value);}),T.push(e,t),T.push(l($));const R=y>0?1:-1;C==="unit"?T.push(l($+R*n)):T.push(l(M)),T=T.filter(P=>P!==null).filter(P=>y<0?P<=$:P>=$),C==="unit"&&(T=T.filter(P=>P!==$));const I=C==="unit"?$:M;w=T[0];let N=Math.abs(w-I);if(T.forEach(P=>{const O=Math.abs(P-I);O<N&&(w=P,N=O);}),w===void 0)return y<0?e:t;if(C==="dist")return w;if(Math.abs(y)>1){const P=[...b];return P[S]=w,d(P,y-R,S,C)}return w}else {if(y==="min")return e;if(y==="max")return t}},m=(b,y,S,C="unit")=>{const w=b[S],$=d(b,y,S,C);return {value:$,changed:$!==w}},p=b=>i===null&&b===0||typeof i=="number"&&b<i;return [u,(b,y,S,C="unit")=>{const w=b.map(u),$=w[S],M=d(w,y,S,C);if(w[S]=M,o===false){const T=i||0;S>0&&w[S-1]!==$&&(w[S]=Math.max(w[S],w[S-1]+T)),S<w.length-1&&w[S+1]!==$&&(w[S]=Math.min(w[S],w[S+1]-T));}else if(typeof i=="number"||i===null){for(let T=S+1;T<w.length;T+=1){let R=true;for(;p(w[T]-w[T-1])&&R;)({value:w[T],changed:R}=m(w,1,T));}for(let T=S;T>0;T-=1){let R=true;for(;p(w[T]-w[T-1])&&R;)({value:w[T-1],changed:R}=m(w,-1,T-1));}for(let T=w.length-1;T>0;T-=1){let R=true;for(;p(w[T]-w[T-1])&&R;)({value:w[T-1],changed:R}=m(w,-1,T-1));}for(let T=0;T<w.length-1;T+=1){let R=true;for(;p(w[T+1]-w[T])&&R;)({value:w[T+1],changed:R}=m(w,1,T+1));}}return {value:w[S],values:w}}]}function Yfe(e){return f.useMemo(()=>{if(e===true||!e)return [!!e,false,false,0];const{editable:t,draggableTrack:n,minCount:r,maxCount:o}=e;return [true,t,!t&&n,r||0,o]},[e])}const Xfe=f.forwardRef((e,t)=>{const{prefixCls:n="rc-slider",className:r,style:o,classNames:i,styles:a,id:l,disabled:u=false,keyboard:d=true,autoFocus:m,onFocus:p,onBlur:g,min:b=0,max:y=100,step:S=1,value:C,defaultValue:w,range:$,count:M,onChange:T,onBeforeChange:R,onAfterChange:I,onChangeComplete:N,allowCross:P=true,pushable:O=false,reverse:_,vertical:B,included:V=true,startPoint:U,trackStyle:G,handleStyle:H,railStyle:z,dotStyle:j,activeDotStyle:W,marks:Y,dots:Q,handleRender:D,activeHandleRender:L,track:K,tabIndex:J=0,ariaLabelForHandle:ee,ariaLabelledByForHandle:te,ariaRequired:re,ariaValueTextFormatterForHandle:ie}=e,de=f.useRef(null),ne=f.useRef(null),ce=f.useMemo(()=>B?_?"ttb":"btt":_?"rtl":"ltr",[_,B]),[fe,se,Me,ae,pe]=Yfe($),Ce=f.useMemo(()=>isFinite(b)?b:0,[b]),xe=f.useMemo(()=>isFinite(y)?y:100,[y]),Ae=f.useMemo(()=>S!==null&&S<=0?1:S,[S]),Xe=f.useMemo(()=>typeof O=="boolean"?O?Ae:false:O>=0?O:false,[O,Ae]),Ne=f.useMemo(()=>Object.keys(Y||{}).map(be=>{const Se=Y[be],he={value:Number(be)};return Se&&typeof Se=="object"&&!f.isValidElement(Se)&&("label"in Se||"style"in Se)?(he.style=Se.style,he.label=Se.label):he.label=Se,he}).filter(({label:be})=>be||typeof be=="number").sort((be,Se)=>be.value-Se.value),[Y]),[ue,ge]=Kfe(Ce,xe,Ae,Ne,P,Xe),[Pe,je]=un(w,C),qe=f.useMemo(()=>{const be=Pe==null?[]:Array.isArray(Pe)?Pe:[Pe],[Se=Ce]=be;let he=Pe===null?[]:[Se];if(fe){if(he=[...be],M||Pe===void 0){const De=M>=0?M+1:2;for(he=he.slice(0,De);he.length<De;)he.push(he[he.length-1]??Ce);}he.sort((De,$e)=>De-$e);}return he.forEach((De,$e)=>{he[$e]=ue(De);}),he},[Pe,fe,Ce,M,ue]),Ue=be=>fe?be:be[0],et=Mt(be=>{const Se=[...be].sort((he,De)=>he-De);T&&!zl(Se,qe,true)&&T(Ue(Se)),je(Se);}),rt=Mt(be=>{be&&de.current.hideHelp();const Se=Ue(qe);I?.(Se),Er(!I,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N?.(Se);}),Ke=be=>{if(u||!se||qe.length<=ae)return;const Se=[...qe];Se.splice(be,1),R?.(Ue(Se)),et(Se);const he=Math.max(0,be-1);de.current.hideHelp(),de.current.focus(he);},[_e,We,Ze,Be,Oe]=qfe(ne,ce,qe,Ce,xe,ue,et,rt,ge,se,ae),lt=(be,Se)=>{if(!u){const he=[...qe];let De=0,$e=0,ke=xe-Ce;qe.forEach((ht,$t)=>{const Rt=Math.abs(be-ht);Rt<=ke&&(ke=Rt,De=$t),ht<be&&($e=$t);});let Ge=De;se&&ke!==0&&(!pe||qe.length<pe)?(he.splice($e+1,0,be),Ge=$e+1):he[De]=be,fe&&!qe.length&&M===void 0&&he.push(be);const ot=Ue(he);R?.(ot),et(he),Se?(document.activeElement?.blur?.(),de.current.focus(Ge),Oe(Se,Ge,he)):(I?.(ot),Er(!I,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),N?.(ot));}},It=be=>{be.preventDefault();const{width:Se,height:he,left:De,top:$e,bottom:ke,right:Ge}=ne.current.getBoundingClientRect(),{clientX:ot,clientY:ht}=be;let $t;switch(ce){case "btt":$t=(ke-ht)/he;break;case "ttb":$t=(ht-$e)/he;break;case "rtl":$t=(Ge-ot)/Se;break;default:$t=(ot-De)/Se;}const Rt=Ce+$t*(xe-Ce);lt(ue(Rt),be);},[mt,Bt]=f.useState(null),xt=(be,Se)=>{if(!u){const he=ge(qe,be,Se);R?.(Ue(qe)),et(he.values),Bt(he.value);}};f.useEffect(()=>{if(mt!==null){const be=qe.indexOf(mt);be>=0&&de.current.focus(be);}Bt(null);},[mt]);const Tt=f.useMemo(()=>Me&&Ae===null?false:Me,[Me,Ae]),ut=Mt((be,Se)=>{Oe(be,Se),R?.(Ue(qe));}),dt=_e!==-1;f.useEffect(()=>{if(!dt){const be=qe.lastIndexOf(We);de.current.focus(be);}},[dt]);const gt=f.useMemo(()=>[...Be].sort((be,Se)=>be-Se),[Be]),[Fe,Qe]=f.useMemo(()=>fe?[gt[0],gt[gt.length-1]]:[Ce,gt[0]],[gt,fe,Ce]);f.useImperativeHandle(t,()=>({focus:()=>{de.current.focus(0);},blur:()=>{const{activeElement:be}=document;ne.current?.contains(be)&&be?.blur();}})),f.useEffect(()=>{m&&de.current.focus(0);},[]);const ye=f.useMemo(()=>({min:Ce,max:xe,direction:ce,disabled:u,keyboard:d,step:Ae,included:V,includedStart:Fe,includedEnd:Qe,range:fe,tabIndex:J,ariaLabelForHandle:ee,ariaLabelledByForHandle:te,ariaRequired:re,ariaValueTextFormatterForHandle:ie,styles:a||{},classNames:i||{}}),[Ce,xe,ce,u,d,Ae,V,Fe,Qe,fe,J,ee,te,re,ie,a,i]);return f.createElement(Eu.Provider,{value:ye},f.createElement("div",{ref:ne,className:X(n,r,{[`${n}-disabled`]:u,[`${n}-vertical`]:B,[`${n}-horizontal`]:!B,[`${n}-with-marks`]:Ne.length}),style:o,onMouseDown:It,id:l},f.createElement("div",{className:X(`${n}-rail`,i?.rail),style:{...z,...a?.rail}}),K!==false&&f.createElement(Wfe,{prefixCls:n,style:G,values:qe,startPoint:U,onStartMove:Tt?ut:void 0}),f.createElement(Ufe,{prefixCls:n,marks:Ne,dots:Q,style:j,activeStyle:W}),f.createElement(Ffe,{ref:de,prefixCls:n,style:H,values:Be,draggingIndex:_e,draggingDelete:Ze,onStartMove:ut,onOffsetChange:xt,onFocus:p,onBlur:g,handleRender:D,activeHandleRender:L,onChangeComplete:rt,onDelete:se?Ke:void 0}),f.createElement(Vfe,{prefixCls:n,marks:Ne,onClick:lt})))}),Q7=f.createContext({}),E8=f.forwardRef((e,t)=>{const{open:n,draggingDelete:r,value:o}=e,i=f.useRef(null),a=n&&!r,l=f.useRef(null);function u(){Lt.cancel(l.current),l.current=null;}function d(){l.current=Lt(()=>{i.current?.forceAlign(),l.current=null;});}return f.useEffect(()=>(a?d():u(),u),[a,e.title,o]),f.createElement(Jl,{ref:Vr(i,t),...e,open:a})}),Qfe=e=>{const{componentCls:t,antCls:n,controlSize:r,dotSize:o,marginFull:i,marginPart:a,colorFillContentHover:l,handleColorDisabled:u,calc:d,handleSize:m,handleSizeHover:p,handleActiveColor:g,handleActiveOutlineColor:b,handleLineWidth:y,handleLineWidthHover:S,motionDurationMid:C}=e;return {[t]:{...dn(e),position:"relative",height:r,margin:`${oe(a)} ${oe(i)}`,padding:0,cursor:"pointer",touchAction:"none","&-vertical":{margin:`${oe(i)} ${oe(a)}`},[`${t}-rail`]:{position:"absolute",backgroundColor:e.railBg,borderRadius:e.borderRadiusXS,transition:`background-color ${C}`},[`${t}-track,${t}-tracks`]:{position:"absolute",transition:`background-color ${C}`},[`${t}-track`]:{backgroundColor:e.trackBg,borderRadius:e.borderRadiusXS},[`${t}-track-draggable`]:{boxSizing:"content-box",backgroundClip:"content-box",border:"solid rgba(0,0,0,0)"},"&:hover":{[`${t}-rail`]:{backgroundColor:e.railHoverBg},[`${t}-track`]:{backgroundColor:e.trackHoverBg},[`${t}-dot`]:{borderColor:l},[`${t}-handle::after`]:{boxShadow:`0 0 0 ${oe(y)} ${e.colorPrimaryBorderHover}`},[`${t}-dot-active`]:{borderColor:e.dotActiveBorderColor}},[`${t}-handle`]:{position:"absolute",width:m,height:m,outline:"none",userSelect:"none","&-dragging-delete":{opacity:0},"&::before":{content:'""',position:"absolute",insetInlineStart:d(y).mul(-1).equal(),insetBlockStart:d(y).mul(-1).equal(),width:d(m).add(d(y).mul(2)).equal(),height:d(m).add(d(y).mul(2)).equal(),backgroundColor:"transparent"},"&::after":{content:'""',position:"absolute",insetBlockStart:0,insetInlineStart:0,width:m,height:m,backgroundColor:e.colorBgElevated,boxShadow:`0 0 0 ${oe(y)} ${e.handleColor}`,outline:"0px solid transparent",borderRadius:"50%",cursor:"pointer",transition:["inset-inline-start","inset-block-start","width","height","box-shadow","outline"].map(w=>`${w} ${C}`).join(", ")},"&:hover, &:active, &:focus":{"&::before":{insetInlineStart:d(p).sub(m).div(2).add(S).mul(-1).equal(),insetBlockStart:d(p).sub(m).div(2).add(S).mul(-1).equal(),width:d(p).add(d(S).mul(2)).equal(),height:d(p).add(d(S).mul(2)).equal()},"&::after":{boxShadow:`0 0 0 ${oe(S)} ${g}`,outline:`6px solid ${b}`,width:p,height:p,insetInlineStart:e.calc(m).sub(p).div(2).equal(),insetBlockStart:e.calc(m).sub(p).div(2).equal()}}},[`&-lock ${t}-handle`]:{"&::before, &::after":{transition:"none"}},[`${t}-mark`]:{position:"absolute",fontSize:e.fontSize},[`${t}-mark-text`]:{position:"absolute",display:"inline-block",color:e.colorTextDescription,textAlign:"center",wordBreak:"keep-all",cursor:"pointer",userSelect:"none","&-active":{color:e.colorText}},[`${t}-step`]:{position:"absolute",background:"transparent",pointerEvents:"none"},[`${t}-dot`]:{position:"absolute",width:o,height:o,backgroundColor:e.colorBgElevated,border:`${oe(y)} solid ${e.dotBorderColor}`,borderRadius:"50%",cursor:"pointer",transition:`border-color ${e.motionDurationSlow}`,pointerEvents:"auto","&-active":{borderColor:e.dotActiveBorderColor}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-rail`]:{backgroundColor:`${e.railBg} !important`},[`${t}-track`]:{backgroundColor:`${e.trackBgDisabled} !important`},[`
${t}-dot
`]:{backgroundColor:e.colorBgElevated,borderColor:e.trackBgDisabled,boxShadow:"none",cursor:"not-allowed"},[`${t}-handle::after`]:{backgroundColor:e.colorBgElevated,cursor:"not-allowed",width:m,height:m,boxShadow:`0 0 0 ${oe(y)} ${u}`,insetInlineStart:0,insetBlockStart:0},[`
${t}-mark-text,
${t}-dot
`]:{cursor:"not-allowed !important"}},[`&-tooltip ${n}-tooltip-container`]:{minWidth:"unset"}}}},Z7=(e,t)=>{const{componentCls:n,railSize:r,handleSize:o,dotSize:i,marginFull:a,calc:l}=e,u=t?"paddingBlock":"paddingInline",d=t?"width":"height",m=t?"height":"width",p=t?"insetBlockStart":"insetInlineStart",g=t?"top":"insetInlineStart",b=l(r).mul(3).sub(o).div(2).equal(),y=l(o).sub(r).div(2).equal(),S=t?{borderWidth:`${oe(y)} 0`,transform:`translateY(${oe(l(y).mul(-1).equal())})`}:{borderWidth:`0 ${oe(y)}`,transform:`translateX(${oe(e.calc(y).mul(-1).equal())})`};return {[u]:r,[m]:l(r).mul(3).equal(),[`${n}-rail`]:{[d]:"100%",[m]:r},[`${n}-track,${n}-tracks`]:{[m]:r},[`${n}-track-draggable`]:{...S},[`${n}-handle`]:{[p]:b},[`${n}-mark`]:{insetInlineStart:0,top:0,[g]:l(r).mul(3).add(t?0:a).equal(),[d]:"100%"},[`${n}-step`]:{insetInlineStart:0,top:0,[g]:r,[d]:"100%",[m]:r},[`${n}-dot`]:{position:"absolute",[p]:l(r).sub(i).div(2).equal()}}},Zfe=e=>{const{componentCls:t,marginPartWithMark:n}=e;return {[`${t}-horizontal`]:{...Z7(e,true),[`&${t}-with-marks`]:{marginBottom:n}}}},Jfe=e=>{const{componentCls:t}=e;return {[`${t}-vertical`]:{...Z7(e,false),height:"100%"}}},eme=e=>{const n=e.controlHeightLG/4,r=e.controlHeightSM/2,o=e.lineWidth+1,i=e.lineWidth+1*1.5,a=e.colorPrimary,l=new cn(a).setA(.2).toRgbString();return {controlSize:n,railSize:4,handleSize:n,handleSizeHover:r,dotSize:8,handleLineWidth:o,handleLineWidthHover:i,railBg:e.colorFillTertiary,railHoverBg:e.colorFillSecondary,trackBg:e.colorPrimaryBorder,trackHoverBg:e.colorPrimaryBorderHover,handleColor:e.colorPrimaryBorder,handleActiveColor:a,handleActiveOutlineColor:l,handleColorDisabled:new cn(e.colorTextDisabled).onBackground(e.colorBgContainer).toHexString(),dotBorderColor:e.colorBorderSecondary,dotActiveBorderColor:e.colorPrimaryBorder,trackBgDisabled:e.colorBgContainerDisabled}},tme=Wt("Slider",e=>{const t=Ft(e,{marginPart:e.calc(e.controlHeight).sub(e.controlSize).div(2).equal(),marginFull:e.calc(e.controlSize).div(2).equal(),marginPartWithMark:e.calc(e.controlHeightLG).sub(e.controlSize).equal()});return [Qfe(t),Zfe(t),Jfe(t)]},eme);function rw(){const[e,t]=f.useState(false),n=f.useRef(null),r=()=>{Lt.cancel(n.current);},o=i=>{r(),i?t(i):n.current=Lt(()=>{t(i);});};return f.useEffect(()=>r,[]),[e,o]}function nme(e){return e||e===null?e:t=>typeof t=="number"?t.toString():""}const tT=q.forwardRef((e,t)=>{const{prefixCls:n,range:r,className:o,rootClassName:i,style:a,disabled:l,tooltip:u={},onChangeComplete:d,classNames:m,styles:p,vertical:g,orientation:b,...y}=e,[,S]=xu(b,g),{getPrefixCls:C,direction:w,className:$,style:M,classNames:T,styles:R,getPopupContainer:I}=jt("slider"),N=q.useContext(no),P=l??N,O={...e,disabled:P,vertical:S},[_,B]=Kt([T,m],[R,p],{props:O}),{handleRender:V,direction:U}=q.useContext(Q7),H=(U||w)==="rtl",[z,j]=rw(),[W,Y]=rw(),Q={...u},{open:D,placement:L,getPopupContainer:K,prefixCls:J,formatter:ee}=Q,te=D,re=(z||W)&&te!==false,ie=nme(ee),[de,ne]=rw(),ce=Ne=>{d?.(Ne),ne(false);},fe=(Ne,ue)=>Ne||(ue?H?"left":"right":"top"),se=C("slider",n),[Me,ae]=tme(se),pe=X(o,$,_.root,i,{[`${se}-rtl`]:H,[`${se}-lock`]:de},Me,ae);H&&!S&&(y.reverse=!y.reverse),q.useEffect(()=>{const Ne=()=>{Lt(()=>{Y(false);},1);};return document.addEventListener("mouseup",Ne),()=>{document.removeEventListener("mouseup",Ne);}},[]);const Ce=r&&!te,xe=V||((Ne,ue)=>{const{index:ge}=ue,Pe=Ne.props;function je(rt,Ke,_e){_e&&y[rt]?.(Ke),Pe[rt]?.(Ke);}const qe={...Pe,onMouseEnter:rt=>{j(true),je("onMouseEnter",rt);},onMouseLeave:rt=>{j(false),je("onMouseLeave",rt);},onMouseDown:rt=>{Y(true),ne(true),je("onMouseDown",rt);},onFocus:rt=>{Y(true),y.onFocus?.(rt),je("onFocus",rt,true);},onBlur:rt=>{Y(false),y.onBlur?.(rt),je("onBlur",rt,true);}},Ue=q.cloneElement(Ne,qe),et=(!!te||re)&&ie!==null;return Ce?Ue:q.createElement(E8,{...Q,prefixCls:C("tooltip",J),title:ie?ie(ue.value):"",value:ue.value,open:et,placement:fe(L,S),key:ge,classNames:{root:`${se}-tooltip`},getPopupContainer:K||I},Ue)}),Ae=Ce?(Ne,ue)=>{const ge=q.cloneElement(Ne,{style:{...Ne.props.style,visibility:"hidden"}});return q.createElement(E8,{...Q,prefixCls:C("tooltip",J),title:ie?ie(ue.value):"",open:ie!==null&&re,placement:fe(L,S),key:"tooltip",classNames:{root:`${se}-tooltip`},getPopupContainer:K||I,draggingDelete:ue.draggingDelete},ge)}:void 0,Xe={...B.root,...M,...a};return q.createElement(Xfe,{...y,classNames:_,styles:B,step:y.step,range:r,className:pe,style:Xe,disabled:P,vertical:S,ref:t,prefixCls:se,handleRender:xe,activeHandleRender:Ae,onChangeComplete:ce})}),J7=e=>{const{prefixCls:t,colors:n,type:r,color:o,range:i=false,className:a,activeIndex:l,onActive:u,onDragStart:d,onDragChange:m,onKeyDelete:p,...g}=e,b={...g,track:false},y=f.useMemo(()=>`linear-gradient(90deg, ${n.map(I=>`${I.color} ${I.percent}%`).join(", ")})`,[n]),S=f.useMemo(()=>!o||!r?null:r==="alpha"?o.toRgbString():`hsl(${o.toHsb().h}, 100%, 50%)`,[o,r]),C=Mt(d),w=Mt(m),$=f.useMemo(()=>({onDragStart:C,onDragChange:w}),[]),M=Mt((R,I)=>{const{onFocus:N,style:P,className:O,onKeyDown:_}=R.props,B={...P};return r==="gradient"&&(B.background=zk(n,I.value)),f.cloneElement(R,{onFocus:V=>{u?.(I.index),N?.(V);},style:B,className:X(O,{[`${t}-slider-handle-active`]:l===I.index}),onKeyDown:V=>{(V.key==="Delete"||V.key==="Backspace")&&p&&p(I.index),_?.(V);}})}),T=f.useMemo(()=>({direction:"ltr",handleRender:M}),[]);return f.createElement(Q7.Provider,{value:T},f.createElement(X7.Provider,{value:$},f.createElement(tT,{...b,className:X(a,`${t}-slider`),tooltip:{open:false},range:{editable:i,minCount:2},styles:{rail:{background:y},handle:S?{background:S}:{}},classNames:{rail:`${t}-slider-rail`,handle:`${t}-slider-handle`}})))},rme=e=>{const{value:t,onChange:n,onChangeComplete:r}=e,o=a=>n(a[0]),i=a=>r(a[0]);return f.createElement(J7,{...e,value:[t],onChange:o,onChangeComplete:i})};function M8(e){return qt(e).sort((t,n)=>t.percent-n.percent)}const ome=e=>{const{prefixCls:t,mode:n,onChange:r,onChangeComplete:o,onActive:i,activeIndex:a,onGradientDragging:l,colors:u}=e,d=n==="gradient",m=f.useMemo(()=>u.map(w=>({percent:w.percent,color:w.color.toRgbString()})),[u]),p=f.useMemo(()=>m.map(w=>w.percent),[m]),g=f.useRef(m),b=({rawValues:w,draggingIndex:$,draggingValue:M})=>{if(w.length>m.length){const T=zk(m,M),R=qt(m);R.splice($,0,{percent:M,color:T}),g.current=R;}else g.current=m;l(true),r(new Go(M8(g.current)),true);},y=({deleteIndex:w,draggingIndex:$,draggingValue:M})=>{let T=qt(g.current);w!==-1?T.splice(w,1):(T[$]={...T[$],percent:M},T=M8(T)),r(new Go(T),true);},S=w=>{const $=qt(m);$.splice(w,1);const M=new Go($);r(M),o(M);},C=w=>{o(new Go(m)),a>=w.length&&i(w.length-1),l(false);};return d?f.createElement(J7,{min:0,max:100,prefixCls:t,className:`${t}-gradient-slider`,colors:m,color:null,value:p,range:true,onChangeComplete:C,disabled:false,type:"gradient",activeIndex:a,onActive:i,onDragStart:b,onDragChange:y,onKeyDelete:S}):null},ime=f.memo(ome),ame={slider:rme},R8=()=>{const e=f.useContext(L7),{mode:t,onModeChange:n,modeOptions:r,prefixCls:o,allowClear:i,value:a,disabledAlpha:l,onChange:u,onClear:d,onChangeComplete:m,activeIndex:p,gradientDragging:g,...b}=e,y=q.useMemo(()=>a.cleared?[{percent:0,color:new Go("")},{percent:100,color:new Go("")}]:a.getColors(),[a]),S=!a.isGradient(),[C,w]=q.useState(a);An(()=>{S||w(y[p]?.color);},[S,y,g,p]);const $=q.useMemo(()=>S?a:g?C:y[p]?.color,[y,a,p,S,C,g]),[M,T]=q.useState($),[R,I]=Xz(),N=M?.equals($)?$:M;An(()=>{T($);},[R,$?.toHexString()]);const P=(G,H)=>{let z=ro(G);if(a.cleared){const W=z.toRgb();if(!W.r&&!W.g&&!W.b&&H){const{type:Y,value:Q=0}=H;z=new Go({h:Y==="hue"?Q:0,s:1,b:1,a:Y==="alpha"?Q/100:1});}else z=Wb(z);}if(t==="single")return z;const j=qt(y);return j[p]={...j[p],color:z},new Go(j)},O=(G,H,z)=>{const j=P(G,z);T(j.isGradient()?j.getColors()[p].color:j),u(j,H);},_=(G,H)=>{m(P(G,H)),I();},B=G=>{u(P(G));};let V=null;const U=r.length>1;return (i||U)&&(V=q.createElement("div",{className:`${o}-operation`},U&&q.createElement(QR,{size:"small",options:r,value:t,onChange:n}),q.createElement(k7,{prefixCls:o,value:a,onChange:G=>{u(G),d?.();},...b}))),q.createElement(q.Fragment,null,V,q.createElement(ime,{...e,colors:y}),q.createElement(kre,{prefixCls:o,value:N?.toHsb(),disabledAlpha:l,onChange:(G,H)=>{O(G,true,H);},onChangeComplete:(G,H)=>{_(G,H);},components:ame}),q.createElement(kfe,{value:$,onChange:B,prefixCls:o,disabledAlpha:l,...b}))},T8=()=>{const{prefixCls:e,value:t,presets:n,onChange:r}=f.useContext(z7);return Array.isArray(n)?q.createElement(Doe,{value:t,presets:n,prefixCls:e,onChange:r}):null},sme=e=>{const{prefixCls:t,presets:n,panelRender:r,value:o,onChange:i,onClear:a,allowClear:l,disabledAlpha:u,mode:d,onModeChange:m,modeOptions:p,onChangeComplete:g,activeIndex:b,onActive:y,format:S,onFormatChange:C,gradientDragging:w,onGradientDragging:$,disabledFormat:M}=e,T=`${t}-inner`,R=q.useMemo(()=>({prefixCls:t,value:o,onChange:i,onClear:a,allowClear:l,disabledAlpha:u,mode:d,onModeChange:m,modeOptions:p,onChangeComplete:g,activeIndex:b,onActive:y,format:S,onFormatChange:C,gradientDragging:w,onGradientDragging:$,disabledFormat:M}),[t,o,i,a,l,u,d,m,p,g,b,y,S,C,w,$,M]),I=q.useMemo(()=>({prefixCls:t,value:o,presets:n,onChange:i}),[t,o,n,i]),N=q.createElement("div",{className:`${T}-content`},q.createElement(R8,null),Array.isArray(n)&&q.createElement(Ul,null),q.createElement(T8,null));return q.createElement(L7.Provider,{value:R},q.createElement(z7.Provider,{value:I},q.createElement("div",{className:T},typeof r=="function"?r(N,{components:{Picker:R8,Presets:T8}}):N)))},lme=f.forwardRef((e,t)=>{const{color:n,prefixCls:r,open:o,disabled:i,format:a,className:l,style:u,classNames:d,styles:m,showText:p,activeIndex:g,...b}=e,y=`${r}-trigger`,S=`${y}-text`,C=`${S}-cell`,[w]=Oo("ColorPicker"),$=q.useMemo(()=>{if(!p)return "";if(typeof p=="function")return p(n);if(n.cleared)return w.transparent;if(n.isGradient())return n.getColors().map((I,N)=>{const P=g!==-1&&g!==N;return q.createElement("span",{key:N,className:X(C,P&&`${C}-inactive`)},I.color.toRgbString()," ",I.percent,"%")});const T=n.toHexString().toUpperCase(),R=vR(n);switch(a){case "rgb":return n.toRgbString();case "hsb":return n.toHsbString();default:return R<100?`${T.slice(0,7)},${R}%`:T}},[n,a,p,g,w.transparent,C]),M=f.useMemo(()=>n.cleared?q.createElement(k7,{prefixCls:r,className:d.body,style:m.body}):q.createElement(uR,{prefixCls:r,color:n.toCssString(),className:d.body,innerClassName:d.content,style:m.body,innerStyle:m.content}),[n,r,d.body,d.content,m.body,m.content]);return q.createElement("div",{ref:t,className:X(y,l,d.root,{[`${y}-active`]:o,[`${y}-disabled`]:i}),style:{...m.root,...u},...yo(b)},M,p&&q.createElement("div",{className:X(S,d.description),style:m.description},$))});function cme(e,t,n){const[r]=Oo("ColorPicker"),[o,i]=un(e,t),[a,l]=f.useState("single"),[u,d]=f.useMemo(()=>{const S=(Array.isArray(n)?n:[n]).filter(M=>M);S.length||S.push("single");const C=new Set(S),w=[],$=(M,T)=>{C.has(M)&&w.push({label:T,value:M});};return $("single",r.singleColor),$("gradient",r.gradientColor),[w,C]},[n,r.singleColor,r.gradientColor]),[m,p]=f.useState(null),g=Mt(S=>{p(S),i(S);}),b=f.useMemo(()=>{const S=ro(o||"");return S.equals(m)?m:S},[o,m]),y=f.useMemo(()=>d.has(a)?a:u[0]?.value,[d,a,u]);return f.useEffect(()=>{l(b.isGradient()?"gradient":"single");},[b]),[b,g,y,l,u]}const eH=(e,t)=>({backgroundImage:`conic-gradient(${t} 25%, transparent 25% 50%, ${t} 50% 75%, transparent 75% 100%)`,backgroundSize:`${e} ${e}`}),A8=(e,t)=>{const{componentCls:n,borderRadiusSM:r,colorPickerInsetShadow:o,lineWidth:i,colorFillSecondary:a}=e;return {[`${n}-color-block`]:{position:"relative",borderRadius:r,width:t,height:t,boxShadow:o,flex:"none",...eH("50%",e.colorFillSecondary),[`${n}-color-block-inner`]:{width:"100%",height:"100%",boxShadow:`inset 0 0 0 ${oe(i)} ${a}`,borderRadius:"inherit"}}}},ume=e=>{const{componentCls:t,antCls:n,fontSizeSM:r,lineHeightSM:o,colorPickerAlphaInputWidth:i,marginXXS:a,paddingXXS:l,controlHeightSM:u,marginXS:d,fontSizeIcon:m,paddingXS:p,colorTextPlaceholder:g,colorPickerInputNumberHandleWidth:b,lineWidth:y}=e;return {[`${t}-input-container`]:{display:"flex",[`${t}-steppers${n}-input-number`]:{fontSize:r,lineHeight:o,padding:0,[`${n}-input-number-input`]:{paddingInlineStart:l,paddingInlineEnd:0},[`${n}-input-number-handler-wrap`]:{width:b}},[`${t}-steppers${t}-alpha-input`]:{flex:`0 0 ${oe(i)}`,marginInlineStart:a},[`${t}-format-select${n}-select`]:{marginInlineEnd:d,width:"auto","&-single":{[`${n}-select-selector`]:{padding:0,border:0},[`${n}-select-arrow`]:{insetInlineEnd:0},[`${n}-select-selection-item`]:{paddingInlineEnd:e.calc(m).add(a).equal(),fontSize:r,lineHeight:oe(u)},[`${n}-select-item-option-content`]:{fontSize:r,lineHeight:o},[`${n}-select-dropdown`]:{[`${n}-select-item`]:{minHeight:"auto"}}}},[`${t}-input`]:{gap:a,alignItems:"center",flex:1,width:0,[`${t}-hsb-input,${t}-rgb-input`]:{height:u,display:"flex",gap:a,alignItems:"center"},[`${t}-steppers`]:{flex:1},[`${t}-hex-input${n}-input-affix-wrapper`]:{flex:1,padding:`0 ${oe(p)}`,[`${n}-input`]:{fontSize:r,textTransform:"uppercase",lineHeight:oe(e.calc(u).sub(e.calc(y).mul(2)).equal())},[`${n}-input-prefix`]:{color:g}}}}}},dme=e=>{const{componentCls:t,controlHeightLG:n,borderRadiusSM:r,colorPickerInsetShadow:o,marginSM:i,colorBgElevated:a,colorFillSecondary:l,lineWidthBold:u,colorPickerHandlerSize:d}=e;return {userSelect:"none",[`${t}-select`]:{[`${t}-palette`]:{minHeight:e.calc(n).mul(4).equal(),overflow:"hidden",borderRadius:r},[`${t}-saturation`]:{position:"absolute",borderRadius:"inherit",boxShadow:o,inset:0},marginBottom:i},[`${t}-handler`]:{width:d,height:d,border:`${oe(u)} solid ${a}`,position:"relative",borderRadius:"50%",cursor:"pointer",boxShadow:`${o}, 0 0 0 1px ${l}`}}},fme=e=>{const{componentCls:t,antCls:n,colorTextQuaternary:r,paddingXXS:o,colorPickerPresetColorSize:i,fontSizeSM:a,colorText:l,lineHeightSM:u,lineWidth:d,borderRadius:m,colorFill:p,colorWhite:g,marginXXS:b,paddingXS:y,fontHeightSM:S}=e;return {[`${t}-presets`]:{[`${n}-collapse-item > ${n}-collapse-header`]:{padding:0,[`${n}-collapse-expand-icon`]:{height:S,color:r,paddingInlineEnd:o}},[`${n}-collapse`]:{display:"flex",flexDirection:"column",gap:b},[`${n}-collapse-item > ${n}-collapse-panel > ${n}-collapse-body`]:{padding:`${oe(y)} 0`},"&-label":{fontSize:a,color:l,lineHeight:u},"&-items":{display:"flex",flexWrap:"wrap",gap:e.calc(b).mul(1.5).equal(),[`${t}-presets-color`]:{position:"relative",cursor:"pointer",width:i,height:i,"&::before":{content:'""',pointerEvents:"none",width:e.calc(i).add(e.calc(d).mul(4)).equal(),height:e.calc(i).add(e.calc(d).mul(4)).equal(),position:"absolute",top:e.calc(d).mul(-2).equal(),insetInlineStart:e.calc(d).mul(-2).equal(),borderRadius:m,border:`${oe(d)} solid transparent`,transition:`border-color ${e.motionDurationMid} ${e.motionEaseInBack}`},"&:hover::before":{borderColor:p},"&::after":{boxSizing:"border-box",position:"absolute",top:"50%",insetInlineStart:"21.5%",display:"table",width:e.calc(i).div(13).mul(5).equal(),height:e.calc(i).div(13).mul(8).equal(),border:`${oe(e.lineWidthBold)} solid ${e.colorWhite}`,borderTop:0,borderInlineStart:0,transform:"rotate(45deg) scale(0) translate(-50%,-50%)",opacity:0,content:'""',transition:`all ${e.motionDurationFast} ${e.motionEaseInBack}, opacity ${e.motionDurationFast}`},[`&${t}-presets-color-checked`]:{"&::after":{opacity:1,borderColor:g,transform:"rotate(45deg) scale(1) translate(-50%,-50%)",transition:`transform ${e.motionDurationMid} ${e.motionEaseOutBack} ${e.motionDurationFast}`},[`&${t}-presets-color-bright`]:{"&::after":{borderColor:"rgba(0, 0, 0, 0.45)"}}}}},"&-empty":{fontSize:a,color:r}}}},mme=e=>{const{componentCls:t,colorPickerInsetShadow:n,colorBgElevated:r,colorFillSecondary:o,lineWidthBold:i,colorPickerHandlerSizeSM:a,colorPickerSliderHeight:l,marginSM:u,marginXS:d}=e,m=e.calc(a).sub(e.calc(i).mul(2).equal()).equal(),p=e.calc(a).add(e.calc(i).mul(2).equal()).equal(),g={"&:after":{transform:"scale(1)",boxShadow:`${n}, 0 0 0 1px ${e.colorPrimaryActive}`}};return {[`${t}-slider`]:[eH(oe(l),e.colorFillSecondary),{margin:0,padding:0,height:l,borderRadius:e.calc(l).div(2).equal(),"&-rail":{height:l,borderRadius:e.calc(l).div(2).equal(),boxShadow:n},[`& ${t}-slider-handle`]:{width:m,height:m,top:0,borderRadius:"100%","&:before":{display:"block",position:"absolute",background:"transparent",left:{_skip_check_:true,value:"50%"},top:"50%",transform:"translate(-50%, -50%)",width:p,height:p,borderRadius:"100%"},"&:after":{width:a,height:a,border:`${oe(i)} solid ${r}`,boxShadow:`${n}, 0 0 0 1px ${o}`,outline:"none",insetInlineStart:e.calc(i).mul(-1).equal(),top:e.calc(i).mul(-1).equal(),background:"transparent",transition:"none"},"&:focus":g}}],[`${t}-slider-container`]:{display:"flex",gap:u,marginBottom:u,[`${t}-slider-group`]:{flex:1,flexDirection:"column",justifyContent:"space-between",display:"flex","&-disabled-alpha":{justifyContent:"center"}}},[`${t}-gradient-slider`]:{marginBottom:d,[`& ${t}-slider-handle`]:{"&:after":{transform:"scale(0.8)"},"&-active, &:focus":g}}}},KE=(e,t,n)=>({borderInlineEndWidth:e.lineWidth,borderColor:t,boxShadow:`0 0 0 ${oe(e.controlOutlineWidth)} ${n}`,outline:0}),hme=e=>{const{componentCls:t}=e;return {"&-rtl":{[`${t}-presets-color`]:{"&::after":{direction:"ltr"}},[`${t}-clear`]:{"&::after":{direction:"ltr"}}}}},N8=(e,t,n)=>{const{componentCls:r,borderRadiusSM:o,lineWidth:i,colorSplit:a,colorBorder:l,red6:u}=e;return {[`${r}-clear`]:{width:t,height:t,borderRadius:o,border:`${oe(i)} solid ${a}`,position:"relative",overflow:"hidden",cursor:"inherit",transition:`all ${e.motionDurationFast}`,...n,"&::after":{content:'""',position:"absolute",insetInlineEnd:e.calc(i).mul(-1).equal(),top:e.calc(i).mul(-1).equal(),display:"block",width:40,height:2,transformOrigin:"calc(100% - 1px) 1px",transform:"rotate(-45deg)",backgroundColor:u},"&:hover":{borderColor:l}}}},pme=e=>{const{componentCls:t,colorError:n,colorWarning:r,colorErrorHover:o,colorWarningHover:i,colorErrorOutline:a,colorWarningOutline:l}=e;return {[`&${t}-status-error`]:{borderColor:n,"&:hover":{borderColor:o},[`&${t}-trigger-active`]:{...KE(e,n,a)}},[`&${t}-status-warning`]:{borderColor:r,"&:hover":{borderColor:i},[`&${t}-trigger-active`]:{...KE(e,r,l)}}}},gme=e=>{const{componentCls:t,controlHeightLG:n,controlHeightSM:r,controlHeight:o,controlHeightXS:i,borderRadius:a,borderRadiusSM:l,borderRadiusXS:u,borderRadiusLG:d,fontSizeLG:m}=e;return {[`&${t}-lg`]:{minWidth:n,minHeight:n,borderRadius:d,[`${t}-color-block, ${t}-clear`]:{width:o,height:o,borderRadius:a},[`${t}-trigger-text`]:{fontSize:m}},[`&${t}-sm`]:{minWidth:r,minHeight:r,borderRadius:l,[`${t}-color-block, ${t}-clear`]:{width:i,height:i,borderRadius:u},[`${t}-trigger-text`]:{lineHeight:oe(i)}}}},vme=e=>{const{antCls:t,componentCls:n,colorPickerWidth:r,colorPrimary:o,motionDurationMid:i,colorBgElevated:a,colorTextDisabled:l,colorText:u,colorBgContainerDisabled:d,borderRadius:m,marginXS:p,marginSM:g,controlHeight:b,controlHeightSM:y,colorBgTextActive:S,colorPickerPresetColorSize:C,colorPickerPreviewSize:w,lineWidth:$,colorBorder:M,paddingXXS:T,fontSize:R,colorPrimaryHover:I,controlOutline:N}=e;return [{[n]:{[`${n}-inner`]:{"&-content":{display:"flex",flexDirection:"column",width:r,[`& > ${t}-divider`]:{margin:`${oe(g)} 0 ${oe(p)}`}},[`${n}-panel`]:{...dme(e)},...mme(e),...A8(e,w),...ume(e),...fme(e),...N8(e,C,{marginInlineStart:"auto"}),[`${n}-operation`]:{display:"flex",justifyContent:"space-between",marginBottom:p}},"&-trigger":{minWidth:b,minHeight:b,borderRadius:m,border:`${oe($)} solid ${M}`,cursor:"pointer",display:"inline-flex",alignItems:"flex-start",justifyContent:"center",transition:`all ${i}`,background:a,padding:e.calc(T).sub($).equal(),[`${n}-trigger-text`]:{marginInlineStart:p,marginInlineEnd:e.calc(p).sub(e.calc(T).sub($)).equal(),fontSize:R,color:u,alignSelf:"center","&-cell":{"&:not(:last-child):after":{content:'", "'},"&-inactive":{color:l}}},"&:hover":{borderColor:I},[`&${n}-trigger-active`]:{...KE(e,o,N)},"&-disabled":{color:l,background:d,cursor:"not-allowed","&:hover":{borderColor:S},[`${n}-trigger-text`]:{color:l}},...N8(e,y),...A8(e,y),...pme(e),...gme(e)},...hme(e)}},If(e,{focusElCls:`${n}-trigger-active`})]},bme=Wt("ColorPicker",e=>{const{colorTextQuaternary:t,marginSM:n}=e,r=8,o=Ft(e,{colorPickerWidth:234,colorPickerHandlerSize:16,colorPickerHandlerSizeSM:12,colorPickerAlphaInputWidth:44,colorPickerInputNumberHandleWidth:16,colorPickerPresetColorSize:24,colorPickerInsetShadow:`inset 0 0 1px 0 ${t}`,colorPickerSliderHeight:r,colorPickerPreviewSize:e.calc(r).mul(2).add(n).equal()});return vme(o)}),nT=e=>{const{mode:t,value:n,defaultValue:r,format:o,defaultFormat:i,allowClear:a=false,presets:l,children:u,trigger:d="click",open:m,disabled:p,placement:g="bottomLeft",arrow:b,panelRender:y,showText:S,style:C,className:w,size:$,rootClassName:M,prefixCls:T,styles:R,classNames:I,disabledAlpha:N=false,onFormatChange:P,onChange:O,onClear:_,onOpenChange:B,onChangeComplete:V,getPopupContainer:U,autoAdjustOverflow:G=true,destroyTooltipOnHide:H,destroyOnHidden:z,disabledFormat:j,...W}=e,{getPrefixCls:Y,direction:Q,className:D,style:L,classNames:K,styles:J,arrow:ee}=jt("colorPicker"),te=f.useContext(no),re=p??te,ie=Y("color-picker",T),de=l1(b,ee),{compactSize:ne,compactItemClassnames:ce}=ks(ie,Q),fe=so(be=>$??ne??be),se={...e,trigger:d,allowClear:a,autoAdjustOverflow:G,disabledAlpha:N,arrow:de,placement:g,disabled:re,size:fe},[Me,ae]=Kt([K,I],[J,R],{props:se},{popup:{_default:"root"}}),[pe,Ce]=un(false,m),xe=!re&&pe,[Ae,Xe]=un(i,o),Ne=be=>{Xe(be),Ae!==be&&P?.(be);},ue=be=>{(!be||!re)&&(Ce(be),B?.(be));},[ge,Pe,je,qe,Ue]=cme(r,n,t),et=f.useMemo(()=>vR(ge)<100,[ge]),[rt,Ke]=q.useState(null),_e=be=>{if(V){let Se=ro(be);N&&et&&(Se=Wb(be)),V(Se);}},We=(be,Se)=>{let he=ro(be);N&&et&&(he=Wb(he)),Pe(he),Ke(null),O&&O(he,he.toCssString()),Se||_e(he);},[Ze,Be]=q.useState(0),[Oe,lt]=q.useState(false),It=be=>{if(qe(be),be==="single"&&ge.isGradient())Be(0),We(new Go(ge.getColors()[0].color)),Ke(ge);else if(be==="gradient"&&!ge.isGradient()){const Se=et?Wb(ge):ge;We(new Go(rt||[{percent:0,color:Se},{percent:100,color:Se}]));}},{status:mt}=q.useContext(So),Bt=Qn(ie),[xt,Tt]=bme(ie,Bt),ut={[`${ie}-rtl`]:Q},dt=X(M,Tt,Bt,ut),gt=X(jl(ie,mt),{[`${ie}-sm`]:fe==="small",[`${ie}-lg`]:fe==="large"},ce,D,dt,w,xt),Fe=X(ie,dt,Me.popup?.root),Qe={open:xe,trigger:d,placement:g,arrow:de,rootClassName:M,getPopupContainer:U,autoAdjustOverflow:G,destroyOnHidden:z??!!H},ye={...L,...C};return q.createElement(Zo,{classNames:{root:Fe},styles:{root:ae.popup?.root,container:R?.popupOverlayInner},onOpenChange:ue,content:q.createElement(Vl,{form:true},q.createElement(sme,{mode:je,onModeChange:It,modeOptions:Ue,prefixCls:ie,value:ge,allowClear:a,disabled:re,disabledAlpha:N,presets:l,panelRender:y,format:Ae,onFormatChange:Ne,onChange:We,onChangeComplete:_e,onClear:_,activeIndex:Ze,onActive:Be,gradientDragging:Oe,onGradientDragging:lt,disabledFormat:j})),...Qe},u||q.createElement(lme,{activeIndex:xe?Ze:-1,open:xe,className:gt,style:ye,classNames:Me,styles:ae,prefixCls:ie,disabled:re,showText:S,format:Ae,...W,color:ge}))},yme=RR(nT,void 0,e=>({...e,placement:"bottom",autoAdjustOverflow:false}),"color-picker",e=>e);nT._InternalPanelDoNotUseOrYouWillBeFired=yme;function ty(e){return ["small","middle","large"].includes(e)}function P8(e){return e?typeof e=="number"&&!Number.isNaN(e):false}const tH=q.createContext({latestIndex:0}),Sme=tH.Provider,Cme=e=>{const{className:t,prefix:n,index:r,children:o,separator:i,style:a,classNames:l,styles:u}=e,{latestIndex:d}=f.useContext(tH);return Jr(o)?f.createElement(f.Fragment,null,f.createElement("div",{className:t,style:a},o),r<d&&i&&f.createElement("span",{className:X(`${n}-item-separator`,l?.separator),style:u?.separator},i)):null},xme=e=>{const{componentCls:t,antCls:n}=e;return {[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},[`${t}-item:empty`]:{display:"none"},[`${t}-item > ${n}-badge-not-a-wrapper:only-child`]:{display:"block"}}}},wme=e=>{const{componentCls:t}=e;return {[t]:{"&-gap-row-small":{rowGap:e.spaceGapSmallSize},"&-gap-row-middle":{rowGap:e.spaceGapMiddleSize},"&-gap-row-large":{rowGap:e.spaceGapLargeSize},"&-gap-col-small":{columnGap:e.spaceGapSmallSize},"&-gap-col-middle":{columnGap:e.spaceGapMiddleSize},"&-gap-col-large":{columnGap:e.spaceGapLargeSize}}}},$me=Wt("Space",e=>{const t=Ft(e,{spaceGapSmallSize:e.paddingXS,spaceGapMiddleSize:e.padding,spaceGapLargeSize:e.paddingLG});return [xme(t),wme(t)]},()=>({}),{resetStyle:false}),Eme=f.forwardRef((e,t)=>{const{getPrefixCls:n,direction:r,size:o,className:i,style:a,classNames:l,styles:u}=jt("space"),{size:d=o??"small",align:m,className:p,rootClassName:g,children:b,direction:y,orientation:S,prefixCls:C,split:w,separator:$,style:M,vertical:T,wrap:R=false,classNames:I,styles:N,...P}=e,[O,_]=Array.isArray(d)?d:[d,d],B=ty(_),V=ty(O),U=P8(_),G=P8(O),H=Qo(b,{keepEmpty:true}),[z,j]=xu(S,T,y),W=m===void 0&&!j?"center":m,Y=$??w,Q=n("space",C),[D,L]=$me(Q),K={...e,size:d,orientation:z,align:W},[J,ee]=Kt([l,I],[u,N],{props:K}),te=X(Q,i,D,`${Q}-${z}`,{[`${Q}-rtl`]:r==="rtl",[`${Q}-align-${W}`]:W,[`${Q}-gap-row-${_}`]:B,[`${Q}-gap-col-${O}`]:V},p,g,L,J.root),re=X(`${Q}-item`,J.item),ie=H.map((ce,fe)=>{const se=ce?.key||`${re}-${fe}`;return f.createElement(Cme,{prefix:Q,classNames:J,styles:ee,className:re,key:se,index:fe,separator:Y,style:ee.item},ce)}),de=f.useMemo(()=>({latestIndex:H.reduce((fe,se,Me)=>Jr(se)?Me:fe,0)}),[H]);if(H.length===0)return null;const ne={};return R&&(ne.flexWrap="wrap"),!V&&G&&(ne.columnGap=O),!B&&U&&(ne.rowGap=_),f.createElement("div",{ref:t,className:te,style:{...ne,...ee.root,...a,...M},...P},f.createElement(Sme,{value:de},ie))}),Zr=Eme;Zr.Compact=lR;Zr.Addon=U7;const nH=e=>{const{getPopupContainer:t,getPrefixCls:n,direction:r}=f.useContext(wt),{prefixCls:o,type:i="default",danger:a,disabled:l,loading:u,onClick:d,htmlType:m,children:p,className:g,menu:b,arrow:y,autoFocus:S,trigger:C,align:w,open:$,onOpenChange:M,placement:T,getPopupContainer:R,href:I,icon:N=f.createElement(UR,null),title:P,buttonsRender:O=ne=>ne,mouseEnterDelay:_,mouseLeaveDelay:B,overlayClassName:V,overlayStyle:U,destroyOnHidden:G,destroyPopupOnHide:H,dropdownRender:z,popupRender:j,...W}=e,Y=n("dropdown",o),Q=`${Y}-button`,L={menu:b,arrow:y,autoFocus:S,align:w,disabled:l,trigger:l?[]:C,onOpenChange:M,getPopupContainer:R||t,mouseEnterDelay:_,mouseLeaveDelay:B,classNames:{root:V},styles:{root:U},destroyOnHidden:G,popupRender:j||z},{compactSize:K,compactItemClassnames:J}=ks(Y,r),ee=X(Q,J,g);"destroyPopupOnHide"in e&&(L.destroyPopupOnHide=H),"open"in e&&(L.open=$),"placement"in e?L.placement=T:L.placement=r==="rtl"?"bottomLeft":"bottomRight";const te=f.createElement(st,{type:i,danger:a,disabled:l,loading:u,onClick:d,htmlType:m,href:I,title:P},p),re=f.createElement(st,{type:i,danger:a,icon:N}),[ie,de]=O([te,re]);return f.createElement(Zr.Compact,{className:ee,size:K,block:true,...W},ie,f.createElement(m1,{...L},de))};nH.__ANT_BUTTON=true;const tc=m1;tc.Button=nH;const rH=["wrap","nowrap","wrap-reverse"],oH=["flex-start","flex-end","start","end","center","space-between","space-around","space-evenly","stretch","normal","left","right"],iH=["center","start","end","flex-start","flex-end","self-start","self-end","baseline","normal","stretch"],Mme=(e,t)=>{const n=t.wrap===true?"wrap":t.wrap;return {[`${e}-wrap-${n}`]:n&&rH.includes(n)}},Rme=(e,t)=>{const n={};return iH.forEach(r=>{n[`${e}-align-${r}`]=t.align===r;}),n[`${e}-align-stretch`]=!t.align&&!!t.vertical,n},Tme=(e,t)=>{const n={};return oH.forEach(r=>{n[`${e}-justify-${r}`]=t.justify===r;}),n},Ame=(e,t)=>X({...Mme(e,t),...Rme(e,t),...Tme(e,t)}),Nme=e=>{const{componentCls:t}=e;return {[t]:{display:"flex",margin:0,padding:0,"&-vertical":{flexDirection:"column"},"&-rtl":{direction:"rtl"},"&:empty":{display:"none"}}}},Pme=e=>{const{componentCls:t}=e;return {[t]:{"&-gap-small":{gap:e.flexGapSM},"&-gap-middle":{gap:e.flexGap},"&-gap-large":{gap:e.flexGapLG}}}},Ime=e=>{const{componentCls:t}=e,n={};return rH.forEach(r=>{n[`${t}-wrap-${r}`]={flexWrap:r};}),n},Ome=e=>{const{componentCls:t}=e,n={};return iH.forEach(r=>{n[`${t}-align-${r}`]={alignItems:r};}),n},Dme=e=>{const{componentCls:t}=e,n={};return oH.forEach(r=>{n[`${t}-justify-${r}`]={justifyContent:r};}),n},_me=()=>({}),Bme=Wt("Flex",e=>{const{paddingXS:t,padding:n,paddingLG:r}=e,o=Ft(e,{flexGapSM:t,flexGap:n,flexGapLG:r});return [Nme(o),Pme(o),Ime(o),Ome(o),Dme(o)]},_me,{resetStyle:false}),Lme=q.forwardRef((e,t)=>{const{prefixCls:n,rootClassName:r,className:o,style:i,flex:a,gap:l,vertical:u,orientation:d,component:m="div",children:p,...g}=e,{flex:b,direction:y,getPrefixCls:S}=q.useContext(wt),C=S("flex",n),[w,$]=Bme(C),[,M]=xu(d,u??b?.vertical),T=X(o,r,b?.className,C,w,$,Ame(C,{...e,vertical:M}),{[`${C}-rtl`]:y==="rtl",[`${C}-gap-${l}`]:ty(l),[`${C}-vertical`]:M}),R={...b?.style,...i};return Jr(a)&&(R.flex=a),Jr(l)&&!ty(l)&&(R.gap=l),q.createElement(m,{ref:t,className:T,style:R,...Ln(g,["justify","wrap","align"])},p)}),ny=q.createContext(null);var zme={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M854.6 288.6L639.4 73.4c-6-6-14.1-9.4-22.6-9.4H192c-17.7 0-32 14.3-32 32v832c0 17.7 14.3 32 32 32h640c17.7 0 32-14.3 32-32V311.3c0-8.5-3.4-16.7-9.4-22.7zM790.2 326H602V137.8L790.2 326zm1.8 562H232V136h302v216a42 42 0 0042 42h216v494zM504 618H320c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM312 490v48c0 4.4 3.6 8 8 8h384c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H320c-4.4 0-8 3.6-8 8z"}}]},name:"file-text",theme:"outlined"};function YE(){return YE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},YE.apply(this,arguments)}const kme=(e,t)=>f.createElement(Xn,YE({},e,{ref:t,icon:zme})),aH=f.forwardRef(kme),Fme=(e,t)=>Jr(e)?typeof e=="object"&&!f.isValidElement(e)?{...t,...e}:{...t,title:e}:null,Hme=e=>{const{componentCls:t,floatButtonSize:n,iconCls:r,antCls:o,floatButtonIconSize:i}=e,[a,l]=tr(o,"float-btn"),u=`${t}-badge`,d=Math.SQRT2,m=(d-1)/d,p=e.calc(e.borderRadius).mul(m).equal(),g=e.calc(e.controlHeight).div(2).mul(m).equal();return {[t]:[{[a("size")]:oe(n)},{flexDirection:"column",margin:0,padding:`${oe(e.paddingXXS)} 0`,width:l("size"),minHeight:l("size"),height:"auto",wordBreak:"break-word",whiteSpace:"normal",gap:e.calc(e.paddingXXS).div(2).equal(),"&-rtl":{direction:"rtl"},[`&${t}-individual`]:{position:"fixed",zIndex:e.zIndexPopupBase,insetInlineEnd:e.floatButtonInsetInlineEnd,bottom:e.floatButtonInsetBlockEnd,boxShadow:e.boxShadowSecondary},[`&${t}-pure`]:{position:"relative",inset:"auto"},"&:empty":{display:"none"},[`${t}-icon`]:{lineHeight:1},[`&${t}-icon-only`]:{[r]:{fontSize:i}},[`${t}-content`]:{fontSize:e.fontSizeSM},[u]:{position:"absolute",top:0,insetInlineEnd:0,[`&:not(${u}-dot)`]:{transform:"translate(50%, -50%)"}},[`&-rtl ${u}:not(${u}-dot)`]:{transform:"translate(-50%, -50%)"},"&-square":{[`${u}-dot`]:{marginTop:p,marginInlineEnd:p}},"&-circle":{[u]:{marginTop:g,marginInlineEnd:g}}}]}},Vme=e=>{const{componentCls:t,antCls:n,floatButtonSize:r,padding:o}=e,i=`${t}-group`,a=`${i}-list`,[l,u]=tr(n,"float-btn");return {[i]:[{[l("list-transform-start")]:`translate(0,${oe(r)})`,[l("list-trigger-offset")]:`calc(${oe(r)} + ${oe(o)})`},{...dn(e),position:"fixed",zIndex:e.zIndexPopupBase,insetInlineEnd:e.floatButtonInsetInlineEnd,bottom:e.floatButtonInsetBlockEnd,gap:o,"&-rtl":{direction:"rtl"},[`&${t}-pure`]:{position:"relative",inset:"auto"},[t]:{position:"relative",inset:"auto"}},{[`&:not(${i}-individual) ${a}`]:{boxShadow:e.boxShadowSecondary},[`&${i}-individual ${a}`]:{gap:o},[`&-menu-mode ${a}`]:{position:"absolute"},[a]:{borderRadius:e.borderRadiusLG,"&-motion":{transition:`all ${e.motionDurationSlow}`,"&-enter, &-appear":{opacity:0,transform:u("list-transform-start"),"&-active":{opacity:1,transform:"translate(0, 0)"}},"&-leave":{"&-active":{opacity:0,transform:u("list-transform-start")}}}},"&-top":{[a]:{bottom:u("list-trigger-offset")}},"&-bottom":{[a]:{[l("list-transform-start")]:`translate(0, calc(${oe(r)} * -1))`,top:u("list-trigger-offset")}},"&-left":{[a]:{[l("list-transform-start")]:`translate(${oe(r)}, 0)`,right:u("list-trigger-offset")}},"&-right":{[a]:{[l("list-transform-start")]:`translate(calc(${oe(r)} * -1), 0)`,left:u("list-trigger-offset")}}}]}},jme=()=>({}),sH=Wt("FloatButton",e=>{const{controlHeightLG:t,marginXXL:n,marginLG:r,fontSizeIcon:o,calc:i}=e,a=Ft(e,{floatButtonIconSize:i(o).mul(1.5).equal(),floatButtonSize:t,floatButtonInsetBlockEnd:n,floatButtonInsetInlineEnd:r});return [Hme(a),Vme(a),fR(e)]},jme,{order:-998}),v1="float-btn",Ume=q.forwardRef((e,t)=>{const{prefixCls:n,className:r,rootClassName:o,style:i,type:a="default",shape:l="circle",icon:u,description:d,content:m,tooltip:p,badge:g={},classNames:b,styles:y,...S}=e,{getPrefixCls:C,direction:w}=q.useContext(wt),$=q.useContext(ny),M=C(v1,n),T=Qn(M),{shape:R,individual:I,classNames:N,styles:P}=$||{},O=R||l,_=I??true,B=m??d,V={...e,type:a,shape:O},[U,G]=sH(M,T),H=q.useMemo(()=>({icon:`${M}-icon`,content:`${M}-content`}),[M]),[z,j]=Kt([H,N,b],[P,y],{props:V}),W=!B&&!u?q.createElement(aH,null):u,[Y]=wu("FloatButton",i?.zIndex),Q={...i,zIndex:Y},D=Ln(g,["title","children","status","text"]),L="badge"in e&&q.createElement(u1,{...D,className:X(D.className,`${M}-badge`,{[`${M}-badge-dot`]:D.dot})}),K=Fme(p);let J=q.createElement(st,{...S,ref:t,className:X(U,G,T,M,r,o,`${M}-${a}`,`${M}-${O}`,{[`${M}-rtl`]:w==="rtl",[`${M}-individual`]:_,[`${M}-icon-only`]:!B}),classNames:z,styles:j,style:Q,shape:O,type:a,size:"large",icon:W,_skipSemantic:true},B,L);return K&&(J=q.createElement(Jl,{...K},J)),J}),Mu=Ume,Wme=q.createElement(bce,null),lH=q.forwardRef((e,t)=>{const{backTopIcon:n}=jt("floatButton"),{prefixCls:r,className:o,type:i="default",shape:a="circle",visibilityHeight:l=400,icon:u,target:d,onClick:m,duration:p=450,...g}=e,b=u??n??Wme,[y,S]=f.useState(l===0),C=q.useRef(null);q.useImperativeHandle(t,()=>({nativeElement:C.current}));const w=()=>C.current?.ownerDocument||window,$=EJ(_=>{const B=Zz(_.target);S(B>=l);});f.useEffect(()=>{const B=(d||w)();return $({target:B}),B?.addEventListener("scroll",$),()=>{$.cancel(),B?.removeEventListener("scroll",$);}},[d]);const M=_=>{sne(0,{getContainer:d||w,duration:p}),m?.(_);},{getPrefixCls:T}=f.useContext(wt),R=T(v1,r),I=T(),P=f.useContext(ny)?.shape||a,O={prefixCls:R,icon:b,type:i,shape:P,...g};return q.createElement(Co,{visible:y,motionName:`${I}-fade`},({className:_},B)=>q.createElement(Mu,{ref:Vr(C,B),...O,onClick:M,className:X(o,_)}))}),cH=e=>{const{prefixCls:t,className:n,style:r,classNames:o,styles:i,rootClassName:a,shape:l="circle",type:u="default",placement:d,icon:m=q.createElement(aH,null),closeIcon:p,trigger:g,children:b,onOpenChange:y,open:S,onClick:C,...w}=e,{direction:$,getPrefixCls:M,closeIcon:T,classNames:R,styles:I,className:N,style:P}=jt("floatButtonGroup"),O=p??T??q.createElement(Ls,null),_=M(v1,t),B=Qn(_),[V,U]=sH(_,B),G=`${_}-group`,H=g&&["click","hover"].includes(g),[z]=wu("FloatButton",r?.zIndex),j=q.useRef(null),W=["top","left","right","bottom"].includes(d)?d:"top",[Y,Q]=un(false,S),D=g==="hover",L=g==="click",K=Mt(pe=>{Y!==pe&&(Q(pe),y?.(pe));}),J=()=>{D&&K(true);},ee=()=>{D&&K(false);},te=pe=>{L&&K(!Y),C?.(pe);};q.useEffect(()=>{if(L){const pe=Ce=>{j.current?.contains(Ce.target)||K(false);};return document.addEventListener("click",pe,{capture:true}),()=>document.removeEventListener("click",pe,{capture:true})}},[L]);const re=l==="circle",ie={...e,shape:l,type:u,placement:W},[de,ne]=Kt([R,o],[I,i],{props:ie}),ce=q.useMemo(()=>({shape:l,individual:re,classNames:{root:de.item,icon:de.itemIcon,content:de.itemContent},styles:{root:ne.item,icon:ne.itemIcon,content:ne.itemContent}}),[l,re,de,ne]),fe=q.useMemo(()=>({...ce,individual:true,classNames:{root:de.trigger,icon:de.triggerIcon,content:de.triggerContent},styles:{root:ne.trigger,icon:ne.triggerIcon,content:ne.triggerContent}}),[ce,de,ne]);let se;const Me=`${G}-list`,ae=pe=>{const Ce=W==="top"||W==="bottom",xe={className:X(Me,de.list,pe),style:ne.list};return re?se=q.createElement(Lme,{vertical:Ce,...xe},b):se=q.createElement(Zr.Compact,{vertical:Ce,...xe},b),se};return q.createElement(ny.Provider,{value:ce},q.createElement("div",{className:X(G,V,U,B,N,de.root,n,a,{[`${G}-rtl`]:$==="rtl",[`${G}-individual`]:re,[`${G}-${W}`]:H,[`${G}-menu-mode`]:H}),style:{...P,zIndex:z,...ne.root,...r},ref:j,onMouseEnter:J,onMouseLeave:ee},H?q.createElement(Co,{visible:Y,motionName:`${Me}-motion`},({className:pe})=>ae(pe)):ae(),H&&q.createElement(ny.Provider,{value:fe},q.createElement(Mu,{type:u,icon:Y?O:m,"aria-label":e["aria-label"],className:`${G}-trigger`,onClick:te,...w}))))},I8=({backTop:e,...t})=>e?f.createElement(lH,{...t,visibilityHeight:0}):f.createElement(Mu,{...t}),Gme=({className:e,items:t,classNames:n,styles:r,prefixCls:o,...i})=>{const{getPrefixCls:a}=f.useContext(wt),u=`${a(v1,o)}-pure`;return t?f.createElement(cH,{className:X(e,u),classNames:n,styles:r,...i},t.map((d,m)=>f.createElement(I8,{key:m,...d}))):f.createElement(I8,{className:X(e,u),classNames:n,styles:r,...i})};Mu.BackTop=lH;Mu.Group=cH;Mu._InternalPanelDoNotUseOrYouWillBeFired=Gme;const qme=e=>{const{getPrefixCls:t,direction:n}=f.useContext(wt),{prefixCls:r,className:o}=e,i=t("input-group",r),a=t("input"),[l,u]=T7(a),d=X(i,u,{[`${i}-lg`]:e.size==="large",[`${i}-sm`]:e.size==="small",[`${i}-compact`]:e.compact,[`${i}-rtl`]:n==="rtl"},l,o),m=f.useContext(So),p=f.useMemo(()=>({...m,isFormItemInput:false}),[m]);return f.createElement(So.Provider,{value:p},f.createElement(Zr.Compact,{className:d,style:e.style,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,onFocus:e.onFocus,onBlur:e.onBlur},e.children))},Kme=e=>{const{componentCls:t,paddingXS:n}=e;return {[t]:{display:"inline-flex",alignItems:"center",flexWrap:"nowrap",columnGap:n,[`${t}-input-wrapper`]:{position:"relative",[`${t}-mask-icon`]:{position:"absolute",zIndex:"1",top:"50%",right:"50%",transform:"translate(50%, -50%)",pointerEvents:"none"},[`${t}-mask-input`]:{color:"transparent",caretColor:e.colorText},[`${t}-mask-input[type=number]::-webkit-inner-spin-button`]:{"-webkit-appearance":"none",margin:0},[`${t}-mask-input[type=number]`]:{"-moz-appearance":"textfield"}},"&-rtl":{direction:"rtl"},[`${t}-input`]:{textAlign:"center",paddingInline:e.paddingXXS},[`&${t}-sm ${t}-input`]:{paddingInline:e.calc(e.paddingXXS).div(2).equal()},[`&${t}-lg ${t}-input`]:{paddingInline:e.paddingXS}}}},Yme=Wt(["Input","OTP"],e=>{const t=Ft(e,Lf(e));return Kme(t)},zf),Xme=f.forwardRef((e,t)=>{const{className:n,value:r,onChange:o,onActiveChange:i,index:a,mask:l,onFocus:u,...d}=e,{getPrefixCls:m}=f.useContext(wt),p=m("otp"),g=typeof l=="string"?l:r,b=f.useRef(null);f.useImperativeHandle(t,()=>b.current);const y=$=>{o(a,$.target.value);},S=()=>{Lt(()=>{const $=b.current?.input;document.activeElement===$&&$&&$.select();});},C=$=>{u?.($),S();},w=$=>{const{key:M,ctrlKey:T,metaKey:R}=$;M==="ArrowLeft"?i(a-1):M==="ArrowRight"?i(a+1):M==="z"&&(T||R)?$.preventDefault():M==="Backspace"&&!r&&i(a-1),S();};return f.createElement("span",{className:`${p}-input-wrapper`,role:"presentation"},l&&r!==""&&r!==void 0&&f.createElement("span",{className:`${p}-mask-icon`,"aria-hidden":"true"},g),f.createElement(kf,{"aria-label":`OTP Input ${a+1}`,type:l===true?"password":"text",...d,ref:b,value:r,onInput:y,onFocus:C,onKeyDown:w,onMouseDown:S,onMouseUp:S,className:X(n,{[`${p}-mask-input`]:l})}))});function db(e){return (e||"").split("")}const Qme=e=>{const{index:t,prefixCls:n,separator:r,className:o,style:i}=e,a=typeof r=="function"?r(t):r;return a?f.createElement("span",{className:X(`${n}-separator`,o),style:i},a):null},Zme=f.forwardRef((e,t)=>{const{prefixCls:n,length:r=6,size:o,defaultValue:i,value:a,onChange:l,formatter:u,separator:d,variant:m,disabled:p,status:g,autoFocus:b,mask:y,type:S,autoComplete:C,onInput:w,onFocus:$,inputMode:M,classNames:T,styles:R,className:I,style:N,...P}=e,{classNames:O,styles:_,getPrefixCls:B,direction:V,style:U,className:G}=jt("otp"),H=B("otp",n),z={...e,length:r},[j,W]=Kt([O,T],[_,R],{props:z}),Y=yo(P,{aria:true,data:true,attr:true}),[Q,D]=Yme(H),L=so(Ce=>o??Ce),K=f.useContext(So),J=Df(K.status,g),ee=f.useMemo(()=>({...K,status:J,hasFeedback:false,feedbackIcon:null}),[K,J]),te=f.useRef(null),re=f.useRef({});f.useImperativeHandle(t,()=>({focus:()=>{re.current[0]?.focus();},blur:()=>{for(let Ce=0;Ce<r;Ce+=1)re.current[Ce]?.blur();},nativeElement:te.current}));const ie=Ce=>u?u(Ce):Ce,[de,ne]=f.useState(()=>db(ie(i||"")));f.useEffect(()=>{a!==void 0&&ne(db(a));},[a]);const ce=Mt(Ce=>{ne(Ce),w&&w(Ce),l&&Ce.length===r&&Ce.every(xe=>xe)&&Ce.some((xe,Ae)=>de[Ae]!==xe)&&l(Ce.join(""));}),fe=Mt((Ce,xe)=>{let Ae=qt(de);for(let Ne=0;Ne<Ce;Ne+=1)Ae[Ne]||(Ae[Ne]="");xe.length<=1?Ae[Ce]=xe:Ae=Ae.slice(0,Ce).concat(db(xe)),Ae=Ae.slice(0,r);for(let Ne=Ae.length-1;Ne>=0&&!Ae[Ne];Ne-=1)Ae.pop();const Xe=ie(Ae.map(Ne=>Ne||" ").join(""));return Ae=db(Xe).map((Ne,ue)=>Ne===" "&&!Ae[ue]?Ae[ue]:Ne),Ae}),se=(Ce,xe)=>{const Ae=fe(Ce,xe),Xe=Math.min(Ce+xe.length,r-1);Xe!==Ce&&Ae[Ce]!==void 0&&re.current[Xe]?.focus(),ce(Ae);},Me=Ce=>{re.current[Ce]?.focus();},ae=(Ce,xe)=>{for(let Ae=0;Ae<xe;Ae+=1)if(!re.current[Ae]?.input?.value){re.current[Ae]?.focus();break}$?.(Ce);},pe={variant:m,disabled:p,status:J,mask:y,type:S,inputMode:M,autoComplete:C};return f.createElement("div",{...Y,ref:te,className:X(I,H,{[`${H}-sm`]:L==="small",[`${H}-lg`]:L==="large",[`${H}-rtl`]:V==="rtl"},D,Q,G,j.root),style:{...W.root,...U,...N},role:"group"},f.createElement(So.Provider,{value:ee},Array.from({length:r}).map((Ce,xe)=>{const Ae=`otp-${xe}`,Xe=de[xe]||"";return f.createElement(f.Fragment,{key:Ae},f.createElement(Xme,{ref:Ne=>{re.current[xe]=Ne;},index:xe,size:L,htmlSize:1,className:X(j.input,`${H}-input`),style:W.input,onChange:se,value:Xe,onActiveChange:Me,autoFocus:xe===0&&b,onFocus:Ne=>ae(Ne,xe),...pe}),xe<r-1&&f.createElement(Qme,{separator:d,index:xe,prefixCls:H,className:X(j.separator),style:W.separator}))})))});var Jme={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"};function XE(){return XE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},XE.apply(this,arguments)}const ehe=(e,t)=>f.createElement(Xn,XE({},e,{ref:t,icon:Jme})),the=f.forwardRef(ehe);var nhe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"};function QE(){return QE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},QE.apply(this,arguments)}const rhe=(e,t)=>f.createElement(Xn,QE({},e,{ref:t,icon:nhe})),ohe=f.forwardRef(rhe),ihe=e=>e?f.createElement(ohe,null):f.createElement(the,null),ahe={click:"onClick",hover:"onMouseOver"},she=f.forwardRef((e,t)=>{const{disabled:n,action:r="click",visibilityToggle:o=true,iconRender:i=ihe,suffix:a}=e,l=f.useContext(no),u=n??l,d=typeof o=="object"&&o.visible!==void 0,[m,p]=f.useState(()=>d?o.visible:false),g=f.useRef(null);f.useEffect(()=>{d&&p(o.visible);},[d,o]);const b=Y7(g),y=()=>{if(u)return;m&&b();const B=!m;p(B),typeof o=="object"&&o.onVisibleChange?.(B);},S=B=>{const V=ahe[r]||"",U=i(m),G={[V]:y,className:`${B}-icon`,key:"passwordIcon",onMouseDown:H=>{H.preventDefault();},onMouseUp:H=>{H.preventDefault();}};return f.cloneElement(f.isValidElement(U)?U:f.createElement("span",null,U),G)},{className:C,prefixCls:w,inputPrefixCls:$,size:M,...T}=e,{getPrefixCls:R}=f.useContext(wt),I=R("input",$),N=R("input-password",w),P=o&&S(N),O=X(N,C,{[`${N}-${M}`]:!!M}),_={...Ln(T,["suffix","iconRender","visibilityToggle"]),type:m?"text":"password",className:O,prefixCls:I,suffix:f.createElement(f.Fragment,null,P,a)};return M&&(_.size=M),f.createElement(kf,{ref:Vr(t,g),..._})}),lhe=e=>{const{componentCls:t}=e,n=`${t}-btn`;return {[t]:{width:"100%",[n]:{"&-filled":{background:e.colorFillTertiary,"&:not(:disabled)":{"&:hover":{background:e.colorFillSecondary},"&:active":{background:e.colorFill}}}}}}},che=Wt(["Input","Search"],e=>[lhe(e)]),uhe=f.forwardRef((e,t)=>{const{prefixCls:n,inputPrefixCls:r,className:o,size:i,style:a,enterButton:l=false,addonAfter:u,loading:d,disabled:m,onSearch:p,onChange:g,onCompositionStart:b,onCompositionEnd:y,variant:S,onPressEnter:C,classNames:w,styles:$,hidden:M,...T}=e,{direction:R,getPrefixCls:I,classNames:N,styles:P}=jt("inputSearch"),O={...e,enterButton:l},[_,B]=Kt([N,w],[P,$],{props:O},{button:{_default:"root"}}),V=f.useRef(false),U=I("input-search",n),G=I("input",r),[H,z]=che(U),{compactSize:j}=ks(U,R),W=so(ae=>i??j??ae),Y=f.useRef(null),Q=ae=>{ae?.target&&ae.type==="click"&&p&&p(ae.target.value,ae,{source:"clear"}),g?.(ae);},D=ae=>{document.activeElement===Y.current?.input&&ae.preventDefault();},L=ae=>{p&&p(Y.current?.input?.value,ae,{source:"input"});},K=ae=>{V.current||d||(C?.(ae),L(ae));},J=typeof l=="boolean"?f.createElement(DR,null):null,ee=`${U}-btn`,te=X(ee,{[`${ee}-${S}`]:S});let re;const ie=l||{},de=ie.type&&ie.type.__ANT_BUTTON===true;de||ie.type==="button"?re=Hr(ie,{onMouseDown:D,onClick:ae=>{ie?.props?.onClick?.(ae),L(ae);},key:"enterButton",...de?{className:te,size:W}:{}}):re=f.createElement(st,{classNames:_.button,styles:B.button,className:te,color:l?"primary":"default",size:W,disabled:m,key:"enterButton",onMouseDown:D,onClick:L,loading:d,icon:J,variant:S==="borderless"||S==="filled"||S==="underlined"?"text":l?"solid":void 0},l),u&&(re=[re,Hr(u,{key:"addonAfter"})]);const ne=X(U,z,{[`${U}-rtl`]:R==="rtl",[`${U}-${W}`]:!!W,[`${U}-with-button`]:!!l},o,H,_.root),ce=ae=>{V.current=true,b?.(ae);},fe=ae=>{V.current=false,y?.(ae);},se=yo(T,{data:true}),Me=Ln({...T,classNames:Ln(_,["button","root"]),styles:Ln(B,["button","root"]),prefixCls:G,type:"search",size:W,variant:S,onPressEnter:K,onCompositionStart:ce,onCompositionEnd:fe,onChange:Q,disabled:m},Object.keys(se));return f.createElement(lR,{className:ne,style:{...a,...B.root},...se,hidden:M},f.createElement(kf,{ref:Vr(Y,t),...Me}),re)}),dhe=`
min-height:0 !important;
max-height:none !important;
height:0 !important;
visibility:hidden !important;
overflow:hidden !important;
position:absolute !important;
z-index:-1000 !important;
top:0 !important;
right:0 !important;
pointer-events: none !important;
`,fhe=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break","white-space"],ow={};let ci;function mhe(e,t=false){const n=e.getAttribute("id")||e.getAttribute("data-reactid")||e.getAttribute("name");if(t&&ow[n])return ow[n];const r=window.getComputedStyle(e),o=r.getPropertyValue("box-sizing")||r.getPropertyValue("-moz-box-sizing")||r.getPropertyValue("-webkit-box-sizing"),i=parseFloat(r.getPropertyValue("padding-bottom"))+parseFloat(r.getPropertyValue("padding-top")),a=parseFloat(r.getPropertyValue("border-bottom-width"))+parseFloat(r.getPropertyValue("border-top-width")),u={sizingStyle:fhe.map(d=>`${d}:${r.getPropertyValue(d)}`).join(";"),paddingSize:i,borderSize:a,boxSizing:o};return t&&n&&(ow[n]=u),u}function hhe(e,t=false,n=null,r=null){ci||(ci=document.createElement("textarea"),ci.setAttribute("tab-index","-1"),ci.setAttribute("aria-hidden","true"),ci.setAttribute("name","hiddenTextarea"),document.body.appendChild(ci)),e.getAttribute("wrap")?ci.setAttribute("wrap",e.getAttribute("wrap")):ci.removeAttribute("wrap");const{paddingSize:o,borderSize:i,boxSizing:a,sizingStyle:l}=mhe(e,t);ci.setAttribute("style",`${l};${dhe}`),ci.value=e.value||e.placeholder||"";let u,d,m,p=ci.scrollHeight;if(a==="border-box"?p+=i:a==="content-box"&&(p-=o),n!==null||r!==null){ci.value=" ";const b=ci.scrollHeight-o;n!==null&&(u=b*n,a==="border-box"&&(u=u+o+i),p=Math.max(u,p)),r!==null&&(d=b*r,a==="border-box"&&(d=d+o+i),m=p>d?"":"hidden",p=Math.min(d,p));}const g={height:p,overflowY:m,resize:"none"};return u&&(g.minHeight=u),d&&(g.maxHeight=d),g}function ZE(){return ZE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},ZE.apply(this,arguments)}const iw=0,aw=1,sw=2,phe=f.forwardRef((e,t)=>{const{prefixCls:n,defaultValue:r,value:o,autoSize:i,onResize:a,className:l,style:u,disabled:d,onChange:m,onInternalAutoSize:p,...g}=e,[b,y]=un(r,o),S=b??"",C=H=>{y(H.target.value),m?.(H);},w=f.useRef();f.useImperativeHandle(t,()=>({textArea:w.current}));const[$,M]=f.useMemo(()=>i&&typeof i=="object"?[i.minRows,i.maxRows]:[],[i]),T=!!i,[R,I]=f.useState(sw),[N,P]=f.useState(),O=()=>{I(iw);};An(()=>{T&&O();},[o,$,M,T]),An(()=>{if(R===iw)I(aw);else if(R===aw){const H=hhe(w.current,false,$,M);I(sw),P(H);}},[R]);const _=f.useRef(),B=()=>{Lt.cancel(_.current);},V=H=>{R===sw&&(a?.(H),i&&(B(),_.current=Lt(()=>{O();})));};f.useEffect(()=>B,[]);const G={...u,...T?N:null};return (R===iw||R===aw)&&(G.overflowY="hidden",G.overflowX="hidden"),f.createElement(ma,{onResize:V,disabled:!(i||a)},f.createElement("textarea",ZE({},g,{ref:w,style:G,className:X(n,l,{[`${n}-disabled`]:d}),disabled:d,value:S,onChange:C})))});function JE(){return JE=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},JE.apply(this,arguments)}const ghe=q.forwardRef(({defaultValue:e,value:t,onFocus:n,onBlur:r,onChange:o,allowClear:i,maxLength:a,onCompositionStart:l,onCompositionEnd:u,suffix:d,prefixCls:m="rc-textarea",showCount:p,count:g,className:b,style:y,disabled:S,hidden:C,classNames:w,styles:$,onResize:M,onClear:T,onPressEnter:R,readOnly:I,autoSize:N,onKeyDown:P,...O},_)=>{const[B,V]=un(e,t),U=B==null?"":String(B),[G,H]=q.useState(false),z=q.useRef(false),[j,W]=q.useState(null),Y=f.useRef(null),Q=f.useRef(null),D=()=>Q.current?.textArea,L=()=>{D().focus();};f.useImperativeHandle(_,()=>({resizableTextArea:Q.current,focus:L,blur:()=>{D().blur();},nativeElement:Y.current?.nativeElement||D()})),f.useEffect(()=>{H(ue=>!S&&ue);},[S]);const[K,J]=q.useState(null);q.useEffect(()=>{K&&D().setSelectionRange(...K);},[K]);const ee=q7(g,p),te=ee.max??a,re=Number(te)>0,ie=ee.strategy(U),de=!!te&&ie>te,ne=(ue,ge)=>{let Pe=ge;!z.current&&ee.exceedFormatter&&ee.max&&ee.strategy(ge)>ee.max&&(Pe=ee.exceedFormatter(ge,{max:ee.max}),ge!==Pe&&J([D().selectionStart||0,D().selectionEnd||0])),V(Pe),Z0(ue.currentTarget,ue,o,Pe);},ce=ue=>{z.current=true,l?.(ue);},fe=ue=>{z.current=false,ne(ue,ue.currentTarget.value),u?.(ue);},se=ue=>{ne(ue,ue.target.value);},Me=ue=>{ue.key==="Enter"&&R&&!ue.nativeEvent.isComposing&&R(ue),P?.(ue);},ae=ue=>{H(true),n?.(ue);},pe=ue=>{H(false),r?.(ue);},Ce=ue=>{V(""),L(),Z0(D(),ue,o);};let xe=d,Ae;ee.show&&(ee.showFormatter?Ae=ee.showFormatter({value:U,count:ie,maxLength:te}):Ae=`${ie}${re?` / ${te}`:""}`,xe=q.createElement(q.Fragment,null,xe,q.createElement("span",{className:X(`${m}-data-count`,w?.count),style:$?.count},Ae)));const Xe=ue=>{M?.(ue),D()?.style.height&&W(true);},Ne=!N&&!p&&!i;return q.createElement(G7,{ref:Y,value:U,allowClear:i,handleReset:Ce,suffix:xe,prefixCls:m,classNames:{...w,affixWrapper:X(w?.affixWrapper,{[`${m}-show-count`]:p,[`${m}-textarea-allow-clear`]:i})},disabled:S,focused:G,className:X(b,de&&`${m}-out-of-range`),style:{...y,...j&&!Ne?{height:"auto"}:{}},dataAttrs:{affixWrapper:{"data-count":typeof Ae=="string"?Ae:void 0}},hidden:C,readOnly:I,onClear:T},q.createElement(phe,JE({},O,{autoSize:N,maxLength:a,onKeyDown:Me,onChange:se,onFocus:ae,onBlur:pe,onCompositionStart:ce,onCompositionEnd:fe,className:X(w?.textarea),style:{resize:y?.resize,...$?.textarea},disabled:S,prefixCls:m,onResize:Xe,ref:Q,readOnly:I})))}),vhe=e=>{const{componentCls:t,paddingLG:n}=e,r=`${t}-textarea`;return {[`textarea${t}`]:{maxWidth:"100%",height:"auto",minHeight:e.controlHeight,lineHeight:e.lineHeight,verticalAlign:"bottom",transition:`all ${e.motionDurationSlow}`,resize:"vertical",[`&${t}-mouse-active`]:{transition:`all ${e.motionDurationSlow}, height 0s, width 0s`}},[`${t}-textarea-affix-wrapper-resize-dirty`]:{width:"auto"},[r]:{position:"relative","&-show-count":{[`${t}-data-count`]:{position:"absolute",bottom:e.calc(e.fontSize).mul(e.lineHeight).mul(-1).equal(),insetInlineEnd:0,color:e.colorTextDescription,whiteSpace:"nowrap",pointerEvents:"none"}},[`
&-allow-clear > ${t},
&-affix-wrapper${r}-has-feedback ${t}
`]:{paddingInlineEnd:n},[`&-affix-wrapper${t}-affix-wrapper`]:{padding:0,[`> textarea${t}`]:{fontSize:"inherit",border:"none",outline:"none",background:"transparent",minHeight:e.calc(e.controlHeight).sub(e.calc(e.lineWidth).mul(2)).equal(),"&:focus":{boxShadow:"none !important"}},[`${t}-suffix`]:{margin:0,"> *:not(:last-child)":{marginInline:0},[`${t}-clear-icon`]:{position:"absolute",insetInlineEnd:e.paddingInline,insetBlockStart:e.paddingXS},[`${r}-suffix`]:{position:"absolute",top:0,insetInlineEnd:e.paddingInline,bottom:0,zIndex:1,display:"inline-flex",alignItems:"center",margin:"auto",pointerEvents:"none"}}},[`&-affix-wrapper${t}-affix-wrapper-rtl`]:{[`${t}-suffix`]:{[`${t}-data-count`]:{direction:"ltr",insetInlineStart:0}}},[`&-affix-wrapper${t}-affix-wrapper-sm`]:{[`${t}-suffix`]:{[`${t}-clear-icon`]:{insetInlineEnd:e.paddingInlineSM}}}}}},bhe=Wt(["Input","TextArea"],e=>{const t=Ft(e,Lf(e));return vhe(t)},zf,{resetFont:false}),yhe=f.forwardRef((e,t)=>{const{prefixCls:n,bordered:r=true,size:o,disabled:i,status:a,allowClear:l,classNames:u,rootClassName:d,className:m,style:p,styles:g,variant:b,showCount:y,onMouseDown:S,onResize:C,...w}=e,{getPrefixCls:$,direction:M,allowClear:T,autoComplete:R,className:I,style:N,classNames:P,styles:O}=jt("textArea"),_=f.useContext(no),B=i??_,{status:V,hasFeedback:U,feedbackIcon:G}=f.useContext(So),H=Df(V,a),[z,j]=Kt([P,u],[O,g],{props:e}),W=f.useRef(null);f.useImperativeHandle(t,()=>({resizableTextArea:W.current?.resizableTextArea,focus:ae=>{xR(W.current?.resizableTextArea?.textArea,ae);},blur:()=>W.current?.blur(),nativeElement:W.current?.nativeElement||null}));const Y=$("input",n),Q=Qn(Y),[D,L]=R7(Y,d);bhe(Y,Q);const{compactSize:K,compactItemClassnames:J}=ks(Y,M),ee=so(ae=>o??K??ae),[te,re]=a1("textArea",b,r),ie=K7(l??T),[de,ne]=f.useState(false),[ce,fe]=f.useState(false),se=ae=>{ne(true),S?.(ae);const pe=()=>{ne(false),document.removeEventListener("mouseup",pe);};document.addEventListener("mouseup",pe);},Me=ae=>{if(C?.(ae),de&&typeof getComputedStyle=="function"){const pe=W.current?.nativeElement?.querySelector("textarea");pe&&getComputedStyle(pe).resize==="both"&&fe(true);}};return f.createElement(ghe,{autoComplete:R,...w,style:{...j.root,...N,...p},styles:j,disabled:B,allowClear:ie,className:X(L,Q,m,d,J,I,z.root,{[`${Y}-textarea-affix-wrapper-resize-dirty`]:ce}),classNames:{...z,textarea:X({[`${Y}-sm`]:ee==="small",[`${Y}-lg`]:ee==="large"},D,z.textarea,de&&`${Y}-mouse-active`),variant:X({[`${Y}-${te}`]:re},jl(Y,H)),affixWrapper:X(`${Y}-textarea-affix-wrapper`,{[`${Y}-affix-wrapper-rtl`]:M==="rtl",[`${Y}-affix-wrapper-sm`]:ee==="small",[`${Y}-affix-wrapper-lg`]:ee==="large",[`${Y}-textarea-show-count`]:y||e.count?.show},D)},prefixCls:Y,suffix:U&&f.createElement("span",{className:`${Y}-textarea-suffix`},G),showCount:y,ref:W,onResize:Me,onMouseDown:se})}),Yi=kf;Yi.Group=qme;Yi.Search=uhe;Yi.TextArea=yhe;Yi.Password=she;Yi.OTP=Zme;var She={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M272.9 512l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L186.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H532c6.7 0 10.4-7.7 6.3-12.9L272.9 512zm304 0l265.4-339.1c4.1-5.2.4-12.9-6.3-12.9h-77.3c-4.9 0-9.6 2.3-12.6 6.1L490.8 492.3a31.99 31.99 0 000 39.5l255.3 326.1c3 3.9 7.7 6.1 12.6 6.1H836c6.7 0 10.4-7.7 6.3-12.9L576.9 512z"}}]},name:"double-left",theme:"outlined"};function e3(){return e3=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},e3.apply(this,arguments)}const Che=(e,t)=>f.createElement(Xn,e3({},e,{ref:t,icon:She})),O8=f.forwardRef(Che);var xhe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M533.2 492.3L277.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H188c-6.7 0-10.4 7.7-6.3 12.9L447.1 512 181.7 851.1A7.98 7.98 0 00188 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5zm304 0L581.9 166.1c-3-3.9-7.7-6.1-12.6-6.1H492c-6.7 0-10.4 7.7-6.3 12.9L751.1 512 485.7 851.1A7.98 7.98 0 00492 864h77.3c4.9 0 9.6-2.3 12.6-6.1l255.3-326.1c9.1-11.7 9.1-27.9 0-39.5z"}}]},name:"double-right",theme:"outlined"};function t3(){return t3=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},t3.apply(this,arguments)}const whe=(e,t)=>f.createElement(Xn,t3({},e,{ref:t,icon:xhe})),D8=f.forwardRef(whe),$he={items_per_page:"条/页",jump_to:"跳至",jump_to_confirm:"确定",page:"页",prev_page:"上一页",next_page:"下一页",prev_5:"向前 5 页",next_5:"向后 5 页",prev_3:"向前 3 页",next_3:"向后 3 页",page_size:"页码"},Ehe=[10,20,50,100],Mhe=e=>{const{pageSizeOptions:t=Ehe,locale:n,changeSize:r,pageSize:o,goButton:i,quickGo:a,rootPrefixCls:l,disabled:u,buildOptionText:d,showSizeChanger:m,sizeChangerRender:p}=e,[g,b]=q.useState(""),y=q.useMemo(()=>!g||Number.isNaN(g)?void 0:Number(g),[g]),S=typeof d=="function"?d:P=>`${P} ${n.items_per_page}`,C=P=>{const O=P.target.value;/^\d*$/.test(O)&&b(O);},w=P=>{i||g===""||(b(""),!(P.relatedTarget&&(P.relatedTarget.className.includes(`${l}-item-link`)||P.relatedTarget.className.includes(`${l}-item`)))&&a?.(y));},$=P=>{g!==""&&(P.keyCode===it.ENTER||P.type==="click")&&(b(""),a?.(y));},M=()=>t.some(P=>P.toString()===o.toString())?t:t.concat([o]).sort((P,O)=>{const _=Number.isNaN(Number(P))?0:Number(P),B=Number.isNaN(Number(O))?0:Number(O);return _-B}),T=`${l}-options`;if(!m&&!a)return null;let R=null,I=null,N=null;return m&&p&&(R=p({disabled:u,size:o,onSizeChange:P=>{r?.(Number(P));},"aria-label":n.page_size,className:`${T}-size-changer`,options:M().map(P=>({label:S(P),value:P}))})),a&&(i&&(N=typeof i=="boolean"?q.createElement("button",{type:"button",onClick:$,onKeyUp:$,disabled:u,className:`${T}-quick-jumper-button`},n.jump_to_confirm):q.createElement("span",{onClick:$,onKeyUp:$},i)),I=q.createElement("div",{className:`${T}-quick-jumper`},n.jump_to,q.createElement("input",{disabled:u,type:"text",value:g,onChange:C,onKeyUp:$,onBlur:w,"aria-label":n.page}),n.page,N)),q.createElement("li",{className:T},R,I)},eh=e=>{const{rootPrefixCls:t,page:n,active:r,className:o,style:i,showTitle:a,onClick:l,onKeyPress:u,itemRender:d}=e,m=`${t}-item`,p=X(m,`${m}-${n}`,{[`${m}-active`]:r,[`${m}-disabled`]:!n},o),g=()=>{l(n);},b=S=>{u(S,l,n);},y=d(n,"page",q.createElement("a",{rel:"nofollow"},n));return y?q.createElement("li",{title:a?String(n):null,className:p,style:i,onClick:g,onKeyDown:b,tabIndex:0},y):null};function El(){return El=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},El.apply(this,arguments)}const Rhe=(e,t,n)=>n;function _8(){}function B8(e){const t=Number(e);return typeof t=="number"&&!Number.isNaN(t)&&isFinite(t)&&Math.floor(t)===t}function Rc(e,t,n){const r=typeof e>"u"?t:e;return Math.floor((n-1)/r)+1}const The=e=>{const{prefixCls:t="rc-pagination",selectPrefixCls:n="rc-select",className:r,classNames:o,styles:i,current:a,defaultCurrent:l=1,total:u=0,pageSize:d,defaultPageSize:m=10,onChange:p=_8,hideOnSinglePage:g,align:b,showPrevNextJumpers:y=true,showQuickJumper:S,showLessItems:C,showTitle:w=true,onShowSizeChange:$=_8,locale:M=$he,style:T,totalBoundaryShowSizeChanger:R=50,disabled:I,simple:N,showTotal:P,showSizeChanger:O=u>R,sizeChangerRender:_,pageSizeOptions:B,itemRender:V=Rhe,jumpPrevIcon:U,jumpNextIcon:G,prevIcon:H,nextIcon:z}=e,j=q.useRef(null),[W,Y]=un(m,d),[Q,D]=un(l,a),L=Math.max(1,Math.min(Q,Rc(void 0,W,u))),[K,J]=q.useState(L);f.useEffect(()=>{J(L);},[L]);const ee=Math.max(1,L-(C?3:5)),te=Math.min(Rc(void 0,W,u),L+(C?3:5));function re(ye,be){let Se=ye||q.createElement("button",{type:"button","aria-label":be,className:`${t}-item-link`});return typeof ye=="function"&&(Se=q.createElement(ye,e)),Se}function ie(ye){const be=ye.target.value,Se=Rc(void 0,W,u);let he;return be===""?he=be:Number.isNaN(Number(be))?he=K:be>=Se?he=Se:he=Number(be),he}function de(ye){return B8(ye)&&ye!==L&&B8(u)&&u>0}const ne=u>W?S:false;function ce(ye){(ye.keyCode===it.UP||ye.keyCode===it.DOWN)&&ye.preventDefault();}function fe(ye){const be=ie(ye);switch(be!==K&&J(be),ye.keyCode){case it.ENTER:ae(be);break;case it.UP:ae(be-1);break;case it.DOWN:ae(be+1);break}}function se(ye){ae(ie(ye));}function Me(ye){const be=Rc(ye,W,u),Se=L>be&&be!==0?be:L;Y(ye),J(Se),$?.(L,ye),D(Se),p?.(Se,ye);}function ae(ye){if(de(ye)&&!I){const be=Rc(void 0,W,u);let Se=ye;return ye>be?Se=be:ye<1&&(Se=1),Se!==K&&J(Se),D(Se),p?.(Se,W),Se}return L}const pe=L>1,Ce=L<Rc(void 0,W,u);function xe(){pe&&ae(L-1);}function Ae(){Ce&&ae(L+1);}function Xe(){ae(ee);}function Ne(){ae(te);}function ue(ye,be,...Se){(ye.key==="Enter"||ye.charCode===it.ENTER||ye.keyCode===it.ENTER)&&be(...Se);}function ge(ye){ue(ye,xe);}function Pe(ye){ue(ye,Ae);}function je(ye){ue(ye,Xe);}function qe(ye){ue(ye,Ne);}function Ue(ye){const be=V(ye,"prev",re(H,"prev page"));return q.isValidElement(be)?q.cloneElement(be,{disabled:!pe}):be}function et(ye){const be=V(ye,"next",re(z,"next page"));return q.isValidElement(be)?q.cloneElement(be,{disabled:!Ce}):be}function rt(ye){(ye.type==="click"||ye.keyCode===it.ENTER)&&ae(K);}let Ke=null;const _e=yo(e,{aria:true,data:true}),We=P&&q.createElement("li",{className:`${t}-total-text`},P(u,[u===0?0:(L-1)*W+1,L*W>u?u:L*W]));let Ze=null;const Be=Rc(void 0,W,u);if(g&&u<=W)return null;const Oe=[],lt={rootPrefixCls:t,onClick:ae,onKeyPress:ue,showTitle:w,itemRender:V,page:-1,className:o?.item,style:i?.item},It=L-1>0?L-1:0,mt=L+1<Be?L+1:Be,Bt=S&&S.goButton,xt=typeof N=="object"?N.readOnly:!N;let Tt=Bt,ut=null;N&&(Bt&&(typeof Bt=="boolean"?Tt=q.createElement("button",{type:"button",onClick:rt,onKeyUp:rt},M.jump_to_confirm):Tt=q.createElement("span",{onClick:rt,onKeyUp:rt},Bt),Tt=q.createElement("li",{title:w?`${M.jump_to}${L}/${Be}`:null,className:`${t}-simple-pager`},Tt)),ut=q.createElement("li",{title:w?`${L}/${Be}`:null,className:X(`${t}-simple-pager`,o?.item),style:i?.item},xt?K:q.createElement("input",{type:"text","aria-label":M.jump_to,value:K,disabled:I,onKeyDown:ce,onKeyUp:fe,onChange:fe,onBlur:se,size:3}),q.createElement("span",{className:`${t}-slash`},"/"),Be));const dt=C?1:2;if(Be<=3+dt*2){Be||Oe.push(q.createElement(eh,El({},lt,{key:"noPager",page:1,className:`${t}-item-disabled`})));for(let ye=1;ye<=Be;ye+=1)Oe.push(q.createElement(eh,El({},lt,{key:ye,page:ye,active:L===ye})));}else {const ye=C?M.prev_3:M.prev_5,be=C?M.next_3:M.next_5,Se=V(ee,"jump-prev",re(U,"prev page")),he=V(te,"jump-next",re(G,"next page"));y&&(Ke=Se?q.createElement("li",{title:w?ye:null,key:"prev",onClick:Xe,tabIndex:0,onKeyDown:je,className:X(`${t}-jump-prev`,{[`${t}-jump-prev-custom-icon`]:!!U})},Se):null,Ze=he?q.createElement("li",{title:w?be:null,key:"next",onClick:Ne,tabIndex:0,onKeyDown:qe,className:X(`${t}-jump-next`,{[`${t}-jump-next-custom-icon`]:!!G})},he):null);let De=Math.max(1,L-dt),$e=Math.min(L+dt,Be);L-1<=dt&&($e=1+dt*2),Be-L<=dt&&(De=Be-dt*2);for(let ke=De;ke<=$e;ke+=1)Oe.push(q.createElement(eh,El({},lt,{key:ke,page:ke,active:L===ke})));if(L-1>=dt*2&&L!==3&&(Oe[0]=q.cloneElement(Oe[0],{className:X(`${t}-item-after-jump-prev`,Oe[0].props.className)}),Oe.unshift(Ke)),Be-L>=dt*2&&L!==Be-2){const ke=Oe[Oe.length-1];Oe[Oe.length-1]=q.cloneElement(ke,{className:X(`${t}-item-before-jump-next`,ke.props.className)}),Oe.push(Ze);}De!==1&&Oe.unshift(q.createElement(eh,El({},lt,{key:1,page:1}))),$e!==Be&&Oe.push(q.createElement(eh,El({},lt,{key:Be,page:Be})));}let gt=Ue(It);if(gt){const ye=!pe||!Be;gt=q.createElement("li",{title:w?M.prev_page:null,onClick:xe,tabIndex:ye?null:0,onKeyDown:ge,className:X(`${t}-prev`,o?.item,{[`${t}-disabled`]:ye}),style:i?.item,"aria-disabled":ye},gt);}let Fe=et(mt);if(Fe){let ye,be;N?(ye=!Ce,be=pe?0:null):(ye=!Ce||!Be,be=ye?null:0),Fe=q.createElement("li",{title:w?M.next_page:null,onClick:Ae,tabIndex:be,onKeyDown:Pe,className:X(`${t}-next`,o?.item,{[`${t}-disabled`]:ye}),style:i?.item,"aria-disabled":ye},Fe);}const Qe=X(t,r,{[`${t}-start`]:b==="start",[`${t}-center`]:b==="center",[`${t}-end`]:b==="end",[`${t}-simple`]:N,[`${t}-disabled`]:I});return q.createElement("ul",El({className:Qe,style:T,ref:j},_e),We,gt,N?ut:Oe,Fe,q.createElement(Mhe,{locale:M,rootPrefixCls:t,disabled:I,selectPrefixCls:n,changeSize:Me,pageSize:W,pageSizeOptions:B,quickGo:ne?ae:null,goButton:Tt,showSizeChanger:O,sizeChangerRender:_}))},Ahe=e=>{const{componentCls:t}=e;return {[`${t}-disabled`]:{"&, &:hover":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}},"&:focus-visible":{cursor:"not-allowed",[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed"}}},[`&${t}-disabled`]:{cursor:"not-allowed",[`${t}-item`]:{cursor:"not-allowed",backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"},a:{color:e.colorTextDisabled,backgroundColor:"transparent",border:"none",cursor:"not-allowed"},"&-active":{borderColor:e.colorBorder,backgroundColor:e.itemActiveBgDisabled,"&:hover, &:active":{backgroundColor:e.itemActiveBgDisabled},a:{color:e.itemActiveColorDisabled}}},[`${t}-item-link`]:{color:e.colorTextDisabled,cursor:"not-allowed","&:hover, &:active":{backgroundColor:"transparent"},[`${t}-simple&`]:{backgroundColor:"transparent","&:hover, &:active":{backgroundColor:"transparent"}}},[`${t}-simple-pager`]:{color:e.colorTextDisabled},[`${t}-jump-prev, ${t}-jump-next`]:{[`${t}-item-link-icon`]:{opacity:0},[`${t}-item-ellipsis`]:{opacity:1}}}}},Nhe=e=>{const{componentCls:t}=e;return {[`&${t}-small ${t}-options`]:{marginInlineStart:e.paginationMiniOptionsMarginInlineStart,"&-quick-jumper":{input:{...qR(e),width:e.paginationMiniQuickJumperInputWidth}}}}},Phe=e=>{const{componentCls:t}=e;return {[`&${t}-large ${t}-options`]:{"&-quick-jumper":{input:{...GR(e)}}}}},Ihe=e=>{const{componentCls:t,antCls:n}=e,[,r]=tr(n,"pagination");return {[`&${t}-simple`]:{[`${t}-prev, ${t}-next`]:{height:r("item-size-actual"),lineHeight:r("item-size-actual"),verticalAlign:"top",[`${t}-item-link`]:{height:r("item-size-actual"),backgroundColor:"transparent",border:0,"&:hover":{backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive},"&::after":{height:r("item-size-actual"),lineHeight:r("item-size-actual")}}},[`${t}-simple-pager`]:{display:"inline-flex",alignItems:"center",height:r("item-size-actual"),marginInlineEnd:r("item-spacing-actual"),input:{boxSizing:"border-box",height:"100%",width:e.quickJumperInputWidth,padding:`0 ${oe(e.paginationItemPaddingInline)}`,textAlign:"center",backgroundColor:e.itemInputBg,border:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadius,outline:"none",transition:`border-color ${e.motionDurationMid}`,color:"inherit","&:hover":{borderColor:e.colorPrimary},"&:focus":{borderColor:e.colorPrimaryHover,boxShadow:`${oe(e.inputOutlineOffset)} 0 ${oe(e.controlOutlineWidth)} ${e.controlOutline}`},"&[disabled]":{color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,cursor:"not-allowed"}}},[`&${t}-disabled`]:{[`${t}-prev, ${t}-next`]:{[`${t}-item-link`]:{"&:hover, &:active":{backgroundColor:"transparent"}}}},[`&${t}-small`]:{[`${t}-simple-pager`]:{input:{width:e.paginationMiniQuickJumperInputWidth}}}}}},Ohe=e=>{const{componentCls:t,antCls:n}=e,[,r]=tr(n,"pagination");return {[`${t}-jump-prev, ${t}-jump-next`]:{outline:0,[`${t}-item-container`]:{position:"relative",[`${t}-item-link-icon`]:{color:e.colorPrimary,fontSize:e.fontSizeSM,opacity:0,transition:`all ${e.motionDurationMid}`,"&-svg":{top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,margin:"auto"}},[`${t}-item-ellipsis`]:{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,display:"block",margin:"auto",color:e.colorTextDisabled,letterSpacing:e.paginationEllipsisLetterSpacing,textAlign:"center",textIndent:e.paginationEllipsisTextIndent,opacity:1,transition:`all ${e.motionDurationMid}`}},"&:hover":{[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0}}},[`
${t}-prev,
${t}-jump-prev,
${t}-jump-next
`]:{marginInlineEnd:r("item-spacing-actual")},[`
${t}-prev,
${t}-next,
${t}-jump-prev,
${t}-jump-next
`]:{display:"inline-block",minWidth:r("item-size-actual"),height:r("item-size-actual"),color:e.colorText,fontFamily:e.fontFamily,lineHeight:r("item-size-actual"),textAlign:"center",verticalAlign:"middle",listStyle:"none",borderRadius:e.borderRadius,cursor:"pointer",transition:`all ${e.motionDurationMid}`},[`${t}-prev, ${t}-next`]:{outline:0,button:{color:e.colorText,cursor:"pointer",userSelect:"none"},[`${t}-item-link`]:{display:"block",width:"100%",height:"100%",padding:0,fontSize:e.fontSizeSM,textAlign:"center",backgroundColor:"transparent",border:`${oe(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:"none",transition:`all ${e.motionDurationMid}`},[`&:hover ${t}-item-link`]:{backgroundColor:e.colorBgTextHover},[`&:active ${t}-item-link`]:{backgroundColor:e.colorBgTextActive},[`&${t}-disabled:hover`]:{[`${t}-item-link`]:{backgroundColor:"transparent"}}},[`${t}-slash`]:{marginInlineEnd:e.paginationSlashMarginInlineEnd,marginInlineStart:e.paginationSlashMarginInlineStart},[`${t}-options`]:{display:"inline-block",marginInlineStart:e.margin,verticalAlign:"middle","&-size-changer":{width:"auto"},"&-quick-jumper":{display:"inline-block",height:r("item-size-actual"),marginInlineStart:e.marginXS,lineHeight:r("item-size-actual"),verticalAlign:"baseline",input:{...p1(e),...WR(e,{borderColor:e.colorBorder,hoverBorderColor:e.colorPrimaryHover,activeBorderColor:e.colorPrimary,activeShadow:e.activeShadow}),"&[disabled]":{...h1(e)},width:e.quickJumperInputWidth,height:r("item-size-actual"),boxSizing:"border-box",margin:0,marginInlineStart:r("item-spacing-actual"),marginInlineEnd:r("item-spacing-actual")}}}}},Dhe=e=>{const{componentCls:t,antCls:n}=e,[,r]=tr(n,"pagination");return {[`${t}-item`]:{display:"inline-block",minWidth:r("item-size-actual"),height:r("item-size-actual"),marginInlineEnd:r("item-spacing-actual"),fontFamily:e.fontFamily,lineHeight:oe(e.calc(r("item-size-actual")).sub(2).equal()),textAlign:"center",verticalAlign:"middle",listStyle:"none",backgroundColor:e.itemBg,border:`${oe(e.lineWidth)} ${e.lineType} transparent`,borderRadius:e.borderRadius,outline:0,cursor:"pointer",userSelect:"none",a:{display:"block",padding:`0 ${oe(e.paginationItemPaddingInline)}`,color:e.colorText,"&:hover":{textDecoration:"none"}},[`&:not(${t}-item-active)`]:{"&:hover":{transition:`all ${e.motionDurationMid}`,backgroundColor:e.colorBgTextHover},"&:active":{backgroundColor:e.colorBgTextActive}},"&-active":{fontWeight:e.fontWeightStrong,backgroundColor:e.itemActiveBg,borderColor:e.colorPrimary,a:{color:e.itemActiveColor},"&:hover":{borderColor:e.colorPrimaryHover},"&:hover a":{color:e.itemActiveColorHover}}}}},_he=e=>{const{componentCls:t,antCls:n}=e,[r,o]=tr(n,"pagination");return {[t]:{[r("item-size-actual")]:oe(e.itemSize),[r("item-spacing-actual")]:oe(e.marginXS),"&-small":{[r("item-size-actual")]:oe(e.itemSizeSM),[r("item-spacing-actual")]:oe(e.marginXXS)},"&-large":{[r("item-size-actual")]:oe(e.itemSizeLG),[r("item-spacing-actual")]:oe(e.marginSM)},...dn(e),display:"flex",alignItems:"center","&-start":{justifyContent:"start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"end"},"ul, ol":{margin:0,padding:0,listStyle:"none"},"&::after":{display:"block",clear:"both",height:0,overflow:"hidden",visibility:"hidden",content:'""'},[`${t}-total-text`]:{display:"inline-block",height:o("item-size-actual"),marginInlineEnd:o("item-spacing-actual"),lineHeight:oe(e.calc(o("item-size-actual")).sub(2).equal()),verticalAlign:"middle"},...Dhe(e),...Ohe(e),...Ihe(e),...Nhe(e),...Phe(e),...Ahe(e),[`@media only screen and (max-width: ${e.screenLG}px)`]:{[`${t}-item`]:{"&-after-jump-prev, &-before-jump-next":{display:"none"}}},[`@media only screen and (max-width: ${e.screenSM}px)`]:{[`${t}-options`]:{display:"none"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}}},Bhe=e=>{const{componentCls:t}=e;return {[`${t}:not(${t}-disabled)`]:{[`${t}-item`]:{...$i(e)},[`${t}-jump-prev, ${t}-jump-next`]:{"&:focus-visible":{[`${t}-item-link-icon`]:{opacity:1},[`${t}-item-ellipsis`]:{opacity:0},...ba(e)}},[`${t}-prev, ${t}-next`]:{[`&:focus-visible ${t}-item-link`]:ba(e)}}}},uH=e=>({itemBg:e.colorBgContainer,itemSize:e.controlHeight,itemSizeSM:e.controlHeightSM,itemSizeLG:e.controlHeightLG,itemActiveBg:e.colorBgContainer,itemActiveColor:e.colorPrimary,itemActiveColorHover:e.colorPrimaryHover,itemLinkBg:e.colorBgContainer,itemActiveColorDisabled:e.colorTextDisabled,itemActiveBgDisabled:e.controlItemBgActiveDisabled,itemInputBg:e.colorBgContainer,miniOptionsSizeChangerTop:0,...zf(e)}),dH=e=>Ft(e,{inputOutlineOffset:0,quickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.25).equal(),paginationMiniOptionsMarginInlineStart:e.calc(e.marginXXS).div(2).equal(),paginationMiniQuickJumperInputWidth:e.calc(e.controlHeightLG).mul(1.1).equal(),paginationItemPaddingInline:e.calc(e.marginXXS).mul(1.5).equal(),paginationEllipsisLetterSpacing:e.calc(e.marginXXS).div(2).equal(),paginationSlashMarginInlineStart:e.marginSM,paginationSlashMarginInlineEnd:e.marginSM,paginationEllipsisTextIndent:"0.13em"},Lf(e)),Lhe=Wt("Pagination",e=>{const t=dH(e);return [_he(t),Bhe(t)]},uH),zhe=e=>{const{componentCls:t}=e;return {[`${t}${t}-bordered${t}-disabled`]:{"&, &:hover":{[`${t}-item-link`]:{borderColor:e.colorBorder}},"&:focus-visible":{[`${t}-item-link`]:{borderColor:e.colorBorder}},[`${t}-item, ${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,[`&:hover:not(${t}-item-active)`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,a:{color:e.colorTextDisabled}},[`&${t}-item-active`]:{backgroundColor:e.itemActiveBgDisabled}},[`${t}-prev, ${t}-next`]:{"&:hover button":{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,color:e.colorTextDisabled},[`${t}-item-link`]:{backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder}}},[`${t}${t}-bordered`]:{[`${t}-prev, ${t}-next`]:{"&:hover button":{borderColor:e.colorPrimaryHover,backgroundColor:e.itemBg},[`${t}-item-link`]:{backgroundColor:e.itemLinkBg,borderColor:e.colorBorder},[`&:hover ${t}-item-link`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,color:e.colorPrimary},[`&${t}-disabled`]:{[`${t}-item-link`]:{borderColor:e.colorBorder,color:e.colorTextDisabled}}},[`${t}-item`]:{backgroundColor:e.itemBg,border:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,[`&:hover:not(${t}-item-active)`]:{borderColor:e.colorPrimary,backgroundColor:e.itemBg,a:{color:e.colorPrimary}},"&-active":{borderColor:e.colorPrimary}}}}},khe=Nf(["Pagination","bordered"],e=>{const t=dH(e);return zhe(t)},uH);function L8(e){return f.useMemo(()=>typeof e=="boolean"?[e,{}]:e&&typeof e=="object"?[true,e]:[void 0,void 0],[e])}const Fhe=e=>{const{align:t,prefixCls:n,selectPrefixCls:r,className:o,rootClassName:i,style:a,size:l,locale:u,responsive:d,showSizeChanger:m,selectComponentClass:p,pageSizeOptions:g,styles:b,classNames:y,...S}=e,{xs:C}=FF(d),[,w]=jr(),{getPrefixCls:$,direction:M,showSizeChanger:T,className:R,style:I,classNames:N,styles:P,totalBoundaryShowSizeChanger:O}=jt("pagination"),_=$("pagination",n),[B,V]=Lhe(_),U=so(l),G=U==="small"||!!(C&&!U&&d),H={...e,size:U},[z,j]=Kt([N,y],[P,b],{props:H}),[W]=Oo("Pagination",Wz),Y={...W,...u},[Q,D]=L8(m),[L,K]=L8(T),J=Q??L,ee=D??K,te=p||Zl,re=f.useMemo(()=>g?g.map(se=>Number(se)):void 0,[g]),ie=se=>{const{disabled:Me,size:ae,onSizeChange:pe,"aria-label":Ce,className:xe,options:Ae}=se,{className:Xe,onChange:Ne}=ee||{},ue=Ae.find(ge=>String(ge.value)===String(ae))?.value;return f.createElement(te,{disabled:Me,showSearch:true,popupMatchSelectWidth:false,getPopupContainer:ge=>ge.parentNode,"aria-label":Ce,options:Ae,...ee,value:ue,onChange:(ge,Pe)=>{pe?.(ge),Ne?.(ge,Pe);},size:U,className:X(xe,Xe)})},de=f.useMemo(()=>{const se=f.createElement("span",{className:`${_}-item-ellipsis`},"•••"),Me=f.createElement("button",{className:`${_}-item-link`,type:"button",tabIndex:-1},M==="rtl"?f.createElement(cf,null):f.createElement(fp,null)),ae=f.createElement("button",{className:`${_}-item-link`,type:"button",tabIndex:-1},M==="rtl"?f.createElement(fp,null):f.createElement(cf,null)),pe=f.createElement("a",{className:`${_}-item-link`},f.createElement("div",{className:`${_}-item-container`},M==="rtl"?f.createElement(D8,{className:`${_}-item-link-icon`}):f.createElement(O8,{className:`${_}-item-link-icon`}),se)),Ce=f.createElement("a",{className:`${_}-item-link`},f.createElement("div",{className:`${_}-item-container`},M==="rtl"?f.createElement(O8,{className:`${_}-item-link-icon`}):f.createElement(D8,{className:`${_}-item-link-icon`}),se));return {prevIcon:Me,nextIcon:ae,jumpPrevIcon:pe,jumpNextIcon:Ce}},[M,_]),ne=$("select",r),ce=X({[`${_}-${t}`]:!!t,[`${_}-${U}`]:U,[`${_}-mini`]:G,[`${_}-rtl`]:M==="rtl",[`${_}-bordered`]:w.wireframe},R,o,i,z.root,B,V),fe={...j.root,...I,...a};return f.createElement(f.Fragment,null,w.wireframe&&f.createElement(khe,{prefixCls:_}),f.createElement(The,{...de,...S,styles:j,classNames:z,style:fe,prefixCls:_,selectPrefixCls:ne,className:ce,locale:Y,pageSizeOptions:re,showSizeChanger:J,totalBoundaryShowSizeChanger:S.totalBoundaryShowSizeChanger??O,sizeChangerRender:ie}))},ry=100,fH=ry/5,mH=ry/2-fH/2,lw=mH*2*Math.PI,z8=50,k8=e=>{const{dotClassName:t,style:n,hasCircleCls:r}=e;return f.createElement("circle",{className:X(`${t}-circle`,{[`${t}-circle-bg`]:r}),r:mH,cx:z8,cy:z8,strokeWidth:fH,style:n})},Hhe=({percent:e,prefixCls:t})=>{const n=`${t}-dot`,r=`${n}-holder`,o=`${r}-hidden`,[i,a]=f.useState(false);An(()=>{e!==0&&a(true);},[e!==0]);const l=Math.max(Math.min(e,100),0);if(!i)return null;const u={strokeDashoffset:`${lw/4}`,strokeDasharray:`${lw*l/100} ${lw*(100-l)/100}`};return f.createElement("span",{className:X(r,`${n}-progress`,l<=0&&o)},f.createElement("svg",{viewBox:`0 0 ${ry} ${ry}`,role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l},f.createElement(k8,{dotClassName:n,hasCircleCls:true}),f.createElement(k8,{dotClassName:n,style:u})))};function Vhe(e){const{prefixCls:t,percent:n=0,className:r,style:o}=e,i=`${t}-dot`,a=`${i}-holder`,l=`${a}-hidden`;return f.createElement(f.Fragment,null,f.createElement("span",{className:X(a,r,n>0&&l),style:o},f.createElement("span",{className:X(i,`${t}-dot-spin`)},[1,2,3,4].map(u=>f.createElement("i",{className:`${t}-dot-item`,key:u})))),f.createElement(Hhe,{prefixCls:t,percent:n}))}function jhe(e){const{prefixCls:t,indicator:n,percent:r,className:o,style:i}=e,a=`${t}-dot`;return n&&f.isValidElement(n)?Hr(n,l=>({className:X(l.className,a,o),style:{...l.style,...i},percent:r})):f.createElement(Vhe,{prefixCls:t,percent:r,className:o,style:i})}const Uhe=new zt("antSpinMove",{to:{opacity:1}}),Whe=new zt("antRotate",{to:{transform:"rotate(405deg)"}}),Ghe=e=>{const{componentCls:t}=e,n=`${t}-section`;return {[t]:{...dn(e),position:"relative","&-rtl":{direction:"rtl"},[`&${n}, ${n}`]:{display:"flex",alignItems:"center",flexDirection:"column",gap:e.paddingSM,color:e.colorPrimary},[`&${n}`]:{display:"inline-flex"},[n]:{position:"absolute",top:"50%",left:{_skip_check_:true,value:"50%"},transform:"translate(-50%, -50%)",zIndex:1},[`${t}-description`]:{fontSize:e.fontSize,lineHeight:1},[`${t}-container`]:{position:"relative",transition:`opacity ${e.motionDurationSlow}`,"&::after":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,zIndex:10,width:"100%",height:"100%",background:e.colorBgContainer,opacity:0,transition:`all ${e.motionDurationSlow}`,content:'""',pointerEvents:"none"}},"&-spinning":{[`${t}-description`]:{textShadow:`0 0px 5px ${e.colorBgContainer}`},[`${t}-container`]:{clear:"both",opacity:.5,userSelect:"none",pointerEvents:"none","&::after":{opacity:.4,pointerEvents:"auto"}}},"&-fullscreen":{position:"fixed",inset:0,backgroundColor:e.colorBgMask,zIndex:e.zIndexPopupBase,opacity:0,pointerEvents:"none",transition:`all ${e.motionDurationMid}`,[`&${t}-spinning`]:{opacity:1,pointerEvents:"auto"},[n]:{color:e.colorWhite,[`${t}-description`]:{color:e.colorTextLightSolid}}}}}},qhe=e=>{const{componentCls:t,antCls:n,motionDurationSlow:r}=e,[o,i]=tr(n,"spin");return {[t]:{[o("dot-holder-size")]:e.dotSize,[o("dot-item-size")]:`calc((${i("dot-holder-size")} - ${e.marginXXS} / 2) / 2)`,[`${t}-dot`]:{"&-holder":{width:"1em",height:"1em",fontSize:i("dot-holder-size"),display:"inline-block",transition:["transform","opacity"].map(a=>`${a} ${r} ease`).join(", "),transformOrigin:"50% 50%",lineHeight:1,"&-hidden":{transform:"scale(0.3)",opacity:0}},position:"relative",display:"inline-block",fontSize:i("dot-holder-size"),width:"1em",height:"1em","&-spin":{transform:"rotate(45deg)",animationName:Whe,animationDuration:"1.2s",animationIterationCount:"infinite",animationTimingFunction:"linear"},"&-item":{position:"absolute",display:"block",width:i("dot-item-size"),height:i("dot-item-size"),background:"currentColor",borderRadius:"100%",transform:"scale(0.75)",transformOrigin:"50% 50%",opacity:.3,animationName:Uhe,animationDuration:"1s",animationIterationCount:"infinite",animationTimingFunction:"linear",animationDirection:"alternate","&:nth-child(1)":{top:0,insetInlineStart:0,animationDelay:"0s"},"&:nth-child(2)":{top:0,insetInlineEnd:0,animationDelay:"0.4s"},"&:nth-child(3)":{insetInlineEnd:0,bottom:0,animationDelay:"0.8s"},"&:nth-child(4)":{bottom:0,insetInlineStart:0,animationDelay:"1.2s"}},"&-progress":{position:"absolute",left:"50%",top:0,transform:"translateX(-50%)"},"&-circle":{strokeLinecap:"round",transition:["stroke-dashoffset","stroke-dasharray","stroke","stroke-width","opacity"].map(a=>`${a} ${r} ease`).join(","),fillOpacity:0,stroke:"currentcolor"},"&-circle-bg":{stroke:e.colorFillSecondary}}}}},Khe=e=>{const{componentCls:t}=e,[n]=tr(e.antCls,"spin");return {[t]:{"&-sm":{[n("dot-holder-size")]:e.dotSizeSM},"&-lg":{[n("dot-holder-size")]:e.dotSizeLG}}}},Yhe=e=>{const{controlHeightLG:t,controlHeight:n}=e;return {contentHeight:400,dotSize:t/2,dotSizeSM:t*.35,dotSizeLG:n}},Xhe=Wt("Spin",e=>{const t=Ft(e,{spinDotDefault:e.colorTextDescription});return [Ghe(t),qhe(t),Khe(t)]},Yhe),Qhe=200,F8=[[30,.05],[70,.03],[96,.01]];function Zhe(e,t){const[n,r]=f.useState(0),o=f.useRef(null),i=t==="auto";return f.useEffect(()=>(i&&e&&(r(0),o.current=setInterval(()=>{r(a=>{const l=100-a;for(let u=0;u<F8.length;u+=1){const[d,m]=F8[u];if(a<=d)return a+l*m}return a});},Qhe)),()=>{o.current&&(clearInterval(o.current),o.current=null);}),[i,e]),i?n:t}let hH;function Jhe(e,t){return !!e&&!!t&&!Number.isNaN(Number(t))}const b1=e=>{const{prefixCls:t,spinning:n=true,delay:r=0,className:o,rootClassName:i,size:a="default",tip:l,description:u,wrapperClassName:d,style:m,children:p,fullscreen:g=false,indicator:b,percent:y,classNames:S,styles:C,...w}=e,{getPrefixCls:$,direction:M,indicator:T,className:R,style:I,classNames:N,styles:P}=jt("spin"),O=$("spin",t),[_,B]=Xhe(O),[V,U]=f.useState(()=>n&&!Jhe(n,r)),G=Zhe(V,y);f.useEffect(()=>{if(n){const K=Lde(r,()=>{U(true);});return K(),()=>{K?.cancel?.();}}U(false);},[r,n]);const H=u??l,z={...e,size:a,spinning:V,tip:H,description:H,fullscreen:g,children:p,percent:G},[j,W]=Kt([N,S],[P,C],{props:z}),Y=b??T??hH,Q=typeof p<"u",D=Q||g,L=f.createElement(f.Fragment,null,f.createElement(jhe,{className:X(j.indicator),style:W.indicator,prefixCls:O,indicator:Y,percent:G}),H&&f.createElement("div",{className:X(`${O}-description`,j.tip,j.description),style:{...W.tip,...W.description}},H));return f.createElement("div",{className:X(O,{[`${O}-sm`]:a==="small",[`${O}-lg`]:a==="large",[`${O}-spinning`]:V,[`${O}-rtl`]:M==="rtl",[`${O}-fullscreen`]:g},i,j.root,g&&j.mask,D?d:[`${O}-section`,j.section],R,o,_,B),style:{...W.root,...D?{}:W.section,...g?W.mask:{},...I,...m},"aria-live":"polite","aria-busy":V,...w},V&&(D?f.createElement("div",{className:X(`${O}-section`,j.section),style:W.section},L):L),Q&&f.createElement("div",{className:X(`${O}-container`,j.container),style:W.container},p))};b1.setDefaultIndicator=e=>{hH=e;};let Dc=null,jc=e=>e(),gp=[],vp={};function H8(){const{getContainer:e,duration:t,rtl:n,maxCount:r,top:o}=vp,i=e?.()||document.body;return {getContainer:()=>i,duration:t,rtl:n,maxCount:r,top:o}}const epe=q.forwardRef((e,t)=>{const{messageConfig:n,sync:r}=e,{getPrefixCls:o}=f.useContext(wt),i=vp.prefixCls||o("message"),a=f.useContext(V0),[l,u]=xk({...n,prefixCls:i,...a.message});return q.useImperativeHandle(t,()=>{const d={...l};return Object.keys(d).forEach(m=>{d[m]=(...p)=>(r(),l[m].apply(l,p));}),{instance:d,sync:r}}),u}),tpe=q.forwardRef((e,t)=>{const[n,r]=q.useState(H8),o=()=>{r(H8);};q.useEffect(o,[]);const i=iR(),a=i.getRootPrefixCls(),l=i.getIconPrefixCls(),u=i.getTheme(),d=q.createElement(epe,{ref:t,sync:o,messageConfig:n});return q.createElement(Do,{prefixCls:a,iconPrefixCls:l,theme:u},i.holderRender?i.holderRender(d):d)}),y1=()=>{if(!Dc){const e=document.createDocumentFragment(),t={fragment:e};Dc=t,jc(()=>{t1(q.createElement(tpe,{ref:n=>{const{instance:r,sync:o}=n||{};Promise.resolve().then(()=>{!t.instance&&r&&(t.instance=r,t.sync=o,y1());});}}),e);});return}Dc.instance&&(gp.forEach(e=>{const{type:t,skipped:n}=e;if(!n)switch(t){case "open":{jc(()=>{const r=Dc.instance.open({...vp,...e.config});r?.then(e.resolve),e.setCloseFn(r);});break}case "destroy":jc(()=>{Dc?.instance.destroy(e.key);});break;default:jc(()=>{var r;const o=(r=Dc.instance)[t].apply(r,qt(e.args));o?.then(e.resolve),e.setCloseFn(o);});}}),gp=[]);};function npe(e){vp={...vp,...e},jc(()=>{Dc?.sync?.();});}function rpe(e){const t=sR(n=>{let r;const o={type:"open",config:e,resolve:n,setCloseFn:i=>{r=i;}};return gp.push(o),()=>{r?jc(()=>{r();}):o.skipped=true;}});return y1(),t}function ope(e,t){const n=sR(r=>{let o;const i={type:e,args:t,resolve:r,setCloseFn:a=>{o=a;}};return gp.push(i),()=>{o?jc(()=>{o();}):i.skipped=true;}});return y1(),n}const ipe=e=>{gp.push({type:"destroy",key:e}),y1();},ape=["success","info","warning","error","loading"],spe={open:rpe,destroy:ipe,config:npe,useMessage:wk,_InternalPanelDoNotUseOrYouWillBeFired:nre},rT=spe;ape.forEach(e=>{rT[e]=(...t)=>ope(e,t);});const lpe=e=>{const{prefixCls:t,className:n,closeIcon:r,closable:o,type:i,title:a,children:l,footer:u,classNames:d,styles:m,...p}=e,{getPrefixCls:g}=f.useContext(wt),{className:b,style:y,classNames:S,styles:C}=jt("modal"),w=g(),$=t||g("modal"),M=Qn(w),[T,R]=tF($,M),[I,N]=Kt([S,d],[C,m],{props:e}),P=`${$}-confirm`;let O={};return i?O={closable:o??false,title:"",footer:"",children:f.createElement(rF,{...e,prefixCls:$,confirmPrefixCls:P,rootPrefixCls:w,content:l})}:O={closable:o??true,title:a,footer:u!==null&&f.createElement(Qk,{...e}),children:l},f.createElement(jk,{prefixCls:$,className:X(T,`${$}-pure-panel`,i&&P,i&&`${P}-${i}`,n,b,R,M,I.root),style:{...y,...N.root},...p,closeIcon:Xk($,r),closable:o,classNames:I,styles:N,...O})},cpe=CF(lpe);function pH(e){return rg(sF(e))}const Ea=nF;Ea.useModal=fF;Ea.info=function(t){return rg(lF(t))};Ea.success=function(t){return rg(cF(t))};Ea.error=function(t){return rg(uF(t))};Ea.warning=pH;Ea.warn=pH;Ea.confirm=function(t){return rg(dF(t))};Ea.destroyAll=function(){for(;Hc.length;){const t=Hc.pop();t&&t();}};Ea.config=jae;Ea._InternalPanelDoNotUseOrYouWillBeFired=cpe;let Td=null,Qb=e=>e(),oy=[],bp={};function V8(){const{getContainer:e,rtl:t,maxCount:n,top:r,bottom:o,showProgress:i,pauseOnHover:a}=bp,l=e?.()||document.body;return {getContainer:()=>l,rtl:t,maxCount:n,top:r,bottom:o,showProgress:i,pauseOnHover:a}}const upe=q.forwardRef((e,t)=>{const{notificationConfig:n,sync:r}=e,{getPrefixCls:o}=f.useContext(wt),i=bp.prefixCls||o("notification"),a=f.useContext(V0),[l,u]=bF({...n,prefixCls:i,...a.notification});return q.useEffect(r,[]),q.useImperativeHandle(t,()=>{const d={...l};return Object.keys(d).forEach(m=>{d[m]=(...p)=>(r(),l[m].apply(l,p));}),{instance:d,sync:r}}),u}),dpe=q.forwardRef((e,t)=>{const[n,r]=q.useState(V8),o=()=>{r(V8);};q.useEffect(o,[]);const i=iR(),a=i.getRootPrefixCls(),l=i.getIconPrefixCls(),u=i.getTheme(),d=q.createElement(upe,{ref:t,sync:o,notificationConfig:n});return q.createElement(Do,{prefixCls:a,iconPrefixCls:l,theme:u},i.holderRender?i.holderRender(d):d)}),oT=()=>{if(!Td){const e=document.createDocumentFragment(),t={fragment:e};Td=t,Qb(()=>{t1(q.createElement(dpe,{ref:n=>{const{instance:r,sync:o}=n||{};Promise.resolve().then(()=>{!t.instance&&r&&(t.instance=r,t.sync=o,oT());});}}),e);});return}Td.instance&&(oy.forEach(e=>{switch(e.type){case "open":{Qb(()=>{Td.instance.open({...bp,...e.config});});break}case "destroy":Qb(()=>{Td?.instance?.destroy(e.key);});break}}),oy=[]);};function fpe(e){bp={...bp,...e},Qb(()=>{Td?.sync?.();});}function gH(e){oy.push({type:"open",config:e}),oT();}const mpe=e=>{oy.push({type:"destroy",key:e}),oT();},hpe=["success","info","warning","error"],ppe={open:gH,destroy:mpe,config:fpe,useNotification:yF,_InternalPanelDoNotUseOrYouWillBeFired:rse},vH=ppe;hpe.forEach(e=>{vH[e]=t=>gH({...t,type:e});});const gpe=e=>{const{componentCls:t,iconCls:n,antCls:r,zIndexPopup:o,colorText:i,colorWarning:a,marginXXS:l,marginXS:u,fontSize:d,fontWeightStrong:m,colorTextHeading:p}=e;return {[t]:{zIndex:o,[`&${r}-popover`]:{fontSize:d},[`${t}-message`]:{marginBottom:u,display:"flex",flexWrap:"nowrap",alignItems:"start",[`> ${t}-message-icon ${n}`]:{color:a,fontSize:d,lineHeight:1,marginInlineEnd:u},[`${t}-title`]:{fontWeight:m,color:p,"&:only-child":{fontWeight:"normal"}},[`${t}-description`]:{marginTop:l,color:i}},[`${t}-buttons`]:{textAlign:"end",whiteSpace:"nowrap",button:{marginInlineStart:u}}}}},vpe=e=>{const{zIndexPopupBase:t}=e;return {zIndexPopup:t+60}},bH=Wt("Popconfirm",e=>gpe(e),vpe,{resetStyle:false}),yH=e=>{const{prefixCls:t,okButtonProps:n,cancelButtonProps:r,title:o,description:i,cancelText:a,okText:l,okType:u="primary",icon:d=f.createElement(Yp,null),showCancel:m=true,close:p,onConfirm:g,onCancel:b,onPopupClick:y,classNames:S,styles:C}=e,{getPrefixCls:w}=f.useContext(wt),[$]=Oo("Popconfirm",ya.Popconfirm),M=df(o),T=df(i);return f.createElement("div",{className:`${t}-inner-content`,onClick:y},f.createElement("div",{className:`${t}-message`},d&&f.createElement("span",{className:`${t}-message-icon`},d),f.createElement("div",{className:`${t}-message-text`},M&&f.createElement("div",{className:X(`${t}-title`,S?.title),style:C?.title},M),T&&f.createElement("div",{className:X(`${t}-description`,S?.content),style:C?.content},T))),f.createElement("div",{className:`${t}-buttons`},m&&f.createElement(st,{onClick:b,size:"small",...r},a||$?.cancelText),f.createElement(SR,{buttonProps:{size:"small",...cR(u),...n},actionFn:g,close:p,prefixCls:w("btn"),quitOnNullishReturnValue:true,emitEvent:true},l||$?.okText)))},bpe=e=>{const{prefixCls:t,placement:n,className:r,style:o,...i}=e,{getPrefixCls:a}=f.useContext(wt),l=a("popconfirm",t);return bH(l),f.createElement(YF,{placement:n,className:X(l,r),style:o,content:f.createElement(yH,{prefixCls:l,...i})})},ype=f.forwardRef((e,t)=>{const{prefixCls:n,placement:r="top",trigger:o,okType:i="primary",icon:a=f.createElement(Yp,null),children:l,overlayClassName:u,onOpenChange:d,overlayStyle:m,styles:p,arrow:g,classNames:b,...y}=e,{getPrefixCls:S,className:C,style:w,classNames:$,styles:M,arrow:T,trigger:R}=jt("popconfirm"),[I,N]=un(e.defaultOpen??false,e.open),P=l1(g,T),O=o||R||"click",_=Q=>{N(Q),d?.(Q);},B=()=>{_(false);},V=Q=>e.onConfirm?.call(void 0,Q),U=Q=>{_(false),e.onCancel?.call(void 0,Q);},G=Q=>{const{disabled:D=false}=e;D||_(Q);},H=S("popconfirm",n),z={...e,placement:r,trigger:O,okType:i,overlayStyle:m,styles:p,classNames:b},[j,W]=Kt([$,b],[M,p],{props:z}),Y=X(H,C,u,j.root);return bH(H),f.createElement(Zo,{arrow:P,...Ln(y,["title"]),trigger:O,placement:r,onOpenChange:G,open:I,ref:t,classNames:{root:Y,container:j.container,arrow:j.arrow},styles:{root:{...w,...W.root,...m},container:W.container,arrow:W.arrow},content:f.createElement(yH,{okType:i,icon:a,...e,prefixCls:H,close:B,onConfirm:V,onCancel:U,classNames:j,styles:W}),"data-popover-inject":true},l)}),yp=ype;yp._InternalPanelDoNotUseOrYouWillBeFired=bpe;function _d(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=BM(e))||t){n&&(e=n);var r=0,o=function(){};return {s:o,n:function(){return r>=e.length?{done:true}:{done:false,value:e[r++]}},e:function(d){throw d},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var i,a=true,l=false;return {s:function(){n=n.call(e);},n:function(){var d=n.next();return a=d.done,d},e:function(d){l=true,i=d;},f:function(){try{a||n.return==null||n.return();}finally{if(l)throw i}}}}var Ff,sg;function Uo(e,t,n){if(t<0||t>31||e>>>t)throw new RangeError("Value out of range");for(var r=t-1;r>=0;r--)n.push(e>>>r&1);}function vs(e,t){return (e>>>t&1)!=0}function ui(e){if(!e)throw new Error("Assertion error")}var za=(function(){function e(t,n){Xi(this,e),Ct(this,"modeBits",void 0),Ct(this,"numBitsCharCount",void 0),this.modeBits=t,this.numBitsCharCount=n;}return Qi(e,[{key:"numCharCountBits",value:function(n){return this.numBitsCharCount[Math.floor((n+7)/17)]}}]),e})();Ff=za;Ct(za,"NUMERIC",new Ff(1,[10,12,14]));Ct(za,"ALPHANUMERIC",new Ff(2,[9,11,13]));Ct(za,"BYTE",new Ff(4,[8,16,16]));Ct(za,"KANJI",new Ff(8,[8,10,12]));Ct(za,"ECI",new Ff(7,[0,0,0]));var ji=Qi(function e(t,n){Xi(this,e),Ct(this,"ordinal",void 0),Ct(this,"formatBits",void 0),this.ordinal=t,this.formatBits=n;});sg=ji;Ct(ji,"LOW",new sg(0,1));Ct(ji,"MEDIUM",new sg(1,0));Ct(ji,"QUARTILE",new sg(2,3));Ct(ji,"HIGH",new sg(3,2));var Jc=(function(){function e(t,n,r){if(Xi(this,e),Ct(this,"mode",void 0),Ct(this,"numChars",void 0),Ct(this,"bitData",void 0),this.mode=t,this.numChars=n,this.bitData=r,n<0)throw new RangeError("Invalid argument");this.bitData=r.slice();}return Qi(e,[{key:"getData",value:function(){return this.bitData.slice()}}],[{key:"makeBytes",value:function(n){var r=[],o=_d(n),i;try{for(o.s();!(i=o.n()).done;){var a=i.value;Uo(a,8,r);}}catch(l){o.e(l);}finally{o.f();}return new e(za.BYTE,n.length,r)}},{key:"makeNumeric",value:function(n){if(!e.isNumeric(n))throw new RangeError("String contains non-numeric characters");for(var r=[],o=0;o<n.length;){var i=Math.min(n.length-o,3);Uo(parseInt(n.substring(o,o+i),10),i*3+1,r),o+=i;}return new e(za.NUMERIC,n.length,r)}},{key:"makeAlphanumeric",value:function(n){if(!e.isAlphanumeric(n))throw new RangeError("String contains unencodable characters in alphanumeric mode");var r=[],o;for(o=0;o+2<=n.length;o+=2){var i=e.ALPHANUMERIC_CHARSET.indexOf(n.charAt(o))*45;i+=e.ALPHANUMERIC_CHARSET.indexOf(n.charAt(o+1)),Uo(i,11,r);}return o<n.length&&Uo(e.ALPHANUMERIC_CHARSET.indexOf(n.charAt(o)),6,r),new e(za.ALPHANUMERIC,n.length,r)}},{key:"makeSegments",value:function(n){return n==""?[]:e.isNumeric(n)?[e.makeNumeric(n)]:e.isAlphanumeric(n)?[e.makeAlphanumeric(n)]:[e.makeBytes(e.toUtf8ByteArray(n))]}},{key:"makeEci",value:function(n){var r=[];if(n<0)throw new RangeError("ECI assignment value out of range");if(n<128)Uo(n,8,r);else if(n<16384)Uo(2,2,r),Uo(n,14,r);else if(n<1e6)Uo(6,3,r),Uo(n,21,r);else throw new RangeError("ECI assignment value out of range");return new e(za.ECI,0,r)}},{key:"isNumeric",value:function(n){return e.NUMERIC_REGEX.test(n)}},{key:"isAlphanumeric",value:function(n){return e.ALPHANUMERIC_REGEX.test(n)}},{key:"getTotalBits",value:function(n,r){var o=0,i=_d(n),a;try{for(i.s();!(a=i.n()).done;){var l=a.value,u=l.mode.numCharCountBits(r);if(l.numChars>=1<<u)return 1/0;o+=4+u+l.bitData.length;}}catch(d){i.e(d);}finally{i.f();}return o}},{key:"toUtf8ByteArray",value:function(n){for(var r=encodeURI(n),o=[],i=0;i<r.length;i++)r.charAt(i)!="%"?o.push(r.charCodeAt(i)):(o.push(parseInt(r.substring(i+1,i+3),16)),i+=2);return o}}]),e})();Ct(Jc,"NUMERIC_REGEX",/^[0-9]*$/);Ct(Jc,"ALPHANUMERIC_REGEX",/^[A-Z0-9 $%*+.\/:-]*$/);Ct(Jc,"ALPHANUMERIC_CHARSET","0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ $%*+-./:");var Fs=(function(){function e(t,n,r,o){Xi(this,e),Ct(this,"size",void 0),Ct(this,"mask",void 0),Ct(this,"modules",[]),Ct(this,"isFunction",[]),Ct(this,"version",void 0),Ct(this,"errorCorrectionLevel",void 0);var i=o;if(this.version=t,this.errorCorrectionLevel=n,t<e.MIN_VERSION||t>e.MAX_VERSION)throw new RangeError("Version value out of range");if(i<-1||i>7)throw new RangeError("Mask value out of range");this.size=t*4+17;for(var a=[],l=0;l<this.size;l++)a.push(false);for(var u=0;u<this.size;u++)this.modules.push(a.slice()),this.isFunction.push(a.slice());this.drawFunctionPatterns();var d=this.addEccAndInterleave(r);if(this.drawCodewords(d),i==-1)for(var m=1e9,p=0;p<8;p++){this.applyMask(p),this.drawFormatBits(p);var g=this.getPenaltyScore();g<m&&(i=p,m=g),this.applyMask(p);}ui(0<=i&&i<=7),this.mask=i,this.applyMask(i),this.drawFormatBits(i),this.isFunction=[];}return Qi(e,[{key:"getModule",value:function(n,r){return 0<=n&&n<this.size&&0<=r&&r<this.size&&this.modules[r][n]}},{key:"getModules",value:function(){return this.modules}},{key:"drawFunctionPatterns",value:function(){for(var n=0;n<this.size;n++)this.setFunctionModule(6,n,n%2==0),this.setFunctionModule(n,6,n%2==0);this.drawFinderPattern(3,3),this.drawFinderPattern(this.size-4,3),this.drawFinderPattern(3,this.size-4);for(var r=this.getAlignmentPatternPositions(),o=r.length,i=0;i<o;i++)for(var a=0;a<o;a++)i==0&&a==0||i==0&&a==o-1||i==o-1&&a==0||this.drawAlignmentPattern(r[i],r[a]);this.drawFormatBits(0),this.drawVersion();}},{key:"drawFormatBits",value:function(n){for(var r=this.errorCorrectionLevel.formatBits<<3|n,o=r,i=0;i<10;i++)o=o<<1^(o>>>9)*1335;var a=(r<<10|o)^21522;ui(a>>>15==0);for(var l=0;l<=5;l++)this.setFunctionModule(8,l,vs(a,l));this.setFunctionModule(8,7,vs(a,6)),this.setFunctionModule(8,8,vs(a,7)),this.setFunctionModule(7,8,vs(a,8));for(var u=9;u<15;u++)this.setFunctionModule(14-u,8,vs(a,u));for(var d=0;d<8;d++)this.setFunctionModule(this.size-1-d,8,vs(a,d));for(var m=8;m<15;m++)this.setFunctionModule(8,this.size-15+m,vs(a,m));this.setFunctionModule(8,this.size-8,true);}},{key:"drawVersion",value:function(){if(!(this.version<7)){for(var n=this.version,r=0;r<12;r++)n=n<<1^(n>>>11)*7973;var o=this.version<<12|n;ui(o>>>18==0);for(var i=0;i<18;i++){var a=vs(o,i),l=this.size-11+i%3,u=Math.floor(i/3);this.setFunctionModule(l,u,a),this.setFunctionModule(u,l,a);}}}},{key:"drawFinderPattern",value:function(n,r){for(var o=-4;o<=4;o++)for(var i=-4;i<=4;i++){var a=Math.max(Math.abs(i),Math.abs(o)),l=n+i,u=r+o;0<=l&&l<this.size&&0<=u&&u<this.size&&this.setFunctionModule(l,u,a!=2&&a!=4);}}},{key:"drawAlignmentPattern",value:function(n,r){for(var o=-2;o<=2;o++)for(var i=-2;i<=2;i++)this.setFunctionModule(n+i,r+o,Math.max(Math.abs(i),Math.abs(o))!=1);}},{key:"setFunctionModule",value:function(n,r,o){this.modules[r][n]=o,this.isFunction[r][n]=true;}},{key:"addEccAndInterleave",value:function(n){var r=this.version,o=this.errorCorrectionLevel;if(n.length!=e.getNumDataCodewords(r,o))throw new RangeError("Invalid argument");for(var i=e.NUM_ERROR_CORRECTION_BLOCKS[o.ordinal][r],a=e.ECC_CODEWORDS_PER_BLOCK[o.ordinal][r],l=Math.floor(e.getNumRawDataModules(r)/8),u=i-l%i,d=Math.floor(l/i),m=[],p=e.reedSolomonComputeDivisor(a),g=0,b=0;g<i;g++){var y=n.slice(b,b+d-a+(g<u?0:1));b+=y.length;var S=e.reedSolomonComputeRemainder(y,p);g<u&&y.push(0),m.push(y.concat(S));}for(var C=[],w=function(T){m.forEach(function(R,I){(T!=d-a||I>=u)&&C.push(R[T]);});},$=0;$<m[0].length;$++)w($);return ui(C.length==l),C}},{key:"drawCodewords",value:function(n){if(n.length!=Math.floor(e.getNumRawDataModules(this.version)/8))throw new RangeError("Invalid argument");for(var r=0,o=this.size-1;o>=1;o-=2){o==6&&(o=5);for(var i=0;i<this.size;i++)for(var a=0;a<2;a++){var l=o-a,u=(o+1&2)==0,d=u?this.size-1-i:i;!this.isFunction[d][l]&&r<n.length*8&&(this.modules[d][l]=vs(n[r>>>3],7-(r&7)),r++);}}ui(r==n.length*8);}},{key:"applyMask",value:function(n){if(n<0||n>7)throw new RangeError("Mask value out of range");for(var r=0;r<this.size;r++)for(var o=0;o<this.size;o++){var i=void 0;switch(n){case 0:i=(o+r)%2==0;break;case 1:i=r%2==0;break;case 2:i=o%3==0;break;case 3:i=(o+r)%3==0;break;case 4:i=(Math.floor(o/3)+Math.floor(r/2))%2==0;break;case 5:i=o*r%2+o*r%3==0;break;case 6:i=(o*r%2+o*r%3)%2==0;break;case 7:i=((o+r)%2+o*r%3)%2==0;break;default:throw new Error("Unreachable")}!this.isFunction[r][o]&&i&&(this.modules[r][o]=!this.modules[r][o]);}}},{key:"getPenaltyScore",value:function(){for(var n=0,r=0;r<this.size;r++){for(var o=false,i=0,a=[0,0,0,0,0,0,0],l=0;l<this.size;l++)this.modules[r][l]==o?(i++,i==5?n+=e.PENALTY_N1:i>5&&n++):(this.finderPenaltyAddHistory(i,a),o||(n+=this.finderPenaltyCountPatterns(a)*e.PENALTY_N3),o=this.modules[r][l],i=1);n+=this.finderPenaltyTerminateAndCount(o,i,a)*e.PENALTY_N3;}for(var u=0;u<this.size;u++){for(var d=false,m=0,p=[0,0,0,0,0,0,0],g=0;g<this.size;g++)this.modules[g][u]==d?(m++,m==5?n+=e.PENALTY_N1:m>5&&n++):(this.finderPenaltyAddHistory(m,p),d||(n+=this.finderPenaltyCountPatterns(p)*e.PENALTY_N3),d=this.modules[g][u],m=1);n+=this.finderPenaltyTerminateAndCount(d,m,p)*e.PENALTY_N3;}for(var b=0;b<this.size-1;b++)for(var y=0;y<this.size-1;y++){var S=this.modules[b][y];S==this.modules[b][y+1]&&S==this.modules[b+1][y]&&S==this.modules[b+1][y+1]&&(n+=e.PENALTY_N2);}var C=0,w=_d(this.modules),$;try{for(w.s();!($=w.n()).done;){var M=$.value;C=M.reduce(function(I,N){return I+(N?1:0)},C);}}catch(I){w.e(I);}finally{w.f();}var T=this.size*this.size,R=Math.ceil(Math.abs(C*20-T*10)/T)-1;return ui(0<=R&&R<=9),n+=R*e.PENALTY_N4,ui(0<=n&&n<=2568888),n}},{key:"getAlignmentPatternPositions",value:function(){if(this.version==1)return [];for(var n=Math.floor(this.version/7)+2,r=this.version==32?26:Math.ceil((this.version*4+4)/(n*2-2))*2,o=[6],i=this.size-7;o.length<n;i-=r)o.splice(1,0,i);return o}},{key:"finderPenaltyCountPatterns",value:function(n){var r=n[1];ui(r<=this.size*3);var o=r>0&&n[2]==r&&n[3]==r*3&&n[4]==r&&n[5]==r;return (o&&n[0]>=r*4&&n[6]>=r?1:0)+(o&&n[6]>=r*4&&n[0]>=r?1:0)}},{key:"finderPenaltyTerminateAndCount",value:function(n,r,o){var i=r;return n&&(this.finderPenaltyAddHistory(i,o),i=0),i+=this.size,this.finderPenaltyAddHistory(i,o),this.finderPenaltyCountPatterns(o)}},{key:"finderPenaltyAddHistory",value:function(n,r){var o=n;r[0]==0&&(o+=this.size),r.pop(),r.unshift(o);}}],[{key:"encodeText",value:function(n,r){var o=Jc.makeSegments(n);return e.encodeSegments(o,r)}},{key:"encodeBinary",value:function(n,r){var o=Jc.makeBytes(n);return e.encodeSegments([o],r)}},{key:"encodeSegments",value:function(n,r){var o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:40,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1,l=arguments.length>5&&arguments[5]!==void 0?arguments[5]:true;if(!(e.MIN_VERSION<=o&&o<=i&&i<=e.MAX_VERSION)||a<-1||a>7)throw new RangeError("Invalid value");var u,d;for(u=o;;u++){var m=e.getNumDataCodewords(u,r)*8,p=Jc.getTotalBits(n,u);if(p<=m){d=p;break}if(u>=i)throw new RangeError("Data too long")}for(var g=r,b=0,y=[ji.MEDIUM,ji.QUARTILE,ji.HIGH];b<y.length;b++){var S=y[b];l&&d<=e.getNumDataCodewords(u,S)*8&&(g=S);}var C=[],w=_d(n),$;try{for(w.s();!($=w.n()).done;){var M=$.value;Uo(M.mode.modeBits,4,C),Uo(M.numChars,M.mode.numCharCountBits(u),C);var T=_d(M.getData()),R;try{for(T.s();!(R=T.n()).done;){var I=R.value;C.push(I);}}catch(_){T.e(_);}finally{T.f();}}}catch(_){w.e(_);}finally{w.f();}ui(C.length==d);var N=e.getNumDataCodewords(u,g)*8;ui(C.length<=N),Uo(0,Math.min(4,N-C.length),C),Uo(0,(8-C.length%8)%8,C),ui(C.length%8==0);for(var P=236;C.length<N;P^=253)Uo(P,8,C);for(var O=[];O.length*8<C.length;)O.push(0);return C.forEach(function(_,B){O[B>>>3]|=_<<7-(B&7);}),new e(u,g,O,a)}},{key:"getNumRawDataModules",value:function(n){if(n<e.MIN_VERSION||n>e.MAX_VERSION)throw new RangeError("Version number out of range");var r=(16*n+128)*n+64;if(n>=2){var o=Math.floor(n/7)+2;r-=(25*o-10)*o-55,n>=7&&(r-=36);}return ui(208<=r&&r<=29648),r}},{key:"getNumDataCodewords",value:function(n,r){return Math.floor(e.getNumRawDataModules(n)/8)-e.ECC_CODEWORDS_PER_BLOCK[r.ordinal][n]*e.NUM_ERROR_CORRECTION_BLOCKS[r.ordinal][n]}},{key:"reedSolomonComputeDivisor",value:function(n){if(n<1||n>255)throw new RangeError("Degree out of range");for(var r=[],o=0;o<n-1;o++)r.push(0);r.push(1);for(var i=1,a=0;a<n;a++){for(var l=0;l<r.length;l++)r[l]=e.reedSolomonMultiply(r[l],i),l+1<r.length&&(r[l]^=r[l+1]);i=e.reedSolomonMultiply(i,2);}return r}},{key:"reedSolomonComputeRemainder",value:function(n,r){var o=r.map(function(){return 0}),i=_d(n),a;try{var l=function(){var d=a.value,m=d^o.shift();o.push(0),r.forEach(function(p,g){o[g]^=e.reedSolomonMultiply(p,m);});};for(i.s();!(a=i.n()).done;)l();}catch(u){i.e(u);}finally{i.f();}return o}},{key:"reedSolomonMultiply",value:function(n,r){if(n>>>8||r>>>8)throw new RangeError("Byte out of range");for(var o=0,i=7;i>=0;i--)o=o<<1^(o>>>7)*285,o^=(r>>>i&1)*n;return ui(o>>>8==0),o}}]),e})();Ct(Fs,"MIN_VERSION",1);Ct(Fs,"MAX_VERSION",40);Ct(Fs,"PENALTY_N1",3);Ct(Fs,"PENALTY_N2",3);Ct(Fs,"PENALTY_N3",40);Ct(Fs,"PENALTY_N4",10);Ct(Fs,"ECC_CODEWORDS_PER_BLOCK",[[-1,7,10,15,20,26,18,20,24,30,18,20,24,26,30,22,24,28,30,28,28,28,28,30,30,26,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,10,16,26,18,24,16,18,22,22,26,30,22,22,24,24,28,28,26,26,26,26,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28,28],[-1,13,22,18,26,18,24,18,22,20,24,28,26,24,20,30,24,28,28,26,30,28,30,30,30,30,28,30,30,30,30,30,30,30,30,30,30,30,30,30,30],[-1,17,28,22,16,22,28,26,26,24,28,24,28,22,24,24,30,28,28,26,28,30,24,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30,30]]);Ct(Fs,"NUM_ERROR_CORRECTION_BLOCKS",[[-1,1,1,1,1,1,2,2,2,2,4,4,4,4,4,6,6,6,6,7,8,8,9,9,10,12,12,12,13,14,15,16,17,18,19,19,20,21,22,24,25],[-1,1,1,1,2,2,4,4,4,5,5,5,8,9,9,10,10,11,13,14,16,17,17,18,20,21,23,25,26,28,29,31,33,35,37,38,40,43,45,47,49],[-1,1,1,2,2,4,4,6,6,8,8,8,10,12,16,12,17,16,18,21,20,23,23,25,27,29,34,34,35,38,40,43,45,48,51,53,56,59,62,65,68],[-1,1,1,2,4,4,4,5,6,8,8,11,11,16,16,18,16,19,21,25,25,25,34,30,32,35,37,40,42,45,48,51,54,57,60,63,66,70,74,77,81]]);var Spe={L:ji.LOW,M:ji.MEDIUM,Q:ji.QUARTILE,H:ji.HIGH},SH=128,CH="L",xH="#FFFFFF",wH="#000000",$H=false,EH=1,Cpe=4,xpe=0,wpe=.1,MH=function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=[];return t.forEach(function(o,i){var a=null;o.forEach(function(l,u){if(!l&&a!==null){r.push("M".concat(a+n," ").concat(i+n,"h").concat(u-a,"v1H").concat(a+n,"z")),a=null;return}if(u===o.length-1){if(!l)return;a===null?r.push("M".concat(u+n,",").concat(i+n," h1v1H").concat(u+n,"z")):r.push("M".concat(a+n,",").concat(i+n," h").concat(u+1-a,"v1H").concat(a+n,"z"));return}l&&a===null&&(a=u);});}),r.join("")},RH=function(t,n){return t.slice().map(function(r,o){return o<n.y||o>=n.y+n.h?r:r.map(function(i,a){return a<n.x||a>=n.x+n.w?i:false})})},$pe=function(t,n,r,o){if(o==null)return null;var i=t.length+r*2,a=Math.floor(n*wpe),l=i/n,u=(o.width||a)*l,d=(o.height||a)*l,m=o.x==null?t.length/2-u/2:o.x*l,p=o.y==null?t.length/2-d/2:o.y*l,g=o.opacity==null?1:o.opacity,b=null;if(o.excavate){var y=Math.floor(m),S=Math.floor(p),C=Math.ceil(u+m-y),w=Math.ceil(d+p-S);b={x:y,y:S,w:C,h:w};}var $=o.crossOrigin;return {x:m,y:p,h:d,w:u,excavation:b,opacity:g,crossOrigin:$}},Epe=function(t,n){return n!=null?Math.max(Math.floor(n),0):t?Cpe:xpe},Mpe=(function(){try{new Path2D().addPath(new Path2D);}catch{return false}return true})(),TH=function(t){var n=t.value,r=t.level,o=t.minVersion,i=t.includeMargin,a=t.marginSize,l=t.imageSettings,u=t.size,d=t.boostLevel,m=q.useMemo(function(){var p=Array.isArray(n)?n:[n],g=p.reduce(function(b,y){return b.push.apply(b,qt(Jc.makeSegments(y))),b},[]);return Fs.encodeSegments(g,Spe[r],o,void 0,void 0,d)},[n,r,o,d]);return q.useMemo(function(){var p=m.getModules(),g=Epe(i,a),b=p.length+g*2,y=$pe(p,u,g,l);return {cells:p,margin:g,numCells:b,calculatedImageSettings:y,qrcode:m}},[m,u,l,i,a])},Rpe=["value","size","level","bgColor","fgColor","includeMargin","minVersion","marginSize","style","imageSettings","boostLevel"],Tpe=q.forwardRef(function(e,t){var n=e.value,r=e.size,o=r===void 0?SH:r,i=e.level,a=i===void 0?CH:i,l=e.bgColor,u=l===void 0?xH:l,d=e.fgColor,m=d===void 0?wH:d,p=e.includeMargin,g=p===void 0?$H:p,b=e.minVersion,y=b===void 0?EH:b,S=e.marginSize,C=e.style,w=e.imageSettings,$=e.boostLevel,M=O7(e,Rpe),T=w?.src,R=q.useRef(null),I=q.useRef(null),N=q.useCallback(function(W){R.current=W,typeof t=="function"?t(W):t&&(t.current=W);},[t]),P=q.useState(false),O=UM(P,2),_=O[1],B=TH({value:n,level:a,minVersion:y,includeMargin:g,marginSize:S,imageSettings:w,size:o,boostLevel:$}),V=B.margin,U=B.cells,G=B.numCells,H=B.calculatedImageSettings;q.useEffect(function(){if(R.current){var W=R.current,Y=W.getContext("2d");if(!Y)return;var Q=U,D=I.current,L=H!=null&&D!==null&&D.complete&&D.naturalHeight!==0&&D.naturalWidth!==0;L&&H.excavation!=null&&(Q=RH(U,H.excavation));var K=window.devicePixelRatio||1;W.height=W.width=o*K;var J=o/G*K;Y.scale(J,J),Y.fillStyle=u,Y.fillRect(0,0,G,G),Y.fillStyle=m,Mpe?Y.fill(new Path2D(MH(Q,V))):U.forEach(function(ee,te){ee.forEach(function(re,ie){re&&Y.fillRect(ie+V,te+V,1,1);});}),H&&(Y.globalAlpha=H.opacity),L&&Y.drawImage(D,H.x+V,H.y+V,H.w,H.h);}}),q.useEffect(function(){_(false);},[T]);var z=nr({height:o,width:o},C),j=null;return T!=null&&(j=q.createElement("img",{alt:"QR-Code",src:T,key:T,style:{display:"none"},onLoad:function(){_(true);},ref:I,crossOrigin:H?.crossOrigin})),q.createElement(q.Fragment,null,q.createElement("canvas",cr({style:z,height:o,width:o,ref:N,role:"img"},M)),j)}),Ape=["value","size","level","bgColor","fgColor","includeMargin","minVersion","title","marginSize","imageSettings","boostLevel"],Npe=q.forwardRef(function(e,t){var n=e.value,r=e.size,o=r===void 0?SH:r,i=e.level,a=i===void 0?CH:i,l=e.bgColor,u=l===void 0?xH:l,d=e.fgColor,m=d===void 0?wH:d,p=e.includeMargin,g=p===void 0?$H:p,b=e.minVersion,y=b===void 0?EH:b,S=e.title,C=e.marginSize,w=e.imageSettings,$=e.boostLevel,M=O7(e,Ape),T=TH({value:n,level:a,minVersion:y,includeMargin:g,marginSize:C,imageSettings:w,size:o,boostLevel:$}),R=T.margin,I=T.cells,N=T.numCells,P=T.calculatedImageSettings,O=I,_=null;w!=null&&P!=null&&(P.excavation!=null&&(O=RH(I,P.excavation)),_=q.createElement("image",{href:w.src,height:P.h,width:P.w,x:P.x+R,y:P.y+R,preserveAspectRatio:"none",opacity:P.opacity,crossOrigin:P.crossOrigin}));var B=MH(O,R);return q.createElement("svg",cr({height:o,width:o,viewBox:"0 0 ".concat(N," ").concat(N),ref:t,role:"img"},M),!!S&&q.createElement("title",null,S),q.createElement("path",{fill:u,d:"M0,0 h".concat(N,"v").concat(N,"H0z"),shapeRendering:"crispEdges"}),q.createElement("path",{fill:m,d:B,shapeRendering:"crispEdges"}),_)}),Ppe={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.1 209.3l-56.4 44.1C775.8 155.1 656.2 92 521.9 92 290 92 102.3 279.5 102 511.5 101.7 743.7 289.8 932 521.9 932c181.3 0 335.8-115 394.6-276.1 1.5-4.2-.7-8.9-4.9-10.3l-56.7-19.5a8 8 0 00-10.1 4.8c-1.8 5-3.8 10-5.9 14.9-17.3 41-42.1 77.8-73.7 109.4A344.77 344.77 0 01655.9 829c-42.3 17.9-87.4 27-133.8 27-46.5 0-91.5-9.1-133.8-27A341.5 341.5 0 01279 755.2a342.16 342.16 0 01-73.7-109.4c-17.9-42.4-27-87.4-27-133.9s9.1-91.5 27-133.9c17.3-41 42.1-77.8 73.7-109.4 31.6-31.6 68.4-56.4 109.3-73.8 42.3-17.9 87.4-27 133.8-27 46.5 0 91.5 9.1 133.8 27a341.5 341.5 0 01109.3 73.8c9.9 9.9 19.2 20.4 27.8 31.4l-60.2 47a8 8 0 003 14.1l175.6 43c5 1.2 9.9-2.6 9.9-7.7l.8-180.9c-.1-6.6-7.8-10.3-13-6.2z"}}]},name:"reload",theme:"outlined"};function n3(){return n3=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},n3.apply(this,arguments)}const Ipe=(e,t)=>f.createElement(Xn,n3({},e,{ref:t,icon:Ppe})),Ope=f.forwardRef(Ipe),Dpe=q.createElement(b1,null);function _pe({prefixCls:e,locale:t,onRefresh:n,statusRender:r,status:o}){const i=q.createElement(q.Fragment,null,q.createElement("p",{className:`${e}-expired`},t?.expired),n&&q.createElement(st,{type:"link",icon:q.createElement(Ope,null),onClick:n},t?.refresh)),a=q.createElement("p",{className:`${e}-scanned`},t?.scanned),l={expired:i,loading:Dpe,scanned:a};return (r??(m=>l[m.status]))({status:o,locale:t,onRefresh:n})}const Bpe=e=>{const{componentCls:t,lineWidth:n,lineType:r,colorSplit:o}=e;return {[t]:{...dn(e),display:"flex",justifyContent:"center",alignItems:"center",padding:e.paddingSM,backgroundColor:e.colorWhite,borderRadius:e.borderRadiusLG,border:`${oe(n)} ${r} ${o}`,position:"relative",overflow:"hidden",[`& > ${t}-cover`]:{position:"absolute",insetBlockStart:0,insetInlineStart:0,zIndex:10,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",width:"100%",height:"100%",color:e.colorText,lineHeight:e.lineHeight,background:e.QRCodeCoverBackgroundColor,textAlign:"center",[`& > ${t}-expired, & > ${t}-scanned`]:{color:e.QRCodeTextColor}},"> canvas":{alignSelf:"stretch",flex:"auto",minWidth:0},"&-icon":{marginBlockEnd:e.marginXS,fontSize:e.controlHeight}},[`${t}-borderless`]:{borderColor:"transparent",padding:0,borderRadius:0}}},Lpe=e=>({QRCodeCoverBackgroundColor:new cn(e.colorBgContainer).setA(.96).toRgbString()}),zpe=Wt("QRCode",e=>{const t=Ft(e,{QRCodeTextColor:e.colorText});return Bpe(t)},Lpe),kpe=e=>{const[,t]=jr(),{value:n,type:r="canvas",icon:o="",size:i=160,iconSize:a,color:l=t.colorText,errorLevel:u="M",status:d="active",bordered:m=true,onRefresh:p,style:g,className:b,rootClassName:y,prefixCls:S,bgColor:C="transparent",marginSize:w,statusRender:$,classNames:M,styles:T,boostLevel:R,...I}=e,{getPrefixCls:N,className:P,style:O,classNames:_,styles:B}=jt("qrcode"),V={...e,bgColor:C,type:r,size:i,status:d,bordered:m,errorLevel:u},[U,G]=Kt([_,M],[B,T],{props:V}),H=N("qrcode",S),[z,j]=zpe(H),W={src:o,x:void 0,y:void 0,height:typeof a=="number"?a:a?.height??40,width:typeof a=="number"?a:a?.width??40,excavate:true,crossOrigin:"anonymous"},Y=yo(I,true),Q=Ln(I,Object.keys(Y)),D={value:n,size:i,level:u,bgColor:C,fgColor:l,style:{width:g?.width,height:g?.height},imageSettings:o?W:void 0,marginSize:w,boostLevel:R,...Y},[L]=Oo("QRCode");if(!n)return null;const K=X(H,b,y,z,j,P,U.root,{[`${H}-borderless`]:!m}),J={backgroundColor:C,...G.root,...O,...g,width:g?.width??i,height:g?.height??i};return q.createElement("div",{...Q,className:K,style:J},d!=="active"&&q.createElement("div",{className:X(`${H}-cover`,U.cover),style:G.cover},q.createElement(_pe,{prefixCls:H,locale:L,status:d,onRefresh:p,statusRender:$})),r==="canvas"?q.createElement(Tpe,{...D}):q.createElement(Npe,{...D}))};function r3(){return r3=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},r3.apply(this,arguments)}const AH=f.forwardRef(({prefixCls:e="rc-switch",className:t,checked:n,defaultChecked:r,disabled:o,loadingIcon:i,checkedChildren:a,unCheckedChildren:l,onClick:u,onChange:d,onKeyDown:m,styles:p,classNames:g,...b},y)=>{const[S,C]=un(r??false,n);function w(R,I){let N=S;return o||(N=R,C(N),d?.(N,I)),N}function $(R){R.which===it.LEFT?w(false,R):R.which===it.RIGHT&&w(true,R),m?.(R);}function M(R){const I=w(!S,R);u?.(I,R);}const T=X(e,t,{[`${e}-checked`]:S,[`${e}-disabled`]:o});return f.createElement("button",r3({},b,{type:"button",role:"switch","aria-checked":S,disabled:o,className:T,ref:y,onKeyDown:$,onClick:M}),i,f.createElement("span",{className:`${e}-inner`},f.createElement("span",{className:X(`${e}-inner-checked`,g?.content),style:p?.content},a),f.createElement("span",{className:X(`${e}-inner-unchecked`,g?.content),style:p?.content},l)))});AH.displayName="Switch";const Fpe=e=>{const{componentCls:t,trackHeightSM:n,trackPadding:r,trackMinWidthSM:o,innerMinMarginSM:i,innerMaxMarginSM:a,handleSizeSM:l,calc:u}=e,d=`${t}-inner`,m=oe(u(l).add(u(r).mul(2)).equal()),p=oe(u(a).mul(2).equal());return {[t]:{[`&${t}-small`]:{minWidth:o,height:n,lineHeight:oe(n),[`${t}-inner`]:{paddingInlineStart:a,paddingInlineEnd:i,[`${d}-checked, ${d}-unchecked`]:{minHeight:n},[`${d}-checked`]:{marginInlineStart:`calc(-100% + ${m} - ${p})`,marginInlineEnd:`calc(100% - ${m} + ${p})`},[`${d}-unchecked`]:{marginTop:u(n).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`${t}-handle`]:{width:l,height:l},[`${t}-loading-icon`]:{top:u(u(l).sub(e.switchLoadingIconSize)).div(2).equal(),fontSize:e.switchLoadingIconSize},[`&${t}-checked`]:{[`${t}-inner`]:{paddingInlineStart:i,paddingInlineEnd:a,[`${d}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${d}-unchecked`]:{marginInlineStart:`calc(100% - ${m} + ${p})`,marginInlineEnd:`calc(-100% + ${m} - ${p})`}},[`${t}-handle`]:{insetInlineStart:`calc(100% - ${oe(u(l).add(r).equal())})`}},[`&:not(${t}-disabled):active`]:{[`&:not(${t}-checked) ${d}`]:{[`${d}-unchecked`]:{marginInlineStart:u(e.marginXXS).div(2).equal(),marginInlineEnd:u(e.marginXXS).mul(-1).div(2).equal()}},[`&${t}-checked ${d}`]:{[`${d}-checked`]:{marginInlineStart:u(e.marginXXS).mul(-1).div(2).equal(),marginInlineEnd:u(e.marginXXS).div(2).equal()}}}}}}},Hpe=e=>{const{componentCls:t,handleSize:n,calc:r}=e;return {[t]:{[`${t}-loading-icon${e.iconCls}`]:{position:"relative",top:r(r(n).sub(e.fontSize)).div(2).equal(),color:e.switchLoadingIconColor,verticalAlign:"top"},[`&${t}-checked ${t}-loading-icon`]:{color:e.switchColor}}}},Vpe=e=>{const{componentCls:t,trackPadding:n,handleBg:r,handleShadow:o,handleSize:i,calc:a}=e,l=`${t}-handle`;return {[t]:{[l]:{position:"absolute",top:n,insetInlineStart:n,width:i,height:i,transition:`all ${e.switchDuration} ease-in-out`,"&::before":{position:"absolute",top:0,insetInlineEnd:0,bottom:0,insetInlineStart:0,backgroundColor:r,borderRadius:a(i).div(2).equal(),boxShadow:o,transition:`all ${e.switchDuration} ease-in-out`,content:'""'}},[`&${t}-checked ${l}`]:{insetInlineStart:`calc(100% - ${oe(a(i).add(n).equal())})`},[`&:not(${t}-disabled):active`]:{[`${l}::before`]:{insetInlineEnd:e.switchHandleActiveInset,insetInlineStart:0},[`&${t}-checked ${l}::before`]:{insetInlineEnd:0,insetInlineStart:e.switchHandleActiveInset}}}}},jpe=e=>{const{componentCls:t,trackHeight:n,trackPadding:r,innerMinMargin:o,innerMaxMargin:i,handleSize:a,switchDuration:l,calc:u}=e,d=`${t}-inner`,m=oe(u(a).add(u(r).mul(2)).equal()),p=oe(u(i).mul(2).equal());return {[t]:{[d]:{display:"block",overflow:"hidden",borderRadius:100,height:"100%",paddingInlineStart:i,paddingInlineEnd:o,transition:["padding-inline-start","padding-inline-end"].map(g=>`${g} ${l} ease-in-out`).join(", "),[`${d}-checked, ${d}-unchecked`]:{display:"block",color:e.colorTextLightSolid,fontSize:e.fontSizeSM,pointerEvents:"none",minHeight:n,transition:["margin-inline-start","margin-inline-end"].map(g=>`${g} ${l} ease-in-out`).join(", ")},[`${d}-checked`]:{marginInlineStart:`calc(-100% + ${m} - ${p})`,marginInlineEnd:`calc(100% - ${m} + ${p})`},[`${d}-unchecked`]:{marginTop:u(n).mul(-1).equal(),marginInlineStart:0,marginInlineEnd:0}},[`&${t}-checked ${d}`]:{paddingInlineStart:o,paddingInlineEnd:i,[`${d}-checked`]:{marginInlineStart:0,marginInlineEnd:0},[`${d}-unchecked`]:{marginInlineStart:`calc(100% - ${m} + ${p})`,marginInlineEnd:`calc(-100% + ${m} - ${p})`}},[`&:not(${t}-disabled):active`]:{[`&:not(${t}-checked) ${d}`]:{[`${d}-unchecked`]:{marginInlineStart:u(r).mul(2).equal(),marginInlineEnd:u(r).mul(-1).mul(2).equal()}},[`&${t}-checked ${d}`]:{[`${d}-checked`]:{marginInlineStart:u(r).mul(-1).mul(2).equal(),marginInlineEnd:u(r).mul(2).equal()}}}}}},Upe=e=>{const{componentCls:t,trackHeight:n,trackMinWidth:r}=e;return {[t]:{...dn(e),position:"relative",display:"inline-block",boxSizing:"border-box",minWidth:r,height:n,lineHeight:oe(n),verticalAlign:"middle",background:e.colorTextQuaternary,border:"0",borderRadius:100,cursor:"pointer",transition:`all ${e.motionDurationMid}`,userSelect:"none",[`&:hover:not(${t}-disabled)`]:{background:e.colorTextTertiary},...$i(e),[`&${t}-checked`]:{background:e.switchColor,[`&:hover:not(${t}-disabled)`]:{background:e.colorPrimaryHover}},[`&${t}-loading, &${t}-disabled`]:{cursor:"not-allowed",opacity:e.switchDisabledOpacity,"*":{boxShadow:"none",cursor:"not-allowed"}},[`&${t}-rtl`]:{direction:"rtl"}}}},Wpe=e=>{const{fontSize:t,lineHeight:n,controlHeight:r,colorWhite:o}=e,i=t*n,a=r/2,l=2,u=i-l*2,d=a-l*2;return {trackHeight:i,trackHeightSM:a,trackMinWidth:u*2+l*4,trackMinWidthSM:d*2+l*2,trackPadding:l,handleBg:o,handleSize:u,handleSizeSM:d,handleShadow:`0 2px 4px 0 ${new cn("#00230b").setA(.2).toRgbString()}`,innerMinMargin:u/2,innerMaxMargin:u+l+l*2,innerMinMarginSM:d/2,innerMaxMarginSM:d+l+l*2}},Gpe=Wt("Switch",e=>{const t=Ft(e,{switchDuration:e.motionDurationMid,switchColor:e.colorPrimary,switchDisabledOpacity:e.opacityLoading,switchLoadingIconSize:e.calc(e.fontSizeIcon).mul(.75).equal(),switchLoadingIconColor:`rgba(0, 0, 0, ${e.opacityLoading})`,switchHandleActiveInset:"-30%"});return [Upe(t),jpe(t),Vpe(t),Hpe(t),Fpe(t)]},Wpe),qpe=f.forwardRef((e,t)=>{const{prefixCls:n,size:r,disabled:o,loading:i,className:a,rootClassName:l,style:u,checked:d,value:m,defaultChecked:p,defaultValue:g,onChange:b,styles:y,classNames:S,...C}=e,[w,$]=un(p??g??false,d??m),{getPrefixCls:M,direction:T,className:R,style:I,classNames:N,styles:P}=jt("switch"),O=f.useContext(no),_=(o??O)||i,B=M("switch",n),[V,U]=Gpe(B),G=so(r),H={...e,size:G,disabled:_},[z,j]=Kt([N,S],[P,y],{props:H}),W=f.createElement("div",{className:X(`${B}-handle`,z.indicator),style:j.indicator},i&&f.createElement(e1,{className:`${B}-loading-icon`})),Y=X(R,{[`${B}-small`]:G==="small",[`${B}-loading`]:i,[`${B}-rtl`]:T==="rtl"},a,l,z.root,V,U),Q={...j.root,...I,...u},D=(...L)=>{$(L[0]),b?.(...L);};return f.createElement(Qp,{component:"Switch",disabled:_},f.createElement(AH,{...C,classNames:z,styles:j,checked:w,onChange:D,prefixCls:B,className:Y,style:Q,disabled:_,ref:t,loadingIcon:W}))}),NH=qpe;NH.__ANT_SWITCH=true;const Kpe=e=>{const{paddingXXS:t,lineWidth:n,tagPaddingHorizontal:r,componentCls:o,calc:i}=e,a=i(r).sub(n).equal(),l=i(t).sub(n).equal();return {[o]:{...dn(e),display:"inline-block",height:"auto",paddingInline:a,fontSize:e.tagFontSize,lineHeight:e.tagLineHeight,whiteSpace:"nowrap",backgroundColor:e.defaultBg,border:`${oe(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,borderRadius:e.borderRadiusSM,opacity:1,transition:`all ${e.motionDurationMid}`,textAlign:"start",position:"relative",[`&${o}-rtl`]:{direction:"rtl"},"&, a, a:hover":{color:e.defaultColor},[`${o}-close-icon`]:{marginInlineStart:l,fontSize:e.tagIconSize,color:e.colorIcon,cursor:"pointer",transition:`all ${e.motionDurationMid}`,"&:hover":{color:e.colorTextHeading}},"&-checkable":{backgroundColor:"transparent",borderColor:"transparent",cursor:"pointer",[`&:not(${o}-checkable-checked):hover`]:{color:e.colorPrimary,backgroundColor:e.colorFillSecondary},"&:active, &-checked":{color:e.colorTextLightSolid},"&-checked":{backgroundColor:e.colorPrimary,"&:hover":{backgroundColor:e.colorPrimaryHover}},"&:active":{backgroundColor:e.colorPrimaryActive},"&-disabled":{cursor:"not-allowed",[`&:not(${o}-checkable-checked)`]:{color:e.colorTextDisabled,"&:hover":{backgroundColor:"transparent"}},[`&${o}-checkable-checked`]:{color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled},"&:hover, &:active":{backgroundColor:e.colorBgContainerDisabled,color:e.colorTextDisabled},[`&:not(${o}-checkable-checked):hover`]:{color:e.colorTextDisabled}},"&-group":{display:"flex",flexWrap:"wrap",gap:e.paddingXS}},"&-hidden":{display:"none"},[`> ${e.iconCls} + span, > span + ${e.iconCls}`]:{marginInlineStart:a}},[`&${e.componentCls}-solid`]:{borderColor:"transparent",color:e.colorTextLightSolid,backgroundColor:e.colorBgSolid,[`&${o}-default`]:{color:e.solidTextColor}},[`${o}-filled`]:{borderColor:"transparent",backgroundColor:e.tagBorderlessBg},[`&${o}-disabled`]:{color:e.colorTextDisabled,cursor:"not-allowed",backgroundColor:e.colorBgContainerDisabled,a:{cursor:"not-allowed",pointerEvents:"none",color:e.colorTextDisabled,"&:hover":{color:e.colorTextDisabled}},"a&":{"&:hover, &:active":{color:e.colorTextDisabled}},[`&${o}-outlined`]:{borderColor:e.colorBorderDisabled},[`&${o}-solid, &${o}-filled`]:{color:e.colorTextDisabled,[`${o}-close-icon`]:{color:e.colorTextDisabled}},[`${o}-close-icon`]:{cursor:"not-allowed",color:e.colorTextDisabled,"&:hover":{color:e.colorTextDisabled}}}}},iT=e=>{const{lineWidth:t,fontSizeIcon:n,calc:r}=e,o=e.fontSizeSM;return Ft(e,{tagFontSize:o,tagLineHeight:oe(r(e.lineHeightSM).mul(o).equal()),tagIconSize:r(n).sub(r(t).mul(2)).equal(),tagPaddingHorizontal:8,tagBorderlessBg:e.defaultBg})},aT=e=>{const t=bR(new Go(e.colorBgSolid),"#fff")?"#000":"#fff";return {defaultBg:new cn(e.colorFillTertiary).onBackground(e.colorBgContainer).toHexString(),defaultColor:e.colorText,solidTextColor:t}},sT=Wt("Tag",e=>{const t=iT(e);return Kpe(t)},aT),PH=f.forwardRef((e,t)=>{const{prefixCls:n,style:r,className:o,checked:i,children:a,icon:l,onChange:u,onClick:d,disabled:m,...p}=e,{getPrefixCls:g,tag:b}=f.useContext(wt),y=f.useContext(no),S=m??y,C=R=>{S||(u?.(!i),d?.(R));},w=g("tag",n),[$,M]=sT(w),T=X(w,`${w}-checkable`,{[`${w}-checkable-checked`]:i,[`${w}-checkable-disabled`]:S},b?.className,o,$,M);return f.createElement("span",{...p,ref:t,style:{...r,...b?.style},className:T,onClick:C},l,f.createElement("span",null,a))});function Ype(e,t){const{id:n,prefixCls:r,rootClassName:o,className:i,style:a,classNames:l,styles:u,disabled:d,options:m,value:p,defaultValue:g,onChange:b,multiple:y,...S}=e,{getPrefixCls:C,direction:w,className:$,style:M,classNames:T,styles:R}=jt("tag"),I=C("tag",r),N=`${I}-checkable-group`,P=Qn(I),[O,_]=sT(I,P),[B,V]=Kt([T,l],[R,u],{props:e}),U=f.useMemo(()=>(m||[]).map(Y=>Y&&typeof Y=="object"?Y:{value:Y,label:Y}),[m]),[G,H]=un(g,p),z=(Y,Q)=>{let D=null;if(y){const L=G||[];D=Y?[].concat(qt(L),[Q.value]):L.filter(K=>K!==Q.value);}else D=Y?Q.value:null;H(D),b?.(D);},j=q.useRef(null);f.useImperativeHandle(t,()=>({nativeElement:j.current}));const W=yo(S,{aria:true,data:true});return q.createElement("div",{...W,className:X(N,$,o,{[`${N}-disabled`]:d,[`${N}-rtl`]:w==="rtl"},O,_,i,B.root),style:{...M,...V.root,...a},id:n,ref:j},U.map(Y=>q.createElement(PH,{key:Y.value,className:X(`${N}-item`,B.item),style:V.item,checked:y?(G||[]).includes(Y.value):G===Y.value,onChange:Q=>z(Q,Y),disabled:d},Y.label)))}const Xpe=q.forwardRef(Ype);function Qpe(e,t){const{color:n,variant:r,bordered:o}=e;return f.useMemo(()=>{const i=n?.endsWith("-inverse");let a;r?a=r:i?a="solid":o===false?a="filled":a=t||"filled";const l=i?n?.replace("-inverse",""):n,u=c1(n),d=sce(n),m={};if(!u&&!d&&l)if(a==="solid")m.backgroundColor=n;else {const p=new cn(l).toHsl();p.l=.95,m.backgroundColor=new cn(p).toHexString(),m.color=n,a==="outlined"&&(m.borderColor=n);}return [a,l,u,d,m]},[n,r,o,t])}const Zpe=e=>Yy(e,(t,{textColor:n,lightBorderColor:r,lightColor:o,darkColor:i})=>({[`${e.componentCls}${e.componentCls}-${t}:not(${e.componentCls}-disabled)`]:{[`&${e.componentCls}-outlined`]:{backgroundColor:o,borderColor:r,color:n},[`&${e.componentCls}-solid`]:{backgroundColor:i,borderColor:i,color:e.colorTextLightSolid},[`&${e.componentCls}-filled`]:{backgroundColor:o,color:n}}})),Jpe=Nf(["Tag","preset"],e=>{const t=iT(e);return Zpe(t)},aT);function ege(e){return typeof e!="string"?e:e.charAt(0).toUpperCase()+e.slice(1)}const fb=(e,t,n)=>{const r=ege(n);return {[`${e.componentCls}${e.componentCls}-${t}:not(${e.componentCls}-disabled)`]:{[`&${e.componentCls}-outlined`]:{backgroundColor:e[`color${r}Bg`],borderColor:e[`color${r}Border`],color:e[`color${n}`]},[`&${e.componentCls}-solid`]:{backgroundColor:e[`color${n}`],borderColor:e[`color${n}`]},[`&${e.componentCls}-filled`]:{backgroundColor:e[`color${r}Bg`],color:e[`color${n}`]}}}},tge=Nf(["Tag","status"],e=>{const t=iT(e);return [fb(t,"success","Success"),fb(t,"processing","Info"),fb(t,"error","Error"),fb(t,"warning","Warning")]},aT),nge=f.forwardRef((e,t)=>{const{prefixCls:n,className:r,rootClassName:o,style:i,children:a,icon:l,color:u,variant:d,onClose:m,bordered:p,disabled:g,href:b,target:y,styles:S,classNames:C,...w}=e,{getPrefixCls:$,direction:M,className:T,variant:R,style:I,classNames:N,styles:P}=jt("tag"),[O,_,B,V,U]=Qpe(e,R),G=B||V,H=f.useContext(no),z=g??H,{tag:j}=f.useContext(wt),[W,Y]=f.useState(true),Q=Ln(w,["closeIcon","closable"]),D={...e,color:_,variant:O,disabled:z,href:b,target:y,icon:l},[L,K]=Kt([N,C],[P,S],{props:D}),J=f.useMemo(()=>{let pe={...K.root,...I,...i};return z||(pe={...U,...pe}),pe},[K.root,I,i,U,z]),ee=$("tag",n),[te,re]=sT(ee),ie=X(ee,T,L.root,`${ee}-${O}`,{[`${ee}-${_}`]:G,[`${ee}-hidden`]:!W,[`${ee}-rtl`]:M==="rtl",[`${ee}-disabled`]:z},r,o,te,re),de=pe=>{z||(pe.stopPropagation(),m?.(pe),!pe.defaultPrevented&&Y(false));},[,ne]=tR(kl(e),kl(j),{closable:false,closeIconRender:pe=>{const Ce=f.createElement("span",{className:`${ee}-close-icon`,onClick:de},pe);return dk(pe,Ce,xe=>({onClick:Ae=>{xe?.onClick?.(Ae),de(Ae);},className:X(xe?.className,`${ee}-close-icon`)}))}}),ce=typeof w.onClick=="function"||a&&a.type==="a",fe=Hr(l,{className:X(f.isValidElement(l)?l.props?.className:"",L.icon),style:K.icon}),se=fe?f.createElement(f.Fragment,null,fe,a&&f.createElement("span",{className:L.content,style:K.content},a)):a,Me=b?"a":"span",ae=f.createElement(Me,{...Q,ref:t,className:ie,style:J,href:z?void 0:b,target:y,onClick:z?void 0:Q.onClick,...b&&z?{"aria-disabled":true}:{}},se,ne,B&&f.createElement(Jpe,{key:"preset",prefixCls:ee}),V&&f.createElement(tge,{key:"status",prefixCls:ee}));return ce?f.createElement(Qp,{component:"Tag"},ae):ae}),vo=nge;vo.CheckableTag=PH;vo.CheckableTagGroup=Xpe;const rge=e=>{const t=e?.algorithm?A0(e.algorithm):KM,n={...sf,...e?.token};return az(n,{override:e?.token},t,Tz)};function oge(e){const{sizeUnit:t,sizeStep:n}=e,r=n-2;return {sizeXXL:t*(r+10),sizeXL:t*(r+6),sizeLG:t*(r+2),sizeMD:t*(r+2),sizeMS:t*(r+1),size:t*r,sizeSM:t*r,sizeXS:t*(r-1),sizeXXS:t*(r-1)}}const ige=(e,t)=>{const n=t??Ky(e),r=n.fontSizeSM,o=n.controlHeight-4;return {...n,...oge(t??e),...Rz(r),controlHeight:o,...Mz({...n,controlHeight:o})}},zi=(e,t)=>new cn(e).setA(t).toRgbString(),Tc=(e,t)=>new cn(e).lighten(t).toHexString(),j8=e=>{const t=qp(e,{theme:"dark"});return {1:t[0],2:t[1],3:t[2],4:t[3],5:t[6],6:t[5],7:t[4],8:t[6],9:t[5],10:t[4]}},age=(e,t)=>{const n=e||"#000",r=t||"#fff";return {colorBgBase:n,colorTextBase:r,colorText:zi(r,.85),colorTextSecondary:zi(r,.65),colorTextTertiary:zi(r,.45),colorTextQuaternary:zi(r,.25),colorFill:zi(r,.18),colorFillSecondary:zi(r,.12),colorFillTertiary:zi(r,.08),colorFillQuaternary:zi(r,.04),colorBgSolid:zi(r,.95),colorBgSolidHover:zi(r,1),colorBgSolidActive:zi(r,.9),colorBgElevated:Tc(n,12),colorBgContainer:Tc(n,8),colorBgLayout:Tc(n,0),colorBgSpotlight:Tc(n,26),colorBgBlur:zi(r,.04),colorBorder:Tc(n,26),colorBorderDisabled:Tc(n,26),colorBorderSecondary:Tc(n,19)}},sge=(e,t)=>{const n=Object.keys(qM).map(a=>{const l=qp(e[a],{theme:"dark"});return Array.from({length:10},()=>1).reduce((u,d,m)=>(u[`${a}-${m+1}`]=l[m],u[`${a}${m+1}`]=l[m],u),{})}).reduce((a,l)=>(a={...a,...l},a),{}),r=t??Ky(e),o=Ez(e,{generateColorPalettes:j8,generateNeutralColorPalettes:age}),i=Wa.reduce((a,l)=>{const u=e[l];if(u){const d=j8(u);a[`${l}Hover`]=d[7],a[`${l}Active`]=d[5];}return a},{});return {...r,...n,...o,...i,colorPrimaryBg:o.colorPrimaryBorder,colorPrimaryBgHover:o.colorPrimaryBorderHover}};function lge(){const[e,t,n,r]=jr();return {theme:e,token:t,hashId:n,cssVar:r}}const iy={defaultSeed:cp.token,useToken:lge,defaultAlgorithm:Ky,darkAlgorithm:sge,compactAlgorithm:ige,getDesignToken:rge,defaultConfig:cp,_internalContext:YM},ay=e=>{const t=new Map;return e.forEach((n,r)=>{t.set(n,r);}),t},cge=e=>{const t=new Map;return e.forEach(({disabled:n,key:r},o)=>{n&&t.set(r,o);}),t};function uge(e,t){const n=e==="right";return t!=="rtl"?n?q.createElement(cf,null):q.createElement(fp,null):n?q.createElement(fp,null):q.createElement(cf,null)}const U8=({type:e,actions:t,moveToLeft:n,moveToRight:r,leftActive:o,rightActive:i,direction:a,disabled:l})=>{const u=e==="right",d=u?t[0]:t[1],m=u?r:n,p=u?i:o,g=uge(e,a);if(q.isValidElement(d)){const b=d,y=S=>{b?.props?.onClick?.(S),m?.(S);};return q.cloneElement(b,{disabled:l||!p,onClick:y})}return q.createElement(st,{type:"primary",size:"small",disabled:l||!p,onClick:b=>m?.(b),icon:g},d)},IH=e=>{const{className:t,style:n,oneWay:r,actions:o,...i}=e;return q.createElement("div",{className:t,style:n},q.createElement(U8,{type:"right",actions:o,...i}),!r&&q.createElement(U8,{type:"left",actions:o,...i}),o.slice(r?1:2))},dge=(e,t,n)=>{const r=f.useMemo(()=>(e||[]).map(a=>t?{...a,key:t(a)}:a),[e,t]),[o,i]=f.useMemo(()=>{const a=[],l=Array.from({length:n?.length??0}),u=ay(n||[]);return r.forEach(d=>{if(u.has(d.key)){const m=u.get(d.key);l[m]=d;}else a.push(d);}),[a,l]},[r,n]);return [r,o.filter(Boolean),i.filter(Boolean)]},fge=[];function mb(e,t){const n=e.filter(r=>t.has(r));return e.length===n.length?e:n}function W8(e){return Array.from(e).join(";")}function mge(e,t,n){const[r,o]=f.useMemo(()=>[new Set(e.map(p=>p?.key)),new Set(t.map(p=>p?.key))],[e,t]),[i,a]=un(fge,n),l=f.useMemo(()=>mb(i,r),[i,r]),u=f.useMemo(()=>mb(i,o),[i,o]);f.useEffect(()=>{a([].concat(qt(mb(i,r)),qt(mb(i,o))));},[W8(r),W8(o)]);const d=Mt(p=>{a([].concat(qt(p),qt(u)));}),m=Mt(p=>{a([].concat(qt(l),qt(p)));});return [l,u,d,m]}const OH=e=>{const{placeholder:t="",value:n,prefixCls:r,disabled:o,onChange:i,handleClear:a}=e,l=f.useCallback(u=>{i?.(u),u.target.value===""&&a?.();},[i]);return f.createElement(kf,{placeholder:t,className:r,value:n,onChange:l,disabled:o,allowClear:true,prefix:f.createElement(DR,null)})};var hge={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M360 184h-8c4.4 0 8-3.6 8-8v8h304v-8c0 4.4 3.6 8 8 8h-8v72h72v-80c0-35.3-28.7-64-64-64H352c-35.3 0-64 28.7-64 64v80h72v-72zm504 72H160c-17.7 0-32 14.3-32 32v32c0 4.4 3.6 8 8 8h60.4l24.7 523c1.6 34.1 29.8 61 63.9 61h454c34.2 0 62.3-26.8 63.9-61l24.7-523H888c4.4 0 8-3.6 8-8v-32c0-17.7-14.3-32-32-32zM731.3 840H292.7l-24.2-512h487l-24.2 512z"}}]},name:"delete",theme:"outlined"};function o3(){return o3=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);}return e},o3.apply(this,arguments)}const pge=(e,t)=>f.createElement(Xn,o3({},e,{ref:t,icon:hge})),gge=f.forwardRef(pge),vge=e=>{const{prefixCls:t,classNames:n,styles:r,renderedText:o,renderedEl:i,item:a,checked:l,disabled:u,onClick:d,onRemove:m,showRemove:p}=e,g=u||a?.disabled,b=X(`${t}-content-item`,n.item,{[`${t}-content-item-disabled`]:g,[`${t}-content-item-checked`]:l&&!g});let y;(typeof o=="string"||typeof o=="number")&&(y=String(o));const[S]=Oo("Transfer",ya.Transfer),C={className:b,style:r.item,title:y},w=f.createElement("span",{className:X(`${t}-content-item-text`,n.itemContent),style:r.itemContent},i);return p?f.createElement("li",{...C},w,f.createElement("button",{type:"button",disabled:g,className:`${t}-content-item-remove`,"aria-label":S?.remove,onClick:()=>m?.(a)},f.createElement(gge,null))):(C.onClick=g?void 0:$=>d(a,$),f.createElement("li",{...C},f.createElement(Ki,{className:X(`${t}-checkbox`,n.itemIcon),style:r.itemIcon,checked:l,disabled:g}),w))},bge=f.memo(vge),yge=["handleFilter","handleClear","checkedKeys"],Sge=e=>({...{simple:true,showSizeChanger:false,showLessItems:false},...e}),Cge=(e,t)=>{const{prefixCls:n,classNames:r,styles:o,filteredRenderItems:i,selectedKeys:a,disabled:l,showRemove:u,pagination:d,onScroll:m,onItemSelect:p,onItemRemove:g}=e,[b,y]=f.useState(1),S=f.useMemo(()=>d?Sge(typeof d=="object"?d:{}):null,[d]),[C,w]=un(10,S?.pageSize);f.useEffect(()=>{if(S){const P=Math.ceil(i.length/C);y(Math.min(b,P));}},[i,S,C]);const $=(P,O)=>{p(P.key,!a.includes(P.key),O);},M=P=>{g?.([P.key]);},T=P=>{y(P);},R=(P,O)=>{y(P),w(O);},I=f.useMemo(()=>S?i.slice((b-1)*C,b*C):i,[b,i,S,C]);f.useImperativeHandle(t,()=>({items:I}));const N=S?f.createElement(Fhe,{size:"small",disabled:l,simple:S.simple,pageSize:C,showLessItems:S.showLessItems,showSizeChanger:S.showSizeChanger,className:`${n}-pagination`,total:i.length,current:b,onChange:T,onShowSizeChange:R}):null;return f.createElement(f.Fragment,null,f.createElement("ul",{className:X(`${n}-content`,r.list,{[`${n}-content-show-remove`]:u}),style:o.list,onScroll:m},(I||[]).map(({renderedEl:P,renderedText:O,item:_})=>f.createElement(bge,{key:_.key,prefixCls:n,classNames:r,styles:o,item:_,renderedText:O,renderedEl:P,showRemove:u,onClick:$,onRemove:M,checked:a.includes(_.key),disabled:l}))),N)},xge=f.forwardRef(Cge),wge=()=>null;function $ge(e){return !!(e&&!q.isValidElement(e)&&Object.prototype.toString.call(e)==="[object Object]")}function th(e){return e.filter(t=>!t.disabled).map(t=>t.key)}const Ege=e=>e!==void 0,Mge=e=>e&&typeof e=="object"?{...e,defaultValue:e.defaultValue||""}:{defaultValue:"",placeholder:""},i3=e=>{const{prefixCls:t,style:n,classNames:r,styles:o,dataSource:i=[],titleText:a="",checkedKeys:l,disabled:u,showSearch:d=false,searchPlaceholder:m,notFoundContent:p,selectAll:g,deselectAll:b,selectCurrent:y,selectInvert:S,removeAll:C,removeCurrent:w,showSelectAll:$=true,showRemove:M,pagination:T,direction:R,itemsUnit:I,itemUnit:N,selectAllLabel:P,selectionsIcon:O,footer:_,renderList:B,onItemSelectAll:V,onItemRemove:U,handleFilter:G,handleClear:H,filterOption:z,render:j=wge}=e,W=`${t}-section`,Y=`${t}-list`,Q=Mge(d),[D,L]=f.useState(Q.defaultValue),K=f.useRef({}),J=ue=>{L(ue.target.value),G(ue);},ee=()=>{L(""),H();},te=(ue,ge)=>typeof z=="function"?z(D,ge,R):ue.includes(D),re=ue=>{let ge=B?B({...ue,onItemSelect:(je,qe)=>ue.onItemSelect(je,qe)}):null;const Pe=!!ge;return Pe||(ge=q.createElement(xge,{ref:K,...ue,prefixCls:Y})),{customize:Pe,bodyContent:ge}},ie=ue=>{const ge=j(ue),Pe=$ge(ge);return {item:ue,renderedEl:Pe?ge.label:ge,renderedText:Pe?ge.value:ge}},de=f.useMemo(()=>Array.isArray(p)?p[R==="left"?0:1]:p,[p,R]),[ne,ce]=f.useMemo(()=>{const ue=[],ge=[];return i.forEach(Pe=>{const je=ie(Pe);D&&!te(je.renderedText,Pe)||(ue.push(Pe),ge.push(je));}),[ue,ge]},[i,D]),fe=f.useMemo(()=>ne.filter(ue=>l.includes(ue.key)&&!ue.disabled),[l,ne]),se=f.useMemo(()=>{if(fe.length===0)return "none";const ue=ay(l);return ne.every(ge=>ue.has(ge.key)||!!ge.disabled)?"all":"part"},[fe.length,l,ne]),Me=()=>{const ue=d?q.createElement("div",{className:`${Y}-body-search-wrapper`},q.createElement(OH,{prefixCls:`${Y}-search`,onChange:J,handleClear:ee,placeholder:Q.placeholder||m,value:D,disabled:u})):null,{customize:ge,bodyContent:Pe}=re({...Ln(e,yge),filteredItems:ne,filteredRenderItems:ce,selectedKeys:l,classNames:r,styles:o});let je;return ge?je=q.createElement("div",{className:`${Y}-body-customize-wrapper`},Pe):je=ne.length?Pe:q.createElement("div",{className:`${Y}-body-not-found`},de),q.createElement("div",{className:X(`${Y}-body`,{[`${Y}-body-with-search`]:d},r.body),style:o.body},ue,je)},ae=q.createElement(Ki,{disabled:i.filter(ue=>!ue.disabled).length===0||u,checked:se==="all",indeterminate:se==="part",className:`${Y}-checkbox`,onChange:()=>{V?.(ne.filter(ue=>!ue.disabled).map(({key:ue})=>ue),se!=="all");}}),pe=(ue,ge)=>{if(P)return typeof P=="function"?P({selectedCount:ue,totalCount:ge}):P;const Pe=ge>1?I:N;return q.createElement(q.Fragment,null,(ue>0?`${ue}/`:"")+ge," ",Pe)},Ce=_&&(_.length<2?_(e):_(e,{direction:R})),xe=Ce?q.createElement("div",{className:X(`${Y}-footer`,r.footer),style:o.footer},Ce):null,Ae=!M&&!T&&ae;let Xe;M?Xe=[T?{key:"removeCurrent",label:w,onClick(){const ue=th((K.current?.items||[]).map(ge=>ge.item));U?.(ue);}}:null,{key:"removeAll",label:C,onClick(){U?.(th(ne));}}].filter(Boolean):Xe=[{key:"selectAll",label:se==="all"?b:g,onClick(){const ue=th(ne);V?.(ue,ue.length!==l.length);}},T?{key:"selectCurrent",label:y,onClick(){const ue=K.current?.items||[];V?.(th(ue.map(ge=>ge.item)),true);}}:null,{key:"selectInvert",label:S,onClick(){const ue=th((K.current?.items||[]).map(je=>je.item)),ge=new Set(l),Pe=new Set(ge);ue.forEach(je=>{ge.has(je)?Pe.delete(je):Pe.add(je);}),V?.(Array.from(Pe),"replace");}}];const Ne=q.createElement(tc,{className:`${Y}-header-dropdown`,menu:{items:Xe},disabled:u},Ege(O)?O:q.createElement(OR,null));return q.createElement("div",{className:X(W,r.section,{[`${W}-with-pagination`]:!!T,[`${W}-with-footer`]:!!Ce}),style:{...n,...o.section}},q.createElement("div",{className:X(`${Y}-header`,r.header),style:o.header},$?q.createElement(q.Fragment,null,Ae,Ne):null,q.createElement("span",{className:`${Y}-header-selected`},pe(fe.length,ne.length)),q.createElement("span",{className:X(`${Y}-header-title`,r.title),style:o.title},a)),Me(),xe)},Rge=e=>{const{antCls:t,componentCls:n,listHeight:r,controlHeightLG:o}=e,i=`${t}-table`,a=`${t}-input`;return {[`${n}-customize-list`]:{[`${n}-section`]:{flex:"1 1 50%",width:"auto",height:"auto",minHeight:r,minWidth:0},[`${i}-wrapper`]:{[`${i}-small`]:{border:0,borderRadius:0,[`${i}-selection-column`]:{width:o,minWidth:o}},[`${i}-pagination${i}-pagination`]:{margin:0,padding:e.paddingXS}},[`${a}[disabled]`]:{backgroundColor:"transparent"}}}},G8=(e,t)=>{const{componentCls:n,colorBorder:r}=e;return {[`${n}-section`]:{borderColor:t,[`${n}-list-search:not([disabled])`]:{borderColor:r}}}},Tge=e=>{const{componentCls:t}=e;return {[`${t}-status-error`]:{...G8(e,e.colorError)},[`${t}-status-warning`]:{...G8(e,e.colorWarning)}}},Age=e=>{const{componentCls:t,colorBorder:n,colorSplit:r,lineWidth:o,itemHeight:i,headerHeight:a,transferHeaderVerticalPadding:l,itemPaddingBlock:u,controlItemBgActive:d,colorTextDisabled:m,colorTextSecondary:p,listHeight:g,listWidth:b,listWidthLG:y,fontSizeIcon:S,marginXS:C,paddingSM:w,lineType:$,antCls:M,iconCls:T,motionDurationSlow:R,controlItemBgHover:I,borderRadiusLG:N,colorBgContainer:P,colorText:O,controlItemBgActiveHover:_}=e,B=oe(e.calc(N).sub(o).equal());return {display:"flex",flexDirection:"column",width:b,height:g,border:`${oe(o)} ${$} ${n}`,borderRadius:e.borderRadiusLG,"&-with-pagination":{width:y,height:"auto"},[`${t}-list`]:{"&-search":{[`${T}-search`]:{color:m}},"&-header":{display:"flex",flex:"none",alignItems:"center",height:a,padding:`${oe(e.calc(l).sub(o).equal())} ${oe(w)} ${oe(l)}`,color:O,background:P,borderBottom:`${oe(o)} ${$} ${r}`,borderRadius:`${oe(N)} ${oe(N)} 0 0`,"> *:not(:last-child)":{marginInlineEnd:4},"> *":{flex:"none"},"&-title":{...Ga,flex:"0 1 auto",textAlign:"end",marginInlineStart:"auto"},"&-dropdown":{...Cu(),fontSize:S,transform:"translateY(10%)",cursor:"pointer","&[disabled]":{cursor:"not-allowed"}}},"&-body":{display:"flex",flex:"auto",flexDirection:"column",fontSize:e.fontSize,minHeight:0,"&-search-wrapper":{position:"relative",flex:"none",padding:w}},"&-content":{flex:"auto",margin:0,padding:0,overflow:"auto",listStyle:"none",borderRadius:`0 0 ${B} ${B}`,"&-item":{display:"flex",alignItems:"center",minHeight:i,padding:`${oe(u)} ${oe(w)}`,transition:`all ${R}`,"> *:not(:last-child)":{marginInlineEnd:C},"> *":{flex:"none"},"&-text":{...Ga,flex:"auto"},"&-remove":{...Jee(e),color:n,"&:hover, &:focus":{color:p}},[`&:not(${t}-list-content-item-disabled)`]:{"&:hover":{backgroundColor:I,cursor:"pointer"},[`&${t}-list-content-item-checked:hover`]:{backgroundColor:_}},"&-checked":{backgroundColor:d},"&-disabled":{color:m,cursor:"not-allowed"}},[`&-show-remove ${t}-list-content-item:not(${t}-list-content-item-disabled):hover`]:{background:"transparent",cursor:"default"}},"&-pagination":{padding:e.paddingXS,textAlign:"end",borderTop:`${oe(o)} ${$} ${r}`,[`${M}-pagination-options`]:{paddingInlineEnd:e.paddingXS}},"&-body-not-found":{flex:"none",width:"100%",margin:"auto 0",color:m,textAlign:"center"},"&-footer":{borderTop:`${oe(o)} ${$} ${r}`},"&-checkbox":{lineHeight:1}}}},Nge=e=>{const{antCls:t,iconCls:n,componentCls:r,marginXS:o,marginXXS:i,fontSizeIcon:a,colorBgContainerDisabled:l}=e;return {[r]:{...dn(e),position:"relative",display:"flex",alignItems:"stretch",[`${r}-disabled`]:{[`${r}-section`]:{background:l}},[`${r}-section`]:Age(e),[`${r}-actions`]:{display:"flex",flex:"none",flexDirection:"column",alignSelf:"center",margin:`0 ${oe(o)}`,verticalAlign:"middle",gap:i,[`${t}-btn ${n}`]:{fontSize:a}}}}},Pge=e=>{const{componentCls:t}=e;return {[`${t}-rtl`]:{direction:"rtl"}}},Ige=e=>{const{fontSize:t,lineHeight:n,controlHeight:r,controlHeightLG:o,lineWidth:i}=e,a=Math.round(t*n);return {listWidth:180,listHeight:200,listWidthLG:250,headerHeight:o,itemHeight:r,itemPaddingBlock:(r-a)/2,transferHeaderVerticalPadding:Math.ceil((o-i-a)/2)}},Oge=Wt("Transfer",e=>{const t=Ft(e);return [Nge(t),Rge(t),Tge(t),Pge(t)]},Ige),S1=e=>{const{prefixCls:t,className:n,rootClassName:r,classNames:o,styles:i,style:a,listStyle:l,operationStyle:u,operations:d,actions:m,dataSource:p,targetKeys:g=[],selectedKeys:b,selectAllLabels:y=[],locale:S={},titles:C,disabled:w,showSearch:$=false,showSelectAll:M,oneWay:T,pagination:R,status:I,selectionsIcon:N,filterOption:P,render:O,footer:_,children:B,rowKey:V,onScroll:U,onChange:G,onSearch:H,onSelectChange:z}=e,{getPrefixCls:j,renderEmpty:W,direction:Y,className:Q,style:D,classNames:L,styles:K,selectionsIcon:J}=jt("transfer"),ee=f.useContext(no),te=w??ee,re={...e,disabled:te},ie=j("transfer",t),[de,ne]=Oge(ie),ce=m||d||[],[fe,se,Me]=dge(p,V,g),[ae,pe,Ce,xe]=mge(se,Me,b),[Ae,Xe]=$I(Re=>Re.key),[Ne,ue]=$I(Re=>Re.key),ge=f.useCallback((Re,ct)=>{if(Re==="left"){const tt=typeof ct=="function"?ct(ae||[]):ct;Ce(tt);}else {const tt=typeof ct=="function"?ct(pe||[]):ct;xe(tt);}},[ae,pe]),Pe=(Re,ct)=>{(Re==="left"?Xe:ue)(ct);},je=f.useCallback((Re,ct)=>{Re==="left"?z?.(ct,pe):z?.(ae,ct);},[ae,pe]),qe=Re=>C??Re.titles??[],Ue=Re=>{U?.("left",Re);},et=Re=>{U?.("right",Re);},rt=Re=>{const ct=Re==="right"?ae:pe,tt=cge(fe),yt=ct.filter(mn=>!tt.has(mn)),At=ay(yt),en=Re==="right"?yt.concat(g):g.filter(mn=>!At.has(mn)),Zt=Re==="right"?"left":"right";ge(Zt,[]),je(Zt,[]),G?.(en,Re,yt);},Ke=()=>{rt("left"),Pe("left",null);},_e=()=>{rt("right"),Pe("right",null);},We=(Re,ct,tt)=>{ge(Re,yt=>{let At=[];if(tt==="replace")At=ct;else if(tt)At=Array.from(new Set([].concat(qt(yt),qt(ct))));else {const en=ay(ct);At=yt.filter(Zt=>!en.has(Zt));}return je(Re,At),At}),Pe(Re,null);},Ze=(Re,ct)=>{We("left",Re,ct);},Be=(Re,ct)=>{We("right",Re,ct);},Oe=Re=>H?.("left",Re.target.value),lt=Re=>H?.("right",Re.target.value),It=()=>H?.("left",""),mt=()=>H?.("right",""),Bt=(Re,ct,tt,yt,At)=>{ct.has(tt)&&(ct.delete(tt),Pe(Re,null)),yt&&(ct.add(tt),Pe(Re,At));},xt=(Re,ct,tt,yt)=>{(Re==="left"?Ae:Ne)(yt,ct,tt);},Tt=(Re,ct,tt,yt)=>{const At=Re==="left",en=qt(At?ae:pe),Zt=new Set(en),mn=qt(At?se:Me).filter(vn=>!vn?.disabled),Un=mn.findIndex(vn=>vn.key===ct);yt&&en.length>0?xt(Re,mn,Zt,Un):Bt(Re,Zt,ct,tt,Un);const rr=Array.from(Zt);je(Re,rr),e.selectedKeys||ge(Re,rr);},ut=(Re,ct,tt)=>{Tt("left",Re,ct,tt?.shiftKey);},dt=(Re,ct,tt)=>{Tt("right",Re,ct,tt?.shiftKey);},gt=Re=>{ge("right",[]),G?.(g.filter(ct=>!Re.includes(ct)),"left",qt(Re));},Fe=Re=>typeof l=="function"?l({direction:Re}):l||{},Qe=f.useContext(So),{hasFeedback:ye,status:be}=Qe,Se=Re=>({...Re,notFoundContent:W?.("Transfer")||q.createElement(zF,{componentName:"Transfer"}),...S}),he=Df(be,I),De=!B&&R,$e=Me.filter(Re=>pe.includes(Re.key)&&!Re.disabled).length>0,ke=se.filter(Re=>ae.includes(Re.key)&&!Re.disabled).length>0,[Ge,ot]=Kt([L,o],[K,i],{props:re}),ht=X(ie,{[`${ie}-disabled`]:te,[`${ie}-customize-list`]:!!B,[`${ie}-rtl`]:Y==="rtl"},jl(ie,he,ye),Q,n,r,de,ne,Ge.root),[$t]=Oo("Transfer",ya.Transfer),Rt=Se($t),[Ot,Sn]=qe(Rt),Hn=N??J;return q.createElement("div",{className:ht,style:{...D,...ot.root,...a}},q.createElement(i3,{prefixCls:ie,style:Fe("left"),classNames:Ge,styles:ot,titleText:Ot,dataSource:se,filterOption:P,checkedKeys:ae,handleFilter:Oe,handleClear:It,onItemSelect:ut,onItemSelectAll:Ze,render:O,showSearch:$,renderList:B,footer:_,onScroll:Ue,disabled:te,direction:Y==="rtl"?"right":"left",showSelectAll:M,selectAllLabel:y[0],pagination:De,selectionsIcon:Hn,...Rt}),q.createElement(IH,{className:X(`${ie}-actions`,Ge.actions),rightActive:ke,moveToRight:_e,leftActive:$e,actions:ce,moveToLeft:Ke,style:{...u,...ot.actions},disabled:te,direction:Y,oneWay:T}),q.createElement(i3,{prefixCls:ie,style:Fe("right"),classNames:Ge,styles:ot,titleText:Sn,dataSource:Me,filterOption:P,checkedKeys:pe,handleFilter:lt,handleClear:mt,onItemSelect:dt,onItemSelectAll:Be,onItemRemove:gt,render:O,showSearch:$,renderList:B,footer:_,onScroll:et,disabled:te,direction:Y==="rtl"?"left":"right",showSelectAll:M,selectAllLabel:y[1],showRemove:T,pagination:De,selectionsIcon:Hn,...Rt}))};S1.List=i3;S1.Search=OH;S1.Operation=IH;const{proxyStateMap:Dge}=$M(),_ge=e=>Dge.has(e),a3=new Set;IQ("createHandler",e=>(...t)=>{const n=e(...t),r=n.get||((o,i,a)=>Reflect.get(o,i,a));return n.get=(o,i,a)=>{for(const l of a3)l(o,i,a);return r(o,i,a)},n});const cw=[],Bge=e=>{cw.length?cw[cw.length-1].add(e):e();};function Lge(e){const t=new Map,n=new Map,r=(u,d)=>Array.from(d).some(([m,p])=>{const g=u[m],b=n.get(g);if(b)return r(g,b);if(!Object.is(g,p[0]))return true;const y=d5(g),S=p[1];return typeof y=="number"&&typeof S=="number"?y!==S:false}),o=()=>{Array.from(n).some(([u,d])=>r(u,d))&&a();},i=()=>{for(const[u,d]of t)n.has(u)||(d(),t.delete(u));for(const u of n.keys())if(!t.has(u)){const d=Xa(u,()=>Bge(o),true);t.set(u,d);}},a=()=>{n.clear();const u=(d,m,p)=>{if(!_ge(p))return;let g=n.get(p);g||(g=new Map,n.set(p,g));const b=Reflect.get(d,m,p);g.set(m,[b,d5(b)]);};a3.add(u);try{e();}finally{a3.delete(u),i();}};return a(),()=>{for(const u of t.values())u();t.clear(),n.clear();}}function zge(e,t){const n=Lge(e);return ()=>{n();}}function ff(e,t,n){return e<t?t:e>n?n:e}function kge(e){return e.value}var lT=class DH{static fromConcurrency(t,n=""){if(!isFinite(t))throw new Error("concurrency must be finite");if(!(t>0))throw new Error("concurrency must be greater than 0");const r=new Array(t).fill(0).map((o,i)=>[n,`executors(${t})`,i].map(a=>a&&a.toString().trim()).filter(Boolean).join("."));return new DH(r)}executorRefs;idleState;constructor(t){if(!t.length)throw new Error("executors can not be empty");this.executorRefs=t.map(n=>({value:n})),this.idleState=new WeakMap,this.executorRefs.forEach(n=>this.idleState.set(n,true));}aborted=false;abort(){this.aborted=true,this.pendingResolves=[];}pendingResolves=[];replenish=t=>{this.aborted||this.pendingResolves.length&&this.pendingResolves.shift()?.();};async getExecutorRef(){const t=()=>this.executorRefs.find(r=>this.idleState.get(r));let n=t();for(;!n;){const{promise:r,resolve:o}=Promise.withResolvers();this.pendingResolves.push(o),await r,n=t();}return this.idleState.set(n,false),n}async dispatch(t){const n=await this.getExecutorRef(),r=kge(n);try{return await t(r)}finally{this.idleState.set(n,true),setTimeout(()=>this.replenish(n));}}};async function Wl(e,t,n){if(!e.length)return [];n=Math.min(n,e.length);const r=lT.fromConcurrency(n,"pmap");try{return await Promise.all(e.map((o,i)=>r.dispatch(()=>t(o,i,e))))}catch(o){throw r.abort(),o}}function cT(e){const t=lT.fromConcurrency(e,"pLimit");return function(r,...o){return t.dispatch(()=>r(...o))}}var _H=Fge;function Fge(e,t){const n=lT.fromConcurrency(t,"createLimitedVersionOfFn");return function(...o){return n.dispatch(()=>e(...o))}}function uT(e,t,n,r){let o=e[t];return Xa(e,()=>{const i=e[t];Object.is(o,i)||n(o=i);},r)}const{proxyStateMap:Hge,snapCache:Vge}=$M(),hb=e=>Hge.has(e);function BH(e){const t=[];let n=0;const r=new Map,o=new WeakMap,i=()=>{const d=Vge.get(l),m=d?.[1];if(m&&!o.has(m)){const p=new Map(r);o.set(m,p);}},a=d=>o.get(d)||r;if(e){if(typeof e[Symbol.iterator]!="function")throw new TypeError(`proxyMap:
initial state must be iterable
tip: structure should be [[key, value]]`);for(const[d,m]of e)r.set(d,n),t[n++]=m;}const l={data:t,index:n,epoch:0,get size(){return hb(this)||i(),a(this).size},get(d){const p=a(this).get(d);if(p===void 0){this.epoch;return}return this.data[p]},has(d){const m=a(this);return this.epoch,m.has(d)},set(d,m){if(!hb(this))throw new Error("Cannot perform mutations on a snapshot");const p=r.get(d);return p===void 0?(r.set(d,this.index),this.data[this.index++]=m):this.data[p]=m,this.epoch++,this},delete(d){if(!hb(this))throw new Error("Cannot perform mutations on a snapshot");const m=r.get(d);return m===void 0?false:(delete this.data[m],r.delete(d),this.epoch++,true)},clear(){if(!hb(this))throw new Error("Cannot perform mutations on a snapshot");this.data.length=0,this.index=0,this.epoch++,r.clear();},forEach(d){this.epoch,a(this).forEach((p,g)=>{d(this.data[p],g,this);});},*entries(){this.epoch;const d=a(this);for(const[m,p]of d)yield [m,this.data[p]];},*keys(){this.epoch;const d=a(this);for(const m of d.keys())yield m;},*values(){this.epoch;const d=a(this);for(const m of d.values())yield this.data[m];},[Symbol.iterator](){return this.entries()},get[Symbol.toStringTag](){return "Map"},toJSON(){return new Map(this.entries())}},u=zn(l);return Object.defineProperties(u,{size:{enumerable:false},index:{enumerable:false},epoch:{enumerable:false},data:{enumerable:false},toJSON:{enumerable:false}}),Object.seal(u),u}const{proxyStateMap:jge,snapCache:Uge}=$M(),pb=e=>typeof e=="object"?zn({x:e}).x:e,gb=e=>jge.has(e);function Rr(e){const t=[],n=new Map;let r=0;const o=new WeakMap,i=()=>{const C=Uge.get(y),w=C?.[1];if(w&&!o.has(w)){const $=new Map(n);o.set(w,$);}},a=C=>o.get(C)||n;if(e){if(typeof e[Symbol.iterator]!="function")throw new TypeError("not iterable");for(const C of e)if(!n.has(C)){const w=pb(C);n.set(w,r),t[r++]=w;}}const l=C=>typeof C=="object"&&C!==null&&Symbol.iterator in C,u=C=>typeof C.forEach=="function",d=C=>{if(l(C))return C;if(u(C)){const w=[];return C.forEach($=>w.push($)),w}throw new TypeError("Expected an iterable")};function m(C){this.epoch;const w=Rr(d(C)),$=Rr();for(const M of this.values())w.has(M)&&$.add(M);return Rr($)}function p(C){this.epoch;const w=Rr(d(C)),$=Rr();for(const M of this.values())$.add(M);for(const M of w.values())$.add(M);return Rr($)}function g(C){this.epoch;const w=Rr(d(C)),$=Rr();for(const M of this.values())w.has(M)||$.add(M);return Rr($)}function b(C){this.epoch;const w=Rr(d(C)),$=Rr();for(const M of this.values())w.has(M)||$.add(M);for(const M of w.values())this.has(M)||$.add(M);return Rr($)}const y={data:t,index:r,epoch:0,get size(){return gb(this)||i(),n.size},has(C){const w=a(this),$=pb(C);return this.epoch,w.has($)},add(C){if(!gb(this))throw new Error("Cannot perform mutations on a snapshot");const w=pb(C);return n.has(w)||(n.set(w,this.index),this.data[this.index++]=w,this.epoch++),this},delete(C){if(!gb(this))throw new Error("Cannot perform mutations on a snapshot");const w=pb(C),$=n.get(w);return $===void 0?false:(delete this.data[$],n.delete(w),this.epoch++,true)},clear(){if(!gb(this))throw new Error("Cannot perform mutations on a snapshot");this.data.length=0,this.index=0,this.epoch++,n.clear();},forEach(C){this.epoch,a(this).forEach($=>{C(this.data[$],this.data[$],this);});},*values(){this.epoch;const C=a(this);for(const w of C.values())yield this.data[w];},keys(){return this.epoch,this.values()},*entries(){this.epoch;const C=a(this);for(const w of C.values()){const $=this.data[w];yield [$,$];}},toJSON(){return new Set(this.values())},[Symbol.iterator](){return this.values()},get[Symbol.toStringTag](){return "Set"},intersection:m,union:p,difference:g,symmetricDifference:b,isSubsetOf(C){this.epoch;for(const w of this.values())if(!C.has(w))return false;return true},isSupersetOf(C){this.epoch;const w=d(C);for(const $ of w)if(!this.has($))return false;return true},isDisjointFrom(C){this.epoch;for(const w of this.values())if(C.has(w))return false;return true}},S=zn(y);return Object.defineProperties(S,{size:{enumerable:false},data:{enumerable:false},index:{enumerable:false},epoch:{enumerable:false},toJSON:{enumerable:false}}),Object.seal(S),S}const Wge=typeof GM_info<"u"&&GM_info.scriptHandler==="Userscripts";function fi(e,t=true){if(e.startsWith("/")&&(e=location.origin+e),Wge){GM.openInTab(e,!t);return}GM.openInTab(e,{active:t,insert:true,setParent:true});}function dT({storageKey:e,onUpdate:t,setPersist:n}){if(typeof GM_addValueChangeListener>"u")return;const r=cT(1);GM_addValueChangeListener(e,(o,i,a,l)=>{l&&a&&r(async()=>{n(false);try{t(a);}finally{await Promise.resolve().then(()=>{n(true);});}});});}function nc(e){const t=zn({value:e()});function n(){return bt(t).value}function r(){return t.value}function o(){return t.value=e()}const i=Yl(o,100,{edges:["leading","trailing"]});return {state:t,use:n,get:r,update:o,updateThrottled:i}}function LH(e,t,n){let r=su(Fr(e),t);Xa(e,()=>{const o=Fr(e),i=su(o,t);fa(r,i)||n(o),r=i;});}function fT(e,t){t.startsWith(Ao)||(t=`${io}:${t}`);const n=Object.keys(e),[r,o]=wf(()=>{const a=localStorage.getItem(t);if(!a)return;const l=JSON.parse(a);return su(l,n)});r&&Ko("failed to load from localStorage key=",t,"error=",r);const i=zn({...e,...o});return setTimeout(()=>{Xa(i,()=>{const a=Fr(i);localStorage.setItem(t,JSON.stringify(a));});}),i}async function mT(e,t){async function n(){const o=Object.keys(e);return su(await GM.getValue(t)||{},o)}const r=zn({...e,...await n()});return setTimeout(()=>{const o=cT(1);Xa(r,()=>o(async()=>{const i=await n(),a=cQ(i,Fr(r));GM.setValue(t,a);}));}),r}async function zH(e){const n=Rr(await(async()=>await GM.getValue(e)||[])()),r=a=>{const l=new Set(a);for(const u of [...n,...l])l.has(u)?n.add(u):n.delete(u);};setTimeout(i);let o=true;function i(){Xa(n,()=>{o&&GM.setValue(e,Array.from(Fr(n)));}),dT({storageKey:e,setPersist:a=>o=a,onUpdate:r});}return {set:n,replaceAllWith:r}}async function kH(e,t){const r=BH(await(async()=>await GM.getValue(e)||[])()),o=l=>{const u=new Map(l);for(const[d,m]of [...r,...u])u.has(d)?r.set(d,m):r.delete(d);};setTimeout(a);let i=true;function a(){Xa(r,()=>{if(!i)return;let l=Array.from(Fr(r));GM.setValue(e,l);}),dT({storageKey:e,setPersist:l=>i=l,onUpdate:o});}return {map:r,replaceAllWith:o}}const Gge=()=>document.querySelector(".bili-header__bar"),hT=nc(FH);function FH(){const e=Gge();return !!(e&&window.getComputedStyle(e).display==="none")}const uu=nc(function(){if(!FH())return 64;if(!document.body.classList.contains("fixed-navbar"))return 0;const n=document.documentElement.style.getPropertyValue("--navbar-height");if(!n)return 50;const r=Number(n.replace("px",""));return Number.isNaN(r)?50:r}),pT=nc(function(){const t=document.documentElement.style.getPropertyValue("--navbar-bounds-padding");return !t||!/^\d+%$/.test(t)?void 0:100-ff(Number(t.replace("%","")),2,10)*2});function qge(){const e=pT.use(),{pureRecommend:t,grid:{useCustomGrid:n}}=Ut();if(!t||!n||!e)return;const r=(1-e/100)/2*window.innerWidth+10,o=40;return r>o+24+5?void 0:r<o?0:Math.floor((r-o)/2)}const lg=nc(function(){return window.getComputedStyle(document.documentElement).getPropertyValue("--theme-color")}),HH=`${io}:evolved-theme-color-hex`;zge(()=>{const e=lg.get();e&&localStorage.setItem(HH,e);});function VH(){return localStorage.getItem(HH)||Mf.Pink}function Kge(){hT.updateThrottled(),uu.updateThrottled(),pT.updateThrottled(),lg.updateThrottled();}const jH=new MutationObserver(()=>Kge());jH.observe(document.documentElement,{attributes:true,attributeFilter:["style"]});jH.observe(document.body,{attributes:true,attributeFilter:["class"]});document.body.addEventListener("click",e=>{const t=e.target,n=r=>!!r?.matches(".be-button.ok");!n(t)&&!n(t.parentElement)||t.closest(".be-popup.picker.open")&&setTimeout(lg.updateThrottled,1e3);},{capture:true,passive:true});const UH={maxCount:5,top:uu.get()-4};rT.config(UH);function Yge(){const e=uu.use();return x(og,{message:{...UH,top:e-4},children:x(Xge,{})})}let vb,_t=rT,ca=vH,gT=Ea;function Xge(){return vb=og.useApp(),_t=vb.message,ca=vb.notification,gT=vb.modal,null}function gi(e){return e.filter(Boolean).filter(t=>t.test===void 0?true:typeof t.test=="boolean"?t.test:t.test()).map(t=>uL(t,["test"]))}const Qge=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",fillRule:"evenodd",d:"M17.793 3.693a1 1 0 0 1 1.414 0l2.5 2.5a1 1 0 0 1 0 1.414l-2.5 2.5a1 1 0 1 1-1.414-1.414L19.586 6.9l-1.793-1.793a1 1 0 0 1 0-1.414m0 10.15a1 1 0 0 1 1.414 0l2.5 2.5a1 1 0 0 1 0 1.414l-2.5 2.5a1 1 0 1 1-1.414-1.414l1.793-1.793l-1.793-1.793a1 1 0 0 1 0-1.414",clipRule:"evenodd"}),x("path",{fill:"currentColor",fillRule:"evenodd",d:"M19.054 5.913c.352.023.657.043.946.043a1 1 0 1 1 0 2c-.346 0-.776-.028-1.184-.054a37 37 0 0 0-.606-.037c-.614-.03-1.118-.02-1.482.065c-1.456.341-3.07 1.481-4.394 4.117c1.304 2.555 2.9 3.529 4.394 3.879c.364.085.868.094 1.482.064c.186-.009.393-.022.606-.036A19 19 0 0 1 20 15.899a1 1 0 1 1 0 2c-.289 0-.594.02-.946.044c-.227.015-.473.032-.747.045c-.63.03-1.377.04-2.035-.115c-1.812-.424-3.549-1.493-4.972-3.634c-.553 1.02-1.177 1.822-1.927 2.427c-.978.788-2.12 1.106-3.213 1.24c-.882.108-1.81.102-2.64.096L3 18a1 1 0 1 1 0-2l.582.002c.824.005 1.593.01 2.335-.08c.892-.11 1.624-.348 2.201-.813c.687-.554 1.323-1.447 1.962-2.95l.046-.109l-.046-.109c-.651-1.53-1.303-2.495-2.015-3.103c-.56-.477-1.277-.726-2.161-.845c-.763-.102-1.562-.099-2.42-.095L3 7.899a1 1 0 1 1 0-2l.445-.001c.853-.004 1.813-.01 2.724.113c1.094.146 2.234.486 3.194 1.305c.75.64 1.375 1.481 1.93 2.52c1.408-2.187 3.136-3.421 4.979-3.853c.658-.154 1.405-.145 2.035-.115c.274.013.52.03.747.045",clipRule:"evenodd"})]}),Zge=f.forwardRef(Qge);function cg(e){return t=>e({xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",width:"1em",height:"1em",...t})}const Jge=cg(e=>x("svg",{viewBox:"0 0 1024 1024",fill:"currentColor",...e,children:x("path",{d:"M550 470q10-36 34-62.5t56.5-41Q673 352 709 352q35 0 67.5 14t57 40.5Q858 433 869 470q1 4-1 7t-9 3H560q-4 0-8-2t-2-8zm-64-11q-7 27 3.5 46t28.5 29q18 10 36 10h310q19 0 37.5-10.5t28-30Q939 484 931 456q-14-51-46.5-88.5T807 309q-45-21-98-21-57 0-103 23.5t-77 62Q498 412 486 459zm-17 15q-35-10-61.5-34t-41-56.5Q352 351 352 315q0-35 14-67.5t40.5-57Q433 166 470 155q3-1 6.5 1t3.5 9v299q0 4-2 8t-9 2zm-11 64q28 7 47-3t29-28.5q10-18.5 10-36.5V160q0-19-10.5-37.5t-30.5-28Q483 85 455 93q-50 14-88 46.5T308.5 217Q288 262 288 315q0 57 23 103t62 77q39 31 85 43zm16 16q-10 36-34 62.5t-57 41Q350 672 314 672q-35 0-67.5-14T190 617.5Q166 591 155 554q-1-3 1-6.5t9-3.5h298q5 0 9 2t2 8zm63 11q7-27-3-46t-28-29q-18-10-36-10H160q-19 0-37.5 10.5t-28 30Q85 540 93 569q14 50 46.5 87.5T217 715q45 21 97 21 57 0 103.5-23.5t77.5-62q31-38.5 42-85.5zm17-15q36 10 62.5 34t41 57q14.5 33 14.5 69 0 35-14 67t-40.5 56.5Q591 858 554 869q-3 1-6.5-1t-3.5-9V560q0-4 2-8t8-2zm11-63q-27-7-46 3t-29 28q-10 18-10 36v310q0 19 10.5 37.5t30 28Q540 939 568 931q51-14 88.5-46.5T715 807q21-45 21-97 0-57-23.5-103.5t-62-77.5Q612 498 565 487z"})})),eve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{children:[x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.14}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.29,transform:"rotate(30 12 12)"}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.43,transform:"rotate(60 12 12)"}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.57,transform:"rotate(90 12 12)"}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.71,transform:"rotate(120 12 12)"}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",opacity:.86,transform:"rotate(150 12 12)"}),x("rect",{width:2,height:5,x:11,y:1,fill:"currentColor",transform:"rotate(180 12 12)"}),x("animateTransform",{attributeName:"transform",calcMode:"discrete",dur:"0.75s",repeatCount:"indefinite",type:"rotate",values:"0 12 12;30 12 12;60 12 12;90 12 12;120 12 12;150 12 12;180 12 12;210 12 12;240 12 12;270 12 12;300 12 12;330 12 12;360 12 12"})]})]}),vT=f.forwardRef(eve),tve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 256 256",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"currentColor",children:[x("path",{d:"M80 104v104H32a8 8 0 0 1-8-8v-88a8 8 0 0 1 8-8Z",opacity:.2}),x("path",{d:"M234 80.12A24 24 0 0 0 216 72h-56V56a40 40 0 0 0-40-40a8 8 0 0 0-7.16 4.42L75.06 96H32a16 16 0 0 0-16 16v88a16 16 0 0 0 16 16h172a24 24 0 0 0 23.82-21l12-96A24 24 0 0 0 234 80.12M32 112h40v88H32Zm191.94-15l-12 96a8 8 0 0 1-7.94 7H88v-94.11l36.71-73.43A24 24 0 0 1 144 56v24a8 8 0 0 0 8 8h64a8 8 0 0 1 7.94 9"})]})]}),nve=f.forwardRef(tve),rve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 256 256",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"currentColor",children:[x("path",{d:"M80 48v104H32a8 8 0 0 1-8-8V56a8 8 0 0 1 8-8Z",opacity:.2}),x("path",{d:"m239.82 157l-12-96A24 24 0 0 0 204 40H32a16 16 0 0 0-16 16v88a16 16 0 0 0 16 16h43.06l37.78 75.58A8 8 0 0 0 120 240a40 40 0 0 0 40-40v-16h56a24 24 0 0 0 23.82-27M72 144H32V56h40Zm150 21.29a7.88 7.88 0 0 1-6 2.71h-64a8 8 0 0 0-8 8v24a24 24 0 0 1-19.29 23.54L88 150.11V56h116a8 8 0 0 1 7.94 7l12 96a7.87 7.87 0 0 1-1.94 6.29"})]})]}),ove=f.forwardRef(rve),ive=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"m24 4l-6 6h-8v8l-6 6l6 6v8h8l6 6l6-6h8v-8l6-6l-6-6v-8h-8z"}),x("path",{d:"M24 30a6 6 0 1 0 0-12a6 6 0 0 0 0 12Z"})]})]}),ave=f.forwardRef(ive),sve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("rect",{width:36,height:36,x:6,y:6,strokeLinecap:"round",rx:3}),x("path",{d:"M18.5 24v-7.794l6.75 3.897L32 24l-6.75 3.897l-6.75 3.897z"})]})]}),lve=f.forwardRef(sve),cve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M5.616 20q-.691 0-1.153-.462T4 18.384V5.616q0-.691.463-1.153T5.616 4h5.615v1H5.616q-.231 0-.424.192T5 5.616v12.769q0 .23.192.423t.423.192h12.77q.23 0 .423-.192t.192-.423v-5.616h1v5.616q0 .69-.462 1.152T18.384 20zm4.123-5.03l-.708-.709L18.292 5H14V4h6v6h-1V5.708z"})]}),uve=f.forwardRef(cve),dve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M18 7h-3l4-4l4 4h-3v14h-2zM8 5c-3.86 0-7 3.13-7 7s3.13 7 7 7c3.86 0 7-3.13 7-7s-3.13-7-7-7m2.19 9.53L7 12.69V9h1.5v2.82l2.44 1.41z"})]}),fve=f.forwardRef(dve),mve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M20 17h3l-4 4l-4-4h3V3h2zM8 5c-3.86 0-7 3.13-7 7s3.13 7 7 7c3.86 0 7-3.13 7-7s-3.13-7-7-7m2.19 9.53L7 12.69V9h1.5v2.82l2.44 1.41z"})]}),hve=f.forwardRef(mve),pve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 6h7m-7 6h7m-7 6h9m2-9l3-3l3 3m-3-3v12"})]}),gve=f.forwardRef(pve),vve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 6h9m-9 6h7m-7 6h7m4-3l3 3l3-3m-3-9v12"})]}),bve=f.forwardRef(vve),yve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",children:[x("path",{stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M24 44a19.94 19.94 0 0 0 14.142-5.858A19.94 19.94 0 0 0 44 24a19.94 19.94 0 0 0-5.858-14.142A19.94 19.94 0 0 0 24 4A19.94 19.94 0 0 0 9.858 9.858A19.94 19.94 0 0 0 4 24a19.94 19.94 0 0 0 5.858 14.142A19.94 19.94 0 0 0 24 44Z"}),x("path",{fill:"currentColor",fillRule:"evenodd",d:"M24 11a2.5 2.5 0 1 1 0 5a2.5 2.5 0 0 1 0-5",clipRule:"evenodd"}),x("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"M24.5 34V20h-2M21 34h7"})]})]}),Sve=f.forwardRef(yve),Cve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M16 4.5V7H5v2h11v2.5L19.5 8M16 12.5V15H5v2h11v2.5l3.5-3.5"})]}),xve=f.forwardRef(Cve),wve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M24 44c11.046 0 20-8.954 20-20S35.046 4 24 4S4 12.954 4 24s8.954 20 20 20Z"}),x("path",{strokeLinecap:"round",d:"M24.008 12v12.01l8.479 8.48"})]})]}),$ve=f.forwardRef(wve),Eve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeWidth:4,children:[x("rect",{width:26,height:40,x:11,y:4,rx:3}),x("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M22 10h4m-6 28h8"})]})]}),Mve=f.forwardRef(Eve),Rve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeWidth:4,children:[x("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19 32h10v9H19z"}),x("rect",{width:38,height:24,x:5,y:8,rx:2}),x("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M22 27h4M14 41h20"})]})]}),Tve=f.forwardRef(Rve),Ave=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",children:[x("path",{strokeLinecap:"round",strokeWidth:4,d:"M10.858 9.858A19.94 19.94 0 0 0 5 24a19.94 19.94 0 0 0 5.858 14.142m28.284 0A19.94 19.94 0 0 0 45 24a19.94 19.94 0 0 0-5.858-14.142M34.9 33.9A13.96 13.96 0 0 0 39 24a13.96 13.96 0 0 0-4.1-9.9m-19.8 0A13.96 13.96 0 0 0 11 24a13.96 13.96 0 0 0 4.1 9.9"}),x("path",{strokeLinejoin:"round",strokeWidth:3.5,d:"M28.182 20C30.29 20 32 21.612 32 23.6c0 2.588-2.546 4.8-3.818 6Q26.908 30.8 25 32q-1.909-1.2-3.182-2.4C20.545 28.4 18 26.188 18 23.6c0-1.988 1.71-3.6 3.818-3.6c1.328 0 2.498.64 3.182 1.61c.684-.97 1.854-1.61 3.182-1.61Z"})]})]}),Nve=f.forwardRef(Ave),Pve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"m16 6.52l2.76 5.58l.46 1l1 .15l6.16.89l-4.38 4.3l-.75.73l.18 1l1.05 6.13l-5.51-2.89L16 23l-.93.49l-5.51 2.85l1-6.13l.18-1l-.74-.77l-4.42-4.35l6.16-.89l1-.15l.46-1zM16 2l-4.55 9.22l-10.17 1.47l7.36 7.18L6.9 30l9.1-4.78L25.1 30l-1.74-10.13l7.36-7.17l-10.17-1.48Z"})]}),Ive=f.forwardRef(Pve),Ove=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 32 32",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"m16 2l-4.55 9.22l-10.17 1.47l7.36 7.18L6.9 30l9.1-4.78L25.1 30l-1.74-10.13l7.36-7.17l-10.17-1.48Z"})]}),Dve=f.forwardRef(Ove),_ve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M24 44c8.235 0 15-6.526 15-14.902c0-2.056-.105-4.26-1.245-7.686s-1.369-3.868-2.574-5.984c-.515 4.317-3.27 6.117-3.97 6.655c0-.56-1.666-6.747-4.193-10.45C24.537 8 21.163 5.617 19.185 4c0 3.07-.863 7.634-2.1 9.96c-1.236 2.325-1.468 2.41-3.013 4.14s-2.253 2.265-3.545 4.365S9 27.362 9 29.418C9 37.794 15.765 44 24 44Z"})]}),Bve=f.forwardRef(_ve),Lve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{strokeDasharray:32,d:"M12 3c4.97 0 9 4.03 9 9c0 4.97 -4.03 9 -9 9",children:x("animate",{fill:"freeze",attributeName:"stroke-dashoffset",dur:"0.6s",values:"32;0"})}),F("path",{strokeDasharray:"2 4",strokeDashoffset:6,d:"M12 21c-4.97 0 -9 -4.03 -9 -9c0 -4.97 4.03 -9 9 -9",opacity:0,children:[x("set",{fill:"freeze",attributeName:"opacity",begin:"0.45s",to:1}),x("animateTransform",{fill:"freeze",attributeName:"transform",begin:"0.45s",dur:"0.6s",type:"rotate",values:"-180 12 12;0 12 12"}),x("animate",{attributeName:"stroke-dashoffset",begin:"0.85s",dur:"0.6s",repeatCount:"indefinite",to:0})]}),x("path",{strokeDasharray:10,strokeDashoffset:10,d:"M12 16v-7.5",children:x("animate",{fill:"freeze",attributeName:"stroke-dashoffset",begin:"0.85s",dur:"0.2s",to:0})}),x("path",{strokeDasharray:8,strokeDashoffset:8,d:"M12 8.5l3.5 3.5M12 8.5l-3.5 3.5",children:x("animate",{fill:"freeze",attributeName:"stroke-dashoffset",begin:"1.05s",dur:"0.2s",to:0})})]})]}),zve=f.forwardRef(Lve),kve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M19 20a7 7 0 1 0 0-14a7 7 0 0 0 0 14Z"}),x("path",{strokeLinecap:"round",d:"m33 31l8 8m-8 0l8-8m-14-3h-8.2c-4.48 0-6.72 0-8.432.872a8 8 0 0 0-3.496 3.496C6 34.08 6 36.32 6 40.8V42h21"})]})]}),Fve=f.forwardRef(kve),Hve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"m13 8l-7 6l7 7"}),x("path",{d:"M6 14h22.994c6.883 0 12.728 5.62 12.996 12.5c.284 7.27-5.723 13.5-12.996 13.5H11.998"})]})]}),WH=f.forwardRef(Hve),Vve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{strokeLinecap:"round",d:"M13 12.432v-4.62A2.813 2.813 0 0 1 15.813 5h24.374A2.813 2.813 0 0 1 43 7.813v24.375A2.813 2.813 0 0 1 40.188 35h-4.672"}),x("path",{d:"M32.188 13H7.811A2.813 2.813 0 0 0 5 15.813v24.374A2.813 2.813 0 0 0 7.813 43h24.375A2.813 2.813 0 0 0 35 40.188V15.811A2.813 2.813 0 0 0 32.188 13Z"})]})]}),jve=f.forwardRef(Vve),Uve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M7 21q-.825 0-1.412-.587T5 19V6q-.425 0-.712-.288T4 5t.288-.712T5 4h4q0-.425.288-.712T10 3h4q.425 0 .713.288T15 4h4q.425 0 .713.288T20 5t-.288.713T19 6v13q0 .825-.587 1.413T17 21zM17 6H7v13h10zm-6.287 10.713Q11 16.425 11 16V9q0-.425-.288-.712T10 8t-.712.288T9 9v7q0 .425.288.713T10 17t.713-.288m4 0Q15 16.426 15 16V9q0-.425-.288-.712T14 8t-.712.288T13 9v7q0 .425.288.713T14 17t.713-.288M7 6v13z"})]}),Wve=f.forwardRef(Uve),Gve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"m10 8l-6 6l6 6m28 8l6 6l-6 6M4 14h40M4 34h40"})]}),GH=f.forwardRef(Gve),qve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M5.325 43.5h8.485l31.113-31.113l-8.486-8.485L5.325 35.015z"}),x("path",{strokeLinecap:"round",d:"m27.952 12.387l8.485 8.485"})]})]}),Kve=f.forwardRef(qve),Yve=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M16 20v-7h4v7zm-6 0V4h4v16zm-6 0V9h4v11z"})]}),Xve=f.forwardRef(Yve),bT=f.createContext({});function C1(e){const t=f.useRef(null);return t.current===null&&(t.current=e()),t.current}const qH=typeof window<"u",KH=qH?f.useLayoutEffect:f.useEffect,x1=f.createContext(null);function yT(e,t){e.indexOf(t)===-1&&e.push(t);}function mf(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1);}const qa=(e,t,n)=>n>t?t:n<e?e:n;let ST=()=>{};const Ns={},YH=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function XH(e){return typeof e=="object"&&e!==null}const QH=e=>/^0[^.\s]+$/u.test(e);function ZH(e){let t;return ()=>(t===void 0&&(t=e()),t)}const Wi=e=>e,Qve=(e,t)=>n=>t(e(n)),ug=(...e)=>e.reduce(Qve),hf=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class CT{constructor(){this.subscriptions=[];}add(t){return yT(this.subscriptions,t),()=>mf(this.subscriptions,t)}notify(t,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,n,r);else for(let i=0;i<o;i++){const a=this.subscriptions[i];a&&a(t,n,r);}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0;}}const Gi=e=>e*1e3,Ui=e=>e/1e3;function JH(e,t){return t?e*(1e3/t):0}const Zve=(e,t,n)=>{const r=t-e;return ((n-e)%r+r)%r+e},eV=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Jve=1e-7,ebe=12;function tbe(e,t,n,r,o){let i,a,l=0;do a=t+(n-t)/2,i=eV(a,r,o)-e,i>0?n=a:t=a;while(Math.abs(i)>Jve&&++l<ebe);return a}function dg(e,t,n,r){if(e===t&&n===r)return Wi;const o=i=>tbe(i,0,1,e,n);return i=>i===0||i===1?i:eV(o(i),t,r)}const tV=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,nV=e=>t=>1-e(1-t),rV=dg(.33,1.53,.69,.99),xT=nV(rV),oV=tV(xT),iV=e=>(e*=2)<1?.5*xT(e):.5*(2-Math.pow(2,-10*(e-1))),wT=e=>1-Math.sin(Math.acos(e)),aV=nV(wT),sV=tV(wT),nbe=dg(.42,0,1,1),rbe=dg(0,0,.58,1),lV=dg(.42,0,.58,1),cV=e=>Array.isArray(e)&&typeof e[0]!="number";function uV(e,t){return cV(e)?e[Zve(0,e.length,t)]:e}const dV=e=>Array.isArray(e)&&typeof e[0]=="number",obe={linear:Wi,easeIn:nbe,easeInOut:lV,easeOut:rbe,circIn:wT,circInOut:sV,circOut:aV,backIn:xT,backInOut:oV,backOut:rV,anticipate:iV},ibe=e=>typeof e=="string",q8=e=>{if(dV(e)){ST(e.length===4);const[t,n,r,o]=e;return dg(t,n,r,o)}else if(ibe(e))return obe[e];return e},bb=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function abe(e,t){let n=new Set,r=new Set,o=false,i=false;const a=new WeakSet;let l={delta:0,timestamp:0,isProcessing:false};function u(m){a.has(m)&&(d.schedule(m),e()),m(l);}const d={schedule:(m,p=false,g=false)=>{const y=g&&o?n:r;return p&&a.add(m),y.has(m)||y.add(m),m},cancel:m=>{r.delete(m),a.delete(m);},process:m=>{if(l=m,o){i=true;return}o=true,[n,r]=[r,n],n.forEach(u),n.clear(),o=false,i&&(i=false,d.process(m));}};return d}const sbe=40;function fV(e,t){let n=false,r=true;const o={delta:0,timestamp:0,isProcessing:false},i=()=>n=true,a=bb.reduce((M,T)=>(M[T]=abe(i),M),{}),{setup:l,read:u,resolveKeyframes:d,preUpdate:m,update:p,preRender:g,render:b,postRender:y}=a,S=()=>{const M=Ns.useManualTiming?o.timestamp:performance.now();n=false,Ns.useManualTiming||(o.delta=r?1e3/60:Math.max(Math.min(M-o.timestamp,sbe),1)),o.timestamp=M,o.isProcessing=true,l.process(o),u.process(o),d.process(o),m.process(o),p.process(o),g.process(o),b.process(o),y.process(o),o.isProcessing=false,n&&t&&(r=false,e(S));},C=()=>{n=true,r=true,o.isProcessing||e(S);};return {schedule:bb.reduce((M,T)=>{const R=a[T];return M[T]=(I,N=false,P=false)=>(n||C(),R.schedule(I,N,P)),M},{}),cancel:M=>{for(let T=0;T<bb.length;T++)a[bb[T]].cancel(M);},state:o,steps:a}}const{schedule:Vn,cancel:Gl,state:Xr,steps:uw}=fV(typeof requestAnimationFrame<"u"?requestAnimationFrame:Wi,true);let Zb;function lbe(){Zb=void 0;}const Eo={now:()=>(Zb===void 0&&Eo.set(Xr.isProcessing||Ns.useManualTiming?Xr.timestamp:performance.now()),Zb),set:e=>{Zb=e,queueMicrotask(lbe);}},mV=e=>t=>typeof t=="string"&&t.startsWith(e),hV=mV("--"),cbe=mV("var(--"),$T=e=>cbe(e)?ube.test(e.split("/*")[0].trim()):false,ube=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function K8(e){return typeof e!="string"?false:e.split("/*")[0].includes("var(--")}const Hf={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Sp={...Hf,transform:e=>qa(0,1,e)},yb={...Hf,default:1},zh=e=>Math.round(e*1e5)/1e5,ET=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function dbe(e){return e==null}const fbe=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,MT=(e,t)=>n=>!!(typeof n=="string"&&fbe.test(n)&&n.startsWith(e)||t&&!dbe(n)&&Object.prototype.hasOwnProperty.call(n,t)),pV=(e,t,n)=>r=>{if(typeof r!="string")return r;const[o,i,a,l]=r.match(ET);return {[e]:parseFloat(o),[t]:parseFloat(i),[n]:parseFloat(a),alpha:l!==void 0?parseFloat(l):1}},mbe=e=>qa(0,255,e),dw={...Hf,transform:e=>Math.round(mbe(e))},Uc={test:MT("rgb","red"),parse:pV("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+dw.transform(e)+", "+dw.transform(t)+", "+dw.transform(n)+", "+zh(Sp.transform(r))+")"};function hbe(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const s3={test:MT("#"),parse:hbe,transform:Uc.transform},fg=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),wl=fg("deg"),ja=fg("%"),vt=fg("px"),pbe=fg("vh"),gbe=fg("vw"),Y8={...ja,parse:e=>ja.parse(e)/100,transform:e=>ja.transform(e*100)},Bd={test:MT("hsl","hue"),parse:pV("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ja.transform(zh(t))+", "+ja.transform(zh(n))+", "+zh(Sp.transform(r))+")"},Cr={test:e=>Uc.test(e)||s3.test(e)||Bd.test(e),parse:e=>Uc.test(e)?Uc.parse(e):Bd.test(e)?Bd.parse(e):s3.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Uc.transform(e):Bd.transform(e),getAnimatableNone:e=>{const t=Cr.parse(e);return t.alpha=0,Cr.transform(t)}},vbe=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function bbe(e){return isNaN(e)&&typeof e=="string"&&(e.match(ET)?.length||0)+(e.match(vbe)?.length||0)>0}const gV="number",vV="color",ybe="var",Sbe="var(",X8="${}",Cbe=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Cp(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let i=0;const l=t.replace(Cbe,u=>(Cr.test(u)?(r.color.push(i),o.push(vV),n.push(Cr.parse(u))):u.startsWith(Sbe)?(r.var.push(i),o.push(ybe),n.push(u)):(r.number.push(i),o.push(gV),n.push(parseFloat(u))),++i,X8)).split(X8);return {values:n,split:l,indexes:r,types:o}}function bV(e){return Cp(e).values}function yV(e){const{split:t,types:n}=Cp(e),r=t.length;return o=>{let i="";for(let a=0;a<r;a++)if(i+=t[a],o[a]!==void 0){const l=n[a];l===gV?i+=zh(o[a]):l===vV?i+=Cr.transform(o[a]):i+=o[a];}return i}}const xbe=e=>typeof e=="number"?0:Cr.test(e)?Cr.getAnimatableNone(e):e;function wbe(e){const t=bV(e);return yV(e)(t.map(xbe))}const pa={test:bbe,parse:bV,createTransformer:yV,getAnimatableNone:wbe};function fw(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function $be({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let o=0,i=0,a=0;if(!t)o=i=a=n;else {const l=n<.5?n*(1+t):n+t-n*t,u=2*n-l;o=fw(u,l,e+1/3),i=fw(u,l,e),a=fw(u,l,e-1/3);}return {red:Math.round(o*255),green:Math.round(i*255),blue:Math.round(a*255),alpha:r}}function sy(e,t){return n=>n>0?t:e}const er=(e,t,n)=>e+(t-e)*n,mw=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},Ebe=[s3,Uc,Bd],Mbe=e=>Ebe.find(t=>t.test(e));function Q8(e){const t=Mbe(e);if(!t)return false;let n=t.parse(e);return t===Bd&&(n=$be(n)),n}const Z8=(e,t)=>{const n=Q8(e),r=Q8(t);if(!n||!r)return sy(e,t);const o={...n};return i=>(o.red=mw(n.red,r.red,i),o.green=mw(n.green,r.green,i),o.blue=mw(n.blue,r.blue,i),o.alpha=er(n.alpha,r.alpha,i),Uc.transform(o))},l3=new Set(["none","hidden"]);function Rbe(e,t){return l3.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Tbe(e,t){return n=>er(e,t,n)}function RT(e){return typeof e=="number"?Tbe:typeof e=="string"?$T(e)?sy:Cr.test(e)?Z8:Pbe:Array.isArray(e)?SV:typeof e=="object"?Cr.test(e)?Z8:Abe:sy}function SV(e,t){const n=[...e],r=n.length,o=e.map((i,a)=>RT(i)(i,t[a]));return i=>{for(let a=0;a<r;a++)n[a]=o[a](i);return n}}function Abe(e,t){const n={...e,...t},r={};for(const o in n)e[o]!==void 0&&t[o]!==void 0&&(r[o]=RT(e[o])(e[o],t[o]));return o=>{for(const i in r)n[i]=r[i](o);return n}}function Nbe(e,t){const n=[],r={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){const i=t.types[o],a=e.indexes[i][r[i]],l=e.values[a]??0;n[o]=l,r[i]++;}return n}const Pbe=(e,t)=>{const n=pa.createTransformer(t),r=Cp(e),o=Cp(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?l3.has(e)&&!o.values.length||l3.has(t)&&!r.values.length?Rbe(e,t):ug(SV(Nbe(r,o),o.values),n):sy(e,t)};function CV(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?er(e,t,n):RT(e)(e,t)}const Ibe=e=>{const t=({timestamp:n})=>e(n);return {start:(n=true)=>Vn.update(t,n),stop:()=>Gl(t),now:()=>Xr.isProcessing?Xr.timestamp:Eo.now()}},xV=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let i=0;i<o;i++)r+=Math.round(e(i/(o-1))*1e4)/1e4+", ";return `linear(${r.substring(0,r.length-2)})`},ly=2e4;function TT(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<ly;)t+=n,r=e.next(t);return t>=ly?1/0:t}function wV(e,t=100,n){const r=n({...e,keyframes:[0,t]}),o=Math.min(TT(r),ly);return {type:"keyframes",ease:i=>r.next(o*i).value/t,duration:Ui(o)}}const Obe=5;function $V(e,t,n){const r=Math.max(t-Obe,0);return JH(n-e(r),t-r)}const lr={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},hw=.001;function Dbe({duration:e=lr.duration,bounce:t=lr.bounce,velocity:n=lr.velocity,mass:r=lr.mass}){let o,i,a=1-t;a=qa(lr.minDamping,lr.maxDamping,a),e=qa(lr.minDuration,lr.maxDuration,Ui(e)),a<1?(o=d=>{const m=d*a,p=m*e,g=m-n,b=c3(d,a),y=Math.exp(-p);return hw-g/b*y},i=d=>{const p=d*a*e,g=p*n+n,b=Math.pow(a,2)*Math.pow(d,2)*e,y=Math.exp(-p),S=c3(Math.pow(d,2),a);return (-o(d)+hw>0?-1:1)*((g-b)*y)/S}):(o=d=>{const m=Math.exp(-d*e),p=(d-n)*e+1;return -hw+m*p},i=d=>{const m=Math.exp(-d*e),p=(n-d)*(e*e);return m*p});const l=5/e,u=Bbe(o,i,l);if(e=Gi(e),isNaN(u))return {stiffness:lr.stiffness,damping:lr.damping,duration:e};{const d=Math.pow(u,2)*r;return {stiffness:d,damping:a*2*Math.sqrt(r*d),duration:e}}}const _be=12;function Bbe(e,t,n){let r=n;for(let o=1;o<_be;o++)r=r-e(r)/t(r);return r}function c3(e,t){return e*Math.sqrt(1-t*t)}const Lbe=["duration","bounce"],zbe=["stiffness","damping","mass"];function J8(e,t){return t.some(n=>e[n]!==void 0)}function kbe(e){let t={velocity:lr.velocity,stiffness:lr.stiffness,damping:lr.damping,mass:lr.mass,isResolvedFromDuration:false,...e};if(!J8(e,zbe)&&J8(e,Lbe))if(t.velocity=0,e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),o=r*r,i=2*qa(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:lr.mass,stiffness:o,damping:i};}else {const n=Dbe({...e,velocity:0});t={...t,...n,mass:lr.mass},t.isResolvedFromDuration=true;}return t}function xp(e=lr.visualDuration,t=lr.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const i=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],l={done:false,value:i},{stiffness:u,damping:d,mass:m,duration:p,velocity:g,isResolvedFromDuration:b}=kbe({...n,velocity:-Ui(n.velocity||0)}),y=g||0,S=d/(2*Math.sqrt(u*m)),C=a-i,w=Ui(Math.sqrt(u/m)),$=Math.abs(C)<5;r||(r=$?lr.restSpeed.granular:lr.restSpeed.default),o||(o=$?lr.restDelta.granular:lr.restDelta.default);let M;if(S<1){const R=c3(w,S);M=I=>{const N=Math.exp(-S*w*I);return a-N*((y+S*w*C)/R*Math.sin(R*I)+C*Math.cos(R*I))};}else if(S===1)M=R=>a-Math.exp(-w*R)*(C+(y+w*C)*R);else {const R=w*Math.sqrt(S*S-1);M=I=>{const N=Math.exp(-S*w*I),P=Math.min(R*I,300);return a-N*((y+S*w*C)*Math.sinh(P)+R*C*Math.cosh(P))/R};}const T={calculatedDuration:b&&p||null,next:R=>{const I=M(R);if(b)l.done=R>=p;else {let N=R===0?y:0;S<1&&(N=R===0?Gi(y):$V(M,R,I));const P=Math.abs(N)<=r,O=Math.abs(a-I)<=o;l.done=P&&O;}return l.value=l.done?a:I,l},toString:()=>{const R=Math.min(TT(T),ly),I=xV(N=>T.next(R*N).value,R,30);return R+"ms "+I},toTransition:()=>{}};return T}xp.applyToOptions=e=>{const t=wV(e,100,xp);return e.ease=t.ease,e.duration=Gi(t.duration),e.type="keyframes",e};function u3({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:a,min:l,max:u,restDelta:d=.5,restSpeed:m}){const p=e[0],g={done:false,value:p},b=P=>l!==void 0&&P<l||u!==void 0&&P>u,y=P=>l===void 0?u:u===void 0||Math.abs(l-P)<Math.abs(u-P)?l:u;let S=n*t;const C=p+S,w=a===void 0?C:a(C);w!==C&&(S=w-p);const $=P=>-S*Math.exp(-P/r),M=P=>w+$(P),T=P=>{const O=$(P),_=M(P);g.done=Math.abs(O)<=d,g.value=g.done?w:_;};let R,I;const N=P=>{b(g.value)&&(R=P,I=xp({keyframes:[g.value,y(g.value)],velocity:$V(M,P,g.value),damping:o,stiffness:i,restDelta:d,restSpeed:m}));};return N(0),{calculatedDuration:null,next:P=>{let O=false;return !I&&R===void 0&&(O=true,T(P),N(P)),R!==void 0&&P>=R?I.next(P-R):(!O&&T(P),g)}}}function Fbe(e,t,n){const r=[],o=n||Ns.mix||CV,i=e.length-1;for(let a=0;a<i;a++){let l=o(e[a],e[a+1]);if(t){const u=Array.isArray(t)?t[a]||Wi:t;l=ug(u,l);}r.push(l);}return r}function Hbe(e,t,{clamp:n=true,ease:r,mixer:o}={}){const i=e.length;if(ST(i===t.length),i===1)return ()=>t[0];if(i===2&&t[0]===t[1])return ()=>t[1];const a=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const l=Fbe(t,r,o),u=l.length,d=m=>{if(a&&m<e[0])return t[0];let p=0;if(u>1)for(;p<e.length-2&&!(m<e[p+1]);p++);const g=hf(e[p],e[p+1],m);return l[p](g)};return n?m=>d(qa(e[0],e[i-1],m)):d}function EV(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=hf(0,t,r);e.push(er(n,1,o));}}function MV(e){const t=[0];return EV(t,e.length-1),t}function Vbe(e,t){return e.map(n=>n*t)}function jbe(e,t){return e.map(()=>t||lV).splice(0,e.length-1)}function kh({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=cV(r)?r.map(q8):q8(r),i={done:false,value:t[0]},a=Vbe(n&&n.length===t.length?n:MV(t),e),l=Hbe(a,t,{ease:Array.isArray(o)?o:jbe(t,o)});return {calculatedDuration:e,next:u=>(i.value=l(u),i.done=u>=e,i)}}const Ube=e=>e!==null;function AT(e,{repeat:t,repeatType:n="loop"},r,o=1){const i=e.filter(Ube),l=o<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return !l||r===void 0?i[l]:r}const Wbe={decay:u3,inertia:u3,tween:kh,keyframes:kh,spring:xp};function RV(e){typeof e.type=="string"&&(e.type=Wbe[e.type]);}class NT{constructor(){this.updateFinished();}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t;});}notifyFinished(){this.resolve();}then(t,n){return this.finished.then(t,n)}}const Gbe=e=>e/100;class PT extends NT{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=false,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==Eo.now()&&this.tick(Eo.now()),this.isStopped=true,this.state!=="idle"&&(this.teardown(),this.options.onStop?.());},this.options=t,this.initAnimation(),this.play(),t.autoplay===false&&this.pause();}initAnimation(){const{options:t}=this;RV(t);const{type:n=kh,repeat:r=0,repeatDelay:o=0,repeatType:i,velocity:a=0}=t;let{keyframes:l}=t;const u=n||kh;u!==kh&&typeof l[0]!="number"&&(this.mixKeyframes=ug(Gbe,CV(l[0],l[1])),l=[0,100]);const d=u({...t,keyframes:l});i==="mirror"&&(this.mirroredGenerator=u({...t,keyframes:[...l].reverse(),velocity:-a})),d.calculatedDuration===null&&(d.calculatedDuration=TT(d));const{calculatedDuration:m}=d;this.calculatedDuration=m,this.resolvedDuration=m+o,this.totalDuration=this.resolvedDuration*(r+1)-o,this.generator=d;}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n;}tick(t,n=false){const{generator:r,totalDuration:o,mixKeyframes:i,mirroredGenerator:a,resolvedDuration:l,calculatedDuration:u}=this;if(this.startTime===null)return r.next(0);const{delay:d=0,keyframes:m,repeat:p,repeatType:g,repeatDelay:b,type:y,onUpdate:S,finalKeyframe:C}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-o/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-d*(this.playbackSpeed>=0?1:-1),$=this.playbackSpeed>=0?w<0:w>o;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let M=this.currentTime,T=r;if(p){const P=Math.min(this.currentTime,o)/l;let O=Math.floor(P),_=P%1;!_&&P>=1&&(_=1),_===1&&O--,O=Math.min(O,p+1),O%2&&(g==="reverse"?(_=1-_,b&&(_-=b/l)):g==="mirror"&&(T=a)),M=qa(0,1,_)*l;}const R=$?{done:false,value:m[0]}:T.next(M);i&&(R.value=i(R.value));let{done:I}=R;!$&&u!==null&&(I=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);const N=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&I);return N&&y!==u3&&(R.value=AT(m,this.options,C,this.speed)),S&&S(R.value),N&&this.finish(),R}then(t,n){return this.finished.then(t,n)}get duration(){return Ui(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ui(t)}get time(){return Ui(this.currentTime)}set time(t){t=Gi(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(false);}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(Eo.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Ui(this.currentTime));}play(){if(this.isStopped)return;const{driver:t=Ibe,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),this.options.onPlay?.();const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start();}pause(){this.state="paused",this.updateTime(Eo.now()),this.holdTime=this.currentTime;}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null;}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.();}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.();}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null;}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0);}sample(t){return this.startTime=0,this.tick(t,true)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function qbe(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1]);}const Wc=e=>e*180/Math.PI,d3=e=>{const t=Wc(Math.atan2(e[1],e[0]));return f3(t)},Kbe={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:d3,rotateZ:d3,skewX:e=>Wc(Math.atan(e[1])),skewY:e=>Wc(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},f3=e=>(e=e%360,e<0&&(e+=360),e),eD=d3,tD=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),nD=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Ybe={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:tD,scaleY:nD,scale:e=>(tD(e)+nD(e))/2,rotateX:e=>f3(Wc(Math.atan2(e[6],e[5]))),rotateY:e=>f3(Wc(Math.atan2(-e[2],e[0]))),rotateZ:eD,rotate:eD,skewX:e=>Wc(Math.atan(e[4])),skewY:e=>Wc(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function m3(e){return e.includes("scale")?1:0}function h3(e,t){if(!e||e==="none")return m3(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,o;if(n)r=Ybe,o=n;else {const l=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Kbe,o=l;}if(!o)return m3(t);const i=r[t],a=o[1].split(",").map(Qbe);return typeof i=="function"?i(a):a[i]}const Xbe=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return h3(n,t)};function Qbe(e){return parseFloat(e.trim())}const Vf=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],jf=new Set(Vf),rD=e=>e===Hf||e===vt,Zbe=new Set(["x","y","z"]),Jbe=Vf.filter(e=>!Zbe.has(e));function e0e(e){const t=[];return Jbe.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0));}),t}const Il={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>h3(t,"x"),y:(e,{transform:t})=>h3(t,"y")};Il.translateX=Il.x;Il.translateY=Il.y;const eu=new Set;let p3=false,g3=false,v3=false;function TV(){if(g3){const e=Array.from(eu).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const o=e0e(r);o.length&&(n.set(r,o),r.render());}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const o=n.get(r);o&&o.forEach(([i,a])=>{r.getValue(i)?.set(a);});}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY);});}g3=false,p3=false,eu.forEach(e=>e.complete(v3)),eu.clear();}function AV(){eu.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(g3=true);});}function t0e(){v3=true,AV(),TV(),v3=false;}class IT{constructor(t,n,r,o,i,a=false){this.state="pending",this.isAsync=false,this.needsMeasurement=false,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=o,this.element=i,this.isAsync=a;}scheduleResolve(){this.state="scheduled",this.isAsync?(eu.add(this),p3||(p3=true,Vn.read(AV),Vn.resolveKeyframes(TV))):(this.readKeyframes(),this.complete());}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:o}=this;if(t[0]===null){const i=o?.get(),a=t[t.length-1];if(i!==void 0)t[0]=i;else if(r&&n){const l=r.readValue(n,a);l!=null&&(t[0]=l);}t[0]===void 0&&(t[0]=a),o&&i===void 0&&o.set(t[0]);}qbe(t);}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=false){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),eu.delete(this);}cancel(){this.state==="scheduled"&&(eu.delete(this),this.state="pending");}resume(){this.state==="pending"&&this.scheduleResolve();}}const n0e=e=>e.startsWith("--");function r0e(e,t,n){n0e(t)?e.style.setProperty(t,n):e.style[t]=n;}const o0e={};function NV(e,t){const n=ZH(e);return ()=>o0e[t]??n()}const i0e=NV(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),PV=NV(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"});}catch{return false}return true},"linearEasing"),wh=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,oD={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:wh([0,.65,.55,1]),circOut:wh([.55,0,1,.45]),backIn:wh([.31,.01,.66,-0.59]),backOut:wh([.33,1.53,.69,.99])};function IV(e,t){if(e)return typeof e=="function"?PV()?xV(e,t):"ease-out":dV(e)?wh(e):Array.isArray(e)?e.map(n=>IV(n,t)||oD.easeOut):oD[e]}function a0e(e,t,n,{delay:r=0,duration:o=300,repeat:i=0,repeatType:a="loop",ease:l="easeOut",times:u}={},d=void 0){const m={[t]:n};u&&(m.offset=u);const p=IV(l,o);Array.isArray(p)&&(m.easing=p);const g={delay:r,duration:o,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:i+1,direction:a==="reverse"?"alternate":"normal"};return d&&(g.pseudoElement=d),e.animate(m,g)}function OT(e){return typeof e=="function"&&"applyToOptions"in e}function s0e({type:e,...t}){return OT(e)&&PV()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class OV extends NT{constructor(t){if(super(),this.finishedTime=null,this.isStopped=false,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:o,pseudoElement:i,allowFlatten:a=false,finalKeyframe:l,onComplete:u}=t;this.isPseudoElement=!!i,this.allowFlatten=a,this.options=t,ST(typeof t.type!="string");const d=s0e(t);this.animation=a0e(n,r,o,d,i),d.autoplay===false&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const m=AT(o,this.options,l,this.speed);this.updateMotionValue?this.updateMotionValue(m):r0e(n,r,m),this.animation.cancel();}u?.(),this.notifyFinished();};}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished());}pause(){this.animation.pause();}complete(){this.animation.finish?.();}cancel(){try{this.animation.cancel();}catch{}}stop(){if(this.isStopped)return;this.isStopped=true;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel());}commitStyles(){const t=this.options?.element;!this.isPseudoElement&&t?.isConnected&&this.animation.commitStyles?.();}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return Ui(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ui(t)}get time(){return Ui(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Gi(t);}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t;}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t;}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&i0e()?(this.animation.timeline=t,Wi):n(this)}}const DV={anticipate:iV,backInOut:oV,circInOut:sV};function l0e(e){return e in DV}function c0e(e){typeof e.ease=="string"&&l0e(e.ease)&&(e.ease=DV[e.ease]);}const pw=10;class u0e extends OV{constructor(t){c0e(t),RV(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t;}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:o,element:i,...a}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const l=new PT({...a,autoplay:false}),u=Math.max(pw,Eo.now()-this.startTime),d=qa(0,pw,u-pw);n.setWithVelocity(l.sample(Math.max(0,u-d)).value,l.sample(u).value,d),l.stop();}}const iD=(e,t)=>t==="zIndex"?false:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(pa.test(e)||e==="0")&&!e.startsWith("url("));function d0e(e){const t=e[0];if(e.length===1)return true;for(let n=0;n<e.length;n++)if(e[n]!==t)return true}function f0e(e,t,n,r){const o=e[0];if(o===null)return false;if(t==="display"||t==="visibility")return true;const i=e[e.length-1],a=iD(o,t),l=iD(i,t);return !a||!l?false:d0e(e)||(n==="spring"||OT(n))&&r}function b3(e){e.duration=0,e.type="keyframes";}const m0e=new Set(["opacity","clipPath","filter","transform"]),h0e=ZH(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function p0e(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:i,type:a}=e;if(!(t?.owner?.current instanceof HTMLElement))return false;const{onUpdate:u,transformTemplate:d}=t.owner.getProps();return h0e()&&n&&m0e.has(n)&&(n!=="transform"||!d)&&!u&&!r&&o!=="mirror"&&i!==0&&a!=="inertia"}const g0e=40;class v0e extends NT{constructor({autoplay:t=true,delay:n=0,type:r="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:a="loop",keyframes:l,name:u,motionValue:d,element:m,...p}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel();},this.createdAt=Eo.now();const g={autoplay:t,delay:n,type:r,repeat:o,repeatDelay:i,repeatType:a,name:u,motionValue:d,element:m,...p},b=m?.KeyframeResolver||IT;this.keyframeResolver=new b(l,(y,S,C)=>this.onKeyframesResolved(y,S,g,!C),u,d,m),this.keyframeResolver?.scheduleResolve();}onKeyframesResolved(t,n,r,o){this.keyframeResolver=void 0;const{name:i,type:a,velocity:l,delay:u,isHandoff:d,onUpdate:m}=r;this.resolvedAt=Eo.now(),f0e(t,i,a,l)||((Ns.instantAnimations||!u)&&m?.(AT(t,r,n)),t[0]=t[t.length-1],b3(r),r.repeat=0);const g={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>g0e?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},b=!d&&p0e(g),y=g.motionValue?.owner?.current,S=b?new u0e({...g,element:y}):new PT(g);S.finished.then(()=>{this.notifyFinished();}).catch(Wi),this.pendingTimeline&&(this.stopTimeline=S.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=S;}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),t0e()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t;}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t;}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play();}pause(){this.animation.pause();}complete(){this.animation.complete();}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel();}}class b0e{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean);}get finished(){return Promise.all(this.animations.map(t=>t.finished))}getAll(t){return this.animations[0][t]}setAll(t,n){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=n;}attachTimeline(t){const n=this.animations.map(r=>r.attachTimeline(t));return ()=>{n.forEach((r,o)=>{r&&r(),this.animations[o].stop();});}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t);}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t);}get state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){return aD(this.animations,"duration")}get iterationDuration(){return aD(this.animations,"iterationDuration")}runAll(t){this.animations.forEach(n=>n[t]());}play(){this.runAll("play");}pause(){this.runAll("pause");}cancel(){this.runAll("cancel");}complete(){this.runAll("complete");}}function aD(e,t){let n=0;for(let r=0;r<e.length;r++){const o=e[r][t];o!==null&&o>n&&(n=o);}return n}class y0e extends b0e{then(t,n){return this.finished.finally(t).then(()=>{})}}function _V(e,t,n,r=0,o=1){const i=Array.from(e).sort((d,m)=>d.sortNodePosition(m)).indexOf(t),a=e.size,l=(a-1)*r;return typeof n=="function"?n(i,a):o===1?i*r:l-i*r}const S0e=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function C0e(e){const t=S0e.exec(e);if(!t)return [,];const[,n,r,o]=t;return [`--${n??r}`,o]}function BV(e,t,n=1){const[r,o]=C0e(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const a=i.trim();return YH(a)?parseFloat(a):a}return $T(o)?BV(o,t,n+1):o}const x0e={type:"spring",stiffness:500,damping:25,restSpeed:10},w0e=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),$0e={type:"keyframes",duration:.8},E0e={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},M0e=(e,{keyframes:t})=>t.length>2?$0e:jf.has(e)?e.startsWith("scale")?w0e(t[1]):x0e:E0e,R0e=e=>e!==null;function T0e(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(R0e),i=t&&n!=="loop"&&t%2===1?0:o.length-1;return o[i]}function LV(e,t){if(e?.inherit&&t){const{inherit:n,...r}=e;return {...t,...r}}return e}function DT(e,t){const n=e?.[t]??e?.default??e;return n!==e?LV(n,e):n}function A0e({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:i,repeatType:a,repeatDelay:l,from:u,elapsed:d,...m}){return !!Object.keys(m).length}const _T=(e,t,n,r={},o,i)=>a=>{const l=DT(r,e)||{},u=l.delay||r.delay||0;let{elapsed:d=0}=r;d=d-Gi(u);const m={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...l,delay:-d,onUpdate:g=>{t.set(g),l.onUpdate&&l.onUpdate(g);},onComplete:()=>{a(),l.onComplete&&l.onComplete();},name:e,motionValue:t,element:i?void 0:o};A0e(l)||Object.assign(m,M0e(e,m)),m.duration&&(m.duration=Gi(m.duration)),m.repeatDelay&&(m.repeatDelay=Gi(m.repeatDelay)),m.from!==void 0&&(m.keyframes[0]=m.from);let p=false;if((m.type===false||m.duration===0&&!m.repeatDelay)&&(b3(m),m.delay===0&&(p=true)),(Ns.instantAnimations||Ns.skipAnimations||o?.shouldSkipAnimations)&&(p=true,b3(m),m.delay=0),m.allowFlatten=!l.type&&!l.ease,p&&!i&&t.get()!==void 0){const g=T0e(m.keyframes,l);if(g!==void 0){Vn.update(()=>{m.onUpdate(g),m.onComplete();});return}}return l.isSync?new PT(m):new v0e(m)};function sD(e){const t=[{},{}];return e?.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity();}),t}function BT(e,t,n,r){if(typeof t=="function"){const[o,i]=sD(r);t=t(n!==void 0?n:e.custom,o,i);}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[o,i]=sD(r);t=t(n!==void 0?n:e.custom,o,i);}return t}function Yd(e,t,n){const r=e.getProps();return BT(r,t,n!==void 0?n:r.custom,e)}const zV=new Set(["width","height","top","left","right","bottom",...Vf]),lD=30,N0e=e=>!isNaN(parseFloat(e));class P0e{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{const o=Eo.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty();},this.hasAnimated=false,this.setCurrent(t),this.owner=n.owner;}setCurrent(t){this.current=t,this.updatedAt=Eo.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=N0e(this.current));}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt;}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new CT);const r=this.events[t].add(n);return t==="change"?()=>{r(),Vn.read(()=>{this.events.change.getSize()||this.stop();});}:r}clearListeners(){for(const t in this.events)this.events[t].clear();}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n;}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t);}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r;}jump(t,n=true){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect();}dirty(){this.events.change?.notify(this.current);}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t);}removeDependent(t){this.dependents&&this.dependents.delete(t);}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=Eo.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>lD)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,lD);return JH(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=true,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify();}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation();})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation();}isAnimating(){return !!this.animation}clearAnimation(){delete this.animation;}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect();}}function du(e,t){return new P0e(e,t)}const y3=e=>Array.isArray(e);function I0e(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,du(n));}function O0e(e){return y3(e)?e[e.length-1]||0:e}function D0e(e,t){const n=Yd(e,t);let{transitionEnd:r={},transition:o={},...i}=n||{};i={...i,...r};for(const a in i){const l=O0e(i[a]);I0e(e,a,l);}}const zr=e=>!!(e&&e.getVelocity);function _0e(e){return !!(zr(e)&&e.add)}function S3(e,t){const n=e.getValue("willChange");if(_0e(n))return n.add(t);if(!n&&Ns.WillChange){const r=new Ns.WillChange("auto");e.addValue("willChange",r),r.add(t);}}function LT(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const B0e="framerAppearId",kV="data-"+LT(B0e);function FV(e){return e.props[kV]}function L0e({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==true;return t[n]=false,r}function zT(e,t,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:i,transitionEnd:a,...l}=t;const u=e.getDefaultTransition();i=i?LV(i,u):u;const d=i?.reduceMotion;r&&(i=r);const m=[],p=o&&e.animationState&&e.animationState.getState()[o];for(const g in l){const b=e.getValue(g,e.latestValues[g]??null),y=l[g];if(y===void 0||p&&L0e(p,g))continue;const S={delay:n,...DT(i||{},g)},C=b.get();if(C!==void 0&&!b.isAnimating&&!Array.isArray(y)&&y===C&&!S.velocity)continue;let w=false;if(window.MotionHandoffAnimation){const T=FV(e);if(T){const R=window.MotionHandoffAnimation(T,g,Vn);R!==null&&(S.startTime=R,w=true);}}S3(e,g);const $=d??e.shouldReduceMotion;b.start(_T(g,b,y,$&&zV.has(g)?{type:false}:S,e,w));const M=b.animation;M&&m.push(M);}if(a){const g=()=>Vn.update(()=>{a&&D0e(e,a);});m.length?Promise.all(m).then(g):g();}return m}function C3(e,t,n={}){const r=Yd(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:o=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const i=r?()=>Promise.all(zT(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:m,staggerDirection:p}=o;return z0e(e,t,u,d,m,p,n)}:()=>Promise.resolve(),{when:l}=o;if(l){const[u,d]=l==="beforeChildren"?[i,a]:[a,i];return u().then(()=>d())}else return Promise.all([i(),a(n.delay)])}function z0e(e,t,n=0,r=0,o=0,i=1,a){const l=[];for(const u of e.variantChildren)u.notify("AnimationStart",t),l.push(C3(u,t,{...a,delay:n+(typeof r=="function"?0:r)+_V(e.variantChildren,u,r,o,i)}).then(()=>u.notify("AnimationComplete",t)));return Promise.all(l)}function k0e(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const o=t.map(i=>C3(e,i,n));r=Promise.all(o);}else if(typeof t=="string")r=C3(e,t,n);else {const o=typeof t=="function"?Yd(e,t,n.custom):t;r=Promise.all(zT(e,o,n));}return r.then(()=>{e.notify("AnimationComplete",t);})}const F0e={test:e=>e==="auto",parse:e=>e},HV=e=>t=>t.test(e),VV=[Hf,vt,ja,wl,gbe,pbe,F0e],cD=e=>VV.find(HV(e));function H0e(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||QH(e):true}const V0e=new Set(["brightness","contrast","saturate","opacity"]);function j0e(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(ET)||[];if(!r)return e;const o=n.replace(r,"");let i=V0e.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+o+")"}const U0e=/\b([a-z-]*)\(.*?\)/gu,x3={...pa,getAnimatableNone:e=>{const t=e.match(U0e);return t?t.map(j0e).join(" "):e}},w3={...pa,getAnimatableNone:e=>{const t=pa.parse(e);return pa.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},uD={...Hf,transform:Math.round},W0e={rotate:wl,rotateX:wl,rotateY:wl,rotateZ:wl,scale:yb,scaleX:yb,scaleY:yb,scaleZ:yb,skew:wl,skewX:wl,skewY:wl,distance:vt,translateX:vt,translateY:vt,translateZ:vt,x:vt,y:vt,z:vt,perspective:vt,transformPerspective:vt,opacity:Sp,originX:Y8,originY:Y8,originZ:vt},kT={borderWidth:vt,borderTopWidth:vt,borderRightWidth:vt,borderBottomWidth:vt,borderLeftWidth:vt,borderRadius:vt,borderTopLeftRadius:vt,borderTopRightRadius:vt,borderBottomRightRadius:vt,borderBottomLeftRadius:vt,width:vt,maxWidth:vt,height:vt,maxHeight:vt,top:vt,right:vt,bottom:vt,left:vt,inset:vt,insetBlock:vt,insetBlockStart:vt,insetBlockEnd:vt,insetInline:vt,insetInlineStart:vt,insetInlineEnd:vt,padding:vt,paddingTop:vt,paddingRight:vt,paddingBottom:vt,paddingLeft:vt,paddingBlock:vt,paddingBlockStart:vt,paddingBlockEnd:vt,paddingInline:vt,paddingInlineStart:vt,paddingInlineEnd:vt,margin:vt,marginTop:vt,marginRight:vt,marginBottom:vt,marginLeft:vt,marginBlock:vt,marginBlockStart:vt,marginBlockEnd:vt,marginInline:vt,marginInlineStart:vt,marginInlineEnd:vt,fontSize:vt,backgroundPositionX:vt,backgroundPositionY:vt,...W0e,zIndex:uD,fillOpacity:Sp,strokeOpacity:Sp,numOctaves:uD},G0e={...kT,color:Cr,backgroundColor:Cr,outlineColor:Cr,fill:Cr,stroke:Cr,borderColor:Cr,borderTopColor:Cr,borderRightColor:Cr,borderBottomColor:Cr,borderLeftColor:Cr,filter:x3,WebkitFilter:x3,mask:w3,WebkitMask:w3},jV=e=>G0e[e],q0e=new Set([x3,w3]);function UV(e,t){let n=jV(e);return q0e.has(n)||(n=pa),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const K0e=new Set(["auto","none","0"]);function Y0e(e,t,n){let r=0,o;for(;r<e.length&&!o;){const i=e[r];typeof i=="string"&&!K0e.has(i)&&Cp(i).values.length&&(o=e[r]),r++;}if(o&&n)for(const i of t)e[i]=UV(n,o);}class X0e extends IT{constructor(t,n,r,o,i){super(t,n,r,o,i,true);}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let m=0;m<t.length;m++){let p=t[m];if(typeof p=="string"&&(p=p.trim(),$T(p))){const g=BV(p,n.current);g!==void 0&&(t[m]=g),m===t.length-1&&(this.finalKeyframe=p);}}if(this.resolveNoneKeyframes(),!zV.has(r)||t.length!==2)return;const[o,i]=t,a=cD(o),l=cD(i),u=K8(o),d=K8(i);if(u!==d&&Il[r]){this.needsMeasurement=true;return}if(a!==l)if(rD(a)&&rD(l))for(let m=0;m<t.length;m++){const p=t[m];typeof p=="string"&&(t[m]=parseFloat(p));}else Il[r]&&(this.needsMeasurement=true);}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let o=0;o<t.length;o++)(t[o]===null||H0e(t[o]))&&r.push(o);r.length&&Y0e(t,r,n);}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Il[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const o=n[n.length-1];o!==void 0&&t.getValue(r,o).jump(o,false);}measureEndState(){const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const o=t.getValue(n);o&&o.jump(this.measuredOrigin,false);const i=r.length-1,a=r[i];r[i]=Il[n](t.measureViewportBox(),window.getComputedStyle(t.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),this.removedTransforms?.length&&this.removedTransforms.forEach(([l,u])=>{t.getValue(l).set(u);}),this.resolveNoneKeyframes();}}const Q0e=new Set(["opacity","clipPath","filter","transform"]);function FT(e,t,n){if(e==null)return [];if(e instanceof EventTarget)return [e];if(typeof e=="string"){let r=document;t&&(r=t.current);const o=n?.[e]??r.querySelectorAll(e);return o?Array.from(o):[]}return Array.from(e).filter(r=>r!=null)}const WV=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function $3(e){return XH(e)&&"offsetHeight"in e}const{schedule:HT}=fV(queueMicrotask,false),ia={x:false,y:false};function GV(){return ia.x||ia.y}function Z0e(e){return e==="x"||e==="y"?ia[e]?null:(ia[e]=true,()=>{ia[e]=false;}):ia.x||ia.y?null:(ia.x=ia.y=true,()=>{ia.x=ia.y=false;})}function qV(e,t){const n=FT(e),r=new AbortController,o={passive:true,...t,signal:r.signal};return [n,o,()=>r.abort()]}function J0e(e){return !(e.pointerType==="touch"||GV())}function eye(e,t,n={}){const[r,o,i]=qV(e,n);return r.forEach(a=>{let l=false,u=false,d;const m=()=>{a.removeEventListener("pointerleave",y);},p=C=>{d&&(d(C),d=void 0),m();},g=C=>{l=false,window.removeEventListener("pointerup",g),window.removeEventListener("pointercancel",g),u&&(u=false,p(C));},b=()=>{l=true,window.addEventListener("pointerup",g,o),window.addEventListener("pointercancel",g,o);},y=C=>{if(C.pointerType!=="touch"){if(l){u=true;return}p(C);}},S=C=>{if(!J0e(C))return;u=false;const w=t(a,C);typeof w=="function"&&(d=w,a.addEventListener("pointerleave",y,o));};a.addEventListener("pointerenter",S,o),a.addEventListener("pointerdown",b,o);}),i}const KV=(e,t)=>t?e===t?true:KV(e,t.parentElement):false,VT=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==false,tye=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function nye(e){return tye.has(e.tagName)||e.isContentEditable===true}const rye=new Set(["INPUT","SELECT","TEXTAREA"]);function oye(e){return rye.has(e.tagName)||e.isContentEditable===true}const Jb=new WeakSet;function dD(e){return t=>{t.key==="Enter"&&e(t);}}function gw(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:true,bubbles:true}));}const iye=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=dD(()=>{if(Jb.has(n))return;gw(n,"down");const o=dD(()=>{gw(n,"up");}),i=()=>gw(n,"cancel");n.addEventListener("keyup",o,t),n.addEventListener("blur",i,t);});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t);};function fD(e){return VT(e)&&!GV()}const mD=new WeakSet;function aye(e,t,n={}){const[r,o,i]=qV(e,n),a=l=>{const u=l.currentTarget;if(!fD(l)||mD.has(l))return;Jb.add(u),n.stopPropagation&&mD.add(l);const d=t(u,l),m=(b,y)=>{window.removeEventListener("pointerup",p),window.removeEventListener("pointercancel",g),Jb.has(u)&&Jb.delete(u),fD(b)&&typeof d=="function"&&d(b,{success:y});},p=b=>{m(b,u===window||u===document||n.useGlobalTarget||KV(u,b.target));},g=b=>{m(b,false);};window.addEventListener("pointerup",p,o),window.addEventListener("pointercancel",g,o);};return r.forEach(l=>{(n.useGlobalTarget?window:l).addEventListener("pointerdown",a,o),$3(l)&&(l.addEventListener("focus",d=>iye(d,o)),!nye(l)&&!l.hasAttribute("tabindex")&&(l.tabIndex=0));}),i}function w1(e){return XH(e)&&"ownerSVGElement"in e}const e0=new WeakMap;let t0;const YV=(e,t,n)=>(r,o)=>o&&o[0]?o[0][e+"Size"]:w1(r)&&"getBBox"in r?r.getBBox()[t]:r[n],sye=YV("inline","width","offsetWidth"),lye=YV("block","height","offsetHeight");function cye({target:e,borderBoxSize:t}){e0.get(e)?.forEach(n=>{n(e,{get width(){return sye(e,t)},get height(){return lye(e,t)}});});}function uye(e){e.forEach(cye);}function dye(){typeof ResizeObserver>"u"||(t0=new ResizeObserver(uye));}function fye(e,t){t0||dye();const n=FT(e);return n.forEach(r=>{let o=e0.get(r);o||(o=new Set,e0.set(r,o)),o.add(t),t0?.observe(r);}),()=>{n.forEach(r=>{const o=e0.get(r);o?.delete(t),o?.size||t0?.unobserve(r);});}}const n0=new Set;let Ld;function mye(){Ld=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};n0.forEach(t=>t(e));},window.addEventListener("resize",Ld);}function hye(e){return n0.add(e),Ld||mye(),()=>{n0.delete(e),!n0.size&&typeof Ld=="function"&&(window.removeEventListener("resize",Ld),Ld=void 0);}}function hD(e,t){return typeof e=="function"?hye(e):fye(e,t)}function XV(e){return w1(e)&&e.tagName==="svg"}const pye=[...VV,Cr,pa],gye=e=>pye.find(HV(e)),pD=()=>({translate:0,scale:1,origin:0,originPoint:0}),zd=()=>({x:pD(),y:pD()}),gD=()=>({min:0,max:0}),Sr=()=>({x:gD(),y:gD()}),wp=new WeakMap;function $1(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function $p(e){return typeof e=="string"||Array.isArray(e)}const jT=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],UT=["initial",...jT];function E1(e){return $1(e.animate)||UT.some(t=>$p(e[t]))}function QV(e){return !!(E1(e)||e.variants)}function vye(e,t,n){for(const r in t){const o=t[r],i=n[r];if(zr(o))e.addValue(r,o);else if(zr(i))e.addValue(r,du(o,{owner:e}));else if(i!==o)if(e.hasValue(r)){const a=e.getValue(r);a.liveStyle===true?a.jump(o):a.hasAnimated||a.set(o);}else {const a=e.getStaticValue(r);e.addValue(r,du(a!==void 0?a:o,{owner:e}));}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const cy={current:null},WT={current:false},bye=typeof window<"u";function ZV(){if(WT.current=true,!!bye)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>cy.current=e.matches;e.addEventListener("change",t),t();}else cy.current=false;}const vD=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let uy={};function JV(e){uy=e;}function yye(){return uy}class ej{scrapeMotionValuesFromProps(t,n,r){return {}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:o,skipAnimations:i,blockInitialAnimation:a,visualState:l},u={}){this.current=null,this.children=new Set,this.isVariantNode=false,this.isControllingVariants=false,this.shouldReduceMotion=null,this.shouldSkipAnimations=false,this.values=new Map,this.KeyframeResolver=IT,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=false,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection));},this.renderScheduledAt=0,this.scheduleRender=()=>{const b=Eo.now();this.renderScheduledAt<b&&(this.renderScheduledAt=b,Vn.render(this.render,false,true));};const{latestValues:d,renderState:m}=l;this.latestValues=d,this.baseTarget={...d},this.initialValues=n.initial?{...d}:{},this.renderState=m,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.skipAnimationsConfig=i,this.options=u,this.blockInitialAnimation=!!a,this.isControllingVariants=E1(n),this.isVariantNode=QV(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:p,...g}=this.scrapeMotionValuesFromProps(n,{},this);for(const b in g){const y=g[b];d[b]!==void 0&&zr(y)&&y.set(d[b]);}}mount(t){if(this.hasBeenMounted)for(const n in this.initialValues)this.values.get(n)?.jump(this.initialValues[n]),this.latestValues[n]=this.initialValues[n];this.current=t,wp.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=false:this.reducedMotionConfig==="always"?this.shouldReduceMotion=true:(WT.current||ZV(),this.shouldReduceMotion=cy.current),this.shouldSkipAnimations=this.skipAnimationsConfig??false,this.parent?.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=true;}unmount(){this.projection&&this.projection.unmount(),Gl(this.notifyUpdate),Gl(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=false);}this.current=null;}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t);}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t);}bindToMotionValue(t,n){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&Q0e.has(t)&&this.current instanceof HTMLElement){const{factory:a,keyframes:l,times:u,ease:d,duration:m}=n.accelerate,p=new OV({element:this.current,name:t,keyframes:l,times:u,ease:d,duration:Gi(m)}),g=a(p);this.valueSubscriptions.set(t,()=>{g(),p.cancel();});return}const r=jf.has(t);r&&this.onBindTransform&&this.onBindTransform();const o=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&Vn.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=true),this.scheduleRender();});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{o(),i&&i(),n.owner&&n.stop();});}sortNodePosition(t){return !this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in uy){const n=uy[t];if(!n)continue;const{isEnabled:r,Feature:o}=n;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=true);}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props);}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Sr()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n;}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<vD.length;r++){const o=vD[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const i="on"+o,a=t[i];a&&(this.propEventSubscriptions[o]=this.on(o,a));}this.prevMotionValues=vye(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue();}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get());}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState);}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=du(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(YH(r)||QH(r))?r=parseFloat(r):!gye(r)&&pa.test(n)&&(r=UV(t,n)),this.setBaseTarget(t,zr(r)?r.get():r)),zr(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n;}getBaseTarget(t){const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const i=BT(this.props,n,this.presenceContext?.custom);i&&(r=i[t]);}if(n&&r!==void 0)return r;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!zr(o)?o:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new CT),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n);}scheduleRenderMicrotask(){HT.render(this.render);}}class tj extends ej{constructor(){super(...arguments),this.KeyframeResolver=X0e;}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t];}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;zr(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`);}));}}class rc{constructor(t){this.isMounted=false,this.node=t;}update(){}}function nj({top:e,left:t,right:n,bottom:r}){return {x:{min:t,max:n},y:{min:e,max:r}}}function Sye({x:e,y:t}){return {top:t.min,right:e.max,bottom:t.max,left:e.min}}function Cye(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return {top:n.y,left:n.x,bottom:r.y,right:r.x}}function vw(e){return e===void 0||e===1}function E3({scale:e,scaleX:t,scaleY:n}){return !vw(e)||!vw(t)||!vw(n)}function _c(e){return E3(e)||rj(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function rj(e){return bD(e.x)||bD(e.y)}function bD(e){return e&&e!=="0%"}function dy(e,t,n){const r=e-n,o=t*r;return n+o}function yD(e,t,n,r,o){return o!==void 0&&(e=dy(e,o,r)),dy(e,n,r)+t}function M3(e,t=0,n=1,r,o){e.min=yD(e.min,t,n,r,o),e.max=yD(e.max,t,n,r,o);}function oj(e,{x:t,y:n}){M3(e.x,t.translate,t.scale,t.originPoint),M3(e.y,n.translate,n.scale,n.originPoint);}const SD=.999999999999,CD=1.0000000000001;function xye(e,t,n,r=false){const o=n.length;if(!o)return;t.x=t.y=1;let i,a;for(let l=0;l<o;l++){i=n[l],a=i.projectionDelta;const{visualElement:u}=i.options;u&&u.props.style&&u.props.style.display==="contents"||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&Fd(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,oj(e,a)),r&&_c(i.latestValues)&&Fd(e,i.latestValues));}t.x<CD&&t.x>SD&&(t.x=1),t.y<CD&&t.y>SD&&(t.y=1);}function kd(e,t){e.min=e.min+t,e.max=e.max+t;}function xD(e,t,n,r,o=.5){const i=er(e.min,e.max,o);M3(e,t,n,i,r);}function Fd(e,t){xD(e.x,t.x,t.scaleX,t.scale,t.originX),xD(e.y,t.y,t.scaleY,t.scale,t.originY);}function ij(e,t){return nj(Cye(e.getBoundingClientRect(),t))}function wye(e,t,n){const r=ij(e,n),{scroll:o}=t;return o&&(kd(r.x,o.offset.x),kd(r.y,o.offset.y)),r}const $ye={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Eye=Vf.length;function Mye(e,t,n){let r="",o=true;for(let i=0;i<Eye;i++){const a=Vf[i],l=e[a];if(l===void 0)continue;let u=true;if(typeof l=="number")u=l===(a.startsWith("scale")?1:0);else {const d=parseFloat(l);u=a.startsWith("scale")?d===1:d===0;}if(!u||n){const d=WV(l,kT[a]);if(!u){o=false;const m=$ye[a]||a;r+=`${m}(${d}) `;}n&&(t[a]=d);}}return r=r.trim(),n?r=n(t,o?"":r):o&&(r="none"),r}function GT(e,t,n){const{style:r,vars:o,transformOrigin:i}=e;let a=false,l=false;for(const u in t){const d=t[u];if(jf.has(u)){a=true;continue}else if(hV(u)){o[u]=d;continue}else {const m=WV(d,kT[u]);u.startsWith("origin")?(l=true,i[u]=m):r[u]=m;}}if(t.transform||(a||n?r.transform=Mye(t,e.transform,n):r.transform&&(r.transform="none")),l){const{originX:u="50%",originY:d="50%",originZ:m=0}=i;r.transformOrigin=`${u} ${d} ${m}`;}}function aj(e,{style:t,vars:n},r,o){const i=e.style;let a;for(a in t)i[a]=t[a];o?.applyProjectionStyles(i,r);for(a in n)i.setProperty(a,n[a]);}function wD(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const nh={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(vt.test(e))e=parseFloat(e);else return e;const n=wD(e,t.target.x),r=wD(e,t.target.y);return `${n}% ${r}%`}},Rye={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=pa.parse(e);if(o.length>5)return r;const i=pa.createTransformer(e),a=typeof o[0]!="number"?1:0,l=n.x.scale*t.x,u=n.y.scale*t.y;o[0+a]/=l,o[1+a]/=u;const d=er(l,u,.5);return typeof o[2+a]=="number"&&(o[2+a]/=d),typeof o[3+a]=="number"&&(o[3+a]/=d),i(o)}},R3={borderRadius:{...nh,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:nh,borderTopRightRadius:nh,borderBottomLeftRadius:nh,borderBottomRightRadius:nh,boxShadow:Rye};function sj(e,{layout:t,layoutId:n}){return jf.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!R3[e]||e==="opacity")}function qT(e,t,n){const r=e.style,o=t?.style,i={};if(!r)return i;for(const a in r)(zr(r[a])||o&&zr(o[a])||sj(a,e)||n?.getValue(a)?.liveStyle!==void 0)&&(i[a]=r[a]);return i}function Tye(e){return window.getComputedStyle(e)}class lj extends tj{constructor(){super(...arguments),this.type="html",this.renderInstance=aj;}readValueFromInstance(t,n){if(jf.has(n))return this.projection?.isProjecting?m3(n):Xbe(t,n);{const r=Tye(t),o=(hV(n)?r.getPropertyValue(n):r[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return ij(t,n)}build(t,n,r){GT(t,n,r.transformTemplate);}scrapeMotionValuesFromProps(t,n,r){return qT(t,n,r)}}function Aye(e,t){return e in t}class Nye extends ej{constructor(){super(...arguments),this.type="object";}readValueFromInstance(t,n){if(Aye(n,t)){const r=t[n];if(typeof r=="string"||typeof r=="number")return r}}getBaseTargetFromProps(){}removeValueFromRenderState(t,n){delete n.output[t];}measureInstanceViewportBox(){return Sr()}build(t,n){Object.assign(t.output,n);}renderInstance(t,{output:n}){Object.assign(t,n);}sortInstanceNodePosition(){return 0}}const Pye={offset:"stroke-dashoffset",array:"stroke-dasharray"},Iye={offset:"strokeDashoffset",array:"strokeDasharray"};function Oye(e,t,n=1,r=0,o=true){e.pathLength=1;const i=o?Pye:Iye;e[i.offset]=`${-r}`,e[i.array]=`${t} ${n}`;}const Dye=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function cj(e,{attrX:t,attrY:n,attrScale:r,pathLength:o,pathSpacing:i=1,pathOffset:a=0,...l},u,d,m){if(GT(e,l,d),u){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:p,style:g}=e;p.transform&&(g.transform=p.transform,delete p.transform),(g.transform||p.transformOrigin)&&(g.transformOrigin=p.transformOrigin??"50% 50%",delete p.transformOrigin),g.transform&&(g.transformBox=m?.transformBox??"fill-box",delete p.transformBox);for(const b of Dye)p[b]!==void 0&&(g[b]=p[b],delete p[b]);t!==void 0&&(p.x=t),n!==void 0&&(p.y=n),r!==void 0&&(p.scale=r),o!==void 0&&Oye(p,o,i,a,false);}const uj=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),dj=e=>typeof e=="string"&&e.toLowerCase()==="svg";function _ye(e,t,n,r){aj(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(uj.has(o)?o:LT(o),t.attrs[o]);}function fj(e,t,n){const r=qT(e,t,n);for(const o in e)if(zr(e[o])||zr(t[o])){const i=Vf.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[i]=e[o];}return r}class mj extends tj{constructor(){super(...arguments),this.type="svg",this.isSVGTag=false,this.measureInstanceViewportBox=Sr;}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(jf.has(n)){const r=jV(n);return r&&r.default||0}return n=uj.has(n)?n:LT(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return fj(t,n,r)}build(t,n,r){cj(t,n,this.isSVGTag,r.transformTemplate,r.style);}renderInstance(t,n,r,o){_ye(t,n,r,o);}mount(t){this.isSVGTag=dj(t.tagName),super.mount(t);}}const Bye=UT.length;function hj(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?hj(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<Bye;n++){const r=UT[n],o=e.props[r];($p(o)||o===false)&&(t[r]=o);}return t}function pj(e,t){if(!Array.isArray(t))return false;const n=t.length;if(n!==e.length)return false;for(let r=0;r<n;r++)if(t[r]!==e[r])return false;return true}const Lye=[...jT].reverse(),zye=jT.length;function kye(e){return t=>Promise.all(t.map(({animation:n,options:r})=>k0e(e,n,r)))}function Fye(e){let t=kye(e),n=$D(),r=true;const o=u=>(d,m)=>{const p=Yd(e,m,u==="exit"?e.presenceContext?.custom:void 0);if(p){const{transition:g,transitionEnd:b,...y}=p;d={...d,...y,...b};}return d};function i(u){t=u(e);}function a(u){const{props:d}=e,m=hj(e.parent)||{},p=[],g=new Set;let b={},y=1/0;for(let C=0;C<zye;C++){const w=Lye[C],$=n[w],M=d[w]!==void 0?d[w]:m[w],T=$p(M),R=w===u?$.isActive:null;R===false&&(y=C);let I=M===m[w]&&M!==d[w]&&T;if(I&&r&&e.manuallyAnimateOnMount&&(I=false),$.protectedKeys={...b},!$.isActive&&R===null||!M&&!$.prevProp||$1(M)||typeof M=="boolean")continue;if(w==="exit"&&$.isActive&&R!==true){$.prevResolvedValues&&(b={...b,...$.prevResolvedValues});continue}const N=Hye($.prevProp,M);let P=N||w===u&&$.isActive&&!I&&T||C>y&&T,O=false;const _=Array.isArray(M)?M:[M];let B=_.reduce(o(w),{});R===false&&(B={});const{prevResolvedValues:V={}}=$,U={...V,...B},G=j=>{P=true,g.has(j)&&(O=true,g.delete(j)),$.needsAnimating[j]=true;const W=e.getValue(j);W&&(W.liveStyle=false);};for(const j in U){const W=B[j],Y=V[j];if(b.hasOwnProperty(j))continue;let Q=false;y3(W)&&y3(Y)?Q=!pj(W,Y):Q=W!==Y,Q?W!=null?G(j):g.add(j):W!==void 0&&g.has(j)?G(j):$.protectedKeys[j]=true;}$.prevProp=M,$.prevResolvedValues=B,$.isActive&&(b={...b,...B}),r&&e.blockInitialAnimation&&(P=false);const H=I&&N;P&&(!H||O)&&p.push(..._.map(j=>{const W={type:w};if(typeof j=="string"&&r&&!H&&e.manuallyAnimateOnMount&&e.parent){const{parent:Y}=e,Q=Yd(Y,j);if(Y.enteringChildren&&Q){const{delayChildren:D}=Q.transition||{};W.delay=_V(Y.enteringChildren,e,D);}}return {animation:j,options:W}}));}if(g.size){const C={};if(typeof d.initial!="boolean"){const w=Yd(e,Array.isArray(d.initial)?d.initial[0]:d.initial);w&&w.transition&&(C.transition=w.transition);}g.forEach(w=>{const $=e.getBaseTarget(w),M=e.getValue(w);M&&(M.liveStyle=true),C[w]=$??null;}),p.push({animation:C});}let S=!!p.length;return r&&(d.initial===false||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(S=false),r=false,S?t(p):Promise.resolve()}function l(u,d){if(n[u].isActive===d)return Promise.resolve();e.variantChildren?.forEach(p=>p.animationState?.setActive(u,d)),n[u].isActive=d;const m=a(u);for(const p in n)n[p].protectedKeys={};return m}return {animateChanges:a,setActive:l,setAnimateFunction:i,getState:()=>n,reset:()=>{n=$D();}}}function Hye(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!pj(t,e):false}function Ac(e=false){return {isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function $D(){return {animate:Ac(true),whileInView:Ac(),whileHover:Ac(),whileTap:Ac(),whileDrag:Ac(),whileFocus:Ac(),exit:Ac()}}function ED(e,t){e.min=t.min,e.max=t.max;}function ta(e,t){ED(e.x,t.x),ED(e.y,t.y);}function MD(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin;}const gj=1e-4,Vye=1-gj,jye=1+gj,vj=.01,Uye=0-vj,Wye=0+vj;function Mo(e){return e.max-e.min}function Gye(e,t,n){return Math.abs(e-t)<=n}function RD(e,t,n,r=.5){e.origin=r,e.originPoint=er(t.min,t.max,e.origin),e.scale=Mo(n)/Mo(t),e.translate=er(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Vye&&e.scale<=jye||isNaN(e.scale))&&(e.scale=1),(e.translate>=Uye&&e.translate<=Wye||isNaN(e.translate))&&(e.translate=0);}function Fh(e,t,n,r){RD(e.x,t.x,n.x,r?r.originX:void 0),RD(e.y,t.y,n.y,r?r.originY:void 0);}function TD(e,t,n){e.min=n.min+t.min,e.max=e.min+Mo(t);}function qye(e,t,n){TD(e.x,t.x,n.x),TD(e.y,t.y,n.y);}function AD(e,t,n){e.min=t.min-n.min,e.max=e.min+Mo(t);}function fy(e,t,n){AD(e.x,t.x,n.x),AD(e.y,t.y,n.y);}function ND(e,t,n,r,o){return e-=t,e=dy(e,1/n,r),o!==void 0&&(e=dy(e,1/o,r)),e}function Kye(e,t=0,n=1,r=.5,o,i=e,a=e){if(ja.test(t)&&(t=parseFloat(t),t=er(a.min,a.max,t/100)-a.min),typeof t!="number")return;let l=er(i.min,i.max,r);e===i&&(l-=t),e.min=ND(e.min,t,n,l,o),e.max=ND(e.max,t,n,l,o);}function PD(e,t,[n,r,o],i,a){Kye(e,t[n],t[r],t[o],t.scale,i,a);}const Yye=["x","scaleX","originX"],Xye=["y","scaleY","originY"];function ID(e,t,n,r){PD(e.x,t,Yye,n?n.x:void 0,r?r.x:void 0),PD(e.y,t,Xye,n?n.y:void 0,r?r.y:void 0);}function OD(e){return e.translate===0&&e.scale===1}function bj(e){return OD(e.x)&&OD(e.y)}function DD(e,t){return e.min===t.min&&e.max===t.max}function Qye(e,t){return DD(e.x,t.x)&&DD(e.y,t.y)}function _D(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function yj(e,t){return _D(e.x,t.x)&&_D(e.y,t.y)}function BD(e){return Mo(e.x)/Mo(e.y)}function LD(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Oa(e){return [e("x"),e("y")]}function Zye(e,t,n){let r="";const o=e.x.translate/t.x,i=e.y.translate/t.y,a=n?.z||0;if((o||i||a)&&(r=`translate3d(${o}px, ${i}px, ${a}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:d,rotate:m,rotateX:p,rotateY:g,skewX:b,skewY:y}=n;d&&(r=`perspective(${d}px) ${r}`),m&&(r+=`rotate(${m}deg) `),p&&(r+=`rotateX(${p}deg) `),g&&(r+=`rotateY(${g}deg) `),b&&(r+=`skewX(${b}deg) `),y&&(r+=`skewY(${y}deg) `);}const l=e.x.scale*t.x,u=e.y.scale*t.y;return (l!==1||u!==1)&&(r+=`scale(${l}, ${u})`),r||"none"}const Sj=["TopLeft","TopRight","BottomLeft","BottomRight"],Jye=Sj.length,zD=e=>typeof e=="string"?parseFloat(e):e,kD=e=>typeof e=="number"||vt.test(e);function e1e(e,t,n,r,o,i){o?(e.opacity=er(0,n.opacity??1,t1e(r)),e.opacityExit=er(t.opacity??1,0,n1e(r))):i&&(e.opacity=er(t.opacity??1,n.opacity??1,r));for(let a=0;a<Jye;a++){const l=`border${Sj[a]}Radius`;let u=FD(t,l),d=FD(n,l);if(u===void 0&&d===void 0)continue;u||(u=0),d||(d=0),u===0||d===0||kD(u)===kD(d)?(e[l]=Math.max(er(zD(u),zD(d),r),0),(ja.test(d)||ja.test(u))&&(e[l]+="%")):e[l]=d;}(t.rotate||n.rotate)&&(e.rotate=er(t.rotate||0,n.rotate||0,r));}function FD(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const t1e=Cj(0,.5,aV),n1e=Cj(.5,.95,Wi);function Cj(e,t,n){return r=>r<e?0:r>t?1:n(hf(e,t,r))}function xj(e,t,n){const r=zr(e)?e:du(e);return r.start(_T("",r,t,n)),r.animation}function Ep(e,t,n,r={passive:true}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const r1e=(e,t)=>e.depth-t.depth;class o1e{constructor(){this.children=[],this.isDirty=false;}add(t){yT(this.children,t),this.isDirty=true;}remove(t){mf(this.children,t),this.isDirty=true;}forEach(t){this.isDirty&&this.children.sort(r1e),this.isDirty=false,this.children.forEach(t);}}function i1e(e,t){const n=Eo.now(),r=({timestamp:o})=>{const i=o-n;i>=t&&(Gl(r),e(i-t));};return Vn.setup(r,true),()=>Gl(r)}function r0(e){return zr(e)?e.get():e}class a1e{constructor(){this.members=[];}add(t){yT(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const o=r.instance;o&&o.isConnected===false&&r.isPresent!==false&&!r.snapshot&&mf(this.members,r);}t.scheduleRender();}remove(t){if(mf(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n);}}relegate(t){const n=this.members.findIndex(o=>t===o);if(n===0)return false;let r;for(let o=n;o>=0;o--){const i=this.members[o],a=i.instance;if(i.isPresent!==false&&(!a||a.isConnected!==false)){r=i;break}}return r?(this.promote(r),true):false}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender();const o=r.options.layoutDependency,i=t.options.layoutDependency;if(!(o!==void 0&&i!==void 0&&o===i)){const u=r.instance;u&&u.isConnected===false&&!r.snapshot||(t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=true),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=true));}const{crossfade:l}=t.options;l===false&&r.hide();}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete();});}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(false);});}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0);}}const o0={hasAnimatedSinceResize:true,hasEverUpdated:false},bw=["","X","Y","Z"],s1e=1e3;let l1e=0;function yw(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0));}function wj(e){if(e.hasCheckedOptimisedAppear=true,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=FV(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:o,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Vn,!(o||i));}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&wj(r);}function $j({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(a={},l=t?.()){this.id=l1e++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=false,this.isAnimationBlocked=false,this.isLayoutDirty=false,this.isProjectionDirty=false,this.isSharedProjectionDirty=false,this.isTransformDirty=false,this.updateManuallyBlocked=false,this.updateBlockedByResize=false,this.isUpdating=false,this.isSVG=false,this.needsReset=false,this.shouldResetTransform=false,this.hasCheckedOptimisedAppear=false,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=false,this.layoutVersion=0,this.updateScheduled=false,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=false,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=false,this.clearAllSnapshots());},this.updateProjection=()=>{this.projectionUpdateScheduled=false,this.nodes.forEach(d1e),this.nodes.forEach(p1e),this.nodes.forEach(g1e),this.nodes.forEach(f1e);},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=false,this.isVisible=true,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=true;this.root===this&&(this.nodes=new o1e);}addEventListener(a,l){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new CT),this.eventHandlers.get(a).add(l)}notifyListeners(a,...l){const u=this.eventHandlers.get(a);u&&u.notify(...l);}hasListeners(a){return this.eventHandlers.has(a)}mount(a){if(this.instance)return;this.isSVG=w1(a)&&!XV(a),this.instance=a;const{layoutId:l,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(u||l)&&(this.isLayoutDirty=true),e){let m,p=0;const g=()=>this.root.updateBlockedByResize=false;Vn.read(()=>{p=window.innerWidth;}),e(a,()=>{const b=window.innerWidth;b!==p&&(p=b,this.root.updateBlockedByResize=true,m&&m(),m=i1e(g,250),o0.hasAnimatedSinceResize&&(o0.hasAnimatedSinceResize=false,this.nodes.forEach(jD)));});}l&&this.root.registerSharedNode(l,this),this.options.animate!==false&&d&&(l||u)&&this.addEventListener("didUpdate",({delta:m,hasLayoutChanged:p,hasRelativeLayoutChanged:g,layout:b})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const y=this.options.transition||d.getDefaultTransition()||C1e,{onLayoutAnimationStart:S,onLayoutAnimationComplete:C}=d.getProps(),w=!this.targetLayout||!yj(this.targetLayout,b),$=!p&&g;if(this.options.layoutRoot||this.resumeFrom||$||p&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const M={...DT(y,"layout"),onPlay:S,onComplete:C};(d.shouldReduceMotion||this.options.layoutRoot)&&(M.delay=0,M.type=false),this.startAnimation(M),this.setAnimationOrigin(m,$);}else p||jD(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=b;});}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Gl(this.updateProjection);}blockUpdate(){this.updateManuallyBlocked=true;}unblockUpdate(){this.updateManuallyBlocked=false;}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||false}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=true,this.nodes&&this.nodes.forEach(v1e),this.animationId++);}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=true){if(this.root.hasTreeAnimated=true,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&wj(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=true;for(let m=0;m<this.path.length;m++){const p=this.path[m];p.shouldResetTransform=true,p.updateScroll("snapshot"),p.options.layoutRoot&&p.willUpdate(false);}const{layoutId:l,layout:u}=this.options;if(l===void 0&&!u)return;const d=this.getTransformTemplate();this.prevTransformTemplateValue=d?d(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate");}update(){if(this.updateScheduled=false,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(HD);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(VD);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=false,this.nodes.forEach(h1e),this.nodes.forEach(c1e),this.nodes.forEach(u1e)):this.nodes.forEach(VD),this.clearAllSnapshots();const l=Eo.now();Xr.delta=qa(0,1e3/60,l-Xr.timestamp),Xr.timestamp=l,Xr.isProcessing=true,uw.update.process(Xr),uw.preRender.process(Xr),uw.render.process(Xr),Xr.isProcessing=false;}didUpdate(){this.updateScheduled||(this.updateScheduled=true,HT.read(this.scheduleUpdate));}clearAllSnapshots(){this.nodes.forEach(m1e),this.sharedNodes.forEach(b1e);}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=true,Vn.preRender(this.updateProjection,false,true));}scheduleCheckAfterUnmount(){Vn.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed();});}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Mo(this.snapshot.measuredBox.x)&&!Mo(this.snapshot.measuredBox.y)&&(this.snapshot=void 0));}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();const a=this.layout;this.layout=this.measure(false),this.layoutVersion++,this.layoutCorrected=Sr(),this.isLayoutDirty=false,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:l}=this.options;l&&l.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0);}updateScroll(a="measure"){let l=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(l=false),l&&this.instance){const u=r(this.instance);this.scroll={animationId:this.root.animationId,phase:a,isRoot:u,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:u};}}resetTransform(){if(!o)return;const a=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,l=this.projectionDelta&&!bj(this.projectionDelta),u=this.getTransformTemplate(),d=u?u(this.latestValues,""):void 0,m=d!==this.prevTransformTemplateValue;a&&this.instance&&(l||_c(this.latestValues)||m)&&(o(this.instance,d),this.shouldResetTransform=false,this.scheduleRender());}measure(a=true){const l=this.measurePageBox();let u=this.removeElementScroll(l);return a&&(u=this.removeTransform(u)),x1e(u),{animationId:this.root.animationId,measuredBox:l,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:a}=this.options;if(!a)return Sr();const l=a.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(w1e))){const{scroll:d}=this.root;d&&(kd(l.x,d.offset.x),kd(l.y,d.offset.y));}return l}removeElementScroll(a){const l=Sr();if(ta(l,a),this.scroll?.wasRoot)return l;for(let u=0;u<this.path.length;u++){const d=this.path[u],{scroll:m,options:p}=d;d!==this.root&&m&&p.layoutScroll&&(m.wasRoot&&ta(l,a),kd(l.x,m.offset.x),kd(l.y,m.offset.y));}return l}applyTransform(a,l=false){const u=Sr();ta(u,a);for(let d=0;d<this.path.length;d++){const m=this.path[d];!l&&m.options.layoutScroll&&m.scroll&&m!==m.root&&Fd(u,{x:-m.scroll.offset.x,y:-m.scroll.offset.y}),_c(m.latestValues)&&Fd(u,m.latestValues);}return _c(this.latestValues)&&Fd(u,this.latestValues),u}removeTransform(a){const l=Sr();ta(l,a);for(let u=0;u<this.path.length;u++){const d=this.path[u];if(!d.instance||!_c(d.latestValues))continue;E3(d.latestValues)&&d.updateSnapshot();const m=Sr(),p=d.measurePageBox();ta(m,p),ID(l,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,m);}return _c(this.latestValues)&&ID(l,this.latestValues),l}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=true;}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:true};}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=false;}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Xr.timestamp&&this.relativeParent.resolveTargetDelta(true);}resolveTargetDelta(a=false){const l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);const u=!!this.resumingFrom||this!==l;if(!(a||u&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:m,layoutId:p}=this.options;if(!this.layout||!(m||p))return;this.resolvedRelativeTargetAt=Xr.timestamp;const g=this.getClosestProjectingParent();g&&this.linkedParentVersion!==g.layoutVersion&&!g.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(g&&g.layout?this.createRelativeTarget(g,this.layout.layoutBox,g.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Sr(),this.targetWithTransforms=Sr()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),qye(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):ta(this.target,this.layout.layoutBox),oj(this.target,this.targetDelta)):ta(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=false,g&&!!g.resumingFrom==!!this.resumingFrom&&!g.options.layoutScroll&&g.target&&this.animationProgress!==1?this.createRelativeTarget(g,this.target,g.target):this.relativeParent=this.relativeTarget=void 0));}getClosestProjectingParent(){if(!(!this.parent||E3(this.parent.latestValues)||rj(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return !!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(a,l,u){this.relativeParent=a,this.linkedParentVersion=a.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Sr(),this.relativeTargetOrigin=Sr(),fy(this.relativeTargetOrigin,l,u),ta(this.relativeTarget,this.relativeTargetOrigin);}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0;}calcProjection(){const a=this.getLead(),l=!!this.resumingFrom||this!==a;let u=true;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(u=false),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=false),this.resolvedRelativeTargetAt===Xr.timestamp&&(u=false),u)return;const{layout:d,layoutId:m}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||m))return;ta(this.layoutCorrected,this.layout.layoutBox);const p=this.treeScale.x,g=this.treeScale.y;xye(this.layoutCorrected,this.treeScale,this.path,l),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=Sr());const{target:b}=a;if(!b){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(MD(this.prevProjectionDelta.x,this.projectionDelta.x),MD(this.prevProjectionDelta.y,this.projectionDelta.y)),Fh(this.projectionDelta,this.layoutCorrected,b,this.latestValues),(this.treeScale.x!==p||this.treeScale.y!==g||!LD(this.projectionDelta.x,this.prevProjectionDelta.x)||!LD(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=true,this.scheduleRender(),this.notifyListeners("projectionUpdate",b));}hide(){this.isVisible=false;}show(){this.isVisible=true;}scheduleRender(a=true){if(this.options.visualElement?.scheduleRender(),a){const l=this.getStack();l&&l.scheduleRender();}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0);}createProjectionDeltas(){this.prevProjectionDelta=zd(),this.projectionDelta=zd(),this.projectionDeltaWithTransform=zd();}setAnimationOrigin(a,l=false){const u=this.snapshot,d=u?u.latestValues:{},m={...this.latestValues},p=zd();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!l;const g=Sr(),b=u?u.source:void 0,y=this.layout?this.layout.source:void 0,S=b!==y,C=this.getStack(),w=!C||C.members.length<=1,$=!!(S&&!w&&this.options.crossfade===true&&!this.path.some(S1e));this.animationProgress=0;let M;this.mixTargetDelta=T=>{const R=T/1e3;UD(p.x,a.x,R),UD(p.y,a.y,R),this.setTargetDelta(p),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(fy(g,this.layout.layoutBox,this.relativeParent.layout.layoutBox),y1e(this.relativeTarget,this.relativeTargetOrigin,g,R),M&&Qye(this.relativeTarget,M)&&(this.isProjectionDirty=false),M||(M=Sr()),ta(M,this.relativeTarget)),S&&(this.animationValues=m,e1e(m,d,this.latestValues,R,$,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=R;},this.mixTargetDelta(this.options.layoutRoot?1e3:0);}startAnimation(a){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Gl(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Vn.update(()=>{o0.hasAnimatedSinceResize=true,this.motionValue||(this.motionValue=du(0)),this.motionValue.jump(0,false),this.currentAnimation=xj(this.motionValue,[0,1e3],{...a,velocity:0,isSync:true,onUpdate:l=>{this.mixTargetDelta(l),a.onUpdate&&a.onUpdate(l);},onStop:()=>{},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation();}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0;});}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete");}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(s1e),this.currentAnimation.stop()),this.completeAnimation();}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:l,target:u,layout:d,latestValues:m}=a;if(!(!l||!u||!d)){if(this!==a&&this.layout&&d&&Ej(this.options.animationType,this.layout.layoutBox,d.layoutBox)){u=this.target||Sr();const p=Mo(this.layout.layoutBox.x);u.x.min=a.target.x.min,u.x.max=u.x.min+p;const g=Mo(this.layout.layoutBox.y);u.y.min=a.target.y.min,u.y.max=u.y.min+g;}ta(l,u),Fd(l,m),Fh(this.projectionDeltaWithTransform,this.layoutCorrected,l,m);}}registerSharedNode(a,l){this.sharedNodes.has(a)||this.sharedNodes.set(a,new a1e),this.sharedNodes.get(a).add(l);const d=l.options.initialPromotionConfig;l.promote({transition:d?d.transition:void 0,preserveFollowOpacity:d&&d.shouldPreserveFollowOpacity?d.shouldPreserveFollowOpacity(l):void 0});}isLead(){const a=this.getStack();return a?a.lead===this:true}getLead(){const{layoutId:a}=this.options;return a?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:a}=this.options;return a?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:l,preserveFollowOpacity:u}={}){const d=this.getStack();d&&d.promote(this,u),a&&(this.projectionDelta=void 0,this.needsReset=true),l&&this.setOptions({transition:l});}relegate(){const a=this.getStack();return a?a.relegate(this):false}resetSkewAndRotation(){const{visualElement:a}=this.options;if(!a)return;let l=false;const{latestValues:u}=a;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(l=true),!l)return;const d={};u.z&&yw("z",a,d,this.animationValues);for(let m=0;m<bw.length;m++)yw(`rotate${bw[m]}`,a,d,this.animationValues),yw(`skew${bw[m]}`,a,d,this.animationValues);a.render();for(const m in d)a.setStaticValue(m,d[m]),this.animationValues&&(this.animationValues[m]=d[m]);a.scheduleRender();}applyProjectionStyles(a,l){if(!this.instance||this.isSVG)return;if(!this.isVisible){a.visibility="hidden";return}const u=this.getTransformTemplate();if(this.needsReset){this.needsReset=false,a.visibility="",a.opacity="",a.pointerEvents=r0(l?.pointerEvents)||"",a.transform=u?u(this.latestValues,""):"none";return}const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){this.options.layoutId&&(a.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,a.pointerEvents=r0(l?.pointerEvents)||""),this.hasProjected&&!_c(this.latestValues)&&(a.transform=u?u({},""):"none",this.hasProjected=false);return}a.visibility="";const m=d.animationValues||d.latestValues;this.applyTransformsToTarget();let p=Zye(this.projectionDeltaWithTransform,this.treeScale,m);u&&(p=u(m,p)),a.transform=p;const{x:g,y:b}=this.projectionDelta;a.transformOrigin=`${g.origin*100}% ${b.origin*100}% 0`,d.animationValues?a.opacity=d===this?m.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:m.opacityExit:a.opacity=d===this?m.opacity!==void 0?m.opacity:"":m.opacityExit!==void 0?m.opacityExit:0;for(const y in R3){if(m[y]===void 0)continue;const{correct:S,applyTo:C,isCSSVariable:w}=R3[y],$=p==="none"?m[y]:S(m[y],d);if(C){const M=C.length;for(let T=0;T<M;T++)a[C[T]]=$;}else w?this.options.visualElement.renderState.vars[y]=$:a[y]=$;}this.options.layoutId&&(a.pointerEvents=d===this?r0(l?.pointerEvents)||"":"none");}clearSnapshot(){this.resumeFrom=this.snapshot=void 0;}resetTree(){this.root.nodes.forEach(a=>a.currentAnimation?.stop()),this.root.nodes.forEach(HD),this.root.sharedNodes.clear();}}}function c1e(e){e.updateLayout();}function u1e(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:r}=e.layout,{animationType:o}=e.options,i=t.source!==e.layout.source;o==="size"?Oa(m=>{const p=i?t.measuredBox[m]:t.layoutBox[m],g=Mo(p);p.min=n[m].min,p.max=p.min+g;}):Ej(o,t.layoutBox,n)&&Oa(m=>{const p=i?t.measuredBox[m]:t.layoutBox[m],g=Mo(n[m]);p.max=p.min+g,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=true,e.relativeTarget[m].max=e.relativeTarget[m].min+g);});const a=zd();Fh(a,n,t.layoutBox);const l=zd();i?Fh(l,e.applyTransform(r,true),t.measuredBox):Fh(l,n,t.layoutBox);const u=!bj(a);let d=false;if(!e.resumeFrom){const m=e.getClosestProjectingParent();if(m&&!m.resumeFrom){const{snapshot:p,layout:g}=m;if(p&&g){const b=Sr();fy(b,t.layoutBox,p.layoutBox);const y=Sr();fy(y,n,g.layoutBox),yj(b,y)||(d=true),m.options.layoutRoot&&(e.relativeTarget=y,e.relativeTargetOrigin=b,e.relativeParent=m);}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:d});}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n();}e.options.transition=void 0;}function d1e(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty));}function f1e(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=false;}function m1e(e){e.clearSnapshot();}function HD(e){e.clearMeasurements();}function VD(e){e.isLayoutDirty=false;}function h1e(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform();}function jD(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=true;}function p1e(e){e.resolveTargetDelta();}function g1e(e){e.calcProjection();}function v1e(e){e.resetSkewAndRotation();}function b1e(e){e.removeLeadSnapshot();}function UD(e,t,n){e.translate=er(t.translate,0,n),e.scale=er(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint;}function WD(e,t,n,r){e.min=er(t.min,n.min,r),e.max=er(t.max,n.max,r);}function y1e(e,t,n,r){WD(e.x,t.x,n.x,r),WD(e.y,t.y,n.y,r);}function S1e(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const C1e={duration:.45,ease:[.4,0,.1,1]},GD=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),qD=GD("applewebkit/")&&!GD("chrome/")?Math.round:Wi;function KD(e){e.min=qD(e.min),e.max=qD(e.max);}function x1e(e){KD(e.x),KD(e.y);}function Ej(e,t,n){return e==="position"||e==="preserve-aspect"&&!Gye(BD(t),BD(n),.2)}function w1e(e){return e!==e.root&&e.scroll?.wasRoot}const $1e=$j({attachResizeListener:(e,t)=>Ep(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body?.scrollLeft||0,y:document.documentElement.scrollTop||document.body?.scrollTop||0}),checkIsScrollRoot:()=>true}),Sw={current:void 0},Mj=$j({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Sw.current){const e=new $1e({});e.mount(window),e.setOptions({layoutScroll:true}),Sw.current=e;}return Sw.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none";},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),M1=f.createContext({transformPagePoint:e=>e,isStatic:false,reducedMotion:"never"});function YD(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t);}function E1e(...e){return t=>{let n=false;const r=e.map(o=>{const i=YD(o,t);return !n&&typeof i=="function"&&(n=true),i});if(n)return ()=>{for(let o=0;o<r.length;o++){const i=r[o];typeof i=="function"?i():YD(e[o],null);}}}}function M1e(...e){return f.useCallback(E1e(...e),e)}class R1e extends f.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent&&this.props.pop!==false){const r=n.offsetParent,o=$3(r)&&r.offsetWidth||0,i=$3(r)&&r.offsetHeight||0,a=this.props.sizeRef.current;a.height=n.offsetHeight||0,a.width=n.offsetWidth||0,a.top=n.offsetTop,a.left=n.offsetLeft,a.right=o-a.width-a.left,a.bottom=i-a.height-a.top;}return null}componentDidUpdate(){}render(){return this.props.children}}function T1e({children:e,isPresent:t,anchorX:n,anchorY:r,root:o,pop:i}){const a=f.useId(),l=f.useRef(null),u=f.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:d}=f.useContext(M1),m=e.props?.ref??e?.ref,p=M1e(l,m);return f.useInsertionEffect(()=>{const{width:g,height:b,top:y,left:S,right:C,bottom:w}=u.current;if(t||i===false||!l.current||!g||!b)return;const $=n==="left"?`left: ${S}`:`right: ${C}`,M=r==="bottom"?`bottom: ${w}`:`top: ${y}`;l.current.dataset.motionPopId=a;const T=document.createElement("style");d&&(T.nonce=d);const R=o??document.head;return R.appendChild(T),T.sheet&&T.sheet.insertRule(`
[data-motion-pop-id="${a}"] {
position: absolute !important;
width: ${g}px !important;
height: ${b}px !important;
${$}px !important;
${M}px !important;
}
`),()=>{R.contains(T)&&R.removeChild(T);}},[t]),qo.jsx(R1e,{isPresent:t,childRef:l,sizeRef:u,pop:i,children:i===false?e:f.cloneElement(e,{ref:p})})}const A1e=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:o,presenceAffectsLayout:i,mode:a,anchorX:l,anchorY:u,root:d})=>{const m=C1(N1e),p=f.useId();let g=true,b=f.useMemo(()=>(g=false,{id:p,initial:t,isPresent:n,custom:o,onExitComplete:y=>{m.set(y,true);for(const S of m.values())if(!S)return;r&&r();},register:y=>(m.set(y,false),()=>m.delete(y))}),[n,m,r]);return i&&g&&(b={...b}),f.useMemo(()=>{m.forEach((y,S)=>m.set(S,false));},[n]),f.useEffect(()=>{!n&&!m.size&&r&&r();},[n]),e=qo.jsx(T1e,{pop:a==="popLayout",isPresent:n,anchorX:l,anchorY:u,root:d,children:e}),qo.jsx(x1.Provider,{value:b,children:e})};function N1e(){return new Map}function Rj(e=true){const t=f.useContext(x1);if(t===null)return [true,null];const{isPresent:n,onExitComplete:r,register:o}=t,i=f.useId();f.useEffect(()=>{if(e)return o(i)},[e]);const a=f.useCallback(()=>e&&r&&r(i),[i,r,e]);return !n&&r?[false,a]:[true]}const Sb=e=>e.key||"";function XD(e){const t=[];return f.Children.forEach(e,n=>{f.isValidElement(n)&&t.push(n);}),t}const P1e=({children:e,custom:t,initial:n=true,onExitComplete:r,presenceAffectsLayout:o=true,mode:i="sync",propagate:a=false,anchorX:l="left",anchorY:u="top",root:d})=>{const[m,p]=Rj(a),g=f.useMemo(()=>XD(e),[e]),b=a&&!m?[]:g.map(Sb),y=f.useRef(true),S=f.useRef(g),C=C1(()=>new Map),w=f.useRef(new Set),[$,M]=f.useState(g),[T,R]=f.useState(g);KH(()=>{y.current=false,S.current=g;for(let P=0;P<T.length;P++){const O=Sb(T[P]);b.includes(O)?(C.delete(O),w.current.delete(O)):C.get(O)!==true&&C.set(O,false);}},[T,b.length,b.join("-")]);const I=[];if(g!==$){let P=[...g];for(let O=0;O<T.length;O++){const _=T[O],B=Sb(_);b.includes(B)||(P.splice(O,0,_),I.push(_));}return i==="wait"&&I.length&&(P=I),R(XD(P)),M(g),null}const{forceRender:N}=f.useContext(bT);return qo.jsx(qo.Fragment,{children:T.map(P=>{const O=Sb(P),_=a&&!m?false:g===T||b.includes(O),B=()=>{if(w.current.has(O))return;if(w.current.add(O),C.has(O))C.set(O,true);else return;let V=true;C.forEach(U=>{U||(V=false);}),V&&(N?.(),R(S.current),a&&p?.(),r&&r());};return qo.jsx(A1e,{isPresent:_,initial:!y.current||n?void 0:false,custom:t,presenceAffectsLayout:o,mode:i,root:d,onExitComplete:_?void 0:B,anchorX:l,anchorY:u,children:P},O)})})},Tj=f.createContext({strict:false}),QD={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let ZD=false;function I1e(){if(ZD)return;const e={};for(const t in QD)e[t]={isEnabled:n=>QD[t].some(r=>!!n[r])};JV(e),ZD=true;}function Aj(){return I1e(),yye()}function O1e(e){const t=Aj();for(const n in e)t[n]={...t[n],...e[n]};JV(t);}const D1e=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function my(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||D1e.has(e)}let Nj=e=>!my(e);function _1e(e){typeof e=="function"&&(Nj=t=>t.startsWith("on")?!my(t):e(t));}try{_1e(require("@emotion/is-prop-valid").default);}catch{}function B1e(e,t,n){const r={};for(const o in e)o==="values"&&typeof e.values=="object"||(Nj(o)||n===true&&my(o)||!t&&!my(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}const R1=f.createContext({});function L1e(e,t){if(E1(e)){const{initial:n,animate:r}=e;return {initial:n===false||$p(n)?n:void 0,animate:$p(r)?r:void 0}}return e.inherit!==false?t:{}}function z1e(e){const{initial:t,animate:n}=L1e(e,f.useContext(R1));return f.useMemo(()=>({initial:t,animate:n}),[JD(t),JD(n)])}function JD(e){return Array.isArray(e)?e.join(" "):e}const KT=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Pj(e,t,n){for(const r in t)!zr(t[r])&&!sj(r,n)&&(e[r]=t[r]);}function k1e({transformTemplate:e},t){return f.useMemo(()=>{const n=KT();return GT(n,t,e),Object.assign({},n.vars,n.style)},[t])}function F1e(e,t){const n=e.style||{},r={};return Pj(r,n,e),Object.assign(r,k1e(e,t)),r}function H1e(e,t){const n={},r=F1e(e,t);return e.drag&&e.dragListener!==false&&(n.draggable=false,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===true?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const Ij=()=>({...KT(),attrs:{}});function V1e(e,t,n,r){const o=f.useMemo(()=>{const i=Ij();return cj(i,t,dj(r),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Pj(i,e.style,e),o.style={...i,...o.style};}return o}const j1e=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function YT(e){return typeof e!="string"||e.includes("-")?false:!!(j1e.indexOf(e)>-1||/[A-Z]/u.test(e))}function U1e(e,t,n,{latestValues:r},o,i=false,a){const u=(a??YT(e)?V1e:H1e)(t,r,o,e),d=B1e(t,typeof e=="string",i),m=e!==f.Fragment?{...d,...u,ref:n}:{},{children:p}=t,g=f.useMemo(()=>zr(p)?p.get():p,[p]);return f.createElement(e,{...m,children:g})}function W1e({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,o){return {latestValues:G1e(n,r,o,e),renderState:t()}}function G1e(e,t,n,r){const o={},i=r(e,{});for(const g in i)o[g]=r0(i[g]);let{initial:a,animate:l}=e;const u=E1(e),d=QV(e);t&&d&&!u&&e.inherit!==false&&(a===void 0&&(a=t.initial),l===void 0&&(l=t.animate));let m=n?n.initial===false:false;m=m||a===false;const p=m?l:a;if(p&&typeof p!="boolean"&&!$1(p)){const g=Array.isArray(p)?p:[p];for(let b=0;b<g.length;b++){const y=BT(e,g[b]);if(y){const{transitionEnd:S,transition:C,...w}=y;for(const $ in w){let M=w[$];if(Array.isArray(M)){const T=m?M.length-1:0;M=M[T];}M!==null&&(o[$]=M);}for(const $ in S)o[$]=S[$];}}}return o}const Oj=e=>(t,n)=>{const r=f.useContext(R1),o=f.useContext(x1),i=()=>W1e(e,t,r,o);return n?i():C1(i)},q1e=Oj({scrapeMotionValuesFromProps:qT,createRenderState:KT}),K1e=Oj({scrapeMotionValuesFromProps:fj,createRenderState:Ij}),Y1e=Symbol.for("motionComponentSymbol");function X1e(e,t,n){const r=f.useRef(n);f.useInsertionEffect(()=>{r.current=n;});const o=f.useRef(null);return f.useCallback(i=>{i&&e.onMount?.(i),t&&(i?t.mount(i):t.unmount());const a=r.current;if(typeof a=="function")if(i){const l=a(i);typeof l=="function"&&(o.current=l);}else o.current?(o.current(),o.current=null):a(i);else a&&(a.current=i);},[t])}const Dj=f.createContext({});function Ad(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Q1e(e,t,n,r,o,i){const{visualElement:a}=f.useContext(R1),l=f.useContext(Tj),u=f.useContext(x1),d=f.useContext(M1),m=d.reducedMotion,p=d.skipAnimations,g=f.useRef(null),b=f.useRef(false);r=r||l.renderer,!g.current&&r&&(g.current=r(e,{visualState:t,parent:a,props:n,presenceContext:u,blockInitialAnimation:u?u.initial===false:false,reducedMotionConfig:m,skipAnimations:p,isSVG:i}),b.current&&g.current&&(g.current.manuallyAnimateOnMount=true));const y=g.current,S=f.useContext(Dj);y&&!y.projection&&o&&(y.type==="html"||y.type==="svg")&&Z1e(g.current,n,o,S);const C=f.useRef(false);f.useInsertionEffect(()=>{y&&C.current&&y.update(n,u);});const w=n[kV],$=f.useRef(!!w&&!window.MotionHandoffIsComplete?.(w)&&window.MotionHasOptimisedAnimation?.(w));return KH(()=>{b.current=true,y&&(C.current=true,window.MotionIsMounted=true,y.updateFeatures(),y.scheduleRenderMicrotask(),$.current&&y.animationState&&y.animationState.animateChanges());}),f.useEffect(()=>{y&&(!$.current&&y.animationState&&y.animationState.animateChanges(),$.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(w);}),$.current=false),y.enteringChildren=void 0);}),y}function Z1e(e,t,n,r){const{layoutId:o,layout:i,drag:a,dragConstraints:l,layoutScroll:u,layoutRoot:d,layoutCrossfade:m}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:_j(e.parent)),e.projection.setOptions({layoutId:o,layout:i,alwaysMeasureLayout:!!a||l&&Ad(l),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,crossfade:m,layoutScroll:u,layoutRoot:d});}function _j(e){if(e)return e.options.allowProjection!==false?e.projection:_j(e.parent)}function Cw(e,{forwardMotionProps:t=false,type:n}={},r,o){r&&O1e(r);const i=n?n==="svg":YT(e),a=i?K1e:q1e;function l(d,m){let p;const g={...f.useContext(M1),...d,layoutId:J1e(d)},{isStatic:b}=g,y=z1e(d),S=a(d,b);if(!b&&qH){eSe();const C=tSe(g);p=C.MeasureLayout,y.visualElement=Q1e(e,S,g,o,C.ProjectionNode,i);}return qo.jsxs(R1.Provider,{value:y,children:[p&&y.visualElement?qo.jsx(p,{visualElement:y.visualElement,...g}):null,U1e(e,d,X1e(S,y.visualElement,m),S,b,t,i)]})}l.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const u=f.forwardRef(l);return u[Y1e]=e,u}function J1e({layoutId:e}){const t=f.useContext(bT).id;return t&&e!==void 0?t+"-"+e:e}function eSe(e,t){f.useContext(Tj).strict;}function tSe(e){const t=Aj(),{drag:n,layout:r}=t;if(!n&&!r)return {};const o={...n,...r};return {MeasureLayout:n?.isEnabled(e)||r?.isEnabled(e)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function nSe(e,t){if(typeof Proxy>"u")return Cw;const n=new Map,r=(i,a)=>Cw(i,a,e,t),o=(i,a)=>r(i,a);return new Proxy(o,{get:(i,a)=>a==="create"?r:(n.has(a)||n.set(a,Cw(a,void 0,e,t)),n.get(a))})}const rSe=(e,t)=>t.isSVG??YT(e)?new mj(t):new lj(t,{allowProjection:e!==f.Fragment});class oSe extends rc{constructor(t){super(t),t.animationState||(t.animationState=Fye(t));}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();$1(t)&&(this.unmountControls=t.subscribe(this.node));}mount(){this.updateAnimationControlsSubscription();}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription();}unmount(){this.node.animationState.reset(),this.unmountControls?.();}}let iSe=0;class aSe extends rc{constructor(){super(...arguments),this.id=iSe++;}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const o=this.node.animationState.setActive("exit",!t);n&&!t&&o.then(()=>{n(this.id);});}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id));}unmount(){}}const sSe={animation:{Feature:oSe},exit:{Feature:aSe}};function mg(e){return {point:{x:e.pageX,y:e.pageY}}}const lSe=e=>t=>VT(t)&&e(t,mg(t));function Hh(e,t,n,r){return Ep(e,t,lSe(n),r)}const Bj=({current:e})=>e?e.ownerDocument.defaultView:null,e_=(e,t)=>Math.abs(e-t);function cSe(e,t){const n=e_(e.x,t.x),r=e_(e.y,t.y);return Math.sqrt(n**2+r**2)}const t_=new Set(["auto","scroll"]);class Lj{constructor(t,n,{transformPagePoint:r,contextWindow:o=window,dragSnapToOrigin:i=false,distanceThreshold:a=3,element:l}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=b=>{this.handleScroll(b.target);},this.onWindowScroll=()=>{this.handleScroll(window);},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const b=ww(this.lastMoveEventInfo,this.history),y=this.startEvent!==null,S=cSe(b.offset,{x:0,y:0})>=this.distanceThreshold;if(!y&&!S)return;const{point:C}=b,{timestamp:w}=Xr;this.history.push({...C,timestamp:w});const{onStart:$,onMove:M}=this.handlers;y||($&&$(this.lastMoveEvent,b),this.startEvent=this.lastMoveEvent),M&&M(this.lastMoveEvent,b);},this.handlePointerMove=(b,y)=>{this.lastMoveEvent=b,this.lastMoveEventInfo=xw(y,this.transformPagePoint),Vn.update(this.updatePoint,true);},this.handlePointerUp=(b,y)=>{this.end();const{onEnd:S,onSessionEnd:C,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const $=ww(b.type==="pointercancel"?this.lastMoveEventInfo:xw(y,this.transformPagePoint),this.history);this.startEvent&&S&&S(b,$),C&&C(b,$);},!VT(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=a,this.contextWindow=o||window;const u=mg(t),d=xw(u,this.transformPagePoint),{point:m}=d,{timestamp:p}=Xr;this.history=[{...m,timestamp:p}];const{onSessionStart:g}=n;g&&g(t,ww(d,this.history)),this.removeListeners=ug(Hh(this.contextWindow,"pointermove",this.handlePointerMove),Hh(this.contextWindow,"pointerup",this.handlePointerUp),Hh(this.contextWindow,"pointercancel",this.handlePointerUp)),l&&this.startScrollTracking(l);}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(t_.has(r.overflowX)||t_.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement;}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:true}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:true}),window.removeEventListener("scroll",this.onWindowScroll);};}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,o=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:o.x-n.x,y:o.y-n.y};i.x===0&&i.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,o),Vn.update(this.updatePoint,true));}updateHandlers(t){this.handlers=t;}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Gl(this.updatePoint);}}function xw(e,t){return t?{point:t(e.point)}:e}function n_(e,t){return {x:e.x-t.x,y:e.y-t.y}}function ww({point:e},t){return {point:e,delta:n_(e,zj(t)),offset:n_(e,uSe(t)),velocity:dSe(t,.1)}}function uSe(e){return e[0]}function zj(e){return e[e.length-1]}function dSe(e,t){if(e.length<2)return {x:0,y:0};let n=e.length-1,r=null;const o=zj(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>Gi(t)));)n--;if(!r)return {x:0,y:0};r===e[0]&&e.length>2&&o.timestamp-r.timestamp>Gi(t)*2&&(r=e[1]);const i=Ui(o.timestamp-r.timestamp);if(i===0)return {x:0,y:0};const a={x:(o.x-r.x)/i,y:(o.y-r.y)/i};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function fSe(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?er(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?er(n,e,r.max):Math.min(e,n)),e}function r_(e,t,n){return {min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function mSe(e,{top:t,left:n,bottom:r,right:o}){return {x:r_(e.x,n,o),y:r_(e.y,t,r)}}function o_(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function hSe(e,t){return {x:o_(e.x,t.x),y:o_(e.y,t.y)}}function pSe(e,t){let n=.5;const r=Mo(e),o=Mo(t);return o>r?n=hf(t.min,t.max-r,e.min):r>o&&(n=hf(e.min,e.max-o,t.min)),qa(0,1,n)}function gSe(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const T3=.35;function vSe(e=T3){return e===false?e=0:e===true&&(e=T3),{x:i_(e,"left","right"),y:i_(e,"top","bottom")}}function i_(e,t,n){return {min:a_(e,t),max:a_(e,n)}}function a_(e,t){return typeof e=="number"?e:e[t]||0}const bSe=new WeakMap;class ySe{constructor(t){this.openDragLock=null,this.isDragging=false,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=false,this.hasMutatedConstraints=false,this.elastic=Sr(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t;}start(t,{snapToCursor:n=false,distanceThreshold:r}={}){const{presenceContext:o}=this.visualElement;if(o&&o.isPresent===false)return;const i=p=>{n&&this.snapToCursor(mg(p).point),this.stopAnimation();},a=(p,g)=>{const{drag:b,dragPropagation:y,onDragStart:S}=this.getProps();if(b&&!y&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Z0e(b),!this.openDragLock))return;this.latestPointerEvent=p,this.latestPanInfo=g,this.isDragging=true,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=true,this.visualElement.projection.target=void 0),Oa(w=>{let $=this.getAxisMotionValue(w).get()||0;if(ja.test($)){const{projection:M}=this.visualElement;if(M&&M.layout){const T=M.layout.layoutBox[w];T&&($=Mo(T)*(parseFloat($)/100));}}this.originPoint[w]=$;}),S&&Vn.update(()=>S(p,g),false,true),S3(this.visualElement,"transform");const{animationState:C}=this.visualElement;C&&C.setActive("whileDrag",true);},l=(p,g)=>{this.latestPointerEvent=p,this.latestPanInfo=g;const{dragPropagation:b,dragDirectionLock:y,onDirectionLock:S,onDrag:C}=this.getProps();if(!b&&!this.openDragLock)return;const{offset:w}=g;if(y&&this.currentDirection===null){this.currentDirection=CSe(w),this.currentDirection!==null&&S&&S(this.currentDirection);return}this.updateAxis("x",g.point,w),this.updateAxis("y",g.point,w),this.visualElement.render(),C&&Vn.update(()=>C(p,g),false,true);},u=(p,g)=>{this.latestPointerEvent=p,this.latestPanInfo=g,this.stop(p,g),this.latestPointerEvent=null,this.latestPanInfo=null;},d=()=>{const{dragSnapToOrigin:p}=this.getProps();(p||this.constraints)&&this.startAnimation({x:0,y:0});},{dragSnapToOrigin:m}=this.getProps();this.panSession=new Lj(t,{onSessionStart:i,onStart:a,onMove:l,onSessionEnd:u,resumeAnimation:d},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:m,distanceThreshold:r,contextWindow:Bj(this.visualElement),element:this.visualElement.current});}stop(t,n){const r=t||this.latestPointerEvent,o=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!o||!r)return;const{velocity:a}=o;this.startAnimation(a);const{onDragEnd:l}=this.getProps();l&&Vn.postRender(()=>l(r,o));}cancel(){this.isDragging=false;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=false),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",false);}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0;}updateAxis(t,n,r){const{drag:o}=this.getProps();if(!r||!Cb(t,o,this.currentDirection))return;const i=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=fSe(a,this.constraints[t],this.elastic[t])),i.set(a);}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(false):this.visualElement.projection?.layout,o=this.constraints;t&&Ad(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=mSe(r.layoutBox,t):this.constraints=false,this.elastic=vSe(n),o!==this.constraints&&!Ad(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Oa(i=>{this.constraints!==false&&this.getAxisMotionValue(i)&&(this.constraints[i]=gSe(r.layoutBox[i],this.constraints[i]));});}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Ad(t))return false;const r=t.current,{projection:o}=this.visualElement;if(!o||!o.layout)return false;const i=wye(r,o.root,this.visualElement.getTransformPagePoint());let a=hSe(o.layout.layoutBox,i);if(n){const l=n(Sye(a));this.hasMutatedConstraints=!!l,l&&(a=nj(l));}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:i,dragSnapToOrigin:a,onDragTransitionEnd:l}=this.getProps(),u=this.constraints||{},d=Oa(m=>{if(!Cb(m,n,this.currentDirection))return;let p=u&&u[m]||{};a&&(p={min:0,max:0});const g=o?200:1e6,b=o?40:1e7,y={type:"inertia",velocity:r?t[m]:0,bounceStiffness:g,bounceDamping:b,timeConstant:750,restDelta:1,restSpeed:10,...i,...p};return this.startAxisValueAnimation(m,y)});return Promise.all(d).then(l)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return S3(this.visualElement,t),r.start(_T(t,r,0,n,this.visualElement,false))}stopAnimation(){Oa(t=>this.getAxisMotionValue(t).stop());}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Oa(n=>{const{drag:r}=this.getProps();if(!Cb(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,i=this.getAxisMotionValue(n);if(o&&o.layout){const{min:a,max:l}=o.layout.layoutBox[n],u=i.get()||0;i.set(t[n]-er(a,l,.5)+u);}});}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Ad(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};Oa(a=>{const l=this.getAxisMotionValue(a);if(l&&this.constraints!==false){const u=l.get();o[a]=pSe({min:u,max:u},this.constraints[a]);}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=false,this.resolveConstraints(),Oa(a=>{if(!Cb(a,t,null))return;const l=this.getAxisMotionValue(a),{min:u,max:d}=this.constraints[a];l.set(er(u,d,o[a]));}),this.visualElement.render();}addListeners(){if(!this.visualElement.current)return;bSe.set(this.visualElement,this);const t=this.visualElement.current,n=Hh(t,"pointerdown",d=>{const{drag:m,dragListener:p=true}=this.getProps(),g=d.target,b=g!==t&&oye(g);m&&p&&!b&&this.start(d);});let r;const o=()=>{const{dragConstraints:d}=this.getProps();Ad(d)&&d.current&&(this.constraints=this.resolveRefConstraints(),r||(r=SSe(t,d.current,()=>this.scalePositionWithinConstraints())));},{projection:i}=this.visualElement,a=i.addEventListener("measure",o);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),Vn.read(o);const l=Ep(window,"resize",()=>this.scalePositionWithinConstraints()),u=i.addEventListener("didUpdate",(({delta:d,hasLayoutChanged:m})=>{this.isDragging&&m&&(Oa(p=>{const g=this.getAxisMotionValue(p);g&&(this.originPoint[p]+=d[p].translate,g.set(g.get()+d[p].translate));}),this.visualElement.render());}));return ()=>{l(),n(),a(),u&&u(),r&&r();}}getProps(){const t=this.visualElement.getProps(),{drag:n=false,dragDirectionLock:r=false,dragPropagation:o=false,dragConstraints:i=false,dragElastic:a=T3,dragMomentum:l=true}=t;return {...t,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:i,dragElastic:a,dragMomentum:l}}}function s_(e){let t=true;return ()=>{if(t){t=false;return}e();}}function SSe(e,t,n){const r=hD(e,s_(n)),o=hD(t,s_(n));return ()=>{r(),o();}}function Cb(e,t,n){return (t===true||t===e)&&(n===null||n===e)}function CSe(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class xSe extends rc{constructor(t){super(t),this.removeGroupControls=Wi,this.removeListeners=Wi,this.controls=new ySe(t);}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Wi;}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)));}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession();}}const $w=e=>(t,n)=>{e&&Vn.update(()=>e(t,n),false,true);};class wSe extends rc{constructor(){super(...arguments),this.removePointerDownListener=Wi;}onPointerDown(t){this.session=new Lj(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Bj(this.node)});}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return {onSessionStart:$w(t),onStart:$w(n),onMove:$w(r),onEnd:(i,a)=>{delete this.session,o&&Vn.postRender(()=>o(i,a));}}}mount(){this.removePointerDownListener=Hh(this.node.current,"pointerdown",t=>this.onPointerDown(t));}update(){this.session&&this.session.updateHandlers(this.createPanHandlers());}unmount(){this.removePointerDownListener(),this.session&&this.session.end();}}let Ew=false;class $Se extends f.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),r&&r.register&&o&&r.register(i),Ew&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove();}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),o0.hasEverUpdated=true;}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:o,isPresent:i}=this.props,{projection:a}=r;return a&&(a.isPresent=i,t.layoutDependency!==n&&a.setOptions({...a.options,layoutDependency:n}),Ew=true,o||t.layoutDependency!==n||n===void 0||t.isPresent!==i?a.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?a.promote():a.relegate()||Vn.postRender(()=>{const l=a.getStack();(!l||!l.members.length)&&this.safeToRemove();}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),HT.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove();}));}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=t;Ew=true,o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o));}safeToRemove(){const{safeToRemove:t}=this.props;t&&t();}render(){return null}}function kj(e){const[t,n]=Rj(),r=f.useContext(bT);return qo.jsx($Se,{...e,layoutGroup:r,switchLayoutGroup:f.useContext(Dj),isPresent:t,safeToRemove:n})}const ESe={pan:{Feature:wSe},drag:{Feature:xSe,ProjectionNode:Mj,MeasureLayout:kj}};function l_(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const o="onHover"+n,i=r[o];i&&Vn.postRender(()=>i(t,mg(t)));}class MSe extends rc{mount(){const{current:t}=this.node;t&&(this.unmount=eye(t,(n,r)=>(l_(this.node,r,"Start"),o=>l_(this.node,o,"End"))));}unmount(){}}class RSe extends rc{constructor(){super(...arguments),this.isActive=false;}onFocus(){let t=false;try{t=this.node.current.matches(":focus-visible");}catch{t=true;}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",true),this.isActive=true);}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",false),this.isActive=false);}mount(){this.unmount=ug(Ep(this.node.current,"focus",()=>this.onFocus()),Ep(this.node.current,"blur",()=>this.onBlur()));}unmount(){}}function c_(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const o="onTap"+(n==="End"?"":n),i=r[o];i&&Vn.postRender(()=>i(t,mg(t)));}class TSe extends rc{mount(){const{current:t}=this.node;if(!t)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=aye(t,(o,i)=>(c_(this.node,i,"Start"),(a,{success:l})=>c_(this.node,a,l?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:r?.tap===false});}unmount(){}}const A3=new WeakMap,Mw=new WeakMap,ASe=e=>{const t=A3.get(e.target);t&&t(e);},NSe=e=>{e.forEach(ASe);};function PSe({root:e,...t}){const n=e||document;Mw.has(n)||Mw.set(n,{});const r=Mw.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(NSe,{root:e,...t})),r[o]}function ISe(e,t,n){const r=PSe(t);return A3.set(e,n),r.observe(e),()=>{A3.delete(e),r.unobserve(e);}}const OSe={some:0,all:1};class DSe extends rc{constructor(){super(...arguments),this.hasEnteredView=false,this.isInView=false;}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:i}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:OSe[o]},l=u=>{const{isIntersecting:d}=u;if(this.isInView===d||(this.isInView=d,i&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=true),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:m,onViewportLeave:p}=this.node.getProps(),g=d?m:p;g&&g(u);};return ISe(this.node.current,a,l)}mount(){this.startObserver();}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(_Se(t,n))&&this.startObserver();}unmount(){}}function _Se({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const BSe={inView:{Feature:DSe},tap:{Feature:TSe},focus:{Feature:RSe},hover:{Feature:MSe}},LSe={layout:{ProjectionNode:Mj,MeasureLayout:kj}},zSe={...sSe,...BSe,...ESe,...LSe},XT=nSe(zSe,rSe);function kSe(e){return f.useEffect(()=>()=>e(),[])}function FSe(){!WT.current&&ZV();const[e]=f.useState(cy.current);return e}function HSe(){const e=FSe(),{reducedMotion:t}=f.useContext(M1);return t==="never"?false:t==="always"?true:e}function QT(e){return typeof e=="object"&&!Array.isArray(e)}function Fj(e,t,n,r){return e==null?[]:typeof e=="string"&&QT(t)?FT(e,n,r):e instanceof NodeList?Array.from(e):Array.isArray(e)?e.filter(o=>o!=null):[e]}function VSe(e,t,n){return e*(t+1)}function u_(e,t,n,r){return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?n:t.startsWith("<")?Math.max(0,n+parseFloat(t.slice(1))):r.get(t)??e}function jSe(e,t,n){for(let r=0;r<e.length;r++){const o=e[r];o.at>t&&o.at<n&&(mf(e,o),r--);}}function USe(e,t,n,r,o,i){jSe(e,o,i);for(let a=0;a<t.length;a++)e.push({value:t[a],at:er(o,i,r[a]),easing:uV(n,a)});}function WSe(e,t){for(let n=0;n<e.length;n++)e[n]=e[n]/(t+1);}function GSe(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}const qSe="easeInOut";function KSe(e,{defaultTransition:t={},...n}={},r,o){const i=t.duration||.3,a=new Map,l=new Map,u={},d=new Map;let m=0,p=0,g=0;for(let b=0;b<e.length;b++){const y=e[b];if(typeof y=="string"){d.set(y,p);continue}else if(!Array.isArray(y)){d.set(y.name,u_(p,y.at,m,d));continue}let[S,C,w={}]=y;w.at!==void 0&&(p=u_(p,w.at,m,d));let $=0;const M=(T,R,I,N=0,P=0)=>{const O=YSe(T),{delay:_=0,times:B=MV(O),type:V=t.type||"keyframes",repeat:U,repeatType:G,repeatDelay:H=0,...z}=R;let{ease:j=t.ease||"easeOut",duration:W}=R;const Y=typeof _=="function"?_(N,P):_,Q=O.length,D=OT(V)?V:o?.[V||"keyframes"];if(Q<=2&&D){let ee=100;if(Q===2&&ZSe(O)){const ie=O[1]-O[0];ee=Math.abs(ie);}const te={...t,...z};W!==void 0&&(te.duration=Gi(W));const re=wV(te,ee,D);j=re.ease,W=re.duration;}W??(W=i);const L=p+Y;B.length===1&&B[0]===0&&(B[1]=1);const K=B.length-O.length;if(K>0&&EV(B,K),O.length===1&&O.unshift(null),U){W=VSe(W,U);const ee=[...O],te=[...B];j=Array.isArray(j)?[...j]:[j];const re=[...j];for(let ie=0;ie<U;ie++){O.push(...ee);for(let de=0;de<ee.length;de++)B.push(te[de]+(ie+1)),j.push(de===0?"linear":uV(re,de-1));}WSe(B,U);}const J=L+W;USe(I,O,j,B,L,J),$=Math.max(Y+W,$),g=Math.max(J,g);};if(zr(S)){const T=d_(S,l);M(C,w,f_("default",T));}else {const T=Fj(S,C,r,u),R=T.length;for(let I=0;I<R;I++){C=C,w=w;const N=T[I],P=d_(N,l);for(const O in C)M(C[O],XSe(w,O),f_(O,P),I,R);}}m=p,p+=$;}return l.forEach((b,y)=>{for(const S in b){const C=b[S];C.sort(GSe);const w=[],$=[],M=[];for(let N=0;N<C.length;N++){const{at:P,value:O,easing:_}=C[N];w.push(O),$.push(hf(0,g,P)),M.push(_||"easeOut");}$[0]!==0&&($.unshift(0),w.unshift(w[0]),M.unshift(qSe)),$[$.length-1]!==1&&($.push(1),w.push(null)),a.has(y)||a.set(y,{keyframes:{},transition:{}});const T=a.get(y);T.keyframes[S]=w;const{type:R,...I}=t;T.transition[S]={...I,duration:g,ease:M,times:$,...n};}}),a}function d_(e,t){return !t.has(e)&&t.set(e,{}),t.get(e)}function f_(e,t){return t[e]||(t[e]=[]),t[e]}function YSe(e){return Array.isArray(e)?e:[e]}function XSe(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}const QSe=e=>typeof e=="number",ZSe=e=>e.every(QSe);function JSe(e){const t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},n=w1(e)&&!XV(e)?new mj(t):new lj(t);n.mount(e),wp.set(e,n);}function eCe(e){const t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},n=new Nye(t);n.mount(e),wp.set(e,n);}function tCe(e,t){return zr(e)||typeof e=="number"||typeof e=="string"&&!QT(t)}function Hj(e,t,n,r){const o=[];if(tCe(e,t))o.push(xj(e,QT(t)&&t.default||t,n&&(n.default||n)));else {if(e==null)return o;const i=Fj(e,t,r),a=i.length;for(let l=0;l<a;l++){const u=i[l],d=u instanceof Element?JSe:eCe;wp.has(u)||d(u);const m=wp.get(u),p={...n};"delay"in p&&typeof p.delay=="function"&&(p.delay=p.delay(l,a)),o.push(...zT(m,{...t,transition:p},{}));}}return o}function nCe(e,t,n){const r=[],o=e.map(a=>{if(Array.isArray(a)&&typeof a[0]=="function"){const l=a[0],u=du(0);return u.on("change",l),a.length===1?[u,[0,1]]:a.length===2?[u,[0,1],a[1]]:[u,a[1],a[2]]}return a});return KSe(o,t,n,{spring:xp}).forEach(({keyframes:a,transition:l},u)=>{r.push(...Hj(u,a,l));}),r}function rCe(e){return Array.isArray(e)&&e.some(Array.isArray)}function Vj(e={}){const{scope:t,reduceMotion:n}=e;function r(o,i,a){let l=[],u;if(rCe(o))l=nCe(o,n!==void 0?{reduceMotion:n,...i}:i,t);else {const{onComplete:m,...p}=a||{};typeof m=="function"&&(u=m),l=Hj(o,i,n!==void 0?{reduceMotion:n,...p}:p,t);}const d=new y0e(l);return u&&d.finished.then(u),t&&(t.animations.push(d),d.finished.then(()=>{mf(t.animations,d);})),d}return r}Vj();function oCe(){const e=C1(()=>({current:null,animations:[]})),t=HSe()??void 0,n=f.useMemo(()=>Vj({scope:e,reduceMotion:t}),[e,t]);return kSe(()=>{e.animations.forEach(r=>r.stop()),e.animations.length=0;}),[e,n]}function Mp({size:e=18,useAnimation:t=false,color:n="currentColor",...r}){return x("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:e,height:e,...r,children:x(XT.path,{fill:"transparent",stroke:n,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M5 11L11 17L21 7",...t&&{initial:{pathLength:0},animate:{pathLength:1},transition:{duration:.2,ease:"easeInOut"}}})})}const jj=nve,ZT=ove,JT=ave,hg=lve,No=uve,N3=fve,P3=hve,iCe=gve,m_=bve,Uj=Sve,aCe=xve,Wj=Zge,sCe=$ve,lCe=Mve,cCe=Tve,uCe=Nve,hy=Jge,pf=Ive,dCe=Dve,fCe=Bve,py=zve,I3=Fve,gy=WH,tu=jve,Gj=vT,Uf=Wve,mCe=GH,eA=Kve,hCe="data:image/gif;base64,R0lGODlhGAAYAJECAP7+/v///wAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/wtYTVAgRGF0YVhNUDw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMTQ4IDc5LjE2NDAzNiwgMjAxOS8wOC8xMy0wMTowNjo1NyAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIDIxLjAgKE1hY2ludG9zaCkiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6QTI2NTYzMDc2RTNDMTFFREJENEJEMzUxOTQzQjMxMkQiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6QTI2NTYzMDg2RTNDMTFFREJENEJEMzUxOTQzQjMxMkQiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDpBMjY1NjMwNTZFM0MxMUVEQkQ0QkQzNTE5NDNCMzEyRCIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDpBMjY1NjMwNjZFM0MxMUVEQkQ0QkQzNTE5NDNCMzEyRCIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PgH//v38+/r5+Pf29fTz8vHw7+7t7Ovq6ejn5uXk4+Lh4N/e3dzb2tnY19bV1NPS0dDPzs3My8rJyMfGxcTDwsHAv769vLu6ubi3trW0s7KxsK+urayrqqmop6alpKOioaCfnp2cm5qZmJeWlZSTkpGQj46NjIuKiYiHhoWEg4KBgH9+fXx7enl4d3Z1dHNycXBvbm1sa2ppaGdmZWRjYmFgX15dXFtaWVhXVlVUU1JRUE9OTUxLSklIR0ZFRENCQUA/Pj08Ozo5ODc2NTQzMjEwLy4tLCsqKSgnJiUkIyIhIB8eHRwbGhkYFxYVFBMSERAPDg0MCwoJCAcGBQQDAgEAACH5BAkEAAIALAAAAAAYABgAAAI5lI+py+0Po2QhTFXrRdlu031gJgqhpI0pdJ4sacJv6j6trABeTOMcfFslgp7ar4fcDVcyX+kJjToKACH5BAkEAAIALAAAAAAYABgAAAI2lI+py+0Po5xUhFDRvdls3H0T522SaJkRikKs6qptAr+kYoOzJvc37dPBgKQco3YbdpbM5qQAACH5BAkEAAIALAAAAAAYABgAAAI3lI+py+0Po5y02hhykHqLzmkGiImfCZHkkh0qmrztOSuyt8bmzfC0Z9sJa7qZLwhEwS7MpnNSAAAh+QQJBAACACwAAAAAGAAYAAACPJSPqcvtD6OctJoQ7MFYC55dYQSKHcmZo3J+qdsmJRzO7DvbMs7HSN5b/YIqBvCkGyKJixds4/NIp1RHAQAh+QQJBAACACwAAAAAGAAYAAACOpSPqcvtD6OcLwSarMVHXy54YKhJIrmhn3K25eKmJ/vGa1bnKS3rN2IzzHC94q/jE754yNVyBI1KIQUAIfkECQQAAgAsAAAAABgAGAAAAjmUj6nL7Q+jnLSaEOzBePbLSVwmjGJYopCZfmnDxmoif6xSkzeN5ozfIuF6RBfPVhQeN66Z5gmNTgoAIfkECQQAAgAsAAAAABgAGAAAAjmUj6nL7Q+jnLRaETLSMnMfdJ4Bit8YlRgKqerauOibyCen2OGK1/Pf2wB3NOGNyPLteIfk5QmNTgoAIfkECQQAAgAsAAAAABgAGAAAAjeUj6nL7Q+jnCkEWu3FRm/uHdYUCiVUnk+qSewYvd/amrWKyF2t6DbcuwmBGZgv+OHxOMyms1kAACH5BAkEAAIALAAAAAAYABgAAAI5lI+py+0PowtBLkptwlUf7n1YaIBlF5kmpI6puz5t9tLxBLsCgCpzdxPZcjQfEajbFHVJkvMJtRQAACH5BAkEAAIALAAAAAAYABgAAAI1lI+py+0Po5wpBFrtxUZv7nGdJgqheJ5QSkasJb2bmsFmSyPyaCv73avNcC1fr1gsKZdMSAEAIfkECQQAAgAsAAAAABgAGAAAAjWUj6nL7Q+jnLRaEfI1Wd8ebKDYkR4WHqcyol7Llm4KJ+0tx69cI/i+8vGGQdUpl9sol0xIAQAh+QQJBAACACwAAAAAGAAYAAACNJSPqcvtD6OctNq7QsBCa+xtV9h8DJl5p5qaCtqJsZugNvuyN43sIlzTCXkHnJHISSqXiQIAIfkECQQAAgAsAAAAABgAGAAAAjKUj6nL7Q+jnLTai3MMPLDuLeDXkZwZKqNYsqebJqva0u86yy1e6/feQ9SGL43xiEwUAAAh+QQJBAACACwAAAAAGAAYAAACM5SPqcvtD6OctNp7Q8BCa+xtzDd6JamEp5iai2qgcEvCc2K7N5LXLi3qsXCy4pCDTCoXBQAh+QQJBAACACwAAAAAGAAYAAACNJSPqcvtD6OctNoYcrhC7+txIag1mVkuY/exp5qOayLHqVK/M5J/+9Ez/IQvF7DISSqXkAIAIfkEBQQAAgAsAAAAABgAGAAAAjKUj6nL7Q+jnFSEUNG92WzcfZ21jWJYRucJranyutwig2xSey+e5nQPnMGEMeHoiExCCgA7";function tA({active:e=false,...t}){return e?x("img",{...t,src:hCe}):x(Xve,{...t})}const nA=cg(e=>F("svg",{viewBox:"0 0 20 20",fill:"currentColor",...e,children:[x("path",{className:"circle",d:"M10 3.1248000000000005C6.20305 3.1248000000000005 3.1250083333333336 6.202841666666667 3.1250083333333336 9.999833333333335C3.1250083333333336 13.796750000000001 6.20305 16.874833333333335 10 16.874833333333335C11.898291666666667 16.874833333333335 13.615833333333333 16.106291666666667 14.860625 14.861916666666666C15.104708333333335 14.617916666666666 15.500416666666668 14.617958333333334 15.7445 14.862041666666668C15.9885 15.106166666666669 15.988416666666668 15.501916666666666 15.744333333333334 15.745958333333334C14.274750000000001 17.215041666666668 12.243041666666667 18.124833333333335 10 18.124833333333335C5.512691666666667 18.124833333333335 1.8750083333333334 14.487125 1.8750083333333334 9.999833333333335C1.8750083333333334 5.512483333333334 5.512691666666667 1.8748000000000002 10 1.8748000000000002C14.487291666666668 1.8748000000000002 18.125 5.512483333333334 18.125 9.999833333333335C18.125 10.304458333333333 18.108208333333334 10.605458333333333 18.075458333333337 10.901791666666668C18.0375 11.244916666666667 17.728625 11.492291666666667 17.385583333333333 11.454333333333334C17.0425 11.416416666666667 16.795083333333334 11.107541666666668 16.833000000000002 10.764458333333334C16.860750000000003 10.513625000000001 16.875 10.2585 16.875 9.999833333333335C16.875 6.202841666666667 13.796958333333333 3.1248000000000005 10 3.1248000000000005z",fill:"currentColor"}),x("path",{d:"M15.391416666666666 9.141166666666667C15.635458333333334 8.897083333333335 16.031208333333332 8.897083333333335 16.275291666666668 9.141166666666667L17.5 10.365875L18.72475 9.141166666666667C18.968791666666668 8.897083333333335 19.364541666666668 8.897083333333335 19.608625 9.141166666666667C19.852666666666668 9.385291666666667 19.852666666666668 9.780958333333334 19.608625 10.025083333333333L18.08925 11.544416666666669C17.763833333333334 11.869833333333334 17.236208333333334 11.869833333333334 16.91075 11.544416666666669L15.391416666666666 10.025083333333333C15.147333333333334 9.780958333333334 15.147333333333334 9.385291666666667 15.391416666666666 9.141166666666667z",fill:"currentColor"}),x("path",{d:"M12.499333333333334 9.278375C13.05475 9.599 13.05475 10.400666666666668 12.499333333333334 10.721291666666668L9.373916666666666 12.525791666666668C8.818541666666667 12.846416666666666 8.124274999999999 12.445583333333333 8.124274999999999 11.804291666666668L8.124274999999999 8.1954C8.124274999999999 7.554066666666667 8.818541666666667 7.153233333333334 9.373916666666666 7.473900000000001L12.499333333333334 9.278375z",fill:"currentColor"})]})),qj=zX(),rA=qj.os.name?.toLowerCase()==="mac os",pCe=qj.browser.name||"",oA=e=>new RegExp(String.raw`\b${e}\b`,"i").test(pCe),pg=oA("safari");oA("firefox");oA("edge");const gCe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"m19.833 21.26l-1.298-1.298q-.096.019-.173.029q-.077.009-.173.009H5.616q-.691 0-1.153-.462T4 18.384V5.813q0-.096.01-.173t.029-.173l-1.299-1.3l.713-.713l17.092 17.092zM5.616 19h11.957l-5.933-5.933l-1.902 1.902l-.707-.708l1.902-1.902L5 6.427v11.958q0 .23.192.423t.423.192M7.813 5l-1-1h4.419v1zm5.948 5.948l-.708-.707L18.292 5H14V4h6v6h-1V5.708zm6.24 6.24l-1-1V12.77h1z"})]}),vCe=f.forwardRef(gCe),bCe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M16 3h6v6h-2V5h-4zM2 3h6v2H4v4H2zm18 16v-4h2v6h-6v-2zM4 19h4v2H2v-6h2z"})]}),yCe=f.forwardRef(bCe),SCe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("rect",{width:20,height:16,x:2,y:4,rx:2}),x("rect",{width:9,height:7,x:13,y:13,rx:2})]})]}),CCe=f.forwardRef(SCe),xCe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M6 3h8.99v1.5H6zM2.99 6h1.5v1.5h-1.5zm0-3h1.5v1.5h-1.5zm0 6.01H4.5v1.5H2.99z"}),x("path",{fill:"currentColor",d:"M4.5 12h-3V1.49h15V6H18V2a2 2 0 0 0-2-2H2a2 2 0 0 0-2 2v9.48a2 2 0 0 0 2 2h2.5Z"}),x("path",{fill:"currentColor",d:"M22 7.5H8a2 2 0 0 0-2 2V19a2 2 0 0 0 2 2h5.53v1.53H12V24h6v-1.49h-1.5V21H22a2 2 0 0 0 2-2V9.5a2 2 0 0 0-2-2m.51 12h-15V9h15Z"})]}),wCe=f.forwardRef(xCe),h_="0";function nu(e,t){GM.setClipboard(e),_t.success(`已复制: ${e}`,t);}var ql=(e=>(e.PlayerScreenMode=`${g5}-player-screen-mode`,e.ForceAutoPlay=`${g5}-force-auto-play`,e))(ql||{}),Tl=(e=>(e.Normal="normal",e.Wide="wide",e.WebFullscreen="web",e.Fullscreen="full",e))(Tl||{}),iA=(e=>(e.ON="on",e.OFF="off",e))(iA||{}),sr=(e=>(e.Normal="Normal",e.CurrentPage="CurrentPage",e.NormalWebFullscreen="NormalWebFullscreen",e.Popup="Popup",e.Background="Background",e.Iina="Iina",e))(sr||{});const p_=Object.entries(sr).reduce((e,[t,n])=>({...e,[n]:`LinkOpenMode.${t}`}),{}),di={Normal:{icon:x(No,{className:"size-16px"}),label:"打开",desc:"默认在新标签页中打开"},CurrentPage:{icon:x(vCe,{className:"size-16px"}),label:"当前页中打开",desc:"不打开新标签页, 使用当前标签页打开, 适用于将网站作为应用安装场景"},NormalWebFullscreen:{icon:x(yCe,{className:"size-15px"}),label:"打开-网页全屏",desc:x(ze,{children:"默认在新标签页中打开, 打开后自动网页全屏"})},Popup:{icon:x(CCe,{className:"size-15px"}),label:"小窗打开",desc:F(ze,{children:["当"," ",x("a",{href:"https://developer.chrome.com/docs/web-platform/document-picture-in-picture",target:"_blank",children:"「文档画中画」API"})," ","可用时, 会使用「文档画中画」的形式: 窗口置顶 + 播放页网页全屏.",x("br",{}),"当该 API 不可用时, 会使用 popup window + 播放页网页全屏 的形式."]})},Background:{icon:x(wCe,{className:"size-15px"}),label:"后台打开"},Iina:{icon:x(hg,{className:"size-15px"}),label:"在 IINA 中打开",enabled:rA,desc:x(ze,{children:x("a",{href:"https://github.com/magicdawn/Bilibili-Gate/blob/main/notes/iina.md",target:"_blank",children:"macOS IINA 设置教程"})})}};function $Ce(){return new Xo}const Kj=$Ce(),O3={card:{name:"18iuzk9",styles:"grid-column:1/-1"},cardWrap:{name:"k9oiqw",styles:"display:flex;column-gap:20px"},cover:{name:"1t7agkb",styles:"width:clamp(250px, 20%, 400px);flex-shrink:0"}},ECe="z-2",MCe="z-3",RCe="z-4",TCe="z-5",ACe="z-6";var kr=(e=>(e.NormalGrid="grid",e.List="list",e.TwoColumnGrid="two-column-grid",e.CenterEmptyGrid="center-empty-grid",e))(kr||{}),ru=(e=>(e.Center="center",e.Left="left",e.Right="right",e))(ru||{}),gf=(e=>(e.Left="left",e.Right="right",e))(gf||{}),bo=(e=>(e.AddTimeDesc="add-time-desc",e.AddTimeAsc="add-time-asc",e.Shuffle="shuffle",e))(bo||{});function Yj(e,t="",n=[]){t&&n.push(t);for(const r in e){if(!Object.prototype.hasOwnProperty.call(e,r))continue;const o=e[r],i=t?`${t}.${r}`:r;n.push(i),o&&typeof o=="object"&&!Array.isArray(o)&&!(o instanceof Date)&&!(o instanceof RegExp)&&Yj(o,i,n);}return [...new Set(n)]}function Xj(e,t=""){const n=[];t&&n.push(t);for(const r in e){if(!Object.prototype.hasOwnProperty.call(e,r))continue;const o=e[r],i=t?`${t}.${r}`:r;o&&typeof o=="object"&&!Array.isArray(o)&&!(o instanceof Date)&&!(o instanceof RegExp)&&Object.getPrototypeOf(o)===Object.prototype&&(n.push(i),n.push(...Xj(o,i)));}return [...new Set(n)]}function NCe(e){const t=Yj(e),n=Xj(e);return t.filter(r=>!n.includes(r))}function PCe(e){return [...new Set(e)]}function ICe(e,t){if(!e)throw Error(t)}const Qj=String.raw,Nc=(e,...t)=>new RegExp(Qj(e,...t)),g_=Qj`(\d+(\.\d+)?)?(xs|sm|md|lg|xl)`,xb="(solid|dashed|dotted|double|none|hidden)";function mr(e,t){return ICe(e.endsWith("-"),"prefix must end with `-`"),t.map(n=>e+n)}const OCe=[[[...["block","flex","grid","table"].flatMap(e=>[e,`inline-${e}`]),"inline","flow-root","contents","list-item","hidden",...mr("table-",["row","column","cell","caption","row-group","column-group","header-group","footer-group"])],"display"],[["isolate","isolation-auto"],"isolation"],[["static","fixed","absolute","relative","sticky"],"position"],[["visible","invisible","collapse"],"visibility"],[mr("flex-",["row","row-reverse","col","col-reverse"]),"flex-direction"],[mr("flex-",["wrap","wrap-reverse","nowrap"]),"flex-wrap"],[mr("object-",["contain","cover","fill","none","scale-down"]),"object-fit"],[mr("object-",["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]),"object-position"],[["antialiased","subpixel-antialiased"],"font-smoothing"],[["italic","not-italic","oblique","not-oblique"],"font-style"],[mr("font-",["mono","sans","serif"]),"font-family"],[/^(?:font|fw)-?(thin|extralight|light|normal|medium|semibold|bold|extrabold|black|\d+)$/,"font-weight"],[["normal-nums","ordinal","slashed-zero","lining-nums","oldstyle-nums","proportional-nums","tabular-nums","diagonal-fractions","stacked-fractions"],"font-variant-numeric"],[Nc`^(text|text-size|font-size)-(\d+|${g_}$)`,"font-size"],[/^(leading|line-height)-/,"line-height"],[mr("list-",["inside","outside"]),"list-style-position"],[mr("list-",["none","disc","decimal"]),"list-style-type"],[mr("text-",["left","center","right","justify","start","end"]),"text-align"],[["underline","overline","line-through","no-underline"],"text-decoration-line"],[mr("decoration-",["solid","double","dotted","dashed","wavy"]),"text-decoration-style"],[/^decoration-(\d+|(auto|from-font)$)/,"text-decoration-thickness"],[["truncate","text-ellipsis","text-clip"],"text-overflow"],[mr("text-",["wrap","nowrap","balance","pretty"]),"text-wrap"],[mr("bg-",["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]),"background-position"],[/^bg(-no)?-repeat($|-)/,"background-repeat"],[mr("bg-",["auto","cover","contain"]),"background-size"],[["bg-none",/^bg-gradient-to-/],"background-image"],[/^(?:border-|b-)?(?:rounded|rd)(?:-(.+))?$/,"rounded"],[Nc`^b(?:order)?-${xb}$`,"border-style"],[Nc`^b(?:order)?-([tblrxyse])-${xb}$`,(e,t)=>`border-${t?.[1]}-style`],[/^b(?:order)?($|-\d+)/,"border-width"],[/^b(?:order)?-([tblrxyse])($|-\d+)/,(e,t)=>`border-${t?.[1]}-width`],[/^(?:border|b)-(?:color-)?(.+)$/,"border-color"],[/^(?:border|b)-([rltbse])-(?:color-)?(.+)$/,(e,t)=>`border-${t?.[1]}-color`],[/^outline-\d+/,"outline-width"],[["outline",Nc`^outline-${xb}$`],"outline-style"],[Nc`^divide-${xb}$`,"divide-style"],[/^divide-(x|y)($|-\d+)/,(e,t)=>`divide-${t?.[1]}-width`],[["ring",/^ring-\d+/],"ring-width"],[[/^ring-offset-\d+/],"ring-offset-width"],[["shadow",...mr("shadow-",["inner","none"]),Nc`^shadow-${g_}$`],"box-shadow"],[mr("border-",["collapse","separate"]),"border-collapse"],[mr("table-",["auto","fixed"]),"table-layout"],[mr("caption-",["top","bottom"]),"caption-side"],[mr("scroll-",["auto","smooth"]),"scroll-behavior"],[mr("snap-",["start","end","center","align-none"]),"scroll-snap-align"],[mr("snap-",["normal","always"]),"scroll-snap-stop"],[mr("snap-",["none","x","y","both","mandatory","proximity"]),"scroll-snap-type"],[/^stroke-\d+/,"stroke-width"],[["sr-only","not-sr-only"],"Screen-Readers"],[/^(flex-)?grow($|-\d+$)/,"flex-grow"],[/^(flex-)?shrink($|-\d+$)/,"flex-shrink"],[/^(flex-)?basis-(.+)$/,"flex-basis"],[/^flex-(initial|auto|none|\d+)$/,"flex"],[/^col-start-/,"grid-column-start"],[/^col-end-/,"grid-column-end"],[[/^col-/,/^col-span-/],"grid-column"],[/^row-start-/,"grid-row-start"],[/^row-end-/,"grid-row-end"],[[/^row-/,/^row-span-/],"grid-row"],["transition-none","transition-none"],[/^transition-delay-(.+)$/,"transition-delay"],[/^transition-ease(?:-(.+))?$/,"transition-timing-function"],[/^transition(-duration)?-\d+(m?s)?$/,"transition-duration"],[/^transition-(all$|\w+)/,"transition-property"],...["ring-inset","divide-x-reverse","divide-y-reverse"].map(e=>[e,e]),...["resize","blur","drop-shadow","grayscale","invert","sepia","backdrop-blur","backdrop-grayscale","backdrop-invert","backdrop-sepia"].map(e=>[Nc`^${e}($|-)`,e])],D3=new Map,Zj=new Map;for(let[e,t]of OCe){let n=[e].flat(),r=n.filter(i=>typeof i=="string"),o=n.filter(i=>typeof i=="object"&&i instanceof RegExp);r.forEach(i=>{let a=typeof t=="string"?t:t(i);D3.set(i,a);}),o.forEach(i=>{Zj.set(i,t);});}function DCe(e){if(D3.has(e))return D3.get(e);for(let[t,n]of Zj.entries())if(t.test(e)){let r=t.exec(e);return typeof n=="string"?n:n(e,r)}}function _Ce(e){return BCe.map(t=>typeof t=="string"?[t,t]:t).find(([t,n])=>e.startsWith(`${t}-`))}const BCe=["break-after","break-before","break-inside","grid-flow","align","whitespace","mix-blend","bg-blend","ease","origin","cursor","touch","color",["text","color"],["c","color"],["bg","background-color"],["decoration","text-decoration-color"],["from","gradient-color-stops"],["divide","divide-color"],["outline","outline-color"],["ring","ring-color"],["ring-offset","ring-offset-color"],["shadow","box-shadow-color"],["accent","accent-color"],["caret","caret-color"],"fill","stroke"],v_=new Map(Object.entries({flex:["flex-grow","flex-shrink","flex-basis"],"transiton-none":["transition-duration","transition-delay","transition-timing-function","transition-property"],m:["mt","mb","ml","mr","mx","my"],mx:["ml","mr"],my:["mt","mb"],p:["pt","pb","pl","pr","px","py"],px:["pl","pr"],py:["pt","pb"]}));function LCe(e){return (e||"").split(" ").map(t=>t.trim()).filter(Boolean)}function Jj(...e){let t=new Map;return LCe(X(...e)).filter(Boolean).forEach(n=>zCe(n,t)),PCe(Array.from(t.values())).join(" ")}function zCe(e,t){let n=e,r;function o(p){[p].flat().forEach(g=>{v_.has(g)&&[v_.get(g)].flat().filter(b=>b!==void 0).forEach(b=>{t.delete(r?r+b:b);}),t.set(r?r+g:g,n);});}function i(){let p=DCe(e);if(p)return o(p),true}function a(){let p=_Ce(e);if(!p)return;let[g,b]=p;return o(b),true}function l(){let p=e,g=/(\[[\w,()/-]+\])$/;g.test(e)&&(p=e.replace(g,function(y,S){return "*".repeat(S.length)})),p=p.replaceAll(/--(?=\d)/g,"-*");let b=p.lastIndexOf("-");if(b!==-1)return o(e.slice(0,b)),true}function u(){return o(e)}function d(){let p=/^(?:(?:[\w-]+|\[\S+\]):)+/.exec(e);p&&(r=p[0].split(new RegExp("(?<=:)(?:\\b|$)")).filter(Boolean).sort().join(""),e=e.slice(r.length));}function m(){if(e.startsWith("!")){e="important:"+e.slice(1);return}if(e.endsWith("!")){e="important:"+e.slice(0,-1);return}}i()||a()||(m(),d(),i()||a()||l()||u());}function ur(...e){let t=f.useMemo(()=>X(...e),[...e]);return f.useMemo(()=>Jj(t),[t])}const fu="inline-block cursor-pointer rounded bg-gate-primary-lv-3 px-6px text-white line-height-tight font-mono";function b_({className:e,...t}){return x("kbd",{...t,className:ur(fu,e)})}const eU=x(vT,{className:"text-gate-primary [.ant-spin_.ant-spin-dot&]:size-25px"}),tU="flex items-center gap-x-1 [&.ant-btn:not(:disabled):focus-visible]:outline-0";function y_(e){if(/^z-\d+$/.test(e))return Number.parseInt(e.slice(2))}const kCe="z-1001",FCe="z-10004",HCe="z-10005",S_="z-11000",VCe="z-11200",jCe="z-11300",UCe="z-90000",C_={default:X("fixed left-50% top-50% max-w-450px min-w-200px w-[max-content] translate-x--50% translate-y--50% whitespace-pre-wrap rounded-6px bg-gate-primary px-24px py-12px text-14px text-white",UCe),singleLine:"text-center"};function rn(e,t=2e3,n=document.body){const r=document.createElement("div");r.textContent=e;const o=!e.includes(`
`)&&!e.includes("<br");r.className=X($a,C_.default,o&&C_.singleLine),n.appendChild(r),setTimeout(()=>r.remove(),t);}function nU(){return rn(Ef)}var Rw,x_;function WCe(){if(x_)return Rw;x_=1;var e=1e3,t=e*60,n=t*60,r=n*24,o=r*7,i=r*365.25;Rw=function(m,p){p=p||{};var g=typeof m;if(g==="string"&&m.length>0)return a(m);if(g==="number"&&isFinite(m))return p.long?u(m):l(m);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(m))};function a(m){if(m=String(m),!(m.length>100)){var p=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(m);if(p){var g=parseFloat(p[1]),b=(p[2]||"ms").toLowerCase();switch(b){case "years":case "year":case "yrs":case "yr":case "y":return g*i;case "weeks":case "week":case "w":return g*o;case "days":case "day":case "d":return g*r;case "hours":case "hour":case "hrs":case "hr":case "h":return g*n;case "minutes":case "minute":case "mins":case "min":case "m":return g*t;case "seconds":case "second":case "secs":case "sec":case "s":return g*e;case "milliseconds":case "millisecond":case "msecs":case "msec":case "ms":return g;default:return}}}}function l(m){var p=Math.abs(m);return p>=r?Math.round(m/r)+"d":p>=n?Math.round(m/n)+"h":p>=t?Math.round(m/t)+"m":p>=e?Math.round(m/e)+"s":m+"ms"}function u(m){var p=Math.abs(m);return p>=r?d(m,p,r,"day"):p>=n?d(m,p,n,"hour"):p>=t?d(m,p,t,"minute"):p>=e?d(m,p,e,"second"):m+" ms"}function d(m,p,g,b){var y=p>=g*1.5;return Math.round(m/g)+" "+b+(y?"s":"")}return Rw}var GCe=WCe();const lo=Io(GCe);var Tw,w_;function qCe(){return w_||(w_=1,Tw=function(t){return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}),Tw}var Aw,$_;function KCe(){return $_||($_=1,Aw=function(t,n){return n?t.replace(/\/?\/$/,"")+"/"+n.replace(/^\/+/,""):t}),Aw}var Nw,E_;function YCe(){if(E_)return Nw;E_=1;var e=qCe(),t=KCe();return Nw=function(r,o,i){var a=!e(o);return r&&(a||i===false)?t(r,o):o},Nw}var XCe=YCe();const QCe=Io(XCe);var Pw,M_;function ZCe(){return M_||(M_=1,Pw=function(t,n){return function(){return t.apply(n,arguments)}}),Pw}var Iw,R_;function gg(){if(R_)return Iw;R_=1;var e=ZCe(),t=Object.prototype.toString,n=(function(D){return function(L){var K=t.call(L);return D[K]||(D[K]=K.slice(8,-1).toLowerCase())}})(Object.create(null));function r(D){return D=D.toLowerCase(),function(K){return n(K)===D}}function o(D){return Array.isArray(D)}function i(D){return typeof D>"u"}function a(D){return D!==null&&!i(D)&&D.constructor!==null&&!i(D.constructor)&&typeof D.constructor.isBuffer=="function"&&D.constructor.isBuffer(D)}var l=r("ArrayBuffer");function u(D){var L;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?L=ArrayBuffer.isView(D):L=D&&D.buffer&&l(D.buffer),L}function d(D){return typeof D=="string"}function m(D){return typeof D=="number"}function p(D){return D!==null&&typeof D=="object"}function g(D){if(n(D)!=="object")return false;var L=Object.getPrototypeOf(D);return L===null||L===Object.prototype}function b(D){return D&&Object.keys(D).length===0&&Object.getPrototypeOf(D)===Object.prototype}var y=r("Date"),S=r("File"),C=r("Blob"),w=r("FileList");function $(D){return t.call(D)==="[object Function]"}function M(D){return p(D)&&$(D.pipe)}function T(D){var L="[object FormData]";return D&&(typeof FormData=="function"&&D instanceof FormData||t.call(D)===L||$(D.toString)&&D.toString()===L)}var R=r("URLSearchParams");function I(D){return D.trim?D.trim():D.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}function N(){var D;return typeof navigator<"u"&&((D=navigator.product)==="ReactNative"||D==="NativeScript"||D==="NS")?false:typeof window<"u"&&typeof document<"u"}function P(D,L){if(!(D===null||typeof D>"u"))if(typeof D!="object"&&(D=[D]),o(D))for(var K=0,J=D.length;K<J;K++)L.call(null,D[K],K,D);else for(var ee in D)Object.prototype.hasOwnProperty.call(D,ee)&&L.call(null,D[ee],ee,D);}function O(){var D={};function L(ee,te){g(D[te])&&g(ee)?D[te]=O(D[te],ee):g(ee)?D[te]=O({},ee):o(ee)?D[te]=ee.slice():D[te]=ee;}for(var K=0,J=arguments.length;K<J;K++)P(arguments[K],L);return D}function _(D,L,K){return P(L,function(ee,te){K&&typeof ee=="function"?D[te]=e(ee,K):D[te]=ee;}),D}function B(D){return D.charCodeAt(0)===65279&&(D=D.slice(1)),D}function V(D,L,K,J){D.prototype=Object.create(L.prototype,J),D.prototype.constructor=D,K&&Object.assign(D.prototype,K);}function U(D,L,K,J){var ee,te,re,ie={};if(L=L||{},D==null)return L;do{for(ee=Object.getOwnPropertyNames(D),te=ee.length;te-- >0;)re=ee[te],(!J||J(re,D,L))&&!ie[re]&&(L[re]=D[re],ie[re]=true);D=K!==false&&Object.getPrototypeOf(D);}while(D&&(!K||K(D,L))&&D!==Object.prototype);return L}function G(D,L,K){D=String(D),(K===void 0||K>D.length)&&(K=D.length),K-=L.length;var J=D.indexOf(L,K);return J!==-1&&J===K}function H(D){if(!D)return null;if(o(D))return D;var L=D.length;if(!m(L))return null;for(var K=new Array(L);L-- >0;)K[L]=D[L];return K}var z=(function(D){return function(L){return D&&L instanceof D}})(typeof Uint8Array<"u"&&Object.getPrototypeOf(Uint8Array));function j(D,L){for(var K=D&&D[Symbol.iterator],J=K.call(D),ee;(ee=J.next())&&!ee.done;){var te=ee.value;L.call(D,te[0],te[1]);}}function W(D,L){for(var K,J=[];(K=D.exec(L))!==null;)J.push(K);return J}var Y=r("HTMLFormElement"),Q=(function(L){return function(K,J){return L.call(K,J)}})(Object.prototype.hasOwnProperty);return Iw={isArray:o,isArrayBuffer:l,isBuffer:a,isFormData:T,isArrayBufferView:u,isString:d,isNumber:m,isObject:p,isPlainObject:g,isEmptyObject:b,isUndefined:i,isDate:y,isFile:S,isBlob:C,isFunction:$,isStream:M,isURLSearchParams:R,isStandardBrowserEnv:N,forEach:P,merge:O,extend:_,trim:I,stripBOM:B,inherits:V,toFlatObject:U,kindOf:n,kindOfTest:r,endsWith:G,toArray:H,isTypedArray:z,isFileList:w,forEachEntry:j,matchAll:W,isHTMLForm:Y,hasOwnProperty:Q},Iw}var Ow,T_;function rU(){if(T_)return Ow;T_=1;var e=gg();function t(o,i,a,l,u){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=o,this.name="AxiosError",i&&(this.code=i),a&&(this.config=a),l&&(this.request=l),u&&(this.response=u);}e.inherits(t,Error,{toJSON:function(){return {message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var n=t.prototype,r={};return ["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(function(o){r[o]={value:o};}),Object.defineProperties(t,r),Object.defineProperty(n,"isAxiosError",{value:true}),t.from=function(o,i,a,l,u,d){var m=Object.create(n);return e.toFlatObject(o,m,function(g){return g!==Error.prototype}),t.call(m,o.message,i,a,l,u),m.cause=o,m.name=o.name,d&&Object.assign(m,d),m},Ow=t,Ow}var Dw,A_;function JCe(){if(A_)return Dw;A_=1;var e=rU();return Dw=function(n,r,o){var i=o.config.validateStatus;!o.status||!i||i(o.status)?n(o):r(new e("Request failed with status code "+o.status,[e.ERR_BAD_REQUEST,e.ERR_BAD_RESPONSE][Math.floor(o.status/100)-4],o.config,o.request,o));},Dw}var exe=JCe();const txe=Io(exe);var _w,N_;function nxe(){return N_||(N_=1,_w=typeof self=="object"?self.FormData:window.FormData),_w}var Bw,P_;function rxe(){return P_||(P_=1,Bw=nxe()),Bw}var Lw,I_;function oxe(){if(I_)return Lw;I_=1;var e=gg(),t=rU(),n=rxe();function r(m){return e.isPlainObject(m)||e.isArray(m)}function o(m){return e.endsWith(m,"[]")?m.slice(0,-2):m}function i(m,p,g){return m?m.concat(p).map(function(y,S){return y=o(y),!g&&S?"["+y+"]":y}).join(g?".":""):p}function a(m){return e.isArray(m)&&!m.some(r)}var l=e.toFlatObject(e,{},null,function(p){return /^is[A-Z]/.test(p)});function u(m){return m&&e.isFunction(m.append)&&m[Symbol.toStringTag]==="FormData"&&m[Symbol.iterator]}function d(m,p,g){if(!e.isObject(m))throw new TypeError("target must be an object");p=p||new(n||FormData),g=e.toFlatObject(g,{metaTokens:true,dots:false,indexes:false},false,function(O,_){return !e.isUndefined(_[O])});var b=g.metaTokens,y=g.visitor||T,S=g.dots,C=g.indexes,w=g.Blob||typeof Blob<"u"&&Blob,$=w&&u(p);if(!e.isFunction(y))throw new TypeError("visitor must be a function");function M(P){if(P===null)return "";if(e.isDate(P))return P.toISOString();if(!$&&e.isBlob(P))throw new t("Blob is not supported. Use a Buffer instead.");return e.isArrayBuffer(P)||e.isTypedArray(P)?$&&typeof Blob=="function"?new Blob([P]):Buffer.from(P):P}function T(P,O,_){var B=P;if(P&&!_&&typeof P=="object"){if(e.endsWith(O,"{}"))O=b?O:O.slice(0,-2),P=JSON.stringify(P);else if(e.isArray(P)&&a(P)||e.isFileList(P)||e.endsWith(O,"[]")&&(B=e.toArray(P)))return O=o(O),B.forEach(function(U,G){!(e.isUndefined(U)||U===null)&&p.append(C===true?i([O],G,S):C===null?O:O+"[]",M(U));}),false}return r(P)?true:(p.append(i(_,O,S),M(P)),false)}var R=[],I=Object.assign(l,{defaultVisitor:T,convertValue:M,isVisitable:r});function N(P,O){if(!e.isUndefined(P)){if(R.indexOf(P)!==-1)throw Error("Circular reference detected in "+O.join("."));R.push(P),e.forEach(P,function(B,V){var U=!(e.isUndefined(B)||B===null)&&y.call(p,B,e.isString(V)?V.trim():V,O,I);U===true&&N(B,O?O.concat(V):[V]);}),R.pop();}}if(!e.isObject(m))throw new TypeError("data must be an object");return N(m),p}return Lw=d,Lw}var zw,O_;function ixe(){if(O_)return zw;O_=1;var e=oxe();function t(o){var i={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(o).replace(/[!'\(\)~]|%20|%00/g,function(l){return i[l]})}function n(o,i){this._pairs=[],o&&e(o,this,i);}var r=n.prototype;return r.append=function(i,a){this._pairs.push([i,a]);},r.toString=function(i){var a=i?function(l){return i.call(this,l,t)}:t;return this._pairs.map(function(u){return a(u[0])+"="+a(u[1])},"").join("&")},zw=n,zw}var kw,D_;function axe(){if(D_)return kw;D_=1;var e=gg(),t=ixe();function n(r){return encodeURIComponent(r).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}return kw=function(o,i,a){if(!i)return o;var l=o.indexOf("#");l!==-1&&(o=o.slice(0,l));var u=a&&a.encode||n,d=a&&a.serialize,m;return d?m=d(i,a):m=e.isURLSearchParams(i)?i.toString():new t(i,a).toString(u),m&&(o+=(o.indexOf("?")===-1?"?":"&")+m),o},kw}var sxe=axe();const lxe=Io(sxe);var Fw,__;function cxe(){if(__)return Fw;__=1;var e=gg(),t=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];return Fw=function(r){var o={},i,a,l;return r&&e.forEach(r.split(`
`),function(d){if(l=d.indexOf(":"),i=e.trim(d.slice(0,l)).toLowerCase(),a=e.trim(d.slice(l+1)),i){if(o[i]&&t.indexOf(i)>=0)return;i==="set-cookie"?o[i]=(o[i]?o[i]:[]).concat([a]):o[i]=o[i]?o[i]+", "+a:a;}}),o},Fw}var uxe=cxe();const dxe=Io(uxe);var fxe=gg();const B_=Io(fxe);function mxe(e){return new Promise((t,n)=>{let r=e.data;const o=e.headers??{};if(B_.isFormData(r)&&delete o["Content-Type"],e.auth){const m=e.auth.username||"",p=e.auth.password||"";o.Authorization="Basic "+Buffer.from(m+":"+p).toString("base64");}const i=function(){n(new pM.AxiosError("Network Error",pM.AxiosError.ERR_NETWORK,e));},a=function(){n(new pM.AxiosError("timeout of "+e.timeout+"ms exceeded",pM.AxiosError.ECONNABORTED,e));};B_.forEach(o,function(p,g){typeof r>"u"&&g.toLowerCase()==="content-type"&&delete o[g];}),r===void 0&&(r=null);const l=function(p){const g="responseHeaders"in p?dxe(p.responseHeaders):{},y={data:!e.responseType||e.responseType==="text"?p.responseText:p.response,status:p.status,statusText:p.statusText,headers:g,config:e,request:{responseURL:p.finalUrl,status:p.status,statusText:p.statusText,responseXML:null}};txe(t,n,y);};e.cancelToken&&e.cancelToken.promise.then(function(p){n(p);});let u;e.responseType&&e.responseType!=="json"&&(u=e.responseType);const d=e.method.toUpperCase();d==="UNLINK"||d==="PURGE"||d==="LINK"?n(new pM.AxiosError(`${d} is not a supported method by GM.xmlHttpRequest`)):GM.xmlHttpRequest({method:d,url:lxe(QCe(e.baseURL,e.url),e.params,e.paramsSerializer),headers:Object.fromEntries(Object.entries(o).map(([m,p])=>[m,p.toString()])),responseType:u,data:r,timeout:e.timeout,ontimeout:a,onload:l,onerror:i});})}const Hw=()=>Yn().format("YYYY-MM-DD");function oU(e){async function t(){const n=Hw();(await GM.listValues()).filter(o=>o.startsWith(`${e}:`)&&o!==`${e}:${n}`).forEach(o=>GM.deleteValue(o));}return t(),{async set(n){t(),await GM.setValue(`${e}:${Hw()}`,n);},get(){return t(),GM.getValue(`${e}:${Hw()}`)}}}const hxe=(e,t,n,r)=>{if(n==="length"||n==="prototype"||n==="arguments"||n==="caller")return;const o=Object.getOwnPropertyDescriptor(e,n),i=Object.getOwnPropertyDescriptor(t,n);!pxe(o,i)&&r||Object.defineProperty(e,n,i);},pxe=function(e,t){return e===void 0||e.configurable||e.writable===t.writable&&e.enumerable===t.enumerable&&e.configurable===t.configurable&&(e.writable||e.value===t.value)},gxe=(e,t)=>{const n=Object.getPrototypeOf(t);n!==Object.getPrototypeOf(e)&&Object.setPrototypeOf(e,n);},vxe=(e,t)=>`/* Wrapped ${e}*/
${t}`,bxe=Object.getOwnPropertyDescriptor(Function.prototype,"toString"),yxe=Object.getOwnPropertyDescriptor(Function.prototype.toString,"name"),Sxe=(e,t,n)=>{const r=n===""?"":`with ${n.trim()}() `,o=vxe.bind(null,r,t.toString());Object.defineProperty(o,"name",yxe);const{writable:i,enumerable:a,configurable:l}=bxe;Object.defineProperty(e,"toString",{value:o,writable:i,enumerable:a,configurable:l});};function Cxe(e,t,{ignoreNonConfigurable:n=false}={}){const{name:r}=e;for(const o of Reflect.ownKeys(t))hxe(e,t,o,n);return gxe(e,t),Sxe(e,t,r),e}const xxe=new WeakMap;function aA(e,t){const n=([l])=>l,{cacheKey:r=n,cache:o=new Map}=t??{},i=new Map,a=function(...l){const u=r(l);if(i.has(u))return i.get(u);const d=(async()=>{try{if(o&&await o.has(u))return await o.get(u);const p=await e.apply(this,l);try{return p}finally{o&&(!t?.shouldCache||await t.shouldCache(p,{key:u,argumentsList:l}))&&await o.set(u,p);}}finally{i.delete(u);}})();return i.set(u,d),d};return Cxe(a,e,{ignoreNonConfigurable:true}),xxe.set(a,o),a}function Hs(e,t){return t??=(...n)=>JSON.stringify(n),aA(e,{cache:false,cacheKey(n){return t(...n)}})}async function T1(e){const{img_key:t,sub_key:n}=await wxe(),r=Mxe(t+n),o=Math.round(Date.now()/1e3),i={...e,wts:o},a=/[!'()*]/g,l=Object.keys(i).sort().map(d=>`${encodeURIComponent(d)}=${encodeURIComponent(i[d].toString().replaceAll(a,""))}`).join("&"),u=sparkMd5.hash(l+r);return {...i,wts:o,w_rid:u}}const iU=oU("wbi-keys"),wxe=Hs(async function(){const e=await iU.get();return e?.val&&e?.ts&&Date.now()-e.ts<=lo("6h")?e.val:$xe()});async function $xe(){const t=(await pM.get("/x/web-interface/nav",{baseURL:wL})).data,n=t.data.wbi_img.img_url,r=t.data.wbi_img.sub_url,o={img_key:n.slice(n.lastIndexOf("/")+1,n.lastIndexOf(".")),sub_key:r.slice(r.lastIndexOf("/")+1,r.lastIndexOf("."))};return await iU.set({val:o,ts:Date.now()}),o}const Exe=[46,47,18,2,53,8,23,32,15,50,10,31,58,3,45,35,27,43,5,49,33,9,42,19,29,28,14,39,12,38,41,13,37,48,7,16,24,55,40,61,26,17,0,1,60,51,30,4,22,25,54,21,56,59,6,63,57,62,11,36,20,34,44,52];function Mxe(e){return Exe.map(t=>e[t]).join("").slice(0,32)}function aU(e,t,n){e.appkey=t;const r=new URLSearchParams(e);return r.sort(),sparkMd5.hash(r.toString()+n)}const Rxe={platform:"ios",mobi_app:"ipad",device:"pad",build:"37300100",c_locale:"zh-Hans_CN",s_locale:"zh-Hans_CN"};class sA extends Error{constructor(t,n){t||="需要有效的 access_key",super(t,{cause:n}),this.name="NeedValidAccessKeyError";}}const Qt=pM.create({baseURL:wL,withCredentials:true});Qt.interceptors.request.use(async function(e){return e.params||={},e.url?.includes("/wbi/")&&!(e.params.w_rid||e.params.wts)&&(e.params=await T1(e.params)),e});function jn(e){return e?.code===0&&["0","success","ok"].includes(e?.message?.toLowerCase())}class Txe extends Error{constructor(t){const n="WebApiError: "+t.message;super(n),this.json=t,this.name="WebApiError";}}const vg=pM.create({adapter:mxe});vg.interceptors.request.use(function(e){if(!e.params?.sign){const{appkey:t,appsec:n}=Qh;e.params={appkey:t,access_key:at.accessKey||"",...uL(e.params,["sign"])},e.params.sign=aU(e.params,t,n);}return e});vg.interceptors.response.use(e=>{if(e.config.responseType==="json"&&e.data&&e.data instanceof ArrayBuffer){Ko("response data is ArrayBuffer");const t=new TextDecoder,n=new Uint8Array(e.data),r=t.decode(n);e.data=r;try{e.data=JSON.parse(r);}catch{}}return e});function lA(){const e={};return document.cookie.split(";").map(t=>t.trim()).filter(Boolean).forEach(t=>{const[n,r]=t.split("=").map(o=>o.trim()).filter(Boolean);n&&(e[n]=r);}),e}function oc(){const e=lA().bili_jct;if(!e)throw rn("找不到 csrf token, 请检查是否登录"),new Error("找不到 csrf token, 请检查是否登录");return e}function Jo(){return lA().DedeUserID}function A1(){return !!lA().DedeUserID}const _3=nc(()=>({cookie:document.cookie,logined:A1()}));function sU(){return _3.update(),_3.state.value.logined}function cA(){return _3.use().logined}async function L_(){return (await Qt.get("https://member.bilibili.com/x/web/draft/list")).data.artlist?.drafts||[]}async function Vw(e){const t=new URLSearchParams({title:"",banner_url:"",content:"",summary:"",words:"0",category:"15",tid:"0",reprint:"0",tags:"",image_urls:"",origin_image_urls:"",dynamic_intro:"",media_id:"0",spoiler:"0",original:"0",top_video_bvid:"",aid:"",csrf:oc(),...e}),n=(await Qt.post("/x/article/creative/draft/addupdate",t)).data,r=n?.data?.aid?.toString(),o=jn(n);return o||rn(n.message||"addupdate error"),{success:o,aid:r}}async function Axe(e){return (await Qt.get("/x/article/creative/draft/view",{params:{aid:e}})).data?.data?.content||""}class Nxe{title;constructor(t){this.title=t;}getData=async()=>{const{title:t}=this,r=(await L_()).find(u=>u.title===t);if(!r){const{success:u,aid:d}=await Vw({title:t});return}const o=await Axe(r.id),l=(new DOMParser().parseFromString(o,"text/html").body.textContent||"").trim();if(l)try{return JSON.parse(l)}catch{return}};_aid;setData=async t=>{const{title:n}=this;if(!this._aid){const a=(await L_()).find(l=>l.title===n);if(a)this._aid=a.id.toString();else {const{success:l,aid:u}=await Vw({title:n});if(!l)return false;this._aid=u;}}const r=JSON.stringify(t),{success:o}=await Vw({aid:this._aid,title:n,content:`<p>${r}</p>`,words:r.length.toString()});return o}}const Pxe=ao.extend("settings"),lU=new Nxe(Ao),cU=["accessKey","accessKeyExpireAt"],Ixe=()=>[...cU,...vy,"backupSettingsToArticleDraft","fav.addSeparator","watchlaterAddSeparator","watchlaterItemsOrder","popularWeeklyUseShuffle","popularGeneralUseAnonymous"],Oxe=[...cU,"backupSettingsToArticleDraft"];let uU=false;function dU(e){uU=e;}let jw;const Dxe=Yl(lU.setData,lo("5s"));async function _xe(e){if(!e.backupSettingsToArticleDraft||uU)return;const{pickedSettings:t}=Wf(e,ic,Ixe());if(!jw||!fa(jw,t))try{await Dxe(t),jw=t,Pxe("backup to article draft complete");}catch(r){console.error(r.stack||r);}}const Bxe=ao.extend("settings"),bg={accessKey:"",accessKeyExpireAt:0,pureRecommend:true,appRecommend:{addOtherTabContents:false},modalFeedFullScreen:false,grid:{useCustomGrid:true,gridDisplayMode:kr.NormalGrid,twoColumnModeAlign:ru.Center,enableForceColumn:false,forceColumnCount:4,cardMinWidth:320},videoCard:{actions:{openInPipWindow:false,showLargePreview:true},videoPreview:{useMp4:true,useScale:false,useVideoCardAsTrigger:false,usePreferredCdn:true,addTo:{searchPage:true}},imgPreview:{enabled:true,autoPreviewWhenKeyboardSelect:false,autoPreviewWhenHover:true,disableWhenMultiSelecting:true}},autoPreviewUpdateInterval:700,useDelayForHover:false,enableSidebar:true,sidebarAlign:gf.Right,dynamicFeed:{showLive:true,videoOnly:false,followGroup:{enabled:true,forceUseMergeTimelineIds:[]},whenViewAll:{enableHideSomeContents:false,hideIds:[]},advancedFilter:false,__internal:{cacheAllItemsEntry:false,cacheAllItemsUpMids:[],externalFilterInput:false}},watchlaterAddSeparator:true,watchlaterItemsOrder:bo.AddTimeDesc,watchlaterUseNormalVideoUrl:false,fav:{addSeparator:true,excludedFolderIds:[],useCustomFavPicker:{onPlayPage:false}},popularGeneralUseAnonymous:false,popularWeeklyUseShuffle:false,spaceUpload:{showVol:false,useSyncFilterTextFromSearchText:false},filter:{enabled:true,minDuration:{enabled:false,value:60},minPlayCount:{enabled:false,value:1e4},minDanmakuCount:{enabled:false,value:10},exemptForFollowed:{video:true,picture:true},hideGotoTypePicture:false,hideGotoTypeBangumi:false,byAuthor:{enabled:false,keywords:[]},byTitle:{enabled:false,keywords:[]},dfByTitle:{enabled:false,keywords:[]},dfHideOpusMids:{enabled:false,keywords:[]}},style:{general:{popoverBorderColorUseColorPrimary:false},pureRecommend:{useStickyTabbar:true,stickyTabbarShadow:false,useWhiteBackground:true,hideTopChannel:false},videoCard:{useBorder:true,useBorderOnlyOnHover:true,useBoxShadow:false}},theme:"",colorPickerThemeSelectedColor:"",backupSettingsToArticleDraft:false,videoLinkOpenMode:sr.Normal,pipWindow:{defaultLocked:true,autoWebFullscreen:true},hidingTabKeys:[nt.KeepFollowOnly,nt.Live,nt.Liked],customTabKeysOrder:[],showBackForwardButtons:false,multiSelect:{clearWhenExit:true,showIcon:true},__internalEnableCopyBvidInfo:false,__internalAddTabbarCopyBvidButton:false,__internalHotSubUseDropdown:false,__internalRecTabRenderAsSegments:false},at=zn(ef(bg)),ic=NCe(bg),vy=ic.filter(e=>e.includes("__internal")&&typeof To(bg,e)=="boolean");Bxe("allowedLeafSettingsPaths = %O, internalBooleanPaths = %O",ic,vy);function Ut(e){return bt(at,e)}function yg(){return Fr(at)}const uA="settings";async function fU(){const e=await GM.getValue(uA);return !e||typeof e!="object"?{}:(dA(e),Wf(e,ic).pickedSettings)}async function Lxe(){const e=await fU();Ka(e),Xa(at,()=>{zxe();}),dT({storageKey:uA,setPersist(t){mU=t;},onUpdate(t){Ka(t);}});}async function zxe(){const e=ef(Fr(at));await kxe(e),await _xe(e);}let mU=true;async function kxe(e){mU&&await GM.setValue(uA,e);}function Ka(e){const{pickedPaths:t}=Wf(e,ic);for(const n of t){const r=To(e,n);$f(at,n,r);}}function Fxe(){return Ka(bg)}function dA(e){if(!e)return;const t=[["dynamicFeed.showLive","dynamicFeedShowLive"],["dynamicFeed.followGroup.enabled","dynamicFeedFollowGroupEnabled"],["dynamicFeed.followGroup.forceUseMergeTimelineIds","dynamicFeedFollowGroupForceUseMergeTimelineIds"],["dynamicFeed.whenViewAll.enableHideSomeContents","dynamicFeedWhenViewAllEnableHideSomeContents"],["dynamicFeed.whenViewAll.hideIds","dynamicFeedWhenViewAllHideIds"],["fav.addSeparator","favAddSeparator"],["fav.excludedFolderIds","favExcludedFolderIds"],["filter.enabled","filterEnabled"],["filter.minPlayCount.enabled","filterMinPlayCountEnabled"],["filter.minPlayCount.value","filterMinPlayCount"],["filter.minDuration.enabled","filterMinDurationEnabled"],["filter.minDuration.value","filterMinDuration"],["filter.exemptForFollowed.video","exemptForFollowedVideo"],["filter.exemptForFollowed.picture","exemptForFollowedPicture"],["filter.hideGotoTypePicture","filterOutGotoTypePicture"],["filter.hideGotoTypeBangumi","filterOutGotoTypeBangumi"],["filter.byAuthor.enabled","filterByAuthorNameEnabled"],["filter.byAuthor.keywords","filterByAuthorNameKeywords"],["filter.byTitle.enabled","filterByTitleEnabled"],["filter.byTitle.keywords","filterByTitleKeywords"],["style.pureRecommend.useStickyTabbar","styleUseStickyTabbarInPureRecommend"],["style.pureRecommend.useWhiteBackground","styleUseWhiteBackground"],["style.pureRecommend.hideTopChannel","styleHideTopChannel"],["style.videoCard.useBorder","styleUseCardBorder"],["style.videoCard.useBorderOnlyOnHover","styleUseCardBorderOnlyOnHover"],["style.videoCard.useBoxShadow","styleUseCardBoxShadow"],["pipWindow.defaultLocked","pipWindowDefaultLocked"],["videoCard.imgPreview.autoPreviewWhenKeyboardSelect","autoPreviewWhenKeyboardSelect"],["videoCard.imgPreview.autoPreviewWhenHover","autoPreviewWhenHover"],["grid.useCustomGrid","style.pureRecommend.useCustomGrid"],["grid.enableForceColumn","grid.enableForceCoumn"],["dynamicFeed.advancedFilter","dynamicFeedAdvancedSearch"],["dynamicFeed.advancedFilter","dynamicFeed.advancedSearch"]];for(const[n,r]of t){const o=i=>!Ha(i);o(To(e,n))||o(To(e,r))&&$f(e,n,To(e,r));}}function Wf(e,t,n=[]){const r={},o=t.filter(i=>ic.includes(i)&&!n.includes(i)&&!Ha(To(e,i)));return o.forEach(i=>{const a=To(e,i);$f(r,i,a);}),{pickedPaths:o,pickedSettings:r}}function hU(e){const t=Ut();return To(t,e)}async function N1(e){const t=await fU();return To(t,e)||To(yg(),e)}function Hxe(e,t){$f(at,e,t);}async function Ua(e,{add:t,remove:n}){const r=await N1(e),o=new Set(r);for(const i of t??[])o.add(i);for(const i of n??[])o.delete(i);Hxe(e,Array.from(o));}await( Lxe());_s&&at.accessKey&&at.accessKeyExpireAt&&Date.now()>=at.accessKeyExpireAt&&rn("access_key 已过期, 请重新获取 !!!");var i0={exports:{}},Vxe=i0.exports,z_;function jxe(){return z_||(z_=1,(function(e,t){(function(n,r){e.exports=r();})(Vxe,(function(){var n,r,o=1e3,i=6e4,a=36e5,l=864e5,u=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,d=31536e6,m=2628e6,p=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,g={years:d,months:m,days:l,hours:a,minutes:i,seconds:o,milliseconds:1,weeks:6048e5},b=function(I){return I instanceof T},y=function(I,N,P){return new T(I,P,N.$l)},S=function(I){return r.p(I)+"s"},C=function(I){return I<0},w=function(I){return C(I)?Math.ceil(I):Math.floor(I)},$=function(I){return Math.abs(I)},M=function(I,N){return I?C(I)?{negative:true,format:""+$(I)+N}:{negative:false,format:""+I+N}:{negative:false,format:""}},T=(function(){function I(P,O,_){var B=this;if(this.$d={},this.$l=_,P===void 0&&(this.$ms=0,this.parseFromMilliseconds()),O)return y(P*g[S(O)],this);if(typeof P=="number")return this.$ms=P,this.parseFromMilliseconds(),this;if(typeof P=="object")return Object.keys(P).forEach((function(G){B.$d[S(G)]=P[G];})),this.calMilliseconds(),this;if(typeof P=="string"){var V=P.match(p);if(V){var U=V.slice(2).map((function(G){return G!=null?Number(G):0}));return this.$d.years=U[0],this.$d.months=U[1],this.$d.weeks=U[2],this.$d.days=U[3],this.$d.hours=U[4],this.$d.minutes=U[5],this.$d.seconds=U[6],this.calMilliseconds(),this}}return this}var N=I.prototype;return N.calMilliseconds=function(){var P=this;this.$ms=Object.keys(this.$d).reduce((function(O,_){return O+(P.$d[_]||0)*g[_]}),0);},N.parseFromMilliseconds=function(){var P=this.$ms;this.$d.years=w(P/d),P%=d,this.$d.months=w(P/m),P%=m,this.$d.days=w(P/l),P%=l,this.$d.hours=w(P/a),P%=a,this.$d.minutes=w(P/i),P%=i,this.$d.seconds=w(P/o),P%=o,this.$d.milliseconds=P;},N.toISOString=function(){var P=M(this.$d.years,"Y"),O=M(this.$d.months,"M"),_=+this.$d.days||0;this.$d.weeks&&(_+=7*this.$d.weeks);var B=M(_,"D"),V=M(this.$d.hours,"H"),U=M(this.$d.minutes,"M"),G=this.$d.seconds||0;this.$d.milliseconds&&(G+=this.$d.milliseconds/1e3,G=Math.round(1e3*G)/1e3);var H=M(G,"S"),z=P.negative||O.negative||B.negative||V.negative||U.negative||H.negative,j=V.format||U.format||H.format?"T":"",W=(z?"-":"")+"P"+P.format+O.format+B.format+j+V.format+U.format+H.format;return W==="P"||W==="-P"?"P0D":W},N.toJSON=function(){return this.toISOString()},N.format=function(P){var O=P||"YYYY-MM-DDTHH:mm:ss",_={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return O.replace(u,(function(B,V){return V||String(_[B])}))},N.as=function(P){return this.$ms/g[S(P)]},N.get=function(P){var O=this.$ms,_=S(P);return _==="milliseconds"?O%=1e3:O=_==="weeks"?w(O/g[_]):this.$d[_],O||0},N.add=function(P,O,_){var B;return B=O?P*g[S(O)]:b(P)?P.$ms:y(P,this).$ms,y(this.$ms+B*(_?-1:1),this)},N.subtract=function(P,O){return this.add(P,O,true)},N.locale=function(P){var O=this.clone();return O.$l=P,O},N.clone=function(){return y(this.$ms,this)},N.humanize=function(P){return n().add(this.$ms,"ms").locale(this.$l).fromNow(!P)},N.valueOf=function(){return this.asMilliseconds()},N.milliseconds=function(){return this.get("milliseconds")},N.asMilliseconds=function(){return this.as("milliseconds")},N.seconds=function(){return this.get("seconds")},N.asSeconds=function(){return this.as("seconds")},N.minutes=function(){return this.get("minutes")},N.asMinutes=function(){return this.as("minutes")},N.hours=function(){return this.get("hours")},N.asHours=function(){return this.as("hours")},N.days=function(){return this.get("days")},N.asDays=function(){return this.as("days")},N.weeks=function(){return this.get("weeks")},N.asWeeks=function(){return this.as("weeks")},N.months=function(){return this.get("months")},N.asMonths=function(){return this.as("months")},N.years=function(){return this.get("years")},N.asYears=function(){return this.as("years")},I})(),R=function(I,N,P){return I.add(N.years()*P,"y").add(N.months()*P,"M").add(N.days()*P,"d").add(N.hours()*P,"h").add(N.minutes()*P,"m").add(N.seconds()*P,"s").add(N.milliseconds()*P,"ms")};return function(I,N,P){n=P,r=P().$utils(),P.duration=function(B,V){var U=P.locale();return y(B,{$l:U},V)},P.isDuration=b;var O=N.prototype.add,_=N.prototype.subtract;N.prototype.add=function(B,V){return b(B)?R(this,B,1):O.bind(this)(B,V)},N.prototype.subtract=function(B,V){return b(B)?R(this,B,-1):_.bind(this)(B,V)};}}));})(i0)),i0.exports}var Uxe=jxe();const Wxe=Io(Uxe);function k_(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,true)}function F_(e,t,n){var r=[],o=PM(e,r,n);return r.length<2?n:o+t(r)}var pU=function(t){var n=BL(t);n.sheet.speedy=function(l){this.isSpeedy=l;},n.compat=true;var r=function(){for(var u=arguments.length,d=new Array(u),m=0;m<u;m++)d[m]=arguments[m];var p=Ud(d,n.registered,void 0);return IM(n,p,false),n.key+"-"+p.name},o=function(){for(var u=arguments.length,d=new Array(u),m=0;m<u;m++)d[m]=arguments[m];var p=Ud(d,n.registered),g="animation-"+p.name;return k_(n,{name:p.name,styles:"@keyframes "+g+"{"+p.styles+"}"}),g},i=function(){for(var u=arguments.length,d=new Array(u),m=0;m<u;m++)d[m]=arguments[m];var p=Ud(d,n.registered);k_(n,p);},a=function(){for(var u=arguments.length,d=new Array(u),m=0;m<u;m++)d[m]=arguments[m];return F_(n.registered,r,Gxe(d))};return {css:r,cx:a,injectGlobal:i,keyframes:o,hydrate:function(u){u.forEach(function(d){n.inserted[d]=true;});},flush:function(){n.registered={},n.inserted={},n.sheet.flush();},sheet:n.sheet,cache:n,getRegisteredStyles:PM.bind(null,n.registered),merge:F_.bind(null,n.registered,r)}},Gxe=function e(t){for(var n="",r=0;r<t.length;r++){var o=t[r];if(o!=null){var i=void 0;switch(typeof o){case "boolean":break;case "object":{if(Array.isArray(o))i=e(o);else {i="";for(var a in o)o[a]&&a&&(i&&(i+=" "),i+=a);}break}default:i=o;}i&&(n&&(n+=" "),n+=i);}}return n},H_=function(t,n){var r=arguments;if(n==null||!Gp.call(n,"css"))return f.createElement.apply(void 0,r);var o=r.length,i=new Array(o);i[0]=DM,i[1]=OM(t,n);for(var a=2;a<o;a++)i[a]=r[a];return f.createElement.apply(null,i)};(function(e){var t;t||(t=e.JSX||(e.JSX={}));})(H_||(H_={}));var fA=HL(function(e,t){var n=e.styles,r=Ud([n],void 0,f.useContext(VL)),o=f.useRef();return A5(function(){var i=t.key+"-global",a=new t.sheet.constructor({key:i,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),l=false,u=document.querySelector('style[data-emotion="'+i+" "+r.name+'"]');return t.sheet.tags.length&&(a.before=t.sheet.tags[0]),u!==null&&(l=true,u.setAttribute("data-emotion",i),a.hydrate([u])),o.current=[a,l],function(){a.flush();}},[t]),A5(function(){var i=o.current,a=i[0],l=i[1];if(l){i[1]=false;return}if(r.next!==void 0&&IM(t,r.next,true),a.tags.length){var u=a.tags[a.tags.length-1].nextElementSibling;a.before=u,a.flush();}t.insert("",r,a,false);},[t,r.name]),null});function ln(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return Ud(t)}var rh={},Uw={exports:{}},V_;function Ma(){return V_||(V_=1,(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=true,e.exports.default=e.exports;})(Uw)),Uw.exports}var oh={},j_;function qxe(){if(j_)return oh;j_=1,Object.defineProperty(oh,"__esModule",{value:true}),oh.default=void 0;const e={items_per_page:"条/页",jump_to:"跳至",jump_to_confirm:"确定",page:"页",prev_page:"上一页",next_page:"下一页",prev_5:"向前 5 页",next_5:"向后 5 页",prev_3:"向前 3 页",next_3:"向后 3 页",page_size:"页码"};return oh.default=e,oh}var ih={},ah={},sh={},lh={},U_;function Kxe(){return U_||(U_=1,Object.defineProperty(lh,"__esModule",{value:true}),lh.commonLocale=void 0,lh.commonLocale={yearFormat:"YYYY",dayFormat:"D",cellMeridiemFormat:"A",monthBeforeYear:true}),lh}var W_;function Yxe(){if(W_)return sh;W_=1,Object.defineProperty(sh,"__esModule",{value:true}),sh.default=void 0;var e=Kxe();function t(u){"@babel/helpers - typeof";return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(d){return typeof d}:function(d){return d&&typeof Symbol=="function"&&d.constructor===Symbol&&d!==Symbol.prototype?"symbol":typeof d},t(u)}function n(u,d){var m=Object.keys(u);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(u);d&&(p=p.filter(function(g){return Object.getOwnPropertyDescriptor(u,g).enumerable})),m.push.apply(m,p);}return m}function r(u){for(var d=1;d<arguments.length;d++){var m=arguments[d]!=null?arguments[d]:{};d%2?n(Object(m),true).forEach(function(p){o(u,p,m[p]);}):Object.getOwnPropertyDescriptors?Object.defineProperties(u,Object.getOwnPropertyDescriptors(m)):n(Object(m)).forEach(function(p){Object.defineProperty(u,p,Object.getOwnPropertyDescriptor(m,p));});}return u}function o(u,d,m){return d=i(d),d in u?Object.defineProperty(u,d,{value:m,enumerable:true,configurable:true,writable:true}):u[d]=m,u}function i(u){var d=a(u,"string");return t(d)=="symbol"?d:String(d)}function a(u,d){if(t(u)!="object"||!u)return u;var m=u[Symbol.toPrimitive];if(m!==void 0){var p=m.call(u,d);if(t(p)!="object")return p;throw new TypeError("@@toPrimitive must return a primitive value.")}return (d==="string"?String:Number)(u)}var l=r(r({},e.commonLocale),{},{locale:"zh_CN",today:"今天",now:"此刻",backToToday:"返回今天",ok:"确定",timeSelect:"选择时间",dateSelect:"选择日期",weekSelect:"选择周",clear:"清除",week:"周",month:"月",year:"年",previousMonth:"上个月 (翻页上键)",nextMonth:"下个月 (翻页下键)",monthSelect:"选择月份",yearSelect:"选择年份",decadeSelect:"选择年代",previousYear:"上一年 (Control键加左方向键)",nextYear:"下一年 (Control键加右方向键)",previousDecade:"上一年代",nextDecade:"下一年代",previousCentury:"上一世纪",nextCentury:"下一世纪",yearFormat:"YYYY年",cellDateFormat:"D",monthBeforeYear:false});return sh.default=l,sh}var ch={},G_;function gU(){if(G_)return ch;G_=1,Object.defineProperty(ch,"__esModule",{value:true}),ch.default=void 0;const e={placeholder:"请选择时间",rangePlaceholder:["开始时间","结束时间"]};return ch.default=e,ch}var q_;function vU(){if(q_)return ah;q_=1;var e=Ma().default;Object.defineProperty(ah,"__esModule",{value:true}),ah.default=void 0;var t=e(Yxe()),n=e(gU());const r={lang:{placeholder:"请选择日期",yearPlaceholder:"请选择年份",quarterPlaceholder:"请选择季度",monthPlaceholder:"请选择月份",weekPlaceholder:"请选择周",rangePlaceholder:["开始日期","结束日期"],rangeYearPlaceholder:["开始年份","结束年份"],rangeMonthPlaceholder:["开始月份","结束月份"],rangeQuarterPlaceholder:["开始季度","结束季度"],rangeWeekPlaceholder:["开始周","结束周"],...t.default},timePickerLocale:{...n.default}};return r.lang.ok="确定",ah.default=r,ah}var K_;function Xxe(){if(K_)return ih;K_=1;var e=Ma().default;Object.defineProperty(ih,"__esModule",{value:true}),ih.default=void 0;var t=e(vU());return ih.default=t.default,ih}var Y_;function Qxe(){if(Y_)return rh;Y_=1;var e=Ma().default;Object.defineProperty(rh,"__esModule",{value:true}),rh.default=void 0;var t=e(qxe()),n=e(Xxe()),r=e(vU()),o=e(gU());const i="${label}不是一个有效的${type}",a={locale:"zh-cn",Pagination:t.default,DatePicker:r.default,TimePicker:o.default,Calendar:n.default,global:{placeholder:"请选择",close:"关闭",sortable:"可排序"},Table:{filterTitle:"筛选",filterConfirm:"确定",filterReset:"重置",filterEmptyText:"无筛选项",filterCheckAll:"全选",filterSearchPlaceholder:"在筛选项中搜索",emptyText:"暂无数据",selectAll:"全选当页",selectInvert:"反选当页",selectNone:"清空所有",selectionAll:"全选所有",sortTitle:"排序",expand:"展开行",collapse:"关闭行",triggerDesc:"点击降序",triggerAsc:"点击升序",cancelSort:"取消排序"},Modal:{okText:"确定",cancelText:"取消",justOkText:"知道了"},Tour:{Next:"下一步",Previous:"上一步",Finish:"结束导览"},Popconfirm:{cancelText:"取消",okText:"确定"},Transfer:{titles:["",""],searchPlaceholder:"请输入搜索内容",itemUnit:"项",itemsUnit:"项",remove:"删除",selectCurrent:"全选当页",removeCurrent:"删除当页",selectAll:"全选所有",deselectAll:"取消全选",removeAll:"删除全部",selectInvert:"反选当页"},Upload:{uploading:"文件上传中",removeFile:"删除文件",uploadError:"上传错误",previewFile:"预览文件",downloadFile:"下载文件"},Empty:{description:"暂无数据"},Icon:{icon:"图标"},Text:{edit:"编辑",copy:"复制",copied:"复制成功",expand:"展开",collapse:"收起"},Form:{optional:"(可选)",defaultValidateMessages:{default:"字段验证错误${label}",required:"请输入${label}",enum:"${label}必须是其中一个[${enum}]",whitespace:"${label}不能为空字符",date:{format:"${label}日期格式无效",parse:"${label}不能转换为日期",invalid:"${label}是一个无效日期"},types:{string:i,method:i,array:i,object:i,number:i,date:i,boolean:i,integer:i,float:i,regexp:i,email:i,url:i,hex:i},string:{len:"${label}须为${len}个字符",min:"${label}最少${min}个字符",max:"${label}最多${max}个字符",range:"${label}须在${min}-${max}字符之间"},number:{len:"${label}必须等于${len}",min:"${label}最小值为${min}",max:"${label}最大值为${max}",range:"${label}须在${min}-${max}之间"},array:{len:"须为${len}个${label}",min:"最少${min}个${label}",max:"最多${max}个${label}",range:"${label}数量须在${min}-${max}之间"},pattern:{mismatch:"${label}与模式不匹配${pattern}"}}},QRCode:{expired:"二维码过期",refresh:"点击刷新",scanned:"已扫描"},ColorPicker:{presetEmpty:"暂无",transparent:"无色",singleColor:"单色",gradientColor:"渐变色"}};return rh.default=a,rh}var Ww,X_;function Zxe(){return X_||(X_=1,Ww=Qxe()),Ww}var Jxe=Zxe();const ewe=Io(Jxe),twe="--bilibili-gate--font",nwe="--bilibili-gate--video-card--border-radius",bU="--bilibili-gate--primary-color",rwe="--bilibili-gate--border-color",yU="--bilibili-gate--text-color",SU="--bilibili-gate--bg",owe="--bilibili-gate--primary-color--lv1",iwe="--bilibili-gate--primary-color--lv2",awe="--bilibili-gate--primary-color--lv3",swe="--bilibili-gate--bg--lv1",lwe="--bilibili-gate--bg--lv2",cwe="--bilibili-gate--bg--lv3",uwe="#ff6699",dwe='"Alibaba PuHuiTi 3.0", "PingFang SC", "HarmonyOS_Regular", "Helvetica Neue", "Microsoft YaHei", sans-serif',CU="var(--custom-font-family--options--font-family, var(--bilibili-gate--font))",fwe="bilibili-gate-root",xU="bilibili-gate-using-dark",wU="bilibili-gate-using-light",$U="html.bilibili-gate-using-dark",mwe="html.bilibili-gate-using-light",Vs={appCustomFontId:twe,appVideoCardBorderRadiusId:nwe,appPrimaryColorId:bU,appBorderColorId:rwe,appTextColorId:yU,appBgId:SU,appPrimaryColorLv1Id:owe,appPrimaryColorLv2Id:iwe,appPrimaryColorLv3Id:awe,appBgLv1Id:swe,appBgLv2Id:lwe,appBgLv3Id:cwe,biliPink:uwe,appCustomFontValue:dwe,appUsingFont:CU,appClsRoot:fwe,appClsDark:xU,appClsLight:wU,appClsDarkSelector:$U,appClsLightSelector:mwe},Q_=ao.extend("utility:dom"),EU=10*1e3,MU=200;async function Sg(e,t){const n=t?.interval??MU;let r=t?.timeout??EU;r===0&&(r=1/0);const o=t?.validate??(l=>!Ha(l)),i=performance.now();let a=e();for(;!o(a)&&performance.now()-i<r;)await gn(n),a=e();return a}async function P1(e,t,n){const r=n?.pollTimeout??EU,o=n?.pollInterval??MU,i=n?.selectorPredicate,a=n?.warnOnTimeout??false,l=await Sg(()=>{let u=Array.from(document.querySelectorAll(e));if(i&&(u=u.filter(i)),u.length)return u},{timeout:r,interval:o});if(!l?.length){Q_("tryAction: timeout for selector = `%s`",e),a&&Ko("tryAction timeout, selector = `%s`",e);return}Q_("tryAction: selector=`%s` count=%s",e,l.length);for(const u of l)await Promise.resolve(t(u));}async function Vh(e,t,n){return P1(e,r=>r.remove(),{selectorPredicate:t,warnOnTimeout:false})}function js(){const e=document.activeElement?.tagName?.toLowerCase()??"";return !!(["input","textarea"].includes(e)||document.querySelector(".center-search__bar.is-focus"))}function hwe(e,t){t??=e.getBoundingClientRect();const n=document.documentElement;return {top:t.top+window.scrollY-n.clientTop,left:t.left+window.scrollX-n.clientLeft}}function I1(e){return new Promise(t=>{typeof requestIdleCallback=="function"?requestIdleCallback(()=>t(),e):setTimeout(t);})}let Gw="";function mA(e){Gw||(Gw=document.title),document.title=`${e} - ${Gw}`;}function B3(...e){return e.map(t=>t.trim()).filter(Boolean).map(t=>t.startsWith(".")?t:`.${t}`).join(",")}const Rp={Evolved:{getDetectEl:()=>document.body,detect:e=>e.classList.contains("dark"),trigger:'.custom-navbar-item[role="listitem"][data-name="darkMode"]',triggerInner:'.navbar-dark-mode[item="darkMode"]'},Bili:{getDetectEl:()=>document.documentElement,detect:e=>e.classList.contains("bili_dark"),isTrigger:e=>{const t=e.closest(".avatar-panel-popover a.single-link-item");return t?!!Array.from(t.querySelectorAll(".link-title span")).find(n=>["深色","浅色"].includes(n.textContent||"")):false}}},Z_=e=>{const t=e.getDetectEl();return t?e.detect(t):false},vf=nc(()=>Z_(Rp.Bili)||Z_(Rp.Evolved)||document.body.classList.contains("bilibili-helper-dark-mode")||document.documentElement.classList.contains("dark"));function O1(){return vf.use()}const RU=()=>{document.documentElement.classList.toggle(xU,vf.get()),document.documentElement.classList.toggle(wU,!vf.get());};RU();Xa(vf.state,RU);const hA=new MutationObserver(async()=>{await gn(0),vf.updateThrottled();});hA.observe(document.body,{attributes:true,attributeFilter:["class"]});hA.observe(document.documentElement,{attributes:true,attributeFilter:["data-darkreader-scheme"]});pwe();async function pwe(){const e=await Sg(Rp.Bili.getDetectEl);e&&hA.observe(e,{attributes:true});}document.addEventListener("click",gwe,{passive:true});async function gwe(e){const t=e.target;(Rp.Bili.isTrigger(t)||t.closest(Rp.Evolved.trigger))&&(await gn(0),vf.updateThrottled());}const vwe=ao.extend("components:css-vars");vwe(":export = %O",Vs);const ac=e=>(e.startsWith("--")||(e=`--${e}`),`var(${e})`),pA=ac(Vs.appVideoCardBorderRadiusId),xa=ac(Vs.appPrimaryColorId),TU=ac(Vs.appBorderColorId);ac(Vs.appTextColorId);const L3=ac(Vs.appBgId),by=ac(Vs.appBgLv1Id),bwe=ac(Vs.appBgLv2Id);ac(Vs.appBgLv3Id);const Gf={name:"rmyi3a",styles:"color:var(--ant-button-default-hover-color);border-color:var(--ant-button-default-hover-border-color);background:var(--ant-button-default-hover-bg)"};function ywe(){return iy.useToken().token.colorPrimaryHover}function qf(){const{popoverBorderColorUseColorPrimary:e}=bt(at.style.general),t=ywe();return e?t:TU}function Swe(){const e=qf();return f.useMemo(()=>({border:`1px solid ${e}`}),[e])}function Cwe(){const{colorLink:e,colorLinkActive:t,colorLinkHover:n}=iy.useToken().token;return f.useMemo(()=>ln("color:",e,";&:visited{color:",e,";}&:hover{color:",n,";}&:active{color:",t,";}",""),[e,t,n])}const AU=`${io}--use-ant-link-color`;function xwe(){const e=Cwe();return ln(":root .",AU,"{",e,";}","")}var NU=function(e){return function(t,n){var r=f.useRef(false);e(function(){return function(){r.current=false;}},[]),e(function(){if(!r.current)r.current=true;else return t()},n);}},z3=function(e,t){return z3=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r;}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o]);},z3(e,t)};function PU(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");z3(e,t);function n(){this.constructor=e;}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n);}var hi=function(){return hi=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i]);}return t},hi.apply(this,arguments)};function D1(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function IU(e,t,n,r){var o=arguments.length,i=o<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,n,r);else for(var l=e.length-1;l>=0;l--)(a=e[l])&&(i=(o<3?a(i):o>3?a(t,n,i):a(t,n))||i);return o>3&&i&&Object.defineProperty(t,n,i),i}function OU(e,t){return function(n,r){t(n,r,e);}}function DU(e,t,n,r,o,i){function a(w){if(w!==void 0&&typeof w!="function")throw new TypeError("Function expected");return w}for(var l=r.kind,u=l==="getter"?"get":l==="setter"?"set":"value",d=!t&&e?r.static?e:e.prototype:null,m=t||(d?Object.getOwnPropertyDescriptor(d,r.name):{}),p,g=false,b=n.length-1;b>=0;b--){var y={};for(var S in r)y[S]=S==="access"?{}:r[S];for(var S in r.access)y.access[S]=r.access[S];y.addInitializer=function(w){if(g)throw new TypeError("Cannot add initializers after decoration has completed");i.push(a(w||null));};var C=(0, n[b])(l==="accessor"?{get:m.get,set:m.set}:m[u],y);if(l==="accessor"){if(C===void 0)continue;if(C===null||typeof C!="object")throw new TypeError("Object expected");(p=a(C.get))&&(m.get=p),(p=a(C.set))&&(m.set=p),(p=a(C.init))&&o.unshift(p);}else (p=a(C))&&(l==="field"?o.unshift(p):m[u]=p);}d&&Object.defineProperty(d,r.name,m),g=true;}function _U(e,t,n){for(var r=arguments.length>2,o=0;o<t.length;o++)n=r?t[o].call(e,n):t[o].call(e);return r?n:void 0}function BU(e){return typeof e=="symbol"?e:"".concat(e)}function LU(e,t,n){return typeof t=="symbol"&&(t=t.description?"[".concat(t.description,"]"):""),Object.defineProperty(e,"name",{configurable:true,value:n?"".concat(n," ",t):t})}function zU(e,t){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(e,t)}function _1(e,t,n,r){function o(i){return i instanceof n?i:new n(function(a){a(i);})}return new(n||(n=Promise))(function(i,a){function l(m){try{d(r.next(m));}catch(p){a(p);}}function u(m){try{d(r.throw(m));}catch(p){a(p);}}function d(m){m.done?i(m.value):o(m.value).then(l,u);}d((r=r.apply(e,t||[])).next());})}function B1(e,t){var n={label:0,sent:function(){if(i[0]&1)throw i[1];return i[1]},trys:[],ops:[]},r,o,i,a=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return a.next=l(0),a.throw=l(1),a.return=l(2),typeof Symbol=="function"&&(a[Symbol.iterator]=function(){return this}),a;function l(d){return function(m){return u([d,m])}}function u(d){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,d[0]&&(n=0)),n;)try{if(r=1,o&&(i=d[0]&2?o.return:d[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,d[1])).done)return i;switch(o=0,i&&(d=[d[0]&2,i.value]),d[0]){case 0:case 1:i=d;break;case 4:return n.label++,{value:d[1],done:!1};case 5:n.label++,o=d[1],d=[0];continue;case 7:d=n.ops.pop(),n.trys.pop();continue;default:if(i=n.trys,!(i=i.length>0&&i[i.length-1])&&(d[0]===6||d[0]===2)){n=0;continue}if(d[0]===3&&(!i||d[1]>i[0]&&d[1]<i[3])){n.label=d[1];break}if(d[0]===6&&n.label<i[1]){n.label=i[1],i=d;break}if(i&&n.label<i[2]){n.label=i[2],n.ops.push(d);break}i[2]&&n.ops.pop(),n.trys.pop();continue}d=t.call(e,n);}catch(m){d=[6,m],o=0;}finally{r=i=0;}if(d[0]&5)throw d[1];return {value:d[0]?d[1]:void 0,done:true}}}var L1=Object.create?(function(e,t,n,r){r===void 0&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);(!o||("get"in o?!t.__esModule:o.writable||o.configurable))&&(o={enumerable:true,get:function(){return t[n]}}),Object.defineProperty(e,r,o);}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n];});function kU(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&L1(t,e,n);}function mu(e){var t=typeof Symbol=="function"&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&typeof e.length=="number")return {next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Jn(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),o,i=[],a;try{for(;(t===void 0||t-- >0)&&!(o=r.next()).done;)i.push(o.value);}catch(l){a={error:l};}finally{try{o&&!o.done&&(n=r.return)&&n.call(r);}finally{if(a)throw a.error}}return i}function FU(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Jn(arguments[t]));return e}function HU(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;for(var r=Array(e),o=0,t=0;t<n;t++)for(var i=arguments[t],a=0,l=i.length;a<l;a++,o++)r[o]=i[a];return r}function Nr(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}function bf(e){return this instanceof bf?(this.v=e,this):new bf(e)}function VU(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),o,i=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),l("next"),l("throw"),l("return",a),o[Symbol.asyncIterator]=function(){return this},o;function a(b){return function(y){return Promise.resolve(y).then(b,p)}}function l(b,y){r[b]&&(o[b]=function(S){return new Promise(function(C,w){i.push([b,S,C,w])>1||u(b,S);})},y&&(o[b]=y(o[b])));}function u(b,y){try{d(r[b](y));}catch(S){g(i[0][3],S);}}function d(b){b.value instanceof bf?Promise.resolve(b.value.v).then(m,p):g(i[0][2],b);}function m(b){u("next",b);}function p(b){u("throw",b);}function g(b,y){b(y),i.shift(),i.length&&u(i[0][0],i[0][1]);}}function jU(e){var t,n;return t={},r("next"),r("throw",function(o){throw o}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(o,i){t[o]=e[o]?function(a){return (n=!n)?{value:bf(e[o](a)),done:false}:i?i(a):a}:i;}}function UU(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof mu=="function"?mu(e):e[Symbol.iterator](),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(i){n[i]=e[i]&&function(a){return new Promise(function(l,u){a=e[i](a),o(l,u,a.done,a.value);})};}function o(i,a,l,u){Promise.resolve(u).then(function(d){i({value:d,done:l});},a);}}function WU(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var wwe=Object.create?(function(e,t){Object.defineProperty(e,"default",{enumerable:true,value:t});}):function(e,t){e.default=t;},k3=function(e){return k3=Object.getOwnPropertyNames||function(t){var n=[];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[n.length]=r);return n},k3(e)};function GU(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var n=k3(e),r=0;r<n.length;r++)n[r]!=="default"&&L1(t,e,n[r]);return wwe(t,e),t}function qU(e){return e&&e.__esModule?e:{default:e}}function KU(e,t,n,r){if(n==="a"&&!r)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!r:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?r:n==="a"?r.call(e):r?r.value:t.get(e)}function YU(e,t,n,r,o){if(r==="m")throw new TypeError("Private method is not writable");if(r==="a"&&!o)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!o:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return r==="a"?o.call(e,n):o?o.value=n:t.set(e,n),n}function XU(e,t){if(t===null||typeof t!="object"&&typeof t!="function")throw new TypeError("Cannot use 'in' operator on non-object");return typeof e=="function"?t===e:e.has(t)}function QU(e,t,n){if(t!=null){if(typeof t!="object"&&typeof t!="function")throw new TypeError("Object expected.");var r,o;if(n){if(!Symbol.asyncDispose)throw new TypeError("Symbol.asyncDispose is not defined.");r=t[Symbol.asyncDispose];}if(r===void 0){if(!Symbol.dispose)throw new TypeError("Symbol.dispose is not defined.");r=t[Symbol.dispose],n&&(o=r);}if(typeof r!="function")throw new TypeError("Object not disposable.");o&&(r=function(){try{o.call(this);}catch(i){return Promise.reject(i)}}),e.stack.push({value:t,dispose:r,async:n});}else n&&e.stack.push({async:true});return t}var $we=typeof SuppressedError=="function"?SuppressedError:function(e,t,n){var r=new Error(n);return r.name="SuppressedError",r.error=e,r.suppressed=t,r};function ZU(e){function t(i){e.error=e.hasError?new $we(i,e.error,"An error was suppressed during disposal."):i,e.hasError=true;}var n,r=0;function o(){for(;n=e.stack.pop();)try{if(!n.async&&r===1)return r=0,e.stack.push(n),Promise.resolve().then(o);if(n.dispose){var i=n.dispose.call(n.value);if(n.async)return r|=2,Promise.resolve(i).then(o,function(a){return t(a),o()})}else r|=1;}catch(a){t(a);}if(r===1)return e.hasError?Promise.reject(e.error):Promise.resolve();if(e.hasError)throw e.error}return o()}function JU(e,t){return typeof e=="string"&&/^\.\.?\//.test(e)?e.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(n,r,o,i,a){return r?t?".jsx":".js":o&&(!i||!a)?n:o+i+"."+a.toLowerCase()+"js"}):e}const Ewe={__extends:PU,__assign:hi,__rest:D1,__decorate:IU,__param:OU,__esDecorate:DU,__runInitializers:_U,__propKey:BU,__setFunctionName:LU,__metadata:zU,__awaiter:_1,__generator:B1,__createBinding:L1,__exportStar:kU,__values:mu,__read:Jn,__spread:FU,__spreadArrays:HU,__spreadArray:Nr,__await:bf,__asyncGenerator:VU,__asyncDelegator:jU,__asyncValues:UU,__makeTemplateObject:WU,__importStar:GU,__importDefault:qU,__classPrivateFieldGet:KU,__classPrivateFieldSet:YU,__classPrivateFieldIn:XU,__addDisposableResource:QU,__disposeResources:ZU,__rewriteRelativeImportExtension:JU},Mwe=Object.freeze(Object.defineProperty({__proto__:null,__addDisposableResource:QU,get __assign(){return hi},__asyncDelegator:jU,__asyncGenerator:VU,__asyncValues:UU,__await:bf,__awaiter:_1,__classPrivateFieldGet:KU,__classPrivateFieldIn:XU,__classPrivateFieldSet:YU,__createBinding:L1,__decorate:IU,__disposeResources:ZU,__esDecorate:DU,__exportStar:kU,__extends:PU,__generator:B1,__importDefault:qU,__importStar:GU,__makeTemplateObject:WU,__metadata:zU,__param:OU,__propKey:BU,__read:Jn,__rest:D1,__rewriteRelativeImportExtension:JU,__runInitializers:_U,__setFunctionName:LU,__spread:FU,__spreadArray:Nr,__spreadArrays:HU,__values:mu,default:Ewe},Symbol.toStringTag,{value:"Module"}));var gA=function(e){return typeof e=="function"},Rwe=function(e){return typeof e=="string"},eW=function(e){return typeof e=="number"},Je=function(e){var t=f.useRef(e);t.current=f.useMemo(function(){return e},[e]);var n=f.useRef(void 0);return n.current||(n.current=function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return t.current.apply(this,r)}),n.current};const Ps=NU(f.useEffect);var tW=function(e,t){var n=t.manual,r=t.ready,o=r===void 0?true:r,i=t.defaultParams,a=i===void 0?[]:i,l=t.refreshDeps,u=l===void 0?[]:l,d=t.refreshDepsAction,m=f.useRef(false);return m.current=false,Ps(function(){!n&&o&&(m.current=true,e.run.apply(e,Nr([],Jn(a),false)));},[o]),Ps(function(){m.current||n||(m.current=true,d?d():e.refresh());},Nr([],Jn(u),false)),{onBefore:function(){if(!o)return {stopNow:true}}}};tW.onInit=function(e){var t=e.ready,n=t===void 0?true:t,r=e.manual;return {loading:!r&&n}};function F3(e,t){if(e===t)return true;for(var n=0;n<e.length;n++)if(!Object.is(e[n],t[n]))return false;return true}var z1=function(e,t){var n=f.useRef({deps:t,obj:void 0,initialized:false}).current;return (n.initialized===false||!F3(n.deps,t))&&(n.deps=t,n.obj=e(),n.initialized=true),n.obj};function hu(e){var t=f.useRef(e);return t.current=e,t}var Kf=function(e){var t=hu(e);f.useEffect(function(){return function(){t.current();}},[]);},a0=new Map,Twe=function(e,t,n){var r=a0.get(e);r?.timer&&clearTimeout(r.timer);var o=void 0;t>-1&&(o=setTimeout(function(){a0.delete(e);},t)),a0.set(e,hi(hi({},n),{timer:o}));},Awe=function(e){return a0.get(e)},s0=new Map,Nwe=function(e){return s0.get(e)},Pwe=function(e,t){s0.set(e,t),t.then(function(n){return s0.delete(e),n}).catch(function(){s0.delete(e);});},zc={},Iwe=function(e,t){zc[e]&&zc[e].forEach(function(n){return n(t)});},qw=function(e,t){return zc[e]||(zc[e]=[]),zc[e].push(t),function(){var r=zc[e].indexOf(t);zc[e].splice(r,1);}},Owe=function(e,t){var n=t.cacheKey,r=t.cacheTime,o=r===void 0?300*1e3:r,i=t.staleTime,a=i===void 0?0:i,l=t.setCache,u=t.getCache,d=f.useRef(void 0),m=f.useRef(void 0),p=function(b,y){l?l(y):Twe(b,o,y),Iwe(b,y.data);},g=function(b,y){return y===void 0&&(y=[]),u?u(y):Awe(b)};return z1(function(){if(n){var b=g(n);b&&Object.hasOwnProperty.call(b,"data")&&(e.state.data=b.data,e.state.params=b.params,(a===-1||Date.now()-b.time<=a)&&(e.state.loading=false)),d.current=qw(n,function(y){e.setState({data:y});});}},[]),Kf(function(){var b;(b=d.current)===null||b===void 0||b.call(d);}),n?{onBefore:function(b){var y=g(n,b);return !y||!Object.hasOwnProperty.call(y,"data")?{}:a===-1||Date.now()-y.time<=a?{loading:false,data:y?.data,error:void 0,returnNow:true}:{data:y?.data,error:void 0}},onRequest:function(b,y){var S=Nwe(n);return S&&S!==m.current?{servicePromise:S}:(S=b.apply(void 0,Nr([],Jn(y),false)),m.current=S,Pwe(n,S),{servicePromise:S})},onSuccess:function(b,y){var S;n&&((S=d.current)===null||S===void 0||S.call(d),p(n,{data:b,params:y,time:Date.now()}),d.current=qw(n,function(C){e.setState({data:C});}));},onMutate:function(b){var y;n&&((y=d.current)===null||y===void 0||y.call(d),p(n,{data:b,params:e.state.params,time:Date.now()}),d.current=qw(n,function(S){e.setState({data:S});}));}}:{}},Kw,J_;function vA(){if(J_)return Kw;J_=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return Kw=e,Kw}var Yw,e9;function Dwe(){if(e9)return Yw;e9=1;var e=typeof qv=="object"&&qv&&qv.Object===Object&&qv;return Yw=e,Yw}var Xw,t9;function nW(){if(t9)return Xw;t9=1;var e=Dwe(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return Xw=n,Xw}var Qw,n9;function _we(){if(n9)return Qw;n9=1;var e=nW(),t=function(){return e.Date.now()};return Qw=t,Qw}var Zw,r9;function Bwe(){if(r9)return Zw;r9=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return Zw=t,Zw}var Jw,o9;function Lwe(){if(o9)return Jw;o9=1;var e=Bwe(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return Jw=n,Jw}var e$,i9;function rW(){if(i9)return e$;i9=1;var e=nW(),t=e.Symbol;return e$=t,e$}var t$,a9;function zwe(){if(a9)return t$;a9=1;var e=rW(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,o=e?e.toStringTag:void 0;function i(a){var l=n.call(a,o),u=a[o];try{a[o]=void 0;var d=!0;}catch{}var m=r.call(a);return d&&(l?a[o]=u:delete a[o]),m}return t$=i,t$}var n$,s9;function kwe(){if(s9)return n$;s9=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return n$=n,n$}var r$,l9;function Fwe(){if(l9)return r$;l9=1;var e=rW(),t=zwe(),n=kwe(),r="[object Null]",o="[object Undefined]",i=e?e.toStringTag:void 0;function a(l){return l==null?l===void 0?o:r:i&&i in Object(l)?t(l):n(l)}return r$=a,r$}var o$,c9;function Hwe(){if(c9)return o$;c9=1;function e(t){return t!=null&&typeof t=="object"}return o$=e,o$}var i$,u9;function Vwe(){if(u9)return i$;u9=1;var e=Fwe(),t=Hwe(),n="[object Symbol]";function r(o){return typeof o=="symbol"||t(o)&&e(o)==n}return i$=r,i$}var a$,d9;function jwe(){if(d9)return a$;d9=1;var e=Lwe(),t=vA(),n=Vwe(),r=NaN,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,a=/^0o[0-7]+$/i,l=parseInt;function u(d){if(typeof d=="number")return d;if(n(d))return r;if(t(d)){var m=typeof d.valueOf=="function"?d.valueOf():d;d=t(m)?m+"":m;}if(typeof d!="string")return d===0?d:+d;d=e(d);var p=i.test(d);return p||a.test(d)?l(d.slice(2),p?2:8):o.test(d)?r:+d}return a$=u,a$}var s$,f9;function oW(){if(f9)return s$;f9=1;var e=vA(),t=_we(),n=jwe(),r="Expected a function",o=Math.max,i=Math.min;function a(l,u,d){var m,p,g,b,y,S,C=0,w=false,$=false,M=true;if(typeof l!="function")throw new TypeError(r);u=n(u)||0,e(d)&&(w=!!d.leading,$="maxWait"in d,g=$?o(n(d.maxWait)||0,u):g,M="trailing"in d?!!d.trailing:M);function T(U){var G=m,H=p;return m=p=void 0,C=U,b=l.apply(H,G),b}function R(U){return C=U,y=setTimeout(P,u),w?T(U):b}function I(U){var G=U-S,H=U-C,z=u-G;return $?i(z,g-H):z}function N(U){var G=U-S,H=U-C;return S===void 0||G>=u||G<0||$&&H>=g}function P(){var U=t();if(N(U))return O(U);y=setTimeout(P,I(U));}function O(U){return y=void 0,M&&m?T(U):(m=p=void 0,b)}function _(){y!==void 0&&clearTimeout(y),C=0,m=S=p=y=void 0;}function B(){return y===void 0?b:O(t())}function V(){var U=t(),G=N(U);if(m=arguments,p=this,S=U,G){if(y===void 0)return R(S);if($)return clearTimeout(y),y=setTimeout(P,u),T(S)}return y===void 0&&(y=setTimeout(P,u)),b}return V.cancel=_,V.flush=B,V}return s$=a,s$}var Uwe=oW();const Wwe=Io(Uwe);var Gwe=function(e,t){var n=t.debounceWait,r=t.debounceLeading,o=t.debounceTrailing,i=t.debounceMaxWait,a=f.useRef(void 0),l=f.useMemo(function(){var u={};return r!==void 0&&(u.leading=r),o!==void 0&&(u.trailing=o),i!==void 0&&(u.maxWait=i),u},[r,o,i]);return f.useEffect(function(){if(n){var u=e.runAsync.bind(e);return a.current=Wwe(function(d){d();},n,l),e.runAsync=function(){for(var d=[],m=0;m<arguments.length;m++)d[m]=arguments[m];return new Promise(function(p,g){var b;(b=a.current)===null||b===void 0||b.call(a,function(){u.apply(void 0,Nr([],Jn(d),false)).then(p).catch(g);});})},function(){var d;(d=a.current)===null||d===void 0||d.cancel(),e.runAsync=u;}}},[n,l]),n?{onCancel:function(){var u;(u=a.current)===null||u===void 0||u.cancel();}}:{}},qwe=function(e,t){var n=t.loadingDelay,r=t.ready,o=f.useRef(void 0);if(!n)return {};var i=function(){o.current&&clearTimeout(o.current);};return {onBefore:function(){return i(),r!==false&&(o.current=setTimeout(function(){e.setState({loading:true});},n)),{loading:false}},onFinally:function(){i();},onCancel:function(){i();}}},Cg=!!(typeof window<"u"&&window.document&&window.document.createElement);function bA(){return Cg?document.visibilityState!=="hidden":true}var l0=new Set;function Kwe(e){return l0.add(e),function(){l0.has(e)&&l0.delete(e);}}if(Cg){var Ywe=function(){bA()&&l0.forEach(function(e){return e()});};window.addEventListener("visibilitychange",Ywe,false);}var Xwe=function(e,t){var n=t.pollingInterval,r=t.pollingWhenHidden,o=r===void 0?true:r,i=t.pollingErrorRetryCount,a=i===void 0?-1:i,l=f.useRef(void 0),u=f.useRef(void 0),d=f.useRef(0),m=function(){var p;l.current&&clearTimeout(l.current),(p=u.current)===null||p===void 0||p.call(u);};return Ps(function(){n||m();},[n]),n?{onBefore:function(){m();},onError:function(){d.current+=1;},onSuccess:function(){d.current=0;},onFinally:function(){a===-1||a!==-1&&d.current<=a?l.current=setTimeout(function(){!o&&!bA()?u.current=Kwe(function(){e.refresh();}):e.refresh();},n):d.current=0;},onCancel:function(){m();}}:{}};function Qwe(e,t){var n=false;return function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];n||(n=true,e.apply(void 0,Nr([],Jn(r),false)),setTimeout(function(){n=false;},t));}}var Zwe=function(){return Cg&&typeof navigator.onLine<"u"?navigator.onLine:true},c0=new Set;function Jwe(e){return c0.add(e),function(){c0.has(e)&&c0.delete(e);}}if(Cg){var m9=function(){!bA()||!Zwe()||c0.forEach(function(e){return e()});};window.addEventListener("visibilitychange",m9,false),window.addEventListener("focus",m9,false);}var e$e=function(e,t){var n=t.refreshOnWindowFocus,r=t.focusTimespan,o=r===void 0?5e3:r,i=f.useRef(void 0),a=function(){var l;(l=i.current)===null||l===void 0||l.call(i);};return f.useEffect(function(){if(n){var l=Qwe(e.refresh.bind(e),o);i.current=Jwe(function(){l();});}return function(){a();}},[n,o]),Kf(function(){a();}),{}},t$e=function(e,t){var n=t.retryInterval,r=t.retryCount,o=f.useRef(void 0),i=f.useRef(0),a=f.useRef(false);return r?{onBefore:function(){a.current||(i.current=0),a.current=false,o.current&&clearTimeout(o.current);},onSuccess:function(){i.current=0;},onError:function(){if(i.current+=1,r===-1||i.current<=r){var l=n??Math.min(1e3*Math.pow(2,i.current),3e4);o.current=setTimeout(function(){a.current=true,e.refresh();},l);}else i.current=0;},onCancel:function(){i.current=0,o.current&&clearTimeout(o.current);}}:{}},l$,h9;function n$e(){if(h9)return l$;h9=1;var e=oW(),t=vA(),n="Expected a function";function r(o,i,a){var l=true,u=true;if(typeof o!="function")throw new TypeError(n);return t(a)&&(l="leading"in a?!!a.leading:l,u="trailing"in a?!!a.trailing:u),e(o,i,{leading:l,maxWait:i,trailing:u})}return l$=r,l$}var r$e=n$e();const o$e=Io(r$e);var i$e=function(e,t){var n=t.throttleWait,r=t.throttleLeading,o=t.throttleTrailing,i=f.useRef(void 0),a={};return r!==void 0&&(a.leading=r),o!==void 0&&(a.trailing=o),f.useEffect(function(){if(n){var l=e.runAsync.bind(e);return i.current=o$e(function(u){u();},n,a),e.runAsync=function(){for(var u=[],d=0;d<arguments.length;d++)u[d]=arguments[d];return new Promise(function(m,p){var g;(g=i.current)===null||g===void 0||g.call(i,function(){l.apply(void 0,Nr([],Jn(u),false)).then(m).catch(p);});})},function(){var u;e.runAsync=l,(u=i.current)===null||u===void 0||u.cancel();}}},[n,r,o]),n?{onCancel:function(){var l;(l=i.current)===null||l===void 0||l.cancel();}}:{}},oo=function(e){f.useEffect(function(){var t=e?.();if(!(t&&typeof t=="object"&&typeof t.then=="function"))return t},[]);},a$e=function(){var e=Jn(f.useState({}),2),t=e[1];return f.useCallback(function(){return t({})},[])},s$e=(function(){function e(t,n,r,o){o===void 0&&(o={}),this.serviceRef=t,this.options=n,this.subscribe=r,this.initState=o,this.pluginImpls=[],this.count=0,this.state={loading:false,params:void 0,data:void 0,error:void 0},this.state=hi(hi(hi({},this.state),{loading:!n.manual}),o);}return e.prototype.setState=function(t){t===void 0&&(t={}),this.state=hi(hi({},this.state),t),this.subscribe();},e.prototype.runPluginHandler=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=this.pluginImpls.map(function(i){var a;return (a=i[t])===null||a===void 0?void 0:a.call.apply(a,Nr([i],Jn(n),false))}).filter(Boolean);return Object.assign.apply(Object,Nr([{}],Jn(o),false))},e.prototype.runAsync=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return _1(this,void 0,void 0,function(){var r,o,i,a,l,u,d,m,p,g,b,y,S,C,w,$,M,T,R,I,N;return B1(this,function(P){switch(P.label){case 0:if(this.count+=1,r=this.count,o=this.runPluginHandler("onBefore",t),i=o.stopNow,a=i===void 0?false:i,l=o.returnNow,u=l===void 0?false:l,d=D1(o,["stopNow","returnNow"]),a)return [2,new Promise(function(){})];if(this.setState(hi({loading:true,params:t},d)),u)return [2,Promise.resolve(d.data)];(S=(y=this.options).onBefore)===null||S===void 0||S.call(y,t),P.label=1;case 1:return P.trys.push([1,3,,4]),m=this.runPluginHandler("onRequest",this.serviceRef.current,t).servicePromise,m||(m=(b=this.serviceRef).current.apply(b,Nr([],Jn(t),false))),[4,m];case 2:return p=P.sent(),r!==this.count?[2,new Promise(function(){})]:(this.setState({data:p,error:void 0,loading:false}),(w=(C=this.options).onSuccess)===null||w===void 0||w.call(C,p,t),this.runPluginHandler("onSuccess",p,t),(M=($=this.options).onFinally)===null||M===void 0||M.call($,t,p,void 0),r===this.count&&this.runPluginHandler("onFinally",t,p,void 0),[2,p]);case 3:if(g=P.sent(),r!==this.count)return [2,new Promise(function(){})];throw this.setState({error:g,loading:false}),(R=(T=this.options).onError)===null||R===void 0||R.call(T,g,t),this.runPluginHandler("onError",g,t),(N=(I=this.options).onFinally)===null||N===void 0||N.call(I,t,void 0,g),r===this.count&&this.runPluginHandler("onFinally",t,void 0,g),g;case 4:return [2]}})})},e.prototype.run=function(){for(var t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];this.runAsync.apply(this,Nr([],Jn(n),false)).catch(function(o){t.options.onError||console.error(o);});},e.prototype.cancel=function(){this.count+=1,this.setState({loading:false}),this.runPluginHandler("onCancel");},e.prototype.refresh=function(){this.run.apply(this,Nr([],Jn(this.state.params||[]),false));},e.prototype.refreshAsync=function(){return this.runAsync.apply(this,Nr([],Jn(this.state.params||[]),false))},e.prototype.mutate=function(t){var n=gA(t)?t(this.state.data):t;this.runPluginHandler("onMutate",n),this.setState({data:n});},e})();function l$e(e,t,n){t===void 0&&(t={}),n===void 0&&(n=[]);var r=t.manual,o=r===void 0?false:r,i=t.ready,a=i===void 0?true:i,l=D1(t,["manual","ready"]),u=hi({manual:o,ready:a},l),d=hu(e),m=a$e(),p=z1(function(){var g=n.map(function(b){var y;return (y=b?.onInit)===null||y===void 0?void 0:y.call(b,u)}).filter(Boolean);return new s$e(d,u,m,Object.assign.apply(Object,Nr([{}],Jn(g),false)))},[]);return p.options=u,p.pluginImpls=n.map(function(g){return g(p,u)}),oo(function(){if(!o&&a){var g=p.state.params||t.defaultParams||[];p.run.apply(p,Nr([],Jn(g),false));}}),Kf(function(){p.cancel();}),{loading:p.state.loading,data:p.state.data,error:p.state.error,params:p.state.params||[],cancel:Je(p.cancel.bind(p)),refresh:Je(p.refresh.bind(p)),refreshAsync:Je(p.refreshAsync.bind(p)),run:Je(p.run.bind(p)),runAsync:Je(p.runAsync.bind(p)),mutate:Je(p.mutate.bind(p))}}function ga(e,t,n){return l$e(e,t,Nr(Nr([],Jn([]),false),[Gwe,qwe,Xwe,e$e,i$e,tW,Owe,t$e],false))}function iW(e,t){e===void 0&&(e=false);var n=Jn(f.useState(e),2),r=n[0],o=n[1],i=f.useMemo(function(){var a=!e,l=function(){return o(function(p){return p===e?a:e})},u=function(p){return o(p)},d=function(){return o(e)},m=function(){return o(a)};return {toggle:l,set:u,setLeft:d,setRight:m}},[]);return [r,i]}function c$e(e){var t=Jn(iW(false),2),n=t[0],r=t[1],o=r.toggle,i=r.set,a=f.useMemo(function(){var l=function(){return i(true)},u=function(){return i(false)};return {toggle:o,set:function(d){return i(!!d)},setTrue:l,setFalse:u}},[]);return [n,a]}function Yf(e,t){if(Cg){if(!e)return t;var n;return gA(e)?n=e():"current"in e?n=e.current:n=e,n}}var u$e=function(e){return e.every(function(t){var n=Yf(t);return n?n.getRootNode()instanceof ShadowRoot:false})},d$e=function(e){return e?e.getRootNode():document},f$e=function(e){if(!e||!document.getRootNode)return document;var t=Array.isArray(e)?e:[e];return u$e(t)?d$e(Yf(t[0])):document},m$e=function(e){var t=function(n,r,o){var i=f.useRef(false),a=f.useRef([]),l=f.useRef([]),u=f.useRef(void 0);e(function(){var d,m=Array.isArray(o)?o:[o],p=m.map(function(g){return Yf(g)});if(!i.current){i.current=true,a.current=p,l.current=r,u.current=n();return}(p.length!==a.current.length||!F3(a.current,p)||!F3(l.current,r))&&((d=u.current)===null||d===void 0||d.call(u),a.current=p,l.current=r,u.current=n());}),Kf(function(){var d;(d=u.current)===null||d===void 0||d.call(u),i.current=false;});};return t},yA=m$e(f.useEffect);function h$e(e,t,n){n===void 0&&(n="click");var r=hu(e);yA(function(){var o=function(l){var u=Array.isArray(t)?t:[t];u.some(function(d){var m=Yf(d);return !m||m.contains(l.target)})||r.current(l);},i=f$e(t),a=Array.isArray(n)?n:[n];return a.forEach(function(l){return i.addEventListener(l,o)}),function(){a.forEach(function(l){return i.removeEventListener(l,o)});}},Array.isArray(n)?n:[n],t);}var c$,p9;function aW(){if(p9)return c$;p9=1;var e=typeof Element<"u",t=typeof Map=="function",n=typeof Set=="function",r=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function o(i,a){if(i===a)return true;if(i&&a&&typeof i=="object"&&typeof a=="object"){if(i.constructor!==a.constructor)return false;var l,u,d;if(Array.isArray(i)){if(l=i.length,l!=a.length)return false;for(u=l;u--!==0;)if(!o(i[u],a[u]))return false;return true}var m;if(t&&i instanceof Map&&a instanceof Map){if(i.size!==a.size)return false;for(m=i.entries();!(u=m.next()).done;)if(!a.has(u.value[0]))return false;for(m=i.entries();!(u=m.next()).done;)if(!o(u.value[1],a.get(u.value[0])))return false;return true}if(n&&i instanceof Set&&a instanceof Set){if(i.size!==a.size)return false;for(m=i.entries();!(u=m.next()).done;)if(!a.has(u.value[0]))return false;return true}if(r&&ArrayBuffer.isView(i)&&ArrayBuffer.isView(a)){if(l=i.length,l!=a.length)return false;for(u=l;u--!==0;)if(i[u]!==a[u])return false;return true}if(i.constructor===RegExp)return i.source===a.source&&i.flags===a.flags;if(i.valueOf!==Object.prototype.valueOf&&typeof i.valueOf=="function"&&typeof a.valueOf=="function")return i.valueOf()===a.valueOf();if(i.toString!==Object.prototype.toString&&typeof i.toString=="function"&&typeof a.toString=="function")return i.toString()===a.toString();if(d=Object.keys(i),l=d.length,l!==Object.keys(a).length)return false;for(u=l;u--!==0;)if(!Object.prototype.hasOwnProperty.call(a,d[u]))return false;if(e&&i instanceof Element)return false;for(u=l;u--!==0;)if(!((d[u]==="_owner"||d[u]==="__v"||d[u]==="__o")&&i.$$typeof)&&!o(i[d[u]],a[d[u]]))return false;return true}return i!==i&&a!==a}return c$=function(a,l){try{return o(a,l)}catch(u){if((u.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),false;throw u}},c$}var p$e=aW();const g$e=Io(p$e);var v$e=function(e,t){return e===void 0&&(e=[]),t===void 0&&(t=[]),g$e(e,t)};function va(e,t,n){n===void 0&&(n={});var r=n.enable,o=r===void 0?true:r,i=hu(t);yA(function(){if(o){var a=Yf(n.target,window);if(a?.addEventListener){var l=function(d){return i.current(d)},u=Array.isArray(e)?e:[e];return u.forEach(function(d){a.addEventListener(d,l,{capture:n.capture,once:n.once,passive:n.passive});}),function(){u.forEach(function(d){a.removeEventListener(d,l,{capture:n.capture});});}}}},[e,n.capture,n.once,n.passive,o],n.target);}const k1=(function(e,t){var n={},r=n.onEnter,o=n.onLeave,i=n.onChange,a=Jn(c$e(),2),l=a[0],u=a[1],d=u.setTrue,m=u.setFalse;return va("mouseenter",function(){r?.(),d(),i?.(true);},{target:e}),va("mouseleave",function(){o?.(),m(),i?.(false);},{target:e}),l});var b$e=function(e,t,n){var r=f.useRef(void 0),o=f.useRef(0);v$e(t,r.current)||(o.current+=1),r.current=t,yA(e,[o.current],n);},y$e=/(mac|iphone|ipod|ipad)/i.test(typeof navigator<"u"?navigator?.platform:""),sW={0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,pausebreak:19,capslock:20,esc:27,space:32,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,a:65,b:66,c:67,d:68,e:69,f:70,g:71,h:72,i:73,j:74,k:75,l:76,m:77,n:78,o:79,p:80,q:81,r:82,s:83,t:84,u:85,v:86,w:87,x:88,y:89,z:90,leftwindowkey:91,rightwindowkey:92,meta:y$e?[91,93]:[91,92],selectkey:93,numpad0:96,numpad1:97,numpad2:98,numpad3:99,numpad4:100,numpad5:101,numpad6:102,numpad7:103,numpad8:104,numpad9:105,multiply:106,add:107,subtract:109,decimalpoint:110,divide:111,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,numlock:144,scrolllock:145,semicolon:186,equalsign:187,comma:188,dash:189,period:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222},H3={ctrl:function(e){return e.ctrlKey},shift:function(e){return e.shiftKey},alt:function(e){return e.altKey},meta:function(e){return e.type==="keyup"?sW.meta.includes(e.keyCode):e.metaKey}};function lW(e){return Rwe(e)||eW(e)}function S$e(e){var t=Object.keys(H3).reduce(function(n,r){return H3[r](e)?n+1:n},0);return [16,17,18,91,92].includes(e.keyCode)?t:t+1}function g9(e,t,n){var r,o;if(!e.key)return false;if(eW(t))return e.keyCode===t?t:false;var i=t.split("."),a=0;try{for(var l=mu(i),u=l.next();!u.done;u=l.next()){var d=u.value,m=H3[d],p=sW[d.toLowerCase()];(m&&m(e)||p&&p===e.keyCode)&&a++;}}catch(g){r={error:g};}finally{try{u&&!u.done&&(o=l.return)&&o.call(l);}finally{if(r)throw r.error}}return n?a===i.length&&S$e(e)===i.length?t:false:a===i.length?t:false}function C$e(e,t){return gA(e)?e:lW(e)?function(n){return g9(n,e,t)}:Array.isArray(e)?function(n){return e.find(function(r){return g9(n,r,t)})}:function(){return !!e}}var x$e=["keydown"];function ua(e,t,n){var r=n||{},o=r.events,i=o===void 0?x$e:o,a=r.target,l=r.exactMatch,u=l===void 0?false:l,d=r.useCapture,m=d===void 0?false:d,p=hu(t),g=hu(e);b$e(function(){var b,y,S,C=Yf(a,window);if(C){var w=function(R){var I,N=R,P=C$e(g.current,u),O=P(N),_=lW(O)?O:N.key;if(O)return (I=p.current)===null||I===void 0?void 0:I.call(p,N,_)};try{for(var $=mu(i),M=$.next();!M.done;M=$.next()){var T=M.value;(S=C?.addEventListener)===null||S===void 0||S.call(C,T,w,m);}}catch(R){b={error:R};}finally{try{M&&!M.done&&(y=$.return)&&y.call($);}finally{if(b)throw b.error}}return function(){var R,I,N;try{for(var P=mu(i),O=P.next();!O.done;O=P.next()){var _=O.value;(N=C?.removeEventListener)===null||N===void 0||N.call(C,_,w,m);}}catch(B){R={error:B};}finally{try{O&&!O.done&&(I=P.return)&&I.call(P);}finally{if(R)throw R.error}}}}},[i],a);}function xg(e){var t=this,n=f.useRef(false);return f.useCallback(function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];return _1(t,void 0,void 0,function(){var i,a;return B1(this,function(l){switch(l.label){case 0:if(n.current)return [2];n.current=true,l.label=1;case 1:return l.trys.push([1,3,4,5]),[4,e.apply(void 0,Nr([],Jn(r),false))];case 2:return i=l.sent(),[2,i];case 3:throw a=l.sent(),a;case 4:return n.current=false,[7];case 5:return [2]}})})},[e])}function v9(e){var t=f.useRef(0),n=Jn(f.useState(e),2),r=n[0],o=n[1],i=f.useCallback(function(a){cancelAnimationFrame(t.current),t.current=requestAnimationFrame(function(){o(a);});},[]);return Kf(function(){cancelAnimationFrame(t.current);}),[r,i]}var w$e=function(e,t){return !Object.is(e,t)};function SA(e,t){t===void 0&&(t=w$e);var n=f.useRef(void 0),r=f.useRef(void 0);return t(r.current,e)&&(n.current=r.current,r.current=e),n.current}var cW=function(){var e=f.useRef(false);return f.useEffect(function(){return e.current=false,function(){e.current=true;}},[]),e};const $$e=NU(f.useLayoutEffect),E$e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"m12 13.4l-4.9 4.9q-.275.275-.7.275t-.7-.275t-.275-.7t.275-.7l4.9-4.9l-4.9-4.9q-.275-.275-.275-.7t.275-.7t.7-.275t.7.275l4.9 4.9l4.9-4.9q.275-.275.7-.275t.7.275t.275.7t-.275.7L13.4 12l4.9 4.9q.275.275.275.7t-.275.7t-.7.275t-.7-.275z"})]}),M$e=f.forwardRef(E$e),Po={modalMask:X("fixed inset-0 flex items-center justify-center bg-black/50",HCe),modal:"max-h-[calc(90vh-50px)] w-500px flex flex-col overflow-hidden b-1px b-transparent rounded-10px b-solid bg-gate-bg px-15px pb-15px text-gate-text dark:b-gate-border",modalHeader:"flex items-center justify-between border-b-0 py-10px",modalTitle:"mb-0 flex items-center text-[1.5rem] line-height-1.5",modalBody:"flex-grow-1 overflow-y-auto pt-0"},uW=`${io}-modal-visible`,R$e=ln("body:has(.",uW,"){overflow-y:hidden;}","");function wg({show:e,onHide:t,children:n,clsModalMask:r,clsModal:o,width:i,hideWhenMaskOnClick:a=false,hideWhenEsc:l=false}){const u=f.useRef(null),d=Je(g=>{const b=g.target;if(u.current?.contains(b))return;const y=['.ant-tooltip-container[role="tooltip"]','.ant-popover-container[role="tooltip"]',".ant-select-dropdown"];b.closest(y.join(","))||a&&t();});ua("esc",g=>{e&&l&&(g.preventDefault(),g.stopImmediatePropagation(),setTimeout(t));},{exactMatch:true});const m=ur(Po.modalMask,r),p=ur(Po.modal,o);return e?$o.createPortal(x("div",{className:X($a,{[uW]:e}),"data-role":"base-modal",children:x("div",{className:m,onClick:d,children:x("div",{className:p,style:{width:i},ref:u,children:n})})}),document.body):null}const $g=({className:e,...t})=>{const n=ur("ml-10px size-24px cursor-pointer transition-duration-150 transition-ease transition-property-transform hover:rotate-90 hover:scale-105%",e);return x(M$e,{...t,className:n})};let fo=(function(e){return e.Lavender="#e6e6fa",e.Thistle="#d8bfd8",e.Plum="#dda0dd",e.Mauve="#e0b0ff",e.Wisteria="#c9a0dc",e.Orchid="#da70d6",e.MediumOrchid="#ba55d3",e.MediumPurple="#9370db",e.Amethyst="#9966cc",e.BlueViolet="#8a2be2",e.Purple="#800080",e.Violet="#8f00ff",e.Magenta="#ff00ff",e.Grape="#6f2da8",e.Indigo="#4b0082",e.Eggplant="#301934",e})({});const T$e=[{name:"Lavender",nameZh:"薰衣草",hex:fo.Lavender,desc:"淡紫偏粉"},{name:"Thistle",nameZh:"蓟紫色",hex:fo.Thistle,desc:"带灰调"},{name:"Plum",nameZh:"李子紫",hex:fo.Plum,desc:"柔和温暖"},{name:"Mauve",nameZh:"淡紫色",hex:fo.Mauve,desc:"烟粉色调"},{name:"Wisteria",nameZh:"紫藤色",hex:fo.Wisteria,desc:"温柔浅紫"},{name:"Orchid",nameZh:"兰花紫",hex:fo.Orchid,desc:"偏红亮紫"},{name:"Medium Orchid",nameZh:"中兰花紫",hex:fo.MediumOrchid,desc:"稍深更艳"},{name:"Medium Purple",nameZh:"中紫色",hex:fo.MediumPurple,desc:"柔和略蓝"},{name:"Amethyst",nameZh:"紫水晶色",hex:fo.Amethyst,desc:"经典冷紫"},{name:"Blue Violet",nameZh:"蓝紫色",hex:fo.BlueViolet,desc:"较冷"},{name:"Purple",nameZh:"标准紫色",hex:fo.Purple,desc:"饱和且暗"},{name:"Violet",nameZh:"紫罗兰",hex:fo.Violet,desc:"更偏蓝光谱"},{name:"Magenta",nameZh:"洋红色",hex:fo.Magenta,desc:"红紫交界"},{name:"Grape",nameZh:"葡萄紫",hex:fo.Grape,desc:"饱和深紫"},{name:"Indigo",nameZh:"靛青色",hex:fo.Indigo,desc:"蓝紫之间"},{name:"Eggplant",nameZh:"茄子紫",hex:fo.Eggplant,desc:"极深紫红"}],A$e=[{id:"green",name:"绿意盎然",isDark:false,isCustom:false,colorPrimary:"rgb(77, 175, 124)",colorTheme:"rgb(77, 175, 124)"},{id:"blue",name:"蓝田生玉",isDark:false,isCustom:false,colorPrimary:"rgb(52, 152, 219)",colorTheme:"rgb(52, 152, 219)"},{id:"blue_plus",name:"蛋雅深蓝",isDark:false,isCustom:false,colorPrimary:"rgb(77, 131, 175)",colorTheme:"rgb(77, 131, 175)"},{id:"orange",name:"橙黄橘绿",isDark:false,isCustom:false,colorPrimary:"rgb(245, 171, 53)",colorTheme:"rgb(245, 171, 53)"},{id:"red",name:"热情似火",isDark:false,isCustom:false,colorPrimary:"rgb(214, 69, 65)",colorTheme:"rgb(214, 69, 65)"},{id:"pink",name:"粉装玉琢",isDark:false,isCustom:false,colorPrimary:"rgb(241, 130, 141)",colorTheme:"rgb(241, 130, 141)"},{id:"purple",name:"重斤球紫",isDark:false,isCustom:false,colorPrimary:"rgb(155, 89, 182)",colorTheme:"rgb(155, 89, 182)"},{id:"grey",name:"灰常美丽",isDark:false,isCustom:false,colorPrimary:"rgb(108, 122, 137)",colorTheme:"rgb(108, 122, 137)"},{id:"ming",name:"青出于黑",isDark:false,isCustom:false,colorPrimary:"rgb(51, 110, 123)",colorTheme:"rgb(51, 110, 123)"},{id:"blue2",name:"清热板蓝",isDark:false,isCustom:false,colorPrimary:"rgb(79, 98, 208)",colorTheme:"rgb(79, 98, 208)"},{id:"black",name:"黑灯瞎火",isDark:true,isCustom:false,colorPrimary:"rgb(150, 150, 150)",colorTheme:"rgb(59,59,59)"},{id:"mid_autumn",name:"月里嫦娥",isDark:false,isCustom:false,colorPrimary:"rgb(74, 55, 82)",colorTheme:"rgb(74, 55, 82)"},{id:"naruto",name:"木叶之村",isDark:false,isCustom:false,colorPrimary:"rgb(87, 144, 167)",colorTheme:"rgb(87, 144, 167)"},{id:"china_ink",name:"近墨者黑",isDark:false,isCustom:false,colorPrimary:"rgba(47, 47, 47, 1)",colorTheme:"rgba(47, 47, 47, 1)"},{id:"happy_new_year",name:"新年快乐",isDark:false,isCustom:false,colorPrimary:"rgb(192, 57, 43)",colorTheme:"rgb(192, 57, 43)"}],yy={id:"default-bili-pink",name:"B站粉",colorPrimary:Mf.Pink,tooltip:"B站品牌色"},dW={id:"color-picker",name:"自定义",isCustom:true,colorPrimary:Mf.Pink};function N$e(e,t){return t.split(`
`).map(n=>n.trim()).filter(Boolean).map(n=>{const[r,o]=n.split(" ").filter(Boolean);return {id:`${e}:${o}`,name:o,colorPrimary:r}})}const CA="UP长期洗涤",P$e=N$e(CA,`
#0545b2 理想之蓝
#f4cd00 柠檬黄
#ef2729 石榴红
#f89c00 鹿箭
#233728 黛绿
#f2b9b7 和熙粉
#f3cc91 芝士黄
#6b4c68 葡萄紫
#ff7227 落日橙
#004d62 碧海天
#23909b 洗碧空
#aeb400 芥丝绿
#425a17 箬叶青
#002fa7 克莱因蓝
#003153 普鲁士蓝
#01847f 马尔斯绿
#fbd26a 申布伦黄
#470024 勃艮第红
#492d22 凡戴克棕
`),fW="bilibili-evolved-sync",mW=[{name:"预设",themes:[yy,{id:"bilibili-blue",name:"B站蓝",colorPrimary:Mf.Blue,tooltip:"B站品牌色"},{id:"app-custom-高能红",name:"高能红",colorPrimary:"#fd453e"},{id:"app-custom-咸蛋黄",name:"咸蛋黄",colorPrimary:"#ffc034"},{id:"app-custom-早苗绿",name:"早苗绿",colorPrimary:"#85c255"},{id:"app-custom-宝石蓝",name:"宝石蓝",colorPrimary:"#0095ef"},{id:"app-custom-罗兰紫",name:"罗兰紫",colorPrimary:"#a029ac"},{id:fW,name:"B-Evolved",colorPrimary:`var(--theme-color,${VH()})`,tooltip:F(ze,{children:["使用 Bilibili-Evolved 的主题色",x("br",{}),"在 Bilibili-Evolved 设置中修改主题色后可能需要刷新页面同步"]})},dW]},{name:"LX Themes",themes:A$e,tooltip:F(ze,{children:["提取自"," ",x("a",{target:"_blank",href:"https://github.com/lyswhut/lx-music-desktop/",children:"lx-music-desktop"}),x("br",{}),"Apache License 2.0"]})},{name:CA,themes:P$e,tooltip:F(ze,{children:["提取自"," ",x("a",{target:"_blank",href:"https://www.bilibili.com/video/BV1g3411u7Lg/",children:"BV1g3411u7Lg"})," ","&"," ",x("a",{target:"_blank",href:"https://www.bilibili.com/video/BV1xu411q7sU/",children:"BV1xu411q7sU"})]})},{name:"紫定能行",themes:T$e.map(e=>({id:`purple-colors-${e.name}`,name:e.nameZh,colorPrimary:e.hex,tooltip:F(ze,{children:[e.name," ",e.nameZh," ",x("br",{}),e.desc]})})),tooltip:F(ze,{children:["提取自"," ",x("a",{target:"_blank",href:"https://magicdawn.github.io/purple-colors/",children:"purple-colors"})," "]})}],I$e=mW.map(e=>e.themes).flat(),b9={[`${CA}:马尔斯绿`]:F(ze,{children:["马尔斯绿 MARRS GREEN ",x("br",{}),"2017年英国的百年造纸商G.F SMITH和英国城市文化节联合发起了「选出全世界最受欢迎的颜色」的活动, ",x("br",{}),"在为期半年由来自100多个约3万名用户的投票后,由来自苏格兰的联合国教科文组织工作人员 ",x("br",{}),"安妮•马尔斯(ANNIE MARRS)提交的一种蓝绿色当选。 ",x("br",{}),"马尔斯绿也因此由ANNIE MARRS的姓氏和主色调组合而得名。 ",x("br",{}),"马尔斯绿的灵感来源于ANNIE家乡苏格兰的泰勒河畔自然景观的一种蓝绿色调。 ",x("br",{})]})};function hW(){let{theme:e,colorPickerThemeSelectedColor:t}=Ut();return e||=yy.id,f.useMemo(()=>{const n=I$e.find(r=>r.id===e)||yy;return n.id===dW.id&&t?{...n,colorPrimary:t}:n},[e,t])}function pW(){const e=hW(),t=lg.use();let n=e.colorPrimary;return e.id===fW&&(n=t||VH()),n}function O$e(e,t){return e||t?"--bg1":"--bg2"}function D$e(){const e=pW(),t=O1(),n=xwe(),{style:{pureRecommend:{useWhiteBackground:r}}}=Ut(),o=f.useMemo(()=>({bgSrc:O$e(t,r),bgFallback:t?"#17181a":r?"#fff":"#f6f7f8",text:t?"#fff":"#333"}),[t,r]);return x(fA,{styles:[n,R$e,ln`
:root {
${bU}: ${e};
${SU}: var(${o.bgSrc}, ${o.bgFallback});
${yU}: var(--text1, ${o.text});
}
`,"",""]})}var _$e={name:"1ughwg6",styles:".bili-feed4 .bili-header{min-height:64px!important;}"},B$e={name:"rpxvzv",styles:"#i_cecream,body>#app{.bili-feed4-layout{display:none;}}.desktop-download-tip,.vip-login-tip,.palette-button-adcard{display:none!important;}"};function L$e(){const{grid:{useCustomGrid:e},style:{pureRecommend:{useWhiteBackground:t,hideTopChannel:n}}}=Ut(),r=O1(),o=qge(),i=hT.use(),a=pT.use()??90,l="0 10px";if(_s)return x(fA,{styles:[B$e,e&&ln("#i_cecream,body>#app,.bili-feed4 .bili-header,.bili-feed4 .bili-header .bili-header__bar{max-width:unset;}.bili-feed4-layout,.bili-feed4 .bili-header .bili-header__channel{max-width:",a,"%;padding:",l,";}",""),e&&typeof o=="number"&&ln(".",$a,"{--back-top-right:",o,"px;}",""),ln("body{background-color:",L3,"!important;}.large-header,#i_cecream,body>#app,.bili-header.large-header,.bili-header.large-header .bili-header__channel{background-color:",L3,";}",""),!r&&!t&&ln(".bili-header .bili-header__channel .channel-entry-more__link,.bili-header .bili-header__channel .channel-link{background-color:",by,";}",""),n&&ln(".bili-header__channel,.bili-header__banner{display:none!important;}",!i&&_$e," .bili-feed4 .bili-header .bili-header__bar{&.slide-down,&:not(.slide-down){animation:headerSlideDown 0.3s linear forwards!important;box-shadow:0 2px 4px ",r?"rgb(255 255 255 / 5%)":"rgb(0 0 0 / 8%)","!important;}}.bili-header__bar:not(.slide-down){background-color:var(--bg1);color:var(--text1);transition:background-color 0.2s linear;animation-name:headerSlideDown;.left-entry{.mini-header__title,.entry-title,.default-entry,.loc-mc-box__text,.download-entry,.loc-entry{color:var(--text1);}}.right-entry .right-entry__outside{.right-entry-text,.right-entry-icon{color:var(--text2);}}}.area-header-wrapper{margin-top:10px;}",""),"",""]})}function z$e(...e){return function(t){return e.reduceRight((n,r)=>r?r(n):n,t)}}function Us({children:e,cssInsertContainer:t,cssInsertContainerEmotionKey:n}){t&&Ro(n,"cssInsertContainerEmotionKey is required when cssInsertContainer is provided");const r=f.useMemo(()=>{if(t)return pU({key:n,container:t}).cache},[t,n]),o=O1(),i=pW();return z$e(!!r&&(l=>x(qZ,{value:r,children:l})),!!t&&(l=>x(DJ,{container:t,children:l})),l=>x(Do,{locale:ewe,button:{autoInsertSpace:false},getPopupContainer:u=>u?.closest("."+$a)??document.body,theme:{algorithm:o?iy.darkAlgorithm:iy.defaultAlgorithm,token:{colorPrimary:i,colorBgSpotlight:i,zIndexPopupBase:y_(S_),fontFamily:CU},components:{Notification:{zIndexPopup:y_(S_)},Button:{defaultShadow:"none",primaryShadow:"none"},Dropdown:{}}},children:l}))(e)}function F1({antd:e,baseGlobalStyle:t,homePageGlobalStyle:n}){return F(ze,{children:[e&&x(Yge,{}),t&&x(D$e,{}),n&&x(L$e,{})]})}function k$e(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return f.useMemo(()=>r=>{t.forEach(o=>o(r));},t)}const H1=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Xf(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function xA(e){return "nodeType"in e}function ei(e){var t,n;return e?Xf(e)?e:xA(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function wA(e){const{Document:t}=ei(e);return e instanceof t}function Eg(e){return Xf(e)?false:e instanceof ei(e).HTMLElement}function gW(e){return e instanceof ei(e).SVGElement}function Qf(e){return e?Xf(e)?e.document:xA(e)?wA(e)?e:Eg(e)||gW(e)?e.ownerDocument:document:document:document}const Ya=H1?f.useLayoutEffect:f.useEffect;function $A(e){const t=f.useRef(e);return Ya(()=>{t.current=e;}),f.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}function F$e(){const e=f.useRef(null),t=f.useCallback((r,o)=>{e.current=setInterval(r,o);},[]),n=f.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null);},[]);return [t,n]}function Tp(e,t){t===void 0&&(t=[e]);const n=f.useRef(e);return Ya(()=>{n.current!==e&&(n.current=e);},t),n}function Mg(e,t){const n=f.useRef();return f.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function Sy(e){const t=$A(e),n=f.useRef(null),r=f.useCallback(o=>{o!==n.current&&t?.(o,n.current),n.current=o;},[]);return [n,r]}function V3(e){const t=f.useRef();return f.useEffect(()=>{t.current=e;},[e]),t.current}let u$={};function Rg(e,t){return f.useMemo(()=>{if(t)return t;const n=u$[e]==null?0:u$[e]+1;return u$[e]=n,e+"-"+n},[e,t])}function vW(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((i,a)=>{const l=Object.entries(a);for(const[u,d]of l){const m=i[u];m!=null&&(i[u]=m+e*d);}return i},{...t})}}const Xd=vW(1),Cy=vW(-1);function H$e(e){return "clientX"in e&&"clientY"in e}function EA(e){if(!e)return false;const{KeyboardEvent:t}=ei(e.target);return t&&e instanceof t}function V$e(e){if(!e)return false;const{TouchEvent:t}=ei(e.target);return t&&e instanceof t}function j3(e){if(V$e(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return {x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return {x:t,y:n}}}return H$e(e)?{x:e.clientX,y:e.clientY}:null}const yf=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return "translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return "scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return [yf.Translate.toString(e),yf.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),y9="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function j$e(e){return e.matches(y9)?e:e.querySelector(y9)}const U$e={display:"none"};function W$e(e){let{id:t,value:n}=e;return q.createElement("div",{id:t,style:U$e},n)}function G$e(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return q.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":true},n)}function q$e(){const[e,t]=f.useState("");return {announce:f.useCallback(r=>{r!=null&&t(r);},[]),announcement:e}}const bW=f.createContext(null);function yW(e){const t=f.useContext(bW);f.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t]);}function K$e(){const[e]=f.useState(()=>new Set),t=f.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return [f.useCallback(r=>{let{type:o,event:i}=r;e.forEach(a=>{var l;return (l=a[o])==null?void 0:l.call(a,i)});},[e]),t]}const Y$e={draggable:`
To pick up a draggable item, press the space bar.
While dragging, use the arrow keys to move the item.
Press space again to drop the item in its new position, or press escape to cancel.
`},X$e={onDragStart(e){let{active:t}=e;return "Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was moved over droppable area "+n.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was dropped over droppable area "+n.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return "Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function Q$e(e){let{announcements:t=X$e,container:n,hiddenTextDescribedById:r,screenReaderInstructions:o=Y$e}=e;const{announce:i,announcement:a}=q$e(),l=Rg("DndLiveRegion"),[u,d]=f.useState(false);if(f.useEffect(()=>{d(true);},[]),yW(f.useMemo(()=>({onDragStart(p){let{active:g}=p;i(t.onDragStart({active:g}));},onDragMove(p){let{active:g,over:b}=p;t.onDragMove&&i(t.onDragMove({active:g,over:b}));},onDragOver(p){let{active:g,over:b}=p;i(t.onDragOver({active:g,over:b}));},onDragEnd(p){let{active:g,over:b}=p;i(t.onDragEnd({active:g,over:b}));},onDragCancel(p){let{active:g,over:b}=p;i(t.onDragCancel({active:g,over:b}));}}),[i,t])),!u)return null;const m=q.createElement(q.Fragment,null,q.createElement(W$e,{id:r,value:o.draggable}),q.createElement(G$e,{id:l,announcement:a}));return n?$o.createPortal(m,n):m}var Ar;(function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable";})(Ar||(Ar={}));function xy(){}function Z$e(e,t){return f.useMemo(()=>({sensor:e,options:{}}),[e,t])}function J$e(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return f.useMemo(()=>[...t].filter(r=>r!=null),[...t])}const wa=Object.freeze({x:0,y:0});function e2e(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function t2e(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function n2e(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function r2e(e,t){if(!e||e.length===0)return null;const[n]=e;return n[t]}function S9(e,t,n){return t===void 0&&(t=e.left),n===void 0&&(n=e.top),{x:t+e.width*.5,y:n+e.height*.5}}const o2e=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=S9(t,t.left,t.top),i=[];for(const a of r){const{id:l}=a,u=n.get(l);if(u){const d=e2e(S9(u),o);i.push({id:l,data:{droppableContainer:a,value:d}});}}return i.sort(t2e)};function i2e(e,t){const n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),a=o-r,l=i-n;if(r<o&&n<i){const u=t.width*t.height,d=e.width*e.height,m=a*l,p=m/(u+d-m);return Number(p.toFixed(4))}return 0}const a2e=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=[];for(const i of r){const{id:a}=i,l=n.get(a);if(l){const u=i2e(l,t);u>0&&o.push({id:a,data:{droppableContainer:i,value:u}});}}return o.sort(n2e)};function s2e(e,t,n){return {...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}function SW(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:wa}function l2e(e){return function(n){for(var r=arguments.length,o=new Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return o.reduce((a,l)=>({...a,top:a.top+e*l.y,bottom:a.bottom+e*l.y,left:a.left+e*l.x,right:a.right+e*l.x}),{...n})}}const c2e=l2e(1);function u2e(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return {x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}else if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return {x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}function d2e(e,t,n){const r=u2e(t);if(!r)return e;const{scaleX:o,scaleY:i,x:a,y:l}=r,u=e.left-a-(1-o)*parseFloat(n),d=e.top-l-(1-i)*parseFloat(n.slice(n.indexOf(" ")+1)),m=o?e.width/o:e.width,p=i?e.height/i:e.height;return {width:m,height:p,top:d,right:u+m,bottom:d+p,left:u}}const f2e={ignoreTransform:false};function Zf(e,t){t===void 0&&(t=f2e);let n=e.getBoundingClientRect();if(t.ignoreTransform){const{transform:d,transformOrigin:m}=ei(e).getComputedStyle(e);d&&(n=d2e(n,d,m));}const{top:r,left:o,width:i,height:a,bottom:l,right:u}=n;return {top:r,left:o,width:i,height:a,bottom:l,right:u}}function C9(e){return Zf(e,{ignoreTransform:true})}function m2e(e){const t=e.innerWidth,n=e.innerHeight;return {top:0,left:0,right:t,bottom:n,width:t,height:n}}function h2e(e,t){return t===void 0&&(t=ei(e).getComputedStyle(e)),t.position==="fixed"}function p2e(e,t){t===void 0&&(t=ei(e).getComputedStyle(e));const n=/(auto|scroll|overlay)/;return ["overflow","overflowX","overflowY"].some(o=>{const i=t[o];return typeof i=="string"?n.test(i):false})}function MA(e,t){const n=[];function r(o){if(t!=null&&n.length>=t||!o)return n;if(wA(o)&&o.scrollingElement!=null&&!n.includes(o.scrollingElement))return n.push(o.scrollingElement),n;if(!Eg(o)||gW(o)||n.includes(o))return n;const i=ei(e).getComputedStyle(o);return o!==e&&p2e(o,i)&&n.push(o),h2e(o,i)?n:r(o.parentNode)}return e?r(e):n}function CW(e){const[t]=MA(e,1);return t??null}function d$(e){return !H1||!e?null:Xf(e)?e:xA(e)?wA(e)||e===Qf(e).scrollingElement?window:Eg(e)?e:null:null}function xW(e){return Xf(e)?e.scrollX:e.scrollLeft}function wW(e){return Xf(e)?e.scrollY:e.scrollTop}function U3(e){return {x:xW(e),y:wW(e)}}var Lr;(function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward";})(Lr||(Lr={}));function $W(e){return !H1||!e?false:e===document.scrollingElement}function EW(e){const t={x:0,y:0},n=$W(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height},o=e.scrollTop<=t.y,i=e.scrollLeft<=t.x,a=e.scrollTop>=r.y,l=e.scrollLeft>=r.x;return {isTop:o,isLeft:i,isBottom:a,isRight:l,maxScroll:r,minScroll:t}}const g2e={x:.2,y:.2};function v2e(e,t,n,r,o){let{top:i,left:a,right:l,bottom:u}=n;r===void 0&&(r=10),o===void 0&&(o=g2e);const{isTop:d,isBottom:m,isLeft:p,isRight:g}=EW(e),b={x:0,y:0},y={x:0,y:0},S={height:t.height*o.y,width:t.width*o.x};return !d&&i<=t.top+S.height?(b.y=Lr.Backward,y.y=r*Math.abs((t.top+S.height-i)/S.height)):!m&&u>=t.bottom-S.height&&(b.y=Lr.Forward,y.y=r*Math.abs((t.bottom-S.height-u)/S.height)),!g&&l>=t.right-S.width?(b.x=Lr.Forward,y.x=r*Math.abs((t.right-S.width-l)/S.width)):!p&&a<=t.left+S.width&&(b.x=Lr.Backward,y.x=r*Math.abs((t.left+S.width-a)/S.width)),{direction:b,speed:y}}function b2e(e){if(e===document.scrollingElement){const{innerWidth:i,innerHeight:a}=window;return {top:0,left:0,right:i,bottom:a,width:i,height:a}}const{top:t,left:n,right:r,bottom:o}=e.getBoundingClientRect();return {top:t,left:n,right:r,bottom:o,width:e.clientWidth,height:e.clientHeight}}function MW(e){return e.reduce((t,n)=>Xd(t,U3(n)),wa)}function y2e(e){return e.reduce((t,n)=>t+xW(n),0)}function S2e(e){return e.reduce((t,n)=>t+wW(n),0)}function C2e(e,t){if(t===void 0&&(t=Zf),!e)return;const{top:n,left:r,bottom:o,right:i}=t(e);CW(e)&&(o<=0||i<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"});}const x2e=[["x",["left","right"],y2e],["y",["top","bottom"],S2e]];class RA{constructor(t,n){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const r=MA(n),o=MW(r);this.rect={...t},this.width=t.width,this.height=t.height;for(const[i,a,l]of x2e)for(const u of a)Object.defineProperty(this,u,{get:()=>{const d=l(r),m=o[i]-d;return this.rect[u]+m},enumerable:true});Object.defineProperty(this,"rect",{enumerable:false});}}class jh{constructor(t){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach(n=>{var r;return (r=this.target)==null?void 0:r.removeEventListener(...n)});},this.target=t;}add(t,n,r){var o;(o=this.target)==null||o.addEventListener(t,n,r),this.listeners.push([t,n,r]);}}function w2e(e){const{EventTarget:t}=ei(e);return e instanceof t?e:Qf(e)}function f$(e,t){const n=Math.abs(e.x),r=Math.abs(e.y);return typeof t=="number"?Math.sqrt(n**2+r**2)>t:"x"in t&&"y"in t?n>t.x&&r>t.y:"x"in t?n>t.x:"y"in t?r>t.y:false}var Fi;(function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange";})(Fi||(Fi={}));function x9(e){e.preventDefault();}function $2e(e){e.stopPropagation();}var En;(function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter",e.Tab="Tab";})(En||(En={}));const RW={start:[En.Space,En.Enter],cancel:[En.Esc],end:[En.Space,En.Enter,En.Tab]},E2e=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case En.Right:return {...n,x:n.x+25};case En.Left:return {...n,x:n.x-25};case En.Down:return {...n,y:n.y+25};case En.Up:return {...n,y:n.y-25}}};class TW{constructor(t){this.props=void 0,this.autoScrollEnabled=false,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=t;const{event:{target:n}}=t;this.props=t,this.listeners=new jh(Qf(n)),this.windowListeners=new jh(ei(n)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach();}attach(){this.handleStart(),this.windowListeners.add(Fi.Resize,this.handleCancel),this.windowListeners.add(Fi.VisibilityChange,this.handleCancel),setTimeout(()=>this.listeners.add(Fi.Keydown,this.handleKeyDown));}handleStart(){const{activeNode:t,onStart:n}=this.props,r=t.node.current;r&&C2e(r),n(wa);}handleKeyDown(t){if(EA(t)){const{active:n,context:r,options:o}=this.props,{keyboardCodes:i=RW,coordinateGetter:a=E2e,scrollBehavior:l="smooth"}=o,{code:u}=t;if(i.end.includes(u)){this.handleEnd(t);return}if(i.cancel.includes(u)){this.handleCancel(t);return}const{collisionRect:d}=r.current,m=d?{x:d.left,y:d.top}:wa;this.referenceCoordinates||(this.referenceCoordinates=m);const p=a(t,{active:n,context:r.current,currentCoordinates:m});if(p){const g=Cy(p,m),b={x:0,y:0},{scrollableAncestors:y}=r.current;for(const S of y){const C=t.code,{isTop:w,isRight:$,isLeft:M,isBottom:T,maxScroll:R,minScroll:I}=EW(S),N=b2e(S),P={x:Math.min(C===En.Right?N.right-N.width/2:N.right,Math.max(C===En.Right?N.left:N.left+N.width/2,p.x)),y:Math.min(C===En.Down?N.bottom-N.height/2:N.bottom,Math.max(C===En.Down?N.top:N.top+N.height/2,p.y))},O=C===En.Right&&!$||C===En.Left&&!M,_=C===En.Down&&!T||C===En.Up&&!w;if(O&&P.x!==p.x){const B=S.scrollLeft+g.x,V=C===En.Right&&B<=R.x||C===En.Left&&B>=I.x;if(V&&!g.y){S.scrollTo({left:B,behavior:l});return}V?b.x=S.scrollLeft-B:b.x=C===En.Right?S.scrollLeft-R.x:S.scrollLeft-I.x,b.x&&S.scrollBy({left:-b.x,behavior:l});break}else if(_&&P.y!==p.y){const B=S.scrollTop+g.y,V=C===En.Down&&B<=R.y||C===En.Up&&B>=I.y;if(V&&!g.x){S.scrollTo({top:B,behavior:l});return}V?b.y=S.scrollTop-B:b.y=C===En.Down?S.scrollTop-R.y:S.scrollTop-I.y,b.y&&S.scrollBy({top:-b.y,behavior:l});break}}this.handleMove(t,Xd(Cy(p,this.referenceCoordinates),b));}}}handleMove(t,n){const{onMove:r}=this.props;t.preventDefault(),r(n);}handleEnd(t){const{onEnd:n}=this.props;t.preventDefault(),this.detach(),n();}handleCancel(t){const{onCancel:n}=this.props;t.preventDefault(),this.detach(),n();}detach(){this.listeners.removeAll(),this.windowListeners.removeAll();}}TW.activators=[{eventName:"onKeyDown",handler:(e,t,n)=>{let{keyboardCodes:r=RW,onActivation:o}=t,{active:i}=n;const{code:a}=e.nativeEvent;if(r.start.includes(a)){const l=i.activatorNode.current;return l&&e.target!==l?false:(e.preventDefault(),o?.({event:e.nativeEvent}),true)}return false}}];function w9(e){return !!(e&&"distance"in e)}function $9(e){return !!(e&&"delay"in e)}class TA{constructor(t,n,r){var o;r===void 0&&(r=w2e(t.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=true,this.document=void 0,this.activated=false,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=t,this.events=n;const{event:i}=t,{target:a}=i;this.props=t,this.events=n,this.document=Qf(a),this.documentListeners=new jh(this.document),this.listeners=new jh(r),this.windowListeners=new jh(ei(a)),this.initialCoordinates=(o=j3(i))!=null?o:wa,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach();}attach(){const{events:t,props:{options:{activationConstraint:n,bypassActivationConstraint:r}}}=this;if(this.listeners.add(t.move.name,this.handleMove,{passive:false}),this.listeners.add(t.end.name,this.handleEnd),t.cancel&&this.listeners.add(t.cancel.name,this.handleCancel),this.windowListeners.add(Fi.Resize,this.handleCancel),this.windowListeners.add(Fi.DragStart,x9),this.windowListeners.add(Fi.VisibilityChange,this.handleCancel),this.windowListeners.add(Fi.ContextMenu,x9),this.documentListeners.add(Fi.Keydown,this.handleKeydown),n){if(r!=null&&r({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if($9(n)){this.timeoutId=setTimeout(this.handleStart,n.delay),this.handlePending(n);return}if(w9(n)){this.handlePending(n);return}}this.handleStart();}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),this.timeoutId!==null&&(clearTimeout(this.timeoutId),this.timeoutId=null);}handlePending(t,n){const{active:r,onPending:o}=this.props;o(r,t,this.initialCoordinates,n);}handleStart(){const{initialCoordinates:t}=this,{onStart:n}=this.props;t&&(this.activated=true,this.documentListeners.add(Fi.Click,$2e,{capture:true}),this.removeTextSelection(),this.documentListeners.add(Fi.SelectionChange,this.removeTextSelection),n(t));}handleMove(t){var n;const{activated:r,initialCoordinates:o,props:i}=this,{onMove:a,options:{activationConstraint:l}}=i;if(!o)return;const u=(n=j3(t))!=null?n:wa,d=Cy(o,u);if(!r&&l){if(w9(l)){if(l.tolerance!=null&&f$(d,l.tolerance))return this.handleCancel();if(f$(d,l.distance))return this.handleStart()}if($9(l)&&f$(d,l.tolerance))return this.handleCancel();this.handlePending(l,d);return}t.cancelable&&t.preventDefault(),a(u);}handleEnd(){const{onAbort:t,onEnd:n}=this.props;this.detach(),this.activated||t(this.props.active),n();}handleCancel(){const{onAbort:t,onCancel:n}=this.props;this.detach(),this.activated||t(this.props.active),n();}handleKeydown(t){t.code===En.Esc&&this.handleCancel();}removeTextSelection(){var t;(t=this.document.getSelection())==null||t.removeAllRanges();}}const M2e={cancel:{name:"pointercancel"},move:{name:"pointermove"},end:{name:"pointerup"}};class AA extends TA{constructor(t){const{event:n}=t,r=Qf(n.target);super(t,M2e,r);}}AA.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return !n.isPrimary||n.button!==0?false:(r?.({event:n}),true)}}];const R2e={move:{name:"mousemove"},end:{name:"mouseup"}};var W3;(function(e){e[e.RightClick=2]="RightClick";})(W3||(W3={}));class T2e extends TA{constructor(t){super(t,R2e,Qf(t.event.target));}}T2e.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button===W3.RightClick?false:(r?.({event:n}),true)}}];const m$={cancel:{name:"touchcancel"},move:{name:"touchmove"},end:{name:"touchend"}};class A2e extends TA{constructor(t){super(t,m$);}static setup(){return window.addEventListener(m$.move.name,t,{capture:false,passive:false}),function(){window.removeEventListener(m$.move.name,t);};function t(){}}}A2e.activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;const{touches:o}=n;return o.length>1?false:(r?.({event:n}),true)}}];var Uh;(function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect";})(Uh||(Uh={}));var wy;(function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder";})(wy||(wy={}));function N2e(e){let{acceleration:t,activator:n=Uh.Pointer,canScroll:r,draggingRect:o,enabled:i,interval:a=5,order:l=wy.TreeOrder,pointerCoordinates:u,scrollableAncestors:d,scrollableAncestorRects:m,delta:p,threshold:g}=e;const b=I2e({delta:p,disabled:!i}),[y,S]=F$e(),C=f.useRef({x:0,y:0}),w=f.useRef({x:0,y:0}),$=f.useMemo(()=>{switch(n){case Uh.Pointer:return u?{top:u.y,bottom:u.y,left:u.x,right:u.x}:null;case Uh.DraggableRect:return o}},[n,o,u]),M=f.useRef(null),T=f.useCallback(()=>{const I=M.current;if(!I)return;const N=C.current.x*w.current.x,P=C.current.y*w.current.y;I.scrollBy(N,P);},[]),R=f.useMemo(()=>l===wy.TreeOrder?[...d].reverse():d,[l,d]);f.useEffect(()=>{if(!i||!d.length||!$){S();return}for(const I of R){if(r?.(I)===false)continue;const N=d.indexOf(I),P=m[N];if(!P)continue;const{direction:O,speed:_}=v2e(I,P,$,t,g);for(const B of ["x","y"])b[B][O[B]]||(_[B]=0,O[B]=0);if(_.x>0||_.y>0){S(),M.current=I,y(T,a),C.current=_,w.current=O;return}}C.current={x:0,y:0},w.current={x:0,y:0},S();},[t,T,r,S,i,a,JSON.stringify($),JSON.stringify(b),y,d,R,m,JSON.stringify(g)]);}const P2e={x:{[Lr.Backward]:false,[Lr.Forward]:false},y:{[Lr.Backward]:false,[Lr.Forward]:false}};function I2e(e){let{delta:t,disabled:n}=e;const r=V3(t);return Mg(o=>{if(n||!r||!o)return P2e;const i={x:Math.sign(t.x-r.x),y:Math.sign(t.y-r.y)};return {x:{[Lr.Backward]:o.x[Lr.Backward]||i.x===-1,[Lr.Forward]:o.x[Lr.Forward]||i.x===1},y:{[Lr.Backward]:o.y[Lr.Backward]||i.y===-1,[Lr.Forward]:o.y[Lr.Forward]||i.y===1}}},[n,t,r])}function O2e(e,t){const n=t!=null?e.get(t):void 0,r=n?n.node.current:null;return Mg(o=>{var i;return t==null?null:(i=r??o)!=null?i:null},[r,t])}function D2e(e,t){return f.useMemo(()=>e.reduce((n,r)=>{const{sensor:o}=r,i=o.activators.map(a=>({eventName:a.eventName,handler:t(a.handler,r)}));return [...n,...i]},[]),[e,t])}var Ap;(function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging";})(Ap||(Ap={}));var G3;(function(e){e.Optimized="optimized";})(G3||(G3={}));const E9=new Map;function _2e(e,t){let{dragging:n,dependencies:r,config:o}=t;const[i,a]=f.useState(null),{frequency:l,measure:u,strategy:d}=o,m=f.useRef(e),p=C(),g=Tp(p),b=f.useCallback(function(w){w===void 0&&(w=[]),!g.current&&a($=>$===null?w:$.concat(w.filter(M=>!$.includes(M))));},[g]),y=f.useRef(null),S=Mg(w=>{if(p&&!n)return E9;if(!w||w===E9||m.current!==e||i!=null){const $=new Map;for(let M of e){if(!M)continue;if(i&&i.length>0&&!i.includes(M.id)&&M.rect.current){$.set(M.id,M.rect.current);continue}const T=M.node.current,R=T?new RA(u(T),T):null;M.rect.current=R,R&&$.set(M.id,R);}return $}return w},[e,i,n,p,u]);return f.useEffect(()=>{m.current=e;},[e]),f.useEffect(()=>{p||b();},[n,p]),f.useEffect(()=>{i&&i.length>0&&a(null);},[JSON.stringify(i)]),f.useEffect(()=>{p||typeof l!="number"||y.current!==null||(y.current=setTimeout(()=>{b(),y.current=null;},l));},[l,p,b,...r]),{droppableRects:S,measureDroppableContainers:b,measuringScheduled:i!=null};function C(){switch(d){case Ap.Always:return false;case Ap.BeforeDragging:return n;default:return !n}}}function AW(e,t){return Mg(n=>e?n||(typeof t=="function"?t(e):e):null,[t,e])}function B2e(e,t){return AW(e,t)}function L2e(e){let{callback:t,disabled:n}=e;const r=$A(t),o=f.useMemo(()=>{if(n||typeof window>"u"||typeof window.MutationObserver>"u")return;const{MutationObserver:i}=window;return new i(r)},[r,n]);return f.useEffect(()=>()=>o?.disconnect(),[o]),o}function V1(e){let{callback:t,disabled:n}=e;const r=$A(t),o=f.useMemo(()=>{if(n||typeof window>"u"||typeof window.ResizeObserver>"u")return;const{ResizeObserver:i}=window;return new i(r)},[n]);return f.useEffect(()=>()=>o?.disconnect(),[o]),o}function z2e(e){return new RA(Zf(e),e)}function M9(e,t,n){t===void 0&&(t=z2e);const[r,o]=f.useState(null);function i(){o(u=>{if(!e)return null;if(e.isConnected===false){var d;return (d=u??n)!=null?d:null}const m=t(e);return JSON.stringify(u)===JSON.stringify(m)?u:m});}const a=L2e({callback(u){if(e)for(const d of u){const{type:m,target:p}=d;if(m==="childList"&&p instanceof HTMLElement&&p.contains(e)){i();break}}}}),l=V1({callback:i});return Ya(()=>{i(),e?(l?.observe(e),a?.observe(document.body,{childList:true,subtree:true})):(l?.disconnect(),a?.disconnect());},[e]),r}function k2e(e){const t=AW(e);return SW(e,t)}const R9=[];function F2e(e){const t=f.useRef(e),n=Mg(r=>e?r&&r!==R9&&e&&t.current&&e.parentNode===t.current.parentNode?r:MA(e):R9,[e]);return f.useEffect(()=>{t.current=e;},[e]),n}function H2e(e){const[t,n]=f.useState(null),r=f.useRef(e),o=f.useCallback(i=>{const a=d$(i.target);a&&n(l=>l?(l.set(a,U3(a)),new Map(l)):null);},[]);return f.useEffect(()=>{const i=r.current;if(e!==i){a(i);const l=e.map(u=>{const d=d$(u);return d?(d.addEventListener("scroll",o,{passive:true}),[d,U3(d)]):null}).filter(u=>u!=null);n(l.length?new Map(l):null),r.current=e;}return ()=>{a(e),a(i);};function a(l){l.forEach(u=>{const d=d$(u);d?.removeEventListener("scroll",o);});}},[o,e]),f.useMemo(()=>e.length?t?Array.from(t.values()).reduce((i,a)=>Xd(i,a),wa):MW(e):wa,[e,t])}function T9(e,t){t===void 0&&(t=[]);const n=f.useRef(null);return f.useEffect(()=>{n.current=null;},t),f.useEffect(()=>{const r=e!==wa;r&&!n.current&&(n.current=e),!r&&n.current&&(n.current=null);},[e]),n.current?Cy(e,n.current):wa}function V2e(e){f.useEffect(()=>{if(!H1)return;const t=e.map(n=>{let{sensor:r}=n;return r.setup==null?void 0:r.setup()});return ()=>{for(const n of t)n?.();}},e.map(t=>{let{sensor:n}=t;return n}));}function j2e(e,t){return f.useMemo(()=>e.reduce((n,r)=>{let{eventName:o,handler:i}=r;return n[o]=a=>{i(a,t);},n},{}),[e,t])}function NW(e){return f.useMemo(()=>e?m2e(e):null,[e])}const A9=[];function U2e(e,t){t===void 0&&(t=Zf);const[n]=e,r=NW(n?ei(n):null),[o,i]=f.useState(A9);function a(){i(()=>e.length?e.map(u=>$W(u)?r:new RA(t(u),u)):A9);}const l=V1({callback:a});return Ya(()=>{l?.disconnect(),a(),e.forEach(u=>l?.observe(u));},[e]),o}function W2e(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return Eg(t)?t:e}function G2e(e){let{measure:t}=e;const[n,r]=f.useState(null),o=f.useCallback(d=>{for(const{target:m}of d)if(Eg(m)){r(p=>{const g=t(m);return p?{...p,width:g.width,height:g.height}:g});break}},[t]),i=V1({callback:o}),a=f.useCallback(d=>{const m=W2e(d);i?.disconnect(),m&&i?.observe(m),r(m?t(m):null);},[t,i]),[l,u]=Sy(a);return f.useMemo(()=>({nodeRef:l,rect:n,setRef:u}),[n,l,u])}const q2e=[{sensor:AA,options:{}},{sensor:TW,options:{}}],K2e={current:{}},u0={draggable:{measure:C9},droppable:{measure:C9,strategy:Ap.WhileDragging,frequency:G3.Optimized},dragOverlay:{measure:Zf}};class Wh extends Map{get(t){var n;return t!=null&&(n=super.get(t))!=null?n:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter(t=>{let{disabled:n}=t;return !n})}getNodeFor(t){var n,r;return (n=(r=this.get(t))==null?void 0:r.node.current)!=null?n:void 0}}const Y2e={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new Wh,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:xy},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:u0,measureDroppableContainers:xy,windowRect:null,measuringScheduled:false},X2e={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:xy,draggableNodes:new Map,over:null,measureDroppableContainers:xy},j1=f.createContext(X2e),PW=f.createContext(Y2e);function Q2e(){return {draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new Wh}}}function Z2e(e,t){switch(t.type){case Ar.DragStart:return {...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case Ar.DragMove:return e.draggable.active==null?e:{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}};case Ar.DragEnd:case Ar.DragCancel:return {...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case Ar.RegisterDroppable:{const{element:n}=t,{id:r}=n,o=new Wh(e.droppable.containers);return o.set(r,n),{...e,droppable:{...e.droppable,containers:o}}}case Ar.SetDroppableDisabled:{const{id:n,key:r,disabled:o}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;const a=new Wh(e.droppable.containers);return a.set(n,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:a}}}case Ar.UnregisterDroppable:{const{id:n,key:r}=t,o=e.droppable.containers.get(n);if(!o||r!==o.key)return e;const i=new Wh(e.droppable.containers);return i.delete(n),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function J2e(e){let{disabled:t}=e;const{active:n,activatorEvent:r,draggableNodes:o}=f.useContext(j1),i=V3(r),a=V3(n?.id);return f.useEffect(()=>{if(!t&&!r&&i&&a!=null){if(!EA(i)||document.activeElement===i.target)return;const l=o.get(a);if(!l)return;const{activatorNode:u,node:d}=l;if(!u.current&&!d.current)return;requestAnimationFrame(()=>{for(const m of [u.current,d.current]){if(!m)continue;const p=j$e(m);if(p){p.focus();break}}});}},[r,t,o,a,i]),null}function eEe(e,t){let{transform:n,...r}=t;return e!=null&&e.length?e.reduce((o,i)=>i({transform:o,...r}),n):n}function tEe(e){return f.useMemo(()=>({draggable:{...u0.draggable,...e?.draggable},droppable:{...u0.droppable,...e?.droppable},dragOverlay:{...u0.dragOverlay,...e?.dragOverlay}}),[e?.draggable,e?.droppable,e?.dragOverlay])}function nEe(e){let{activeNode:t,measure:n,initialRect:r,config:o=true}=e;const i=f.useRef(false),{x:a,y:l}=typeof o=="boolean"?{x:o,y:o}:o;Ya(()=>{if(!a&&!l||!t){i.current=false;return}if(i.current||!r)return;const d=t?.node.current;if(!d||d.isConnected===false)return;const m=n(d),p=SW(m,r);if(a||(p.x=0),l||(p.y=0),i.current=true,Math.abs(p.x)>0||Math.abs(p.y)>0){const g=CW(d);g&&g.scrollBy({top:p.y,left:p.x});}},[t,a,l,r,n]);}const IW=f.createContext({...wa,scaleX:1,scaleY:1});var Ml;(function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized";})(Ml||(Ml={}));const OW=f.memo(function(t){var n,r,o,i;let{id:a,accessibility:l,autoScroll:u=true,children:d,sensors:m=q2e,collisionDetection:p=a2e,measuring:g,modifiers:b,...y}=t;const S=f.useReducer(Z2e,void 0,Q2e),[C,w]=S,[$,M]=K$e(),[T,R]=f.useState(Ml.Uninitialized),I=T===Ml.Initialized,{draggable:{active:N,nodes:P,translate:O},droppable:{containers:_}}=C,B=N!=null?P.get(N):null,V=f.useRef({initial:null,translated:null}),U=f.useMemo(()=>{var ut;return N!=null?{id:N,data:(ut=B?.data)!=null?ut:K2e,rect:V}:null},[N,B]),G=f.useRef(null),[H,z]=f.useState(null),[j,W]=f.useState(null),Y=Tp(y,Object.values(y)),Q=Rg("DndDescribedBy",a),D=f.useMemo(()=>_.getEnabled(),[_]),L=tEe(g),{droppableRects:K,measureDroppableContainers:J,measuringScheduled:ee}=_2e(D,{dragging:I,dependencies:[O.x,O.y],config:L.droppable}),te=O2e(P,N),re=f.useMemo(()=>j?j3(j):null,[j]),ie=Tt(),de=B2e(te,L.draggable.measure);nEe({activeNode:N!=null?P.get(N):null,config:ie.layoutShiftCompensation,initialRect:de,measure:L.draggable.measure});const ne=M9(te,L.draggable.measure,de),ce=M9(te?te.parentElement:null),fe=f.useRef({activatorEvent:null,active:null,activeNode:te,collisionRect:null,collisions:null,droppableRects:K,draggableNodes:P,draggingNode:null,draggingNodeRect:null,droppableContainers:_,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),se=_.getNodeFor((n=fe.current.over)==null?void 0:n.id),Me=G2e({measure:L.dragOverlay.measure}),ae=(r=Me.nodeRef.current)!=null?r:te,pe=I?(o=Me.rect)!=null?o:ne:null,Ce=!!(Me.nodeRef.current&&Me.rect),xe=k2e(Ce?null:ne),Ae=NW(ae?ei(ae):null),Xe=F2e(I?se??te:null),Ne=U2e(Xe),ue=eEe(b,{transform:{x:O.x-xe.x,y:O.y-xe.y,scaleX:1,scaleY:1},activatorEvent:j,active:U,activeNodeRect:ne,containerNodeRect:ce,draggingNodeRect:pe,over:fe.current.over,overlayNodeRect:Me.rect,scrollableAncestors:Xe,scrollableAncestorRects:Ne,windowRect:Ae}),ge=re?Xd(re,O):null,Pe=H2e(Xe),je=T9(Pe),qe=T9(Pe,[ne]),Ue=Xd(ue,je),et=pe?c2e(pe,ue):null,rt=U&&et?p({active:U,collisionRect:et,droppableRects:K,droppableContainers:D,pointerCoordinates:ge}):null,Ke=r2e(rt,"id"),[_e,We]=f.useState(null),Ze=Ce?ue:Xd(ue,qe),Be=s2e(Ze,(i=_e?.rect)!=null?i:null,ne),Oe=f.useRef(null),lt=f.useCallback((ut,dt)=>{let{sensor:gt,options:Fe}=dt;if(G.current==null)return;const Qe=P.get(G.current);if(!Qe)return;const ye=ut.nativeEvent,be=new gt({active:G.current,activeNode:Qe,event:ye,options:Fe,context:fe,onAbort(he){if(!P.get(he))return;const{onDragAbort:$e}=Y.current,ke={id:he};$e?.(ke),$({type:"onDragAbort",event:ke});},onPending(he,De,$e,ke){if(!P.get(he))return;const{onDragPending:ot}=Y.current,ht={id:he,constraint:De,initialCoordinates:$e,offset:ke};ot?.(ht),$({type:"onDragPending",event:ht});},onStart(he){const De=G.current;if(De==null)return;const $e=P.get(De);if(!$e)return;const{onDragStart:ke}=Y.current,Ge={activatorEvent:ye,active:{id:De,data:$e.data,rect:V}};$o.unstable_batchedUpdates(()=>{ke?.(Ge),R(Ml.Initializing),w({type:Ar.DragStart,initialCoordinates:he,active:De}),$({type:"onDragStart",event:Ge}),z(Oe.current),W(ye);});},onMove(he){w({type:Ar.DragMove,coordinates:he});},onEnd:Se(Ar.DragEnd),onCancel:Se(Ar.DragCancel)});Oe.current=be;function Se(he){return async function(){const{active:$e,collisions:ke,over:Ge,scrollAdjustedTranslate:ot}=fe.current;let ht=null;if($e&&ot){const{cancelDrop:$t}=Y.current;ht={activatorEvent:ye,active:$e,collisions:ke,delta:ot,over:Ge},he===Ar.DragEnd&&typeof $t=="function"&&await Promise.resolve($t(ht))&&(he=Ar.DragCancel);}G.current=null,$o.unstable_batchedUpdates(()=>{w({type:he}),R(Ml.Uninitialized),We(null),z(null),W(null),Oe.current=null;const $t=he===Ar.DragEnd?"onDragEnd":"onDragCancel";if(ht){const Rt=Y.current[$t];Rt?.(ht),$({type:$t,event:ht});}});}}},[P]),It=f.useCallback((ut,dt)=>(gt,Fe)=>{const Qe=gt.nativeEvent,ye=P.get(Fe);if(G.current!==null||!ye||Qe.dndKit||Qe.defaultPrevented)return;const be={active:ye};ut(gt,dt.options,be)===true&&(Qe.dndKit={capturedBy:dt.sensor},G.current=Fe,lt(gt,dt));},[P,lt]),mt=D2e(m,It);V2e(m),Ya(()=>{ne&&T===Ml.Initializing&&R(Ml.Initialized);},[ne,T]),f.useEffect(()=>{const{onDragMove:ut}=Y.current,{active:dt,activatorEvent:gt,collisions:Fe,over:Qe}=fe.current;if(!dt||!gt)return;const ye={active:dt,activatorEvent:gt,collisions:Fe,delta:{x:Ue.x,y:Ue.y},over:Qe};$o.unstable_batchedUpdates(()=>{ut?.(ye),$({type:"onDragMove",event:ye});});},[Ue.x,Ue.y]),f.useEffect(()=>{const{active:ut,activatorEvent:dt,collisions:gt,droppableContainers:Fe,scrollAdjustedTranslate:Qe}=fe.current;if(!ut||G.current==null||!dt||!Qe)return;const{onDragOver:ye}=Y.current,be=Fe.get(Ke),Se=be&&be.rect.current?{id:be.id,rect:be.rect.current,data:be.data,disabled:be.disabled}:null,he={active:ut,activatorEvent:dt,collisions:gt,delta:{x:Qe.x,y:Qe.y},over:Se};$o.unstable_batchedUpdates(()=>{We(Se),ye?.(he),$({type:"onDragOver",event:he});});},[Ke]),Ya(()=>{fe.current={activatorEvent:j,active:U,activeNode:te,collisionRect:et,collisions:rt,droppableRects:K,draggableNodes:P,draggingNode:ae,draggingNodeRect:pe,droppableContainers:_,over:_e,scrollableAncestors:Xe,scrollAdjustedTranslate:Ue},V.current={initial:pe,translated:et};},[U,te,rt,et,P,ae,pe,K,_,_e,Xe,Ue]),N2e({...ie,delta:O,draggingRect:et,pointerCoordinates:ge,scrollableAncestors:Xe,scrollableAncestorRects:Ne});const Bt=f.useMemo(()=>({active:U,activeNode:te,activeNodeRect:ne,activatorEvent:j,collisions:rt,containerNodeRect:ce,dragOverlay:Me,draggableNodes:P,droppableContainers:_,droppableRects:K,over:_e,measureDroppableContainers:J,scrollableAncestors:Xe,scrollableAncestorRects:Ne,measuringConfiguration:L,measuringScheduled:ee,windowRect:Ae}),[U,te,ne,j,rt,ce,Me,P,_,K,_e,J,Xe,Ne,L,ee,Ae]),xt=f.useMemo(()=>({activatorEvent:j,activators:mt,active:U,activeNodeRect:ne,ariaDescribedById:{draggable:Q},dispatch:w,draggableNodes:P,over:_e,measureDroppableContainers:J}),[j,mt,U,ne,w,Q,P,_e,J]);return q.createElement(bW.Provider,{value:M},q.createElement(j1.Provider,{value:xt},q.createElement(PW.Provider,{value:Bt},q.createElement(IW.Provider,{value:Be},d)),q.createElement(J2e,{disabled:l?.restoreFocus===false})),q.createElement(Q$e,{...l,hiddenTextDescribedById:Q}));function Tt(){const ut=H?.autoScrollEnabled===false,dt=typeof u=="object"?u.enabled===false:u===false,gt=I&&!ut&&!dt;return typeof u=="object"?{...u,enabled:gt}:{enabled:gt}}}),rEe=f.createContext(null),N9="button",oEe="Draggable";function DW(e){let{id:t,data:n,disabled:r=false,attributes:o}=e;const i=Rg(oEe),{activators:a,activatorEvent:l,active:u,activeNodeRect:d,ariaDescribedById:m,draggableNodes:p,over:g}=f.useContext(j1),{role:b=N9,roleDescription:y="draggable",tabIndex:S=0}=o??{},C=u?.id===t,w=f.useContext(C?IW:rEe),[$,M]=Sy(),[T,R]=Sy(),I=j2e(a,t),N=Tp(n);Ya(()=>(p.set(t,{id:t,key:i,node:$,activatorNode:T,data:N}),()=>{const O=p.get(t);O&&O.key===i&&p.delete(t);}),[p,t]);const P=f.useMemo(()=>({role:b,tabIndex:S,"aria-disabled":r,"aria-pressed":C&&b===N9?true:void 0,"aria-roledescription":y,"aria-describedby":m.draggable}),[r,b,S,C,y,m.draggable]);return {active:u,activatorEvent:l,activeNodeRect:d,attributes:P,isDragging:C,listeners:r?void 0:I,node:$,over:g,setNodeRef:M,setActivatorNodeRef:R,transform:w}}function iEe(){return f.useContext(PW)}const aEe="Droppable",sEe={timeout:25};function lEe(e){let{data:t,disabled:n=false,id:r,resizeObserverConfig:o}=e;const i=Rg(aEe),{active:a,dispatch:l,over:u,measureDroppableContainers:d}=f.useContext(j1),m=f.useRef({disabled:n}),p=f.useRef(false),g=f.useRef(null),b=f.useRef(null),{disabled:y,updateMeasurementsFor:S,timeout:C}={...sEe,...o},w=Tp(S??r),$=f.useCallback(()=>{if(!p.current){p.current=true;return}b.current!=null&&clearTimeout(b.current),b.current=setTimeout(()=>{d(Array.isArray(w.current)?w.current:[w.current]),b.current=null;},C);},[C]),M=V1({callback:$,disabled:y||!a}),T=f.useCallback((P,O)=>{M&&(O&&(M.unobserve(O),p.current=false),P&&M.observe(P));},[M]),[R,I]=Sy(T),N=Tp(t);return f.useEffect(()=>{!M||!R.current||(M.disconnect(),p.current=false,M.observe(R.current));},[R,M]),f.useEffect(()=>(l({type:Ar.RegisterDroppable,element:{id:r,key:i,disabled:n,node:R,rect:g,data:N}}),()=>l({type:Ar.UnregisterDroppable,key:i,id:r})),[r]),f.useEffect(()=>{n!==m.current.disabled&&(l({type:Ar.SetDroppableDisabled,id:r,key:i,disabled:n}),m.current.disabled=n);},[r,i,n,l]),{active:a,rect:g,isOver:u?.id===r,node:R,over:u,setNodeRef:I}}function cEe(e,t){Ha(e)||(typeof e=="function"?e(t):e.current=t);}function U1(...e){const t=f.useRef(null);return f.useMemo(()=>({get current(){return t.current},set current(n){t.current=n,e.forEach(r=>r&&cEe(r,n));}}),[t,...e])}const Qd=nc(()=>({width:window.innerWidth,height:window.innerHeight}));document.addEventListener("resize",Qd.updateThrottled);document.addEventListener("orientationchange",Qd.updateThrottled);document.addEventListener("scroll",Yl(Qd.update,1e3));function uEe({expanded:e,children:t,...n}){return x("div",{...n,"data-classname":"wrapper",css:ln("transition:grid-template-rows 0.2s ease-out;display:grid;grid-template-rows:",e?1:0,"fr;",""),children:x("div",{"data-classname":"inner",className:"overflow-hidden",children:t})})}function fn(e){return x(Jl,{...e,styles:{...e.styles,root:{width:"max-content",maxWidth:"50vw",...e.styles?.root}},children:e.children})}const dEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M40 20c0 6.808-4.252 12.622-10.244 14.934H18.244C12.252 32.622 8 26.808 8 20c0-8.837 7.163-16 16-16s16 7.163 16 16"}),x("path",{d:"m29.756 34.934l-.68 8.15a1 1 0 0 1-.996.916h-8.16a1 1 0 0 1-.996-.917l-.68-8.15M18 17v6l6-3l6 3v-6"})]})]}),fEe=f.forwardRef(dEe),mEe=fEe,_W="rgb(0 0 0 / 0.85)";function pr({children:e,tooltipProps:t,IconComponent:n,className:r,useBlackBg:o,...i}){n??=mEe;const a=x(n,{...i,className:ur("ml-4px size-16px cursor-pointer",r)});return !!e&&x(fn,{color:o?_W:void 0,...t,title:e,children:a})}function hEe(e,t){const n=Ut(),r=!!To(n,e,false),o=f.useCallback(l=>{$f(at,e,l),t?.(l);},[]),i=f.useCallback(l=>{o(l.target.checked);},[]),a=f.useCallback(()=>{o(!To(at,e,false));},[]);return {checked:r,onChange:o,checkboxOnChange:i,onToggle:a}}function BW({configPath:e,label:t,extraAction:n,tooltip:r,tooltipProps:o,as:i,checkboxProps:a,switchProps:l,ref:u}){const{checked:d,onChange:m,checkboxOnChange:p}=hEe(e,n),g=y=>r?x(fn,{...o,title:r,children:y}):y;let b;if(typeof t=="function"?b=t(d):b=(t??e)||null,i==="checkbox"){let y=x("span",{style:{userSelect:"none"},children:b});return r&&(y=g(y)),x(Ki,{...a,ref:u,checked:d,onChange:p,styles:{label:{paddingInline:6}},children:y})}if(i==="switch"){let y=x(NH,{...l,checked:d,onChange:m,ref:u});return r&&(y=g(y)),y}}const Pt=function({configPath:e,label:t,extraAction:n,tooltip:r,tooltipProps:o,ref:i,...a}){return x(BW,{ref:i,configPath:e,label:t,extraAction:n,tooltip:r,tooltipProps:o,as:"checkbox",checkboxProps:a})};function pu({configPath:e,extraAction:t,tooltip:n,tooltipProps:r,ref:o,...i}){return x(BW,{ref:o,configPath:e,extraAction:t,tooltip:n,tooltipProps:r,as:"switch",switchProps:i})}async function W1(e="即将刷新网页!"){_t.info(e),await gn(500),location.reload();}function Br(e,t){return F(ze,{children:[F("div",{className:"flex items-center",children:["✅: ",e]}),F("div",{className:"flex items-center",children:["❎: ",t]})]})}let uh;function pEe(){wf(()=>{uh&&URL.revokeObjectURL(uh),uh=void 0;});const e=yg(),t=JSON.stringify(e,null,2),n=new Blob([t],{type:"application/json"});return uh=URL.createObjectURL(n),uh}function gEe(){const e=pEe(),t=`${Ao}-settings ${Yn().format("YYYY-MM-DD HH:mm:ss")}.json`;if(typeof GM_download<"u")GM_download?.({url:e,name:t});else {const n=document.createElement("a");n.href=e,n.download=t,n.click();}}async function vEe(){const e=await bEe();if(!e)return;const t=await e.text();if(!t)return rn("文件内容为空!");let n;try{n=JSON.parse(t);}catch{return rn("无法解析文件内容!")}dA(n);const{pickedPaths:r,pickedSettings:o}=Wf(n,ic);return r.length?(dU(true),Ka(o),_t.success("导入成功!"),W1()):rn("没有有效的设置!")}function bEe(){return yEe({accept:".json",multiple:false})}function yEe(e){return new Promise(t=>{const n=document.createElement("input");n.type="file",Object.assign(n,e),n.addEventListener("change",()=>{t(n.files?.[0]||null);}),n.click();})}const Bn={tabPane:"max-h-[max(362px,calc(90vh-50px-56px-15px))] min-h-362px overflow-y-auto pr-12px",settingsGroup:"mb-10px",settingsGroupTitle:"flex items-center text-2em",settingsGroupSubTitle:"flex items-center text-1.25em",settingsLine:"flex flex-row flex-wrap items-center gap-x-10px gap-y-1"};function eo({children:e,title:t,titleClassName:n,contentClassName:r,resetSettingPaths:o,...i}){const a=!!o?.length;return F("div",{className:Bn.settingsGroup,"data-role":"settings-group",...i,children:[F("div",{"data-role":"settings-group-title",className:ur(Bn.settingsGroupTitle,a&&"justify-between",n),children:[a?x("div",{className:"flex items-center",children:t}):t,o&&x(LW,{paths:o})]}),x("div",{"data-role":"settings-group-content",className:ur("flex flex-col gap-y-1",r),children:e})]})}function SEe(e){const{pickedSettings:t}=Wf(bg,e);Ka(t);}function LW({paths:e,className:t}){return x(yp,{title:"确定重置下面的设置项?",onConfirm:()=>SEe(e),children:F(st,{className:X("gap-x-4px",t),children:[x(WH,{className:"mt--1px size-12px"}),x("span",{children:"重置"})]})})}const CEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"M3.06 13a9 9 0 1 0 .49-4.087"}),x("path",{d:"M3 4.001v5h5M11 12a1 1 0 1 0 2 0a1 1 0 1 0-2 0"})]})]}),P9=f.forwardRef(CEe),xEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"M14 3v4a1 1 0 0 0 1 1h4"}),x("path",{d:"M11.5 21H7a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7l5 5v5m-5 6h7m-3-3l3 3l-3 3"})]})]}),Np=f.forwardRef(xEe),wEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"M14 3v4a1 1 0 0 0 1 1h4"}),x("path",{d:"M5 13V5a2 2 0 0 1 2-2h7l5 5v11a2 2 0 0 1-2 2h-5.5M2 19h7m-3-3l3 3l-3 3"})]})]}),Pp=f.forwardRef(wEe),$Ee=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5l1.53.11A2.98 2.98 0 0 1 22 15c0 1.65-1.35 3-3 3H6c-2.21 0-4-1.79-4-4c0-2.05 1.53-3.76 3.56-3.97l1.07-.11l.5-.95A5.47 5.47 0 0 1 12 6m0-2C9.11 4 6.6 5.64 5.35 8.04A5.994 5.994 0 0 0 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5c0-2.64-2.05-4.78-4.65-4.96A7.49 7.49 0 0 0 12 4"})]}),EEe=f.forwardRef($Ee),MEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M24 44c11.046 0 20-8.954 20-20S35.046 4 24 4S4 12.954 4 24s8.954 20 20 20Z"}),x("path",{strokeLinecap:"round",d:"m33 21l-9 9l-9-9"})]})]}),REe=f.forwardRef(MEe);function TEe(){return Fxe(),W1()}async function AEe(){const e=await lU.getData();dA(e);const{pickedPaths:t,pickedSettings:n}=Wf(e,ic,Oxe);return t.length?(dU(true),Ka(n),W1()):_t.error("备份不存在或没有有效的配置")}function NEe(){const[e,t]=f.useState(false);return F("div",{className:Bn.tabPane,children:[x(eo,{title:"设置项",children:F(Zr,{size:20,children:[x(yp,{title:"确定",description:"确定恢复默认设置? 此操作不可逆!",onConfirm:TEe,children:F(st,{danger:true,type:"primary",children:[x(P9,{}),"恢复默认设置"]})}),F(Zr,{size:5,children:[x(fn,{title:"导出所有设置项到文件中, 包含 access_key 等数据, 请妥善保存",children:F(st,{onClick:()=>gEe(),children:[x(Np,{}),"导出设置"]})}),x(fn,{title:"从文件中导入设置项, 将覆盖当前设置, 此操作不可逆!",children:F(st,{onClick:()=>vEe(),children:[x(Pp,{}),"导入设置"]})})]})]})}),x(eo,{title:F(ze,{children:[x(EEe,{className:"mr-4px size-28px"}),"备份"]}),children:F("div",{className:"flex items-center gap-x-40px",children:[F("span",{className:"flex items-center gap-x-8px",children:[x(Pt,{configPath:"backupSettingsToArticleDraft",label:"备份设置到专栏草稿箱中",tooltip:`专栏 - 草稿箱 - ${Ao}`}),F("a",{className:"inline-flex items-center",href:"https://member.bilibili.com/platform/upload/text/draft",target:"_blank",children:[x(No,{className:"mr-4px size-16px"}),"去草稿箱浏览"]})]}),x(yp,{title:"确定",description:"将覆盖本地设置? 此操作不可逆!",onConfirm:AEe,children:F(st,{danger:true,type:"primary",children:[x(P9,{}),"从专栏草稿箱中恢复"]})})]})}),x(eo,{title:F(ze,{children:["其他",x(pr,{children:"这里是一些作者不愿意解释的设置项 😬"}),x(st,{onClick:()=>t(n=>!n),className:"ml-10px inline-icon-only-round-button",css:e&&Gf,children:x(REe,{className:X("size-16px transition-300 transition-transform",e?"rotate-180":"rotate-0")})})]}),children:x(uEe,{expanded:e,children:F("div",{className:"w-full flex gap-x-20px b-1px b-gate-border rounded-6px b-solid p-10px",children:[x(LW,{paths:vy,className:"flex-none"}),x("div",{className:"flex flex-1 flex-wrap items-start gap-x-20px gap-y-10px",children:vy.map(n=>x(Pt,{configPath:n,tooltip:F(ze,{children:[n,I9[n]&&F(ze,{children:[x("br",{}),I9[n]]})]}),label:dQ(n.startsWith("__internal")?n.slice(10):n.replaceAll("__internal.",""))},n))})]})})})]})}const I9={};function zW(e,{l:t,c:n,h:r,alpha:o,deltaL:i,deltaC:a,deltaH:l,deltaAlpha:u}={}){const d=t??(i?`calc(l + ${i})`:"l"),m=n??(a?`calc(c + ${a})`:"c"),p=r??(l?`calc(h + ${l})`:"h"),g=o??(u?`calc(alpha + ${u})`:"alpha");return `oklch(from ${e} ${d} ${m} ${p} / ${g})`}function PEe(e,t){return zW(e,{deltaL:t})}function q3({className:e,...t}){return x(Ul,{variant:"solid",...t,className:ur("my-7px",e),css:ln("border-top-color:",zW(xa,{l:.9}),";","")})}const kW=e=>{const t=aU(e,Qh.appkey,Qh.appsec);return new URLSearchParams({...e,sign:t})};async function IEe(){const t=(await Qt.post("https://passport.bilibili.com/x/passport-tv-login/qrcode/auth_code",kW({appkey:Qh.appkey,local_id:"0",ts:"0"}))).data;if(!jn(t)){rn(t?.message||"获取 auth_code 失败");return}return t.data}async function OEe(e){const n=(await Qt.post("https://passport.bilibili.com/x/passport-tv-login/qrcode/poll",kW({appkey:Qh.appkey,auth_code:e,local_id:"0",ts:"0"}))).data,r={0:"成功","-3":"API校验密匙错误","-400":"请求错误","-404":"啥都木有",86038:"二维码已失效",86039:"二维码尚未确认",86090:"二维码已扫码未确认"};if(!jn(n)){const a=n.code.toString(),l=n.message||r[a]||"未知错误";return a==="86038"?{success:false,message:l,action:"refresh"}:a==="86039"||a==="86090"?{success:false,message:l,action:"wait"}:{success:false,message:l,action:void 0}}const o=n.data.access_token,i=Date.now()+n.data.expires_in*1e3;return {success:true,message:"获取成功",accessKey:o,accessKeyExpireAt:i}}const NA={show:false,qrcodeUrl:"",auth_code:"",message:"",expired:false},Rl=zn({...NA});function Hd(e){LEe(),Object.assign(Rl,e);}function DEe(e){Hd({...NA,...e,show:true});}const G1=new Xo;function FW(){Hd({...NA}),G1.emit("hide");}function O9(){return G1.once("hide")}function _Ee(){return G1.once("refresh")}function BEe(){const{qrcodeUrl:e,show:t,message:n,expired:r}=bt(Rl),o=FW,i=()=>{G1.emit("refresh");};return F(wg,{show:t,onHide:o,hideWhenMaskOnClick:false,hideWhenEsc:false,clsModalMask:"backdrop-blur-10px",clsModal:"aspect-ratio-10/16",width:260,children:[F("div",{className:Po.modalHeader,children:[x("div",{className:Po.modalTitle}),x($g,{onClick:o})]}),F("div",{className:X(Po.modalBody,"flex flex-col items-center justify-center text-center"),children:[x("div",{className:"mb-2px min-h-25px flex-center text-size-14px",children:n||""}),e&&F("div",{className:"relative mx-auto mb-40px flex-shrink-0",children:[x(kpe,{className:"p-8px",value:e,size:200,icon:"https://is1-ssl.mzstatic.com/image/thumb/Purple211/v4/72/9c/b6/729cb6d8-75f5-0a56-0508-3a26cbba69ae/AppIcon-1x_U007emarketing-0-6-0-0-85-220-0.png/230x0w.webp"}),r&&F("div",{className:"absolute inset-0 flex flex-col cursor-pointer items-center justify-center bg-black/65 text-white",onClick:i,children:[x("div",{className:"mb-8px text-size-14px font-600",children:"二维码已过期"}),x("div",{className:"border border-white/40 rounded-6px px-12px py-6px text-size-13px",children:"点击刷新"})]})]}),F("div",{className:"footnote text-size-13px line-height-snug",children:["打开「哔哩哔哩」或「bilibili」App ",x("br",{}),"扫码获取 access_key"]})]})]})}const LEe=xf(function(){const t=document.createElement("div");t.classList.add("modal-tv-qrcode-auth",$a),document.body.appendChild(t),Qa.createRoot(t).render(x(Us,{children:x(BEe,{})}));});async function D9(){const e=await IEe();if(e)return DEe({qrcodeUrl:e.url,auth_code:e.auth_code}),true}async function zEe(){let e,t;if(!await D9())return;e=Rl.auth_code;function r(){if(!Rl.show||!Rl.auth_code||e!==Rl.auth_code)return true}function o(){return !r()}for(;o();){const i=gn(1500),a=O9();if(await Promise.race([i,a]),a.off(),r())return;t=await OEe(Rl.auth_code);const{success:l,accessKey:u,accessKeyExpireAt:d,message:m,action:p}=t;if(r())return;if(Hd({message:m}),l)return await gn(1e3),FW(),{accessKey:u,accessKeyExpireAt:d};if(p==="refresh"){Hd({message:"二维码已过期,请点击刷新",expired:true});const g=O9(),b=_Ee();if(await Promise.race([g,b]),g.off(),b.off(),r()||!await D9())return;e=Rl.auth_code,Hd({message:"已刷新二维码",expired:false});continue}if(p!=="wait"){Hd({message:m}),rn(m);return}}}async function kEe(){const{accessKey:e,accessKeyExpireAt:t}=await zEe()||{};!e||!t||(at.accessKey=e,at.accessKeyExpireAt=t,rn("获取成功"));}function FEe(){at.accessKey="",at.accessKeyExpireAt=0,rn("已删除 access_key");}const _9=x(st,{target:"_blank",href:"https://github.com/indefined/UserScripts/tree/master/bilibiliHome#%E6%8E%88%E6%9D%83%E8%AF%B4%E6%98%8E",children:"access_key 说明"});function PA({style:e,className:t}){const{runAsync:n,loading:r}=ga(kEe,{manual:true}),{accessKey:o}=Ut();return x(Zr,{size:"small",style:e,className:t,children:o?F(ze,{children:[x(st,{onClick:n,loading:r,children:"重新获取 access_key"}),x(yp,{onConfirm:FEe,title:"确定删除 access_key?",children:x(st,{children:"删除 access_key"})}),_9]}):F(ze,{children:[x(st,{onClick:n,loading:r,children:"获取 access_key"}),_9]})})}const HEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M2 22V2h2v20zm4-5v-3h10v3zm0-7V7h16v3z"})]}),HW=f.forwardRef(HEe),VEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M11 22v-5H6v-3h5v-4H3V7h8V2h2v5h8v3h-8v4h5v3h-5v5z"})]}),jEe=f.forwardRef(VEe),UEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M20 22V2h2v20zM8 17v-3h10v3zm-6-7V7h16v3z"})]}),VW=f.forwardRef(UEe),jW="w-720px",WEe=(e,t)=>{switch(e){case ru.Left:return t==="flex"?"justify-left":"ml-0 mr-auto";case ru.Right:return t==="flex"?"justify-right":"ml-auto mr-0";default:return t==="flex"?"justify-center":"mx-auto"}};function GEe({className:e}){const{grid:{gridDisplayMode:t,twoColumnModeAlign:n}}=Ut();return F(to.Group,{className:e,disabled:t!==kr.TwoColumnGrid,buttonStyle:"solid",size:"small",value:n,onChange:r=>{at.grid.twoColumnModeAlign=r.target.value;},children:[x(to.Button,{value:ru.Left,className:"inline-flex-center",children:x(HW,{className:"size-16px"})}),x(to.Button,{value:ru.Center,className:"inline-flex-center",children:x(jEe,{className:"size-16px"})}),x(to.Button,{value:ru.Right,className:"inline-flex-center",children:x(VW,{className:"size-16px"})})]})}const qEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 5a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1zm10 0a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1zM4 15a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1zm10 0a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1z"})]}),KEe=f.forwardRef(qEe),YEe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M13 5h8m-8 4h5m-5 6h8m-8 4h5M3 5a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1zm0 10a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v4a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1z"})]}),XEe=f.forwardRef(YEe);function UW(e){return {usingListMode:e===kr.List,usingTwoColumnMode:e===kr.TwoColumnGrid,usingCenterEmptyMode:e===kr.CenterEmptyGrid}}function WW(){const{gridDisplayMode:e}=bt(at.grid);return UW(e)}function IA(e){return e===kr.List}function QEe(){return bt(at.grid).gridDisplayMode===kr.List}function ZEe({className:e}){const{gridDisplayMode:t}=bt(at.grid),o=ur("flex items-center gap-x-15px","[&_.ant-radio-wrapper]:inline-flex [&_.ant-radio-wrapper]:items-center","[&_.ant-radio-label]:inline-flex [&_.ant-radio-label]:items-center ![&_.ant-radio-label]:pl-4px",e);return x(to.Group,{size:"large",className:o,value:t,onChange:i=>{at.grid.gridDisplayMode=i.target.value;},options:[{value:kr.NormalGrid,label:x(fn,{title:"这个是默认的网格模式",children:F("span",{className:"inline-flex-center",children:[x(KEe,{className:"mx-4px size-16px cursor-pointer"}),"网格"]})})},{value:kr.List,label:F(ze,{children:[x(XEe,{className:"mx-4px size-16px cursor-pointer"}),"列表"]})},{value:kr.TwoColumnGrid,label:F(ze,{children:["双列模式",x(GEe,{className:"ml-5px"})]})},{value:kr.CenterEmptyGrid,label:x(ze,{children:x(fn,{title:"网格中间不显示卡片",children:"中空模式"})})}]})}const GW=TL&&["/video/","/list/watchlater","/bangumi/play/"].some(e=>location.pathname.startsWith(e)),JEe=[["/video/",()=>/^\/video\/(?<bvid>BV\w+)\//.exec(location.pathname)?.groups?.bvid],["/list/watchlater",()=>new URLSearchParams(location.search).get("bvid")||void 0],["/bangumi/play/",()=>{}]];function qW(){return JEe.find(([t])=>location.pathname.startsWith(t))?.[1]()}function OA(e,t=21){return `https://space.bilibili.com/${Jo()}/favlist?fid=${e}&ftype=create`}function KW(e,t=21){return `https://space.bilibili.com/${Jo()}/favlist?fid=${e}&ftype=collect&ctype=${t}`}function e3e(e){return `https://www.bilibili.com/list/ml${e}`}function t3e(e){return `https://www.bilibili.com/video/${e}`}function DA(e){return e.toString(2).at(-2)==="0"}function q1(e){return e.toString(2).at(-1)==="1"}async function YW({avid:e,add_media_ids:t="",del_media_ids:n=""}){const r=new URLSearchParams({rid:e.toString(),type:"2",add_media_ids:t,del_media_ids:n,platform:"web",eab_x:"2",ramval:"0",ga:"1",gaia_source:"web_normal",csrf:oc()}),i=(await Qt.post("/x/v3/fav/resource/deal",r)).data,a=jn(i);return a||rn(i?.message||"fav deal api fail"),a}const gu={getVideoFavState:o3e,addFav:i3e,removeFavs:n3e,moveFavs:r3e,modifyFav:s3e};async function n3e(e,t){const n=new URLSearchParams({resources:[t].flat().join(","),media_id:e.toString(),platform:"web",csrf:oc()}),o=(await Qt.post("/x/v3/fav/resource/batch-del",n)).data,i=jn(o);return i||rn(o.message||Up),i}async function r3e(e,t,n){const r=new URLSearchParams({resources:[e].flat().join(","),src_media_id:t.toString(),tar_media_id:n.toString(),mid:Jo(),platform:"web",csrf:oc()}),i=(await Qt.post("/x/v3/fav/resource/move",r)).data,a=jn(i);return a||rn(i?.message||"fav deal api fail"),a}async function o3e(e){if(!A1())return;const r=(await Qt.get("/x/v3/fav/folder/created/list-all",{params:{up_mid:Jo(),type:2,rid:e}})).data.data.list.filter(l=>l.fav_state>0),o=r.map(l=>l.title),i=r.map(l=>OA(l.id)),a=r.map(l=>l.id);return {favFolders:r,favFolderNames:o,favFolderUrls:i,favFolderIds:a}}let h$,K3;async function i3e(e,t){if(!t&&(!h$||!K3)){await u6();const{folders:n}=pn,r=n.find(o=>DA(o.attr))??n[0];if(!r)return rn("没有找到默认收藏夹!");h$=r.id,K3=r.title;}return t||=h$,t?await YW({avid:e,add_media_ids:t.toString()}):rn("没有找到默认收藏夹!")}async function a3e(){return (await Qt.get("/x/v3/fav/folder/created/list-all",{params:{up_mid:Jo()}})).data.data.list}async function s3e(e,t,n){const r=(t??[]).filter(u=>u!==void 0),o=[n].filter(u=>u!==void 0),i=g0(r,o),a=g0(o,r);return await YW({avid:e,del_media_ids:i.length?i.join(","):void 0,add_media_ids:a.length?a.join(","):void 0})}async function l3e(e){const n=(await Qt.get("/x/v3/fav/folder/info",{params:{media_id:e,web_location:"0.0"}})).data;if(!jn(n))throw new Txe(n);return n.data}async function c3e(e,t){const n=await l3e(e);if(!n)return;const r=new URLSearchParams({media_id:e.toString(),title:t,intro:n.intro,cover:n.cover,privacy:q1(n.attr)?"1":"0",csrf:oc()}),i=(await Qt.post("/x/v3/fav/folder/edit",r)).data,a=jn(i);if(!a){const l=i.message||"编辑收藏夹失败";rn(l);}return a}async function u3e(e){return (await Qt.get("/x/v3/fav/folder/collected/list",{params:{up_mid:Jo(),platform:"web",ps:20,pn:e}})).data.data}async function d3e(){let e=1,t=true,n=[];for(;t;){const r=await u3e(e);n.push(...r.list),t=r.has_more,e++;}return n=n.filter(r=>!(r.title==="该合集已失效"&&r.upper.mid===0)),n=Kl(n,r=>r.id),n}async function f3e(e,t){return (await Qt.get("/x/space/fav/season/list",{params:{season_id:e,ps:20,pn:t}})).data.data}var Dt=(e=>(e.Initial="initial",e.Shuffle="shuffle",e.PubTimeDesc="pub-time-desc",e.PubTimeAsc="pub-time-asc",e.PlayCountDesc="play-count-desc",e.CollectCountDesc="collect-count-desc",e.FavTimeDesc="fav-time-desc",e.FavTimeAsc="fav-time-asc",e))(Dt||{});function Y3(e,t){return t==="initial"?e:t==="shuffle"?Si(e):t==="pub-time-desc"||t==="pub-time-asc"?xs(e,[r=>r.pubtime],[t==="pub-time-desc"?"desc":"asc"]):(t==="fav-time-desc"||t==="fav-time-asc")&&e.every(n=>n.from==="fav-folder")?xs(e,[r=>r.fav_time],[t==="fav-time-desc"?"desc":"asc"]):t==="play-count-desc"?xs(e,[n=>n.cnt_info.play],["desc"]):t==="collect-count-desc"?xs(e,[n=>n.cnt_info.collect],["desc"]):e}var Ye=(e=>(e.Separator="separator",e.AppRecommend="app-recommend",e.PcRecommend="pc-recommend",e.DynamicFeed="dynamic-feed",e.Watchlater="watchlater",e.Fav="fav",e.PopularGeneral="popular-general",e.PopularWeekly="popular-weekly",e.Rank="ranking",e.Live="live",e.SpaceUpload="space-upload",e.Liked="liked",e))(Ye||{});function Sf(e){return e.api===Ye.AppRecommend}function K1(e){return e.api===Ye.PcRecommend}function Vd(e){return e.api===Ye.DynamicFeed}function XW(e){return e.api===Ye.Watchlater}function vu(e){return e.api===Ye.Fav}function QW(e){return e.api===Ye.Rank}function Ip(e){return e.api===Ye.Live}function X3(e){return e.api===Ye.SpaceUpload}function Jf(e){const t=a5.createInstance({driver:a5.INDEXEDDB,name:io,storeName:e});return {db:t,get(n){return t.getItem(n.toString())},set(n,r){return t.setItem(n.toString(),r)},delete(n){return t.removeItem(n.toString())}}}function Ru({fn:e,generateKey:t,tableName:n,ttl:r,concurrency:o,autoCleanUp:i=true}){const a=typeof n=="string"?Jf(n):n,l=Yl(()=>{a.db.iterate((g,b)=>{u(g)||a.db.removeItem(b);});},1e3);i&&I1().then(l);function u(g){return !!(g&&g.val&&g.ts&&Date.now()-g.ts<=r)}async function d(...g){const b=t(...g),y=await a.get(b);if(y&&u(y))return y.val}const m=o&&o>0?_H(e,o):e,p=aA(m,{cacheKey(g){return t(...g)},cache:{async has(g){const b=await a.get(g);return u(b)},async get(g){const b=await a.get(g);if(b&&u(b))return b.val},async set(g,b){Ha(b)||await a.set(g,{val:b,ts:Date.now()});},async delete(g){await a.delete(g);}}});return Object.defineProperties(p,{cache:{value:a},cleanUp:{value:l},generateKey:{value:t},shouldReuseCached:{value:u},queryCache:{value:d}}),p}async function m3e(e){return (await Qt.get("/x/web-interface/view",{params:{bvid:e}})).data.data}const ZW=Ru({fn:m3e,generateKey:e=>e,tableName:"video-detail",ttl:lo("3M"),concurrency:3});async function h3e(e){return (await Qt.get("/x/player/pagelist",{params:{bvid:e}})).data?.data||[]}const JW=Ru({fn:h3e,generateKey:e=>e,tableName:"video-page-list",ttl:lo("3M"),concurrency:3});async function eG(e,t){const n=Jo(),r=oc(),o=new URLSearchParams({fid:e,act:String(t),re_src:"11",gaia_source:"web_main",spmid:"333.999.0.0",extend_content:JSON.stringify({entity:"user",entity_id:n,fp:p3e()}),csrf:r}),a=(await Qt.post("/x/relation/modify",o)).data,l=jn(a);return l||rn(a.message||"未知错误"),l}function p3e(){let e,t;const n=((e=window.reportObserver)===null||e===void 0||(t=e.cache)===null||t===void 0?void 0:t.fpriskMsg)||{};let r="empty";return n&&(r=`${n.webdriver}${n.screenResolution}${n.platform}${n.hardwareConcurrency}${n.deviceMemory}${n.colorDepth}${n.indexedDb}${n.language}${n.openDatabase}${n.touchSupport}${n.userAgent}`),decodeURIComponent(r)}const g3e=ao.extend("service:user:relations:blacklist"),v3e=nG("follow"),b3e=nG("remove"),tG={add:v3e,remove:b3e},{set:Gh,replaceAllWith:y3e}=await( zH("blacklist-mids"));function S3e(e){const t=bt(Gh);return !!e&&t.has(e)}function nG(e){const t=e==="follow"?5:6;return async function(r){const o=await eG(r,t);if(o){const i=Gh;e==="follow"?i.add(r):e==="remove"&&i.delete(r);}return o}}async function C3e(){const t=async a=>{const u=(await Qt.get("/x/relation/blacks",{params:{re_version:0,ps:20,pn:a}})).data;if(!jn(u))return;const d=u.data.total,m=u.data.list.map(p=>p.mid);return {total:d,mids:m}},n=await t(1);if(!n)return;const{total:r,mids:o=[]}=n;let i=o;if(r){const a=Math.ceil(r/20);for(let l=2;l<=a;l++){const{mids:u=[]}=await t(l)||{};i=i.concat(u);}}return i}(async()=>{if(!_s)return;await I1();const e=await C3e();g3e("user blocklist fetched: %o",e),e&&y3e(e.map(t=>t.toString()));})();var mi;(e=>{(t=>{t.Av="DYNAMIC_TYPE_AV",t.Draw="DYNAMIC_TYPE_DRAW",t.PgcUnion="DYNAMIC_TYPE_PGC_UNION",t.UgcSeason="DYNAMIC_TYPE_UGC_SEASON",t.Forward="DYNAMIC_TYPE_FORWARD",t.Article="DYNAMIC_TYPE_ARTICLE",t.LiveRcmd="DYNAMIC_TYPE_LIVE_RCMD";})(e.ItemType||(e.ItemType={})),(t=>{t.Normal="AUTHOR_TYPE_NORMAL",t.Pgc="AUTHOR_TYPE_PGC",t.UgcSeason="AUTHOR_TYPE_UGC_SEASON";})(e.AuthorType||(e.AuthorType={})),(t=>{t.Archive="MAJOR_TYPE_ARCHIVE",t.Opus="MAJOR_TYPE_OPUS",t.Pgc="MAJOR_TYPE_PGC",t.UgcSeason="MAJOR_TYPE_UGC_SEASON",t.LiveRcmd="MAJOR_TYPE_LIVE_RCMD";})(e.MajorType||(e.MajorType={})),(t=>{t.Goods="ADDITIONAL_TYPE_GOODS",t.Reserve="ADDITIONAL_TYPE_RESERVE";})(e.AdditionalType||(e.AdditionalType={}));})(mi||(mi={}));function dh(e){const t=e.modules.module_dynamic.major;if(t?.type==="MAJOR_TYPE_ARCHIVE")return t.archive}async function x3e({appKey:e,nscode:t,versionId:n}){const r={appKey:e,nscode:t,versionId:n};return (await Qt.get("/x/kv-frontend/namespace/data",{params:r})).data}function rG({appKey:e,nscode:t}){return new URLSearchParams([["appKey",e],["nscode",t.toString()]]).toString()}const B9=Jf("kv-latest-version"),w3e=Hs(async({appKey:e,nscode:t})=>{const n=rG({appKey:e,nscode:t}),r=await B9.get(n);let o="0";r&&r.versionId&&r.data&&Object.keys(r.data).length&&(o=r.versionId);const i=await x3e({appKey:e,nscode:t,versionId:o});return r?.data&&i.code===-304&&i.message==="Not Modified"?r.data:(await B9.set(n,i.data),i.data.data)}),$3e=Ru({fn:w3e,tableName:"get-kv-data",generateKey:({appKey:e,nscode:t})=>rG({appKey:e,nscode:t}),ttl:lo("1h")});function E3e(e={},t){t.endsWith(".")||(t+=".");const n={};return e&&Object.keys(e).filter(r=>r.startsWith(t)).forEach(r=>{const o=r.slice(t.length),i=e[r]||"";n[o]=i;}),n}const L9=[{tid:0,name:"全部",slug:"all",season_type:0,type:"all"},{tid:0,name:"番剧",slug:"anime",season_type:1,type:"anime"},{tid:0,name:"国创",slug:"guochuang",season_type:4,type:"guochuang"},{tid:0,name:"纪录片",slug:"documentary",season_type:3,type:"documentary"},{tid:0,name:"电影",slug:"movie",season_type:2,type:"movie"},{tid:0,name:"电视剧",slug:"tv",season_type:5,type:"tv"},{tid:0,name:"综艺",slug:"variety",season_type:7,type:"variety"},{tid:1005,name:"动画",slug:"douga",season_type:0,type:"douga"},{tid:1008,name:"游戏",slug:"game",season_type:0,type:"game"},{tid:1007,name:"鬼畜",slug:"kichiku",season_type:0,type:"kichiku"},{tid:1003,name:"音乐",slug:"music",season_type:0,type:"music"},{tid:1004,name:"舞蹈",slug:"dance",season_type:0,type:"dance"},{tid:1001,name:"影视",slug:"cinephile",season_type:0,type:"cinephile"},{tid:1002,name:"娱乐",slug:"ent",season_type:0,type:"ent"},{tid:1010,name:"知识",slug:"knowledge",season_type:0,type:"knowledge"},{tid:1012,name:"科技数码",slug:"tech",season_type:0,type:"tech"},{tid:1020,name:"美食",slug:"food",season_type:0,type:"food"},{tid:1013,name:"汽车",slug:"car",season_type:0,type:"car"},{tid:1014,name:"时尚美妆",slug:"fashion",season_type:0,type:"fashion"},{tid:1018,name:"体育运动",slug:"sports",season_type:0,type:"sports"},{tid:1024,name:"动物",slug:"animal",season_type:0,type:"animal"}],_A={name:"全站",tid:0,slug:"all"};async function M3e(){try{return await R3e()||L9}catch(e){return rZ("parseRankTabsConfig failed",e),L9}}async function R3e(){const e=await $3e({appKey:"333.1339",nscode:10}),t=E3e(e,"channel_list"),n=JSON.parse(t.popular_page_sort||"");if(!n.length)return;const r=[],o=i=>{r.push({tid:i.tid||0,name:i.name,slug:i.route,season_type:i.seasonType||0,type:i.route});};for(const i of n){if(!t[i])continue;const a=JSON.parse(t[i]);o(a);}return Kl(r,i=>i.slug)}var d0=(e=>(e.Normal="normal",e.PgcSeason="pgc/season",e.PgcWeb="pgc/web",e))(d0||{});function oG(e){if(!["anime","guochuang","documentary","movie","tv","variety"].includes(e.type||""))return {apiType:"normal",url:`/x/web-interface/ranking/v2?rid=${e.tid}&type=all`};const{season_type:t}=e,n=`?day=3&season_type=${t}`;let r=`/pgc/web/rank/list${n}`,o="pgc/web";return t&&[2,3,4,5,7].includes(t)&&(r=`/pgc/season/rank/web/list${n}`,o="pgc/season"),{apiType:o,url:r}}function BA(e){return e.from==="normal"}function T3e(e){return e.from==="pgc/season"}function A3e(e){return e.from==="pgc/web"}const iG=23442827791579n,N3e=2251799813685247n,P3e=1n<<51n,Q3=58n,aG="FcwAPNKTMug3GV5Lj7EJnHpWsx4tb8haYeviqBz6rkCy12mUSDQX9RdoZf";function LA(e){const t=["B","V","1","0","0","0","0","0","0","0","0","0"];let n=t.length-1,r=(P3e|BigInt(e))^iG;for(;r>0;)t[n]=aG[Number(r%BigInt(Q3))],r=r/Q3,n-=1;return [t[3],t[9]]=[t[9],t[3]],[t[4],t[7]]=[t[7],t[4]],t.join("")}function I3e(e){const t=Array.from(e);[t[3],t[9]]=[t[9],t[3]],[t[4],t[7]]=[t[7],t[4]],t.splice(0,3);const n=t.reduce((r,o)=>r*Q3+BigInt(aG.indexOf(o)),0n);return Number(n&N3e^iG)}const O3e=cg(e=>F("svg",{viewBox:"0 0 24 24",fill:"currentColor",...e,children:[x("path",{d:"M12 4.99805C9.48178 4.99805 7.283 5.12616 5.73089 5.25202C4.65221 5.33949 3.81611 6.16352 3.72 7.23254C3.60607 8.4998 3.5 10.171 3.5 11.998C3.5 13.8251 3.60607 15.4963 3.72 16.76355C3.81611 17.83255 4.65221 18.6566 5.73089 18.7441C7.283 18.8699 9.48178 18.998 12 18.998C14.5185 18.998 16.7174 18.8699 18.2696 18.74405C19.3481 18.65655 20.184 17.8328 20.2801 16.76405C20.394 15.4973 20.5 13.82645 20.5 11.998C20.5 10.16965 20.394 8.49877 20.2801 7.23205C20.184 6.1633 19.3481 5.33952 18.2696 5.25205C16.7174 5.12618 14.5185 4.99805 12 4.99805zM5.60965 3.75693C7.19232 3.62859 9.43258 3.49805 12 3.49805C14.5677 3.49805 16.8081 3.62861 18.3908 3.75696C20.1881 3.90272 21.6118 5.29278 21.7741 7.09773C21.8909 8.3969 22 10.11405 22 11.998C22 13.88205 21.8909 15.5992 21.7741 16.8984C21.6118 18.7033 20.1881 20.09335 18.3908 20.23915C16.8081 20.3675 14.5677 20.498 12 20.498C9.43258 20.498 7.19232 20.3675 5.60965 20.2392C3.81206 20.0934 2.38831 18.70295 2.22603 16.8979C2.10918 15.5982 2 13.8808 2 11.998C2 10.1153 2.10918 8.39787 2.22603 7.09823C2.38831 5.29312 3.81206 3.90269 5.60965 3.75693z",fill:"currentColor"}),x("path",{d:"M14.7138 10.96875C15.50765 11.4271 15.50765 12.573 14.71375 13.0313L11.5362 14.8659C10.74235 15.3242 9.75 14.7513 9.75001 13.8346L9.75001 10.1655C9.75001 9.24881 10.74235 8.67587 11.5362 9.13422L14.7138 10.96875z",fill:"currentColor"})]})),D3e=cg(e=>F("svg",{viewBox:"0 0 24 24",fill:"currentColor",...e,children:[x("path",{d:"M12 4.99805C9.48178 4.99805 7.283 5.12616 5.73089 5.25202C4.65221 5.33949 3.81611 6.16352 3.72 7.23254C3.60607 8.4998 3.5 10.171 3.5 11.998C3.5 13.8251 3.60607 15.4963 3.72 16.76355C3.81611 17.83255 4.65221 18.6566 5.73089 18.7441C7.283 18.8699 9.48178 18.998 12 18.998C14.5185 18.998 16.7174 18.8699 18.2696 18.74405C19.3481 18.65655 20.184 17.8328 20.2801 16.76405C20.394 15.4973 20.5 13.82645 20.5 11.998C20.5 10.16965 20.394 8.49877 20.2801 7.23205C20.184 6.1633 19.3481 5.33952 18.2696 5.25205C16.7174 5.12618 14.5185 4.99805 12 4.99805zM5.60965 3.75693C7.19232 3.62859 9.43258 3.49805 12 3.49805C14.5677 3.49805 16.8081 3.62861 18.3908 3.75696C20.1881 3.90272 21.6118 5.29278 21.7741 7.09773C21.8909 8.3969 22 10.11405 22 11.998C22 13.88205 21.8909 15.5992 21.7741 16.8984C21.6118 18.7033 20.1881 20.09335 18.3908 20.23915C16.8081 20.3675 14.5677 20.498 12 20.498C9.43258 20.498 7.19232 20.3675 5.60965 20.2392C3.81206 20.0934 2.38831 18.70295 2.22603 16.8979C2.10918 15.5982 2 13.8808 2 11.998C2 10.1153 2.10918 8.39787 2.22603 7.09823C2.38831 5.29312 3.81206 3.90269 5.60965 3.75693z",fill:"currentColor"}),x("path",{d:"M15.875 10.75L9.875 10.75C9.46079 10.75 9.125 10.4142 9.125 10C9.125 9.58579 9.46079 9.25 9.875 9.25L15.875 9.25C16.2892 9.25 16.625 9.58579 16.625 10C16.625 10.4142 16.2892 10.75 15.875 10.75z",fill:"currentColor"}),x("path",{d:"M17.375 14.75L11.375 14.75C10.9608 14.75 10.625 14.4142 10.625 14C10.625 13.5858 10.9608 13.25 11.375 13.25L17.375 13.25C17.7892 13.25 18.125 13.5858 18.125 14C18.125 14.4142 17.7892 14.75 17.375 14.75z",fill:"currentColor"}),x("path",{d:"M7.875 10C7.875 10.4142 7.53921 10.75 7.125 10.75L6.625 10.75C6.21079 10.75 5.875 10.4142 5.875 10C5.875 9.58579 6.21079 9.25 6.625 9.25L7.125 9.25C7.53921 9.25 7.875 9.58579 7.875 10z",fill:"currentColor"}),x("path",{d:"M9.375 14C9.375 14.4142 9.03921 14.75 8.625 14.75L8.125 14.75C7.71079 14.75 7.375 14.4142 7.375 14C7.375 13.5858 7.71079 13.25 8.125 13.25L8.625 13.25C9.03921 13.25 9.375 13.5858 9.375 14z",fill:"currentColor"})]})),_3e=cg(function(e){return F("svg",{viewBox:"0 0 16 16",fill:"currentColor",...e,children:[x("path",{d:"M8.624933333333333 13.666666666666666C8.624933333333333 14.011849999999999 8.345125 14.291666666666666 7.999933333333333 14.291666666666666C4.525166666666666 14.291666666666666 1.7082933333333332 11.474791666666665 1.7082933333333332 8C1.7082933333333332 6.013308333333333 2.629825 4.2414233333333335 4.066321666666667 3.089385C4.335603333333333 2.8734283333333335 4.728959999999999 2.9166533333333335 4.944915 3.1859349999999997C5.160871666666666 3.4552099999999997 5.1176466666666665 3.848573333333333 4.848366666666666 4.0645283333333335C3.694975 4.98953 2.9582933333333328 6.40852 2.9582933333333328 8C2.9582933333333328 10.784416666666667 5.215528333333333 13.041666666666666 7.999933333333333 13.041666666666666C8.345125 13.041666666666666 8.624933333333333 13.321483333333333 8.624933333333333 13.666666666666666zM11.060475 12.810558333333333C10.844225000000002 12.541558333333331 10.887033333333335 12.148125 11.156041666666667 11.931875C12.306858333333333 11.006775 13.041599999999999 9.589424999999999 13.041599999999999 8C13.041599999999999 5.215561666666666 10.784408333333332 2.958333333333333 7.999933333333333 2.958333333333333C7.6548083333333325 2.958333333333333 7.374933333333333 2.6785083333333333 7.374933333333333 2.333333333333333C7.374933333333333 1.9881533333333332 7.6548083333333325 1.7083333333333333 7.999933333333333 1.7083333333333333C11.474725000000001 1.7083333333333333 14.291599999999999 4.525206666666667 14.291599999999999 8C14.291599999999999 9.984108333333333 13.372483333333332 11.753958333333332 11.939225 12.906125C11.670166666666663 13.122375 11.276725 13.079625 11.060475 12.810558333333333z",fill:"currentColor"}),x("path",{d:"M1.375 3.4130866666666666C1.375 3.0679066666666666 1.654825 2.7880866666666666 2 2.7880866666666666L4.333333333333333 2.7880866666666666C4.862608333333333 2.7880866666666666 5.291666666666666 3.2171449999999995 5.291666666666666 3.7464199999999996L5.291666666666666 6.079753333333334C5.291666666666666 6.424928333333334 5.011841666666666 6.704736666666666 4.666666666666666 6.704736666666666C4.321491666666667 6.704736666666666 4.041666666666666 6.424928333333334 4.041666666666666 6.079753333333334L4.041666666666666 4.038086666666667L2 4.038086666666667C1.654825 4.038086666666667 1.375 3.7582616666666664 1.375 3.4130866666666666z",fill:"currentColor"}),x("path",{d:"M14.625 12.5864C14.625 12.931591666666666 14.345183333333333 13.2114 14 13.2114L11.666666666666666 13.2114C11.137408333333335 13.2114 10.708333333333332 12.782383333333332 10.708333333333332 12.253066666666665L10.708333333333332 9.919733333333333C10.708333333333332 9.574608333333334 10.98815 9.294733333333333 11.333333333333332 9.294733333333333C11.678516666666667 9.294733333333333 11.958333333333332 9.574608333333334 11.958333333333332 9.919733333333333L11.958333333333332 11.9614L14 11.9614C14.345183333333333 11.9614 14.625 12.241275000000002 14.625 12.5864z",fill:"currentColor"})]})});function $y(e){if(!e)return 0;const t=[1,60,360];return e.split(":").map(Number).reverse().reduce((o,i,a)=>o+i*t[a],0)}function Ws(e){return e||=0,Yn.duration(e||0,"seconds").format(e>=3600?"HH:mm:ss":"mm:ss")}function B3e(e){if(!e)return typeof e=="number"?"0":e;if(e<=9999)return e.toString();const t=n=>n.replace(/\.0$/,"");if(e/=1e4,e<=9999)return `${t(e.toFixed(1))}万`;if(e/=1e4,e<=9999)return `${t(e.toFixed(1))}亿`;console.warn(`formatCount(count = ${e}); can not handle input`);}function Gc(e){if(e){if(e==="-")return 0;if(/^\d+$/.test(e))return Number(e);if(/^\d+(?:\.\d+)?万$/.test(e))return Number(e.slice(0,-1))*1e4;if(/^\d+(?:\.\d+)?亿$/.test(e))return Number(e.slice(0,-1))*1e8}}const L3e=Yn().format("YYYY");function f0(e,t=false){if(!e)return "";const n=Yn.unix(e),r=t?" HH:mm":"";return n.format("YYYY")===L3e?n.format(`M-D${r}`):n.format(`YY-M-D${r}`)}function z3e(e){const t=Yn().subtract(1,"day").startOf("day").unix();return e>=t}function k3e(e,t){if(!e)return;const n=Yn.unix(e),r=n.format("YYYY-MM-DD")===Yn().format("YYYY-MM-DD"),o=r&&Date.now()-e*1e3<=lo("12h"),i=n.format("YYYY-MM-DD")===Yn().subtract(1,"day").format("YYYY-MM-DD"),a=n.format("YYYY")===Yn().format("YYYY");if(o){const l=Yn().diff(n,"minutes"),u=Yn().diff(n,"hours");return l<1?"刚刚":l<60?`${l}分钟前`:`${u}小时前`}return r?n.format("今天 HH:mm"):i?n.format("昨天 HH:mm"):a?n.format("M月D日"):n.format("YYYY年M月D日")}const F3e={1:"橙色通过",0:"开放浏览","-1":"待审","-2":"被打回","-3":"网警锁定","-4":"被锁定","-5":"管理员锁定","-6":"修复待审","-7":"暂缓审核","-8":"补档待审","-9":"等待转码","-10":"延迟审核","-11":"视频源待修","-12":"转储失败","-13":"允许评论待审","-14":"临时回收站","-15":"分发中","-16":"转码失败","-20":"创建未提交","-30":"创建已提交","-40":"定时发布","-100":"用户删除"};function H3e(e){if(e!==void 0&&!(e>=0))return F3e[e]}const V3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M27.6 18.6v-7.2A5.4 5.4 0 0 0 22.2 6L15 22.2V42h20.916a3.6 3.6 0 0 0 3.6-3.06L42 22.74a3.6 3.6 0 0 0-3.6-4.14zM15 22h-4.806C8.085 21.963 6.283 23.71 6 25.8v12.6a4.16 4.16 0 0 0 4.194 3.6H15z"})]}),j3e=f.forwardRef(V3e),U3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M6.979 3.074a6 6 0 0 1 4.988 1.425l.037.033l.034-.03a6 6 0 0 1 4.733-1.44l.246.036a6 6 0 0 1 3.364 10.008l-.18.185l-.048.041l-7.45 7.379a1 1 0 0 1-1.313.082l-.094-.082l-7.493-7.422A6 6 0 0 1 6.979 3.074"})]}),W3e=f.forwardRef(U3e),G3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"M3 12a9 9 0 1 0 18 0a9 9 0 1 0-18 0m6 0h6m-6 3h6M9 8l3 4.5"}),x("path",{d:"m15 8l-3 4.5V17"})]})]}),q3e=f.forwardRef(G3e),K3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M24 36c11.046 0 20-12 20-12s-8.954-12-20-12S4 24 4 24s8.954 12 20 12Z"}),x("path",{d:"M24 29a5 5 0 1 0 0-10a5 5 0 0 0 0 10Z"})]})]}),Y3e=f.forwardRef(K3e),X3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"m3 20l1.3-3.9C1.976 12.663 2.874 8.228 6.4 5.726c3.526-2.501 8.59-2.296 11.845.48c3.255 2.777 3.695 7.266 1.029 10.501S11.659 20.922 7.7 19z"})]}),Q3e=f.forwardRef(X3e),Z3e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"m15 14l4-4l-4-4"}),x("path",{d:"M19 10H8a4 4 0 1 0 0 8h1"})]})]}),J3e=f.forwardRef(Z3e);const z9="size-18px",Pc="size-16px",eMe={play:x(O3e,{className:z9}),danmaku:x(D3e,{className:z9}),like:x(j3e,{className:Pc}),"bangumi:follow":x(W3e,{className:Pc}),favorite:x(pf,{className:Pc}),coin:x(q3e,{className:Pc}),"live:viewed-by":x(Y3e,{className:Pc}),"dynamic-feed:comment":x(Q3e,{className:Pc}),"dynamic-feed:forward":x(J3e,{className:Pc})},tMe=f.memo(function({field:e,value:t}){const n=f.useMemo(()=>typeof t=="number"||t&&/^\d+$/.test(t)?B3e(Number(t))??h_:t??h_,[t]),r=eMe[e];return F("span",{"data-field":e,className:"bili-video-card__stats--item gap-x-2px mr-0!",children:[r,x("span",{className:X("bili-video-card__stats--text line-height-18px"),children:n})]})});var ws=(e=>(e.AV="av",e.Ad="ad",e.Live="live",e))(ws||{});const nMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M7.5.875A3.626 3.626 0 0 1 11.127 4.5A3.624 3.624 0 0 1 8.5 7.983c1.197.145 2.224.568 2.997 1.33c.981.967 1.478 2.408 1.478 4.288a.475.475 0 0 1-.949 0c0-1.72-.453-2.88-1.196-3.613c-.745-.733-1.856-1.113-3.33-1.113c-1.472 0-2.584.38-3.328 1.113s-1.197 1.893-1.197 3.613a.475.475 0 0 1-.949 0c0-1.88.497-3.32 1.479-4.289c.772-.76 1.799-1.183 2.995-1.328a3.627 3.627 0 0 1 1-7.109m0 .95a2.676 2.676 0 1 0 0 5.35a2.676 2.676 0 0 0 0-5.35"})]}),sG=f.forwardRef(nMe),rMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M17 19.5c0-1.657-2.239-3-5-3s-5 1.343-5 3m14-3c0-1.23-1.234-2.287-3-2.75M3 16.5c0-1.23 1.234-2.287 3-2.75m12-4.014a3 3 0 1 0-4-4.472M6 9.736a3 3 0 0 1 4-4.472m2 8.236a3 3 0 1 1 0-6a3 3 0 0 1 0 6"})]}),oMe=f.forwardRef(rMe),iMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 5v14m-7-7h14"})]}),aMe=f.forwardRef(iMe),lG=sG,cG=oMe,Op=aMe;function uG(e){return `https://space.bilibili.com/${Jo()}/fans/follow?tagid=${e}`}function Tg(e){return `https://space.bilibili.com/${e}`}const dG=oU("w_webid"),fG=Hs(async()=>{const e=await dG.get();return e||sMe()});async function sMe(){const e=Jo();if(!e)return;const t=Tg(e),r=(await Qt.get(t,{responseType:"text",withCredentials:true})).data,i=new DOMParser().parseFromString(r,"text/html"),a=decodeURIComponent(i.getElementById("__RENDER_DATA__")?.textContent?.trim()||"");if(!a)return;const l=JSON.parse(a)?.access_id;return l&&await dG.set(l),l}async function mG({removeEmpty:e=true}={}){const t=await T1({web_location:"0.0",w_webid:await fG()||""}),o=(await Qt.get("/x/relation/tags",{params:t})).data.data||[];return e?o.filter(i=>!!i.count):o}async function Z3(e){const n=async l=>(await Qt.get("/x/relation/tag",{params:{mid:Jo(),tagid:e,pn:l,ps:20}})).data.data||[];let r=1,o=[],i=[];do i=await n(r),o=o.concat(i),r++;while(i.length===20);return ky(o.map(l=>l.mid))}async function lMe(){return (await Qt.get("/x/polymer/web-dynamic/v1/portal")).data?.data?.up_list||[]}var pi=(e=>(e.Mid="dyn-mid",e.GroupId="dyn-group-id",e.FilterTextFull="dyn-filter-text",e.FilterTextShort="dyn-filter",e.Offset="dyn-offset",e.MinId="dyn-min-id",e.MinTs="dyn-min-ts",e))(pi||{});const Is=new URLSearchParams(location.search),Os=Is.get("dyn-mid")?.trim(),J3=Is.get("dyn-group-id")?.trim()?Number(Is.get("dyn-group-id").trim()):void 0,cMe=Is.get("dyn-offset")||void 0,hG=Os&&(Is.get("dyn-filter-text")||Is.get("dyn-filter"))||void 0,eM=Os?Is.get("dyn-min-id"):void 0,k9=eM?Is.get("dyn-min-ts"):void 0,zA=_s&&(!!Os||J3!==void 0);let tM,pG,gG;zA&&(Os?(tM=Os,pG=Is.get("dyn-name")??tM?.toString()??void 0):J3!==void 0&&(gG=J3));var Ba=(e=>(e.All="all",e.UploadOnly="upload-only",e.DynamicOnly="dynamic-only",e))(Ba||{}),da=(e=>(e.Upload="投稿视频",e.Dynamic="动态视频",e.ChargeOnly="充电专属",e))(da||{});const uMe={all:"全部","upload-only":"仅投稿视频","dynamic-only":"仅动态视频"};var ou=(e=>(e.All="all",e._5m="5min",e._2m="2min",e._1m="1min",e._30s="30s",e._10s="10s",e))(ou||{});const vG={all:{label:"全部时长",duration:0},"5min":{label:"5分钟",duration:300},"2min":{label:"2分钟",duration:120},"1min":{label:"1分钟",duration:60},"30s":{label:"30秒",duration:30},"10s":{label:"10秒",duration:10}},Dp="all",Cf="up:",bu="group:",dMe=(await( zH("dynamic-feed:hide-charge-only-videos-for-keys"))).set,fMe=(await( kH("dynamic-feed:add-separators"))).map,Jt=bG();function bG(){return zn({upMid:tM,upName:pG,upFace:void 0,upList:[],upListUpdatedAt:0,groups:[],groupsUpdatedAt:0,selectedGroupId:gG,get selectedGroup(){if(typeof this.selectedGroupId=="number")return this.groups.find(e=>e.tagid===this.selectedGroupId)},dynamicFeedVideoType:"all",filterText:hG??void 0,get viewingAll(){return this.selectedKey===Dp},get viewingSomeUp(){return !!this.upMid},get viewingSomeGroup(){return typeof this.selectedGroupId=="number"},get selectedKey(){return this.upMid?`${Cf}${this.upMid}`:this.selectedGroupId!==void 0?`${bu}${this.selectedGroupId}`:Dp},hideChargeOnlyVideosForKeysSet:dMe,get hideChargeOnlyVideos(){return this.hideChargeOnlyVideosForKeysSet.has(this.selectedKey)},addSeparatorsMap:fMe,get addSeparators(){return this.addSeparatorsMap.get("global")??false},filterMinDuration:"all",get filterMinDurationValue(){return vG[this.filterMinDuration].duration},updateUpList:yG,updateGroups:SG})}zn({followGroupInfo:{}});async function yG(e=false){if(!e&&Jt.upList.length&&Jt.upListUpdatedAt&&Jt.upListUpdatedAt-Date.now()<lo("5min"))return;const n=await lMe();Jt.upList=n,Jt.upListUpdatedAt=Date.now();}async function SG(e=false){{const{followGroup:n,whenViewAll:r}=at.dynamicFeed;if(!(n.enabled||!!r.hideIds.filter(i=>i.startsWith(bu)).length))return}!e&&Jt.groups.length&&Jt.groupsUpdatedAt&&Jt.groupsUpdatedAt-Date.now()<lo("1h")||(Jt.groups=await mG({removeEmpty:true}),Jt.groupsUpdatedAt=Date.now());}function CG(){if(Jo())return Promise.all([yG(),SG()])}(async()=>_s&&(await gn(5e3),(!Jt.upList.length||!Jt.groups.length)&&(await I1(),CG())))();Os&&LH(Jt,["upName","filterText","selectedGroup","viewingSomeUp","viewingAll"],({upName:e,filterText:t,selectedGroup:n,viewingSomeUp:r,viewingAll:o})=>{let i=o?"动态":r?`「${e}」的动态`:`「${n?.name}」分组动态`;t&&(i=`🔍【${t}】 - ${i}`),mA(i);});function mMe(e){const{major:t,additional:n}=e.modules.module_dynamic;if(n?.type===mi.AdditionalType.Goods)return true;if(t?.type===mi.MajorType.Opus){const r=t.opus.title||"";if(["B站密令","大红包"].some(o=>r.includes(o)))return true}return false}function xG(e){if(mMe(e))return;const t=e.modules.module_dynamic.major;if(!t)return;const n=e.modules.module_author,r=e.modules.module_dynamic.additional,o=t.type,i={authorName:n.name,authorFace:n.face,authorMid:n.mid.toString(),followed:n.following,pubts:n.pub_ts,statItems:[{field:"like",value:e.modules.module_stat.like.count},{field:"dynamic-feed:comment",value:e.modules.module_stat.comment.count},{field:"dynamic-feed:forward",value:e.modules.module_stat.forward.count}],recommendReason:n.pub_action};if(o===mi.MajorType.Archive&&t.archive){const a=t.archive;return {...i,avid:a.aid,bvid:a.bvid,goto:"av",href:`/video/${a.bvid}/`,title:a.title,cover:a.cover,duration:$y(a.duration_text)||0,durationStr:a.duration_text,recommendReason:a.badge.text===da.Upload?a.badge.text:void 0,topMarkIcon:a.badge.text===da.Upload?void 0:a.badge.icon_url??void 0,topMarkText:a.badge.text===da.Upload?void 0:a.badge.text,statItems:[{field:"play",value:a.stat.play},{field:"danmaku",value:a.stat.danmaku}],play:Gc(a.stat.play),danmaku:Gc(a.stat.danmaku)}}if(o===mi.MajorType.Opus&&t.opus){const{opus:a}=t,l=!!a.pics?.length,u=r?.type===mi.AdditionalType.Reserve,d=u&&/直播预告/.test(r.reserve.title),m=(()=>{if(d)return "直播预告";if(u)return r.reserve.title?.split(":")[0]||"预约";if(e.type===mi.ItemType.Draw)return l?"图片":"文字动态";if(e.type===mi.ItemType.Article)return "专栏"})();return {...i,goto:"opus",href:a.jump_url,cover:a.pics?.[0]?.url,title:a.title||a.summary?.text||"",topMarkText:m}}if(o===mi.MajorType.Pgc&&t.pgc){const{pgc:a}=t;return {...i,cover:a.cover,goto:"bangumi",href:a.jump_url,title:a.title,statItems:[{field:"play",value:a.stat.play},{field:"danmaku",value:a.stat.danmaku}],topMarkText:n.label,pubts:n.pub_ts,pubdateDisplay:n.pub_time}}if(o===mi.MajorType.UgcSeason&&t.ugc_season){const{ugc_season:a}=t;return {...i,bvid:a.bvid,avid:a.aid.toString(),goto:"av",duration:$y(a.duration_text),durationStr:a.duration_text,cover:a.cover,href:`/video/${a.bvid}/`,title:a.title,statItems:[{field:"play",value:a.stat.play},{field:"danmaku",value:a.stat.danmaku}],play:Gc(a.stat.play),danmaku:Gc(a.stat.danmaku),recommendReason:n.pub_action,topMarkText:"合集",authorMid:void 0}}}var wG=function(e){return function(t,n,r){return e(t,n,r)*r}},nM=function(e,t){if(e)throw Error("Invalid sort config: "+t)},$G=function(e){var t=e||{},n=t.asc,r=t.desc,o=n?1:-1,i=n||r;nM(!i,"Expected `asc` or `desc` property"),nM(n&&r,"Ambiguous object with `asc` and `desc` config properties");var a=e.comparer&&wG(e.comparer);return {order:o,sortBy:i,comparer:a}},hMe=function(e){return function t(n,r,o,i,a,l,u){var d,m;if(typeof n=="string")d=l[n],m=u[n];else if(typeof n=="function")d=n(l),m=n(u);else {var p=$G(n);return t(p.sortBy,r,o,p.order,p.comparer||e,l,u)}var g=a(d,m,i);return (g===0||d==null&&m==null)&&r.length>o?t(r[o],r,o+1,i,a,l,u):g}};function EG(e,t,n){if(e===void 0||e===true)return function(i,a){return t(i,a,n)};if(typeof e=="string")return nM(e.includes("."),"String syntax not allowed for nested properties."),function(i,a){return t(i[e],a[e],n)};if(typeof e=="function")return function(i,a){return t(e(i),e(a),n)};if(Array.isArray(e)){var r=hMe(t);return function(i,a){return r(e[0],e,1,n,t,i,a)}}var o=$G(e);return EG(o.sortBy,o.comparer||t,o.order)}var p$=function(e,t,n,r){var o;return Array.isArray(t)?(Array.isArray(n)&&n.length<2&&(o=n,n=o[0]),t.sort(EG(n,r,e))):t};function MG(e){var t=wG(e.comparer);return function(n){var r=Array.isArray(n)&&!e.inPlaceSorting?n.slice():n;return {asc:function(o){return p$(1,r,o,t)},desc:function(o){return p$(-1,r,o,t)},by:function(o){return p$(1,r,o,t)}}}}var RG=function(e,t,n){return e==null?n:t==null?-n:typeof e!=typeof t?typeof e<typeof t?-1:1:e<t?-1:e>t?1:0},TG=MG({comparer:RG});MG({comparer:RG,inPlaceSorting:true});function rM(e,t,n){if(t.length!==n.length)throw new Error("props & orders length not match");const r=t.map((o,i)=>{const a=n[i];return a==="asc"?{asc:o}:a==="desc"?{desc:o}:{asc:o,comparer:a}});return TG(e).by(r)}function Ey(e,t){const n=t.map(({order:r,prop:o})=>r==="asc"?{asc:o}:r==="desc"?{desc:o}:{asc:o,comparer:r});return TG(e).by(n)}function kA(e){return e.replace(/([A-Z])/,"999999$1").replace(/([a-z])/,"999998$1")}function FA(e,t){return e.localeCompare(t,"zh-CN")}function F9(e,t){return Ey(e,[{prop:n=>{const r=typeof t=="function"?t(n):n[t];return kA(r)},order:FA}])}function AG(e){throw new Error(`Unexpected object: ${e}`)}function pMe(e){return e=e.replace(new RegExp("^[\\s\\p{RGI_Emoji}]+","v"),""),e=kA(e),e}function NG(e,t){const n={prop:i=>DA(i.attr)?1:0,order:"desc"},r={prop:i=>pMe(i.title),order:FA},o={prop:"media_count",order:"desc"};if(t==="default")return e;if(t==="name")return Ey(e,[n,r]);if(t==="count")return Ey(e,[n,o,r]);AG(t);}function PG(e){return x(QR,{size:"middle",options:[{label:"默认",value:"default"},{label:"名称",value:"name"},{label:"数量",value:"count"}],...e})}class Gs{qs;constructor(t){this.qs=new Y1(t);}get hasMore(){return !!this.qs.bufferQueue.length||this.hasMoreExceptQueue}restore(){this.qs.restore();}async loadMore(t){if(!this.hasMore)return;if(this.qs.bufferQueue.length)return this.qs.sliceFromQueue();const n=await this.fetchMore(t);return n?.length&&this.qs.bufferQueue.push(...n),this.qs.sliceFromQueue()}}class Y1{returnQueue=[];bufferQueue=[];get hasCache(){return !!this.returnQueue.length}ps;constructor(t=20){this.ps=t;}sliceCountFromQueue(t){if(this.bufferQueue.length){const n=this.bufferQueue.slice(0,t);return this.bufferQueue=this.bufferQueue.slice(t),this.doReturnItems(n)??[]}else return []}sliceFromQueue(t=1){return this.sliceCountFromQueue(this.ps*t)}doReturnItems(t){return this.returnQueue=[...this.returnQueue,...t??[]],t}restore(){this.bufferQueue=[...this.returnQueue,...this.bufferQueue],this.returnQueue=[];}get fetchedCount(){return this.returnQueue.length+this.bufferQueue.length}}function Tu(){const e=f.useRef(null),t=f.useCallback(()=>e.current?.closest(`.${RL}`)?.parentElement||document.body,[]);return {ref:e,getPopupContainer:t}}class gMe{constructor(t){this.anonymous=t;}hasMore=true;page=1;tabbarView=x(vMe,{});async loadMore(){if(!this.hasMore)return;const n=(await Qt.get("/x/web-interface/popular",{params:{ps:20,pn:this.page},withCredentials:!this.anonymous})).data;return jn(n)?(this.page++,this.hasMore=!n.data.no_more,(n.data.list||[]).map(o=>({...o,api:Ye.PopularGeneral,uniqId:`${Ye.PopularGeneral}:${o.bvid}`}))):(rn(n.message||Ef),void 0)}}function vMe(){const e=co();return x(Pt,{configPath:"popularGeneralUseAnonymous",tooltip:x(ze,{children:"✅ 匿名访问: 使用游客身份访问"}),label:"匿名访问",extraAction:async()=>{await gn(100),e();}})}function bMe(){const t=localStorage.getItem("bpx_player_profile");if(t)try{return JSON.parse(t)}catch{return}}function IG(){return !!bMe()?.media.autoplay}const _p={top:e=>X("absolute top-8px",e==="left"?"left-8px":"right-8px",e==="left"?TCe:ACe),topContainer:e=>X(_p.top(e),"flex items-center gap-x-5px",e==="left"?"flex-row":"flex-row-reverse"),tooltip:e=>X("pointer-events-none absolute bottom--6px translate-y-100% select-none whitespace-nowrap rounded-4px bg-gate-primary px-8px py-4px text-12px text-white line-height-18px",e==="left"?"left-0":"right-0")},ka=f.memo(function({inlinePosition:t,icon:n,tooltip:r,visible:o=true,active:i=false,className:a,useMotion:l=false,motionProps:u,ref:d,...m}){const{triggerRef:p,tooltipEl:g}=X1({inlinePosition:t,tooltip:r}),b=f.useMemo(()=>Jj("action-button","relative size-28px cursor-pointer rounded-6px bg-[rgb(33_33_33_/_0.7)] color-white","b-1px b-solid",i?"b-gate-primary":"b-#444","hover:b-gate-primary",l||o?"inline-flex":"hidden","items-center justify-center","[&_svg]:pointer-events-none [&_svg]:select-none",a),[i,a,o,l]),y=U1(p,d),S={...m,className:b,ref:y,children:F(ze,{children:[n,g]})};return l?x(P1e,{children:o&&x(XT.div,{...S,...u},"action-button")}):x("div",{...S})});function X1({inlinePosition:e,tooltip:t,tooltipClassName:n}){const r=f.useRef(null),o=k1(r),i=ur(_p.tooltip(e),n,o?"block":"hidden");return {triggerRef:r,tooltipEl:t?x("span",{className:i,children:t}):void 0}}function yMe(e,t,n=true){let r=0,o=t;return (...i)=>{if(r++,r===o)return r=0,n&&o++,e(...i)}}function OG(e,t,n=true){const r=Je(e);return f.useMemo(()=>yMe(r,t,n),[r,t,n])}const SMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M8.5 6q.049 0 .098.009q.076.017.142.054q.061.034.114.083q.05.052.082.113A.5.5 0 0 1 9 6.5v3a.5.5 0 0 1-1 0V7.707l-5.146 5.147a.5.5 0 1 1-.708-.707L7.293 7H5.5a.5.5 0 0 1 0-1zM12 2a1 1 0 0 1 1 1v9a1 1 0 0 1-1 1H8.5a.5.5 0 0 1 0-1H12V3H3v3.5a.5.5 0 0 1-1 0V3a1 1 0 0 1 1-1z"})]}),DG=f.forwardRef(SMe),CMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M10.969 3.219a.574.574 0 1 1 .812.812L8.313 7.5l3.468 3.469l.074.09a.575.575 0 0 1-.796.796l-.09-.074L7.5 8.312l-3.469 3.47a.574.574 0 1 1-.812-.813L6.688 7.5l-3.47-3.469l-.073-.09a.575.575 0 0 1 .796-.797l.09.075L7.5 6.687z"})]}),xMe=f.forwardRef(CMe),wMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M7.499 0c1.072 0 1.966.338 2.589 1.002c.619.66.912 1.58.912 2.634V6h1a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h7V3.636c0-.876-.242-1.524-.642-1.95C8.963 1.267 8.357 1 7.5 1c-.888 0-1.502.269-1.895.715l-.077.092C5.197 2.233 5 2.843 5 3.633H4c0-.95.237-1.795.737-2.44l.121-.145C5.482.342 6.4 0 7.5 0M3 13h9V7H3z"})]}),_G=f.forwardRef(wMe),$Me=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 15 15",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M7.501.978c1.074 0 1.968.345 2.59 1.014c.616.664.909 1.587.909 2.642V6h1a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h1V4.636c0-1.055.293-1.979.91-2.643c.622-.67 1.517-1.015 2.591-1.015M3 13h9V7H3zM7.501 1.978c-.855 0-1.461.27-1.857.696C5.243 3.105 5 3.76 5 4.636V6h5V4.634c0-.877-.241-1.531-.642-1.962c-.395-.426-1.001-.694-1.857-.694"})]}),EMe=f.forwardRef($Me);function MMe(e,t){const n=t.document.head;pU({key:"pip-window",container:n}),Array.from(document.querySelectorAll("style")).filter(i=>[io,"ant","rc"].some(a=>i.textContent.includes(a))).forEach(i=>{const a=t.document.createElement("style");a.textContent=i.textContent,t.document.head.appendChild(a);});const r=document.createElement("div");r.classList.add($a),r.style.lineHeight="0",t.document.body.appendChild(r),Qa.createRoot(r).render(x(Us,{cssInsertContainer:n,cssInsertContainerEmotionKey:"pip-window",children:x(Do,{getPopupContainer:()=>t.document.body,getTargetContainer:()=>t,children:F(og,{message:{getContainer:()=>t.document.body},children:[x(F1,{baseGlobalStyle:true}),x(TMe,{newHref:e,pipWindow:t})]})})}));}var RMe={name:"pb1257",styles:"*{box-sizing:border-box;}:root,body,iframe{margin:0;padding:0;overscroll-behavior:none;}"};function TMe({newHref:e,pipWindow:t}){const n=k1(t.document.documentElement),[r,o]=f.useState(()=>at.pipWindow.defaultLocked);return F(ze,{children:[x(fA,{styles:[RMe,"",""]}),x("iframe",{src:e,className:"block h-100vh w-full border-none"}),x(AMe,{locked:r,setLocked:o,pipWindow:t}),F("div",{className:X("fixed right-10px top-10px z-9999 flex-row-reverse items-center gap-x-6px",n?"flex":"hidden"),children:[x(NMe,{pipWindow:t,newHref:e}),x(PMe,{locked:r,setLocked:o})]})]})}const BG="size-30px [&_svg]:size-16px";function AMe({locked:e,setLocked:t,pipWindow:n}){const{message:r}=og.useApp(),o=OG(()=>{r.info("请先点击右上角「🔓解锁按钮」解锁");},3);return f.useMemo(()=>gi([{key:"unlock",label:"解锁",icon:x(_G,{}),onClick(){t(false);}}]),[]),e&&x("div",{className:X("locked-overlay","fixed inset-0 z-9999 select-none bg-transparent"),onClick:o})}function NMe({newHref:e,pipWindow:t}){return x(ka,{inlinePosition:"right",icon:x(DG,{}),tooltip:"新窗口打开",onClick:()=>{t.close();const r=new URL(e);r.searchParams.delete(ql.PlayerScreenMode),r.searchParams.delete(ql.ForceAutoPlay),fi(r.href);},className:BG})}function PMe({locked:e,setLocked:t}){const[n,r]=e?["锁定","解锁"]:["解锁","锁定"];return x(ka,{inlinePosition:"right",icon:e?x(EMe,{}):x(_G,{}),tooltip:`已${n}, 点击${r}`,className:BG,onClick:()=>t(o=>!o)})}const LG=ao.extend("VideoCard:useOpenRelated");function IMe({href:e,item:t,cardData:n,actionButtonVisible:r,hasOpenInPopupActionButton:o,getLargePreviewCurrentTime:i,hideLargePreview:a,shouldUseLargePreviewCurrentTime:l}){const{videoLinkOpenMode:u}=Ut();function d($){const M=new URL(e,location.href);return $?.(M),M.href}const m=Je($=>{$.stopPropagation(),$.preventDefault(),p(void 0,$);}),p=Je(($,M)=>{$||=at.videoLinkOpenMode;const T=d(P=>{if(($===sr.NormalWebFullscreen||$===sr.Popup&&at.pipWindow.autoWebFullscreen)&&(P.searchParams.set(ql.PlayerScreenMode,Tl.WebFullscreen),$===sr.Popup&&!IG()&&P.searchParams.set(ql.ForceAutoPlay,iA.ON)),l()){const O=i();O&&(a(),P.searchParams.set("t",O.toString()));}}),R=()=>{const O=!($===sr.Background||!!(M?.metaKey||M?.ctrlKey));fi(T,O);},I=()=>{location.href=T;};({[sr.Normal]:R,[sr.Background]:R,[sr.CurrentPage]:I,[sr.NormalWebFullscreen]:R,[sr.Popup]:()=>g(T),[sr.Iina]:b})[$]?.();});function g($){const{width:M,height:T}=HA({item:t});return zG($,n.bvid,M,T)}function b(){let $=e;t.api===Ye.Watchlater&&($=`/video/${t.bvid}`);const M=new URL($,location.href).href,T=`iina://open?url=${encodeURIComponent(M)}`;window.open(T,"_self");}const y=f.useMemo(()=>Object.values(sr).filter($=>di[$].enabled===void 0).map($=>({key:p_[$],label:di[$].label,icon:di[$].icon,onClick:()=>p($)})),[]),S=f.useMemo(()=>Object.values(sr).filter($=>typeof di[$].enabled=="boolean"&&di[$].enabled).length?Object.values(sr).filter($=>typeof di[$].enabled=="boolean"&&di[$].enabled).map($=>({key:p_[$],label:di[$].label,icon:di[$].icon,onClick:()=>p($)})):[],[]),C=f.useMemo(()=>{if(u!==sr.Popup&&t.api!==Ye.Live&&VA&&o)return x(ka,{visible:r,inlinePosition:"right",icon:di.Popup.icon,tooltip:di.Popup.label,onClick:$=>{$.preventDefault(),$.stopPropagation(),p(sr.Popup);}})},[u,r]),w=Je(()=>{p(sr.Popup);});return {onOpenWithMode:p,handleVideoLinkClick:m,consistentOpenMenus:y,conditionalOpenMenus:S,openInPopupActionButtonEl:C,onOpenInPopup:w}}function HA({item:e,dimensionFromApi:t}){let n,r,o;if(t)[n,r]=[t.width,t.height],t.rotate===1&&([n,r]=[r,n]),o=n/r;else if(e?.api===Ye.AppRecommend&&e.uri?.startsWith("bilibili://")){const i=new URL(e.uri).searchParams,a=Number(i.get("player_width")||0),l=Number(i.get("player_height")||0),u=Number(i.get("player_rotate")||0);a&&l&&!Number.isNaN(a)&&!Number.isNaN(l)&&([n,r]=[a,l],u===1&&([n,r]=[r,n]),o=n/r);}else if(e?.api===Ye.Rank&&BA(e)){const i=e.dimension.width,a=e.dimension.height,l=e.dimension.rotate;i&&a&&!Number.isNaN(i)&&!Number.isNaN(a)&&([n,r]=[i,a],l===1&&([n,r]=[r,n]),o=n/r);}return {width:n,height:r,aspectRatio:o}}const VA=!!window.documentPictureInPicture?.requestWindow;async function zG(e,t,n,r){let o=1e3,i=Math.ceil(o/16*9);const a=200;if((!n||!r)&&t){const u=await Promise.race([JW(t),gn(a)]);if(u?.[0]?.dimension){const{dimension:d}=u[0];n=d.width,r=d.height;}}if(n&&r&&n<r){const u=Math.min(Math.floor(window.screen.availHeight*.8),1e3),d=Math.floor(u/r*n);o=Math.min(720,d),i=Math.floor(o/n*r);}LG("openInPipOrPopup newHref=%s size=%sx%s",e,o,i);let l;if(VA)try{l=await window.documentPictureInPicture?.requestWindow({width:o,height:i,disallowReturnToOpener:!0});}catch{}l?MMe(e,l):OMe(e,o,i);}function OMe(e,t,n){const r=(window.innerWidth-t)/2,o=(window.innerHeight-n)/2-50,i=["popup=true",`width=${t}`,`height=${n}`,`left=${r}`,`top=${o}`].join(",");LG("openInPopup: features -> %s",i),window.open(e,"_blank",i);}function kG(){const{videoLinkOpenMode:e}=Ut();return e!==sr.CurrentPage}function Q1(){return kG()?"_blank":"_self"}function m0(){return at.videoLinkOpenMode!==sr.CurrentPage?"_blank":"_self"}function Bp(e){const t=Q1();return x("a",{...e,target:t,children:e.children})}let wb=[],g$="";function H9(){const e=Yn();return [e.format("YYYYMMDD"),e.hour()<18?"lt-18":"gte-18"].join("_")}async function DMe(){return wb.length&&g$&&g$===H9()||(wb=(await Qt.get("/x/web-interface/popular/series/list")).data.data.list,g$=H9()),wb}class My{constructor(t){this.useShuffle=t;}static PAGE_SIZE=20;episodesLoaded=false;episodes=[];qs=new Y1(My.PAGE_SIZE);get hasMore(){return this.episodesLoaded?!!this.qs.bufferQueue.length||!!this.episodes.length:true}async loadMore(){if(this.episodesLoaded||(this.episodes=await DMe(),this.episodesLoaded=true,this.useShuffle&&(this.episodes=Si(this.episodes))),!this.hasMore)return;if(!this.useShuffle){if(this.qs.bufferQueue.length)return this.qs.sliceFromQueue();const n=this.episodes[0],r=n.number,o=await V9(r);return this.qs.bufferQueue.push({api:Ye.Separator,uniqId:`${Ye.PopularWeekly}:separator:${r}`,content:x(Bp,{href:`https://www.bilibili.com/v/popular/weekly?num=${r}`,children:n.name})},...o),this.episodes=this.episodes.slice(1),this.qs.sliceFromQueue()}const t=5;for(;this.qs.bufferQueue.length<My.PAGE_SIZE*t&&this.episodes.length;){this.episodes=Si(this.episodes);const n=this.episodes.slice(0,t);this.episodes=this.episodes.slice(t);const r=await Wl(n.map(o=>o.number),o=>V9(o),2);this.qs.bufferQueue=Si([...this.qs.bufferQueue,...r.flat()]);}return this.qs.sliceFromQueue()}get tabbarView(){return x(_Me,{})}}const v$={};async function V9(e){if(!v$[e]?.length){const o=((await Qt.get("/x/web-interface/popular/series/one",{params:{number:e}})).data.data.list||[]).map(i=>({...i,api:Ye.PopularWeekly,uniqId:`${Ye.PopularWeekly}:${i.bvid}`}));v$[e]=o;}return v$[e]}function _Me(){const e=co();return x(ze,{children:x(pu,{configPath:"popularWeeklyUseShuffle",checkedChildren:"随机顺序: 开",unCheckedChildren:"随机顺序: 关",extraAction:async()=>{await gn(100),e();}})})}const FG="rank-store-slug",BMe=await( GM.getValue(FG))||_A.slug,xi=zn({slug:BMe,tabs:[],get currentTab(){return this.tabs.find(e=>e.slug===this.slug)||_A}}),LMe=Hs(async()=>{if(xi.tabs.length)return;const e=await M3e();xi.tabs=e;});uT(xi,"slug",()=>{GM.setValue(FG,xi.slug);});class HG{constructor(t){this.slug=t;}loaded=false;qs=new Y1(20);tabbarView=x(zMe,{});sidebarView=x(kMe,{});get hasMore(){return this.loaded?!!this.qs.bufferQueue.length:true}get rankTab(){return Fr(xi).tabs.find(t=>t.slug===this.slug)||_A}async loadMore(t){if(this.hasMore){if(!this.loaded){await LMe();const{url:n,apiType:r}=oG(this.rankTab),i=(await Qt.get(n,{signal:t})).data;if(this.loaded=true,!jn(i)){rn(i.message||Ef);return}const l=(i?.data?.list||i?.result?.list||[]).map((u,d)=>{const m=d+1;return {...u,api:Ye.Rank,uniqId:`${Ye.Rank}:${this.rankTab.slug}:rankingNo-${m}`,rankingNo:m,slug:this.rankTab.slug,rankTab:this.rankTab,from:r}});this.qs.bufferQueue=l;}return this.qs.sliceFromQueue()}}}function VG(){const{tabs:e}=bt(xi),{normalList:t,pgcList:n}=f.useMemo(()=>{const r=e.map(a=>({...a,apiType:oG(a).apiType})),o=r.filter(a=>[d0.PgcSeason,d0.PgcWeb].includes(a.apiType));return {normalList:r.filter(a=>a.apiType===d0.Normal),pgcList:o}},[e]);return {normalList:t,pgcList:n}}function zMe(){const{enableSidebar:e}=Ut(),{ref:t,getPopupContainer:n}=Tu(),r=co(),{slug:o,currentTab:i}=bt(xi),{normalList:a,pgcList:l}=VG(),u=(y,S,C)=>y.length?F("div",{className:"mt-15px max-w-350px first:mt-0",children:[F("p",{className:"mb-5px flex-v-center rounded-5px bg-gate-primary py-5px pl-6px text-white",children:[S,!!C&&x(pr,{children:C})]}),x("div",{className:"grid grid-cols-4 gap-x-10px gap-y-8px px-2px",children:y.map(w=>{const $=w.slug===o;return x(st,{className:X({"b-gate-primary":$,"color-gate-primary":$}),onClick:M=>{g(false),xi.slug=w.slug,r();},children:x("span",{children:w.name})},w.slug)})})]}):null,d=Je(y=>{const S=[...a,...l];if(!S.length)return;const C=S.findIndex(M=>M.slug===o);if(C===-1)return;const w=y.shiftKey?-1:1,$=(C+w+S.length)%S.length;xi.slug=S[$].slug,r();}),m=F(ze,{children:[u(a,"视频"),u(l,"PGC内容","不能提供预览")]}),[p,g]=f.useState(false),b=x(Zo,{arrow:false,open:p,onOpenChange:g,placement:"bottomLeft",getPopupContainer:n,content:m,styles:{container:{border:`1px solid ${qf()}`}},children:x(st,{css:[p&&Gf,"",""],onClick:d,className:"outline-none!",children:i.name})});if(!e)return x("div",{ref:t,children:b})}function kMe(){const{slug:e}=bt(xi),{normalList:t,pgcList:n}=VG(),r=co(),o=Je(a=>{xi.slug=a,r();}),i=f.useMemo(()=>{const a={type:"group",label:"视频",children:t.map(u=>({key:u.slug,label:u.name,onClick:()=>o(u.slug)}))},l={type:"group",label:"PGC内容",children:n.map(u=>({key:u.slug,label:u.name,onClick:()=>o(u.slug)}))};return [a,l]},[t,n]);return x(ec,{items:i,selectedKeys:[e],mode:"inline",inlineIndent:10})}const FMe={[hr.PopularGeneral]:()=>new gMe(at.popularGeneralUseAnonymous),[hr.PopularWeekly]:()=>new My(at.popularWeeklyUseShuffle),[hr.Rank]:()=>new HG(xi.slug)};function jG(e){const{subtab:t}=Wo;return e??=at.popularWeeklyUseShuffle,t===hr.PopularWeekly&&e}const b$=e=>x("img",{src:e,alt:"",className:"size-18px"}),y$={[hr.PopularGeneral]:{icon:b$("https://s1.hdslb.com/bfs/static/jinkela/popular/assets/icon_popular.png"),label:"综合热门",desc:"各个领域中新奇好玩的优质内容都在这里~",swr:true,anonymousUsage:true},[hr.PopularWeekly]:{icon:b$("https://s1.hdslb.com/bfs/static/jinkela/popular/assets/icon_weekly.png"),label:"每周必看",desc:"每周五晚 18:00 更新",anonymousUsage:true},[hr.Rank]:{icon:b$("https://s1.hdslb.com/bfs/static/jinkela/popular/assets/icon_rank.png"),label:"排行榜",desc:"排行榜根据稿件内容质量,近期的数据综合展示,动态更新",anonymousUsage:true,swr:true}};class HMe extends Gs{subtab;service;constructor(){super(20),this.subtab=Wo.subtab,this.service=FMe[Wo.subtab]();}get tabbarView(){return x(VMe,{children:this.service.tabbarView})}get sidebarView(){return this.service.sidebarView}get hasMoreExceptQueue(){return this.service.hasMore}fetchMore(t){return this.service.loadMore(t)}}const Wo=await( mT({subtab:hr.PopularGeneral},"hot-store"));Object.values(hr).includes(Wo.subtab)||(Wo.subtab=hr.PopularGeneral);function VMe({children:e}){const{subtab:t}=bt(Wo),{icon:n,label:r}=y$[t],o=co(),{ref:i,getPopupContainer:a}=Tu(),{__internalHotSubUseDropdown:l}=Ut(),u=f.useMemo(()=>[hr.PopularGeneral,hr.PopularWeekly,hr.Rank].map((p,g)=>{const b=y$[p],y=p===t;return [g>0&&{type:"divider"},{key:p,label:x("span",{className:X({"color-gate-primary":y}),children:b.label}),icon:b.icon,onClick(){p!==Wo.subtab&&(Wo.subtab=p,o());}}].filter(Boolean)}).flat(),[t]),d=x(tc,{menu:{items:u},getPopupContainer:a,rootClassName:'![&_[role="separator"]]:mx-0 ![&_[role="separator"]]:my-2px',children:F(st,{ref:i,className:"w-114px flex items-center justify-start gap-0 pl-16px",children:[n,x("span",{className:"ml-8px",children:r})]})}),m=f.useMemo(()=>x(Zr.Compact,{children:[hr.PopularGeneral,hr.PopularWeekly,hr.Rank].map((p,g)=>{const{icon:b,label:y,desc:S}=y$[p],C=p===t;return x(fn,{title:F(ze,{children:[y,": ",S]}),children:x(st,{className:"[&_.ant-btn-icon]:line-height-0",icon:b,variant:C?"solid":"outlined",color:C?"primary":"default",onClick:()=>{p!==Wo.subtab&&(Wo.subtab=p,o());},children:y})},p)})}),[t]);return F(ze,{children:[l?d:m,e]})}const UG=x(Ul,{className:"[&.ant-divider-horizontal.ant-divider-with-text]:my-5px [&.ant-divider-horizontal.ant-divider-with-text]:text-14px",children:"底线"});function jA(e){const{enableSidebar:t}=Ut(),{usingTwoColumnMode:n}=WW(),r=bt(Wo).subtab,{insideModal:o}=Ei();return f.useMemo(()=>!t||o&&n?false:e===nt.DynamicFeed?!Os:e===nt.Hot?r===hr.Rank:e===nt.Fav,[e,t,r,o,n])}function WG(e,t){const n=f.useRef(null),r=Je(a=>{if(a||=t,!a)return;const l=n.current?.menu?.findItem({key:a});if(l)return l.scrollIntoViewIfNeeded?l.scrollIntoViewIfNeeded():l.scrollIntoView(),true}),o=f.useRef(false),i=Je(()=>{if(o.current)return;r()&&(o.current=true);});return oo(()=>i()),Ps(()=>i(),[e]),{menuRef:n,revealSelected:r}}const Fn=zn({multiSelecting:false,selectedIdSet:Rr(),shiftMultiSelectAnchorUniqId:void 0});function jMe(){const{multiSelecting:e}=bt(Fn);return e}function UMe(e){const{multiSelecting:t,selectedIdSet:n}=bt(Fn);return t&&!!e&&n.has(e)}const Ry=[];function Ds(){return Ry.at(-1)?.items??[]}function WMe(e){const t=Ry.at(-1);t&&(t.items=e);}function GMe(){oo(()=>(Ry.push({items:[]}),()=>{Ry.pop();}));}function Z1(){const{multiSelecting:e,selectedIdSet:t}=Fn;return e?Ds().filter(n=>t.has(n.uniqId)):[]}function qMe(){return Z1().map(em)}function UA(){const{multiSelecting:e}=Fn;let t=e?Z1():Ds();return e&&!t.length&&(t=Ds()),t.map(em).toReversed()}function WA(){const t=UA().map(n=>n.bvid).join(" ");nu(t,1);}function GA(e){let{bvid:t,authorName:n,pubts:r,title:o}=e;const i=Yn.unix(r??0).format("YYYY-MM-DD");return o=o.replaceAll(/\n+/g," "),`${t} ;; [${n}] ${i} ${o}`}function qA(){const t=UA().map(GA).join(`
`);nu(t,1);}function KMe(){const t=qMe().map(n=>{let r=n.href;if(r)return r.startsWith("/")&&(r=new URL(r,location.href).href),r}).filter(Boolean).join(`
`);nu(t);}function YMe(e,t){const{multiSelecting:n,selectedIdSet:r}=Fn;if(!n||!e||!t||e===t)return;const o=Ds(),i=o.findIndex(g=>g.uniqId===e),a=o.findIndex(g=>g.uniqId===t),l=g=>g>=0&&g<=o.length-1;if(!l(i)||!l(a))return;const u=[i,a],[d,m]=rM(u,[g=>g],["asc"]),p=r.has(e);for(let g=d;g<=m;g++){const b=Ds()[g].uniqId;p?r.add(b):r.delete(b);}}const XMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 16 16",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M2 10h3a1 1 0 0 1 1 1v3a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1v-3a1 1 0 0 1 1-1m9-9h3a1 1 0 0 1 1 1v3a1 1 0 0 1-1 1h-3a1 1 0 0 1-1-1V2a1 1 0 0 1 1-1m0 9a1 1 0 0 0-1 1v3a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1zm0-10a2 2 0 0 0-2 2v3a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2zM2 9a2 2 0 0 0-2 2v3a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2v-3a2 2 0 0 0-2-2zm7 2a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2h-3a2 2 0 0 1-2-2zM0 2a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2zm5.354.854a.5.5 0 1 0-.708-.708L3 3.793l-.646-.647a.5.5 0 1 0-.708.708l1 1a.5.5 0 0 0 .708 0z"})]}),QMe=f.forwardRef(XMe),ZMe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 16 16",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M9.854 5.854a.5.5 0 0 0-.708-.708L6.5 7.793L5.354 6.646a.5.5 0 1 0-.708.708l1.5 1.5a.5.5 0 0 0 .708 0zM2 4.5A2.5 2.5 0 0 1 4.5 2h5A2.5 2.5 0 0 1 12 4.5v5A2.5 2.5 0 0 1 9.5 12h-5A2.5 2.5 0 0 1 2 9.5zM4.5 3A1.5 1.5 0 0 0 3 4.5v5A1.5 1.5 0 0 0 4.5 11h5A1.5 1.5 0 0 0 11 9.5v-5A1.5 1.5 0 0 0 9.5 3zM7 14a2.5 2.5 0 0 1-2-1h4.5A3.5 3.5 0 0 0 13 9.5V4c.607.456 1 1.182 1 2v3.5A4.5 4.5 0 0 1 9.5 14z"})]}),JMe=f.forwardRef(ZMe),eRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M6.99 11L3 15l3.99 4v-3H14v-2H6.99zM21 9l-3.99-4v3H10v2h7.01v3z"})]}),tRe=f.forwardRef(eRe),nRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 512 512",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:32,d:"M320 176v-40a40 40 0 0 0-40-40H88a40 40 0 0 0-40 40v240a40 40 0 0 0 40 40h192a40 40 0 0 0 40-40v-40m64-160l80 80l-80 80m-193-80h273"})]}),rRe=f.forwardRef(nRe);function GG({iconOnly:e,addCopyActions:t=false}){const{multiSelecting:n}=bt(Fn),r=qf(),o=Je(()=>{Fn.multiSelecting||(Fn.shiftMultiSelectAnchorUniqId=void 0,at.multiSelect.clearWhenExit&&Fn.selectedIdSet.clear());}),i=F(st,{type:n?"primary":"default",className:X(e?"icon-only-round-button":"inline-flex-center"),onClick:()=>{Fn.multiSelecting=!Fn.multiSelecting,o();},children:[x(QMe,{className:"size-12px"}),!e&&F(ze,{children:["多选",Fn.multiSelecting?"中":""]})]}),a=l=>x(Zo,{styles:{container:{border:`1px solid ${r}`}},content:F("div",{className:"max-w-288px",children:[F("div",{className:"flex items-start gap-x-6px",children:[x(Uj,{className:"mt-1 size-14px"}),F("div",{className:"flex-1 break-all",children:["使用 ",x("kbd",{className:X(fu,"mx-1"),children:"Shift"})," 键扩选: 切换选中状态后, 按住"," ",x("kbd",{className:X(fu,"mx-1"),children:"Shift"}),"键再选择区间终点, 整个区间会与起点选中状态同步."]})]}),x(Ul,{variant:"solid",className:"my-7px"}),F("div",{className:"flex flex-wrap items-center gap-x-15px gap-y-2px",children:[F(st,{className:"inline-flex items-center",onClick:()=>Fn.selectedIdSet.clear(),children:[x(Uf,{className:"size-18px"}),"清空"]}),F(st,{className:"inline-flex items-center",onClick:()=>{const u=Ds().map(d=>d.uniqId);Fn.selectedIdSet=Rr(u);},children:[x(JMe,{className:"size-18px"}),"全选"]}),F(st,{className:"inline-flex items-center",onClick:()=>{const u=Ds().filter(d=>!Fn.selectedIdSet.has(d.uniqId)).map(d=>d.uniqId);Fn.selectedIdSet=Rr(u);},children:[x(tRe,{className:"size-18px"}),"反选"]}),x("div",{className:"flex-basis-100%"}),F(st,{className:"inline-flex items-center",onClick:()=>{Fn.multiSelecting=false,o();},children:[x(rRe,{className:"size-18px"}),"退出"]}),x(Pt,{configPath:"multiSelect.clearWhenExit",label:"退出时清空",tooltip:"退出多选时, 清空所有已选择项"})]}),t&&F(ze,{children:[x(Ul,{variant:"solid",className:"my-7px"}),x("div",{className:"flex flex-wrap gap-x-10px gap-y-5px",children:x(QG,{showCopyBvidInfo:true})})]})]}),children:l});return n?a(i):e?x(fn,{title:"多选",arrow:false,children:i}):i}const oRe=Object.prototype.toString,iRe=e=>oRe.call(e)==="[object Error]",aRe=new Set(["network error","Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Network request failed","fetch failed","terminated"," A network error occurred.","Network connection lost"]);function sRe(e){if(!(e&&iRe(e)&&e.name==="TypeError"&&typeof e.message=="string"))return false;const{message:n,stack:r}=e;return n==="Load failed"?r===void 0||"__sentry_captured__"in e:n.startsWith("error sending request for url")?true:aRe.has(n)}function lRe(e){if(typeof e=="number"){if(e<0)throw new TypeError("Expected `retries` to be a non-negative number.");if(Number.isNaN(e))throw new TypeError("Expected `retries` to be a valid number or Infinity, got NaN.")}else if(e!==void 0)throw new TypeError("Expected `retries` to be a number or Infinity.")}function $b(e,t,{min:n=0,allowInfinity:r=false}={}){if(t!==void 0){if(typeof t!="number"||Number.isNaN(t))throw new TypeError(`Expected \`${e}\` to be a number${r?" or Infinity":""}.`);if(!r&&!Number.isFinite(t))throw new TypeError(`Expected \`${e}\` to be a finite number.`);if(t<n)throw new TypeError(`Expected \`${e}\` to be ≥ ${n}.`)}}class cRe extends Error{constructor(t){super(),t instanceof Error?(this.originalError=t,{message:t}=t):(this.originalError=new Error(t),this.originalError.stack=this.stack),this.name="AbortError",this.message=t;}}function uRe(e,t){const n=Math.max(1,e+1),r=t.randomize?Math.random()+1:1;let o=Math.round(r*t.minTimeout*t.factor**(n-1));return o=Math.min(o,t.maxTimeout),o}function j9(e,t){return Number.isFinite(t)?t-(performance.now()-e):t}async function dRe({error:e,attemptNumber:t,retriesConsumed:n,startTime:r,options:o}){const i=e instanceof Error?e:new TypeError(`Non-error was thrown: "${e}". You should only throw errors.`);if(i instanceof cRe)throw i.originalError;const a=Number.isFinite(o.retries)?Math.max(0,o.retries-n):o.retries,l=o.maxRetryTime??Number.POSITIVE_INFINITY,u=Object.freeze({error:i,attemptNumber:t,retriesLeft:a,retriesConsumed:n});if(await o.onFailedAttempt(u),j9(r,l)<=0)throw i;const d=await o.shouldConsumeRetry(u),m=j9(r,l);if(m<=0||a<=0)throw i;if(i instanceof TypeError&&!sRe(i)){if(d)throw i;return o.signal?.throwIfAborted(),false}if(!await o.shouldRetry(u))throw i;if(!d)return o.signal?.throwIfAborted(),false;const p=uRe(n,o),g=Math.min(p,m);return o.signal?.throwIfAborted(),g>0&&await new Promise((b,y)=>{const S=()=>{clearTimeout(C),o.signal?.removeEventListener("abort",S),y(o.signal.reason);},C=setTimeout(()=>{o.signal?.removeEventListener("abort",S),b();},g);o.unref&&C.unref?.(),o.signal?.addEventListener("abort",S,{once:true});}),o.signal?.throwIfAborted(),true}async function qG(e,t={}){if(t={...t},lRe(t.retries),Object.hasOwn(t,"forever"))throw new Error("The `forever` option is no longer supported. For many use-cases, you can set `retries: Infinity` instead.");t.retries??=10,t.factor??=2,t.minTimeout??=1e3,t.maxTimeout??=Number.POSITIVE_INFINITY,t.maxRetryTime??=Number.POSITIVE_INFINITY,t.randomize??=false,t.onFailedAttempt??=()=>{},t.shouldRetry??=()=>true,t.shouldConsumeRetry??=()=>true,$b("factor",t.factor,{min:0,allowInfinity:false}),$b("minTimeout",t.minTimeout,{min:0,allowInfinity:false}),$b("maxTimeout",t.maxTimeout,{min:0,allowInfinity:true}),$b("maxRetryTime",t.maxRetryTime,{min:0,allowInfinity:true}),t.factor>0||(t.factor=1),t.signal?.throwIfAborted();let n=0,r=0;const o=performance.now();for(;!Number.isFinite(t.retries)||r<=t.retries;){n++;try{t.signal?.throwIfAborted();const i=await e(n);return t.signal?.throwIfAborted(),i}catch(i){await dRe({error:i,attemptNumber:n,retriesConsumed:r,startTime:o,options:t})&&r++;}}throw new Error("Retry attempts exhausted without throwing an error.")}var $s=(e=>(e.Latest="pubdate",e.View="click",e.Fav="stow",e))($s||{});const fRe={pubdate:{icon:x(sCe,{}),label:"最新发布"},click:{icon:x(hg,{}),label:"最多播放"},stow:{icon:x(pf,{}),label:"最多收藏"}},mRe=40;async function hRe({mid:e,order:t="pubdate",keyword:n="",pagenum:r=1}){const i=(await Qt.get("/x/space/wbi/arc/search",{params:{mid:e,order:t,keyword:n,ps:mRe,pn:r}})).data;if(!jn(i))throw new Error(`request json error: ${i.message}`||Up);const a=i.data.list.vlist||[],l=i.data.page.count;let u,d;{const{count:m,pn:p,ps:g}=i.data.page;u=p*g<m,d=m-(p-1)*g;}return {items:a,hasMore:u,count:l,endVol:d}}async function pRe(...e){return await qG(()=>hRe(...e),{retries:5,factor:1.5,onFailedAttempt:t=>console.error(t)})}var Fa=(e=>(e.Mid="space-mid",e.GroupId="space-group-id",e.SearchText="space-search-text",e.FilterText="space-filter-text",e.InitialPage="space-initial-page",e))(Fa||{});const Ag=new URLSearchParams(location.search),gRe=Ag.get("space-mid")||void 0,U9=Ag.get("space-group-id")||void 0,vRe=Ag.get("space-search-text")||void 0,bRe=Ag.get("space-filter-text")||void 0,W9=Ag.get("space-initial-page")||void 0,KG=(gRe||"").split(/[,_-]/).map(e=>e.trim()).filter(Boolean).filter(e=>/^\d+$/.test(e)),YG=U9?Number(U9):void 0,oM=!!KG.length||YG!==void 0,ra=zn({mids:KG,groupId:YG,order:$s.Latest,searchText:vRe,filterText:bRe,get isMultipleTraget(){return this.mids.length>1||this.groupId!==void 0},get allowedOrders(){return [$s.Latest,$s.View,!this.isMultipleTraget&&$s.Fav].filter(Boolean)},get usingOrder(){return this.allowedOrders.includes(this.order)?this.order:this.allowedOrders[0]}});function J1(){if(zA)return nt.DynamicFeed;if(Dy)return nt.Fav;if(oM)return nt.SpaceUpload;if(iM.get("gate-tab"))return iM.get("gate-tab")}var XG=(e=>(e.MainSwitch="gate",e.Tab="gate-tab",e))(XG||{});const iM=new URL(location.href).searchParams;function yRe(){return iM.has("gate")}function SRe(){const e=new URL(location.href);return e.search="",e.searchParams.set("gate","1"),e.href}const CRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[F("path",{strokeDasharray:20,d:"M12 4h2v6h2.5l-4.5 4.5M12 4h-2v6h-2.5l4.5 4.5",children:[x("animate",{attributeName:"d",dur:"1.5s",keyTimes:"0;0.5;1",repeatCount:"indefinite",values:"M12 4h2v6h2.5l-4.5 4.5M12 4h-2v6h-2.5l4.5 4.5;M12 4h2v3h2.5l-4.5 4.5M12 4h-2v3h-2.5l4.5 4.5;M12 4h2v6h2.5l-4.5 4.5M12 4h-2v6h-2.5l4.5 4.5"}),x("animate",{fill:"freeze",attributeName:"stroke-dashoffset",dur:"0.5s",values:"20;0"})]}),x("path",{strokeDasharray:14,strokeDashoffset:14,d:"M6 19h12",children:x("animate",{fill:"freeze",attributeName:"stroke-dashoffset",begin:"0.5s",dur:"0.2s",to:0})})]})]}),xRe=f.forwardRef(CRe);function QG({showCopyBvidInfo:e}){const{__internalEnableCopyBvidInfo:t}=Ut();return F(ze,{children:[F(st,{onClick:WA,className:"inline-flex-center",children:[x(tu,{})," 复制 BVID"]}),(e??t)&&F(st,{onClick:qA,className:"inline-flex-center",children:[x(tu,{})," 复制 BVID 信息"]})]})}function Ng(){const{__internalAddTabbarCopyBvidButton:e}=Ut();return e?x("div",{className:"flex items-center gap-x-2",children:F(Do,{theme:{components:{Button:{paddingInline:6}}},children:[x(wRe,{}),x(GG,{iconOnly:false}),x(QG,{})]})}):null}function wRe(){const e=f.useMemo(ZG,[]),{recSharedEmitter:t}=Ei(),n=ga(()=>t.emit("load-to-end"),{manual:true});return e&&F(st,{className:"flex items-center gap-x-1",loading:n.loading,onClick:()=>n.run(),children:[!n.loading&&x(xRe,{className:"size-18px"}),"加载全部"]})}function ZG(){const e=J1();return !!e&&[nt.DynamicFeed,nt.SpaceUpload].includes(e)}const JG={overscrollBehavior:"contain",maxHeight:"60vh",overflowY:"scroll",scrollbarWidth:"thin",paddingRight:"12px"},$Re=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 5h.01M3 12h.01M3 19h.01M8 5h13M8 12h13M8 19h13"})]}),ERe=f.forwardRef($Re),MRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("rect",{width:8,height:5,x:14,y:17,rx:1}),x("path",{d:"M10 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v2.5"}),x("path",{d:"M20 17v-2a2 2 0 1 0-4 0v2"})]})]}),RRe=f.forwardRef(MRe),TRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"})]}),ARe=f.forwardRef(TRe),NRe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 512 512",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:32,d:"m434.8 137.65l-149.36-68.1c-16.19-7.4-42.69-7.4-58.88 0L77.3 137.65c-17.6 8-17.6 21.09 0 29.09l148 67.5c16.89 7.7 44.69 7.7 61.58 0l148-67.5c17.52-8 17.52-21.1-.08-29.09M160 308.52l-82.7 37.11c-17.6 8-17.6 21.1 0 29.1l148 67.5c16.89 7.69 44.69 7.69 61.58 0l148-67.5c17.6-8 17.6-21.1 0-29.1l-79.94-38.47"}),x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:32,d:"m160 204.48l-82.8 37.16c-17.6 8-17.6 21.1 0 29.1l148 67.49c16.89 7.7 44.69 7.7 61.58 0l148-67.49c17.7-8 17.7-21.1.1-29.1L352 204.48"})]}),PRe=f.forwardRef(NRe),eq=ERe,KA=RRe,YA=ARe,eS=PRe,G9=fT({sidebarFavFolderOrder:"default"},"fav-rec-service:view");function tq(e,t){const{folders:n,collections:r,selectedKey:o}=bt(pn),{sidebarFavFolderOrder:i}=bt(G9),a=co();return {menuItems:f.useMemo(()=>{let u;{let m=n,p;e==="sidebarView"&&(p=x(PG,{value:i,onChange:b=>G9.sidebarFavFolderOrder=b,className:"ml-4"}),m=NG(n,i));const g=m.map(b=>{DA(b.attr);const y=q1(b.attr),S=`fav-folder:${b.id}`,C=y?x(KA,{}):x(YA,{}),w=`${b.title} (${b.media_count})`;return {key:S,icon:C,label:w,async onClick(){pn.selectedFavFolderId=b.id,pn.selectedFavCollectionId=void 0,t?.(),await gn(100),a();}}});u=!!m.length&&{type:"group",label:F("div",{className:"flex items-center justify-between line-height-snug",children:["收藏夹",p]}),children:g};}let d;{const m=GX(r,b=>b.upper.name);let p=Object.entries(m).map(([b,y])=>({upName:b,collections:F9(y,"title")}));p=F9(p,"upName");const g=[];for(const{upName:b,collections:y}of p){const S=y[0]?.upper.mid,C=S?Tg(S):"#";g.push(...gi([{type:"group",label:F("span",{className:"flex items-center gap-x-2px",children:[x(No,{className:"mt-2px size-15px flex-none"}),F("a",{target:"_blank",href:C,children:["@",b]})]}),children:y.map(w=>{const $=`fav-collection:${w.id}`,M=F("span",{className:"ml-8px flex items-center gap-x-2px",children:[x(eS,{className:"size-15px flex-none"}),w.title," (",w.media_count,")"]});return {key:$,label:M,title:`${w.title} (${w.media_count})`,async onClick(){pn.selectedFavFolderId=void 0,pn.selectedFavCollectionId=w.id,t?.(),await gn(100),a();}}})}]));}d=!!r.length&&{type:"group",label:"合集",children:g};}return gi([{key:"all",icon:x(eq,{}),label:"全部",async onClick(){pn.selectedFavFolderId=void 0,pn.selectedFavCollectionId=void 0,t?.(),await gn(100),a();}},u,d])},[n,r,e,i,a]),selectedKey:o}}function IRe({extraContent:e}){const{fav:t,enableSidebar:n}=Ut(),{selectedFavFolder:r,selectedFavCollection:o,selectedLabel:i,selectedKey:a}=bt(pn),l=co(),{ref:u,getPopupContainer:d}=Tu();oo(()=>{c6();}),Ps(()=>{(async()=>(await gn(100),l()))();},[t.addSeparator]);const[m,p]=f.useState(false),{menuItems:g}=tq("tabbarView",()=>{p(false);}),b="relative top-[-0.5px] size-15px",y=r?q1(r.attr)?x(KA,{className:b}):x(YA,{className:b}):o?x(eS,{className:b}):x(eq,{className:b}),S=i,C=x(tc,{open:m,onOpenChange:p,placement:"bottomLeft",getPopupContainer:d,menu:{items:g,style:{...JG,border:`1px solid ${qf()}`},selectedKeys:[a]},children:x(st,{css:[m&&Gf,"",""],children:F("span",{className:"h-full flex items-center gap-x-4px",children:[y,S]})})});return F("div",{ref:u,className:"flex items-center gap-x-10px",children:[!n&&C,e,x(Ng,{})]})}function ORe({allFavFolderServices:e,state:t}){const{fav:n}=Ut(),r=co(),{ref:o,getPopupContainer:i}=Tu(),{totalCountInFavFolders:a}=bt(t),[l,u]=f.useState(false),d=Je((g,b,y)=>{u(true),at.fav.excludedFolderIds=g.map(S=>S.toString());}),m=f.useMemo(()=>e.filter(g=>!n.excludedFolderIds.includes(g.entry.id.toString())).length,[e,n.excludedFolderIds]),p=Je(g=>{g?u(false):l&&r();});return x(Zo,{getTooltipContainer:i,trigger:"click",placement:"bottom",onOpenChange:p,getPopupContainer:g=>g.parentElement||document.body,content:x(ze,{children:x(S1,{dataSource:e,rowKey:g=>g.entry.id.toString(),titles:["收藏夹","忽略"],targetKeys:n.excludedFolderIds,onChange:d,render:g=>g.entry.title,oneWay:true,style:{marginBottom:10}})}),children:F(vo,{ref:o,color:"success",className:"mx-0 cursor-pointer text-size-12px",children:["收藏夹(",m,") 收藏(",a,")"]})})}function DRe(){const{menuItems:e,selectedKey:t}=tq("sidebarView"),{menuRef:n}=WG(e,t);return F(ze,{children:[x(ec,{ref:n,items:e,selectedKeys:[t],mode:"inline",inlineIndent:10}),UG]})}var La=(e=>(e[e.Offline=0]="Offline",e[e.Streaming=1]="Streaming",e[e.Rolling=2]="Rolling",e))(La||{});class XA extends Map{#n=0;#e=new Map;#t=new Map;#o;#a;#i;constructor(t={}){if(super(),!(t.maxSize&&t.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof t.maxAge=="number"&&t.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");this.#o=t.maxSize,this.#a=t.maxAge||Number.POSITIVE_INFINITY,this.#i=t.onEviction;}get __oldCache(){return this.#t}#s(t){if(typeof this.#i=="function")for(const[n,r]of t)this.#i(n,r.value);}#r(t,n){return typeof n.expiry=="number"&&n.expiry<=Date.now()?(typeof this.#i=="function"&&this.#i(t,n.value),this.delete(t)):false}#f(t,n){if(this.#r(t,n)===false)return n.value}#c(t,n){return n.expiry?this.#f(t,n):n.value}#u(t,n){const r=n.get(t);return this.#c(t,r)}#d(t,n){this.#e.set(t,n),this.#n++,this.#n>=this.#o&&(this.#n=0,this.#s(this.#t),this.#t=this.#e,this.#e=new Map);}#m(t,n){this.#t.delete(t),this.#d(t,n);}*#l(){for(const t of this.#t){const[n,r]=t;this.#e.has(n)||this.#r(n,r)===false&&(yield t);}for(const t of this.#e){const[n,r]=t;this.#r(n,r)===false&&(yield t);}}get(t){if(this.#e.has(t)){const n=this.#e.get(t);return this.#c(t,n)}if(this.#t.has(t)){const n=this.#t.get(t);if(this.#r(t,n)===false)return this.#m(t,n),n.value}}set(t,n,{maxAge:r=this.#a}={}){const o=typeof r=="number"&&r!==Number.POSITIVE_INFINITY?Date.now()+r:void 0;return this.#e.has(t)?this.#e.set(t,{value:n,expiry:o}):this.#d(t,{value:n,expiry:o}),this}has(t){return this.#e.has(t)?!this.#r(t,this.#e.get(t)):this.#t.has(t)?!this.#r(t,this.#t.get(t)):false}peek(t){if(this.#e.has(t))return this.#u(t,this.#e);if(this.#t.has(t))return this.#u(t,this.#t)}expiresIn(t){const n=this.#e.get(t)??this.#t.get(t);if(n)return n.expiry?n.expiry-Date.now():Number.POSITIVE_INFINITY}delete(t){const n=this.#e.delete(t);return n&&this.#n--,this.#t.delete(t)||n}clear(){this.#e.clear(),this.#t.clear(),this.#n=0;}resize(t){if(!(t&&t>0))throw new TypeError("`maxSize` must be a number greater than 0");const n=[...this.#l()],r=n.length-t;r<0?(this.#e=new Map(n),this.#t=new Map,this.#n=n.length):(r>0&&this.#s(n.slice(0,r)),this.#t=new Map(n.slice(r)),this.#e=new Map,this.#n=0),this.#o=t;}evict(t=1){const n=Number(t);if(!n||n<=0)return;const r=[...this.#l()],o=Math.trunc(Math.min(n,Math.max(r.length-1,0)));o<=0||(this.#s(r.slice(0,o)),this.#t=new Map(r.slice(o)),this.#e=new Map,this.#n=0);}*keys(){for(const[t]of this)yield t;}*values(){for(const[,t]of this)yield t;}*[Symbol.iterator](){for(const t of this.#e){const[n,r]=t;this.#r(n,r)===false&&(yield [n,r.value]);}for(const t of this.#t){const[n,r]=t;this.#e.has(n)||this.#r(n,r)===false&&(yield [n,r.value]);}}*entriesDescending(){let t=[...this.#e];for(let n=t.length-1;n>=0;--n){const r=t[n],[o,i]=r;this.#r(o,i)===false&&(yield [o,i.value]);}t=[...this.#t];for(let n=t.length-1;n>=0;--n){const r=t[n],[o,i]=r;this.#e.has(o)||this.#r(o,i)===false&&(yield [o,i.value]);}}*entriesAscending(){for(const[t,n]of this.#l())yield [t,n.value];}get size(){if(!this.#n)return this.#t.size;let t=0;for(const n of this.#t.keys())this.#e.has(n)||t++;return Math.min(this.#n+t,this.#o)}get maxSize(){return this.#o}get maxAge(){return this.#a}entries(){return this.entriesAscending()}forEach(t,n=this){for(const[r,o]of this.entriesAscending())t.call(n,o,r,this);}get[Symbol.toStringTag](){return "QuickLRU"}toString(){return `QuickLRU(${this.size}/${this.maxSize})`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}const _Re=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 8V6a2 2 0 0 1 2-2h2M4 16v2a2 2 0 0 0 2 2h2m8-16h2a2 2 0 0 1 2 2v2m-4 12h2a2 2 0 0 0 2-2v-2M9 10h.01M15 10h.01M9.5 15.05a3.5 3.5 0 0 1 5 0"})]}),BRe=f.forwardRef(_Re);function LRe(e){return e instanceof Error&&e.name==="AxiosError"}function fh(e){return e&&x("p",{className:"mt-10px",children:e})}function nq(e){if(!(e&&e instanceof Error))return fh(JSON.stringify(e));const t=!!e.message&&F(ze,{children:["Error Message: ",e.message]}),n=!!e.stack&&F(ze,{children:["Error Stack: ",x("br",{}),e.stack]});let r,o;if(e.cause&&(r=F(ze,{children:["Error Cause: ",nq(e.cause)]})),LRe(e)){const i=ef(e);i.config?.params?.access_key&&(i.config.params.access_key="*".repeat(i.config.params.access_key.length)),o=F(ze,{children:["axios config: ",JSON.stringify(i.config,null,2)]});}return F(ze,{children:[fh(t),fh(n),fh(r),fh(o)]})}function zRe(e){return e&&e instanceof rq&&e.message||e&&e instanceof sA?e.message:"出错了, 请刷新重试!"}class rq extends Error{constructor(t){super(t),this.name="ShowMessageError";}}function kRe({err:e,tab:t}){const n=Q1(),r=f.useMemo(()=>zRe(e),[e]),o=f.useMemo(()=>nq(e),[e]);return F("div",{className:"flex flex-col items-center gap-y-0.5em p-20px text-center text-size-20px",children:[x(fn,{title:F("div",{className:"py-10px",children:[x("h3",{children:"错误详情"}),x("div",{className:"max-h-50vh overflow-hidden overflow-y-auto whitespace-pre-wrap break-normal",children:o})]}),children:F("p",{className:"flex cursor-pointer items-center justify-center",children:[x(BRe,{className:"mr-4px"}),r]})}),t===nt.Hot&&Wo.subtab===hr.PopularWeekly&&F("p",{className:"mt-8px flex items-center justify-center",children:["可能需手动输入验证码",x(No,{className:"ml-12px"}),x("a",{href:"https://www.bilibili.com/v/popular/weekly",target:n,className:"ml-2px",children:"每周必看"})]}),t===nt.Liked&&e instanceof sA&&x(PA,{className:"mt-0.5em"})]})}function oq(e){const t=e==="follow"?1:2;return async function(r){return await eG(r,t)}}const FRe=oq("follow"),HRe=oq("unfollow"),VRe={follow:FRe,unfollow:HRe};function jRe(e){return [1,2,6].includes(e.attribute)}async function URe(e){return (await Qt.get("/x/relation",{params:{fid:e}})).data.data}const WRe=aA(URe,{cacheKey:([e])=>e.toString()});async function GRe(e){const n=(await Qt.get("/x/space/wbi/acc/info",{params:{mid:e,w_webid:await fG()||""}})).data;if(!jn(n)){Ko("space acc info error for %s: %o",e,n);return}return n.data}const QA=Ru({fn:GRe,generateKey:e=>e.toString(),tableName:"space-acc-info",ttl:lo("10d"),concurrency:2});async function qRe(e){return (await QA(e))?.name}const Pg=Ru({fn:qRe,generateKey:e=>e.toString(),tableName:"user-nickname",ttl:lo("10d")});async function S$(e,t){await Pg.cache.set(e.toString(),{val:t,ts:Date.now()});}const iq=F(ze,{children:["1. 可以使用多个过滤词, 用空格分隔, 逻辑关系为且 (AND) ",x("br",{}),'2. 可以使用引号包裹过滤词, 如 "word or sentence" ',x("br",{}),'3. 可以使用 -"word or sentence" 排除; 必须使用引号(单引号 或 双引号) ',x("br",{})]});function aq(e){const t=[],n=[];if(!e.trim())return {includes:t,excludes:n};let r=0;const o=e.length;for(;r<o;){for(;r<o&&e[r]===" ";)r++;if(r>=o)break;let i=false,a="";if(e[r]==="-"){const l=e[r+1];(l==='"'||l==="'")&&(i=true,r++);}if(e[r]==='"'||e[r]==="'"){const l=e[r];r++;let u=false;for(;r<o;){const d=e[r];if(u){a+=d,u=false,r++;continue}if(d==="\\"){const m=e[r+1];if(m==='"'||m==="'"){u=true,r++;continue}a+=d,r++;continue}if(d===l){r++;break}a+=d,r++;}}else for(;r<o&&e[r]!==" ";){if(e[r]==="\\"){r++,r<o&&(a+=e[r],r++);continue}a+=e[r],r++;}a&&(i?n.push(a):t.push(a));}return {includes:t,excludes:n}}function KRe(e){return !!(e.elec_arc_type===1||!e.elec_arc_type&&e.is_charging_arc||e.elec_arc_type===2)}const ZA=function({value:e,onChange:t,disabled:n,list:r,listDisplayConfig:o,dropdownProps:i,extraHelpInfo:a,$ref:l}){const{icon:u,label:d}=o[e],m=Je(S=>{const C=r.filter(T=>T!=="divider"),w=C.indexOf(e);if(w===-1)return;const $=(w+(S.shiftKey?-1:1)+C.length)%C.length,M=C[$];t(M);}),p=f.useMemo(()=>gi(r.map(S=>{if(S==="divider")return {type:"divider"};const{icon:C,label:w}=o[S];return {key:S,icon:C,label:w,onClick:()=>t(S)}})),[r,o,t]),[g,b]=f.useState(false),y=Swe();return F("span",{className:"inline-flex items-center",ref:l,children:[x(tc,{open:g,onOpenChange:b,disabled:n,menu:{items:p,selectedKeys:[e.toString()],styles:{root:y}},placement:"bottomRight",classNames:{root:"text-13px",item:"justify-start",itemContent:"flex-shrink-0"},...i,children:F(st,{className:X(tU,"px-3"),css:[g&&Gf,"",""],disabled:n,onClick:m,children:[u,d]})}),F(pr,{children:[a,a&&x(q3,{}),"操作说明: ",x("br",{}),"1. 点击/下拉切换 ",x("br",{}),"2. 按住 ",x("kbd",{className:fu,children:"Shift"})," 键点击逆序切换 ",x("br",{})]})]})};function YRe(){const{searchText:e,filterText:t}=bt(ra,{sync:true}),{allowedOrders:n,usingOrder:r}=bt(ra),{spaceUpload:{useSyncFilterTextFromSearchText:o}}=Ut(),i=co(),{recSharedEmitter:a}=Ei(),l=Je(()=>{u();const{searchText:d,filterText:m}=ra,p=location.href,g=new URL(p);d?g.searchParams.set(Fa.SearchText,d):g.searchParams.delete(Fa.SearchText),m?g.searchParams.set(Fa.FilterText,m):g.searchParams.delete(Fa.FilterText),g.href!==p&&history.replaceState({},"",g.href);}),u=Je(()=>{at.spaceUpload.useSyncFilterTextFromSearchText&&(ra.filterText=ra.searchText);});return oo(l),F("div",{className:"flex items-center gap-x-10px",children:[x(ZA,{value:r,list:n,listDisplayConfig:fRe,onChange:d=>{ra.order=d,i();}}),x(Yi.Search,{style:{width:200},placeholder:"搜索词",allowClear:true,value:e,onChange:d=>ra.searchText=d.target.value,onSearch:d=>{ra.searchText=d,l(),i();}}),F(Zr.Compact,{children:[x(Zr.Addon,{children:x(fn,{title:x(ze,{children:"精准搜索: 自动将搜索词同步到过滤词"}),children:x(Pt,{className:"[&>.ant-checkbox-label]:hidden",configPath:"spaceUpload.useSyncFilterTextFromSearchText",extraAction:d=>{d&&(l(),i());}})})}),x(Yi.Search,{style:{width:200},placeholder:"本地过滤词",allowClear:true,value:t,disabled:o,onChange:d=>ra.filterText=d.target.value,onSearch:d=>{ra.filterText=d,l(),i();}})]}),x(Pt,{configPath:"spaceUpload.showVol",label:"显示序号",className:"flex-none"}),x(Ng,{})]})}const sq=new XA({maxSize:100}),Ty=Rr();async function XRe(e){if(Ty.has(e))return;const t=await WRe(e);jRe(t)&&Ty.add(e);}function lq(){const e=Fr(ra);return {mids:e.mids,groupId:e.groupId,order:e.usingOrder,searchText:e.searchText,filterText:e.filterText,initialPage:W9?Number(W9):void 0}}class JA extends Gs{constructor(t){if(super(JA.PAGE_SIZE),this.config=t,Object.assign(this,t),this.mids=t.mids,this.order=t.order,Ro(this.mids.length||this.groupId!==void 0,"mid & groupId can not both be empty"),this.searchText=this.searchText?.trim(),this.initialPage&&(this.groupId!==void 0||this.mids.length>1))throw new Error("initialPage not supported when merging")}static PAGE_SIZE=20;mids;groupId;order;searchText;filterText;initialPage;sidebarView=void 0;tabbarView=x(YRe,{});get hasMoreExceptQueue(){return this.service?this.service.hasMore:true}async fetchAvatars(t){await Promise.all(t.map(async n=>{const r=await QA(n);r&&sq.set(n,r.face);}));}async fetchFollowState(t){await Wl(t,XRe,3);}pageTitleSet=false;async setPageTitle(){if(this.pageTitleSet)return;const t=[];this.searchText&&t.push(`🔍【${this.searchText}】`),this.filterText&&t.push(`⏳【${this.filterText}】`);let n;if(this.mids.length)n=(await Wl(this.mids,Pg,3)).map(i=>i?.trim()).filter(Boolean).map(i=>`「${i}」`).join("、");else {const i=(await mG()).find(a=>a.tagid===this.groupId)?.name||"";n=i?`「${i}」`:"";}const r=[t.join(""),`${n}的投稿`].map(o=>o.trim()).filter(Boolean).join(" - ");mA(r),this.pageTitleSet=true;}singleUpService;mergeTimelineService;async setupServices(){if(!(this.singleUpService||this.mergeTimelineService)){if(this.mids.length===1){this.singleUpService=new cq(this.mids[0],this.order,this.searchText,this.initialPage);return}if(this.mids.length){this.mergeTimelineService=new q9(this.mids,this.order,this.searchText);return}if(this.groupId!==void 0){const t=await Z3(this.groupId);if(t.forEach(n=>Ty.add(n)),!t.length)throw new Error("Group is Empty!");this.mergeTimelineService=new q9(t.map(n=>n.toString()),this.order,this.searchText);return}}}get service(){return this.singleUpService||this.mergeTimelineService}warnNeedLoginOnce=xf(zq);async fetchMore(t){if(!sU())throw this.warnNeedLoginOnce(),new rq(Lq);this.setPageTitle(),await this.setupServices(),Ro(this.service,"this.service should exist after setupServices");const n=await this.service.loadMore(t)||[],r=this.singleUpService?this.singleUpService.endVol:this.mergeTimelineService.count-this.qs.fetchedCount;let o=n.map((i,a)=>({...i,api:Ye.SpaceUpload,uniqId:`${Ye.SpaceUpload}:${i.bvid}`,groupId:this.groupId,vol:r-a,page:this.singleUpService?this.singleUpService.page-1:void 0}));if(o=o.filter(i=>!KRe(i)),this.filterText){const{includes:i,excludes:a}=aq(this.filterText);o=o.filter(l=>i.every(u=>l.title.includes(u))&&a.every(u=>!l.title.includes(u)));}{const i=ky(o.filter(a=>a.author.trim()!=="账号已注销")).map(a=>a.mid).filter(Boolean);await Promise.all([this.fetchAvatars(i),this.fetchFollowState(i)]);}return o}}class q9{constructor(t,n,r){this.mids=t,this.order=n,this.searchText=r,Ro(this.mids.length===1||this.mids.length>1&&this.order!==$s.Fav,"SpaceUploadItem.Fav not supported when merging"),this.singleUpServices=t.map(o=>new cq(o,this.order,this.searchText));}singleUpServices;get hasMore(){return this.singleUpServices.some(t=>t.hasMore)}get count(){return this.singleUpServices.reduce((t,n)=>t+n.count,0)}async refillQueues(t){await Wl(this.singleUpServices,n=>n.refillQueue(1,t),5);}async loadMore(t){if(!this.hasMore)return;if(this.mids.length===1)return this.singleUpServices[0].loadMore(t);const n=[],r=10;for(;this.hasMore&&n.length<r;){await this.refillQueues(t);const o=this.singleUpServices.filter(l=>l.bufferQueue.length>0),i=xs(o.map(l=>{const u=l.bufferQueue[0],d={[$s.Latest]:u.created,[$s.View]:u.play,[$s.Fav]:u.play}[this.order];return {service:l,item:u,valueForSort:d}}),["valueForSort"],["desc"]).map(l=>l.service)[0];if(!i)break;const a=i.bufferQueue[0];i.bufferQueue=i.bufferQueue.slice(1),n.push(a);}return n}}class cq{constructor(t,n,r,o){this.mid=t,this.order=n,this.searchText=r,this.initialPage=o,this.page=this.initialPage??1;}bufferQueue=[];hasMoreForApi=true;count=0;endVol=0;get hasMore(){return !!this.bufferQueue.length||this.hasMoreForApi}async refillQueue(t,n){if(this.hasMore)for(;!n?.aborted&&this.hasMoreForApi&&this.bufferQueue.length<t;){const r=await this.loadMore(n)||[];this.bufferQueue.push(...r);}}page;async loadMore(t){const{items:n,hasMore:r,count:o,endVol:i}=await pRe({mid:this.mid,order:this.order,pagenum:this.page,keyword:this.searchText||""});return this.hasMoreForApi=r,this.page++,this.count=o,this.endVol=i,n}}const K9=e=>(e||"").replace(/^http:\/\//,"https://"),e6="·";function QRe(e,t){const n=e.api,r=t[n];return r(e)}function ZRe(){const t=new WeakMap;return t.clear??=FB,t.size=0,t}const em=tQ(e=>{const t=QRe(e,{[Ye.AppRecommend]:JRe,[Ye.PcRecommend]:tTe,[Ye.DynamicFeed]:nTe,[Ye.Watchlater]:rTe,[Ye.Fav]:oTe,[Ye.PopularGeneral]:iTe,[Ye.PopularWeekly]:aTe,[Ye.Rank]:sTe,[Ye.Live]:lTe,[Ye.SpaceUpload]:cTe,[Ye.Liked]:uTe});return t.authorFace&&(t.authorFace=K9(t.authorFace)),t.cover&&(t.cover=K9(t.cover)),t},{cache:ZRe(),getCacheKey:e=>e});function JRe(e){return eTe(e)}function eTe(e){const t=C=>{const{cover_left_text_1:w,cover_left_text_2:$,cover_left_text_3:M}=e,T=[w,$,M].filter(Boolean);if(C==="play"){const R=T.find(N=>/观看|播放$/.test(N));if(!R)return;const I=R.replace(/观看|播放$/,"");return Gc(I)}if(C==="danmaku"){const R=T.find(N=>N.endsWith("弹幕"));if(!R)return;const I=R.replace(/弹幕$/,"");return Gc(I)}if(C==="bangumi:follow"){const R=T.find(N=>/追[剧番]$/.test(N));if(!R)return;const I=R.replace(/追[剧番]$/,"");return Gc(I)}},n=e.param,r=e.bvid||LA(Number(e.param)),o=e.player_args?.cid,i=(()=>{if(e.uri.startsWith("http://")||e.uri.startsWith("https://"))return e.uri;if(e.goto==="av")return `/video/${r}/`;if(e.goto==="bangumi")return Ko("bangumi uri should not starts with 'bilibili://': %s",e.uri),e.uri;if(e.goto==="picture"){const C=/^bilibili:\/\/article\/(\d+)$/.exec(e.uri)?.[1];return C?`/read/cv${C}`:e.uri}return e.uri})(),a=t("play"),l=void 0,u=void 0,d=t("danmaku"),m=void 0,p=t("bangumi:follow"),g=[{field:"play",value:a},typeof d=="number"?{field:"danmaku",value:d}:{field:"bangumi:follow",value:p}],b=e.desc||"",[y=void 0,S=void 0]=b.split(e6);return {avid:n,bvid:r,cid:o,goto:e.goto,href:i,title:e.title,cover:e.cover,pubts:void 0,pubdateDisplay:S,duration:e.player_args?.duration||0,durationStr:Ws(e.player_args?.duration),recommendReason:e.bottom_rcmd_reason||e.top_rcmd_reason,play:a,like:l,coin:u,danmaku:d,favorite:m,bangumiFollow:p,statItems:g,authorName:e.args.up_name||y,authorFace:e.avatar.cover,authorMid:String(e.args.up_id||""),appBadge:e.cover_badge,appBadgeDesc:e.desc}}function tTe(e){e.goto,ws.AV;const t=e.goto===ws.Live;return {avid:t?void 0:String(e.id),bvid:t?void 0:e.bvid,cid:t?void 0:e.cid,goto:e.goto,href:e.goto==="av"?`/video/${e.bvid}/`:e.uri,title:e.title,cover:e.pic,pubts:e.pubdate,duration:e.duration,durationStr:Ws(e.duration),recommendReason:t?e.room_info?.area.area_name:e.rcmd_reason?.content,play:e.stat?.view,like:e.stat?.like,coin:void 0,danmaku:e.stat?.danmaku,favorite:void 0,statItems:t?[{field:"live:viewed-by",value:e.room_info?.watched_show.num}]:[{field:"play",value:e.stat?.view},{field:"danmaku",value:e.stat?.danmaku}],authorName:e.owner?.name,authorFace:e.owner?.face,authorMid:String(e.owner?.mid)}}function nTe(e){return xG(e)}function rTe(e){const t=H3e(e.state),n=e.progress>0,r=`${n?"【已观看】· ":""}${e.title}`,o=t?x(fn,{title:F(ze,{children:["视频已失效, 原因: ",t]}),align:{offset:[0,-5]},placement:"topLeft",children:F("del",{children:[n?"【已观看】· ":"",e.title,"`"]})}):void 0,{watchlaterUseNormalVideoUrl:i,watchlaterItemsOrder:a}=yg(),l=(()=>{if(i)return `https://www.bilibili.com/video/${e.bvid}/`;let u=`https://www.bilibili.com/list/watchlater?bvid=${e.bvid}&oid=${e.aid}`;return a===bo.AddTimeAsc&&(u+="&desc=0"),u})();return {avid:String(e.aid),bvid:e.bvid,cid:e.cid,goto:"av",href:l,title:r,titleRender:o,cover:e.pic,pubts:e.pubdate,pubdateDisplayForTitleAttr:`${f0(e.pubdate,true)} 发布, ${f0(e.add_at,true)} 添加稍后再看`,duration:e.duration,durationStr:Ws(e.duration),recommendReason:`${f0(e.add_at)} · 稍后再看`,statItems:[{field:"play",value:e.stat.view},{field:"like",value:e.stat.like},{field:"favorite",value:e.stat.favorite}],play:e.stat.view,like:e.stat.like,danmaku:e.stat.danmaku,authorName:e.owner.name,authorFace:e.owner.face,authorMid:String(e.owner.mid)}}function oTe(e){const t=e.from==="fav-folder"?e.folder.title:e.collection.title,n={display:"inline-block",verticalAlign:"middle",marginRight:4,marginTop:-2},r="[&_path]:fill-gate-primary",o=e.from==="fav-folder"?q1(e.folder.attr)?x(KA,{className:X("size-15px",r),style:n}):x(YA,{className:X("size-15px",r),style:n}):x(eS,{className:X("size-15px",r),style:n});return {avid:String(e.id),bvid:e.bvid,goto:"av",href:`/video/${e.bvid}/`,title:`【${t}】· ${e.title}`,titleRender:F(ze,{children:["【",o,t,"】· ",e.title]}),cover:e.cover,pubts:e.pubtime,duration:e.duration,durationStr:Ws(e.duration),recommendReason:e.from==="fav-folder"?`${f0(e.fav_time)} · 收藏`:void 0,play:e.cnt_info.play,danmaku:e.cnt_info.danmaku,favorite:e.cnt_info.collect,statItems:[{field:"play",value:e.cnt_info.play},{field:"danmaku",value:e.cnt_info.danmaku},{field:"favorite",value:e.cnt_info.collect}],authorName:e.upper.name,authorFace:e.upper.face,authorMid:String(e.upper.mid)}}function iTe(e){return {avid:String(e.aid),bvid:e.bvid,cid:e.cid,goto:"av",href:`/video/${e.bvid}/`,title:e.title,cover:e.pic,pubts:e.pubdate,duration:e.duration,durationStr:Ws(e.duration),recommendReason:e.rcmd_reason?.content,play:e.stat.view,like:e.stat.like,coin:void 0,danmaku:e.stat.danmaku,favorite:void 0,statItems:[{field:"play",value:e.stat.view},{field:"like",value:e.stat.like}],authorName:e.owner.name,authorFace:e.owner.face,authorMid:String(e.owner.mid)}}function aTe(e){return {avid:String(e.aid),bvid:e.bvid,cid:e.cid,goto:"av",href:`/video/${e.bvid}/`,title:e.title,cover:e.pic,pubts:e.pubdate,duration:e.duration,durationStr:Ws(e.duration),recommendReason:e.rcmd_reason,play:e.stat.view,like:e.stat.like,danmaku:e.stat.danmaku,statItems:[{field:"play",value:e.stat.view},{field:"like",value:e.stat.like}],authorName:e.owner.name,authorFace:e.owner.face,authorMid:String(e.owner.mid)}}function sTe(e){if(A3e(e)||T3e(e)){const n=e.new_ep.cover,r=e.new_ep.index_show;return {avid:"",bvid:"",goto:"bangumi",href:e.url,title:e.title,cover:n,pubts:void 0,pubdateDisplay:void 0,duration:0,durationStr:"",play:e.stat.view,like:e.stat.follow,danmaku:e.stat.danmaku,statItems:[{field:"play",value:e.stat.view},{field:"bangumi:follow",value:e.stat.follow}],rankingDesc:r}}let t=(e.dynamic||e.desc)?.trim();return t==="-"&&(t=void 0),t&&e.title.includes(t)&&(t=void 0),{avid:String(e.aid),bvid:e.bvid,cid:e.cid,goto:"av",href:`/video/${e.bvid}/`,title:e.title,cover:e.pic,pubts:e.pubdate,duration:e.duration,durationStr:Ws(e.duration),recommendReason:t,play:e.stat.view,like:e.stat.like,danmaku:e.stat.danmaku,statItems:[{field:"play",value:e.stat.view},{field:"like",value:e.stat.like}],authorName:e.owner.name,authorFace:e.owner.face,authorMid:String(e.owner.mid)}}function lTe(e){const t=`${e.area_name_v2}`,n=e.live_status===La.Streaming?"":`${e6}${o(e.record_live_time)} 直播过`,r="https://s1.hdslb.com/bfs/static/blive/blfe-link-center/static/img/average-backimg.e65973e.png";function o(i){const a=Yn().format("YYYYMMDD"),l=Yn().subtract(1,"day").format("YYYYMMDD"),u=Yn.unix(i);return u.format("YYYYMMDD")===a?u.format("HH:mm"):u.format("YYYYMMDD")===l?`昨天 ${u.format("HH:mm")}`:u.format("MM-DD HH:mm")}return {goto:"live",href:`https://live.bilibili.com/${e.roomid}`,title:e.title,cover:e.room_cover||r,recommendReason:t,liveExtraDesc:n,statItems:[{field:"live:viewed-by",value:e.text_small}],authorName:e.uname,authorFace:e.face,authorMid:String(e.uid)}}function cTe(e){const t=$y(e.length),n=Ws(t);let r=e.description?.trim();return r==="-"&&(r=void 0),r&&e.title.includes(r)&&(r=void 0),{avid:e.aid.toString(),bvid:e.bvid,cid:void 0,goto:"av",href:`/video/${e.bvid}/`,title:e.title,cover:e.pic,pubts:e.created,duration:t,durationStr:n,recommendReason:r,play:e.play,like:void 0,coin:void 0,danmaku:e.video_review,favorite:void 0,statItems:[{field:"play",value:e.play},{field:"danmaku",value:e.video_review}],authorName:e.author,authorFace:sq.get(e.mid),authorMid:e.mid.toString(),followed:Ty.has(e.mid)}}function uTe(e){const{videoDetail:t}=e,n=e.param,r=LA(Number(n));return {avid:n,bvid:r,cid:void 0,goto:"av",href:`/video/${r}/`,title:e.title,cover:e.cover,pubts:t?.pubdate??e.ctime,duration:e.duration,durationStr:Ws(e.duration),recommendReason:void 0,play:e.play,danmaku:e.danmaku,like:void 0,coin:void 0,favorite:void 0,statItems:[{field:"play",value:e.play},{field:"danmaku",value:e.danmaku}],authorName:e.author,authorFace:t?.owner.face,authorMid:t?.owner.mid?.toString()}}const Y9=/^(?<mid>\d+)\((?<remark>[\S ]+)\)$/,dTe=/^\d+$/;function tS(e){if(Y9.test(e)){const t=Y9.exec(e)?.groups,n=t?.mid,r=t?.remark;return {mid:n,remark:r}}return dTe.test(e)?{mid:e,remark:void 0}:{}}function aM(e){const t=new Set,n=new Set;return e.forEach(r=>{const{mid:o}=tS(r);o?t.add(o):n.add(r);}),{blockUpMids:t,blockUpNames:n}}function X9(e){const t=[],n=[];e.forEach(o=>{if(o.startsWith("/")&&o.endsWith("/")){const i=new RegExp(o.slice(1,-1),"i");t.push(i);}else n.push(o);});function r(o){return n.some(i=>o.includes(i))||t.some(i=>i.test(o))}return {titleKeywordList:n,titleRegexList:t,test:r}}const na=ao.extend("modules:filter");function t6(e){return !!e&&["已关注","新关注"].includes(e)}function uq(e){return [Ye.AppRecommend,Ye.PcRecommend,Ye.Rank,Ye.PopularGeneral,Ye.PopularWeekly].includes(e)}function Ay(e,t){if(!at.filter.enabled&&!Gh.size)return e;const n=yg().filter,{minDuration:r,minPlayCount:o,minDanmakuCount:i,byAuthor:a,byTitle:l,dfByTitle:u,dfHideOpusMids:d}=n,{blockUpMids:m,blockUpNames:p}=aM(a.keywords),{test:g}=X9(l.keywords),{test:b}=X9(u.keywords),{blockUpMids:y}=aM(d.keywords);return e.filter(S=>{if(S.api===Ye.Separator)return true;const{play:C,duration:w,danmaku:$,recommendReason:M,goto:T,authorName:R,authorMid:I,title:N,bvid:P,href:O}=em(S),_=t6(M);if(t==="keep-follow-only"&&!_)return false;function B(){if(I&&Gh.size&&Gh.has(I))return na("filter out by blacklist-rule: %s %o",I,{bvid:P,title:N}),false;if(n.enabled&&a.enabled&&(m.size||p.size)&&(R||I)&&(R&&p.has(R)||I&&m.has(I)))return na("filter out by author-rule: %o",{authorName:R,authorMid:I,rules:a.keywords,blockUpMids:m,blockUpNames:p,bvid:P,title:N}),false;let H=[N];if(S.api===Ye.Rank&&BA(S)&&S.desc&&H.push(S.desc),H=H.filter(Boolean),n.enabled&&l.enabled&&l.keywords.length&&H.length&&H.some(g))return na("filter out by title-rule: %o",{possibleTitles:H,rules:l.keywords,bvid:P}),false}if(uq(S.api)&&B()===false)return false;if((S.api===Ye.AppRecommend||S.api===Ye.PcRecommend)&&n.enabled){const H=T==="av",z=T==="picture",j=T==="bangumi";if(H)return V();if(z)return U();if(j)return G()}function V(){return _&&n.exemptForFollowed.video?true:M==="关注了你"?(na("filter out by recommendReason-rule: %s %o",M,{bvid:P,title:N}),false):r.enabled&&r.value&&w&&w<r.value?(na("filter out by min-duration-rule: %s < %s %o",w,r.value,{bvid:P,title:N}),false):o.enabled&&o.value&&typeof C=="number"&&C<o.value?(na("filter out by min-play-count-rule: %s < %s, %o",C,o.value,{bvid:P,title:N}),false):i.enabled&&i.value&&typeof $=="number"&&$<i.value?(na("filter out by min-danmaku-count-rule: %s < %s, %o",$,i.value,{bvid:P,title:N}),false):true}function U(){return n.hideGotoTypePicture?_&&n.exemptForFollowed.picture?true:(na("filter out by goto-type-picture-rule: %s %o",T,{bvid:P,title:N}),false):true}function G(){return n.hideGotoTypeBangumi?(na("filter out by goto-type-bangumi-rule: %s %o",T,{title:N,href:O}),false):true}if(Vd(S)&&n.enabled){const{major:H}=S.modules.module_dynamic,z=H?.type===mi.MajorType.Opus;if(at.filter.dfByTitle.enabled&&at.filter.dfByTitle.keywords.length){let j=[N];if(z&&j.push(H.opus.summary?.text||""),j=ky(j.filter(Boolean)),j.some(b))return na("filter out by df-title-rule: %o",{possibleTitles:j,rules:u.keywords,uniqId:S.uniqId,item:S}),false}if(z&&d.enabled&&d.keywords.length&&I&&y.has(I))return na("filter out by df-hide-opus-mids-rule: %o",{dfHideOpusMids:d,authorMid:I,title:N,uniqId:S.uniqId}),false}return true})}async function fTe(e){return (await Qt.get("https://api.live.bilibili.com/xlive/web-ucenter/user/following",{params:{page:e,page_size:Ig.PAGE_SIZE,ignoreRecord:1,hit_ab:true}})).data}class Ig extends Gs{constructor(t=false){super(Ig.PAGE_SIZE),this.streamingOnly=t;}static PAGE_SIZE=20;tabbarView=void 0;sidebarView=void 0;hasMoreExceptQueue=true;separatorAdded=false;liveCount=-1;page=1;totalPage=1/0;async fetchMore(t){if(this.page>this.totalPage){this.hasMoreExceptQueue=false;return}const n=await fTe(this.page);jn(n)||(rn(n.message||Ef),this.hasMoreExceptQueue=false),this.page++;const{count:r,live_count:o,totalPage:i}=n.data;this.totalPage=i,this.liveCount=o;const a=n.data.list.map(m=>({...m,api:Ye.Live,uniqId:`${Ye.Live}:${m.roomid}`})),l=a.at(-1),u=Yn().subtract(2,"weeks").unix();if(l){const m=l.live_status,p=l.record_live_time;m!==La.Streaming&&p&&p<u&&(this.hasMoreExceptQueue=false);}let d=a;if(!this.streamingOnly&&!this.separatorAdded&&a.some(m=>m.live_status!==La.Streaming)){this.separatorAdded=true;const m=a.findIndex(p=>p.live_status!==La.Streaming);d.splice(m,0,{api:Ye.Separator,uniqId:`${Ye.Live}:separator:recent`,content:"最近直播过"});}return this.streamingOnly&&a.some(m=>m.live_status!==La.Streaming)&&(this.hasMoreExceptQueue=false,d=a.filter(m=>m.live_status===La.Streaming)),d}}const mTe=ao.extend("modules:rec-services:dynamic-feed:api");async function Og({videoOnly:e,offset:t,page:n,upMid:r,abortSignal:o}){const i={timezone_offset:"-480",type:e?"video":"all",platform:"web",features:"itemOpusStyle",web_location:"0.0","x-bili-device-req-json":JSON.stringify({platform:"web",device:"pc"}),"x-bili-web-req-json":JSON.stringify({spm_id:"0.0"}),page:n};t&&(i.offset=t);const a="/x/polymer/web-dynamic/v1/feed/all";r&&(i.host_mid=r);const u=(await Qt.get(a,{signal:o,params:i})).data;if(!jn(u)){const m=u.message||Ef;throw rn(m),new Error(m,{cause:u})}const d=u.data;return d?.items?.length&&(d.items=d.items.filter(m=>{const p=!!xG(m);return p||mTe("dynamic-feed filter out: %o",{type:m.type,majorType:m.modules.module_dynamic.major?.type,additionalType:m.modules.module_dynamic.additional?.type,item:m}),p})),d}const Ny=Jf("dynamic-feed-items"),Dg=Jf("dynamic-feed-items-info");async function nS(e){return !!(await Dg.get(e))?.count}function hTe(e,t){const n=a=>`update-filter-cache:${a}`,o=Yl((a,l)=>{ca.info({icon:x(vT,{className:"size-16px"}),key:n(e),title:"过滤缓存更新中...",description:`「${t}」更新中: Page(${a}) Total(${l})`,duration:false});},200);return {notifyOnProgress:o,notifyOnSuccess:()=>{o.flush(),ca.success({key:n(e),title:"缓存更新成功",description:`「${t}」的过滤缓存更新成功`,duration:false});}}}async function pTe(e,t){await nS(e)?await dq(e):await vTe(e,void 0,t);}async function gTe(e,t=false){const n=await Dg.get(e);if(!(!t&&n&&n.count&&n.updatedAt&&Date.now()-n.updatedAt<60*1e3))return dq(e)}async function dq(e){if(!await nS(e))return;const t=await Ny.get(e)||[],n=new Set(t.map(u=>u.id_str));let r=1,o="",i=true,a=[];for(;i;){const u=await Og({upMid:e,page:r,offset:o,videoOnly:true}),d=u.items;a=[...a,...d],o=u.offset,i=u.has_more,r++,i&&n.size&&d.every(p=>n.has(p.id_str))&&(i=false);}const l=Kl([...a,...t],u=>u.id_str);await Ny.set(e,l),await Dg.set(e,{count:l.length,updatedAt:Date.now()});}const C$=Jf("dynamic-feed-items-in-progress");async function vTe(e,t=false,n){const r=t?void 0:await C$.get(e);let o=r?.page??1,i=r?.offset??"",a=r?.items??[],l=true;for(;l;){const d=await Og({upMid:e,page:o,offset:i,videoOnly:true}),m=d.items;a=[...a,...m],i=d.offset,l=d.has_more,o++,await C$.set(e,{page:o,offset:i,items:a}),n?.(o,a.length);}const u=Kl(a,d=>d.id_str);await Ny.set(e,u),await Dg.set(e,{count:u.length,updatedAt:Date.now()}),await C$.delete(e);}const fq=Ru({fn:Og,generateKey:({upMid:e,videoOnly:t})=>`upMid=${e}&videoOnly=${t}`,tableName:"dynamic-feed-newest-items",ttl:300*1e3});class bTe{constructor(t,n,r=false){this.upMid=t,this.videoOnly=n,this.enableHeadCache=r;}bufferQueue=[];hasMoreForApi=true;offset="";page=1;get hasMore(){return !!this.bufferQueue.length||this.hasMoreForApi}async loadMore(){const r=await(this.page===1&&!this.offset&&this.enableHeadCache?fq:Og)({videoOnly:this.videoOnly,upMid:this.upMid,page:this.page,offset:this.offset});return this.offset=r.offset,this.hasMoreForApi=r.has_more,this.page++,fa(r,{has_more:true,items:[],offset:"",update_baseline:"",update_num:0})&&(this.hasMoreForApi=false),r.items}async fillQueue(t,n){for(;!n?.aborted&&this.hasMoreForApi&&this.bufferQueue.length<t;){const r=await this.loadMore();this.bufferQueue.push(...r);}}}class Es{constructor(t,n){this.upMids=t,this.videoOnly=n;const r=t.length>Es.ENABLE_HEAD_CACHE_UPMID_COUNT_THRESHOLD;this.upServices=t.map(o=>new bTe(o,n,r));}static ENABLE_MERGE_TIMELINE_UPMID_COUNT_THRESHOLD=20;static ENABLE_HEAD_CACHE_UPMID_COUNT_THRESHOLD=10;upServices=[];get hasMore(){return this.upServices.some(t=>t.hasMore)}async loadMore(t){if(!this.hasMore)return [];const n=async()=>{await Wl(this.upServices,a=>a.fillQueue(1,t),5);},r=[],o=10;for(;this.hasMore&&r.length<o;){await n();const i=this.upServices.filter(u=>u.hasMore),a=xs(i.map(u=>{const d=u.bufferQueue[0],m=BigInt(d.id_str);return {service:u,item:d,id:m}}),["id"],["desc"]).map(u=>u.service)[0];if(!a)break;const l=a.bufferQueue[0];a.bufferQueue=a.bufferQueue.slice(1),r.push(l);}return r}}function go(e,t,n){const r=Je(n);f.useEffect(()=>(e.on(t,r),()=>{e.off(t,r);}),[e,t,r]);}function yTe(){return new Promise((e,t)=>{const n=new Image;n.onload=()=>e(true),n.onerror=r=>e(false),n.src="data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=";})}const STe=!pg&&await( yTe());function n6(e){return `${e}@96w_96h_1c_1s_!web-avatar${STe?".avif":".webp"}`}function Q9(e){return new Promise(t=>{const n=new Image;n.src=e,n.onload=()=>t(true),n.onerror=()=>t(false);})}function CTe({externalFilterInput:e,onRefresh:t,getPopupContainer:n}){const{upMid:r,dynamicFeedVideoType:o,filterMinDuration:i,filterText:a,hideChargeOnlyVideos:l}=bt(Jt),u=x(Yi.Search,{style:{width:e?"250px":void 0},placeholder:"按标题关键字过滤",type:"search",autoCorrect:"off",autoCapitalize:"off",name:`filterText_${r}`,variant:"outlined",defaultValue:Jt.filterText,autoComplete:"off",allowClear:true,onChange:S=>{$Te({filterText:S.target.value,upMid:r,onRefresh:t});},onSearch:async S=>{Jt.filterText=S||void 0,await gn(100),t();}}),d=x(xTe,{externalFilterInput:e,filterInput:u,refresh:t}),[m,p]=f.useState(false),g=p,b=f.useMemo(()=>!!(o!==Ba.All||l||a||i!==ou.All),[o,l,a,i]),y=x(Zo,{open:m,onOpenChange:g,arrow:false,placement:"bottomLeft",getPopupContainer:n,content:d,styles:{container:{border:`1px solid ${qf()}`}},children:x(u1,{dot:b,color:xa,offset:[-5,5],children:x(st,{className:"icon-only-round-button",css:m&&Gf,children:x(Op,{className:"ml-1px"})})})});return {filterInput:u,popoverContent:d,popoverTrigger:y}}const Yr={wrapper:"max-w-350px",section:"mt-10px min-w-300px first:mt-0px",sectionTilte:"flex items-center pb-2px pl-2px text-20px",sectionContent:"flex flex-col items-start gap-x-10px gap-y-6px"};function xTe({externalFilterInput:e,filterInput:t,refresh:n}){const{viewingSomeUp:r,selectedGroup:o,viewingSomeGroup:i,selectedKey:a,dynamicFeedVideoType:l,filterMinDuration:u,hideChargeOnlyVideos:d,addSeparators:m,filterText:p}=bt(Jt);let g;{const b=zA&&!!p,y=p===hG,{href:S}=f.useMemo(()=>{const C=new URL(location.href);return C.searchParams.has(pi.FilterTextFull)?C.searchParams.set(pi.FilterTextFull,p||""):C.searchParams.has(pi.FilterTextShort)?C.searchParams.set(pi.FilterTextShort,p||""):C.searchParams.set(pi.FilterTextFull,p||""),{href:C.href,path:`${C.pathname}?${C.search}`}},[p]);g=b&&x(fn,{title:S,children:F(st,{disabled:y,href:S,children:["转到过滤词为「",p||"空","」的链接"]})});}return F("div",{className:Yr.wrapper,children:[F("div",{className:Yr.section,children:[F("div",{className:Yr.sectionTilte,children:["视频类型",F(pr,{children:["「",da.ChargeOnly,"」在此程序中归类为「投稿视频」",x("br",{}),"「动态视频」时长通常较短"]})]}),x("div",{children:x(to.Group,{buttonStyle:"solid",value:l,onChange:async b=>{Jt.dynamicFeedVideoType=b.target.value,await gn(100),n?.();},children:Object.values(Ba).map(b=>x(to.Button,{value:b,children:uMe[b]},b))})})]}),l!==Ba.DynamicOnly&&F("div",{className:Yr.section,children:[x("div",{className:Yr.sectionTilte,children:"充电专属"}),x("div",{className:Yr.sectionContent,children:x(Ki,{className:"ml-5px",checked:d,onChange:async b=>{const y=b.target.checked,S=Jt.hideChargeOnlyVideosForKeysSet;y?S.add(a):S.delete(a),await gn(100),n?.();},children:x(fn,{title:F(ze,{children:["隐藏「",da.ChargeOnly,"」视频 ",x("br",{}),"仅对当前 UP 或 分组生效"]}),children:F("span",{style:{userSelect:"none"},children:["隐藏「",da.ChargeOnly,"」"]})})})})]}),F("div",{className:Yr.section,children:[x("div",{className:Yr.sectionTilte,children:"最短时长"}),x("div",{children:x(to.Group,{className:"overflow-hidden [&_.ant-radio-button-wrapper]:px-10px",buttonStyle:"solid",value:u,onChange:async b=>{Jt.filterMinDuration=b.target.value,await gn(100),n?.();},children:Object.values(ou).map(b=>{const{label:y}=vG[b];return x(to.Button,{value:b,children:y},b)})})})]}),(!e||g)&&F("div",{className:Yr.section,children:[x("div",{className:Yr.sectionTilte,children:"过滤"}),F("div",{className:Yr.sectionContent,children:[!e&&t,g]})]}),x(wTe,{}),F("div",{className:Yr.section,children:[F("div",{className:Yr.sectionTilte,children:[i?"分组":r?"UP":"全部",F(pr,{children:["当前",i?"分组":r?"UP":"范围","的一些操作~"]}),i&&o&&F("span",{className:"ml-15px inline-flex items-center text-size-14px",children:["(",F("a",{href:uG(o?.tagid||""),target:"_blank",className:`mx-4px inline-flex items-center text-size-16px ${AU}`,children:[x(No,{className:"mr-2px size-18px"}),o?.name]}),")"]})]}),F("div",{className:Yr.sectionContent,children:[x(Ki,{checked:m,onChange:async b=>{Jt.addSeparatorsMap.set("global",b.target.checked),await gn(100),n?.();},children:x(fn,{title:F(ze,{children:["添加今日/更早分割线 ",x("br",{}),"当前实现为全局共享此设置"]}),children:"添加分割线"})}),i&&!!o&&x(ETe,{followGroup:o,refresh:n})]})]})]})}function wTe(){const{cacheAllItemsEntry:e,cacheAllItemsUpMids:t}=Ut().dynamicFeed.__internal,{viewingSomeUp:n,upMid:r,upName:o}=bt(Jt),i=ga(async(u,d)=>{const{notifyOnProgress:m,notifyOnSuccess:p}=hTe(u,d);await pTe(u,m),p();},{manual:true}),a=f.useMemo(()=>!!r&&t.includes(r.toString()),[r,t]),l=f.useCallback(async u=>{if(!r)return;const m=u.target.checked?{add:[r]}:{remove:[r]};await Ua("dynamicFeed.__internal.cacheAllItemsUpMids",m);},[]);return x(ze,{children:e&&n&&r&&o&&F("div",{className:Yr.section,children:[F("div",{className:Yr.sectionTilte,children:["过滤缓存",F(pr,{children:["开启过滤缓存后, 会加载并缓存 UP 所有的动态 ",x("br",{}),"当本地有缓存且总条数 <= 5000时, 过滤框成为及时过滤, 无需点击过滤按钮"]})]}),F("div",{className:Yr.sectionContent,children:[F("div",{className:"flex flex-wrap items-center gap-x-10px gap-y-3px",children:[x(Ki,{className:"inline-flex items-center",checked:a,onChange:l,children:x(fn,{title:"只有开启此项, 过滤时才会使用缓存",children:F("span",{children:["为「",o,"」开启"]})})}),x(st,{loading:i.loading,onClick:async()=>{await i.runAsync(r,o);},children:"更新缓存"})]}),x(Pt,{configPath:"dynamicFeed.advancedFilter",label:"使用高级过滤",tooltip:iq})]})]})})}const $Te=Yl(async function({filterText:e,upMid:t,onRefresh:n}){if(!t||!(e||!e&&Jt.filterText)||!at.dynamicFeed.__internal.cacheAllItemsEntry||!at.dynamicFeed.__internal.cacheAllItemsUpMids.includes(t.toString())||!await nS(t))return;const r=await Dg.get(t);!r||!r.count||r.count>=5e3||(Jt.filterText=e,await gn(0),n());},100);function mq(){return F(ze,{children:[x("p",{children:"机制介绍:"}),F("ul",{className:"text-13px",children:[F("li",{className:"flex items-start gap-x-10px",children:[x("div",{children:"「从全部过滤」:"}),x("div",{children:'基于全部动态 + 分组UP过滤, 速度可能巨慢, 且过滤后的数量取决于B站记录的"全部"动态范围'})]}),F("li",{className:"flex items-start gap-x-10px",children:[x("div",{children:"「拼接时间线」:"}),F("div",{children:["可以理解为: 去看一遍分组所有 UP 的动态, 然后将它们拼接起来 ",x("br",{}),"启动慢, 但可以加载所有动态; 且分组 UP 越多, 启动越慢 ",x("br",{}),"默认分组 UP 数量不超过 ",Es.ENABLE_MERGE_TIMELINE_UPMID_COUNT_THRESHOLD," ","时会使用「拼接时间线」 ",x("br",{}),"详见",x("a",{className:"mx-5px",href:"https://magicdawn.fun/2024/12/01/bilibili-gate-dynamic-feed-merge-timeline/",target:"_blank",children:"介绍博客"})]})]})]})]})}function ETe({followGroup:e,refresh:t}){const{whenViewAll:n}=bt(at.dynamicFeed),r=e.count;let o;const i=Z9(e.tagid,"dynamicFeed.followGroup.forceUseMergeTimelineIds");{const{checked:u,onChange:d}=i,m=r<=Es.ENABLE_MERGE_TIMELINE_UPMID_COUNT_THRESHOLD;o=x(Ki,{checked:u,onChange:p=>{d(p),t?.();},disabled:m,children:x(fn,{title:F(ze,{children:[x(mq,{}),m&&F("p",{className:"text-yellow-400 italic",children:["当前分组 UP 数量: ",r,", 无需设置"]})]}),children:"分组动态: 强制使用「拼接时间线」"})});}let a;a=(r<=Es.ENABLE_MERGE_TIMELINE_UPMID_COUNT_THRESHOLD||i.checked)&&r>Es.ENABLE_HEAD_CACHE_UPMID_COUNT_THRESHOLD&&x(fn,{title:F(ze,{children:["当分组 UP 数量"," > ",Es.ENABLE_HEAD_CACHE_UPMID_COUNT_THRESHOLD,"时, 「拼接时间线」功能会缓存每个 UP 的最新动态5分钟. ",x("br",{}),"这里可以手动清除缓存"]}),children:x(st,{onClick:()=>{fq.cache.db.clear(),_t.success("已清除缓存");},children:"清除「拼接时间线」- 队头缓存"})});let l;{const{checked:u,onChange:d}=Z9(`${bu}${e.tagid}`,"dynamicFeed.whenViewAll.hideIds");l=n.enableHideSomeContents&&x(Ki,{checked:u,onChange:d,children:x(fn,{title:F(ze,{children:["在「全部」动态中隐藏来自此 ",e.name," 的动态"]}),children:"在「全部」动态中隐藏来自此分组的动态"})});}return F(ze,{children:[l,o,a]})}function Z9(e,t){const n=hU(t),r=f.useMemo(()=>n.includes(e),[n]),o=Je(async a=>{await Ua(t,a?{add:[e]}:{remove:[e]});}),i=f.useCallback(a=>{o(a.target.checked);},[]);return {checked:r,setChecked:o,onChange:i}}function MTe(e){if(Object.assign(Jt,e),e.upMid){const t=Jt.upList.find(n=>n.mid.toString()===e.upMid);t&&(t.has_update=false);}}const x$={upMid:void 0,upName:void 0,upFace:void 0,filterText:void 0,selectedGroupId:void 0,dynamicFeedVideoType:Ba.All,filterMinDuration:ou.All};function hq(e){const{upList:t,groups:n,selectedKey:r}=bt(Jt),o=co(),{followGroup:{enabled:i}}=Ut().dynamicFeed,{recSharedEmitter:a}=Ei(),l=Je(async m=>{MTe(m),await gn(100),o();}),u=Je(()=>{l({...x$}),a.emit("dynamic-feed:clear");});return {menuItems:f.useMemo(()=>{const m={key:"all",icon:x(Yc,{size:"small",children:"全"}),label:"全部",title:"全部",onClick:u};let p=[];i&&(p=n.map(y=>({key:`group:${y.tagid}`,icon:x(Yc,{size:"small",children:y.name[0]||"组"}),label:`${y.name} (${y.count})`,title:`${y.name} (${y.count})`,onClick:()=>l({...x$,selectedGroupId:y.tagid})})));let g=t;e==="dropdown"&&(g=Ey(t,[{prop:y=>y.has_update?1:0,order:"desc"},{prop:y=>kA(y.uname),order:FA}]));const b=g.map(y=>{let S=x(Yc,{size:"small",src:n6(y.face)});return y.has_update&&(S=x(u1,{dot:true,children:S})),{key:`up:${y.mid}`,icon:S,label:x("span",{title:y.uname,className:"block max-w-130px overflow-hidden text-ellipsis whitespace-nowrap",children:y.uname}),title:y.uname,onClick(){l({...x$,upMid:y.mid.toString(),upName:y.uname,upFace:y.face});}}});return [m,...p,...b]},[t,i,n,e]),selectedKey:r,onClear:u,onSelect:l}}function RTe(){const{dynamicFeed:{__internal:{externalFilterInput:e}}}=Ut(),{viewingSomeUp:t,upName:n,upFace:r,selectedGroup:o}=bt(Jt),i=co(),{ref:a,getPopupContainer:l}=Tu(),u=jA(nt.DynamicFeed),{menuItems:d,selectedKey:m,onClear:p}=hq("dropdown");oo(()=>{CG();});const g=o?.count,b=x(lG,{className:"mt--2px size-14px"}),y=r?x(Yc,{size:20,src:n6(r)}):void 0,S=t?y||b:o?x(cG,{className:"size-18px"}):void 0,C=t?n:o?o.name+(g?` (${g})`:""):"全部",[w,$]=f.useState(false),M=x(tc,{open:w,onOpenChange:$,placement:"bottomLeft",getPopupContainer:l,menu:{items:d,style:{...JG,border:`1px solid ${qf()}`},selectedKeys:[m]},children:x(st,{icon:S,className:"gap-4px",css:[w&&Gf,"",""],children:C})}),{popoverTrigger:T,filterInput:R}=CTe({externalFilterInput:e,onRefresh:i,getPopupContainer:l});return F("div",{ref:a,className:"inline-flex items-center gap-x-8px",children:[!u&&M,u?F(st,{onClick:p,className:"gap-0",disabled:!(t||o),children:[x(gy,{className:"mr-5px size-14px"}),x("span",{children:"清除"})]}):(t||o)&&F(st,{onClick:p,className:"gap-0",children:[x(gy,{className:"mr-5px size-14px"}),x("span",{children:"清除"})]}),T,e&&R,x(Ng,{})]})}function TTe(){const e=jA(nt.DynamicFeed),{menuItems:t,selectedKey:n}=hq("sidebar"),{menuRef:r,revealSelected:o}=WG(t,n),{recSharedEmitter:i}=Ei();if(go(i,"dynamic-feed:clear",()=>{o(Dp);}),!!e)return F(ze,{children:[x(ec,{ref:r,items:t,selectedKeys:[n],mode:"inline",inlineIndent:10}),UG]})}function r6(e=Jt){const t=Fr(e);return {upMid:t.upMid,groupId:t.selectedGroupId,filterText:t.filterText,dynamicFeedVideoType:t.dynamicFeedVideoType,hideChargeOnlyVideos:t.hideChargeOnlyVideos,filterMinDuration:t.filterMinDuration,filterMinDurationValue:t.filterMinDurationValue,selectedKey:t.selectedKey,viewingAll:t.viewingAll,viewingSomeUp:t.viewingSomeUp,viewingSomeGroup:t.viewingSomeGroup,addSeparators:t.addSeparators,showLiveInDynamicFeed:at.dynamicFeed.showLive,videoOnly:at.dynamicFeed.videoOnly,whenViewAllEnableHideSomeContents:at.dynamicFeed.whenViewAll.enableHideSomeContents,whenViewAllHideIds:new Set(at.dynamicFeed.whenViewAll.hideIds),advancedFilter:at.dynamicFeed.advancedFilter,filterCacheEnabled:!!t.upMid&&at.dynamicFeed.__internal.cacheAllItemsEntry&&at.dynamicFeed.__internal.cacheAllItemsUpMids.includes(t.upMid.toString()),forceUseMergeTime:!!t.selectedGroup&&at.dynamicFeed.followGroup.forceUseMergeTimelineIds.includes(t.selectedGroup.tagid),startingOffset:cMe,minId:J9(eM)?BigInt(eM):void 0,minTs:J9(k9)?Number(k9):void 0}}function J9(e){return !!e&&/^\d+$/.test(e)}const ATe=ao.extend("modules:rec-services:dynamic-feed");class rS extends Gs{constructor(t){super(rS.PAGE_SIZE),this.config=t,this.config.showLiveInDynamicFeed&&!this.upMid&&this.groupId===void 0&&!this.filterText&&this.dynamicFeedVideoType===Ba.All&&this.filterMinDuration===ou.All&&(this.liveRecService=new Ig(true)),this.config.startingOffset&&(this.offset=this.config.startingOffset);}static PAGE_SIZE=15;tabbarView=x(RTe,{});sidebarView=x(TTe,{});hasMoreExceptQueue=true;get hasMore(){return this.qs.bufferQueue.length||this.liveRecService?.hasMore?true:this.viewingSomeGroup&&this.groupMergeTimelineService?this.groupMergeTimelineService.hasMore:!!this.hasMoreExceptQueue}async shouldReduceMinCount(){return this.viewingAll,this.viewingSomeGroup?(await this.loadGroupMids(),!this.groupMergeTimelineService):!!(this.filterText||this.dynamicFeedVideoType===Ba.DynamicOnly||this.filterMinDuration!==ou.All)}get upMid(){return this.config.upMid}get groupId(){return this.config.groupId}get filterText(){return this.config.filterText}get dynamicFeedVideoType(){return this.config.dynamicFeedVideoType}get hideChargeOnlyVideos(){return this.config.hideChargeOnlyVideos}get filterMinDuration(){return this.config.filterMinDuration}get filterMinDurationValue(){return this.config.filterMinDurationValue}get viewingSomeUp(){return this.config.viewingSomeUp}get viewingSomeGroup(){return this.config.viewingSomeGroup}shouldEnableMergeTimeline(t){return this.config.forceUseMergeTime||t>0&&t<=Es.ENABLE_MERGE_TIMELINE_UPMID_COUNT_THRESHOLD}groupMergeTimelineService;groupMids=new Set;groupMidsLoaded=false;async loadGroupMids(){if(this.groupId!==void 0&&!this.groupMidsLoaded)try{const t=await Z3(this.groupId);this.groupMids=new Set(t),this.shouldEnableMergeTimeline(t.length)&&(this.groupMergeTimelineService=new Es(t.map(n=>n.toString()),this.config.videoOnly));}finally{this.groupMidsLoaded=true;}}get viewingAll(){return this.config.viewingAll}viewingAllHideMids=new Set;viewingAllHideMidsLoaded=false;async loadViewingAllHideMids(){if(!this.viewingAll||!this.config.whenViewAllEnableHideSomeContents||!this.config.whenViewAllHideIds.size||this.viewingAllHideMidsLoaded)return;const t=Array.from(this.config.whenViewAllHideIds).filter(i=>i.startsWith(Cf)).map(i=>i.slice(Cf.length)),n=Array.from(this.config.whenViewAllHideIds).filter(i=>i.startsWith(bu)).map(i=>i.slice(bu.length)),r=this.viewingAllHideMids;t.forEach(i=>r.add(i)),(await Wl(n,i=>Z3(i),3)).flat().forEach(i=>r.add(i.toString())),this.viewingAllHideMidsLoaded=true;}async fetchMore(t){const n=await this._fetchMore(t);return this.handleAddSeparators(n)}liveRecService;_queueForFilterCache;offset="";page=0;async _fetchMore(t){if(this.liveRecService?.hasMore)return (await this.liveRecService.loadMore(t)||[]).filter(p=>p.api!==Ye.Separator);let n;this.viewingSomeGroup&&await this.loadGroupMids(),this.viewingAll&&(await this.loadViewingAllHideMids(),ATe("viewingAll: hide-mids = %o",this.viewingAllHideMids));const r=!!(this.upMid&&this.filterText&&this.config.filterCacheEnabled&&await nS(this.upMid)),o=r&&this.config.advancedFilter,i=o?aq((this.filterText||"").toLowerCase()):void 0;if(r)this._queueForFilterCache||(await gTe(this.upMid),this._queueForFilterCache=new Y1(20),this._queueForFilterCache.bufferQueue=(await Ny.get(this.upMid)||[]).filter(m=>{const p=dh(m);if(!p)return false;const g=p.title;return l({filterText:this.filterText,title:g,useAdvancedFilter:o,useAdvancedFilterParsed:i})})),n=this._queueForFilterCache.sliceFromQueue(this.page+1)||[],this.page++,this.hasMoreExceptQueue=!!this._queueForFilterCache.bufferQueue.length;else if(this.viewingSomeGroup&&this.groupMergeTimelineService)n=await this.groupMergeTimelineService.loadMore(t);else {const m=await Og({videoOnly:this.config.videoOnly,abortSignal:t,page:this.page+1,offset:this.offset,upMid:this.upMid});if(this.page++,this.hasMoreExceptQueue=m.has_more,this.offset=m.offset,n=m.items,this.config.minId){const p=this.config.minId,g=n.findIndex(b=>BigInt(b.id_str)<=p);g!==-1&&(this.hasMoreExceptQueue=false,n=n.slice(0,g+1));}if(this.config.minTs){const p=this.config.minTs,g=n.findIndex(b=>b.modules.module_author.pub_ts<=p);g!==-1&&(this.hasMoreExceptQueue=false,n=n.slice(0,g+1));}}const a=n.filter(m=>{if(!this.viewingSomeGroup||this.groupMergeTimelineService||!this.groupMids.size)return true;const p=m.modules.module_author.mid;return this.groupMids.has(p)}).filter(m=>{if(this.dynamicFeedVideoType===Ba.All)return true;const p=dh(m);if(!p)return false;const g=p.badge.text;return this.dynamicFeedVideoType===Ba.DynamicOnly?g===da.Dynamic:this.dynamicFeedVideoType===Ba.UploadOnly?g===da.Upload||g===da.ChargeOnly:false}).filter(m=>{if(!this.hideChargeOnlyVideos)return true;const p=dh(m);return p?!(p.badge.text===da.ChargeOnly):true}).filter(m=>{if(this.filterMinDuration===ou.All)return true;const p=dh(m);return p?$y(p.duration_text)>=this.filterMinDurationValue:false}).filter(m=>{if(!this.filterText)return true;const p=dh(m);if(!p)return false;const g=p.title||"";return l({filterText:this.filterText,title:g,useAdvancedFilter:o,useAdvancedFilterParsed:i})}).filter(m=>{if(this.config.selectedKey!==Dp)return true;const p=this.viewingAllHideMids;if(!p.size)return true;const g=m.modules.module_author.mid;return !p.has(g.toString())}).map(m=>({...m,api:Ye.DynamicFeed,uniqId:`${Ye.DynamicFeed}:${m.id_str||crypto.randomUUID()}`,groupId:this.viewingSomeGroup?this.groupId:void 0}));function l({title:m,filterText:p,useAdvancedFilter:g,useAdvancedFilterParsed:b}){return m=m.toLowerCase(),p=p.toLowerCase(),g?(b?.includes??[]).every(C=>m.includes(C))&&(b?.excludes??[]).every(C=>!m.includes(C)):m.includes(p)}const{upMid:u,upName:d}=Jt;if(Os&&u&&d&&d===u.toString()&&a[0]){const m=a[0].modules.module_author.name,p=a[0].modules.module_author.face;Jt.upName=m,Jt.upFace=p;}if(this.viewingSomeGroup&&Jt.groups.length){const m=Jt.groups.find(p=>p.tagid===this.groupId);m&&(m.count=this.groupMids.size);}return a}separatorsConfig={today:{added:false,content:"今日",getInsertIndex:NTe},earlier:{added:false,content:"更早",getInsertIndex:pq(-1/0,Yn().startOf("day").unix())}};handleAddSeparators(t){if(!this.config.addSeparators)return t;const n=t;{const r=this.separatorsConfig.today,{getInsertIndex:o,content:i,added:a}=r;if(!a){const l=o(t);l!==-1&&(n.splice(l,0,{api:Ye.Separator,uniqId:`${Ye.DynamicFeed}:separator:today`,content:i}),r.added=true);}}{const r=this.separatorsConfig.earlier,{getInsertIndex:o,content:i,added:a}=r;if(!a){const l=o(t);l!==-1&&(n.splice(l,0,{api:Ye.Separator,uniqId:`${Ye.DynamicFeed}:separator:earlier`,content:i}),r.added=true);}}return n}}function pq(e,t){return n=>n.findIndex(r=>{if(r.api!==Ye.DynamicFeed)return false;const o=r.modules.module_author.pub_ts;return o>=e&&o<t})}function NTe(e){const t=e.findIndex(r=>r.api===Ye.Live&&r.live_status===La.Streaming);return t!==-1?t:pq(Yn().startOf("day").unix(),Yn().endOf("day").unix())(e)}const Ms=20,qh="ml-30px inline-flex items-center text-15px [&_svg]:mr-5px [&_svg]:mt--1px first:ml-0";class gq{constructor(t,n,r){this.collectionId=t,this.addSeparator=n,this.itemsOrder=r;}get hasMore(){return this.addSeparator&&!this.separatorAdded||!this.loaded?true:!!this.bufferQueue.length}loaded=false;bufferQueue=[];separatorAdded=false;get separator(){return {api:Ye.Separator,uniqId:`${Ye.Fav}:collection:separator:${this.collectionId}`,content:x(PTe,{service:this})}}state=zn({firstBvid:void 0,info:void 0});async loadMore(t){if(!this.hasMore)return;if(this.addSeparator&&!this.separatorAdded)return this.separatorAdded=true,[this.separator];if(!this.loaded){const r=await f3e(this.collectionId,1),o=r?.medias||[],i=r?.info;await Vp(()=>this.loadUserAvatarFromSpaceAccInfo(o,t));let a=o.map(u=>({...u,api:Ye.Fav,uniqId:`${Ye.Fav}:collection:${this.collectionId}:${u.bvid}`,collection:r.info,from:"fav-collection"}));[Dt.PubTimeDesc,Dt.PubTimeAsc,Dt.Shuffle].includes(this.itemsOrder)&&(a=Y3(a,Dt.PubTimeDesc),a.forEach((u,d,m)=>{u.vol=m.length-d,u.volTooltip=F(ze,{children:["按投稿时间 Vol.",u.vol]});})),a=Y3(a,this.itemsOrder),this.bufferQueue=a,this.loaded=true,this.state.firstBvid=a[0]?.bvid,this.state.info=ef(i),pn.selectedFavCollectionDetailInfo=ef(i);}this.itemsOrder===Dt.Shuffle&&(this.bufferQueue=Si(this.bufferQueue));let n;return [n,this.bufferQueue]=[this.bufferQueue.slice(0,Ms),this.bufferQueue.slice(Ms)],n}async loadUserAvatarFromSpaceAccInfo(t,n){if(!t.length)return;const r=WX(t,a=>a.upper.mid),o=Object.entries(r).map(([a,l])=>({mid:a,count:l})),i=xs(o,[a=>a.count],["desc"]).slice(0,3).map(a=>a.mid);await Promise.all(i.map(async a=>{if(n?.aborted)return;const u=(await QA(a))?.face;u&&t.filter(d=>d.upper.mid.toString()===a).forEach(d=>{d.upper.face||=u;});}));}get extraTabbarView(){return x(l6,{})}}function PTe({service:e}){const{firstBvid:t,info:n}=bt(e.state);return F(ze,{children:[x(fn,{title:F(ze,{children:["UP: ",n?.upper.name," ",x("br",{}),"简介: ",n?.intro||"无"]}),children:F(Bp,{href:KW(e.collectionId),className:qh,children:[x(No,{className:"size-16px"}),"去个人空间查看合集: ",n?.title]})}),t&&F(Bp,{href:t3e(t),className:qh,children:[x(hg,{className:"size-16px"}),"播放全部"]})]})}function ITe({folderId:e,currentFolderTitle:t,onClosePopover:n}){const r=ga(l=>c3e(e,l),{manual:true}),[o,i]=f.useState(t),a=Je(async()=>{const l=o.trim();if(!l)return rn("收藏夹名称不能为空!");if(l===t)return rn("无变更!");if(!await r.runAsync(l))return;n();const d=pn.folders.find(m=>m.id===e);d&&(d.title=o);});return F("div",{className:"flex flex-col gap-y-2",children:[x("div",{children:"重命名收藏夹"}),x(Yi,{placeholder:"收藏夹名称",value:o,onChange:l=>i(l.target.value),onPressEnter:a}),F("div",{className:"flex justify-end gap-x-2",children:[x(st,{onClick:n,children:"取消"}),x(st,{type:"primary",loading:r.loading,onClick:a,disabled:!o||o===t,children:"确定"})]})]})}function OTe({service:e}){const[t,n]=f.useState(false),{viewingSomeFolder:r}=bt(pn),{id:o,attr:i,title:a}=e.entry,l=bt(pn.folders).find(d=>d.id===o)?.title??a,u="size-16px";return F(ze,{children:[F(Bp,{href:OA(o,i),className:qh,children:[x(No,{className:u}),"去个人空间查看收藏夹: ",l]}),F(Bp,{href:e3e(o),className:qh,children:[x(hg,{className:u}),"播放全部"]}),r&&x(Zo,{open:t,onOpenChange:n,trigger:"click",content:x(ITe,{folderId:o,currentFolderTitle:l,onClosePopover:()=>n(false)}),children:F(st,{className:X(qh,"gap-x-1 px-0 text-15px!"),type:"link",children:[x(eA,{className:u}),"重命名"]})})]})}const DTe=[Dt.FavTimeDesc,Dt.PlayCountDesc,Dt.PubTimeDesc];function eB(e){return DTe.includes(e)}const vq=Jf("fav-folder-all-items");async function h0(e){await vq.delete(e);}class bq{constructor(t,n,r){if(this.folderId=t,this.addSeparator=n,this.itemsOrder=r,this.itemsOrder===Dt.Initial)throw new Error("this should not happen!");eB(this.itemsOrder)?this.needLoadAll=false:this.needLoadAll=true;}needLoadAll;get hasMore(){return this.addSeparator&&!this.separatorAdded?true:this.needLoadAll?this.allItemsLoaded?!!this.bufferQueue.length:true:this.innerService?this.innerService.hasMore:true}separatorAdded=false;get separator(){return this.assertInnerService(),{api:Ye.Separator,uniqId:`${Ye.Fav}:folder:separator:${this.folderId}`,content:x(OTe,{service:this.innerService})}}entry;innerService;assertInnerService(){Ro(this.innerService,"this.innerService should not be undefined"),Ro(this.entry,"this.entry should not be undefined");}async createService(){if(this.innerService)return;await c6();const t=Fr(pn.folders).find(n=>n.id===this.folderId);Ro(t,`favStore.favFolders should have this entry[fid=${this.folderId}]`),this.entry=t,eB(this.itemsOrder)?this.innerService=new Zd(t,this.itemsOrder):this.innerService=new Zd(t);}async loadMore(t){if(this.innerService||await this.createService(),!!this.hasMore){if(this.addSeparator&&!this.separatorAdded)return this.separatorAdded=true,[this.separator];if(this.needLoadAll){this.allItemsLoaded||await this.loadAllItems(t),this.itemsOrder===Dt.Shuffle&&(this.bufferQueue=Si(this.bufferQueue));const n=this.bufferQueue.slice(0,Ms);return this.bufferQueue=this.bufferQueue.slice(Ms),n}else {const n=await this.innerService?.loadMore(t);return this.runSideEffects(),n}}}allItemsLoaded=false;bufferQueue=[];async loadAllItems(t){const n=await this.fetchAllItems(t);this.bufferQueue=Y3(n,this.itemsOrder),this.allItemsLoaded=true,this.runSideEffects();}_fetchAllItems=async t=>{this.assertInnerService();const n=[];for(;this.innerService.hasMore&&!t.aborted;){const r=await this.innerService.loadMore(t)||[];n.push(...r);}return n};_fetchAllItemsWithCache=Ru({fn:this._fetchAllItems,tableName:vq,generateKey:()=>`${this.folderId}`,ttl:lo("5min")});fetchAllItems=t=>(this.assertInnerService(),this.entry.media_count>Zd.PAGE_SIZE*3?this._fetchAllItemsWithCache(t):this._fetchAllItems(t));runSideEffects(){this.assertInnerService(),typeof this.innerService.info?.media_count=="number"&&Bq(this.folderId,this.innerService.info.media_count);}get extraTabbarView(){return x(l6,{})}}class Zd{constructor(t,n=Dt.FavTimeDesc){this.entry=t,this.itemsOrder=n,this.hasMore=t.media_count>0;}static PAGE_SIZE=20;hasMore;info;page=0;async loadMore(t){if(!this.hasMore)return;const n={[Dt.FavTimeDesc]:"mtime",[Dt.PlayCountDesc]:"view",[Dt.PubTimeDesc]:"pubtime"}[this.itemsOrder],o=(await Qt.get("/x/v3/fav/resource/list",{params:{media_id:this.entry.id,pn:this.page+1,ps:Zd.PAGE_SIZE,keyword:"",order:n,type:"0",tid:"0",platform:"web"}})).data;if(!jn(o)){rn(o.message||Ef);return}this.page++,this.hasMore=o.data.has_more,this.info=o.data.info;let i=o.data.medias||[];return i=i.filter(a=>a.title!=="已失效视频"),i.map(a=>({...a,from:"fav-folder",folder:this.info,api:Ye.Fav,uniqId:`${Ye.Fav}:folder:${this.info?.id||this.entry.id}:${a.bvid}`}))}}class _Te{constructor(t,n,r){if(this.addSeparator=t,this.itemsOrder=n,this.excludedFolderIds=r,![Dt.Initial,Dt.Shuffle].includes(this.itemsOrder))throw new Error("invalid items order")}get useShuffle(){return this.itemsOrder===Dt.Shuffle}shuffleBufferQueue=[];get hasMoreInService(){return this.serviceCreated?this.allServices.some(t=>t.hasMore):true}get hasMore(){return this.useShuffle?!!this.shuffleBufferQueue.length||this.hasMoreInService:this.hasMoreInService}get extraTabbarView(){return F(ze,{children:[x(l6,{}),x(ORe,{allFavFolderServices:this.allFolderServices,state:this.state})]})}async loadMore(t){if(this.serviceCreated||await this.createServices(),!this.hasMore)return;if(!this.useShuffle)return this.allServices.find(o=>o.hasMore)?.loadMore(t);if(this.shuffleBufferQueue.length<Ms)for(;this.hasMoreInService&&this.shuffleBufferQueue.length<Ms*3;){const i=this.allServices.filter(u=>u.hasMore),a=Si(i).slice(0,6),l=(await Wl(a,async u=>await u.loadMore(t)||[],2)).flat().filter(u=>u.api!==Ye.Separator);this.shuffleBufferQueue=Si([...this.shuffleBufferQueue,...Si(l)]);}const n=this.shuffleBufferQueue.slice(0,Ms);return this.shuffleBufferQueue=this.shuffleBufferQueue.slice(Ms),n}allFolderServices=[];state=zn({totalCountInFavFolders:0});serviceCreated=false;allServices=[];async createServices(){await c6();const{folders:t,collections:n}=ef(Fr(pn));this.allFolderServices=t.map(r=>new Zd(r)),this.state.totalCountInFavFolders=t.filter(r=>!this.excludedFolderIds.includes(r.id.toString())).reduce((r,o)=>r+o.media_count,0);{const r=t.filter(i=>!this.excludedFolderIds.includes(i.id.toString()));let o=this.itemsOrder;o===Dt.Initial&&(o=Dt.FavTimeDesc),this.allServices.push(...r.map(i=>new bq(i.id,this.addSeparator,o)));}this.allServices.push(...n.map(r=>new gq(r.id,this.addSeparator,this.itemsOrder))),this.serviceCreated=true;}}function o6(){const e=Fr(pn);return {selectedKey:e.selectedKey,viewingAll:e.viewingAll,viewingSomeFolder:e.viewingSomeFolder,viewingSomeCollection:e.viewingSomeCollection,itemsOrder:s6(e.selectedKey,e.savedOrderMap),selectedFavFolderId:e.selectedFavFolderId,selectedFavCollectionId:e.selectedFavCollectionId,addSeparator:at.fav.addSeparator,excludedFolderIds:at.fav.excludedFolderIds}}class oS extends Gs{constructor(t){super(oS.PAGE_SIZE),this.config=t;const{viewingAll:n,viewingSomeFolder:r,viewingSomeCollection:o}=this.config;if(n)this.innerService=new _Te(this.config.addSeparator,this.config.itemsOrder,this.config.excludedFolderIds);else if(r)this.innerService=new bq(this.config.selectedFavFolderId,this.config.addSeparator,this.config.itemsOrder);else if(o)this.innerService=new gq(this.config.selectedFavCollectionId,this.config.addSeparator,this.config.itemsOrder);else throw new Error("unexpected case!")}static PAGE_SIZE=Ms;innerService;get tabbarView(){const{tabbarView:t,extraTabbarView:n}=this.innerService;return t||x(IRe,{extraContent:n})}sidebarView=x(DRe,{});get hasMoreExceptQueue(){return this.innerService.hasMore}fetchMore(t){return this.innerService.loadMore(t)}decreaseTotal(){this.config.viewingAll?this.innerService.state.totalCountInFavFolders-=1:this.config.viewingSomeFolder&&this.config.selectedFavFolderId?Bq(this.config.selectedFavFolderId,t=>t-1):this.config.viewingSomeCollection&&this.config.selectedFavCollectionId;}}async function i6({asc:e=false,searchText:t="",abortSignal:n,extraParams:r}={}){const i=(await Qt.get("/x/v2/history/toview/web",{signal:n,params:await T1({asc:e,key:t,viewed:0,web_location:333.881,...r})})).data;return jn(i)?{total:i.data.count,items:BTe(i.data.list||[])}:(Ko("getAllWatchlaterItems error %s, fulljson %o",i.message,i),{err:i.message})}function BTe(e){return e.filter(t=>!(t.title==="以下为更早添加的视频"&&t.aid===0&&t.bvid===""&&t.add_at===0))}async function LTe(e){const t=new FormData;t.append("resources",e.join(",")),t.append("csrf",oc());const n=await T1({}),o=(await Qt.post("/x/v2/history/toview/v2/dels",t,{params:n})).data;return jn(o)?true:(rn(o?.message||"出错了"),false)}const yq=()=>Yn().subtract(2,"days").unix(),Sq="最近 48 小时内",sM={api:Ye.Separator,uniqId:`${Ye.Watchlater}:separator:recent`,content:F(ze,{children:["近期",x(pr,{children:Sq})]})},lM={api:Ye.Separator,uniqId:`${Ye.Watchlater}:separator:earlier`,content:"更早"},Kh=zn({searchText:void 0});function zTe({service:e}){const{watchlaterAddSeparator:t,watchlaterItemsOrder:n,watchlaterUseNormalVideoUrl:r}=Ut(),o=co(),{searchText:i}=bt(Kh,{sync:true}),a=jMe(),{recSharedEmitter:l}=Ei();Ps(()=>{(async()=>(await gn(100),o()))();},[t,n,r]);const{total:u}=bt(e.state),d=i?`共 ${u} 条搜索结果`:`共 ${u} 个视频`,m=typeof u=="number"&&x(vo,{color:"success",style:{marginRight:0,marginTop:1,cursor:"pointer"},title:d,onClick:()=>{rn(`稍后再看: ${d}`);},children:u});return F("div",{className:"flex items-center gap-x-12px",children:[x(FTe,{}),x(Yi.Search,{allowClear:true,placeholder:"搜索稍后再看",style:{width:180},value:i,onChange:p=>Kh.searchText=p.target.value,onSearch:p=>{Kh.searchText=p,o();}}),m,a&&x(fn,{arrow:false,title:"移除稍后再看 (多选)",children:x(st,{className:"icon-only-round-button",onClick:()=>UTe(l),children:x(Uf,{})})}),x(Ng,{})]})}const Cq={[bo.AddTimeDesc]:{icon:x(P3,{}),label:"最近添加",helpInfo:"按添加时间倒序"},[bo.AddTimeAsc]:{icon:x(N3,{}),label:"最早添加",helpInfo:"按添加时间增序"},[bo.Shuffle]:{icon:x(Wj,{}),label:"随机顺序",helpInfo:`随机但不包括近期添加的稍后再看, 近期指: ${Sq}`}},xq=Object.values(bo),kTe=x("div",{className:"grid grid-cols-[repeat(2,max-content)] gap-x-1 gap-y-0 line-height-normal",children:xq.map(e=>{const{icon:t,label:n,helpInfo:r}=Cq[e];return F(ze,{children:[F("div",{className:"flex-center gap-x-1",children:[t,n,": "]}),x("div",{children:r})]})})});function FTe(){const e=co(),{ref:t,getPopupContainer:n}=Tu(),{watchlaterItemsOrder:r}=Ut(),{searchText:o}=bt(Kh),i=!!o;return x(ZA,{disabled:i,value:i?bo.AddTimeDesc:r,onChange:a=>{at.watchlaterItemsOrder=a,e();},list:xq,listDisplayConfig:Cq,$ref:t,dropdownProps:{getPopupContainer:n},extraHelpInfo:kTe})}const yu=zn({updatedAt:0,bvidSet:Rr()});function HTe(e){const t=bt(yu).bvidSet;return !!e&&t.has(e)}function wq(e){yu.updatedAt=Date.now(),yu.bvidSet=Rr(e);}function VTe(e,t){yu.updatedAt&&yu.bvidSet.add(t);}async function jTe(){if(!A1()||!Jo())return;const{items:e=[]}=await i6();e.length&&wq(e.map(t=>t.bvid));}_s&&(async()=>(await I1(),await qG(jTe,{retries:3,onFailedAttempt(e){Ko(`Try updateWatchlaterState ${e.attemptNumber} failed. There are ${e.retriesLeft} retries left`);}})))();async function UTe(e){const t=Z1().map(a=>({item:a,cardData:em(a)})).filter(a=>a.cardData.avid).map(a=>[a.cardData.avid,a.item.uniqId,a.cardData.title]).filter(Boolean),n=t.map(a=>a[0]),r=t.map(a=>a[1]),o=t.map(a=>a[2]);if(!n.length)return rn("没有选中的视频");await LTe(n)&&e.emit("remove-cards",[r,o]);}class Lp extends Gs{constructor(t,n,r,o){super(Lp.PAGE_SIZE),this.searchText=o,this.innerService=t===bo.Shuffle&&!this.searchText?new tB(n,r):new WTe(t,n,this.searchText);}static PAGE_SIZE=10;sidebarView=void 0;innerService;get hasMoreExceptQueue(){return this.innerService.hasMore}fetchMore(t){return this.innerService.loadMore(t)}get tabbarView(){return x(zTe,{service:this})}get state(){return this.innerService.state}decreaseTotal(){this.innerService.state.total!==void 0&&this.innerService.state.total--;}getServiceSnapshot(){return {bvidIndexMap:this.innerService instanceof tB?this.innerService.currentBvidIndexMap:void 0}}}function $q(e){return {...e,api:Ye.Watchlater,uniqId:`${Ye.Watchlater}:${e.bvid}`}}function Eq(e){throw rn(`获取稍后再看失败: ${e}`),new Error(`获取稍后再看失败: ${e}`,{cause:e})}class tB{constructor(t,n){this.addSeparator=t,n?.size?(this.keepOrder=true,this.prevBvidIndexMap=n):this.keepOrder=false;}hasMore=true;state=zn({total:void 0});keepOrder;prevBvidIndexMap;async loadMore(t){if(!this.hasMore)return;const n=await this.fetch(t);return this.hasMore=false,n}currentBvidIndexMap;async fetch(t){const{items:n=[],err:r}=await i6({asc:false,searchText:void 0,abortSignal:t});r!==void 0&&Eq(r),wq(n.map(u=>u.bvid).filter(Boolean));const o=n.map($q),i=yq(),a=o.findIndex(u=>u.add_at<i);let l=o;if(a!==-1){const u=o.slice(0,a);let d=o.slice(a);this.keepOrder&&this.prevBvidIndexMap?.size?d=xs(d,[m=>this.prevBvidIndexMap?.get(m.bvid)??-1],["asc"]):d=Si(d),l=[!!u.length&&this.addSeparator&&sM,...u,!!d.length&&this.addSeparator&&lM,...d].filter(Boolean);}return this.state.total=n.length,this.currentBvidIndexMap=new Map(l.filter(u=>u.api!==Ye.Separator).map((u,d)=>[u.bvid,d])),l}}class WTe{constructor(t,n,r){this.order=t,this.addSeparator=n,this.searchText=r,this.searchText||Ro(t!==bo.Shuffle,"shuffle not supported in NormalOrderService");}firstPageLoaded=false;state=zn({total:void 0});hasMore=true;page=1;async loadMore(){if(!this.hasMore)return;const t=await i6({asc:this.order===bo.AddTimeAsc,searchText:this.searchText,extraParams:{need_split:"true",ps:20,pn:this.page}});if(t.err!==void 0){this.hasMore=false,Eq(t.err);return}const{items:n,total:r}=t,o=Math.ceil(r/20);this.firstPageLoaded=true,this.state.total=t.total,this.hasMore=this.page<o,this.page++,n.forEach(a=>{a.bvid&&VTe("add",a.bvid);});const i=n.map($q);return this.insertSeparator(i)}recentSeparatorInserted=false;earlierSeparatorInserted=false;insertSeparator(t){if(!this.addSeparator)return t;let n=[...t];const r=yq(),o=t.some(a=>a.add_at<r),i=t.some(a=>a.add_at>=r);if(this.order===bo.AddTimeAsc){if(!this.earlierSeparatorInserted&&o&&(n=[lM,...n],this.earlierSeparatorInserted=true),!this.recentSeparatorInserted&&i){const a=n.findIndex(l=>l.api===Ye.Watchlater&&l.add_at>=r);n=[...n.slice(0,a),sM,...n.slice(a)],this.recentSeparatorInserted=true;}}else if(!this.recentSeparatorInserted&&i&&(n=[sM,...t],this.recentSeparatorInserted=true),!this.earlierSeparatorInserted&&o){const a=n.findIndex(l=>l.api===Ye.Watchlater&&l.add_at<r);n=[...n.slice(0,a),lM,...n.slice(a)],this.earlierSeparatorInserted=true;}return n}}function GTe(){return {addOtherTabContents:yg().appRecommend.addOtherTabContents}}const Mq=e=>x(Pt,{configPath:"appRecommend.addOtherTabContents",label:"显示来自其他 Tab 的内容",tooltip:F(ze,{children:["显示来自其他 Tab 的内容 ",x("br",{}),"如动态 / 收藏 / 稍后再看 ",x("br",{}),"但是: 刷新时间会更长"]}),extraAction:async()=>{await gn(100),e?.();}});function qTe(){const e=co(),{hidingTabKeys:t}=Ut(),n=t.includes(nt.Liked);return F("div",{className:"flex items-center gap-x-10px",children:[Mq(e),n&&x(fn,{title:"查看「我」点赞的视频",children:x("a",{href:`/?${XG.Tab}=${nt.Liked}`,target:"_blank",children:x(jj,{className:"size-18px align-top"})})})]})}class Jd extends Gs{constructor(t){super(Jd.PAGE_SIZE),this.config=t,this.innerService=new KTe,this.allServices=[this.innerService],this.initOtherTabServices();}static PAGE_SIZE=20;tabbarView=x(qTe,{});sidebarView=void 0;innerService;allServices=[];otherTabServices=[];initOtherTabServices(){if(!A1()||!this.config.addOtherTabContents)return;let t,n,r;{const a=bG();a.upMid=void 0,a.selectedGroupId=void 0;const l=r6(a);Object.assign(l,{showLiveInDynamicFeed:true,whenViewAllEnableHideSomeContents:false,filterCacheEnabled:false}),t=new rS(l);}{const a=Object.assign(o6(),{selectedKey:"all",viewingAll:true,viewingSomeFolder:false,viewingSomeCollection:false,itemsOrder:Dt.Shuffle,selectedFavFolderId:void 0,selectedFavCollectionId:void 0,addSeparator:false});n=new oS(a);}r=new Lp(bo.AddTimeDesc,false),this.otherTabServices=[t,n,r];const o=[],i=7/3;o.push(...this.otherTabServices),CQ(Math.round(i*this.otherTabServices.length),()=>o.push(this.innerService)),this.allServices=Si(o);}get hasMore(){return !!this.qs.bufferQueue.length||this.innerService.hasMore||this.otherTabServices.some(t=>t.hasMore)}hasMoreExceptQueue=true;fetchMore(t){return this.config.addOtherTabContents?this._fetchWithOtherTabsChecked(t):this._fetchFromApi(t,2)}async _fetchWithOtherTabsChecked(t){let n=[];for(;this.hasMore&&n.length<Jd.PAGE_SIZE*3;){const r=this.allServices.filter(a=>a.hasMore);if(!r.length)break;const o=Si(r).slice(0,3),i=(await Promise.all(o.map(async a=>await a.loadMore(t)||[]))).flat().filter(a=>a.api!==Ye.Separator);n.push(...i),n=Si(n);}return n}_fetchFromApi(t,n){return this.innerService.getRecommendTimes(t,n)}async preloadTimesFromApiIfNeeded(t,n){this.qs.bufferQueue.length<Jd.PAGE_SIZE&&this.qs.bufferQueue.push(...await this._fetchFromApi(t,n));}}class KTe{static PAGE_SIZE=16;hasMore=true;async getRecommend(){const t=await vg.get(`${$L}/x/v2/feed/index`,{timeout:2e4,responseType:"json",params:{build:"1",mobi_app:"iphone",device:"pad",idx:Math.floor(Date.now()/1e3)+YX(1e3)}}),n=t.data;if(!n.data)throw new Error("Request fail with none invalid json",{cause:{type:"invalid-json",statusCode:t.status,json:n}});return n?.data?.items||[]}loadMore(t,n=2){return this.getRecommendTimes(t,n)}async getRecommendTimes(t,n){let r=(await Promise.all(HB(n).map(()=>this.getRecommend()))).flat();return r=r.filter(i=>!(i.card_goto?.includes("ad")||i.goto?.includes("ad")||i.ad_info||i.card_goto==="banner"||i.goto==="av"&&i.player_args===void 0)),r=Kl(r,i=>i.param),r.map(i=>({...i,api:Ye.AppRecommend,uniqId:`${Ye.AppRecommend}:${i.param}`}))}}async function YTe(e,t){const{bvid:n,goto:r,recommendReason:o}=t,i=r==="av";return Sf(e)&&i&&!!n&&t6(o)?(await ZW(n))?.pubdate:void 0}async function XTe(e=20,t=1){const n=Jo();return (await vg.get(`https://app.bilibili.com/x/v2/space/likearc?mid=${n}`,{responseType:"json",params:{...Rxe,vmid:n,ps:e,pn:t}})).data}function QTe({service:e}){const{count:t}=e.useStore();return Number.isFinite(t)?F(ze,{children:[x(fn,{title:`共 ${t} 个视频`,children:x(vo,{color:"success",variant:"outlined",className:"cursor-pointer",children:t})}),x(Ng,{})]}):null}class Py extends Gs{static PAGE_SIZE=20;constructor(){super(Py.PAGE_SIZE);}tabbarView=x(QTe,{service:this});sidebarView;get hasMoreExceptQueue(){return this.errorJson?false:Py.PAGE_SIZE*this.pn<this.store.count}pn=0;errorJson=void 0;store=zn({count:1/0});useStore=()=>bt(this.store);showErrorNotification(t){ca.error({key:"LikedRecService:error",title:"获取喜欢列表失败",...t});}async fetchMore(t){if(!at.accessKey)throw new sA;ca.destroy("LikedRecService:error");const n=await XTe(this.qs.ps,this.pn+1);if(!jn(n))throw this.errorJson=n,this.showErrorNotification({title:"获取喜欢列表失败",description:n.message}),new Error("Request fail with none invalid json",{cause:n});const{count:r,item:o}=n.data,[i,a]=await Vp(()=>Promise.all(o.map(u=>u.state?ZW(LA(u.param)):void 0))),l=o.map((u,d)=>({...u,api:Ye.Liked,uniqId:`${Ye.Liked}:${u.param}`,videoDetail:a?.[d]}));return this.pn++,this.store.count=r,l}}const ZTe=ao.extend("modules:rec-services:pc");class iu extends Gs{constructor(t){super(iu.PAGE_SIZE),this.isKeepFollowOnly=t;}static PAGE_SIZE=30;tabbarView=void 0;sidebarView=void 0;hasMoreExceptQueue=true;fetchMore(t){const n=this.isKeepFollowOnly?5:2;return this.getRecommendTimes(t,n)}async preloadTimesFromApiIfNeeded(t,n){this.qs.bufferQueue.length<iu.PAGE_SIZE&&this.qs.bufferQueue.push(...await this.getRecommendTimes(t,n));}async getRecommendTimes(t,n){let r=(await Promise.all(HB(n).map(()=>this.getRecommend(t)))).flat();const o=new Set([ws.AV,ws.Live,ws.Ad]);r.forEach(l=>{o.has(l.goto)||ZTe("uknown goto from API: %s %o",l.goto,l);});const i=new Set([ws.AV]);return r=r.filter(l=>i.has(l.goto)),r=Kl(r,l=>l.id),r.forEach(l=>{l.rcmd_reason?.reason_type===1&&(l.rcmd_reason.content||="已关注");}),r.map(l=>({...l,uniqId:`${Ye.PcRecommend}:${l.bvid||l.room_info?.room_id||crypto.randomUUID()}`,api:Ye.PcRecommend}))}page=0;async getRecommend(t){const n=++this.page,r="/x/web-interface/wbi/index/top/feed/rcmd",o={fresh_type:8,fresh_idx_1h:n,fresh_idx:n,ps:iu.PAGE_SIZE,web_location:1430650,feed_version:"V8",homepage_ver:1},a=(await Qt.get(r,{signal:t,params:o})).data;return !jn(a)&&a.code===-62011&&a.message==="暂时没有更多内容了"?(this.hasMoreExceptQueue=false,[]):(a.data?.item||rn(a.message||"API 请求没有返回结果"),a.data?.item||[])}}const JTe=[nt.KeepFollowOnly,nt.PcRecommend,nt.AppRecommend];function zp(e){return JTe.includes(e)}const eAe={[nt.AppRecommend]:()=>new Jd(GTe()),[nt.PcRecommend]:()=>new iu(false),[nt.KeepFollowOnly]:()=>new iu(true),[nt.DynamicFeed]:()=>new rS(r6()),[nt.Watchlater]:({existingService:e})=>{const{watchlaterAddSeparator:t,watchlaterItemsOrder:n}=at,r=e&&e instanceof Lp?e.getServiceSnapshot().bvidIndexMap:void 0;return new Lp(n,t,r,Fr(Kh).searchText)},[nt.Fav]:()=>new oS(o6()),[nt.Hot]:()=>new HMe,[nt.Live]:()=>new Ig,[nt.SpaceUpload]:()=>new JA(lq()),[nt.Liked]:()=>new Py};function Rq(e,t){const n=e[t];return Ro(n,`serviceRegistry[tab=${t}] should not be nil`),n}const Tq=new Xo;class Aq{constructor(t){this.insideModal=t;}recSharedEmitter=new Xo;serviceRegistry={};serviceQueueMap={};store=zn({refreshing:false,refreshingTab:void 0,tabbarView:void 0,sidebarView:void 0,serviceQueueStateMap:{}});get refreshing(){return this.store.refreshing}get refreshingTab(){return this.store.refreshingTab}useStore=()=>bt(this.store);setStore=t=>{const n=["tabbarView","sidebarView"];for(const r of n){const o=t[r];typeof o=="object"&&o!==null&&(t[r]=CL(o));}Object.assign(this.store,t);};getTabServiceQueueState=t=>Fr(this.store.serviceQueueStateMap)[t];setTabServiceQueueState=(t,n)=>{this.store.serviceQueueStateMap[t]=n;};_calcTabBackForwardStatus=(t,n)=>{if(!zp(t)||!n||n.len<=1)return [false,false];const{len:r,cursor:o}=n;return [o>0,o<r-1]};getTabBackForwardStatus=t=>this._calcTabBackForwardStatus(t,this.getTabServiceQueueState(t));useTabBackForwardStatus=t=>{const n=bt(this.store.serviceQueueStateMap)[t];return f.useMemo(()=>this._calcTabBackForwardStatus(t,n),[t,n])}}const a6=f.createContext(new Aq);function Nq(...e){return z1(()=>new Aq(...e),[])}function Ei(){return f.useContext(a6)}function co(){const{recSharedEmitter:e}=Ei();return xg(t=>e.emit("refresh",t))}const Sl="size-16px",tAe={[Dt.Initial]:{icon:x(aCe,{className:Sl}),label:"初始顺序"},[Dt.Shuffle]:{icon:x(Wj,{className:Sl}),label:"随机顺序"},[Dt.PubTimeDesc]:{icon:x(P3,{className:Sl}),label:"最新投稿"},[Dt.PubTimeAsc]:{icon:x(N3,{className:Sl}),label:"最早投稿"},[Dt.PlayCountDesc]:{icon:x(hg,{className:Sl}),label:"最多播放"},[Dt.CollectCountDesc]:{icon:x(pf,{className:X(Sl)}),label:"最多收藏"},[Dt.FavTimeDesc]:{icon:x(P3,{className:X(Sl)}),label:"最近收藏"},[Dt.FavTimeAsc]:{icon:x(N3,{className:X(Sl)}),label:"最早收藏"}},nAe={all:[Dt.Initial,Dt.Shuffle],"fav-folder":[Dt.FavTimeDesc,Dt.PubTimeDesc,Dt.PlayCountDesc,Dt.CollectCountDesc,"divider",Dt.FavTimeAsc,Dt.PubTimeAsc,"divider",Dt.Shuffle],"fav-collection":[Dt.Initial,Dt.PubTimeDesc,Dt.PlayCountDesc,Dt.CollectCountDesc,"divider",Dt.PubTimeAsc,"divider",Dt.Shuffle]};function Pq(e){return e.split(":")[0]}function Iq(e){const t=Pq(e);return nAe[t]||Object.values(Dt)}function nB(e){const t=Pq(e);return t==="fav-folder"?Dt.FavTimeDesc:t==="fav-collection"?Dt.PubTimeDesc:Dt.Initial}function s6(e,t){const n=Iq(e).filter(o=>o!=="divider"),r=t.get(e)||nB(e);return n.includes(r)?r:nB(e)}function rAe(e,t){return f.useMemo(()=>s6(e,t),[t,e])}function l6(){const e=co(),{ref:t,getPopupContainer:n}=Tu(),{selectedKey:r,savedOrderMap:o}=bt(pn),i=rAe(r,o),a=f.useMemo(()=>Iq(r),[r]);return x(ZA,{value:i,onChange:async l=>{pn.savedOrderMap.set(r,l),await gn(100),e();},list:a,listDisplayConfig:tAe,$ref:t,dropdownProps:{getPopupContainer:n}})}const oAe=ao.extend("modules:rec-services:fav:store");var Iy=(e=>(e.CollectionIdFull="fav-collection-id",e.CollectionId="fav-cid",e.FolderIdFull="fav-folder-id",e.FolderId="fav-fid",e))(Iy||{});const Oq=e=>{if(!e)return;const t=Number(e);if(!Number.isNaN(t))return t},Oy=new URLSearchParams(location.search),Dq=Oq(Oy.get("fav-collection-id")??Oy.get("fav-cid")),_q=Oq(Oy.get("fav-folder-id")??Oy.get("fav-fid")),Dy=_s&&(typeof _q=="number"||typeof Dq=="number"),pn=zn({folders:[],foldersUpdateAt:0,selectedFavFolderId:_q,get selectedFavFolder(){if(typeof this.selectedFavFolderId=="number")return this.folders.find(e=>e.id===this.selectedFavFolderId)},collections:[],collectionsUpdateAt:0,selectedFavCollectionId:Dq,selectedFavCollectionDetailInfo:void 0,get selectedFavCollection(){if(typeof this.selectedFavCollectionId=="number")return this.collections.find(e=>e.id===this.selectedFavCollectionId)},get selectedKey(){let e,t;if(this.selectedFavFolderId!==void 0)e="fav-folder",t=this.selectedFavFolderId;else if(this.selectedFavCollectionId!==void 0)e="fav-collection",t=this.selectedFavCollectionId;else return "all";return `${e}:${t}`},get selectedLabel(){if(this.selectedFavFolder)return `${this.selectedFavFolder.title} (${this.selectedFavFolder.media_count})`;if(typeof this.selectedFavCollectionId=="number"){if(this.selectedFavCollection)return `${this.selectedFavCollection.title} (${this.selectedFavCollection.media_count})`;const e=this.selectedFavCollectionDetailInfo;return e?.id===this.selectedFavCollectionId?`${e.title} (${e.media_count})`:void 0}return "全部"},savedOrderMap:(await( kH("fav-saved-order"))).map,get usingShuffle(){return s6(this.selectedKey,this.savedOrderMap)===Dt.Shuffle},get viewingAll(){return this.selectedKey==="all"},get viewingSomeFolder(){return typeof this.selectedFavFolderId=="number"},get viewingSomeCollection(){return typeof this.selectedFavCollectionId=="number"}});function Bq(e,t){const n=pn.folders.find(o=>o.id===e);if(!n)return;const r=typeof t=="function"?t(n.media_count):t;r!==n.media_count&&(n.media_count=r,oAe("update folder(id=%s title=%s) media_count to %s",n.id,n.title,r));}function c6(e=false){return Promise.all([u6(e),sAe(e)])}const iAe=Hs(async()=>{const e=await a3e();pn.folders=e,pn.foldersUpdateAt=Date.now();});async function u6(e=false){if(!e){const{folders:t,foldersUpdateAt:n}=pn;if(t.length&&n&&Date.now()-n<lo("5min"))return}return iAe()}const aAe=Hs(async()=>{const e=await d3e();pn.collections=e,pn.collectionsUpdateAt=Date.now();});async function sAe(e=false){if(!e){const{collections:t,collectionsUpdateAt:n}=pn;if(t.length&&n&&Date.now()-n<lo("5min"))return}return aAe()}Dy&&uT(pn,"selectedLabel",()=>{pn.selectedLabel&&mA(pn.selectedLabel);});lAe();async function lAe(){if(!(_s||GW)||Dy)return;const e="fav-store",t=["selectedFavFolderId","selectedFavCollectionId","folders"],n=await GM.getValue(e);if(n)for(const o of t)Ha(n[o])||(pn[o]=n[o]);const r=cT(1);LH(pn,t,o=>{if(Dy)return;const i=su(o,t);r(async()=>{await GM.setValue(e,i);});});}const tm={[nt.AppRecommend]:{icon:x(lCe,{className:"size-18px"}),label:"推荐",desc:"使用 Bilibili App 端推荐 API",anonymousUsage:true},[nt.PcRecommend]:{icon:x(cCe,{className:"size-18px"}),label:"推荐",desc:"使用新版首页顶部推荐 API",anonymousUsage:true},[nt.KeepFollowOnly]:{icon:x(uCe,{className:"size-18px"}),label:"已关注",desc:"从PC端推荐中筛选出「已关注」,可能比较慢; 关注的UP更新在动态~"},[nt.DynamicFeed]:{icon:x(hy,{className:"size-18px"}),label:"动态",desc:"视频投稿动态",swr:true},[nt.Watchlater]:{icon:x(nA,{className:"size-17px [&_.circle]:stroke-current"}),label:"稍后再看",desc:"「我」的稍后再看",swr:true},[nt.Fav]:{icon:x(pf,{className:"mt--1px size-16px"}),label:"收藏",desc:"「我」的收藏",get swr(){return !pn.usingShuffle}},[nt.Hot]:{icon:x(fCe,{className:"size-16px"}),label:"热门",desc:"各个领域中新奇好玩的优质内容都在这里~",anonymousUsage:true,get swr(){return !jG()}},[nt.Live]:{icon:x(tA,{className:"size-16px"}),label:"直播",desc:"直播~",swr:true},[nt.SpaceUpload]:{icon:x(py,{className:"size-16px"}),label:"投稿",desc:"UP 视频投稿",anonymousUsage:true,extraHelpInfo:F("div",{className:"ml-20px",children:["搜索词: 搜索相关作品 ",x("br",{}),"本地过滤词: 本地过滤搜索结果; 本地过滤词支持高级规则:",x("div",{className:"ml-20px",children:iq})]})},[nt.Liked]:{icon:x(jj,{className:"size-16px"}),label:"赞",desc:"「我」的点赞. 使用 App 端个人空间 API, 需要 access_key"}};function yi({tabKey:e,active:t,className:n}){const{icon:r}=tm[e],o=r.props,i={...o,className:ur(o.className,n),active:e===nt.Live?t:void 0};return f.cloneElement(r,i)}const Lq="你需要登录B站后使用该功能! 如已完成登录, 请刷新网页重试~";function zq(){return rn(Lq)}const cAe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",children:[x("path",{stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M24 44a19.94 19.94 0 0 0 14.142-5.858A19.94 19.94 0 0 0 44 24a19.94 19.94 0 0 0-5.858-14.142A19.94 19.94 0 0 0 24 4A19.94 19.94 0 0 0 9.858 9.858A19.94 19.94 0 0 0 4 24a19.94 19.94 0 0 0 5.858 14.142A19.94 19.94 0 0 0 24 44Z"}),x("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"M24 28.625v-4a6 6 0 1 0-6-6"}),x("path",{fill:"currentColor",fillRule:"evenodd",d:"M24 37.625a2.5 2.5 0 1 0 0-5a2.5 2.5 0 0 0 0 5",clipRule:"evenodd"})]})]}),uAe=f.forwardRef(cAe),dAe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("path",{d:"M10 12a2 2 0 1 0 4 0a2 2 0 0 0-4 0"}),x("path",{d:"M12 18q-.492 0-.97-.05Q6.271 17.452 3 12q3.6-6 9-6q5.197 0 8.727 5.558M15 18a3 3 0 1 0 6 0a3 3 0 1 0-6 0m5.2 2.2L22 22"})]})]}),fAe=f.forwardRef(dAe);function mAe(){const{grid:{useCustomGrid:e,enableForceColumn:t,forceColumnCount:n,cardMinWidth:r},style:o,enableSidebar:i,sidebarAlign:a}=Ut();oo(()=>uT(at,"pureRecommend",async m=>{await gn(0),W1();}));const l=Je(()=>{const m="v0.34.12";GM.setClipboard(m),_t.success(`已复制当前版本: ${m}`);}),u=f.useRef(null),d=k1(u);return F("div",{className:Bn.tabPane,children:[x(eo,{title:F(ze,{children:[x(yi,{tabKey:nt.AppRecommend,className:"mr-5px mt-2px size-30px"}),"access_key",F(pr,{className:"ml-5px mt-6px size-18px",IconComponent:uAe,tooltipProps:{classNames:{root:"text-14px"}},children:["App 端登录凭证, 使用情况: ",x("br",{}),x(q3,{}),F("div",{className:"group flex items-start",children:[F("div",{className:"w-55px flex flex-none items-center",children:[x(yi,{tabKey:nt.AppRecommend,className:"mr-1"})," 推荐"]}),F("ul",{className:"flex-1 list-disc pl-20px",children:[x("li",{className:"w-max",children:"获取推荐"}),x("li",{className:"w-max",children:"提交不喜欢"})]})]}),x(q3,{}),F("div",{className:"group flex items-start",children:[F("div",{className:"w-55px flex flex-none items-center",children:[x(yi,{tabKey:nt.Liked,className:"mr-1"}),"赞"]}),x("ul",{className:"w-max flex-1 list-disc pl-20px",children:x("li",{className:"w-max",children:"获取点赞列表"})})]})]})]}),children:x(PA,{})}),x(eo,{title:"开关",resetSettingPaths:["pureRecommend","multiSelect.showIcon","showBackForwardButtons"],children:F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"pureRecommend",label:"覆盖默认推荐",tooltip:F(ze,{children:[Br("覆盖默认推荐内容",`保留默认首页; 你可以从屏幕边缘找到入口面板, 使用 ${Ao} 的功能.`),"P.S 需要刷新网页"]})}),x(Pt,{configPath:"multiSelect.showIcon",label:"「多选」按钮",tooltip:"是否显示「多选」按钮"}),x(Pt,{configPath:"showBackForwardButtons",label:"「后退 / 前进」按钮",tooltip:"是否显示「后退 / 前进」按钮"})]})}),F(eo,{title:F(ze,{children:["布局",x(fn,{title:"透视",children:x(fAe,{ref:u,title:"透视",className:X("ml-1.5 size-1em cursor-pointer b-1px b-transparent rounded-md b-solid p-2px hover:b-gate-primary",{peeking:d})})})]}),resetSettingPaths:["grid.useCustomGrid","grid.cardMinWidth","grid.enableForceColumn","grid.forceColumnCount","enableSidebar","sidebarAlign","grid.gridDisplayMode","grid.twoColumnModeAlign"],children:[F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"grid.useCustomGrid",label:"使用自定义网格配置",tooltip:F(ze,{children:["网格配置指: 网格宽度, 间距, 列数等. ",x("br",{}),Br(F(ze,{children:["使用 ",Ao," 自定义网格配置: 宽度为90%; 可跟随 Bilibili-Evolved 自定义顶栏配置"]}),x(ze,{children:"使用 bili-feed4 版本B站首页默认的网格配置"}))]})}),F("div",{className:"flex items-center gap-x-1 px-6px",children:[x(fn,{title:F(ze,{children:["如果期望显示更多的列, 可以调小这个值; ",x("br",{}),"如果期望显示更少的列, 可以调大这个值; ",x("br",{}),"手动设置列数时, 这个值不起作用. ",x("br",{}),x(b_,{children:"Alt / Opt"})," + ",x(b_,{children:"上下键"}),"可调整"]}),children:x("span",{className:"cursor-pointer",children:"视频卡片最小宽度"})}),x(Qc,{disabled:!e||t,value:r,onChange:m=>{m&&(at.grid.cardMinWidth=m);},min:150,max:450,step:10,size:"small",className:"w-75px"})]}),F("div",{className:"flex items-center px-6px",children:[x(Pt,{disabled:!e,configPath:"grid.enableForceColumn",label:"手动设置列数",tooltip:x(ze,{children:"手动设置列数"})}),e&&t&&x(Qc,{value:n,onChange:m=>{m&&(at.grid.forceColumnCount=m);},min:0,max:10,step:1,size:"small",className:"w-50px"})]})]}),F("div",{className:"flex items-center gap-x-4px",children:[x(Pt,{configPath:"enableSidebar",label:"使用侧边栏",tooltip:Br("使用侧边栏(如动态 分组/UP 选择)","使用下拉面板")}),F(to.Group,{disabled:!i,buttonStyle:"solid",size:"small",value:a,onChange:m=>{at.sidebarAlign=m.target.value;},children:[x(to.Button,{value:gf.Left,className:"inline-flex-center",children:x(HW,{className:"size-16px"})}),x(to.Button,{value:gf.Right,className:"inline-flex-center",children:x(VW,{className:"size-16px"})})]})]}),F("div",{className:"flex items-center",children:["网格显示模式",x(ZEe,{className:"ml-xl"})]})]}),F(eo,{title:"样式",resetSettingPaths:["style.general.popoverBorderColorUseColorPrimary","style.pureRecommend.useStickyTabbar","style.pureRecommend.stickyTabbarShadow","grid.useCustomGrid","style.pureRecommend.useWhiteBackground","style.pureRecommend.hideTopChannel"],children:[x("div",{className:Bn.settingsLine,children:x(Pt,{configPath:"style.general.popoverBorderColorUseColorPrimary",label:"下拉面板使用主题色边框"})}),F("div",{children:[x("div",{className:"flex items-center text-1.2em",children:"全屏推荐"}),F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"style.pureRecommend.useStickyTabbar",label:"固定 Tab 栏",tooltip:Br("Tab 栏会吸附在顶栏下方","Tab 栏会随页面一起滚动")}),x(Pt,{disabled:!o.pureRecommend.useStickyTabbar,configPath:"style.pureRecommend.stickyTabbarShadow",label:"固定 Tab 栏时添加边框 & 阴影",tooltip:Br("Tab 栏在吸附状态下: 加宽, 添加边框 & 阴影","不改变")}),x(Pt,{configPath:"style.pureRecommend.useWhiteBackground",label:"使用纯白背景",tooltip:F(ze,{children:[Br("纯白背景","浅灰色背景"),"仅影响白色/浅色模式"]})}),x(Pt,{configPath:"style.pureRecommend.hideTopChannel",label:"隐藏顶部分区和Banner"})]})]})]}),x(eo,{title:F(ze,{children:["帮助",F("span",{className:"relative top-4px ml-8px mr-4px inline-flex items-center text-size-14px",children:["当前版本",F(vo,{color:"green",className:"mx-4px cursor-pointer",onClick:l,children:[Ao," v","0.34.12"]}),x(tu,{className:"size-16px cursor-pointer",onClick:l})]})]}),children:F("div",{className:Bn.settingsLine,children:[x(fn,{title:"来个 Star 支持一下",children:x(st,{href:"https://github.com/magicdawn/Bilibili-Gate",target:"_blank",children:"GitHub 主页"})}),x(st,{href:"https://afdian.com/a/magicdawn",target:"_blank",children:"「爱发电」支持"}),x(st,{href:"http://greasyfork.icu/zh-CN/scripts/443530-bilibili-gate",target:"_blank",children:"GreasyFork 主页"}),x(st,{href:"https://github.com/magicdawn/Bilibili-Gate/#%E5%BF%AB%E6%8D%B7%E9%94%AE%E8%AF%B4%E6%98%8E",target:"_blank",children:"查看可用的快捷键"}),x(st,{href:"https://github.com/magicdawn/Bilibili-Gate/releases",target:"_blank",children:"更新日志"})]})})]})}function hAe(){return iS("filter.byAuthor.keywords")}function pAe(){return aS("filter.byAuthor.keywords")}function gAe(){return iS("filter.byTitle.keywords")}function vAe(){return aS("filter.byTitle.keywords")}function bAe(){return iS("filter.dfByTitle.keywords")}function yAe(){return aS("filter.dfByTitle.keywords")}function SAe(){return iS("filter.dfHideOpusMids.keywords")}function CAe(){return aS("filter.dfHideOpusMids.keywords")}function kq(e){return `__${Ao}:${e}__`}async function iS(e){const t=kq(e),n=await N1(e);if(!n?.length)return _t.error("没有可导出数据!");GM.setClipboard(JSON.stringify({[t]:n},null,2)),_t.success("已复制到剪贴板!");}async function aS(e){const[t,n]=await Vp(()=>navigator.clipboard.readText());if(t)return _t.error("读取剪贴板失败!");if(!n)return _t.error("剪贴板内容为空!");const[r,o]=wf(()=>JSON.parse(n));if(r)return _t.error("无法解析剪贴板内容!");if(!o)return _t.error("剪贴板内容为空!");const i=kq(e),a=o?.[i];if(!a?.length)return _t.error("没有符合条件的数据!");const l=await N1(e),u=g0(a,l);if(!u.length)return _t.warning("没有可导入内容, 已全部存在!");Ua(e,{add:u}),_t.success(`已导入 ${u.length} 条数据!`);}const xAe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"m14 14l20 20m-20 0l20-20"})]}),wAe=f.forwardRef(xAe),{Search:$Ae}=Yi;var EAe={name:"1mzc5hv",styles:"color:var(--ant-color-text-disabled);background-color:var(--ant-color-bg-container-disabled);box-shadow:none;opacity:1;pointer-events:none;cursor:not-allowed"};function _y({configPath:e,searchProps:t,disabled:n,className:r,inputClassName:o,listClassName:i,renderHeader:a=kB}){const l=hU(e),u=f.useMemo(()=>ky(l).toReversed(),[l]),d=["filter.byAuthor.keywords","filter.dfHideOpusMids.keywords"].includes(e),m=x($Ae,{className:X("my-5px",o),enterButton:"添加",allowClear:true,disabled:n,size:"middle",...t,onSearch:async(S,C)=>{if(!S)return;if(new Set(await N1(e)).has(S)){_t.warning(`${S} 已存在`);return}await Ua(e,{add:[S]}),C?.target&&C.target.closest(".ant-input-wrapper")?.querySelector(".ant-input-clear-icon")?.click();}}),p=!!u.length,g=!p,b=ur(g?"rounded-lg":["max-h-250px flex flex-wrap items-start gap-x-10px gap-y-5px overflow-y-auto pr-10px",i]),y=F("div",{className:b,css:n&&EAe,children:[g&&x(Vi,{image:Vi.PRESENTED_IMAGE_SIMPLE,description:"空空如也",className:"[&.ant-empty-normal]:my-1 [&.ant-empty-normal]:py-5px"}),p&&u.map(S=>x(Fq,{tag:S.toString(),TagComponent:d?MAe:void 0,onDelete:C=>Ua(e,{remove:[C]})},S))]});return F(ze,{children:[a(m),y]})}const Fq=f.memo(function({tag:e,renderTag:t,TagComponent:n,onDelete:r,className:o,...i}){const a=f.useMemo(()=>n?x(n,{tag:e}):(t??=kB,t(e)),[n,t,e]);return F("div",{...i,className:X("relative inline-flex items-center b-1px b-gate-border rounded-5px b-solid px-6px py-2px hover:b-gate-primary hover:color-gate-primary",o),children:[a,x(wAe,{className:"ml-2px size-16px cursor-pointer text-size-12px",onClick:()=>r?.(e)})]})}),MAe=f.memo(function({tag:e}){const{mid:t,remark:n}=f.useMemo(()=>tS(e),[e]),[r,o]=f.useState(void 0);f.useEffect(()=>{(async()=>{if(!t)return;const l=await Pg(t);l&&o(l);})();},[t]);const i=t?r||n||t:e;return x(ze,{children:x(fn,{title:F(ze,{children:[!!t&&F(ze,{children:["mid: ",t," ",x("br",{})]}),!!n&&F(ze,{children:["备注: ",n," ",x("br",{}),n===r&&F(ze,{children:['P.S "备注" 与 "用户昵称" 相同, 是之前的数据, 现在你只需要填写 mid, 会自动获取昵称 ',x("br",{})]})]}),!t&&F(ze,{children:["使用用户名过滤: 用户可能改名, 建议使用 mid 过滤 ",x("br",{})]})]}),children:F("span",{className:X("inline-flex items-center justify-center",t?"cursor-pointer":"cursor-[edit]"),children:[t&&x(sG,{className:"mr-2px size-12px"}),t?x("a",{href:Tg(t),target:"_blank",style:{color:"inherit"},children:i}):i]})})})}),By={blockContainer:"b-1px b-gate-border rounded-lg b-solid p-x-2 p-y-1 light:hover:b-gate-primary"};function RAe(){return x("div",{className:X(Bn.tabPane,"pr-15px"),children:x(eo,{title:F(ze,{children:["内容过滤",x(pu,{configPath:"filter.enabled",className:"ml-10px"})]}),children:x(XR,{items:[{key:"recommend",label:F("span",{className:"inline-flex-center gap-x-1",children:[x(yi,{tabKey:nt.AppRecommend}),"推荐 / 热门",F(pr,{className:"ml-1",children:["生效范围: ",x("br",{}),"视频/图文/影视: 推荐类 Tab ",x("br",{}),"UP/标题: 推荐类、热门 Tab ",x("br",{})]})]}),children:x(TAe,{})},{key:"dynamic-feed",label:F("span",{className:"inline-flex-center gap-x-1",children:[x(yi,{tabKey:nt.DynamicFeed}),"动态",F(pr,{className:"ml-1",children:["使用场景: 关注的 UP 发布的部分内容 ",x("br",{}),F("ol",{children:[x("li",{children:"如果有规律可以按标题关键字过滤"}),x("li",{children:"没有规律可以屏蔽 UP 发布的全部图文动态"})]})]})]}),children:x(AAe,{})}]})})})}function TAe(){const{enabled:e,minDuration:t,minPlayCount:n,minDanmakuCount:r,hideGotoTypeBangumi:o,hideGotoTypePicture:i,byAuthor:a,byTitle:l}=Ut().filter,u=d=>({label:"「已关注」豁免",tooltipProps:{color:_W},tooltip:F(ze,{children:["「已关注」内容不考虑过滤条件, 总是展示",x("br",{}),'"豁免" 一词来源'," ",x("a",{target:"_blank",href:"https://github.com/magicdawn/Bilibili-Gate/issues/1#issuecomment-2197868587",children:"pilipala"})]})});return x(ze,{children:F("div",{className:"grid grid-cols-2 gap-15px",children:[F("div",{children:[x("div",{className:Bn.settingsGroupSubTitle,children:"视频"}),F("div",{className:"flex flex-col gap-y-1",children:[F("div",{className:"flex items-center",children:[x(Pt,{configPath:"filter.minDuration.enabled",label:"按视频时长过滤",tooltip:x(ze,{children:"不显示短视频"}),disabled:!e,className:"min-w-130px"}),F(Zr.Compact,{children:[x(Qc,{className:"w-130px",size:"small",min:1,step:10,value:t.value,onChange:d=>!Ha(d)&&(at.filter.minDuration.value=d),disabled:!e||!t.enabled}),x(Zr.Addon,{children:"秒"})]})]}),F("div",{className:"flex items-center",children:[x(Pt,{disabled:!e,configPath:"filter.minPlayCount.enabled",label:"按播放次数过滤",tooltip:x(ze,{children:"不显示播放次数很少的视频"}),className:"min-w-130px"}),F(Zr.Compact,{children:[x(Qc,{className:"w-130px",size:"small",min:1,step:1e3,value:n.value,onChange:d=>!Ha(d)&&(at.filter.minPlayCount.value=d),disabled:!e||!n.enabled}),x(Zr.Addon,{children:"次"})]})]}),F("div",{className:"flex items-center",children:[x(Pt,{disabled:!e,configPath:"filter.minDanmakuCount.enabled",label:"按弹幕条数过滤",tooltip:x(ze,{children:"不显示弹幕条数很少的视频"}),className:"min-w-130px"}),F(Zr.Compact,{children:[x(Qc,{className:"w-130px",size:"small",min:1,step:100,value:r.value,onChange:d=>!Ha(d)&&(at.filter.minDanmakuCount.value=d),disabled:!e||!r.enabled}),x(Zr.Addon,{children:"条"})]})]}),x(Pt,{configPath:"filter.exemptForFollowed.video",disabled:!e,...u()})]})]}),F("div",{children:[x("div",{className:Bn.settingsGroupSubTitle,children:"图文"}),x(Pt,{configPath:"filter.hideGotoTypePicture",label:"过滤图文类型推荐",disabled:!e,className:"flex",tooltip:F(ze,{children:["过滤 ",x("kbd",{children:"goto = picture"})," 的内容: 包括 (动态 & 专栏) 等"]})}),x(Pt,{className:"flex",disabled:!e||!i,configPath:"filter.exemptForFollowed.picture",...u()}),x("div",{className:X(Bn.settingsGroupSubTitle,"mt-2"),children:"影视"}),x(Pt,{configPath:"filter.hideGotoTypeBangumi",label:"过滤影视类型推荐",tooltip:F(ze,{children:["过滤 ",x("kbd",{children:"goto = bangumi"})," 的内容: 包括 (番剧 / 电影 / 国创 / 纪录片) 等"]}),disabled:!e})]}),F("div",{className:X(By.blockContainer,"col-span-full"),children:[F("div",{className:Bn.settingsGroupSubTitle,children:["UP",F(pr,{children:["根据 UP 过滤视频 ",x("br",{}),"使用 mid 屏蔽时支持备注, 格式: ",x(vo,{color:"success",children:"mid(备注)"})," 如"," ",x(vo,{color:"success",children:"8047632(B站官方)"}),x("br",{}),F("div",{className:"mt-4px flex items-start",children:[x(Uj,{className:"mt-3px"}),F("div",{className:"ml-8px flex-1",children:["B站官方支持黑名单, 对于不喜欢的 UP 可以直接拉黑 ",x("br",{}),"此脚本会拉取官方黑名单, 并无视此页开关, 总是会过滤掉 ",x("br",{}),"这里是客户端过滤, 与黑名单功能重复, 优先使用黑名单功能 ",x("br",{})]})]})]}),x(pu,{configPath:"filter.byAuthor.enabled",disabled:!e,className:"ml-10px"}),x("div",{className:"flex-1"}),x(Zo,{placement:"left",content:F("div",{className:"flex flex-col gap-x-10px gap-y-5px",children:[F(st,{onClick:NAe,children:[x(Uf,{}),"清理无效备注数据"]}),F(st,{onClick:hAe,disabled:!a.keywords.length,children:[x(Np,{}),"导出"]}),F(st,{onClick:pAe,children:[x(Pp,{}),"导入"]})]}),children:x(st,{className:"icon-only-round-button size-26px",children:x(Op,{className:"size-16px"})})})]}),x(_y,{configPath:"filter.byAuthor.keywords",searchProps:{placeholder:"添加UP: 全名 / mid / mid(备注)"},disabled:!e||!a.enabled,className:"mt-2",listClassName:"max-h-130px"})]}),F("div",{className:X(By.blockContainer,"col-span-full"),children:[F("div",{className:X(Bn.settingsGroupSubTitle),children:[x("span",{children:"标题"}),F(pr,{children:["根据标题关键词过滤视频 ",x("br",{}),"支持普通关键字和正则(i), 语法:",x(vo,{color:"success",variant:"solid",children:"/abc|\\d+/"})]}),x(pu,{configPath:"filter.byTitle.enabled",disabled:!e,className:"ml-10px"}),x("div",{className:"flex-1"}),x(Zo,{placement:"left",content:F("div",{className:"flex flex-col gap-x-10px gap-y-5px",children:[F(st,{onClick:gAe,disabled:!l.keywords.length,children:[x(Np,{}),"导出"]}),F(st,{onClick:vAe,children:[x(Pp,{}),"导入"]})]}),children:x(st,{className:"icon-only-round-button size-26px",children:x(Op,{className:"size-16px"})})})]}),x(_y,{configPath:"filter.byTitle.keywords",searchProps:{placeholder:"添加过滤关键词"},disabled:!e||!l.enabled,listClassName:"max-h-130px"})]})]})})}function AAe(){const{filter:{enabled:e,dfByTitle:t,dfHideOpusMids:n}}=Ut();return F("div",{className:"flex flex-col gap-y-15px",children:[F("div",{className:By.blockContainer,children:[F("div",{className:Bn.settingsGroupSubTitle,children:[x("span",{children:"标题"}),F(pr,{children:["支持普通关键字和正则(i), 语法:",x(vo,{color:"success",variant:"solid",children:"/abc|\\d+/"}),x("br",{}),"作用范围: 支持的动态类型: 视频 / 图文"]}),x(pu,{configPath:"filter.dfByTitle.enabled",disabled:!e,className:"ml-10px"}),x("div",{className:"flex-1"}),x(Zo,{placement:"left",content:F("div",{className:"flex flex-col gap-x-10px gap-y-5px",children:[F(st,{onClick:bAe,disabled:!t.keywords.length,children:[x(Np,{}),"导出"]}),F(st,{onClick:yAe,children:[x(Pp,{}),"导入"]})]}),children:x(st,{className:"icon-only-round-button size-26px",children:x(Op,{className:"size-16px"})})})]}),x(_y,{configPath:"filter.dfByTitle.keywords",searchProps:{placeholder:"添加过滤关键词"},disabled:!e||!t.enabled})]}),F("div",{className:By.blockContainer,children:[F("div",{className:Bn.settingsGroupSubTitle,children:[x("span",{children:"屏蔽 UP 的图文动态"}),F(pr,{children:["支持 mid 或 mid(备注) ",x("br",{}),"右键图文动态可快速添加"]}),x(pu,{configPath:"filter.dfHideOpusMids.enabled",disabled:!e,className:"ml-10px"}),x("div",{className:"flex-1"}),x(Zo,{placement:"left",content:F("div",{className:"flex flex-col gap-x-10px gap-y-5px",children:[F(st,{onClick:SAe,disabled:!n.keywords.length,children:[x(Np,{}),"导出"]}),F(st,{onClick:CAe,children:[x(Pp,{}),"导入"]})]}),children:x(st,{className:"icon-only-round-button size-26px",children:x(Op,{className:"size-16px"})})})]}),x(_y,{configPath:"filter.dfHideOpusMids.keywords",searchProps:{placeholder:"添加 UP: mid / mid(备注)"},disabled:!e||!n.enabled,listClassName:"max-h-130px"})]})]})}async function NAe(){const e=at.filter.byAuthor.keywords,t=await Wl(e,async n=>{const{mid:r,remark:o}=tS(n);return !r||!o||await Pg(r)!==o?n:r},1/0);return fa(t,e)?_t.warning("没有「无效备注」数据!"):(at.filter.byAuthor.keywords=t,_t.success("已清理「无效备注」数据!"))}function PAe(){return F("div",{className:Bn.tabPane,children:[x(eo,{title:"视频播放页",children:x(Pt,{configPath:"fav.useCustomFavPicker.onPlayPage",label:"使用自定义收藏弹窗",tooltip:F(ze,{children:["使用「",Ao,"」提供的选择收藏夹弹窗 ",x("br",{}),F("ul",{className:"ml-20px list-circle",children:[x("li",{children:"支持拼音搜索, 帮你快速找到收藏夹"}),x("li",{children:F("span",{className:"flex-v-center",children:["支持从收藏夹图标 或 快捷键",x("kbd",{className:X(fu,"mx-1 h-14px py-0 line-height-14px"),children:"e"}),"触发"]})})]})]})})}),x(eo,{title:"搜索页",children:x(Pt,{configPath:"videoCard.videoPreview.addTo.searchPage",label:"浮动预览: 添加到「搜索页」",tooltip:x(ze,{children:"在搜索页的视频也添加「浮动预览」"})})})]})}function IAe(e,t,n){const r={...e};return t.top+e.y<=n.top?r.y=n.top-t.top:t.bottom+e.y>=n.top+n.height&&(r.y=n.top+n.height-t.bottom),t.left+e.x<=n.left?r.x=n.left-t.left:t.right+e.x>=n.left+n.width&&(r.x=n.left+n.width-t.right),r}const OAe=e=>{let{containerNodeRect:t,draggingNodeRect:n,transform:r}=e;return !n||!t?r:IAe(r,n,t)},DAe=e=>{let{transform:t}=e;return {...t,x:0}};function kp(e,t,n){const r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function _Ae(e,t){return e.reduce((n,r,o)=>{const i=t.get(r);return i&&(n[o]=i),n},Array(e.length))}function Eb(e){return e!==null&&e>=0}function BAe(e,t){if(e===t)return true;if(e.length!==t.length)return false;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return false;return true}function LAe(e){return typeof e=="boolean"?{draggable:e,droppable:e}:e}const Hq=e=>{let{rects:t,activeIndex:n,overIndex:r,index:o}=e;const i=kp(t,r,n),a=t[o],l=i[o];return !l||!a?null:{x:l.left-a.left,y:l.top-a.top,scaleX:l.width/a.width,scaleY:l.height/a.height}},Mb={scaleX:1,scaleY:1},zAe=e=>{var t;let{activeIndex:n,activeNodeRect:r,index:o,rects:i,overIndex:a}=e;const l=(t=i[n])!=null?t:r;if(!l)return null;if(o===n){const d=i[a];return d?{x:0,y:n<a?d.top+d.height-(l.top+l.height):d.top-l.top,...Mb}:null}const u=kAe(i,o,n);return o>n&&o<=a?{x:0,y:-l.height-u,...Mb}:o<n&&o>=a?{x:0,y:l.height+u,...Mb}:{x:0,y:0,...Mb}};function kAe(e,t,n){const r=e[t],o=e[t-1],i=e[t+1];return r?n<t?o?r.top-(o.top+o.height):i?i.top-(r.top+r.height):0:i?i.top-(r.top+r.height):o?r.top-(o.top+o.height):0:0}const Vq="Sortable",jq=q.createContext({activeIndex:-1,containerId:Vq,disableTransforms:false,items:[],overIndex:-1,useDragOverlay:false,sortedRects:[],strategy:Hq,disabled:{draggable:false,droppable:false}});function FAe(e){let{children:t,id:n,items:r,strategy:o=Hq,disabled:i=false}=e;const{active:a,dragOverlay:l,droppableRects:u,over:d,measureDroppableContainers:m}=iEe(),p=Rg(Vq,n),g=l.rect!==null,b=f.useMemo(()=>r.map(I=>typeof I=="object"&&"id"in I?I.id:I),[r]),y=a!=null,S=a?b.indexOf(a.id):-1,C=d?b.indexOf(d.id):-1,w=f.useRef(b),$=!BAe(b,w.current),M=C!==-1&&S===-1||$,T=LAe(i);Ya(()=>{$&&y&&m(b);},[$,b,y,m]),f.useEffect(()=>{w.current=b;},[b]);const R=f.useMemo(()=>({activeIndex:S,containerId:p,disabled:T,disableTransforms:M,items:b,overIndex:C,useDragOverlay:g,sortedRects:_Ae(b,u),strategy:o}),[S,p,T.draggable,T.droppable,M,b,C,u,g,o]);return q.createElement(jq.Provider,{value:R},t)}const HAe=e=>{let{id:t,items:n,activeIndex:r,overIndex:o}=e;return kp(n,r,o).indexOf(t)},VAe=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:o,items:i,newIndex:a,previousItems:l,previousContainerId:u,transition:d}=e;return !d||!r||l!==i&&o===a?false:n?true:a!==o&&t===u},jAe={duration:200,easing:"ease"},Uq="transform",UAe=yf.Transition.toString({property:Uq,duration:0,easing:"linear"}),WAe={roleDescription:"sortable"};function GAe(e){let{disabled:t,index:n,node:r,rect:o}=e;const[i,a]=f.useState(null),l=f.useRef(n);return Ya(()=>{if(!t&&n!==l.current&&r.current){const u=o.current;if(u){const d=Zf(r.current,{ignoreTransform:true}),m={x:u.left-d.left,y:u.top-d.top,scaleX:u.width/d.width,scaleY:u.height/d.height};(m.x||m.y)&&a(m);}}n!==l.current&&(l.current=n);},[t,n,r,o]),f.useEffect(()=>{i&&a(null);},[i]),i}function qAe(e){let{animateLayoutChanges:t=VAe,attributes:n,disabled:r,data:o,getNewIndex:i=HAe,id:a,strategy:l,resizeObserverConfig:u,transition:d=jAe}=e;const{items:m,containerId:p,activeIndex:g,disabled:b,disableTransforms:y,sortedRects:S,overIndex:C,useDragOverlay:w,strategy:$}=f.useContext(jq),M=KAe(r,b),T=m.indexOf(a),R=f.useMemo(()=>({sortable:{containerId:p,index:T,items:m},...o}),[p,o,T,m]),I=f.useMemo(()=>m.slice(m.indexOf(a)),[m,a]),{rect:N,node:P,isOver:O,setNodeRef:_}=lEe({id:a,data:R,disabled:M.droppable,resizeObserverConfig:{updateMeasurementsFor:I,...u}}),{active:B,activatorEvent:V,activeNodeRect:U,attributes:G,setNodeRef:H,listeners:z,isDragging:j,over:W,setActivatorNodeRef:Y,transform:Q}=DW({id:a,data:R,attributes:{...WAe,...n},disabled:M.draggable}),D=k$e(_,H),L=!!B,K=L&&!y&&Eb(g)&&Eb(C),J=!w&&j,ee=J&&K?Q:null,re=K?ee??(l??$)({rects:S,activeNodeRect:U,activeIndex:g,overIndex:C,index:T}):null,ie=Eb(g)&&Eb(C)?i({id:a,items:m,activeIndex:g,overIndex:C}):T,de=B?.id,ne=f.useRef({activeId:de,items:m,newIndex:ie,containerId:p}),ce=m!==ne.current.items,fe=t({active:B,containerId:p,isDragging:j,isSorting:L,id:a,index:T,items:m,newIndex:ne.current.newIndex,previousItems:ne.current.items,previousContainerId:ne.current.containerId,transition:d,wasDragging:ne.current.activeId!=null}),se=GAe({disabled:!fe,index:T,node:P,rect:N});return f.useEffect(()=>{L&&ne.current.newIndex!==ie&&(ne.current.newIndex=ie),p!==ne.current.containerId&&(ne.current.containerId=p),m!==ne.current.items&&(ne.current.items=m);},[L,ie,p,m]),f.useEffect(()=>{if(de===ne.current.activeId)return;if(de!=null&&ne.current.activeId==null){ne.current.activeId=de;return}const ae=setTimeout(()=>{ne.current.activeId=de;},50);return ()=>clearTimeout(ae)},[de]),{active:B,activeIndex:g,attributes:G,data:R,rect:N,index:T,newIndex:ie,items:m,isOver:O,isSorting:L,isDragging:j,listeners:z,node:P,overIndex:C,over:W,setNodeRef:D,setActivatorNodeRef:Y,setDroppableNodeRef:_,setDraggableNodeRef:H,transform:se??re,transition:Me()};function Me(){if(se||ce&&ne.current.newIndex===T)return UAe;if(!(J&&!EA(V)||!d)&&(L||fe))return yf.Transition.toString({...d,property:Uq})}}function KAe(e,t){var n,r;return typeof e=="boolean"?{draggable:e,droppable:false}:{draggable:(n=e?.draggable)!=null?n:t.draggable,droppable:(r=e?.droppable)!=null?r:t.droppable}}En.Down,En.Right,En.Up,En.Left;const d6=await( mT({value:nt.AppRecommend},"video-source-tab"));{const e=J1();e&&(d6.value=e);}function Wq(e){return RM.slice().sort((t,n)=>{let r=e.indexOf(t),o=e.indexOf(n);return r===-1&&(r=Q$.indexOf(t)),o===-1&&(o=Q$.indexOf(n)),r-o})}function f6(e){const{customTabKeysOrder:t}=Ut(e);return f.useMemo(()=>Wq(t),[t])}function Gq(){const{hidingTabKeys:e,customTabKeysOrder:t}=Ut(),n=cA(),r=f.useMemo(J1,[]),o=f.useMemo(()=>Wq(t).filter(a=>a===nt.AppRecommend&&!n?true:!e.includes(a)),[e,t,n]);return r?[r]:o}function YAe(){const e=Gq();return f.useMemo(()=>e.map(t=>({key:t,...tm[t]})),[e])}function qq(){const e=bt(d6).value,t=Gq(),n=cA(),r=nt.AppRecommend;return !t.includes(e)||!n&&!tm[e].anonymousUsage?r:e}function Kq(){const e=f.useDeferredValue(qq()),t=SA(e),n=f6(),r=f.useMemo(()=>t?n.indexOf(e)>n.indexOf(t)?"right":"left":void 0,[n,e]);return {tab:e,prevTab:t,direction:r}}const XAe={name:"18r7nz9",styles:"height:32px;line-height:unset;--ant-border-radius:16px;&:has(:focus-visible){outline:none;outline-offset:unset;}>.ant-radio-button+span{height:100%;}"};function Yq({className:e}){const t=cA(),n=qq(),r=YAe(),{__internalRecTabRenderAsSegments:o}=Ut(),i=Je(u=>{if(!t&&!tm[u].anonymousUsage&&!sU())return zq();d6.value=u;}),a=x(to.Group,{optionType:"button",buttonStyle:"solid",size:"middle",value:n,className:X("inline-flex items-center",e),onFocus:u=>{u.target.blur();},onChange:u=>{const d=u.target.value;i(d);},children:r.map(({key:u,label:d})=>x(to.Button,{css:XAe,className:"video-source-tab",tabIndex:-1,value:u,children:F("span",{className:"h-full flex items-center line-height-unset",children:[x(yi,{tabKey:u,className:"mr-4px",active:u===n}),d]})},u))});let l;{const u=f.useMemo(()=>r.map(({key:d,label:m})=>({value:d,label:F("div",{className:"flex items-center gap-x-6px",children:[x(yi,{tabKey:d,active:d===n}),m]})})),[r,n]);l=x(QR,{size:"middle",options:u,value:n,onChange:i});}return F("div",{className:"flex-v-center",children:[o?l:a,x(pr,{className:"ml-6px size-16px",children:x(ze,{children:r.map(({key:u,label:d,desc:m,extraHelpInfo:p})=>F(f.Fragment,{children:[F("div",{className:"h-22px flex items-center",children:[x(yi,{tabKey:u,className:"mr-4px",active:true}),d,": ",m]}),!!p&&p]},u))})})]})}const QAe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",fillRule:"evenodd",d:"M19 10a4 4 0 1 1-8 0a4 4 0 0 1 8 0m-4 18a4 4 0 1 0 0-8a4 4 0 0 0 0 8m0 14a4 4 0 1 0 0-8a4 4 0 0 0 0 8m22-32a4 4 0 1 1-8 0a4 4 0 0 1 8 0m-4 18a4 4 0 1 0 0-8a4 4 0 0 0 0 8m0 14a4 4 0 1 0 0-8a4 4 0 0 0 0 8",clipRule:"evenodd"})]}),Xq=f.forwardRef(QAe);function ZAe(){const{dynamicFeed:e}=Ut(),t=f6(),n=r=>({order:t.indexOf(r)+1});return x("div",{className:Bn.tabPane,children:F("div",{className:"grid grid-cols-[250px_1fr] gap-x-50px",children:[x(eo,{title:F(ze,{children:["Tab 设置",x(pr,{className:"ml-5px",children:"勾选显示, 拖动排序"})]}),resetSettingPaths:["hidingTabKeys","customTabKeysOrder"],children:x(e6e,{})}),F(eo,{title:"更多设置",contentClassName:"gap-y-15px",children:[F("div",{style:n(nt.Watchlater),children:[F("div",{className:"flex items-center text-size-1.3em",children:[x(yi,{tabKey:nt.Watchlater,className:"mr-5px mt--1px"}),"稍后再看"]}),F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"watchlaterAddSeparator",label:"添加分割线",tooltip:"添加「近期」「更早」分割线"}),x(Pt,{configPath:"watchlaterUseNormalVideoUrl",label:"使用普通视频链接",tooltip:Br("使用普通视频链接","使用「稍后再看」自动列表链接")})]})]}),F("div",{style:n(nt.Fav),children:[F("div",{className:"flex items-center text-size-1.3em",children:[x(yi,{tabKey:nt.Fav,className:"mr-5px mt--2px"}),"收藏"]}),x("div",{className:Bn.settingsLine,children:x(Pt,{configPath:"fav.addSeparator",label:"添加分割线",tooltip:"顺序显示时, 按收藏夹添加分割线"})})]}),F("div",{style:n(nt.DynamicFeed),children:[F("div",{className:"flex items-center text-size-1.3em",children:[x(yi,{tabKey:nt.DynamicFeed,className:"mr-5px mt--2px"}),"动态"]}),F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"dynamicFeed.followGroup.enabled",label:"启用分组筛选",tooltip:F(ze,{children:["动态 Tab 启用分组筛选 ",x("br",{}),x(mq,{})]})}),x(Pt,{configPath:"dynamicFeed.showLive",label:"在动态中显示直播",tooltip:F(ze,{children:["动态里显示正在直播的 UP",x("br",{}),"P.S 仅在选择「全部」时展示"]})}),x(Pt,{configPath:"dynamicFeed.videoOnly",label:"只显示视频",tooltip:Br("只获取视频动态: 投稿视频 / 动态视频","获取全部动态: 包含视频 / 图片 / 文章等")}),x(Pt,{configPath:"dynamicFeed.whenViewAll.enableHideSomeContents",label:"「全部」动态过滤",tooltip:F(ze,{children:["查看「全部」动态时 ",x("br",{}),Br("将添加右键菜单, 点击可添加到「全部」动态的过滤列表","关闭此功能")]})}),e.whenViewAll.enableHideSomeContents&&x(Lk,{size:"small",className:"w-full",items:[{key:"1",label:"在「全部」动态中隐藏 UP/分组 的动态",children:x(n6e,{})}]})]})]}),F("div",{style:n(nt.AppRecommend),children:[F("div",{className:"flex items-center text-size-1.3em",children:[x(yi,{tabKey:nt.AppRecommend,className:"mr-5px"}),"App 推荐"]}),x("div",{className:Bn.settingsLine,children:x("div",{className:"flex items-center",children:Mq()})})]})]})]})})}function JAe(){const{hidingTabKeys:e}=Ut();return f.useMemo(()=>RM.filter(t=>!e.includes(t)),[e])}function e6e({className:e,style:t}){const n=JAe(),r=f6({sync:true}),o=J$e(Z$e(AA)),i=Je(a=>{const{over:l,active:u}=a;if(!l?.id||l.id===u.id)return;const d=r.indexOf(u.id.toString()),m=r.indexOf(l.id.toString()),p=kp(r,d,m);at.customTabKeysOrder=p;});return x("div",{className:e,style:t,children:x(Ki.Group,{className:"block line-height-[unset]",value:n,onChange:a=>{if(!a.length)return _t.error("至少选择一项!");Ka({hidingTabKeys:RM.filter(l=>!a.includes(l))});},children:x(OW,{sensors:o,collisionDetection:o2e,onDragEnd:i,modifiers:[DAe,OAe],children:x(FAe,{items:r,strategy:zAe,children:r.map(a=>x(t6e,{id:a},a))})})})})}function t6e({id:e}){const{label:t,desc:n}=tm[e],{attributes:r,listeners:o,setNodeRef:i,transform:a,transition:l,setActivatorNodeRef:u}=qAe({id:e}),d={transform:yf.Transform.toString(a),transition:l};return F("div",{ref:i,style:d,className:"mt-8px h-35px flex items-center justify-between b-1px b-gate-bg-lv-2 rounded-6px b-solid pl-10px pr-6px",children:[F(Ki,{value:e,className:"inline-flex items-center [&_.ant-checkbox-label]:inline-flex [&_.ant-checkbox-label]:select-none [&_.ant-checkbox-label]:items-center",children:[x(yi,{tabKey:e,className:"mr-5px"}),x(fn,{align:{offset:[0,-6]},title:n,children:t})]}),x("div",{...o,...r,ref:u,className:"cursor-grab rounded-5px px-5px py-3px text-size-0 hover:bg-gate-bg-lv-3",children:x(Xq,{className:"size-18px"})})]},e)}function n6e(){const{hideIds:e}=bt(at.dynamicFeed.whenViewAll),t=Je(async o=>{await Ua("dynamicFeed.whenViewAll.hideIds",{remove:[o]});}),{groups:n}=bt(Jt);return oo(()=>{Jt.updateGroups();}),e.length?x("div",{className:"max-h-250px flex flex-wrap gap-10px overflow-y-auto",children:e.map(o=>x(Fq,{tag:o,onDelete:t,renderTag:i=>x(r6e,{tag:i,followGroups:n})},o))}):x("div",{className:"flex items-center justify-center",children:x(Vi,{})})}function r6e({tag:e,followGroups:t}){let n,r;e.startsWith(Cf)?n=e.slice(Cf.length):e.startsWith(bu)&&(r=e.slice(bu.length));const[o,i]=f.useState(void 0);oo(async()=>{if(!n)return;const g=await Pg(n);g&&i(g);});const[a,l]=f.useState(void 0);oo(()=>{if(!r)return;const g=t?.find(b=>b.tagid.toString()===r)?.name;g&&l(g);});const u=f.useMemo(()=>n?o||n:r?a||r:"无效数据",[n,o,r,a]),d=f.useMemo(()=>n?`mid: ${n}`:r?`分组: ${r}`:`Tag: ${e}`,[n,r,e]),m=f.useMemo(()=>n?x(lG,{className:"mr-2px size-12px"}):r?x(cG,{className:"mr-2px size-16px"}):void 0,[n,r]),p=f.useMemo(()=>n?Tg(n):r?uG(r):void 0,[n,r]);return x(ze,{children:x(fn,{title:d,children:F("span",{className:X("inline-flex items-center",n?"cursor-pointer":"cursor-text"),children:[m,p?x("a",{href:p,target:"_blank",children:u}):u]})})})}const w$=[{useBorder:false},{useBorder:true,useBorderOnlyOnHover:true},{useBorder:true,useBorderOnlyOnHover:false}],Qq=["「卡片边框」: 禁用","「卡片边框」: 仅在悬浮时显示","「卡片边框」: 总是显示"];function o6e(){return ua(["shift.b"],e=>{if(js())return;const t=su(at.style.videoCard,["useBorder","useBorderOnlyOnHover"]),n=w$.findIndex(a=>fa(a,su(t,Object.keys(a))));if(n===-1)throw new Error("unexpected curIndex = -1");const r=(n+1)%w$.length,o=w$[r];Object.assign(at.style.videoCard,o);const i=Qq[r];_t.success(i);},{exactMatch:true})}function i6e(){const{videoCard:{actions:{showLargePreview:e,openInPipWindow:t},imgPreview:{enabled:n}},videoLinkOpenMode:r,style:o,autoPreviewUpdateInterval:i}=Ut(),a=f.useMemo(()=>Object.values(sr).filter(l=>di[l].enabled??true).map(l=>{const u=di[l];return {config:u,value:l,label:F("span",{className:"flex-v-center gap-x-8px",children:[u.icon,x("span",{children:u.label})]})}}),[]);return F("div",{className:Bn.tabPane,children:[x(eo,{title:"视频链接",resetSettingPaths:["videoLinkOpenMode"],children:F("div",{className:"flex-v-center",children:["打开方式",F(pr,{useBlackBg:true,children:["选择点击视频(封面图片 或 标题)时打开的模式 ",x("br",{}),a.map(({value:l,config:u})=>!!u.desc&&F("div",{className:"mt-10px flex items-start first:mt-0",children:[F("span",{className:"inline-flex items-center",children:[u.icon,x("span",{className:"ml-4px mr-10px min-w-95px",children:u.label})]}),x("span",{className:"desc",children:u.desc})]},l))]}),x(Zl,{className:"ml-8px w-160px",options:a,value:r,onChange:l=>{Ka({videoLinkOpenMode:l});}})]})}),x(eo,{title:"边框样式",resetSettingPaths:["style.videoCard.useBorder","style.videoCard.useBorderOnlyOnHover","style.videoCard.useBoxShadow"],children:F("div",{className:Bn.settingsLine,children:[x(Pt,{configPath:"style.videoCard.useBorder",label:"使用卡片边框",tooltip:F(ze,{children:["勾选后, 视频卡片会有边框包裹, 更像是一个卡片~ ",x("br",{}),"整个卡片区域可点击 / 可触发预览 / 可使用右键菜单 ",x("br",{}),"否则只是封面区域可以 ",x("br",{}),"使用快捷键 ",x(vo,{color:"green",children:"shift+b"})," 切换状态 ",x("br",{}),Qq.map(l=>x(vo,{color:"success",className:"mx-1",children:l},l))]})}),x(Pt,{configPath:"style.videoCard.useBorderOnlyOnHover",label:"仅在悬浮时显示",disabled:!o.videoCard.useBorder,tooltip:Br("仅在悬浮时显示","常驻显示")}),x(Pt,{configPath:"style.videoCard.useBoxShadow",disabled:!o.videoCard.useBorder,label:"悬浮卡片时使用发光效果",tooltip:x(ze,{children:"悬浮卡片时使用发光效果, 看起来比较花哨~"})})]})}),F(eo,{title:F(ze,{children:["快照预览",x(pu,{configPath:"videoCard.imgPreview.enabled",tooltip:"关闭此功能",className:"ml-3"})]}),resetSettingPaths:["videoCard.imgPreview.enabled","videoCard.imgPreview.autoPreviewWhenKeyboardSelect","videoCard.imgPreview.autoPreviewWhenHover","videoCard.imgPreview.disableWhenMultiSelecting","useDelayForHover","autoPreviewUpdateInterval"],children:[F("div",{className:Bn.settingsLine,children:[x(Pt,{disabled:!n,configPath:"videoCard.imgPreview.autoPreviewWhenHover",label:"鼠标悬浮后自动开始",tooltip:F(ze,{children:[Br("鼠标悬浮后自动开始预览, 不跟随鼠标位置","预览进度跟随鼠标位置(百分比)"),"切换设置快捷键: ",x(vo,{color:"green",children:"shift+m"})]})}),x(Pt,{disabled:!n,configPath:"videoCard.imgPreview.disableWhenMultiSelecting",label:"多选时禁用",tooltip:Br("多选开启时, 禁用快照预览","不禁用")}),x(Pt,{disabled:!n,configPath:"useDelayForHover",label:"延迟悬浮预览",tooltip:"延迟悬浮预览"}),x(Pt,{disabled:!n,configPath:"videoCard.imgPreview.autoPreviewWhenKeyboardSelect",label:"键盘选中后自动开始",tooltip:F(ze,{children:["手动预览快捷键: ",x(vo,{color:"green",children:"."})," or ",x(vo,{color:"green",children:"p"})," ",x("br",{}),"切换设置快捷键: ",x(vo,{color:"green",children:"shift+p"})]})})]}),F("div",{className:Bn.settingsLine,children:["自动预览更新间隔",x(tT,{disabled:!n,className:"w-500px",min:0,max:1e3,keyboard:true,onChange:l=>at.autoPreviewUpdateInterval=l,value:i}),F("span",{style:{width:"65px"},children:["(",i,"ms)"]})]})]}),x(eo,{title:F(ze,{children:["操作按钮",F(pr,{children:["视频卡片右上角「稍后再看」按钮旁 ",x("br",{}),"「稍后再看」因其通用性不提供关闭选项"]})]}),resetSettingPaths:["videoCard.actions.showLargePreview","videoCard.actions.openInPipWindow","videoCard.videoPreview.useMp4","videoCard.videoPreview.usePreferredCdn","videoCard.videoPreview.useScale","videoCard.videoPreview.useVideoCardAsTrigger","pipWindow.defaultLocked","pipWindow.autoWebFullscreen"],children:F("div",{className:"grid grid-cols-[repeat(2,max-content)_1fr] items-start gap-x-20px",children:[x(Pt,{configPath:"videoCard.actions.showLargePreview",label:"浮动预览",tooltip:F(ze,{children:["创意来源「浮图秀」, 但使用视频预览 ",x("br",{}),"操作说明: ",x("br",{}),"1. 鼠标悬浮打开 「浮动预览」, 离开关闭 ",x("br",{}),"2. 点击固定「浮动预览」, 固定指: 不再随鼠标移出关闭预览 ",x("br",{}),"3. 可使用以下方式关闭固定的「浮动预览」",F("ul",{className:"ml-30px list-circle",children:[x("li",{children:"再次点击视频卡片按钮"}),x("li",{children:"点击预览视频右上方的「关闭」按钮"}),x("li",{children:"触发其他卡片的「浮动预览」"}),x("li",{children:"Esc键"}),x("li",{children:"点击页面空白处"})]})]})}),x(Pt,{configPath:"videoCard.actions.openInPipWindow",label:"小窗打开",tooltip:x(ze,{children:"仅当「文档画中画」API 可用时, 勾选生效"})}),x(Ul,{className:"grid-col-span-full my-2px py-0"}),F("div",{className:"flex flex-col",children:[x(Pt,{configPath:"videoCard.videoPreview.useMp4",disabled:!e,label:"浮动预览: 使用 mp4",tooltip:Br("使用 mp4, 最高 720p, 有声音","使用 dash, 最高 1080p, 无声音, 理论上更快")}),x(Pt,{configPath:"videoCard.videoPreview.usePreferredCdn",disabled:!e,label:"浮动预览: 使用优选 CDN",tooltip:Br("使用优选 CDN (降低 MCDN & PCDN 优先级)","使用默认 CDN")}),x(Pt,{configPath:"videoCard.videoPreview.useScale",disabled:!e,label:"浮动预览: 使用放大效果",tooltip:Br("浮动预览面板: 放大展开 (类似浮图秀)","浮动预览面板: 滑动展开")}),x(Pt,{configPath:"videoCard.videoPreview.useVideoCardAsTrigger",label:"浮动预览: 使用视频卡片作为触发器",tooltip:F(ze,{children:[Br("使用「视频卡片」作为触发器","使用「视频卡片右上角按钮」作为触发器, 悬浮视频卡片 1 秒后展开"),x(Ul,{className:"my-1"}),x("ul",{className:"ml-25px list-circle",children:x("li",{children:"与上面「浮动预览」开关独立"})})]})})]}),F("div",{className:"flex flex-col",children:[x(Pt,{configPath:"pipWindow.defaultLocked",disabled:!t,label:"小窗: 默认锁定",tooltip:Br("小窗打开时: 默认锁定","小窗打开时: 不锁定")}),x(Pt,{configPath:"pipWindow.autoWebFullscreen",disabled:!t,label:"小窗: 自动网页全屏",tooltip:Br("自动网页全屏","不启用")})]})]})})]})}function a6e(){const e=hW().id,t=SA(e),{colorPickerThemeSelectedColor:n}=Ut(),[r,o]=f.useState(n||Mf.Pink),i=f.useMemo(()=>typeof r=="string"?r:r.toHexString(),[r]);return oo(()=>{lg.updateThrottled();}),x("div",{children:mW.map(({name:a,themes:l,tooltip:u})=>F(f.Fragment,{children:[F("div",{className:"mt-2 flex items-center text-size-1.5em",children:[a,x(pr,{className:"size-16px",useBlackBg:true,children:u})]}),x("div",{className:"flex flex-wrap gap-x-5px gap-y-2px",children:l.map(d=>{const m=e===d.id,p=d.isCustom,g=!!t&&t!==d.id,b=28,y=b+8;let S=x("div",{"data-role":"preview-wrapper",style:{width:y},className:X("mx-auto my-0 aspect-1 b-2px rounded-full b-solid",m?"b-gate-primary":"b-transparent","flex items-center justify-center text-size-0"),children:x("div",{"data-role":"preview",className:"aspect-1 flex items-center justify-center rounded-full text-white",css:ln("width:",b,"px;background-color:",p?i:d.colorPrimary,";",""),children:m&&x(Mp,{size:18,useAnimation:g})})});d.isCustom&&(S=x(nT,{value:r,onChange:w=>o(w),onOpenChange:w=>{w||Ka({colorPickerThemeSelectedColor:i});},children:S}));let C=F("div",{className:"min-w-60px cursor-pointer text-center",onClick:w=>{Ka({theme:d.id});},children:[S,d.name]});return (d.tooltip||b9[d.id])&&(C=x(fn,{title:F(ze,{children:[d.tooltip,b9[d.id]]}),color:d.colorPrimary,children:C})),C=x(f.Fragment,{children:C},d.id),C})})]},a))})}function rB(e,t,n){return ua(e,r=>{if(js())return;const i=!!!To(at,t);$f(at,t,i),_t.success(`已${i?"启用":"禁用"}「${n}」`);},{exactMatch:true})}const s6e="basic",oB=zn({tab:s6e});function l6e(){return rB(["shift.p"],"videoCard.imgPreview.autoPreviewWhenKeyboardSelect","键盘选中后自动开始预览"),rB(["shift.m"],"videoCard.imgPreview.autoPreviewWhenHover","鼠标悬浮后自动开始预览"),o6e(),null}const c6e={name:"4k370z",styles:"&.ant-tabs{.ant-tabs-tab{justify-content:end;padding-inline:5px 15px;}.ant-tabs-nav-operations{display:none;}}"};function u6e({show:e,onHide:t}){const{tab:n}=bt(oB);return F(wg,{show:e,onHide:t,hideWhenMaskOnClick:true,hideWhenEsc:true,width:900,clsModalMask:"[&:has(svg.peeking)]:bg-transparent",clsModal:"max-h-unset [&:has(svg.peeking)]:opacity-10",children:[F("div",{className:Po.modalHeader,children:[F("div",{className:Po.modalTitle,children:[x(JT,{className:"mr-4px mt--2px size-26px"}),"设置"]}),x($g,{onClick:t})]}),x("main",{className:Po.modalBody,style:{overflow:"hidden"},children:x(XR,{tabPlacement:"start",size:"middle",css:c6e,activeKey:n,onChange:r=>oB.tab=r,items:[{label:"常规设置",key:"basic",children:x(mAe,{})},{label:"视频卡片",key:"video-card",children:x(i6e,{})},{label:"内容过滤",key:"filter",children:x(RAe,{})},{label:"主题选择",key:"theme-select",children:x("div",{className:Bn.tabPane,children:x(a6e,{})})},{label:"Tab 设置",key:"video-source-tab-config",children:x(ZAe,{})},{label:"其他页面",key:"other-pages",children:x(PAe,{})},{label:"高级设置",key:"advance",children:x(NEe,{})}]})})]})}const d6e=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"m19 12l12 12l-12 12"})]}),Zq=f.forwardRef(d6e);function f6e({children:e,initialOpen:t=false,ref:n}){const[r,o]=iW(t);f.useImperativeHandle(n,()=>o,[o]);const i=x(st,{onClick:o.toggle,className:"icon-only-round-button",children:x(Zq,{className:X("size-13px",r?"rotate-z-0":"rotate-z-180deg")})});return F(ze,{children:[i,r&&e]})}function Jq({Component:e,defaultProps:t,containerClassName:n}){const r=zn(t);function o(){const u=bt(r);return x(e,{...u})}const i=xf(()=>{const u=document.createElement("div");u.className=X($a,n),document.body.appendChild(u),Qa.createRoot(u).render(x(Us,{children:x(o,{})}));});function a(u){return (...d)=>(i(),u(...d))}const l=a(u=>{Object.assign(r,u);});return {WrappedComponent:o,proxyProps:r,mount:i,wrapAction:a,updateProps:l}}const Ly=BH();function m6e(){return bt(Ly)}function h6e(e){const t=m6e();return e?t.get(e):void 0}function p6e(e){Ly.delete(e);}const g6e={show:false,reasons:[],onHide:b6e,okAction:void 0},{proxyProps:v6e,updateProps:eK}=Jq({Component:S6e,containerClassName:"show-dislike-container",defaultProps:g6e}),tK=new Xo;function b6e(){tK.emit("modal-close"),eK({show:false,reasons:[],okAction:void 0});}async function y6e(e,t){eK({show:true,reasons:e,okAction:t}),await tK.once("modal-close");}const nK=function(){return bt(v6e).show};function S6e({show:e,reasons:t,onHide:n,okAction:r}){const o=f.useRef(null),i=()=>!!e&&!!t?.length,a=ga(async b=>r?.(b),{manual:true}),l=a.loading,[u,d]=f.useState(t.length-1);$$e(()=>{d(t.length-1);},[t]);const m=["1","2","3","4","5","6"];ua(m,b=>{if(!i()||!m.includes(b.key)||!t?.length)return;const y=Number(b.key)-1;y>=0&&y<t.length&&d(y);});const p=Je(b=>{if(!i()||js())return;const y=t.length;let S=u+b;S<0&&(S=S%y+y),S>y-1&&(S=S%y),d(S);});ua("uparrow",()=>p(-1),{exactMatch:true}),ua("downarrow",()=>p(1),{exactMatch:true});const g=xg(async b=>{if(!i()||u<0||u>t.length-1)return;const y=t[u];if(!y)return;b.preventDefault(),b.stopPropagation(),await a.runAsync(y)&&n();});return ua("enter",g,{exactMatch:true}),F(wg,{show:e,onHide:n,hideWhenMaskOnClick:true,hideWhenEsc:true,width:350,clsModal:"rounded-15px",children:[F("div",{className:Po.modalHeader,children:[F("div",{className:Po.modalTitle,children:[x(ZT,{className:"size-25px"}),x("span",{className:"ml-5px",children:"我不想看"}),F(pr,{children:["选择后将减少相似内容推荐 ",x("br",{}),"操作说明: ",x("br",{}),F("div",{className:"ml-10px",children:["1. 使用删除键打开弹窗, Esc 关闭 ",x("br",{}),"2. 数字键 或 方向键选择 ",x("br",{}),"3. 回车键 或 确定按钮提交 ",x("br",{})]})]})]}),x($g,{onClick:n})]}),x("div",{className:Po.modalBody,ref:o,children:x(b1,{spinning:l,indicator:eU,children:x("div",{className:"reason-list mb-20px mt-20px flex flex-col gap-y-10px",children:t.map((b,y)=>{const S=y===u;return F("button",{"data-id":b.id,className:X("reason",{active:S},"relative flex cursor-pointer items-center b-2px rounded-6px b-solid bg-transparent px-6px py-12px",S?"b-gate-primary":"b-gate-border"),disabled:l,onClick:()=>{d(y);},children:[x("span",{"data-cls":"reason-no",className:"size-20px flex flex-none items-center justify-center rounded-full bg-gate-primary text-13px color-white",children:y+1}),x("span",{className:"flex-1 px-4px text-14px",children:b.name}),x("span",{className:"size-20px flex-none",children:S&&x(Mp,{className:"h-100% w-100% color-gate-primary",useAnimation:true})})]},b.id)})})})}),F("div",{className:"mt-2 flex items-center justify-end gap-x-10px",children:[x(st,{onClick:n,children:"取消"}),x(st,{type:"primary",onClick:g,loading:l,children:"确定"})]})]})}const rK={modalWidth:60,favFolderOrder:"default"},$h=fT({...rK},"modal-fav-manager");function C6e(){const{modalWidth:e,favFolderOrder:t}=bt($h),n="text-1.5em",r="text-1.2em";return F("div",{className:"flex flex-col gap-y-10px",children:[F("div",{className:"flex items-center justify-between",children:[x("div",{className:n,children:"窗口设置"}),x(st,{className:"icon-only-round-button size-24px",onClick:()=>Object.assign($h,rK),children:x(gy,{})})]}),F("div",{children:[F("div",{className:r,children:["窗口宽度 ",e,"%"]}),x(tT,{className:"mt-0",value:e,min:30,max:90,onChange:o=>{$h.modalWidth=o;}})]}),F("div",{children:[x("div",{className:r,children:"收藏夹排序"}),x(PG,{value:t,onChange:o=>$h.favFolderOrder=o})]})]})}function x6e({show:e,onHide:t,mode:n,pickOkAction:r,modifyInitialSelectedIds:o,modifyAllowEmpty:i,modifyOkAction:a}){const{modalWidth:l,favFolderOrder:u}=bt($h),[d,m]=f.useState(void 0),[p,g]=f.useState(void 0),b=ga(u6,{manual:true}),y=ga(async _=>r?.(_),{manual:true}),S=ga(async _=>a?.(_),{manual:true}),{folders:C}=bt(pn),w=f.useMemo(()=>{const _=C.map((G,H)=>({...G,vol:H+1}));if(!p)return _;const B=_.filter(G=>G.title.includes(p)),V=_.filter(G=>G.title.toLowerCase().includes(p.toLowerCase())),U=_.filter(G=>kX.match(G.title,p));return Kl([...B,...V,...U],G=>G.id)},[C,p]),M=f.useMemo(()=>NG(w,u),[w,u]),T=f.useMemo(()=>new Set([o].flat().filter(_=>typeof _=="number")),[o]),R=w6e(),I=n==="modify"&&i,N=f.useMemo(()=>!I&&!d||n==="modify"&&fa(Array.from(T),[d]),[I,d,n,T]);ua("r",()=>{e&&(js()||b.run(true));},{exactMatch:true});const P=Je(async()=>{let _;if(d&&(_=C.find(B=>B.id===d)),!I&&!_)return _t.error("请选择一个收藏夹");n==="pick"&&(Ro(_,"selectedFolder should not be empty when mode=pick"),await y.runAsync(_)&&t()),n==="modify"&&await S.runAsync(_)&&t();}),O=Je(()=>{if(!(!e||n!=="modify"||!T.size)&&(!d||!T.has(d))){const _=Array.from(T)[0];m(_);}});return f.useEffect(()=>{e&&(b.run(),O());},[e]),Ps(()=>{if(e&&(!d||!T.has(d))){const _=Array.from(T)[0];m(_);}},[T]),F(wg,{show:e,onHide:t,hideWhenMaskOnClick:true,hideWhenEsc:true,width:`${l}vw`,clsModal:"rounded-15px",children:[F("div",{className:Po.modalHeader,children:[F("div",{className:"flex flex-wrap items-center gap-x-10px gap-y-1",children:[F("div",{className:Po.modalTitle,children:[n==="pick"?x(mCe,{className:"size-25px"}):x(eA,{className:"size-25px"}),x("span",{className:"ml-5px",children:n==="pick"?"选择目标收藏夹":"修改收藏"})]}),x(Yi,{className:"w-215px",allowClear:true,placeholder:"过滤: 支持拼音 / 拼音首字母",value:p,onChange:_=>g(_.target.value),spellCheck:false}),!!p&&F("span",{className:"ml-5px",children:[x("span",{className:X({"text-red":C.length&&!M.length}),children:M.length})," ","/ ",x("span",{children:C.length})]}),F(pr,{className:"ml-5px size-1.3em",children:["1. 使用 ",x("kbd",{className:X(fu,"mx-2px"),children:"r"})," 刷新收藏夹 ",x("br",{}),"2. 使用 ",x("kbd",{className:X(fu,"mx-2px"),children:"esc"})," 取消操作, 关闭窗口 ",x("br",{}),"3. 使用 拼音 / 拼音首字母 过滤收藏夹标题 ",x("br",{})]}),x(Zo,{trigger:"click",title:x(C6e,{}),children:x(JT,{className:"size-1.3em cursor-pointer"})})]}),x($g,{onClick:t})]}),x("div",{className:X(Po.modalBody),children:x(b1,{spinning:b.loading||y.loading||S.loading,indicator:eU,children:x("div",{className:"grid grid-cols-[repeat(auto-fill,minmax(225px,1fr))] mb-10px min-h-100px content-start items-center gap-10px pr-18px",children:M.length?M.map(_=>{const B=n==="modify"&&T.has(_.id),V=_.id===d;return F("button",{"data-id":_.id,className:X({active:V},"relative min-h-40px flex cursor-pointer items-center b-2px b-gate-border rounded-20px b-solid bg-transparent px-4px line-height-[1.2] hover:bg-gate-bg-lv1",V&&"b-gate-primary color-white bg-gate-primary! hover:bg-gate-primary-lv1!"),onClick:()=>{if(V&&I)return m(void 0);m(_.id);},children:[B&&x(fn,{title:"源收藏夹",placement:"left",children:x("span",{className:X("absolute left-2 top-50% size-2.5 flex-center translate-y--50% rounded-full",R)})}),F("span",{className:"flex-1 px-4px text-14px",children:[_.title," (",_.media_count,")"]}),x("span",{className:"mr-2px size-20px flex-none",children:V&&x(Mp,{className:"size-full color-white",useAnimation:true})})]},_.id)}):x(Vi,{className:"grid-col-span-full",image:Vi.PRESENTED_IMAGE_SIMPLE,description:"未找到收藏夹",children:"无过滤结果, 请检查过滤词 !"})})})}),F("div",{className:"mt-2 flex items-center justify-between",children:[x("div",{className:"flex-v-center gap-x-10px",children:F("a",{href:`https://space.bilibili.com/${Jo()}/favlist`,target:"_blank",className:"flex-v-center gap-x-1",children:[x(No,{className:"size-1.1em"}),"去个人空间新建收藏夹"]})}),F("div",{className:"flex-v-center gap-x-10px",children:[x(st,{onClick:t,children:"取消"}),x(st,{type:"primary",onClick:P,loading:y.loading||S.loading,disabled:N,children:"确定"})]})]})]})}function w6e(){const{theme:e}=Ut();return e===yy.id?"bg-$brand_blue":"bg-$brand_pink"}const $6e={onHide:M6e,show:false,mode:"pick",pickOkAction:void 0,modifyInitialSelectedIds:void 0,modifyOkAction:void 0},{proxyProps:E6e,updateProps:m6}=Jq({Component:x6e,containerClassName:"ModalFavManager",defaultProps:$6e}),h6=new Xo;function M6e(){m6({show:false}),h6.emit("modal-close");}function oK(){return bt(E6e).show}async function R6e(e){m6({show:true,mode:"pick",pickOkAction:e}),await h6.once("modal-close");}async function zy(e,t,n=true){m6({show:true,mode:"modify",modifyInitialSelectedIds:e,modifyOkAction:t,modifyAllowEmpty:n}),await h6.once("modal-close");}async function p6(e,t,n){if(fa(t,[n?.id]))return _t.warning("请选择不同的收藏夹!"),false;if(!await gu.modifyFav(e,t,n?.id))return false;[...t??[],n?.id].filter(a=>a!==void 0).forEach(a=>h0(a));let i;return n?i=`${t?.length?"已移动收藏到":"已加入收藏"}「${n.title}」`:i="已取消收藏",_t.success(i),true}var cM=new Map,Rb=new WeakMap,iB=0,T6e;function A6e(e){return e?(Rb.has(e)||(iB+=1,Rb.set(e,iB.toString())),Rb.get(e)):"0"}function N6e(e){return Object.keys(e).sort().filter(t=>e[t]!==void 0).map(t=>`${t}_${t==="root"?A6e(e.root):e[t]}`).toString()}function P6e(e){const t=N6e(e);let n=cM.get(t);if(!n){const r=new Map;let o;const i=new IntersectionObserver(a=>{a.forEach(l=>{var u;const d=l.isIntersecting&&o.some(m=>l.intersectionRatio>=m);e.trackVisibility&&typeof l.isVisible>"u"&&(l.isVisible=d),[...(u=r.get(l.target))!=null?u:[]].forEach(m=>{m(d,l);});});},e);o=i.thresholds||(Array.isArray(e.threshold)?e.threshold:[e.threshold||0]),n={id:t,observer:i,elements:r},cM.set(t,n);}return n}function I6e(e,t,n={},r=T6e){if(typeof window.IntersectionObserver>"u"&&r!==void 0){const u=e.getBoundingClientRect();return t(r,{isIntersecting:r,target:e,intersectionRatio:typeof n.threshold=="number"?n.threshold:0,time:0,boundingClientRect:u,intersectionRect:u,rootBounds:u}),()=>{}}const{id:o,observer:i,elements:a}=P6e(n),l=a.get(e)||[];return a.has(e)||a.set(e,l),l.push(t),i.observe(e),function(){l.splice(l.indexOf(t),1),l.length===0&&(a.delete(e),i.unobserve(e)),a.size===0&&(i.disconnect(),cM.delete(o));}}function O6e({threshold:e,delay:t,trackVisibility:n,rootMargin:r,root:o,triggerOnce:i,skip:a,initialInView:l,fallbackInView:u,onChange:d}={}){var m;const[p,g]=f.useState(null),b=f.useRef(d),y=f.useRef(l),[S,C]=f.useState({inView:!!l,entry:void 0});b.current=d,f.useEffect(()=>{if(y.current===void 0&&(y.current=l),a||!p)return;let T;return T=I6e(p,(R,I)=>{const N=y.current;y.current=R,!(N===void 0&&!R)&&(C({inView:R,entry:I}),b.current&&b.current(R,I),I.isIntersecting&&i&&T&&(T(),T=void 0));},{root:o,rootMargin:r,threshold:e,trackVisibility:n,delay:t},u),()=>{T&&T();}},[Array.isArray(e)?e.toString():e,p,o,r,i,a,n,u,t]);const w=(m=S.entry)==null?void 0:m.target,$=f.useRef(void 0);!p&&w&&!i&&!a&&$.current!==w&&($.current=w,C({inView:!!l,entry:void 0}),y.current=l);const M=[g,S.inView,S.entry];return M.ref=M[0],M.inView=M[1],M.entry=M[2],M}function aB(e){return !f.Children.toArray(e.props?.children).length}function D6e(e){const[t,n]=f.useState(e),r=f.useRef(t),o=f.useCallback(a=>{const l=typeof a=="function"?a(r.current):a;r.current=l,n(l);},[n]),i=f.useCallback(()=>r.current,[]);return [t,o,i]}function Ol(e){const[t,n,r]=D6e(e),o=f.useMemo(()=>({state:t,get:r,set:n,get val(){return r()},set val(i){n(i);}}),[r,n]);return o.state=t,o}function uM(e){const t=f.useRef(e),n=f.useCallback(()=>t.current,[]),r=f.useCallback(o=>t.current=o,[]);return f.useMemo(()=>({get:n,set:r,get val(){return n()},set val(o){r(o);}}),[n,r])}function iK({src:e,avif:t,webp:n,imgProps:r,className:o,...i}){return t??=!pg,n??=true,F("picture",{className:ur("h-full w-full object-cover",o),...i,children:[t&&x("source",{srcSet:`${e}.avif`,type:"image/avif"}),n&&x("source",{srcSet:`${e}.webp`,type:"image/webp"}),x("img",{src:e,loading:"lazy",className:"block h-full w-full",...r})]})}const _6e=typeof unsafeWindow<"u"?unsafeWindow:globalThis,g6=(e,t)=>{wf(()=>_6e[e]=t);},B6e=`${EM}_gridItems`;function L6e(e){const t=e.filter(n=>n.api!==Ye.Separator);WMe(t),g6(B6e,t);}const z6e={getGenericCardDatas:UA,copyBvidsSingleLine:WA,copyBvidInfos:qA};setTimeout(()=>{Object.entries(z6e).forEach(([e,t])=>{g6(`${EM}_${e}`,t);});});function k6e(e){const{enabled:t,keywords:n}=bt(at.filter.byAuthor),{blockUpMids:r}=f.useMemo(()=>aM(n),[n]);return e?t&&r.has(e):false}var Tb={},wo={},$$={exports:{}},sB;function aK(){return sB||(sB=1,(function(e){function t(n){"@babel/helpers - typeof";return e.exports=t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},e.exports.__esModule=true,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=true,e.exports.default=e.exports;})($$)),$$.exports}var lB;function v6(){if(lB)return wo;lB=1;var e=Ma();Object.defineProperty(wo,"__esModule",{value:true}),wo.isUndef=wo.isString=wo.isObject=wo.isNumber=wo.isFunction=wo.isBoolean=void 0;var t=e(aK());return wo.isObject=function(r){return r!==null&&(0, t.default)(r)==="object"},wo.isFunction=function(r){return typeof r=="function"},wo.isString=function(r){return typeof r=="string"},wo.isBoolean=function(r){return typeof r=="boolean"},wo.isNumber=function(r){return typeof r=="number"},wo.isUndef=function(r){return typeof r>"u"},wo}var E$={},cB;function F6e(){return cB||(cB=1,(function(e){Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var t=!!(typeof window<"u"&&window.document&&window.document.createElement);e.default=t;})(E$)),E$}var uB;function b6(){if(uB)return Tb;uB=1;var e=Ma();Object.defineProperty(Tb,"__esModule",{value:true}),Tb.getTargetElement=r;var t=v6(),n=e(F6e());function r(o,i){if(n.default){if(!o)return i;var a;return (0, t.isFunction)(o)?a=o():"current"in o?a=o.current:a=o,a}}return Tb}var sK=b6();async function H6e(e,t,n=false,r=false){const o={cid:t,fnver:0,fnval:n?1:16},i=e.toString();if(i.startsWith("BV"))o.bvid=i;else if(/^\d+$/.test(i))o.avid=i;else throw new Error("Invalid videoId provided, must be avid | bvid");const l=(await Qt.get("/x/player/wbi/playurl",{params:o})).data;function u(p){return rM(p,[g=>V6e(g,r)],["desc"])}if(l?.data?.durl){const p=(l.data.durl||[]).map(g=>[g.url,...g.backup_url||[]]).flat().filter(Boolean);if(p.length)return u(p)}return rM(l.data?.dash?.video||[],["id","codecid"],["desc","desc"]).map(p=>u([p.baseUrl,...p.backupUrl||[]])[0]).filter(Boolean)}function V6e(e,t){if(!t)return 10;const{hostname:n,searchParams:r,pathname:o}=new URL(e);return n.includes("mcdn")||r.get("os")==="mcdn"?2:o.startsWith("/v1/resource/")?1:n.includes("-mirror")?100:10}function y6(e){return !!(e?.image?.length&&e?.index?.length)}function dB(e){return jn(e)?y6(e.data):true}async function j6e(e){const n=(await Qt.get("/x/player/videoshot",{params:{bvid:e,index:"1"}})).data;return jn(n)||Ko("videoshot error for %s: %o",e,n),y6(n.data)||Ko("videoshot data invalid bvid=%s: %o",e,n.data),n}const M$=new XA({maxSize:1e4}),U6e=Hs(async e=>{if(M$.has(e)){const a=M$.get(e);if(a)return a}const t=5,n=200;let r=0,o;do{if(r++,o=await j6e(e),dB(o))break;await gn(n);}while(r<t);dB(o)&&M$.set(e,o);const i=o.data;if(at.videoCard.imgPreview.autoPreviewWhenHover){const a=i?.image||[];await Q9(a[0]),(async()=>{for(const l of a.slice(1))await Q9(l);})();}return o}),W6e=ao.extend("VideoCard:services");function lK(e){return async function(n){const r=new URLSearchParams({aid:n,csrf:oc()}),i=(await Qt.post(`/x/v2/history/toview/${e}`,r)).data,a=jn(i);return a||rn(i?.message||"出错了"),a}}const dM=lK("add"),G6e=lK("del"),cK=e=>{const t={dislike:"/x/feed/dislike",cancel:"/x/feed/dislike/cancel"}[e];return async function(n,r){const i=(await vg.get($L+t,{responseType:"json",params:{goto:n.goto,id:n.param,reason_id:r,build:"1",mobi_app:"android",idx:(Date.now()/1e3).toFixed(0)}})).data,a=jn(i);let l=i.message;return a||(l||=Up,l+=`(code ${i.code})`,l+=`
请重新获取 access_key 后重试`),{success:a,json:i,message:l}}},q6e=cK("dislike"),K6e=cK("cancel");async function Y6e(e){return {videoshotJson:await U6e(e)}}function X6e(e){return y6(e?.videoshotJson?.data)}const Q6e=e=>!!e?.playUrls?.length,fB=new XA({maxSize:1e4,maxAge:lo("1h")}),Z6e=Hs(async({bvid:e,cid:t,useMp4:n,usePreferredCdn:r,aspectRatioFromItem:o})=>{const i=JSON.stringify([e,n,r]),a=fB.get(i);if(a)return a;let l;if(t===void 0||o===void 0){const m=await JW(e);if(t=m[0]?.cid,l=m[0]?.dimension,t===void 0)throw new TypeError(`can not get cid by bvid=${e}`)}const[u,d]=await Vp(()=>H6e(e,t,n,r));if(W6e("playUrl: bvid=%s cid=%s %s",e,t,d),u)throw ca.error({title:"获取视频播放地址失败",description:u.message||u}),u;return d?.length&&fB.set(i,{playUrls:d,dimension:l}),{playUrls:d??void 0,dimension:l}}),J6e=ao.extend("VideoCard:LargePreview"),uK={right:{multiplier:1,axis:"x",reverse:"left"},left:{multiplier:-1,axis:"x",reverse:"right"},bottom:{multiplier:1,axis:"y",reverse:"top"},top:{multiplier:-1,axis:"y",reverse:"bottom"}},mo={border:40,card:10};function eNe(e){return e?.closest(B3(Dl,"bili-video-card"))?.querySelector(B3(ML,"bili-video-card__image"))?.getBoundingClientRect()}const tNe=f.memo(function({children:t,aspectRatio:n=1.7777777777777777,cardDescendantTarget:r,ref:o,...i}){const a=U1(o),[l,u]=f.useState(false),[d,m]=f.useState(void 0),p=Je(()=>{u(false),m(void 0);}),g=Je(()=>{const $=eNe(sK.getTargetElement(r)??void 0);if(!$)return p();const[M,T]=[document.documentElement.clientWidth,document.documentElement.clientHeight],R=40;if($.top>T-R||$.bottom<0+R||$.left>M-R||$.right<0+R)return p();const I={top:{x:0,y:0,width:M,height:$.top},bottom:{x:0,y:$.bottom,width:M,height:T-$.bottom},left:{x:0,y:0,width:$.left,height:T},right:{x:$.right,y:0,width:M-$.right,height:T}},N=K=>{const J=n,ee=1,te=K.width/J,re=K.height/ee;return {scale:Math.min(te,re),scaleLimit:te>re?"height":"width"}},P=xs(Object.entries(I).map(([K,J])=>({direction:K,bbox:J,...N(J)})),["scale",K=>{switch(K.direction){case "top":return $.top;case "bottom":return T-$.bottom;case "left":return $.left;case "right":return M-$.right}}],["desc","desc"])[0];J6e("picked direction",P);const{direction:O,bbox:_,scale:B,scaleLimit:V}=P;let U,G;if(V==="width")U=Math.floor(_.width-(mo.card+mo.border)),G=U/n;else if(V==="height")G=Math.floor(_.height-(mo.card+mo.border)),U=G*n;else throw new Error("unexpected scaleLimit");let H=0,z=0,j=0,W=0;const Y=()=>{j=$.y+$.height/2-z;},Q=()=>{W=$.x+$.width/2-H;},D=()=>{if(H<mo.border){H=mo.border;return}if(H+U>M-mo.border){H=M-mo.border-U;return}},L=()=>{if(z<mo.border){z=mo.border;return}if(z+G>T-mo.border){z=T-mo.border-G;return}};switch(O){case "top":H=$.x+$.width/2-U/2,z=$.top-mo.card-G,D(),Q();break;case "bottom":H=$.x+$.width/2-U/2,z=$.bottom+mo.card,D(),Q();break;case "right":H=$.right+mo.card,z=$.y+$.height/2-G/2,L(),Y();break;case "left":H=$.left-mo.card-U,z=$.y+$.height/2-G/2,L(),Y();break}H=Math.floor(H),z=Math.floor(z),u(true),m({direction:O,elWidth:U,elHeight:G,elPosX:H,elPosY:z,arrowTop:j,arrowLeft:W});}),b=f.useMemo(()=>Yl(g,100),[g]);oo(b),va("resize",b,{target:window}),va("scroll",b,{target:window});const{useScale:y}=Ut().videoCard.videoPreview,S=y?.2:.3,C=f.useMemo(()=>{const $=d?.direction;if(!$)return;const{axis:M,multiplier:T,reverse:R}=uK[$];if(y)return M==="x"?{scale:.5,transformOrigin:`${R} ${d.arrowTop}px`}:{scale:.5,transformOrigin:`${d.arrowLeft}px ${R}`};{let I=30;return $==="top"&&(I=20),M==="x"?{x:-T*I,y:0}:{x:0,y:-T*I}}},[d,y]);return x("div",{...i,ref:a,className:X("fixed",VCe,l?"block":"hidden"),css:d&&ln("width:",d.elWidth,"px;height:",d.elHeight,"px;top:",d.elPosY,"px;left:",d.elPosX,"px;",""),children:l&&F(XT.div,{className:"relative h-100%",initial:{opacity:0,...C},animate:{opacity:1,x:0,y:0,scale:1},transition:{bounce:0,duration:S},children:[d?.direction&&x(nNe,{size:7,direction:d.direction,arrowTop:d.arrowTop,arrowLeft:d.arrowLeft}),x("div",{className:"h-full overflow-hidden rounded-20px bg-white/50% backdrop-blur-10px",css:ln("box-shadow:0px 0px 1px 1px ",xa,";",""),children:t})]})})});function nNe({size:e,direction:t,arrowTop:n,arrowLeft:r}){const{axis:o,multiplier:i,reverse:a}=uK[t],l=f.useMemo(()=>o==="x"?ln`
${t}: 100%;
margin-${t}: -1px;
top: ${n}px;
margin-top: -${e/2}px;
`:ln`
${t}: 100%;
margin-${t}: -1px;
left: ${r}px;
margin-left: -${e/2}px;
`,[e,t,o,n,r]);return x("div",{className:"absolute box-content h-0 w-0",css:[ln("border:",e,"px solid transparent;",""),l,ln`
border-${t}-color: ${xa};
`,"",""]})}const Md=await( mT({volume:void 0,muted:void 0},"large-preview-store")),rNe=function({currentTimeRef:e,ref:t,...n}){const r=U1(t),o=f.useRef(false);oo(()=>{r.current&&(typeof e.current=="number"&&(r.current.currentTime=e.current),typeof Md.volume=="number"&&(r.current.volume=Md.volume),typeof Md.muted=="boolean"&&(r.current.muted=Md.muted)),o.current=true;});const i=Je(()=>{o.current&&(e.current=r.current?.currentTime);}),a=Je(()=>{o.current&&r.current&&(Md.volume=r.current.volume,Md.muted=r.current.muted);});return x("video",{ref:r,...n,onTimeUpdate:i,onVolumeChange:a})},oNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M10.696 17.504c2.639-2.638 5.774-2.565 9.182-.696L32.62 9.745l-.721-4.958L43.213 16.1l-4.947-.71l-7.074 12.73c1.783 3.638 1.942 6.544-.697 9.182l-7.778-7.778L6.443 41.556l11.995-16.31z"})]}),iNe=f.forwardRef(oNe),aNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M39 6H9a3 3 0 0 0-3 3v30a3 3 0 0 0 3 3h30a3 3 0 0 0 3-3V9a3 3 0 0 0-3-3"}),x("path",{d:"M20.5 28v-6.062l5.25 3.03L31 28l-5.25 3.031l-5.25 3.031zM6 15h36m-9-9l-6 9m-6-9l-6 9"})]})]}),sNe=f.forwardRef(aNe);function mB(e){e.current!==void 0&&(clearTimeout(e.current),e.current=void 0);}function dK({shouldFetchPreviewData:e,hasLargePreviewActionButton:t,actionButtonVisible:n,actionButtonProps:r,actionButtonCss:o,bvid:i,cid:a,uniqId:l,recSharedEmitter:u,cardTarget:d,aspectRatioFromItem:m,cover:p,videoCardAsTriggerRef:g}){const{useMp4:b,useVideoCardAsTrigger:y,usePreferredCdn:S}=bt(at.videoCard.videoPreview),C=Ol(void 0),w=xg(async()=>{if(!e||Q6e(C.val))return;const ne=await Z6e({bvid:i,cid:a,useMp4:b,usePreferredCdn:S,aspectRatioFromItem:m});C.set(ne);});Ps(()=>{C.set(void 0);},[b,S]);const $=ga(w,{manual:true,loadingDelay:100}),[M,T]=f.useState(false),R=Ol(void 0),I=Ol(void 0),N=Ol(void 0),P=uM({}),O=Je(()=>N.val?Date.now()-N.val<1200:false),_=f.useRef(void 0),B=f.useRef(void 0),V=Je(()=>{mB(_),mB(B);}),U=Je((ne,ce)=>{T(true),R.set(ne),I.set(ce),u.emit("show-large-preview",l),N.set(void 0);}),G=Je(()=>{T(false),R.set(void 0),I.set(void 0),N.set(Date.now());});go(u,"show-large-preview",ne=>{ne!==l&&(V(),G());});const H=Je(ne=>{if(P.set({...P.val,[ne]:true}),R.val==="click")return;$.run(),V();let ce=0;ne==="video-card-action-button"&&(ce=200),ne==="video-card"&&(ce=1e3),ce?_.current=setTimeout(()=>U("hover",ne),ce):U("hover",ne);}),z=Je(ne=>{if(P.set({...P.val,[ne]:false}),R.val==="click")return;const ce=()=>{P.val.popover||P.val["video-card-action-button"]||G();};V(),ne==="video-card-action-button"||ne==="video-card"||ne==="popover"?B.current=setTimeout(ce,250):ce();}),j=Je(ne=>{V(),R.val==="click"?G():U("click",ne);}),W=Je(()=>{if(K.current)return Math.floor(K.current)}),Y=Je(()=>!!(M||O())),Q=Je(()=>{if(!i)return;const ne=new URL(`https://${Ll.Main}/video/${i}`),ce=W();ce&&ne.searchParams.set("t",ce.toString()),fi(ne.href),L.current?.pause(),G();}),D=f.useMemo(()=>HA({dimensionFromApi:C.state?.dimension})?.aspectRatio??m,[C.state?.dimension]),L=f.useRef(null),K=f.useRef(void 0),J=f.useRef(null),ee=M&&!!C.state?.playUrls?.length,te=ee&&F(tNe,{ref:J,aspectRatio:D,onMouseEnter:ne=>H("popover"),onMouseLeave:ne=>z("popover"),cardDescendantTarget:d,children:[x(rNe,{ref:L,currentTimeRef:K,autoPlay:true,controls:true,loop:true,poster:p,className:"size-full object-contain",children:C.state?.playUrls?.map((ne,ce)=>x("source",{src:ne},ce))}),F("div",{className:"absolute right-10px top-10px flex flex-row-reverse items-center justify-start gap-x-5px",children:[R.state==="click"?x(ka,{inlinePosition:"right",icon:x(xMe,{className:"size-14px"}),tooltip:"关闭",onClick:ne=>{ne.preventDefault(),ne.stopPropagation(),G();}}):x(ka,{inlinePosition:"right",icon:x(iNe,{className:"size-14px"}),tooltip:"固定",onClick:ne=>{ne.preventDefault(),ne.stopPropagation(),j("popover-action-button");}}),x(ka,{inlinePosition:"right",icon:x(DG,{className:"size-14px"}),tooltip:"新窗口打开",onClick:ne=>{ne.preventDefault(),ne.stopPropagation(),Q();}})]})]}),re=t&&e&&x(ka,{css:o,...r,visible:n,active:ee,inlinePosition:"right",icon:$.loading?x(Gj,{className:"size-16px"}):x(sNe,{className:"size-15px"}),tooltip:R.state==="click"&&M?"关闭浮动预览":"浮动预览",onMouseEnter:ne=>H("video-card-action-button"),onMouseLeave:ne=>z("video-card-action-button"),onClick:ne=>{ne.preventDefault(),ne.stopPropagation(),j("video-card-action-button");}},"video-card-action-button");ua("esc",()=>{js()||G();},{exactMatch:true}),h$e(()=>G(),[J,()=>sK.getTargetElement(d)?.closest(B3(Dl,"bili-video-card"))]),va("fullscreenchange",()=>{document.fullscreenElement&&(!M||R.val==="click"||document.fullscreenElement===L.current&&U("click","popover-video-fullscreen-button"));},{target:document});const ie=f.useRef(null),de=g||ie;return va("mouseenter",()=>{!y||!g||H("video-card");},{target:de}),va("mouseleave",()=>{!y||!g||z("video-card");},{target:de}),{largePreviewActionButtonEl:re,largePreviewEl:te,getLargePreviewCurrentTime:W,shouldUseLargePreviewCurrentTime:Y,largePreviewVisible:M,hideLargePreview:G}}const lNe=PEe(xa,.1),Hi={normalBorder:ln("border-color:",TU,";",""),activeBorder:ln("border-color:",xa,";box-shadow:0px 0px 9px 4px ",lNe,";",""),rounded:ln("border-radius:",pA,";",""),bgLv1:ln("background-color:",by,";",""),coverZoomEffect:{name:"dj03ws",styles:".bili-video-card__cover{transform-origin:center center;transition:transform 0.2s ease-out;transform:scale(1.05);}"}},cNe=ln(Hi.activeBorder," &:hover{",Hi.activeBorder,";}","");function uNe(e){const t=`--${io}--separator-color`;return f.useMemo(()=>{if(e)return ln`
${Hi.rounded}
${Hi.normalBorder}
background-color: ${L3};
${t}: ${by};
&:hover {
background-color: ${by};
${t}: ${bwe};
}
/* disable padding */
margin-inline: 0;
.bili-video-card__wrap {
padding: 0;
}
`},[e])}var dNe={name:"7dle4o",styles:"border:1px solid transparent;transition-property:border-color,box-shadow,background-color;transition-duration:0.3s;transition-timing-function:ease-in-out"};function fNe(){const{useDelayForHover:e,style:{videoCard:{useBorder:t,useBorderOnlyOnHover:n,useBoxShadow:r}}}=Ut(),{multiSelecting:o}=bt(Fn),i=QEe();return f.useMemo(()=>[dNe,(o||t&&!i)&&[ln("cursor:pointer;",Hi.rounded," &:hover{",Hi.bgLv1," ",Hi.normalBorder," ",r&&Hi.activeBorder," ",e&&Hi.coverZoomEffect,";}",""),(o||!n)&&Hi.normalBorder]],[t,n,r,e,i,o])}function mNe(e){return e&&[Hi.rounded,Hi.activeBorder]}const hNe="_skeleton-active_wlycr_12";function pNe(e,t){const[n,r]=f.useState(void 0),[o,i]=f.useState(void 0),[a,l]=f.useState(void 0),u=Je(async()=>{if(!t)return;const{enable:d}=fK(e.api);if(!(d||vu(e)&&e.from==="fav-folder"))return;const m=await gu.getVideoFavState(t);m&&(r(m.favFolderNames),i(m.favFolderUrls),l(m.favFolderIds));});return f.useMemo(()=>({folderNames:n,folderUrls:o,folderIds:a,updateFavFolderNames:u}),[n,o,a,u])}function fK(e){const t=![Ye.Separator,Ye.Live,Ye.Fav].includes(e),n=e===Ye.Watchlater||e===Ye.Liked;return {enable:t,enableDetailMenu:n}}function gNe(e,t,n){if(!n)return;const{enable:r,enableDetailMenu:o}=fK(t.api);if(!r)return;const i=e.folderNames??[],a=e.folderUrls??[],l=e.folderIds??[],u=gi([{key:"quick-fav:faved:modify-fav",icon:x(dCe,{className:X(Tn,"color-gate-primary")}),label:`已收藏在 ${(i||[]).map(p=>`「${p}」`).join("")}`,async onClick(){Ro(l.length,"folderIds.length should not be empty"),await zy(l,p=>p6(n,l,p));}},{test:o,key:"quick-fav:faved:browse-fav-folder-in-self-space",icon:x(No,{className:Tn}),label:"去个人空间查看收藏夹",onClick(){a.forEach(p=>{window.open(p,m0());});}}]),d=gi([{key:"quick-fav:unfaved:add-fav",icon:x(pf,{className:Tn}),label:"收藏到",async onClick(){await R6e(async p=>{const g=await gu.addFav(n,p.id);return g&&_t.success(`已加入收藏夹「${p.title}」`),g});}},{test:o,key:"quick-fav:unfaved:add-fav-to-default-folder",icon:x(pf,{className:Tn}),label:"收藏到「默认收藏夹」",async onClick(){await gu.addFav(n)&&_t.success(`已加入收藏夹「${K3}」`);}}]);return !!i.length?u:d}function vNe({ctx:e,item:t,cardData:n,tab:r,multiSelecting:o,multiSelectingAppendix:i,onRemoveCurrent:a,recSharedEmitter:l}){if(!vu(t))return [];const{avid:u}=n;e.folderNames,e.folderUrls;const d=e.folderIds??[];if(t.from==="fav-folder"){const m=o?[{key:"fav:batch-move-fav",label:`移动到其他收藏夹${i}`,icon:x(GH,{className:Tn}),async onClick(){if(!Fn.multiSelecting)return;const p=Z1().filter(w=>vu(w)&&w.from==="fav-folder").toReversed(),g=new Set(p.map(w=>w.folder.id));if(!g.size)return rn("至少选择一项视频");if(g.size>1)return rn("多选移动: 只能批量移动同一源收藏夹下的视频");const b=p[0].folder.id,y=p.map(w=>`${w.id}:${w.type}`),S=p.map(w=>w.uniqId),C=p.map(w=>w.title);await zy([t.folder.id],async w=>{Ro(w,"targetFolder should not be empty");const $=await gu.moveFavs(y,b,w.id);if($)return h0(t.folder.id),h0(w.id),l.emit("remove-cards",[S,C,true]),_t.success(`已移动 ${S.length} 个视频到「${w.title}」收藏夹`),$},false);}}]:[];return gi([{key:"fav:browse-fav-folder-in-self-space",label:"去个人空间查看收藏夹",icon:x(No,{className:Tn}),onClick(){const{id:p}=t.folder,g=OA(p);window.open(g,m0());}},{key:"fav:view-fav-in-new-window",label:"在新窗口中查看收藏夹",icon:x(No,{className:Tn}),onClick(){const{id:p}=t.folder,g=`/?${Iy.FolderIdFull}=${p}`;window.open(g,m0());}},{test:!!u,key:"modify-fav",icon:x(eA,{className:Tn}),label:"编辑收藏",async onClick(){await zy(d,async p=>{const g=await p6(u,d,p);return g&&p?.id!==t.folder.id&&a?.(t,n,true),g},false);}},{key:"remove-fav",label:"移除收藏",icon:x(Uf,{className:Tn}),async onClick(){if(!await gT.confirm({centered:true,title:"移除收藏",content:F(ze,{children:["确定将视频「",t.title,"」",x("br",{}),"从收藏夹「",t.folder.title,"」中移除?"]})}))return;const g=`${t.id}:${t.type}`;await gu.removeFavs(t.folder.id,g)&&(h0(t.folder.id),a?.(t,n));}},...m])}return t.from==="fav-collection"?gi([{key:"open-fav-collection",label:"浏览合集",icon:x(No,{className:Tn}),onClick(){const{id:m}=t.collection,p=r!==nt.Fav||pn.selectedKey==="all"&&pn.usingShuffle?`/?${Iy.CollectionIdFull}=${m}`:KW(m);window.open(p,m0());}}]):[]}const bNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:4,children:[x("path",{d:"M33 7.263A18.9 18.9 0 0 0 24 5C13.507 5 5 13.507 5 24s8.507 19 19 19a18.9 18.9 0 0 0 8-1.761"}),x("path",{strokeLinejoin:"round",d:"M31 30h12m-28-8l7 7l19-18m-4 13v12"})]})]}),yNe=f.forwardRef(bNe),SNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",children:[x("path",{stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M19 20a7 7 0 1 0 0-14a7 7 0 0 0 0 14Z"}),x("path",{d:"M30 35h12z",clipRule:"evenodd"}),x("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"M30 35h12m-15-7h-8.2c-4.48 0-6.72 0-8.432.872a8 8 0 0 0-3.496 3.496C6 34.08 6 36.32 6 40.8V42h21"})]})]}),CNe=f.forwardRef(SNe),xNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",children:[x("path",{fill:"currentColor",fillRule:"evenodd",d:"M15.92 12.799Q16 12.41 16 12a4 4 0 0 0-4.799-3.92zM8.667 9.788a4 4 0 0 0 5.545 5.545l-1.474-1.474a2 2 0 0 1-2.597-2.597z",clipRule:"evenodd"}),x("path",{fill:"currentColor",fillRule:"evenodd",d:"m16.52 17.64l-1.47-1.469c-.972.51-2.002.829-3.05.829c-1.526 0-3.014-.678-4.34-1.632c-1.32-.95-2.396-2.112-3.076-2.938c-.1-.121-.174-.212-.236-.291a2 2 0 0 1-.1-.139q.028-.045.1-.139c.062-.08.136-.17.236-.291c.665-.808 1.71-1.938 2.99-2.875l-1.43-1.43C4.797 8.297 3.723 9.47 3.04 10.3l-.073.088c-.314.375-.737.883-.737 1.613s.423 1.238.737 1.613l.073.088c.74.899 1.94 2.203 3.451 3.29C7.994 18.073 9.891 19 12 19c1.67 0 3.206-.581 4.52-1.36M8.806 5.686C9.79 5.269 10.864 5 12 5c2.11 0 4.006.927 5.509 2.009c1.51 1.087 2.711 2.391 3.45 3.29l.074.088c.314.375.737.883.737 1.613s-.423 1.238-.737 1.613l-.073.088a20.5 20.5 0 0 1-2.015 2.123l-1.416-1.416a18.5 18.5 0 0 0 2.123-2.27a2 2 0 0 0 .1-.138a2 2 0 0 0-.1-.139a14 14 0 0 0-.236-.291c-.68-.826-1.756-1.989-3.075-2.938C15.014 7.678 13.526 7 12 7c-.551 0-1.097.088-1.632.246z",clipRule:"evenodd"}),x("path",{stroke:"currentColor",strokeWidth:2,d:"m5 2l16 16"})]})]}),hB=f.forwardRef(xNe),Tn="size-16px";function wNe(e){const{item:t,cardData:n,tab:r,favContext:o,watchlaterContext:i,hasDislikeEntry:a,onTriggerDislike:l,onRemoveCurrent:u,consistentOpenMenus:d,conditionalOpenMenus:m,multiSelecting:p}=e,{avid:g,bvid:b,cover:y,href:S,recommendReason:C,authorName:w,authorMid:$}=n,{watchlaterItemsOrder:M,filter:{dfHideOpusMids:{enabled:T}},dynamicFeed:{whenViewAll:{enableHideSomeContents:R}}}=Ut(),I=M===bo.AddTimeAsc?"end":"start",N=M===bo.AddTimeAsc?"移到最后":"移到最前",{recSharedEmitter:P}=Ei(),O=Je(()=>{let se=S;S.startsWith("/")&&(se=new URL(S,location.href).href),nu(se);}),_=!!$&&uq(t.api)&&r!==nt.KeepFollowOnly,B=Je(async()=>{if(!$)return _t.error("UP mid 为空!");await tG.add($)&&_t.success(`已加入黑名单: ${w}`);}),V=Je(async()=>{if(!$)return _t.error("UP mid 为空!");const se=`${$}`;if(at.filter.byAuthor.keywords.includes(se))return rn(`已在过滤名单中: ${se}`);await Ua("filter.byAuthor.keywords",{add:[se]}),w&&S$($,w),_t.success(`已加入过滤名单: ${w||$}`);}),U=Ha(n.followed)?r===nt.DynamicFeed&&Ip(t)||r===nt.Live&&Ip(t)?true:Sf(t)||K1(t)?t6(C):false:n.followed,G=U,H=Je(async()=>{if(!$||!await gT.confirm({centered:true,title:"取消关注",content:F(ze,{children:["确定取消关注「",w,"」?"]})}))return;await VRe.unfollow($)&&_t.success("已取消关注");}),z=!!$&&!!w,j=Je(()=>{$&&fi(`/?${pi.Mid}=${$}`);}),W=Je(()=>{$&&fi(`/?${Fa.Mid}=${$}`);}),Y=R&&Vd(t)&&Jt.selectedKey===Dp&&!!$,Q=Je(async()=>{Y&&(await Ua("dynamicFeed.whenViewAll.hideIds",{add:[Cf+$]}),S$($,w||""),_t.success(`在「全部」动态中隐藏【${w}】的动态`));}),D=T&&Vd(t)&&t.modules.module_dynamic.major?.type===mi.MajorType.Opus&&!!$,L=Je(async()=>{if(!$)return _t.error("UP mid 为空!");const se=`${$}`;if(at.filter.dfHideOpusMids.keywords.includes(se))return rn(`已在过滤名单中: ${se}`);await Ua("filter.dfHideOpusMids.keywords",{add:[se]}),w&&S$($,w),_t.success(`已屏蔽【${w||$}】的图文动态`);}),K=!!(Vd(t)&&Os&&Jt.viewingSomeUp&&$),J=f.useMemo(()=>K&&{label:"动态: 从此项开始查看",key:"动态: 从此项开始查看",icon:x(m_,{className:Tn}),onClick(){const se=new URL("/",location.href);se.searchParams.set(pi.Mid,$);const Me=Ds().findIndex(pe=>pe.api===Ye.DynamicFeed&&pe.id_str===t.id_str),ae=Ds()[Me-1]?.id_str||t.id_str;se.searchParams.set(pi.Offset,ae),fi(se.href);}},[K,t,$]),ee=f.useMemo(()=>K&&{icon:x(iCe,{className:Tn}),label:"动态: 从此项开始截止",key:"动态: 从此项开始截止",onClick(){const se=new URL("/",location.href);se.searchParams.set(pi.Mid,$),se.searchParams.set(pi.MinId,t.id_str),fi(se.href);}},[K,t,$]),te=f.useMemo(()=>oM&&X3(t)&&!!t.page&&{key:"space-upload-view-start-from-here",label:`投稿: 从此页开始查看 (当前第${t.page}页)`,icon:x(m_,{className:Tn}),onClick(){const se=new URL(location.href);se.searchParams.set(Fa.InitialPage,t.page.toString()),fi(se.href);}},[oM,t]),re=Vd(t)||X3(t)?t.groupId:void 0,ie=re!==void 0,de=bt(Jt.groups),ne=re!==void 0?de.find(se=>se.tagid===re):void 0,ce=ne?.name,fe=ne?.count;return f.useMemo(()=>{const{watchlaterAdded:se,hasWatchlaterEntry:Me,onToggleWatchlater:ae}=i,pe={type:"divider"},Ce=p?" (多选)":"",xe=gi([{key:"copy-link",label:`复制视频链接${Ce}`,icon:x(tu,{className:Tn}),onClick(){Fn.multiSelecting?KMe():O();}},{test:!!b,key:"copy-bvid",label:`复制 BVID${Ce}`,icon:x(tu,{className:Tn}),onClick(){Fn.multiSelecting?WA():nu(b);}},{test:!!b&&at.__internalEnableCopyBvidInfo,key:"copy-bvid-info",label:`复制 BVID 信息${Ce}`,icon:x(tu,{className:Tn}),onClick(){Fn.multiSelecting?qA():nu(GA(n));}},{test:!!y,key:"view-cover",label:"查看封面",icon:x(No,{className:Tn}),onClick(){if(!y)return;fi(y);}}]),Ae=gi([{test:z&&U,key:"查看「投稿」与「动态」的区别",label:"查看「投稿」与「动态」的区别",icon:x(No,{className:Tn}),onClick:()=>fi("https://github.com/magicdawn/Bilibili-Gate?tab=readme-ov-file#%E5%8F%B3%E9%94%AE%E8%8F%9C%E5%8D%95-%E6%9F%A5%E7%9C%8B-up-%E7%9A%84%E6%8A%95%E7%A8%BF--%E6%9F%A5%E7%9C%8B-up-%E7%9A%84%E5%8A%A8%E6%80%81")},{test:z,key:"查看 UP 的投稿",label:"查看 UP 的投稿",icon:x(py,{className:Tn}),onClick:W},te,{test:z&&U,key:"查看 UP 的动态",label:"查看 UP 的动态",icon:x(hy,{className:Tn}),onClick:j},ee,J,...z&&ie?gi([{type:"divider"},{test:z&&ie&&(fe===void 0||fe<=30),key:"查看分组的投稿",label:"查看分组的投稿",icon:x(py,{className:Tn}),onClick:()=>fi(`/?${Fa.GroupId}=${re}`)},{test:z&&ie,key:"查看分组的动态",label:"查看分组的动态",icon:x(hy,{className:Tn}),onClick:()=>fi(`/?${pi.GroupId}=${re}`)},{type:"divider"}]):[],{test:Me,key:"watchlater",label:se?"移除稍后再看":"稍后再看",icon:se?x(Uf,{className:Tn}):x(nA,{className:Tn}),onClick(){ae();}},{test:Me&&se,key:"watchlater-readd",label:`重新添加稍候再看${r===nt.Watchlater?` (${N})`:""}`,icon:x(yNe,{className:Tn}),async onClick(){const{success:ge}=await ae(void 0,dM);ge&&(_t.success("已重新添加"),r===nt.Watchlater&&P.emit("move-card-to",[t.uniqId,I]));}},...gNe(o,t,g)??[]]),Xe=gi([{test:a,key:"dislike",label:"我不想看",icon:x(ZT,{width:15,height:15}),onClick(){l();}},{test:G,key:"unfollow-up",label:"取消关注",icon:x(CNe,{className:Tn}),onClick:H},{test:Y,key:"hasEntry_addMidTo_dynamicFeedWhenViewAllHideIds",label:"在「全部」动态中隐藏 UP 的动态",icon:x(hB,{className:Tn}),onClick:Q},{test:D,key:"hide-up-opus-dynamic",label:"屏蔽此 UP 的图文动态",icon:x(hB,{className:Tn}),onClick:L},{test:_,key:"blacklist-up",label:"将 UP 加入黑名单",icon:x(I3,{className:Tn}),onClick:B},{test:_,key:"add-up-to-filterlist",label:"将 UP 加入过滤列表",icon:x(I3,{className:Tn}),onClick:V}]),Ne=vNe({ctx:o,item:t,cardData:n,tab:r,multiSelecting:p,multiSelectingAppendix:Ce,onRemoveCurrent:u,recSharedEmitter:P});return gi([...d,!!xe.length&&pe,...xe,!!Ae.length&&pe,...Ae,!!Xe.length&&pe,...Xe,!!Ne.length&&pe,...Ne,!!m.length&&pe,...m])},[t,n,r,i,o,a,G,_,z,Y,D,d,m,p,re,ie,ce,fe,P,u])}function Eh(e){if(e.altKey)return e.stopPropagation(),true}const Fp=nc(()=>Date.now()),$Ne=(Yn().add(1,"minute").startOf("minute").valueOf()-Fp.get())%3e4;setTimeout(()=>{Fp.update(),setInterval(Fp.update,3e4);},$Ne);document.addEventListener("visibilitychange",()=>{document.visibilityState==="visible"&&Fp.update();});const ENe=f.memo(function({ts:t}){return t?z3e(t)?x(MNe,{ts:t}):x(mK,{ts:t}):null});function mK({ts:e}){return f.useMemo(()=>k3e(e),[e])}function MNe({ts:e}){const t=Fp.use();return x(mK,{ts:e},t)}const RNe=X(JQ,"max-w-[calc(100%-6px)] w-max cursor-default overflow-hidden text-ellipsis whitespace-nowrap b-1px b-gate-border rounded-9px b-solid px-8px py-0 text-12px color-gate-primary line-height-17px"),TNe=X("line-clamp-2 mt-10px h-auto whitespace-normal"),ANe=ln("background-color:oklch(from ",xa," calc(l * 0.1 + 0.88) calc(c * 0.25) h);",$U," &{background-color:oklch(from ",xa," calc(l * 0.3 + 0.175) calc(c * 0.25) h);}",""),NNe=ln("color:",xa,";border-radius:2px;border:1px ",xa," solid;line-height:20px;padding:0 10px;transform:scale(0.8);transform-origin:center left;",""),Ab={name:"nux2qa",styles:"font-size:var(--subtitle-font-size);line-height:var(--subtitle-line-height);color:var(--text3);a&:visited{color:var(--text3);}display:inline-flex;width:max-content;max-width:100%;align-items:center;justify-content:flex-start"};var PNe={name:"15xw6zv",styles:"display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1;overflow:hidden;text-overflow:ellipsis;max-width:100%"},INe={name:"feo88y",styles:".bili-video-card .bili-video-card__info--tit>a&{font-family:inherit;font-weight:initial;}"},ONe={name:"1eyh0r6",styles:"text-indent:0!important;.bili-video-card &.bili-video-card__info--tit{padding-right:0;height:auto;max-height:calc(2 * var(--title-line-height));}"};const hK=f.memo(function({item:e,cardData:t,handleVideoLinkClick:n,className:r,gridDisplayMode:o}){const{useBorder:i}=bt(at.style.videoCard),a=Q1(),l=IA(o),{goto:u,href:d,title:m,titleRender:p,pubts:g,pubdateDisplay:b,pubdateDisplayForTitleAttr:y,recommendReason:S,authorName:C,authorFace:w,authorMid:$,appBadge:M,appBadgeDesc:T,rankingDesc:R,liveExtraDesc:I}=t,N=u==="av",P=$?Tg($):d,O=e.api===Ye.Live&&e.live_status===La.Streaming,{data:_}=ga(()=>YTe(e,t),{refreshDeps:[e,t]}),B=f.useMemo(()=>{if(N&&(C||g||_||b||y)){let G;return g||_?G=Yn.unix(g||_).format("YYYY年M月D日 HH:mm"):G=b,[C,y||G].filter(Boolean).join(" · ")}},[N,C,g,_,b,y]),V=ur(RNe,l&&TNe);return F("div",{className:X(l?"pt-5px":"pt-15px","flex gap-x-5px overflow-hidden px-5px",i?"mb-10px":"mb-5px",r),children:[!!$&&F("a",{href:P,target:a,className:X("relative flex-center self-start rounded-full p-1px ring-1px",O?"ring-gate-primary":"ring-gate-border"),children:[w?x(Yc,{src:n6(w)}):x(Yc,{children:C?.[0]||T?.[0]||""}),O&&x(tA,{active:true,className:"absolute bottom-0 right-0 size-12px rounded-full bg-gate-primary"})]}),F("div",{className:"ml-5px flex flex-1 flex-col gap-y-4px overflow-hidden",children:[x("h3",{className:"bili-video-card__info--tit",title:m,css:ONe,children:x("a",{onClick:n,onContextMenu:Eh,href:d,target:a,rel:"noopener",css:INe,children:p??m})}),U()]})]});function U(){const G=!!S&&x("div",{title:S,css:ANe,className:V,children:S}),H=()=>{let z;return g||_?z=x(ENe,{ts:g||_}):b&&(z=b),F(ze,{children:[F("a",{className:"bili-video-card__info--owner",href:P,target:a,title:B,css:Ab,onContextMenu:Eh,children:[x("span",{className:"bili-video-card__info--author",children:C}),!!z&&F("span",{className:"bili-video-card__info--date",children:[e6,z]})]}),G]})};return N?H():M||T?F("a",{className:"bili-video-card__info--owner",css:Ab,href:d,target:a,onContextMenu:Eh,children:[!!M&&x("span",{css:NNe,children:M}),!!T&&x("span",{children:T})]}):QW(e)&&R?x("div",{css:Ab,children:R}):Ip(e)||K1(e)&&e.goto===ws.Live?F(ze,{children:[F("a",{css:[Ab,PNe,"",""],href:P,target:a,title:(C||"")+(I||""),onContextMenu:Eh,children:[C,I&&x("span",{className:"ml-4px",children:I})]}),G]}):H()}}),DNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M24 44c11.046 0 20-8.954 20-20S35.046 4 24 4S4 12.954 4 24s8.954 20 20 20Z"}),x("path",{strokeLinecap:"round",d:"M24 29c5 0 7 4 7 4H17s2-4 7-4m8-12l-3 3l3 3m-16-6l3 3l-3 3"})]})]}),_Ne=f.forwardRef(DNe),BNe=f.memo(function({loading:t}){return F("div",{className:X("bili-video-card__skeleton",{hide:!t,[hNe]:t}),children:[x("div",{className:"bili-video-card__skeleton--cover",style:{borderRadius:pA}}),F("div",{className:"bili-video-card__skeleton--info px-5px",children:[x("div",{className:"bili-video-card__skeleton--avatar size-32px rounded-full"}),F("div",{className:"bili-video-card__skeleton--right ml-10px flex-1",children:[x("p",{className:"bili-video-card__skeleton--text"}),x("p",{className:"bili-video-card__skeleton--text short"}),x("p",{className:"bili-video-card__skeleton--light"}),x("p",{className:"bili-video-card__skeleton--text tiny"})]})]})]})}),vi={wrapper:"h-full flex flex-col overflow-hidden",cover:"relative aspect-16/9 rounded-t-6px",coverInner:"absolute left-0 top-0 h-full w-full flex flex-col items-center justify-center gap-y-2",dislikeReason:"text-center font-size-20px",dislikeDesc:"text-center text-16px",action:"relative flex-1",actionInner:"absolute left-0 top-0 h-full w-full flex items-center justify-center b-t-1px b-t-$bilibili-gate--separator-color b-t-solid transition-duration-300 transition-property-[border-color]",actionButton:"flex cursor-pointer items-center rounded-lg bg-transparent p-15px text-16px color-inherit"},LNe=f.memo(function({item:t,cardData:n,dislikedReason:r,emitter:o=Kj}){const i=Je(async()=>{if(!r?.id)return;let a=false,l="",u;try{({success:a,message:l}=await K6e(t,r.id));}catch(d){u=d;}if(u)return console.error(u.stack||u),nU();a?(_t.success("已撤销"),p6e(t.param)):_t.error(l||Up);});return go(o,"cancel-dislike",i),F("div",{className:vi.wrapper,children:[x("div",{className:vi.cover,children:F("div",{className:vi.coverInner,children:[x(_Ne,{className:"size-32px"}),x("div",{className:vi.dislikeReason,children:r?.name}),x("div",{className:vi.dislikeDesc,children:r?.toast||"将减少此类内容推荐"})]})}),x(pK,{item:t,cardData:n,onClick:i})]})});function pK({item:e,cardData:t,onClick:n}){return F("div",{className:vi.action,children:[x(hK,{item:e,cardData:t,className:"invisible"}),x("div",{className:vi.actionInner,children:F("button",{className:vi.actionButton,onClick:n,children:[x(gy,{className:"mr-4px mt--2px size-16px"}),"撤销"]})})]})}const pB=f.memo(function({item:t,cardData:n,blockType:r}){const{authorMid:o,authorName:i}=n,a=r==="blacklist"?"已拉黑":"已加入过滤列表",l=Je(()=>r==="blacklist"?u():d()),u=Je(async()=>{if(!o)return;await tG.remove(o)&&_t.success(`已移出黑名单: ${i}`);}),d=Je(()=>{if(!o)return;const m=at.filter.byAuthor.keywords.filter(p=>tS(p).mid===o);Ua("filter.byAuthor.keywords",{remove:m}),_t.success(`已移出过滤列表: ${i}`);});return F("div",{className:vi.wrapper,children:[x("div",{className:vi.cover,children:F("div",{className:vi.coverInner,children:[x(I3,{className:"size-32px"}),x("div",{className:vi.dislikeReason,children:a}),F("div",{className:vi.dislikeDesc,children:["UP: ",i]})]})}),x(pK,{item:t,cardData:n,onClick:l})]})}),zNe=X("pointer-events-none absolute inset-0 overflow-hidden",MCe,"rounded-b-none rounded-t-gate-video-card"),kNe=f.memo(function({videoDuration:t,pvideo:n,progress:r,t:o,className:i,ref:a,...l}){const u=f.useRef(null),[d,m]=f.useState(()=>({width:0,height:0}));oo(()=>{const S=u.current?.getBoundingClientRect();S&&m({width:S.width,height:S.height});});const p=f.useMemo(()=>{function S(){return typeof r=="number"&&!Number.isNaN(r)?r:0}return ff(S()??0,0,1)},[r]),g=f.useMemo(()=>o??Math.floor((t||0)*p),[o,t,p]),b=Je(()=>g);f.useImperativeHandle(a,()=>({getT:b}),[b]);const y={progress:p,t:g,pvideo:n,elWidth:d.width,elHeight:d.height};return x("div",{...l,ref:u,className:X(zNe,i),children:!!(n&&d.width&&d.height&&p)&&x(FNe,{...y})})}),FNe=f.memo(function({t,progress:n,pvideo:r,elWidth:o,elHeight:i}){let a=f.useMemo(()=>HNe(r?.index||[],t)??0,[r,t]);const{img_x_len:l,img_y_len:u,img_x_size:d,img_y_size:m}=r,p=u*l;a=a+1;const g=Math.floor(a/p),b=a-g*p,y=r.image?.[g]||"",S=Math.floor(b/l)+1,C=b-(S-1)*l,w=o*l,$=i*u,M=(S-1)*i,T=(C-1)*o;return x("div",{className:"size-full",style:{backgroundColor:"black",backgroundImage:`url(${y})`,backgroundPosition:`-${T}px -${M}px`,backgroundSize:`${w}px ${$}px`},children:x(gK,{progress:n})})});function gK({progress:e,className:t,...n}){return x("div",{...n,"data-role":"track",className:X("absolute inset-x-0 bottom-0 h-2px bg-gate-bg-lv1",t),children:x("div",{"data-role":"bar",className:"h-full bg-gate-primary",style:{width:`${e*100}%`}})})}function HNe(e,t){let n=VNe(e,t);if(n!==-1)return n;t>e.at(-1)&&(n=e.length-1);}function VNe(e,t){let n=0,r=e.length-1,o=-1;for(;n<=r;){const l=Math.floor((n+r)/2),u=e[l];if(t===u)return l;u<t?(n=l+1,o=l):r=l-1;}if(o===-1)return -1;const i=e[o],a=e[o+1]??0;return i<t&&t<a?o:-1}const jNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 256 256",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"currentColor",d:"M248 80a28 28 0 1 0-51.12 15.77l-26.79 33L146 73.4a28 28 0 1 0-36.06 0l-24.03 55.34l-26.79-33a28 28 0 1 0-26.6 12L47 194.63A16 16 0 0 0 62.78 208h130.44A16 16 0 0 0 209 194.63l14.47-86.85A28 28 0 0 0 248 80M128 40a12 12 0 1 1-12 12a12 12 0 0 1 12-12M24 80a12 12 0 1 1 12 12a12 12 0 0 1-12-12m196 12a12 12 0 1 1 12-12a12 12 0 0 1-12 12"})]}),UNe=f.forwardRef(jNe),WNe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("circle",{cx:12,cy:24,r:3,fill:"currentColor"}),x("circle",{cx:24,cy:24,r:3,fill:"currentColor"}),x("circle",{cx:36,cy:24,r:3,fill:"currentColor"})]}),GNe=f.forwardRef(WNe),vK="pointer-events-none h-19px flex-center whitespace-nowrap rounded-2px bg-gate-primary px-4px text-center text-12px color-white";function bK({children:e,className:t}){return x("span",{className:ur(vK,t),children:e})}function yK(e){const{topMarkIcon:t,topMarkText:n}=e;return !!(t||n)}function qNe({cardData:e}){if(!yK(e))return;const{topMarkIcon:t,topMarkText:n}=e,r=!!t;return F(bK,{className:X("min-w-32px",r?"pl-4px pr-6px":"px-4px"),children:[r&&x(iK,{src:`${t}@!web-dynamic`,className:"h-16px w-16px"}),n]})}function KNe(e){return ["#FFD700","#C0C0C0","#B36700"][e-1]??xa}function YNe({item:e}){const t=e.rankingNo<=3,n=x(UNe,{});let r=false,o=[];BA(e)&&e.others?.length&&(r=true,o=e.others);const i=`「${e.rankTab.name}」排行第 ${e.rankingNo} 名`,{triggerRef:a,tooltipEl:l}=X1({inlinePosition:"left",tooltip:i,tooltipClassName:"left--2px"}),u="relative size-28px flex-center whitespace-nowrap rounded-full text-14px color-white",d=f.useMemo(()=>({backgroundColor:KNe(e.rankingNo)}),[e.rankingNo]),m=kG();return F(ze,{children:[F("div",{ref:a,className:u,style:d,children:[t?n:x("span",{style:{marginLeft:-1},children:e.rankingNo}),l]}),r&&x(tc,{placement:"bottomLeft",menu:{items:[{type:"group",label:"「其他上榜视频」",children:o.map(p=>({key:p.bvid,label:p.title,onClick(){const g=new URL(`/video/${p.bvid}`,location.href).href;m?fi(g):location.href=g;}}))}]},children:x("div",{className:u,style:d,children:x(GNe,{})})})]})}function XNe(){return F(bK,{children:[x(tA,{active:true,className:"size-14px"}),"直播中"]})}function QNe({item:e}){const t=f.useMemo(()=>Vd(e)?"动态":XW(e)?"稍后再看":vu(e)?e.from==="fav-folder"?"收藏夹":"合集":e.api,[e]),n=f.useMemo(()=>{if(vu(e)&&e.from==="fav-collection")return e.volTooltip},[e]),{triggerRef:r,tooltipEl:o}=X1({inlinePosition:"left",tooltip:n});return F("span",{ref:r,className:ur(vK,"pointer-events-auto"),children:[t,o]})}function ZNe({vol:e,volTooltip:t}){const{triggerRef:n,tooltipEl:r}=X1({inlinePosition:"left",tooltip:t,tooltipClassName:"left--2px"});return F("div",{ref:n,className:"relative h-24px min-w-24px flex-center whitespace-nowrap rounded-8px bg-gate-primary px-6px text-center text-14px color-white",children:[e,r]})}const JNe=x(ZT,{className:"size-16px"});function ePe({item:e,authed:t,actionButtonVisible:n}){const r=Sf(e)&&!!e.three_point?.dislike_reasons?.length,o=Je(async l=>{if(l?.preventDefault(),l?.stopPropagation(),!r)return e.api!==Ye.AppRecommend?_t.error("当前视频不支持提交「我不想看」"):void 0;if(!t)return rn("请先获取 access_key !");e?.param&&Ly.has(e.param)||await y6e(e.three_point?.dislike_reasons||[],i);}),i=xg(async l=>{if(!Sf(e))return;let u=false,d="",m;try{({success:u,message:d}=await q6e(e,l.id));}catch(p){m=p;}return m?(console.error(m.stack||m),nU()):(u?(_t.success("已标记不想看"),Ly.set(e.param,{...l})):_t.error(d||Up),u)});return {dislikeButtonEl:r&&x(ka,{visible:n,inlinePosition:"left",icon:JNe,tooltip:"我不想看",onClick:o}),hasDislikeEntry:r,onTriggerDislike:o}}const tPe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("circle",{cx:12,cy:12,r:10,fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2})]}),nPe=f.forwardRef(tPe),rPe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 24 24",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,children:[x("circle",{cx:12,cy:12,r:10}),x("path",{d:"m9 12l2 2l4-4"})]})]}),oPe=f.forwardRef(rPe),iPe=nPe,aPe=oPe;function sPe({multiSelecting:e,multiSelected:t,uniqId:n}){const r=Je(l=>{const{selectedIdSet:u,multiSelecting:d}=Fn;if(!d)return;l?.preventDefault(),l?.stopPropagation();const m=!!l?.shiftKey;Fn.shiftMultiSelectAnchorUniqId??=n,m||(Fn.shiftMultiSelectAnchorUniqId=n),m?YMe(Fn.shiftMultiSelectAnchorUniqId,n):t?u.delete(n):u.add(n);}),o=e&&x("div",{onClick:r,className:X("absolute inset-0 flex items-center justify-center bg-black/10",RCe)}),a=e&&x(t?aPe:iPe,{onClick:r,className:X("size-30px cursor-pointer text-white [&_g]:fill-inherit",t?"fill-gate-primary":"fill-none")});return {toggleMultiSelect:r,multiSelectBgEl:o,multiSelectEl:a}}function lPe(...e){}function cPe({uniqId:e,recSharedEmitter:t,title:n,active:r,videoDuration:o,tryFetchImagePreviewData:i,imagePreviewDataBox:a,autoPreviewWhenHover:l,videoPreviewWrapperRef:u}){const d=Je(()=>{const L=a.val?.videoshotJson?.data;return !!(L?.index?.length&&L?.image?.length)}),[m,p]=f.useState(false),[g,b]=v9(),[y,S]=v9(),C=Je(()=>g||0),[w,$]=f.useState(false),M=Ol(false),T=Ol(false),R=uM(false),[I,N]=f.useState(void 0),P=L=>{const K=u.current?.getBoundingClientRect();if(!K)return;const{x:J,width:ee}=K,te=L.pageX-window.scrollX-J;N(te/ee);};va("mouseenter",async L=>{t.emit("mouseenter",e),M.set(true),P(L);const K=i(),J=800;let ee;at.useDelayForHover&&(ee=gn(J)),await Promise.all([K,ee].filter(Boolean)),M.val&&(T.set(true),l&&!_.val&&d()&&G(true));},{target:u});const O=Je(()=>{M.set(false),T.set(false);});va("mouseleave",O,{target:u}),go(t,"mouseenter",L=>{L!==e&&O();}),va("mousemove",L=>{$(true),M.val&&(!T.val||!l)&&P(L),l||V.stop();},{target:u});const _=uM(void 0),B=f.useRef(void 0),V=uPe({startByHoverBox:R,isHoveringBox:M,active:r,mouseMoved:w,idBox:_,autoPreviewWhenHover:l,setAutoPreviewing:p,setPreviewT:S,setPreviewProgress:b,onResume(){B.current?.();}}),U=Je(async()=>{if(!_.val){await i(),d()&&G(false);return}V.togglePaused();}),G=Je(L=>{R.set(L),$(false),V.reset(),V.stop(true),p(true),b(re=>re===void 0?0:re),S(void 0);const K=8e3;let J=performance.now(),ee=0;B.current=()=>{J=performance.now()-C()*K;};function te(re){if(V.shouldStop())return V.stop();if(!V.paused){const ie=performance.now(),de=ie-J,ne=ff(de%K/K,0,1);if(b(ne),(!ee||ie-ee>=at.autoPreviewUpdateInterval)&&(b(ne),ee=ie,o)){const ce=ff(Math.round(ne*o),0,o);S(ce);}}_.val=requestAnimationFrame(te);}_.val=requestAnimationFrame(te);}),H=M.state,z=T.state,j=a.state?.videoshotJson?.data,W=!!j?.image?.length&&!!o&&(z||r)&&(l?m:true),Y=f.useRef(null);let Q,D;if(W){const L={videoDuration:o,pvideo:j};l?Q={...L,progress:g,t:y}:Q={...L,progress:I},D=x(kNe,{ref:Y,...Q});}return {onHotkeyPreviewAnimation:U,onStartPreviewAnimation:G,autoPreviewing:m,mouseProgress:I,previewProgress:g,previewT:y,isHovering:H,isHoveringAfterDelay:z,shouldShowPreview:W,previewImageRef:Y,previewImgProps:Q,previewImageEl:D}}function uPe({startByHoverBox:e,isHoveringBox:t,idBox:n,active:r,mouseMoved:o,autoPreviewWhenHover:i,setAutoPreviewing:a,setPreviewT:l,setPreviewProgress:u,onResume:d}){const m=cW(),p=Je(()=>{if(m.current)return true;if(e.val){if(!t.val)return true}else if(!r||o)return true;return false}),g=Je((S=false)=>{S||lPe("stopAnimation: %o",{autoPreviewWhenHover:i,unmounted:m.current,isHovering:t.val,active:r,mouseMoved:o}),n.val&&cancelAnimationFrame(n.val),n.val=void 0,a(false),u(void 0),l(void 0),y.reset();}),b=f.useRef(false),y=f.useMemo(()=>({shouldStop:p,stop:g,get paused(){return b.current},set paused(S){b.current=S;},togglePaused(){const S=this.paused;this.paused=!this.paused,S&&d?.();},reset(){this.paused=false;}}),[p,g,b,d]);return y}function dPe({item:e,cardData:t,onRemoveCurrent:n,actionButtonVisible:r,watchlaterAdded:o}){const{avid:i,bvid:a}=t,l=f.useMemo(()=>Sf(e)||K1(e)?e.goto==="av":e.api===Ye.Rank?t.goto==="av":e.api===Ye.Live?false:!!a,[e,t]),u=ga((C,w)=>C(w),{manual:true}),d=SA(o),m=Je(async(C,w)=>{if(C?.preventDefault(),C?.stopPropagation(),u.loading)return {success:false};if(!i||!a)return {success:false};w??=o?G6e:dM;const $=await u.runAsync(w,i),M=w===dM;return $&&(M?yu.bvidSet.add(a):yu.bvidSet.delete(a),e.api===Ye.Watchlater?M||(await gn(250),n?.(e,t)):_t.success(`已${M?"添加":"移除"}稍后再看`)),{success:$,targetState:M}}),p=18,g=u.loading?x(Gj,{className:"size-16px"}):e.api===Ye.Watchlater?o?x(Uf,{className:"size-16px"}):x(Mp,{size:p,useAnimation:d===true}):o?x(Mp,{size:p,useAnimation:d===false}):x(nA,{className:"size-20px"}),b=e.api===Ye.Watchlater?o?"已添加稍后再看, 点击移除":"已移除稍后再看":o?"已添加稍后再看, 点击移除":"稍后再看",y=l&&x(ka,{visible:r,inlinePosition:"right",icon:g,tooltip:b,onClick:m});return {context:f.useMemo(()=>({watchlaterAdded:o,hasWatchlaterEntry:l,onToggleWatchlater:m}),[m,o,l]),watchlaterButtonEl:y}}const gB=f.memo(function({style:t,className:n,item:r,loading:o,active:i,onRemoveCurrent:a,emitter:l,recSharedEmitter:u,tab:d,baseCss:m,gridDisplayMode:p,multiSelecting:g,...b}){o=o??!r;const y=f.useMemo(()=>r&&em(r),[r]),S=h6e(r?.api===Ye.AppRecommend?r.param:void 0),C=S3e(y?.authorMid),w=k6e(y?.authorMid),$=HTe(y?.bvid),M=UMe(r?.uniqId),T=!!S,R=C,I=w,P=uNe(T||R||I),O=X("bili-video-card",Dl,{[EL]:i},"relative",n),_=[m,P,IA(p)&&O3.card,g&&M&&cNe];return x("div",{"data-bvid":y?.bvid,style:t,className:O,css:_,...b,children:o?x(BNe,{loading:o}):r&&y&&(T?x(LNe,{item:r,cardData:y,emitter:l,dislikedReason:S}):R?x(pB,{item:r,cardData:y,blockType:"blacklist"}):I?x(pB,{item:r,cardData:y,blockType:"filter"}):x(mPe,{item:r,cardData:y,active:i,emitter:l,recSharedEmitter:u,tab:d,onRemoveCurrent:a,watchlaterAdded:$,gridDisplayMode:p,multiSelecting:g,multiSelected:M}))})});var fPe={name:"vpmszz",styles:"background-color:unset;position:static;height:100%"};const mPe=f.memo(function({item:t,cardData:n,tab:r,active:o=false,onRemoveCurrent:i,emitter:a=Kj,recSharedEmitter:l=Tq,watchlaterAdded:u,gridDisplayMode:d,multiSelecting:m=false,multiSelected:p}){const{accessKey:g,style:{videoCard:{useBorder:b,useBorderOnlyOnHover:y}},videoCard:{actions:S,imgPreview:{enabled:C,autoPreviewWhenHover:w,disableWhenMultiSelecting:$}},spaceUpload:{showVol:M},__internalEnableCopyBvidInfo:T}=Ut(),{avid:R,bvid:I,cid:N,goto:P,href:O,title:_,cover:B,duration:V,durationStr:U,recommendReason:G,statItems:H,authorName:z,authorMid:j}=n,W=!!g,Y=P==="av",Q=["av","bangumi","picture","live","opus"];Q.includes(P)||Ko(`none (${Q.join(",")}) goto type %s`,P,t);const D=IA(d),L=f.useMemo(()=>HA({item:t})?.aspectRatio,[t]),K=f.useMemo(()=>!(!I||!I.startsWith("BV")||P!=="av"),[I,P]),J=!(!C||$&&m),ee=Ol(void 0),te=xg(async()=>{if(!K||!J||X6e(ee.val))return;const Re=await Y6e(I);ee.set(Re),jn(Re.videoshotJson)||re(Re.videoshotJson);}),re=OG(Re=>{ca.warning({title:`${Re.message} (code: ${Re.code})`,description:`${_} (${I})`,duration:2});},3,false),ie=f.useRef(null),de=f.useRef(null),ne=b&&!D?ie:de,{onStartPreviewAnimation:ce,onHotkeyPreviewAnimation:fe,isHovering:se,previewImageEl:Me}=cPe({uniqId:t.uniqId,recSharedEmitter:l,title:_,active:o,videoDuration:V,tryFetchImagePreviewData:te,imagePreviewDataBox:ee,autoPreviewWhenHover:w,videoPreviewWrapperRef:ne});Ps(()=>{o&&(g6(`${EM}_activeItem`,t),at.videoCard.imgPreview.autoPreviewWhenKeyboardSelect&&te().then(()=>{ce(false);}));},[o]);const ae=o||se,{watchlaterButtonEl:pe,context:Ce}=dPe({item:t,cardData:n,onRemoveCurrent:i,actionButtonVisible:ae,watchlaterAdded:u}),{dislikeButtonEl:xe,hasDislikeEntry:Ae,onTriggerDislike:Xe}=ePe({item:t,authed:W,actionButtonVisible:ae}),{largePreviewActionButtonEl:Ne,largePreviewEl:ue,shouldUseLargePreviewCurrentTime:ge,getLargePreviewCurrentTime:Pe,largePreviewVisible:je,hideLargePreview:qe}=dK({shouldFetchPreviewData:K,actionButtonVisible:ae,hasLargePreviewActionButton:S.showLargePreview,bvid:I,cid:N,uniqId:t.uniqId,recSharedEmitter:l,cardTarget:ie,aspectRatioFromItem:L,cover:B,videoCardAsTriggerRef:ne}),Ue=pNe(t,R),{onOpenWithMode:et,handleVideoLinkClick:rt,consistentOpenMenus:Ke,conditionalOpenMenus:_e,openInPopupActionButtonEl:We,onOpenInPopup:Ze}=IMe({href:O,item:t,cardData:n,actionButtonVisible:ae,hasOpenInPopupActionButton:S.openInPipWindow,getLargePreviewCurrentTime:Pe,hideLargePreview:qe,shouldUseLargePreviewCurrentTime:ge}),{multiSelectBgEl:Be,multiSelectEl:Oe,toggleMultiSelect:lt}=sPe({multiSelecting:m,multiSelected:p,uniqId:t.uniqId}),It=Je(Re=>{b&&(Re.target.closest(".ant-dropdown-menu")||Re.target.closest("a")||et());});go(a,"open",()=>et()),go(a,"open-in-popup",Ze),go(a,"open-with-large-preview-visible",()=>{je&&(qe(),et());}),go(a,"toggle-watch-later",()=>{Ce.onToggleWatchlater();}),go(a,"trigger-dislike",()=>{Xe();}),go(a,"start-preview-animation",ce),go(a,"hotkey-preview-animation",fe);const mt=wNe({item:t,cardData:n,tab:r,watchlaterContext:Ce,favContext:Ue,hasDislikeEntry:Ae,onTriggerDislike:Xe,onRemoveCurrent:i,consistentOpenMenus:Ke,conditionalOpenMenus:_e,multiSelecting:m}),Bt=Je(Re=>{Re&&Ue.updateFavFolderNames();}),xt=yK(n),Tt=QW(t),ut=Ip(t)&&t.live_status===La.Streaming||K1(t)&&t.goto===ws.Live,dt=r===nt.AppRecommend&&!Sf(t)&&!Ip(t),gt=X3(t)&&M||vu(t)&&!!t.vol&&!dt,Fe=T&&I&&x(ka,{visible:ae,inlinePosition:"right",icon:x(tu,{className:"size-14px"}),tooltip:"复制 BVID 信息",onClick:Re=>{Re.stopPropagation(),Re.preventDefault(),nu(GA(n));}}),Qe=F(ze,{children:[m&&Oe,xe,xt&&x(qNe,{cardData:n}),Tt&&x(YNe,{item:t}),ut&&x(XNe,{}),dt&&x(QNe,{item:t}),gt&&!!t.vol&&x(ZNe,{vol:t.vol,volTooltip:vu(t)?t.volTooltip:void 0})]}),ye=F(ze,{children:[pe,Fe,We,Ne]}),be=!aB(Qe),Se=!aB(ye),he=ur("left-top-marks",_p.topContainer("left"),m&&"gap-x-10px"),De=XW(t)&&t.progress>0?x(gK,{progress:t.progress/t.duration,className:X("h-3px",ECe)}):void 0,$e=`.${$a} .${Dl}`,ke=f.useMemo(()=>[ln($e," &{overflow:hidden;border-radius:",pA,";transition:border-radius 0.2s ease;}",""),!D&&[(o||m||b&&!y)&&ln($e," &{border-bottom-left-radius:0;border-bottom-right-radius:0;}",""),b&&ln($e,":hover &{border-bottom-left-radius:0;border-bottom-right-radius:0;}","")]],[D,o,m,b,y]),Ge=f.useMemo(()=>b&&!y||m?false:!b||b&&y&&!se,[b,y,se,m]),ot=Q1(),ht=F("a",{ref:de,href:O,target:ot,className:X(ML,"relative isolate block overflow-hidden",Ge&&"ring-1px ring-gate-border"),css:[ke,D&&O3.cover,"",""],onClick:rt,onContextMenu:Re=>{Eh(Re)||Re.preventDefault();},children:[x("div",{className:"bili-video-card__image",style:{aspectRatio:"16 / 9"},children:B?x("div",{className:"bili-video-card__image--wrap",children:x(iK,{src:`${B}@672w_378h_1c_!web-home-common-cover`,className:"bili-video-card__cover v-img",style:{borderRadius:0},imgProps:{alt:_}})}):x("div",{className:"size-full flex-center",children:x("div",{className:"line-clamp-3 my-auto px-4 py-2 text-center text-1.2em line-height-snug",children:_})})}),F("div",{className:"bili-video-card__stats",css:ln($e," &{pointer-events:none;border-radius:0;}",""),children:[x("div",{className:"bili-video-card__stats--left gap-x-4px xl:gap-x-8px",children:H.map(({field:Re,value:ct})=>x(tMe,{field:Re,value:ct},Re))}),x("span",{className:"bili-video-card__stats__duration relative top-0.5px",children:Y&&U})]}),De,J&&Me,Be,be&&x("div",{className:he,children:Qe}),Se&&x("div",{className:X("right-actions",_p.topContainer("right")),children:ye})]}),$t=x(hK,{item:t,cardData:n,gridDisplayMode:d,handleVideoLinkClick:m?lt:rt}),Rt=x(ze,{children:ue});function Ot(Re){return x(tc,{trigger:["contextMenu"],onOpenChange:Bt,getPopupContainer:()=>ie.current?.closest(`.${Dl}`)??document.body,rootClassName:X(jCe,jX),menu:{items:mt,className:"w-max"},children:Re})}function Sn(Re){return x("div",{className:"bili-video-card__wrap",ref:ie,css:[fPe,D&&O3.cardWrap,"",""],onClick:m?lt:It,onContextMenu:ct=>{b&&ct.preventDefault();},children:Re})}const Hn=b&&!D?Ot(Sn(F(ze,{children:[ht,$t]}))):Sn(F(ze,{children:[Ot(ht),$t]}));return F(ze,{children:[Hn,Rt]})});var R$={};const hPe=OQ(Mwe);var T$={},vB;function SK(){return vB||(vB=1,(function(e){Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var t=Xl();function n(r){var o=(0, t.useRef)(r);return o.current=r,o}e.default=n;})(T$)),T$}var A$={},N$={},P$={},I$={},O$={},bB;function pPe(){return bB||(bB=1,(function(e){Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var t=false;e.default=t;})(O$)),O$}var yB;function gPe(){return yB||(yB=1,(function(e){var t=Ma();Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var n=t(aK()),r=Xl(),o=t(SK()),i=v6(),a=t(pPe()),l=function(d){a.default&&((0, i.isFunction)(d)||console.error("useUnmount expected parameter is a function, got ".concat((0, n.default)(d))));var m=(0, o.default)(d);(0, r.useEffect)(function(){return function(){m.current();}},[]);};e.default=l;})(I$)),I$}var D$={},SB;function vPe(){return SB||(SB=1,(function(e){Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;function t(n,r){if(n===r)return true;for(var o=0;o<n.length;o++)if(!Object.is(n[o],r[o]))return false;return true}e.default=t;})(D$)),D$}var CB;function bPe(){return CB||(CB=1,(function(e){var t=Ma();Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var n=Xl(),r=t(gPe()),o=t(vPe()),i=b6(),a=function(u){var d=function(p,g,b){var y=(0, n.useRef)(false),S=(0, n.useRef)([]),C=(0, n.useRef)([]),w=(0, n.useRef)(void 0);u(function(){var $,M=Array.isArray(b)?b:[b],T=M.map(function(R){return (0, i.getTargetElement)(R)});if(!y.current){y.current=true,S.current=T,C.current=g,w.current=p();return}(T.length!==S.current.length||!(0, o.default)(S.current,T)||!(0, o.default)(C.current,g))&&(($=w.current)===null||$===void 0||$.call(w),S.current=T,C.current=g,w.current=p());}),(0, r.default)(function(){var $;($=w.current)===null||$===void 0||$.call(w),y.current=false;});};return d};e.default=a;})(P$)),P$}var xB;function yPe(){return xB||(xB=1,(function(e){var t=Ma();Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var n=Xl(),r=t(bPe()),o=(0, r.default)(n.useEffect);e.default=o;})(N$)),N$}var mh={},wB;function SPe(){if(wB)return mh;wB=1;var e=Ma();Object.defineProperty(mh,"__esModule",{value:true}),mh.depsEqual=void 0;var t=e(aW());return mh.depsEqual=function(r,o){return r===void 0&&(r=[]),o===void 0&&(o=[]),(0, t.default)(r,o)},mh}var $B;function CPe(){return $B||($B=1,(function(e){var t=Ma();Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var n=Xl(),r=t(yPe()),o=SPe(),i=function(l,u,d){var m=(0, n.useRef)(void 0),p=(0, n.useRef)(0);(0, o.depsEqual)(u,m.current)||(p.current+=1),m.current=u,(0, r.default)(l,[p.current],d);};e.default=i;})(A$)),A$}var _$={},EB;function xPe(){return EB||(EB=1,(function(e){Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var t=/(mac|iphone|ipod|ipad)/i.test(typeof navigator<"u"?navigator?.platform:"");e.default=t;})(_$)),_$}var MB;function wPe(){return MB||(MB=1,(function(e){var t=Ma();Object.defineProperty(e,"__esModule",{value:true}),e.default=void 0;var n=hPe,r=t(SK()),o=v6(),i=b6(),a=t(CPe()),l=t(xPe()),u={0:48,1:49,2:50,3:51,4:52,5:53,6:54,7:55,8:56,9:57,backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,pausebreak:19,capslock:20,esc:27,space:32,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,a:65,b:66,c:67,d:68,e:69,f:70,g:71,h:72,i:73,j:74,k:75,l:76,m:77,n:78,o:79,p:80,q:81,r:82,s:83,t:84,u:85,v:86,w:87,x:88,y:89,z:90,leftwindowkey:91,rightwindowkey:92,meta:l.default?[91,93]:[91,92],selectkey:93,numpad0:96,numpad1:97,numpad2:98,numpad3:99,numpad4:100,numpad5:101,numpad6:102,numpad7:103,numpad8:104,numpad9:105,multiply:106,add:107,subtract:109,decimalpoint:110,divide:111,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,numlock:144,scrolllock:145,semicolon:186,equalsign:187,comma:188,dash:189,period:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222},d={ctrl:function(w){return w.ctrlKey},shift:function(w){return w.shiftKey},alt:function(w){return w.altKey},meta:function(w){return w.type==="keyup"?u.meta.includes(w.keyCode):w.metaKey}};function m(C){return (0, o.isString)(C)||(0, o.isNumber)(C)}function p(C){var w=Object.keys(d).reduce(function($,M){return d[M](C)?$+1:$},0);return [16,17,18,91,92].includes(C.keyCode)?w:w+1}function g(C,w,$){var M,T;if(!C.key)return false;if((0, o.isNumber)(w))return C.keyCode===w?w:false;var R=w.split("."),I=0;try{for(var N=(0,n.__values)(R),P=N.next();!P.done;P=N.next()){var O=P.value,_=d[O],B=u[O.toLowerCase()];(_&&_(C)||B&&B===C.keyCode)&&I++;}}catch(V){M={error:V};}finally{try{P&&!P.done&&(T=N.return)&&T.call(N);}finally{if(M)throw M.error}}return $?I===R.length&&p(C)===R.length?w:false:I===R.length?w:false}function b(C,w){return (0, o.isFunction)(C)?C:m(C)?function($){return g($,C,w)}:Array.isArray(C)?function($){return C.find(function(M){return g($,M,w)})}:function(){return !!C}}var y=["keydown"];function S(C,w,$){var M=$||{},T=M.events,R=T===void 0?y:T,I=M.target,N=M.exactMatch,P=N===void 0?false:N,O=M.useCapture,_=O===void 0?false:O,B=(0, r.default)(w),V=(0, r.default)(C);(0, a.default)(function(){var U,G,H,z=(0, i.getTargetElement)(I,window);if(z){var j=function(L){var K,J=L,ee=b(V.current,P),te=ee(J),re=m(te)?te:J.key;if(te)return (K=B.current)===null||K===void 0?void 0:K.call(B,J,re)};try{for(var W=(0,n.__values)(R),Y=W.next();!Y.done;Y=W.next()){var Q=Y.value;(H=z?.addEventListener)===null||H===void 0||H.call(z,Q,j,_);}}catch(D){U={error:D};}finally{try{Y&&!Y.done&&(G=W.return)&&G.call(W);}finally{if(U)throw U.error}}return function(){var D,L,K;try{for(var J=(0,n.__values)(R),ee=J.next();!ee.done;ee=J.next()){var te=ee.value;(K=z?.removeEventListener)===null||K===void 0||K.call(z,te,j,_);}}catch(re){D={error:re};}finally{try{ee&&!ee.done&&(L=J.return)&&L.call(J);}finally{if(D)throw D.error}}}}},[R],I);}e.default=S;})(R$)),R$}var $Pe=wPe();const EPe=Io($Pe);function MPe({enabled:e,refresh:t,minIndex:n=0,maxIndex:r,gridRef:o,getScrollerRect:i,changeScrollY:a,videoCardEmitters:l,activeLargePreviewItemIndex:u}){const[d,m]=f.useState(void 0),p=Je(()=>!(!e||js())),g=Je(()=>{if(typeof d!="number"||!o.current)return false;const N=i(),P=o.current.querySelector(`.${Dl}.${EL}`)?.getBoundingClientRect();return !(!N||!P||P.top-N.top<-(N.height+P.height)||P.top-N.top>N.height*2+P.height)});function b(N){const P=R(d),O=P.getBoundingClientRect().left,_=G=>Math.abs(O-G)<1;{const G=CK(o.current),H=N==="down"?G:-G,z=R(d+H);if(z){const j=z.getBoundingClientRect().left;if(_(j))return H}}let B=0,V=P;const U=()=>N==="down"?V.nextElementSibling:V.previousElementSibling;for(;U();){if(V=U(),!V.classList.contains(Dl))continue;N==="down"?B++:B--;const G=V.getBoundingClientRect().left;if(_(G))return B}return 0}const y=N=>P=>{if(!p())return;P?.preventDefault();let O;if(g()){const _=typeof N=="number"?N:b(N);O=d+_;}else O=$();if(O<n){I(n);return}if(O>r){I(r);return}m(O),I(O);},S=(N,P)=>{EPe(N,(O,_)=>{p()&&P(O,_);},{exactMatch:true});};S("leftarrow",y(-1)),S("rightarrow",y(1)),S("tab",y(1)),S("shift.tab",y(-1)),S("uparrow",y("up")),S("downarrow",y("down"));const C=()=>{p()&&m(void 0);},w=()=>{if(!(!p()||typeof d!="number"))return l[d]};S("esc",C),S("enter",N=>{if(p()){if(typeof d=="number")return N.preventDefault(),l[d]?.emit("open");if(typeof u=="number")return N.preventDefault(),l[u]?.emit("open-with-large-preview-visible")}}),S("x",()=>w()?.emit("open-in-popup")),S("backspace",()=>w()?.emit("trigger-dislike")),S(["s","w"],()=>w()?.emit("toggle-watch-later")),S(["period","p"],()=>w()?.emit("hotkey-preview-animation"));function $(){const N=i();if(!N)return 0;const P=T();for(const[O,_]of P.entries())if(_.getBoundingClientRect().top>=N.top)return O;return 0}const M=`.${Dl}`;function T(){return [...o.current?.querySelectorAll(M)||[]]}function R(N){return T()[N]}function I(N){const P=R(N);P?.scrollIntoViewIfNeeded?.(false);const O=i(),_=P.getBoundingClientRect();if(!(!O||!_)){if(_.top<=O.top){const B=-(O.top-_.top+10);a?.({offset:B});return}if(O.bottom-_.bottom<20){const B=20-(O.bottom-_.bottom);a?.({offset:B});return}}}return {activeIndex:d,clearActiveIndex:C}}const RPe=new Map,TPe=new Map;function CK(e,t=true){const{gridDisplayMode:n,useCustomGrid:r,enableForceColumn:o,forceColumnCount:i,cardMinWidth:a}=at.grid;if(n===kr.List)return 1;if(t&&n===kr.TwoColumnGrid)return 2;if(r&&o&&i)return i;if(e||=document.querySelector(`.${gM}`),!e)return Ko("getColumnCount(): gridEl not found"),0;const l=r?RPe:TPe,u=new URLSearchParams({width:Math.round(e.clientWidth).toString(),cardMinWidth:r?a.toString():""}).toString();{const p=l.get(u);if(p)return p}const d=window.getComputedStyle(e);if(d.display!=="grid")return Ko('getColumnCount(): gridEl.style.display !== "grid"'),0;const m=d.gridTemplateColumns.split(" ").length;return l.set(u,m),m}const Nb=ao.extend("service"),APe=e=>{if(e.api===Ye.Separator)return e.uniqId;const{bvid:t}=em(e);return t||e.uniqId};function fM(e,t){return Kl([...e,...t],APe)}const RB=e=>e===nt.PcRecommend||e===nt.KeepFollowOnly;async function NPe(e,t,n=5){const{tab:r,service:o,abortSignal:i}=t;let a=[],l=true;const u=async d=>{let m=[];if(!zp(r)){m=await o.loadMore(i)??[],l=o.hasMore,m=Ay(m,r),a=fM(a,m);return}let p;if(r===nt.KeepFollowOnly)p=8,Nb("getMinCount: addMore(restCount = %s) times=%s",d,p);else {const g=RB(r)?iu.PAGE_SIZE:Jd.PAGE_SIZE,y=(()=>{const{enabled:S,byAuthor:C,byTitle:w,minDuration:$,minPlayCount:M,minDanmakuCount:T}=at.filter;return S||C.enabled||w.enabled||$.enabled||M.enabled||T.enabled})()?n:1.2;p=Math.ceil(d*y/g),Nb("getMinCount: addMore(restCount = %s) multipler=%s pagesize=%s times=%s",d,y,g,p);}if(RB(r))await o.preloadTimesFromApiIfNeeded(i,p);else {const g=o;g.config.addOtherTabContents||await g.preloadTimesFromApiIfNeeded(i,p);}m=await o.loadMore(i)||[],m=Ay(m,r),a=fM(a,m),l=o.hasMore;};for(await u(e);;){if(i?.aborted){Nb("getMinCount: break for abortSignal");break}if(!l){Nb("getMinCount: break for tab=%s hasMore=false",r);break}if(a.filter(m=>m.api!==Ye.Separator).length>=e)break;await u(e-a.length);}return a}const S6=()=>CK()*4;async function PPe(e){let t=S6();return e.tab===nt.DynamicFeed&&await e.service.shouldReduceMinCount()&&(t=1),NPe(t,e,5)}function IPe(e,t){let n;switch(e){case nt.DynamicFeed:return n=t[nt.DynamicFeed],!fa(n?.config,r6());case nt.Fav:return n=t[nt.Fav],!fa(n?.config,o6());case nt.Hot:return n=t[nt.Hot],n?.subtab!==Wo.subtab||n.subtab===hr.Rank&&n.service instanceof HG&&n.service.rankTab.slug!==xi.slug;case nt.SpaceUpload:return n=t[nt.SpaceUpload],!fa(n?.config,lq());default:return false}}function OPe({tab:e,debug:t,fetcher:n,preAction:r,postAction:o,updateViewFromService:i,self:a}){const l=Ei(),{serviceRegistry:u}=l;oo(()=>{d("reuse");}),Kf(()=>{a.abortController.abort();});const d=Je(async(p="refresh")=>{if(l.refreshing&&l.refreshingTab===e)if(IPe(e,u))t("refresh(): tab=%s [start], current refreshing, sametab but conditions change, abort existing",e),a.abortController.abort();else {t("refresh() tab=%s [start], current refreshing, prevent same tab refresh()",e);return}else t("refresh(): tab=%s [start]",e);const b=performance.now();l.setStore({refreshing:true,refreshingTab:e}),a.setStore({refreshError:void 0,hasMore:true,items:[],refreshTs:Date.now()});const y=new AbortController,{signal:S}=y;a.abortController=y,await r?.();function C(){l.setStore({refreshing:false,refreshingTab:void 0}),a.setStore({showSkeleton:false});}function w(N){C(),a.setStore({refreshError:N}),console.error(N);}function $(){C(),a.setStore({hasMore:Rq(u,e).hasMore});}async function M(N){const[P,O]=await Vp(()=>n({tab:e,service:N,abortSignal:S}));return S.aborted?t("refresh(): tab=%s [aborted], ignoring rest code",e):P?w(P):(a.setStore({items:O??[]}),true)}let T,R;switch(p){case "refresh":break;case "reuse":T=u[e];break;case "back":case "forward":{Ro(zp(e),"only rec tab can perform back/forward");const[N,P]=l.getTabBackForwardStatus(e);if(p==="back"&&!N)throw new Error("cannot go back");if(p==="forward"&&!P)throw new Error("cannot go forward");const O=l.getTabServiceQueueState(e);Ro(O,"state should not be nil");const{len:_,cursor:B}=O,U=B+(p==="back"?-1:1);if(U<0||U>_-1)throw new Error("cannot go back/forward");const G=l.serviceQueueMap[e]?.[U];Ro(G,"service should not be nil"),T=G,l.setTabServiceQueueState(e,{cursor:U,len:_}),u[e]=G,R=false;break}default:AG(p);break}if(T){T.restore();const N=Ay(T.qs.bufferQueue,e).slice(0,S6());a.setStore({items:N});const P=!!await M(T);R??=P&&!!tm[e].swr;}else a.setStore({showSkeleton:true}),R=true;if(R){const[N,P]=wf(()=>eAe[e]({existingService:T}));if(N)return w(N);if(u[e]=P,i?.(),zp(e)){l.serviceQueueMap[e]||=[],l.serviceQueueMap[e].push(P);const _=l.serviceQueueMap[e].length;l.setTabServiceQueueState(e,{len:_,cursor:_-1});}if(!await M(P))return}$(),await o?.();const I=performance.now()-b;t("refresh(): tab=%s [success] cost %s ms",e,I.toFixed(0));}),{recSharedEmitter:m}=Ei();return go(m,"refresh",d),{refresh:d}}const DPe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,F("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,children:[x("path",{d:"M4 24c0 11.046 8.954 20 20 20v0c11.046 0 20-8.954 20-20S35.046 4 24 4"}),x("path",{d:"M36 24c0-6.627-5.373-12-12-12s-12 5.373-12 12s5.373 12 12 12v0"})]})]}),_Pe=f.forwardRef(DPe),hh=ao.extend("components:RecGrid"),TB="grid-col-span-full";class BPe{store=zn({refreshTs:-1,showSkeleton:false,hasMore:true,refreshError:void 0,items:[]});useStore=()=>bt(this.store);setStore=t=>{const n=["items","refreshError"];for(const r of n)typeof t[r]=="object"&&(t[r]=CL(t[r]));Object.assign(this.store,t);};loadedPage=0;abortController=new AbortController;loadMoreLocker={};isLocked=t=>!!this.loadMoreLocker[t];lock=t=>{this.loadMoreLocker={[t]:true};};unlock=t=>{this.loadMoreLocker[t]=false;};get loadMoreRunning(){return this.isLocked(this.store.refreshTs)}}const xK=f.memo(function({className:t,containerClassName:n,shortcutEnabled:r,tab:o,infiniteScrollUseWindow:i,onScrollToTop:a,scrollerRef:l,ref:u}){const d=Ei(),{serviceRegistry:m,recSharedEmitter:p}=d,{refreshing:g}=d.useStore(),b=z1(()=>new BPe,[]),{useCustomGrid:y,gridDisplayMode:S,enableForceColumn:C,forceColumnCount:w,cardMinWidth:$}=bt(at.grid),{multiSelecting:M}=bt(Fn),T=cW();GMe();const R=Je(()=>{T.current||d.setStore({tabbarView:m[o]?.tabbarView,sidebarView:m[o]?.sidebarView});});oo(R);const I=Je(()=>{de(),R(),a?.();}),N=Je(()=>{de(),R(),b.loadedPage=1,H();}),{refresh:P}=OPe({tab:o,debug:hh,fetcher:PPe,preAction:I,postAction:N,updateViewFromService:R,self:b});f.useImperativeHandle(u,()=>({refresh:P}),[P]);const{items:O,hasMore:_,refreshError:B,refreshTs:V,showSkeleton:U}=b.useStore();f.useEffect(()=>L6e(O),[O]);const G=f.useRef(void 0);va("visibilitychange",ue=>{if(!(document.visibilityState==="visible")){G.current=Date.now();return}d.refreshing||b.loadMoreRunning||o===nt.Watchlater&&G.current&&Date.now()-G.current>lo("1h")&&P("reuse");},{target:document});const H=Je(async()=>{if(await gn(pg?100:0),hh("checkShouldLoadMore(): footerInViewRef = %s",ae.current),ae.current)return j()}),z=Je(()=>!(T.current||d.refreshing||b.abortController.signal.aborted||b.loadMoreRunning||b.store.refreshTs<0||b.store.refreshError||!b.store.hasMore)),j=Je(async()=>{if(!z())return;const ue=b.store.refreshTs;b.lock(ue);let ge=b.store.items,Pe=true,je;try{const qe=Rq(m,o);let Ue=await qe.loadMore(b.abortController.signal)||[];Ue=Ay(Ue,o),ge=fM(ge,Ue),Pe=qe.hasMore;}catch(qe){je=qe;}if(je)throw b.unlock(ue),ca.error({title:"加载失败",description:je.message||je.stack}),je;{const qe=b.store.refreshTs;if(ue!==qe){hh("loadMore: skip update for mismatch refreshTs, %o != %o",ue,qe),b.unlock(ue);return}}b.loadedPage++,hh("loadMore: loadedPage(%s) len(%s -> %s)",b.loadedPage,b.store.items.length,ge.length),b.setStore({hasMore:Pe,items:ge}),b.unlock(ue),H();}),W=Je(async()=>{const ge={key:"RecGrid:loadToEnd"+":error",title:"加载全部",duration:15},Pe={title:"加载全部"},je=qe=>{throw ca.error({...ge,description:qe}),new Error("loadToEnd error",{cause:qe})};if(!ZG())return je("当前 Tab 不支持加载全部");if(b.store.refreshError)return je("预检查失败: 先前错误");if(!b.store.hasMore)return ca.success({...Pe,description:"没有更多了"});for(;!z();)await gn(500);for(;z();)await j();ca.success({...Pe,description:"已完成"});});go(p,"load-to-end",W);const Y=O,Q=f.useMemo(()=>Y.filter(ue=>ue.api!==Ye.Separator),[Y]),D=f.useRef(null),L=Je(()=>{if(i){const ue=uu.get()+50;return new DOMRect(0,ue,window.innerWidth,window.innerHeight-ue)}else return l?.current?.getBoundingClientRect()}),K=f.useMemo(()=>new Map,[V]),J=f.useMemo(()=>Q.map(({uniqId:ue})=>{const ge=ue;return K.get(ge)||(()=>{const Pe=new Xo;return K.set(ge,Pe),Pe})()}),[Q]),[ee,te]=f.useState(void 0);go(p,"show-large-preview",te);const re=f.useMemo(()=>{if(ee)return Q.findIndex(ue=>ue.uniqId===ee)},[Y,ee]),{activeIndex:ie,clearActiveIndex:de}=MPe({enabled:r,refresh:P,maxIndex:Q.length-1,gridRef:D,getScrollerRect:L,videoCardEmitters:J,activeLargePreviewItemIndex:re,changeScrollY:i?function({offset:ue,absolute:ge}){const Pe=document.documentElement;if(typeof ue=="number"){Pe.scrollTop+=ue;return}if(typeof ge=="number"){Pe.scrollTop=ge;return}}:void 0}),ne=Je(ue=>{const ge=b.store.items;b.setStore({items:ue(ge)??ge});}),ce=Je((ue,ge,Pe)=>{ne(je=>{const qe=je.slice(),Ue=[];for(const[et,rt]of ue.entries()){const Ke=qe.findIndex(We=>We.uniqId===rt);if(Ke===-1)continue;qe.splice(Ke,1);const _e=ge?.[et];_e&&Ue.push(_e),o===nt.Watchlater&&m[o]?.decreaseTotal(),o===nt.Fav&&m[o]?.decreaseTotal();}return !Pe&&Ue.length&&(Ue.length<=3?Ue.forEach(et=>_t.success(`已移除: ${Ue.join(", ")}`)):_t.success(`已移除: ${Ue.length}个视频`)),qe});}),fe=Je((ue,ge)=>{ne(Pe=>{const je=Pe.findIndex(qe=>qe.uniqId===ue);if(je!==-1){if(ge==="start"){const qe=Pe.findIndex(Ue=>Ue.api!==Ye.Separator);return kp(Pe,je,qe)}else if(ge==="end")return kp(Pe,je,Pe.length-1)}});});go(p,"remove-cards",ue=>ce(...ue)),go(p,"move-card-to",ue=>fe(...ue));const{ref:se,inView:Me}=O6e({root:i?null:l?.current||null,rootMargin:`0px 0px ${window.innerHeight}px 0px`,onChange(ue){ue&&(hh("footerInView change to visible"),wf(()=>ae.current=!0),H());}}),ae=hu(Me),pe=x("div",{ref:se,className:X(TB,"flex items-center justify-center py-30px text-size-120%"),children:!g&&x(ze,{children:_?F(ze,{children:[x(_Pe,{className:"mr-10px size-40px animate-spin color-gate-primary"}),"加载中~"]}):x(ze,{children:"没有更多了~"})})}),Ce=X("min-h-100vh @container-inline-size",n),xe=f.useMemo(()=>{const{videoGrid:ue,videoGridBiliFeed4:ge,videoGridCustom:Pe,videoGridAddonCenterEmpty:je,gridTemplateColumnsUsingVarCol:qe,gridTemplateColumnsUsingCardMinWidth:Ue,narrowMode:et}=s5,rt=y&&!(C&&w)&&S!==kr.TwoColumnGrid?Ue:qe,Ke=[ZQ,ue,rt,y?Pe:ge],_e=(...We)=>X(Ke,...We,t);return S===kr.TwoColumnGrid?{className:_e(et)}:(S===kr.CenterEmptyGrid&&Ke.push(je),y?C&&w?{className:_e(),style:{"--col":w.toString()}}:{className:_e(),style:{"--card-min-width":`${$}px`}}:{className:_e()})},[s5,y,S,C,w,$,t]),Ae=fNe(),Xe=({gridChildren:ue,gridSiblings:ge}={})=>F("div",{"data-tab":o,className:Ce,children:[x("div",{"data-tab":o,ref:D,...xe,children:ue}),ge]});if(B)return console.error("RecGrid.refresh error:",B.stack||B),Xe({gridSiblings:x(kRe,{tab:o,err:B})});if(g&&U){const ue=S6();return Xe({gridChildren:Array.from({length:ue}).fill(0).map((ge,Pe)=>x(gB,{loading:true,tab:o},Pe))})}const Ne=ue=>{if(ue.api===Ye.Separator)return x(Ul,{className:X(TB,VX),orientation:"horizontal",titlePlacement:"left",children:ue.content},ue.uniqId);{const ge=Q.findIndex(je=>je.uniqId===ue.uniqId),Pe=ge===ie;return x(gB,{baseCss:[Ae,mNe(Pe)],tab:o,item:ue,active:Pe,onRemoveCurrent:(je,qe,Ue)=>ce([je.uniqId],[qe.title],Ue),emitter:J[ge],recSharedEmitter:p,gridDisplayMode:S,multiSelecting:M},ue.uniqId)}};return Xe({gridChildren:F(ze,{children:[Y.map(Ne),pe]})})});function wK({className:e="",style:t,tab:n,refreshHotkeyEnabled:r,ref:o}){r??=true;const{refreshing:i}=Ei().useStore(),a=co(),l=f.useRef(null),u=Je(()=>{l.current&&(l.current.disabled||l.current.click());});f.useImperativeHandle(o,()=>({click:u}),[]),ua("r",()=>{js()||r&&u();},{exactMatch:true});const{watchlaterItemsOrder:d,popularWeeklyUseShuffle:m}=Ut(),{usingShuffle:p}=bt(pn),g=n===nt.AppRecommend||n===nt.PcRecommend||n===nt.KeepFollowOnly||n===nt.Watchlater&&d===bo.Shuffle||n===nt.Fav&&p||n===nt.Hot&&jG(m)?"换一换":"刷新",[b,y]=oCe(),S=Je(C=>{y(b.current,{rotate:[0,360]},{duration:.5,type:"tween"}),a();});return F(st,{ref:l,style:t,className:X(tU,"[&:disabled]:cursor-wait",e),disabled:i,onClick:S,children:[x(_3e,{ref:b,className:"size-14px"}),g]})}const LPe={name:"x4d4ct",styles:"scrollbar-width:thin;.ant-menu-item-group-title{padding:4px 8px;}.ant-menu-item{margin-block:1px;}ul.ant-menu-item-group-list{font-size:inherit;}"};function zPe(e){const t=bt(Wo).subtab;if(e===nt.Fav)return "max-w-300px";if(e===nt.DynamicFeed)return "min-w-200px";if(e===nt.Hot&&t===hr.Rank)return "min-w-130px"}function $K({className:e,style:t,sidebarView:n,tab:r}){const o=jA(r),i=ur("h-fit max-w-250px w-max flex-none overflow-x-hidden overflow-y-auto b-1px b-gate-border rounded-15px b-solid",zPe(r),e);return o&&n&&x("div",{className:i,css:LPe,style:t,children:x(Do,{theme:{components:{Menu:{itemHeight:30}}},children:n})})}const kPe=f.memo(function({show:t,onHide:n}){const{grid:{gridDisplayMode:r},modalFeedFullScreen:o,sidebarAlign:i}=Ut(),{usingTwoColumnMode:a}=UW(r),l=!a&&o,u=f.useRef(null),d=f.useMemo(()=>X(l?"b-5px":"b-1px","b-gate-primary b-solid"),[l]),m=Je(()=>{u.current&&(u.current.scrollTop=0);}),{modalSettingsVisible:p}=C6(),g=[t,!p,!nK(),!oK()].every(Boolean),b=Nq(true),{tabbarView:y,sidebarView:S}=b.useStore(),{tab:C,direction:w}=Kq(),$=()=>F("div",{className:X(Po.modalHeader,"gap-x-15px pr-15px"),children:[F("div",{className:"left flex flex-shrink-1 flex-wrap items-center gap-x-15px gap-y-4px",children:[x(Yq,{}),y]}),F("div",{className:"right flex flex-shrink-0 items-center gap-x-8px",children:[r===kr.TwoColumnGrid?null:x(f6e,{initialOpen:true,children:x(FPe,{})}),x(wK,{refreshHotkeyEnabled:g,tab:C}),x($g,{onClick:n,className:"ml-5px"})]})]}),M=X(a&&"bg-black/90%"),I=X("h-[calc(100vh-30px)] max-h-unset w-[calc(100vw-30px)] pr-0",l&&"h-full w-full",a&&jW,d);return x(a6.Provider,{value:b,children:F(wg,{show:t,onHide:n,clsModalMask:M,clsModal:I,children:[$(),F("div",{"data-role":"modal-body",className:X("flex flex-1 gap-x-25px overflow-hidden",i===gf.Right&&"flex-row-reverse"),children:[x($K,{tab:C,sidebarView:S,className:"max-h-full"}),x("div",{className:"h-full flex-1 overflow-y-auto pr-15px",ref:u,children:x(xK,{tab:C,direction:w,shortcutEnabled:g,onScrollToTop:m,infiniteScrollUseWindow:false,scrollerRef:u},C)})]})]})})});function FPe(){return x(ze,{children:x(Pt,{configPath:"modalFeedFullScreen",label:"全屏",tooltip:"世界清净了~"})})}const Au=zn({modalFeedVisible:false,modalSettingsVisible:false});function C6(){return bt(Au)}function HPe(){Au.modalFeedVisible?EK():VPe();}function VPe(){TK(),Au.modalFeedVisible=true;}function EK(){Au.modalFeedVisible=false;}function jPe(){Au.modalSettingsVisible?MK():x6();}function x6(){TK(),Au.modalSettingsVisible=true;}function MK(){Au.modalSettingsVisible=false;}function RK(){GM.registerMenuCommand?.("⚙️ 设置",x6);}const TK=xf(function(){const t=document.createElement("div");t.classList.add("modals-container",$a),document.body.appendChild(t),Qa.createRoot(t).render(x(Us,{children:x(UPe,{})}));});function UPe(){const{modalFeedVisible:e,modalSettingsVisible:t}=C6();return F(ze,{children:[x(kPe,{show:e,onHide:EK}),x(u6e,{show:t,onHide:MK})]})}const Ic=fT({align:"right",top:100},"float-entry"),B$={wrapperInner:"flex flex-col items-center gap-y-8px b-1px b-gate-primary rounded-18px b-solid bg-gate-bg p-4px",buttonIcon:"size-18px"};function WPe(){return x(OW,{children:x(GPe,{})})}function GPe(){const{align:e,top:t}=bt(Ic,{sync:true}),n=f.useMemo(()=>({arrow:false,placement:e==="right"?"left":"right",align:{offset:[10*(e==="right"?-1:1),0]}}),[e]),r=f.useMemo(SRe,[]),{attributes:o,listeners:i,setNodeRef:a,setActivatorNodeRef:l,transform:u}=DW({id:"GateFloatEntry"});yW({onDragEnd(b){if(b.active.id==="GateFloatEntry"){Qd.update();const y=d.current?.getBoundingClientRect();if(!y)return;const S=ff(Math.round(y.top),0,window.innerHeight-y.height);let C=Ic.align;(Ic.align==="right"&&y.left<window.innerWidth/4||Ic.align==="left"&&y.right>window.innerWidth/4*3)&&(C=Ic.align==="right"?"left":"right"),nZ("new pos",{align:C,top:S}),Ic.align=C,Ic.top=S,d.current?.animate([{transform:C==="right"?`translateX(-${window.innerWidth-y.right}px)`:`translateX(${y.left}px)`},{transform:"translateX(0)"}],{duration:200,easing:"ease-in-out"});}}});const d=U1(a),m=ur("fixed transition-200 transition-ease-in-out transition-property-right,left",FCe,e==="right"&&"right--30px pr-6px hover:right-0",e==="left"&&"left--30px pl-6px hover:left-0");oo(Qd.updateThrottled);const{height:p}=Qd.use(),g=f.useMemo(()=>ff(t,0,p-150),[t,p]);return x("div",{ref:d,className:m,style:{top:`${g}px`,transform:yf.Transform.toString(u)},children:F("div",{className:B$.wrapperInner,children:[x(fn,{title:F(ze,{children:[Ao,": 在新窗口打开"]}),...n,children:x(st,{className:"icon-only-round-button",href:r,target:"_blank",children:x(No,{className:B$.buttonIcon})})}),x(fn,{title:F(ze,{children:[Ao,": 弹窗打开"]}),...n,children:x(st,{className:"icon-only-round-button",onClick:HPe,children:x(Zq,{className:B$.buttonIcon})})}),x(st,{className:"icon-only-round-button cursor-move",...i,...o,ref:l,children:x(Xq,{className:"size-14px"})})]})})}function qPe(e,t,n){const r=Je(t),o=Ol(n);return f.useEffect(()=>{const i=new ResizeObserver(a=>{for(const l of a)if(l.target===e&&l.contentRect){const u=r(l);fa(o.val,u)||o.set(u);}});return i.observe(e),()=>{i.disconnect();}},[e,r]),o.state}function KPe(){const e=f.useRef(null),[t,n]=f.useState(false);return f.useEffect(()=>{const r=Yl(()=>{if(!e.current)return;const o=Math.trunc(e.current.getBoundingClientRect().top*10)/10,i=Number.parseInt(getComputedStyle(e.current).top),a=o<=i;n(a);},16);return r(),document.addEventListener("scroll",r),window.addEventListener("resize",r),window.addEventListener("orientationchange",r),()=>{document.removeEventListener("scroll",r),window.removeEventListener("resize",r),window.removeEventListener("orientationchange",r);}},[t]),[e,t]}const YPe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"M42 24H6m24-12l12 12l-12 12"})]}),XPe=f.forwardRef(YPe),QPe=({title:e,titleId:t,...n},r)=>F("svg",{viewBox:"0 0 48 48",width:"1.2em",height:"1.2em",ref:r,"aria-labelledby":t,...n,children:[e?x("title",{id:t,children:e}):null,x("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:4,d:"M5.799 24h36m-24 12l-12-12l12-12"})]}),ZPe=f.forwardRef(QPe),JPe=ao.extend("RecHeader");function e4e({tab:e,leftSlot:t,rightSlot:n,shortcutEnabled:r,ref:o}){const{pureRecommend:i,showBackForwardButtons:a,multiSelect:{showIcon:l},style:{pureRecommend:{useStickyTabbar:u,stickyTabbarShadow:d,useWhiteBackground:m}}}=Ut(),p=f.useMemo(()=>zp(e),[e]),g=Ei(),{refreshing:b,serviceQueueStateMap:y}=g.useStore(),[S,C]=g.useTabBackForwardStatus(e),w=co();ua(["shift.comma"],U=>{js()||jPe();},{exactMatch:true,useCapture:true});const[$,M]=KPe(),T=Je(()=>{if(!i)return;const U=$.current?.parentElement;if(!U)return;const G=U.getBoundingClientRect(),H=uu.get();if(G.top<H){const z=hwe(U).top;JPe("[refresh:scroll] rect.top = %s, headerHeight = %s",G.top,H),document.documentElement.scrollTop=z-H+2;}});f.useImperativeHandle(o,()=>({scrollToTop:T}));const R=uu.use(),I=n4e(e),N=hT.use(),P=O1(),O=t4e(),_=(()=>{let U;return N?U=P?"rgba(0, 0, 0, 26%) 0px 2px 10px 1px":"rgba(0, 0, 0, 13%) 0 1px 10px 1px;":U=`0 2px 4px ${P?"rgb(255 255 255 / 5%)":"rgb(0 0 0 / 8%)"}`,ln("box-shadow:",U,";","")})(),B=ur(i&&u&&["sticky mb-10px b-b-1px b-b-transparent b-b-solid",kCe,M&&["bg-gate-bg","b-b-gate-bg-lv1"]],M&&"sticky-state-on"),V=f.useMemo(()=>{if(!(i&&u))return;const G=[ln("top:",R-1,"px;","")];return d&&M&&G.push(_,O),G},[i,u,d,M,R,_,O]);return x("div",{ref:$,"data-role":"tab-bar-wrapper",className:B,css:V,children:F("div",{"data-role":"tab-bar",className:X(RL,"relative mb-0 h-auto flex flex-row items-center justify-between gap-x-15px px-0 py-8px"),children:[F("div",{"data-class-name":"left",className:"h-full flex flex-wrap items-center gap-x-15px gap-y-8px",children:[x(Yq,{className:"flex-none"}),t]}),F("div",{"data-class-name":"right",className:"h-full min-w-180px flex flex-row-reverse flex-wrap items-center justify-right gap-x-8px gap-y-8px",children:[x(wK,{tab:e,refreshHotkeyEnabled:r}),a&&p&&F(ze,{children:[x(fn,{arrow:false,title:"前进",children:x(st,{className:"icon-only-round-button",disabled:b||!C,onClick:()=>w("forward"),children:x(XPe,{})})}),x(fn,{arrow:false,title:"后退",children:x(st,{className:"icon-only-round-button",disabled:b||!S,onClick:()=>w("back"),children:x(ZPe,{})})})]}),x(fn,{title:"设置",arrow:false,children:F(st,{onClick:x6,className:"icon-only-round-button",children:[x(l6e,{}),x(JT,{className:"size-14px"})]})}),l&&x(GG,{iconOnly:true,addCopyActions:true}),I&&x(PA,{style:{marginLeft:5}}),n]})]})})}function t4e(){const{xScrolling:e,bodyWidth:t}=qPe(document.body,n=>{const r=n.contentRect.width,o=!!(r&&Math.round(r)>Math.round(window.innerWidth));return o?{xScrolling:o,bodyWidth:r}:{xScrolling:o}},()=>({xScrolling:false}));return f.useMemo(()=>{if(e){const n=Math.floor(t);return ln("margin-inline:calc((100% - ",n,"px) / 2);padding-inline:calc((",n,"px - 100%) / 2);","")}else {const n=rA||pg?"0px":"20px";return ln("margin-inline:calc((100% - 100vw + ",n,") / 2);padding-inline:calc((100vw - ",n," - 100%) / 2);","")}},[e,t])}function n4e(e){const{accessKey:t}=Ut();return !t&&[nt.AppRecommend,nt.Liked].includes(e)}function r4e(){const{modalFeedVisible:e,modalSettingsVisible:t}=C6();return [e,t,nK(),oK()].every(r=>r===false)}function o4e(){const{grid:{twoColumnModeAlign:e},sidebarAlign:t}=Ut(),{usingTwoColumnMode:n}=WW(),r=r4e(),o=Nq(),{tabbarView:i,sidebarView:a}=o.useStore(),{tab:l,direction:u}=Kq(),d=f.useRef(null),m=Je(()=>d.current?.scrollToTop()),p=uu.use(),g=f.useMemo(()=>ln("position:sticky;top:",p+55,"px;max-height:calc(100vh - ",p+55+20,"px);",""),[p]);let b,y,S;return b=X("flex gap-x-25px",t===gf.Right&&"flex-row-reverse"),y="flex-1",S=X(n&&[jW,WEe(e,"margin")]),F(a6.Provider,{value:o,children:[x(e4e,{ref:d,tab:l,leftSlot:i,shortcutEnabled:r}),F("div",{className:b,children:[x($K,{css:g,tab:l,sidebarView:a}),x(xK,{tab:l,direction:u,containerClassName:y,className:S,shortcutEnabled:r,infiniteScrollUseWindow:true,onScrollToTop:m},l)]})]})}const AK="html.bewly-design:not(:has(#i_cecream,#app))";function i4e(){return !!document.querySelector(AK)}function a4e(){return P1(AK,()=>{Ko("unmount for using bewly-design"),Hp?.unmount();},{pollTimeout:5e3,warnOnTimeout:false})}let Hp;async function s4e(){if(Vh(".adblock-tips"),Vh(".vip-login-tip"),P1("html.gray",t=>t.classList.remove("gray")),RK(),i4e())return Ko("quit for using bewly-design");at.pureRecommend||yRe()||J1()?(await c4e(),a4e()):l4e();}function l4e(){const e=document.createElement("section");e.classList.add($a),document.body.append(e),Hp=Qa.createRoot(e),Hp.render(F(Us,{children:[x(F1,{antd:true,baseGlobalStyle:true}),x(WPe,{})]}));}async function c4e(){pg&&await gn(500),Vh("#i_cecream .bili-feed4-layout, body > #app .bili-feed4-layout"),Vh(".bili-feed4 .header-channel"),Vh(".palette-button-wrap");const e=document.createElement("div");e.classList.add("bili-feed4-layout","pure-recommend",$a),await Sg(()=>document.querySelector(".bili-feed4 .bili-header"),{interval:20,timeout:2e3}),document.body.append(e);const t=document.createElement("div");e.append(t),Hp=Qa.createRoot(t),Hp.render(F(Us,{children:[x(F1,{antd:true,baseGlobalStyle:true,homePageGlobalStyle:true}),x(o4e,{}),x(Mu.BackTop,{style:{insetInlineEnd:"var(--back-top-right, 24px)"}})]}));}function w6(){d4e(),RK();}const u4e=xf(()=>{const e=document.createElement("div");document.body.appendChild(e),Qa.createRoot(e).render(x(Us,{children:x(F1,{antd:true,baseGlobalStyle:true})}));});function d4e(){u4e();}function f4e(){try{return globalThis.self!==window.top}catch{return true}}const $6=new Xo,m4e=xf(()=>{window.navigation?.addEventListener?.("navigatesuccess",()=>{$6.emit("navigate-success");});});queueMicrotask(m4e);function h4e(){f4e()||(w6(),at.videoCard.videoPreview.addTo.searchPage&&p4e());}function p4e(){const e=_H(()=>{const r=Array.from(document.querySelectorAll(".video-list-item:has(> .bili-video-card),div:has(> .bili-video-card)"));for(const o of r)g4e(o);},1);e(),new MutationObserver(()=>e()).observe(document.body,{childList:true,subtree:true});}const AB=new WeakSet,NB=`${io}-add-large-preview-processed`;function g4e(e){if(AB.has(e)||e.getAttribute(NB))return;const t=e.querySelector(".bili-watch-later--wrap");if(!t)return;const n=document.createElement("div");t.after(n),AB.add(e),e.setAttribute(NB,"true"),Qa.createRoot(n).render(x(Us,{children:x(v4e,{el:e})}));}function v4e({el:e}){const{bvid:t="",cover:n}=f.useMemo(()=>b4e(e),[e]),r=f.useMemo(()=>e.querySelector(".bili-video-card")??e,[e]),o=f.useMemo(()=>r.querySelector(".bili-video-card__wrap > a"),[e]),i=k1(r),a=f.useRef(o),{largePreviewActionButtonEl:l,largePreviewEl:u}=dK({shouldFetchPreviewData:!!t,hasLargePreviewActionButton:true,actionButtonVisible:i,actionButtonProps:{useMotion:true,motionProps:{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0,transition:{delay:0}},transition:{duration:.2,ease:"linear",delay:.2}}},bvid:t,cid:void 0,uniqId:t,recSharedEmitter:Tq,cardTarget:r,cover:n,videoCardAsTriggerRef:a});return F(ze,{children:[x("div",{className:ur(_p.top("right"),"right-[calc(8px+28px+5px)]"),children:l}),$o.createPortal(u,r)]})}function b4e(e){let t;{const r=e.querySelector(".bili-video-card__wrap > a")?.href;r&&(t=/^\/video\/(?<bvid>BV\w+)\//i.exec(new URL(r).pathname)?.groups?.bvid);}const n=e.querySelector("picture.v-img.bili-video-card__cover img")?.currentSrc;return {bvid:t,cover:n}}const y4e=`${io}-${crypto.randomUUID()}`;async function S4e(){if(!au.mid)return;const e=".h-action",t=".upinfo .operations";await P1([e,t].join(","),n=>{au.href=location.href,au.usingNewSpacePage=n.matches(t),NK();const r=document.createElement("span");r.id=y4e,r.classList.add("mr-24px"),n.prepend(r),Qa.createRoot(r).render(x(Us,{children:x(C4e,{})}));},{pollTimeout:1e4,pollInterval:1e3});}const au=zn({href:location.href,usingNewSpacePage:false,followed:false,get mid(){return x4e(this.href)},get collectionId(){const e=new URL(this.href);{const t=/https:\/\/space.bilibili.com\/(?<mid>\d+)\/lists\/(?<collectionId>\d+)(?:\?type=season)?/,n=this.href.match(t);if(n?.groups?.collectionId&&(e.searchParams.get("type")==="season"||!e.searchParams.get("type")))return Number(n?.groups?.collectionId)}if(/https:\/\/space.bilibili.com\/\d+\/channel\/collectiondetail\?/.test(this.href)){const r=new URL(this.href).searchParams.get("sid")?.trim();if(r)return Number(r)}},get isCollectionPage(){return typeof this.collectionId=="number"},get searchKeyword(){return /https:\/\/space.bilibili.com\/\d+\/search/.test(this.href)?new URLSearchParams(location.search).get("keyword")??void 0:void 0},get isSearching(){return !!this.searchKeyword?.trim()}}),NK=Hs(async()=>{const e=await Sg(()=>{if(Array.from(document.querySelectorAll(".space-follow-btn")).filter(n=>n.textContent?.trim()==="已关注").length>0)return true},{interval:100,timeout:5e3});au.followed=!!e;});$6.on("navigate-success",()=>{au.href=location.href,NK();});function C4e(){const{mid:e,collectionId:t,followed:n,isSearching:r,searchKeyword:o}=bt(au);if(!e)return;const i="w-34px b-white/33% rounded-full hover:b-gate-primary hover:bg-gate-primary",a="size-17px";let l;{let m=`https://www.bilibili.com/?${Fa.Mid}=${e}`;r&&o&&(m+=`&${Fa.SearchText}=${o}`),l=x(L$,{className:i,href:m,tooltip:`在「${Ao}」中查看 UP 的投稿`,children:x(py,{className:a})},"btnSpaceUpload");}let u;if(n){const m=`https://www.bilibili.com/?${pi.Mid}=${e}`;u=x(L$,{className:i,href:m,tooltip:`在「${Ao}」中查看 UP 的动态`,children:x(hy,{className:a})},"btnDynamicFeed");}let d;return typeof t=="number"&&(d=x(L$,{className:i,href:`https://www.bilibili.com/?${Iy.CollectionIdFull}=${t}`,target:"_blank",tooltip:`在「${Ao}」中查看合集`,children:x(eS,{className:a})},"btnViewCollection")),F("span",{className:"inline-flex items-center gap-x-8px",children:[d,l,u]})}function L$({href:e,children:t,className:n,style:r,tooltip:o,...i}){const{usingNewSpacePage:a}=bt(au),l=ur("h-34px w-150px flex cursor-pointer items-center justify-center b-1px b-white/20% rounded-6px b-solid bg-white/14% text-14px color-white font-700 transition-duration-300 transition-property-all hover:bg-white/40%",n),u=a?x("a",{...i,href:e,className:l,style:r,children:t}):x("a",{href:e,className:X("h-f-btn",n),style:{width:"auto",paddingInline:"15px",...r},...i,children:t});return o?x(fn,{title:o,children:u}):u}function x4e(e=location.href){const n=new URL(e).pathname.split("/").map(r=>r.trim()).find(Boolean);if(!(!n||!/^\d+$/.test(n)))return n}function w4e(){$6.on("navigate-success",$4e);}function $4e(){const e=new URL(location.href);if(e.hostname!=="space.bilibili.com")return;const t=/^\/(?<mid>\d+)\/lists\?sid=(?<sid>\d+)$/.exec(e.pathname+e.search);if(!t)return;const n=new URL(`/${t.groups?.mid}/lists/${t.groups?.sid}`,location.href).href;location.href=n;}function E4e(){w6(),w4e(),S4e();}function mM(){if(!(typeof unsafeWindow>"u"))return unsafeWindow.player}const p0=ao.extend("main:video-play-page");async function M4e(){w6(),R4e(),_4e(),await N4e(),await P4e();}function R4e(){T4e(),A4e(),D4e();}function T4e(){VA&&GM.registerMenuCommand?.("🎦 小窗打开",()=>{PK(),I4e();});}function A4e(){rA&&GM.registerMenuCommand?.("▶️ IINA 打开",()=>{PK(),O4e();});}async function N4e(){const e=new URL(location.href).searchParams.get(ql.PlayerScreenMode);if(p0("targetMode=%s",e),!(e===Tl.WebFullscreen||e===Tl.Fullscreen))return;let n;e===Tl.WebFullscreen&&(n=()=>document.querySelector('[role="button"][aria-label="网页全屏"]')?.click()),e===Tl.Fullscreen&&(n=()=>document.querySelector('[role="button"][aria-label="全屏"]')?.click());const r=()=>document.querySelector("#bilibili-player .bpx-player-container")?.dataset.screen||Tl.Normal,o=Date.now()+lo("30s");for(;r()!==e&&Date.now()<=o;)p0("current mode: %s",r()),n?.(),await gn(100);p0("handleFullscreen to %s complete",e);}async function P4e(){if(IG()||!(new URL(location.href).searchParams.get(ql.ForceAutoPlay)===iA.ON))return;const t=()=>{const r=mM();return !!r&&!r.isPaused()},n=Date.now()+lo("30s");for(;Date.now()<=n&&!t();)mM()?.play(),await gn(1e3);p0("handleForceAutoPlay complete, playing = %s",t());}function PK(){const e=mM();e&&!e.isPaused()&&e.pause();}function I4e(){const e=new URL(location.href);e.searchParams.set(ql.PlayerScreenMode,Tl.WebFullscreen);const t=e.href;zG(t,"");}function O4e(){const e=`iina://open?url=${encodeURIComponent(location.href)}`;window.open(e,"_self");}function D4e(){GM.registerMenuCommand?.("⭐️ 加入收藏",()=>hM());}async function _4e(){if(!at.fav.useCustomFavPicker.onPlayPage||!qW())return;document.addEventListener("keydown",t=>{t.key!=="e"||js()||t.target.closest("bili-comments")||(t.stopImmediatePropagation(),t.preventDefault(),hM());},{capture:true}),(await Sg(()=>document.querySelector(".video-fav.video-toolbar-left-item"),{interval:100,timeout:5e3}))?.addEventListener("click",t=>{t.stopImmediatePropagation(),t.preventDefault(),hM();},{capture:true});}async function hM(e){const t=qW();if(!t)return _t.error("无法解析视频 BVID !");const n=I3e(t);if(e===void 0){const r=await gu.getVideoFavState(n);r&&(e=r.favFolderIds);}await zy(e,async r=>{if(!await p6(n,e,r))return;const i=!!r;return document.querySelector(".video-fav.video-toolbar-left-item")?.classList.toggle("on",i),true});}Yn.extend(Wxe);(function(){if(_s)return s4e();if(GW)return M4e();if(eZ)return E4e();if(tZ)return h4e()})();
})(UAParser, axios, SparkMD5, localforage, PinyinMatch);