PageSourceSearch

https://daybookpro-prod.web.app/assets/dialog-QOi_sbC8.js

js daybookpro-prod.web.app collected 2026-10-03 12:22:09 UTC 6,517 bytes, 1 lines download raw bytes

1import{i as e}from"./rolldown-runtime-Dd_uD5pT.js";import{n as t,t as n}from"./jsx-runtime-CObvJnpU.js";import{t as r}from"./react-BLZA0yey.js";import{t as i}from"./createLucideIcon-tmP3rYEF.js";import{t as a}from"./utils-DXalBF5w.js";import{a as o,c as s,i as c,n as l,o as u,r as d,s as f,t as p}from"./dist-CU6EtWHK.js";import{t as m}from"./button-DpNOHjnD.js";import{t as h}from"./close-circle-button-C3XrK48i.js";import{t as g}from"./use-body-scroll-lock-B1nprMWz.js";import{t as _}from"./use-media-query-CUmerR30.js";var v=i(`minus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}]]),y=e(t(),1),b=(0,y.createContext)(null);function x(){let e=(0,y.useContext)(b);return{available:e?.available===!0,minimize:()=>e?.minimize()}}var S=(0,y.createContext)(null),C=r(e=>({docked:[],dock:t=>e(e=>{let n=e.docked.findIndex(e=>e.id===t.id);if(n===-1)return{docked:[...e.docked,t]};let r=e.docked.slice();return r[n]=t,{docked:r}}),undock:t=>e(e=>({docked:e.docked.filter(e=>e.id!==t)}))})),w=n(),T=`translate-x-[calc(-50%-(var(--action-dock-px,0px)+var(--help-dock-px,0px))/2)]`,E=`sm:translate-x-[calc(-50%-(var(--action-dock-px,0px)+var(--help-dock-px,0px))/2)]`,D=`[--dialog-free-width:calc(100vw-var(--action-dock-px,0px)-var(--help-dock-px,0px)-2rem)]`,O=a(`inset-0 h-[100dvh] max-h-[100dvh] w-full max-w-none translate-x-0 translate-y-0 rounded-none`,`sm:inset-auto sm:top-1/2 sm:left-1/2 sm:right-auto sm:bottom-auto sm:h-auto sm:max-h-[calc(100dvh-2rem)] sm:w-full ${E} sm:-translate-y-1/2 sm:rounded-xl`);function k({minimizable:e,...t}){return e?(0,w.jsx)(A,{minimizable:e,...t}):(0,w.jsx)(u,{"data-slot":`dialog`,...t})}function A({minimizable:e,modal:t,open:n,children:r,...i}){let a=y.useId(),o=_(),[s,c]=y.useState(!1),l=C(e=>e.dock),d=C(e=>e.undock),f=y.useContext(S),[p,m]=y.useState(n);n!==p&&(m(n),s&&c(!1)),s&&!o&&c(!1),g(n===!0&&!s),y.useEffect(()=>{f?.setKeepAlive(s)},[s,f]);let h=y.useRef({onOpenChange:i.onOpenChange});y.useEffect(()=>{h.current={onOpenChange:i.onOpenChange}});let v=y.useCallback(e=>{h.current.onOpenChange?.(e)},[]),{title:x,subtitle:T,closeFromDock:E}=e;y.useEffect(()=>{if(s)return l({id:a,title:x,subtitle:T,restore:()=>c(!1),close:E?()=>v(!1):void 0}),()=>d(a)},[s,a,x,T,E,l,d,v]);let D=y.useMemo(()=>({minimized:s,minimize:()=>c(!0),available:o,standInOverlay:t!==!1}),[s,o,t]);return(0,w.jsx)(u,{"data-slot":`dialog`,...i,modal:!1,open:n,onOpenChange:v,children:(0,w.jsx)(b.Provider,{value:D,children:r})})}function j({...e}){return(0,w.jsx)(s,{"data-slot":`dialog-trigger`,...e})}function M({...e}){return(0,w.jsx)(o,{"data-slot":`dialog-portal`,...e})}function N({...e}){return(0,w.jsx)(p,{"data-slot":`dialog-close`,...e})}function P({className:e,hidden:t,style:n,...r}){return(0,w.jsx)(c,{"data-slot":`dialog-overlay`,"data-hidden-overlay":t?``:void 0,style:t?{...n,display:`none`}:n,className:a(`fixed inset-0 isolate z-50 bg-black/10 duration-100 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...r})}function F({className:e,children:t,showCloseButton:n=!0,hideOverlay:r=!1,onPointerDownOutside:i,onInteractOutside:o,onOpenAutoFocus:s,onEscapeKeyDown:c,overlayClassName:u,style:d,ref:f,...g}){let _=i??(e=>e.preventDefault()),x=o??(e=>e.preventDefault()),S=s??(e=>e.preventDefault()),C=y.useContext(b),E=C?.minimized===!0,O=e=>{if(E){e.preventDefault();return}c?.(e)},k=y.useCallback(e=>{if(typeof f==`function`?f(e):f&&(f.current=e),!e)return;let t=e=>e.stopPropagation();return e.addEventListener(`wheel`,t),()=>e.removeEventListener(`wheel`,t)},[f]);return(0,w.jsxs)(M,{children:[(0,w.jsx)(P,{hidden:r,className:u}),C?.standInOverlay&&(0,w.jsx)(`div`,{"data-slot":`dialog-overlay-standin`,style:E||r?{display:`none`}:void 0,className:a(`fixed inset-0 isolate z-50 bg-black/10 supports-backdrop-filter:backdrop-blur-xs`,u)}),(0,w.jsxs)(l,{"data-slot":`dialog-content`,className:a(`fixed top-1/2 left-1/2 z-50 grid grid-cols-[minmax(0,1fr)] w-full max-w-full max-h-[calc(100dvh-2*max(env(safe-area-inset-top),1rem)-8rem)] ${T} ${D} -translate-y-1/2 gap-4 overflow-x-hidden overflow-y-auto overscroll-contain touch-pan-y rounded-none bg-popover p-4 text-sm text-popover-foreground ring-0 duration-100 outline-none sm:max-w-sm sm:max-h-[calc(100dvh-2rem)] sm:rou
1nded-xl sm:ring-1 sm:ring-foreground/10 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,n&&`[&_[data-slot=dialog-header]]:pl-14`,n&&`[&_[data-slot=dialog-header]]:mt-2`,n&&C?.available&&`[&_[data-slot=dialog-header]]:pr-12`,e),onPointerDownOutside:_,onInteractOutside:x,onOpenAutoFocus:S,onEscapeKeyDown:O,"data-minimized":E?`true`:void 0,style:E?{...d,display:`none`}:d,ref:k,...g,children:[t,C?.available&&n&&(0,w.jsx)(m,{type:`button`,variant:`ghost`,onClick:C.minimize,"aria-label":`Minimize`,title:`Minimize — pick it up where you left off`,className:`absolute top-3 right-3 z-30 size-9 rounded-full bg-background/90 text-foreground shadow-md ring-1 ring-border/60 transition-transform hover:bg-background active:scale-90 [&_svg]:size-5 md:[&_svg]:size-4`,size:`icon`,children:(0,w.jsx)(v,{})}),n&&(0,w.jsx)(p,{"data-slot":`dialog-close`,asChild:!0,children:(0,w.jsx)(h,{})})]})]})}function I({className:e,...t}){let n=x();return n.available?(0,w.jsx)(m,{type:`button`,variant:`ghost`,size:`icon`,"data-slot":`dialog-minimize`,"aria-label":`Minimize`,title:`Minimize — pick it up where you left off`,onClick:n.minimize,className:a(`shrink-0`,e),...t,children:(0,w.jsx)(v,{className:`size-4`})}):null}function L({className:e,...t}){return(0,w.jsx)(`div`,{"data-slot":`dialog-header`,className:a(`flex min-w-0 flex-col gap-2`,e),...t})}function R({className:e,showCloseButton:t=!1,children:n,...r}){return(0,w.jsxs)(`div`,{"data-slot":`dialog-footer`,className:a(`-mx-4 -mb-4 flex flex-col-reverse gap-2 rounded-b-xl border-t bg-muted/50 p-4 sm:flex-row sm:justify-end`,e),...r,children:[n,t&&(0,w.jsx)(p,{asChild:!0,children:(0,w.jsx)(m,{variant:`outline`,children:`Close`})})]})}function z({className:e,...t}){return(0,w.jsx)(f,{"data-slot":`dialog-title`,className:a(`font-heading text-base leading-none font-medium`,e),...t})}function B({className:e,...t}){return(0,w.jsx)(d,{"data-slot":`dialog-description`,className:a(`text-sm text-muted-foreground *:[a]:underline *:[a]:underline-offset-3 *:[a]:hover:text-foreground`,e),...t})}export{R as a,z as c,C as d,S as f,B as i,j as l,N as n,L as o,v as p,F as r,I as s,k as t,O as u};

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.