import{j as r}from"./document_model_editor-B0b9iLkL.js";import{u as l}from"./index-Zdob0kL_.js";import{a3 as p,i as d,N as u,aP as i,O as x}from"./reactor_browser-CqcNBhxi.js";import{q as h}from"./design_system_connect-CyoiT4fi.js";import"./graphql-AKTCpY7l.js";import"./drive_explorer-C9ZlHrfH.js";import"./sentry_react-cODD7zWc.js";import"./react-DQSxOgtG.js";import"./sentry_browser-B4YoBIIG.js";import"./react/jsx-runtime-DldvXD6N.js";import"./document_model-BhnxVUEi.js";import"./zod-9j67vCAu.js";import"./design_system-D3L2kJJ3.js";import"./tailwind_merge-Dr4f9Rms.js";import"./react-dom-D6zQJsh6.js";import"./react-dom/client-BVPiT_FE.js";import"./document_drive-CacD9AxC.js";import"./config-CU-aFfVJ.js";import"./graphql_request-BJtmW2JS.js";import"./design_system_ui-cfMsqDx9.js";function F(){const n=p(),m=n?.type==="exportDocumentWithErrors",s=m?n.documentId:void 0,[e]=d(s),{t:o}=l();if(!e)return null;const a=u(e);return r.jsx(h,{header:o("modals.exportDocumentWithErrors.title"),title:o("modals.exportDocumentWithErrors.title"),body:r.jsxs("div",{children:[r.jsx("p",{children:o("modals.exportDocumentWithErrors.body")}),r.jsx("ul",{className:"mt-4 flex list-disc flex-col items-start px-4 text-xs",children:a.map((t,c)=>r.jsx("li",{children:t.message},c))})]}),cancelLabel:o("common.cancel"),continueLabel:o("common.export"),onCancel:()=>i(),onContinue:async()=>{try{await x(e)}catch(t){console.error(t)}finally{i()}},open:m,onOpenChange:t=>{if(!t)return i()}})}export{F as ExportDocumentWithErrorsModal};
