PageSourceSearch

https://harmny.ai/app/assets/Modal-CF3s8Y-C.js

js harmny.ai collected 2026-10-05 12:32:23 UTC 2,393 bytes, 2 lines download raw bytes

1import{o as e}from"./rolldown-runtime-DAXXjFlN.js";import{N as t}from"./charts-CrCOBpVf.js";import{g as n}from"./flow-D6L7UM7m.js";var r=e(t(),1),i=n(),a=(0,r.createContext)(null),o={sm:`max-w-[calc(100vw-2rem)] sm:max-w-sm`,md:`max-w-[calc(100vw-2rem)] sm:max-w-md`,lg:`max-w-[calc(100vw-2rem)] sm:max-w-lg`,xl:`max-w-[calc(100vw-2rem)] sm:max-w-xl`,"2xl":`max-w-[calc(100vw-2rem)] sm:max-w-2xl`,"4xl":`max-w-[calc(100vw-2rem)] sm:max-w-2xl md:max-w-4xl`};function s({isOpen:e,onClose:t,title:n,size:s=`md`,children:c,className:l}){let u=(0,r.useRef)(null),[d,f]=(0,r.useState)(null),p=(0,r.useRef)(null),m=(0,r.useRef)(null),h=(0,r.useId)(),g=(0,r.useCallback)(e=>{u.current=e,f(e)},[]);return(0,r.useEffect)(()=>{let t=u.current;t&&(e?(p.current=document.activeElement,t.showModal()):(t.close(),p.current?.focus?.(),p.current=null))},[e]),(0,r.useEffect)(()=>{let e=u.current;if(!e)return;let n=e=>{e.preventDefault(),t()};return e.addEventListener(`cancel`,n),()=>e.removeEventListener(`cancel`,n)},[t]),(0,i.jsx)(a.Provider,{value:d,children:(0,i.jsx)(`dialog`,{ref:g,onMouseDown:e=>{m.current=e.target},onClick:e=>{e.target===u.current&&m.current===u.current&&t()},"aria-labelledby":n?h:void 0,"aria-modal":`true`,className:`m-auto w-full overflow-visible bg-transparent p-0 backdrop:bg-black/50 ${o[s]}`,children:(0,i.jsxs)(`div`,{className:`animate-slide-up flex max-h-[90vh] flex-col overflow-hidden rounded-2xl bg-white shadow-xl dark:bg-gray-800 ${l??``}`,children:[n&&(0,i.jsxs)(`div`,{className:`flex shrink-0 items-center justify-between p-6 pb-0`,children:[(0,i.jsx)(`h2`,{id:h,className:`text-lg font-semibold text-gray-900 dark:text-white`,children:n}),(0,i.jsx)(`button`,{onClick:t,"aria-label":`Close modal`,className:`flex min-h-[44px] min-w-[44px] items-center justify-center rounded-lg text-gray-400 transition-colors hover:bg-gray-100 hover:text-gray-600 focus:outline-none focus-visible:ring-2 focus-visible:ring-blue-500 dark:hover:bg-gray-700 dark:hover:text-gray-300`,children:(0,i.jsx)(`svg`,{className:`h-5 w-5`,fill:`none`,viewBox:`0 0 24 24`,stroke:`currentColor`,children:(0,i.jsx)(`path`,{strokeLinecap:`round`,strokeLinejoin:`round`,strokeWidth:2,d:`M6 18L18 6M6 6l12 12`})})})]}),(0,i.jsx)(`div`,{className:`app-scrollbar min-h-0 flex-1 overflow-y-auto overscroll-contain`,children:c})]})})})}export{a as n,s as t};
2//# sourceMappingURL=Modal-CF3s8Y-C.js.map

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.