@riverbankcms/sdk 0.161.0 → 0.162.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (187) hide show
  1. package/dist/_dts/{BlocksIslandsHydrator-Bx4kLiTA.d.ts → BlocksIslandsHydrator-PZUoA872.d.ts} +1 -1
  2. package/dist/_dts/{Page-Dm7_P13o.d.ts → Page-CdQS6C7i.d.ts} +8 -8
  3. package/dist/_dts/{SdkPreviewMode-D7HdWWwF.d.ts → SdkPreviewMode-CNGO-5f1.d.ts} +58 -91
  4. package/dist/_dts/{client-Ep0jI9eE.d.ts → client-DGa53rjL.d.ts} +11 -3
  5. package/dist/_dts/{content-types-BgAzCrBc.d.ts → content-types-K9R7P-KF.d.ts} +2 -2
  6. package/dist/_dts/{contracts-DUiOnj9e.d.ts → contracts-CyBaPaIq.d.ts} +13 -4
  7. package/dist/_dts/{footerPageOutline-B-uXamTG.d.ts → footerPageOutline-B6jmKmon.d.ts} +6 -6
  8. package/dist/_dts/{generatePageMetadata-BDkZYEcS.d.ts → generatePageMetadata-iemoR3AN.d.ts} +2 -2
  9. package/dist/_dts/{index-ylivB7Jj.d.ts → index-8CN0Nd-Z.d.ts} +2 -2
  10. package/dist/_dts/{index-CSsfq6KG.d.ts → index-BtnsA14K.d.ts} +9 -5
  11. package/dist/_dts/{index-BVkP8f70.d.ts → index-C39F9KaB.d.ts} +13 -2
  12. package/dist/_dts/{index-KPrWM0KF.d.ts → index-DEu85xBt.d.ts} +1 -1
  13. package/dist/_dts/{schema-BHu0PYWl.d.ts → index-DI2yaSPY.d.ts} +4099 -3343
  14. package/dist/_dts/{types-BR1Yboa9.d.ts → index-Dbd0Sn0G.d.ts} +3300 -1691
  15. package/dist/_dts/{index-CF6Cjs7b.d.ts → index-Du1IRglc.d.ts} +2 -2
  16. package/dist/_dts/{index-D_8uz4OP.d.ts → index-Jlcq6w69.d.ts} +3 -3
  17. package/dist/_dts/{index-DvKQA6AZ.d.ts → index-Wm62sXf2.d.ts} +4 -4
  18. package/dist/_dts/{loadContent-DTjKOO-T.d.ts → loadContent-BPfAAZDW.d.ts} +10 -7
  19. package/dist/_dts/{resolvePageContent-C1vA5c5w.d.ts → resolvePageContent-DWbrtKf8.d.ts} +2 -2
  20. package/dist/_dts/sdk/src/bookings/index.d.ts +2 -2
  21. package/dist/_dts/sdk/src/client/types.d.ts +2 -2
  22. package/dist/_dts/sdk/src/client.d.ts +6 -6
  23. package/dist/_dts/sdk/src/config/index.d.ts +6 -6
  24. package/dist/_dts/sdk/src/config/template-validation.d.ts +1 -1
  25. package/dist/_dts/sdk/src/config/validation.d.ts +1 -1
  26. package/dist/_dts/sdk/src/index.d.ts +8 -8
  27. package/dist/_dts/sdk/src/manifest/index.d.ts +3 -3
  28. package/dist/_dts/sdk/src/metadata/index.d.ts +1 -1
  29. package/dist/_dts/sdk/src/navigation/index.d.ts +2 -2
  30. package/dist/_dts/sdk/src/next/index.d.ts +7 -7
  31. package/dist/_dts/sdk/src/next/middleware.d.ts +2 -2
  32. package/dist/_dts/sdk/src/page-converter/index.d.ts +3 -3
  33. package/dist/_dts/sdk/src/portal/client.d.ts +1 -1
  34. package/dist/_dts/sdk/src/prebuild/index.d.ts +1 -1
  35. package/dist/_dts/sdk/src/preview-next/before-render.d.ts +2 -2
  36. package/dist/_dts/sdk/src/preview-next/client/index.d.ts +2 -2
  37. package/dist/_dts/sdk/src/preview-next/client/runtime.d.ts +1 -1
  38. package/dist/_dts/sdk/src/rendering/client.d.ts +2 -2
  39. package/dist/_dts/sdk/src/rendering/index.d.ts +6 -6
  40. package/dist/_dts/sdk/src/rendering/islands/client.d.ts +1 -1
  41. package/dist/_dts/sdk/src/rendering/server.d.ts +2 -2
  42. package/dist/_dts/sdk/src/routing/index.d.ts +5 -5
  43. package/dist/_dts/sdk/src/server.d.ts +5 -5
  44. package/dist/_dts/sdk/src/theme/index.d.ts +1 -1
  45. package/dist/_dts/{types-ZGUiHpDE.d.ts → types-CVv2H4AT.d.ts} +7 -7
  46. package/dist/_dts/{types-D02ngcUH.d.ts → types-CfNG5koF.d.ts} +2 -2
  47. package/dist/_dts/{types-CJXTCF_F.d.ts → types-ClZ-BQL_.d.ts} +3 -3
  48. package/dist/_dts/{validation-BaV565gb.d.ts → validation-BJ6Lf_Dr.d.ts} +4 -4
  49. package/dist/client/{BlocksIslandsHydrator-DTExCJsb.mjs → BlocksIslandsHydrator-COqlgWYU.mjs} +20 -19
  50. package/dist/client/{BookingMailingListNote-BDpxmn1p.mjs → BookingMailingListNote-CFYPDEHH.mjs} +1 -1
  51. package/dist/client/{CalendarNavigationChevron-PeCiL82X.mjs → CalendarNavigationChevron-COBVxgHb.mjs} +6 -6
  52. package/dist/client/{CheckboxChoice-DWexRLf6.mjs → CheckboxChoice-C7X9dJ8A.mjs} +1 -1
  53. package/dist/client/{DemoBookingPortalAccess-3zmIqakW.mjs → DemoBookingPortalAccess-CvT0E9AR.mjs} +26 -10
  54. package/dist/client/{DemoPortalSignInLink-GHi-8BW5.mjs → DemoPortalSignInLink-EBOBN5dT.mjs} +1 -1
  55. package/dist/client/{EventCalendar.client-BxQLY5cX.mjs → EventCalendar.client-U6pKcntV.mjs} +16 -17
  56. package/dist/client/{EventCombined.client-B5bmQ03b.mjs → EventCombined.client-CNzwEHws.mjs} +8 -8
  57. package/dist/client/{EventEmbeddedCheckoutStep-CgMZ9TeU.mjs → EventEmbeddedCheckoutStep-B9yAWV_k.mjs} +1 -1
  58. package/dist/client/{EventItem-BEx-qiDE.mjs → EventItem-M5rpaHxi.mjs} +4 -4
  59. package/dist/client/{EventListWeekNavigation-CyH5tA6Y.mjs → EventListWeekNavigation-D4ieBLDY.mjs} +1 -1
  60. package/dist/client/{EventListing.client-D3uySdGP.mjs → EventListing.client-B8F40Rmn.mjs} +3 -3
  61. package/dist/client/{EventListing.view-9RFrBejr.mjs → EventListing.view-k4lhuCn5.mjs} +14 -21
  62. package/dist/client/{EventRegistrationPayment-CG2tQx8K.mjs → EventRegistrationPayment-C3g8_Hqb.mjs} +10 -10
  63. package/dist/client/LocationMapActions-CAjt7qVo.mjs +62 -0
  64. package/dist/client/{LocationMapActions-Wsr83Q7q.mjs → MapDrawingSvg-_aIK2ojv.mjs} +2 -70
  65. package/dist/client/{Page-Bf2nPACI.mjs → Page-DJBIQBOw.mjs} +1762 -254
  66. package/dist/client/{StepIndicator-CZweb1vs.mjs → StepIndicator-CFacB1z6.mjs} +2 -2
  67. package/dist/client/{TabBarFragment-Bkgz67gt.mjs → TabBarFragment-BLsfQskO.mjs} +1 -1
  68. package/dist/client/{ThemedButton-CnyL3s1A.mjs → ThemedButton-BWsDgjMC.mjs} +1 -1
  69. package/dist/client/{accordion-TcimLLRQ.mjs → accordion-CtO2XF7M.mjs} +1 -1
  70. package/dist/client/{booking-form.client-q-RpJ4aF.mjs → booking-form.client-RICCQ0h2.mjs} +137 -60
  71. package/dist/client/{bookingForm-DjGfk3Wj.mjs → bookingForm-SvjLPx8i.mjs} +4 -4
  72. package/dist/client/bookings.mjs +5 -5
  73. package/dist/client/{carousel-CGAk6j0m.mjs → carousel-BR-zCD3O.mjs} +2 -2
  74. package/dist/client/{carousel.client-ArlGmYWV.mjs → carousel.client-CEWtoZd3.mjs} +1 -1
  75. package/dist/client/{cart-D_h3rAZ2.mjs → cart-C6YpKbZZ.mjs} +3 -3
  76. package/dist/client/{cart.client-DHOxZbJ7.mjs → cart.client-dC938WrX.mjs} +1 -1
  77. package/dist/client/{checkout-tC-3CzuM.mjs → checkout-Dy9RlREI.mjs} +3 -3
  78. package/dist/client/{checkout.client-DsBb2Pkm.mjs → checkout.client-CefG0d2F.mjs} +1 -1
  79. package/dist/client/client.mjs +34 -69
  80. package/dist/client/{context-9ZfMb6GA.mjs → context-BFwxgZpB.mjs} +28 -1
  81. package/dist/client/{cta-D-ZqL7-e.mjs → cta-DtA42Xio.mjs} +1 -1
  82. package/dist/client/{dateFormatting-BCwLqYpW.mjs → dateFormatting-yP1B7F0O.mjs} +39 -2
  83. package/dist/client/{demoPortalMagicLink-BxkSS9fx.mjs → demoPortalMagicLink-WOiT5Ryi.mjs} +1 -1
  84. package/dist/client/{enhanceHeaderSection-xg6to91E.mjs → enhanceHeaderSection-Dh8c_Lq-.mjs} +3 -3
  85. package/dist/client/{event-details.client-C670TgRd.mjs → event-details.client-BFgsLqTj.mjs} +2 -1
  86. package/dist/client/{event-registration.client-C6GApWTB.mjs → event-registration.client-BaXZ1-Ky.mjs} +13 -13
  87. package/dist/client/{eventCalendar-CWc0dg9i.mjs → eventCalendar-COLwF80U.mjs} +4 -4
  88. package/dist/client/{eventCombined-D4DbOrvQ.mjs → eventCombined-D3Ltwu03.mjs} +4 -4
  89. package/dist/client/{eventDetails-C2DfmbC0.mjs → eventDetails-CBrkimXu.mjs} +2 -2
  90. package/dist/client/{eventListing-C_yXmHyz.mjs → eventListing-CedKVA1S.mjs} +4 -4
  91. package/dist/client/{eventRegistration-DJuaCB-O.mjs → eventRegistration-DkQQfR1b.mjs} +4 -4
  92. package/dist/client/{form-QZhtdFHA.mjs → form-XFy9uXSJ.mjs} +3 -3
  93. package/dist/client/{form.client-CgvPACwG.mjs → form.client-B0iancFK.mjs} +4 -4
  94. package/dist/client/{form.parts-2uI0-5N-.mjs → form.parts-DMbolu9Y.mjs} +3 -3
  95. package/dist/client/{formatDate-Danr0Nk4.mjs → formatDate-Jm5MQOCA.mjs} +1 -1
  96. package/dist/client/gifting/client.mjs +3 -3
  97. package/dist/client/{headerSection-DJdlLdvZ.mjs → headerSection-WjlECjtV.mjs} +2 -2
  98. package/dist/client/{mediaAssets-BvjcAZpS.mjs → mediaAssets-BkoW_PEn.mjs} +1 -1
  99. package/dist/client/mediaContext-CNzWmoA4.mjs +136 -0
  100. package/dist/client/{newsletter-form.client-Cbepz2KU.mjs → newsletter-form.client-D-XwJTjN.mjs} +5 -5
  101. package/dist/client/{newsletter-form.parts-DN8oMCQ0.mjs → newsletter-form.parts-H92f30y0.mjs} +2 -2
  102. package/dist/client/{newsletterForm-wjLtW-wq.mjs → newsletterForm-DMuxzu6I.mjs} +3 -3
  103. package/dist/client/{noop-B7H6gCbj.mjs → noop-B3RNPVrt.mjs} +19 -3
  104. package/dist/client/portal/client.mjs +1116 -85
  105. package/dist/client/{product-detail.client-CYTR165c.mjs → product-detail.client-B3HuuykE.mjs} +1 -1
  106. package/dist/client/{product-list.client-B4vTvag8.mjs → product-list.client-CzsDrHQO.mjs} +1 -1
  107. package/dist/client/{productDetail-k8LEMSWn.mjs → productDetail-CbBUVWgd.mjs} +3 -3
  108. package/dist/client/{productList-DEo8Bqoe.mjs → productList-vqOKH2mh.mjs} +3 -3
  109. package/dist/client/{propsDecoder-G0j0HXBO.mjs → propsDecoder-CkSUep5a.mjs} +4 -3
  110. package/dist/client/{registry.server-BTmSXE3D.mjs → registry.server-cZ24QwtW.mjs} +272 -68
  111. package/dist/client/rendering/client.mjs +27 -26
  112. package/dist/client/rendering/islands.mjs +1 -1
  113. package/dist/client/rendering.mjs +10 -7
  114. package/dist/client/{richText-coerce-B19taoH6.mjs → richText-coerce-DDcCKvBJ.mjs} +1 -1
  115. package/dist/client/{routeIslandApiConfig-Chu5BHra.mjs → routeIslandApiConfig-DYBioANh.mjs} +1 -1
  116. package/dist/client/{schema-C-m8XHuW.mjs → schema-DNHLlze-.mjs} +4575 -4311
  117. package/dist/client/{shop-RGWa43H7.mjs → shop-CF0dhnfH.mjs} +3 -3
  118. package/dist/client/{shop-commerce-TJYCBO_H.mjs → shop-commerce-DQznNBEo.mjs} +11 -11
  119. package/dist/client/{shop-commerce-store-CjCcUB_o.mjs → shop-commerce-store-Ba8zPlIg.mjs} +1 -1
  120. package/dist/client/{shop.client-tsKfZw1W.mjs → shop.client-DqfYoqWH.mjs} +12 -12
  121. package/dist/client/{shop.interactive-CVqLAU53.mjs → shop.interactive-CreQ0I7i.mjs} +38 -31
  122. package/dist/client/{shopShared-C3lHMz_R.mjs → shopShared-D-yh-P7g.mjs} +2 -2
  123. package/dist/client/{mediaContext-jPeJ2PmJ.mjs → site-styles-B9HgmY07.mjs} +1329 -511
  124. package/dist/client/{timetableModel-V2ifvGGy.mjs → timetableModel-DCdVErTJ.mjs} +10 -9
  125. package/dist/client/{useAvailableSlots-D1X69-pN.mjs → useAvailableSlots-Cvgdp2DH.mjs} +8 -11
  126. package/dist/client/{useBookingNowIso-Ch30jino.mjs → useBookingNowIso-DrTnGNzD.mjs} +1 -1
  127. package/dist/client/{useDiscountApply-Bwzr1RjV.mjs → useDiscountApply-CULjnXGl.mjs} +2 -2
  128. package/dist/client/{useDiscountCodeUi-BimJbFC7.mjs → useDiscountCodeUi-Gn_m7e0o.mjs} +1 -1
  129. package/dist/client/{useEventPagination-CLAS0upd.mjs → useEventPagination-CsysCF22.mjs} +6 -6
  130. package/dist/client/{view-Dj_FZHmg.mjs → view-BpBjo9Te.mjs} +64 -55
  131. package/dist/client/{view-BUh4LnLS.mjs → view-DMyTchi7.mjs} +4 -4
  132. package/dist/client/{wizardSteps-BkZc-hKH.mjs → wizardSteps-BO2OmMO9.mjs} +59 -53
  133. package/dist/preview-next/before-render.mjs +3 -3
  134. package/dist/preview-next/client/{EventEmbeddedCheckoutStep-CwerMfzn.mjs → EventEmbeddedCheckoutStep-DLsSmZbO.mjs} +1 -1
  135. package/dist/preview-next/client/{PreviewEditorSidebar-Dvq-RW9-.mjs → PreviewEditorSidebar-ChrW9VEo.mjs} +164 -1042
  136. package/dist/preview-next/client/{PreviewEditorUI-BdFjS39R.mjs → PreviewEditorUI-VaHvYtrA.mjs} +9 -190
  137. package/dist/preview-next/client/{SdkPreviewModeRuntime-CjkGh1IG.mjs → SdkPreviewModeRuntime-Bz7jR6nl.mjs} +1 -1
  138. package/dist/preview-next/client/{SdkPreviewModeRuntime-BEfHln1E.mjs → SdkPreviewModeRuntime-DWwktlWs.mjs} +220 -130
  139. package/dist/preview-next/client/{ThemedButton-b14Bv03E.mjs → ThemedButton-CHKOWXxl.mjs} +608 -333
  140. package/dist/preview-next/client/{SiteChromeCustomizeContext-CDbxk_qZ.mjs → previewAuthStore-C0VUwEHz.mjs} +158752 -162808
  141. package/dist/preview-next/client/{previewChromeSurface-Dd1_mNIg.mjs → previewChromeSurface-Dhyx2YrS.mjs} +1 -1
  142. package/dist/preview-next/client/runtime.mjs +3 -3
  143. package/dist/preview-next/client/{sdk-runtime-B-CXyGVb.mjs → sdk-runtime-C2GWOCyj.mjs} +1 -1
  144. package/dist/preview-next/client/siteStyleAccess-DHyzUpv4.mjs +12833 -0
  145. package/dist/preview-next/client/{spinner-CGxS8Ns-.mjs → spinner-BeR2S8oG.mjs} +1 -1
  146. package/dist/preview-next/keepAlive.mjs +2 -2
  147. package/dist/preview-next/middleware.mjs +1 -1
  148. package/dist/preview-next/{refresh-contract-CvmNqZ1Q.mjs → refresh-contract-uQ6BXgLJ.mjs} +5 -0
  149. package/dist/preview-next/{route-contract-hLg-yjQN.mjs → route-contract-CkrFDMrl.mjs} +394 -200
  150. package/dist/server/{Block.shared-CeTd2saO.mjs → Block.shared-DxvNGDig.mjs} +4 -4
  151. package/dist/server/{bindings-C5YpKuKt.mjs → bindings-BuhKvYkE.mjs} +2 -2
  152. package/dist/server/{client-Cv26lZQ4.mjs → client-BobW6DOz.mjs} +34 -69
  153. package/dist/server/config-validation.mjs +1 -1
  154. package/dist/server/config.mjs +2 -2
  155. package/dist/server/{effectiveNavLinkStyle-CGvGr3yD.mjs → effectiveNavLinkStyle-B-MKSt0p.mjs} +1127 -144
  156. package/dist/server/index.mjs +3 -3
  157. package/dist/server/{loadContent-C8a0b-cC.mjs → loadContent-CCG_3mbY.mjs} +7 -4
  158. package/dist/server/loadPage-Bk9HDh9K.mjs +2 -0
  159. package/dist/server/{loadPage-BW7dklu3.mjs → loadPage-jntGoMrf.mjs} +2 -2
  160. package/dist/server/next.mjs +9 -9
  161. package/dist/server/{overrideResolution-tIuqmJB3.mjs → overrideResolution-BBOlgn4Z.mjs} +1 -1
  162. package/dist/server/{overrides-D1fiPOKF.mjs → overrides-DByQwIyW.mjs} +264 -168
  163. package/dist/server/page-converter.mjs +1 -1
  164. package/dist/server/{prebuild--fO0E2tr.mjs → prebuild-DrwcTk2t.mjs} +1 -1
  165. package/dist/server/prebuild.mjs +1 -1
  166. package/dist/server/{prefetchBlockData-CqJnokWJ.mjs → prefetchBlockData-LfgxSJYE.mjs} +31 -10
  167. package/dist/server/{publicProducts-CvvZ4JIe.mjs → publicProducts-8A3T5v4M.mjs} +647 -166
  168. package/dist/server/{registry-BVfCqaCq.mjs → registry-Digv02oV.mjs} +308 -36
  169. package/dist/server/rendering/server.mjs +4 -4
  170. package/dist/server/rendering.mjs +8 -8
  171. package/dist/server/{resolveBlockData-DPNvhXEz.mjs → resolveBlockData-C23t8-77.mjs} +1 -1
  172. package/dist/server/routing.mjs +1 -1
  173. package/dist/server/{schema-CD4peO7m.mjs → schema-BiqpDRwB.mjs} +2813 -2549
  174. package/dist/server/server.mjs +3 -3
  175. package/dist/server/{site-styles-H-EvTJiW.mjs → site-styles-DrkprQPL.mjs} +81 -113
  176. package/dist/server/{siteChromeOverlayClearance-DNC2k1U0.mjs → siteChromeOverlayClearance-BmKKkkbh.mjs} +2 -2
  177. package/dist/server/{src-ILxc6pid.mjs → src-08GY1njw.mjs} +902 -44
  178. package/dist/server/theme-bridge.mjs +1 -1
  179. package/dist/server/theme.mjs +1 -1
  180. package/dist/server/{themeAdmission-BNHIXiUj.mjs → themeAdmission-CSd_Vusz.mjs} +36 -29
  181. package/dist/server/{validation-B1ieVemg.mjs → validation-DdUTkBOZ.mjs} +2 -2
  182. package/dist/server/{version-BQK44wFg.mjs → version-DdIOqIDe.mjs} +1 -1
  183. package/dist/styles/index.css +872 -41
  184. package/package.json +1 -1
  185. package/dist/_dts/index-BQDBQvdu.d.ts +0 -13
  186. package/dist/preview-next/client/siteStyleAccess-Kqk0j0dE.mjs +0 -5812
  187. package/dist/server/loadPage--DXBwI8V.mjs +0 -2
