2 lines
77 KiB
JavaScript
2 lines
77 KiB
JavaScript
import{r as f,a as Jr,j as r}from"./router-zNjPR4CY.js";import{x as te,E as Kr,D as Zr,i as ea,g as B,j as ta,k as sa,l as ra,T as js,O as ws,P as ge,I as Ns,B as I,S as aa,ae as dt}from"./index-CuOHsLf7.js";import{B as pe}from"./badge-CDs67obV.js";import{C as _s}from"./checkbox-DWiVrbnx.js";import{S as na,a as ia,b as ca,c as oa,d as ut}from"./select-DGqIoF9r.js";import{P as la,a as da,b as Tt,c as ua,d as ha}from"./pagination-DX-kWu7G.js";import{ax as fa,_ as ma,X as xa,ad as It,e as M,f as X,S as ks,R as qe,W as ga,G as pa,y as va,av as ya,a1 as zt,d as ba}from"./icons-DTcdLw9j.js";var Kt=rt(),N=e=>st(e,Kt),Zt=rt();N.write=e=>st(e,Zt);var yt=rt();N.onStart=e=>st(e,yt);var es=rt();N.onFrame=e=>st(e,es);var ts=rt();N.onFinish=e=>st(e,ts);var ze=[];N.setTimeout=(e,t)=>{const s=N.now()+t,a=()=>{const c=ze.findIndex(o=>o.cancel==a);~c&&ze.splice(c,1),be-=~c?1:0},i={time:s,handler:e,cancel:a};return ze.splice(Hs(s),0,i),be+=1,Ws(),i};var Hs=e=>~(~ze.findIndex(t=>t.time>e)||~ze.length);N.cancel=e=>{yt.delete(e),es.delete(e),ts.delete(e),Kt.delete(e),Zt.delete(e)};N.sync=e=>{Lt=!0,N.batchedUpdates(e),Lt=!1};N.throttle=e=>{let t;function s(){try{e(...t)}finally{t=null}}function a(...i){t=i,N.onStart(s)}return a.handler=e,a.cancel=()=>{yt.delete(s),t=null},a};var ss=typeof window<"u"?window.requestAnimationFrame:(()=>{});N.use=e=>ss=e;N.now=typeof performance<"u"?()=>performance.now():Date.now;N.batchedUpdates=e=>e();N.catch=console.error;N.frameLoop="always";N.advance=()=>{N.frameLoop!=="demand"?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):Js()};var ye=-1,be=0,Lt=!1;function st(e,t){Lt?(t.delete(e),e(0)):(t.add(e),Ws())}function Ws(){ye<0&&(ye=0,N.frameLoop!=="demand"&&ss(Ys))}function ja(){ye=-1}function Ys(){~ye&&(ss(Ys),N.batchedUpdates(Js))}function Js(){const e=ye;ye=N.now();const t=Hs(ye);if(t&&(Ks(ze.splice(0,t),s=>s.handler()),be-=t),!be){ja();return}yt.flush(),Kt.flush(e?Math.min(64,ye-e):16.667),es.flush(),Zt.flush(),ts.flush()}function rt(){let e=new Set,t=e;return{add(s){be+=t==e&&!e.has(s)?1:0,e.add(s)},delete(s){return be-=t==e&&e.has(s)?1:0,e.delete(s)},flush(s){t.size&&(e=new Set,be-=t.size,Ks(t,a=>a(s)&&e.add(a)),be+=e.size,t=e)}}}function Ks(e,t){e.forEach(s=>{try{t(s)}catch(a){N.catch(a)}})}var wa=Object.defineProperty,Na=(e,t)=>{for(var s in t)wa(e,s,{get:t[s],enumerable:!0})},ee={};Na(ee,{assign:()=>ka,colors:()=>je,createStringInterpolator:()=>as,skipAnimation:()=>er,to:()=>Zs,willAdvance:()=>ns});function Ut(){}var _a=(e,t,s)=>Object.defineProperty(e,t,{value:s,writable:!0,configurable:!0}),l={arr:Array.isArray,obj:e=>!!e&&e.constructor.name==="Object",fun:e=>typeof e=="function",str:e=>typeof e=="string",num:e=>typeof e=="number",und:e=>e===void 0};function le(e,t){if(l.arr(e)){if(!l.arr(t)||e.length!==t.length)return!1;for(let s=0;s<e.length;s++)if(e[s]!==t[s])return!1;return!0}return e===t}var C=(e,t)=>e.forEach(t);function oe(e,t,s){if(l.arr(e)){for(let a=0;a<e.length;a++)t.call(s,e[a],`${a}`);return}for(const a in e)e.hasOwnProperty(a)&&t.call(s,e[a],a)}var O=e=>l.und(e)?[]:l.arr(e)?e:[e];function Qe(e,t){if(e.size){const s=Array.from(e);e.clear(),C(s,t)}}var Ue=(e,...t)=>Qe(e,s=>s(...t)),rs=()=>typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),as,Zs,je=null,er=!1,ns=Ut,ka=e=>{e.to&&(Zs=e.to),e.now&&(N.now=e.now),e.colors!==void 0&&(je=e.colors),e.skipAnimation!=null&&(er=e.skipAnimation),e.createStringInterpolator&&(as=e.createStringInterpolator),e.requestAnimationFrame&&N.use(e.requestAnimationFrame),e.batchedUpdates&&(N.batchedUpdates=e.batchedUpdates),e.willAdvance&&(ns=e.willAdvance),e.frameLoop&&(N.frameLoop=e.frameLoop)},Be=new Set,H=[],Ft=[],xt=0,bt={get idle(){return!Be.size&&!H.length},start(e){xt>e.priority?(Be.add(e),N.onStart(Sa)):(tr(e),N(Qt))},advance:Qt,sort(e){if(xt)N.onFrame(()=>bt.sort(e));else{const t=H.indexOf(e);~t&&(H.splice(t,1),sr(e))}},clear(){H=[],Be.clear()}};function Sa(){Be.forEach(tr),Be.clear(),N(Qt)}function tr(e){H.includes(e)||sr(e)}function sr(e){H.splice(Pa(H,t=>t.priority>e.priority),0,e)}function Qt(e){const t=Ft;for(let s=0;s<H.length;s++){const a=H[s];xt=a.priority,a.idle||(ns(a),a.advance(e),a.idle||t.push(a))}return xt=0,Ft=H,Ft.length=0,H=t,H.length>0}function Pa(e,t){const s=e.findIndex(t);return s<0?e.length:s}var Ca={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},Z="[-+]?\\d*\\.?\\d+",gt=Z+"%";function jt(...e){return"\\(\\s*("+e.join(")\\s*,\\s*(")+")\\s*\\)"}var Aa=new RegExp("rgb"+jt(Z,Z,Z)),Ra=new RegExp("rgba"+jt(Z,Z,Z,Z)),Ea=new RegExp("hsl"+jt(Z,gt,gt)),Ta=new RegExp("hsla"+jt(Z,gt,gt,Z)),Ia=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,za=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,Fa=/^#([0-9a-fA-F]{6})$/,Va=/^#([0-9a-fA-F]{8})$/;function Da(e){let t;return typeof e=="number"?e>>>0===e&&e>=0&&e<=4294967295?e:null:(t=Fa.exec(e))?parseInt(t[1]+"ff",16)>>>0:je&&je[e]!==void 0?je[e]:(t=Aa.exec(e))?(Ie(t[1])<<24|Ie(t[2])<<16|Ie(t[3])<<8|255)>>>0:(t=Ra.exec(e))?(Ie(t[1])<<24|Ie(t[2])<<16|Ie(t[3])<<8|Cs(t[4]))>>>0:(t=Ia.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+"ff",16)>>>0:(t=Va.exec(e))?parseInt(t[1],16)>>>0:(t=za.exec(e))?parseInt(t[1]+t[1]+t[2]+t[2]+t[3]+t[3]+t[4]+t[4],16)>>>0:(t=Ea.exec(e))?(Ss(Ps(t[1]),ht(t[2]),ht(t[3]))|255)>>>0:(t=Ta.exec(e))?(Ss(Ps(t[1]),ht(t[2]),ht(t[3]))|Cs(t[4]))>>>0:null}function Vt(e,t,s){return s<0&&(s+=1),s>1&&(s-=1),s<1/6?e+(t-e)*6*s:s<1/2?t:s<2/3?e+(t-e)*(2/3-s)*6:e}function Ss(e,t,s){const a=s<.5?s*(1+t):s+t-s*t,i=2*s-a,c=Vt(i,a,e+1/3),o=Vt(i,a,e),d=Vt(i,a,e-1/3);return Math.round(c*255)<<24|Math.round(o*255)<<16|Math.round(d*255)<<8}function Ie(e){const t=parseInt(e,10);return t<0?0:t>255?255:t}function Ps(e){return(parseFloat(e)%360+360)%360/360}function Cs(e){const t=parseFloat(e);return t<0?0:t>1?255:Math.round(t*255)}function ht(e){const t=parseFloat(e);return t<0?0:t>100?1:t/100}function As(e){let t=Da(e);if(t===null)return e;t=t||0;const s=(t&4278190080)>>>24,a=(t&16711680)>>>16,i=(t&65280)>>>8,c=(t&255)/255;return`rgba(${s}, ${a}, ${i}, ${c})`}var He=(e,t,s)=>{if(l.fun(e))return e;if(l.arr(e))return He({range:e,output:t,extrapolate:s});if(l.str(e.output[0]))return as(e);const a=e,i=a.output,c=a.range||[0,1],o=a.extrapolateLeft||a.extrapolate||"extend",d=a.extrapolateRight||a.extrapolate||"extend",m=a.easing||(u=>u);return u=>{const x=qa(u,c);return $a(u,c[x],c[x+1],i[x],i[x+1],m,o,d,a.map)}};function $a(e,t,s,a,i,c,o,d,m){let u=m?m(e):e;if(u<t){if(o==="identity")return u;o==="clamp"&&(u=t)}if(u>s){if(d==="identity")return u;d==="clamp"&&(u=s)}return a===i?a:t===s?e<=t?a:i:(t===-1/0?u=-u:s===1/0?u=u-t:u=(u-t)/(s-t),u=c(u),a===-1/0?u=-u:i===1/0?u=u+a:u=u*(i-a)+a,u)}function qa(e,t){for(var s=1;s<t.length-1&&!(t[s]>=e);++s);return s-1}var Ma={linear:e=>e},We=Symbol.for("FluidValue.get"),Ve=Symbol.for("FluidValue.observers"),G=e=>!!(e&&e[We]),q=e=>e&&e[We]?e[We]():e,Rs=e=>e[Ve]||null;function Oa(e,t){e.eventObserved?e.eventObserved(t):e(t)}function Ye(e,t){const s=e[Ve];s&&s.forEach(a=>{Oa(a,t)})}var rr=class{constructor(e){if(!e&&!(e=this.get))throw Error("Unknown getter");La(this,e)}},La=(e,t)=>ar(e,We,t);function De(e,t){if(e[We]){let s=e[Ve];s||ar(e,Ve,s=new Set),s.has(t)||(s.add(t),e.observerAdded&&e.observerAdded(s.size,t))}return t}function Je(e,t){const s=e[Ve];if(s&&s.has(t)){const a=s.size-1;a?s.delete(t):e[Ve]=null,e.observerRemoved&&e.observerRemoved(a,t)}}var ar=(e,t,s)=>Object.defineProperty(e,t,{value:s,writable:!0,configurable:!0}),ft=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,Ua=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Es=new RegExp(`(${ft.source})(%|[a-z]+)`,"i"),Qa=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,wt=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,nr=e=>{const[t,s]=Ba(e);if(!t||rs())return e;const a=window.getComputedStyle(document.documentElement).getPropertyValue(t);if(a)return a.trim();if(s&&s.startsWith("--")){const i=window.getComputedStyle(document.documentElement).getPropertyValue(s);return i||e}else{if(s&&wt.test(s))return nr(s);if(s)return s}return e},Ba=e=>{const t=wt.exec(e);if(!t)return[,];const[,s,a]=t;return[s,a]},Dt,Xa=(e,t,s,a,i)=>`rgba(${Math.round(t)}, ${Math.round(s)}, ${Math.round(a)}, ${i})`,ir=e=>{Dt||(Dt=je?new RegExp(`(${Object.keys(je).join("|")})(?!\\w)`,"g"):/^\b$/);const t=e.output.map(c=>q(c).replace(wt,nr).replace(Ua,As).replace(Dt,As)),s=t.map(c=>c.match(ft).map(Number)),i=s[0].map((c,o)=>s.map(d=>{if(!(o in d))throw Error('The arity of each "output" value must be equal');return d[o]})).map(c=>He({...e,output:c}));return c=>{const o=!Es.test(t[0])&&t.find(m=>Es.test(m))?.replace(ft,"");let d=0;return t[0].replace(ft,()=>`${i[d++](c)}${o||""}`).replace(Qa,Xa)}},is="react-spring: ",cr=e=>{const t=e;let s=!1;if(typeof t!="function")throw new TypeError(`${is}once requires a function parameter`);return(...a)=>{s||(t(...a),s=!0)}},Ga=cr(console.warn);function Ha(){Ga(`${is}The "interpolate" function is deprecated in v9 (use "to" instead)`)}var Wa=cr(console.warn);function Ya(){Wa(`${is}Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions`)}function Nt(e){return l.str(e)&&(e[0]=="#"||/\d/.test(e)||!rs()&&wt.test(e)||e in(je||{}))}var cs=rs()?f.useEffect:f.useLayoutEffect,Ja=()=>{const e=f.useRef(!1);return cs(()=>(e.current=!0,()=>{e.current=!1}),[]),e};function or(){const e=f.useState()[1],t=Ja();return()=>{t.current&&e(Math.random())}}var lr=e=>f.useEffect(e,Ka),Ka=[];function Ts(e){const t=f.useRef(void 0);return f.useEffect(()=>{t.current=e}),t.current}var Ke=Symbol.for("Animated:node"),Za=e=>!!e&&e[Ke]===e,ce=e=>e&&e[Ke],os=(e,t)=>_a(e,Ke,t),_t=e=>e&&e[Ke]&&e[Ke].getPayload(),dr=class{constructor(){os(this,this)}getPayload(){return this.payload||[]}},kt=class ur extends dr{constructor(t){super(),this._value=t,this.done=!0,this.durationProgress=0,l.num(this._value)&&(this.lastPosition=this._value)}static create(t){return new ur(t)}getPayload(){return[this]}getValue(){return this._value}setValue(t,s){return l.num(t)&&(this.lastPosition=t,s&&(t=Math.round(t/s)*s,this.done&&(this.lastPosition=t))),this._value===t?!1:(this._value=t,!0)}reset(){const{done:t}=this;this.done=!1,l.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,t&&(this.lastVelocity=null),this.v0=null)}},pt=class hr extends kt{constructor(t){super(0),this._string=null,this._toString=He({output:[t,t]})}static create(t){return new hr(t)}getValue(){const t=this._string;return t??(this._string=this._toString(this._value))}setValue(t){if(l.str(t)){if(t==this._string)return!1;this._string=t,this._value=1}else if(super.setValue(t))this._string=null;else return!1;return!0}reset(t){t&&(this._toString=He({output:[this.getValue(),t]})),this._value=0,super.reset()}},vt={dependencies:null},St=class extends dr{constructor(e){super(),this.source=e,this.setValue(e)}getValue(e){const t={};return oe(this.source,(s,a)=>{Za(s)?t[a]=s.getValue(e):G(s)?t[a]=q(s):e||(t[a]=s)}),t}setValue(e){this.source=e,this.payload=this._makePayload(e)}reset(){this.payload&&C(this.payload,e=>e.reset())}_makePayload(e){if(e){const t=new Set;return oe(e,this._addToPayload,t),Array.from(t)}}_addToPayload(e){vt.dependencies&&G(e)&&vt.dependencies.add(e);const t=_t(e);t&&C(t,s=>this.add(s))}},en=class fr extends St{constructor(t){super(t)}static create(t){return new fr(t)}getValue(){return this.source.map(t=>t.getValue())}setValue(t){const s=this.getPayload();return t.length==s.length?s.map((a,i)=>a.setValue(t[i])).some(Boolean):(super.setValue(t.map(tn)),!0)}};function tn(e){return(Nt(e)?pt:kt).create(e)}function Bt(e){const t=ce(e);return t?t.constructor:l.arr(e)?en:Nt(e)?pt:kt}var Is=(e,t)=>{const s=!l.fun(e)||e.prototype&&e.prototype.isReactComponent;return f.forwardRef((a,i)=>{const c=f.useRef(null),o=s&&f.useCallback(w=>{c.current=an(i,w)},[i]),[d,m]=rn(a,t),u=or(),x=()=>{const w=c.current;if(s&&!w)return;(w?t.applyAnimatedValues(w,d.getValue(!0)):!1)===!1&&u()},p=new sn(x,m),y=f.useRef(void 0);cs(()=>(y.current=p,C(m,w=>De(w,p)),()=>{y.current&&(C(y.current.deps,w=>Je(w,y.current)),N.cancel(y.current.update))})),f.useEffect(x,[]),lr(()=>()=>{const w=y.current;C(w.deps,b=>Je(b,w))});const g=t.getComponentProps(d.getValue());return f.createElement(e,{...g,ref:o})})},sn=class{constructor(e,t){this.update=e,this.deps=t}eventObserved(e){e.type=="change"&&N.write(this.update)}};function rn(e,t){const s=new Set;return vt.dependencies=s,e.style&&(e={...e,style:t.createAnimatedStyle(e.style)}),e=new St(e),vt.dependencies=null,[e,s]}function an(e,t){return e&&(l.fun(e)?e(t):e.current=t),t}var zs=Symbol.for("AnimatedComponent"),nn=(e,{applyAnimatedValues:t=()=>!1,createAnimatedStyle:s=i=>new St(i),getComponentProps:a=i=>i}={})=>{const i={applyAnimatedValues:t,createAnimatedStyle:s,getComponentProps:a},c=o=>{const d=Fs(o)||"Anonymous";return l.str(o)?o=c[o]||(c[o]=Is(o,i)):o=o[zs]||(o[zs]=Is(o,i)),o.displayName=`Animated(${d})`,o};return oe(e,(o,d)=>{l.arr(e)&&(d=Fs(o)),c[d]=c(o)}),{animated:c}},Fs=e=>l.str(e)?e:e&&l.str(e.displayName)?e.displayName:l.fun(e)&&e.name||null;function Se(e,...t){return l.fun(e)?e(...t):e}var Xe=(e,t)=>e===!0||!!(t&&e&&(l.fun(e)?e(t):O(e).includes(t))),mr=(e,t)=>l.obj(e)?t&&e[t]:e,xr=(e,t)=>e.default===!0?e[t]:e.default?e.default[t]:void 0,cn=e=>e,ls=(e,t=cn)=>{let s=on;e.default&&e.default!==!0&&(e=e.default,s=Object.keys(e));const a={};for(const i of s){const c=t(e[i],i);l.und(c)||(a[i]=c)}return a},on=["config","onProps","onStart","onChange","onPause","onResume","onRest"],ln={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function dn(e){const t={};let s=0;if(oe(e,(a,i)=>{ln[i]||(t[i]=a,s++)}),s)return t}function gr(e){const t=dn(e);if(t){const s={to:t};return oe(e,(a,i)=>i in t||(s[i]=a)),s}return{...e}}function Ze(e){return e=q(e),l.arr(e)?e.map(Ze):Nt(e)?ee.createStringInterpolator({range:[0,1],output:[e,e]})(1):e}function un(e){for(const t in e)return!0;return!1}function Xt(e){return l.fun(e)||l.arr(e)&&l.obj(e[0])}function hn(e,t){e.ref?.delete(e),t?.delete(e)}function fn(e,t){t&&e.ref!==t&&(e.ref?.delete(e),t.add(e),e.ref=t)}var mn={default:{tension:170,friction:26}},Gt={...mn.default,mass:1,damping:1,easing:Ma.linear,clamp:!1},xn=class{constructor(){this.velocity=0,Object.assign(this,Gt)}};function gn(e,t,s){s&&(s={...s},Vs(s,t),t={...s,...t}),Vs(e,t),Object.assign(e,t);for(const o in Gt)e[o]==null&&(e[o]=Gt[o]);let{frequency:a,damping:i}=e;const{mass:c}=e;return l.und(a)||(a<.01&&(a=.01),i<0&&(i=0),e.tension=Math.pow(2*Math.PI/a,2)*c,e.friction=4*Math.PI*i*c/a),e}function Vs(e,t){if(!l.und(t.decay))e.duration=void 0;else{const s=!l.und(t.tension)||!l.und(t.friction);(s||!l.und(t.frequency)||!l.und(t.damping)||!l.und(t.mass))&&(e.duration=void 0,e.decay=void 0),s&&(e.frequency=void 0)}}var Ds=[],pn=class{constructor(){this.changed=!1,this.values=Ds,this.toValues=null,this.fromValues=Ds,this.config=new xn,this.immediate=!1}};function pr(e,{key:t,props:s,defaultProps:a,state:i,actions:c}){return new Promise((o,d)=>{let m,u,x=Xe(s.cancel??a?.cancel,t);if(x)g();else{l.und(s.pause)||(i.paused=Xe(s.pause,t));let w=a?.pause;w!==!0&&(w=i.paused||Xe(w,t)),m=Se(s.delay||0,t),w?(i.resumeQueue.add(y),c.pause()):(c.resume(),y())}function p(){i.resumeQueue.add(y),i.timeouts.delete(u),u.cancel(),m=u.time-N.now()}function y(){m>0&&!ee.skipAnimation?(i.delayed=!0,u=N.setTimeout(g,m),i.pauseQueue.add(p),i.timeouts.add(u)):g()}function g(){i.delayed&&(i.delayed=!1),i.pauseQueue.delete(p),i.timeouts.delete(u),e<=(i.cancelId||0)&&(x=!0);try{c.start({...s,callId:e,cancel:x},o)}catch(w){d(w)}}})}var ds=(e,t)=>t.length==1?t[0]:t.some(s=>s.cancelled)?Fe(e.get()):t.every(s=>s.noop)?vr(e.get()):K(e.get(),t.every(s=>s.finished)),vr=e=>({value:e,noop:!0,finished:!0,cancelled:!1}),K=(e,t,s=!1)=>({value:e,finished:t,cancelled:s}),Fe=e=>({value:e,cancelled:!0,finished:!1});function yr(e,t,s,a){const{callId:i,parentId:c,onRest:o}=t,{asyncTo:d,promise:m}=s;return!c&&e===d&&!t.reset?m:s.promise=(async()=>{s.asyncId=i,s.asyncTo=e;const u=ls(t,(k,v)=>v==="onRest"?void 0:k);let x,p;const y=new Promise((k,v)=>(x=k,p=v)),g=k=>{const v=i<=(s.cancelId||0)&&Fe(a)||i!==s.asyncId&&K(a,!1);if(v)throw k.result=v,p(k),k},w=(k,v)=>{const S=new $s,j=new qs;return(async()=>{if(ee.skipAnimation)throw et(s),j.result=K(a,!1),p(j),j;g(S);const R=l.obj(k)?{...k}:{...v,to:k};R.parentId=i,oe(u,(E,V)=>{l.und(R[V])&&(R[V]=E)});const A=await a.start(R);return g(S),s.paused&&await new Promise(E=>{s.resumeQueue.add(E)}),A})()};let b;if(ee.skipAnimation)return et(s),K(a,!1);try{let k;l.arr(e)?k=(async v=>{for(const S of v)await w(S)})(e):k=Promise.resolve(e(w,a.stop.bind(a))),await Promise.all([k.then(x),y]),b=K(a.get(),!0,!1)}catch(k){if(k instanceof $s)b=k.result;else if(k instanceof qs)b=k.result;else throw k}finally{i==s.asyncId&&(s.asyncId=c,s.asyncTo=c?d:void 0,s.promise=c?m:void 0)}return l.fun(o)&&N.batchedUpdates(()=>{o(b,a,a.item)}),b})()}function et(e,t){Qe(e.timeouts,s=>s.cancel()),e.pauseQueue.clear(),e.resumeQueue.clear(),e.asyncId=e.asyncTo=e.promise=void 0,t&&(e.cancelId=t)}var $s=class extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise.")}},qs=class extends Error{constructor(){super("SkipAnimationSignal")}},Ht=e=>e instanceof us,vn=1,us=class extends rr{constructor(){super(...arguments),this.id=vn++,this._priority=0}get priority(){return this._priority}set priority(e){this._priority!=e&&(this._priority=e,this._onPriorityChange(e))}get(){const e=ce(this);return e&&e.getValue()}to(...e){return ee.to(this,e)}interpolate(...e){return Ha(),ee.to(this,e)}toJSON(){return this.get()}observerAdded(e){e==1&&this._attach()}observerRemoved(e){e==0&&this._detach()}_attach(){}_detach(){}_onChange(e,t=!1){Ye(this,{type:"change",parent:this,value:e,idle:t})}_onPriorityChange(e){this.idle||bt.sort(this),Ye(this,{type:"priority",parent:this,priority:e})}},Pe=Symbol.for("SpringPhase"),br=1,Wt=2,Yt=4,$t=e=>(e[Pe]&br)>0,ve=e=>(e[Pe]&Wt)>0,Me=e=>(e[Pe]&Yt)>0,Ms=(e,t)=>t?e[Pe]|=Wt|br:e[Pe]&=~Wt,Os=(e,t)=>t?e[Pe]|=Yt:e[Pe]&=~Yt,yn=class extends us{constructor(e,t){if(super(),this.animation=new pn,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!l.und(e)||!l.und(t)){const s=l.obj(e)?{...e}:{...t,from:e};l.und(s.default)&&(s.default=!0),this.start(s)}}get idle(){return!(ve(this)||this._state.asyncTo)||Me(this)}get goal(){return q(this.animation.to)}get velocity(){const e=ce(this);return e instanceof kt?e.lastVelocity||0:e.getPayload().map(t=>t.lastVelocity||0)}get hasAnimated(){return $t(this)}get isAnimating(){return ve(this)}get isPaused(){return Me(this)}get isDelayed(){return this._state.delayed}advance(e){let t=!0,s=!1;const a=this.animation;let{toValues:i}=a;const{config:c}=a,o=_t(a.to);!o&&G(a.to)&&(i=O(q(a.to))),a.values.forEach((u,x)=>{if(u.done)return;const p=u.constructor==pt?1:o?o[x].lastPosition:i[x];let y=a.immediate,g=p;if(!y){if(g=u.lastPosition,c.tension<=0){u.done=!0;return}let w=u.elapsedTime+=e;const b=a.fromValues[x],k=u.v0!=null?u.v0:u.v0=l.arr(c.velocity)?c.velocity[x]:c.velocity;let v;const S=c.precision||(b==p?.005:Math.min(1,Math.abs(p-b)*.001));if(l.und(c.duration))if(c.decay){const j=c.decay===!0?.998:c.decay,R=Math.exp(-(1-j)*w);g=b+k/(1-j)*(1-R),y=Math.abs(u.lastPosition-g)<=S,v=k*R}else{v=u.lastVelocity==null?k:u.lastVelocity;const j=c.restVelocity||S/10,R=c.clamp?0:c.bounce,A=!l.und(R),E=b==p?u.v0>0:b<p;let V,F=!1;const T=1,de=Math.ceil(e/T);for(let L=0;L<de&&(V=Math.abs(v)>j,!(!V&&(y=Math.abs(p-g)<=S,y)));++L){A&&(F=g==p||g>p==E,F&&(v=-v*R,g=p));const ue=-c.tension*1e-6*(g-p),W=-c.friction*.001*v,Ce=(ue+W)/c.mass;v=v+Ce*T,g=g+v*T}}else{let j=1;c.duration>0&&(this._memoizedDuration!==c.duration&&(this._memoizedDuration=c.duration,u.durationProgress>0&&(u.elapsedTime=c.duration*u.durationProgress,w=u.elapsedTime+=e)),j=(c.progress||0)+w/this._memoizedDuration,j=j>1?1:j<0?0:j,u.durationProgress=j),g=b+c.easing(j)*(p-b),v=(g-u.lastPosition)/e,y=j==1}u.lastVelocity=v,Number.isNaN(g)&&(console.warn("Got NaN while animating:",this),y=!0)}o&&!o[x].done&&(y=!1),y?u.done=!0:t=!1,u.setValue(g,c.round)&&(s=!0)});const d=ce(this),m=d.getValue();if(t){const u=q(a.to);(m!==u||s)&&!c.decay?(d.setValue(u),this._onChange(u)):s&&c.decay&&this._onChange(m),this._stop()}else s&&this._onChange(m)}set(e){return N.batchedUpdates(()=>{this._stop(),this._focus(e),this._set(e)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(ve(this)){const{to:e,config:t}=this.animation;N.batchedUpdates(()=>{this._onStart(),t.decay||this._set(e,!1),this._stop()})}return this}update(e){return(this.queue||(this.queue=[])).push(e),this}start(e,t){let s;return l.und(e)?(s=this.queue||[],this.queue=[]):s=[l.obj(e)?e:{...t,to:e}],Promise.all(s.map(a=>this._update(a))).then(a=>ds(this,a))}stop(e){const{to:t}=this.animation;return this._focus(this.get()),et(this._state,e&&this._lastCallId),N.batchedUpdates(()=>this._stop(t,e)),this}reset(){this._update({reset:!0})}eventObserved(e){e.type=="change"?this._start():e.type=="priority"&&(this.priority=e.priority+1)}_prepareNode(e){const t=this.key||"";let{to:s,from:a}=e;s=l.obj(s)?s[t]:s,(s==null||Xt(s))&&(s=void 0),a=l.obj(a)?a[t]:a,a==null&&(a=void 0);const i={to:s,from:a};return $t(this)||(e.reverse&&([s,a]=[a,s]),a=q(a),l.und(a)?ce(this)||this._set(s):this._set(a)),i}_update({...e},t){const{key:s,defaultProps:a}=this;e.default&&Object.assign(a,ls(e,(o,d)=>/^on/.test(d)?mr(o,s):o)),Us(this,e,"onProps"),Le(this,"onProps",e,this);const i=this._prepareNode(e);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const c=this._state;return pr(++this._lastCallId,{key:s,props:e,defaultProps:a,state:c,actions:{pause:()=>{Me(this)||(Os(this,!0),Ue(c.pauseQueue),Le(this,"onPause",K(this,Oe(this,this.animation.to)),this))},resume:()=>{Me(this)&&(Os(this,!1),ve(this)&&this._resume(),Ue(c.resumeQueue),Le(this,"onResume",K(this,Oe(this,this.animation.to)),this))},start:this._merge.bind(this,i)}}).then(o=>{if(e.loop&&o.finished&&!(t&&o.noop)){const d=jr(e);if(d)return this._update(d,!0)}return o})}_merge(e,t,s){if(t.cancel)return this.stop(!0),s(Fe(this));const a=!l.und(e.to),i=!l.und(e.from);if(a||i)if(t.callId>this._lastToId)this._lastToId=t.callId;else return s(Fe(this));const{key:c,defaultProps:o,animation:d}=this,{to:m,from:u}=d;let{to:x=m,from:p=u}=e;i&&!a&&(!t.default||l.und(x))&&(x=p),t.reverse&&([x,p]=[p,x]);const y=!le(p,u);y&&(d.from=p),p=q(p);const g=!le(x,m);g&&this._focus(x);const w=Xt(t.to),{config:b}=d,{decay:k,velocity:v}=b;(a||i)&&(b.velocity=0),t.config&&!w&&gn(b,Se(t.config,c),t.config!==o.config?Se(o.config,c):void 0);let S=ce(this);if(!S||l.und(x))return s(K(this,!0));const j=l.und(t.reset)?i&&!t.default:!l.und(p)&&Xe(t.reset,c),R=j?p:this.get(),A=Ze(x),E=l.num(A)||l.arr(A)||Nt(A),V=!w&&(!E||Xe(o.immediate||t.immediate,c));if(g){const L=Bt(x);if(L!==S.constructor)if(V)S=this._set(A);else throw Error(`Cannot animate between ${S.constructor.name} and ${L.name}, as the "to" prop suggests`)}const F=S.constructor;let T=G(x),de=!1;if(!T){const L=j||!$t(this)&&y;(g||L)&&(de=le(Ze(R),A),T=!de),(!le(d.immediate,V)&&!V||!le(b.decay,k)||!le(b.velocity,v))&&(T=!0)}if(de&&ve(this)&&(d.changed&&!j?T=!0:T||this._stop(m)),!w&&((T||G(m))&&(d.values=S.getPayload(),d.toValues=G(x)?null:F==pt?[1]:O(A)),d.immediate!=V&&(d.immediate=V,!V&&!j&&this._set(m)),T)){const{onRest:L}=d;C(jn,W=>Us(this,t,W));const ue=K(this,Oe(this,m));Ue(this._pendingCalls,ue),this._pendingCalls.add(s),d.changed&&N.batchedUpdates(()=>{d.changed=!j,L?.(ue,this),j?Se(o.onRest,ue):d.onStart?.(ue,this)})}j&&this._set(R),w?s(yr(t.to,t,this._state,this)):T?this._start():ve(this)&&!g?this._pendingCalls.add(s):s(vr(R))}_focus(e){const t=this.animation;e!==t.to&&(Rs(this)&&this._detach(),t.to=e,Rs(this)&&this._attach())}_attach(){let e=0;const{to:t}=this.animation;G(t)&&(De(t,this),Ht(t)&&(e=t.priority+1)),this.priority=e}_detach(){const{to:e}=this.animation;G(e)&&Je(e,this)}_set(e,t=!0){const s=q(e);if(!l.und(s)){const a=ce(this);if(!a||!le(s,a.getValue())){const i=Bt(s);!a||a.constructor!=i?os(this,i.create(s)):a.setValue(s),a&&N.batchedUpdates(()=>{this._onChange(s,t)})}}return ce(this)}_onStart(){const e=this.animation;e.changed||(e.changed=!0,Le(this,"onStart",K(this,Oe(this,e.to)),this))}_onChange(e,t){t||(this._onStart(),Se(this.animation.onChange,e,this)),Se(this.defaultProps.onChange,e,this),super._onChange(e,t)}_start(){const e=this.animation;ce(this).reset(q(e.to)),e.immediate||(e.fromValues=e.values.map(t=>t.lastPosition)),ve(this)||(Ms(this,!0),Me(this)||this._resume())}_resume(){ee.skipAnimation?this.finish():bt.start(this)}_stop(e,t){if(ve(this)){Ms(this,!1);const s=this.animation;C(s.values,i=>{i.done=!0}),s.toValues&&(s.onChange=s.onPause=s.onResume=void 0),Ye(this,{type:"idle",parent:this});const a=t?Fe(this.get()):K(this.get(),Oe(this,e??s.to));Ue(this._pendingCalls,a),s.changed&&(s.changed=!1,Le(this,"onRest",a,this))}}};function Oe(e,t){const s=Ze(t),a=Ze(e.get());return le(a,s)}function jr(e,t=e.loop,s=e.to){const a=Se(t);if(a){const i=a!==!0&&gr(a),c=(i||e).reverse,o=!i||i.reset;return tt({...e,loop:t,default:!1,pause:void 0,to:!c||Xt(s)?s:void 0,from:o?e.from:void 0,reset:o,...i})}}function tt(e){const{to:t,from:s}=e=gr(e),a=new Set;return l.obj(t)&&Ls(t,a),l.obj(s)&&Ls(s,a),e.keys=a.size?Array.from(a):null,e}function bn(e){const t=tt(e);return l.und(t.default)&&(t.default=ls(t)),t}function Ls(e,t){oe(e,(s,a)=>s!=null&&t.add(a))}var jn=["onStart","onRest","onChange","onPause","onResume"];function Us(e,t,s){e.animation[s]=t[s]!==xr(t,s)?mr(t[s],e.key):void 0}function Le(e,t,...s){e.animation[t]?.(...s),e.defaultProps[t]?.(...s)}var wn=["onStart","onChange","onRest"],Nn=1,_n=class{constructor(e,t){this.id=Nn++,this.springs={},this.queue=[],this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),t&&(this._flush=t),e&&this.start({default:!0,...e})}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(e=>e.idle&&!e.isDelayed&&!e.isPaused)}get item(){return this._item}set item(e){this._item=e}get(){const e={};return this.each((t,s)=>e[s]=t.get()),e}set(e){for(const t in e){const s=e[t];l.und(s)||this.springs[t].set(s)}}update(e){return e&&this.queue.push(tt(e)),this}start(e){let{queue:t}=this;return e?t=O(e).map(tt):this.queue=[],this._flush?this._flush(this,t):(Sr(this,t),Jt(this,t))}stop(e,t){if(e!==!!e&&(t=e),t){const s=this.springs;C(O(t),a=>s[a].stop(!!e))}else et(this._state,this._lastAsyncId),this.each(s=>s.stop(!!e));return this}pause(e){if(l.und(e))this.start({pause:!0});else{const t=this.springs;C(O(e),s=>t[s].pause())}return this}resume(e){if(l.und(e))this.start({pause:!1});else{const t=this.springs;C(O(e),s=>t[s].resume())}return this}each(e){oe(this.springs,e)}_onFrame(){const{onStart:e,onChange:t,onRest:s}=this._events,a=this._active.size>0,i=this._changed.size>0;(a&&!this._started||i&&!this._started)&&(this._started=!0,Qe(e,([d,m])=>{m.value=this.get(),d(m,this,this._item)}));const c=!a&&this._started,o=i||c&&s.size?this.get():null;i&&t.size&&Qe(t,([d,m])=>{m.value=o,d(m,this,this._item)}),c&&(this._started=!1,Qe(s,([d,m])=>{m.value=o,d(m,this,this._item)}))}eventObserved(e){if(e.type=="change")this._changed.add(e.parent),e.idle||this._active.add(e.parent);else if(e.type=="idle")this._active.delete(e.parent);else return;N.onFrame(this._onFrame)}};function Jt(e,t){return Promise.all(t.map(s=>wr(e,s))).then(s=>ds(e,s))}async function wr(e,t,s){const{keys:a,to:i,from:c,loop:o,onRest:d,onResolve:m}=t,u=l.obj(t.default)&&t.default;o&&(t.loop=!1),i===!1&&(t.to=null),c===!1&&(t.from=null);const x=l.arr(i)||l.fun(i)?i:void 0;x?(t.to=void 0,t.onRest=void 0,u&&(u.onRest=void 0)):C(wn,b=>{const k=t[b];if(l.fun(k)){const v=e._events[b];t[b]=({finished:S,cancelled:j})=>{const R=v.get(k);R?(S||(R.finished=!1),j&&(R.cancelled=!0)):v.set(k,{value:null,finished:S||!1,cancelled:j||!1})},u&&(u[b]=t[b])}});const p=e._state;t.pause===!p.paused?(p.paused=t.pause,Ue(t.pause?p.pauseQueue:p.resumeQueue)):p.paused&&(t.pause=!0);const y=(a||Object.keys(e.springs)).map(b=>e.springs[b].start(t)),g=t.cancel===!0||xr(t,"cancel")===!0;(x||g&&p.asyncId)&&y.push(pr(++e._lastAsyncId,{props:t,state:p,actions:{pause:Ut,resume:Ut,start(b,k){g?(et(p,e._lastAsyncId),k(Fe(e))):(b.onRest=d,k(yr(x,b,p,e)))}}})),p.paused&&await new Promise(b=>{p.resumeQueue.add(b)});const w=ds(e,await Promise.all(y));if(o&&w.finished&&!(s&&w.noop)){const b=jr(t,o,i);if(b)return Sr(e,[b]),wr(e,b,!0)}return m&&N.batchedUpdates(()=>m(w,e,e.item)),w}function Qs(e,t){const s={...e.springs};return t&&C(O(t),a=>{l.und(a.keys)&&(a=tt(a)),l.obj(a.to)||(a={...a,to:void 0}),kr(s,a,i=>_r(i))}),Nr(e,s),s}function Nr(e,t){oe(t,(s,a)=>{e.springs[a]||(e.springs[a]=s,De(s,e))})}function _r(e,t){const s=new yn;return s.key=e,t&&De(s,t),s}function kr(e,t,s){t.keys&&C(t.keys,a=>{(e[a]||(e[a]=s(a)))._prepareNode(t)})}function Sr(e,t){C(t,s=>{kr(e.springs,s,a=>_r(a,e))})}var kn=f.createContext({pause:!1,immediate:!1}),Sn=()=>{const e=[],t=function(a){Ya();const i=[];return C(e,(c,o)=>{if(l.und(a))i.push(c.start());else{const d=s(a,c,o);d&&i.push(c.start(d))}}),i};t.current=e,t.add=function(a){e.includes(a)||e.push(a)},t.delete=function(a){const i=e.indexOf(a);~i&&e.splice(i,1)},t.pause=function(){return C(e,a=>a.pause(...arguments)),this},t.resume=function(){return C(e,a=>a.resume(...arguments)),this},t.set=function(a){C(e,(i,c)=>{const o=l.fun(a)?a(c,i):a;o&&i.set(o)})},t.start=function(a){const i=[];return C(e,(c,o)=>{if(l.und(a))i.push(c.start());else{const d=this._getProps(a,c,o);d&&i.push(c.start(d))}}),i},t.stop=function(){return C(e,a=>a.stop(...arguments)),this},t.update=function(a){return C(e,(i,c)=>i.update(this._getProps(a,i,c))),this};const s=function(a,i,c){return l.fun(a)?a(c,i):a};return t._getProps=s,t};function Pn(e,t,s){const a=l.fun(t)&&t;a&&!s&&(s=[]);const i=f.useMemo(()=>a||arguments.length==3?Sn():void 0,[]),c=f.useRef(0),o=or(),d=f.useMemo(()=>({ctrls:[],queue:[],flush(v,S){const j=Qs(v,S);return c.current>0&&!d.queue.length&&!Object.keys(j).some(A=>!v.springs[A])?Jt(v,S):new Promise(A=>{Nr(v,j),d.queue.push(()=>{A(Jt(v,S))}),o()})}}),[]),m=f.useRef([...d.ctrls]),u=f.useRef([]),x=Ts(e)||0;f.useMemo(()=>{C(m.current.slice(e,x),v=>{hn(v,i),v.stop(!0)}),m.current.length=e,p(x,e)},[e]),f.useMemo(()=>{p(0,Math.min(x,e))},s);function p(v,S){for(let j=v;j<S;j++){const R=m.current[j]||(m.current[j]=new _n(null,d.flush)),A=a?a(j,R):t[j];A&&(u.current[j]=bn(A))}}const y=m.current.map((v,S)=>Qs(v,u.current[S])),g=f.useContext(kn),w=Ts(g),b=g!==w&&un(g);cs(()=>{c.current++,d.ctrls=m.current;const{queue:v}=d;v.length&&(d.queue=[],C(v,S=>S())),C(m.current,(S,j)=>{i?.add(S),b&&S.start({default:g});const R=u.current[j];R&&(fn(S,R.ref),S.ref?S.queue.push(R):S.start(R))})}),lr(()=>()=>{C(d.ctrls,v=>v.stop(!0))});const k=y.map(v=>({...v}));return i?[k,i]:k}function Cn(e,t){const s=l.fun(e),[[a],i]=Pn(1,s?e:[e],s?[]:t);return s||arguments.length==2?[a,i]:a}var An=class extends us{constructor(e,t){super(),this.source=e,this.idle=!0,this._active=new Set,this.calc=He(...t);const s=this._get(),a=Bt(s);os(this,a.create(s))}advance(e){const t=this._get(),s=this.get();le(t,s)||(ce(this).setValue(t),this._onChange(t,this.idle)),!this.idle&&Bs(this._active)&&qt(this)}_get(){const e=l.arr(this.source)?this.source.map(q):O(q(this.source));return this.calc(...e)}_start(){this.idle&&!Bs(this._active)&&(this.idle=!1,C(_t(this),e=>{e.done=!1}),ee.skipAnimation?(N.batchedUpdates(()=>this.advance()),qt(this)):bt.start(this))}_attach(){let e=1;C(O(this.source),t=>{G(t)&&De(t,this),Ht(t)&&(t.idle||this._active.add(t),e=Math.max(e,t.priority+1))}),this.priority=e,this._start()}_detach(){C(O(this.source),e=>{G(e)&&Je(e,this)}),this._active.clear(),qt(this)}eventObserved(e){e.type=="change"?e.idle?this.advance():(this._active.add(e.parent),this._start()):e.type=="idle"?this._active.delete(e.parent):e.type=="priority"&&(this.priority=O(this.source).reduce((t,s)=>Math.max(t,(Ht(s)?s.priority:0)+1),0))}};function Rn(e){return e.idle!==!1}function Bs(e){return!e.size||Array.from(e).every(Rn)}function qt(e){e.idle||(e.idle=!0,C(_t(e),t=>{t.done=!0}),Ye(e,{type:"idle",parent:e}))}ee.assign({createStringInterpolator:ir,to:(e,t)=>new An(e,t)});var Pr=/^--/;function En(e,t){return t==null||typeof t=="boolean"||t===""?"":typeof t=="number"&&t!==0&&!Pr.test(e)&&!(Ge.hasOwnProperty(e)&&Ge[e])?t+"px":(""+t).trim()}var Xs={};function Tn(e,t){if(!e.nodeType||!e.setAttribute)return!1;const s=e.nodeName==="filter"||e.parentNode&&e.parentNode.nodeName==="filter",{className:a,style:i,children:c,scrollTop:o,scrollLeft:d,viewBox:m,...u}=t,x=Object.values(u),p=Object.keys(u).map(y=>s||e.hasAttribute(y)?y:Xs[y]||(Xs[y]=y.replace(/([A-Z])/g,g=>"-"+g.toLowerCase())));c!==void 0&&(e.textContent=c);for(const y in i)if(i.hasOwnProperty(y)){const g=En(y,i[y]);Pr.test(y)?e.style.setProperty(y,g):e.style[y]=g}p.forEach((y,g)=>{e.setAttribute(y,x[g])}),a!==void 0&&(e.className=a),o!==void 0&&(e.scrollTop=o),d!==void 0&&(e.scrollLeft=d),m!==void 0&&e.setAttribute("viewBox",m)}var Ge={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},In=(e,t)=>e+t.charAt(0).toUpperCase()+t.substring(1),zn=["Webkit","Ms","Moz","O"];Ge=Object.keys(Ge).reduce((e,t)=>(zn.forEach(s=>e[In(s,t)]=e[t]),e),Ge);var Fn=/^(matrix|translate|scale|rotate|skew)/,Vn=/^(translate)/,Dn=/^(rotate|skew)/,Mt=(e,t)=>l.num(e)&&e!==0?e+t:e,mt=(e,t)=>l.arr(e)?e.every(s=>mt(s,t)):l.num(e)?e===t:parseFloat(e)===t,$n=class extends St{constructor({x:e,y:t,z:s,...a}){const i=[],c=[];(e||t||s)&&(i.push([e||0,t||0,s||0]),c.push(o=>[`translate3d(${o.map(d=>Mt(d,"px")).join(",")})`,mt(o,0)])),oe(a,(o,d)=>{if(d==="transform")i.push([o||""]),c.push(m=>[m,m===""]);else if(Fn.test(d)){if(delete a[d],l.und(o))return;const m=Vn.test(d)?"px":Dn.test(d)?"deg":"";i.push(O(o)),c.push(d==="rotate3d"?([u,x,p,y])=>[`rotate3d(${u},${x},${p},${Mt(y,m)})`,mt(y,0)]:u=>[`${d}(${u.map(x=>Mt(x,m)).join(",")})`,mt(u,d.startsWith("scale")?1:0)])}}),i.length&&(a.transform=new qn(i,c)),super(a)}},qn=class extends rr{constructor(e,t){super(),this.inputs=e,this.transforms=t,this._value=null}get(){return this._value||(this._value=this._get())}_get(){let e="",t=!0;return C(this.inputs,(s,a)=>{const i=q(s[0]),[c,o]=this.transforms[a](l.arr(i)?i:s.map(q));e+=" "+c,t=t&&o}),t?"none":e}observerAdded(e){e==1&&C(this.inputs,t=>C(t,s=>G(s)&&De(s,this)))}observerRemoved(e){e==0&&C(this.inputs,t=>C(t,s=>G(s)&&Je(s,this)))}eventObserved(e){e.type=="change"&&(this._value=null),Ye(this,e)}},Mn=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"];ee.assign({batchedUpdates:Jr.unstable_batchedUpdates,createStringInterpolator:ir,colors:Ca});var On=nn(Mn,{applyAnimatedValues:Tn,createAnimatedStyle:e=>new $n(e),getComponentProps:({scrollTop:e,scrollLeft:t,...s})=>s}),Ln=On.animated;const se="/api/webui/expression";async function Un(){const e=await te(`${se}/chats`,{});if(!e.ok)try{const t=await e.json();return{success:!1,error:t.detail||t.message||"获取聊天列表失败"}}catch{return{success:!1,error:e.statusText||"获取聊天列表失败"}}try{const t=await e.json();return t.success?{success:!0,data:t.data}:{success:!1,error:"获取聊天列表失败"}}catch{return{success:!1,error:"无法解析聊天列表响应"}}}async function Zn(e){const t=new URLSearchParams;e.page&&t.append("page",e.page.toString()),e.page_size&&t.append("page_size",e.page_size.toString()),e.search&&t.append("search",e.search),e.chat_id&&t.append("chat_id",e.chat_id);const s=await te(`${se}/list?${t}`,{});if(!s.ok)try{const a=await s.json();return{success:!1,error:a.detail||a.message||"获取表达方式列表失败"}}catch{return{success:!1,error:s.statusText||"获取表达方式列表失败"}}try{const a=await s.json();return a.success?{success:!0,data:a}:{success:!1,error:"获取表达方式列表失败"}}catch{return{success:!1,error:"无法解析表达方式列表响应"}}}async function ei(e){const t=await te(`${se}/${e}`,{});if(!t.ok)try{const s=await t.json();return{success:!1,error:s.detail||s.message||"获取表达方式详情失败"}}catch{return{success:!1,error:t.statusText||"获取表达方式详情失败"}}try{const s=await t.json();return s.success?{success:!0,data:s.data}:{success:!1,error:"获取表达方式详情失败"}}catch{return{success:!1,error:"无法解析表达方式详情响应"}}}async function ti(e){const t=await te(`${se}/`,{method:"POST",body:JSON.stringify(e)});if(!t.ok)try{const s=await t.json();return{success:!1,error:s.detail||s.message||"创建表达方式失败"}}catch{return{success:!1,error:t.statusText||"创建表达方式失败"}}try{const s=await t.json();return s.success?{success:!0,data:s.data}:{success:!1,error:s.message||"创建表达方式失败"}}catch{return{success:!1,error:"无法解析创建表达方式响应"}}}async function si(e,t){const s=await te(`${se}/${e}`,{method:"PATCH",body:JSON.stringify(t)});if(!s.ok)try{const a=await s.json();return{success:!1,error:a.detail||a.message||"更新表达方式失败"}}catch{return{success:!1,error:s.statusText||"更新表达方式失败"}}try{const a=await s.json();return a.success?{success:!0,data:a.data||{}}:{success:!1,error:a.message||"更新表达方式失败"}}catch{return{success:!1,error:"无法解析更新表达方式响应"}}}async function ri(e){const t=await te(`${se}/${e}`,{method:"DELETE"});if(!t.ok)try{const s=await t.json();return{success:!1,error:s.detail||s.message||"删除表达方式失败"}}catch{return{success:!1,error:t.statusText||"删除表达方式失败"}}try{const s=await t.json();return s.success?{success:!0,data:{}}:{success:!1,error:s.message||"删除表达方式失败"}}catch{return{success:!1,error:"无法解析删除表达方式响应"}}}async function ai(e){const t=await te(`${se}/batch/delete`,{method:"POST",body:JSON.stringify({ids:e})});if(!t.ok)try{const s=await t.json();return{success:!1,error:s.detail||s.message||"批量删除表达方式失败"}}catch{return{success:!1,error:t.statusText||"批量删除表达方式失败"}}try{const s=await t.json();return s.success?{success:!0,data:{}}:{success:!1,error:s.message||"批量删除表达方式失败"}}catch{return{success:!1,error:"无法解析批量删除表达方式响应"}}}async function ni(){const e=await te(`${se}/stats/summary`,{});if(!e.ok)try{const t=await e.json();return{success:!1,error:t.detail||t.message||"获取统计数据失败"}}catch{return{success:!1,error:e.statusText||"获取统计数据失败"}}try{const t=await e.json();return t.success?{success:!0,data:t.data}:{success:!1,error:"获取统计数据失败"}}catch{return{success:!1,error:"无法解析统计数据响应"}}}async function Qn(){const e=await te(`${se}/review/stats`);if(!e.ok)try{const t=await e.json();return{success:!1,error:t.detail||t.message||"获取审核统计失败"}}catch{return{success:!1,error:e.statusText||"获取审核统计失败"}}try{return{success:!0,data:await e.json()}}catch{return{success:!1,error:"无法解析审核统计响应"}}}async function Gs(e){const t=new URLSearchParams;e.page&&t.append("page",e.page.toString()),e.page_size&&t.append("page_size",e.page_size.toString()),e.filter_type&&t.append("filter_type",e.filter_type),e.order&&t.append("order",e.order),e.search&&t.append("search",e.search),e.chat_id&&t.append("chat_id",e.chat_id),e.exclude_ids?.forEach(a=>t.append("exclude_ids",a.toString()));const s=await te(`${se}/review/list?${t}`);if(!s.ok)try{const a=await s.json();return{success:!1,error:a.detail||a.message||"获取审核列表失败"}}catch{return{success:!1,error:s.statusText||"获取审核列表失败"}}try{const a=await s.json();return a.success?{success:!0,data:a}:{success:!1,error:"获取审核列表失败"}}catch{return{success:!1,error:"无法解析审核列表响应"}}}async function Ot(e){const t=await te(`${se}/review/batch`,{method:"POST",body:JSON.stringify({items:e})});if(!t.ok)try{const s=await t.json();return{success:!1,error:s.detail||s.message||"批量审核失败"}}catch{return{success:!1,error:t.statusText||"批量审核失败"}}try{const s=await t.json();return s.success?{success:!0,data:s}:{success:!1,error:"批量审核失败"}}catch{return{success:!1,error:"无法解析批量审核响应"}}}const Bn=Ln("div");function ii({open:e,onOpenChange:t}){const[s,a]=f.useState("list"),[i,c]=f.useState(null),[o,d]=f.useState([]),[m,u]=f.useState("unchecked"),[x,p]=f.useState([]),y=f.useRef([]),[g,w]=f.useState(0),[b,k]=f.useState(!1),[v,S]=f.useState(0),[j,R]=f.useState(1),A=f.useRef(null),E=f.useRef(!1),[V,F]=Cn(()=>({x:0,opacity:1,rotate:0,config:{tension:300,friction:30}})),T=f.useRef(0),[de,L]=f.useState(null),ue=f.useRef(null),W=f.useRef(null),Ce=f.useRef(!1);f.useEffect(()=>{y.current=x},[x]);const[U,at]=f.useState(!1),[nt,hs]=f.useState(!1),[fs,Cr]=f.useState(0),[re,we]=f.useState(1),[it,Ar]=f.useState(20),[ms,xs]=f.useState(""),[Q,Rr]=f.useState("unchecked"),[Pt,Er]=f.useState(""),[gs,Tr]=f.useState(""),[D,Ne]=f.useState(new Set),[ae,ps]=f.useState(new Set),[Ir,zr]=f.useState(new Map),{toast:z}=Kr(),Y=f.useCallback(async()=>{try{hs(!0);const n=await Qn();n.success?c(n.data):z({title:"错误",description:n.error,variant:"destructive"})}catch(n){console.error("加载统计失败:",n)}finally{hs(!1)}},[z]),$e=f.useCallback(async()=>{try{at(!0);const n=await Gs({page:re,page_size:it,filter_type:Q,search:Pt||void 0});n.success?(d(n.data.data),Cr(n.data.total)):z({title:"加载失败",description:n.error,variant:"destructive"})}catch(n){z({title:"加载失败",description:n instanceof Error?n.message:"无法加载列表",variant:"destructive"})}finally{at(!1)}},[re,it,Q,Pt,z]),vs=f.useCallback(async()=>{try{const n=await Un();if(n.success){const h=new Map;n.data.forEach(_=>{h.set(_.chat_id,_.chat_name)}),zr(h)}}catch(n){console.error("加载聚天名称失败:",n)}},[]),he=f.useCallback(async(n=!0,h=!1)=>{try{k(!0);const _=h?j+1:j,P=await Gs({page:m==="unchecked"?1:_,page_size:20,filter_type:m,order:m==="unchecked"?"random":"latest",exclude_ids:m==="unchecked"&&h?y.current.map($=>$.id):void 0});P.success?(h?(p($=>[...$,...P.data.data]),R(_)):p(P.data.data),S(P.data.total),n&&w(0)):z({title:"加载失败",description:P.error,variant:"destructive"})}catch(_){z({title:"加载失败",description:_ instanceof Error?_.message:"无法加载列表",variant:"destructive"})}finally{k(!1)}},[j,m,z]);f.useEffect(()=>{s==="quick"&&(R(1),w(0))},[m,s]),f.useEffect(()=>{e&&s==="quick"&&(he(),Y())},[e,s,j,m,he,Y]);const ne=f.useCallback(n=>n?m==="unchecked"?{left:!0,right:!0}:m==="passed"?{left:!0,right:!1}:m==="rejected"?{left:!1,right:!0}:n.checked?n.rejected?{left:!1,right:!0}:{left:!0,right:!1}:{left:!0,right:!0}:{left:!1,right:!1},[m]),_e=f.useCallback(async n=>{const h=x[g];if(!h||E.current)return;const _=ne(h);if(!(n&&!_.left||!n&&!_.right)){E.current=!0,A.current=n?"left":"right",F.start({x:n?-400:400,rotate:n?-20:20,opacity:0});try{const P=await Ot([{id:h.id,rejected:n,require_unchecked:m==="unchecked"}]);if(!P.success){z({title:"操作失败",description:P.error,variant:"destructive"});return}P.data.results[0]?.success?(z({title:n?"已拒绝":"已通过",description:`表达方式 #${h.id} ${n?"已拒绝":"已通过"}`}),setTimeout(()=>{p($=>$.filter((ke,J)=>J!==g)),S($=>$-1),g>=x.length-1&&w(Math.max(0,g-1)),A.current=null,T.current=0,F.set({x:0,opacity:1,rotate:0}),E.current=!1,Y(),x.length<=1&&v>1&&he(!1)},300)):(L(h.id),z({title:"数据冲突",description:"该条目已被后台任务处理,正在刷新数据...",variant:"destructive"}),setTimeout(()=>{L(null),A.current=null,T.current=0,F.set({x:0,opacity:1,rotate:0}),E.current=!1,he(!1),Y()},1500))}catch(P){z({title:"操作失败",description:P instanceof Error?P.message:"未知错误",variant:"destructive"}),A.current=null,T.current=0,F.set({x:0,opacity:1,rotate:0}),E.current=!1}}},[x,g,E,ne,m,z,Y,v,he]),ct=f.useCallback((n,h)=>{E.current||(W.current={x:n,y:h},Ce.current=!1)},[E]),Ct=f.useCallback(n=>{E.current||(E.current=!0,F.start({x:n==="left"?-30:30,immediate:!0}),setTimeout(()=>{F.start({x:0}),setTimeout(()=>{E.current=!1},300)},150))},[F]),ot=f.useCallback(n=>{if(!W.current||E.current)return;const h=n-W.current.x,_=x[g],P=ne(_);if(h<0&&!P.left){F.start({x:h*.2,immediate:!0}),T.current=h*.2,A.current=null;return}if(h>0&&!P.right){F.start({x:h*.2,immediate:!0}),T.current=h*.2,A.current=null;return}Ce.current=!0,T.current=h,F.start({x:h,rotate:h*.05,opacity:Math.max(0,1-Math.abs(h)/500),immediate:!0}),F.start({x:h,rotate:h*.05,opacity:Math.max(0,1-Math.abs(h)/500),immediate:!0}),Math.abs(h)>50?A.current=h>0?"right":"left":A.current=null},[x,g,ne,F]),Ae=f.useCallback(()=>{if(!W.current)return;const n=100,h=V.x.get();Math.abs(h)>n&&A.current?_e(A.current==="left"):(F.start({x:0,rotate:0,opacity:1}),T.current=0,A.current=null),W.current=null,Ce.current=!1},[V.x,_e,F]),Fr=f.useCallback(n=>{ct(n.clientX,n.clientY)},[ct]),Vr=f.useCallback(n=>{W.current&&(n.preventDefault(),ot(n.clientX))},[ot]),Dr=f.useCallback(()=>{Ae()},[Ae]),$r=f.useCallback(()=>{W.current&&Ae()},[Ae]),qr=f.useCallback(n=>{const h=n.touches[0];ct(h.clientX,h.clientY)},[ct]),Mr=f.useCallback(n=>{const h=n.touches[0];ot(h.clientX)},[ot]),Or=f.useCallback(()=>{Ae()},[Ae]);f.useEffect(()=>{if(!e||s!=="quick")return;const n=h=>{if(!["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].includes(h.key)||(h.preventDefault(),h.stopPropagation(),h.stopImmediatePropagation(),E.current||b))return;const _=x[g],P=ne(_);h.key==="ArrowLeft"?P.left?_e(!0):Ct("left"):h.key==="ArrowRight"?P.right?_e(!1):Ct("right"):h.key==="ArrowDown"?g<x.length-1&&w($=>$+1):h.key==="ArrowUp"&&g>0&&w($=>$-1)};return window.addEventListener("keydown",n,!0),()=>window.removeEventListener("keydown",n,!0)},[e,s,x,g,E,b,ne,_e,Ct]),f.useEffect(()=>{if(!e||s!=="quick"||b)return;const n=x.length-g-1,h=x.length<v;n<=5&&h&&he(!1,!0)},[e,s,g,x.length,v,b,he]),f.useEffect(()=>{e&&(Y(),$e(),vs())},[e,Y,$e,vs]),f.useEffect(()=>{we(1),Ne(new Set)},[Q,Pt]),f.useEffect(()=>{Ne(new Set)},[o]);const ys=()=>{Er(gs),we(1)},Re=n=>n.chat_name||Ir.get(n.chat_id)||n.chat_id,fe=async(n,h)=>{try{ps(P=>new Set(P).add(n));const _=await Ot([{id:n,rejected:h,require_unchecked:Q==="unchecked"}]);if(!_.success){z({title:"操作失败",description:_.error,variant:"destructive"});return}_.data.results[0]?.success?(z({title:h?"已拒绝":"已通过",description:`表达方式 #${n} ${h?"已拒绝":"已通过"}`}),$e(),Y()):z({title:"操作失败",description:_.data.results[0]?.message||"未知错误",variant:"destructive"})}catch(_){z({title:"操作失败",description:_ instanceof Error?_.message:"未知错误",variant:"destructive"})}finally{ps(_=>{const P=new Set(_);return P.delete(n),P})}},Ee=async n=>{if(D.size===0){z({title:"请选择",description:"请先选择要审核的表达方式",variant:"destructive"});return}try{at(!0);const h=Array.from(D).map(P=>({id:P,rejected:n,require_unchecked:Q==="unchecked"})),_=await Ot(h);if(!_.success){z({title:"批量审核失败",description:_.error,variant:"destructive"});return}z({title:"批量审核完成",description:`成功 ${_.data.succeeded} 条,失败 ${_.data.failed} 条`,variant:_.data.failed>0?"destructive":"default"}),Ne(new Set),$e(),Y()}catch(h){z({title:"批量审核失败",description:h instanceof Error?h.message:"未知错误",variant:"destructive"})}finally{at(!1)}},Lr=()=>{D.size===o.length?Ne(new Set):Ne(new Set(o.map(n=>n.id)))},Ur=n=>{Ne(h=>{const _=new Set(h);return _.has(n)?_.delete(n):_.add(n),_})},At=n=>n?new Date(n*1e3).toLocaleString("zh-CN",{month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"}):"-",Rt=n=>n.checked?n.rejected?r.jsxs(pe,{variant:"destructive",className:"gap-1",children:[r.jsx(X,{className:"h-3 w-3"}),"已拒绝"]}):r.jsxs(pe,{variant:"default",className:"gap-1 bg-green-600",children:[r.jsx(M,{className:"h-3 w-3"}),"已通过"]}):r.jsxs(pe,{variant:"outline",className:"gap-1",children:[r.jsx(It,{className:"h-3 w-3"}),"待审核"]}),Et=n=>n?n==="ai"?r.jsxs(pe,{variant:"secondary",className:"gap-1 text-xs",children:[r.jsx(ba,{className:"h-3 w-3"}),"AI"]}):r.jsxs(pe,{variant:"secondary",className:"gap-1 text-xs",children:[r.jsx(zt,{className:"h-3 w-3"}),"人工"]}):null,ie=Math.ceil(fs/it),Qr=()=>{const n=[];if(ie<=7)for(let h=1;h<=ie;h++)n.push(h);else{n.push(1),re>3&&n.push("ellipsis");const h=Math.max(2,re-1),_=Math.min(ie-1,re+1);for(let P=h;P<=_;P++)n.push(P);re<ie-2&&n.push("ellipsis"),ie>1&&n.push(ie)}return n},bs=()=>{const n=parseInt(ms,10);!isNaN(n)&&n>=1&&n<=ie&&(we(n),xs(""))};return r.jsx(Zr,{open:e,onOpenChange:t,children:r.jsxs(ea,{className:"max-w-5xl w-[95vw] sm:w-full h-[90vh] sm:h-[85vh] flex flex-col p-0",hideCloseButton:!0,children:[r.jsxs("div",{className:"flex items-end bg-muted/30 px-2 pt-2 shrink-0",children:[r.jsxs("button",{onClick:()=>a("list"),className:B("group relative flex items-center gap-2 px-4 py-2 text-sm font-medium rounded-t-lg transition-all","hover:bg-background/50",s==="list"?"bg-background text-foreground shadow-sm border border-b-0 border-border":"text-muted-foreground hover:text-foreground"),children:[r.jsx(fa,{className:"h-4 w-4"}),r.jsx("span",{children:"列表模式"}),s==="list"&&r.jsx("span",{className:"absolute bottom-0 left-0 right-0 h-[2px] bg-background"})]}),r.jsxs("button",{onClick:()=>a("quick"),className:B("group relative flex items-center gap-2 px-4 py-2 text-sm font-medium rounded-t-lg transition-all","hover:bg-background/50",s==="quick"?"bg-background text-foreground shadow-sm border border-b-0 border-border":"text-muted-foreground hover:text-foreground"),children:[r.jsx(ma,{className:"h-4 w-4"}),r.jsx("span",{children:"快速审核"}),r.jsx(pe,{variant:"secondary",className:"ml-1 h-5 px-1.5 text-xs",children:"新"}),s==="quick"&&r.jsx("span",{className:"absolute bottom-0 left-0 right-0 h-[2px] bg-background"})]}),r.jsx("div",{className:"flex-1 border-b border-border"}),r.jsx("button",{onClick:()=>t(!1),className:"mb-[1px] p-2 text-muted-foreground hover:text-foreground hover:bg-muted rounded-lg transition-colors",children:r.jsx(xa,{className:"h-4 w-4"})})]}),s==="list"&&r.jsxs(r.Fragment,{children:[r.jsxs(ta,{className:"px-4 sm:px-6 pt-4 sm:pt-6 pb-4 border-b shrink-0",children:[r.jsx(sa,{className:"text-lg sm:text-xl",children:"表达方式审核"}),r.jsx(ra,{className:"text-xs sm:text-sm",children:"审核麦麦学习到的表达方式。通过审核的项目才会被使用(可在配置中调整),被拒绝的项目永远不会被使用。"}),r.jsxs("div",{className:"grid grid-cols-2 sm:grid-cols-4 gap-2 sm:gap-3 mt-4",children:[r.jsxs("div",{className:"rounded-lg border p-2 sm:p-3 text-center",children:[r.jsx("div",{className:"text-xl sm:text-2xl font-bold text-orange-500",children:nt?"-":i?.unchecked??0}),r.jsx("div",{className:"text-xs text-muted-foreground",children:"待审核"})]}),r.jsxs("div",{className:"rounded-lg border p-2 sm:p-3 text-center",children:[r.jsx("div",{className:"text-xl sm:text-2xl font-bold text-green-500",children:nt?"-":i?.passed??0}),r.jsx("div",{className:"text-xs text-muted-foreground",children:"已通过"})]}),r.jsxs("div",{className:"rounded-lg border p-2 sm:p-3 text-center",children:[r.jsx("div",{className:"text-xl sm:text-2xl font-bold text-red-500",children:nt?"-":i?.rejected??0}),r.jsx("div",{className:"text-xs text-muted-foreground",children:"已拒绝"})]}),r.jsxs("div",{className:"rounded-lg border p-2 sm:p-3 text-center",children:[r.jsx("div",{className:"text-xl sm:text-2xl font-bold text-blue-500",children:nt?"-":i?.total??0}),r.jsx("div",{className:"text-xs text-muted-foreground",children:"总计"})]})]})]}),r.jsxs("div",{className:"px-4 sm:px-6 py-3 border-b shrink-0 space-y-3",children:[r.jsx(js,{value:Q,onValueChange:n=>Rr(n),className:"w-full",children:r.jsxs(ws,{className:"grid w-full grid-cols-4",children:[r.jsxs(ge,{value:"unchecked",className:"gap-1 text-xs sm:text-sm px-1 sm:px-3",children:[r.jsx(It,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"待审核"}),r.jsx("span",{className:"sm:hidden",children:"待审"}),r.jsxs("span",{className:"hidden sm:inline",children:["(",i?.unchecked??0,")"]})]}),r.jsxs(ge,{value:"passed",className:"gap-1 text-xs sm:text-sm px-1 sm:px-3",children:[r.jsx(M,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"已通过"}),r.jsx("span",{className:"sm:hidden",children:"通过"}),r.jsxs("span",{className:"hidden sm:inline",children:["(",i?.passed??0,")"]})]}),r.jsxs(ge,{value:"rejected",className:"gap-1 text-xs sm:text-sm px-1 sm:px-3",children:[r.jsx(X,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"已拒绝"}),r.jsx("span",{className:"sm:hidden",children:"拒绝"}),r.jsxs("span",{className:"hidden sm:inline",children:["(",i?.rejected??0,")"]})]}),r.jsxs(ge,{value:"all",className:"gap-1 text-xs sm:text-sm px-1 sm:px-3",children:[r.jsx("span",{children:"全部"}),r.jsxs("span",{className:"hidden sm:inline",children:["(",i?.total??0,")"]})]})]})}),r.jsxs("div",{className:"flex flex-col sm:flex-row items-stretch sm:items-center gap-2",children:[r.jsxs("div",{className:"relative flex-1",children:[r.jsx(ks,{className:"absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground"}),r.jsx(Ns,{placeholder:"搜索情景或风格...",value:gs,onChange:n=>Tr(n.target.value),onKeyDown:n=>n.key==="Enter"&&ys(),className:"pl-9"})]}),r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx(I,{variant:"outline",size:"icon",onClick:ys,children:r.jsx(ks,{className:"h-4 w-4"})}),r.jsx(I,{variant:"outline",size:"icon",onClick:()=>{$e(),Y()},disabled:U,children:r.jsx(qe,{className:B("h-4 w-4",U&&"animate-spin")})})]}),D.size>0&&r.jsx("div",{className:"flex items-center gap-2 w-full sm:w-auto",children:Q==="unchecked"?r.jsxs(r.Fragment,{children:[r.jsxs(I,{variant:"default",size:"sm",className:"bg-green-600 hover:bg-green-700 flex-1 sm:flex-none",onClick:()=>Ee(!1),disabled:U,children:[r.jsx(M,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量通过"}),r.jsx("span",{className:"sm:hidden",children:"通过"}),"(",D.size,")"]}),r.jsxs(I,{variant:"destructive",size:"sm",className:"flex-1 sm:flex-none",onClick:()=>Ee(!0),disabled:U,children:[r.jsx(X,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量拒绝"}),r.jsx("span",{className:"sm:hidden",children:"拒绝"}),"(",D.size,")"]})]}):Q==="passed"?r.jsxs(I,{variant:"destructive",size:"sm",className:"flex-1 sm:flex-none",onClick:()=>Ee(!0),disabled:U,children:[r.jsx(X,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量改为拒绝"}),r.jsx("span",{className:"sm:hidden",children:"改为拒绝"}),"(",D.size,")"]}):Q==="rejected"?r.jsxs(I,{variant:"default",size:"sm",className:"bg-green-600 hover:bg-green-700 flex-1 sm:flex-none",onClick:()=>Ee(!1),disabled:U,children:[r.jsx(M,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量改为通过"}),r.jsx("span",{className:"sm:hidden",children:"改为通过"}),"(",D.size,")"]}):r.jsxs(r.Fragment,{children:[r.jsxs(I,{variant:"default",size:"sm",className:"bg-green-600 hover:bg-green-700 flex-1 sm:flex-none",onClick:()=>Ee(!1),disabled:U,children:[r.jsx(M,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量通过"}),r.jsx("span",{className:"sm:hidden",children:"通过"}),"(",D.size,")"]}),r.jsxs(I,{variant:"destructive",size:"sm",className:"flex-1 sm:flex-none",onClick:()=>Ee(!0),disabled:U,children:[r.jsx(X,{className:"h-4 w-4 mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"批量拒绝"}),r.jsx("span",{className:"sm:hidden",children:"拒绝"}),"(",D.size,")"]})]})})]})]}),r.jsx(aa,{className:"flex-1 px-4 sm:px-6",children:U&&o.length===0?r.jsx("div",{className:"flex items-center justify-center h-40",children:r.jsx(qe,{className:"h-6 w-6 animate-spin text-muted-foreground"})}):o.length===0?r.jsxs("div",{className:"flex flex-col items-center justify-center h-40 text-muted-foreground",children:[r.jsx(ga,{className:"h-8 w-8 mb-2"}),r.jsx("p",{children:"没有找到表达方式"})]}):r.jsxs("div",{className:"space-y-2 py-2",children:[o.length>0&&r.jsxs("div",{className:"flex items-center justify-between py-2 px-3 rounded-lg bg-muted/50",children:[r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx(_s,{checked:D.size===o.length&&o.length>0,onCheckedChange:Lr}),r.jsx("span",{className:"text-sm text-muted-foreground",children:D.size===o.length&&o.length>0?`已全选当前页 (${o.length} 条)`:`全选当前页 (${o.length} 条)`})]}),D.size>0&&r.jsx(I,{variant:"ghost",size:"sm",onClick:()=>Ne(new Set),className:"h-7 text-xs",children:"取消选择"})]}),o.map(n=>r.jsx("div",{className:B("rounded-lg border p-3 sm:p-4 space-y-2 sm:space-y-3 transition-colors",D.has(n.id)&&"bg-accent border-primary",ae.has(n.id)&&"opacity-50"),children:r.jsxs("div",{className:"flex items-start gap-2 sm:gap-3",children:[r.jsx(_s,{checked:D.has(n.id),onCheckedChange:()=>Ur(n.id),disabled:ae.has(n.id),className:"mt-1"}),r.jsxs("div",{className:"flex-1 min-w-0 space-y-2",children:[r.jsxs("div",{children:[r.jsx("span",{className:"text-xs text-muted-foreground",children:"情景:"}),r.jsx("p",{className:"text-sm font-medium break-words",children:n.situation})]}),r.jsxs("div",{children:[r.jsx("span",{className:"text-xs text-muted-foreground",children:"风格:"}),r.jsx("p",{className:"text-sm text-muted-foreground break-words",children:n.style})]}),r.jsxs("div",{className:"flex flex-wrap items-center gap-1 sm:gap-2 text-xs text-muted-foreground",children:[r.jsxs("span",{children:["#",n.id]}),r.jsx("span",{children:"·"}),r.jsx("span",{title:Re(n),className:"truncate max-w-24 sm:max-w-32",children:Re(n)}),r.jsx("span",{children:"·"}),r.jsx("span",{children:At(n.create_date)}),r.jsxs("div",{className:"flex items-center gap-1",children:[Rt(n),Et(n.modified_by)]})]})]}),r.jsx("div",{className:"flex flex-col gap-1 sm:gap-2 shrink-0",children:Q==="unchecked"?r.jsxs(r.Fragment,{children:[r.jsxs(I,{size:"sm",variant:"outline",className:"text-green-600 hover:text-green-700 hover:bg-green-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!1),disabled:ae.has(n.id),children:[r.jsx(M,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"通过"})]}),r.jsxs(I,{size:"sm",variant:"outline",className:"text-red-600 hover:text-red-700 hover:bg-red-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!0),disabled:ae.has(n.id),children:[r.jsx(X,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"拒绝"})]})]}):Q==="passed"?r.jsxs(I,{size:"sm",variant:"outline",className:"text-red-600 hover:text-red-700 hover:bg-red-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!0),disabled:ae.has(n.id),children:[r.jsx(X,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"改为拒绝"})]}):Q==="rejected"?r.jsxs(I,{size:"sm",variant:"outline",className:"text-green-600 hover:text-green-700 hover:bg-green-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!1),disabled:ae.has(n.id),children:[r.jsx(M,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"改为通过"})]}):r.jsx(r.Fragment,{children:n.rejected?r.jsxs(I,{size:"sm",variant:"outline",className:"text-green-600 hover:text-green-700 hover:bg-green-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!1),disabled:ae.has(n.id),children:[r.jsx(M,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"改为通过"})]}):n.checked?r.jsxs(I,{size:"sm",variant:"outline",className:"text-red-600 hover:text-red-700 hover:bg-red-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!0),disabled:ae.has(n.id),children:[r.jsx(X,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"改为拒绝"})]}):r.jsxs(r.Fragment,{children:[r.jsxs(I,{size:"sm",variant:"outline",className:"text-green-600 hover:text-green-700 hover:bg-green-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!1),disabled:ae.has(n.id),children:[r.jsx(M,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"通过"})]}),r.jsxs(I,{size:"sm",variant:"outline",className:"text-red-600 hover:text-red-700 hover:bg-red-50 h-8 sm:h-9 px-2 sm:px-3",onClick:()=>fe(n.id,!0),disabled:ae.has(n.id),children:[r.jsx(X,{className:"h-4 w-4 sm:mr-1"}),r.jsx("span",{className:"hidden sm:inline",children:"拒绝"})]})]})})})]})},n.id))]})}),r.jsxs("div",{className:"px-4 sm:px-6 py-3 border-t shrink-0 flex flex-col sm:flex-row items-center justify-between gap-3",children:[r.jsxs("div",{className:"flex items-center gap-2 text-sm text-muted-foreground",children:[r.jsx("span",{className:"hidden sm:inline",children:"每页"}),r.jsxs(na,{value:it.toString(),onValueChange:n=>{Ar(parseInt(n,10)),we(1)},children:[r.jsx(ia,{className:"w-[70px] h-8",children:r.jsx(ca,{})}),r.jsxs(oa,{children:[r.jsx(ut,{value:"10",children:"10"}),r.jsx(ut,{value:"20",children:"20"}),r.jsx(ut,{value:"50",children:"50"}),r.jsx(ut,{value:"100",children:"100"})]})]}),r.jsx("span",{className:"hidden sm:inline",children:"条"}),r.jsxs("span",{className:"text-muted-foreground",children:["共 ",fs," 条"]})]}),r.jsx(la,{className:"mx-0 w-auto",children:r.jsxs(da,{children:[r.jsx(Tt,{children:r.jsx(I,{variant:"ghost",size:"icon",className:"h-8 w-8",onClick:()=>we(n=>Math.max(1,n-1)),disabled:re<=1||U,children:r.jsx(pa,{className:"h-4 w-4"})})}),Qr().map((n,h)=>r.jsx(Tt,{children:n==="ellipsis"?r.jsx(ua,{}):r.jsx(ha,{href:"#",isActive:n===re,onClick:_=>{_.preventDefault(),we(n)},className:"h-8 w-8 cursor-pointer",children:n})},h)),r.jsx(Tt,{children:r.jsx(I,{variant:"ghost",size:"icon",className:"h-8 w-8",onClick:()=>we(n=>Math.min(ie,n+1)),disabled:re>=ie||U,children:r.jsx(va,{className:"h-4 w-4"})})})]})}),r.jsxs("div",{className:"hidden sm:flex items-center gap-2 text-sm",children:[r.jsx("span",{className:"text-muted-foreground",children:"跳至"}),r.jsx(Ns,{type:"number",min:1,max:ie,value:ms,onChange:n=>xs(n.target.value),onKeyDown:n=>n.key==="Enter"&&bs(),className:"w-16 h-8 text-center",placeholder:re.toString()}),r.jsx("span",{className:"text-muted-foreground",children:"页"}),r.jsx(I,{variant:"outline",size:"sm",className:"h-8",onClick:bs,disabled:U,children:"跳转"})]})]})]}),s==="quick"&&r.jsxs("div",{className:"flex-1 flex flex-col overflow-hidden",children:[r.jsxs("div",{className:"px-4 sm:px-6 py-3 border-b shrink-0 space-y-3",children:[r.jsxs("div",{className:"flex items-center justify-between text-sm",children:[r.jsxs("div",{className:"flex items-center gap-4",children:[r.jsxs("span",{className:"text-muted-foreground",children:["待审核: ",r.jsx("span",{className:"font-medium text-orange-500",children:i?.unchecked??0})]}),r.jsxs("span",{className:"text-muted-foreground",children:["已通过: ",r.jsx("span",{className:"font-medium text-green-500",children:i?.passed??0})]}),r.jsxs("span",{className:"text-muted-foreground",children:["已拒绝: ",r.jsx("span",{className:"font-medium text-red-500",children:i?.rejected??0})]})]}),r.jsxs(I,{variant:"outline",size:"sm",onClick:()=>{he(),Y()},disabled:b,children:[r.jsx(qe,{className:B("h-4 w-4 mr-1",b&&"animate-spin")}),"刷新"]})]}),r.jsx(js,{value:m,onValueChange:n=>u(n),className:"w-full",children:r.jsxs(ws,{className:"grid w-full grid-cols-4",children:[r.jsxs(ge,{value:"unchecked",className:"gap-1 text-xs sm:text-sm",children:[r.jsx(It,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"待审核"}),r.jsx("span",{className:"sm:hidden",children:"待审"})]}),r.jsxs(ge,{value:"passed",className:"gap-1 text-xs sm:text-sm",children:[r.jsx(M,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"已通过"}),r.jsx("span",{className:"sm:hidden",children:"通过"})]}),r.jsxs(ge,{value:"rejected",className:"gap-1 text-xs sm:text-sm",children:[r.jsx(X,{className:"h-3 w-3 sm:h-4 sm:w-4"}),r.jsx("span",{className:"hidden sm:inline",children:"已拒绝"}),r.jsx("span",{className:"sm:hidden",children:"拒绝"})]}),r.jsx(ge,{value:"all",className:"gap-1 text-xs sm:text-sm",children:"全部"})]})})]}),r.jsx("div",{className:"flex-1 flex flex-col items-center justify-center p-4 sm:p-8 relative overflow-hidden",children:b&&x.length===0?r.jsxs("div",{className:"flex flex-col items-center justify-center",children:[r.jsx(qe,{className:"h-8 w-8 animate-spin text-muted-foreground mb-4"}),r.jsx("p",{className:"text-muted-foreground",children:"加载中..."})]}):x.length===0?r.jsxs("div",{className:"flex flex-col items-center justify-center text-center",children:[r.jsx("div",{className:"w-20 h-20 rounded-full bg-muted/50 flex items-center justify-center mb-6",children:r.jsx(M,{className:"h-10 w-10 text-green-500"})}),r.jsx("h3",{className:"text-xl font-semibold mb-2",children:"全部审核完成!"}),r.jsx("p",{className:"text-muted-foreground",children:"当前筛选条件下没有待处理的项目"})]}):r.jsxs(r.Fragment,{children:[r.jsxs("div",{className:"absolute top-4 left-1/2 -translate-x-1/2 text-sm text-muted-foreground z-50",children:[g+1," / ",x.length,v>x.length&&r.jsxs("span",{className:"ml-1",children:["(共 ",v," 条)"]})]}),r.jsx("div",{className:"absolute inset-x-4 top-1/2 -translate-y-1/2 flex justify-between pointer-events-none z-40",children:(()=>{const n=x[g],h=ne(n);return r.jsxs(r.Fragment,{children:[r.jsxs("div",{className:B("flex items-center gap-2 px-4 py-2 rounded-lg transition-all duration-300",A.current==="left"?"bg-red-500/20 text-red-500 scale-110":"bg-muted/50 text-muted-foreground opacity-0",!h.left&&"invisible"),children:[r.jsx(X,{className:"h-8 w-8"}),r.jsx("span",{className:"font-bold text-lg hidden sm:inline",children:"拒绝"})]}),r.jsxs("div",{className:B("flex items-center gap-2 px-4 py-2 rounded-lg transition-all duration-300",A.current==="right"?"bg-green-500/20 text-green-500 scale-110":"bg-muted/50 text-muted-foreground opacity-0",!h.right&&"invisible"),children:[r.jsx("span",{className:"font-bold text-lg hidden sm:inline",children:"通过"}),r.jsx(M,{className:"h-8 w-8"})]})]})})()}),r.jsx("div",{className:"relative w-full max-w-md h-[400px] flex items-center justify-center",role:"listbox",tabIndex:0,"aria-label":"待审核的表达方式","aria-activedescendant":x[g]?`quick-expr-${x[g].id}`:void 0,children:x.slice(g,g+5).reverse().map((n,h,_)=>{const P=_.length-1-h,$=P===0;let ke={zIndex:5-P,position:"absolute",width:"100%",transition:$&&!Ce.current?"all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1)":"none"};if($)ke={...ke,cursor:"grab"};else{const J=Math.min(Math.abs(T.current)/200,1),Te=xe=>{const Wr=xe*7%5,Yr=xe*13%7;return{scale:1-xe*.05,translateY:xe*12,rotate:(xe%2===0?1:-1)*(xe*2)+Wr,translateX:(xe%2===0?-1:1)*(xe*4)+Yr}},me=Te(P),lt=Te(P-1),Br=me.scale+(lt.scale-me.scale)*J,Xr=me.translateY+(lt.translateY-me.translateY)*J,Gr=me.rotate+(lt.rotate-me.rotate)*J,Hr=me.translateX+(lt.translateX-me.translateX)*J;ke={...ke,transform:`translate3d(${Hr}px, ${Xr}px, 0) scale(${Br}) rotate(${Gr}deg)`,opacity:1-P*.15,filter:`blur(${Math.max(0,P*1-J)}px)`,pointerEvents:"none"}}return $?r.jsxs(Bn,{ref:ue,role:"option",id:`quick-expr-${n.id}`,"aria-selected":!0,className:B("bg-card border rounded-xl shadow-xl p-6 select-none h-full flex flex-col","active:cursor-grabbing shadow-2xl ring-1 ring-border/50",de===n.id&&"ring-4 ring-orange-500/50 bg-orange-50/10"),style:{...ke,...V},onMouseDown:Fr,onMouseMove:Vr,onMouseUp:Dr,onMouseLeave:$r,onTouchStart:qr,onTouchMove:Mr,onTouchEnd:Or,children:[de===n.id&&r.jsxs("div",{className:"absolute inset-0 z-50 flex flex-col items-center justify-center bg-background/80 backdrop-blur-sm animate-in fade-in duration-300 rounded-xl",children:[r.jsxs("div",{className:"relative",children:[r.jsx("div",{className:"absolute inset-0 bg-orange-500/20 rounded-full animate-ping"}),r.jsx(qe,{className:"relative h-16 w-16 text-orange-500 mb-4 animate-spin duration-1000"})]}),r.jsx("h3",{className:"text-xl font-bold text-foreground animate-in slide-in-from-bottom-2 fade-in duration-500",children:"数据已更新"}),r.jsx("p",{className:"text-muted-foreground mt-2 animate-in slide-in-from-bottom-3 fade-in duration-700",children:"后台任务已处理此条目"})]}),r.jsx("div",{className:B("absolute inset-0 flex items-center justify-center z-20 pointer-events-none transition-opacity duration-200",T.current<-10&&!ne(n).left||T.current>10&&!ne(n).right?"opacity-100":"opacity-0"),children:r.jsx("div",{className:"bg-background/80 backdrop-blur-sm p-4 rounded-full shadow-lg border border-border",children:r.jsx(ya,{className:"h-12 w-12 text-muted-foreground"})})}),r.jsxs("div",{className:"space-y-4 flex-1",children:[r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsxs("span",{className:"text-sm text-muted-foreground font-mono",children:["#",n.id]}),r.jsxs("div",{className:"flex items-center gap-2",children:[Rt(n),Et(n.modified_by)]})]}),r.jsxs("div",{className:"space-y-1.5",children:[r.jsx("div",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wider",children:"情景"}),r.jsx("div",{className:"p-3 bg-muted/30 rounded-lg border border-border/50",children:r.jsx("p",{className:"text-lg font-medium leading-relaxed",children:n.situation})})]}),r.jsxs("div",{className:"space-y-1.5",children:[r.jsx("div",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wider",children:"风格"}),r.jsx("div",{className:"flex flex-wrap gap-2",children:n.style.split(/[,,]/).map((J,Te)=>r.jsx(pe,{variant:"secondary",className:"font-normal",children:J.trim()},Te))})]})]}),r.jsxs("div",{className:"mt-auto pt-4 border-t flex items-center justify-between text-xs text-muted-foreground",children:[r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("div",{className:"w-6 h-6 rounded-full bg-primary/10 flex items-center justify-center text-primary",children:r.jsx(zt,{className:"h-3 w-3"})}),r.jsx("span",{title:Re(n),className:"truncate max-w-[120px] font-medium",children:Re(n)})]}),r.jsx("span",{className:"font-mono",children:At(n.create_date)})]})]},n.id):r.jsxs("div",{role:"option",id:`quick-expr-${n.id}`,"aria-selected":!1,className:B("bg-card border rounded-xl shadow-xl p-6 select-none h-full flex flex-col"),style:ke,children:[r.jsxs("div",{className:"space-y-4 flex-1",children:[r.jsxs("div",{className:"flex items-center justify-between",children:[r.jsxs("span",{className:"text-sm text-muted-foreground font-mono",children:["#",n.id]}),r.jsxs("div",{className:"flex items-center gap-2",children:[Rt(n),Et(n.modified_by)]})]}),r.jsxs("div",{className:"space-y-1.5",children:[r.jsx("div",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wider",children:"情景"}),r.jsx("div",{className:"p-3 bg-muted/30 rounded-lg border border-border/50",children:r.jsx("p",{className:"text-lg font-medium leading-relaxed",children:n.situation})})]}),r.jsxs("div",{className:"space-y-1.5",children:[r.jsx("div",{className:"text-xs font-semibold text-muted-foreground uppercase tracking-wider",children:"风格"}),r.jsx("div",{className:"flex flex-wrap gap-2",children:n.style.split(/[,,]/).map((J,Te)=>r.jsx(pe,{variant:"secondary",className:"font-normal",children:J.trim()},Te))})]})]}),r.jsxs("div",{className:"mt-auto pt-4 border-t flex items-center justify-between text-xs text-muted-foreground",children:[r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("div",{className:"w-6 h-6 rounded-full bg-primary/10 flex items-center justify-center text-primary",children:r.jsx(zt,{className:"h-3 w-3"})}),r.jsx("span",{title:Re(n),className:"truncate max-w-[120px] font-medium",children:Re(n)})]}),r.jsx("span",{className:"font-mono",children:At(n.create_date)})]})]},n.id)})}),r.jsx("div",{className:"flex items-center gap-8 mt-8 sm:hidden z-50",children:(()=>{const n=x[g],h=ne(n);return r.jsxs(r.Fragment,{children:[r.jsx(I,{variant:"outline",size:"lg",className:B("w-16 h-16 rounded-full border-2 shadow-lg transition-all active:scale-95",h.left?"hover:bg-red-50 hover:text-red-600 hover:border-red-200":"opacity-30 cursor-not-allowed"),onClick:()=>h.left&&_e(!0),disabled:!h.left||E.current,children:r.jsx(X,{className:"h-8 w-8"})}),r.jsx(I,{variant:"outline",size:"lg",className:B("w-16 h-16 rounded-full border-2 shadow-lg transition-all active:scale-95",h.right?"hover:bg-green-50 hover:text-green-600 hover:border-green-200":"opacity-30 cursor-not-allowed"),onClick:()=>h.right&&_e(!1),disabled:!h.right||E.current,children:r.jsx(M,{className:"h-8 w-8"})})]})})()})]})}),r.jsxs("div",{className:"hidden sm:flex items-center justify-center gap-6 px-6 py-3 border-t text-xs text-muted-foreground",children:[r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx(dt,{size:"sm",keys:["left"]}),r.jsx("span",{children:"拒绝"})]}),r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx(dt,{size:"sm",keys:["right"]}),r.jsx("span",{children:"通过"})]}),r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx(dt,{size:"sm",keys:["up"]}),r.jsx("span",{children:"上一条"})]}),r.jsxs("div",{className:"flex items-center gap-1",children:[r.jsx(dt,{size:"sm",keys:["down"]}),r.jsx("span",{children:"下一条"})]}),r.jsx("span",{className:"text-muted-foreground/50",children:"|"}),r.jsx("span",{children:"拖拽卡片滑动审核"})]})]})]})})}export{ii as E,Ln as a,si as b,ti as c,Zn as d,ni as e,Un as f,Qn as g,ei as h,ri as i,ai as j,Cn as u};
|