try{let e=typeof window<`u`?window:typeof global<`u`?global:typeof globalThis<`u`?globalThis:typeof self<`u`?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]=`b432a8d4-4099-40bd-8922-35a10d1d6f94`,e._sentryDebugIdIdentifier=`sentry-dbid-b432a8d4-4099-40bd-8922-35a10d1d6f94`)}catch{}import{o as e}from"./rolldown-runtime-nx40z1zs.js";import{Ag as t,Hm as n,Yh as r,Zm as i,_r as a,ng as o,pi as s}from"./entry.client-mpghtlrl.js";import{n as c}from"./DialogShell-ga7ic6wy.js";import{t as l}from"./ConfirmationDialog-gwsu4d5l.js";var u=t(),d=e(s(),1),f=o(),p=e=>{let t=(0,u.c)(9),{locGenericErrorSubheading:r,locOkay:i}=n();if(!(`type`in e))return e;switch(e.type){case`generic-error`:{let e;t[0]===r?e=t[1]:(e=r(),t[0]=r,t[1]=e);let n;t[2]===i?n=t[3]:(n=i(),t[2]=i,t[3]=n);let a;t[4]===n?a=t[5]:(a={text:n},t[4]=n,t[5]=a);let o;return t[6]!==e||t[7]!==a?(o={title:``,prompt:e,illustration:`error`,firstButton:a},t[6]=e,t[7]=a,t[8]=o):o=t[8],o}}},m=a(e=>{let t=(0,u.c)(23),n,r;t[0]===e?(n=t[1],r=t[2]):({goBack:r,...n}=e,t[0]=e,t[1]=n,t[2]=r);let i=c.useComponent(),a=p(n),o;t[3]!==r||t[4]!==a.firstButton?(o=e=>{r(),a.firstButton?.onPress?.(e)},t[3]=r,t[4]=a.firstButton,t[5]=o):o=t[5];let s;t[6]!==a.firstButton||t[7]!==o?(s={...a.firstButton,onPress:o},t[6]=a.firstButton,t[7]=o,t[8]=s):s=t[8];let m;t[9]!==a.secondButton||t[10]!==r?(m=a.secondButton&&{...a.secondButton,onPress:e=>{r(),a.secondButton?.onPress?.(e)}},t[9]=a.secondButton,t[10]=r,t[11]=m):m=t[11];let h;t[12]!==a||t[13]!==s||t[14]!==m?(h={...a,firstButton:s,secondButton:m},t[12]=a,t[13]=s,t[14]=m,t[15]=h):h=t[15];let g=h,_=a.title,v;t[16]===Symbol.for(`react.memo_cache_sentinel`)?(v=(0,d.default)(l.CONTAINER_CLASSNAME,`modal-medium modal-floating`),t[16]=v):v=t[16];let y;t[17]===g?y=t[18]:(y=(0,f.jsx)(l,{...g}),t[17]=g,t[18]=y);let b;return t[19]!==i||t[20]!==a.title||t[21]!==y?(b=(0,f.jsx)(i,{accessibleTitle:_,autoHeight:!0,className:v,children:y}),t[19]=i,t[20]=a.title,t[21]=y,t[22]=b):b=t[22],b},({...e})=>{let{dialog:t}=i(),{mutate:n}=r(t.mutations.goBack.getOptions());return{...e,goBack:n}}),h=e=>{let t=(0,u.c)(5),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r=m.useComponent(),i;return t[2]!==r||t[3]!==n?(i=(0,f.jsx)(r,{...n}),t[2]=r,t[3]=n,t[4]=i):i=t[4],i};export{h as ConfirmationDialog,h as default,m as ConfirmationDialogConnection};