@@ -1,10 +1,10 @@
1
1
  "use client";
2
- import { Co as Tooltip, Ct as useEntryEditorController, Dt as useAutosaveStatus, Es as cva, Et as classifyHistoryShortcut, Ft as EditorWriteSurface, Jo as DialogContent, Mn as canDiscardDraft, Os as cn, Qo as DialogTitle, To as TooltipTrigger, Ts as Button, Tt as useSessionJournalHistory, Yo as DialogDescription, Zo as DialogHeader, _r as unwrapResponse, b as selectPreviewDesignHistoryDomain, ds as DropdownMenuItem, g as usePreviewPageDesignEditorState, kn as useEditorUiStore, ln as useEditor, ls as DropdownMenu, ms as DropdownMenuTrigger, n as useSiteChromeCustomizeOptional, qo as Dialog, st as usePreviewAuth, us as DropdownMenuContent, v as usePreviewDesignHistoryOrder, wo as TooltipContent, wt as useOptionalSessionJournal, y as previewDesignHistoryDomainForCommand } from "./SiteChromeCustomizeContext-CDbxk_qZ.mjs";
2
+ import { $o as Dialog, Ao as TooltipContent, Bt as useEditorUiStore, G as EditorWriteSurface, Gt as canDiscardDraft, Ms as cva, P as useAutosaveStatus, Ps as cn, Rn as unwrapResponse, T as useSessionJournalHistory, _s as DropdownMenuItem, a as usePreviewAuth, bs as DropdownMenuTrigger, en as editorAdmissionIsOpen, es as DialogContent, gs as DropdownMenuContent, hs as DropdownMenu, is as DialogTitle, jo as TooltipTrigger, js as Button, ko as Tooltip, rs as DialogHeader, ts as DialogDescription, vt as useEditor, w as useSessionJournal, x as useEntryEditorController } from "./previewAuthStore-C0VUwEHz.mjs";
3
3
  import { A as LoaderCircle, S as Palette, Y as Eye, Z as EllipsisVertical, b as Pencil, dt as ChevronDown, o as Undo2, s as TriangleAlert, v as Redo2, x as PenLine } from "./lucide-react-CA9cpo0P.mjs";
