1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[63373],{63373:(e,l,s)=>{s.r(l),s.d(l,{default:()=>y});var t=s(63616),n=s(27980),r=s(10927),a=s(31828),i=s(42942),c=s(41129),o=s(66935),d=s(43336),u=s(52120),x=s(2467),m=s(54867),g=s(19256);function p(e){let{value:l,onChange:s,options:n,className:r}=e;return(0,t.jsx)("div",{className:(0,g.cn)("flex h-[45px] w-fit gap-1 rounded-xl bg-light-gray-1 p-1",r),children:n.map(e=>{let n=l===e.value;return(0,t.jsx)("button",{type:"button",className:"h-full",onClick:()=>s(e.value),children:(0,t.jsx)("div",{className:(0,g.cn)("flex items-center justify-center rounded-lg px-5 py-2",n&&"bg-light-gray-2"),children:(0,t.jsx)("div",{className:(0,g.cn)("text-sm text-text-color",n&&"text-main-color"),children:e.name})})},e.value)})})}var h=s(68964),f=s(53667),j=s(70613),v=s(73444);function b(){return(0,t.jsx)("div",{className:"grid w-full animate-pulse grid-cols-2 gap-2 lg:grid-cols-5",children:(0,f.q)(25).map(e=>(0,t.jsx)("div",{className:"h-52 rounded bg-main-gray lg:h-72"},e))})}function N(e){let{image:l,handleConfirm:s}=e;return(0,t.jsx)("div",{className:"w-full overflow-hidden rounded",children:(0,t.jsx)("img",{src:l.url,alt:l.title,className:"w-full cursor-pointer transition-all duration-200 hover:scale-105",loading:"lazy",decoding:"async",fetchPriority:"high",onClick:()=>s(l.url)})})}function w(e){let{onConfirm:l}=e,[s,r]=(0,n.useState)(1),{data:a,isLoading:i,total:c}=(0,v.Ay)({pageNum:s,pageSize:25}),o=async e=>{l(e)};return(0,t.jsxs)("div",{className:"relative flex h-full w-full flex-col items-center justify-center gap-3 px-8 py-3",children:[i&&(0,t.jsx)(b,{}),(0,t.jsx)("div",{className:"no-scrollbar h-full w-full overflow-y-auto",children:!i&&a&&a.length>0&&(0,t.jsx)(h.a,{items:a,config:{columns:[2,5],gap:[8,8],media:[768,1148]},render:e=>(0,t.jsx)(N,{image:e,handleConfirm:o},e.id)})}),(0,t.jsx)(j.A,{currentPage:s,pageSize:25,onChange:r,total:c||0,className:"mt-auto justify-center px-3 lg:px-0"})]})}function y(e){let{open:l,setOpen:s,onConfirm:g}=e,h=(0,i.c)("ui.image-dialog-form"),f=(0,m.A)(e=>
1e.imageObj),[j,v]=(0,n.useState)("create"),b=e=>{g(e),(0,n.startTransition)(()=>{s(!1)})};return(0,t.jsx)(o.lG,{open:l,onOpenChange:s,children:(0,t.jsx)(o.Cf,{onInteractOutside:e=>{e.preventDefault()},onSubmit:e=>{e.stopPropagation()},closeBtnClassName:"hidden",overlayClassName:"bg-black/60",className:"flex h-dvh w-dvw !rounded-none border-none bg-background-color p-0 shadow-[0px_0px_20px_0px_rgba(255,255,255,0.1)] lg:max-h-[723px] lg:min-w-[1322px] lg:!rounded-2xl",children:(0,t.jsxs)("div",{className:"flex size-full flex-col overflow-y-auto",children:[(0,t.jsxs)("div",{className:"flex w-full items-center justify-between border-b border-light-gray p-3",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(p,{value:j,onChange:e=>v(e),options:[{name:h("create"),value:"create"},{name:h("history"),value:"history"}]}),(0,t.jsx)(x.A,{tips:h("warning"),icon:(0,t.jsx)(r.A,{className:"size-4 cursor-help"})})]}),(0,t.jsx)("button",{type:"button",className:"flex size-5 items-center justify-center rounded hover:bg-white/10",onClick:()=>{if("loading"===f)return void c.o.warning(h("warning"));s(!1)},children:(0,t.jsx)(a.A,{className:"size-4 rounded-full text-[#D9D9D9]"})})]}),(0,t.jsxs)("div",{className:"w-full flex-1 overflow-hidden",children:["create"===j&&(0,t.jsx)(d.A,{formType:"image-dialog",className:"gap-2 rounded-none bg-background-color p-0 lg:h-full lg:p-0",wrapperClassName:"lg:w-[calc(100%-368px)]",onConfirmUrl:b,children:(0,t.jsx)(u.Q,{formTitle:h("title")})}),"history"===j&&(0,t.jsx)(w,{onConfirm:b})]})]})})})}},70613:(e,l,s)=>{s.d(l,{A:()=>d});var t=s(63616),n=s(58151),r=s(5160),a=s(91509),i=s(36713),c=s(19256);function o(e){let{className:l,children:s}=e;return(0,t.jsx)("button",{type:"button",className:(0,c.cn)("size-8 rounded-lg bg-main-black p-px hover:cursor-pointer hover:text-white",l),children:(0,t.jsx)("span",{className:"flex-xy-center size-full flex-1 rounded-lg bg-dark-gray",children:s})})}function d(e){let{currentPage:l,pageSize:s,onChange:d,total:u,className:x}=e;return(0,t.jsxs)("div",{className:(0,c.cn)("flex items-center justify-center gap-3",x),children:[(0,t.jsx)(i.A,{className:"flex gap-3 text-xs text-white [&>li]:flex [&>li]:items-center [&>
1li]:justify-center",pageSize:s,current:l,onChange:d,total:u,showLessItems:!0,itemRender:(e,s,a)=>(function(e){let{page:l,type:s,element:a,currentPage:i}=e;return"page"===s?(0,t.jsx)(o,{className:l===i?"bg-white":"",children:l}):"prev"===s?(0,t.jsx)(o,{children:(0,t.jsx)(n.A,{className:"h-4 w-4"})}):"next"===s?(0,t.jsx)(o,{children:(0,t.jsx)(r.A,{className:"h-4 w-4"})}):"jump-prev"===s||"jump-next"===s?(0,t.jsx)("div",{children:"..."}):a})({page:e,type:s,element:a,currentPage:l}),locale:{next_page:"next",prev_page:"prev"},prevIcon:(0,t.jsx)(n.A,{className:"h-4 w-4"}),nextIcon:(0,t.jsx)(r.A,{className:"h-4 w-4"})}),(0,t.jsxs)("form",{onSubmit:e=>{e.preventDefault(),d(Number(new FormData(e.target).get("page")))},className:"flex items-center gap-3",children:[(0,t.jsx)("input",{type:"number",min:1,max:Math.ceil(u/s),name:"page",defaultValue:l,className:"hide-number-input flex h-8 max-w-[50px] items-center justify-center rounded border border-white/40 bg-transparent px-2 text-xs"}),(0,t.jsx)("button",{type:"submit",className:"flex size-8 items-center justify-center rounded border border-transparent bg-transparent text-white/40 hover:cursor-pointer hover:bg-[#2C2D36]",children:(0,t.jsx)(a.A,{className:"size-6"})})]})]})}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.