karin-plugin-kkk 2.45.2-beta.3 → 2.45.2-beta.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));export{s as n,l as r,o as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{An as t,J as n,Ln as r,Mn as i,q as a,xn as o}from"./createLucideIcon-BQ-Qp6cj.js";var s=t({base:`separator`,defaultVariants:{orientation:`horizontal`,variant:`default`},variants:{orientation:{horizontal:`separator--horizontal`,vertical:`separator--vertical`},variant:{default:`separator--default`,secondary:`separator--secondary`,tertiary:`separator--tertiary`}}}),c=e(r(),1),l=i(),u=({className:e,isDecorative:t=!1,orientation:r,render:i,variant:u,...d})=>{let f=o(n,d.slot),p=i??f?.render,m=r??f?.orientation??`horizontal`,h=d.elementType??f?.elementType??`div`,g=(0,c.useMemo)(()=>s({className:e,orientation:m,variant:u}),[e,m,u]);return(0,l.jsx)(a,{className:g,"data-orientation":m,"data-slot":`separator`,orientation:m,...d,render:t?(e,t)=>{let n={...e,"aria-hidden":!0,"aria-orientation":void 0,role:`presentation`};return p?p(n,t):c.createElement(h===`hr`&&m===`vertical`?`div`:h,n)}:i})};u.displayName=`HeroUI.Separator`;var d=Object.assign(u,{Root:u});export{d as t};
@@ -6,8 +6,10 @@
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
7
  <meta name="description" content="KKK Config - Karin 插件配置管理面板" />
8
8
  <title>KKK Config</title>
9
- <script type="module" crossorigin src="/kkk/assets/assets/index-RFCFN09q.js"></script>
10
- <link rel="stylesheet" crossorigin href="/kkk/assets/assets/index-D1zuPqD3.css">
9
+ <script type="module" crossorigin src="/kkk/assets/assets/index-DSqk8j2R.js"></script>
10
+ <link rel="modulepreload" crossorigin href="/kkk/assets/assets/rolldown-runtime-hePW80VL.js">
11
+ <link rel="modulepreload" crossorigin href="/kkk/assets/assets/createLucideIcon-BQ-Qp6cj.js">
12
+ <link rel="stylesheet" crossorigin href="/kkk/assets/assets/index-BVZg44aV.css">
11
13
  </head>
12
14
  <body>
13
15
  <div id="root"></div>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "karin-plugin-kkk",
3
- "version": "2.45.2-beta.3",
3
+ "version": "2.45.2-beta.4",
4
4
  "description": "Karin 的「抖音」「B 站」视频解析/动态推送插件",
5
5
  "keywords": [
6
6
  "karin",
@@ -83,7 +83,7 @@
83
83
  "@lobehub/webfont-harmony-sans-sc": "^1.0.0",
84
84
  "emoji-datasource-apple": "16.0.0"
85
85
  },
86
- "timestamp": "2026-10-27T15:36:05.738Z",
86
+ "timestamp": "2026-10-30T04:19:15.528Z",
87
87
  "engines": {
88
88
  "node": ">=18.0.0"
89
89
  }
@@ -1 +0,0 @@
1
- import{t as e}from"./separator-CCrVXPvv.js";import{$ as t,A as n,At as r,B as i,Bt as a,C as o,Ct as s,D as c,Dt as l,Et as u,F as d,Ft as f,G as p,H as m,Ht as h,I as g,It as _,J as v,K as y,L as b,Lt as x,M as S,Mt as C,N as w,Nt as T,Ot as E,P as D,Pt as O,Q as k,Rt as A,S as j,St as M,T as N,Tt as ee,U as P,Ut as F,V as I,Vt as L,W as te,X as R,Y as z,Z as ne,_ as re,_t as ie,at as ae,b as B,bt as oe,ct as se,dt as ce,et as le,f as ue,ft as de,gt as fe,h as pe,ht as me,it as he,j as ge,jt as V,k as _e,kt as ve,lt as ye,m as H,mt as be,nt as xe,o as Se,ot as Ce,p as U,pt as we,q as Te,rt as Ee,st as De,tt as Oe,ut as ke,v as W,vt as Ae,w as je,wt as G,x as K,xt as Me,y as Ne,zt as Pe}from"./index-RFCFN09q.js";var Fe=oe({base:`header`}),Ie=oe({defaultVariants:{fullWidth:!1,variant:`primary`},slots:{base:`number-field`,decrementButton:`number-field__decrement-button`,group:`number-field__group`,incrementButton:`number-field__increment-button`,input:`number-field__input`},variants:{fullWidth:{false:{},true:{base:`number-field--full-width`,group:`number-field__group--full-width`}},variant:{primary:{base:`number-field--primary`},secondary:{base:`number-field--secondary`}}}}),Le=oe({base:`radio-group`,defaultVariants:{variant:`primary`},variants:{variant:{primary:`radio-group--primary`,secondary:`radio-group--secondary`}}}),Re=oe({slots:{base:`radio`,content:`radio__content`,control:`radio__control`,indicator:`radio__indicator`}}),ze=RegExp(`^.*\\(.*\\).*$`),Be=[`latn`,`arab`,`hanidec`,`deva`,`beng`,`fullwide`],Ve=class{constructor(e,t={}){this.locale=e,this.options=t}parse(e){return Ue(this.locale,this.options,e).parse(e)}isValidPartialNumber(e,t,n){return Ue(this.locale,this.options,e).isValidPartialNumber(e,t,n)}getNumberingSystem(e){return Ue(this.locale,this.options,e).options.numberingSystem}},He=new Map;function Ue(e,t,n){let r=We(e,t);if(!e.includes(`-nu-`)&&!r.isValidPartialNumber(n)){for(let i of Be)if(i!==r.options.numberingSystem){let r=We(e+(e.includes(`-u-`)?`-nu-`:`-u-nu-`)+i,t);if(r.isValidPartialNumber(n))return r}}return r}function We(e,t){let n=e+(t?Object.entries(t).sort((e,t)=>e[0]<t[0]?-1:1).join():``),r=He.get(n);return r||(r=new Ge(e,t),He.set(n,r)),r}var Ge=class{constructor(e,t={}){this.locale=e,t.roundingIncrement!==1&&t.roundingIncrement!=null&&(t.maximumFractionDigits==null&&t.minimumFractionDigits==null?(t.maximumFractionDigits=0,t.minimumFractionDigits=0):t.maximumFractionDigits==null?t.maximumFractionDigits=t.minimumFractionDigits:t.minimumFractionDigits??=t.maximumFractionDigits),this.formatter=new Intl.NumberFormat(e,t),this.options=this.formatter.resolvedOptions(),this.symbols=Je(e,this.formatter,this.options,t),this.options.style===`percent`&&((this.options.minimumFractionDigits??0)>18||(this.options.maximumFractionDigits??0)>18)&&console.warn(`NumberParser cannot handle percentages with greater than 18 decimal places, please reduce the number in your options.`)}parse(e){let t=this.formatter.resolvedOptions().useGrouping,n=this.sanitize(e);if(!t&&this.symbols.group&&n.includes(this.symbols.group))return NaN;if(this.symbols.group&&(n=n.replaceAll(this.symbols.group,``)),this.symbols.decimal&&(n=n.replace(this.symbols.decimal,`.`)),this.symbols.minusSign&&(n=n.replace(this.symbols.minusSign,`-`)),n=n.replace(this.symbols.numeral,this.symbols.index),this.options.style===`percent`){let e=n.indexOf(`-`);n=n.replace(`-`,``),n=n.replace(`+`,``);let t=n.indexOf(`.`);t===-1&&(t=n.length),n=n.replace(`.`,``),n=t-2==0?`0.${n}`:t-2==-1?`0.0${n}`:t-2==-2?`0.00`:`${n.slice(0,t-2)}.${n.slice(t-2)}`,e>-1&&(n=`-${n}`)}let r=n?+n:NaN;if(isNaN(r))return NaN;if(this.options.style===`percent`){let e={...this.options,style:`decimal`,minimumFractionDigits:Math.min((this.options.minimumFractionDigits??0)+2,20),maximumFractionDigits:Math.min((this.options.maximumFractionDigits??0)+2,20)};return new Ve(this.locale,e).parse(new ye(this.locale,e).format(r))}return this.options.currencySign===`accounting`&&ze.test(e)&&(r=-1*r),r}sanitize(e){let t=this.formatter.resolvedOptions().useGrouping;return this.symbols.noNumeralUnits.length>0&&this.symbols.noNumeralUnits.find(t=>t.unit===e)?this.symbols.noNumeralUnits.find(t=>t.unit===e).value.toString():(e=e.replace(this.symbols.literals,``),this.symbols.minusSign&&(e=e.replace(`-`,this.symbols.minusSign)),this.options.numberingSystem===`arab`&&(this.symbols.decimal&&(e=q(e,`,`,this.symbols.decimal),e=q(e,`،`,this.symbols.decimal)),this.symbols.group&&t&&(e=q(e,`.`,this.symbols.group))),this.symbols.group===`’`&&e.includes(`'`)&&t&&(e=q(e,`'`,this.symbols.group)),this.symbols.group===`'`&&e.includes(`’`)&&t&&(e=q(e,`’`,this.symbols.group)),this.options.locale===`fr-FR`&&this.symbols.group&&t&&(e=q(e,` `,this.symbols.group),e=q(e,/\u00A0/g,this.symbols.group)),e)}isValidPartialNumber(e,t=-1/0,n=1/0){let r=this.formatter.resolvedOptions().useGrouping;return e=this.sanitize(e),this.symbols.minusSign&&e.startsWith(this.symbols.minusSign)&&t<0?e=e.slice(this.symbols.minusSign.length):this.symbols.plusSign&&e.startsWith(this.symbols.plusSign)&&n>0&&(e=e.slice(this.symbols.plusSign.length)),this.symbols.decimal&&e.indexOf(this.symbols.decimal)>-1&&this.options.maximumFractionDigits===0?!1:(this.symbols.group&&r&&(e=q(e,this.symbols.group,``)),e=e.replace(this.symbols.numeral,``),this.symbols.decimal&&(e=e.replace(this.symbols.decimal,``)),e.length===0)}},Ke=new Set([`decimal`,`fraction`,`integer`,`minusSign`,`plusSign`,`group`]),qe=[0,4,2,1,11,20,3,7,100,21,.1,1.1];function Je(e,t,n,r){let i=new Intl.NumberFormat(e,{...n,minimumSignificantDigits:1,maximumSignificantDigits:21,roundingIncrement:1,roundingPriority:`auto`,roundingMode:`halfExpand`,useGrouping:!0}),a=i.formatToParts(-10000.111),o=i.formatToParts(10000.111),s=qe.map(e=>i.formatToParts(e)),c=s.map((e,t)=>{let n=e.find(e=>e.type===`unit`);return n&&!e.some(e=>e.type===`integer`||e.type===`fraction`)?{unit:n.value,value:qe[t]}:null}).filter(e=>!!e),l=a.find(e=>e.type===`minusSign`)?.value??`-`,u=o.find(e=>e.type===`plusSign`)?.value;!u&&(r?.signDisplay===`exceptZero`||r?.signDisplay===`always`)&&(u=`+`);let d=new Intl.NumberFormat(e,{...n,minimumFractionDigits:2,maximumFractionDigits:2}).formatToParts(.001).find(e=>e.type===`decimal`)?.value,f=a.find(e=>e.type===`group`)?.value,p=a.filter(e=>!Ke.has(e.type)).map(e=>Ye(e.value)),m=s.flatMap(e=>e.filter(e=>!Ke.has(e.type)).map(e=>Ye(e.value))),h=[...new Set([...p,...m])].sort((e,t)=>t.length-e.length),g=h.length===0?RegExp(`\\p{White_Space}|\\p{Cf}`,`gu`):RegExp(`${h.join(`|`)}|\\p{White_Space}|\\p{Cf}`,`gu`),_=[...new Intl.NumberFormat(n.locale,{useGrouping:!1}).format(9876543210)].reverse(),v=new Map(_.map((e,t)=>[e,t])),y=RegExp(`[${_.join(``)}]`,`g`);return{minusSign:l,plusSign:u,decimal:d,group:f,literals:g,numeral:y,numerals:_,index:e=>String(v.get(e)),noNumeralUnits:c}}function q(e,t,n){return e.replaceAll?e.replaceAll(t,n):e.split(t).join(n)}function Ye(e){return e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`)}var J=F(h(),1);function Xe(){return typeof window<`u`&&window.InputEvent&&typeof InputEvent.prototype.getTargetRanges==`function`}function Ze(e,t,n){let r=l(e=>{let r=n.current;if(!r)return;let i=null;switch(e.inputType){case`historyUndo`:case`historyRedo`:return;case`insertLineBreak`:return;case`deleteContent`:case`deleteByCut`:case`deleteByDrag`:i=r.value.slice(0,r.selectionStart)+r.value.slice(r.selectionEnd);break;case`deleteContentForward`:i=r.selectionEnd===r.selectionStart?r.value.slice(0,r.selectionStart)+r.value.slice(r.selectionEnd+1):r.value.slice(0,r.selectionStart)+r.value.slice(r.selectionEnd);break;case`deleteContentBackward`:i=r.selectionEnd===r.selectionStart?r.value.slice(0,r.selectionStart-1)+r.value.slice(r.selectionStart):r.value.slice(0,r.selectionStart)+r.value.slice(r.selectionEnd);break;case`deleteSoftLineBackward`:case`deleteHardLineBackward`:i=r.value.slice(r.selectionStart);break;default:e.data!=null&&(i=r.value.slice(0,r.selectionStart)+e.data+r.value.slice(r.selectionEnd))}(i==null||!t.validate(i))&&e.preventDefault()});(0,J.useEffect)(()=>{if(!Xe()||!n.current)return;let e=n.current;return e.addEventListener(`beforeinput`,r,!1),()=>{e.removeEventListener(`beforeinput`,r,!1)}},[n]);let i=Xe()?null:e=>{let n=O(e).value.slice(0,O(e).selectionStart)+e.data+O(e).value.slice(O(e).selectionEnd);t.validate(n)||e.preventDefault()},{labelProps:a,inputProps:o,descriptionProps:s,errorMessageProps:c,...u}=j(e,n),d=(0,J.useRef)(null);return{inputProps:V(o,{onBeforeInput:i,onCompositionStart(){let{value:e,selectionStart:t,selectionEnd:r}=n.current;d.current={value:e,selectionStart:t,selectionEnd:r}},onCompositionEnd(){if(n.current&&!t.validate(n.current.value)){let{value:e,selectionStart:r,selectionEnd:i}=d.current;n.current.value=e,n.current.setSelectionRange(r,i),t.setInputValue(e)}}}),labelProps:a,descriptionProps:s,errorMessageProps:c,...u}}function Qe(e,t){let{onScroll:n,isDisabled:r}=e,i=(0,J.useCallback)(e=>{e.ctrlKey||(e.preventDefault(),e.stopPropagation(),n&&n({deltaX:e.deltaX,deltaY:e.deltaY}))},[n]);u(t,`wheel`,r?void 0:i)}var $e={};$e={Empty:`فارغ`};var et={};et={Empty:`Изпразни`};var tt={};tt={Empty:`Prázdné`};var nt={};nt={Empty:`Tom`};var rt={};rt={Empty:`Leer`};var it={};it={Empty:`Άδειο`};var at={};at={Empty:`Empty`};var ot={};ot={Empty:`Vacío`};var st={};st={Empty:`Tühjenda`};var ct={};ct={Empty:`Tyhjä`};var lt={};lt={Empty:`Vide`};var ut={};ut={Empty:`ריק`};var dt={};dt={Empty:`Prazno`};var ft={};ft={Empty:`Üres`};var pt={};pt={Empty:`Vuoto`};var mt={};mt={Empty:`空`};var ht={};ht={Empty:`비어 있음`};var gt={};gt={Empty:`Tuščias`};var _t={};_t={Empty:`Tukšs`};var vt={};vt={Empty:`Tom`};var yt={};yt={Empty:`Leeg`};var bt={};bt={Empty:`Pusty`};var xt={};xt={Empty:`Vazio`};var St={};St={Empty:`Vazio`};var Ct={};Ct={Empty:`Gol`};var wt={};wt={Empty:`Не заполнено`};var Tt={};Tt={Empty:`Prázdne`};var Et={};Et={Empty:`Prazen`};var Dt={};Dt={Empty:`Prazno`};var Ot={};Ot={Empty:`Tomt`};var kt={};kt={Empty:`Boş`};var At={};At={Empty:`Пусто`};var jt={};jt={Empty:`空`};var Mt={};Mt={Empty:`空白`};var Nt={};Nt={"ar-AE":$e,"bg-BG":et,"cs-CZ":tt,"da-DK":nt,"de-DE":rt,"el-GR":it,"en-US":at,"es-ES":ot,"et-EE":st,"fi-FI":ct,"fr-FR":lt,"he-IL":ut,"hr-HR":dt,"hu-HU":ft,"it-IT":pt,"ja-JP":mt,"ko-KR":ht,"lt-LT":gt,"lv-LV":_t,"nb-NO":vt,"nl-NL":yt,"pl-PL":bt,"pt-BR":xt,"pt-PT":St,"ro-RO":Ct,"ru-RU":wt,"sk-SK":Tt,"sl-SI":Et,"sr-SP":Dt,"sv-SE":Ot,"tr-TR":kt,"uk-UA":At,"zh-CN":jt,"zh-TW":Mt};function Pt(e){return e&&e.__esModule?e.default:e}var Ft=()=>{};function It(e){let t=(0,J.useRef)(void 0),{value:n,textValue:r,minValue:i,maxValue:a,isDisabled:o,isReadOnly:s,isRequired:c,onIncrement:u,onIncrementPage:d,onDecrement:f,onDecrementPage:p,onDecrementToMin:m,onIncrementToMax:h}=e,g=te(Pt(Nt),`@react-aria/spinbutton`),_=(0,J.useRef)(!1),v=(0,J.useCallback)(()=>{clearTimeout(t.current),_.current=!1},[]),y=l(()=>{v()});(0,J.useEffect)(()=>()=>y(),[]);let{keyboardProps:b}=he({isDisabled:o||s,shortcuts:{PageUp:()=>{if(d){d();return}if(u){u();return}return!1},ArrowUp:()=>{if(u){u();return}return!1},PageDown:()=>{if(p){p();return}if(f){f();return}return!1},ArrowDown:()=>{if(f){f();return}return!1},Home:()=>{if(m){m();return}return!1},End:()=>{if(h){h();return}return!1}},allowRepeats:!0}),x=(0,J.useRef)(!1),S=()=>{x.current=!0},C=()=>{x.current=!1},w=r===``?g.format(`Empty`):(r||`${n}`).replace(`-`,`−`);(0,J.useEffect)(()=>{x.current&&(De(`assertive`),Ce(w,`assertive`))},[w]);let T=(0,J.useCallback)(()=>{v()},[v]),E=l(u??Ft),D=l(f??Ft),O=l(()=>{(a===void 0||isNaN(a)||n===void 0||isNaN(n)||n<a)&&(E(),k(60))}),k=l(e=>{y(),_.current=!0,t.current=window.setTimeout(O,e)}),A=l(()=>{(i===void 0||isNaN(i)||n===void 0||isNaN(n)||n>i)&&(D(),j(60))}),j=l(e=>{y(),_.current=!0,t.current=window.setTimeout(A,e)}),M=e=>{e.preventDefault()},{addGlobalListener:N,removeAllGlobalListeners:ee}=ve(),P=(0,J.useRef)(!1),[F,I]=(0,J.useState)(null);(0,J.useEffect)(()=>{F===`touch`?k(600):F?k(400):F||y()},[F]);let[L,R]=(0,J.useState)(null);return(0,J.useEffect)(()=>{L===`touch`?j(600):L?j(400):L||y()},[L]),{spinButtonProps:{role:`spinbutton`,"aria-valuenow":n!==void 0&&!isNaN(n)?n:void 0,"aria-valuetext":w,"aria-valuemin":i,"aria-valuemax":a,"aria-disabled":o||void 0,"aria-readonly":s||void 0,"aria-required":c||void 0,...b,onFocus:S,onBlur:C},incrementButtonProps:{onPressStart:e=>{v(),e.pointerType===`touch`?(N(window,`pointercancel`,T,{capture:!0}),P.current=!1,I(`touch`)):(u?.(),I(`mouse`)),N(window,`contextmenu`,M)},onPressUp:e=>{v(),e.pointerType===`touch`&&(P.current=!0),ee(),I(null)},onPressEnd:e=>{v(),e.pointerType===`touch`&&!_.current&&P.current&&u?.(),P.current=!1,I(null)},onFocus:S,onBlur:C},decrementButtonProps:{onPressStart:e=>{v(),e.pointerType===`touch`?(N(window,`pointercancel`,T,{capture:!0}),P.current=!1,R(`touch`)):(f?.(),R(`mouse`))},onPressUp:e=>{v(),e.pointerType===`touch`&&(P.current=!0),ee(),R(null)},onPressEnd:e=>{v(),e.pointerType===`touch`&&!_.current&&P.current&&f?.(),P.current=!1,R(null)},onFocus:S,onBlur:C}}}var Lt={};Lt={decrease:e=>`\u{62E}\u{641}\u{636} ${e.fieldLabel}`,increase:e=>`\u{632}\u{64A}\u{627}\u{62F}\u{629} ${e.fieldLabel}`,numberField:`حقل رقمي`};var Rt={};Rt={decrease:e=>`\u{41D}\u{430}\u{43C}\u{430}\u{43B}\u{44F}\u{432}\u{430}\u{43D}\u{435} ${e.fieldLabel}`,increase:e=>`\u{423}\u{441}\u{438}\u{43B}\u{432}\u{430}\u{43D}\u{435} ${e.fieldLabel}`,numberField:`Номер на полето`};var zt={};zt={decrease:e=>`Sn\xed\u{17E}it ${e.fieldLabel}`,increase:e=>`Zv\xfd\u{161}it ${e.fieldLabel}`,numberField:`Číselné pole`};var Bt={};Bt={decrease:e=>`Reducer ${e.fieldLabel}`,increase:e=>`\xd8g ${e.fieldLabel}`,numberField:`Talfelt`};var Vt={};Vt={decrease:e=>`${e.fieldLabel} verringern`,increase:e=>`${e.fieldLabel} erh\xf6hen`,numberField:`Nummernfeld`};var Ht={};Ht={decrease:e=>`\u{39C}\u{3B5}\u{3AF}\u{3C9}\u{3C3}\u{3B7} ${e.fieldLabel}`,increase:e=>`\u{391}\u{3CD}\u{3BE}\u{3B7}\u{3C3}\u{3B7} ${e.fieldLabel}`,numberField:`Πεδίο αριθμού`};var Ut={};Ut={decrease:e=>`Decrease ${e.fieldLabel}`,increase:e=>`Increase ${e.fieldLabel}`,numberField:`Number field`};var Wt={};Wt={decrease:e=>`Reducir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:`Campo de número`};var Gt={};Gt={decrease:e=>`V\xe4henda ${e.fieldLabel}`,increase:e=>`Suurenda ${e.fieldLabel}`,numberField:`Numbri väli`};var Kt={};Kt={decrease:e=>`V\xe4henn\xe4 ${e.fieldLabel}`,increase:e=>`Lis\xe4\xe4 ${e.fieldLabel}`,numberField:`Numerokenttä`};var qt={};qt={decrease:e=>`Diminuer ${e.fieldLabel}`,increase:e=>`Augmenter ${e.fieldLabel}`,numberField:`Champ de nombre`};var Jt={};Jt={decrease:e=>`\u{5D4}\u{5E7}\u{5D8}\u{5DF} ${e.fieldLabel}`,increase:e=>`\u{5D4}\u{5D2}\u{5D3}\u{5DC} ${e.fieldLabel}`,numberField:`שדה מספר`};var Yt={};Yt={decrease:e=>`Smanji ${e.fieldLabel}`,increase:e=>`Pove\u{107}aj ${e.fieldLabel}`,numberField:`Polje broja`};var Xt={};Xt={decrease:e=>`${e.fieldLabel} cs\xf6kkent\xe9se`,increase:e=>`${e.fieldLabel} n\xf6vel\xe9se`,numberField:`Számmező`};var Zt={};Zt={decrease:e=>`Riduci ${e.fieldLabel}`,increase:e=>`Aumenta ${e.fieldLabel}`,numberField:`Campo numero`};var Qt={};Qt={decrease:e=>`${e.fieldLabel}\u{3092}\u{7E2E}\u{5C0F}`,increase:e=>`${e.fieldLabel}\u{3092}\u{62E1}\u{5927}`,numberField:`数値フィールド`};var $t={};$t={decrease:e=>`${e.fieldLabel} \u{AC10}\u{C18C}`,increase:e=>`${e.fieldLabel} \u{C99D}\u{AC00}`,numberField:`번호 필드`};var en={};en={decrease:e=>`Suma\u{17E}inti ${e.fieldLabel}`,increase:e=>`Padidinti ${e.fieldLabel}`,numberField:`Numerio laukas`};var tn={};tn={decrease:e=>`Samazin\u{101}\u{161}ana ${e.fieldLabel}`,increase:e=>`Palielin\u{101}\u{161}ana ${e.fieldLabel}`,numberField:`Skaitļu lauks`};var nn={};nn={decrease:e=>`Reduser ${e.fieldLabel}`,increase:e=>`\xd8k ${e.fieldLabel}`,numberField:`Tallfelt`};var rn={};rn={decrease:e=>`${e.fieldLabel} verlagen`,increase:e=>`${e.fieldLabel} verhogen`,numberField:`Getalveld`};var an={};an={decrease:e=>`Zmniejsz ${e.fieldLabel}`,increase:e=>`Zwi\u{119}ksz ${e.fieldLabel}`,numberField:`Pole numeru`};var on={};on={decrease:e=>`Diminuir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:`Campo de número`};var sn={};sn={decrease:e=>`Diminuir ${e.fieldLabel}`,increase:e=>`Aumentar ${e.fieldLabel}`,numberField:`Campo numérico`};var cn={};cn={decrease:e=>`Sc\u{103}dere ${e.fieldLabel}`,increase:e=>`Cre\u{219}tere ${e.fieldLabel}`,numberField:`Câmp numeric`};var ln={};ln={decrease:e=>`\u{423}\u{43C}\u{435}\u{43D}\u{44C}\u{448}\u{435}\u{43D}\u{438}\u{435} ${e.fieldLabel}`,increase:e=>`\u{423}\u{432}\u{435}\u{43B}\u{438}\u{447}\u{435}\u{43D}\u{438}\u{435} ${e.fieldLabel}`,numberField:`Числовое поле`};var un={};un={decrease:e=>`Zn\xed\u{17E}i\u{165} ${e.fieldLabel}`,increase:e=>`Zv\xfd\u{161}i\u{165} ${e.fieldLabel}`,numberField:`Číselné pole`};var dn={};dn={decrease:e=>`Upadati ${e.fieldLabel}`,increase:e=>`Pove\u{10D}ajte ${e.fieldLabel}`,numberField:`Številčno polje`};var fn={};fn={decrease:e=>`Smanji ${e.fieldLabel}`,increase:e=>`Pove\u{107}aj ${e.fieldLabel}`,numberField:`Polje broja`};var pn={};pn={decrease:e=>`Minska ${e.fieldLabel}`,increase:e=>`\xd6ka ${e.fieldLabel}`,numberField:`Nummerfält`};var mn={};mn={decrease:e=>`${e.fieldLabel} azalt`,increase:e=>`${e.fieldLabel} artt\u{131}r`,numberField:`Sayı alanı`};var hn={};hn={decrease:e=>`\u{417}\u{43C}\u{435}\u{43D}\u{448}\u{438}\u{442}\u{438} ${e.fieldLabel}`,increase:e=>`\u{417}\u{431}\u{456}\u{43B}\u{44C}\u{448}\u{438}\u{442}\u{438} ${e.fieldLabel}`,numberField:`Поле номера`};var gn={};gn={decrease:e=>`\u{964D}\u{4F4E} ${e.fieldLabel}`,increase:e=>`\u{63D0}\u{9AD8} ${e.fieldLabel}`,numberField:`数字字段`};var _n={};_n={decrease:e=>`\u{7E2E}\u{5C0F} ${e.fieldLabel}`,increase:e=>`\u{653E}\u{5927} ${e.fieldLabel}`,numberField:`數字欄位`};var vn={};vn={"ar-AE":Lt,"bg-BG":Rt,"cs-CZ":zt,"da-DK":Bt,"de-DE":Vt,"el-GR":Ht,"en-US":Ut,"es-ES":Wt,"et-EE":Gt,"fi-FI":Kt,"fr-FR":qt,"he-IL":Jt,"hr-HR":Yt,"hu-HU":Xt,"it-IT":Zt,"ja-JP":Qt,"ko-KR":$t,"lt-LT":en,"lv-LV":tn,"nb-NO":nn,"nl-NL":rn,"pl-PL":an,"pt-BR":on,"pt-PT":sn,"ro-RO":cn,"ru-RU":ln,"sk-SK":un,"sl-SI":dn,"sr-SP":fn,"sv-SE":pn,"tr-TR":mn,"uk-UA":hn,"zh-CN":gn,"zh-TW":_n};var yn=F(L(),1);function bn(e){return e&&e.__esModule?e.default:e}function xn(e,t,n){let{id:i,decrementAriaLabel:o,incrementAriaLabel:s,isDisabled:c,isReadOnly:l,isRequired:u,minValue:d,maxValue:f,autoFocus:p,label:m,formatOptions:h,onBlur:g=()=>{},onFocus:v,onFocusChange:y,onKeyDown:b,onKeyUp:x,description:C,errorMessage:w,isWheelDisabled:E,...D}=e,{increment:k,incrementToMax:j,decrement:M,decrementToMin:N,numberValue:P,inputValue:F,commit:I,commitValidation:L}=t,R=te(bn(vn),`@react-aria/numberfield`),z=(0,J.useCallback)(()=>{let e=n.current?.value??``;(0,yn.flushSync)(()=>{I()}),n.current?.value!==e&&Ce(n.current?.value??``,`assertive`)},[I,n]),ne=_(i),{focusProps:re}=ae({onBlur(){z()}}),ie=se(h),B=(0,J.useMemo)(()=>ie.resolvedOptions(),[ie]),oe=se({...h,currencySign:void 0}),{spinButtonProps:ce,incrementButtonProps:le,decrementButtonProps:ue}=It({isDisabled:c,isReadOnly:l,isRequired:u,maxValue:f,minValue:d,onIncrement:k,onIncrementToMax:j,onDecrement:M,onDecrementToMin:N,value:P,textValue:(0,J.useMemo)(()=>isNaN(P)?``:oe.format(P),[oe,P])}),[de,fe]=(0,J.useState)(!1),{focusWithinProps:pe}=Oe({isDisabled:c,onFocusWithinChange:fe});Qe({onScroll:(0,J.useCallback)(e=>{Math.abs(e.deltaY)<=Math.abs(e.deltaX)||(e.deltaY>0?k():e.deltaY<0&&M())},[M,k]),isDisabled:E||c||l||!de},n);let me=(B.maximumFractionDigits??0)>0,ge=t.minValue===void 0||isNaN(t.minValue)||t.minValue<0,_e=`numeric`;A()?ge?_e=`text`:me&&(_e=`decimal`):Pe()&&(ge?_e=`numeric`:me&&(_e=`decimal`));let ve=e=>{t.validate(e)&&t.setInputValue(e)},ye=t=>{e.onPaste?.(t);let n=O(t);n&&(n.selectionEnd??-1)-(n.selectionStart??0)===n.value.length&&(t.preventDefault(),I(t.clipboardData?.getData?.(`text/plain`)?.trim()??``))},H=r(e),{keyboardProps:be}=he({isDisabled:c||l,shortcuts:{Enter:()=>((0,yn.flushSync)(()=>{I()}),L(),{shouldPreventDefault:!1})},onKeyDown:b,onKeyUp:x}),{isInvalid:xe,validationErrors:Se,validationDetails:U}=t.displayValidation,{labelProps:we,inputProps:Te,descriptionProps:Ee,errorMessageProps:De}=Ze({...D,...H,name:void 0,form:void 0,label:m,autoFocus:p,isDisabled:c,isReadOnly:l,isRequired:u,validate:void 0,[S]:t,value:F,defaultValue:`!`,autoComplete:`off`,"aria-label":e[`aria-label`]||void 0,"aria-labelledby":e[`aria-labelledby`]||void 0,id:ne,type:`text`,inputMode:_e,onChange:ve,onBlur:g,onFocus:v,onFocusChange:y,onPaste:ye,description:C,errorMessage:w},t,n),ke=V(be,Te);ee(n,t.defaultNumberValue,t.setNumberValue),Sn(t,e.validationBehavior,e.commitBehavior,n,t.minValue,t.maxValue,e.step,t.numberValue);let W=V(ce,re,ke,{role:null,"aria-roledescription":a()?null:R.format(`numberField`),"aria-valuemax":null,"aria-valuemin":null,"aria-valuenow":null,"aria-valuetext":null,autoCorrect:`off`,spellCheck:`false`});e.validationBehavior===`native`&&(W[`aria-required`]=void 0);let Ae=e=>{T()!==n.current&&(e.pointerType===`mouse`?n.current?.focus():e.target.focus())},je=e[`aria-label`]||(typeof e.label==`string`?e.label:``),G;je||(G=e.label==null?e[`aria-labelledby`]:we.id);let K=_(),Me=_(),Ne=V(le,{"aria-label":s||R.format(`increase`,{fieldLabel:je}).trim(),id:G&&!s?K:null,"aria-labelledby":G&&!s?`${K} ${G}`:null,"aria-controls":ne,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canIncrement,onPressStart:Ae}),Fe=V(ue,{"aria-label":o||R.format(`decrease`,{fieldLabel:je}).trim(),id:G&&!o?Me:null,"aria-labelledby":G&&!o?`${Me} ${G}`:null,"aria-controls":ne,excludeFromTabOrder:!0,preventFocusOnPress:!0,allowFocusWhenDisabled:!0,isDisabled:!t.canDecrement,onPressStart:Ae});return{groupProps:{...pe,role:`group`,"aria-disabled":c,"aria-invalid":xe?`true`:void 0},labelProps:we,inputProps:W,incrementButtonProps:Ne,decrementButtonProps:Fe,errorMessageProps:De,descriptionProps:Ee,isInvalid:xe,validationErrors:Se,validationDetails:U}}var Y=null;function Sn(e,t,n,r,i,a,o,s){x(()=>{let c=r.current;if(n!==`validate`||e.realtimeValidation.isInvalid||!c||c.disabled||(!Y&&typeof document<`u`&&(Y=document.createElement(`input`),Y.type=`number`),!Y))return;Y.min=i!=null&&!isNaN(i)?String(i):``,Y.max=a!=null&&!isNaN(a)?String(a):``,Y.step=o!=null&&!isNaN(o)?String(o):``,Y.value=s!=null&&!isNaN(s)?String(s):``;let l=c.validity.valid&&Y.validity.valid,u=c.validationMessage||Y.validationMessage,d={isInvalid:!l,validationErrors:u?[u]:[],validationDetails:{badInput:c.validity.badInput,customError:c.validity.customError,patternMismatch:c.validity.patternMismatch,rangeOverflow:Y.validity.rangeOverflow,rangeUnderflow:Y.validity.rangeUnderflow,stepMismatch:Y.validity.stepMismatch,tooLong:c.validity.tooLong,tooShort:c.validity.tooShort,typeMismatch:c.validity.typeMismatch,valueMissing:c.validity.valueMissing,valid:l}};e.updateValidation(d),t===`native`&&!Y.validity.valid&&c.setCustomValidity(Y.validationMessage)})}function Cn(e){let{minValue:t,maxValue:n,step:r,formatOptions:i,value:a,defaultValue:o=NaN,onChange:c,locale:l,isDisabled:u,isReadOnly:d,commitBehavior:f=`snap`}=e;a===null&&(a=NaN);let p=(0,J.useCallback)(e=>r===void 0||isNaN(r)?s(e,t,n):G(e,t,n,r),[r,t,n]);a!==void 0&&!isNaN(a)&&f===`snap`&&(a=p(a)),!isNaN(o)&&f===`snap`&&(o=p(o));let[m,h]=R(a,isNaN(o)?NaN:o,c),[g]=(0,J.useState)(m),[_,v]=(0,J.useState)(()=>isNaN(m)?``:new ye(l,i).format(m)),y=(0,J.useMemo)(()=>new Ve(l,i),[l,i]),b=(0,J.useMemo)(()=>y.getNumberingSystem(_),[y,_]),x=(0,J.useMemo)(()=>new ye(l,{...i,numberingSystem:b}),[l,i,b]),S=(0,J.useMemo)(()=>x.resolvedOptions(),[x]),C=(0,J.useCallback)(e=>isNaN(e)||e===null?``:x.format(e),[x]),T=w({...e,value:m}),E=r!==void 0&&!isNaN(r)?r:1;S.style===`percent`&&(r===void 0||isNaN(r))&&(E=.01);let[D,O]=(0,J.useState)(m),[k,A]=(0,J.useState)(l),[j,M]=(0,J.useState)(i);(!Object.is(m,D)||l!==k||!wn(i,j))&&(v(C(m)),O(m),A(l),M(i));let N=(0,J.useMemo)(()=>y.parse(_),[y,_]),ee=e=>{let t=e===void 0?_:e,n=N;if(e!==void 0&&(n=y.parse(t)),!t.length){h(NaN),v(a===void 0?``:C(m));return}if(isNaN(n)){v(C(m));return}let r=f===`snap`?p(n):n;r=y.parse(C(r));let i=r!==m;h(r),v(C(a===void 0?r:m)),i&&T.commitValidation()},P=(e,r=0)=>{let i=N;if(isNaN(i))return G(isNaN(r)?0:r,t,n,E);{let r=G(i,t,n,E);return e===`+`&&r>i||e===`-`&&r<i?r:G(Tn(e,i,E),t,n,E)}},F=()=>{let e=P(`+`,t);e===m&&v(C(e)),h(e),T.commitValidation()},I=()=>{let e=P(`-`,n);e===m&&v(C(e)),h(e),T.commitValidation()},L=()=>{n!=null&&(h(G(n,t,n,E)),T.commitValidation())},te=()=>{t!=null&&(h(t),T.commitValidation())},z=(0,J.useMemo)(()=>!u&&!d&&(isNaN(N)||n===void 0||isNaN(n)||G(N,t,n,E)>N||Tn(`+`,N,E)<=n),[u,d,t,n,E,N]),ne=(0,J.useMemo)(()=>!u&&!d&&(isNaN(N)||t===void 0||isNaN(t)||G(N,t,n,E)<N||Tn(`-`,N,E)>=t),[u,d,t,n,E,N]),re=e=>y.isValidPartialNumber(e,t,n);return{...T,validate:re,increment:F,incrementToMax:L,decrement:I,decrementToMin:te,canIncrement:z,canDecrement:ne,minValue:t,maxValue:n,numberValue:N,defaultNumberValue:isNaN(o)?g:o,setNumberValue:h,setInputValue:v,inputValue:_,commit:ee}}function wn(e,t){if(e===t)return!0;if(!e||!t)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(t[r]!==e[r])return!1;return!0}function Tn(e,t,n){let r=e===`+`?t+n:t-n;if(t%1!=0||n%1!=0){let i=t.toString().split(`.`),a=n.toString().split(`.`),o=i[1]&&i[1].length||0,s=a[1]&&a[1].length||0,c=10**Math.max(o,s);t=Math.round(t*c),n=Math.round(n*c),r=e===`+`?t+n:t-n,r/=c}return r}var En=(0,J.createContext)(null),Dn=(0,J.createContext)(null),On=(0,J.forwardRef)(function(e,t){[e,t]=we(e,t,En);let{validationBehavior:n}=Ae(ge)||{},i=e.validationBehavior??n??`native`,{locale:a}=ke(),s=Cn({...e,locale:a,validationBehavior:i}),c=(0,J.useRef)(null),[l,u]=me(!e[`aria-label`]&&!e[`aria-labelledby`]),{labelProps:d,groupProps:f,inputProps:p,incrementButtonProps:m,decrementButtonProps:h,descriptionProps:_,errorMessageProps:v,...y}=xn({...ie(e),label:u,validationBehavior:i},s,c),x=be({...e,values:{state:s,isDisabled:e.isDisabled||!1,isInvalid:y.isInvalid||!1,isRequired:e.isRequired||!1,isReadOnly:e.isReadOnly||!1},defaultClassName:`react-aria-NumberField`}),S=r(e,{global:!0});return delete S.id,J.createElement(de,{values:[[Dn,s],[g,f],[o,{...p,ref:c}],[ce,{...d,ref:l}],[ne,{slots:{increment:m,decrement:h}}],[b,{slots:{description:_,errorMessage:v}}],[D,y]]},J.createElement(fe.div,{...S,...x,ref:t,slot:e.slot||void 0,"data-disabled":e.isDisabled||void 0,"data-readonly":e.isReadOnly||void 0,"data-required":e.isRequired||void 0,"data-invalid":y.isInvalid||void 0}),e.name&&J.createElement(`input`,{type:`hidden`,name:e.name,form:e.form,value:isNaN(s.numberValue)?``:s.numberValue,disabled:e.isDisabled||void 0}))}),kn=new WeakMap;function An(e,t,n){let{value:i,children:a,"aria-label":o,"aria-labelledby":s,onPressStart:c,onPressEnd:l,onPressChange:u,onPress:d,onPressUp:f,onClick:p}=e,m=e.isDisabled||t.isDisabled,h=t.selectedValue===i,g=e=>{e.stopPropagation(),t.setSelectedValue(i)},{pressProps:_,isPressed:v}=xe({onPressStart:c,onPressEnd:l,onPressChange:u,onPress:d,onPressUp:f,onClick:p,isDisabled:m}),{pressProps:y,isPressed:b}=xe({onPressStart:c,onPressEnd:l,onPressChange:u,onPressUp:f,onClick:p,isDisabled:m,onPress(e){d?.(e),t.setSelectedValue(i),n.current?.focus()}}),{focusableProps:x}=Ee(V(e,{onFocus:()=>t.setLastFocusedValue(i)}),n),S=V(_,x),C=r(e,{labelable:!0}),w=-1;t.selectedValue==null?(t.lastFocusedValue===i||t.lastFocusedValue==null)&&(w=0):t.selectedValue===i&&(w=0),m&&(w=void 0);let{name:T,form:E,descriptionId:D,errorMessageId:O,validationBehavior:k}=kn.get(t);ee(n,t.defaultSelectedValue,t.setSelectedValue),_e({validationBehavior:k},t,n);let A=N();return{labelProps:V(y,(0,J.useMemo)(()=>({onClick:e=>e.preventDefault(),onMouseDown:e=>e.preventDefault()}),[])),inputProps:V(C,{...S,type:`radio`,name:T,form:E,tabIndex:w,disabled:m,required:t.isRequired&&k===`native`,checked:h,value:i,onChange:g,"aria-describedby":[e[`aria-describedby`],A.id,t.isInvalid?O:null,D].filter(Boolean).join(` `)||void 0}),descriptionProps:A,isDisabled:m,isSelected:h,isPressed:v||b}}function jn(e,t){let{name:i,form:a,isReadOnly:o,isRequired:s,isDisabled:c,orientation:l=`vertical`,validationBehavior:u=`aria`}=e,{direction:d}=ke(),{isInvalid:m,validationErrors:h,validationDetails:g}=t.displayValidation,{labelProps:v,fieldProps:y,descriptionProps:b,errorMessageProps:x}=n({...e,labelElementType:`span`,isInvalid:t.isInvalid,errorMessage:e.errorMessage||h}),S=r(e,{labelable:!0}),{focusWithinProps:C}=Oe({onBlurWithin(n){e.onBlur?.(n),t.selectedValue||t.setLastFocusedValue(null)},onFocusWithin:e.onFocus,onFocusWithinChange:e.onFocusChange});function w(e,n){let r=p(n.currentTarget,{from:O(n),accept:e=>e instanceof f(e).HTMLInputElement&&e.type===`radio`}),i;return e===`next`?(i=r.nextNode(),i||=(r.currentNode=n.currentTarget,r.firstChild())):(i=r.previousNode(),i||=(r.currentNode=n.currentTarget,r.lastChild())),i?(i.focus(),t.setSelectedValue(i.value),!0):!1}let{keyboardProps:T}=he({shortcuts:{ArrowRight:e=>w(d===`rtl`&&l!==`vertical`?`prev`:`next`,e),ArrowLeft:e=>w(d===`rtl`&&l!==`vertical`?`next`:`prev`,e),ArrowDown:e=>w(`next`,e),ArrowUp:e=>w(`prev`,e)},allowRepeats:!0}),E=_(i);return kn.set(t,{name:E,form:a,descriptionId:b.id,errorMessageId:x.id,validationBehavior:u}),{radioGroupProps:V(S,{role:`radiogroup`,...T,"aria-invalid":t.isInvalid||void 0,"aria-errormessage":e[`aria-errormessage`],"aria-readonly":o||void 0,"aria-required":s||void 0,"aria-disabled":c||void 0,"aria-orientation":l,...y,...C}),labelProps:v,descriptionProps:b,errorMessageProps:x,isInvalid:m,validationErrors:h,validationDetails:g}}var Mn=Math.round(Math.random()*1e10),Nn=0;function Pn(e){let t=(0,J.useMemo)(()=>e.name||`radio-group-${Mn}-${++Nn}`,[e.name]),[n,r]=R(e.value,e.defaultValue??null,e.onChange),[i]=(0,J.useState)(n),[a,o]=(0,J.useState)(null),s=w({...e,value:n}),c=t=>{!e.isReadOnly&&!e.isDisabled&&(r(t),s.commitValidation())},l=s.displayValidation.isInvalid;return{...s,name:t,selectedValue:n,defaultSelectedValue:e.value===void 0?e.defaultValue??null:i,setSelectedValue:c,lastFocusedValue:a,setLastFocusedValue:o,isDisabled:e.isDisabled||!1,isReadOnly:e.isReadOnly||!1,isRequired:e.isRequired||!1,validationState:e.validationState||(l?`invalid`:null),isInvalid:l}}var Fn=(0,J.createContext)(null),In=(0,J.createContext)(null),Ln=(0,J.createContext)(null),Rn=(0,J.forwardRef)(function(e,t){[e,t]=we(e,t,Fn);let{validationBehavior:n}=Ae(ge)||{},i=e.validationBehavior??n??`native`,a=Pn({...e,validationBehavior:i}),[o,s]=me(!e[`aria-label`]&&!e[`aria-labelledby`]),{radioGroupProps:c,labelProps:l,descriptionProps:u,errorMessageProps:d,...f}=jn({...e,label:s,validationBehavior:i},a),p=be({...e,values:{orientation:e.orientation||`vertical`,isDisabled:a.isDisabled,isReadOnly:a.isReadOnly,isRequired:a.isRequired,isInvalid:a.isInvalid,state:a},defaultClassName:`react-aria-RadioGroup`}),m=r(e,{global:!0});return J.createElement(fe.div,{...V(m,p,c),ref:t,slot:e.slot||void 0,"data-orientation":e.orientation||`vertical`,"data-invalid":a.isInvalid||void 0,"data-disabled":a.isDisabled||void 0,"data-readonly":a.isReadOnly||void 0,"data-required":a.isRequired||void 0},J.createElement(de,{values:[[Ln,a],[ce,{...l,ref:o,elementType:`span`}],[b,{slots:{description:u,errorMessage:d}}],[D,f]]},J.createElement(I,null,p.children)))}),zn=(0,J.createContext)(null),Bn=(0,J.forwardRef)(function(e,t){let{inputRef:n=null,...a}=e;[e,t]=we(a,t,In);let o=J.useContext(Ln),s=E((0,J.useMemo)(()=>C(n,e.inputRef===void 0?null:e.inputRef),[n,e.inputRef])),c=An({...ie(e),children:typeof e.children==`function`||e.children},o,s),{descriptionProps:l,isSelected:u,isDisabled:d}=c,f=be({...e,defaultClassName:`react-aria-RadioField`,values:{isSelected:u,isDisabled:d,isReadOnly:o.isReadOnly,isInvalid:o.isInvalid,isRequired:o.isRequired}}),p=r(e,{global:!0});return delete p.id,delete p.onClick,J.createElement(fe.div,{...V(p,f),ref:t,"data-selected":u||void 0,"data-disabled":d||void 0,"data-readonly":o.isReadOnly||void 0,"data-invalid":o.isInvalid||void 0,"data-required":o.isRequired||void 0},J.createElement(de,{values:[[i,{isSelected:u}],[zn,{...c,inputRef:s,defaultClassName:`react-aria-RadioButton`}],[b,{slots:{description:l}}]]},f.children))}),Vn=(0,J.forwardRef)(function(e,n){let{labelProps:i,inputProps:a,isSelected:o,isDisabled:s,isPressed:c,defaultClassName:l,inputRef:u}=(0,J.useContext)(zn),d=J.useContext(Ln),{isFocused:f,isFocusVisible:p,focusProps:m}=le(),h=s||d.isReadOnly,{hoverProps:g,isHovered:_}=t({...e,isDisabled:h}),v=be({...e,defaultClassName:l,values:{isSelected:o,isPressed:c,isHovered:_,isFocused:f,isFocusVisible:p,isDisabled:s,isReadOnly:d.isReadOnly,isInvalid:d.isInvalid,isRequired:d.isRequired}}),y=r(e,{global:!0});return delete y.id,delete y.onClick,J.createElement(fe.label,{...V(y,i,g,v),ref:n,"data-selected":o||void 0,"data-pressed":c||void 0,"data-hovered":_||void 0,"data-focused":f||void 0,"data-focus-visible":p||void 0,"data-disabled":s||void 0,"data-readonly":d.isReadOnly||void 0,"data-invalid":d.isInvalid||void 0,"data-required":d.isRequired||void 0},J.createElement(P,{elementType:`span`},J.createElement(`input`,{...V(a,m),ref:u})),v.children)}),X=M(),Hn=({children:e,className:t,...n})=>(0,X.jsx)(m,{className:Fe({className:t}),"data-slot":`header`,...n,children:e}),Un=(0,J.createContext)({}),Wn=({children:e,className:t,fullWidth:n,variant:r,...i})=>{let a=J.useMemo(()=>Ie({fullWidth:n,variant:r}),[n,r]),o=J.useMemo(()=>({slots:a}),[a]);return(0,X.jsx)(Un,{value:o,children:(0,X.jsx)(On,{"data-slot":`number-field`,...i,className:z(t,a?.base()),children:t=>(0,X.jsx)(X.Fragment,{children:typeof e==`function`?e(t):e})})})},Z=Object.assign(Wn,{Root:Wn,Group:({children:e,className:t,...n})=>{let{slots:r}=(0,J.use)(Un);return(0,X.jsx)(d,{className:z(t,r?.group()),"data-slot":`number-field-group`,...n,children:t=>(0,X.jsx)(X.Fragment,{children:typeof e==`function`?e(t):e})})},Input:({className:e,...t})=>{let{slots:n}=(0,J.use)(Un);return(0,X.jsx)(je,{className:z(e,n?.input()),"data-slot":`number-field-input`,...t})},IncrementButton:({children:e,className:t,...n})=>{let{slots:r}=(0,J.use)(Un);return(0,X.jsx)(k,{className:z(t,r?.incrementButton()),"data-slot":`number-field-increment-button`,slot:`increment`,...n,children:e&&J.isValidElement(e)?e:(0,X.jsx)(Te,{"data-slot":`number-field-increment-button-icon`})})},DecrementButton:({children:e,className:t,...n})=>{let{slots:r}=(0,J.use)(Un);return(0,X.jsx)(k,{className:z(t,r?.decrementButton()),"data-slot":`number-field-decrement-button`,slot:`decrement`,...n,children:e&&J.isValidElement(e)?e:(0,X.jsx)(y,{"data-slot":`number-field-decrement-button-icon`})})}}),Gn={elementType:`span`},Kn=(0,J.createContext)({}),qn=({children:e,className:t,...n})=>{let r=J.useMemo(()=>Re(),[]);return(0,X.jsx)(Bn,{"data-slot":`radio`,...n,className:z(t,r.base()),children:t=>(0,X.jsx)(Kn,{value:{slots:r,state:t},children:typeof e==`function`?e(t):e})})};qn.displayName=`HeroUI.Radio`;var Jn=({children:e,className:t,...n})=>{let{slots:r}=(0,J.use)(Kn);return(0,X.jsx)(Vn,{"data-slot":`radio-content`,...n,className:z(t,r?.content()),children:t=>(0,X.jsx)(ce,{value:Gn,children:typeof e==`function`?e(t):e})})};Jn.displayName=`HeroUI.Radio.Content`;var Yn=({children:e,className:t,...n})=>{let{slots:r}=(0,J.use)(Kn);return(0,X.jsx)(Me.span,{className:v(r?.control,t),"data-slot":`radio-control`,...n,children:e})};Yn.displayName=`HeroUI.Radio.Control`;var Xn=({children:e,className:t,...n})=>{let{slots:r,state:i}=(0,J.use)(Kn),a=typeof e==`function`?e(i??{}):e;return(0,X.jsx)(Me.span,{"aria-hidden":`true`,className:v(r?.indicator,t),"data-slot":`radio-indicator`,...n,children:a})};Xn.displayName=`HeroUI.Radio.Indicator`;var Q=Object.assign(qn,{Root:qn,Content:Jn,Control:Yn,Indicator:Xn}),Zn=({children:e,className:t,variant:n,...r})=>{let i=J.useMemo(()=>Le({variant:n}),[n]);return(0,X.jsx)(Rn,{"data-slot":`radio-group`,...r,className:z(t,i),children:t=>(0,X.jsx)(X.Fragment,{children:typeof e==`function`?e(t):e})})},Qn=Object.assign(Zn,{Root:Zn}),$n={name:`clock`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M12 6v6l4 2`,key:`mmk7yg`}]]};$n.node;var er=Se($n),tr=`*/10 * * * *`,nr=[`周日`,`周一`,`周二`,`周三`,`周四`,`周五`,`周六`],rr=[{title:`高频检查`,presets:[{id:`every5`,label:`每 5 分钟`,description:`更频繁地检查推送,适合更新很密集的账号。`,value:`*/5 * * * *`},{id:`every10`,label:`每 10 分钟`,description:`推荐:全天每 10 分钟检查一次推送。`,value:`*/10 * * * *`},{id:`every15`,label:`每 15 分钟`,description:`兼顾及时性和任务频率,适合大多数推送。`,value:`*/15 * * * *`},{id:`every30`,label:`每 30 分钟`,description:`检查频率较低,适合不太活跃的推送。`,value:`*/30 * * * *`}]},{title:`按小时轮询`,presets:[{id:`hourly`,label:`每小时一次`,description:`每个整点执行,例如 00:00、01:00。`,value:`0 * * * *`},{id:`every2Hours`,label:`每 2 小时`,description:`从 0 点开始,每隔 2 小时执行一次。`,value:`0 */2 * * *`},{id:`every3Hours`,label:`每 3 小时`,description:`从 0 点开始,每隔 3 小时执行一次。`,value:`0 */3 * * *`},{id:`every6Hours`,label:`每 6 小时`,description:`每天 0 点、6 点、12 点、18 点执行。`,value:`0 */6 * * *`}]},{title:`每天固定时间`,presets:[{id:`daily8`,label:`每天上午 8 点`,description:`每天早上固定执行一次。`,value:`0 8 * * *`},{id:`daily9`,label:`每天上午 9 点`,description:`每天固定执行一次。`,value:`0 9 * * *`},{id:`daily12`,label:`每天中午 12 点`,description:`每天午间固定执行一次。`,value:`0 12 * * *`},{id:`daily18`,label:`每天晚上 6 点`,description:`每天傍晚固定执行一次。`,value:`0 18 * * *`},{id:`daily20`,label:`每天晚上 8 点`,description:`适合晚间集中推送。`,value:`0 20 * * *`},{id:`daily22`,label:`每天晚上 10 点`,description:`每天夜间固定执行一次。`,value:`0 22 * * *`}]},{title:`每天多次`,presets:[{id:`daily9And20`,label:`每天 9 点和 20 点`,description:`每天早晚各执行一次。`,value:`0 9,20 * * *`},{id:`daily9And12And18`,label:`每天 9 点、12 点、18 点`,description:`每天早中晚各执行一次。`,value:`0 9,12,18 * * *`}]},{title:`按星期`,presets:[{id:`weekday9`,label:`工作日上午 9 点`,description:`只在周一到周五执行。`,value:`0 9 * * 1,2,3,4,5`},{id:`weekday18`,label:`工作日晚上 6 点`,description:`只在周一到周五的傍晚执行。`,value:`0 18 * * 1,2,3,4,5`},{id:`weekend10`,label:`周末上午 10 点`,description:`只在周六和周日执行。`,value:`0 10 * * 0,6`},{id:`friday20`,label:`每周五晚上 8 点`,description:`每周五固定执行一次。`,value:`0 20 * * 5`}]}],ir=rr.flatMap(e=>e.presets),ar={minuteType:`interval`,minuteInterval:10,specificMinutes:[],hourType:`every`,hourInterval:1,specificHours:[],dayType:`every`,dayInterval:1,specificDays:[],weekType:`every`,specificWeeks:[]},or=e=>String(e).padStart(2,`0`),sr=(e,t,n,r)=>Number.isFinite(e)?Math.min(n,Math.max(t,Math.trunc(e))):r,$=(e,t,n)=>Array.from(new Set(e.filter(e=>Number.isInteger(e)&&e>=t&&e<=n))).sort((e,t)=>e-t),cr=(e,t,n)=>$(e.split(`,`).map(e=>Number(e.trim())).filter(e=>Number.isFinite(e)),t,n),lr=e=>$(e.split(`,`).map(e=>{let t=Number(e.trim());return t===7?0:t}).filter(e=>Number.isFinite(e)),0,6),ur=(e,t,n,r)=>{if(e===`*`||e===`*/1`)return{type:`every`,interval:r,specific:[]};let i=e.match(/^\*\/(\d+)$/);if(i){let e=sr(Number(i[1]),1,n,r);return e<=1?{type:`every`,interval:r,specific:[]}:{type:`interval`,interval:e,specific:[]}}let a=cr(e,t,n);return a.length>0?{type:`specific`,interval:r,specific:a}:{type:`every`,interval:r,specific:[]}},dr=e=>{let t=(e||tr).trim().split(/\s+/);if(t.length!==5)return{...ar};let[n,r,i,,a]=t,o=ur(n,0,59,10),s=ur(r,0,23,1),c=ur(i,1,31,1),l=a===`*`?[]:lr(a),u=l.length>0;return{minuteType:o.type,minuteInterval:o.interval,specificMinutes:o.specific,hourType:s.type,hourInterval:s.interval,specificHours:s.specific,dayType:u?`every`:c.type,dayInterval:u?1:c.interval,specificDays:u?[]:c.specific,weekType:u?`specific`:`every`,specificWeeks:l}},fr=e=>{let t=`*`,n=`*`,r=`*`,i=`*`;switch(e.minuteType){case`every`:t=`*`;break;case`interval`:t=e.minuteInterval<=1?`*`:`*/${e.minuteInterval}`;break;case`specific`:t=e.specificMinutes.length>0?$(e.specificMinutes,0,59).join(`,`):`0`}switch(e.hourType){case`every`:n=`*`;break;case`interval`:n=e.hourInterval<=1?`*`:`*/${e.hourInterval}`;break;case`specific`:n=e.specificHours.length>0?$(e.specificHours,0,23).join(`,`):`0`}switch(e.dayType){case`every`:r=`*`;break;case`interval`:r=e.dayInterval<=1?`*`:`*/${e.dayInterval}`;break;case`specific`:r=e.specificDays.length>0?$(e.specificDays,1,31).join(`,`):`1`}return e.weekType===`specific`&&(i=e.specificWeeks.length>0?$(e.specificWeeks,0,6).join(`,`):`*`),`${t} ${n} ${r} * ${i}`},pr=e=>{let t=(e||tr).trim().replace(/\s+/g,` `);return ir.find(e=>e.value===t)?.id??null},mr=e=>e.join(`、`),hr=e=>e.map(e=>`${e} 点`).join(`、`),gr=e=>{if(e.weekType===`specific`&&e.specificWeeks.length>0){let t=$(e.specificWeeks,0,6);return t.length===5&&t.every(e=>[1,2,3,4,5].includes(e))?`工作日`:t.length===2&&t.every(e=>[0,6].includes(e))?`周末`:`每${t.map(e=>nr[e]).join(`、`)}`}return e.dayType===`interval`&&e.dayInterval>1?`每隔 ${e.dayInterval} 天`:e.dayType===`specific`&&e.specificDays.length>0?`每月 ${mr($(e.specificDays,1,31))} 号`:`每天`},_r=e=>e.minuteType===`every`?`每分钟`:e.minuteType===`interval`?e.minuteInterval<=1?`每分钟`:`每 ${e.minuteInterval} 分钟`:`第 ${mr(e.specificMinutes.length>0?$(e.specificMinutes,0,59):[0])} 分钟`,vr=e=>{let t=_r(e);if(e.hourType===`every`||e.hourType===`interval`&&e.hourInterval<=1)return e.minuteType===`specific`?`每小时的${t}`:`全天${t}`;if(e.hourType===`specific`){let n=e.specificHours.length>0?$(e.specificHours,0,23):[0];return e.minuteType===`specific`?`在 ${hr(n)} 的${t}`:`在 ${hr(n)} 内${t}`}return e.minuteType===`specific`?`从 0 点开始每隔 ${e.hourInterval} 小时,在${t}`:`从 0 点开始每隔 ${e.hourInterval} 小时,该小时内${t}`},yr=e=>{let t=gr(e),n=vr(e);return`${t},${t===`每天`?n.replace(/^全天/,``):n}执行`},br=e=>yr(dr(e)),xr=e=>{if(e.minuteType===`every`)return Array.from({length:60},(e,t)=>t);if(e.minuteType===`interval`){let t=Math.max(1,e.minuteInterval);return Array.from({length:Math.ceil(60/t)},(e,n)=>n*t).filter(e=>e<=59)}return e.specificMinutes.length>0?$(e.specificMinutes,0,59):[0]},Sr=e=>{if(e.hourType===`every`)return Array.from({length:24},(e,t)=>t);if(e.hourType===`interval`){let t=Math.max(1,e.hourInterval);return Array.from({length:Math.ceil(24/t)},(e,n)=>n*t).filter(e=>e<=23)}return e.specificHours.length>0?$(e.specificHours,0,23):[0]},Cr=e=>{let t=[],n=Sr(e),r=xr(e);for(let e of n)for(let n of r)if(t.push(`${or(e)}:${or(n)}`),t.length>=6)return t;return t},wr=e=>{let t=Cr(e).join(`、`);return`${e.dayType===`every`&&e.weekType===`every`?`一天内示例`:`符合日期时,一天内示例`}:${t}`},Tr=({value:t,onChange:n,disabled:r=!1,device:i=`desktop`})=>{let[a,o]=(0,J.useState)(!1),[s,l]=(0,J.useState)(`quick`),[u,d]=(0,J.useState)(pr(t)),[f,p]=(0,J.useState)(`interval`),[m,h]=(0,J.useState)(10),[g,_]=(0,J.useState)([]),[v,y]=(0,J.useState)(`every`),[b,x]=(0,J.useState)(1),[S,C]=(0,J.useState)([]),[w,T]=(0,J.useState)(`every`),[E,D]=(0,J.useState)(1),[O,k]=(0,J.useState)([]),[A,j]=(0,J.useState)(`every`),[M,N]=(0,J.useState)([]),ee=e=>{p(e.minuteType),h(e.minuteInterval),_(e.specificMinutes),y(e.hourType),x(e.hourInterval),C(e.specificHours),T(e.dayType),D(e.dayInterval),k(e.specificDays),j(e.weekType),N(e.specificWeeks)},P=()=>({minuteType:f,minuteInterval:m,specificMinutes:g,hourType:v,hourInterval:b,specificHours:S,dayType:w,dayInterval:E,specificDays:O,weekType:A,specificWeeks:M});(0,J.useEffect)(()=>{if(!a)return;let e=dr(t||tr);ee(e),d(pr(fr(e))),l(`quick`)},[t,a]);let F=()=>fr(P()),I=()=>yr(P()),L=()=>wr(P()),te=()=>xr({...P(),minuteType:`interval`,minuteInterval:m}).slice(0,5).join(`、`),R=()=>Sr({...P(),hourType:`interval`,hourInterval:b}).slice(0,5).map(e=>`${e} 点`).join(`、`),z=()=>{n(F()),o(!1)},ne=e=>{let t=dr(e.value);ee(t),d(e.id)},ie=e=>{if(e===null||Array.isArray(e))return;let t=ir.find(t=>t.id===String(e));t&&ne(t)},ae=e=>{d(null),p(e)},oe=e=>{d(null),y(e)},se=e=>{d(null),T(e),e!==`every`&&(j(`every`),N([]))},ce=e=>{d(null),j(e),e!==`every`&&(T(`every`),D(1),k([]))},le=()=>(0,X.jsxs)(`div`,{className:`min-w-0 space-y-4 overflow-x-hidden`,children:[(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsxs)(`div`,{className:`mb-3 flex min-w-0 flex-col gap-1`,children:[(0,X.jsx)(W,{className:`block text-base font-semibold`,children:`常用规则`}),(0,X.jsx)(K,{className:`block leading-relaxed`,children:`不用理解 Cron,直接选一个最接近的执行时间,再看下方预览确认。`})]}),(0,X.jsxs)(pe,{fullWidth:!0,variant:`secondary`,placeholder:`选择常用执行规则`,value:u??``,onChange:ie,children:[(0,X.jsx)(W,{children:`执行规则`}),(0,X.jsxs)(pe.Trigger,{children:[(0,X.jsx)(pe.Value,{}),(0,X.jsx)(pe.Indicator,{})]}),(0,X.jsx)(pe.Popover,{children:(0,X.jsx)(re,{children:rr.map((t,n)=>(0,X.jsxs)(J.Fragment,{children:[n>0?(0,X.jsx)(e,{}):null,(0,X.jsxs)(re.Section,{children:[(0,X.jsx)(Hn,{children:t.title}),t.presets.map(e=>(0,X.jsxs)(re.Item,{id:e.id,textValue:e.label,children:[(0,X.jsxs)(`div`,{className:`flex min-w-0 flex-col gap-1`,children:[(0,X.jsx)(W,{children:e.label}),(0,X.jsx)(K,{children:e.description})]}),(0,X.jsx)(re.ItemIndicator,{})]},e.id))]})]},t.title))})})]})]}),(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(`div`,{className:`flex flex-row justify-between items-center`,children:[(0,X.jsx)(W,{className:`text-base font-semibold`,children:`需要更细的规则?`}),(0,X.jsx)(c,{size:`sm`,variant:`secondary`,onPress:()=>l(`minute`),children:`转到高级`})]})})]}),de=()=>(0,X.jsxs)(`div`,{className:`space-y-4`,children:[(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(Qn,{"aria-label":`分钟类型`,variant:`secondary`,value:f,onChange:e=>ae(e),children:[(0,X.jsx)(W,{className:`text-base font-semibold`,children:`每个小时里,哪些分钟执行?`}),(0,X.jsx)(K,{className:`mb-3`,children:`例如选“每 10 分钟”,就是 00、10、20、30、40、50 分执行。`}),(0,X.jsxs)(`div`,{className:`space-y-3`,children:[(0,X.jsxs)(Q,{value:`every`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`每分钟`]}),(0,X.jsx)(K,{children:`该小时里的每一分钟都执行,频率最高。`})]}),(0,X.jsxs)(Q,{value:`interval`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`间隔执行`]}),(0,X.jsx)(K,{children:`从第 0 分钟开始,按固定分钟数重复。`})]}),(0,X.jsxs)(Q,{value:`specific`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`指定分钟`]}),(0,X.jsx)(K,{children:`只在你点选的分钟执行,适合“整点”或“半点”。`})]})]})]})}),f===`interval`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`间隔设置`}),(0,X.jsxs)(Z,{variant:`secondary`,minValue:1,maxValue:59,value:m,onChange:e=>{d(null),h(sr(e,1,59,10))},children:[(0,X.jsx)(W,{children:`间隔(分钟)`}),(0,X.jsxs)(Z.Group,{children:[(0,X.jsx)(Z.DecrementButton,{}),(0,X.jsx)(Z.Input,{className:`w-24`}),(0,X.jsx)(Z.IncrementButton,{})]}),(0,X.jsx)(K,{children:m<=1?`等价于每分钟执行。`:`每个小时的 ${te()} 分执行。`})]})]}),f===`specific`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsxs)(`div`,{className:`flex flex-col`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`选择分钟`}),(0,X.jsx)(K,{className:`mb-3`,children:`点击选择要执行的分钟数,可多选。选 0 就是整点执行。`})]}),(0,X.jsx)(`div`,{className:`grid max-h-80 grid-cols-5 gap-2 overflow-y-auto p-1 md:grid-cols-10`,children:Array.from({length:60},(e,t)=>t).map(e=>(0,X.jsx)(c,{className:`aspect-square min-w-0 shrink-0 p-0`,size:`sm`,variant:g.includes(e)?`primary`:`secondary`,onPress:()=>{d(null),_(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e].sort((e,t)=>e-t))},children:e},e))}),g.length>0&&(0,X.jsxs)(K,{className:`mt-2`,children:[`已选择 `,g.length,` 个:`,g.join(`, `)]})]})]}),fe=()=>(0,X.jsxs)(`div`,{className:`space-y-4`,children:[(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(Qn,{"aria-label":`小时类型`,variant:`secondary`,value:v,onChange:e=>oe(e),children:[(0,X.jsx)(W,{className:`text-base font-semibold`,children:`一天里,哪些小时允许执行?`}),(0,X.jsx)(K,{className:`mb-3`,children:`如果选择“全部小时”,分钟页的规则会全天生效。`}),(0,X.jsxs)(`div`,{className:`space-y-3`,children:[(0,X.jsxs)(Q,{value:`every`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`全部小时`]}),(0,X.jsx)(K,{children:`不限制小时。例如分钟为每 10 分钟时,就是全天每 10 分钟。`})]}),(0,X.jsxs)(Q,{value:`interval`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`间隔执行`]}),(0,X.jsx)(K,{children:`从 0 点开始,每隔几个小时开放一次执行时段。`})]}),(0,X.jsxs)(Q,{value:`specific`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`指定小时`]}),(0,X.jsx)(K,{children:`只在你点选的小时内执行。`})]})]})]})}),v===`interval`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`间隔设置`}),(0,X.jsxs)(Z,{variant:`secondary`,minValue:1,maxValue:23,value:b,onChange:e=>{d(null),x(sr(e,1,23,1))},children:[(0,X.jsx)(W,{children:`间隔(小时)`}),(0,X.jsxs)(Z.Group,{children:[(0,X.jsx)(Z.DecrementButton,{}),(0,X.jsx)(Z.Input,{className:`w-24`}),(0,X.jsx)(Z.IncrementButton,{})]}),(0,X.jsx)(K,{children:b<=1?`间隔 1 小时等价于全部小时,保存时会自动写成 *。`:`只在 ${R()} 这些小时内执行。`})]})]}),v===`specific`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsxs)(`div`,{className:`flex flex-col`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`选择小时`}),(0,X.jsx)(K,{className:`mb-3`,children:`点击选择允许执行的小时,可多选。具体分钟仍由“分钟”页决定。`})]}),(0,X.jsx)(`div`,{className:`grid max-h-80 grid-cols-4 gap-2 overflow-y-auto p-1 md:grid-cols-6`,children:Array.from({length:24},(e,t)=>t).map(e=>(0,X.jsx)(c,{className:`aspect-square min-w-0 shrink-0 p-0`,size:`sm`,variant:S.includes(e)?`primary`:`secondary`,onPress:()=>{d(null),C(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e].sort((e,t)=>e-t))},children:e},e))}),S.length>0&&(0,X.jsxs)(K,{className:`mt-2`,children:[`已选择 `,S.length,` 个:`,S.map(e=>`${e}点`).join(`, `)]})]})]}),me=()=>(0,X.jsxs)(`div`,{className:`space-y-4`,children:[(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(Qn,{"aria-label":`日期类型`,variant:`secondary`,value:w,onChange:e=>se(e),children:[(0,X.jsx)(W,{className:`text-base font-semibold`,children:`一个月里,哪些日期允许执行?`}),(0,X.jsx)(K,{className:`mb-3`,children:`日期和星期只保留一个条件。选择日期后,会自动清空星期条件。`}),(0,X.jsxs)(`div`,{className:`space-y-3`,children:[(0,X.jsxs)(Q,{value:`every`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`全部日期`]}),(0,X.jsx)(K,{children:`不限制几号执行。`})]}),(0,X.jsxs)(Q,{value:`interval`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`间隔执行`]}),(0,X.jsx)(K,{children:`从每月 1 号开始,每隔几天开放一次执行日期。`})]}),(0,X.jsxs)(Q,{value:`specific`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`指定日期`]}),(0,X.jsx)(K,{children:`只在你点选的几号执行。`})]})]})]})}),w===`interval`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`间隔设置`}),(0,X.jsxs)(Z,{variant:`secondary`,minValue:1,maxValue:31,value:E,onChange:e=>{d(null),D(sr(e,1,31,1)),j(`every`),N([])},children:[(0,X.jsx)(W,{children:`间隔(天)`}),(0,X.jsxs)(Z.Group,{children:[(0,X.jsx)(Z.DecrementButton,{}),(0,X.jsx)(Z.Input,{className:`w-24`}),(0,X.jsx)(Z.IncrementButton,{})]}),(0,X.jsx)(K,{children:E<=1?`间隔 1 天等价于全部日期,保存时会自动写成 *。`:`每月从 1 号开始,每隔 ${E} 天执行。`})]})]}),w===`specific`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsxs)(`div`,{className:`flex flex-col`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`选择日期`}),(0,X.jsx)(K,{className:`mb-3`,children:`点击选择允许执行的日期,可多选。月份没有这一天时会自动跳过。`})]}),(0,X.jsx)(`div`,{className:`grid max-h-80 grid-cols-5 gap-2 overflow-y-auto p-1 md:grid-cols-7`,children:Array.from({length:31},(e,t)=>t+1).map(e=>(0,X.jsx)(c,{className:`aspect-square min-w-0 shrink-0 p-0`,size:`sm`,variant:O.includes(e)?`primary`:`secondary`,onPress:()=>{d(null),j(`every`),N([]),k(t=>t.includes(e)?t.filter(t=>t!==e):[...t,e].sort((e,t)=>e-t))},children:e},e))}),O.length>0&&(0,X.jsxs)(K,{className:`mt-2`,children:[`已选择 `,O.length,` 个:`,O.map(e=>`${e}号`).join(`, `)]})]})]}),he=()=>(0,X.jsxs)(`div`,{className:`space-y-4`,children:[(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(Qn,{"aria-label":`星期类型`,variant:`secondary`,value:A,onChange:e=>ce(e),children:[(0,X.jsx)(W,{className:`text-base font-semibold`,children:`一周里,哪些星期允许执行?`}),(0,X.jsx)(K,{className:`mb-3`,children:`日期和星期只保留一个条件。选择星期后,会自动清空日期条件。`}),(0,X.jsxs)(`div`,{className:`space-y-3`,children:[(0,X.jsxs)(Q,{value:`every`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`全部星期`]}),(0,X.jsx)(K,{children:`不限制星期几执行。`})]}),(0,X.jsxs)(Q,{value:`specific`,children:[(0,X.jsxs)(Q.Content,{children:[(0,X.jsx)(Q.Control,{children:(0,X.jsx)(Q.Indicator,{})}),`指定星期`]}),(0,X.jsx)(K,{children:`只在你点选的星期执行。`})]})]})]})}),A===`specific`&&(0,X.jsxs)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:[(0,X.jsxs)(`div`,{className:`flex flex-col`,children:[(0,X.jsx)(W,{className:`mb-2 text-base font-semibold`,children:`选择星期`}),(0,X.jsx)(K,{className:`mb-3`,children:`点击选择允许执行的星期,可多选。具体时间仍由分钟和小时页决定。`})]}),(0,X.jsx)(`div`,{className:`grid grid-cols-7 gap-2 p-1`,children:[`日`,`一`,`二`,`三`,`四`,`五`,`六`].map((e,t)=>(0,X.jsx)(c,{className:`aspect-square min-w-0 shrink-0 p-0`,size:`sm`,variant:M.includes(t)?`primary`:`secondary`,onPress:()=>{d(null),T(`every`),D(1),k([]),N(e=>e.includes(t)?e.filter(e=>e!==t):[...e,t].sort((e,t)=>e-t))},children:e},t))}),M.length>0&&(0,X.jsxs)(K,{className:`mt-2`,children:[`已选择 `,M.length,` 天:`,M.map(e=>`周${`日一二三四五六`[e]}`).join(`, `)]})]})]}),ge=i===`desktop`?`right`:`bottom`,V=br(t||tr);return(0,X.jsxs)(`div`,{className:`space-y-2`,children:[(0,X.jsxs)(`div`,{className:`flex gap-2 flex-col`,children:[(0,X.jsxs)(`div`,{className:`flex gap-2`,children:[(0,X.jsxs)(ue,{fullWidth:!0,isDisabled:!0,value:t,children:[(0,X.jsx)(W,{className:`sr-only`,children:`定时推送时间`}),(0,X.jsx)(Ne,{placeholder:`*/10 * * * *`,variant:`secondary`,"aria-label":`定时任务表达式`})]}),(0,X.jsxs)(c,{isDisabled:r,variant:`secondary`,onPress:()=>o(!0),children:[(0,X.jsx)(er,{className:`size-4`,"aria-hidden":`true`}),(0,X.jsx)(`span`,{children:`编辑`})]})]}),(0,X.jsxs)(K,{children:[`当前规则:`,V]})]}),(0,X.jsx)(B.Backdrop,{isOpen:a,variant:`blur`,onOpenChange:o,children:(0,X.jsx)(B.Content,{placement:ge,children:(0,X.jsxs)(B.Dialog,{className:i===`desktop`?`h-full w-120 max-w-[90vw]`:`max-h-[85dvh]`,children:[(0,X.jsx)(B.Handle,{}),(0,X.jsx)(B.CloseTrigger,{}),(0,X.jsxs)(B.Header,{children:[(0,X.jsx)(B.Heading,{children:`定时推送时间`}),(0,X.jsx)(K,{children:`先选常用规则;需要精细控制时,再进入分钟、小时、日期、星期设置。`})]}),(0,X.jsxs)(B.Body,{className:`min-w-0 space-y-4 overflow-x-hidden`,children:[(0,X.jsxs)(U,{className:`min-w-0`,selectedKey:s,onSelectionChange:e=>l(e),children:[(0,X.jsx)(U.ListContainer,{children:(0,X.jsxs)(U.List,{children:[(0,X.jsxs)(U.Tab,{id:`quick`,children:[(0,X.jsx)(`span`,{children:`常用`}),(0,X.jsx)(U.Indicator,{})]}),(0,X.jsxs)(U.Tab,{id:`minute`,children:[(0,X.jsx)(`span`,{children:`分钟`}),(0,X.jsx)(U.Indicator,{})]}),(0,X.jsxs)(U.Tab,{id:`hour`,children:[(0,X.jsx)(`span`,{children:`小时`}),(0,X.jsx)(U.Indicator,{})]}),(0,X.jsxs)(U.Tab,{id:`day`,children:[(0,X.jsx)(`span`,{children:`日期`}),(0,X.jsx)(U.Indicator,{})]}),(0,X.jsxs)(U.Tab,{id:`week`,children:[(0,X.jsx)(`span`,{children:`星期`}),(0,X.jsx)(U.Indicator,{})]})]})}),(0,X.jsx)(`div`,{className:`h-1`}),(0,X.jsx)(U.Panel,{id:`quick`,className:`p-0`,children:le()}),(0,X.jsx)(U.Panel,{id:`minute`,className:`p-0`,children:de()}),(0,X.jsx)(U.Panel,{id:`hour`,className:`p-0`,children:fe()}),(0,X.jsx)(U.Panel,{id:`day`,className:`p-0`,children:me()}),(0,X.jsx)(U.Panel,{id:`week`,className:`p-0`,children:he()})]}),(0,X.jsx)(H,{className:`p-4 rounded-3xl`,variant:`secondary`,children:(0,X.jsxs)(`div`,{className:`space-y-3`,children:[(0,X.jsxs)(`div`,{children:[(0,X.jsx)(W,{className:`text-sm font-medium text-muted`,children:`实际执行时间`}),(0,X.jsx)(`p`,{className:`mt-1 text-sm leading-relaxed`,children:I()}),(0,X.jsx)(K,{className:`mt-1`,children:L()})]}),(0,X.jsxs)(`div`,{children:[(0,X.jsx)(W,{className:`text-sm font-medium text-muted`,children:`表达式`}),(0,X.jsx)(`code`,{className:`mt-1 block font-mono text-base font-semibold`,children:F()})]})]})})]}),(0,X.jsxs)(B.Footer,{children:[(0,X.jsx)(c,{className:`flex-1`,slot:`close`,variant:`tertiary`,children:`取消`}),(0,X.jsx)(c,{className:`flex-1`,variant:`primary`,onPress:z,children:`使用这个规则`})]})]})})})]})};export{Tr as default};
@@ -1 +0,0 @@
1
- import{t as e}from"./separator-CCrVXPvv.js";import{a as t,c as n,i as r,l as i,n as a,o,r as s,s as c,t as l}from"./ThemeSwitch-Cipx1aP1.js";import{D as u,Ht as d,O as f,St as p,Ut as m,a as h,c as g,g as _,i as v,l as y,n as b,o as x,s as S,u as C,yt as w}from"./index-RFCFN09q.js";var T={name:`panel-left-close`,size:24,node:[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M9 3v18`,key:`fh3hqa`}],[`path`,{d:`m16 15-3-3 3-3`,key:`14y99z`}]],aliases:[`sidebar-close`]};T.node;var E=x(T),D=m(d(),1),O=p(),k=({activeMenu:e})=>{let t=(0,D.useRef)(null);return(0,D.useEffect)(()=>{t.current&&S.fromTo(t.current,{autoAlpha:0},{autoAlpha:1,duration:h(.2),ease:`power2.out`,overwrite:`auto`})},[e]),(0,O.jsx)(`div`,{ref:t,className:`mx-auto w-full max-w-7xl px-4`,children:(()=>{switch(e){case`config`:return(0,O.jsx)(v,{device:`desktop`});case`about`:return(0,O.jsx)(s,{});default:return(0,O.jsx)(v,{device:`desktop`})}})()})},A=[{id:`config`,label:`配置管理`,icon:r},{id:`about`,label:`关于插件`,icon:n}],j=({collapsed:t,activeMenu:n,onMenuChange:r})=>{let o=C(()=>{window.open(`https://kkk.karinjs.com`,`_blank`,`noopener,noreferrer`)}),s=C(()=>{g(),window.location.reload()});return t?null:(0,O.jsxs)(`div`,{className:`flex h-full flex-col`,children:[(0,O.jsx)(`div`,{className:`shrink-0 px-4 pt-3 pb-2`,children:(0,O.jsxs)(_,{children:[(0,O.jsx)(_.Trigger,{"aria-label":`用户信息`,children:(0,O.jsxs)(`div`,{className:`flex w-full items-center gap-3 rounded-lg p-2 transition-colors hover:bg-default-100 cursor-pointer`,tabIndex:0,children:[(0,O.jsxs)(f,{size:`lg`,children:[(0,O.jsx)(f.Image,{src:a}),(0,O.jsx)(f.Fallback,{children:`ikenxuan`})]}),(0,O.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col items-start`,children:[(0,O.jsx)(`p`,{className:`truncate text-lg font-semibold`,children:`炫炫`}),(0,O.jsx)(`p`,{className:`truncate text-md text-muted`,children:`Super Admin`})]})]})}),(0,O.jsx)(_.Content,{className:`w-60`,children:(0,O.jsxs)(_.Dialog,{children:[(0,O.jsxs)(`div`,{className:`flex items-center gap-3 pb-3`,children:[(0,O.jsxs)(f,{size:`md`,children:[(0,O.jsx)(f.Image,{src:a}),(0,O.jsx)(f.Fallback,{children:`U`})]}),(0,O.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,O.jsx)(`p`,{className:`truncate font-medium`,children:`用户`}),(0,O.jsx)(`p`,{className:`truncate text-md text-muted`,children:`Super Admin`})]})]}),(0,O.jsx)(e,{className:`my-2`}),(0,O.jsx)(`p`,{className:`text-xs text-muted`,children:`当前身份:管理员`})]})})]})}),(0,O.jsx)(`nav`,{className:`flex flex-1 flex-col gap-1 overflow-y-auto px-3 py-3`,"aria-label":`主导航`,children:A.map(e=>{let t=e.icon,i=n===e.id;return(0,O.jsxs)(u,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:i?`tertiary`:`ghost`,"aria-label":e.label,"aria-current":i?`page`:void 0,onPress:()=>r(e.id),children:[(0,O.jsx)(t,{size:20,className:w(`shrink-0 mr-3`,!i&&`text-muted`),"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:w(`truncate`,i&&`font-medium`),children:e.label})]},e.id)})}),(0,O.jsxs)(`div`,{className:`flex shrink-0 flex-col gap-1 px-3 py-3`,children:[(0,O.jsxs)(u,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:`ghost`,"aria-label":`查看帮助文档`,onPress:o,children:[(0,O.jsx)(i,{size:20,className:`shrink-0 mr-3 text-muted`,"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:`truncate`,children:`帮助文档`})]}),(0,O.jsxs)(u,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:`ghost`,"aria-label":`登出`,onPress:s,children:[(0,O.jsx)(c,{size:20,className:`shrink-0 mr-3 text-muted`,"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:`truncate`,children:`登出`})]})]})]})},M=({onToggleSidebar:e,sidebarCollapsed:n,currentMenuLabel:r})=>(0,O.jsxs)(`div`,{className:`flex w-full items-center justify-between`,children:[(0,O.jsxs)(`div`,{className:`flex min-w-0 items-center gap-3`,children:[(0,O.jsx)(u,{isIconOnly:!0,variant:`ghost`,onPress:e,"aria-label":n?`展开侧边栏`:`折叠侧边栏`,"aria-expanded":!n,children:n?(0,O.jsx)(o,{size:20,"aria-hidden":`true`}):(0,O.jsx)(E,{size:20,"aria-hidden":`true`})}),n&&(0,O.jsxs)(O.Fragment,{children:[(0,O.jsx)(t,{size:24,"aria-hidden":`true`}),(0,O.jsx)(`h1`,{className:`truncate text-lg font-semibold`,children:`KKK Config`})]}),!n&&(0,O.jsx)(`h1`,{className:`truncate text-lg font-semibold`,children:r||`配置管理面板`})]}),(0,O.jsx)(l,{})]}),N=[{id:`config`,label:`配置管理`,icon:r},{id:`about`,label:`关于插件`,icon:n}],P=({activeMenu:e,onMenuChange:t})=>{let[n,{toggle:r}]=y(!1),i=(0,D.useRef)(null),a=(0,D.useRef)(null),o=(0,D.useRef)(null);return(0,D.useEffect)(()=>(o.current=b(a),()=>{o.current?.destroy(),o.current=null}),[]),(0,D.useEffect)(()=>{o.current?.scrollTo(0)},[e]),(0,D.useEffect)(()=>{i.current&&(n?S.to(i.current,{width:0,opacity:0,borderRightWidth:0,duration:.3,ease:`power2.inOut`,onComplete:()=>{i.current&&(i.current.style.display=`none`)}}):(i.current.style.display=`flex`,S.fromTo(i.current,{width:0,opacity:0,borderRightWidth:0},{width:260,opacity:1,borderRightWidth:1,duration:.3,ease:`power2.inOut`})))},[n]),(0,O.jsxs)(`div`,{className:`flex h-screen overflow-hidden`,children:[(0,O.jsx)(`aside`,{ref:i,className:`flex h-full w-65 shrink-0 flex-col border-r border-default-100`,"aria-label":`侧边栏导航`,children:(0,O.jsx)(j,{collapsed:n,activeMenu:e,onMenuChange:t,onToggleCollapse:r})}),(0,O.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col overflow-hidden`,children:[(0,O.jsx)(`header`,{className:`flex h-16 shrink-0 items-center px-6`,children:(0,O.jsx)(M,{onToggleSidebar:r,sidebarCollapsed:n,currentMenuLabel:N.find(t=>t.id===e)?.label})}),(0,O.jsx)(`main`,{ref:a,className:`scrollbar flex-1 overflow-y-auto p-6`,id:`main-content`,children:(0,O.jsx)(`div`,{"data-scrollbar":`thin`,children:(0,O.jsx)(k,{activeMenu:e})})})]})]})};export{P as default};
@@ -1 +0,0 @@
1
- import{a as e,c as t,i as n,l as r,n as i,o as a,r as o,s,t as c}from"./ThemeSwitch-Cipx1aP1.js";import{D as l,Ht as u,O as d,St as f,Ut as p,a as m,b as h,c as g,i as _,l as v,m as y,o as b,s as x,t as S,u as C,yt as w}from"./index-RFCFN09q.js";var T={name:`x`,size:24,node:[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]};T.node;var E=b(T),D=p(u(),1),O=f(),k=({activeMenu:e})=>{let t=(0,D.useRef)(null);return(0,D.useEffect)(()=>{t.current&&x.fromTo(t.current,{autoAlpha:0},{autoAlpha:1,duration:m(.2),ease:`power2.out`,overwrite:`auto`})},[e]),(0,O.jsx)(`div`,{ref:t,className:`w-full max-w-2xl mx-auto`,children:(()=>{switch(e){case`config`:return(0,O.jsx)(_,{device:`mobile`});case`about`:return(0,O.jsx)(o,{});default:return(0,O.jsx)(_,{device:`mobile`})}})()})},A=[{id:`config`,label:`配置管理`,icon:n},{id:`about`,label:`关于插件`,icon:t}],j=({open:e,onClose:t,activeMenu:n,onMenuChange:a})=>{let o=C(()=>{window.open(`https://kkk.karinjs.com`,`_blank`,`noopener,noreferrer`)}),c=C(()=>{g(),window.location.reload()});return(0,D.useEffect)(()=>{let n=n=>{n.key===`Escape`&&e&&t()};return window.addEventListener(`keydown`,n),()=>window.removeEventListener(`keydown`,n)},[e,t]),(0,D.useEffect)(()=>(e?document.body.style.overflow=`hidden`:document.body.style.overflow=``,()=>{document.body.style.overflow=``}),[e]),(0,O.jsx)(h.Backdrop,{isOpen:e,isDismissable:!0,className:`backdrop-blur-sm`,onOpenChange:e=>{e||t()},children:(0,O.jsx)(h.Content,{placement:`right`,children:(0,O.jsxs)(h.Dialog,{className:`px-4`,children:[(0,O.jsxs)(h.Header,{className:`flex items-center justify-between pb-4`,children:[(0,O.jsx)(h.Heading,{className:`text-lg font-semibold`,children:`菜单`}),(0,O.jsx)(h.CloseTrigger,{"aria-label":`关闭菜单`,className:`mr-2`,children:(0,O.jsx)(E,{size:24,"aria-hidden":`true`})})]}),(0,O.jsxs)(h.Body,{className:`flex flex-col`,children:[(0,O.jsx)(`div`,{className:`shrink-0 pb-5`,children:(0,O.jsxs)(`div`,{className:`flex items-center gap-3 px-1`,children:[(0,O.jsxs)(d,{size:`md`,children:[(0,O.jsx)(d.Image,{src:i}),(0,O.jsx)(d.Fallback,{children:`ikenxuan`})]}),(0,O.jsxs)(`div`,{className:`flex min-w-0 flex-1 flex-col`,children:[(0,O.jsx)(`p`,{className:`truncate text-sm font-medium`,children:`炫炫`}),(0,O.jsx)(`p`,{className:`truncate text-xs text-muted`,children:`Super Admin`})]})]})}),(0,O.jsx)(`nav`,{className:`flex flex-1 flex-col gap-2 overflow-y-auto`,"aria-label":`主导航`,children:A.map(e=>{let t=e.icon,r=n===e.id;return(0,O.jsxs)(l,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:r?`tertiary`:`ghost`,"aria-label":e.label,"aria-current":r?`page`:void 0,onPress:()=>a(e.id),children:[(0,O.jsx)(t,{size:20,className:w(`shrink-0 mr-3`,!r&&`text-muted`),"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:w(`truncate`,r&&`font-semibold`),children:e.label})]},e.id)})}),(0,O.jsxs)(`div`,{className:`flex shrink-0 flex-col gap-2`,children:[(0,O.jsxs)(l,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:`ghost`,"aria-label":`查看帮助文档`,onPress:o,children:[(0,O.jsx)(r,{size:20,className:`shrink-0 mr-3 text-muted`,"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:`truncate`,children:`帮助文档`})]}),(0,O.jsxs)(l,{fullWidth:!0,className:`justify-start`,size:`lg`,variant:`ghost`,"aria-label":`登出`,onPress:c,children:[(0,O.jsx)(s,{size:20,className:`shrink-0 mr-3 text-muted`,"aria-hidden":`true`}),(0,O.jsx)(`span`,{className:`truncate`,children:`登出`})]})]})]})]})})})},M=({onOpenDrawer:t})=>(0,O.jsxs)(`div`,{className:`flex h-full items-center justify-between px-4`,children:[(0,O.jsx)(c,{className:`shrink-0`}),(0,O.jsxs)(`div`,{className:`flex min-w-0 flex-1 items-center justify-center gap-2 px-2`,children:[(0,O.jsx)(e,{size:22,"aria-hidden":`true`}),(0,O.jsx)(`h1`,{className:`truncate text-base font-semibold`,children:`KKK Config`})]}),(0,O.jsx)(l,{isIconOnly:!0,className:`shrink-0`,variant:`ghost`,onPress:t,"aria-label":`打开菜单`,"aria-expanded":!1,children:(0,O.jsx)(a,{size:24,"aria-hidden":`true`})})]}),N=({activeMenu:e,onMenuChange:t})=>{let[n,{setTrue:r,setFalse:i}]=v(!1),a=(0,D.useRef)(null),o=(0,D.useRef)(null);(0,D.useEffect)(()=>(o.current=S(a),()=>{o.current?.destroy(),o.current=null}),[]),(0,D.useEffect)(()=>{o.current?.scrollTo(0)},[e]);let s=C(e=>{t(e),i()});return(0,O.jsxs)(y,{ref:a,"data-scrollbar":`thin`,className:`flex min-h-screen flex-col`,children:[(0,O.jsx)(`header`,{className:`sticky top-0 z-50 h-14 shrink-0 backdrop-blur-xs mask-[linear-gradient(to_bottom,black_40%,transparent_100%)]`,children:(0,O.jsx)(M,{onOpenDrawer:r})}),(0,O.jsx)(j,{open:n,onClose:i,activeMenu:e,onMenuChange:s}),(0,O.jsx)(`main`,{className:`scrollbar flex-1 overflow-y-auto p-4`,id:`main-content`,children:(0,O.jsx)(k,{activeMenu:e})})]})};export{N as default};
@@ -1 +0,0 @@
1
- import{D as e,E as t,St as n,d as r,o as i,r as a,x as o}from"./index-RFCFN09q.js";var s={name:`circle-question-mark`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3`,key:`1u773s`}],[`path`,{d:`M12 17h.01`,key:`p32p05`}]],aliases:[`help-circle`,`circle-help`]};s.node;var c=i(s),l={name:`external-link`,size:24,node:[[`path`,{d:`M15 3h6v6`,key:`1q9fwt`}],[`path`,{d:`M10 14 21 3`,key:`gplh6r`}],[`path`,{d:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6`,key:`a6xqqp`}]]};l.node;var u=i(l),d={name:`file-text`,size:24,node:[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 9H8`,key:`b1mrlr`}],[`path`,{d:`M16 13H8`,key:`t4e002`}],[`path`,{d:`M16 17H8`,key:`z1uh3a`}]]};d.node;var f=i(d),p={name:`log-out`,size:24,node:[[`path`,{d:`m16 17 5-5-5-5`,key:`1bji2h`}],[`path`,{d:`M21 12H9`,key:`dn1m92`}],[`path`,{d:`M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4`,key:`1uf3rs`}]]};p.node;var m=i(p),h={name:`menu`,size:24,node:[[`path`,{d:`M4 5h16`,key:`1tepv9`}],[`path`,{d:`M4 12h16`,key:`1lakjw`}],[`path`,{d:`M4 19h16`,key:`1djgab`}]]};h.node;var g=i(h),_={name:`moon`,size:24,node:[[`path`,{d:`M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401`,key:`kfwtm`}]]};_.node;var v=i(_),y={name:`package`,size:24,node:[[`path`,{d:`M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z`,key:`1a0edw`}],[`path`,{d:`M12 22V12`,key:`d0xqtd`}],[`polyline`,{points:`3.29 7 12 12 20.71 7`,key:`ousv84`}],[`path`,{d:`m7.5 4.27 9 5.15`,key:`1c824w`}]]};y.node;var b=i(y),x={name:`settings`,size:24,node:[[`path`,{d:`M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915`,key:`1i5ecw`}],[`circle`,{cx:`12`,cy:`12`,r:`3`,key:`1v7zrd`}]]};x.node;var S=i(x),C={name:`sun`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`4`,key:`4exip2`}],[`path`,{d:`M12 2v2`,key:`tus03m`}],[`path`,{d:`M12 20v2`,key:`1lh1kg`}],[`path`,{d:`m4.93 4.93 1.41 1.41`,key:`149t6j`}],[`path`,{d:`m17.66 17.66 1.41 1.41`,key:`ptbguv`}],[`path`,{d:`M2 12h2`,key:`1t8f8n`}],[`path`,{d:`M20 12h2`,key:`1q8mjw`}],[`path`,{d:`m6.34 17.66-1.41 1.41`,key:`1m8zz5`}],[`path`,{d:`m19.07 4.93-1.41 1.41`,key:`1shlcs`}]]};C.node;var w=i(C),T=n(),E=()=>{let n=e=>{window.open(e,`_blank`)};return(0,T.jsxs)(t,{className:`mx-auto max-w-3xl`,children:[(0,T.jsxs)(t.Header,{className:`items-center text-center gap-4 pt-8 pb-6`,children:[(0,T.jsx)(b,{size:64,"aria-hidden":`true`}),(0,T.jsx)(t.Title,{children:`karin-plugin-kkk`}),(0,T.jsx)(t.Description,{children:`版本 2.33.0`})]}),(0,T.jsxs)(t.Content,{className:`flex flex-col gap-6 pb-8`,children:[(0,T.jsxs)(`section`,{children:[(0,T.jsx)(`h3`,{className:`mb-3 text-base font-semibold`,children:`插件简介`}),(0,T.jsx)(o,{children:`Karin 的「抖音」「B站」视频解析/动态推送插件。 支持视频解析、动态推送、扫码登录等功能。`})]}),(0,T.jsxs)(`section`,{children:[(0,T.jsx)(`h3`,{className:`mb-3 text-base font-semibold`,children:`开发者`}),(0,T.jsx)(o,{children:`ikenxuan, sj817`})]}),(0,T.jsxs)(`section`,{children:[(0,T.jsx)(`h3`,{className:`mb-3 text-base font-semibold`,children:`相关链接`}),(0,T.jsxs)(`div`,{className:`mt-3 flex flex-wrap gap-3`,children:[(0,T.jsxs)(e,{variant:`outline`,onPress:()=>n(`https://github.com/ikenxuan/karin-plugin-kkk`),children:[(0,T.jsx)(u,{size:18,"aria-hidden":`true`}),(0,T.jsx)(`span`,{children:`GitHub 仓库`})]}),(0,T.jsxs)(e,{variant:`outline`,onPress:()=>n(`https://github.com/ikenxuan/karin-plugin-kkk/issues`),children:[(0,T.jsx)(u,{size:18,"aria-hidden":`true`}),(0,T.jsx)(`span`,{children:`反馈问题`})]})]})]})]})]})},D=`https://github.com/ikenxuan.png`,O=({className:t})=>{let{isDark:n,toggleTheme:i}=a();return(0,T.jsxs)(r,{delay:1,closeDelay:1,children:[(0,T.jsx)(e,{isIconOnly:!0,"aria-label":n?`切换到浅色模式`:`切换到深色模式`,className:t,variant:`ghost`,onPress:i,children:n?(0,T.jsx)(w,{size:20,"aria-hidden":`true`}):(0,T.jsx)(v,{size:20,"aria-hidden":`true`})}),(0,T.jsx)(r.Content,{children:n?`浅色模式`:`深色模式`})]})};export{b as a,f as c,S as i,c as l,D as n,g as o,E as r,m as s,O as t};