4
- import { t as Spinner } from "./spinner-CGxS8Ns-.mjs";
5
- import { a as resolvePreviewChromeSurface, c as PREVIEW_THEME_COOKIE_NAME, l as PREVIEW_CHROME_Z_INDEX, n as PREVIEW_CHROME_THEME_CLASS_NAME, r as applyPreviewChromeSurfaceToElement, t as PREVIEW_CHROME_PORTAL_CLASS_NAME, u as FixedBottomSurface } from "./previewChromeSurface-Dd1_mNIg.mjs";
4
+ import { t as Spinner } from "./spinner-BeR2S8oG.mjs";
5
+ import { a as resolvePreviewChromeSurface, c as PREVIEW_THEME_COOKIE_NAME, l as PREVIEW_CHROME_Z_INDEX, n as PREVIEW_CHROME_THEME_CLASS_NAME, r as applyPreviewChromeSurfaceToElement, t as PREVIEW_CHROME_PORTAL_CLASS_NAME, u as FixedBottomSurface } from "./previewChromeSurface-Dhyx2YrS.mjs";
6
6
  import * as React$1 from "react";
7
- import { useCallback, useEffect, useMemo, useRef, useState, useTransition } from "react";
7
+ import { useEffect, useMemo, useRef, useState, useTransition } from "react";
8
8
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
9
9
  import { createPortal } from "react-dom";
