import{i as e}from"./chunk-B3pr0VN8.js";import{n as t,t as n}from"./jsx-runtime-wTfS3W87.js";import{t as r}from"./chevron-down-B0T6sOHE.js";import{t as i}from"./chevron-up-D6LLrYny.js";var a=e(t(),1),o=n();function s({title:e,hint:t}){return(0,o.jsxs)(`div`,{className:`mb-4`,children:[(0,o.jsx)(`h1`,{className:`text-[18px] font-semibold`,style:{color:`var(--text-1)`},children:e}),t?(0,o.jsx)(`div`,{className:`mt-1 text-[12px]`,style:{color:`var(--text-3)`},children:t}):null]})}function c({title:e,hint:t,right:n,extra:r}){return(0,o.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,o.jsxs)(`div`,{children:[(0,o.jsx)(`h2`,{className:`text-[15px] font-semibold`,style:{color:`var(--text-1)`},children:e}),t?(0,o.jsx)(`div`,{className:`mt-1 text-[11px] leading-5`,style:{color:`var(--text-3)`},children:t}):null]}),n||r?(0,o.jsx)(`div`,{children:n||r}):null]})}function l({title:e,hint:t,right:n,children:s,defaultOpen:c=!1}){let[l,u]=(0,a.useState)(c),d=l?i:r;return(0,o.jsxs)(`div`,{className:`ui-card ui-card-p`,children:[(0,o.jsxs)(`div`,{className:`flex items-start justify-between gap-3`,children:[(0,o.jsxs)(`div`,{className:`min-w-0`,children:[(0,o.jsx)(`h2`,{className:`text-[15px] font-semibold`,style:{color:`var(--text-1)`},children:e}),t?(0,o.jsx)(`div`,{className:`mt-1 text-[11px] leading-5`,style:{color:`var(--text-3)`},children:t}):null]}),(0,o.jsxs)(`span`,{className:`flex shrink-0 items-center gap-2`,children:[n,(0,o.jsx)(`button`,{type:`button`,className:`inline-flex h-7 w-7 items-center justify-center rounded-ds-pill border ds-focus-ring`,style:{borderColor:`var(--ds-border-default)`,background:`var(--ds-bg-subtle)`,color:`var(--ds-text-secondary)`},"aria-label":l?`收起${e}`:`展开${e}`,"aria-expanded":l,onClick:()=>u(e=>!e),children:(0,o.jsx)(d,{size:14})})]})]}),l?(0,o.jsx)(`div`,{className:`mt-4`,children:s}):null]})}function u({children:e}){return(0,o.jsx)(`div`,{className:`grid gap-3 md:grid-cols-3`,children:e})}function d({label:e,value:t,detail:n,accent:r}){return(0,o.jsxs)(`div`,{className:`rounded-ds-lg border px-4 py-4`,style:{borderColor:r?`color-mix(in srgb, var(--ds-ochre) 28%, var(--ds-border-default))`:`var(--ds-border-default)`,background:r?`color-mix(in srgb, var(--ds-ochre) 8%, var(--ds-bg-surface))`:`var(--ds-bg-surface)`},children:[(0,o.jsx)(`div`,{className:`text-[11px]`,style:{color:`var(--text-3)`},children:e}),(0,o.jsx)(`div`,{className:`mt-2 text-[18px] font-semibold break-words`,style:{color:`var(--text-1)`},children:t}),n?(0,o.jsx)(`div`,{className:`mt-2 text-[11px] leading-5`,style:{color:`var(--text-2)`},children:n}):null]})}function f({children:e}){return(0,o.jsx)(`span`,{className:`inline-flex items-center rounded-ds-pill border px-3 py-1 text-[11px]`,style:{borderColor:`var(--ds-border-default)`,background:`var(--ds-bg-subtle)`,color:`var(--ds-text-secondary)`},children:e})}function p({width:e,height:t=16,radius:n=8}){return(0,o.jsx)(`div`,{style:{width:e,height:t,borderRadius:n,background:`linear-gradient(90deg, color-mix(in srgb, var(--ds-text-muted) 12%, transparent) 0%, color-mix(in srgb, var(--ds-text-muted) 20%, transparent) 50%, color-mix(in srgb, var(--ds-text-muted) 12%, transparent) 100%)`}})}function m({children:e,className:t=``}){return(0,o.jsx)(`div`,{className:`rounded-ds-lg border px-4 py-3 ${t}`,style:{borderColor:`var(--ds-border-default)`,background:`var(--ds-bg-surface)`},children:e})}export{m as a,u as c,f as i,c as n,p as o,s as r,d as s,l as t};