10
10
  import { useRouter } from "next/navigation.js";
@@ -613,41 +613,14 @@ function OnboardingThemeSwitcher({ apiClient, siteId, surfaceId, isSiteLaunched,
613
613
  });
614
614
  }
615
615
  //#endregion
616
- //#region ../preview-next/src/client/preview/previewUndoDomains.ts
617
- function selectPreviewUndoDomain(domains, command, context) {
618
- const canRun = (domain) => domain.status !== "pending" && domain.status !== "stale" && (command === "undo" ? domain.canUndo : domain.canRedo);
619
- if (context.kind === "shortcut" && context.owner === "native") return null;
620
- const focusedDomain = domains.find((domain) => canRun(domain) && domain.ownership.kind === "focused" && (context.kind === "chrome" || domain.ownership.owner === context.owner));
621
- if (focusedDomain) return focusedDomain;
622
- return domains.find((domain) => canRun(domain) && domain.ownership.kind === "available") ?? domains.find((domain) => canRun(domain) && domain.ownership.kind === "fallback") ?? null;
623
- }
624
- function previewUndoControlsForDomains(domains, context) {
625
- return {
626
- canUndo: Boolean(selectPreviewUndoDomain(domains, "undo", context)),
627
- canRedo: Boolean(selectPreviewUndoDomain(domains, "redo", context)),
628
- onUndo: () => {
629
- selectPreviewUndoDomain(domains, "undo", context)?.undo();
630
- },
631
- onRedo: () => {
632
- selectPreviewUndoDomain(domains, "redo", context)?.redo();
633
- }
634
- };
635
- }
636
- //#endregion
637
616
  //#region ../preview-next/src/client/preview/PreviewEditorUI.tsx
638
- function PreviewEditorUI(props) {
639
- const journal = useOptionalSessionJournal();
640
- return journal ? /* @__PURE__ */ jsx(DocumentSessionEditorUI, {
641
- ...props,
642
- journal
643
- }) : /* @__PURE__ */ jsx(PreviewEditorChrome, { ...props });
644
- }
645
617
  /** One session cursor and shortcut owner; native field editors keep their existing handling. */
646
- function DocumentSessionEditorUI({ journal, ...props }) {
618
+ function PreviewEditorUI(props) {
619
+ const journal = useSessionJournal();
647
620
  const rootRef = useRef(typeof document === "undefined" ? null : document.body);
648
- const admission = useEditorUiStore((state) => state.editAdmission);
621
+ const admission = useEditorUiStore((state) => state.getAdmission());
649
622
  const { isEditingMode } = useEditor();
650
- const history = useSessionJournalHistory(journal, rootRef, isEditingMode && admission.kind === "document");
623
+ const history = useSessionJournalHistory(journal, rootRef, isEditingMode && editorAdmissionIsOpen(admission));
651
624
  return /* @__PURE__ */ jsx(PreviewEditorChrome, {
652
625
  ...props,
653
626
  sessionHistory: history
@@ -661,17 +634,8 @@ function PreviewEditorChrome({ dashboardBaseUrl = null, inMaintenanceMode = fals
661
634
  const lifecycleRunning = useEditorUiStore((state) => state.lifecycle.kind === "running" || state.lifecycle.kind === "holding");
662
635
  const surfaceDocument = useMemo(() => resolvePreviewChromeSurface(surfaceId), [surfaceId]);
663
636
  const draftSyncState = useEditorUiStore((state) => state.getDraftSyncState());
664
- const canUndo = useEditorUiStore((state) => state.history.canUndo());
665
- const canRedo = useEditorUiStore((state) => state.history.canRedo());
666
637
  const hasUnpublishedChanges = useEditorUiStore((state) => state.getUnpublishedState().hasUnpublishedChanges);
667
638
  const canDiscard = useEditorUiStore((state) => canDiscardDraft(state.getUnpublishedState()));
668
- const undo = useEditorUiStore((state) => state.history.undo);
669
- const redo = useEditorUiStore((state) => state.history.redo);
670
- const designHistory = usePreviewPageDesignEditorState();
671
- const previewDesignHistoryOrder = usePreviewDesignHistoryOrder();
672
- const siteChromeCustomize = useSiteChromeCustomizeOptional();
673
- const siteStyleHistory = siteChromeCustomize?.siteStyleHistory ?? null;
674
- const quickControlHistory = siteChromeCustomize?.quickControlHistory ?? null;
675
639
  const lastSavedAt = combinedAutosave.lastSavedAt;
676
640
  const computedToolbar = useMemo(() => {
677
641
  const base = controller.toolbar ?? {};
@@ -689,93 +653,6 @@ function PreviewEditorChrome({ dashboardBaseUrl = null, inMaintenanceMode = fals
689
653
  ]);
690
654
  const lifecycleActions = controller.actions;
691
655
  const { handlePublish, handleDiscard } = previewLifecycleHandlers(lifecycleActions, useRouter().refresh);
692
- const designHistoryControllers = useMemo(() => ({
693
- "site-style-design": siteStyleHistory,
694
- "site-chrome-quick-controls": quickControlHistory,
695
- "theme-customize": designHistory
696
- }), [
697
- designHistory,
698
- quickControlHistory,
699
- siteStyleHistory
700
- ]);
701
- const designHistoryCapabilities = useMemo(() => ({
702
- "site-style-design": previewDesignHistoryCapabilities(siteStyleHistory),
703
- "site-chrome-quick-controls": previewDesignHistoryCapabilities(quickControlHistory),
704
- "theme-customize": previewDesignHistoryCapabilities(designHistory)
705
- }), [
706
- designHistory,
707
- quickControlHistory,
708
- siteStyleHistory
709
- ]);
710
- const runPreviewDesignHistoryCommand = useCallback((command) => {
711
- const domainId = selectPreviewDesignHistoryDomain(previewDesignHistoryOrder.state, command, designHistoryCapabilities);
712
- if (!domainId) return;
713
- const controller = designHistoryControllers[domainId];
714
- const run = command === "undo" ? controller?.undo : controller?.redo;
715
- if (!run) return;
716
- Promise.resolve(run()).then((outcome) => {
717
- if (!isSavedPreviewHistoryOutcome(outcome)) return;
718
- if (command === "undo") previewDesignHistoryOrder.confirmUndo(domainId);
719
- else previewDesignHistoryOrder.confirmRedo(domainId);
720
- });
721
- }, [
722
- designHistoryCapabilities,
723
- designHistoryControllers,
724
- previewDesignHistoryOrder
725
- ]);
726
- const designHistoryBlocksChrome = Boolean(siteStyleHistory?.hasActiveStagedPreview) || previewDesignHistoryBlocksCommand(previewDesignHistoryOrder.state, "undo", designHistoryCapabilities) || previewDesignHistoryBlocksCommand(previewDesignHistoryOrder.state, "redo", designHistoryCapabilities);
727
- const historyDomains = useMemo(() => [previewDesignHistoryDomainFromControllers({
728
- orderState: previewDesignHistoryOrder.state,
729
- capabilities: designHistoryCapabilities,
730
- hasActiveStagedPreview: siteStyleHistory?.hasActiveStagedPreview ?? false,
731
- runCommand: runPreviewDesignHistoryCommand
732
- }), {
733
- id: "content",
734
- ownership: { kind: "fallback" },
735
- canUndo,
736
- canRedo,
737
- status: "idle",
738
- undo,
739
- redo
740
- }], [
741
- canRedo,
742
- canUndo,
743
- designHistoryCapabilities,
744
- previewDesignHistoryOrder.state,
745
- redo,
746
- runPreviewDesignHistoryCommand,
747
- siteStyleHistory?.hasActiveStagedPreview,
748
- undo
749
- ]);
750
- const historyControls = useMemo(() => designHistoryBlocksChrome ? disabledPreviewHistoryControls : previewUndoControlsForDomains(historyDomains, { kind: "chrome" }), [designHistoryBlocksChrome, historyDomains]);
751
- useEffect(() => {
752
- if (sessionHistory) return;
753
- const handleKeyDown = (event) => {
754
- const command = classifyHistoryShortcut(event, event.target);
755
- if (!command) return;
756
- const owner = previewUndoFocusOwnerForShortcutTarget(event.target);
757
- if (designHistoryBlocksChrome && owner === "preview-customize") {
758
- event.preventDefault();
759
- return;
760
- }
761
- const domain = selectPreviewUndoDomain(historyDomains, command, {
762
- kind: "shortcut",
763
- owner
764
- });
765
- if (!domain || domain.ownership.kind === "fallback") return;
766
- event.preventDefault();
767
- if (command === "undo") domain.undo();
768
- else domain.redo();
769
- };
770
- document.addEventListener("keydown", handleKeyDown, true);
771
- return () => {
772
- document.removeEventListener("keydown", handleKeyDown, true);
773
- };
774
- }, [
775
- designHistoryBlocksChrome,
776
- historyDomains,
777
- sessionHistory
778
- ]);
779
656
  useEffect(() => {
780
657
  if (!canEdit) {
781
658
  setPortalTarget(null);
@@ -822,65 +699,13 @@ function PreviewEditorChrome({ dashboardBaseUrl = null, inMaintenanceMode = fals
822
699
  lastSavedLabel: controller.formatSavedTime(lastSavedAt),
823
700
  draftSyncState,
824
701
  hasFailedSaves: combinedAutosave.hasFailedSaves,
825
- ...previewChromeHistoryProps(sessionHistory, historyControls)
702
+ ...sessionHistory
826
703
  }), portalTarget);
827
704
  }
828
705
  /** Editor chrome is portalled out of the sidebar's gate, so it carries its own write surface. */
829
706
  function createGatedPortal(chrome, target) {
830
707
  return createPortal(/* @__PURE__ */ jsx(EditorWriteSurface, { children: chrome }), target);
831
708
  }
832
- const disabledPreviewHistoryControls = {
833
- canUndo: false,
834
- canRedo: false,
835
- onUndo: () => {},
836
- onRedo: () => {}
837
- };
838
- function previewDesignHistoryDomainFromControllers(input) {
839
- const canUndo = Boolean(selectPreviewDesignHistoryDomain(input.orderState, "undo", input.capabilities));
840
- const canRedo = Boolean(selectPreviewDesignHistoryDomain(input.orderState, "redo", input.capabilities));
841
- return {
842
- id: "preview-design-history",
843
- ownership: input.orderState.past.length > 0 || input.orderState.future.length > 0 || input.hasActiveStagedPreview || canUndo || canRedo ? {
844
- kind: "focused",
845
- owner: "preview-customize"
846
- } : { kind: "available" },
847
- canUndo,
848
- canRedo,
849
- status: previewDesignHistoryAggregateStatus(input.capabilities),
850
- undo: () => {
851
- input.runCommand("undo");
852
- },
853
- redo: () => {
854
- input.runCommand("redo");
855
- }
856
- };
857
- }
858
- function previewDesignHistoryCapabilities(controller) {
859
- return {
860
- canUndo: controller?.canUndo ?? false,
861
- canRedo: controller?.canRedo ?? false,
862
- isPending: controller?.isHistoryPending || controller?.hasActiveStagedPreview ? true : false,
863
- isStale: controller?.isHistoryStale ?? false
864
- };
865
- }
866
- function previewDesignHistoryBlocksCommand(state, command, capabilities) {
867
- if (!previewDesignHistoryDomainForCommand(state, command)) return false;
868
- return !selectPreviewDesignHistoryDomain(state, command, capabilities);
869
- }
870
- function previewDesignHistoryAggregateStatus(capabilities) {
871
- const values = Object.values(capabilities);
872
- if (values.some((capability) => capability.isPending)) return "pending";
873
- if (values.some((capability) => capability.isStale)) return "stale";
874
- return "idle";
875
- }
876
- function isSavedPreviewHistoryOutcome(outcome) {
877
- return outcome !== null && typeof outcome === "object" && "kind" in outcome && outcome.kind === "saved";
878
- }
879
- function previewUndoFocusOwnerForShortcutTarget(target) {
880
- if (!(target instanceof HTMLElement)) return "preview-customize";
881
- if (target.closest("[data-preview-undo-owner=\"content\"]")) return "content";
882
- return "preview-customize";
883
- }
884
709
  /** The lifecycle owns failure presentation; only a completed discard refreshes the page. */
885
710
  function previewLifecycleHandlers(actions, refresh) {
886
711
  return {
@@ -902,11 +727,5 @@ function previewLifecycleHandlers(actions, refresh) {
902
727
  }
903
728
  };
904
729
  }
905
- function previewChromeHistoryProps(session, legacy) {
906
- return session ?? {
907
- historyControls: legacy,
908
- secondaryMessage: null
909
- };
910
- }
911
730
  //#endregion
912
731
  export { PreviewEditorUI };
@@ -1,3 +1,3 @@
1
1
  "use client";
2
- import { t as SdkPreviewModeRuntime } from "./SdkPreviewModeRuntime-BEfHln1E.mjs";
2
+ import { t as SdkPreviewModeRuntime } from "./SdkPreviewModeRuntime-DWwktlWs.mjs";
3
3
  export { SdkPreviewModeRuntime };