@homepages/concrete 7.0.0 → 9.0.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 (331) hide show
  1. package/CHANGELOG.md +1007 -0
  2. package/README.md +20 -9
  3. package/codemods/list-grammar.mjs +923 -0
  4. package/codemods/manifest.json +66 -0
  5. package/codemods/process-builders.mjs +198 -0
  6. package/codemods/slot-object.mjs +1097 -0
  7. package/codemods/steps/content-object-fields.mjs +324 -0
  8. package/codemods/steps/list-object-form.mjs +6 -7
  9. package/codemods/table-rows.mjs +568 -0
  10. package/codemods/unwrap-object-fields.mjs +310 -0
  11. package/codemods/viewer-slot-document.mjs +131 -0
  12. package/codemods/write-property-as-facts-document.mjs +716 -0
  13. package/codemods/write-the-address-line.mjs +255 -0
  14. package/codemods/write-the-registry-members.mjs +653 -0
  15. package/codemods/write-the-select-from.mjs +141 -0
  16. package/codemods/write-the-sole-from.mjs +369 -0
  17. package/codemods/write-the-table-from.mjs +267 -0
  18. package/codemods/write-the-whole-item.mjs +512 -0
  19. package/codemods/writeback-drop.mjs +168 -0
  20. package/codemods/written-contact-address.mjs +162 -0
  21. package/codemods/written-media-category.mjs +227 -0
  22. package/codemods/written-ref-kinds-name-the-layer.mjs +172 -0
  23. package/codemods/written-uploads-replace-pool-reads.mjs +454 -0
  24. package/codemods/written-uploads-sort-into-lists.mjs +405 -0
  25. package/codemods/written-uploads-stated-in-sorted-lists.mjs +295 -0
  26. package/codemods/written-video-sources-drop.mjs +144 -0
  27. package/codemods/written-without-pick-none.mjs +146 -0
  28. package/codemods/written-without-retired-knowledge.mjs +223 -0
  29. package/codemods/written-without-the-media-key.mjs +202 -0
  30. package/codemods/written-without-the-property-type.mjs +249 -0
  31. package/dist/artifact/playground/client/assets/index-BUmdDDX5.js +1259 -0
  32. package/dist/artifact/playground/client/assets/index-DDOcM0zA.css +1 -0
  33. package/dist/artifact/playground/client/index.html +2 -2
  34. package/dist/artifact/playground/client/island-canvas-host.mjs +1 -1
  35. package/dist/artifact/playground/host.mjs +61 -27
  36. package/dist/base.css +58 -1
  37. package/dist/cli/build/artifact.js +6 -9
  38. package/dist/cli/build/captures.js +2 -12
  39. package/dist/cli/build/esbuild.js +1 -25
  40. package/dist/cli/build/fixtures.js +2 -1
  41. package/dist/cli/build/icons.js +1 -1
  42. package/dist/cli/build/static.js +2 -2
  43. package/dist/cli/capture/capture.js +8 -9
  44. package/dist/cli/check/analyze.js +8 -1
  45. package/dist/cli/check/load-outdir.js +47 -0
  46. package/dist/cli/check/load-workspace.js +4 -4
  47. package/dist/cli/check/render/html.js +1 -2
  48. package/dist/cli/check/render/inputs.js +10 -3
  49. package/dist/cli/check/render/island-frames.js +2 -1
  50. package/dist/cli/check/render/marker-coverage.js +23 -15
  51. package/dist/cli/check/report.js +5 -0
  52. package/dist/cli/check/stages/bundles.js +1 -1
  53. package/dist/cli/check/stages/relations.js +1 -1
  54. package/dist/cli/check/stages/render.js +48 -33
  55. package/dist/cli/check/stages/sections.js +83 -31
  56. package/dist/cli/commands.js +1 -1
  57. package/dist/cli/dev/crop.js +1 -1
  58. package/dist/cli/dev/fixture-ladders.js +96 -0
  59. package/dist/cli/dev/islands.js +12 -123
  60. package/dist/cli/dev/listen.js +20 -1
  61. package/dist/cli/dev/load-template.js +1 -1
  62. package/dist/cli/dev/server.js +35 -10
  63. package/dist/cli/dev/vite.js +9 -7
  64. package/dist/cli/dev/workspace-reader.js +16 -16
  65. package/dist/cli/media/derive.js +43 -57
  66. package/dist/cli/media/frame-rung-floor.js +0 -1
  67. package/dist/cli/property/index.js +1 -6
  68. package/dist/css/inline.js +1 -22
  69. package/dist/eslint/rules/no-marker-literal.js +1 -1
  70. package/dist/fixtures/load.js +16 -7
  71. package/dist/fixtures/media-plugin.js +17 -12
  72. package/dist/fixtures/media-store.js +115 -0
  73. package/dist/fixtures/property.js +345 -126
  74. package/dist/fixtures/resolve.js +263 -251
  75. package/dist/fixtures/rows.js +4 -11
  76. package/dist/fixtures.d.ts +234 -109
  77. package/dist/index.d.ts +25 -16
  78. package/dist/index.js +10 -6
  79. package/dist/islands/marker.js +2 -1
  80. package/dist/packages/external/concrete/package.js +1 -1
  81. package/dist/packages/internal/canvas-core/dist/island-host.js +62 -0
  82. package/dist/packages/internal/canvas-core/dist/island-shields.js +30 -0
  83. package/dist/packages/internal/capture-settle/dist/index.js +3 -0
  84. package/dist/packages/internal/capture-settle/dist/island-markers.d.ts +13 -0
  85. package/dist/packages/internal/capture-settle/dist/island-markers.js +6 -0
  86. package/dist/packages/internal/capture-settle/dist/settle.js +150 -0
  87. package/dist/packages/internal/{image-ladder/dist/crop.js → crop-region/dist/index.js} +21 -20
  88. package/dist/packages/internal/fill-bake/dist/bake-property-ref.js +252 -35
  89. package/dist/packages/internal/fill-bake/dist/compute-reads.js +365 -4
  90. package/dist/packages/internal/fill-bake/dist/derive-source.js +35 -21
  91. package/dist/packages/internal/fill-bake/dist/index.js +8 -3
  92. package/dist/packages/internal/fill-bake/dist/item-merge.js +119 -0
  93. package/dist/packages/internal/fill-bake/dist/item-overrides.js +28 -0
  94. package/dist/packages/internal/fill-bake/dist/linked-merge.js +40 -0
  95. package/dist/packages/internal/fill-bake/dist/list-grammar.js +175 -0
  96. package/dist/packages/internal/fill-vocabulary/dist/holder.js +51 -0
  97. package/dist/packages/internal/fill-vocabulary/dist/resolved-decision.js +390 -0
  98. package/dist/packages/internal/fill-vocabulary/dist/row-planners.js +1 -23
  99. package/dist/packages/internal/fill-vocabulary/dist/row-reads.js +1 -1
  100. package/dist/packages/internal/fill-vocabulary/dist/verbs.js +75 -0
  101. package/dist/packages/internal/format-geometry/dist/capture.js +11 -147
  102. package/dist/packages/internal/format-geometry/dist/format.d.ts +8 -2
  103. package/dist/packages/internal/format-geometry/dist/geometry.js +13 -2
  104. package/dist/packages/internal/image-ladder/dist/encode.js +27 -14
  105. package/dist/packages/internal/image-ladder/dist/index.js +3 -3
  106. package/dist/packages/internal/image-ladder/dist/policy.js +28 -53
  107. package/dist/packages/internal/island-runtime/dist/capture-holds.js +1 -1
  108. package/dist/packages/internal/island-runtime/dist/contract.d.ts +3 -12
  109. package/dist/packages/internal/island-runtime/dist/contract.js +2 -2
  110. package/dist/packages/internal/island-runtime/dist/index.d.ts +3 -7
  111. package/dist/packages/internal/island-runtime/dist/index.js +2 -1
  112. package/dist/packages/internal/island-runtime/dist/viewport-schedule.js +1 -1
  113. package/dist/packages/internal/media-resolution/dist/crop-key.js +7 -0
  114. package/dist/packages/internal/media-resolution/dist/document.js +63 -0
  115. package/dist/packages/internal/media-resolution/dist/image.js +228 -0
  116. package/dist/packages/internal/media-resolution/dist/index.js +11 -0
  117. package/dist/packages/internal/media-resolution/dist/list.js +112 -0
  118. package/dist/packages/internal/media-resolution/dist/media.js +59 -0
  119. package/dist/packages/internal/media-resolution/dist/records.js +7 -0
  120. package/dist/packages/internal/media-resolution/dist/slot.js +34 -0
  121. package/dist/packages/internal/media-resolution/dist/store.js +19 -0
  122. package/dist/packages/internal/media-resolution/dist/tour.js +59 -0
  123. package/dist/packages/internal/media-resolution/dist/video.js +93 -0
  124. package/dist/packages/internal/property-facts/dist/registry-facts.js +244 -0
  125. package/dist/packages/internal/section-contracts/dist/cap-contract.js +8 -17
  126. package/dist/packages/internal/section-contracts/dist/catalog.js +35 -27
  127. package/dist/packages/internal/section-contracts/dist/count-bounds-contract.js +11 -2
  128. package/dist/packages/internal/section-contracts/dist/directly-linked-list-contract.js +27 -0
  129. package/dist/packages/internal/section-contracts/dist/fill-options.js +12 -0
  130. package/dist/packages/internal/section-contracts/dist/fill-spec-view.js +1 -0
  131. package/dist/packages/internal/section-contracts/dist/fill-verb-contract.js +95 -0
  132. package/dist/packages/internal/section-contracts/dist/grammar-scope.js +154 -0
  133. package/dist/packages/internal/section-contracts/dist/index.js +7 -5
  134. package/dist/packages/internal/section-contracts/dist/list-fill-contract.js +23 -19
  135. package/dist/packages/internal/section-contracts/dist/list-scalar-contract.js +12 -7
  136. package/dist/packages/internal/section-contracts/dist/list-source-contract.js +46 -0
  137. package/dist/packages/internal/section-contracts/dist/nested-slot-contract.js +11 -2
  138. package/dist/packages/internal/section-contracts/dist/object-contract.js +92 -0
  139. package/dist/packages/internal/section-contracts/dist/poi-curation-contract.js +5 -5
  140. package/dist/packages/internal/section-contracts/dist/reads-acyclic-contract.js +63 -0
  141. package/dist/packages/internal/section-contracts/dist/row-fill-contract.js +7 -4
  142. package/dist/packages/internal/section-contracts/dist/row-rule-contract.js +83 -0
  143. package/dist/packages/internal/section-contracts/dist/row-source-contract.js +67 -0
  144. package/dist/packages/internal/section-contracts/dist/runners.js +77 -33
  145. package/dist/packages/internal/section-contracts/dist/select-contract.js +0 -8
  146. package/dist/packages/internal/section-contracts/dist/source-contract.js +120 -66
  147. package/dist/packages/internal/section-contracts/dist/sources-contract.js +47 -17
  148. package/dist/packages/internal/section-contracts/dist/table-member.js +16 -0
  149. package/dist/packages/internal/section-contracts/dist/writer-reads-fact-contract.js +43 -18
  150. package/dist/packages/internal/source-resolution/dist/index.js +113 -118
  151. package/dist/packages/internal/static-assets-binding/dist/section-asset-url.js +16 -0
  152. package/dist/packages/internal/street-address/dist/index.js +72 -0
  153. package/dist/packages/internal/template-artifact/dist/asset-mime.js +30 -0
  154. package/dist/packages/internal/template-artifact/dist/layout.js +1 -2
  155. package/dist/packages/internal/template-artifact/dist/manifest.js +1 -1
  156. package/dist/packages/internal/template-artifact/dist/verify.js +12 -29
  157. package/dist/packages/internal/template-contracts/dist/address-value.d.ts +52 -0
  158. package/dist/packages/internal/template-contracts/dist/address-value.js +90 -0
  159. package/dist/packages/internal/template-contracts/dist/comparable-address.js +19 -0
  160. package/dist/{schema → packages/internal/template-contracts/dist}/compute.d.ts +29 -6
  161. package/dist/{schema → packages/internal/template-contracts/dist}/compute.js +11 -13
  162. package/dist/packages/internal/template-contracts/dist/content-pick.js +51 -0
  163. package/dist/packages/internal/template-contracts/dist/decision-fills.js +85 -0
  164. package/dist/packages/internal/template-contracts/dist/display-overrides.js +7 -0
  165. package/dist/packages/internal/template-contracts/dist/document-value.d.ts +16 -5
  166. package/dist/packages/internal/template-contracts/dist/fact-compute.d.ts +24 -0
  167. package/dist/packages/internal/template-contracts/dist/fact-compute.js +30 -0
  168. package/dist/packages/internal/template-contracts/dist/fact-keys.d.ts +44 -0
  169. package/dist/packages/internal/template-contracts/dist/fact-keys.js +88 -0
  170. package/dist/packages/internal/template-contracts/dist/fact-registry.d.ts +290 -0
  171. package/dist/packages/internal/template-contracts/dist/fact-registry.js +598 -0
  172. package/dist/packages/internal/template-contracts/dist/facts-view.d.ts +12 -36
  173. package/dist/packages/internal/template-contracts/dist/fill-builders.d.ts +157 -0
  174. package/dist/packages/internal/template-contracts/dist/fill-builders.js +79 -0
  175. package/dist/packages/internal/template-contracts/dist/fill-declaration.d.ts +14 -0
  176. package/dist/{schema → packages/internal/template-contracts/dist}/fill-declaration.js +6 -5
  177. package/dist/packages/internal/template-contracts/dist/fill-spec-schema.js +158 -0
  178. package/dist/packages/internal/template-contracts/dist/fill-spec.js +291 -0
  179. package/dist/packages/internal/template-contracts/dist/findable.js +8 -0
  180. package/dist/packages/internal/template-contracts/dist/floor-presets.js +13 -0
  181. package/dist/packages/internal/template-contracts/dist/icon-names.d.ts +5 -0
  182. package/dist/packages/internal/template-contracts/dist/icon-names.js +70 -0
  183. package/dist/packages/internal/template-contracts/dist/legacy-facts.js +167 -0
  184. package/dist/packages/internal/template-contracts/dist/list-editing.js +94 -0
  185. package/dist/packages/internal/template-contracts/dist/list.d.ts +215 -0
  186. package/dist/packages/internal/template-contracts/dist/list.js +258 -0
  187. package/dist/packages/internal/template-contracts/dist/markers.d.ts +2 -2
  188. package/dist/packages/internal/template-contracts/dist/media-candidates.js +38 -0
  189. package/dist/packages/internal/template-contracts/dist/mirror-kind.js +48 -0
  190. package/dist/packages/internal/template-contracts/dist/number-display.js +10 -0
  191. package/dist/packages/internal/template-contracts/dist/object.d.ts +89 -0
  192. package/dist/packages/internal/template-contracts/dist/object.js +131 -0
  193. package/dist/packages/internal/template-contracts/dist/poi-row.d.ts +1 -1
  194. package/dist/packages/internal/template-contracts/dist/primitive-descriptors.d.ts +1 -0
  195. package/dist/packages/internal/template-contracts/dist/primitive-descriptors.js +162 -0
  196. package/dist/packages/internal/template-contracts/dist/process-builders.d.ts +77 -0
  197. package/dist/packages/internal/template-contracts/dist/process-builders.js +73 -0
  198. package/dist/packages/internal/template-contracts/dist/read-graph.js +250 -0
  199. package/dist/packages/internal/template-contracts/dist/ref-locate.js +192 -0
  200. package/dist/packages/internal/template-contracts/dist/registry-aliases.js +77 -0
  201. package/dist/packages/internal/template-contracts/dist/registry-facts.d.ts +268 -0
  202. package/dist/packages/internal/template-contracts/dist/registry-facts.js +202 -0
  203. package/dist/packages/internal/template-contracts/dist/registry-shape.d.ts +41 -0
  204. package/dist/packages/internal/template-contracts/dist/registry-shape.js +135 -0
  205. package/dist/packages/internal/template-contracts/dist/resolve-scope.js +103 -0
  206. package/dist/packages/internal/{image-descriptor/dist/index.d.ts → template-contracts/dist/responsive-image.d.ts} +1 -1
  207. package/dist/packages/internal/template-contracts/dist/row-planners.js +29 -0
  208. package/dist/packages/internal/template-contracts/dist/row-ref.d.ts +133 -0
  209. package/dist/packages/internal/template-contracts/dist/row-ref.js +101 -0
  210. package/dist/packages/internal/template-contracts/dist/row-sources.js +48 -8
  211. package/dist/packages/internal/template-contracts/dist/row.d.ts +155 -0
  212. package/dist/packages/internal/template-contracts/dist/row.js +84 -0
  213. package/dist/packages/internal/template-contracts/dist/runtime-values.d.ts +97 -0
  214. package/dist/packages/internal/template-contracts/dist/slot-builders.d.ts +782 -0
  215. package/dist/packages/internal/template-contracts/dist/slot-builders.js +233 -0
  216. package/dist/packages/internal/template-contracts/dist/slot-catalog.d.ts +243 -384
  217. package/dist/packages/internal/template-contracts/dist/slot-catalog.js +334 -230
  218. package/dist/packages/internal/template-contracts/dist/slot-overrides.js +21 -0
  219. package/dist/packages/internal/template-contracts/dist/slot-ref.d.ts +155 -0
  220. package/dist/packages/internal/template-contracts/dist/slot-ref.js +76 -0
  221. package/dist/packages/internal/template-contracts/dist/slot-types.d.ts +163 -0
  222. package/dist/packages/internal/template-contracts/dist/slot-types.js +140 -0
  223. package/dist/packages/internal/template-contracts/dist/slot-value.d.ts +97 -0
  224. package/dist/packages/internal/template-contracts/dist/table-members.d.ts +25 -0
  225. package/dist/packages/internal/template-contracts/dist/table-members.js +90 -0
  226. package/dist/packages/internal/template-contracts/dist/tour-value.d.ts +5 -5
  227. package/dist/packages/internal/template-contracts/dist/value-contracts.js +15 -0
  228. package/dist/packages/internal/template-contracts/dist/video-value.d.ts +2 -2
  229. package/dist/platform/fs.js +5 -2
  230. package/dist/playground/canvas-island-host.d.ts +11 -0
  231. package/dist/playground/canvas-island-host.js +29 -0
  232. package/dist/playground/canvas-markers.js +14 -0
  233. package/dist/playground-island-runtime.d.ts +3 -2
  234. package/dist/playground-island-runtime.js +3 -2
  235. package/dist/primitives/FrameShell.js +0 -1
  236. package/dist/primitives/Image.d.ts +5 -4
  237. package/dist/primitives/Tour.d.ts +1 -1
  238. package/dist/primitives/Video.d.ts +2 -2
  239. package/dist/primitives/index.d.ts +2 -3
  240. package/dist/primitives/picture-sources.js +2 -2
  241. package/dist/primitives/probe-context.js +2 -12
  242. package/dist/primitives/slot-address.d.ts +44 -0
  243. package/dist/primitives/slot-address.js +19 -0
  244. package/dist/primitives/slot-bindings.d.ts +65 -26
  245. package/dist/primitives/slot-bindings.js +104 -46
  246. package/dist/primitives/slot-document.d.ts +23 -18
  247. package/dist/primitives/slot-document.js +39 -14
  248. package/dist/primitives/slot-download.d.ts +39 -0
  249. package/dist/primitives/slot-download.js +39 -0
  250. package/dist/primitives/slot-list.d.ts +3 -3
  251. package/dist/primitives/slot-list.js +0 -2
  252. package/dist/primitives/slot-media.d.ts +24 -5
  253. package/dist/primitives/slot-media.js +6 -9
  254. package/dist/primitives/slot-object.d.ts +49 -0
  255. package/dist/primitives/slot-object.js +20 -0
  256. package/dist/primitives/slot-scalar.d.ts +27 -2
  257. package/dist/primitives/slot-scalar.js +50 -7
  258. package/dist/primitives/slot.d.ts +13 -6
  259. package/dist/primitives/slot.js +10 -3
  260. package/dist/rules/registry.js +19 -30
  261. package/dist/schema/define-schema.d.ts +4 -8
  262. package/dist/schema/define-schema.js +178 -79
  263. package/dist/schema/extract-fill-spec.js +2 -158
  264. package/dist/schema/fact.d.ts +57 -15
  265. package/dist/schema/fact.js +42 -7
  266. package/dist/schema/facts-view.d.ts +14 -0
  267. package/dist/schema/format.d.ts +1 -0
  268. package/dist/schema/format.js +2 -1
  269. package/dist/schema/manifest.js +24 -0
  270. package/dist/schema/property-facts.d.ts +8 -11
  271. package/dist/schema/section-props.d.ts +2 -66
  272. package/dist/schema/section-schema.d.ts +8 -11
  273. package/dist/schema/section-schema.js +27 -10
  274. package/dist/section/declare.d.ts +18 -7
  275. package/dist/section/declare.js +18 -5
  276. package/dist/section/materialize.js +3 -8
  277. package/dist/section/section.d.ts +12 -8
  278. package/dist/section/section.js +1 -1
  279. package/dist/template/logic-shim.d.ts +14 -7
  280. package/dist/template/logic-shim.js +14 -7
  281. package/dist/template/materialize.js +17 -18
  282. package/dist/template/mirror-types.js +30 -31
  283. package/dist/template/section-reads.js +85 -9
  284. package/guide/reference/cli/INDEX.md +2 -2
  285. package/guide/reference/cli/build.md +1 -1
  286. package/guide/reference/cli/check.md +1 -1
  287. package/guide/reference/cli/dev.md +1 -1
  288. package/guide/reference/cli/property-add.md +1 -1
  289. package/guide/reference/cli/property-list.md +2 -2
  290. package/guide/reference/cli/publish.md +1 -1
  291. package/guide/reference/cli/upgrade.md +1 -1
  292. package/guide/reference/rules/INDEX.md +29 -29
  293. package/package.json +9 -8
  294. package/dist/artifact/playground/client/assets/index-CckS2ONm.css +0 -1
  295. package/dist/artifact/playground/client/assets/index-D8eepVr-.js +0 -1101
  296. package/dist/fixtures/canonical.d.ts +0 -166
  297. package/dist/fixtures/media.js +0 -163
  298. package/dist/packages/internal/fill-vocabulary/dist/origination.js +0 -111
  299. package/dist/packages/internal/format-geometry/dist/index.js +0 -4
  300. package/dist/packages/internal/property-facts/dist/derive-facts-view.js +0 -10
  301. package/dist/packages/internal/property-facts/dist/index.js +0 -3
  302. package/dist/packages/internal/property-facts/dist/property-facts-Cy7-O4p0.js +0 -189
  303. package/dist/packages/internal/section-contracts/dist/choose-select-contract.js +0 -20
  304. package/dist/packages/internal/section-contracts/dist/name-title-contract.js +0 -20
  305. package/dist/packages/internal/section-contracts/dist/pooling-field-contract.js +0 -22
  306. package/dist/packages/internal/section-contracts/dist/record-collection-contract.js +0 -24
  307. package/dist/packages/internal/section-contracts/dist/source-filter-contract.js +0 -15
  308. package/dist/packages/internal/template-contracts/dist/collection-editing.js +0 -22
  309. package/dist/packages/internal/template-contracts/dist/facts-view.js +0 -111
  310. package/dist/packages/internal/template-contracts/dist/select-key.js +0 -7
  311. package/dist/primitives/slot-group.d.ts +0 -40
  312. package/dist/primitives/slot-group.js +0 -36
  313. package/dist/schema/extract-used-facts.js +0 -34
  314. package/dist/schema/fill-builders.d.ts +0 -115
  315. package/dist/schema/fill-builders.js +0 -25
  316. package/dist/schema/fill-declaration.d.ts +0 -14
  317. package/dist/schema/fill-spec.js +0 -89
  318. package/dist/schema/layout.d.ts +0 -30
  319. package/dist/schema/layout.js +0 -14
  320. package/dist/schema/row-fields.js +0 -88
  321. package/dist/schema/row-ref.d.ts +0 -59
  322. package/dist/schema/row-ref.js +0 -28
  323. package/dist/schema/runtime-values.d.ts +0 -71
  324. package/dist/schema/section-nav.js +0 -14
  325. package/dist/schema/slot-builders.d.ts +0 -613
  326. package/dist/schema/slot-builders.js +0 -177
  327. package/dist/schema/slot-ref.d.ts +0 -79
  328. package/dist/schema/slot-ref.js +0 -41
  329. package/dist/schema/slot-types.d.ts +0 -111
  330. package/dist/schema/slot-types.js +0 -214
  331. package/dist/section/groups.js +0 -68
@@ -1,1101 +0,0 @@
1
- var xg=n=>{throw TypeError(n)};var Ad=(n,l,s)=>l.has(n)||xg("Cannot "+s);var S=(n,l,s)=>(Ad(n,l,"read from private field"),s?s.call(n):l.get(n)),be=(n,l,s)=>l.has(n)?xg("Cannot add the same private member more than once"):l instanceof WeakSet?l.add(n):l.set(n,s),fe=(n,l,s,o)=>(Ad(n,l,"write to private field"),o?o.call(n,s):l.set(n,s),s),je=(n,l,s)=>(Ad(n,l,"access private method"),s);var Ir=(n,l,s,o)=>({set _(u){fe(n,l,u,s)},get _(){return S(n,l,o)}});(function(){const l=document.createElement("link").relList;if(l&&l.supports&&l.supports("modulepreload"))return;for(const u of document.querySelectorAll('link[rel="modulepreload"]'))o(u);new MutationObserver(u=>{for(const d of u)if(d.type==="childList")for(const h of d.addedNodes)h.tagName==="LINK"&&h.rel==="modulepreload"&&o(h)}).observe(document,{childList:!0,subtree:!0});function s(u){const d={};return u.integrity&&(d.integrity=u.integrity),u.referrerPolicy&&(d.referrerPolicy=u.referrerPolicy),u.crossOrigin==="use-credentials"?d.credentials="include":u.crossOrigin==="anonymous"?d.credentials="omit":d.credentials="same-origin",d}function o(u){if(u.ep)return;u.ep=!0;const d=s(u);fetch(u.href,d)}})();function j_(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Nd={exports:{}},to={};/**
2
- * @license React
3
- * react-jsx-runtime.production.js
4
- *
5
- * Copyright (c) Meta Platforms, Inc. and affiliates.
6
- *
7
- * This source code is licensed under the MIT license found in the
8
- * LICENSE file in the root directory of this source tree.
9
- */var _g;function M_(){if(_g)return to;_g=1;var n=Symbol.for("react.transitional.element"),l=Symbol.for("react.fragment");function s(o,u,d){var h=null;if(d!==void 0&&(h=""+d),u.key!==void 0&&(h=""+u.key),"key"in u){d={};for(var p in u)p!=="key"&&(d[p]=u[p])}else d=u;return u=d.ref,{$$typeof:n,type:o,key:h,ref:u!==void 0?u:null,props:d}}return to.Fragment=l,to.jsx=s,to.jsxs=s,to}var wg;function C_(){return wg||(wg=1,Nd.exports=M_()),Nd.exports}var f=C_(),Td={exports:{}},Ne={};/**
10
- * @license React
11
- * react.production.js
12
- *
13
- * Copyright (c) Meta Platforms, Inc. and affiliates.
14
- *
15
- * This source code is licensed under the MIT license found in the
16
- * LICENSE file in the root directory of this source tree.
17
- */var Sg;function A_(){if(Sg)return Ne;Sg=1;var n=Symbol.for("react.transitional.element"),l=Symbol.for("react.portal"),s=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),u=Symbol.for("react.profiler"),d=Symbol.for("react.consumer"),h=Symbol.for("react.context"),p=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),g=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),v=Symbol.for("react.activity"),E=Symbol.iterator;function M(k){return k===null||typeof k!="object"?null:(k=E&&k[E]||k["@@iterator"],typeof k=="function"?k:null)}var N={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},A=Object.assign,j={};function O(k,I,$){this.props=k,this.context=I,this.refs=j,this.updater=$||N}O.prototype.isReactComponent={},O.prototype.setState=function(k,I){if(typeof k!="object"&&typeof k!="function"&&k!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,k,I,"setState")},O.prototype.forceUpdate=function(k){this.updater.enqueueForceUpdate(this,k,"forceUpdate")};function z(){}z.prototype=O.prototype;function D(k,I,$){this.props=k,this.context=I,this.refs=j,this.updater=$||N}var Y=D.prototype=new z;Y.constructor=D,A(Y,O.prototype),Y.isPureReactComponent=!0;var W=Array.isArray;function ee(){}var ae={H:null,A:null,T:null,S:null},U=Object.prototype.hasOwnProperty;function re(k,I,$){var T=$.ref;return{$$typeof:n,type:k,key:I,ref:T!==void 0?T:null,props:$}}function de(k,I){return re(k.type,I,k.props)}function ce(k){return typeof k=="object"&&k!==null&&k.$$typeof===n}function ie(k){var I={"=":"=0",":":"=2"};return"$"+k.replace(/[=:]/g,function($){return I[$]})}var L=/\/+/g;function G(k,I){return typeof k=="object"&&k!==null&&k.key!=null?ie(""+k.key):I.toString(36)}function F(k){switch(k.status){case"fulfilled":return k.value;case"rejected":throw k.reason;default:switch(typeof k.status=="string"?k.then(ee,ee):(k.status="pending",k.then(function(I){k.status==="pending"&&(k.status="fulfilled",k.value=I)},function(I){k.status==="pending"&&(k.status="rejected",k.reason=I)})),k.status){case"fulfilled":return k.value;case"rejected":throw k.reason}}throw k}function w(k,I,$,T,B){var q=typeof k;(q==="undefined"||q==="boolean")&&(k=null);var V=!1;if(k===null)V=!0;else switch(q){case"bigint":case"string":case"number":V=!0;break;case"object":switch(k.$$typeof){case n:case l:V=!0;break;case x:return V=k._init,w(V(k._payload),I,$,T,B)}}if(V)return B=B(k),V=T===""?"."+G(k,0):T,W(B)?($="",V!=null&&($=V.replace(L,"$&/")+"/"),w(B,I,$,"",function(ke){return ke})):B!=null&&(ce(B)&&(B=de(B,$+(B.key==null||k&&k.key===B.key?"":(""+B.key).replace(L,"$&/")+"/")+V)),I.push(B)),1;V=0;var me=T===""?".":T+":";if(W(k))for(var he=0;he<k.length;he++)T=k[he],q=me+G(T,he),V+=w(T,I,$,q,B);else if(he=M(k),typeof he=="function")for(k=he.call(k),he=0;!(T=k.next()).done;)T=T.value,q=me+G(T,he++),V+=w(T,I,$,q,B);else if(q==="object"){if(typeof k.then=="function")return w(F(k),I,$,T,B);throw I=String(k),Error("Objects are not valid as a React child (found: "+(I==="[object Object]"?"object with keys {"+Object.keys(k).join(", ")+"}":I)+"). If you meant to render a collection of children, use an array instead.")}return V}function Z(k,I,$){if(k==null)return k;var T=[],B=0;return w(k,T,"","",function(q){return I.call($,q,B++)}),T}function ue(k){if(k._status===-1){var I=k._result;I=I(),I.then(function($){(k._status===0||k._status===-1)&&(k._status=1,k._result=$)},function($){(k._status===0||k._status===-1)&&(k._status=2,k._result=$)}),k._status===-1&&(k._status=0,k._result=I)}if(k._status===1)return k._result.default;throw k._result}var te=typeof reportError=="function"?reportError:function(k){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var I=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof k=="object"&&k!==null&&typeof k.message=="string"?String(k.message):String(k),error:k});if(!window.dispatchEvent(I))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",k);return}console.error(k)},P={map:Z,forEach:function(k,I,$){Z(k,function(){I.apply(this,arguments)},$)},count:function(k){var I=0;return Z(k,function(){I++}),I},toArray:function(k){return Z(k,function(I){return I})||[]},only:function(k){if(!ce(k))throw Error("React.Children.only expected to receive a single React element child.");return k}};return Ne.Activity=v,Ne.Children=P,Ne.Component=O,Ne.Fragment=s,Ne.Profiler=u,Ne.PureComponent=D,Ne.StrictMode=o,Ne.Suspense=y,Ne.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=ae,Ne.__COMPILER_RUNTIME={__proto__:null,c:function(k){return ae.H.useMemoCache(k)}},Ne.cache=function(k){return function(){return k.apply(null,arguments)}},Ne.cacheSignal=function(){return null},Ne.cloneElement=function(k,I,$){if(k==null)throw Error("The argument must be a React element, but you passed "+k+".");var T=A({},k.props),B=k.key;if(I!=null)for(q in I.key!==void 0&&(B=""+I.key),I)!U.call(I,q)||q==="key"||q==="__self"||q==="__source"||q==="ref"&&I.ref===void 0||(T[q]=I[q]);var q=arguments.length-2;if(q===1)T.children=$;else if(1<q){for(var V=Array(q),me=0;me<q;me++)V[me]=arguments[me+2];T.children=V}return re(k.type,B,T)},Ne.createContext=function(k){return k={$$typeof:h,_currentValue:k,_currentValue2:k,_threadCount:0,Provider:null,Consumer:null},k.Provider=k,k.Consumer={$$typeof:d,_context:k},k},Ne.createElement=function(k,I,$){var T,B={},q=null;if(I!=null)for(T in I.key!==void 0&&(q=""+I.key),I)U.call(I,T)&&T!=="key"&&T!=="__self"&&T!=="__source"&&(B[T]=I[T]);var V=arguments.length-2;if(V===1)B.children=$;else if(1<V){for(var me=Array(V),he=0;he<V;he++)me[he]=arguments[he+2];B.children=me}if(k&&k.defaultProps)for(T in V=k.defaultProps,V)B[T]===void 0&&(B[T]=V[T]);return re(k,q,B)},Ne.createRef=function(){return{current:null}},Ne.forwardRef=function(k){return{$$typeof:p,render:k}},Ne.isValidElement=ce,Ne.lazy=function(k){return{$$typeof:x,_payload:{_status:-1,_result:k},_init:ue}},Ne.memo=function(k,I){return{$$typeof:g,type:k,compare:I===void 0?null:I}},Ne.startTransition=function(k){var I=ae.T,$={};ae.T=$;try{var T=k(),B=ae.S;B!==null&&B($,T),typeof T=="object"&&T!==null&&typeof T.then=="function"&&T.then(ee,te)}catch(q){te(q)}finally{I!==null&&$.types!==null&&(I.types=$.types),ae.T=I}},Ne.unstable_useCacheRefresh=function(){return ae.H.useCacheRefresh()},Ne.use=function(k){return ae.H.use(k)},Ne.useActionState=function(k,I,$){return ae.H.useActionState(k,I,$)},Ne.useCallback=function(k,I){return ae.H.useCallback(k,I)},Ne.useContext=function(k){return ae.H.useContext(k)},Ne.useDebugValue=function(){},Ne.useDeferredValue=function(k,I){return ae.H.useDeferredValue(k,I)},Ne.useEffect=function(k,I){return ae.H.useEffect(k,I)},Ne.useEffectEvent=function(k){return ae.H.useEffectEvent(k)},Ne.useId=function(){return ae.H.useId()},Ne.useImperativeHandle=function(k,I,$){return ae.H.useImperativeHandle(k,I,$)},Ne.useInsertionEffect=function(k,I){return ae.H.useInsertionEffect(k,I)},Ne.useLayoutEffect=function(k,I){return ae.H.useLayoutEffect(k,I)},Ne.useMemo=function(k,I){return ae.H.useMemo(k,I)},Ne.useOptimistic=function(k,I){return ae.H.useOptimistic(k,I)},Ne.useReducer=function(k,I,$){return ae.H.useReducer(k,I,$)},Ne.useRef=function(k){return ae.H.useRef(k)},Ne.useState=function(k){return ae.H.useState(k)},Ne.useSyncExternalStore=function(k,I,$){return ae.H.useSyncExternalStore(k,I,$)},Ne.useTransition=function(){return ae.H.useTransition()},Ne.version="19.2.6",Ne}var kg;function Gf(){return kg||(kg=1,Td.exports=A_()),Td.exports}var _=Gf();const Qr=j_(_);var Od={exports:{}},no={},Rd={exports:{}},zd={};/**
18
- * @license React
19
- * scheduler.production.js
20
- *
21
- * Copyright (c) Meta Platforms, Inc. and affiliates.
22
- *
23
- * This source code is licensed under the MIT license found in the
24
- * LICENSE file in the root directory of this source tree.
25
- */var Eg;function N_(){return Eg||(Eg=1,(function(n){function l(w,Z){var ue=w.length;w.push(Z);e:for(;0<ue;){var te=ue-1>>>1,P=w[te];if(0<u(P,Z))w[te]=Z,w[ue]=P,ue=te;else break e}}function s(w){return w.length===0?null:w[0]}function o(w){if(w.length===0)return null;var Z=w[0],ue=w.pop();if(ue!==Z){w[0]=ue;e:for(var te=0,P=w.length,k=P>>>1;te<k;){var I=2*(te+1)-1,$=w[I],T=I+1,B=w[T];if(0>u($,ue))T<P&&0>u(B,$)?(w[te]=B,w[T]=ue,te=T):(w[te]=$,w[I]=ue,te=I);else if(T<P&&0>u(B,ue))w[te]=B,w[T]=ue,te=T;else break e}}return Z}function u(w,Z){var ue=w.sortIndex-Z.sortIndex;return ue!==0?ue:w.id-Z.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var d=performance;n.unstable_now=function(){return d.now()}}else{var h=Date,p=h.now();n.unstable_now=function(){return h.now()-p}}var y=[],g=[],x=1,v=null,E=3,M=!1,N=!1,A=!1,j=!1,O=typeof setTimeout=="function"?setTimeout:null,z=typeof clearTimeout=="function"?clearTimeout:null,D=typeof setImmediate<"u"?setImmediate:null;function Y(w){for(var Z=s(g);Z!==null;){if(Z.callback===null)o(g);else if(Z.startTime<=w)o(g),Z.sortIndex=Z.expirationTime,l(y,Z);else break;Z=s(g)}}function W(w){if(A=!1,Y(w),!N)if(s(y)!==null)N=!0,ee||(ee=!0,ie());else{var Z=s(g);Z!==null&&F(W,Z.startTime-w)}}var ee=!1,ae=-1,U=5,re=-1;function de(){return j?!0:!(n.unstable_now()-re<U)}function ce(){if(j=!1,ee){var w=n.unstable_now();re=w;var Z=!0;try{e:{N=!1,A&&(A=!1,z(ae),ae=-1),M=!0;var ue=E;try{t:{for(Y(w),v=s(y);v!==null&&!(v.expirationTime>w&&de());){var te=v.callback;if(typeof te=="function"){v.callback=null,E=v.priorityLevel;var P=te(v.expirationTime<=w);if(w=n.unstable_now(),typeof P=="function"){v.callback=P,Y(w),Z=!0;break t}v===s(y)&&o(y),Y(w)}else o(y);v=s(y)}if(v!==null)Z=!0;else{var k=s(g);k!==null&&F(W,k.startTime-w),Z=!1}}break e}finally{v=null,E=ue,M=!1}Z=void 0}}finally{Z?ie():ee=!1}}}var ie;if(typeof D=="function")ie=function(){D(ce)};else if(typeof MessageChannel<"u"){var L=new MessageChannel,G=L.port2;L.port1.onmessage=ce,ie=function(){G.postMessage(null)}}else ie=function(){O(ce,0)};function F(w,Z){ae=O(function(){w(n.unstable_now())},Z)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(w){w.callback=null},n.unstable_forceFrameRate=function(w){0>w||125<w?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):U=0<w?Math.floor(1e3/w):5},n.unstable_getCurrentPriorityLevel=function(){return E},n.unstable_next=function(w){switch(E){case 1:case 2:case 3:var Z=3;break;default:Z=E}var ue=E;E=Z;try{return w()}finally{E=ue}},n.unstable_requestPaint=function(){j=!0},n.unstable_runWithPriority=function(w,Z){switch(w){case 1:case 2:case 3:case 4:case 5:break;default:w=3}var ue=E;E=w;try{return Z()}finally{E=ue}},n.unstable_scheduleCallback=function(w,Z,ue){var te=n.unstable_now();switch(typeof ue=="object"&&ue!==null?(ue=ue.delay,ue=typeof ue=="number"&&0<ue?te+ue:te):ue=te,w){case 1:var P=-1;break;case 2:P=250;break;case 5:P=1073741823;break;case 4:P=1e4;break;default:P=5e3}return P=ue+P,w={id:x++,callback:Z,priorityLevel:w,startTime:ue,expirationTime:P,sortIndex:-1},ue>te?(w.sortIndex=ue,l(g,w),s(y)===null&&w===s(g)&&(A?(z(ae),ae=-1):A=!0,F(W,ue-te))):(w.sortIndex=P,l(y,w),N||M||(N=!0,ee||(ee=!0,ie()))),w},n.unstable_shouldYield=de,n.unstable_wrapCallback=function(w){var Z=E;return function(){var ue=E;E=Z;try{return w.apply(this,arguments)}finally{E=ue}}}})(zd)),zd}var jg;function T_(){return jg||(jg=1,Rd.exports=N_()),Rd.exports}var Dd={exports:{}},Bt={};/**
26
- * @license React
27
- * react-dom.production.js
28
- *
29
- * Copyright (c) Meta Platforms, Inc. and affiliates.
30
- *
31
- * This source code is licensed under the MIT license found in the
32
- * LICENSE file in the root directory of this source tree.
33
- */var Mg;function O_(){if(Mg)return Bt;Mg=1;var n=Gf();function l(y){var g="https://react.dev/errors/"+y;if(1<arguments.length){g+="?args[]="+encodeURIComponent(arguments[1]);for(var x=2;x<arguments.length;x++)g+="&args[]="+encodeURIComponent(arguments[x])}return"Minified React error #"+y+"; visit "+g+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function s(){}var o={d:{f:s,r:function(){throw Error(l(522))},D:s,C:s,L:s,m:s,X:s,S:s,M:s},p:0,findDOMNode:null},u=Symbol.for("react.portal");function d(y,g,x){var v=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:u,key:v==null?null:""+v,children:y,containerInfo:g,implementation:x}}var h=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function p(y,g){if(y==="font")return"";if(typeof g=="string")return g==="use-credentials"?g:""}return Bt.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=o,Bt.createPortal=function(y,g){var x=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!g||g.nodeType!==1&&g.nodeType!==9&&g.nodeType!==11)throw Error(l(299));return d(y,g,null,x)},Bt.flushSync=function(y){var g=h.T,x=o.p;try{if(h.T=null,o.p=2,y)return y()}finally{h.T=g,o.p=x,o.d.f()}},Bt.preconnect=function(y,g){typeof y=="string"&&(g?(g=g.crossOrigin,g=typeof g=="string"?g==="use-credentials"?g:"":void 0):g=null,o.d.C(y,g))},Bt.prefetchDNS=function(y){typeof y=="string"&&o.d.D(y)},Bt.preinit=function(y,g){if(typeof y=="string"&&g&&typeof g.as=="string"){var x=g.as,v=p(x,g.crossOrigin),E=typeof g.integrity=="string"?g.integrity:void 0,M=typeof g.fetchPriority=="string"?g.fetchPriority:void 0;x==="style"?o.d.S(y,typeof g.precedence=="string"?g.precedence:void 0,{crossOrigin:v,integrity:E,fetchPriority:M}):x==="script"&&o.d.X(y,{crossOrigin:v,integrity:E,fetchPriority:M,nonce:typeof g.nonce=="string"?g.nonce:void 0})}},Bt.preinitModule=function(y,g){if(typeof y=="string")if(typeof g=="object"&&g!==null){if(g.as==null||g.as==="script"){var x=p(g.as,g.crossOrigin);o.d.M(y,{crossOrigin:x,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0})}}else g==null&&o.d.M(y)},Bt.preload=function(y,g){if(typeof y=="string"&&typeof g=="object"&&g!==null&&typeof g.as=="string"){var x=g.as,v=p(x,g.crossOrigin);o.d.L(y,x,{crossOrigin:v,integrity:typeof g.integrity=="string"?g.integrity:void 0,nonce:typeof g.nonce=="string"?g.nonce:void 0,type:typeof g.type=="string"?g.type:void 0,fetchPriority:typeof g.fetchPriority=="string"?g.fetchPriority:void 0,referrerPolicy:typeof g.referrerPolicy=="string"?g.referrerPolicy:void 0,imageSrcSet:typeof g.imageSrcSet=="string"?g.imageSrcSet:void 0,imageSizes:typeof g.imageSizes=="string"?g.imageSizes:void 0,media:typeof g.media=="string"?g.media:void 0})}},Bt.preloadModule=function(y,g){if(typeof y=="string")if(g){var x=p(g.as,g.crossOrigin);o.d.m(y,{as:typeof g.as=="string"&&g.as!=="script"?g.as:void 0,crossOrigin:x,integrity:typeof g.integrity=="string"?g.integrity:void 0})}else o.d.m(y)},Bt.requestFormReset=function(y){o.d.r(y)},Bt.unstable_batchedUpdates=function(y,g){return y(g)},Bt.useFormState=function(y,g,x){return h.H.useFormState(y,g,x)},Bt.useFormStatus=function(){return h.H.useHostTransitionStatus()},Bt.version="19.2.6",Bt}var Cg;function _0(){if(Cg)return Dd.exports;Cg=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(l){console.error(l)}}return n(),Dd.exports=O_(),Dd.exports}/**
34
- * @license React
35
- * react-dom-client.production.js
36
- *
37
- * Copyright (c) Meta Platforms, Inc. and affiliates.
38
- *
39
- * This source code is licensed under the MIT license found in the
40
- * LICENSE file in the root directory of this source tree.
41
- */var Ag;function R_(){if(Ag)return no;Ag=1;var n=T_(),l=Gf(),s=_0();function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)t+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function u(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function d(e){var t=e,a=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(a=t.return),e=t.return;while(e)}return t.tag===3?a:null}function h(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function p(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function y(e){if(d(e)!==e)throw Error(o(188))}function g(e){var t=e.alternate;if(!t){if(t=d(e),t===null)throw Error(o(188));return t!==e?null:e}for(var a=e,i=t;;){var r=a.return;if(r===null)break;var c=r.alternate;if(c===null){if(i=r.return,i!==null){a=i;continue}break}if(r.child===c.child){for(c=r.child;c;){if(c===a)return y(r),e;if(c===i)return y(r),t;c=c.sibling}throw Error(o(188))}if(a.return!==i.return)a=r,i=c;else{for(var m=!1,b=r.child;b;){if(b===a){m=!0,a=r,i=c;break}if(b===i){m=!0,i=r,a=c;break}b=b.sibling}if(!m){for(b=c.child;b;){if(b===a){m=!0,a=c,i=r;break}if(b===i){m=!0,i=c,a=r;break}b=b.sibling}if(!m)throw Error(o(189))}}if(a.alternate!==i)throw Error(o(190))}if(a.tag!==3)throw Error(o(188));return a.stateNode.current===a?e:t}function x(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=x(e),t!==null)return t;e=e.sibling}return null}var v=Object.assign,E=Symbol.for("react.element"),M=Symbol.for("react.transitional.element"),N=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),j=Symbol.for("react.strict_mode"),O=Symbol.for("react.profiler"),z=Symbol.for("react.consumer"),D=Symbol.for("react.context"),Y=Symbol.for("react.forward_ref"),W=Symbol.for("react.suspense"),ee=Symbol.for("react.suspense_list"),ae=Symbol.for("react.memo"),U=Symbol.for("react.lazy"),re=Symbol.for("react.activity"),de=Symbol.for("react.memo_cache_sentinel"),ce=Symbol.iterator;function ie(e){return e===null||typeof e!="object"?null:(e=ce&&e[ce]||e["@@iterator"],typeof e=="function"?e:null)}var L=Symbol.for("react.client.reference");function G(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===L?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case A:return"Fragment";case O:return"Profiler";case j:return"StrictMode";case W:return"Suspense";case ee:return"SuspenseList";case re:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case N:return"Portal";case D:return e.displayName||"Context";case z:return(e._context.displayName||"Context")+".Consumer";case Y:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ae:return t=e.displayName||null,t!==null?t:G(e.type)||"Memo";case U:t=e._payload,e=e._init;try{return G(e(t))}catch{}}return null}var F=Array.isArray,w=l.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=s.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ue={pending:!1,data:null,method:null,action:null},te=[],P=-1;function k(e){return{current:e}}function I(e){0>P||(e.current=te[P],te[P]=null,P--)}function $(e,t){P++,te[P]=e.current,e.current=t}var T=k(null),B=k(null),q=k(null),V=k(null);function me(e,t){switch($(q,t),$(B,e),$(T,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Qy(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=Qy(t),e=Ky(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}I(T),$(T,e)}function he(){I(T),I(B),I(q)}function ke(e){e.memoizedState!==null&&$(V,e);var t=T.current,a=Ky(t,e.type);t!==a&&($(B,e),$(T,a))}function Ae(e){B.current===e&&(I(T),I(B)),V.current===e&&(I(V),Ps._currentValue=ue)}var Ue,nt;function Ve(e){if(Ue===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);Ue=t&&t[1]||"",nt=-1<a.stack.indexOf(`
42
- at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
43
- `+Ue+e+nt}var Oe=!1;function hn(e,t){if(!e||Oe)return"";Oe=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var i={DetermineComponentFrameRoot:function(){try{if(t){var oe=function(){throw Error()};if(Object.defineProperty(oe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(oe,[])}catch(J){var X=J}Reflect.construct(e,[],oe)}else{try{oe.call()}catch(J){X=J}e.call(oe.prototype)}}else{try{throw Error()}catch(J){X=J}(oe=e())&&typeof oe.catch=="function"&&oe.catch(function(){})}}catch(J){if(J&&X&&typeof J.stack=="string")return[J.stack,X.stack]}return[null,null]}};i.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var r=Object.getOwnPropertyDescriptor(i.DetermineComponentFrameRoot,"name");r&&r.configurable&&Object.defineProperty(i.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var c=i.DetermineComponentFrameRoot(),m=c[0],b=c[1];if(m&&b){var C=m.split(`
44
- `),K=b.split(`
45
- `);for(r=i=0;i<C.length&&!C[i].includes("DetermineComponentFrameRoot");)i++;for(;r<K.length&&!K[r].includes("DetermineComponentFrameRoot");)r++;if(i===C.length||r===K.length)for(i=C.length-1,r=K.length-1;1<=i&&0<=r&&C[i]!==K[r];)r--;for(;1<=i&&0<=r;i--,r--)if(C[i]!==K[r]){if(i!==1||r!==1)do if(i--,r--,0>r||C[i]!==K[r]){var le=`
46
- `+C[i].replace(" at new "," at ");return e.displayName&&le.includes("<anonymous>")&&(le=le.replace("<anonymous>",e.displayName)),le}while(1<=i&&0<=r);break}}}finally{Oe=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?Ve(a):""}function Eo(e,t){switch(e.tag){case 26:case 27:case 5:return Ve(e.type);case 16:return Ve("Lazy");case 13:return e.child!==t&&t!==null?Ve("Suspense Fallback"):Ve("Suspense");case 19:return Ve("SuspenseList");case 0:case 15:return hn(e.type,!1);case 11:return hn(e.type.render,!1);case 1:return hn(e.type,!0);case 31:return Ve("Activity");default:return""}}function jo(e){try{var t="",a=null;do t+=Eo(e,a),a=e,e=e.return;while(e);return t}catch(i){return`
47
- Error generating stack: `+i.message+`
48
- `+i.stack}}var ti=Object.prototype.hasOwnProperty,ni=n.unstable_scheduleCallback,ai=n.unstable_cancelCallback,dl=n.unstable_shouldYield,On=n.unstable_requestPaint,rt=n.unstable_now,Mo=n.unstable_getCurrentPriorityLevel,ds=n.unstable_ImmediatePriority,li=n.unstable_UserBlockingPriority,fl=n.unstable_NormalPriority,ii=n.unstable_LowPriority,it=n.unstable_IdlePriority,hl=n.log,Co=n.unstable_setDisableYieldValue,xa=null,zt=null;function ne(e){if(typeof hl=="function"&&Co(e),zt&&typeof zt.setStrictMode=="function")try{zt.setStrictMode(xa,e)}catch{}}var pe=Math.clz32?Math.clz32:Be,Se=Math.log,Me=Math.LN2;function Be(e){return e>>>=0,e===0?32:31-(Se(e)/Me|0)|0}var Te=256,pt=262144,mt=4194304;function ct(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Dt(e,t,a){var i=e.pendingLanes;if(i===0)return 0;var r=0,c=e.suspendedLanes,m=e.pingedLanes;e=e.warmLanes;var b=i&134217727;return b!==0?(i=b&~c,i!==0?r=ct(i):(m&=b,m!==0?r=ct(m):a||(a=b&~e,a!==0&&(r=ct(a))))):(b=i&~c,b!==0?r=ct(b):m!==0?r=ct(m):a||(a=i&~e,a!==0&&(r=ct(a)))),r===0?0:t!==0&&t!==r&&(t&c)===0&&(c=r&-r,a=t&-t,c>=a||c===32&&(a&4194048)!==0)?t:r}function Ut(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Lt(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function jn(){var e=mt;return mt<<=1,(mt&62914560)===0&&(mt=4194304),e}function pl(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function _a(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function wa(e,t,a,i,r,c){var m=e.pendingLanes;e.pendingLanes=a,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=a,e.entangledLanes&=a,e.errorRecoveryDisabledLanes&=a,e.shellSuspendCounter=0;var b=e.entanglements,C=e.expirationTimes,K=e.hiddenUpdates;for(a=m&~a;0<a;){var le=31-pe(a),oe=1<<le;b[le]=0,C[le]=-1;var X=K[le];if(X!==null)for(K[le]=null,le=0;le<X.length;le++){var J=X[le];J!==null&&(J.lane&=-536870913)}a&=~oe}i!==0&&Ao(e,i,0),c!==0&&r===0&&e.tag!==0&&(e.suspendedLanes|=c&~(m&~t))}function Ao(e,t,a){e.pendingLanes|=t,e.suspendedLanes&=~t;var i=31-pe(t);e.entangledLanes|=t,e.entanglements[i]=e.entanglements[i]|1073741824|a&261930}function jh(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var i=31-pe(a),r=1<<i;r&t|e[i]&t&&(e[i]|=t),a&=~r}}function Mh(e,t){var a=t&-t;return a=(a&42)!==0?1:bc(a),(a&(e.suspendedLanes|t))!==0?0:a}function bc(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function vc(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Ch(){var e=Z.p;return e!==0?e:(e=window.event,e===void 0?32:hg(e.type))}function Ah(e,t){var a=Z.p;try{return Z.p=e,t()}finally{Z.p=a}}var Sa=Math.random().toString(36).slice(2),Ct="__reactFiber$"+Sa,Kt="__reactProps$"+Sa,si="__reactContainer$"+Sa,xc="__reactEvents$"+Sa,mx="__reactListeners$"+Sa,yx="__reactHandles$"+Sa,Nh="__reactResources$"+Sa,fs="__reactMarker$"+Sa;function _c(e){delete e[Ct],delete e[Kt],delete e[xc],delete e[mx],delete e[yx]}function oi(e){var t=e[Ct];if(t)return t;for(var a=e.parentNode;a;){if(t=a[si]||a[Ct]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=Py(e);e!==null;){if(a=e[Ct])return a;e=Py(e)}return t}e=a,a=e.parentNode}return null}function ri(e){if(e=e[Ct]||e[si]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function hs(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(o(33))}function ci(e){var t=e[Nh];return t||(t=e[Nh]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function Et(e){e[fs]=!0}var Th=new Set,Oh={};function ml(e,t){ui(e,t),ui(e+"Capture",t)}function ui(e,t){for(Oh[e]=t,e=0;e<t.length;e++)Th.add(t[e])}var gx=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),Rh={},zh={};function bx(e){return ti.call(zh,e)?!0:ti.call(Rh,e)?!1:gx.test(e)?zh[e]=!0:(Rh[e]=!0,!1)}function No(e,t,a){if(bx(t))if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var i=t.toLowerCase().slice(0,5);if(i!=="data-"&&i!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+a)}}function To(e,t,a){if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+a)}}function Yn(e,t,a,i){if(i===null)e.removeAttribute(a);else{switch(typeof i){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttributeNS(t,a,""+i)}}function pn(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Dh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function vx(e,t,a){var i=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof i<"u"&&typeof i.get=="function"&&typeof i.set=="function"){var r=i.get,c=i.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(m){a=""+m,c.call(this,m)}}),Object.defineProperty(e,t,{enumerable:i.enumerable}),{getValue:function(){return a},setValue:function(m){a=""+m},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function wc(e){if(!e._valueTracker){var t=Dh(e)?"checked":"value";e._valueTracker=vx(e,t,""+e[t])}}function Uh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),i="";return e&&(i=Dh(e)?e.checked?"true":"false":e.value),e=i,e!==a?(t.setValue(e),!0):!1}function Oo(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var xx=/[\n"\\]/g;function mn(e){return e.replace(xx,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Sc(e,t,a,i,r,c,m,b){e.name="",m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"?e.type=m:e.removeAttribute("type"),t!=null?m==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+pn(t)):e.value!==""+pn(t)&&(e.value=""+pn(t)):m!=="submit"&&m!=="reset"||e.removeAttribute("value"),t!=null?kc(e,m,pn(t)):a!=null?kc(e,m,pn(a)):i!=null&&e.removeAttribute("value"),r==null&&c!=null&&(e.defaultChecked=!!c),r!=null&&(e.checked=r&&typeof r!="function"&&typeof r!="symbol"),b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.name=""+pn(b):e.removeAttribute("name")}function Lh(e,t,a,i,r,c,m,b){if(c!=null&&typeof c!="function"&&typeof c!="symbol"&&typeof c!="boolean"&&(e.type=c),t!=null||a!=null){if(!(c!=="submit"&&c!=="reset"||t!=null)){wc(e);return}a=a!=null?""+pn(a):"",t=t!=null?""+pn(t):a,b||t===e.value||(e.value=t),e.defaultValue=t}i=i??r,i=typeof i!="function"&&typeof i!="symbol"&&!!i,e.checked=b?e.checked:!!i,e.defaultChecked=!!i,m!=null&&typeof m!="function"&&typeof m!="symbol"&&typeof m!="boolean"&&(e.name=m),wc(e)}function kc(e,t,a){t==="number"&&Oo(e.ownerDocument)===e||e.defaultValue===""+a||(e.defaultValue=""+a)}function di(e,t,a,i){if(e=e.options,t){t={};for(var r=0;r<a.length;r++)t["$"+a[r]]=!0;for(a=0;a<e.length;a++)r=t.hasOwnProperty("$"+e[a].value),e[a].selected!==r&&(e[a].selected=r),r&&i&&(e[a].defaultSelected=!0)}else{for(a=""+pn(a),t=null,r=0;r<e.length;r++){if(e[r].value===a){e[r].selected=!0,i&&(e[r].defaultSelected=!0);return}t!==null||e[r].disabled||(t=e[r])}t!==null&&(t.selected=!0)}}function Bh(e,t,a){if(t!=null&&(t=""+pn(t),t!==e.value&&(e.value=t),a==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=a!=null?""+pn(a):""}function Hh(e,t,a,i){if(t==null){if(i!=null){if(a!=null)throw Error(o(92));if(F(i)){if(1<i.length)throw Error(o(93));i=i[0]}a=i}a==null&&(a=""),t=a}a=pn(t),e.defaultValue=a,i=e.textContent,i===a&&i!==""&&i!==null&&(e.value=i),wc(e)}function fi(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var _x=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function qh(e,t,a){var i=t.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?i?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":i?e.setProperty(t,a):typeof a!="number"||a===0||_x.has(t)?t==="float"?e.cssFloat=a:e[t]=(""+a).trim():e[t]=a+"px"}function Gh(e,t,a){if(t!=null&&typeof t!="object")throw Error(o(62));if(e=e.style,a!=null){for(var i in a)!a.hasOwnProperty(i)||t!=null&&t.hasOwnProperty(i)||(i.indexOf("--")===0?e.setProperty(i,""):i==="float"?e.cssFloat="":e[i]="");for(var r in t)i=t[r],t.hasOwnProperty(r)&&a[r]!==i&&qh(e,r,i)}else for(var c in t)t.hasOwnProperty(c)&&qh(e,c,t[c])}function Ec(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var wx=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Sx=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Ro(e){return Sx.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function $n(){}var jc=null;function Mc(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var hi=null,pi=null;function Ih(e){var t=ri(e);if(t&&(e=t.stateNode)){var a=e[Kt]||null;e:switch(e=t.stateNode,t.type){case"input":if(Sc(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+mn(""+t)+'"][type="radio"]'),t=0;t<a.length;t++){var i=a[t];if(i!==e&&i.form===e.form){var r=i[Kt]||null;if(!r)throw Error(o(90));Sc(i,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name)}}for(t=0;t<a.length;t++)i=a[t],i.form===e.form&&Uh(i)}break e;case"textarea":Bh(e,a.value,a.defaultValue);break e;case"select":t=a.value,t!=null&&di(e,!!a.multiple,t,!1)}}}var Cc=!1;function Qh(e,t,a){if(Cc)return e(t,a);Cc=!0;try{var i=e(t);return i}finally{if(Cc=!1,(hi!==null||pi!==null)&&(xr(),hi&&(t=hi,e=pi,pi=hi=null,Ih(t),e)))for(t=0;t<e.length;t++)Ih(e[t])}}function ps(e,t){var a=e.stateNode;if(a===null)return null;var i=a[Kt]||null;if(i===null)return null;a=i[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(i=!i.disabled)||(e=e.type,i=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!i;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(o(231,t,typeof a));return a}var Fn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ac=!1;if(Fn)try{var ms={};Object.defineProperty(ms,"passive",{get:function(){Ac=!0}}),window.addEventListener("test",ms,ms),window.removeEventListener("test",ms,ms)}catch{Ac=!1}var ka=null,Nc=null,zo=null;function Kh(){if(zo)return zo;var e,t=Nc,a=t.length,i,r="value"in ka?ka.value:ka.textContent,c=r.length;for(e=0;e<a&&t[e]===r[e];e++);var m=a-e;for(i=1;i<=m&&t[a-i]===r[c-i];i++);return zo=r.slice(e,1<i?1-i:void 0)}function Do(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Uo(){return!0}function Vh(){return!1}function Vt(e){function t(a,i,r,c,m){this._reactName=a,this._targetInst=r,this.type=i,this.nativeEvent=c,this.target=m,this.currentTarget=null;for(var b in e)e.hasOwnProperty(b)&&(a=e[b],this[b]=a?a(c):c[b]);return this.isDefaultPrevented=(c.defaultPrevented!=null?c.defaultPrevented:c.returnValue===!1)?Uo:Vh,this.isPropagationStopped=Vh,this}return v(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=Uo)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=Uo)},persist:function(){},isPersistent:Uo}),t}var yl={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Lo=Vt(yl),ys=v({},yl,{view:0,detail:0}),kx=Vt(ys),Tc,Oc,gs,Bo=v({},ys,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:zc,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==gs&&(gs&&e.type==="mousemove"?(Tc=e.screenX-gs.screenX,Oc=e.screenY-gs.screenY):Oc=Tc=0,gs=e),Tc)},movementY:function(e){return"movementY"in e?e.movementY:Oc}}),Yh=Vt(Bo),Ex=v({},Bo,{dataTransfer:0}),jx=Vt(Ex),Mx=v({},ys,{relatedTarget:0}),Rc=Vt(Mx),Cx=v({},yl,{animationName:0,elapsedTime:0,pseudoElement:0}),Ax=Vt(Cx),Nx=v({},yl,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Tx=Vt(Nx),Ox=v({},yl,{data:0}),$h=Vt(Ox),Rx={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},zx={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},Dx={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ux(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Dx[e])?!!t[e]:!1}function zc(){return Ux}var Lx=v({},ys,{key:function(e){if(e.key){var t=Rx[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Do(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?zx[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:zc,charCode:function(e){return e.type==="keypress"?Do(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Do(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Bx=Vt(Lx),Hx=v({},Bo,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Fh=Vt(Hx),qx=v({},ys,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:zc}),Gx=Vt(qx),Ix=v({},yl,{propertyName:0,elapsedTime:0,pseudoElement:0}),Qx=Vt(Ix),Kx=v({},Bo,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Vx=Vt(Kx),Yx=v({},yl,{newState:0,oldState:0}),$x=Vt(Yx),Fx=[9,13,27,32],Dc=Fn&&"CompositionEvent"in window,bs=null;Fn&&"documentMode"in document&&(bs=document.documentMode);var Xx=Fn&&"TextEvent"in window&&!bs,Xh=Fn&&(!Dc||bs&&8<bs&&11>=bs),Zh=" ",Ph=!1;function Jh(e,t){switch(e){case"keyup":return Fx.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var mi=!1;function Zx(e,t){switch(e){case"compositionend":return Wh(t);case"keypress":return t.which!==32?null:(Ph=!0,Zh);case"textInput":return e=t.data,e===Zh&&Ph?null:e;default:return null}}function Px(e,t){if(mi)return e==="compositionend"||!Dc&&Jh(e,t)?(e=Kh(),zo=Nc=ka=null,mi=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Xh&&t.locale!=="ko"?null:t.data;default:return null}}var Jx={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function ep(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Jx[e.type]:t==="textarea"}function tp(e,t,a,i){hi?pi?pi.push(i):pi=[i]:hi=i,t=Mr(t,"onChange"),0<t.length&&(a=new Lo("onChange","change",null,a,i),e.push({event:a,listeners:t}))}var vs=null,xs=null;function Wx(e){Ly(e,0)}function Ho(e){var t=hs(e);if(Uh(t))return e}function np(e,t){if(e==="change")return t}var ap=!1;if(Fn){var Uc;if(Fn){var Lc="oninput"in document;if(!Lc){var lp=document.createElement("div");lp.setAttribute("oninput","return;"),Lc=typeof lp.oninput=="function"}Uc=Lc}else Uc=!1;ap=Uc&&(!document.documentMode||9<document.documentMode)}function ip(){vs&&(vs.detachEvent("onpropertychange",sp),xs=vs=null)}function sp(e){if(e.propertyName==="value"&&Ho(xs)){var t=[];tp(t,xs,e,Mc(e)),Qh(Wx,t)}}function e2(e,t,a){e==="focusin"?(ip(),vs=t,xs=a,vs.attachEvent("onpropertychange",sp)):e==="focusout"&&ip()}function t2(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Ho(xs)}function n2(e,t){if(e==="click")return Ho(t)}function a2(e,t){if(e==="input"||e==="change")return Ho(t)}function l2(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var tn=typeof Object.is=="function"?Object.is:l2;function _s(e,t){if(tn(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),i=Object.keys(t);if(a.length!==i.length)return!1;for(i=0;i<a.length;i++){var r=a[i];if(!ti.call(t,r)||!tn(e[r],t[r]))return!1}return!0}function op(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function rp(e,t){var a=op(e);e=0;for(var i;a;){if(a.nodeType===3){if(i=e+a.textContent.length,e<=t&&i>=t)return{node:a,offset:t-e};e=i}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=op(a)}}function cp(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?cp(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function up(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Oo(e.document);t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=Oo(e.document)}return t}function Bc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var i2=Fn&&"documentMode"in document&&11>=document.documentMode,yi=null,Hc=null,ws=null,qc=!1;function dp(e,t,a){var i=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;qc||yi==null||yi!==Oo(i)||(i=yi,"selectionStart"in i&&Bc(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),ws&&_s(ws,i)||(ws=i,i=Mr(Hc,"onSelect"),0<i.length&&(t=new Lo("onSelect","select",null,t,a),e.push({event:t,listeners:i}),t.target=yi)))}function gl(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var gi={animationend:gl("Animation","AnimationEnd"),animationiteration:gl("Animation","AnimationIteration"),animationstart:gl("Animation","AnimationStart"),transitionrun:gl("Transition","TransitionRun"),transitionstart:gl("Transition","TransitionStart"),transitioncancel:gl("Transition","TransitionCancel"),transitionend:gl("Transition","TransitionEnd")},Gc={},fp={};Fn&&(fp=document.createElement("div").style,"AnimationEvent"in window||(delete gi.animationend.animation,delete gi.animationiteration.animation,delete gi.animationstart.animation),"TransitionEvent"in window||delete gi.transitionend.transition);function bl(e){if(Gc[e])return Gc[e];if(!gi[e])return e;var t=gi[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in fp)return Gc[e]=t[a];return e}var hp=bl("animationend"),pp=bl("animationiteration"),mp=bl("animationstart"),s2=bl("transitionrun"),o2=bl("transitionstart"),r2=bl("transitioncancel"),yp=bl("transitionend"),gp=new Map,Ic="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");Ic.push("scrollEnd");function Mn(e,t){gp.set(e,t),ml(t,[e])}var qo=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},yn=[],bi=0,Qc=0;function Go(){for(var e=bi,t=Qc=bi=0;t<e;){var a=yn[t];yn[t++]=null;var i=yn[t];yn[t++]=null;var r=yn[t];yn[t++]=null;var c=yn[t];if(yn[t++]=null,i!==null&&r!==null){var m=i.pending;m===null?r.next=r:(r.next=m.next,m.next=r),i.pending=r}c!==0&&bp(a,r,c)}}function Io(e,t,a,i){yn[bi++]=e,yn[bi++]=t,yn[bi++]=a,yn[bi++]=i,Qc|=i,e.lanes|=i,e=e.alternate,e!==null&&(e.lanes|=i)}function Kc(e,t,a,i){return Io(e,t,a,i),Qo(e)}function vl(e,t){return Io(e,null,null,t),Qo(e)}function bp(e,t,a){e.lanes|=a;var i=e.alternate;i!==null&&(i.lanes|=a);for(var r=!1,c=e.return;c!==null;)c.childLanes|=a,i=c.alternate,i!==null&&(i.childLanes|=a),c.tag===22&&(e=c.stateNode,e===null||e._visibility&1||(r=!0)),e=c,c=c.return;return e.tag===3?(c=e.stateNode,r&&t!==null&&(r=31-pe(a),e=c.hiddenUpdates,i=e[r],i===null?e[r]=[t]:i.push(t),t.lane=a|536870912),c):null}function Qo(e){if(50<Ks)throw Ks=0,Wu=null,Error(o(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var vi={};function c2(e,t,a,i){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function nn(e,t,a,i){return new c2(e,t,a,i)}function Vc(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Xn(e,t){var a=e.alternate;return a===null?(a=nn(e.tag,t,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=t,a.type=e.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=e.flags&65011712,a.childLanes=e.childLanes,a.lanes=e.lanes,a.child=e.child,a.memoizedProps=e.memoizedProps,a.memoizedState=e.memoizedState,a.updateQueue=e.updateQueue,t=e.dependencies,a.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function vp(e,t){e.flags&=65011714;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=a.childLanes,e.lanes=a.lanes,e.child=a.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=a.memoizedProps,e.memoizedState=a.memoizedState,e.updateQueue=a.updateQueue,e.type=a.type,t=a.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function Ko(e,t,a,i,r,c){var m=0;if(i=e,typeof e=="function")Vc(e)&&(m=1);else if(typeof e=="string")m=p_(e,a,T.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case re:return e=nn(31,a,t,r),e.elementType=re,e.lanes=c,e;case A:return xl(a.children,r,c,t);case j:m=8,r|=24;break;case O:return e=nn(12,a,t,r|2),e.elementType=O,e.lanes=c,e;case W:return e=nn(13,a,t,r),e.elementType=W,e.lanes=c,e;case ee:return e=nn(19,a,t,r),e.elementType=ee,e.lanes=c,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case D:m=10;break e;case z:m=9;break e;case Y:m=11;break e;case ae:m=14;break e;case U:m=16,i=null;break e}m=29,a=Error(o(130,e===null?"null":typeof e,"")),i=null}return t=nn(m,a,t,r),t.elementType=e,t.type=i,t.lanes=c,t}function xl(e,t,a,i){return e=nn(7,e,i,t),e.lanes=a,e}function Yc(e,t,a){return e=nn(6,e,null,t),e.lanes=a,e}function xp(e){var t=nn(18,null,null,0);return t.stateNode=e,t}function $c(e,t,a){return t=nn(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var _p=new WeakMap;function gn(e,t){if(typeof e=="object"&&e!==null){var a=_p.get(e);return a!==void 0?a:(t={value:e,source:t,stack:jo(t)},_p.set(e,t),t)}return{value:e,source:t,stack:jo(t)}}var xi=[],_i=0,Vo=null,Ss=0,bn=[],vn=0,Ea=null,Rn=1,zn="";function Zn(e,t){xi[_i++]=Ss,xi[_i++]=Vo,Vo=e,Ss=t}function wp(e,t,a){bn[vn++]=Rn,bn[vn++]=zn,bn[vn++]=Ea,Ea=e;var i=Rn;e=zn;var r=32-pe(i)-1;i&=~(1<<r),a+=1;var c=32-pe(t)+r;if(30<c){var m=r-r%5;c=(i&(1<<m)-1).toString(32),i>>=m,r-=m,Rn=1<<32-pe(t)+r|a<<r|i,zn=c+e}else Rn=1<<c|a<<r|i,zn=e}function Fc(e){e.return!==null&&(Zn(e,1),wp(e,1,0))}function Xc(e){for(;e===Vo;)Vo=xi[--_i],xi[_i]=null,Ss=xi[--_i],xi[_i]=null;for(;e===Ea;)Ea=bn[--vn],bn[vn]=null,zn=bn[--vn],bn[vn]=null,Rn=bn[--vn],bn[vn]=null}function Sp(e,t){bn[vn++]=Rn,bn[vn++]=zn,bn[vn++]=Ea,Rn=t.id,zn=t.overflow,Ea=e}var At=null,at=null,Qe=!1,ja=null,xn=!1,Zc=Error(o(519));function Ma(e){var t=Error(o(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw ks(gn(t,e)),Zc}function kp(e){var t=e.stateNode,a=e.type,i=e.memoizedProps;switch(t[Ct]=e,t[Kt]=i,a){case"dialog":qe("cancel",t),qe("close",t);break;case"iframe":case"object":case"embed":qe("load",t);break;case"video":case"audio":for(a=0;a<Ys.length;a++)qe(Ys[a],t);break;case"source":qe("error",t);break;case"img":case"image":case"link":qe("error",t),qe("load",t);break;case"details":qe("toggle",t);break;case"input":qe("invalid",t),Lh(t,i.value,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name,!0);break;case"select":qe("invalid",t);break;case"textarea":qe("invalid",t),Hh(t,i.value,i.defaultValue,i.children)}a=i.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||t.textContent===""+a||i.suppressHydrationWarning===!0||Gy(t.textContent,a)?(i.popover!=null&&(qe("beforetoggle",t),qe("toggle",t)),i.onScroll!=null&&qe("scroll",t),i.onScrollEnd!=null&&qe("scrollend",t),i.onClick!=null&&(t.onclick=$n),t=!0):t=!1,t||Ma(e,!0)}function Ep(e){for(At=e.return;At;)switch(At.tag){case 5:case 31:case 13:xn=!1;return;case 27:case 3:xn=!0;return;default:At=At.return}}function wi(e){if(e!==At)return!1;if(!Qe)return Ep(e),Qe=!0,!1;var t=e.tag,a;if((a=t!==3&&t!==27)&&((a=t===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||pd(e.type,e.memoizedProps)),a=!a),a&&at&&Ma(e),Ep(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));at=Zy(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(317));at=Zy(e)}else t===27?(t=at,Ga(e.type)?(e=vd,vd=null,at=e):at=t):at=At?wn(e.stateNode.nextSibling):null;return!0}function _l(){at=At=null,Qe=!1}function Pc(){var e=ja;return e!==null&&(Xt===null?Xt=e:Xt.push.apply(Xt,e),ja=null),e}function ks(e){ja===null?ja=[e]:ja.push(e)}var Jc=k(null),wl=null,Pn=null;function Ca(e,t,a){$(Jc,t._currentValue),t._currentValue=a}function Jn(e){e._currentValue=Jc.current,I(Jc)}function Wc(e,t,a){for(;e!==null;){var i=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,i!==null&&(i.childLanes|=t)):i!==null&&(i.childLanes&t)!==t&&(i.childLanes|=t),e===a)break;e=e.return}}function eu(e,t,a,i){var r=e.child;for(r!==null&&(r.return=e);r!==null;){var c=r.dependencies;if(c!==null){var m=r.child;c=c.firstContext;e:for(;c!==null;){var b=c;c=r;for(var C=0;C<t.length;C++)if(b.context===t[C]){c.lanes|=a,b=c.alternate,b!==null&&(b.lanes|=a),Wc(c.return,a,e),i||(m=null);break e}c=b.next}}else if(r.tag===18){if(m=r.return,m===null)throw Error(o(341));m.lanes|=a,c=m.alternate,c!==null&&(c.lanes|=a),Wc(m,a,e),m=null}else m=r.child;if(m!==null)m.return=r;else for(m=r;m!==null;){if(m===e){m=null;break}if(r=m.sibling,r!==null){r.return=m.return,m=r;break}m=m.return}r=m}}function Si(e,t,a,i){e=null;for(var r=t,c=!1;r!==null;){if(!c){if((r.flags&524288)!==0)c=!0;else if((r.flags&262144)!==0)break}if(r.tag===10){var m=r.alternate;if(m===null)throw Error(o(387));if(m=m.memoizedProps,m!==null){var b=r.type;tn(r.pendingProps.value,m.value)||(e!==null?e.push(b):e=[b])}}else if(r===V.current){if(m=r.alternate,m===null)throw Error(o(387));m.memoizedState.memoizedState!==r.memoizedState.memoizedState&&(e!==null?e.push(Ps):e=[Ps])}r=r.return}e!==null&&eu(t,e,a,i),t.flags|=262144}function Yo(e){for(e=e.firstContext;e!==null;){if(!tn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Sl(e){wl=e,Pn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Nt(e){return jp(wl,e)}function $o(e,t){return wl===null&&Sl(e),jp(e,t)}function jp(e,t){var a=t._currentValue;if(t={context:t,memoizedValue:a,next:null},Pn===null){if(e===null)throw Error(o(308));Pn=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Pn=Pn.next=t;return a}var u2=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(a,i){e.push(i)}};this.abort=function(){t.aborted=!0,e.forEach(function(a){return a()})}},d2=n.unstable_scheduleCallback,f2=n.unstable_NormalPriority,bt={$$typeof:D,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function tu(){return{controller:new u2,data:new Map,refCount:0}}function Es(e){e.refCount--,e.refCount===0&&d2(f2,function(){e.controller.abort()})}var js=null,nu=0,ki=0,Ei=null;function h2(e,t){if(js===null){var a=js=[];nu=0,ki=id(),Ei={status:"pending",value:void 0,then:function(i){a.push(i)}}}return nu++,t.then(Mp,Mp),t}function Mp(){if(--nu===0&&js!==null){Ei!==null&&(Ei.status="fulfilled");var e=js;js=null,ki=0,Ei=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function p2(e,t){var a=[],i={status:"pending",value:null,reason:null,then:function(r){a.push(r)}};return e.then(function(){i.status="fulfilled",i.value=t;for(var r=0;r<a.length;r++)(0,a[r])(t)},function(r){for(i.status="rejected",i.reason=r,r=0;r<a.length;r++)(0,a[r])(void 0)}),i}var Cp=w.S;w.S=function(e,t){dy=rt(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&h2(e,t),Cp!==null&&Cp(e,t)};var kl=k(null);function au(){var e=kl.current;return e!==null?e:tt.pooledCache}function Fo(e,t){t===null?$(kl,kl.current):$(kl,t.pool)}function Ap(){var e=au();return e===null?null:{parent:bt._currentValue,pool:e}}var ji=Error(o(460)),lu=Error(o(474)),Xo=Error(o(542)),Zo={then:function(){}};function Np(e){return e=e.status,e==="fulfilled"||e==="rejected"}function Tp(e,t,a){switch(a=e[a],a===void 0?e.push(t):a!==t&&(t.then($n,$n),t=a),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Rp(e),e;default:if(typeof t.status=="string")t.then($n,$n);else{if(e=tt,e!==null&&100<e.shellSuspendCounter)throw Error(o(482));e=t,e.status="pending",e.then(function(i){if(t.status==="pending"){var r=t;r.status="fulfilled",r.value=i}},function(i){if(t.status==="pending"){var r=t;r.status="rejected",r.reason=i}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,Rp(e),e}throw jl=t,ji}}function El(e){try{var t=e._init;return t(e._payload)}catch(a){throw a!==null&&typeof a=="object"&&typeof a.then=="function"?(jl=a,ji):a}}var jl=null;function Op(){if(jl===null)throw Error(o(459));var e=jl;return jl=null,e}function Rp(e){if(e===ji||e===Xo)throw Error(o(483))}var Mi=null,Ms=0;function Po(e){var t=Ms;return Ms+=1,Mi===null&&(Mi=[]),Tp(Mi,e,t)}function Cs(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Jo(e,t){throw t.$$typeof===E?Error(o(525)):(e=Object.prototype.toString.call(t),Error(o(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function zp(e){function t(H,R){if(e){var Q=H.deletions;Q===null?(H.deletions=[R],H.flags|=16):Q.push(R)}}function a(H,R){if(!e)return null;for(;R!==null;)t(H,R),R=R.sibling;return null}function i(H){for(var R=new Map;H!==null;)H.key!==null?R.set(H.key,H):R.set(H.index,H),H=H.sibling;return R}function r(H,R){return H=Xn(H,R),H.index=0,H.sibling=null,H}function c(H,R,Q){return H.index=Q,e?(Q=H.alternate,Q!==null?(Q=Q.index,Q<R?(H.flags|=67108866,R):Q):(H.flags|=67108866,R)):(H.flags|=1048576,R)}function m(H){return e&&H.alternate===null&&(H.flags|=67108866),H}function b(H,R,Q,se){return R===null||R.tag!==6?(R=Yc(Q,H.mode,se),R.return=H,R):(R=r(R,Q),R.return=H,R)}function C(H,R,Q,se){var Ee=Q.type;return Ee===A?le(H,R,Q.props.children,se,Q.key):R!==null&&(R.elementType===Ee||typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===U&&El(Ee)===R.type)?(R=r(R,Q.props),Cs(R,Q),R.return=H,R):(R=Ko(Q.type,Q.key,Q.props,null,H.mode,se),Cs(R,Q),R.return=H,R)}function K(H,R,Q,se){return R===null||R.tag!==4||R.stateNode.containerInfo!==Q.containerInfo||R.stateNode.implementation!==Q.implementation?(R=$c(Q,H.mode,se),R.return=H,R):(R=r(R,Q.children||[]),R.return=H,R)}function le(H,R,Q,se,Ee){return R===null||R.tag!==7?(R=xl(Q,H.mode,se,Ee),R.return=H,R):(R=r(R,Q),R.return=H,R)}function oe(H,R,Q){if(typeof R=="string"&&R!==""||typeof R=="number"||typeof R=="bigint")return R=Yc(""+R,H.mode,Q),R.return=H,R;if(typeof R=="object"&&R!==null){switch(R.$$typeof){case M:return Q=Ko(R.type,R.key,R.props,null,H.mode,Q),Cs(Q,R),Q.return=H,Q;case N:return R=$c(R,H.mode,Q),R.return=H,R;case U:return R=El(R),oe(H,R,Q)}if(F(R)||ie(R))return R=xl(R,H.mode,Q,null),R.return=H,R;if(typeof R.then=="function")return oe(H,Po(R),Q);if(R.$$typeof===D)return oe(H,$o(H,R),Q);Jo(H,R)}return null}function X(H,R,Q,se){var Ee=R!==null?R.key:null;if(typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint")return Ee!==null?null:b(H,R,""+Q,se);if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case M:return Q.key===Ee?C(H,R,Q,se):null;case N:return Q.key===Ee?K(H,R,Q,se):null;case U:return Q=El(Q),X(H,R,Q,se)}if(F(Q)||ie(Q))return Ee!==null?null:le(H,R,Q,se,null);if(typeof Q.then=="function")return X(H,R,Po(Q),se);if(Q.$$typeof===D)return X(H,R,$o(H,Q),se);Jo(H,Q)}return null}function J(H,R,Q,se,Ee){if(typeof se=="string"&&se!==""||typeof se=="number"||typeof se=="bigint")return H=H.get(Q)||null,b(R,H,""+se,Ee);if(typeof se=="object"&&se!==null){switch(se.$$typeof){case M:return H=H.get(se.key===null?Q:se.key)||null,C(R,H,se,Ee);case N:return H=H.get(se.key===null?Q:se.key)||null,K(R,H,se,Ee);case U:return se=El(se),J(H,R,Q,se,Ee)}if(F(se)||ie(se))return H=H.get(Q)||null,le(R,H,se,Ee,null);if(typeof se.then=="function")return J(H,R,Q,Po(se),Ee);if(se.$$typeof===D)return J(H,R,Q,$o(R,se),Ee);Jo(R,se)}return null}function _e(H,R,Q,se){for(var Ee=null,Ye=null,we=R,De=R=0,Ie=null;we!==null&&De<Q.length;De++){we.index>De?(Ie=we,we=null):Ie=we.sibling;var $e=X(H,we,Q[De],se);if($e===null){we===null&&(we=Ie);break}e&&we&&$e.alternate===null&&t(H,we),R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e,we=Ie}if(De===Q.length)return a(H,we),Qe&&Zn(H,De),Ee;if(we===null){for(;De<Q.length;De++)we=oe(H,Q[De],se),we!==null&&(R=c(we,R,De),Ye===null?Ee=we:Ye.sibling=we,Ye=we);return Qe&&Zn(H,De),Ee}for(we=i(we);De<Q.length;De++)Ie=J(we,H,De,Q[De],se),Ie!==null&&(e&&Ie.alternate!==null&&we.delete(Ie.key===null?De:Ie.key),R=c(Ie,R,De),Ye===null?Ee=Ie:Ye.sibling=Ie,Ye=Ie);return e&&we.forEach(function(Ya){return t(H,Ya)}),Qe&&Zn(H,De),Ee}function Ce(H,R,Q,se){if(Q==null)throw Error(o(151));for(var Ee=null,Ye=null,we=R,De=R=0,Ie=null,$e=Q.next();we!==null&&!$e.done;De++,$e=Q.next()){we.index>De?(Ie=we,we=null):Ie=we.sibling;var Ya=X(H,we,$e.value,se);if(Ya===null){we===null&&(we=Ie);break}e&&we&&Ya.alternate===null&&t(H,we),R=c(Ya,R,De),Ye===null?Ee=Ya:Ye.sibling=Ya,Ye=Ya,we=Ie}if($e.done)return a(H,we),Qe&&Zn(H,De),Ee;if(we===null){for(;!$e.done;De++,$e=Q.next())$e=oe(H,$e.value,se),$e!==null&&(R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e);return Qe&&Zn(H,De),Ee}for(we=i(we);!$e.done;De++,$e=Q.next())$e=J(we,H,De,$e.value,se),$e!==null&&(e&&$e.alternate!==null&&we.delete($e.key===null?De:$e.key),R=c($e,R,De),Ye===null?Ee=$e:Ye.sibling=$e,Ye=$e);return e&&we.forEach(function(E_){return t(H,E_)}),Qe&&Zn(H,De),Ee}function et(H,R,Q,se){if(typeof Q=="object"&&Q!==null&&Q.type===A&&Q.key===null&&(Q=Q.props.children),typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case M:e:{for(var Ee=Q.key;R!==null;){if(R.key===Ee){if(Ee=Q.type,Ee===A){if(R.tag===7){a(H,R.sibling),se=r(R,Q.props.children),se.return=H,H=se;break e}}else if(R.elementType===Ee||typeof Ee=="object"&&Ee!==null&&Ee.$$typeof===U&&El(Ee)===R.type){a(H,R.sibling),se=r(R,Q.props),Cs(se,Q),se.return=H,H=se;break e}a(H,R);break}else t(H,R);R=R.sibling}Q.type===A?(se=xl(Q.props.children,H.mode,se,Q.key),se.return=H,H=se):(se=Ko(Q.type,Q.key,Q.props,null,H.mode,se),Cs(se,Q),se.return=H,H=se)}return m(H);case N:e:{for(Ee=Q.key;R!==null;){if(R.key===Ee)if(R.tag===4&&R.stateNode.containerInfo===Q.containerInfo&&R.stateNode.implementation===Q.implementation){a(H,R.sibling),se=r(R,Q.children||[]),se.return=H,H=se;break e}else{a(H,R);break}else t(H,R);R=R.sibling}se=$c(Q,H.mode,se),se.return=H,H=se}return m(H);case U:return Q=El(Q),et(H,R,Q,se)}if(F(Q))return _e(H,R,Q,se);if(ie(Q)){if(Ee=ie(Q),typeof Ee!="function")throw Error(o(150));return Q=Ee.call(Q),Ce(H,R,Q,se)}if(typeof Q.then=="function")return et(H,R,Po(Q),se);if(Q.$$typeof===D)return et(H,R,$o(H,Q),se);Jo(H,Q)}return typeof Q=="string"&&Q!==""||typeof Q=="number"||typeof Q=="bigint"?(Q=""+Q,R!==null&&R.tag===6?(a(H,R.sibling),se=r(R,Q),se.return=H,H=se):(a(H,R),se=Yc(Q,H.mode,se),se.return=H,H=se),m(H)):a(H,R)}return function(H,R,Q,se){try{Ms=0;var Ee=et(H,R,Q,se);return Mi=null,Ee}catch(we){if(we===ji||we===Xo)throw we;var Ye=nn(29,we,null,H.mode);return Ye.lanes=se,Ye.return=H,Ye}finally{}}}var Ml=zp(!0),Dp=zp(!1),Aa=!1;function iu(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function su(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Na(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ta(e,t,a){var i=e.updateQueue;if(i===null)return null;if(i=i.shared,(Fe&2)!==0){var r=i.pending;return r===null?t.next=t:(t.next=r.next,r.next=t),i.pending=t,t=Qo(e),bp(e,null,a),t}return Io(e,i,t,a),Qo(e)}function As(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194048)!==0)){var i=t.lanes;i&=e.pendingLanes,a|=i,t.lanes=a,jh(e,a)}}function ou(e,t){var a=e.updateQueue,i=e.alternate;if(i!==null&&(i=i.updateQueue,a===i)){var r=null,c=null;if(a=a.firstBaseUpdate,a!==null){do{var m={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};c===null?r=c=m:c=c.next=m,a=a.next}while(a!==null);c===null?r=c=t:c=c.next=t}else r=c=t;a={baseState:i.baseState,firstBaseUpdate:r,lastBaseUpdate:c,shared:i.shared,callbacks:i.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}var ru=!1;function Ns(){if(ru){var e=Ei;if(e!==null)throw e}}function Ts(e,t,a,i){ru=!1;var r=e.updateQueue;Aa=!1;var c=r.firstBaseUpdate,m=r.lastBaseUpdate,b=r.shared.pending;if(b!==null){r.shared.pending=null;var C=b,K=C.next;C.next=null,m===null?c=K:m.next=K,m=C;var le=e.alternate;le!==null&&(le=le.updateQueue,b=le.lastBaseUpdate,b!==m&&(b===null?le.firstBaseUpdate=K:b.next=K,le.lastBaseUpdate=C))}if(c!==null){var oe=r.baseState;m=0,le=K=C=null,b=c;do{var X=b.lane&-536870913,J=X!==b.lane;if(J?(Ge&X)===X:(i&X)===X){X!==0&&X===ki&&(ru=!0),le!==null&&(le=le.next={lane:0,tag:b.tag,payload:b.payload,callback:null,next:null});e:{var _e=e,Ce=b;X=t;var et=a;switch(Ce.tag){case 1:if(_e=Ce.payload,typeof _e=="function"){oe=_e.call(et,oe,X);break e}oe=_e;break e;case 3:_e.flags=_e.flags&-65537|128;case 0:if(_e=Ce.payload,X=typeof _e=="function"?_e.call(et,oe,X):_e,X==null)break e;oe=v({},oe,X);break e;case 2:Aa=!0}}X=b.callback,X!==null&&(e.flags|=64,J&&(e.flags|=8192),J=r.callbacks,J===null?r.callbacks=[X]:J.push(X))}else J={lane:X,tag:b.tag,payload:b.payload,callback:b.callback,next:null},le===null?(K=le=J,C=oe):le=le.next=J,m|=X;if(b=b.next,b===null){if(b=r.shared.pending,b===null)break;J=b,b=J.next,J.next=null,r.lastBaseUpdate=J,r.shared.pending=null}}while(!0);le===null&&(C=oe),r.baseState=C,r.firstBaseUpdate=K,r.lastBaseUpdate=le,c===null&&(r.shared.lanes=0),Ua|=m,e.lanes=m,e.memoizedState=oe}}function Up(e,t){if(typeof e!="function")throw Error(o(191,e));e.call(t)}function Lp(e,t){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)Up(a[e],t)}var Ci=k(null),Wo=k(0);function Bp(e,t){e=oa,$(Wo,e),$(Ci,t),oa=e|t.baseLanes}function cu(){$(Wo,oa),$(Ci,Ci.current)}function uu(){oa=Wo.current,I(Ci),I(Wo)}var an=k(null),_n=null;function Oa(e){var t=e.alternate;$(yt,yt.current&1),$(an,e),_n===null&&(t===null||Ci.current!==null||t.memoizedState!==null)&&(_n=e)}function du(e){$(yt,yt.current),$(an,e),_n===null&&(_n=e)}function Hp(e){e.tag===22?($(yt,yt.current),$(an,e),_n===null&&(_n=e)):Ra()}function Ra(){$(yt,yt.current),$(an,an.current)}function ln(e){I(an),_n===e&&(_n=null),I(yt)}var yt=k(0);function er(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||gd(a)||bd(a)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Wn=0,Re=null,Je=null,vt=null,tr=!1,Ai=!1,Cl=!1,nr=0,Os=0,Ni=null,m2=0;function ut(){throw Error(o(321))}function fu(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!tn(e[a],t[a]))return!1;return!0}function hu(e,t,a,i,r,c){return Wn=c,Re=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,w.H=e===null||e.memoizedState===null?wm:Cu,Cl=!1,c=a(i,r),Cl=!1,Ai&&(c=Gp(t,a,i,r)),qp(e),c}function qp(e){w.H=Ds;var t=Je!==null&&Je.next!==null;if(Wn=0,vt=Je=Re=null,tr=!1,Os=0,Ni=null,t)throw Error(o(300));e===null||xt||(e=e.dependencies,e!==null&&Yo(e)&&(xt=!0))}function Gp(e,t,a,i){Re=e;var r=0;do{if(Ai&&(Ni=null),Os=0,Ai=!1,25<=r)throw Error(o(301));if(r+=1,vt=Je=null,e.updateQueue!=null){var c=e.updateQueue;c.lastEffect=null,c.events=null,c.stores=null,c.memoCache!=null&&(c.memoCache.index=0)}w.H=Sm,c=t(a,i)}while(Ai);return c}function y2(){var e=w.H,t=e.useState()[0];return t=typeof t.then=="function"?Rs(t):t,e=e.useState()[0],(Je!==null?Je.memoizedState:null)!==e&&(Re.flags|=1024),t}function pu(){var e=nr!==0;return nr=0,e}function mu(e,t,a){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a}function yu(e){if(tr){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}tr=!1}Wn=0,vt=Je=Re=null,Ai=!1,Os=nr=0,Ni=null}function Gt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vt===null?Re.memoizedState=vt=e:vt=vt.next=e,vt}function gt(){if(Je===null){var e=Re.alternate;e=e!==null?e.memoizedState:null}else e=Je.next;var t=vt===null?Re.memoizedState:vt.next;if(t!==null)vt=t,Je=e;else{if(e===null)throw Re.alternate===null?Error(o(467)):Error(o(310));Je=e,e={memoizedState:Je.memoizedState,baseState:Je.baseState,baseQueue:Je.baseQueue,queue:Je.queue,next:null},vt===null?Re.memoizedState=vt=e:vt=vt.next=e}return vt}function ar(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Rs(e){var t=Os;return Os+=1,Ni===null&&(Ni=[]),e=Tp(Ni,e,t),t=Re,(vt===null?t.memoizedState:vt.next)===null&&(t=t.alternate,w.H=t===null||t.memoizedState===null?wm:Cu),e}function lr(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Rs(e);if(e.$$typeof===D)return Nt(e)}throw Error(o(438,String(e)))}function gu(e){var t=null,a=Re.updateQueue;if(a!==null&&(t=a.memoCache),t==null){var i=Re.alternate;i!==null&&(i=i.updateQueue,i!==null&&(i=i.memoCache,i!=null&&(t={data:i.data.map(function(r){return r.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),a===null&&(a=ar(),Re.updateQueue=a),a.memoCache=t,a=t.data[t.index],a===void 0)for(a=t.data[t.index]=Array(e),i=0;i<e;i++)a[i]=de;return t.index++,a}function ea(e,t){return typeof t=="function"?t(e):t}function ir(e){var t=gt();return bu(t,Je,e)}function bu(e,t,a){var i=e.queue;if(i===null)throw Error(o(311));i.lastRenderedReducer=a;var r=e.baseQueue,c=i.pending;if(c!==null){if(r!==null){var m=r.next;r.next=c.next,c.next=m}t.baseQueue=r=c,i.pending=null}if(c=e.baseState,r===null)e.memoizedState=c;else{t=r.next;var b=m=null,C=null,K=t,le=!1;do{var oe=K.lane&-536870913;if(oe!==K.lane?(Ge&oe)===oe:(Wn&oe)===oe){var X=K.revertLane;if(X===0)C!==null&&(C=C.next={lane:0,revertLane:0,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null}),oe===ki&&(le=!0);else if((Wn&X)===X){K=K.next,X===ki&&(le=!0);continue}else oe={lane:0,revertLane:K.revertLane,gesture:null,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},C===null?(b=C=oe,m=c):C=C.next=oe,Re.lanes|=X,Ua|=X;oe=K.action,Cl&&a(c,oe),c=K.hasEagerState?K.eagerState:a(c,oe)}else X={lane:oe,revertLane:K.revertLane,gesture:K.gesture,action:K.action,hasEagerState:K.hasEagerState,eagerState:K.eagerState,next:null},C===null?(b=C=X,m=c):C=C.next=X,Re.lanes|=oe,Ua|=oe;K=K.next}while(K!==null&&K!==t);if(C===null?m=c:C.next=b,!tn(c,e.memoizedState)&&(xt=!0,le&&(a=Ei,a!==null)))throw a;e.memoizedState=c,e.baseState=m,e.baseQueue=C,i.lastRenderedState=c}return r===null&&(i.lanes=0),[e.memoizedState,i.dispatch]}function vu(e){var t=gt(),a=t.queue;if(a===null)throw Error(o(311));a.lastRenderedReducer=e;var i=a.dispatch,r=a.pending,c=t.memoizedState;if(r!==null){a.pending=null;var m=r=r.next;do c=e(c,m.action),m=m.next;while(m!==r);tn(c,t.memoizedState)||(xt=!0),t.memoizedState=c,t.baseQueue===null&&(t.baseState=c),a.lastRenderedState=c}return[c,i]}function Ip(e,t,a){var i=Re,r=gt(),c=Qe;if(c){if(a===void 0)throw Error(o(407));a=a()}else a=t();var m=!tn((Je||r).memoizedState,a);if(m&&(r.memoizedState=a,xt=!0),r=r.queue,wu(Vp.bind(null,i,r,e),[e]),r.getSnapshot!==t||m||vt!==null&&vt.memoizedState.tag&1){if(i.flags|=2048,Ti(9,{destroy:void 0},Kp.bind(null,i,r,a,t),null),tt===null)throw Error(o(349));c||(Wn&127)!==0||Qp(i,t,a)}return a}function Qp(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=Re.updateQueue,t===null?(t=ar(),Re.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function Kp(e,t,a,i){t.value=a,t.getSnapshot=i,Yp(t)&&$p(e)}function Vp(e,t,a){return a(function(){Yp(t)&&$p(e)})}function Yp(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!tn(e,a)}catch{return!0}}function $p(e){var t=vl(e,2);t!==null&&Zt(t,e,2)}function xu(e){var t=Gt();if(typeof e=="function"){var a=e;if(e=a(),Cl){ne(!0);try{a()}finally{ne(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:e},t}function Fp(e,t,a,i){return e.baseState=a,bu(e,Je,typeof i=="function"?i:ea)}function g2(e,t,a,i,r){if(rr(e))throw Error(o(485));if(e=t.action,e!==null){var c={payload:r,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(m){c.listeners.push(m)}};w.T!==null?a(!0):c.isTransition=!1,i(c),a=t.pending,a===null?(c.next=t.pending=c,Xp(t,c)):(c.next=a.next,t.pending=a.next=c)}}function Xp(e,t){var a=t.action,i=t.payload,r=e.state;if(t.isTransition){var c=w.T,m={};w.T=m;try{var b=a(r,i),C=w.S;C!==null&&C(m,b),Zp(e,t,b)}catch(K){_u(e,t,K)}finally{c!==null&&m.types!==null&&(c.types=m.types),w.T=c}}else try{c=a(r,i),Zp(e,t,c)}catch(K){_u(e,t,K)}}function Zp(e,t,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(i){Pp(e,t,i)},function(i){return _u(e,t,i)}):Pp(e,t,a)}function Pp(e,t,a){t.status="fulfilled",t.value=a,Jp(t),e.state=a,t=e.pending,t!==null&&(a=t.next,a===t?e.pending=null:(a=a.next,t.next=a,Xp(e,a)))}function _u(e,t,a){var i=e.pending;if(e.pending=null,i!==null){i=i.next;do t.status="rejected",t.reason=a,Jp(t),t=t.next;while(t!==i)}e.action=null}function Jp(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Wp(e,t){return t}function em(e,t){if(Qe){var a=tt.formState;if(a!==null){e:{var i=Re;if(Qe){if(at){t:{for(var r=at,c=xn;r.nodeType!==8;){if(!c){r=null;break t}if(r=wn(r.nextSibling),r===null){r=null;break t}}c=r.data,r=c==="F!"||c==="F"?r:null}if(r){at=wn(r.nextSibling),i=r.data==="F!";break e}}Ma(i)}i=!1}i&&(t=a[0])}}return a=Gt(),a.memoizedState=a.baseState=t,i={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Wp,lastRenderedState:t},a.queue=i,a=vm.bind(null,Re,i),i.dispatch=a,i=xu(!1),c=Mu.bind(null,Re,!1,i.queue),i=Gt(),r={state:t,dispatch:null,action:e,pending:null},i.queue=r,a=g2.bind(null,Re,r,c,a),r.dispatch=a,i.memoizedState=e,[t,a,!1]}function tm(e){var t=gt();return nm(t,Je,e)}function nm(e,t,a){if(t=bu(e,t,Wp)[0],e=ir(ea)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var i=Rs(t)}catch(m){throw m===ji?Xo:m}else i=t;t=gt();var r=t.queue,c=r.dispatch;return a!==t.memoizedState&&(Re.flags|=2048,Ti(9,{destroy:void 0},b2.bind(null,r,a),null)),[i,c,e]}function b2(e,t){e.action=t}function am(e){var t=gt(),a=Je;if(a!==null)return nm(t,a,e);gt(),t=t.memoizedState,a=gt();var i=a.queue.dispatch;return a.memoizedState=e,[t,i,!1]}function Ti(e,t,a,i){return e={tag:e,create:a,deps:i,inst:t,next:null},t=Re.updateQueue,t===null&&(t=ar(),Re.updateQueue=t),a=t.lastEffect,a===null?t.lastEffect=e.next=e:(i=a.next,a.next=e,e.next=i,t.lastEffect=e),e}function lm(){return gt().memoizedState}function sr(e,t,a,i){var r=Gt();Re.flags|=e,r.memoizedState=Ti(1|t,{destroy:void 0},a,i===void 0?null:i)}function or(e,t,a,i){var r=gt();i=i===void 0?null:i;var c=r.memoizedState.inst;Je!==null&&i!==null&&fu(i,Je.memoizedState.deps)?r.memoizedState=Ti(t,c,a,i):(Re.flags|=e,r.memoizedState=Ti(1|t,c,a,i))}function im(e,t){sr(8390656,8,e,t)}function wu(e,t){or(2048,8,e,t)}function v2(e){Re.flags|=4;var t=Re.updateQueue;if(t===null)t=ar(),Re.updateQueue=t,t.events=[e];else{var a=t.events;a===null?t.events=[e]:a.push(e)}}function sm(e){var t=gt().memoizedState;return v2({ref:t,nextImpl:e}),function(){if((Fe&2)!==0)throw Error(o(440));return t.impl.apply(void 0,arguments)}}function om(e,t){return or(4,2,e,t)}function rm(e,t){return or(4,4,e,t)}function cm(e,t){if(typeof t=="function"){e=e();var a=t(e);return function(){typeof a=="function"?a():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function um(e,t,a){a=a!=null?a.concat([e]):null,or(4,4,cm.bind(null,t,e),a)}function Su(){}function dm(e,t){var a=gt();t=t===void 0?null:t;var i=a.memoizedState;return t!==null&&fu(t,i[1])?i[0]:(a.memoizedState=[e,t],e)}function fm(e,t){var a=gt();t=t===void 0?null:t;var i=a.memoizedState;if(t!==null&&fu(t,i[1]))return i[0];if(i=e(),Cl){ne(!0);try{e()}finally{ne(!1)}}return a.memoizedState=[i,t],i}function ku(e,t,a){return a===void 0||(Wn&1073741824)!==0&&(Ge&261930)===0?e.memoizedState=t:(e.memoizedState=a,e=hy(),Re.lanes|=e,Ua|=e,a)}function hm(e,t,a,i){return tn(a,t)?a:Ci.current!==null?(e=ku(e,a,i),tn(e,t)||(xt=!0),e):(Wn&42)===0||(Wn&1073741824)!==0&&(Ge&261930)===0?(xt=!0,e.memoizedState=a):(e=hy(),Re.lanes|=e,Ua|=e,t)}function pm(e,t,a,i,r){var c=Z.p;Z.p=c!==0&&8>c?c:8;var m=w.T,b={};w.T=b,Mu(e,!1,t,a);try{var C=r(),K=w.S;if(K!==null&&K(b,C),C!==null&&typeof C=="object"&&typeof C.then=="function"){var le=p2(C,i);zs(e,t,le,rn(e))}else zs(e,t,i,rn(e))}catch(oe){zs(e,t,{then:function(){},status:"rejected",reason:oe},rn())}finally{Z.p=c,m!==null&&b.types!==null&&(m.types=b.types),w.T=m}}function x2(){}function Eu(e,t,a,i){if(e.tag!==5)throw Error(o(476));var r=mm(e).queue;pm(e,r,t,ue,a===null?x2:function(){return ym(e),a(i)})}function mm(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ue,baseState:ue,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:ue},next:null};var a={};return t.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:ea,lastRenderedState:a},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function ym(e){var t=mm(e);t.next===null&&(t=e.alternate.memoizedState),zs(e,t.next.queue,{},rn())}function ju(){return Nt(Ps)}function gm(){return gt().memoizedState}function bm(){return gt().memoizedState}function _2(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var a=rn();e=Na(a);var i=Ta(t,e,a);i!==null&&(Zt(i,t,a),As(i,t,a)),t={cache:tu()},e.payload=t;return}t=t.return}}function w2(e,t,a){var i=rn();a={lane:i,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},rr(e)?xm(t,a):(a=Kc(e,t,a,i),a!==null&&(Zt(a,e,i),_m(a,t,i)))}function vm(e,t,a){var i=rn();zs(e,t,a,i)}function zs(e,t,a,i){var r={lane:i,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(rr(e))xm(t,r);else{var c=e.alternate;if(e.lanes===0&&(c===null||c.lanes===0)&&(c=t.lastRenderedReducer,c!==null))try{var m=t.lastRenderedState,b=c(m,a);if(r.hasEagerState=!0,r.eagerState=b,tn(b,m))return Io(e,t,r,0),tt===null&&Go(),!1}catch{}finally{}if(a=Kc(e,t,r,i),a!==null)return Zt(a,e,i),_m(a,t,i),!0}return!1}function Mu(e,t,a,i){if(i={lane:2,revertLane:id(),gesture:null,action:i,hasEagerState:!1,eagerState:null,next:null},rr(e)){if(t)throw Error(o(479))}else t=Kc(e,a,i,2),t!==null&&Zt(t,e,2)}function rr(e){var t=e.alternate;return e===Re||t!==null&&t===Re}function xm(e,t){Ai=tr=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function _m(e,t,a){if((a&4194048)!==0){var i=t.lanes;i&=e.pendingLanes,a|=i,t.lanes=a,jh(e,a)}}var Ds={readContext:Nt,use:lr,useCallback:ut,useContext:ut,useEffect:ut,useImperativeHandle:ut,useLayoutEffect:ut,useInsertionEffect:ut,useMemo:ut,useReducer:ut,useRef:ut,useState:ut,useDebugValue:ut,useDeferredValue:ut,useTransition:ut,useSyncExternalStore:ut,useId:ut,useHostTransitionStatus:ut,useFormState:ut,useActionState:ut,useOptimistic:ut,useMemoCache:ut,useCacheRefresh:ut};Ds.useEffectEvent=ut;var wm={readContext:Nt,use:lr,useCallback:function(e,t){return Gt().memoizedState=[e,t===void 0?null:t],e},useContext:Nt,useEffect:im,useImperativeHandle:function(e,t,a){a=a!=null?a.concat([e]):null,sr(4194308,4,cm.bind(null,t,e),a)},useLayoutEffect:function(e,t){return sr(4194308,4,e,t)},useInsertionEffect:function(e,t){sr(4,2,e,t)},useMemo:function(e,t){var a=Gt();t=t===void 0?null:t;var i=e();if(Cl){ne(!0);try{e()}finally{ne(!1)}}return a.memoizedState=[i,t],i},useReducer:function(e,t,a){var i=Gt();if(a!==void 0){var r=a(t);if(Cl){ne(!0);try{a(t)}finally{ne(!1)}}}else r=t;return i.memoizedState=i.baseState=r,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:r},i.queue=e,e=e.dispatch=w2.bind(null,Re,e),[i.memoizedState,e]},useRef:function(e){var t=Gt();return e={current:e},t.memoizedState=e},useState:function(e){e=xu(e);var t=e.queue,a=vm.bind(null,Re,t);return t.dispatch=a,[e.memoizedState,a]},useDebugValue:Su,useDeferredValue:function(e,t){var a=Gt();return ku(a,e,t)},useTransition:function(){var e=xu(!1);return e=pm.bind(null,Re,e.queue,!0,!1),Gt().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,a){var i=Re,r=Gt();if(Qe){if(a===void 0)throw Error(o(407));a=a()}else{if(a=t(),tt===null)throw Error(o(349));(Ge&127)!==0||Qp(i,t,a)}r.memoizedState=a;var c={value:a,getSnapshot:t};return r.queue=c,im(Vp.bind(null,i,c,e),[e]),i.flags|=2048,Ti(9,{destroy:void 0},Kp.bind(null,i,c,a,t),null),a},useId:function(){var e=Gt(),t=tt.identifierPrefix;if(Qe){var a=zn,i=Rn;a=(i&~(1<<32-pe(i)-1)).toString(32)+a,t="_"+t+"R_"+a,a=nr++,0<a&&(t+="H"+a.toString(32)),t+="_"}else a=m2++,t="_"+t+"r_"+a.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:ju,useFormState:em,useActionState:em,useOptimistic:function(e){var t=Gt();t.memoizedState=t.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=a,t=Mu.bind(null,Re,!0,a),a.dispatch=t,[e,t]},useMemoCache:gu,useCacheRefresh:function(){return Gt().memoizedState=_2.bind(null,Re)},useEffectEvent:function(e){var t=Gt(),a={impl:e};return t.memoizedState=a,function(){if((Fe&2)!==0)throw Error(o(440));return a.impl.apply(void 0,arguments)}}},Cu={readContext:Nt,use:lr,useCallback:dm,useContext:Nt,useEffect:wu,useImperativeHandle:um,useInsertionEffect:om,useLayoutEffect:rm,useMemo:fm,useReducer:ir,useRef:lm,useState:function(){return ir(ea)},useDebugValue:Su,useDeferredValue:function(e,t){var a=gt();return hm(a,Je.memoizedState,e,t)},useTransition:function(){var e=ir(ea)[0],t=gt().memoizedState;return[typeof e=="boolean"?e:Rs(e),t]},useSyncExternalStore:Ip,useId:gm,useHostTransitionStatus:ju,useFormState:tm,useActionState:tm,useOptimistic:function(e,t){var a=gt();return Fp(a,Je,e,t)},useMemoCache:gu,useCacheRefresh:bm};Cu.useEffectEvent=sm;var Sm={readContext:Nt,use:lr,useCallback:dm,useContext:Nt,useEffect:wu,useImperativeHandle:um,useInsertionEffect:om,useLayoutEffect:rm,useMemo:fm,useReducer:vu,useRef:lm,useState:function(){return vu(ea)},useDebugValue:Su,useDeferredValue:function(e,t){var a=gt();return Je===null?ku(a,e,t):hm(a,Je.memoizedState,e,t)},useTransition:function(){var e=vu(ea)[0],t=gt().memoizedState;return[typeof e=="boolean"?e:Rs(e),t]},useSyncExternalStore:Ip,useId:gm,useHostTransitionStatus:ju,useFormState:am,useActionState:am,useOptimistic:function(e,t){var a=gt();return Je!==null?Fp(a,Je,e,t):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:gu,useCacheRefresh:bm};Sm.useEffectEvent=sm;function Au(e,t,a,i){t=e.memoizedState,a=a(i,t),a=a==null?t:v({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var Nu={enqueueSetState:function(e,t,a){e=e._reactInternals;var i=rn(),r=Na(i);r.payload=t,a!=null&&(r.callback=a),t=Ta(e,r,i),t!==null&&(Zt(t,e,i),As(t,e,i))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var i=rn(),r=Na(i);r.tag=1,r.payload=t,a!=null&&(r.callback=a),t=Ta(e,r,i),t!==null&&(Zt(t,e,i),As(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=rn(),i=Na(a);i.tag=2,t!=null&&(i.callback=t),t=Ta(e,i,a),t!==null&&(Zt(t,e,a),As(t,e,a))}};function km(e,t,a,i,r,c,m){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(i,c,m):t.prototype&&t.prototype.isPureReactComponent?!_s(a,i)||!_s(r,c):!0}function Em(e,t,a,i){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,i),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,i),t.state!==e&&Nu.enqueueReplaceState(t,t.state,null)}function Al(e,t){var a=t;if("ref"in t){a={};for(var i in t)i!=="ref"&&(a[i]=t[i])}if(e=e.defaultProps){a===t&&(a=v({},a));for(var r in e)a[r]===void 0&&(a[r]=e[r])}return a}function jm(e){qo(e)}function Mm(e){console.error(e)}function Cm(e){qo(e)}function cr(e,t){try{var a=e.onUncaughtError;a(t.value,{componentStack:t.stack})}catch(i){setTimeout(function(){throw i})}}function Am(e,t,a){try{var i=e.onCaughtError;i(a.value,{componentStack:a.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(r){setTimeout(function(){throw r})}}function Tu(e,t,a){return a=Na(a),a.tag=3,a.payload={element:null},a.callback=function(){cr(e,t)},a}function Nm(e){return e=Na(e),e.tag=3,e}function Tm(e,t,a,i){var r=a.type.getDerivedStateFromError;if(typeof r=="function"){var c=i.value;e.payload=function(){return r(c)},e.callback=function(){Am(t,a,i)}}var m=a.stateNode;m!==null&&typeof m.componentDidCatch=="function"&&(e.callback=function(){Am(t,a,i),typeof r!="function"&&(La===null?La=new Set([this]):La.add(this));var b=i.stack;this.componentDidCatch(i.value,{componentStack:b!==null?b:""})})}function S2(e,t,a,i,r){if(a.flags|=32768,i!==null&&typeof i=="object"&&typeof i.then=="function"){if(t=a.alternate,t!==null&&Si(t,a,r,!0),a=an.current,a!==null){switch(a.tag){case 31:case 13:return _n===null?_r():a.alternate===null&&dt===0&&(dt=3),a.flags&=-257,a.flags|=65536,a.lanes=r,i===Zo?a.flags|=16384:(t=a.updateQueue,t===null?a.updateQueue=new Set([i]):t.add(i),nd(e,i,r)),!1;case 22:return a.flags|=65536,i===Zo?a.flags|=16384:(t=a.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([i])},a.updateQueue=t):(a=t.retryQueue,a===null?t.retryQueue=new Set([i]):a.add(i)),nd(e,i,r)),!1}throw Error(o(435,a.tag))}return nd(e,i,r),_r(),!1}if(Qe)return t=an.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=r,i!==Zc&&(e=Error(o(422),{cause:i}),ks(gn(e,a)))):(i!==Zc&&(t=Error(o(423),{cause:i}),ks(gn(t,a))),e=e.current.alternate,e.flags|=65536,r&=-r,e.lanes|=r,i=gn(i,a),r=Tu(e.stateNode,i,r),ou(e,r),dt!==4&&(dt=2)),!1;var c=Error(o(520),{cause:i});if(c=gn(c,a),Qs===null?Qs=[c]:Qs.push(c),dt!==4&&(dt=2),t===null)return!0;i=gn(i,a),a=t;do{switch(a.tag){case 3:return a.flags|=65536,e=r&-r,a.lanes|=e,e=Tu(a.stateNode,i,e),ou(a,e),!1;case 1:if(t=a.type,c=a.stateNode,(a.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||c!==null&&typeof c.componentDidCatch=="function"&&(La===null||!La.has(c))))return a.flags|=65536,r&=-r,a.lanes|=r,r=Nm(r),Tm(r,e,a,i),ou(a,r),!1}a=a.return}while(a!==null);return!1}var Ou=Error(o(461)),xt=!1;function Tt(e,t,a,i){t.child=e===null?Dp(t,null,a,i):Ml(t,e.child,a,i)}function Om(e,t,a,i,r){a=a.render;var c=t.ref;if("ref"in i){var m={};for(var b in i)b!=="ref"&&(m[b]=i[b])}else m=i;return Sl(t),i=hu(e,t,a,m,c,r),b=pu(),e!==null&&!xt?(mu(e,t,r),ta(e,t,r)):(Qe&&b&&Fc(t),t.flags|=1,Tt(e,t,i,r),t.child)}function Rm(e,t,a,i,r){if(e===null){var c=a.type;return typeof c=="function"&&!Vc(c)&&c.defaultProps===void 0&&a.compare===null?(t.tag=15,t.type=c,zm(e,t,c,i,r)):(e=Ko(a.type,null,i,t,t.mode,r),e.ref=t.ref,e.return=t,t.child=e)}if(c=e.child,!qu(e,r)){var m=c.memoizedProps;if(a=a.compare,a=a!==null?a:_s,a(m,i)&&e.ref===t.ref)return ta(e,t,r)}return t.flags|=1,e=Xn(c,i),e.ref=t.ref,e.return=t,t.child=e}function zm(e,t,a,i,r){if(e!==null){var c=e.memoizedProps;if(_s(c,i)&&e.ref===t.ref)if(xt=!1,t.pendingProps=i=c,qu(e,r))(e.flags&131072)!==0&&(xt=!0);else return t.lanes=e.lanes,ta(e,t,r)}return Ru(e,t,a,i,r)}function Dm(e,t,a,i){var r=i.children,c=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),i.mode==="hidden"){if((t.flags&128)!==0){if(c=c!==null?c.baseLanes|a:a,e!==null){for(i=t.child=e.child,r=0;i!==null;)r=r|i.lanes|i.childLanes,i=i.sibling;i=r&~c}else i=0,t.child=null;return Um(e,t,c,a,i)}if((a&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Fo(t,c!==null?c.cachePool:null),c!==null?Bp(t,c):cu(),Hp(t);else return i=t.lanes=536870912,Um(e,t,c!==null?c.baseLanes|a:a,a,i)}else c!==null?(Fo(t,c.cachePool),Bp(t,c),Ra(),t.memoizedState=null):(e!==null&&Fo(t,null),cu(),Ra());return Tt(e,t,r,a),t.child}function Us(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Um(e,t,a,i,r){var c=au();return c=c===null?null:{parent:bt._currentValue,pool:c},t.memoizedState={baseLanes:a,cachePool:c},e!==null&&Fo(t,null),cu(),Hp(t),e!==null&&Si(e,t,i,!0),t.childLanes=r,null}function ur(e,t){return t=fr({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Lm(e,t,a){return Ml(t,e.child,null,a),e=ur(t,t.pendingProps),e.flags|=2,ln(t),t.memoizedState=null,e}function k2(e,t,a){var i=t.pendingProps,r=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Qe){if(i.mode==="hidden")return e=ur(t,i),t.lanes=536870912,Us(null,e);if(du(t),(e=at)?(e=Xy(e,xn),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ea!==null?{id:Rn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},a=xp(e),a.return=t,t.child=a,At=t,at=null)):e=null,e===null)throw Ma(t);return t.lanes=536870912,null}return ur(t,i)}var c=e.memoizedState;if(c!==null){var m=c.dehydrated;if(du(t),r)if(t.flags&256)t.flags&=-257,t=Lm(e,t,a);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(o(558));else if(xt||Si(e,t,a,!1),r=(a&e.childLanes)!==0,xt||r){if(i=tt,i!==null&&(m=Mh(i,a),m!==0&&m!==c.retryLane))throw c.retryLane=m,vl(e,m),Zt(i,e,m),Ou;_r(),t=Lm(e,t,a)}else e=c.treeContext,at=wn(m.nextSibling),At=t,Qe=!0,ja=null,xn=!1,e!==null&&Sp(t,e),t=ur(t,i),t.flags|=4096;return t}return e=Xn(e.child,{mode:i.mode,children:i.children}),e.ref=t.ref,t.child=e,e.return=t,e}function dr(e,t){var a=t.ref;if(a===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(o(284));(e===null||e.ref!==a)&&(t.flags|=4194816)}}function Ru(e,t,a,i,r){return Sl(t),a=hu(e,t,a,i,void 0,r),i=pu(),e!==null&&!xt?(mu(e,t,r),ta(e,t,r)):(Qe&&i&&Fc(t),t.flags|=1,Tt(e,t,a,r),t.child)}function Bm(e,t,a,i,r,c){return Sl(t),t.updateQueue=null,a=Gp(t,i,a,r),qp(e),i=pu(),e!==null&&!xt?(mu(e,t,c),ta(e,t,c)):(Qe&&i&&Fc(t),t.flags|=1,Tt(e,t,a,c),t.child)}function Hm(e,t,a,i,r){if(Sl(t),t.stateNode===null){var c=vi,m=a.contextType;typeof m=="object"&&m!==null&&(c=Nt(m)),c=new a(i,c),t.memoizedState=c.state!==null&&c.state!==void 0?c.state:null,c.updater=Nu,t.stateNode=c,c._reactInternals=t,c=t.stateNode,c.props=i,c.state=t.memoizedState,c.refs={},iu(t),m=a.contextType,c.context=typeof m=="object"&&m!==null?Nt(m):vi,c.state=t.memoizedState,m=a.getDerivedStateFromProps,typeof m=="function"&&(Au(t,a,m,i),c.state=t.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof c.getSnapshotBeforeUpdate=="function"||typeof c.UNSAFE_componentWillMount!="function"&&typeof c.componentWillMount!="function"||(m=c.state,typeof c.componentWillMount=="function"&&c.componentWillMount(),typeof c.UNSAFE_componentWillMount=="function"&&c.UNSAFE_componentWillMount(),m!==c.state&&Nu.enqueueReplaceState(c,c.state,null),Ts(t,i,c,r),Ns(),c.state=t.memoizedState),typeof c.componentDidMount=="function"&&(t.flags|=4194308),i=!0}else if(e===null){c=t.stateNode;var b=t.memoizedProps,C=Al(a,b);c.props=C;var K=c.context,le=a.contextType;m=vi,typeof le=="object"&&le!==null&&(m=Nt(le));var oe=a.getDerivedStateFromProps;le=typeof oe=="function"||typeof c.getSnapshotBeforeUpdate=="function",b=t.pendingProps!==b,le||typeof c.UNSAFE_componentWillReceiveProps!="function"&&typeof c.componentWillReceiveProps!="function"||(b||K!==m)&&Em(t,c,i,m),Aa=!1;var X=t.memoizedState;c.state=X,Ts(t,i,c,r),Ns(),K=t.memoizedState,b||X!==K||Aa?(typeof oe=="function"&&(Au(t,a,oe,i),K=t.memoizedState),(C=Aa||km(t,a,C,i,X,K,m))?(le||typeof c.UNSAFE_componentWillMount!="function"&&typeof c.componentWillMount!="function"||(typeof c.componentWillMount=="function"&&c.componentWillMount(),typeof c.UNSAFE_componentWillMount=="function"&&c.UNSAFE_componentWillMount()),typeof c.componentDidMount=="function"&&(t.flags|=4194308)):(typeof c.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=i,t.memoizedState=K),c.props=i,c.state=K,c.context=m,i=C):(typeof c.componentDidMount=="function"&&(t.flags|=4194308),i=!1)}else{c=t.stateNode,su(e,t),m=t.memoizedProps,le=Al(a,m),c.props=le,oe=t.pendingProps,X=c.context,K=a.contextType,C=vi,typeof K=="object"&&K!==null&&(C=Nt(K)),b=a.getDerivedStateFromProps,(K=typeof b=="function"||typeof c.getSnapshotBeforeUpdate=="function")||typeof c.UNSAFE_componentWillReceiveProps!="function"&&typeof c.componentWillReceiveProps!="function"||(m!==oe||X!==C)&&Em(t,c,i,C),Aa=!1,X=t.memoizedState,c.state=X,Ts(t,i,c,r),Ns();var J=t.memoizedState;m!==oe||X!==J||Aa||e!==null&&e.dependencies!==null&&Yo(e.dependencies)?(typeof b=="function"&&(Au(t,a,b,i),J=t.memoizedState),(le=Aa||km(t,a,le,i,X,J,C)||e!==null&&e.dependencies!==null&&Yo(e.dependencies))?(K||typeof c.UNSAFE_componentWillUpdate!="function"&&typeof c.componentWillUpdate!="function"||(typeof c.componentWillUpdate=="function"&&c.componentWillUpdate(i,J,C),typeof c.UNSAFE_componentWillUpdate=="function"&&c.UNSAFE_componentWillUpdate(i,J,C)),typeof c.componentDidUpdate=="function"&&(t.flags|=4),typeof c.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof c.componentDidUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=4),typeof c.getSnapshotBeforeUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=1024),t.memoizedProps=i,t.memoizedState=J),c.props=i,c.state=J,c.context=C,i=le):(typeof c.componentDidUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=4),typeof c.getSnapshotBeforeUpdate!="function"||m===e.memoizedProps&&X===e.memoizedState||(t.flags|=1024),i=!1)}return c=i,dr(e,t),i=(t.flags&128)!==0,c||i?(c=t.stateNode,a=i&&typeof a.getDerivedStateFromError!="function"?null:c.render(),t.flags|=1,e!==null&&i?(t.child=Ml(t,e.child,null,r),t.child=Ml(t,null,a,r)):Tt(e,t,a,r),t.memoizedState=c.state,e=t.child):e=ta(e,t,r),e}function qm(e,t,a,i){return _l(),t.flags|=256,Tt(e,t,a,i),t.child}var zu={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Du(e){return{baseLanes:e,cachePool:Ap()}}function Uu(e,t,a){return e=e!==null?e.childLanes&~a:0,t&&(e|=on),e}function Gm(e,t,a){var i=t.pendingProps,r=!1,c=(t.flags&128)!==0,m;if((m=c)||(m=e!==null&&e.memoizedState===null?!1:(yt.current&2)!==0),m&&(r=!0,t.flags&=-129),m=(t.flags&32)!==0,t.flags&=-33,e===null){if(Qe){if(r?Oa(t):Ra(),(e=at)?(e=Xy(e,xn),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ea!==null?{id:Rn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},a=xp(e),a.return=t,t.child=a,At=t,at=null)):e=null,e===null)throw Ma(t);return bd(e)?t.lanes=32:t.lanes=536870912,null}var b=i.children;return i=i.fallback,r?(Ra(),r=t.mode,b=fr({mode:"hidden",children:b},r),i=xl(i,r,a,null),b.return=t,i.return=t,b.sibling=i,t.child=b,i=t.child,i.memoizedState=Du(a),i.childLanes=Uu(e,m,a),t.memoizedState=zu,Us(null,i)):(Oa(t),Lu(t,b))}var C=e.memoizedState;if(C!==null&&(b=C.dehydrated,b!==null)){if(c)t.flags&256?(Oa(t),t.flags&=-257,t=Bu(e,t,a)):t.memoizedState!==null?(Ra(),t.child=e.child,t.flags|=128,t=null):(Ra(),b=i.fallback,r=t.mode,i=fr({mode:"visible",children:i.children},r),b=xl(b,r,a,null),b.flags|=2,i.return=t,b.return=t,i.sibling=b,t.child=i,Ml(t,e.child,null,a),i=t.child,i.memoizedState=Du(a),i.childLanes=Uu(e,m,a),t.memoizedState=zu,t=Us(null,i));else if(Oa(t),bd(b)){if(m=b.nextSibling&&b.nextSibling.dataset,m)var K=m.dgst;m=K,i=Error(o(419)),i.stack="",i.digest=m,ks({value:i,source:null,stack:null}),t=Bu(e,t,a)}else if(xt||Si(e,t,a,!1),m=(a&e.childLanes)!==0,xt||m){if(m=tt,m!==null&&(i=Mh(m,a),i!==0&&i!==C.retryLane))throw C.retryLane=i,vl(e,i),Zt(m,e,i),Ou;gd(b)||_r(),t=Bu(e,t,a)}else gd(b)?(t.flags|=192,t.child=e.child,t=null):(e=C.treeContext,at=wn(b.nextSibling),At=t,Qe=!0,ja=null,xn=!1,e!==null&&Sp(t,e),t=Lu(t,i.children),t.flags|=4096);return t}return r?(Ra(),b=i.fallback,r=t.mode,C=e.child,K=C.sibling,i=Xn(C,{mode:"hidden",children:i.children}),i.subtreeFlags=C.subtreeFlags&65011712,K!==null?b=Xn(K,b):(b=xl(b,r,a,null),b.flags|=2),b.return=t,i.return=t,i.sibling=b,t.child=i,Us(null,i),i=t.child,b=e.child.memoizedState,b===null?b=Du(a):(r=b.cachePool,r!==null?(C=bt._currentValue,r=r.parent!==C?{parent:C,pool:C}:r):r=Ap(),b={baseLanes:b.baseLanes|a,cachePool:r}),i.memoizedState=b,i.childLanes=Uu(e,m,a),t.memoizedState=zu,Us(e.child,i)):(Oa(t),a=e.child,e=a.sibling,a=Xn(a,{mode:"visible",children:i.children}),a.return=t,a.sibling=null,e!==null&&(m=t.deletions,m===null?(t.deletions=[e],t.flags|=16):m.push(e)),t.child=a,t.memoizedState=null,a)}function Lu(e,t){return t=fr({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function fr(e,t){return e=nn(22,e,null,t),e.lanes=0,e}function Bu(e,t,a){return Ml(t,e.child,null,a),e=Lu(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Im(e,t,a){e.lanes|=t;var i=e.alternate;i!==null&&(i.lanes|=t),Wc(e.return,t,a)}function Hu(e,t,a,i,r,c){var m=e.memoizedState;m===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:i,tail:a,tailMode:r,treeForkCount:c}:(m.isBackwards=t,m.rendering=null,m.renderingStartTime=0,m.last=i,m.tail=a,m.tailMode=r,m.treeForkCount=c)}function Qm(e,t,a){var i=t.pendingProps,r=i.revealOrder,c=i.tail;i=i.children;var m=yt.current,b=(m&2)!==0;if(b?(m=m&1|2,t.flags|=128):m&=1,$(yt,m),Tt(e,t,i,a),i=Qe?Ss:0,!b&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Im(e,a,t);else if(e.tag===19)Im(e,a,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(r){case"forwards":for(a=t.child,r=null;a!==null;)e=a.alternate,e!==null&&er(e)===null&&(r=a),a=a.sibling;a=r,a===null?(r=t.child,t.child=null):(r=a.sibling,a.sibling=null),Hu(t,!1,r,a,c,i);break;case"backwards":case"unstable_legacy-backwards":for(a=null,r=t.child,t.child=null;r!==null;){if(e=r.alternate,e!==null&&er(e)===null){t.child=r;break}e=r.sibling,r.sibling=a,a=r,r=e}Hu(t,!0,a,null,c,i);break;case"together":Hu(t,!1,null,null,void 0,i);break;default:t.memoizedState=null}return t.child}function ta(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),Ua|=t.lanes,(a&t.childLanes)===0)if(e!==null){if(Si(e,t,a,!1),(a&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(o(153));if(t.child!==null){for(e=t.child,a=Xn(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Xn(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function qu(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Yo(e)))}function E2(e,t,a){switch(t.tag){case 3:me(t,t.stateNode.containerInfo),Ca(t,bt,e.memoizedState.cache),_l();break;case 27:case 5:ke(t);break;case 4:me(t,t.stateNode.containerInfo);break;case 10:Ca(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,du(t),null;break;case 13:var i=t.memoizedState;if(i!==null)return i.dehydrated!==null?(Oa(t),t.flags|=128,null):(a&t.child.childLanes)!==0?Gm(e,t,a):(Oa(t),e=ta(e,t,a),e!==null?e.sibling:null);Oa(t);break;case 19:var r=(e.flags&128)!==0;if(i=(a&t.childLanes)!==0,i||(Si(e,t,a,!1),i=(a&t.childLanes)!==0),r){if(i)return Qm(e,t,a);t.flags|=128}if(r=t.memoizedState,r!==null&&(r.rendering=null,r.tail=null,r.lastEffect=null),$(yt,yt.current),i)break;return null;case 22:return t.lanes=0,Dm(e,t,a,t.pendingProps);case 24:Ca(t,bt,e.memoizedState.cache)}return ta(e,t,a)}function Km(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps)xt=!0;else{if(!qu(e,a)&&(t.flags&128)===0)return xt=!1,E2(e,t,a);xt=(e.flags&131072)!==0}else xt=!1,Qe&&(t.flags&1048576)!==0&&wp(t,Ss,t.index);switch(t.lanes=0,t.tag){case 16:e:{var i=t.pendingProps;if(e=El(t.elementType),t.type=e,typeof e=="function")Vc(e)?(i=Al(e,i),t.tag=1,t=Hm(null,t,e,i,a)):(t.tag=0,t=Ru(null,t,e,i,a));else{if(e!=null){var r=e.$$typeof;if(r===Y){t.tag=11,t=Om(null,t,e,i,a);break e}else if(r===ae){t.tag=14,t=Rm(null,t,e,i,a);break e}}throw t=G(e)||e,Error(o(306,t,""))}}return t;case 0:return Ru(e,t,t.type,t.pendingProps,a);case 1:return i=t.type,r=Al(i,t.pendingProps),Hm(e,t,i,r,a);case 3:e:{if(me(t,t.stateNode.containerInfo),e===null)throw Error(o(387));i=t.pendingProps;var c=t.memoizedState;r=c.element,su(e,t),Ts(t,i,null,a);var m=t.memoizedState;if(i=m.cache,Ca(t,bt,i),i!==c.cache&&eu(t,[bt],a,!0),Ns(),i=m.element,c.isDehydrated)if(c={element:i,isDehydrated:!1,cache:m.cache},t.updateQueue.baseState=c,t.memoizedState=c,t.flags&256){t=qm(e,t,i,a);break e}else if(i!==r){r=gn(Error(o(424)),t),ks(r),t=qm(e,t,i,a);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(at=wn(e.firstChild),At=t,Qe=!0,ja=null,xn=!0,a=Dp(t,null,i,a),t.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling}else{if(_l(),i===r){t=ta(e,t,a);break e}Tt(e,t,i,a)}t=t.child}return t;case 26:return dr(e,t),e===null?(a=tg(t.type,null,t.pendingProps,null))?t.memoizedState=a:Qe||(a=t.type,e=t.pendingProps,i=Cr(q.current).createElement(a),i[Ct]=t,i[Kt]=e,Ot(i,a,e),Et(i),t.stateNode=i):t.memoizedState=tg(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return ke(t),e===null&&Qe&&(i=t.stateNode=Jy(t.type,t.pendingProps,q.current),At=t,xn=!0,r=at,Ga(t.type)?(vd=r,at=wn(i.firstChild)):at=r),Tt(e,t,t.pendingProps.children,a),dr(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Qe&&((r=i=at)&&(i=t_(i,t.type,t.pendingProps,xn),i!==null?(t.stateNode=i,At=t,at=wn(i.firstChild),xn=!1,r=!0):r=!1),r||Ma(t)),ke(t),r=t.type,c=t.pendingProps,m=e!==null?e.memoizedProps:null,i=c.children,pd(r,c)?i=null:m!==null&&pd(r,m)&&(t.flags|=32),t.memoizedState!==null&&(r=hu(e,t,y2,null,null,a),Ps._currentValue=r),dr(e,t),Tt(e,t,i,a),t.child;case 6:return e===null&&Qe&&((e=a=at)&&(a=n_(a,t.pendingProps,xn),a!==null?(t.stateNode=a,At=t,at=null,e=!0):e=!1),e||Ma(t)),null;case 13:return Gm(e,t,a);case 4:return me(t,t.stateNode.containerInfo),i=t.pendingProps,e===null?t.child=Ml(t,null,i,a):Tt(e,t,i,a),t.child;case 11:return Om(e,t,t.type,t.pendingProps,a);case 7:return Tt(e,t,t.pendingProps,a),t.child;case 8:return Tt(e,t,t.pendingProps.children,a),t.child;case 12:return Tt(e,t,t.pendingProps.children,a),t.child;case 10:return i=t.pendingProps,Ca(t,t.type,i.value),Tt(e,t,i.children,a),t.child;case 9:return r=t.type._context,i=t.pendingProps.children,Sl(t),r=Nt(r),i=i(r),t.flags|=1,Tt(e,t,i,a),t.child;case 14:return Rm(e,t,t.type,t.pendingProps,a);case 15:return zm(e,t,t.type,t.pendingProps,a);case 19:return Qm(e,t,a);case 31:return k2(e,t,a);case 22:return Dm(e,t,a,t.pendingProps);case 24:return Sl(t),i=Nt(bt),e===null?(r=au(),r===null&&(r=tt,c=tu(),r.pooledCache=c,c.refCount++,c!==null&&(r.pooledCacheLanes|=a),r=c),t.memoizedState={parent:i,cache:r},iu(t),Ca(t,bt,r)):((e.lanes&a)!==0&&(su(e,t),Ts(t,null,null,a),Ns()),r=e.memoizedState,c=t.memoizedState,r.parent!==i?(r={parent:i,cache:i},t.memoizedState=r,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=r),Ca(t,bt,i)):(i=c.cache,Ca(t,bt,i),i!==r.cache&&eu(t,[bt],a,!0))),Tt(e,t,t.pendingProps.children,a),t.child;case 29:throw t.pendingProps}throw Error(o(156,t.tag))}function na(e){e.flags|=4}function Gu(e,t,a,i,r){if((t=(e.mode&32)!==0)&&(t=!1),t){if(e.flags|=16777216,(r&335544128)===r)if(e.stateNode.complete)e.flags|=8192;else if(gy())e.flags|=8192;else throw jl=Zo,lu}else e.flags&=-16777217}function Vm(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!sg(t))if(gy())e.flags|=8192;else throw jl=Zo,lu}function hr(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?jn():536870912,e.lanes|=t,Di|=t)}function Ls(e,t){if(!Qe)switch(e.tailMode){case"hidden":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var i=null;a!==null;)a.alternate!==null&&(i=a),a=a.sibling;i===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:i.sibling=null}}function lt(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,i=0;if(t)for(var r=e.child;r!==null;)a|=r.lanes|r.childLanes,i|=r.subtreeFlags&65011712,i|=r.flags&65011712,r.return=e,r=r.sibling;else for(r=e.child;r!==null;)a|=r.lanes|r.childLanes,i|=r.subtreeFlags,i|=r.flags,r.return=e,r=r.sibling;return e.subtreeFlags|=i,e.childLanes=a,t}function j2(e,t,a){var i=t.pendingProps;switch(Xc(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return lt(t),null;case 1:return lt(t),null;case 3:return a=t.stateNode,i=null,e!==null&&(i=e.memoizedState.cache),t.memoizedState.cache!==i&&(t.flags|=2048),Jn(bt),he(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(wi(t)?na(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,Pc())),lt(t),null;case 26:var r=t.type,c=t.memoizedState;return e===null?(na(t),c!==null?(lt(t),Vm(t,c)):(lt(t),Gu(t,r,null,i,a))):c?c!==e.memoizedState?(na(t),lt(t),Vm(t,c)):(lt(t),t.flags&=-16777217):(e=e.memoizedProps,e!==i&&na(t),lt(t),Gu(t,r,e,i,a)),null;case 27:if(Ae(t),a=q.current,r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(!i){if(t.stateNode===null)throw Error(o(166));return lt(t),null}e=T.current,wi(t)?kp(t):(e=Jy(r,i,a),t.stateNode=e,na(t))}return lt(t),null;case 5:if(Ae(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(!i){if(t.stateNode===null)throw Error(o(166));return lt(t),null}if(c=T.current,wi(t))kp(t);else{var m=Cr(q.current);switch(c){case 1:c=m.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:c=m.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":c=m.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":c=m.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":c=m.createElement("div"),c.innerHTML="<script><\/script>",c=c.removeChild(c.firstChild);break;case"select":c=typeof i.is=="string"?m.createElement("select",{is:i.is}):m.createElement("select"),i.multiple?c.multiple=!0:i.size&&(c.size=i.size);break;default:c=typeof i.is=="string"?m.createElement(r,{is:i.is}):m.createElement(r)}}c[Ct]=t,c[Kt]=i;e:for(m=t.child;m!==null;){if(m.tag===5||m.tag===6)c.appendChild(m.stateNode);else if(m.tag!==4&&m.tag!==27&&m.child!==null){m.child.return=m,m=m.child;continue}if(m===t)break e;for(;m.sibling===null;){if(m.return===null||m.return===t)break e;m=m.return}m.sibling.return=m.return,m=m.sibling}t.stateNode=c;e:switch(Ot(c,r,i),r){case"button":case"input":case"select":case"textarea":i=!!i.autoFocus;break e;case"img":i=!0;break e;default:i=!1}i&&na(t)}}return lt(t),Gu(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,a),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==i&&na(t);else{if(typeof i!="string"&&t.stateNode===null)throw Error(o(166));if(e=q.current,wi(t)){if(e=t.stateNode,a=t.memoizedProps,i=null,r=At,r!==null)switch(r.tag){case 27:case 5:i=r.memoizedProps}e[Ct]=t,e=!!(e.nodeValue===a||i!==null&&i.suppressHydrationWarning===!0||Gy(e.nodeValue,a)),e||Ma(t,!0)}else e=Cr(e).createTextNode(i),e[Ct]=t,t.stateNode=e}return lt(t),null;case 31:if(a=t.memoizedState,e===null||e.memoizedState!==null){if(i=wi(t),a!==null){if(e===null){if(!i)throw Error(o(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(o(557));e[Ct]=t}else _l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;lt(t),e=!1}else a=Pc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),e=!0;if(!e)return t.flags&256?(ln(t),t):(ln(t),null);if((t.flags&128)!==0)throw Error(o(558))}return lt(t),null;case 13:if(i=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(r=wi(t),i!==null&&i.dehydrated!==null){if(e===null){if(!r)throw Error(o(318));if(r=t.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(o(317));r[Ct]=t}else _l(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;lt(t),r=!1}else r=Pc(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=r),r=!0;if(!r)return t.flags&256?(ln(t),t):(ln(t),null)}return ln(t),(t.flags&128)!==0?(t.lanes=a,t):(a=i!==null,e=e!==null&&e.memoizedState!==null,a&&(i=t.child,r=null,i.alternate!==null&&i.alternate.memoizedState!==null&&i.alternate.memoizedState.cachePool!==null&&(r=i.alternate.memoizedState.cachePool.pool),c=null,i.memoizedState!==null&&i.memoizedState.cachePool!==null&&(c=i.memoizedState.cachePool.pool),c!==r&&(i.flags|=2048)),a!==e&&a&&(t.child.flags|=8192),hr(t,t.updateQueue),lt(t),null);case 4:return he(),e===null&&cd(t.stateNode.containerInfo),lt(t),null;case 10:return Jn(t.type),lt(t),null;case 19:if(I(yt),i=t.memoizedState,i===null)return lt(t),null;if(r=(t.flags&128)!==0,c=i.rendering,c===null)if(r)Ls(i,!1);else{if(dt!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(c=er(e),c!==null){for(t.flags|=128,Ls(i,!1),e=c.updateQueue,t.updateQueue=e,hr(t,e),t.subtreeFlags=0,e=a,a=t.child;a!==null;)vp(a,e),a=a.sibling;return $(yt,yt.current&1|2),Qe&&Zn(t,i.treeForkCount),t.child}e=e.sibling}i.tail!==null&&rt()>br&&(t.flags|=128,r=!0,Ls(i,!1),t.lanes=4194304)}else{if(!r)if(e=er(c),e!==null){if(t.flags|=128,r=!0,e=e.updateQueue,t.updateQueue=e,hr(t,e),Ls(i,!0),i.tail===null&&i.tailMode==="hidden"&&!c.alternate&&!Qe)return lt(t),null}else 2*rt()-i.renderingStartTime>br&&a!==536870912&&(t.flags|=128,r=!0,Ls(i,!1),t.lanes=4194304);i.isBackwards?(c.sibling=t.child,t.child=c):(e=i.last,e!==null?e.sibling=c:t.child=c,i.last=c)}return i.tail!==null?(e=i.tail,i.rendering=e,i.tail=e.sibling,i.renderingStartTime=rt(),e.sibling=null,a=yt.current,$(yt,r?a&1|2:a&1),Qe&&Zn(t,i.treeForkCount),e):(lt(t),null);case 22:case 23:return ln(t),uu(),i=t.memoizedState!==null,e!==null?e.memoizedState!==null!==i&&(t.flags|=8192):i&&(t.flags|=8192),i?(a&536870912)!==0&&(t.flags&128)===0&&(lt(t),t.subtreeFlags&6&&(t.flags|=8192)):lt(t),a=t.updateQueue,a!==null&&hr(t,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),i=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(i=t.memoizedState.cachePool.pool),i!==a&&(t.flags|=2048),e!==null&&I(kl),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),Jn(bt),lt(t),null;case 25:return null;case 30:return null}throw Error(o(156,t.tag))}function M2(e,t){switch(Xc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Jn(bt),he(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return Ae(t),null;case 31:if(t.memoizedState!==null){if(ln(t),t.alternate===null)throw Error(o(340));_l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ln(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(o(340));_l()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return I(yt),null;case 4:return he(),null;case 10:return Jn(t.type),null;case 22:case 23:return ln(t),uu(),e!==null&&I(kl),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Jn(bt),null;case 25:return null;default:return null}}function Ym(e,t){switch(Xc(t),t.tag){case 3:Jn(bt),he();break;case 26:case 27:case 5:Ae(t);break;case 4:he();break;case 31:t.memoizedState!==null&&ln(t);break;case 13:ln(t);break;case 19:I(yt);break;case 10:Jn(t.type);break;case 22:case 23:ln(t),uu(),e!==null&&I(kl);break;case 24:Jn(bt)}}function Bs(e,t){try{var a=t.updateQueue,i=a!==null?a.lastEffect:null;if(i!==null){var r=i.next;a=r;do{if((a.tag&e)===e){i=void 0;var c=a.create,m=a.inst;i=c(),m.destroy=i}a=a.next}while(a!==r)}}catch(b){Pe(t,t.return,b)}}function za(e,t,a){try{var i=t.updateQueue,r=i!==null?i.lastEffect:null;if(r!==null){var c=r.next;i=c;do{if((i.tag&e)===e){var m=i.inst,b=m.destroy;if(b!==void 0){m.destroy=void 0,r=t;var C=a,K=b;try{K()}catch(le){Pe(r,C,le)}}}i=i.next}while(i!==c)}}catch(le){Pe(t,t.return,le)}}function $m(e){var t=e.updateQueue;if(t!==null){var a=e.stateNode;try{Lp(t,a)}catch(i){Pe(e,e.return,i)}}}function Fm(e,t,a){a.props=Al(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(i){Pe(e,t,i)}}function Hs(e,t){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var i=e.stateNode;break;case 30:i=e.stateNode;break;default:i=e.stateNode}typeof a=="function"?e.refCleanup=a(i):a.current=i}}catch(r){Pe(e,t,r)}}function Dn(e,t){var a=e.ref,i=e.refCleanup;if(a!==null)if(typeof i=="function")try{i()}catch(r){Pe(e,t,r)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(r){Pe(e,t,r)}else a.current=null}function Xm(e){var t=e.type,a=e.memoizedProps,i=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":a.autoFocus&&i.focus();break e;case"img":a.src?i.src=a.src:a.srcSet&&(i.srcset=a.srcSet)}}catch(r){Pe(e,e.return,r)}}function Iu(e,t,a){try{var i=e.stateNode;X2(i,e.type,a,t),i[Kt]=t}catch(r){Pe(e,e.return,r)}}function Zm(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&Ga(e.type)||e.tag===4}function Qu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Zm(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&Ga(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Ku(e,t,a){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(e,t):(t=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,t.appendChild(e),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=$n));else if(i!==4&&(i===27&&Ga(e.type)&&(a=e.stateNode,t=null),e=e.child,e!==null))for(Ku(e,t,a),e=e.sibling;e!==null;)Ku(e,t,a),e=e.sibling}function pr(e,t,a){var i=e.tag;if(i===5||i===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(i!==4&&(i===27&&Ga(e.type)&&(a=e.stateNode),e=e.child,e!==null))for(pr(e,t,a),e=e.sibling;e!==null;)pr(e,t,a),e=e.sibling}function Pm(e){var t=e.stateNode,a=e.memoizedProps;try{for(var i=e.type,r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Ot(t,i,a),t[Ct]=e,t[Kt]=a}catch(c){Pe(e,e.return,c)}}var aa=!1,_t=!1,Vu=!1,Jm=typeof WeakSet=="function"?WeakSet:Set,jt=null;function C2(e,t){if(e=e.containerInfo,fd=Dr,e=up(e),Bc(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var i=a.getSelection&&a.getSelection();if(i&&i.rangeCount!==0){a=i.anchorNode;var r=i.anchorOffset,c=i.focusNode;i=i.focusOffset;try{a.nodeType,c.nodeType}catch{a=null;break e}var m=0,b=-1,C=-1,K=0,le=0,oe=e,X=null;t:for(;;){for(var J;oe!==a||r!==0&&oe.nodeType!==3||(b=m+r),oe!==c||i!==0&&oe.nodeType!==3||(C=m+i),oe.nodeType===3&&(m+=oe.nodeValue.length),(J=oe.firstChild)!==null;)X=oe,oe=J;for(;;){if(oe===e)break t;if(X===a&&++K===r&&(b=m),X===c&&++le===i&&(C=m),(J=oe.nextSibling)!==null)break;oe=X,X=oe.parentNode}oe=J}a=b===-1||C===-1?null:{start:b,end:C}}else a=null}a=a||{start:0,end:0}}else a=null;for(hd={focusedElem:e,selectionRange:a},Dr=!1,jt=t;jt!==null;)if(t=jt,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,jt=e;else for(;jt!==null;){switch(t=jt,c=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(a=0;a<e.length;a++)r=e[a],r.ref.impl=r.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&c!==null){e=void 0,a=t,r=c.memoizedProps,c=c.memoizedState,i=a.stateNode;try{var _e=Al(a.type,r);e=i.getSnapshotBeforeUpdate(_e,c),i.__reactInternalSnapshotBeforeUpdate=e}catch(Ce){Pe(a,a.return,Ce)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,a=e.nodeType,a===9)yd(e);else if(a===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":yd(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(o(163))}if(e=t.sibling,e!==null){e.return=t.return,jt=e;break}jt=t.return}}function Wm(e,t,a){var i=a.flags;switch(a.tag){case 0:case 11:case 15:ia(e,a),i&4&&Bs(5,a);break;case 1:if(ia(e,a),i&4)if(e=a.stateNode,t===null)try{e.componentDidMount()}catch(m){Pe(a,a.return,m)}else{var r=Al(a.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(r,t,e.__reactInternalSnapshotBeforeUpdate)}catch(m){Pe(a,a.return,m)}}i&64&&$m(a),i&512&&Hs(a,a.return);break;case 3:if(ia(e,a),i&64&&(e=a.updateQueue,e!==null)){if(t=null,a.child!==null)switch(a.child.tag){case 27:case 5:t=a.child.stateNode;break;case 1:t=a.child.stateNode}try{Lp(e,t)}catch(m){Pe(a,a.return,m)}}break;case 27:t===null&&i&4&&Pm(a);case 26:case 5:ia(e,a),t===null&&i&4&&Xm(a),i&512&&Hs(a,a.return);break;case 12:ia(e,a);break;case 31:ia(e,a),i&4&&ny(e,a);break;case 13:ia(e,a),i&4&&ay(e,a),i&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=L2.bind(null,a),a_(e,a))));break;case 22:if(i=a.memoizedState!==null||aa,!i){t=t!==null&&t.memoizedState!==null||_t,r=aa;var c=_t;aa=i,(_t=t)&&!c?sa(e,a,(a.subtreeFlags&8772)!==0):ia(e,a),aa=r,_t=c}break;case 30:break;default:ia(e,a)}}function ey(e){var t=e.alternate;t!==null&&(e.alternate=null,ey(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&_c(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var st=null,Yt=!1;function la(e,t,a){for(a=a.child;a!==null;)ty(e,t,a),a=a.sibling}function ty(e,t,a){if(zt&&typeof zt.onCommitFiberUnmount=="function")try{zt.onCommitFiberUnmount(xa,a)}catch{}switch(a.tag){case 26:_t||Dn(a,t),la(e,t,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:_t||Dn(a,t);var i=st,r=Yt;Ga(a.type)&&(st=a.stateNode,Yt=!1),la(e,t,a),Fs(a.stateNode),st=i,Yt=r;break;case 5:_t||Dn(a,t);case 6:if(i=st,r=Yt,st=null,la(e,t,a),st=i,Yt=r,st!==null)if(Yt)try{(st.nodeType===9?st.body:st.nodeName==="HTML"?st.ownerDocument.body:st).removeChild(a.stateNode)}catch(c){Pe(a,t,c)}else try{st.removeChild(a.stateNode)}catch(c){Pe(a,t,c)}break;case 18:st!==null&&(Yt?(e=st,$y(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),Qi(e)):$y(st,a.stateNode));break;case 4:i=st,r=Yt,st=a.stateNode.containerInfo,Yt=!0,la(e,t,a),st=i,Yt=r;break;case 0:case 11:case 14:case 15:za(2,a,t),_t||za(4,a,t),la(e,t,a);break;case 1:_t||(Dn(a,t),i=a.stateNode,typeof i.componentWillUnmount=="function"&&Fm(a,t,i)),la(e,t,a);break;case 21:la(e,t,a);break;case 22:_t=(i=_t)||a.memoizedState!==null,la(e,t,a),_t=i;break;default:la(e,t,a)}}function ny(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Qi(e)}catch(a){Pe(t,t.return,a)}}}function ay(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Qi(e)}catch(a){Pe(t,t.return,a)}}function A2(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Jm),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Jm),t;default:throw Error(o(435,e.tag))}}function mr(e,t){var a=A2(e);t.forEach(function(i){if(!a.has(i)){a.add(i);var r=B2.bind(null,e,i);i.then(r,r)}})}function $t(e,t){var a=t.deletions;if(a!==null)for(var i=0;i<a.length;i++){var r=a[i],c=e,m=t,b=m;e:for(;b!==null;){switch(b.tag){case 27:if(Ga(b.type)){st=b.stateNode,Yt=!1;break e}break;case 5:st=b.stateNode,Yt=!1;break e;case 3:case 4:st=b.stateNode.containerInfo,Yt=!0;break e}b=b.return}if(st===null)throw Error(o(160));ty(c,m,r),st=null,Yt=!1,c=r.alternate,c!==null&&(c.return=null),r.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)ly(t,e),t=t.sibling}var Cn=null;function ly(e,t){var a=e.alternate,i=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:$t(t,e),Ft(e),i&4&&(za(3,e,e.return),Bs(3,e),za(5,e,e.return));break;case 1:$t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),i&64&&aa&&(e=e.updateQueue,e!==null&&(i=e.callbacks,i!==null&&(a=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=a===null?i:a.concat(i))));break;case 26:var r=Cn;if($t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),i&4){var c=a!==null?a.memoizedState:null;if(i=e.memoizedState,a===null)if(i===null)if(e.stateNode===null){e:{i=e.type,a=e.memoizedProps,r=r.ownerDocument||r;t:switch(i){case"title":c=r.getElementsByTagName("title")[0],(!c||c[fs]||c[Ct]||c.namespaceURI==="http://www.w3.org/2000/svg"||c.hasAttribute("itemprop"))&&(c=r.createElement(i),r.head.insertBefore(c,r.querySelector("head > title"))),Ot(c,i,a),c[Ct]=e,Et(c),i=c;break e;case"link":var m=lg("link","href",r).get(i+(a.href||""));if(m){for(var b=0;b<m.length;b++)if(c=m[b],c.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&c.getAttribute("rel")===(a.rel==null?null:a.rel)&&c.getAttribute("title")===(a.title==null?null:a.title)&&c.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){m.splice(b,1);break t}}c=r.createElement(i),Ot(c,i,a),r.head.appendChild(c);break;case"meta":if(m=lg("meta","content",r).get(i+(a.content||""))){for(b=0;b<m.length;b++)if(c=m[b],c.getAttribute("content")===(a.content==null?null:""+a.content)&&c.getAttribute("name")===(a.name==null?null:a.name)&&c.getAttribute("property")===(a.property==null?null:a.property)&&c.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&c.getAttribute("charset")===(a.charSet==null?null:a.charSet)){m.splice(b,1);break t}}c=r.createElement(i),Ot(c,i,a),r.head.appendChild(c);break;default:throw Error(o(468,i))}c[Ct]=e,Et(c),i=c}e.stateNode=i}else ig(r,e.type,e.stateNode);else e.stateNode=ag(r,i,e.memoizedProps);else c!==i?(c===null?a.stateNode!==null&&(a=a.stateNode,a.parentNode.removeChild(a)):c.count--,i===null?ig(r,e.type,e.stateNode):ag(r,i,e.memoizedProps)):i===null&&e.stateNode!==null&&Iu(e,e.memoizedProps,a.memoizedProps)}break;case 27:$t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),a!==null&&i&4&&Iu(e,e.memoizedProps,a.memoizedProps);break;case 5:if($t(t,e),Ft(e),i&512&&(_t||a===null||Dn(a,a.return)),e.flags&32){r=e.stateNode;try{fi(r,"")}catch(_e){Pe(e,e.return,_e)}}i&4&&e.stateNode!=null&&(r=e.memoizedProps,Iu(e,r,a!==null?a.memoizedProps:r)),i&1024&&(Vu=!0);break;case 6:if($t(t,e),Ft(e),i&4){if(e.stateNode===null)throw Error(o(162));i=e.memoizedProps,a=e.stateNode;try{a.nodeValue=i}catch(_e){Pe(e,e.return,_e)}}break;case 3:if(Tr=null,r=Cn,Cn=Ar(t.containerInfo),$t(t,e),Cn=r,Ft(e),i&4&&a!==null&&a.memoizedState.isDehydrated)try{Qi(t.containerInfo)}catch(_e){Pe(e,e.return,_e)}Vu&&(Vu=!1,iy(e));break;case 4:i=Cn,Cn=Ar(e.stateNode.containerInfo),$t(t,e),Ft(e),Cn=i;break;case 12:$t(t,e),Ft(e);break;case 31:$t(t,e),Ft(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 13:$t(t,e),Ft(e),e.child.flags&8192&&e.memoizedState!==null!=(a!==null&&a.memoizedState!==null)&&(gr=rt()),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 22:r=e.memoizedState!==null;var C=a!==null&&a.memoizedState!==null,K=aa,le=_t;if(aa=K||r,_t=le||C,$t(t,e),_t=le,aa=K,Ft(e),i&8192)e:for(t=e.stateNode,t._visibility=r?t._visibility&-2:t._visibility|1,r&&(a===null||C||aa||_t||Nl(e)),a=null,t=e;;){if(t.tag===5||t.tag===26){if(a===null){C=a=t;try{if(c=C.stateNode,r)m=c.style,typeof m.setProperty=="function"?m.setProperty("display","none","important"):m.display="none";else{b=C.stateNode;var oe=C.memoizedProps.style,X=oe!=null&&oe.hasOwnProperty("display")?oe.display:null;b.style.display=X==null||typeof X=="boolean"?"":(""+X).trim()}}catch(_e){Pe(C,C.return,_e)}}}else if(t.tag===6){if(a===null){C=t;try{C.stateNode.nodeValue=r?"":C.memoizedProps}catch(_e){Pe(C,C.return,_e)}}}else if(t.tag===18){if(a===null){C=t;try{var J=C.stateNode;r?Fy(J,!0):Fy(C.stateNode,!1)}catch(_e){Pe(C,C.return,_e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;a===t&&(a=null),t=t.return}a===t&&(a=null),t.sibling.return=t.return,t=t.sibling}i&4&&(i=e.updateQueue,i!==null&&(a=i.retryQueue,a!==null&&(i.retryQueue=null,mr(e,a))));break;case 19:$t(t,e),Ft(e),i&4&&(i=e.updateQueue,i!==null&&(e.updateQueue=null,mr(e,i)));break;case 30:break;case 21:break;default:$t(t,e),Ft(e)}}function Ft(e){var t=e.flags;if(t&2){try{for(var a,i=e.return;i!==null;){if(Zm(i)){a=i;break}i=i.return}if(a==null)throw Error(o(160));switch(a.tag){case 27:var r=a.stateNode,c=Qu(e);pr(e,c,r);break;case 5:var m=a.stateNode;a.flags&32&&(fi(m,""),a.flags&=-33);var b=Qu(e);pr(e,b,m);break;case 3:case 4:var C=a.stateNode.containerInfo,K=Qu(e);Ku(e,K,C);break;default:throw Error(o(161))}}catch(le){Pe(e,e.return,le)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function iy(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;iy(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function ia(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)Wm(e,t.alternate,t),t=t.sibling}function Nl(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:za(4,t,t.return),Nl(t);break;case 1:Dn(t,t.return);var a=t.stateNode;typeof a.componentWillUnmount=="function"&&Fm(t,t.return,a),Nl(t);break;case 27:Fs(t.stateNode);case 26:case 5:Dn(t,t.return),Nl(t);break;case 22:t.memoizedState===null&&Nl(t);break;case 30:Nl(t);break;default:Nl(t)}e=e.sibling}}function sa(e,t,a){for(a=a&&(t.subtreeFlags&8772)!==0,t=t.child;t!==null;){var i=t.alternate,r=e,c=t,m=c.flags;switch(c.tag){case 0:case 11:case 15:sa(r,c,a),Bs(4,c);break;case 1:if(sa(r,c,a),i=c,r=i.stateNode,typeof r.componentDidMount=="function")try{r.componentDidMount()}catch(K){Pe(i,i.return,K)}if(i=c,r=i.updateQueue,r!==null){var b=i.stateNode;try{var C=r.shared.hiddenCallbacks;if(C!==null)for(r.shared.hiddenCallbacks=null,r=0;r<C.length;r++)Up(C[r],b)}catch(K){Pe(i,i.return,K)}}a&&m&64&&$m(c),Hs(c,c.return);break;case 27:Pm(c);case 26:case 5:sa(r,c,a),a&&i===null&&m&4&&Xm(c),Hs(c,c.return);break;case 12:sa(r,c,a);break;case 31:sa(r,c,a),a&&m&4&&ny(r,c);break;case 13:sa(r,c,a),a&&m&4&&ay(r,c);break;case 22:c.memoizedState===null&&sa(r,c,a),Hs(c,c.return);break;case 30:break;default:sa(r,c,a)}t=t.sibling}}function Yu(e,t){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&Es(a))}function $u(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Es(e))}function An(e,t,a,i){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)sy(e,t,a,i),t=t.sibling}function sy(e,t,a,i){var r=t.flags;switch(t.tag){case 0:case 11:case 15:An(e,t,a,i),r&2048&&Bs(9,t);break;case 1:An(e,t,a,i);break;case 3:An(e,t,a,i),r&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&Es(e)));break;case 12:if(r&2048){An(e,t,a,i),e=t.stateNode;try{var c=t.memoizedProps,m=c.id,b=c.onPostCommit;typeof b=="function"&&b(m,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(C){Pe(t,t.return,C)}}else An(e,t,a,i);break;case 31:An(e,t,a,i);break;case 13:An(e,t,a,i);break;case 23:break;case 22:c=t.stateNode,m=t.alternate,t.memoizedState!==null?c._visibility&2?An(e,t,a,i):qs(e,t):c._visibility&2?An(e,t,a,i):(c._visibility|=2,Oi(e,t,a,i,(t.subtreeFlags&10256)!==0||!1)),r&2048&&Yu(m,t);break;case 24:An(e,t,a,i),r&2048&&$u(t.alternate,t);break;default:An(e,t,a,i)}}function Oi(e,t,a,i,r){for(r=r&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var c=e,m=t,b=a,C=i,K=m.flags;switch(m.tag){case 0:case 11:case 15:Oi(c,m,b,C,r),Bs(8,m);break;case 23:break;case 22:var le=m.stateNode;m.memoizedState!==null?le._visibility&2?Oi(c,m,b,C,r):qs(c,m):(le._visibility|=2,Oi(c,m,b,C,r)),r&&K&2048&&Yu(m.alternate,m);break;case 24:Oi(c,m,b,C,r),r&&K&2048&&$u(m.alternate,m);break;default:Oi(c,m,b,C,r)}t=t.sibling}}function qs(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var a=e,i=t,r=i.flags;switch(i.tag){case 22:qs(a,i),r&2048&&Yu(i.alternate,i);break;case 24:qs(a,i),r&2048&&$u(i.alternate,i);break;default:qs(a,i)}t=t.sibling}}var Gs=8192;function Ri(e,t,a){if(e.subtreeFlags&Gs)for(e=e.child;e!==null;)oy(e,t,a),e=e.sibling}function oy(e,t,a){switch(e.tag){case 26:Ri(e,t,a),e.flags&Gs&&e.memoizedState!==null&&m_(a,Cn,e.memoizedState,e.memoizedProps);break;case 5:Ri(e,t,a);break;case 3:case 4:var i=Cn;Cn=Ar(e.stateNode.containerInfo),Ri(e,t,a),Cn=i;break;case 22:e.memoizedState===null&&(i=e.alternate,i!==null&&i.memoizedState!==null?(i=Gs,Gs=16777216,Ri(e,t,a),Gs=i):Ri(e,t,a));break;default:Ri(e,t,a)}}function ry(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Is(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var i=t[a];jt=i,uy(i,e)}ry(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)cy(e),e=e.sibling}function cy(e){switch(e.tag){case 0:case 11:case 15:Is(e),e.flags&2048&&za(9,e,e.return);break;case 3:Is(e);break;case 12:Is(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,yr(e)):Is(e);break;default:Is(e)}}function yr(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var i=t[a];jt=i,uy(i,e)}ry(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:za(8,t,t.return),yr(t);break;case 22:a=t.stateNode,a._visibility&2&&(a._visibility&=-3,yr(t));break;default:yr(t)}e=e.sibling}}function uy(e,t){for(;jt!==null;){var a=jt;switch(a.tag){case 0:case 11:case 15:za(8,a,t);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var i=a.memoizedState.cachePool.pool;i!=null&&i.refCount++}break;case 24:Es(a.memoizedState.cache)}if(i=a.child,i!==null)i.return=a,jt=i;else e:for(a=e;jt!==null;){i=jt;var r=i.sibling,c=i.return;if(ey(i),i===a){jt=null;break e}if(r!==null){r.return=c,jt=r;break e}jt=c}}}var N2={getCacheForType:function(e){var t=Nt(bt),a=t.data.get(e);return a===void 0&&(a=e(),t.data.set(e,a)),a},cacheSignal:function(){return Nt(bt).controller.signal}},T2=typeof WeakMap=="function"?WeakMap:Map,Fe=0,tt=null,He=null,Ge=0,Ze=0,sn=null,Da=!1,zi=!1,Fu=!1,oa=0,dt=0,Ua=0,Tl=0,Xu=0,on=0,Di=0,Qs=null,Xt=null,Zu=!1,gr=0,dy=0,br=1/0,vr=null,La=null,wt=0,Ba=null,Ui=null,ra=0,Pu=0,Ju=null,fy=null,Ks=0,Wu=null;function rn(){return(Fe&2)!==0&&Ge!==0?Ge&-Ge:w.T!==null?id():Ch()}function hy(){if(on===0)if((Ge&536870912)===0||Qe){var e=pt;pt<<=1,(pt&3932160)===0&&(pt=262144),on=e}else on=536870912;return e=an.current,e!==null&&(e.flags|=32),on}function Zt(e,t,a){(e===tt&&(Ze===2||Ze===9)||e.cancelPendingCommit!==null)&&(Li(e,0),Ha(e,Ge,on,!1)),_a(e,a),((Fe&2)===0||e!==tt)&&(e===tt&&((Fe&2)===0&&(Tl|=a),dt===4&&Ha(e,Ge,on,!1)),Un(e))}function py(e,t,a){if((Fe&6)!==0)throw Error(o(327));var i=!a&&(t&127)===0&&(t&e.expiredLanes)===0||Ut(e,t),r=i?z2(e,t):td(e,t,!0),c=i;do{if(r===0){zi&&!i&&Ha(e,t,0,!1);break}else{if(a=e.current.alternate,c&&!O2(a)){r=td(e,t,!1),c=!1;continue}if(r===2){if(c=t,e.errorRecoveryDisabledLanes&c)var m=0;else m=e.pendingLanes&-536870913,m=m!==0?m:m&536870912?536870912:0;if(m!==0){t=m;e:{var b=e;r=Qs;var C=b.current.memoizedState.isDehydrated;if(C&&(Li(b,m).flags|=256),m=td(b,m,!1),m!==2){if(Fu&&!C){b.errorRecoveryDisabledLanes|=c,Tl|=c,r=4;break e}c=Xt,Xt=r,c!==null&&(Xt===null?Xt=c:Xt.push.apply(Xt,c))}r=m}if(c=!1,r!==2)continue}}if(r===1){Li(e,0),Ha(e,t,0,!0);break}e:{switch(i=e,c=r,c){case 0:case 1:throw Error(o(345));case 4:if((t&4194048)!==t)break;case 6:Ha(i,t,on,!Da);break e;case 2:Xt=null;break;case 3:case 5:break;default:throw Error(o(329))}if((t&62914560)===t&&(r=gr+300-rt(),10<r)){if(Ha(i,t,on,!Da),Dt(i,0,!0)!==0)break e;ra=t,i.timeoutHandle=Vy(my.bind(null,i,a,Xt,vr,Zu,t,on,Tl,Di,Da,c,"Throttled",-0,0),r);break e}my(i,a,Xt,vr,Zu,t,on,Tl,Di,Da,c,null,-0,0)}}break}while(!0);Un(e)}function my(e,t,a,i,r,c,m,b,C,K,le,oe,X,J){if(e.timeoutHandle=-1,oe=t.subtreeFlags,oe&8192||(oe&16785408)===16785408){oe={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:$n},oy(t,c,oe);var _e=(c&62914560)===c?gr-rt():(c&4194048)===c?dy-rt():0;if(_e=y_(oe,_e),_e!==null){ra=c,e.cancelPendingCommit=_e(Sy.bind(null,e,t,c,a,i,r,m,b,C,le,oe,null,X,J)),Ha(e,c,m,!K);return}}Sy(e,t,c,a,i,r,m,b,C)}function O2(e){for(var t=e;;){var a=t.tag;if((a===0||a===11||a===15)&&t.flags&16384&&(a=t.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var i=0;i<a.length;i++){var r=a[i],c=r.getSnapshot;r=r.value;try{if(!tn(c(),r))return!1}catch{return!1}}if(a=t.child,t.subtreeFlags&16384&&a!==null)a.return=t,t=a;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ha(e,t,a,i){t&=~Xu,t&=~Tl,e.suspendedLanes|=t,e.pingedLanes&=~t,i&&(e.warmLanes|=t),i=e.expirationTimes;for(var r=t;0<r;){var c=31-pe(r),m=1<<c;i[c]=-1,r&=~m}a!==0&&Ao(e,a,t)}function xr(){return(Fe&6)===0?(Vs(0),!1):!0}function ed(){if(He!==null){if(Ze===0)var e=He.return;else e=He,Pn=wl=null,yu(e),Mi=null,Ms=0,e=He;for(;e!==null;)Ym(e.alternate,e),e=e.return;He=null}}function Li(e,t){var a=e.timeoutHandle;a!==-1&&(e.timeoutHandle=-1,J2(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),ra=0,ed(),tt=e,He=a=Xn(e.current,null),Ge=t,Ze=0,sn=null,Da=!1,zi=Ut(e,t),Fu=!1,Di=on=Xu=Tl=Ua=dt=0,Xt=Qs=null,Zu=!1,(t&8)!==0&&(t|=t&32);var i=e.entangledLanes;if(i!==0)for(e=e.entanglements,i&=t;0<i;){var r=31-pe(i),c=1<<r;t|=e[r],i&=~c}return oa=t,Go(),a}function yy(e,t){Re=null,w.H=Ds,t===ji||t===Xo?(t=Op(),Ze=3):t===lu?(t=Op(),Ze=4):Ze=t===Ou?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,sn=t,He===null&&(dt=1,cr(e,gn(t,e.current)))}function gy(){var e=an.current;return e===null?!0:(Ge&4194048)===Ge?_n===null:(Ge&62914560)===Ge||(Ge&536870912)!==0?e===_n:!1}function by(){var e=w.H;return w.H=Ds,e===null?Ds:e}function vy(){var e=w.A;return w.A=N2,e}function _r(){dt=4,Da||(Ge&4194048)!==Ge&&an.current!==null||(zi=!0),(Ua&134217727)===0&&(Tl&134217727)===0||tt===null||Ha(tt,Ge,on,!1)}function td(e,t,a){var i=Fe;Fe|=2;var r=by(),c=vy();(tt!==e||Ge!==t)&&(vr=null,Li(e,t)),t=!1;var m=dt;e:do try{if(Ze!==0&&He!==null){var b=He,C=sn;switch(Ze){case 8:ed(),m=6;break e;case 3:case 2:case 9:case 6:an.current===null&&(t=!0);var K=Ze;if(Ze=0,sn=null,Bi(e,b,C,K),a&&zi){m=0;break e}break;default:K=Ze,Ze=0,sn=null,Bi(e,b,C,K)}}R2(),m=dt;break}catch(le){yy(e,le)}while(!0);return t&&e.shellSuspendCounter++,Pn=wl=null,Fe=i,w.H=r,w.A=c,He===null&&(tt=null,Ge=0,Go()),m}function R2(){for(;He!==null;)xy(He)}function z2(e,t){var a=Fe;Fe|=2;var i=by(),r=vy();tt!==e||Ge!==t?(vr=null,br=rt()+500,Li(e,t)):zi=Ut(e,t);e:do try{if(Ze!==0&&He!==null){t=He;var c=sn;t:switch(Ze){case 1:Ze=0,sn=null,Bi(e,t,c,1);break;case 2:case 9:if(Np(c)){Ze=0,sn=null,_y(t);break}t=function(){Ze!==2&&Ze!==9||tt!==e||(Ze=7),Un(e)},c.then(t,t);break e;case 3:Ze=7;break e;case 4:Ze=5;break e;case 7:Np(c)?(Ze=0,sn=null,_y(t)):(Ze=0,sn=null,Bi(e,t,c,7));break;case 5:var m=null;switch(He.tag){case 26:m=He.memoizedState;case 5:case 27:var b=He;if(m?sg(m):b.stateNode.complete){Ze=0,sn=null;var C=b.sibling;if(C!==null)He=C;else{var K=b.return;K!==null?(He=K,wr(K)):He=null}break t}}Ze=0,sn=null,Bi(e,t,c,5);break;case 6:Ze=0,sn=null,Bi(e,t,c,6);break;case 8:ed(),dt=6;break e;default:throw Error(o(462))}}D2();break}catch(le){yy(e,le)}while(!0);return Pn=wl=null,w.H=i,w.A=r,Fe=a,He!==null?0:(tt=null,Ge=0,Go(),dt)}function D2(){for(;He!==null&&!dl();)xy(He)}function xy(e){var t=Km(e.alternate,e,oa);e.memoizedProps=e.pendingProps,t===null?wr(e):He=t}function _y(e){var t=e,a=t.alternate;switch(t.tag){case 15:case 0:t=Bm(a,t,t.pendingProps,t.type,void 0,Ge);break;case 11:t=Bm(a,t,t.pendingProps,t.type.render,t.ref,Ge);break;case 5:yu(t);default:Ym(a,t),t=He=vp(t,oa),t=Km(a,t,oa)}e.memoizedProps=e.pendingProps,t===null?wr(e):He=t}function Bi(e,t,a,i){Pn=wl=null,yu(t),Mi=null,Ms=0;var r=t.return;try{if(S2(e,r,t,a,Ge)){dt=1,cr(e,gn(a,e.current)),He=null;return}}catch(c){if(r!==null)throw He=r,c;dt=1,cr(e,gn(a,e.current)),He=null;return}t.flags&32768?(Qe||i===1?e=!0:zi||(Ge&536870912)!==0?e=!1:(Da=e=!0,(i===2||i===9||i===3||i===6)&&(i=an.current,i!==null&&i.tag===13&&(i.flags|=16384))),wy(t,e)):wr(t)}function wr(e){var t=e;do{if((t.flags&32768)!==0){wy(t,Da);return}e=t.return;var a=j2(t.alternate,t,oa);if(a!==null){He=a;return}if(t=t.sibling,t!==null){He=t;return}He=t=e}while(t!==null);dt===0&&(dt=5)}function wy(e,t){do{var a=M2(e.alternate,e);if(a!==null){a.flags&=32767,He=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!t&&(e=e.sibling,e!==null)){He=e;return}He=e=a}while(e!==null);dt=6,He=null}function Sy(e,t,a,i,r,c,m,b,C){e.cancelPendingCommit=null;do Sr();while(wt!==0);if((Fe&6)!==0)throw Error(o(327));if(t!==null){if(t===e.current)throw Error(o(177));if(c=t.lanes|t.childLanes,c|=Qc,wa(e,a,c,m,b,C),e===tt&&(He=tt=null,Ge=0),Ui=t,Ba=e,ra=a,Pu=c,Ju=r,fy=i,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,H2(fl,function(){return Cy(),null})):(e.callbackNode=null,e.callbackPriority=0),i=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||i){i=w.T,w.T=null,r=Z.p,Z.p=2,m=Fe,Fe|=4;try{C2(e,t,a)}finally{Fe=m,Z.p=r,w.T=i}}wt=1,ky(),Ey(),jy()}}function ky(){if(wt===1){wt=0;var e=Ba,t=Ui,a=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||a){a=w.T,w.T=null;var i=Z.p;Z.p=2;var r=Fe;Fe|=4;try{ly(t,e);var c=hd,m=up(e.containerInfo),b=c.focusedElem,C=c.selectionRange;if(m!==b&&b&&b.ownerDocument&&cp(b.ownerDocument.documentElement,b)){if(C!==null&&Bc(b)){var K=C.start,le=C.end;if(le===void 0&&(le=K),"selectionStart"in b)b.selectionStart=K,b.selectionEnd=Math.min(le,b.value.length);else{var oe=b.ownerDocument||document,X=oe&&oe.defaultView||window;if(X.getSelection){var J=X.getSelection(),_e=b.textContent.length,Ce=Math.min(C.start,_e),et=C.end===void 0?Ce:Math.min(C.end,_e);!J.extend&&Ce>et&&(m=et,et=Ce,Ce=m);var H=rp(b,Ce),R=rp(b,et);if(H&&R&&(J.rangeCount!==1||J.anchorNode!==H.node||J.anchorOffset!==H.offset||J.focusNode!==R.node||J.focusOffset!==R.offset)){var Q=oe.createRange();Q.setStart(H.node,H.offset),J.removeAllRanges(),Ce>et?(J.addRange(Q),J.extend(R.node,R.offset)):(Q.setEnd(R.node,R.offset),J.addRange(Q))}}}}for(oe=[],J=b;J=J.parentNode;)J.nodeType===1&&oe.push({element:J,left:J.scrollLeft,top:J.scrollTop});for(typeof b.focus=="function"&&b.focus(),b=0;b<oe.length;b++){var se=oe[b];se.element.scrollLeft=se.left,se.element.scrollTop=se.top}}Dr=!!fd,hd=fd=null}finally{Fe=r,Z.p=i,w.T=a}}e.current=t,wt=2}}function Ey(){if(wt===2){wt=0;var e=Ba,t=Ui,a=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||a){a=w.T,w.T=null;var i=Z.p;Z.p=2;var r=Fe;Fe|=4;try{Wm(e,t.alternate,t)}finally{Fe=r,Z.p=i,w.T=a}}wt=3}}function jy(){if(wt===4||wt===3){wt=0,On();var e=Ba,t=Ui,a=ra,i=fy;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?wt=5:(wt=0,Ui=Ba=null,My(e,e.pendingLanes));var r=e.pendingLanes;if(r===0&&(La=null),vc(a),t=t.stateNode,zt&&typeof zt.onCommitFiberRoot=="function")try{zt.onCommitFiberRoot(xa,t,void 0,(t.current.flags&128)===128)}catch{}if(i!==null){t=w.T,r=Z.p,Z.p=2,w.T=null;try{for(var c=e.onRecoverableError,m=0;m<i.length;m++){var b=i[m];c(b.value,{componentStack:b.stack})}}finally{w.T=t,Z.p=r}}(ra&3)!==0&&Sr(),Un(e),r=e.pendingLanes,(a&261930)!==0&&(r&42)!==0?e===Wu?Ks++:(Ks=0,Wu=e):Ks=0,Vs(0)}}function My(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,Es(t)))}function Sr(){return ky(),Ey(),jy(),Cy()}function Cy(){if(wt!==5)return!1;var e=Ba,t=Pu;Pu=0;var a=vc(ra),i=w.T,r=Z.p;try{Z.p=32>a?32:a,w.T=null,a=Ju,Ju=null;var c=Ba,m=ra;if(wt=0,Ui=Ba=null,ra=0,(Fe&6)!==0)throw Error(o(331));var b=Fe;if(Fe|=4,cy(c.current),sy(c,c.current,m,a),Fe=b,Vs(0,!1),zt&&typeof zt.onPostCommitFiberRoot=="function")try{zt.onPostCommitFiberRoot(xa,c)}catch{}return!0}finally{Z.p=r,w.T=i,My(e,t)}}function Ay(e,t,a){t=gn(a,t),t=Tu(e.stateNode,t,2),e=Ta(e,t,2),e!==null&&(_a(e,2),Un(e))}function Pe(e,t,a){if(e.tag===3)Ay(e,e,a);else for(;t!==null;){if(t.tag===3){Ay(t,e,a);break}else if(t.tag===1){var i=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof i.componentDidCatch=="function"&&(La===null||!La.has(i))){e=gn(a,e),a=Nm(2),i=Ta(t,a,2),i!==null&&(Tm(a,i,t,e),_a(i,2),Un(i));break}}t=t.return}}function nd(e,t,a){var i=e.pingCache;if(i===null){i=e.pingCache=new T2;var r=new Set;i.set(t,r)}else r=i.get(t),r===void 0&&(r=new Set,i.set(t,r));r.has(a)||(Fu=!0,r.add(a),e=U2.bind(null,e,t,a),t.then(e,e))}function U2(e,t,a){var i=e.pingCache;i!==null&&i.delete(t),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,tt===e&&(Ge&a)===a&&(dt===4||dt===3&&(Ge&62914560)===Ge&&300>rt()-gr?(Fe&2)===0&&Li(e,0):Xu|=a,Di===Ge&&(Di=0)),Un(e)}function Ny(e,t){t===0&&(t=jn()),e=vl(e,t),e!==null&&(_a(e,t),Un(e))}function L2(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),Ny(e,a)}function B2(e,t){var a=0;switch(e.tag){case 31:case 13:var i=e.stateNode,r=e.memoizedState;r!==null&&(a=r.retryLane);break;case 19:i=e.stateNode;break;case 22:i=e.stateNode._retryCache;break;default:throw Error(o(314))}i!==null&&i.delete(t),Ny(e,a)}function H2(e,t){return ni(e,t)}var kr=null,Hi=null,ad=!1,Er=!1,ld=!1,qa=0;function Un(e){e!==Hi&&e.next===null&&(Hi===null?kr=Hi=e:Hi=Hi.next=e),Er=!0,ad||(ad=!0,G2())}function Vs(e,t){if(!ld&&Er){ld=!0;do for(var a=!1,i=kr;i!==null;){if(e!==0){var r=i.pendingLanes;if(r===0)var c=0;else{var m=i.suspendedLanes,b=i.pingedLanes;c=(1<<31-pe(42|e)+1)-1,c&=r&~(m&~b),c=c&201326741?c&201326741|1:c?c|2:0}c!==0&&(a=!0,zy(i,c))}else c=Ge,c=Dt(i,i===tt?c:0,i.cancelPendingCommit!==null||i.timeoutHandle!==-1),(c&3)===0||Ut(i,c)||(a=!0,zy(i,c));i=i.next}while(a);ld=!1}}function q2(){Ty()}function Ty(){Er=ad=!1;var e=0;qa!==0&&P2()&&(e=qa);for(var t=rt(),a=null,i=kr;i!==null;){var r=i.next,c=Oy(i,t);c===0?(i.next=null,a===null?kr=r:a.next=r,r===null&&(Hi=a)):(a=i,(e!==0||(c&3)!==0)&&(Er=!0)),i=r}wt!==0&&wt!==5||Vs(e),qa!==0&&(qa=0)}function Oy(e,t){for(var a=e.suspendedLanes,i=e.pingedLanes,r=e.expirationTimes,c=e.pendingLanes&-62914561;0<c;){var m=31-pe(c),b=1<<m,C=r[m];C===-1?((b&a)===0||(b&i)!==0)&&(r[m]=Lt(b,t)):C<=t&&(e.expiredLanes|=b),c&=~b}if(t=tt,a=Ge,a=Dt(e,e===t?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),i=e.callbackNode,a===0||e===t&&(Ze===2||Ze===9)||e.cancelPendingCommit!==null)return i!==null&&i!==null&&ai(i),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||Ut(e,a)){if(t=a&-a,t===e.callbackPriority)return t;switch(i!==null&&ai(i),vc(a)){case 2:case 8:a=li;break;case 32:a=fl;break;case 268435456:a=it;break;default:a=fl}return i=Ry.bind(null,e),a=ni(a,i),e.callbackPriority=t,e.callbackNode=a,t}return i!==null&&i!==null&&ai(i),e.callbackPriority=2,e.callbackNode=null,2}function Ry(e,t){if(wt!==0&&wt!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(Sr()&&e.callbackNode!==a)return null;var i=Ge;return i=Dt(e,e===tt?i:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),i===0?null:(py(e,i,t),Oy(e,rt()),e.callbackNode!=null&&e.callbackNode===a?Ry.bind(null,e):null)}function zy(e,t){if(Sr())return null;py(e,t,!0)}function G2(){W2(function(){(Fe&6)!==0?ni(ds,q2):Ty()})}function id(){if(qa===0){var e=ki;e===0&&(e=Te,Te<<=1,(Te&261888)===0&&(Te=256)),qa=e}return qa}function Dy(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Ro(""+e)}function Uy(e,t){var a=t.ownerDocument.createElement("input");return a.name=t.name,a.value=t.value,e.id&&a.setAttribute("form",e.id),t.parentNode.insertBefore(a,t),e=new FormData(e),a.parentNode.removeChild(a),e}function I2(e,t,a,i,r){if(t==="submit"&&a&&a.stateNode===r){var c=Dy((r[Kt]||null).action),m=i.submitter;m&&(t=(t=m[Kt]||null)?Dy(t.formAction):m.getAttribute("formAction"),t!==null&&(c=t,m=null));var b=new Lo("action","action",null,i,r);e.push({event:b,listeners:[{instance:null,listener:function(){if(i.defaultPrevented){if(qa!==0){var C=m?Uy(r,m):new FormData(r);Eu(a,{pending:!0,data:C,method:r.method,action:c},null,C)}}else typeof c=="function"&&(b.preventDefault(),C=m?Uy(r,m):new FormData(r),Eu(a,{pending:!0,data:C,method:r.method,action:c},c,C))},currentTarget:r}]})}}for(var sd=0;sd<Ic.length;sd++){var od=Ic[sd],Q2=od.toLowerCase(),K2=od[0].toUpperCase()+od.slice(1);Mn(Q2,"on"+K2)}Mn(hp,"onAnimationEnd"),Mn(pp,"onAnimationIteration"),Mn(mp,"onAnimationStart"),Mn("dblclick","onDoubleClick"),Mn("focusin","onFocus"),Mn("focusout","onBlur"),Mn(s2,"onTransitionRun"),Mn(o2,"onTransitionStart"),Mn(r2,"onTransitionCancel"),Mn(yp,"onTransitionEnd"),ui("onMouseEnter",["mouseout","mouseover"]),ui("onMouseLeave",["mouseout","mouseover"]),ui("onPointerEnter",["pointerout","pointerover"]),ui("onPointerLeave",["pointerout","pointerover"]),ml("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),ml("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),ml("onBeforeInput",["compositionend","keypress","textInput","paste"]),ml("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),ml("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),ml("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ys="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),V2=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Ys));function Ly(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var i=e[a],r=i.event;i=i.listeners;e:{var c=void 0;if(t)for(var m=i.length-1;0<=m;m--){var b=i[m],C=b.instance,K=b.currentTarget;if(b=b.listener,C!==c&&r.isPropagationStopped())break e;c=b,r.currentTarget=K;try{c(r)}catch(le){qo(le)}r.currentTarget=null,c=C}else for(m=0;m<i.length;m++){if(b=i[m],C=b.instance,K=b.currentTarget,b=b.listener,C!==c&&r.isPropagationStopped())break e;c=b,r.currentTarget=K;try{c(r)}catch(le){qo(le)}r.currentTarget=null,c=C}}}}function qe(e,t){var a=t[xc];a===void 0&&(a=t[xc]=new Set);var i=e+"__bubble";a.has(i)||(By(t,e,2,!1),a.add(i))}function rd(e,t,a){var i=0;t&&(i|=4),By(a,e,i,t)}var jr="_reactListening"+Math.random().toString(36).slice(2);function cd(e){if(!e[jr]){e[jr]=!0,Th.forEach(function(a){a!=="selectionchange"&&(V2.has(a)||rd(a,!1,e),rd(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[jr]||(t[jr]=!0,rd("selectionchange",!1,t))}}function By(e,t,a,i){switch(hg(t)){case 2:var r=v_;break;case 8:r=x_;break;default:r=kd}a=r.bind(null,t,a,e),r=void 0,!Ac||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(r=!0),i?r!==void 0?e.addEventListener(t,a,{capture:!0,passive:r}):e.addEventListener(t,a,!0):r!==void 0?e.addEventListener(t,a,{passive:r}):e.addEventListener(t,a,!1)}function ud(e,t,a,i,r){var c=i;if((t&1)===0&&(t&2)===0&&i!==null)e:for(;;){if(i===null)return;var m=i.tag;if(m===3||m===4){var b=i.stateNode.containerInfo;if(b===r)break;if(m===4)for(m=i.return;m!==null;){var C=m.tag;if((C===3||C===4)&&m.stateNode.containerInfo===r)return;m=m.return}for(;b!==null;){if(m=oi(b),m===null)return;if(C=m.tag,C===5||C===6||C===26||C===27){i=c=m;continue e}b=b.parentNode}}i=i.return}Qh(function(){var K=c,le=Mc(a),oe=[];e:{var X=gp.get(e);if(X!==void 0){var J=Lo,_e=e;switch(e){case"keypress":if(Do(a)===0)break e;case"keydown":case"keyup":J=Bx;break;case"focusin":_e="focus",J=Rc;break;case"focusout":_e="blur",J=Rc;break;case"beforeblur":case"afterblur":J=Rc;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":J=Yh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":J=jx;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":J=Gx;break;case hp:case pp:case mp:J=Ax;break;case yp:J=Qx;break;case"scroll":case"scrollend":J=kx;break;case"wheel":J=Vx;break;case"copy":case"cut":case"paste":J=Tx;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":J=Fh;break;case"toggle":case"beforetoggle":J=$x}var Ce=(t&4)!==0,et=!Ce&&(e==="scroll"||e==="scrollend"),H=Ce?X!==null?X+"Capture":null:X;Ce=[];for(var R=K,Q;R!==null;){var se=R;if(Q=se.stateNode,se=se.tag,se!==5&&se!==26&&se!==27||Q===null||H===null||(se=ps(R,H),se!=null&&Ce.push($s(R,se,Q))),et)break;R=R.return}0<Ce.length&&(X=new J(X,_e,null,a,le),oe.push({event:X,listeners:Ce}))}}if((t&7)===0){e:{if(X=e==="mouseover"||e==="pointerover",J=e==="mouseout"||e==="pointerout",X&&a!==jc&&(_e=a.relatedTarget||a.fromElement)&&(oi(_e)||_e[si]))break e;if((J||X)&&(X=le.window===le?le:(X=le.ownerDocument)?X.defaultView||X.parentWindow:window,J?(_e=a.relatedTarget||a.toElement,J=K,_e=_e?oi(_e):null,_e!==null&&(et=d(_e),Ce=_e.tag,_e!==et||Ce!==5&&Ce!==27&&Ce!==6)&&(_e=null)):(J=null,_e=K),J!==_e)){if(Ce=Yh,se="onMouseLeave",H="onMouseEnter",R="mouse",(e==="pointerout"||e==="pointerover")&&(Ce=Fh,se="onPointerLeave",H="onPointerEnter",R="pointer"),et=J==null?X:hs(J),Q=_e==null?X:hs(_e),X=new Ce(se,R+"leave",J,a,le),X.target=et,X.relatedTarget=Q,se=null,oi(le)===K&&(Ce=new Ce(H,R+"enter",_e,a,le),Ce.target=Q,Ce.relatedTarget=et,se=Ce),et=se,J&&_e)t:{for(Ce=Y2,H=J,R=_e,Q=0,se=H;se;se=Ce(se))Q++;se=0;for(var Ee=R;Ee;Ee=Ce(Ee))se++;for(;0<Q-se;)H=Ce(H),Q--;for(;0<se-Q;)R=Ce(R),se--;for(;Q--;){if(H===R||R!==null&&H===R.alternate){Ce=H;break t}H=Ce(H),R=Ce(R)}Ce=null}else Ce=null;J!==null&&Hy(oe,X,J,Ce,!1),_e!==null&&et!==null&&Hy(oe,et,_e,Ce,!0)}}e:{if(X=K?hs(K):window,J=X.nodeName&&X.nodeName.toLowerCase(),J==="select"||J==="input"&&X.type==="file")var Ye=np;else if(ep(X))if(ap)Ye=a2;else{Ye=t2;var we=e2}else J=X.nodeName,!J||J.toLowerCase()!=="input"||X.type!=="checkbox"&&X.type!=="radio"?K&&Ec(K.elementType)&&(Ye=np):Ye=n2;if(Ye&&(Ye=Ye(e,K))){tp(oe,Ye,a,le);break e}we&&we(e,X,K),e==="focusout"&&K&&X.type==="number"&&K.memoizedProps.value!=null&&kc(X,"number",X.value)}switch(we=K?hs(K):window,e){case"focusin":(ep(we)||we.contentEditable==="true")&&(yi=we,Hc=K,ws=null);break;case"focusout":ws=Hc=yi=null;break;case"mousedown":qc=!0;break;case"contextmenu":case"mouseup":case"dragend":qc=!1,dp(oe,a,le);break;case"selectionchange":if(i2)break;case"keydown":case"keyup":dp(oe,a,le)}var De;if(Dc)e:{switch(e){case"compositionstart":var Ie="onCompositionStart";break e;case"compositionend":Ie="onCompositionEnd";break e;case"compositionupdate":Ie="onCompositionUpdate";break e}Ie=void 0}else mi?Jh(e,a)&&(Ie="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(Ie="onCompositionStart");Ie&&(Xh&&a.locale!=="ko"&&(mi||Ie!=="onCompositionStart"?Ie==="onCompositionEnd"&&mi&&(De=Kh()):(ka=le,Nc="value"in ka?ka.value:ka.textContent,mi=!0)),we=Mr(K,Ie),0<we.length&&(Ie=new $h(Ie,e,null,a,le),oe.push({event:Ie,listeners:we}),De?Ie.data=De:(De=Wh(a),De!==null&&(Ie.data=De)))),(De=Xx?Zx(e,a):Px(e,a))&&(Ie=Mr(K,"onBeforeInput"),0<Ie.length&&(we=new $h("onBeforeInput","beforeinput",null,a,le),oe.push({event:we,listeners:Ie}),we.data=De)),I2(oe,e,K,a,le)}Ly(oe,t)})}function $s(e,t,a){return{instance:e,listener:t,currentTarget:a}}function Mr(e,t){for(var a=t+"Capture",i=[];e!==null;){var r=e,c=r.stateNode;if(r=r.tag,r!==5&&r!==26&&r!==27||c===null||(r=ps(e,a),r!=null&&i.unshift($s(e,r,c)),r=ps(e,t),r!=null&&i.push($s(e,r,c))),e.tag===3)return i;e=e.return}return[]}function Y2(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function Hy(e,t,a,i,r){for(var c=t._reactName,m=[];a!==null&&a!==i;){var b=a,C=b.alternate,K=b.stateNode;if(b=b.tag,C!==null&&C===i)break;b!==5&&b!==26&&b!==27||K===null||(C=K,r?(K=ps(a,c),K!=null&&m.unshift($s(a,K,C))):r||(K=ps(a,c),K!=null&&m.push($s(a,K,C)))),a=a.return}m.length!==0&&e.push({event:t,listeners:m})}var $2=/\r\n?/g,F2=/\u0000|\uFFFD/g;function qy(e){return(typeof e=="string"?e:""+e).replace($2,`
49
- `).replace(F2,"")}function Gy(e,t){return t=qy(t),qy(e)===t}function We(e,t,a,i,r,c){switch(a){case"children":typeof i=="string"?t==="body"||t==="textarea"&&i===""||fi(e,i):(typeof i=="number"||typeof i=="bigint")&&t!=="body"&&fi(e,""+i);break;case"className":To(e,"class",i);break;case"tabIndex":To(e,"tabindex",i);break;case"dir":case"role":case"viewBox":case"width":case"height":To(e,a,i);break;case"style":Gh(e,i,c);break;case"data":if(t!=="object"){To(e,"data",i);break}case"src":case"href":if(i===""&&(t!=="a"||a!=="href")){e.removeAttribute(a);break}if(i==null||typeof i=="function"||typeof i=="symbol"||typeof i=="boolean"){e.removeAttribute(a);break}i=Ro(""+i),e.setAttribute(a,i);break;case"action":case"formAction":if(typeof i=="function"){e.setAttribute(a,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof c=="function"&&(a==="formAction"?(t!=="input"&&We(e,t,"name",r.name,r,null),We(e,t,"formEncType",r.formEncType,r,null),We(e,t,"formMethod",r.formMethod,r,null),We(e,t,"formTarget",r.formTarget,r,null)):(We(e,t,"encType",r.encType,r,null),We(e,t,"method",r.method,r,null),We(e,t,"target",r.target,r,null)));if(i==null||typeof i=="symbol"||typeof i=="boolean"){e.removeAttribute(a);break}i=Ro(""+i),e.setAttribute(a,i);break;case"onClick":i!=null&&(e.onclick=$n);break;case"onScroll":i!=null&&qe("scroll",e);break;case"onScrollEnd":i!=null&&qe("scrollend",e);break;case"dangerouslySetInnerHTML":if(i!=null){if(typeof i!="object"||!("__html"in i))throw Error(o(61));if(a=i.__html,a!=null){if(r.children!=null)throw Error(o(60));e.innerHTML=a}}break;case"multiple":e.multiple=i&&typeof i!="function"&&typeof i!="symbol";break;case"muted":e.muted=i&&typeof i!="function"&&typeof i!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(i==null||typeof i=="function"||typeof i=="boolean"||typeof i=="symbol"){e.removeAttribute("xlink:href");break}a=Ro(""+i),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":i!=null&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,""+i):e.removeAttribute(a);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":i&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,""):e.removeAttribute(a);break;case"capture":case"download":i===!0?e.setAttribute(a,""):i!==!1&&i!=null&&typeof i!="function"&&typeof i!="symbol"?e.setAttribute(a,i):e.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":i!=null&&typeof i!="function"&&typeof i!="symbol"&&!isNaN(i)&&1<=i?e.setAttribute(a,i):e.removeAttribute(a);break;case"rowSpan":case"start":i==null||typeof i=="function"||typeof i=="symbol"||isNaN(i)?e.removeAttribute(a):e.setAttribute(a,i);break;case"popover":qe("beforetoggle",e),qe("toggle",e),No(e,"popover",i);break;case"xlinkActuate":Yn(e,"http://www.w3.org/1999/xlink","xlink:actuate",i);break;case"xlinkArcrole":Yn(e,"http://www.w3.org/1999/xlink","xlink:arcrole",i);break;case"xlinkRole":Yn(e,"http://www.w3.org/1999/xlink","xlink:role",i);break;case"xlinkShow":Yn(e,"http://www.w3.org/1999/xlink","xlink:show",i);break;case"xlinkTitle":Yn(e,"http://www.w3.org/1999/xlink","xlink:title",i);break;case"xlinkType":Yn(e,"http://www.w3.org/1999/xlink","xlink:type",i);break;case"xmlBase":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:base",i);break;case"xmlLang":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:lang",i);break;case"xmlSpace":Yn(e,"http://www.w3.org/XML/1998/namespace","xml:space",i);break;case"is":No(e,"is",i);break;case"innerText":case"textContent":break;default:(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")&&(a=wx.get(a)||a,No(e,a,i))}}function dd(e,t,a,i,r,c){switch(a){case"style":Gh(e,i,c);break;case"dangerouslySetInnerHTML":if(i!=null){if(typeof i!="object"||!("__html"in i))throw Error(o(61));if(a=i.__html,a!=null){if(r.children!=null)throw Error(o(60));e.innerHTML=a}}break;case"children":typeof i=="string"?fi(e,i):(typeof i=="number"||typeof i=="bigint")&&fi(e,""+i);break;case"onScroll":i!=null&&qe("scroll",e);break;case"onScrollEnd":i!=null&&qe("scrollend",e);break;case"onClick":i!=null&&(e.onclick=$n);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Oh.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(r=a.endsWith("Capture"),t=a.slice(2,r?a.length-7:void 0),c=e[Kt]||null,c=c!=null?c[a]:null,typeof c=="function"&&e.removeEventListener(t,c,r),typeof i=="function")){typeof c!="function"&&c!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(t,i,r);break e}a in e?e[a]=i:i===!0?e.setAttribute(a,""):No(e,a,i)}}}function Ot(e,t,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":qe("error",e),qe("load",e);var i=!1,r=!1,c;for(c in a)if(a.hasOwnProperty(c)){var m=a[c];if(m!=null)switch(c){case"src":i=!0;break;case"srcSet":r=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:We(e,t,c,m,a,null)}}r&&We(e,t,"srcSet",a.srcSet,a,null),i&&We(e,t,"src",a.src,a,null);return;case"input":qe("invalid",e);var b=c=m=r=null,C=null,K=null;for(i in a)if(a.hasOwnProperty(i)){var le=a[i];if(le!=null)switch(i){case"name":r=le;break;case"type":m=le;break;case"checked":C=le;break;case"defaultChecked":K=le;break;case"value":c=le;break;case"defaultValue":b=le;break;case"children":case"dangerouslySetInnerHTML":if(le!=null)throw Error(o(137,t));break;default:We(e,t,i,le,a,null)}}Lh(e,c,b,C,K,m,r,!1);return;case"select":qe("invalid",e),i=m=c=null;for(r in a)if(a.hasOwnProperty(r)&&(b=a[r],b!=null))switch(r){case"value":c=b;break;case"defaultValue":m=b;break;case"multiple":i=b;default:We(e,t,r,b,a,null)}t=c,a=m,e.multiple=!!i,t!=null?di(e,!!i,t,!1):a!=null&&di(e,!!i,a,!0);return;case"textarea":qe("invalid",e),c=r=i=null;for(m in a)if(a.hasOwnProperty(m)&&(b=a[m],b!=null))switch(m){case"value":i=b;break;case"defaultValue":r=b;break;case"children":c=b;break;case"dangerouslySetInnerHTML":if(b!=null)throw Error(o(91));break;default:We(e,t,m,b,a,null)}Hh(e,i,r,c);return;case"option":for(C in a)if(a.hasOwnProperty(C)&&(i=a[C],i!=null))switch(C){case"selected":e.selected=i&&typeof i!="function"&&typeof i!="symbol";break;default:We(e,t,C,i,a,null)}return;case"dialog":qe("beforetoggle",e),qe("toggle",e),qe("cancel",e),qe("close",e);break;case"iframe":case"object":qe("load",e);break;case"video":case"audio":for(i=0;i<Ys.length;i++)qe(Ys[i],e);break;case"image":qe("error",e),qe("load",e);break;case"details":qe("toggle",e);break;case"embed":case"source":case"link":qe("error",e),qe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(K in a)if(a.hasOwnProperty(K)&&(i=a[K],i!=null))switch(K){case"children":case"dangerouslySetInnerHTML":throw Error(o(137,t));default:We(e,t,K,i,a,null)}return;default:if(Ec(t)){for(le in a)a.hasOwnProperty(le)&&(i=a[le],i!==void 0&&dd(e,t,le,i,a,void 0));return}}for(b in a)a.hasOwnProperty(b)&&(i=a[b],i!=null&&We(e,t,b,i,a,null))}function X2(e,t,a,i){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var r=null,c=null,m=null,b=null,C=null,K=null,le=null;for(J in a){var oe=a[J];if(a.hasOwnProperty(J)&&oe!=null)switch(J){case"checked":break;case"value":break;case"defaultValue":C=oe;default:i.hasOwnProperty(J)||We(e,t,J,null,i,oe)}}for(var X in i){var J=i[X];if(oe=a[X],i.hasOwnProperty(X)&&(J!=null||oe!=null))switch(X){case"type":c=J;break;case"name":r=J;break;case"checked":K=J;break;case"defaultChecked":le=J;break;case"value":m=J;break;case"defaultValue":b=J;break;case"children":case"dangerouslySetInnerHTML":if(J!=null)throw Error(o(137,t));break;default:J!==oe&&We(e,t,X,J,i,oe)}}Sc(e,m,b,C,K,le,c,r);return;case"select":J=m=b=X=null;for(c in a)if(C=a[c],a.hasOwnProperty(c)&&C!=null)switch(c){case"value":break;case"multiple":J=C;default:i.hasOwnProperty(c)||We(e,t,c,null,i,C)}for(r in i)if(c=i[r],C=a[r],i.hasOwnProperty(r)&&(c!=null||C!=null))switch(r){case"value":X=c;break;case"defaultValue":b=c;break;case"multiple":m=c;default:c!==C&&We(e,t,r,c,i,C)}t=b,a=m,i=J,X!=null?di(e,!!a,X,!1):!!i!=!!a&&(t!=null?di(e,!!a,t,!0):di(e,!!a,a?[]:"",!1));return;case"textarea":J=X=null;for(b in a)if(r=a[b],a.hasOwnProperty(b)&&r!=null&&!i.hasOwnProperty(b))switch(b){case"value":break;case"children":break;default:We(e,t,b,null,i,r)}for(m in i)if(r=i[m],c=a[m],i.hasOwnProperty(m)&&(r!=null||c!=null))switch(m){case"value":X=r;break;case"defaultValue":J=r;break;case"children":break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(o(91));break;default:r!==c&&We(e,t,m,r,i,c)}Bh(e,X,J);return;case"option":for(var _e in a)if(X=a[_e],a.hasOwnProperty(_e)&&X!=null&&!i.hasOwnProperty(_e))switch(_e){case"selected":e.selected=!1;break;default:We(e,t,_e,null,i,X)}for(C in i)if(X=i[C],J=a[C],i.hasOwnProperty(C)&&X!==J&&(X!=null||J!=null))switch(C){case"selected":e.selected=X&&typeof X!="function"&&typeof X!="symbol";break;default:We(e,t,C,X,i,J)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var Ce in a)X=a[Ce],a.hasOwnProperty(Ce)&&X!=null&&!i.hasOwnProperty(Ce)&&We(e,t,Ce,null,i,X);for(K in i)if(X=i[K],J=a[K],i.hasOwnProperty(K)&&X!==J&&(X!=null||J!=null))switch(K){case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(o(137,t));break;default:We(e,t,K,X,i,J)}return;default:if(Ec(t)){for(var et in a)X=a[et],a.hasOwnProperty(et)&&X!==void 0&&!i.hasOwnProperty(et)&&dd(e,t,et,void 0,i,X);for(le in i)X=i[le],J=a[le],!i.hasOwnProperty(le)||X===J||X===void 0&&J===void 0||dd(e,t,le,X,i,J);return}}for(var H in a)X=a[H],a.hasOwnProperty(H)&&X!=null&&!i.hasOwnProperty(H)&&We(e,t,H,null,i,X);for(oe in i)X=i[oe],J=a[oe],!i.hasOwnProperty(oe)||X===J||X==null&&J==null||We(e,t,oe,X,i,J)}function Iy(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Z2(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,a=performance.getEntriesByType("resource"),i=0;i<a.length;i++){var r=a[i],c=r.transferSize,m=r.initiatorType,b=r.duration;if(c&&b&&Iy(m)){for(m=0,b=r.responseEnd,i+=1;i<a.length;i++){var C=a[i],K=C.startTime;if(K>b)break;var le=C.transferSize,oe=C.initiatorType;le&&Iy(oe)&&(C=C.responseEnd,m+=le*(C<b?1:(b-K)/(C-K)))}if(--i,t+=8*(c+m)/(r.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var fd=null,hd=null;function Cr(e){return e.nodeType===9?e:e.ownerDocument}function Qy(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Ky(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function pd(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var md=null;function P2(){var e=window.event;return e&&e.type==="popstate"?e===md?!1:(md=e,!0):(md=null,!1)}var Vy=typeof setTimeout=="function"?setTimeout:void 0,J2=typeof clearTimeout=="function"?clearTimeout:void 0,Yy=typeof Promise=="function"?Promise:void 0,W2=typeof queueMicrotask=="function"?queueMicrotask:typeof Yy<"u"?function(e){return Yy.resolve(null).then(e).catch(e_)}:Vy;function e_(e){setTimeout(function(){throw e})}function Ga(e){return e==="head"}function $y(e,t){var a=t,i=0;do{var r=a.nextSibling;if(e.removeChild(a),r&&r.nodeType===8)if(a=r.data,a==="/$"||a==="/&"){if(i===0){e.removeChild(r),Qi(t);return}i--}else if(a==="$"||a==="$?"||a==="$~"||a==="$!"||a==="&")i++;else if(a==="html")Fs(e.ownerDocument.documentElement);else if(a==="head"){a=e.ownerDocument.head,Fs(a);for(var c=a.firstChild;c;){var m=c.nextSibling,b=c.nodeName;c[fs]||b==="SCRIPT"||b==="STYLE"||b==="LINK"&&c.rel.toLowerCase()==="stylesheet"||a.removeChild(c),c=m}}else a==="body"&&Fs(e.ownerDocument.body);a=r}while(a);Qi(t)}function Fy(e,t){var a=e;e=0;do{var i=a.nextSibling;if(a.nodeType===1?t?(a._stashedDisplay=a.style.display,a.style.display="none"):(a.style.display=a._stashedDisplay||"",a.getAttribute("style")===""&&a.removeAttribute("style")):a.nodeType===3&&(t?(a._stashedText=a.nodeValue,a.nodeValue=""):a.nodeValue=a._stashedText||""),i&&i.nodeType===8)if(a=i.data,a==="/$"){if(e===0)break;e--}else a!=="$"&&a!=="$?"&&a!=="$~"&&a!=="$!"||e++;a=i}while(a)}function yd(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var a=t;switch(t=t.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":yd(a),_c(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function t_(e,t,a,i){for(;e.nodeType===1;){var r=a;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!i&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(i){if(!e[fs])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(c=e.getAttribute("rel"),c==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(c!==r.rel||e.getAttribute("href")!==(r.href==null||r.href===""?null:r.href)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin)||e.getAttribute("title")!==(r.title==null?null:r.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(c=e.getAttribute("src"),(c!==(r.src==null?null:r.src)||e.getAttribute("type")!==(r.type==null?null:r.type)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin))&&c&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var c=r.name==null?null:""+r.name;if(r.type==="hidden"&&e.getAttribute("name")===c)return e}else return e;if(e=wn(e.nextSibling),e===null)break}return null}function n_(e,t,a){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=wn(e.nextSibling),e===null))return null;return e}function Xy(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=wn(e.nextSibling),e===null))return null;return e}function gd(e){return e.data==="$?"||e.data==="$~"}function bd(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function a_(e,t){var a=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||a.readyState!=="loading")t();else{var i=function(){t(),a.removeEventListener("DOMContentLoaded",i)};a.addEventListener("DOMContentLoaded",i),e._reactRetry=i}}function wn(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var vd=null;function Zy(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"||a==="/&"){if(t===0)return wn(e.nextSibling);t--}else a!=="$"&&a!=="$!"&&a!=="$?"&&a!=="$~"&&a!=="&"||t++}e=e.nextSibling}return null}function Py(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"){if(t===0)return e;t--}else a!=="/$"&&a!=="/&"||t++}e=e.previousSibling}return null}function Jy(e,t,a){switch(t=Cr(a),e){case"html":if(e=t.documentElement,!e)throw Error(o(452));return e;case"head":if(e=t.head,!e)throw Error(o(453));return e;case"body":if(e=t.body,!e)throw Error(o(454));return e;default:throw Error(o(451))}}function Fs(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);_c(e)}var Sn=new Map,Wy=new Set;function Ar(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var ca=Z.d;Z.d={f:l_,r:i_,D:s_,C:o_,L:r_,m:c_,X:d_,S:u_,M:f_};function l_(){var e=ca.f(),t=xr();return e||t}function i_(e){var t=ri(e);t!==null&&t.tag===5&&t.type==="form"?ym(t):ca.r(e)}var qi=typeof document>"u"?null:document;function eg(e,t,a){var i=qi;if(i&&typeof t=="string"&&t){var r=mn(t);r='link[rel="'+e+'"][href="'+r+'"]',typeof a=="string"&&(r+='[crossorigin="'+a+'"]'),Wy.has(r)||(Wy.add(r),e={rel:e,crossOrigin:a,href:t},i.querySelector(r)===null&&(t=i.createElement("link"),Ot(t,"link",e),Et(t),i.head.appendChild(t)))}}function s_(e){ca.D(e),eg("dns-prefetch",e,null)}function o_(e,t){ca.C(e,t),eg("preconnect",e,t)}function r_(e,t,a){ca.L(e,t,a);var i=qi;if(i&&e&&t){var r='link[rel="preload"][as="'+mn(t)+'"]';t==="image"&&a&&a.imageSrcSet?(r+='[imagesrcset="'+mn(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(r+='[imagesizes="'+mn(a.imageSizes)+'"]')):r+='[href="'+mn(e)+'"]';var c=r;switch(t){case"style":c=Gi(e);break;case"script":c=Ii(e)}Sn.has(c)||(e=v({rel:"preload",href:t==="image"&&a&&a.imageSrcSet?void 0:e,as:t},a),Sn.set(c,e),i.querySelector(r)!==null||t==="style"&&i.querySelector(Xs(c))||t==="script"&&i.querySelector(Zs(c))||(t=i.createElement("link"),Ot(t,"link",e),Et(t),i.head.appendChild(t)))}}function c_(e,t){ca.m(e,t);var a=qi;if(a&&e){var i=t&&typeof t.as=="string"?t.as:"script",r='link[rel="modulepreload"][as="'+mn(i)+'"][href="'+mn(e)+'"]',c=r;switch(i){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":c=Ii(e)}if(!Sn.has(c)&&(e=v({rel:"modulepreload",href:e},t),Sn.set(c,e),a.querySelector(r)===null)){switch(i){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Zs(c)))return}i=a.createElement("link"),Ot(i,"link",e),Et(i),a.head.appendChild(i)}}}function u_(e,t,a){ca.S(e,t,a);var i=qi;if(i&&e){var r=ci(i).hoistableStyles,c=Gi(e);t=t||"default";var m=r.get(c);if(!m){var b={loading:0,preload:null};if(m=i.querySelector(Xs(c)))b.loading=5;else{e=v({rel:"stylesheet",href:e,"data-precedence":t},a),(a=Sn.get(c))&&xd(e,a);var C=m=i.createElement("link");Et(C),Ot(C,"link",e),C._p=new Promise(function(K,le){C.onload=K,C.onerror=le}),C.addEventListener("load",function(){b.loading|=1}),C.addEventListener("error",function(){b.loading|=2}),b.loading|=4,Nr(m,t,i)}m={type:"stylesheet",instance:m,count:1,state:b},r.set(c,m)}}}function d_(e,t){ca.X(e,t);var a=qi;if(a&&e){var i=ci(a).hoistableScripts,r=Ii(e),c=i.get(r);c||(c=a.querySelector(Zs(r)),c||(e=v({src:e,async:!0},t),(t=Sn.get(r))&&_d(e,t),c=a.createElement("script"),Et(c),Ot(c,"link",e),a.head.appendChild(c)),c={type:"script",instance:c,count:1,state:null},i.set(r,c))}}function f_(e,t){ca.M(e,t);var a=qi;if(a&&e){var i=ci(a).hoistableScripts,r=Ii(e),c=i.get(r);c||(c=a.querySelector(Zs(r)),c||(e=v({src:e,async:!0,type:"module"},t),(t=Sn.get(r))&&_d(e,t),c=a.createElement("script"),Et(c),Ot(c,"link",e),a.head.appendChild(c)),c={type:"script",instance:c,count:1,state:null},i.set(r,c))}}function tg(e,t,a,i){var r=(r=q.current)?Ar(r):null;if(!r)throw Error(o(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(t=Gi(a.href),a=ci(r).hoistableStyles,i=a.get(t),i||(i={type:"style",instance:null,count:0,state:null},a.set(t,i)),i):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=Gi(a.href);var c=ci(r).hoistableStyles,m=c.get(e);if(m||(r=r.ownerDocument||r,m={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},c.set(e,m),(c=r.querySelector(Xs(e)))&&!c._p&&(m.instance=c,m.state.loading=5),Sn.has(e)||(a={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},Sn.set(e,a),c||h_(r,e,a,m.state))),t&&i===null)throw Error(o(528,""));return m}if(t&&i!==null)throw Error(o(529,""));return null;case"script":return t=a.async,a=a.src,typeof a=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(t=Ii(a),a=ci(r).hoistableScripts,i=a.get(t),i||(i={type:"script",instance:null,count:0,state:null},a.set(t,i)),i):{type:"void",instance:null,count:0,state:null};default:throw Error(o(444,e))}}function Gi(e){return'href="'+mn(e)+'"'}function Xs(e){return'link[rel="stylesheet"]['+e+"]"}function ng(e){return v({},e,{"data-precedence":e.precedence,precedence:null})}function h_(e,t,a,i){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?i.loading=1:(t=e.createElement("link"),i.preload=t,t.addEventListener("load",function(){return i.loading|=1}),t.addEventListener("error",function(){return i.loading|=2}),Ot(t,"link",a),Et(t),e.head.appendChild(t))}function Ii(e){return'[src="'+mn(e)+'"]'}function Zs(e){return"script[async]"+e}function ag(e,t,a){if(t.count++,t.instance===null)switch(t.type){case"style":var i=e.querySelector('style[data-href~="'+mn(a.href)+'"]');if(i)return t.instance=i,Et(i),i;var r=v({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return i=(e.ownerDocument||e).createElement("style"),Et(i),Ot(i,"style",r),Nr(i,a.precedence,e),t.instance=i;case"stylesheet":r=Gi(a.href);var c=e.querySelector(Xs(r));if(c)return t.state.loading|=4,t.instance=c,Et(c),c;i=ng(a),(r=Sn.get(r))&&xd(i,r),c=(e.ownerDocument||e).createElement("link"),Et(c);var m=c;return m._p=new Promise(function(b,C){m.onload=b,m.onerror=C}),Ot(c,"link",i),t.state.loading|=4,Nr(c,a.precedence,e),t.instance=c;case"script":return c=Ii(a.src),(r=e.querySelector(Zs(c)))?(t.instance=r,Et(r),r):(i=a,(r=Sn.get(c))&&(i=v({},a),_d(i,r)),e=e.ownerDocument||e,r=e.createElement("script"),Et(r),Ot(r,"link",i),e.head.appendChild(r),t.instance=r);case"void":return null;default:throw Error(o(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(i=t.instance,t.state.loading|=4,Nr(i,a.precedence,e));return t.instance}function Nr(e,t,a){for(var i=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),r=i.length?i[i.length-1]:null,c=r,m=0;m<i.length;m++){var b=i[m];if(b.dataset.precedence===t)c=b;else if(c!==r)break}c?c.parentNode.insertBefore(e,c.nextSibling):(t=a.nodeType===9?a.head:a,t.insertBefore(e,t.firstChild))}function xd(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function _d(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var Tr=null;function lg(e,t,a){if(Tr===null){var i=new Map,r=Tr=new Map;r.set(a,i)}else r=Tr,i=r.get(a),i||(i=new Map,r.set(a,i));if(i.has(e))return i;for(i.set(e,null),a=a.getElementsByTagName(e),r=0;r<a.length;r++){var c=a[r];if(!(c[fs]||c[Ct]||e==="link"&&c.getAttribute("rel")==="stylesheet")&&c.namespaceURI!=="http://www.w3.org/2000/svg"){var m=c.getAttribute(t)||"";m=e+m;var b=i.get(m);b?b.push(c):i.set(m,[c])}}return i}function ig(e,t,a){e=e.ownerDocument||e,e.head.insertBefore(a,t==="title"?e.querySelector("head > title"):null)}function p_(e,t,a){if(a===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function sg(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function m_(e,t,a,i){if(a.type==="stylesheet"&&(typeof i.media!="string"||matchMedia(i.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var r=Gi(i.href),c=t.querySelector(Xs(r));if(c){t=c._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=Or.bind(e),t.then(e,e)),a.state.loading|=4,a.instance=c,Et(c);return}c=t.ownerDocument||t,i=ng(i),(r=Sn.get(r))&&xd(i,r),c=c.createElement("link"),Et(c);var m=c;m._p=new Promise(function(b,C){m.onload=b,m.onerror=C}),Ot(c,"link",i),a.instance=c}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(a,t),(t=a.state.preload)&&(a.state.loading&3)===0&&(e.count++,a=Or.bind(e),t.addEventListener("load",a),t.addEventListener("error",a))}}var wd=0;function y_(e,t){return e.stylesheets&&e.count===0&&zr(e,e.stylesheets),0<e.count||0<e.imgCount?function(a){var i=setTimeout(function(){if(e.stylesheets&&zr(e,e.stylesheets),e.unsuspend){var c=e.unsuspend;e.unsuspend=null,c()}},6e4+t);0<e.imgBytes&&wd===0&&(wd=62500*Z2());var r=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&zr(e,e.stylesheets),e.unsuspend)){var c=e.unsuspend;e.unsuspend=null,c()}},(e.imgBytes>wd?50:800)+t);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(i),clearTimeout(r)}}:null}function Or(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)zr(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var Rr=null;function zr(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Rr=new Map,t.forEach(g_,e),Rr=null,Or.call(e))}function g_(e,t){if(!(t.state.loading&4)){var a=Rr.get(e);if(a)var i=a.get(null);else{a=new Map,Rr.set(e,a);for(var r=e.querySelectorAll("link[data-precedence],style[data-precedence]"),c=0;c<r.length;c++){var m=r[c];(m.nodeName==="LINK"||m.getAttribute("media")!=="not all")&&(a.set(m.dataset.precedence,m),i=m)}i&&a.set(null,i)}r=t.instance,m=r.getAttribute("data-precedence"),c=a.get(m)||i,c===i&&a.set(null,r),a.set(m,r),this.count++,i=Or.bind(this),r.addEventListener("load",i),r.addEventListener("error",i),c?c.parentNode.insertBefore(r,c.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(r,e.firstChild)),t.state.loading|=4}}var Ps={$$typeof:D,Provider:null,Consumer:null,_currentValue:ue,_currentValue2:ue,_threadCount:0};function b_(e,t,a,i,r,c,m,b,C){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=pl(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=pl(0),this.hiddenUpdates=pl(null),this.identifierPrefix=i,this.onUncaughtError=r,this.onCaughtError=c,this.onRecoverableError=m,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=C,this.incompleteTransitions=new Map}function og(e,t,a,i,r,c,m,b,C,K,le,oe){return e=new b_(e,t,a,m,C,K,le,oe,b),t=1,c===!0&&(t|=24),c=nn(3,null,null,t),e.current=c,c.stateNode=e,t=tu(),t.refCount++,e.pooledCache=t,t.refCount++,c.memoizedState={element:i,isDehydrated:a,cache:t},iu(c),e}function rg(e){return e?(e=vi,e):vi}function cg(e,t,a,i,r,c){r=rg(r),i.context===null?i.context=r:i.pendingContext=r,i=Na(t),i.payload={element:a},c=c===void 0?null:c,c!==null&&(i.callback=c),a=Ta(e,i,t),a!==null&&(Zt(a,e,t),As(a,e,t))}function ug(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function Sd(e,t){ug(e,t),(e=e.alternate)&&ug(e,t)}function dg(e){if(e.tag===13||e.tag===31){var t=vl(e,67108864);t!==null&&Zt(t,e,67108864),Sd(e,67108864)}}function fg(e){if(e.tag===13||e.tag===31){var t=rn();t=bc(t);var a=vl(e,t);a!==null&&Zt(a,e,t),Sd(e,t)}}var Dr=!0;function v_(e,t,a,i){var r=w.T;w.T=null;var c=Z.p;try{Z.p=2,kd(e,t,a,i)}finally{Z.p=c,w.T=r}}function x_(e,t,a,i){var r=w.T;w.T=null;var c=Z.p;try{Z.p=8,kd(e,t,a,i)}finally{Z.p=c,w.T=r}}function kd(e,t,a,i){if(Dr){var r=Ed(i);if(r===null)ud(e,t,i,Ur,a),pg(e,i);else if(w_(r,e,t,a,i))i.stopPropagation();else if(pg(e,i),t&4&&-1<__.indexOf(e)){for(;r!==null;){var c=ri(r);if(c!==null)switch(c.tag){case 3:if(c=c.stateNode,c.current.memoizedState.isDehydrated){var m=ct(c.pendingLanes);if(m!==0){var b=c;for(b.pendingLanes|=2,b.entangledLanes|=2;m;){var C=1<<31-pe(m);b.entanglements[1]|=C,m&=~C}Un(c),(Fe&6)===0&&(br=rt()+500,Vs(0))}}break;case 31:case 13:b=vl(c,2),b!==null&&Zt(b,c,2),xr(),Sd(c,2)}if(c=Ed(i),c===null&&ud(e,t,i,Ur,a),c===r)break;r=c}r!==null&&i.stopPropagation()}else ud(e,t,i,null,a)}}function Ed(e){return e=Mc(e),jd(e)}var Ur=null;function jd(e){if(Ur=null,e=oi(e),e!==null){var t=d(e);if(t===null)e=null;else{var a=t.tag;if(a===13){if(e=h(t),e!==null)return e;e=null}else if(a===31){if(e=p(t),e!==null)return e;e=null}else if(a===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ur=e,null}function hg(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Mo()){case ds:return 2;case li:return 8;case fl:case ii:return 32;case it:return 268435456;default:return 32}default:return 32}}var Md=!1,Ia=null,Qa=null,Ka=null,Js=new Map,Ws=new Map,Va=[],__="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function pg(e,t){switch(e){case"focusin":case"focusout":Ia=null;break;case"dragenter":case"dragleave":Qa=null;break;case"mouseover":case"mouseout":Ka=null;break;case"pointerover":case"pointerout":Js.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ws.delete(t.pointerId)}}function eo(e,t,a,i,r,c){return e===null||e.nativeEvent!==c?(e={blockedOn:t,domEventName:a,eventSystemFlags:i,nativeEvent:c,targetContainers:[r]},t!==null&&(t=ri(t),t!==null&&dg(t)),e):(e.eventSystemFlags|=i,t=e.targetContainers,r!==null&&t.indexOf(r)===-1&&t.push(r),e)}function w_(e,t,a,i,r){switch(t){case"focusin":return Ia=eo(Ia,e,t,a,i,r),!0;case"dragenter":return Qa=eo(Qa,e,t,a,i,r),!0;case"mouseover":return Ka=eo(Ka,e,t,a,i,r),!0;case"pointerover":var c=r.pointerId;return Js.set(c,eo(Js.get(c)||null,e,t,a,i,r)),!0;case"gotpointercapture":return c=r.pointerId,Ws.set(c,eo(Ws.get(c)||null,e,t,a,i,r)),!0}return!1}function mg(e){var t=oi(e.target);if(t!==null){var a=d(t);if(a!==null){if(t=a.tag,t===13){if(t=h(a),t!==null){e.blockedOn=t,Ah(e.priority,function(){fg(a)});return}}else if(t===31){if(t=p(a),t!==null){e.blockedOn=t,Ah(e.priority,function(){fg(a)});return}}else if(t===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Lr(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=Ed(e.nativeEvent);if(a===null){a=e.nativeEvent;var i=new a.constructor(a.type,a);jc=i,a.target.dispatchEvent(i),jc=null}else return t=ri(a),t!==null&&dg(t),e.blockedOn=a,!1;t.shift()}return!0}function yg(e,t,a){Lr(e)&&a.delete(t)}function S_(){Md=!1,Ia!==null&&Lr(Ia)&&(Ia=null),Qa!==null&&Lr(Qa)&&(Qa=null),Ka!==null&&Lr(Ka)&&(Ka=null),Js.forEach(yg),Ws.forEach(yg)}function Br(e,t){e.blockedOn===t&&(e.blockedOn=null,Md||(Md=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,S_)))}var Hr=null;function gg(e){Hr!==e&&(Hr=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Hr===e&&(Hr=null);for(var t=0;t<e.length;t+=3){var a=e[t],i=e[t+1],r=e[t+2];if(typeof i!="function"){if(jd(i||a)===null)continue;break}var c=ri(a);c!==null&&(e.splice(t,3),t-=3,Eu(c,{pending:!0,data:r,method:a.method,action:i},i,r))}}))}function Qi(e){function t(C){return Br(C,e)}Ia!==null&&Br(Ia,e),Qa!==null&&Br(Qa,e),Ka!==null&&Br(Ka,e),Js.forEach(t),Ws.forEach(t);for(var a=0;a<Va.length;a++){var i=Va[a];i.blockedOn===e&&(i.blockedOn=null)}for(;0<Va.length&&(a=Va[0],a.blockedOn===null);)mg(a),a.blockedOn===null&&Va.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(i=0;i<a.length;i+=3){var r=a[i],c=a[i+1],m=r[Kt]||null;if(typeof c=="function")m||gg(a);else if(m){var b=null;if(c&&c.hasAttribute("formAction")){if(r=c,m=c[Kt]||null)b=m.formAction;else if(jd(r)!==null)continue}else b=m.action;typeof b=="function"?a[i+1]=b:(a.splice(i,3),i-=3),gg(a)}}}function bg(){function e(c){c.canIntercept&&c.info==="react-transition"&&c.intercept({handler:function(){return new Promise(function(m){return r=m})},focusReset:"manual",scroll:"manual"})}function t(){r!==null&&(r(),r=null),i||setTimeout(a,20)}function a(){if(!i&&!navigation.transition){var c=navigation.currentEntry;c&&c.url!=null&&navigation.navigate(c.url,{state:c.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var i=!1,r=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(a,100),function(){i=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),r!==null&&(r(),r=null)}}}function Cd(e){this._internalRoot=e}qr.prototype.render=Cd.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(o(409));var a=t.current,i=rn();cg(a,i,e,t,null,null)},qr.prototype.unmount=Cd.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;cg(e.current,2,null,e,null,null),xr(),t[si]=null}};function qr(e){this._internalRoot=e}qr.prototype.unstable_scheduleHydration=function(e){if(e){var t=Ch();e={blockedOn:null,target:e,priority:t};for(var a=0;a<Va.length&&t!==0&&t<Va[a].priority;a++);Va.splice(a,0,e),a===0&&mg(e)}};var vg=l.version;if(vg!=="19.2.6")throw Error(o(527,vg,"19.2.6"));Z.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(o(188)):(e=Object.keys(e).join(","),Error(o(268,e)));return e=g(t),e=e!==null?x(e):null,e=e===null?null:e.stateNode,e};var k_={bundleType:0,version:"19.2.6",rendererPackageName:"react-dom",currentDispatcherRef:w,reconcilerVersion:"19.2.6"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Gr=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Gr.isDisabled&&Gr.supportsFiber)try{xa=Gr.inject(k_),zt=Gr}catch{}}return no.createRoot=function(e,t){if(!u(e))throw Error(o(299));var a=!1,i="",r=jm,c=Mm,m=Cm;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(i=t.identifierPrefix),t.onUncaughtError!==void 0&&(r=t.onUncaughtError),t.onCaughtError!==void 0&&(c=t.onCaughtError),t.onRecoverableError!==void 0&&(m=t.onRecoverableError)),t=og(e,1,!1,null,null,a,i,null,r,c,m,bg),e[si]=t.current,cd(e),new Cd(t)},no.hydrateRoot=function(e,t,a){if(!u(e))throw Error(o(299));var i=!1,r="",c=jm,m=Mm,b=Cm,C=null;return a!=null&&(a.unstable_strictMode===!0&&(i=!0),a.identifierPrefix!==void 0&&(r=a.identifierPrefix),a.onUncaughtError!==void 0&&(c=a.onUncaughtError),a.onCaughtError!==void 0&&(m=a.onCaughtError),a.onRecoverableError!==void 0&&(b=a.onRecoverableError),a.formState!==void 0&&(C=a.formState)),t=og(e,1,!0,t,a??null,i,r,C,c,m,b,bg),t.context=rg(null),a=t.current,i=rn(),i=bc(i),r=Na(i),r.callback=null,Ta(a,r,i),a=i,t.current.lanes=a,_a(t,a),Un(t),e[si]=t.current,cd(e),new qr(t)},no.version="19.2.6",no}var Ng;function z_(){if(Ng)return Od.exports;Ng=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(l){console.error(l)}}return n(),Od.exports=R_(),Od.exports}var D_=z_();function U_(n){if(!n)return null;const l=n.split("~"),s=l[0];if(!s)return null;if(l.length===1)return{kind:"section",instanceId:s};const o=l[1];if(!o)return null;const u=l[2],d=u!==void 0?Number(u):NaN;return{kind:"slot",instanceId:s,slotId:o,...Number.isInteger(d)?{itemIndex:d}:{}}}function L_(n){if(!n)return null;if(n.kind==="section")return n.instanceId;const l=`${n.instanceId}~${n.slotId}`;return n.itemIndex!==void 0?`${l}~${n.itemIndex}`:l}function B_(n,l){const s=new URL(l).pathname,o=s.endsWith("/")?s:`${s}/`;return`${n}/`===o?"":n.startsWith(o)?n.slice(o.length):null}function H_(n,l){const[s,o,u,d,...h]=n.split("/").filter(Boolean);if(s!=="fixtures"||!o||u!=="canvas"||h.length>0)return null;const p=new URLSearchParams(l);return{fixture:decodeURIComponent(o),canvasId:d?decodeURIComponent(d):null,format:p.get("format"),selection:U_(p.get("sel"))}}function q_(n){var s;const l=n.fixtures[0];return l===void 0?null:{fixture:l.id,canvasId:((s=n.template.canvases[0])==null?void 0:s.id)??null,format:null,selection:null}}function Tg(n){const l=n.canvasId===null?"canvas":`canvas/${encodeURIComponent(n.canvasId)}`,s=`fixtures/${encodeURIComponent(n.fixture)}/${l}`,o=new URLSearchParams;n.format!==null&&o.set("format",n.format);const u=L_(n.selection);u&&o.set("sel",u);const d=o.toString();return d?`${s}?${d}`:s}function w0(n,l){var s;return((s=n.parentElement)==null?void 0:s.closest(`[${l.slotId}],[${l.slotField}]`))??null}function ga(n,l){return!n.hasAttribute(l.slotUnselectable)}function S0(n,l,s,o){const u=[];for(const d of Array.from(n.querySelectorAll(l)))w0(d,o)===s&&u.push(d);return u}function If(n,l,s){return S0(n,`[${s.slotItem}="${String(l)}"]`,n,s)}function Og(n,l,s,o){var d;let u=n.closest(`[${l}]`);for(;u&&s.contains(u);){if(ga(u,o)&&w0(u,o)===s)return u;u=((d=u.parentElement)==null?void 0:d.closest(`[${l}]`))??null}return null}const Ud=1,G_=12;function I_(n,l){return{"--we-r-top":`${n.top}px`,"--we-r-left":`${n.left}px`,"--we-r-w":`${n.width}px`,"--we-r-h":`${n.height}px`,"--we-r-off":`${l}px`}}function Q_(n){const l=dc(n);return l.width<=0||l.height<=0?!1:!K_(n,l)}function Rg(n){return n==="hidden"||n==="scroll"||n==="auto"||n==="clip"}function K_(n,l){const s=n.ownerDocument.defaultView;if(!s)return!1;let o=-1/0,u=-1/0,d=1/0,h=1/0;for(let g=n.parentElement;g;g=g.parentElement){const x=s.getComputedStyle(g),v=Rg(x.overflowX||x.overflow),E=Rg(x.overflowY||x.overflow);if(!v&&!E)continue;const M=g.getBoundingClientRect();v&&(u=Math.max(u,M.left),d=Math.min(d,M.right)),E&&(o=Math.max(o,M.top),h=Math.min(h,M.bottom))}const p=l.left+l.width<=u||l.left>=d,y=l.top+l.height<=o||l.top>=h;return p||y}function dc(n){const l=n.getBoundingClientRect();if(l.width>0&&l.height>0)return l;let s=1/0,o=1/0,u=-1/0,d=-1/0,h=!1;for(const p of Array.from(n.children)){const y=dc(p);y.width<=0||y.height<=0||(h=!0,s=Math.min(s,y.top),o=Math.min(o,y.left),u=Math.max(u,y.right),d=Math.max(d,y.bottom))}return h?new DOMRect(o,s,u-o,d-s):l}function k0(n,l,s,o){if(!n)return;if(!l){Zr(n);return}const u=I_(dc(l),s);for(const[d,h]of Object.entries(u))n.style.setProperty(d,h);o&&n.setAttribute("data-kind",o),n.setAttribute("data-active","true")}function Zr(n){n&&(n.removeAttribute("data-active"),n.removeAttribute("data-kind"))}function zg(n,l,s,o){if(!n)return[];const u=n.ownerDocument,d=Array.from(n.querySelectorAll(".we-chrome-ring--selection")),h=n.querySelector(":scope > .we-chrome-label");for(;d.length<l.length;){const p=u.createElement("div");p.className="we-chrome-ring we-chrome-ring--selection",n.insertBefore(p,h),d.push(p)}d.forEach((p,y)=>k0(p,l[y]??null,s,o));for(const p of d.slice(Math.max(l.length,1)))p.remove();return d.slice(0,l.length)}function V_(n,l,s){if(!n)return;if(!l||!s){Wd(n);return}const o=dc(l),u=n.getAttribute("data-active")==="true",d=n.textContent!==s;n.textContent=s,n.style.setProperty("--we-l-top",`${o.top}px`),n.style.setProperty("--we-l-left",`${o.left}px`),n.style.setProperty("--we-l-indent",`${G_}px`),u&&d&&(n.removeAttribute("data-active"),n.offsetWidth),n.setAttribute("data-active","true")}function Wd(n){n&&(n.removeAttribute("data-active"),n.textContent="")}function Fl(n){return typeof CSS<"u"&&CSS.escape?CSS.escape(n):n.replace(/[^a-zA-Z0-9_-]/g,l=>`\\${l}`)}function Qf(n){const l=n.filter(s=>Q_(s));return l.length>0?l:n.slice(0,1)}function E0(n,l,s){const o=Array.from(n.querySelectorAll(`[${s.slotId}="${Fl(l)}"]`)).filter(u=>ga(u,s));return Qf(o)}function Y_(n,l,s){if(!l||l.kind!=="slot"||l.item_index==null)return[];const o=[];for(const u of n)o.push(...If(u,l.item_index,s).filter(d=>ga(d,s)));return Qf(o)}function j0(n,l,s){if(!l)return[];const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);if(!o)return[];if(l.kind==="section")return[o];const u=E0(o,l.slot_id,s);if(u.length===0)return[];if(l.item_index!=null||l.field_name){const d=l.field_name?`[${s.slotField}="${Fl(l.field_name)}"]`:null,h=[];for(const p of u){let y=[p];if(!(l.item_index!=null&&(y=If(p,l.item_index,s).filter(g=>ga(g,s)),y.length===0)))for(const g of y)if(d){const x=S0(g,d,p,s).filter(v=>ga(v,s));if(x.length>0){h.push(...x);continue}g!==p&&h.push(g)}else h.push(g)}if(h.length>0)return Qf(h)}return u.map(d=>{const h=d.closest(`[${s.slotGroup}]`);return h&&ga(h,s)?h:d})}function $_(n,l,s){return j0(n,l,s)[0]??null}const Dg="we-enh-shield",F_="we-enh-shield--item",Ki="data-we-live";function X_(n,l,s){if(!l||l.kind!=="slot"||l.item_index==null)return[];const o=[];for(const u of M0(n,l,s))o.push(...If(u,l.item_index,s).filter(d=>ga(d,s)));return o}function M0(n,l,s){if(!l||l.kind!=="slot")return[];const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);return o?Array.from(o.querySelectorAll(`[${s.slotId}="${Fl(l.slot_id)}"]`)):[]}function Z_(n,l,s){if(n.querySelectorAll(`[${Ki}]`).forEach(u=>u.removeAttribute(Ki)),!l)return;const o=n.querySelector(`[${s.sectionInstanceId}="${Fl(l.instance_id)}"]`);if(o)if(l.kind==="section")o.setAttribute(Ki,"true");else{const u=X_(n,l,s),d=u.length>0?u:M0(n,l,s).filter(h=>ga(h,s));for(const h of d)h.setAttribute(Ki,"true")}}const Yl=1440,Ug=Math.round(Yl*9/16),C0=14,Kf="we-frame-defaults";function P_(n){return`
50
- /* Section wrapper -- structure only. No selection chrome here;
51
- rings are painted by the host's overlay. Zero margin
52
- + padding means sections butt edge-to-edge, matching publisher. */
53
- [${n}] {
54
- position: relative;
55
- margin: 0;
56
- padding: 0;
57
- cursor: pointer;
58
- display: grid;
59
- grid-template-rows: 1fr;
60
- /* Reveal transition — governs the hidden→visible direction because
61
- CSS uses the destination state's transition property. Spring easing
62
- gives a snappy entrance. */
63
- transition:
64
- grid-template-rows 200ms cubic-bezier(0.16, 1, 0.3, 1),
65
- opacity 180ms cubic-bezier(0.16, 1, 0.3, 1);
66
- }
67
-
68
- /* Hidden state -- collapse the section out of the page so it reflows shut.
69
- The 0-height wrapper stays in flow as the anchor for the section's
70
- floating edge tab (built by the host in its own document). */
71
- [${n}][data-hidden="true"] {
72
- grid-template-rows: 0fr;
73
- opacity: 0;
74
- pointer-events: none;
75
- /* Collapse transition — governs the visible→hidden direction.
76
- Faster + accelerating so the hide feels decisive. */
77
- transition:
78
- grid-template-rows 150ms cubic-bezier(0.4, 0, 1, 1),
79
- opacity 120ms cubic-bezier(0.4, 0, 1, 1);
80
- }
81
-
82
- /* Per-section body holds the API HTML.
83
- 1. position:relative gives the body a positioning context for any
84
- body-scoped chrome or future body-only effects.
85
- 2. isolation:isolate SEALS the section's z-index hierarchy
86
- inside this stacking context. Without it, any positioned
87
- descendant with z-index > 0 (the header's sticky+z-50, a
88
- dropdown's z-40, a sticky CTA) creates a stacking context
89
- that escapes upward. Sections never need to know the
90
- editor chrome exists -- internal z-index is unconstrained. */
91
- /* overflow:hidden clips section content as the grid row collapses;
92
- min-height:0 lets the grid child shrink below its content size.
93
- Constraint: overflow:hidden is permanent (not just during animation), so
94
- section content must not overflow its section-body boundary — sticky
95
- elements, absolutely-positioned dropdowns, or shadows that bleed outside
96
- the section edge will be silently clipped. Template sections are
97
- self-contained blocks; this is safe in practice. */
98
- .we-section-body { position: relative; isolation: isolate; overflow: hidden; min-height: 0; }`}function J_(n){return`
99
- [${n}] {
100
- display: contents;
101
- /* Computed even while boxless, so the collapse below has a 1fr start
102
- value to animate from the instant the hidden box appears. */
103
- grid-template-rows: 1fr;
104
- cursor: pointer;
105
- }
106
- [${n}] > .we-section-body { display: contents; }
107
-
108
- /* Hidden state -- the wrapper takes a real box again: a zero-height grid
109
- item in the frame column, collapsing the section out of the page while
110
- staying in flow as the anchor for its edge tab. display is not
111
- transitioned, so the box appears at 1fr immediately and the collapse
112
- animates its full run; the reveal returns to display:contents at once —
113
- a boxless wrapper has nothing to animate, so re-entry is instant by
114
- design. */
115
- [${n}][data-hidden="true"] {
116
- display: grid;
117
- grid-template-rows: 0fr;
118
- opacity: 0;
119
- pointer-events: none;
120
- transition:
121
- grid-template-rows 150ms cubic-bezier(0.4, 0, 1, 1),
122
- opacity 120ms cubic-bezier(0.4, 0, 1, 1);
123
- }
124
- [${n}][data-hidden="true"] > .we-section-body {
125
- display: block;
126
- overflow: hidden;
127
- min-height: 0;
128
- }
129
-
130
- /* The frame stylesheet imposes flex-shrink:0 on the column's items from
131
- outside the section; with the wrapper boxless the section IS that item,
132
- so the same imposition lands here. Layered so an author utility on the
133
- section root still wins, exactly as it does against the stylesheet's own
134
- copy of this rule. */
135
- @layer ${Kf} {
136
- [${n}] > .we-section-body > * { flex-shrink: 0; }
137
- }`}function W_(n,l){const s=l?`#we-page {
138
- padding: 0;
139
- }`:`#we-page {
140
- width: ${Yl}px;
141
- min-height: ${Ug}px;
142
- overflow: hidden;
143
- border-radius: ${C0}px;
144
- background: #f5f3ee;
145
- padding: 0;
146
- }
147
- /* The window this card stands for. The card's WIDTH is a real viewport, so
148
- vw units and width queries need nothing from us; its HEIGHT is the page's
149
- own measurement, which makes 100svh circular here — a section sized from it
150
- asks for a window its own height is what produced, and climbs on every
151
- pass. The window-height token is the seam that ends it: a section writes
152
- the token instead of the unit, and here it is the screen this card is cut
153
- from (the floor above), a constant that settles in one pass. Declared
154
- UNLAYERED, unlike the document defaults: this is not a fallback a template
155
- may better, it is what the window IS on this surface, and Concrete's own
156
- declaration of the token is unlayered too. A page box takes none of this —
157
- a frame document is given the window its format declares, so 100svh there
158
- is already the truth. */
159
- :root {
160
- --concrete-window-h: ${Ug}px;
161
- }`;return`
162
- html, body {
163
- margin: 0;
164
- /* The host owns the scroll container; this document never scrolls —
165
- not even programmatically (overflow: clip pins scrollTop to 0), so a
166
- transient gap while the host syncs the iframe's height to the page
167
- can never flash a scrollbar or shift a measured rect. */
168
- overflow: clip;
169
- }
170
- /* Document defaults, NOT document truth: the theme's own body mapping is
171
- what the published page renders with, so it must win here too — fonts and
172
- wraps in the frame diverge from capture otherwise. The layer (pre-declared
173
- by the srcdoc, see FRAME_DEFAULTS_LAYER) is what makes these lose to any
174
- template declaration. */
175
- @layer ${Kf} {
176
- html, body {
177
- background: transparent;
178
- }
179
- body {
180
- color: #14180F;
181
- font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
182
- }
183
- }
184
- ${s}
185
- ${l?J_(n.sectionInstanceId):P_(n.sectionInstanceId)}
186
-
187
- /* Slot wrapper -- structure only. No outline here; the host's overlay
188
- ring handles slot hover + selection too. */
189
- [${n.slotId}] {
190
- cursor: pointer;
191
- }
192
-
193
- /* Slot-group container -- the gaps between grouped members (dividers,
194
- padding) carry no slot id, so give the group container itself
195
- the pointer cursor: the whole group reads as one clickable unit, and
196
- the overlay ring outlines this container. */
197
- [${n.slotGroup}],
198
- [${n.slotItem}] {
199
- cursor: pointer;
200
- }
201
-
202
- /* Deliberately NO position default on the marker elements: published pages
203
- and captured artifacts set no position on them, so an unpositioned slot
204
- must compute static here too — a relative default (even layered, losing
205
- to author utilities) re-anchored an author's absolutely positioned
206
- descendant to the slot on this surface while the published page anchored
207
- it farther up, and could shift stacking the same way. Nothing in the
208
- chrome needs it: rings measure client rects from the host overlay, and
209
- everything that mounts absolute chrome inside the frame (island shields,
210
- the crop spinner) checks the surface's computed position and forces an
211
- inline relative itself. */
212
-
213
- @media (prefers-reduced-motion: reduce) {
214
- [${n.sectionInstanceId}] {
215
- transition: none !important;
216
- }
217
- }
218
-
219
- /* Render-error placeholder ------------------------------------- */
220
- .we-render-error {
221
- margin: 8px 0;
222
- padding: 24px 16px;
223
- border-radius: 6px;
224
- border: 1px dashed #ebebe6;
225
- background: #ffffff;
226
- color: #8a877e;
227
- font-size: 12.5px;
228
- }
229
- .we-render-error__title {
230
- margin: 0;
231
- color: #4a4842;
232
- font-weight: 500;
233
- }
234
- .we-render-error__detail {
235
- margin: 4px 0 0 0;
236
- color: #b9b6ab;
237
- font-size: 11.5px;
238
- }
239
-
240
- /* Island interaction shield: a transparent click layer derived from a live
241
- island's own markup (island-shields.ts) — a base shield per island root box,
242
- an item shield per rendered collection-item copy. Present until the shield's
243
- owner carries the live-owner stamp; a click on a shield falls through to the
244
- editor's resolver, which selects the nearest marked ancestor. Base z-index 1
245
- sits on the island content's plane but below floating content that must stay
246
- clickable at z-index 2 (e.g. the neighborhood card over the map canvas). Item
247
- shields ride one plane above the base, so a click over an item copy hits the
248
- ITEM's shield and one click selects that item. */
249
- .${Dg} {
250
- position: absolute;
251
- inset: 0;
252
- z-index: 1;
253
- cursor: pointer;
254
- background: transparent;
255
- }
256
- .${F_} { z-index: 2; }
257
- [${Ki}] .${Dg} { display: none; }
258
-
259
- /* Image slider: until the slider's \`images\` slot is the live selection, its
260
- z-index:2 nav arrows would paint above the z-index:1 shield and stay
261
- clickable, escaping the select-first gate. Disable them so the shield
262
- catches the first click; restored once .tr-slider carries data-we-live.
263
- Editor-only — deliberately not in published tokens.css. */
264
- .tr-slider:not([${Ki}]) .tr-slider__nav { pointer-events: none; }
265
- `}function ew(n,l){const o=n/Yl,u=Number.POSITIVE_INFINITY;return Math.max(.05,Math.min(.9,.72*o,.1926*o+.54,u))}const tw=420,Lg=.92;function nw(n,l,s){if(!s)return n;const o=Math.max(n,tw/s.width),u=Math.min(.9,n*Yl/s.width,Lg*l.availableWidthPx/s.width,Lg*l.availableHeightPx/s.height);return Math.max(.05,Math.min(o,u))}function Bg(n,l,s){var u;let o=n.closest(`[${l}]`);for(;o&&!ga(o,s);)o=((u=o.parentElement)==null?void 0:u.closest(`[${l}]`))??null;return o}function aw(n,l,s){for(const o of Array.from(n.querySelectorAll(`[${s.markers.slotId}]`))){if(o.closest(`[${s.markers.slotGroup}]`)!==n)continue;const u=o.getAttribute(s.markers.slotId);if(u&&s.isSlotEditable(l,u))return u}return null}function lw(n,l,s){if(!n)return null;const o=n.closest(`[${s.markers.sectionInstanceId}]`),u=o==null?void 0:o.getAttribute(s.markers.sectionInstanceId);if(!o||!u)return null;const d=l.find(j=>j.instance_id===u),h={selection:{kind:"section",instance_id:u},element:o};if(!d)return h;const p=Bg(n,s.markers.slotGroup,s.markers);if(p&&o.contains(p)){const j=aw(p,u,s);return j?{selection:{kind:"slot",instance_id:u,slot_id:j},element:p}:h}const y=Bg(n,s.markers.slotId,s.markers),g=y==null?void 0:y.getAttribute(s.markers.slotId);if(!y||!g||!s.isSlotEditable(u,g))return h;const x=Og(n,s.markers.slotItem,y,s.markers),v=x?Number(x.getAttribute(s.markers.slotItem)):NaN,E=Number.isInteger(v)?v:void 0,M=Og(n,s.markers.slotField,y,s.markers),N=(M==null?void 0:M.getAttribute(s.markers.slotField))??null,A=N&&s.isSlotEditable(u,g,N)?N:null;return{selection:{kind:"slot",instance_id:u,slot_id:g,...E!==void 0?{item_index:E}:{},...A?{field_name:A}:{}},element:(A?M:null)??x??y}}function ef(n){return n.section_display_name?n.section_display_name:n.section_key.split("-").map(l=>l&&l[0].toUpperCase()+l.slice(1)).join(" ")}function iw(n){if(!n)return"null";let l=2166136261;for(let s=0;s<n.length;s++)l^=n.charCodeAt(s),l=Math.imul(l,16777619);return(l>>>0).toString(16)}function A0(n,l){var d;const s=l.createElement("div");s.className="we-render-error";const o=l.createElement("p");o.className="we-render-error__title",o.textContent="Couldn’t render this section.";const u=l.createElement("p");return u.className="we-render-error__detail",u.textContent=((d=n.render_error)==null?void 0:d.message)??"Unknown render error.",s.appendChild(o),s.appendChild(u),s}function sw(n,l,s,o){const u=l.createElement("div");u.setAttribute(s.sectionInstanceId,n.instance_id),u.setAttribute("data-section-label",ef(n)),u.dataset.svId=n.section_version_id,u.dataset.htmlHash=iw(n.html);const d=l.createElement("div");return d.className="we-section-body",n.render_error||n.html===null?d.appendChild(A0(n,l)):d.innerHTML=o(n.html),u.appendChild(d),u}function Hg(n){return JSON.stringify(n).replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026")}const ow="concrete-frame";function Ld(n){return n.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;")}function rw(n,l){const s=Object.entries(l).map(([o,u])=>`${o}:${u}`).join(";");return{class:ow,dataFormat:n,style:s}}function cw(n){if(!n)return"";const l=rw(n.formatId,n.tokens);return` class="${Ld(l.class)}" data-format="${Ld(l.dataFormat)}" style="${Ld(l.style)}"`}function uw(n){if(Object.keys(n.islandMap).length===0)return"";if(Object.keys(n.importMap).length===0&&!n.hostResolvesOwnImports)return console.error("canvas: this template version has islands but no import map, so nothing can resolve their React — sections render statically. Republish the template to emit the vendor."),"";const l=n.hostScriptSrc?`
266
- <script id="tr-island-host" type="module" src="${n.hostScriptSrc}"><\/script>`:"";return`${Object.keys(n.importMap).length===0?"":`
267
- <script type="importmap">${Hg({imports:n.importMap})}<\/script>`}
268
- <script>window.__TR_ISLAND_MAP=${Hg(n.islandMap)};<\/script>
269
- <!-- id is the contract the host's readiness gate keys off — it waits on THIS
270
- element's load event, not a timeout, so a slow cold first load still
271
- activates without a refresh. -->${l}`}function dw(n,l){return n.replaceAll("/section-assets/",`${l}runtime/section-asset/`)}function fw(n,l,s){const o=n.stylesheets.map(u=>`<link rel="stylesheet" href="${u}">`).join("");return`<!doctype html>
272
- <html>
273
- <head>
274
- <meta charset="utf-8">
275
- <base href="${n.basePath}">
276
- <!-- Cascade-layer order is fixed by FIRST declaration, document-wide. The
277
- kernel's document defaults must lose to everything a template declares,
278
- so their layer is pre-declared here, before any template stylesheet,
279
- pinning it below every layer those go on to declare. -->
280
- <style>@layer ${Kf};</style>
281
- ${o}${uw(n)}
282
- <style>${W_(l,s)}</style>
283
- </head>
284
- <body>
285
- <div id="we-page"${cw(s)}></div>
286
- </body>
287
- </html>`}function hw(n){return!!(n!=null&&n.getElementById("we-page"))}function qg(n){const l=s=>dw(s,n.assets.basePath);return{srcdoc:()=>fw(n.assets,n.markers,n.pageBox),buildSectionWrapper:(s,o)=>sw(s,o,n.markers,l),buildErrorPlaceholder:A0,resolveTarget:(s,o)=>lw(s,o,n),localizeSectionAssets:l,resolveSelectionEl:(s,o)=>$_(s,o,n.markers),resolveSelectionEls:(s,o)=>j0(s,o,n.markers),resolveVisibleSlotEls:(s,o)=>E0(s,o,n.markers),resolveItemEls:(s,o)=>Y_(s,o,n.markers),setLiveOwner:(s,o)=>Z_(s,o,n.markers)}}const N0=(n,l)=>`<svg class="${n}" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">${l}</svg>`;function pw(n){return N0(n,'<path d="M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49"/><path d="M14.084 14.158a3 3 0 0 1-4.242-4.242"/><path d="M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143"/><path d="m2 2 20 20"/>')}function mw(n){return N0(n,'<path d="M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0"/><circle cx="12" cy="12" r="3"/>')}const yw=42,T0=16;function gw(n,l){const s=[];for(const u of n)for(s.push({sum:u.y,n:1,items:[u]});s.length>1;){const d=s[s.length-1],h=s[s.length-2];if(!d||!h)break;const p=d.sum/d.n-(d.n-1)/2*l,y=h.sum/h.n+(h.n-1)/2*l;if(p-y<l)s.splice(s.length-2,2,{sum:h.sum+d.sum,n:h.n+d.n,items:h.items.concat(d.items)});else break}const o={};for(const u of s){const d=u.sum/u.n-(u.n-1)/2*l;u.items.forEach((h,p)=>{o[h.idx]=d+p*l})}return o}const bw=pw("we-htab-eye-off"),vw=mw("we-htab-eye-on"),tf=new WeakMap;function xw(n,l,s,o){const u=n.createElement("button");u.type="button",u.className="we-htab",u.dataset.hiddenTab=l,u.title=`Show ${s}`,u.setAttribute("aria-label",`Show ${s}`),u.innerHTML=`<span class="we-htab-eye">${bw}${vw}</span><span class="we-htab-name"></span>`;const d=u.querySelector(".we-htab-name");return d&&(d.textContent=s),tf.set(u,o),u.addEventListener("click",h=>{var p;h.stopPropagation(),(p=tf.get(u))==null||p()}),u}function _w(n,l,s,o){const u=new Map;n.querySelectorAll(".we-htab").forEach(p=>{const y=p.dataset.hiddenTab;y&&u.set(y,p)});const d=new Set,h=[];for(const p of s){let y=u.get(p.instanceId);if(!y)y=xw(l,p.instanceId,p.label,()=>o(p.instanceId)),n.appendChild(y);else{const g=y.querySelector(".we-htab-name");g&&g.textContent!==p.label&&(g.textContent=p.label),y.title=`Show ${p.label}`,y.setAttribute("aria-label",`Show ${p.label}`),tf.set(y,()=>o(p.instanceId))}d.add(p.instanceId),h.push(y)}return u.forEach((p,y)=>{d.has(y)||p.remove()}),h}function ww(n,l,s){const o=n.map((d,h)=>{const p=l(d.dataset.hiddenTab??""),y=p?p.getBoundingClientRect().top*s:0;return{idx:h,y}}),u=gw(o,yw);n.forEach((d,h)=>{d.style.top=`${u[h]}px`,d.style.left=`${T0-d.offsetWidth}px`})}const Sw=48,kw=30,Ew=`
288
- @property --we-scale {
289
- syntax: "<number>";
290
- inherits: true;
291
- initial-value: 1;
292
- }
293
-
294
- /* The scroll container + dotted canvas surface. The host lays this element
295
- out — position and size are the host's (it must both bound the height and
296
- be positioned, so the frame wrapper's offset parent is the stage);
297
- everything inside is kernel-defined. Declaring position here would win
298
- the cascade over a host's own positioning utility classes (this sheet
299
- loads after theirs), which is how the app's absolutely-positioned stage
300
- once silently became in-flow and unscrollable.
301
- background-attachment: local makes the grid scroll together with
302
- the page card so the canvas + website read as one scene being panned, not
303
- a card sliding over a fixed grid. Padding aligns the page card with the
304
- floating panel: top/bottom/left 20px; the right constant (40px) covers the
305
- panel's right inset (20px) plus an equal 20px gap. Fallback 436px matches
306
- the panel's base CSS width.
307
- The top padding also carries the label lane: a page-title row is drawn
308
- ABOVE its frame's box, so the topmost frame's row would otherwise sit in
309
- the 20px margin. --we-frame-label-lane is set by the stage reconciler only
310
- when some frame is labeled, so a canvas whose pages declare no label keeps
311
- the original 20px exactly. */
312
- .we-canvas-stage {
313
- overflow: auto;
314
- padding: calc(20px + var(--we-frame-label-lane, 0px))
315
- calc(var(--we-panel-w, 436px) + 40px) 20px 20px;
316
- transition: --we-scale 150ms cubic-bezier(0.4, 0, 0.2, 1);
317
- background-image: radial-gradient(rgba(20, 18, 13, 0.13) 1px, transparent 1.2px);
318
- background-size: 20px 20px;
319
- background-position: 10px 10px;
320
- background-attachment: local;
321
- scrollbar-width: none;
322
- -ms-overflow-style: none;
323
- }
324
- .we-canvas-stage::-webkit-scrollbar { width: 0; height: 0; display: none; }
325
-
326
- /* The scaled page card's layout box: exactly the iframe's visual footprint,
327
- so the stage scrolls and centers the card correctly. Auto inline margins
328
- rather than flex centering: they collapse to 0 when the card overflows the
329
- stage, keeping the left edge reachable by scroll at high zoom.
330
-
331
- isolation:isolate SEALS the canvas's own stacking hierarchy (tab layer,
332
- page card, chrome overlay) into this element, so those z-indexes are
333
- ordered only against each other and the whole card paints at the stage's
334
- position in the HOST's DOM order. Without it the overlay competed
335
- directly with the host's floating chrome -- a panel, a zoom toolbar, a
336
- notice banner -- and a hover outline drew straight over the controls.
337
- Same reasoning as the section wrappers' isolate in the frame document. */
338
- .we-canvas-frame {
339
- position: relative;
340
- width: calc(var(--we-page-w, ${Yl}px) * var(--we-scale, 1));
341
- height: calc(var(--we-page-h, 0px) * var(--we-scale, 1));
342
- margin-inline: auto;
343
- isolation: isolate;
344
- }
345
-
346
- /* The multi-frame stack: one frame per row, in the canvas's page order, each
347
- centered on the same axis a lone page card already used (the auto inline
348
- margins above), separated by a constant host-px gap plus whatever lane the
349
- label chips need. Expressed as an adjacent-sibling rule so a single-frame
350
- canvas matches no selector at all and lays out byte-identically to what it
351
- did before frames could stack. The gap does NOT ride --we-scale: it is
352
- chrome between two artifacts, not a part of either, so it stays the same
353
- distance at any zoom. */
354
- .we-canvas-frame + .we-canvas-frame {
355
- margin-top: calc(${Sw}px + var(--we-frame-label-lane, 0px));
356
- }
357
-
358
- /* Page-title row -- "Front", "Back": which page of the canvas this frame
359
- is, with the visibility toggle seated directly beside the name it acts
360
- on (one group, never split across the page's corners). Drawn ABOVE the
361
- frame's box (bottom: 100%, in the lane the stage padding and the
362
- inter-frame gap reserve) so it never covers artwork, and sized in
363
- --we-content like the edge tabs: constant visual size at any zoom,
364
- because it names the page rather than belonging to it.
365
- pointer-events:none at the row so the lane's empty run stays stage
366
- surface (a deselect click must fall through); the toggle re-enables its
367
- own. */
368
- .we-frame-titlebar {
369
- position: absolute;
370
- bottom: 100%;
371
- left: 0;
372
- right: 0;
373
- margin-bottom: calc(4 * var(--we-content, 1px));
374
- display: flex;
375
- align-items: center;
376
- gap: calc(6 * var(--we-content, 1px));
377
- pointer-events: none;
378
- }
379
- /* Quiet by design: the row annotates the artwork below it, so it reads in
380
- a light gray that cedes attention to the page — the ink weights are
381
- reserved for the states that earn them (hover, the engaged toggle). */
382
- .we-canvas-frame-label {
383
- min-width: 0;
384
- overflow: hidden;
385
- text-overflow: ellipsis;
386
- white-space: nowrap;
387
- color: #a09d94;
388
- font-size: calc(13 * var(--we-content, 1px));
389
- font-weight: 500;
390
- letter-spacing: -0.01em;
391
- line-height: 1;
392
- }
393
-
394
- /* Page-visibility toggle -- the eye beside the page title, resting in the
395
- title's own gray so the row reads as one quiet group. Rendered only
396
- for pages the composition marks optional (frame-visibility.ts). */
397
- .we-frame-toggle {
398
- flex: 0 0 auto;
399
- display: grid;
400
- place-items: center;
401
- width: calc(24 * var(--we-content, 1px));
402
- height: calc(22 * var(--we-content, 1px));
403
- padding: 0;
404
- border: 0;
405
- border-radius: calc(6 * var(--we-content, 1px));
406
- background: transparent;
407
- color: #a09d94;
408
- cursor: pointer;
409
- pointer-events: auto;
410
- transition: background-color 0.15s, color 0.15s;
411
- }
412
- .we-frame-toggle svg {
413
- width: calc(14 * var(--we-content, 1px));
414
- height: calc(14 * var(--we-content, 1px));
415
- }
416
- .we-frame-toggle:hover {
417
- background: rgba(20, 18, 13, 0.06);
418
- color: #14180F;
419
- }
420
- .we-frame-toggle:focus-visible {
421
- outline: none;
422
- background: rgba(20, 18, 13, 0.06);
423
- color: #14180F;
424
- box-shadow: 0 0 0 2px rgba(15, 42, 34, 0.5);
425
- }
426
- /* Hidden state reads as an engaged control (the section eye's hidden
427
- treatment): filled box, full-ink glyph. */
428
- .we-frame-toggle[data-page-visibility="hidden"] {
429
- background: rgba(20, 18, 13, 0.06);
430
- color: #14180F;
431
- box-shadow: inset 0 0 0 1px #ebebe6;
432
- }
433
- /* Hidden page -- tinted to a clear deactivated state, in place and at full
434
- footprint (a page never collapses the way a hidden section does), still
435
- fully interactive: the tint says "excluded from the artifact", not
436
- "locked". The title strikes through and lightens, the same reading as a
437
- fully-hidden canvas's bar tab. The stamp is written by
438
- frame-visibility.ts. */
439
- .we-canvas-frame[data-page-hidden="true"] > iframe {
440
- filter: grayscale(1) opacity(0.55);
441
- }
442
- .we-canvas-frame[data-page-hidden="true"] > .we-frame-titlebar > .we-canvas-frame-label {
443
- text-decoration: line-through;
444
- color: #b6b3aa;
445
- }
446
-
447
- /* The frame document: unscaled ${Yl}px layout, scaled here as an
448
- element. The border-radius matches #we-page inside, so the card shadow
449
- follows the content's silhouette; both radius and shadow ride the
450
- transform, exactly as they rode the old in-document scaling. z-index 2
451
- stacks the card above the edge tabs (z-index 1) so the shadow falls over a
452
- tab's tucked-under inner edge, nestling it against the page. */
453
- .we-canvas-frame > iframe {
454
- display: block;
455
- border: 0;
456
- background: transparent;
457
- width: var(--we-page-w, ${Yl}px);
458
- height: var(--we-page-h, 0px);
459
- border-radius: var(--we-page-radius, ${C0}px);
460
- box-shadow:
461
- 0 1px 0 rgba(20,18,13,0.06),
462
- 0 2px 6px -2px rgba(20,18,13,0.10),
463
- 0 12px 28px -8px rgba(20,18,13,0.18),
464
- 0 32px 64px -20px rgba(20,18,13,0.28);
465
- transform: scale(var(--we-scale, 1));
466
- transform-origin: 0 0;
467
- position: relative;
468
- z-index: 2;
469
- transition: filter 0.2s ease;
470
- }
471
-
472
- /* Chrome overlay -- sized to the frame wrapper, i.e. the scaled page card,
473
- so x=0/y=0 is the page's top-left corner. overflow stays visible: a ring
474
- at the page boundary or a label straddling the top border extends past
475
- the card and must not clip. pointer-events:none so clicks pass through to
476
- the iframe underneath.
477
-
478
- Positioning contract: chrome.ts measures a target in the FRAME document
479
- (layout truth — that document never scales or scrolls) and writes the
480
- rect as custom properties on the ring/label; the formulas here scale it
481
- into host space. Keeping the formula in the stylesheet and the data in
482
- properties is what lets a transitioned --we-scale move every ring in
483
- lockstep with the iframe's own animated transform. The ring's offset
484
- (its inflation past the target's edge) stays OUTSIDE the multiplication:
485
- constant host px at any zoom.
486
-
487
- z-index 3 -- one step above the page card, and nothing more: the frame's
488
- isolate is what keeps the chrome under the host's own UI, so a large
489
- value here would buy nothing and read as an escape hatch.
490
-
491
- A CLASS, not an id: every frame on the stage carries one of these, and the
492
- chrome functions are handed the overlay rather than resolving it by
493
- document-global id. */
494
- .we-chrome-overlay {
495
- position: absolute;
496
- inset: 0;
497
- pointer-events: none;
498
- z-index: 3;
499
- }
500
- .we-chrome-ring {
501
- position: absolute;
502
- pointer-events: none;
503
- border: 2px solid transparent;
504
- border-radius: 6px;
505
- opacity: 0;
506
- box-sizing: border-box;
507
- top: calc(var(--we-r-top, 0px) * var(--we-scale, 1) - var(--we-r-off, 0px));
508
- left: calc(var(--we-r-left, 0px) * var(--we-scale, 1) - var(--we-r-off, 0px));
509
- width: calc(var(--we-r-w, 0px) * var(--we-scale, 1) + 2 * var(--we-r-off, 0px));
510
- height: calc(var(--we-r-h, 0px) * var(--we-scale, 1) + 2 * var(--we-r-off, 0px));
511
- }
512
- /* Hover ring -- instant on cursor arrival, fades out on leave.
513
- Position updates instantly (no top/left transition) so dragging
514
- across elements never flickers. Ink stroke + white drop-shadow
515
- halo keeps the ring readable on both light sections and dark ones. */
516
- .we-chrome-ring--hover {
517
- border-color: rgba(15,42,34,0.85);
518
- filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
519
- transition: opacity 70ms ease-in;
520
- }
521
- .we-chrome-ring--hover[data-active="true"] {
522
- opacity: 1;
523
- transition: opacity 100ms cubic-bezier(0.16, 1, 0.3, 1);
524
- }
525
- /* Selection ring -- appears instantly (continuous with hover),
526
- then morphs ink → gold. No position transition so resize
527
- tracking stays tight. Same ink + white halo as hover. */
528
- .we-chrome-ring--selection {
529
- border-color: rgba(15,42,34,0.85);
530
- filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
531
- transform: scale(1);
532
- box-shadow: none;
533
- transition:
534
- opacity 50ms ease-in,
535
- border-color 160ms cubic-bezier(0.2, 0, 0, 1),
536
- box-shadow 160ms cubic-bezier(0.2, 0, 0, 1);
537
- }
538
- .we-chrome-ring--selection[data-active="true"] {
539
- opacity: 1;
540
- /* Instant show on select; only border + glow animate */
541
- transition:
542
- opacity 0ms,
543
- border-color 180ms cubic-bezier(0.2, 0, 0, 1),
544
- box-shadow 180ms cubic-bezier(0.2, 0, 0, 1);
545
- }
546
- .we-chrome-ring--selection[data-kind="section"],
547
- .we-chrome-ring--selection[data-kind="slot"] {
548
- border-color: #E5B832;
549
- filter: drop-shadow(0 0 1px rgba(255,255,255,0.95));
550
- box-shadow: 0 0 0 1px rgba(229,184,50,0.25), 0 8px 24px -10px rgba(229,184,50,0.35);
551
- }
552
-
553
- /* Geometry guides -- the trim line and the bleed region for a rendered-class
554
- page. The overlay is the page (bleed) box exactly, so insetting all four
555
- sides by the declared bleed gives the trim box with no arithmetic: the
556
- border draws the trim line and the shadow's spread fills the band between
557
- trim and page edge. Data/formula split as for the rings — guides.ts writes
558
- --we-g-bleed in frame space, the multiplication happens here, so a
559
- transitioned zoom moves the guides with the card. The 1px line itself
560
- stays OUTSIDE the multiplication: constant host px at any zoom, like the
561
- ring's offset.
562
-
563
- Magenta rather than the chrome's ink/gold: a guide is an instrument about
564
- the artifact, never a selection, and the print convention reads instantly.
565
- The inset white hairline keeps the line legible over dark artwork, the
566
- role the rings' drop-shadow halo plays for them. First child of the
567
- overlay, so rings and the title pill paint above it. */
568
- .we-guide {
569
- position: absolute;
570
- box-sizing: border-box;
571
- pointer-events: none;
572
- opacity: 0;
573
- top: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
574
- right: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
575
- bottom: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
576
- left: calc(var(--we-g-bleed, 0px) * var(--we-scale, 1));
577
- border: 1px solid rgba(214,32,140,0.9);
578
- box-shadow:
579
- inset 0 0 0 1px rgba(255,255,255,0.55),
580
- 0 0 0 calc(var(--we-g-bleed, 0px) * var(--we-scale, 1)) rgba(214,32,140,0.16);
581
- transition: opacity 90ms ease-in;
582
- }
583
- .we-guide[data-active="true"] { opacity: 1; }
584
-
585
- /* Section title pill -- straddles the selection's top border; geometry set
586
- by chrome.ts as custom properties, same contract as the rings. The left
587
- indent is constant host px. Sections only; slots get the outline ring but
588
- no on-canvas label. */
589
- .we-chrome-label {
590
- position: absolute;
591
- top: calc(var(--we-l-top, 0px) * var(--we-scale, 1));
592
- left: calc(var(--we-l-left, 0px) * var(--we-scale, 1) + var(--we-l-indent, 0px));
593
- pointer-events: none;
594
- z-index: 1;
595
- background: rgba(229,184,50,0.95);
596
- color: #282c32;
597
- padding: 3px 8px;
598
- border-radius: 4px;
599
- font-size: 10.5px;
600
- font-weight: 600;
601
- line-height: 1;
602
- white-space: nowrap;
603
- opacity: 0;
604
- transform: translateY(calc(-50% - 4px)) scale(0.96);
605
- transition:
606
- opacity 60ms ease-in,
607
- transform 60ms ease-in;
608
- }
609
- .we-chrome-label[data-active="true"] {
610
- opacity: 1;
611
- transform: translateY(-50%) scale(1);
612
- transition:
613
- opacity 130ms cubic-bezier(0.16, 1, 0.3, 1) 50ms,
614
- transform 130ms cubic-bezier(0.16, 1, 0.3, 1) 50ms;
615
- }
616
-
617
- /* Hidden-section edge tabs -------------------------------------
618
- One dim chip-tab per hidden section, pinned to the page card's left edge
619
- at the collapsed wrapper's reflow seam. Built + positioned by the host
620
- orchestrator; de-collided via placeTabs. Constant visual size at any zoom
621
- — the layer sits outside the scaled iframe. --we-content is the host's
622
- interior scaling unit (its large-screen chrome scale); a host without one
623
- leaves the 1px fallback in force. A class for the same reason the overlay
624
- is one: one tab layer per frame, addressed through that frame's handle. */
625
- .we-htabs {
626
- position: absolute;
627
- inset: 0;
628
- pointer-events: none;
629
- z-index: 1;
630
- }
631
- .we-htab {
632
- position: absolute;
633
- transform: translateY(-50%);
634
- display: flex;
635
- align-items: center;
636
- gap: calc(9 * var(--we-content, 1px));
637
- height: calc(34 * var(--we-content, 1px));
638
- padding: 0 calc(${12+T0} * var(--we-content, 1px)) 0 calc(13 * var(--we-content, 1px));
639
- background: #ffffff;
640
- border: 1px solid #ebebe6;
641
- border-radius: calc(9 * var(--we-content, 1px)) 0 0 calc(9 * var(--we-content, 1px));
642
- box-shadow: 0 10px 24px -12px rgba(20,18,13,0.34);
643
- color: #4a4842;
644
- font: inherit;
645
- cursor: pointer;
646
- opacity: 1;
647
- pointer-events: auto;
648
- transition: transform 0.2s cubic-bezier(0.2,0.7,0.3,1),
649
- border-color 0.18s, box-shadow 0.18s;
650
- }
651
- .we-htab-eye {
652
- display: grid;
653
- place-items: center;
654
- flex: 0 0 auto;
655
- color: #8a877e;
656
- transition: color 0.18s;
657
- }
658
- .we-htab-eye svg { width: calc(14 * var(--we-content, 1px)); height: calc(14 * var(--we-content, 1px)); }
659
- .we-htab-name {
660
- font-size: calc(13 * var(--we-content, 1px));
661
- font-weight: 600;
662
- letter-spacing: -0.01em;
663
- color: #14180F;
664
- white-space: nowrap;
665
- }
666
- .we-htab:hover {
667
- transform: translateY(-50%) scale(1.07);
668
- border-color: rgba(15,42,34,0.5);
669
- box-shadow: 0 13px 30px -12px rgba(15,42,34,0.45);
670
- }
671
- .we-htab:hover .we-htab-eye { color: #0F2A22; }
672
- .we-htab:focus-visible {
673
- outline: none;
674
- transform: translateY(-50%) scale(1.07);
675
- border-color: #0F2A22;
676
- box-shadow: 0 0 0 3px #F3F6EF, 0 13px 30px -12px rgba(15,42,34,0.45);
677
- }
678
- /* Hover/focus swaps the eye-off glyph to the eye glyph in place — no width
679
- change, no sliding label. Only one glyph is in flow at a time, so the eye
680
- slot's grid keeps the shown glyph centered. */
681
- .we-htab-eye-on { display: none; }
682
- .we-htab:hover .we-htab-eye-off,
683
- .we-htab:focus-visible .we-htab-eye-off { display: none; }
684
- .we-htab:hover .we-htab-eye-on,
685
- .we-htab:focus-visible .we-htab-eye-on { display: block; }
686
-
687
- @media (prefers-reduced-motion: reduce) {
688
- .we-canvas-stage,
689
- .we-canvas-frame > iframe,
690
- .we-chrome-ring,
691
- .we-chrome-label,
692
- .we-guide,
693
- .we-htab,
694
- .we-frame-toggle {
695
- transition: none !important;
696
- }
697
- }
698
- `,jw='<div class="we-guide"></div><div class="we-chrome-ring we-chrome-ring--hover"></div><div class="we-chrome-ring we-chrome-ring--selection"></div><div class="we-chrome-label"></div>',tc="we-canvas-frame",Gg="we-frame-titlebar",Ig="we-canvas-frame-label",Qg="we-htabs",Kg="we-chrome-overlay";function Bd(n,l,s){const o=n.querySelector(l);if(o)return o;const u=s();return n.appendChild(u),u}function Mw(n,l){const s=n.querySelector(`:scope > .${Gg}`);if(s)return s;const o=l.createElement("div");return o.className=Gg,n.insertBefore(o,n.firstChild),o}function Cw(n){for(let l=n.nextElementSibling;l;l=l.nextElementSibling)if(l.classList.contains(tc))return l;return null}function Aw(n,l){const s=n.ownerDocument,o=Mw(n,s),u=l.label??"",d=o.querySelector(`:scope > .${Ig}`);if(u==="")d==null||d.remove();else{const x=d??o.insertBefore(s.createElement("div"),o.firstChild);x.className=Ig,x.textContent!==u&&(x.textContent=u)}const h=Bd(n,":scope > iframe",()=>s.createElement("iframe"));l.title!==void 0&&h.title!==l.title&&(h.title=l.title),l.sandbox!==void 0&&h.getAttribute("sandbox")!==l.sandbox&&h.setAttribute("sandbox",l.sandbox),h.getAttribute("srcdoc")!==l.srcdoc&&h.setAttribute("srcdoc",l.srcdoc);const p=Bd(n,`:scope > .${Qg}`,()=>{const x=s.createElement("div");return x.className=Qg,x}),y=Bd(n,`:scope > .${Kg}`,()=>{const x=s.createElement("div");return x.className=Kg,x.setAttribute("aria-hidden","true"),x});y.childElementCount===0&&(y.innerHTML=jw);const g=l.pageBox;return g?(n.style.setProperty("--we-page-w",`${g.width}px`),n.style.setProperty("--we-page-h",`${g.height}px`),n.style.setProperty("--we-page-radius","0px")):(n.style.removeProperty("--we-page-w"),n.style.removeProperty("--we-page-radius")),{iframe:h,overlay:y,tabLayer:p}}function Nw(n,l,s){const{iframe:o}=s;return{key:l,wrapper:n,iframe:o,overlay:s.overlay,tabLayer:s.tabLayer,get doc(){return o.contentDocument},setPageHeight(u){n.style.setProperty("--we-page-h",`${u}px`)}}}function Tw(n,l){const s=n.ownerDocument,o=new Map;for(const y of Array.from(n.querySelectorAll(`:scope > .${tc}`))){const g=y.dataset.frameKey;g!==void 0&&o.set(g,y)}const u=[],d=[],h=new Set;for(const y of l){let g=o.get(y.key);g||(g=s.createElement("div"),g.className=tc,g.dataset.frameKey=y.key);const x=Aw(g,y);u.push(g),h.add(y.key),d.push(Nw(g,y.key,x))}let p=null;for(let y=u.length-1;y>=0;y--){const g=u[y];g&&((g.parentNode!==n||Cw(g)!==p)&&n.insertBefore(g,p),p=g)}return o.forEach((y,g)=>{h.has(g)||y.remove()}),l.some(y=>(y.label??"")!=="")?n.style.setProperty("--we-frame-label-lane",`${kw}px`):n.style.removeProperty("--we-frame-label-lane"),d}function Ow(n,l,s){const o=[];for(const u of n){const d=u.doc;if(!d)continue;const h=l.resolveSelectionEls(d,s);h.length>0&&o.push({handle:u,els:h})}return o}function Rw(n,l){const s=n==null?void 0:n.querySelector(":scope > .we-guide");if(s){if(l===null){s.removeAttribute("data-active");return}s.style.setProperty("--we-g-bleed",`${l}px`),s.setAttribute("data-active","true")}}const zw=24;function Dw(n,l,s,o){if(n.height+2*o<=l)return n.top>=o&&n.bottom<=l-o?null:n.top<o?Math.max(0,s+n.top-o):Math.max(0,s+n.bottom-(l-o));const d=Math.max(0,s+n.top-o);return Math.abs(d-s)<1?null:d}function Uw(n,l,s,o){const u=l+n.top*s-o,d=n.height*s;return{top:u,bottom:u+d,height:d}}const Vg="__trEditorBridge",Lw=1,O0=new WeakMap;function Bw(n){return n?n.kind==="section"?{kind:"section",instanceId:n.instance_id}:{kind:"slot",instanceId:n.instance_id,slotId:n.slot_id,...n.item_index!==void 0?{itemIndex:n.item_index}:{},...n.field_name!==void 0?{fieldName:n.field_name}:{}}:null}function Hw(n){const l=n[Vg];if(l)return l;const s=new Set,o={protocol:Lw,selection:null,subscribe(u){return s.add(u),()=>{s.delete(u)}}};return O0.set(o,s),n[Vg]=o,o}function qw(n,l,s){if(!n||!l)return;const u=Hw(n);u.selection=Bw(s);for(const d of[...O0.get(u)??[]])d()}function R0(n){var l,s,o="";if(typeof n=="string"||typeof n=="number")o+=n;else if(typeof n=="object")if(Array.isArray(n)){var u=n.length;for(l=0;l<u;l++)n[l]&&(s=R0(n[l]))&&(o&&(o+=" "),o+=s)}else for(s in n)n[s]&&(o&&(o+=" "),o+=s);return o}function Vf(){for(var n,l,s=0,o="",u=arguments.length;s<u;s++)(n=arguments[s])&&(l=R0(n))&&(o&&(o+=" "),o+=l);return o}const Gw=(n,l)=>{const s=new Array(n.length+l.length);for(let o=0;o<n.length;o++)s[o]=n[o];for(let o=0;o<l.length;o++)s[n.length+o]=l[o];return s},Iw=(n,l)=>({classGroupId:n,validator:l}),z0=(n=new Map,l=null,s)=>({nextPart:n,validators:l,classGroupId:s}),nc="-",Yg=[],Qw="arbitrary..",Kw=n=>{const l=Yw(n),{conflictingClassGroups:s,conflictingClassGroupModifiers:o}=n;return{getClassGroupId:h=>{if(h.startsWith("[")&&h.endsWith("]"))return Vw(h);const p=h.split(nc),y=p[0]===""&&p.length>1?1:0;return D0(p,y,l)},getConflictingClassGroupIds:(h,p)=>{if(p){const y=o[h],g=s[h];return y?g?Gw(g,y):y:g||Yg}return s[h]||Yg}}},D0=(n,l,s)=>{if(n.length-l===0)return s.classGroupId;const u=n[l],d=s.nextPart.get(u);if(d){const g=D0(n,l+1,d);if(g)return g}const h=s.validators;if(h===null)return;const p=l===0?n.join(nc):n.slice(l).join(nc),y=h.length;for(let g=0;g<y;g++){const x=h[g];if(x.validator(p))return x.classGroupId}},Vw=n=>n.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const l=n.slice(1,-1),s=l.indexOf(":"),o=l.slice(0,s);return o?Qw+o:void 0})(),Yw=n=>{const{theme:l,classGroups:s}=n;return $w(s,l)},$w=(n,l)=>{const s=z0();for(const o in n){const u=n[o];Yf(u,s,o,l)}return s},Yf=(n,l,s,o)=>{const u=n.length;for(let d=0;d<u;d++){const h=n[d];Fw(h,l,s,o)}},Fw=(n,l,s,o)=>{if(typeof n=="string"){Xw(n,l,s);return}if(typeof n=="function"){Zw(n,l,s,o);return}Pw(n,l,s,o)},Xw=(n,l,s)=>{const o=n===""?l:U0(l,n);o.classGroupId=s},Zw=(n,l,s,o)=>{if(Jw(n)){Yf(n(o),l,s,o);return}l.validators===null&&(l.validators=[]),l.validators.push(Iw(s,n))},Pw=(n,l,s,o)=>{const u=Object.entries(n),d=u.length;for(let h=0;h<d;h++){const[p,y]=u[h];Yf(y,U0(l,p),s,o)}},U0=(n,l)=>{let s=n;const o=l.split(nc),u=o.length;for(let d=0;d<u;d++){const h=o[d];let p=s.nextPart.get(h);p||(p=z0(),s.nextPart.set(h,p)),s=p}return s},Jw=n=>"isThemeGetter"in n&&n.isThemeGetter===!0,Ww=n=>{if(n<1)return{get:()=>{},set:()=>{}};let l=0,s=Object.create(null),o=Object.create(null);const u=(d,h)=>{s[d]=h,l++,l>n&&(l=0,o=s,s=Object.create(null))};return{get(d){let h=s[d];if(h!==void 0)return h;if((h=o[d])!==void 0)return u(d,h),h},set(d,h){d in s?s[d]=h:u(d,h)}}},nf="!",$g=":",eS=[],Fg=(n,l,s,o,u)=>({modifiers:n,hasImportantModifier:l,baseClassName:s,maybePostfixModifierPosition:o,isExternal:u}),tS=n=>{const{prefix:l,experimentalParseClassName:s}=n;let o=u=>{const d=[];let h=0,p=0,y=0,g;const x=u.length;for(let A=0;A<x;A++){const j=u[A];if(h===0&&p===0){if(j===$g){d.push(u.slice(y,A)),y=A+1;continue}if(j==="/"){g=A;continue}}j==="["?h++:j==="]"?h--:j==="("?p++:j===")"&&p--}const v=d.length===0?u:u.slice(y);let E=v,M=!1;v.endsWith(nf)?(E=v.slice(0,-1),M=!0):v.startsWith(nf)&&(E=v.slice(1),M=!0);const N=g&&g>y?g-y:void 0;return Fg(d,M,E,N)};if(l){const u=l+$g,d=o;o=h=>h.startsWith(u)?d(h.slice(u.length)):Fg(eS,!1,h,void 0,!0)}if(s){const u=o;o=d=>s({className:d,parseClassName:u})}return o},nS=n=>{const l=new Map;return n.orderSensitiveModifiers.forEach((s,o)=>{l.set(s,1e6+o)}),s=>{const o=[];let u=[];for(let d=0;d<s.length;d++){const h=s[d],p=h[0]==="[",y=l.has(h);p||y?(u.length>0&&(u.sort(),o.push(...u),u=[]),o.push(h)):u.push(h)}return u.length>0&&(u.sort(),o.push(...u)),o}},aS=n=>({cache:Ww(n.cacheSize),parseClassName:tS(n),sortModifiers:nS(n),postfixLookupClassGroupIds:lS(n),...Kw(n)}),lS=n=>{const l=Object.create(null),s=n.postfixLookupClassGroups;if(s)for(let o=0;o<s.length;o++)l[s[o]]=!0;return l},iS=/\s+/,sS=(n,l)=>{const{parseClassName:s,getClassGroupId:o,getConflictingClassGroupIds:u,sortModifiers:d,postfixLookupClassGroupIds:h}=l,p=[],y=n.trim().split(iS);let g="";for(let x=y.length-1;x>=0;x-=1){const v=y[x],{isExternal:E,modifiers:M,hasImportantModifier:N,baseClassName:A,maybePostfixModifierPosition:j}=s(v);if(E){g=v+(g.length>0?" "+g:g);continue}let O=!!j,z;if(O){const ae=A.substring(0,j);z=o(ae);const U=z&&h[z]?o(A):void 0;U&&U!==z&&(z=U,O=!1)}else z=o(A);if(!z){if(!O){g=v+(g.length>0?" "+g:g);continue}if(z=o(A),!z){g=v+(g.length>0?" "+g:g);continue}O=!1}const D=M.length===0?"":M.length===1?M[0]:d(M).join(":"),Y=N?D+nf:D,W=Y+z;if(p.indexOf(W)>-1)continue;p.push(W);const ee=u(z,O);for(let ae=0;ae<ee.length;++ae){const U=ee[ae];p.push(Y+U)}g=v+(g.length>0?" "+g:g)}return g},oS=(...n)=>{let l=0,s,o,u="";for(;l<n.length;)(s=n[l++])&&(o=L0(s))&&(u&&(u+=" "),u+=o);return u},L0=n=>{if(typeof n=="string")return n;let l,s="";for(let o=0;o<n.length;o++)n[o]&&(l=L0(n[o]))&&(s&&(s+=" "),s+=l);return s},rS=(n,...l)=>{let s,o,u,d;const h=y=>{const g=l.reduce((x,v)=>v(x),n());return s=aS(g),o=s.cache.get,u=s.cache.set,d=p,p(y)},p=y=>{const g=o(y);if(g)return g;const x=sS(y,s);return u(y,x),x};return d=h,(...y)=>d(oS(...y))},cS=[],St=n=>{const l=s=>s[n]||cS;return l.isThemeGetter=!0,l},B0=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,H0=/^\((?:(\w[\w-]*):)?(.+)\)$/i,uS=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,dS=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,fS=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,hS=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,pS=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,mS=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,$a=n=>uS.test(n),Le=n=>!!n&&!Number.isNaN(Number(n)),Ln=n=>!!n&&Number.isInteger(Number(n)),Hd=n=>n.endsWith("%")&&Le(n.slice(0,-1)),ua=n=>dS.test(n),q0=()=>!0,yS=n=>fS.test(n)&&!hS.test(n),$f=()=>!1,gS=n=>pS.test(n),bS=n=>mS.test(n),vS=n=>!ve(n)&&!xe(n),xS=n=>n.startsWith("@container")&&(n[10]==="/"&&n[11]!==void 0||n[11]==="s"&&n[16]!==void 0&&n.startsWith("-size/",10)||n[11]==="n"&&n[18]!==void 0&&n.startsWith("-normal/",10)),_S=n=>rl(n,Q0,$f),ve=n=>B0.test(n),Ol=n=>rl(n,K0,yS),Xg=n=>rl(n,AS,Le),wS=n=>rl(n,Y0,q0),SS=n=>rl(n,V0,$f),Zg=n=>rl(n,G0,$f),kS=n=>rl(n,I0,bS),Kr=n=>rl(n,$0,gS),xe=n=>H0.test(n),ao=n=>Jl(n,K0),ES=n=>Jl(n,V0),Pg=n=>Jl(n,G0),jS=n=>Jl(n,Q0),MS=n=>Jl(n,I0),Vr=n=>Jl(n,$0,!0),CS=n=>Jl(n,Y0,!0),rl=(n,l,s)=>{const o=B0.exec(n);return o?o[1]?l(o[1]):s(o[2]):!1},Jl=(n,l,s=!1)=>{const o=H0.exec(n);return o?o[1]?l(o[1]):s:!1},G0=n=>n==="position"||n==="percentage",I0=n=>n==="image"||n==="url",Q0=n=>n==="length"||n==="size"||n==="bg-size",K0=n=>n==="length",AS=n=>n==="number",V0=n=>n==="family-name",Y0=n=>n==="number"||n==="weight",$0=n=>n==="shadow",NS=()=>{const n=St("color"),l=St("font"),s=St("text"),o=St("font-weight"),u=St("tracking"),d=St("leading"),h=St("breakpoint"),p=St("container"),y=St("spacing"),g=St("radius"),x=St("shadow"),v=St("inset-shadow"),E=St("text-shadow"),M=St("drop-shadow"),N=St("blur"),A=St("perspective"),j=St("aspect"),O=St("ease"),z=St("animate"),D=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Y=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],W=()=>[...Y(),xe,ve],ee=()=>["auto","hidden","clip","visible","scroll"],ae=()=>["auto","contain","none"],U=()=>[xe,ve,y],re=()=>[$a,"full","auto",...U()],de=()=>[Ln,"none","subgrid",xe,ve],ce=()=>["auto",{span:["full",Ln,xe,ve]},Ln,xe,ve],ie=()=>[Ln,"auto",xe,ve],L=()=>["auto","min","max","fr",xe,ve],G=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],F=()=>["start","end","center","stretch","center-safe","end-safe"],w=()=>["auto",...U()],Z=()=>[$a,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...U()],ue=()=>[$a,"screen","full","dvw","lvw","svw","min","max","fit",...U()],te=()=>[$a,"screen","full","lh","dvh","lvh","svh","min","max","fit",...U()],P=()=>[n,xe,ve],k=()=>[...Y(),Pg,Zg,{position:[xe,ve]}],I=()=>["no-repeat",{repeat:["","x","y","space","round"]}],$=()=>["auto","cover","contain",jS,_S,{size:[xe,ve]}],T=()=>[Hd,ao,Ol],B=()=>["","none","full",g,xe,ve],q=()=>["",Le,ao,Ol],V=()=>["solid","dashed","dotted","double"],me=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],he=()=>[Le,Hd,Pg,Zg],ke=()=>["","none",N,xe,ve],Ae=()=>["none",Le,xe,ve],Ue=()=>["none",Le,xe,ve],nt=()=>[Le,xe,ve],Ve=()=>[$a,"full",...U()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[ua],breakpoint:[ua],color:[q0],container:[ua],"drop-shadow":[ua],ease:["in","out","in-out"],font:[vS],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[ua],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[ua],shadow:[ua],spacing:["px",Le],text:[ua],"text-shadow":[ua],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",$a,ve,xe,j]}],container:["container"],"container-type":[{"@container":["","normal","size",xe,ve]}],"container-named":[xS],columns:[{columns:[Le,ve,xe,p]}],"break-after":[{"break-after":D()}],"break-before":[{"break-before":D()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:W()}],overflow:[{overflow:ee()}],"overflow-x":[{"overflow-x":ee()}],"overflow-y":[{"overflow-y":ee()}],overscroll:[{overscroll:ae()}],"overscroll-x":[{"overscroll-x":ae()}],"overscroll-y":[{"overscroll-y":ae()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:re()}],"inset-x":[{"inset-x":re()}],"inset-y":[{"inset-y":re()}],start:[{"inset-s":re(),start:re()}],end:[{"inset-e":re(),end:re()}],"inset-bs":[{"inset-bs":re()}],"inset-be":[{"inset-be":re()}],top:[{top:re()}],right:[{right:re()}],bottom:[{bottom:re()}],left:[{left:re()}],visibility:["visible","invisible","collapse"],z:[{z:[Ln,"auto",xe,ve]}],basis:[{basis:[$a,"full","auto",p,...U()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Le,$a,"auto","initial","none",ve]}],grow:[{grow:["",Le,xe,ve]}],shrink:[{shrink:["",Le,xe,ve]}],order:[{order:[Ln,"first","last","none",xe,ve]}],"grid-cols":[{"grid-cols":de()}],"col-start-end":[{col:ce()}],"col-start":[{"col-start":ie()}],"col-end":[{"col-end":ie()}],"grid-rows":[{"grid-rows":de()}],"row-start-end":[{row:ce()}],"row-start":[{"row-start":ie()}],"row-end":[{"row-end":ie()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":L()}],"auto-rows":[{"auto-rows":L()}],gap:[{gap:U()}],"gap-x":[{"gap-x":U()}],"gap-y":[{"gap-y":U()}],"justify-content":[{justify:[...G(),"normal"]}],"justify-items":[{"justify-items":[...F(),"normal"]}],"justify-self":[{"justify-self":["auto",...F()]}],"align-content":[{content:["normal",...G()]}],"align-items":[{items:[...F(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...F(),{baseline:["","last"]}]}],"place-content":[{"place-content":G()}],"place-items":[{"place-items":[...F(),"baseline"]}],"place-self":[{"place-self":["auto",...F()]}],p:[{p:U()}],px:[{px:U()}],py:[{py:U()}],ps:[{ps:U()}],pe:[{pe:U()}],pbs:[{pbs:U()}],pbe:[{pbe:U()}],pt:[{pt:U()}],pr:[{pr:U()}],pb:[{pb:U()}],pl:[{pl:U()}],m:[{m:w()}],mx:[{mx:w()}],my:[{my:w()}],ms:[{ms:w()}],me:[{me:w()}],mbs:[{mbs:w()}],mbe:[{mbe:w()}],mt:[{mt:w()}],mr:[{mr:w()}],mb:[{mb:w()}],ml:[{ml:w()}],"space-x":[{"space-x":U()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":U()}],"space-y-reverse":["space-y-reverse"],size:[{size:Z()}],"inline-size":[{inline:["auto",...ue()]}],"min-inline-size":[{"min-inline":["auto",...ue()]}],"max-inline-size":[{"max-inline":["none",...ue()]}],"block-size":[{block:["auto",...te()]}],"min-block-size":[{"min-block":["auto",...te()]}],"max-block-size":[{"max-block":["none",...te()]}],w:[{w:[p,"screen",...Z()]}],"min-w":[{"min-w":[p,"screen","none",...Z()]}],"max-w":[{"max-w":[p,"screen","none","prose",{screen:[h]},...Z()]}],h:[{h:["screen","lh",...Z()]}],"min-h":[{"min-h":["screen","lh","none",...Z()]}],"max-h":[{"max-h":["screen","lh",...Z()]}],"font-size":[{text:["base",s,ao,Ol]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[o,CS,wS]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Hd,ve]}],"font-family":[{font:[ES,SS,l]}],"font-features":[{"font-features":[ve]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[u,xe,ve]}],"line-clamp":[{"line-clamp":[Le,"none",xe,Xg]}],leading:[{leading:[d,...U()]}],"list-image":[{"list-image":["none",xe,ve]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",xe,ve]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:P()}],"text-color":[{text:P()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...V(),"wavy"]}],"text-decoration-thickness":[{decoration:[Le,"from-font","auto",xe,Ol]}],"text-decoration-color":[{decoration:P()}],"underline-offset":[{"underline-offset":[Le,"auto",xe,ve]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:U()}],"tab-size":[{tab:[Ln,xe,ve]}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",xe,ve]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",xe,ve]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:k()}],"bg-repeat":[{bg:I()}],"bg-size":[{bg:$()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ln,xe,ve],radial:["",xe,ve],conic:[Ln,xe,ve]},MS,kS]}],"bg-color":[{bg:P()}],"gradient-from-pos":[{from:T()}],"gradient-via-pos":[{via:T()}],"gradient-to-pos":[{to:T()}],"gradient-from":[{from:P()}],"gradient-via":[{via:P()}],"gradient-to":[{to:P()}],rounded:[{rounded:B()}],"rounded-s":[{"rounded-s":B()}],"rounded-e":[{"rounded-e":B()}],"rounded-t":[{"rounded-t":B()}],"rounded-r":[{"rounded-r":B()}],"rounded-b":[{"rounded-b":B()}],"rounded-l":[{"rounded-l":B()}],"rounded-ss":[{"rounded-ss":B()}],"rounded-se":[{"rounded-se":B()}],"rounded-ee":[{"rounded-ee":B()}],"rounded-es":[{"rounded-es":B()}],"rounded-tl":[{"rounded-tl":B()}],"rounded-tr":[{"rounded-tr":B()}],"rounded-br":[{"rounded-br":B()}],"rounded-bl":[{"rounded-bl":B()}],"border-w":[{border:q()}],"border-w-x":[{"border-x":q()}],"border-w-y":[{"border-y":q()}],"border-w-s":[{"border-s":q()}],"border-w-e":[{"border-e":q()}],"border-w-bs":[{"border-bs":q()}],"border-w-be":[{"border-be":q()}],"border-w-t":[{"border-t":q()}],"border-w-r":[{"border-r":q()}],"border-w-b":[{"border-b":q()}],"border-w-l":[{"border-l":q()}],"divide-x":[{"divide-x":q()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":q()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...V(),"hidden","none"]}],"divide-style":[{divide:[...V(),"hidden","none"]}],"border-color":[{border:P()}],"border-color-x":[{"border-x":P()}],"border-color-y":[{"border-y":P()}],"border-color-s":[{"border-s":P()}],"border-color-e":[{"border-e":P()}],"border-color-bs":[{"border-bs":P()}],"border-color-be":[{"border-be":P()}],"border-color-t":[{"border-t":P()}],"border-color-r":[{"border-r":P()}],"border-color-b":[{"border-b":P()}],"border-color-l":[{"border-l":P()}],"divide-color":[{divide:P()}],"outline-style":[{outline:[...V(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Le,xe,ve]}],"outline-w":[{outline:["",Le,ao,Ol]}],"outline-color":[{outline:P()}],shadow:[{shadow:["","none",x,Vr,Kr]}],"shadow-color":[{shadow:P()}],"inset-shadow":[{"inset-shadow":["none",v,Vr,Kr]}],"inset-shadow-color":[{"inset-shadow":P()}],"ring-w":[{ring:q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:P()}],"ring-offset-w":[{"ring-offset":[Le,Ol]}],"ring-offset-color":[{"ring-offset":P()}],"inset-ring-w":[{"inset-ring":q()}],"inset-ring-color":[{"inset-ring":P()}],"text-shadow":[{"text-shadow":["none",E,Vr,Kr]}],"text-shadow-color":[{"text-shadow":P()}],opacity:[{opacity:[Le,xe,ve]}],"mix-blend":[{"mix-blend":[...me(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":me()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[Le]}],"mask-image-linear-from-pos":[{"mask-linear-from":he()}],"mask-image-linear-to-pos":[{"mask-linear-to":he()}],"mask-image-linear-from-color":[{"mask-linear-from":P()}],"mask-image-linear-to-color":[{"mask-linear-to":P()}],"mask-image-t-from-pos":[{"mask-t-from":he()}],"mask-image-t-to-pos":[{"mask-t-to":he()}],"mask-image-t-from-color":[{"mask-t-from":P()}],"mask-image-t-to-color":[{"mask-t-to":P()}],"mask-image-r-from-pos":[{"mask-r-from":he()}],"mask-image-r-to-pos":[{"mask-r-to":he()}],"mask-image-r-from-color":[{"mask-r-from":P()}],"mask-image-r-to-color":[{"mask-r-to":P()}],"mask-image-b-from-pos":[{"mask-b-from":he()}],"mask-image-b-to-pos":[{"mask-b-to":he()}],"mask-image-b-from-color":[{"mask-b-from":P()}],"mask-image-b-to-color":[{"mask-b-to":P()}],"mask-image-l-from-pos":[{"mask-l-from":he()}],"mask-image-l-to-pos":[{"mask-l-to":he()}],"mask-image-l-from-color":[{"mask-l-from":P()}],"mask-image-l-to-color":[{"mask-l-to":P()}],"mask-image-x-from-pos":[{"mask-x-from":he()}],"mask-image-x-to-pos":[{"mask-x-to":he()}],"mask-image-x-from-color":[{"mask-x-from":P()}],"mask-image-x-to-color":[{"mask-x-to":P()}],"mask-image-y-from-pos":[{"mask-y-from":he()}],"mask-image-y-to-pos":[{"mask-y-to":he()}],"mask-image-y-from-color":[{"mask-y-from":P()}],"mask-image-y-to-color":[{"mask-y-to":P()}],"mask-image-radial":[{"mask-radial":[xe,ve]}],"mask-image-radial-from-pos":[{"mask-radial-from":he()}],"mask-image-radial-to-pos":[{"mask-radial-to":he()}],"mask-image-radial-from-color":[{"mask-radial-from":P()}],"mask-image-radial-to-color":[{"mask-radial-to":P()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":Y()}],"mask-image-conic-pos":[{"mask-conic":[Le]}],"mask-image-conic-from-pos":[{"mask-conic-from":he()}],"mask-image-conic-to-pos":[{"mask-conic-to":he()}],"mask-image-conic-from-color":[{"mask-conic-from":P()}],"mask-image-conic-to-color":[{"mask-conic-to":P()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:k()}],"mask-repeat":[{mask:I()}],"mask-size":[{mask:$()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",xe,ve]}],filter:[{filter:["","none",xe,ve]}],blur:[{blur:ke()}],brightness:[{brightness:[Le,xe,ve]}],contrast:[{contrast:[Le,xe,ve]}],"drop-shadow":[{"drop-shadow":["","none",M,Vr,Kr]}],"drop-shadow-color":[{"drop-shadow":P()}],grayscale:[{grayscale:["",Le,xe,ve]}],"hue-rotate":[{"hue-rotate":[Le,xe,ve]}],invert:[{invert:["",Le,xe,ve]}],saturate:[{saturate:[Le,xe,ve]}],sepia:[{sepia:["",Le,xe,ve]}],"backdrop-filter":[{"backdrop-filter":["","none",xe,ve]}],"backdrop-blur":[{"backdrop-blur":ke()}],"backdrop-brightness":[{"backdrop-brightness":[Le,xe,ve]}],"backdrop-contrast":[{"backdrop-contrast":[Le,xe,ve]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Le,xe,ve]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Le,xe,ve]}],"backdrop-invert":[{"backdrop-invert":["",Le,xe,ve]}],"backdrop-opacity":[{"backdrop-opacity":[Le,xe,ve]}],"backdrop-saturate":[{"backdrop-saturate":[Le,xe,ve]}],"backdrop-sepia":[{"backdrop-sepia":["",Le,xe,ve]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":U()}],"border-spacing-x":[{"border-spacing-x":U()}],"border-spacing-y":[{"border-spacing-y":U()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",xe,ve]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Le,"initial",xe,ve]}],ease:[{ease:["linear","initial",O,xe,ve]}],delay:[{delay:[Le,xe,ve]}],animate:[{animate:["none",z,xe,ve]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[A,xe,ve]}],"perspective-origin":[{"perspective-origin":W()}],rotate:[{rotate:Ae()}],"rotate-x":[{"rotate-x":Ae()}],"rotate-y":[{"rotate-y":Ae()}],"rotate-z":[{"rotate-z":Ae()}],scale:[{scale:Ue()}],"scale-x":[{"scale-x":Ue()}],"scale-y":[{"scale-y":Ue()}],"scale-z":[{"scale-z":Ue()}],"scale-3d":["scale-3d"],skew:[{skew:nt()}],"skew-x":[{"skew-x":nt()}],"skew-y":[{"skew-y":nt()}],transform:[{transform:[xe,ve,"","none","gpu","cpu"]}],"transform-origin":[{origin:W()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Ve()}],"translate-x":[{"translate-x":Ve()}],"translate-y":[{"translate-y":Ve()}],"translate-z":[{"translate-z":Ve()}],"translate-none":["translate-none"],zoom:[{zoom:[Ln,xe,ve]}],accent:[{accent:P()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:P()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",xe,ve]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scrollbar-thumb-color":[{"scrollbar-thumb":P()}],"scrollbar-track-color":[{"scrollbar-track":P()}],"scrollbar-gutter":[{"scrollbar-gutter":["auto","stable","both"]}],"scrollbar-w":[{scrollbar:["auto","thin","none"]}],"scroll-m":[{"scroll-m":U()}],"scroll-mx":[{"scroll-mx":U()}],"scroll-my":[{"scroll-my":U()}],"scroll-ms":[{"scroll-ms":U()}],"scroll-me":[{"scroll-me":U()}],"scroll-mbs":[{"scroll-mbs":U()}],"scroll-mbe":[{"scroll-mbe":U()}],"scroll-mt":[{"scroll-mt":U()}],"scroll-mr":[{"scroll-mr":U()}],"scroll-mb":[{"scroll-mb":U()}],"scroll-ml":[{"scroll-ml":U()}],"scroll-p":[{"scroll-p":U()}],"scroll-px":[{"scroll-px":U()}],"scroll-py":[{"scroll-py":U()}],"scroll-ps":[{"scroll-ps":U()}],"scroll-pe":[{"scroll-pe":U()}],"scroll-pbs":[{"scroll-pbs":U()}],"scroll-pbe":[{"scroll-pbe":U()}],"scroll-pt":[{"scroll-pt":U()}],"scroll-pr":[{"scroll-pr":U()}],"scroll-pb":[{"scroll-pb":U()}],"scroll-pl":[{"scroll-pl":U()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",xe,ve]}],fill:[{fill:["none",...P()]}],"stroke-w":[{stroke:[Le,ao,Ol,Xg]}],stroke:[{stroke:["none",...P()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{"container-named":["container-type"],overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},postfixLookupClassGroups:["container-type"],orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},Ff=rS(NS);function ye(...n){return Ff(Vf(n))}const F0={property:{latitude:"lat",longitude:"lon"},contact:{address:"contact_address"}},TS={address:{role:"bindable",path:"address",container:"property",value_type:"text",input_group:"address",strength:"blocking",fields:{display:{value_type:"text"},street:{value_type:"text"},street_no_type:{value_type:"text"},city:{value_type:"text"},state:{value_type:"text"},postal:{value_type:"text"},unit:{value_type:"text"}}},address_street:{role:"bindable",path:"address.street",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_unit:{role:"bindable",path:"address.unit",container:"property",value_type:"text",input_group:"address",strength:"optional"},address_city:{role:"bindable",path:"address.city",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_state:{role:"bindable",path:"address.state",container:"property",value_type:"text",input_group:"address",strength:"blocking"},address_postal:{role:"bindable",path:"address.postal",container:"property",value_type:"text",input_group:"address",strength:"blocking"},listing_intent:{role:"bindable",path:"listing_intent",container:"property",value_type:"text",input_group:"intent",strength:"blocking",writeback:{kind:"property",column:"listing_intent"}},property_type:{role:"bindable",path:"property_type",container:"property",value_type:"text",input_group:"type",strength:"blocking"},lat:{role:"bindable",path:"lat",container:"property",value_type:"number",input_group:"address",strength:"blocking"},lon:{role:"bindable",path:"lon",container:"property",value_type:"number",input_group:"address",strength:"blocking"}},X0={units:{role:"bindable",path:"units",container:"property",value_type:"unit_list",input_group:"units",strength:"blocking",row:{unit_id:{path:"unit_id",value_type:"text"},position:{path:"position",value_type:"number"},floor_plans:{path:"floor_plans",value_type:"image_list",pool:"floor_plans",row:{id:{value_type:"text"},floor_label:{value_type:"text"},position:{value_type:"number"}}},unit_label:{path:"unit_label",value_type:"text",strength:"optional",writeback:{column:"unit_label"}},beds:{path:"beds",value_type:"number",strength:"blocking",writeback:{column:"beds"}},baths:{path:"baths",value_type:"number",strength:"blocking",writeback:{column:"baths"}},sqft:{path:"sqft",value_type:"number",strength:"blocking",writeback:{column:"sqft"}},price:{path:"price",value_type:"text",strength:"blocking",writeback:{column:"price"}}}},comparables:{role:"bindable",path:"comparables",container:"property",value_type:"comparable_list",input_group:"comparables",strength:"blocking",row:{id:{path:"id",value_type:"text"},address_street:{path:"address_street",value_type:"text",required:!0},address_city:{path:"address_city",value_type:"text"},address_state:{path:"address_state",value_type:"text"},address_postal:{path:"address_postal",value_type:"text"},address:{path:"address",value_type:"text"},lat:{path:"lat",value_type:"number",required:!0},lng:{path:"lng",value_type:"number",required:!0},distance_m:{path:"distance_m",value_type:"number"},status:{path:"status",value_type:"text"},price:{path:"price",value_type:"number",required:!0,writeback:{column:"price"}},price_period:{path:"price_period",value_type:"text"},sale_date:{path:"sale_date",value_type:"text",writeback:{column:"sale_date"}},beds:{path:"beds",value_type:"number",required:!0,writeback:{column:"beds"}},baths:{path:"baths",value_type:"number",required:!0,writeback:{column:"baths"}},sqft:{path:"sqft",value_type:"number",required:!0,writeback:{column:"sqft"}},photo:{path:"photo_upload_id",value_type:"image"},year_built:{path:"year_built",value_type:"number"},lot_sqft:{path:"lot_sqft",value_type:"number"},stories:{path:"stories",value_type:"number"},units:{path:"units",value_type:"number"},hoa_monthly:{path:"hoa_monthly",value_type:"number"},list_price:{path:"list_price",value_type:"number"},listed_date:{path:"listed_date",value_type:"text"},mls_number:{path:"mls_number",value_type:"text"},description:{path:"description",value_type:"text"},property_type:{path:"property_type",value_type:"text"}}},contacts:{role:"bindable",path:"contacts",container:"property",value_type:"contact_list",input_group:"contacts",strength:"blocking",row:{id:{path:"id",value_type:"text"},primary:{path:"primary",value_type:"boolean"},name:{path:"name",value_type:"text",strength:"optional",writeback:{column:"name"}},title:{path:"title",value_type:"text",strength:"optional",writeback:{column:"title"}},org_name:{path:"org_name",value_type:"text",strength:"optional",writeback:{column:"org_name"}},bio:{path:"bio",value_type:"text",strength:"optional",writeback:{column:"bio"}},address:{path:"address",value_type:"text",strength:"optional",writeback:{column:"address"}},email:{path:"email",value_type:"text",strength:"optional",writeback:{column:"email"}},phone:{path:"phone",value_type:"text",strength:"optional",writeback:{column:"phone"}},website:{path:"website_url",value_type:"text",strength:"optional",writeback:{column:"website"}},instagram:{path:"instagram_url",value_type:"text",strength:"optional",writeback:{column:"socials.instagram"}},linkedin:{path:"linkedin_url",value_type:"text",strength:"optional",writeback:{column:"socials.linkedin"}},x:{path:"x_url",value_type:"text",strength:"optional",writeback:{column:"socials.x"}},facebook:{path:"facebook_url",value_type:"text",strength:"optional",writeback:{column:"socials.facebook"}},headshot:{path:"avatar_upload_id",value_type:"image",strength:"optional",pool:"library"},logo_dark:{path:"logo_dark_upload_id",value_type:"image",strength:"optional",pool:"library"},logo_light:{path:"logo_light_upload_id",value_type:"image",strength:"optional",pool:"library"}}}},Xf={description:{role:"readable",path:"narrative.description",value_type:"text",input_group:"describe",strength:"optional"},photos:{role:"readable",path:"photos",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},tags:{value_type:"text_list"},caption:{value_type:"text"}}},videos:{role:"readable",path:"videos",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},source:{value_type:"text"},tags:{value_type:"text_list"},caption:{value_type:"text"},description:{value_type:"text"},duration_ms:{value_type:"number"},url:{value_type:"text"},provider:{value_type:"text"}}},tours:{role:"readable",path:"tours",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},url:{value_type:"text"},provider:{value_type:"text"}}},floor_plans:{role:"readable",path:"floor_plans",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},unit_assignments:{value_type:"row_list",row:{unit_label:{value_type:"text"},floor_label:{value_type:"text"},position:{value_type:"number"}}}}},documents:{role:"readable",path:"documents",value_type:"row_list",input_group:"uploads",strength:"optional",row:{id:{value_type:"text"},filename:{value_type:"text"},mime:{value_type:"text"},notes:{value_type:"text"}}},document_notes:{role:"readable",path:"document_notes",value_type:"row_list",input_group:"uploads",strength:"optional",row:{upload_id:{value_type:"text"},notes:{value_type:"text"}}},unit:{role:"readable",path:"units",value_type:"row",primary_of:"units"},contact:{role:"readable",path:"contacts",value_type:"row",primary_of:"contacts"}};function Jg(n){const l=X0[Xf[n].primary_of],s=F0[n]??{},o={};for(const[u,d]of Object.entries(l.row)){if(d.strength===void 0)continue;const h={role:"bindable",path:`${l.path}[].${d.path}`,container:n,value_type:d.value_type,input_group:l.input_group,strength:d.strength};d.value_type==="image"&&(h.image=!0),d.writeback!==void 0&&(h.writeback=n==="unit"?{kind:"unit",column:d.writeback.column}:{kind:"contact",field:d.writeback.column}),o[s[u]??u]=h}return o}function OS(){return{...TS,...Jg("unit"),...X0,...Jg("contact"),...Xf}}const Z0=OS(),P0={units:{idKey:"unit_id",ownership:"property"},contacts:{idKey:"id",cap:12,min:1,ownership:"library"},comparables:{idKey:"id",ownership:"property"}};function J0(n){var s;if(((s=n.source)==null?void 0:s.kind)!=="direct")return null;const l=n.source.field;return l!==void 0&&Object.hasOwn(P0,l)?l:null}function RS(n){for(const l of["unit","contact"])if(Xf[l].primary_of===n)return l;return null}function ac(n,l){const s=Z0[n].row;return Object.hasOwn(s,l)?s[l]??null:null}function Zf(n,l,s){const o=s.source;if(o===void 0)return ac(n,l)!==null?l:null;if(typeof o.field!="string")return null;if(o.kind==="row")return ac(n,o.field)!==null?o.field:null;if(o.kind!=="direct")return null;const u=RS(n);if(u===null)return null;const d=F0[u]??{},h=Z0[n].row;for(const[p,y]of Object.entries(h))if(y.strength!==void 0&&(d[p]??p)===o.field)return p;return null}const zS=["tour","video","social","listing","file","map"],Xl={matterport:{kind:"tour",label:"Matterport",pattern:/(^|\.)matterport\.com$/i,strategy:"api"},biganto:{kind:"tour",label:"Biganto",pattern:/(^|\.)biganto\.com$/i,strategy:"opengraph"},youtube:{kind:"video",label:"YouTube",pattern:/(^|\.)(youtube\.com|youtu\.be)$/i,strategy:"oembed"},vimeo:{kind:"video",label:"Vimeo",pattern:/(^|\.)vimeo\.com$/i,strategy:"oembed"},zillow:{kind:"listing",label:"Zillow",pattern:/(^|\.)zillow\.com$/i,strategy:"none"},redfin:{kind:"listing",label:"Redfin",pattern:/(^|\.)redfin\.com$/i,strategy:"none"},dropbox:{kind:"file",label:"Dropbox",pattern:/(^|\.)dropbox\.com$/i,strategy:"none"},drive:{kind:"file",label:"Google Drive",pattern:/^drive\.google\.com$/i,strategy:"none"},maps:{kind:"map",label:"Google Maps",pattern:/(^|\.)google\.com$/i,path:/^\/maps(\/|$)/i,strategy:"none"}};function W0(n){let l;try{l=new URL(n)}catch{return null}if(l.protocol!=="http:"&&l.protocol!=="https:")return null;for(const[s,o]of Object.entries(Xl))if(o.pattern.test(l.hostname)&&!(o.path&&!o.path.test(l.pathname)))return s;return null}function af(n,l){const s=W0(l);return s===null?!1:s===n?!0:zS.includes(n)&&Xl[s].kind===n}function DS(n,l,s){if(n!=="comparables")return!1;const o=Zf(n,l,s);if(o===null)return!1;const u=ac(n,o);return(u==null?void 0:u.value_type)==="image"&&u.pool===void 0}function ev(n){return n==="logo_dark"?{kind:"logo",variant:"dark"}:n==="logo_light"?{kind:"logo",variant:"light"}:n==="headshot"?{kind:"headshot"}:null}function tv(n){return(n==null?void 0:n.kind)!=="direct"?null:ev(n.field)}function US(n,l,s){return n==="contacts"?ev(Zf("contacts",l,s)):tv(s.source)}function LS(n){return n.kind==="headshot"?"headshot":n.variant==="dark"?"logo_dark":"logo_light"}function lf(n){if(typeof n!="object"||n===null)return null;const l=n,s=typeof l.photo_id=="string"&&l.photo_id.length>0?l.photo_id:null;return s||(typeof l.asset_id=="string"&&l.asset_id.length>0?l.asset_id:null)}/**
699
- * @license lucide-react v1.28.0 - ISC
700
- *
701
- * This source code is licensed under the ISC license.
702
- * See the LICENSE file in the root directory of this source tree.
703
- */const nv=(...n)=>n.filter((l,s,o)=>!!l&&l.trim()!==""&&o.indexOf(l)===s).join(" ").trim();/**
704
- * @license lucide-react v1.28.0 - ISC
705
- *
706
- * This source code is licensed under the ISC license.
707
- * See the LICENSE file in the root directory of this source tree.
708
- */const BS=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
709
- * @license lucide-react v1.28.0 - ISC
710
- *
711
- * This source code is licensed under the ISC license.
712
- * See the LICENSE file in the root directory of this source tree.
713
- */const HS=n=>n.replace(/^([A-Z])|[\s-_]+(\w)/g,(l,s,o)=>o?o.toUpperCase():s.toLowerCase());/**
714
- * @license lucide-react v1.28.0 - ISC
715
- *
716
- * This source code is licensed under the ISC license.
717
- * See the LICENSE file in the root directory of this source tree.
718
- */const Wg=n=>{const l=HS(n);return l.charAt(0).toUpperCase()+l.slice(1)};/**
719
- * @license lucide-react v1.28.0 - ISC
720
- *
721
- * This source code is licensed under the ISC license.
722
- * See the LICENSE file in the root directory of this source tree.
723
- */var qd={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
724
- * @license lucide-react v1.28.0 - ISC
725
- *
726
- * This source code is licensed under the ISC license.
727
- * See the LICENSE file in the root directory of this source tree.
728
- */const qS=n=>{for(const l in n)if(l.startsWith("aria-")||l==="role"||l==="title")return!0;return!1},GS=_.createContext({}),IS=()=>_.useContext(GS),QS=_.forwardRef(({color:n,size:l,strokeWidth:s,absoluteStrokeWidth:o,className:u="",children:d,iconNode:h,...p},y)=>{const{size:g=24,strokeWidth:x=2,absoluteStrokeWidth:v=!1,color:E="currentColor",className:M=""}=IS()??{},N=o??v?Number(s??x)*24/Number(l??g):s??x;return _.createElement("svg",{ref:y,...qd,width:l??g??qd.width,height:l??g??qd.height,stroke:n??E,strokeWidth:N,className:nv("lucide",M,u),...!d&&!qS(p)&&{"aria-hidden":"true"},...p},[...h.map(([A,j])=>_.createElement(A,j)),...Array.isArray(d)?d:[d]])});/**
729
- * @license lucide-react v1.28.0 - ISC
730
- *
731
- * This source code is licensed under the ISC license.
732
- * See the LICENSE file in the root directory of this source tree.
733
- */const ge=(n,l)=>{const s=_.forwardRef(({className:o,...u},d)=>_.createElement(QS,{ref:d,iconNode:l,className:nv(`lucide-${BS(Wg(n))}`,`lucide-${n}`,o),...u}));return s.displayName=Wg(n),s};/**
734
- * @license lucide-react v1.28.0 - ISC
735
- *
736
- * This source code is licensed under the ISC license.
737
- * See the LICENSE file in the root directory of this source tree.
738
- */const KS=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],VS=ge("activity",KS);/**
739
- * @license lucide-react v1.28.0 - ISC
740
- *
741
- * This source code is licensed under the ISC license.
742
- * See the LICENSE file in the root directory of this source tree.
743
- */const YS=[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]],$S=ge("archive",YS);/**
744
- * @license lucide-react v1.28.0 - ISC
745
- *
746
- * This source code is licensed under the ISC license.
747
- * See the LICENSE file in the root directory of this source tree.
748
- */const FS=[["path",{d:"M12 5v14",key:"s699le"}],["path",{d:"m19 12-7 7-7-7",key:"1idqje"}]],XS=ge("arrow-down",FS);/**
749
- * @license lucide-react v1.28.0 - ISC
750
- *
751
- * This source code is licensed under the ISC license.
752
- * See the LICENSE file in the root directory of this source tree.
753
- */const ZS=[["path",{d:"M8 3 4 7l4 4",key:"9rb6wj"}],["path",{d:"M4 7h16",key:"6tx8e3"}],["path",{d:"m16 21 4-4-4-4",key:"siv7j2"}],["path",{d:"M20 17H4",key:"h6l3hr"}]],PS=ge("arrow-left-right",ZS);/**
754
- * @license lucide-react v1.28.0 - ISC
755
- *
756
- * This source code is licensed under the ISC license.
757
- * See the LICENSE file in the root directory of this source tree.
758
- */const JS=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],WS=ge("arrow-left",JS);/**
759
- * @license lucide-react v1.28.0 - ISC
760
- *
761
- * This source code is licensed under the ISC license.
762
- * See the LICENSE file in the root directory of this source tree.
763
- */const ek=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]],tk=ge("arrow-right",ek);/**
764
- * @license lucide-react v1.28.0 - ISC
765
- *
766
- * This source code is licensed under the ISC license.
767
- * See the LICENSE file in the root directory of this source tree.
768
- */const nk=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],ak=ge("arrow-up",nk);/**
769
- * @license lucide-react v1.28.0 - ISC
770
- *
771
- * This source code is licensed under the ISC license.
772
- * See the LICENSE file in the root directory of this source tree.
773
- */const lk=[["path",{d:"M12 5v16",key:"1f6ucr"}],["path",{d:"M20.001 19A2 2 0 0022 17V5a2 2 0 00-1.999-2L16 3.002A5 5 0 0012 5a5 5 0 00-4-2H4a2 2 0 00-2 2v12a2 2 0 001.999 2H8a5 5 0 014 2 5 5 0 014-2z",key:"1fyvmf"}]],ik=ge("book-open",lk);/**
774
- * @license lucide-react v1.28.0 - ISC
775
- *
776
- * This source code is licensed under the ISC license.
777
- * See the LICENSE file in the root directory of this source tree.
778
- */const sk=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],Pf=ge("box",sk);/**
779
- * @license lucide-react v1.28.0 - ISC
780
- *
781
- * This source code is licensed under the ISC license.
782
- * See the LICENSE file in the root directory of this source tree.
783
- */const ok=[["path",{d:"M10 12h4",key:"a56b0p"}],["path",{d:"M10 8h4",key:"1sr2af"}],["path",{d:"M14 21v-3a2 2 0 0 0-4 0v3",key:"1rgiei"}],["path",{d:"M6 10H4a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-2",key:"secmi2"}],["path",{d:"M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16",key:"16ra0t"}]],rk=ge("building-2",ok);/**
784
- * @license lucide-react v1.28.0 - ISC
785
- *
786
- * This source code is licensed under the ISC license.
787
- * See the LICENSE file in the root directory of this source tree.
788
- */const ck=[["path",{d:"M8 2v3",key:"1ioesn"}],["path",{d:"M16 2v3",key:"otl347"}],["rect",{x:"3",y:"3",width:"18",height:"18",rx:"2",key:"h1oib"}],["path",{d:"M3 9h18",key:"1pudct"}]],uk=ge("calendar",ck);/**
789
- * @license lucide-react v1.28.0 - ISC
790
- *
791
- * This source code is licensed under the ISC license.
792
- * See the LICENSE file in the root directory of this source tree.
793
- */const dk=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],fk=ge("chart-line",dk);/**
794
- * @license lucide-react v1.28.0 - ISC
795
- *
796
- * This source code is licensed under the ISC license.
797
- * See the LICENSE file in the root directory of this source tree.
798
- */const hk=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],av=ge("check",hk);/**
799
- * @license lucide-react v1.28.0 - ISC
800
- *
801
- * This source code is licensed under the ISC license.
802
- * See the LICENSE file in the root directory of this source tree.
803
- */const pk=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],mk=ge("chevron-down",pk);/**
804
- * @license lucide-react v1.28.0 - ISC
805
- *
806
- * This source code is licensed under the ISC license.
807
- * See the LICENSE file in the root directory of this source tree.
808
- */const yk=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],gk=ge("chevron-right",yk);/**
809
- * @license lucide-react v1.28.0 - ISC
810
- *
811
- * This source code is licensed under the ISC license.
812
- * See the LICENSE file in the root directory of this source tree.
813
- */const bk=[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]],vk=ge("chevrons-up-down",bk);/**
814
- * @license lucide-react v1.28.0 - ISC
815
- *
816
- * This source code is licensed under the ISC license.
817
- * See the LICENSE file in the root directory of this source tree.
818
- */const xk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],_k=ge("circle-question-mark",xk);/**
819
- * @license lucide-react v1.28.0 - ISC
820
- *
821
- * This source code is licensed under the ISC license.
822
- * See the LICENSE file in the root directory of this source tree.
823
- */const wk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]],Sk=ge("clock",wk);/**
824
- * @license lucide-react v1.28.0 - ISC
825
- *
826
- * This source code is licensed under the ISC license.
827
- * See the LICENSE file in the root directory of this source tree.
828
- */const kk=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],Ek=ge("copy",kk);/**
829
- * @license lucide-react v1.28.0 - ISC
830
- *
831
- * This source code is licensed under the ISC license.
832
- * See the LICENSE file in the root directory of this source tree.
833
- */const jk=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],Mk=ge("credit-card",jk);/**
834
- * @license lucide-react v1.28.0 - ISC
835
- *
836
- * This source code is licensed under the ISC license.
837
- * See the LICENSE file in the root directory of this source tree.
838
- */const Ck=[["path",{d:"M6 2v14a2 2 0 0 0 2 2h14",key:"ron5a4"}],["path",{d:"M18 22V8a2 2 0 0 0-2-2H2",key:"7s9ehn"}]],Ak=ge("crop",Ck);/**
839
- * @license lucide-react v1.28.0 - ISC
840
- *
841
- * This source code is licensed under the ISC license.
842
- * See the LICENSE file in the root directory of this source tree.
843
- */const Nk=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],Tk=ge("download",Nk);/**
844
- * @license lucide-react v1.28.0 - ISC
845
- *
846
- * This source code is licensed under the ISC license.
847
- * See the LICENSE file in the root directory of this source tree.
848
- */const Ok=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],Rk=ge("ellipsis",Ok);/**
849
- * @license lucide-react v1.28.0 - ISC
850
- *
851
- * This source code is licensed under the ISC license.
852
- * See the LICENSE file in the root directory of this source tree.
853
- */const zk=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],lv=ge("external-link",zk);/**
854
- * @license lucide-react v1.28.0 - ISC
855
- *
856
- * This source code is licensed under the ISC license.
857
- * See the LICENSE file in the root directory of this source tree.
858
- */const Dk=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],iv=ge("eye-off",Dk);/**
859
- * @license lucide-react v1.28.0 - ISC
860
- *
861
- * This source code is licensed under the ISC license.
862
- * See the LICENSE file in the root directory of this source tree.
863
- */const Uk=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],sv=ge("eye",Uk);/**
864
- * @license lucide-react v1.28.0 - ISC
865
- *
866
- * This source code is licensed under the ISC license.
867
- * See the LICENSE file in the root directory of this source tree.
868
- */const Lk=[["path",{d:"M14.364 13.634a2 2 0 0 0-.506.854l-.837 2.87a.5.5 0 0 0 .62.62l2.87-.837a2 2 0 0 0 .854-.506l4.013-4.009a1 1 0 0 0-3.004-3.004z",key:"ukzhwg"}],["path",{d:"M14.487 7.858A1 1 0 0 1 14 7V2",key:"1klhew"}],["path",{d:"M20 19.645V20a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l2.516 2.516",key:"rxaxab"}],["path",{d:"M8 18h1",key:"13wk12"}]],Bk=ge("file-pen-line",Lk);/**
869
- * @license lucide-react v1.28.0 - ISC
870
- *
871
- * This source code is licensed under the ISC license.
872
- * See the LICENSE file in the root directory of this source tree.
873
- */const Hk=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M8 13h2",key:"yr2amv"}],["path",{d:"M14 13h2",key:"un5t4a"}],["path",{d:"M8 17h2",key:"2yhykz"}],["path",{d:"M14 17h2",key:"10kma7"}]],qk=ge("file-spreadsheet",Hk);/**
874
- * @license lucide-react v1.28.0 - ISC
875
- *
876
- * This source code is licensed under the ISC license.
877
- * See the LICENSE file in the root directory of this source tree.
878
- */const Gk=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],Jf=ge("file-text",Gk);/**
879
- * @license lucide-react v1.28.0 - ISC
880
- *
881
- * This source code is licensed under the ISC license.
882
- * See the LICENSE file in the root directory of this source tree.
883
- */const Ik=[["path",{d:"M15 2h-4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V8",key:"14sh0y"}],["path",{d:"M16.706 2.706A2.4 2.4 0 0 0 15 2v5a1 1 0 0 0 1 1h5a2.4 2.4 0 0 0-.706-1.706z",key:"1970lx"}],["path",{d:"M5 7a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h8a2 2 0 0 0 1.732-1",key:"l4dndm"}]],Qk=ge("files",Ik);/**
884
- * @license lucide-react v1.28.0 - ISC
885
- *
886
- * This source code is licensed under the ISC license.
887
- * See the LICENSE file in the root directory of this source tree.
888
- */const Kk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M3 7.5h4",key:"zfgn84"}],["path",{d:"M3 12h18",key:"1i2n21"}],["path",{d:"M3 16.5h4",key:"1230mu"}],["path",{d:"M17 3v18",key:"in4fa5"}],["path",{d:"M17 7.5h4",key:"myr1c1"}],["path",{d:"M17 16.5h4",key:"go4c1d"}]],Vk=ge("film",Kk);/**
889
- * @license lucide-react v1.28.0 - ISC
890
- *
891
- * This source code is licensed under the ISC license.
892
- * See the LICENSE file in the root directory of this source tree.
893
- */const Yk=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],$k=ge("globe",Yk);/**
894
- * @license lucide-react v1.28.0 - ISC
895
- *
896
- * This source code is licensed under the ISC license.
897
- * See the LICENSE file in the root directory of this source tree.
898
- */const Fk=[["circle",{cx:"9",cy:"12",r:"1",key:"1vctgf"}],["circle",{cx:"9",cy:"5",r:"1",key:"hp0tcf"}],["circle",{cx:"9",cy:"19",r:"1",key:"fkjjf6"}],["circle",{cx:"15",cy:"12",r:"1",key:"1tmaij"}],["circle",{cx:"15",cy:"5",r:"1",key:"19l28e"}],["circle",{cx:"15",cy:"19",r:"1",key:"f4zoj3"}]],ov=ge("grip-vertical",Fk);/**
899
- * @license lucide-react v1.28.0 - ISC
900
- *
901
- * This source code is licensed under the ISC license.
902
- * See the LICENSE file in the root directory of this source tree.
903
- */const Xk=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]],Zk=ge("house",Xk);/**
904
- * @license lucide-react v1.28.0 - ISC
905
- *
906
- * This source code is licensed under the ISC license.
907
- * See the LICENSE file in the root directory of this source tree.
908
- */const Pk=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]],Wf=ge("image",Pk);/**
909
- * @license lucide-react v1.28.0 - ISC
910
- *
911
- * This source code is licensed under the ISC license.
912
- * See the LICENSE file in the root directory of this source tree.
913
- */const Jk=[["path",{d:"m22 11-1.296-1.296a2.4 2.4 0 0 0-3.408 0L11 16",key:"9kzy35"}],["path",{d:"M4 8a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2",key:"1t0f0t"}],["circle",{cx:"13",cy:"7",r:"1",fill:"currentColor",key:"1obus6"}],["rect",{x:"8",y:"2",width:"14",height:"14",rx:"2",key:"1gvhby"}]],Wk=ge("images",Jk);/**
914
- * @license lucide-react v1.28.0 - ISC
915
- *
916
- * This source code is licensed under the ISC license.
917
- * See the LICENSE file in the root directory of this source tree.
918
- */const e5=[["rect",{width:"7",height:"7",x:"3",y:"3",rx:"1",key:"1g98yp"}],["rect",{width:"7",height:"7",x:"14",y:"3",rx:"1",key:"6d4xhi"}],["rect",{width:"7",height:"7",x:"14",y:"14",rx:"1",key:"nxv5o0"}],["rect",{width:"7",height:"7",x:"3",y:"14",rx:"1",key:"1bb6yr"}]],t5=ge("layout-grid",e5);/**
919
- * @license lucide-react v1.28.0 - ISC
920
- *
921
- * This source code is licensed under the ISC license.
922
- * See the LICENSE file in the root directory of this source tree.
923
- */const n5=[["rect",{width:"18",height:"7",x:"3",y:"3",rx:"1",key:"f1a2em"}],["rect",{width:"9",height:"7",x:"3",y:"14",rx:"1",key:"jqznyg"}],["rect",{width:"5",height:"7",x:"16",y:"14",rx:"1",key:"q5h2i8"}]],a5=ge("layout-template",n5);/**
924
- * @license lucide-react v1.28.0 - ISC
925
- *
926
- * This source code is licensed under the ISC license.
927
- * See the LICENSE file in the root directory of this source tree.
928
- */const l5=[["rect",{width:"8",height:"18",x:"3",y:"3",rx:"1",key:"oynpb5"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M20.4 18.9c.2.5-.1 1.1-.6 1.3l-1.9.7c-.5.2-1.1-.1-1.3-.6L11.1 5.1c-.2-.5.1-1.1.6-1.3l1.9-.7c.5-.2 1.1.1 1.3.6Z",key:"1qboyk"}]],i5=ge("library-big",l5);/**
929
- * @license lucide-react v1.28.0 - ISC
930
- *
931
- * This source code is licensed under the ISC license.
932
- * See the LICENSE file in the root directory of this source tree.
933
- */const s5=[["path",{d:"M9 17H7A5 5 0 0 1 7 7h2",key:"8i5ue5"}],["path",{d:"M15 7h2a5 5 0 1 1 0 10h-2",key:"1b9ql8"}],["line",{x1:"8",x2:"16",y1:"12",y2:"12",key:"1jonct"}]],o5=ge("link-2",s5);/**
934
- * @license lucide-react v1.28.0 - ISC
935
- *
936
- * This source code is licensed under the ISC license.
937
- * See the LICENSE file in the root directory of this source tree.
938
- */const r5=[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]],c5=ge("link",r5);/**
939
- * @license lucide-react v1.28.0 - ISC
940
- *
941
- * This source code is licensed under the ISC license.
942
- * See the LICENSE file in the root directory of this source tree.
943
- */const u5=[["path",{d:"M3 5h.01",key:"18ugdj"}],["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 19h.01",key:"noohij"}],["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 19h13",key:"m83p4d"}]],d5=ge("list",u5);/**
944
- * @license lucide-react v1.28.0 - ISC
945
- *
946
- * This source code is licensed under the ISC license.
947
- * See the LICENSE file in the root directory of this source tree.
948
- */const f5=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],h5=ge("lock",f5);/**
949
- * @license lucide-react v1.28.0 - ISC
950
- *
951
- * This source code is licensed under the ISC license.
952
- * See the LICENSE file in the root directory of this source tree.
953
- */const p5=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],m5=ge("log-out",p5);/**
954
- * @license lucide-react v1.28.0 - ISC
955
- *
956
- * This source code is licensed under the ISC license.
957
- * See the LICENSE file in the root directory of this source tree.
958
- */const y5=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],g5=ge("mail",y5);/**
959
- * @license lucide-react v1.28.0 - ISC
960
- *
961
- * This source code is licensed under the ISC license.
962
- * See the LICENSE file in the root directory of this source tree.
963
- */const b5=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],rv=ge("map-pin",b5);/**
964
- * @license lucide-react v1.28.0 - ISC
965
- *
966
- * This source code is licensed under the ISC license.
967
- * See the LICENSE file in the root directory of this source tree.
968
- */const v5=[["path",{d:"M18 8c0 3.613-3.869 7.429-5.393 8.795a1 1 0 0 1-1.214 0C9.87 15.429 6 11.613 6 8a6 6 0 0 1 12 0",key:"11u0oz"}],["circle",{cx:"12",cy:"8",r:"2",key:"1822b1"}],["path",{d:"M8.714 14h-3.71a1 1 0 0 0-.948.683l-2.004 6A1 1 0 0 0 3 22h18a1 1 0 0 0 .948-1.316l-2-6a1 1 0 0 0-.949-.684h-3.712",key:"q8zwxj"}]],x5=ge("map-pinned",v5);/**
969
- * @license lucide-react v1.28.0 - ISC
970
- *
971
- * This source code is licensed under the ISC license.
972
- * See the LICENSE file in the root directory of this source tree.
973
- */const _5=[["path",{d:"M5 12h14",key:"1ays0h"}]],w5=ge("minus",_5);/**
974
- * @license lucide-react v1.28.0 - ISC
975
- *
976
- * This source code is licensed under the ISC license.
977
- * See the LICENSE file in the root directory of this source tree.
978
- */const S5=[["path",{d:"M14 4.1 12 6",key:"ita8i4"}],["path",{d:"m5.1 8-2.9-.8",key:"1go3kf"}],["path",{d:"m6 12-1.9 2",key:"mnht97"}],["path",{d:"M7.2 2.2 8 5.1",key:"1cfko1"}],["path",{d:"M9.037 9.69a.498.498 0 0 1 .653-.653l11 4.5a.5.5 0 0 1-.074.949l-4.349 1.041a1 1 0 0 0-.74.739l-1.04 4.35a.5.5 0 0 1-.95.074z",key:"s0h3yz"}]],k5=ge("mouse-pointer-click",S5);/**
979
- * @license lucide-react v1.28.0 - ISC
980
- *
981
- * This source code is licensed under the ISC license.
982
- * See the LICENSE file in the root directory of this source tree.
983
- */const E5=[["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-4 0v-9a2 2 0 0 1 2-2h2",key:"39pd36"}],["rect",{width:"8",height:"4",x:"10",y:"6",rx:"1",key:"aywv1n"}]],j5=ge("newspaper",E5);/**
984
- * @license lucide-react v1.28.0 - ISC
985
- *
986
- * This source code is licensed under the ISC license.
987
- * See the LICENSE file in the root directory of this source tree.
988
- */const M5=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],C5=ge("palette",M5);/**
989
- * @license lucide-react v1.28.0 - ISC
990
- *
991
- * This source code is licensed under the ISC license.
992
- * See the LICENSE file in the root directory of this source tree.
993
- */const A5=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],N5=ge("pencil",A5);/**
994
- * @license lucide-react v1.28.0 - ISC
995
- *
996
- * This source code is licensed under the ISC license.
997
- * See the LICENSE file in the root directory of this source tree.
998
- */const T5=[["path",{d:"M13.832 16.568a1 1 0 0 0 1.213-.303l.355-.465A2 2 0 0 1 17 15h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2A18 18 0 0 1 2 4a2 2 0 0 1 2-2h3a2 2 0 0 1 2 2v3a2 2 0 0 1-.8 1.6l-.468.351a1 1 0 0 0-.292 1.233 14 14 0 0 0 6.392 6.384",key:"9njp5v"}]],O5=ge("phone",T5);/**
999
- * @license lucide-react v1.28.0 - ISC
1000
- *
1001
- * This source code is licensed under the ISC license.
1002
- * See the LICENSE file in the root directory of this source tree.
1003
- */const R5=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],z5=ge("play",R5);/**
1004
- * @license lucide-react v1.28.0 - ISC
1005
- *
1006
- * This source code is licensed under the ISC license.
1007
- * See the LICENSE file in the root directory of this source tree.
1008
- */const D5=[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z",key:"1xoxul"}],["path",{d:"M9 8V2",key:"14iosj"}]],U5=ge("plug",D5);/**
1009
- * @license lucide-react v1.28.0 - ISC
1010
- *
1011
- * This source code is licensed under the ISC license.
1012
- * See the LICENSE file in the root directory of this source tree.
1013
- */const L5=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],cv=ge("plus",L5);/**
1014
- * @license lucide-react v1.28.0 - ISC
1015
- *
1016
- * This source code is licensed under the ISC license.
1017
- * See the LICENSE file in the root directory of this source tree.
1018
- */const B5=[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]],H5=ge("power",B5);/**
1019
- * @license lucide-react v1.28.0 - ISC
1020
- *
1021
- * This source code is licensed under the ISC license.
1022
- * See the LICENSE file in the root directory of this source tree.
1023
- */const q5=[["path",{d:"M2 3h20",key:"91anmk"}],["path",{d:"M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3",key:"2k9sn8"}],["path",{d:"m7 21 5-5 5 5",key:"bip4we"}]],uv=ge("presentation",q5);/**
1024
- * @license lucide-react v1.28.0 - ISC
1025
- *
1026
- * This source code is licensed under the ISC license.
1027
- * See the LICENSE file in the root directory of this source tree.
1028
- */const G5=[["path",{d:"m15 14 5-5-5-5",key:"12vg1m"}],["path",{d:"M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13",key:"6uklza"}]],I5=ge("redo-2",G5);/**
1029
- * @license lucide-react v1.28.0 - ISC
1030
- *
1031
- * This source code is licensed under the ISC license.
1032
- * See the LICENSE file in the root directory of this source tree.
1033
- */const Q5=[["path",{d:"m15.194 13.707 3.814 1.86-1.86 3.814",key:"16shm9"}],["path",{d:"M16.47214 7.52786 A 5 10 0 1 0 13 21.79796",key:"1245p8"}],["path",{d:"M21.79796 11 A 10 5 0 1 0 19 15.57071",key:"1i40ks"}]],eh=ge("rotate-3d",Q5);/**
1034
- * @license lucide-react v1.28.0 - ISC
1035
- *
1036
- * This source code is licensed under the ISC license.
1037
- * See the LICENSE file in the root directory of this source tree.
1038
- */const K5=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],dv=ge("search",K5);/**
1039
- * @license lucide-react v1.28.0 - ISC
1040
- *
1041
- * This source code is licensed under the ISC license.
1042
- * See the LICENSE file in the root directory of this source tree.
1043
- */const V5=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],Y5=ge("settings",V5);/**
1044
- * @license lucide-react v1.28.0 - ISC
1045
- *
1046
- * This source code is licensed under the ISC license.
1047
- * See the LICENSE file in the root directory of this source tree.
1048
- */const $5=[["path",{d:"M12 2v13",key:"1km8f5"}],["path",{d:"m16 6-4-4-4 4",key:"13yo43"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}]],F5=ge("share",$5);/**
1049
- * @license lucide-react v1.28.0 - ISC
1050
- *
1051
- * This source code is licensed under the ISC license.
1052
- * See the LICENSE file in the root directory of this source tree.
1053
- */const X5=[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],Z5=ge("sparkles",X5);/**
1054
- * @license lucide-react v1.28.0 - ISC
1055
- *
1056
- * This source code is licensed under the ISC license.
1057
- * See the LICENSE file in the root directory of this source tree.
1058
- */const P5=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],fv=ge("trash-2",P5);/**
1059
- * @license lucide-react v1.28.0 - ISC
1060
- *
1061
- * This source code is licensed under the ISC license.
1062
- * See the LICENSE file in the root directory of this source tree.
1063
- */const J5=[["path",{d:"M12 4v16",key:"1654pz"}],["path",{d:"M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2",key:"e0r10z"}],["path",{d:"M9 20h6",key:"s66wpe"}]],W5=ge("type",J5);/**
1064
- * @license lucide-react v1.28.0 - ISC
1065
- *
1066
- * This source code is licensed under the ISC license.
1067
- * See the LICENSE file in the root directory of this source tree.
1068
- */const e4=[["path",{d:"M9 14 4 9l5-5",key:"102s5s"}],["path",{d:"M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11",key:"f3b9sd"}]],t4=ge("undo-2",e4);/**
1069
- * @license lucide-react v1.28.0 - ISC
1070
- *
1071
- * This source code is licensed under the ISC license.
1072
- * See the LICENSE file in the root directory of this source tree.
1073
- */const n4=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],hv=ge("upload",n4);/**
1074
- * @license lucide-react v1.28.0 - ISC
1075
- *
1076
- * This source code is licensed under the ISC license.
1077
- * See the LICENSE file in the root directory of this source tree.
1078
- */const a4=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],l4=ge("user-plus",a4);/**
1079
- * @license lucide-react v1.28.0 - ISC
1080
- *
1081
- * This source code is licensed under the ISC license.
1082
- * See the LICENSE file in the root directory of this source tree.
1083
- */const i4=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],s4=ge("user",i4);/**
1084
- * @license lucide-react v1.28.0 - ISC
1085
- *
1086
- * This source code is licensed under the ISC license.
1087
- * See the LICENSE file in the root directory of this source tree.
1088
- */const o4=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],r4=ge("users",o4);/**
1089
- * @license lucide-react v1.28.0 - ISC
1090
- *
1091
- * This source code is licensed under the ISC license.
1092
- * See the LICENSE file in the root directory of this source tree.
1093
- */const c4=[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]],pv=ge("video",c4);/**
1094
- * @license lucide-react v1.28.0 - ISC
1095
- *
1096
- * This source code is licensed under the ISC license.
1097
- * See the LICENSE file in the root directory of this source tree.
1098
- */const u4=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],mv=ge("x",u4),th="flex flex-col gap-3.5 pt-1",Qn="flex flex-col gap-1",d4="flex items-center justify-between gap-2.5",va="text-[length:calc(11*var(--content))] font-medium text-ink-4 pl-0.5",nh="m-0 text-caption leading-[1.4] text-danger",fc="bg-[repeating-linear-gradient(135deg,rgba(20,18,13,0.05)_0_1px,transparent_1px_9px)]",ot="appearance-none cursor-pointer border-0 bg-transparent p-0 m-0 outline-none",_o="flex w-full items-stretch rounded-[calc(8*var(--content))] border border-line bg-white transition-[border-color,box-shadow] duration-[120ms] focus-within:border-accent focus-within:shadow-[0_0_0_3px_rgba(15,42,34,0.07)]",ss="min-w-0 flex-1 appearance-none border-0 bg-transparent px-2.75 py-2.25 text-[length:calc(13.5*var(--content))] text-ink outline-none placeholder:text-ink-4",sf="flex items-center text-[length:calc(12.5*var(--content))] text-ink-4",f4=ye(ot,"min-w-0 flex-1 bg-transparent text-ink outline-none placeholder:text-ink-4");function wo(n,l="Item"){const s=(n??"").trim().split(/\s+/).filter(Boolean),o=s.length>0?s[s.length-1]:l,u=h4(o);return u.charAt(0).toUpperCase()+u.slice(1)}function h4(n){return/[^aeiou]ies$/i.test(n)?n.slice(0,-3)+"y":/(?:s|x|z|ch|sh)es$/i.test(n)?n.slice(0,-2):/[^s]s$/i.test(n)?n.slice(0,-1):n}function p4(n,l){const s="font-mono text-[length:calc(10.5*var(--content))] text-ink-4 [font-feature-settings:'tnum'] shrink-0";return l==null?s:n>l?ye(s,"text-danger"):n>=l*.9?ye(s,"text-[#7a5a14]"):s}function yv({label:n,count:l,max:s,right:o,revealed:u=!0}){return f.jsxs("div",{className:d4,children:[f.jsx("span",{className:va,children:n}),f.jsx("div",{className:"flex items-center gap-1.5",children:o??(s!=null&&l!=null&&f.jsxs("span",{"aria-hidden":!u,className:ye(p4(l,s),"transition-[opacity,transform] duration-150 ease-out motion-reduce:transition-none",u?"opacity-100 translate-y-0":"opacity-0 translate-y-1"),children:[l," / ",s]}))})]})}function ah({children:n}){return f.jsx("span",{className:va,children:n})}function Pr({value:n,onChange:l,label:s,max:o,count:u,headerRight:d,placeholder:h,multiline:p=!1,rows:y=3,inputMode:g,maxLength:x,spellCheck:v,bare:E=!1,className:M,ariaLabel:N,id:A}){const[j,O]=_.useState(!1),z=ee=>l(ee.target.value),D=()=>O(!0),Y=()=>O(!1);if(E)return f.jsx("input",{id:A,className:ye(f4,M),value:n,placeholder:h,inputMode:g,maxLength:x,spellCheck:v,"aria-label":N,onChange:z});const W=s!=null||d!=null||o!=null;return f.jsxs("div",{className:Qn,children:[W&&f.jsx(yv,{label:s??"",count:u??n.length,max:o,right:d,revealed:j}),f.jsx("div",{className:_o,children:p?f.jsx("textarea",{id:A,className:ye(ss,"min-h-[calc(76*var(--content))] resize-none leading-[1.5]",M),rows:y,value:n,placeholder:h,maxLength:x,spellCheck:v,"aria-label":N,onChange:z,onFocus:D,onBlur:Y}):f.jsx("input",{id:A,className:ye(ss,M),value:n,placeholder:h,inputMode:g,maxLength:x,spellCheck:v,"aria-label":N,onChange:z,onFocus:D,onBlur:Y})})]})}function It(n,l,s=1.5){const o=n;return function({size:d=l}={}){return f.jsx(o,{size:d,strokeWidth:s,style:{width:`calc(${d} * var(--content))`,height:`calc(${d} * var(--content))`}})}}const ze={swap:It(PS,13),crop:It(Ak,13),eye:It(sv,13),eyeOff:It(iv,13),trash:It(fv,11),plus:It(cv,14),up:It(hv,15),link:It(c5,13),play:({size:n=20}={})=>f.jsx(z5,{size:n,strokeWidth:0,fill:"currentColor",style:{width:`calc(${n} * var(--content))`,height:`calc(${n} * var(--content))`}}),tour:It(eh,18),search:It(dv,14),x:It(mv,15),check:It(av,13),minus:It(w5,16),external:It(lv,11),grip:It(ov,13,1.8)},m4="flex max-h-full w-full flex-col overflow-hidden rounded-[14px] bg-canvas shadow-[0_24px_70px_-24px_rgba(20,18,13,0.5),0_2px_0_rgba(20,18,13,0.04)]",gv="flex flex-shrink-0 items-center gap-[14px] border-b border-line-soft px-[18px] py-4",bv="mr-auto flex min-w-0 flex-col gap-0.5",vv="m-0 text-[16px] font-semibold tracking-[-0.01em]",y4="text-[12px] text-ink-3",xv=ye(ot,"grid size-8 flex-shrink-0 place-items-center rounded-[8px] text-ink-3 hover:bg-[#f1f0ea] hover:text-ink"),_v="flex flex-shrink-0 items-center justify-between gap-3 border-t border-line-soft px-[18px] py-[13px]",wv="ml-auto flex gap-2",Sv=ye(ot,"inline-flex h-9 items-center gap-1.5 rounded-[9px] border border-transparent px-4 text-[13px] font-semibold"),kv=ye(Sv,"border-line bg-white text-ink hover:bg-[#faf9f6]"),lh=ye(Sv,"border-honey-2 bg-honey text-honey-ink hover:bg-honey-2 disabled:cursor-default disabled:opacity-45"),g4=ye(ot,"inline-flex h-9 items-center px-1 font-medium text-ink-2 hover:text-ink"),eb="flex flex-shrink-0 gap-2.5 px-[18px] pb-3 pt-[14px]",tb="flex h-[38px] flex-1 items-center gap-2 rounded-[9px] border border-line bg-white px-3 transition-[border-color] duration-[120ms] focus-within:border-accent",nb="grid flex-shrink-0 place-items-center text-ink-3",ab="flex-1 border-0 bg-transparent text-[13.5px] text-ink",b4="min-h-0 flex-1 overflow-y-auto px-[18px] pb-[18px] pt-0.5",v4="grid grid-cols-4 gap-x-3 gap-y-[14px]",x4="col-span-full py-12 text-center text-[13px] text-ink-3",_4=ye(ot,"group/cell flex flex-col gap-1.5 text-left"),w4="flex h-[120px] items-center justify-center",S4="relative mx-auto w-fit max-w-full overflow-hidden rounded-[9px] border border-line transition-[box-shadow,border-color] duration-[120ms] group-hover/cell:border-ink-4 group-data-[selected]/cell:border-accent group-data-[selected]/cell:shadow-[0_0_0_3px_rgba(15,42,34,0.18)]",lb="block h-auto max-h-[120px] w-auto max-w-full",k4="absolute right-1.5 top-1.5 grid size-[22px] place-items-center rounded-full bg-accent text-white shadow-[0_2px_6px_rgba(0,0,0,0.25)]",E4="relative grid h-[120px] w-[160px] place-items-center bg-[#e6e3da] text-ink-3",j4="block w-full truncate text-center text-[11.5px] leading-[1.35] text-ink-2",M4="absolute bottom-1.5 left-1.5 rounded-full bg-[rgba(15,18,9,0.72)] px-1.5 py-0.5 text-[10.5px] font-semibold tabular-nums text-white",C4=ye(ot,"group/up flex h-[120px] w-full flex-col items-center justify-center gap-[7px] self-start rounded-[9px] border-[1.5px] border-dashed border-ink-4 bg-[#fafaf8] text-ink-3 hover:border-accent hover:bg-white hover:text-accent"),A4="grid size-[38px] place-items-center rounded-full border border-line bg-white group-hover/up:border-accent",N4="text-[12px] font-semibold",T4="flex flex-shrink-0 gap-0.5 rounded-[9px] bg-[#f1f0ea] p-[3px]",O4=ye(ot,"inline-flex h-8 items-center rounded-[7px] px-[13px] text-[12.5px] font-semibold text-ink-3");function R4(n,l=!1){return ye(O4,n&&"bg-white text-ink shadow-[0_1px_3px_rgba(20,18,13,0.1)]",l&&"opacity-40 cursor-not-allowed")}var ih=_0();function z4(...n){return Ff(Vf(n))}const Ev=1e3;let D4=0;const ol=[];let jv="",Mv="";function U4(){if(ol.length!==1||typeof document>"u")return;const n=document.body;jv=n.style.overflow,Mv=n.style.paddingRight;const l=window.innerWidth-document.documentElement.clientWidth;n.style.overflow="hidden",l>0&&(n.style.paddingRight=`${l}px`)}function L4(){ol.length===0&&(typeof document>"u"||(document.body.style.overflow=jv,document.body.style.paddingRight=Mv))}function B4(){const n=++D4;return ol.push(n),U4(),n}function ib(n){const l=ol.indexOf(n);l!==-1&&ol.splice(l,1),L4()}function H4(n){const l=ol.indexOf(n);return Ev+(l===-1?0:l)*10}function sb(n){return ol[ol.length-1]===n}const q4="(prefers-reduced-motion: reduce)";function G4(){const[n,l]=_.useState(!1);return _.useEffect(()=>{if(typeof window>"u"||!window.matchMedia)return;const s=window.matchMedia(q4);l(s.matches);const o=u=>l(u.matches);return s.addEventListener("change",o),()=>s.removeEventListener("change",o)},[]),n}const I4={sm:"max-w-[calc(420*var(--frame))]",md:"max-w-[calc(520*var(--frame))]",lg:"max-w-[calc(800*var(--frame))]",xl:"max-w-[calc(1240*var(--frame))]",full:"max-w-[calc(100vw-80px)]"},Q4='a[href],button:not([disabled]),textarea:not([disabled]),input:not([disabled]),select:not([disabled]),[tabindex]:not([tabindex="-1"])';function K4({open:n,onClose:l,className:s,size:o,closeOnBackdrop:u=!0,closeOnEsc:d=!0,labelledBy:h,ariaLabel:p,children:y}){const[g,x]=_.useState("closed"),v=_.useRef(null),E=_.useRef(null),M=_.useRef(null),[N,A]=_.useState(1e3),j=G4(),[O,z]=_.useState(y);n&&O!==y&&z(y),_.useEffect(()=>{n&&g==="closed"?x("open"):!n&&g==="open"&&x(j?"closed":"closing")},[n,g,j]),_.useEffect(()=>{var W;if(g==="open"&&v.current===null){M.current=document.activeElement??null;const ee=B4();v.current=ee,A(H4(ee)),(W=E.current)==null||W.focus()}},[g]),_.useEffect(()=>{var W,ee;g==="closed"&&v.current!==null&&(ib(v.current),v.current=null,(ee=(W=M.current)==null?void 0:W.focus)==null||ee.call(W),M.current=null)},[g]),_.useEffect(()=>()=>{v.current!==null&&(ib(v.current),v.current=null)},[]),_.useEffect(()=>{if(g!=="closing")return;const W=setTimeout(()=>x("closed"),400);return()=>clearTimeout(W)},[g]),_.useEffect(()=>{if(g!=="open"||!d)return;const W=ee=>{ee.key==="Escape"&&(v.current===null||!sb(v.current)||(ee.stopPropagation(),l()))};return document.addEventListener("keydown",W,!0),()=>document.removeEventListener("keydown",W,!0)},[g,d,l]),_.useEffect(()=>{if(g!=="open")return;const W=ee=>{if(ee.key!=="Tab"||v.current===null||!sb(v.current))return;const ae=E.current;if(!ae)return;const U=ae.querySelectorAll(Q4);if(U.length===0){ee.preventDefault();return}const re=U[0],de=U[U.length-1];ee.shiftKey&&document.activeElement===re?(ee.preventDefault(),de==null||de.focus()):!ee.shiftKey&&document.activeElement===de&&(ee.preventDefault(),re==null||re.focus())};return document.addEventListener("keydown",W,!0),()=>document.removeEventListener("keydown",W,!0)},[g]);const D=_.useCallback(W=>{W.target===W.currentTarget&&g==="closing"&&x("closed")},[g]);if(g==="closed"||typeof document>"u")return null;const Y=g==="closing"?"closing":"open";return ih.createPortal(f.jsx("div",{className:"hp-modal-backdrop","data-state":Y,inert:Y==="closing",style:{zIndex:N},onMouseDown:u?l:void 0,children:f.jsx("div",{ref:E,className:z4("hp-modal-panel",o?I4[o]:void 0,s),"data-state":Y,role:"dialog","aria-modal":"true","aria-labelledby":h,"aria-label":p,tabIndex:-1,onMouseDown:W=>W.stopPropagation(),onAnimationEnd:D,children:n?y:O})}),document.body)}const V4={page:"max-w-[920px]",pick:"max-w-[700px]",crop:"max-w-[680px]"};function Cv({open:n=!0,variant:l,onClose:s,children:o}){return f.jsx(K4,{open:n,onClose:s,className:ye(m4,V4[l]),children:o})}const cn={Shell:Cv,head:gv,titles:bv,title:vv,subtitle:y4,close:xv,CloseIcon:ze.x,foot:_v,actions:wv,buttonGhost:kv,buttonPrimary:lh,buttonLink:g4,ZoomOutIcon:ze.minus,ZoomInIcon:ze.plus},Y4=new Set(["text","number","select","url"]);function ob(n){return Y4.has(n.type)?n.type!=="text"||n.size===void 0||n.size==="short":!1}function Av(n){const l=[];for(let s=0;s<n.length;s++){const o=n[s+1];ob(n[s])&&o!==void 0&&ob(o)?(l.push({kind:"pair",indices:[s,s+1]}),s++):l.push({kind:"single",index:s})}return l}function Nv({items:n,rows:l}){return f.jsx("div",{className:th,children:l.map(s=>s.kind==="pair"?f.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[n[s.indices[0]],n[s.indices[1]]]},`p${s.indices[0]}`):f.jsx("div",{children:n[s.index]},`s${s.index}`))})}function Jr(n){var d;const l=n.crop,s=l!=null&&l.aspect&&l.aspect>0?l.aspect:16/10,o=(d=l==null?void 0:l.mobile)==null?void 0:d.aspect,u=o&&o>0&&Math.abs(o-s)>1e-4?o:void 0;return{mode:(l==null?void 0:l.mode)==="free"?"free":"locked",aspect:s,aspectLabel:l==null?void 0:l.aspectLabel,mobileAspect:u}}function $4(n,l){if(!n||!l)return{nx:0,ny:0,nw:1,nh:1};const s=Math.min(1,l/n),o=Math.min(1,n/l);return{nx:(1-s)/2,ny:(1-o)/2,nw:s,nh:o}}function Tv(n,l,s){return n==="free"?{nx:0,ny:0,nw:1,nh:1}:$4(l,s)}function rb(n,l,s){const o=n.nx+n.nw/2,u=n.ny+n.nh/2;if(!l||!s)return{...n};const d=l/s;let h=n.nw,p=h/d;return p>n.nh&&(p=n.nh,h=p*d),{nx:o-h/2,ny:u-p/2,nw:h,nh:p}}function Ov(n){const l=s=>Math.round(s*1e4)/1e4;return l(n.nx)===0&&l(n.ny)===0&&l(n.nw)===1&&l(n.nh)===1}function F4(n,l,s,o){const u=n==null?void 0:n.rect;return u&&u.nw&&u.nh?{nx:u.nx,ny:u.ny,nw:u.nw,nh:u.nh}:Tv(l,s,o)}const Xa=52,X4=1,Z4=6,P4=.94,Rt=(n,l,s)=>s<l?l:Math.max(l,Math.min(s,n));function Yr(n,l,s,o,u,d,h){n=Math.max(Xa,n);const p=u>0?h.r-s:s-h.l;n=Math.min(n,p);let y=n/l;const g=d>0?h.b-o:o-h.t;return y>g&&(y=g,n=y*l),{w:Math.max(Xa,n),h:Math.max(Xa,n/l)}}function J4({src:n,mode:l,aspect:s,seed:o}){const u=_.useRef(null),[,d]=_.useReducer(L=>L+1,0),h=_.useRef(null),p=_.useRef({w:0,h:0}),y=_.useRef({z:1,icx:0,icy:0}),g=_.useRef({x:0,y:0,w:0,h:0}),x=_.useRef(!1),v=_.useRef(o??null),[E,M]=_.useState(null),N=()=>{const L=h.current,G=p.current;if(!L||!G.w)return{w:0,h:0};const F=Math.min(G.w/L.w,G.h/L.h)*P4;return{w:L.w*F,h:L.h*F}},A=()=>{const L=N(),G=y.current,F=L.w*G.z,w=L.h*G.z;return{l:G.icx-F/2,t:G.icy-w/2,r:G.icx+F/2,b:G.icy+w/2,w:F,h:w}},j=()=>{const L=A(),G=p.current;return{l:Math.max(L.l,0),t:Math.max(L.t,0),r:Math.min(L.r,G.w),b:Math.min(L.b,G.h)}},O=()=>{const L=A(),G=g.current,F=y.current,w=L.w/2,Z=L.h/2;L.w>=G.w&&(F.icx=Rt(F.icx,G.x+G.w-w,G.x+w)),L.h>=G.h&&(F.icy=Rt(F.icy,G.y+G.h-Z,G.y+Z))},z=()=>{const L=g.current,G=j(),F=G.r-G.l,w=G.b-G.t;if(l==="locked"){let Z=Math.min(L.w,F),ue=Z/s;ue>w&&(ue=w,Z=ue*s),L.w=Z,L.h=ue}else L.w=Math.min(L.w,F),L.h=Math.min(L.h,w);L.x=Rt(L.x,G.l,G.r-L.w),L.y=Rt(L.y,G.t,G.b-L.h)},D=()=>{z(),O(),z()},Y=L=>{const G=p.current;if(!G.w||!h.current)return;y.current={z:1,icx:G.w/2,icy:G.h/2};const F=A(),w=h.current.w/h.current.h,Z=L?F4(v.current,l,w,s):Tv(l,w,s);g.current={x:F.l+Z.nx*F.w,y:F.t+Z.ny*F.h,w:Z.nw*F.w,h:Z.nh*F.h},D(),x.current=!0,d()};_.useEffect(()=>{x.current=!1,h.current=null,d();const L=new Image;L.onload=()=>{h.current={w:L.naturalWidth||1,h:L.naturalHeight||1},Y(!0)},L.src=n},[n]),_.useEffect(()=>{v.current=o??null},[o]),_.useEffect(()=>{h.current&&Y(!1)},[l,s]),_.useLayoutEffect(()=>{const L=u.current;if(!L)return;const G=()=>{const w=L.getBoundingClientRect(),Z=p.current.w;p.current={w:w.width,h:w.height},!Z&&h.current?Y(!0):Z&&(D(),d())};G();const F=new ResizeObserver(G);return F.observe(L),()=>F.disconnect()},[]);const W=L=>{const G=u.current.getBoundingClientRect();return{x:L.clientX-G.left,y:L.clientY-G.top}},ee=L=>{var ue,te;if(L.button)return;L.stopPropagation(),(te=(ue=L.currentTarget).setPointerCapture)==null||te.call(ue,L.pointerId),M("move");const G=W(L),F={...g.current},w=P=>{const k=W(P),I=j(),$=g.current;$.x=Rt(F.x+(k.x-G.x),I.l,I.r-$.w),$.y=Rt(F.y+(k.y-G.y),I.t,I.b-$.h),d()},Z=()=>{window.removeEventListener("pointermove",w),window.removeEventListener("pointerup",Z),window.removeEventListener("pointercancel",Z),M(null)};window.addEventListener("pointermove",w),window.addEventListener("pointerup",Z),window.addEventListener("pointercancel",Z)},ae=L=>G=>{var P,k;if(G.button)return;G.stopPropagation(),(k=(P=G.currentTarget).setPointerCapture)==null||k.call(P,G.pointerId),M(L);const F=g.current,w={l:F.x,t:F.y,r:F.x+F.w,b:F.y+F.h},Z=W(G),ue=I=>{const $=W(I),T=j(),B=$.x-Z.x,q=$.y-Z.y;let V=w.l,me=w.t,he=w.r,ke=w.b;if(l==="free")L.includes("w")&&(V=Rt(w.l+B,T.l,he-Xa)),L.includes("e")&&(he=Rt(w.r+B,V+Xa,T.r)),L.includes("n")&&(me=Rt(w.t+q,T.t,ke-Xa)),L.includes("s")&&(ke=Rt(w.b+q,me+Xa,T.b));else{const Ae=s;if(L==="se"){const Ue=Yr(w.r+B-w.l,Ae,w.l,w.t,1,1,T);V=w.l,me=w.t,he=V+Ue.w,ke=me+Ue.h}else if(L==="nw"){const Ue=Yr(w.r-(w.l+B),Ae,w.r,w.b,-1,-1,T);he=w.r,ke=w.b,V=he-Ue.w,me=ke-Ue.h}else if(L==="ne"){const Ue=Yr(w.r+B-w.l,Ae,w.l,w.b,1,-1,T);V=w.l,ke=w.b,he=V+Ue.w,me=ke-Ue.h}else if(L==="sw"){const Ue=Yr(w.r-(w.l+B),Ae,w.r,w.t,-1,1,T);he=w.r,me=w.t,V=he-Ue.w,ke=me+Ue.h}else{const Ue=(w.l+w.r)/2,nt=(w.t+w.b)/2;let Ve=F.w,Oe=F.h;L==="e"?Ve=(w.r+B-Ue)*2:L==="w"?Ve=(Ue-(w.l+B))*2:L==="s"?(Oe=(w.b+q-nt)*2,Ve=Oe*Ae):L==="n"&&(Oe=(nt-(w.t+q))*2,Ve=Oe*Ae),Ve=Math.max(Xa,Ve),Oe=Ve/Ae,Ve=Math.min(Ve,T.r-T.l),Oe=Ve/Ae,Oe>T.b-T.t&&(Oe=T.b-T.t,Ve=Oe*Ae),V=Rt(Ue-Ve/2,T.l,T.r-Ve),me=Rt(nt-Oe/2,T.t,T.b-Oe),he=V+Ve,ke=me+Oe}}g.current={x:V,y:me,w:he-V,h:ke-me},d()},te=()=>{window.removeEventListener("pointermove",ue),window.removeEventListener("pointerup",te),window.removeEventListener("pointercancel",te),M(null)};window.addEventListener("pointermove",ue),window.addEventListener("pointerup",te),window.addEventListener("pointercancel",te)},U=(L,G,F)=>{const w=y.current;L=Rt(L,X4,Z4);const Z=L/w.z;w.icx=G+(w.icx-G)*Z,w.icy=F+(w.icy-F)*Z,w.z=L,D(),d()},re=L=>{const G=p.current;U(y.current.z*L,G.w/2,G.h/2)},de=_.useRef(()=>{});de.current=L=>{L.preventDefault();const G=p.current,F=Math.exp(-L.deltaY*.0015*(L.ctrlKey?2.6:1));U(y.current.z*F,G.w/2,G.h/2)},_.useEffect(()=>{const L=u.current;if(!L)return;const G=F=>de.current(F);return L.addEventListener("wheel",G,{passive:!1}),()=>L.removeEventListener("wheel",G)},[]);const ce=()=>Y(!1),ie=()=>{const L=A(),G=g.current;return L.w?{nx:Rt((G.x-L.l)/L.w,0,1),ny:Rt((G.y-L.t)/L.h,0,1),nw:Rt(G.w/L.w,0,1),nh:Rt(G.h/L.h,0,1)}:{nx:0,ny:0,nw:1,nh:1}};return{stageRef:u,ready:x.current,activeHandle:E,imgRect:A,box:g.current,view:y.current,onBoxDown:ee,onHandleDown:ae,zoomBy:re,reset:ce,cropValue:ie,natAspect:h.current?h.current.w/h.current.h:null}}function W4({chrome:n,pct:l,onZoomOut:s,onZoomIn:o,resetSlot:u,children:d}){return f.jsxs("div",{className:n.foot,children:[f.jsxs("div",{className:"flex items-center gap-3",children:[u,f.jsxs("div",{className:"flex h-9 items-center overflow-hidden rounded-[9px] border border-line",children:[f.jsx("button",{type:"button",className:"grid size-9 place-items-center text-ink-2 hover:bg-[#f1f0ea] hover:text-ink",onClick:s,"aria-label":"Zoom out",children:f.jsx(n.ZoomOutIcon,{})}),f.jsx("span",{className:"grid h-9 min-w-[54px] place-items-center border-x border-line font-mono text-[12px] text-ink-2",children:l}),f.jsx("button",{type:"button",className:"grid size-9 place-items-center text-ink-2 hover:bg-[#f1f0ea] hover:text-ink",onClick:o,"aria-label":"Zoom in",children:f.jsx(n.ZoomInIcon,{})})]})]}),f.jsx("div",{className:n.actions,children:d})]})}const eE=["n","s","e","w"],tE=["nw","ne","sw","se"];function nE({cr:n,mode:l,src:s,stageClassName:o}){const u=n.imgRect(),d=n.box,h=n.activeHandle!==null;return f.jsx("div",{className:`we-cs-stage ${o}`,ref:n.stageRef,children:n.ready&&f.jsxs(f.Fragment,{children:[f.jsx("img",{className:"we-cs-img",src:s,alt:"",draggable:!1,style:{left:u.l,top:u.t,width:u.w,height:u.h}}),f.jsxs("div",{className:`we-cs-box${h?" live":""}`,"data-mode":l,"data-crop-box":!0,style:{left:d.x,top:d.y,width:d.w,height:d.h},onPointerDown:n.onBoxDown,children:[f.jsx("div",{className:"we-cs-ring"}),f.jsxs("div",{className:"we-cs-thirds",children:[f.jsx("i",{}),f.jsx("i",{}),f.jsx("i",{}),f.jsx("i",{})]}),eE.map(p=>f.jsx("div",{"data-crop-handle":p,className:`we-cs-h edge ${p}`,onPointerDown:n.onHandleDown(p)},p)),tE.map(p=>f.jsx("div",{"data-crop-handle":p,className:`we-cs-h corner ${p}`,onPointerDown:n.onHandleDown(p)},p))]})]})})}const aE=_.forwardRef(function({chrome:l,src:s,mode:o,aspect:u,seed:d,stageClassName:h="h-[412px]",footerActions:p,onUserEdit:y},g){const x=J4({src:s,mode:o,aspect:u,seed:d});_.useImperativeHandle(g,()=>({cropValue:()=>x.cropValue(),natAspect:()=>x.natAspect}),[x]);const v=Math.round(x.view.z*100)+"%",E=_.useRef(!1),M=_.useRef(!1),N=()=>{M.current=!0},A=()=>{M.current&&!E.current&&(E.current=!0,y==null||y())},j=()=>{M.current=!1};return f.jsxs(f.Fragment,{children:[f.jsx("div",{onPointerDownCapture:N,onPointerMoveCapture:A,onPointerUpCapture:j,children:f.jsx(nE,{cr:x,mode:o,src:s,stageClassName:h})}),f.jsx(W4,{chrome:l,pct:v,onZoomOut:()=>x.zoomBy(1/1.25),onZoomIn:()=>x.zoomBy(1.25),resetSlot:f.jsx("button",{type:"button",className:l.buttonLink,onClick:x.reset,children:"Reset"}),children:p})]})});function cb(...n){return Ff(Vf(n))}function lE({view:n,onChange:l,className:s}){const o=(u,d,h)=>f.jsx("button",{type:"button","aria-label":d,"aria-pressed":n===u,onClick:()=>l(u),className:cb("flex h-7 w-8 items-center justify-center rounded-[6px] transition-[background,color] duration-[120ms]",n===u?"bg-white text-ink shadow-sm":"text-white/85 hover:text-white"),children:f.jsx("svg",{viewBox:"0 0 24 24",className:"h-4 w-4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",children:f.jsx("path",{d:h})})});return f.jsxs("div",{className:cb("inline-flex gap-0.5 rounded-[8px] bg-[rgba(15,18,9,0.55)] p-0.5 backdrop-blur",s),children:[o("desktop","Desktop crop","M3 5h18v11H3zM8 20h8M12 16v4"),o("mobile","Mobile crop","M8 3h8a1 1 0 0 1 1 1v16a1 1 0 0 1-1 1H8a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1zM11 18h2")]})}function sh({chrome:n,open:l=!0,src:s,mode:o,aspect:u,mobileAspect:d,seed:h,mobileSeed:p,onApply:y,onClose:g,title:x="Crop photo",subtitle:v,variant:E="crop",stageClassName:M="h-[412px]"}){const[N]=_.useState(s),A=d!=null&&Math.abs(d-u)>1e-4,[j,O]=_.useState("desktop"),[z,D]=_.useState({desktop:(h==null?void 0:h.rect)??null,mobile:(p==null?void 0:p.rect)??null}),Y=_.useRef(!(p!=null&&p.rect)),W=_.useRef(null),ee=L=>L==="mobile"?d??u:u,ae=()=>{var L;return((L=W.current)==null?void 0:L.natAspect())??u},U=L=>L==="desktop"?{rect:z.desktop}:{rect:z.mobile??z.desktop},re=()=>{var L;return((L=W.current)==null?void 0:L.cropValue())??null},de=L=>{if(L===j)return;const G=re();D(F=>{const w={...F,[j]:G??F[j]};if(j==="desktop"&&Y.current){const Z=w.desktop??G;Z&&(w.mobile=rb(Z,d??u,ae()))}return w}),O(L)},ce=()=>{j==="mobile"&&(Y.current=!1)},ie=()=>{const L=re(),G=ae(),F=(j==="desktop"?L:z.desktop)??L??{nx:0,ny:0,nw:1,nh:1};let w={rect:F,ar:G};if(A){let Z=j==="mobile"?L:z.mobile;Z||(Z=rb(F,d??u,G)),w={...w,mobile:{rect:Z,derived:Y.current}}}y(w)};return f.jsxs(n.Shell,{open:l,variant:E,onClose:g,children:[f.jsxs("div",{className:n.head,children:[f.jsxs("div",{className:n.titles,children:[f.jsx("h2",{className:n.title,children:x}),v?f.jsx("span",{className:n.subtitle,children:v}):null]}),f.jsx("button",{className:n.close,onClick:g,"aria-label":"Close",children:f.jsx(n.CloseIcon,{})})]}),f.jsxs("div",{className:"relative",children:[A&&f.jsx(lE,{view:j,onChange:de,className:"absolute right-3 top-3 z-10"}),f.jsx(aE,{ref:W,chrome:n,src:N,mode:o,aspect:ee(j),seed:U(j),stageClassName:M,onUserEdit:ce,footerActions:f.jsxs(f.Fragment,{children:[f.jsx("button",{className:n.buttonGhost,onClick:g,children:"Cancel"}),f.jsx("button",{className:n.buttonPrimary,onClick:ie,children:"Apply crop"})]})},j)]})]})}function iE(n,l,s){return{nx:n.x/l,ny:n.y/s,nw:n.w/l,nh:n.h/s}}function sE(n,l,s){return{x:n.nx*l,y:n.ny*s,w:n.nw*l,h:n.nh*s}}function oE(n,l,s,o){const u=Math.max(o,Math.min(n.w,l)),d=Math.max(o,Math.min(n.h,s)),h=Math.max(0,Math.min(n.x,l-u)),p=Math.max(0,Math.min(n.y,s-d));return{x:h,y:p,w:u,h:d}}function rE(n,l,s,o){return oE(sE(n,l,s),l,s,o)}var Wl=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(n){return this.listeners.add(n),this.onSubscribe(),()=>{this.listeners.delete(n),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Ul,Za,Vi,c0,cE=(c0=class extends Wl{constructor(){super();be(this,Ul);be(this,Za);be(this,Vi);fe(this,Vi,l=>{if(typeof window<"u"&&window.addEventListener){const s=()=>l();return window.addEventListener("visibilitychange",s,!1),()=>{window.removeEventListener("visibilitychange",s)}}})}onSubscribe(){S(this,Za)||this.setEventListener(S(this,Vi))}onUnsubscribe(){var l;this.hasListeners()||((l=S(this,Za))==null||l.call(this),fe(this,Za,void 0))}setEventListener(l){var s;fe(this,Vi,l),(s=S(this,Za))==null||s.call(this),fe(this,Za,l(o=>{typeof o=="boolean"?this.setFocused(o):this.onFocus()}))}setFocused(l){S(this,Ul)!==l&&(fe(this,Ul,l),this.onFocus())}onFocus(){const l=this.isFocused();this.listeners.forEach(s=>{s(l)})}isFocused(){var l;return typeof S(this,Ul)=="boolean"?S(this,Ul):((l=globalThis.document)==null?void 0:l.visibilityState)!=="hidden"}},Ul=new WeakMap,Za=new WeakMap,Vi=new WeakMap,c0),oh=new cE,uE={setTimeout:(n,l)=>setTimeout(n,l),clearTimeout:n=>clearTimeout(n),setInterval:(n,l)=>setInterval(n,l),clearInterval:n=>clearInterval(n)},Pa,qf,u0,dE=(u0=class{constructor(){be(this,Pa,uE);be(this,qf,!1)}setTimeoutProvider(n){fe(this,Pa,n)}setTimeout(n,l){return S(this,Pa).setTimeout(n,l)}clearTimeout(n){S(this,Pa).clearTimeout(n)}setInterval(n,l){return S(this,Pa).setInterval(n,l)}clearInterval(n){S(this,Pa).clearInterval(n)}},Pa=new WeakMap,qf=new WeakMap,u0),zl=new dE;function fE(n){setTimeout(n,0)}var hE=typeof window>"u"||"Deno"in globalThis;function qt(){}function pE(n,l){return typeof n=="function"?n(l):n}function of(n){return typeof n=="number"&&n>=0&&n!==1/0}function Rv(n,l){return Math.max(n+(l||0)-Date.now(),0)}function sl(n,l){return typeof n=="function"?n(l):n}function fn(n,l){return typeof n=="function"?n(l):n}function ub(n,l){const{type:s="all",exact:o,fetchStatus:u,predicate:d,queryKey:h,stale:p}=n;if(h){if(o){if(l.queryHash!==rh(h,l.options))return!1}else if(!os(l.queryKey,h))return!1}if(s!=="all"){const y=l.isActive();if(s==="active"&&!y||s==="inactive"&&y)return!1}return!(typeof p=="boolean"&&l.isStale()!==p||u&&u!==l.state.fetchStatus||d&&!d(l))}function db(n,l){const{exact:s,status:o,predicate:u,mutationKey:d}=n;if(d){if(!l.options.mutationKey)return!1;if(s){if(Zl(l.options.mutationKey)!==Zl(d))return!1}else if(!os(l.options.mutationKey,d))return!1}return!(o&&l.state.status!==o||u&&!u(l))}function rh(n,l){return((l==null?void 0:l.queryKeyHashFn)||Zl)(n)}function Zl(n){return JSON.stringify(n,(l,s)=>rf(s)?Object.keys(s).sort().reduce((o,u)=>(o[u]=s[u],o),{}):s)}function os(n,l){if(n===l)return!0;if(typeof n!=typeof l)return!1;if(n&&l&&typeof n=="object"&&typeof l=="object"){if(Array.isArray(n)&&Array.isArray(l)){for(let o=0;o<l.length;o++)if(!os(n[o],l[o]))return!1;return!0}const s=Object.keys(l);for(const o of s)if(!os(n[o],l[o]))return!1;return!0}return!1}var mE=Object.prototype.hasOwnProperty;function ch(n,l,s=0){if(n===l)return n;if(s>500)return l;const o=fb(n)&&fb(l);if(!o&&!(rf(n)&&rf(l)))return l;const d=(o?n:Object.keys(n)).length,h=o?l:Object.keys(l),p=h.length,y=o?new Array(p):{};let g=0;for(let x=0;x<p;x++){const v=o?x:h[x],E=n[v],M=l[v];if(E===M){y[v]=E,(o?x<d:mE.call(n,v))&&g++;continue}if(E===null||M===null||typeof E!="object"||typeof M!="object"){y[v]=M;continue}const N=ch(E,M,s+1);y[v]=N,N===E&&g++}return d===p&&g===d?n:y}function co(n,l){if(!l||Object.keys(n).length!==Object.keys(l).length)return!1;for(const s in n)if(n[s]!==l[s])return!1;return!0}function fb(n){return Array.isArray(n)&&n.length===Object.keys(n).length}function rf(n){if(!hb(n))return!1;const l=n.constructor;if(l===void 0)return!0;const s=l.prototype;return!(!hb(s)||!s.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(n)!==Object.prototype)}function hb(n){return Object.prototype.toString.call(n)==="[object Object]"}function yE(n){return new Promise(l=>{zl.setTimeout(l,n)})}function cf(n,l,s){return typeof s.structuralSharing=="function"?s.structuralSharing(n,l):s.structuralSharing!==!1?ch(n,l):l}function gE(n,l,s=0){const o=[...n,l];return s&&o.length>s?o.slice(1):o}function bE(n,l,s=0){const o=[l,...n];return s&&o.length>s?o.slice(0,-1):o}var uh=Symbol();function zv(n,l){return!n.queryFn&&(l!=null&&l.initialPromise)?()=>l.initialPromise:!n.queryFn||n.queryFn===uh?()=>Promise.reject(new Error(`Missing queryFn: '${n.queryHash}'`)):n.queryFn}function dh(n,l){return typeof n=="function"?n(...l):!!n}function vE(n,l,s){let o=!1,u;return Object.defineProperty(n,"signal",{enumerable:!0,get:()=>(u??(u=l()),o||(o=!0,u.aborted?s():u.addEventListener("abort",s,{once:!0})),u)}),n}var uo=(()=>{let n=()=>hE;return{isServer(){return n()},setIsServer(l){n=l}}})();function uf(){let n,l;const s=new Promise((u,d)=>{n=u,l=d});s.status="pending",s.catch(()=>{});function o(u){Object.assign(s,u),delete s.resolve,delete s.reject}return s.resolve=u=>{o({status:"fulfilled",value:u}),n(u)},s.reject=u=>{o({status:"rejected",reason:u}),l(u)},s}var xE=fE;function _E(){let n=[],l=0,s=p=>{p()},o=p=>{p()},u=xE;const d=p=>{l?n.push(p):u(()=>{s(p)})},h=()=>{const p=n;n=[],p.length&&u(()=>{o(()=>{p.forEach(y=>{s(y)})})})};return{batch:p=>{let y;l++;try{y=p()}finally{l--,l||h()}return y},batchCalls:p=>(...y)=>{d(()=>{p(...y)})},schedule:d,setNotifyFunction:p=>{s=p},setBatchNotifyFunction:p=>{o=p},setScheduler:p=>{u=p}}}var ht=_E(),Yi,Ja,$i,d0,wE=(d0=class extends Wl{constructor(){super();be(this,Yi,!0);be(this,Ja);be(this,$i);fe(this,$i,l=>{if(typeof window<"u"&&window.addEventListener){const s=()=>l(!0),o=()=>l(!1);return window.addEventListener("online",s,!1),window.addEventListener("offline",o,!1),()=>{window.removeEventListener("online",s),window.removeEventListener("offline",o)}}})}onSubscribe(){S(this,Ja)||this.setEventListener(S(this,$i))}onUnsubscribe(){var l;this.hasListeners()||((l=S(this,Ja))==null||l.call(this),fe(this,Ja,void 0))}setEventListener(l){var s;fe(this,$i,l),(s=S(this,Ja))==null||s.call(this),fe(this,Ja,l(this.setOnline.bind(this)))}setOnline(l){S(this,Yi)!==l&&(fe(this,Yi,l),this.listeners.forEach(o=>{o(l)}))}isOnline(){return S(this,Yi)}},Yi=new WeakMap,Ja=new WeakMap,$i=new WeakMap,d0),lc=new wE;function SE(n){return Math.min(1e3*2**n,3e4)}function Dv(n){return(n??"online")==="online"?lc.isOnline():!0}var df=class extends Error{constructor(n){super("CancelledError"),this.revert=n==null?void 0:n.revert,this.silent=n==null?void 0:n.silent}};function Uv(n){let l=!1,s=0,o;const u=uf(),d=()=>u.status!=="pending",h=A=>{var j;if(!d()){const O=new df(A);E(O),(j=n.onCancel)==null||j.call(n,O)}},p=()=>{l=!0},y=()=>{l=!1},g=()=>oh.isFocused()&&(n.networkMode==="always"||lc.isOnline())&&n.canRun(),x=()=>Dv(n.networkMode)&&n.canRun(),v=A=>{d()||(o==null||o(),u.resolve(A))},E=A=>{d()||(o==null||o(),u.reject(A))},M=()=>new Promise(A=>{var j;o=O=>{(d()||g())&&A(O)},(j=n.onPause)==null||j.call(n)}).then(()=>{var A;o=void 0,d()||(A=n.onContinue)==null||A.call(n)}),N=()=>{if(d())return;let A;const j=s===0?n.initialPromise:void 0;try{A=j??n.fn()}catch(O){A=Promise.reject(O)}Promise.resolve(A).then(v).catch(O=>{var ee;if(d())return;const z=n.retry??(uo.isServer()?0:3),D=n.retryDelay??SE,Y=typeof D=="function"?D(s,O):D,W=z===!0||typeof z=="number"&&s<z||typeof z=="function"&&z(s,O);if(l||!W){E(O);return}s++,(ee=n.onFail)==null||ee.call(n,s,O),yE(Y).then(()=>g()?void 0:M()).then(()=>{l?E(O):N()})})};return{promise:u,status:()=>u.status,cancel:h,continue:()=>(o==null||o(),u),cancelRetry:p,continueRetry:y,canStart:x,start:()=>(x()?N():M().then(N),u)}}var Ll,f0,Lv=(f0=class{constructor(){be(this,Ll)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),of(this.gcTime)&&fe(this,Ll,zl.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(n){this.gcTime=Math.max(this.gcTime||0,n??(uo.isServer()?1/0:300*1e3))}clearGcTimeout(){S(this,Ll)!==void 0&&(zl.clearTimeout(S(this,Ll)),fe(this,Ll,void 0))}},Ll=new WeakMap,f0);function kE(n){return{onFetch:(l,s)=>{var x,v,E,M,N;const o=l.options,u=(E=(v=(x=l.fetchOptions)==null?void 0:x.meta)==null?void 0:v.fetchMore)==null?void 0:E.direction,d=((M=l.state.data)==null?void 0:M.pages)||[],h=((N=l.state.data)==null?void 0:N.pageParams)||[];let p={pages:[],pageParams:[]},y=0;const g=async()=>{let A=!1;const j=D=>{vE(D,()=>l.signal,()=>A=!0)},O=zv(l.options,l.fetchOptions),z=async(D,Y,W)=>{if(A)return Promise.reject(l.signal.reason);if(Y==null&&D.pages.length)return Promise.resolve(D);const ae=(()=>{const ce={client:l.client,queryKey:l.queryKey,pageParam:Y,direction:W?"backward":"forward",meta:l.options.meta};return j(ce),ce})(),U=await O(ae),{maxPages:re}=l.options,de=W?bE:gE;return{pages:de(D.pages,U,re),pageParams:de(D.pageParams,Y,re)}};if(u&&d.length){const D=u==="backward",Y=D?EE:pb,W={pages:d,pageParams:h},ee=Y(o,W);p=await z(W,ee,D)}else{const D=n??d.length;do{const Y=y===0?h[0]??o.initialPageParam:pb(o,p);if(y>0&&Y==null)break;p=await z(p,Y),y++}while(y<D)}return p};l.options.persister?l.fetchFn=()=>{var A,j;return(j=(A=l.options).persister)==null?void 0:j.call(A,g,{client:l.client,queryKey:l.queryKey,meta:l.options.meta,signal:l.signal},s)}:l.fetchFn=g}}}function pb(n,{pages:l,pageParams:s}){const o=l.length-1;return l.length>0?n.getNextPageParam(l[o],l,s[o],s):void 0}function EE(n,{pages:l,pageParams:s}){var o;return l.length>0?(o=n.getPreviousPageParam)==null?void 0:o.call(n,l[0],l,s[0],s):void 0}var Fi,Bl,Xi,kn,Hl,Mt,fo,ql,dn,Bv,fa,h0,jE=(h0=class extends Lv{constructor(l){super();be(this,dn);be(this,Fi);be(this,Bl);be(this,Xi);be(this,kn);be(this,Hl);be(this,Mt);be(this,fo);be(this,ql);fe(this,ql,!1),fe(this,fo,l.defaultOptions),this.setOptions(l.options),this.observers=[],fe(this,Hl,l.client),fe(this,kn,S(this,Hl).getQueryCache()),this.queryKey=l.queryKey,this.queryHash=l.queryHash,fe(this,Bl,yb(this.options)),this.state=l.state??S(this,Bl),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return S(this,Fi)}get promise(){var l;return(l=S(this,Mt))==null?void 0:l.promise}setOptions(l){if(this.options={...S(this,fo),...l},l!=null&&l._type&&fe(this,Fi,l._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const s=yb(this.options);s.data!==void 0&&(this.setState(mb(s.data,s.dataUpdatedAt)),fe(this,Bl,s))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&S(this,kn).remove(this)}setData(l,s){const o=cf(this.state.data,l,this.options);return je(this,dn,fa).call(this,{data:o,type:"success",dataUpdatedAt:s==null?void 0:s.updatedAt,manual:s==null?void 0:s.manual}),o}setState(l){je(this,dn,fa).call(this,{type:"setState",state:l})}cancel(l){var o,u;const s=(o=S(this,Mt))==null?void 0:o.promise;return(u=S(this,Mt))==null||u.cancel(l),s?s.then(qt).catch(qt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return S(this,Bl)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(l=>fn(l.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===uh||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(l=>sl(l.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(l=>l.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(l=0){return this.state.data===void 0?!0:l==="static"?!1:this.state.isInvalidated?!0:!Rv(this.state.dataUpdatedAt,l)}onFocus(){var s;const l=this.observers.find(o=>o.shouldFetchOnWindowFocus());l==null||l.refetch({cancelRefetch:!1}),(s=S(this,Mt))==null||s.continue()}onOnline(){var s;const l=this.observers.find(o=>o.shouldFetchOnReconnect());l==null||l.refetch({cancelRefetch:!1}),(s=S(this,Mt))==null||s.continue()}addObserver(l){this.observers.includes(l)||(this.observers.push(l),this.clearGcTimeout(),S(this,kn).notify({type:"observerAdded",query:this,observer:l}))}removeObserver(l){this.observers.includes(l)&&(this.observers=this.observers.filter(s=>s!==l),this.observers.length||(S(this,Mt)&&(S(this,ql)||je(this,dn,Bv).call(this)?S(this,Mt).cancel({revert:!0}):S(this,Mt).cancelRetry()),this.scheduleGc()),S(this,kn).notify({type:"observerRemoved",query:this,observer:l}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||je(this,dn,fa).call(this,{type:"invalidate"})}async fetch(l,s){var g,x,v,E,M,N,A,j,O,z,D;if(this.state.fetchStatus!=="idle"&&((g=S(this,Mt))==null?void 0:g.status())!=="rejected"){if(this.state.data!==void 0&&(s!=null&&s.cancelRefetch))this.cancel({silent:!0});else if(S(this,Mt))return S(this,Mt).continueRetry(),S(this,Mt).promise}if(l&&this.setOptions(l),!this.options.queryFn){const Y=this.observers.find(W=>W.options.queryFn);Y&&this.setOptions(Y.options)}const o=new AbortController,u=Y=>{Object.defineProperty(Y,"signal",{enumerable:!0,get:()=>(fe(this,ql,!0),o.signal)})},d=()=>{const Y=zv(this.options,s),ee=(()=>{const ae={client:S(this,Hl),queryKey:this.queryKey,meta:this.meta};return u(ae),ae})();return fe(this,ql,!1),this.options.persister?this.options.persister(Y,ee,this):Y(ee)},p=(()=>{const Y={fetchOptions:s,options:this.options,queryKey:this.queryKey,client:S(this,Hl),state:this.state,fetchFn:d};return u(Y),Y})(),y=S(this,Fi)==="infinite"?kE(this.options.pages):this.options.behavior;y==null||y.onFetch(p,this),fe(this,Xi,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((x=p.fetchOptions)==null?void 0:x.meta))&&je(this,dn,fa).call(this,{type:"fetch",meta:(v=p.fetchOptions)==null?void 0:v.meta}),fe(this,Mt,Uv({initialPromise:s==null?void 0:s.initialPromise,fn:p.fetchFn,onCancel:Y=>{Y instanceof df&&Y.revert&&this.setState({...S(this,Xi),fetchStatus:"idle"}),o.abort()},onFail:(Y,W)=>{je(this,dn,fa).call(this,{type:"failed",failureCount:Y,error:W})},onPause:()=>{je(this,dn,fa).call(this,{type:"pause"})},onContinue:()=>{je(this,dn,fa).call(this,{type:"continue"})},retry:p.options.retry,retryDelay:p.options.retryDelay,networkMode:p.options.networkMode,canRun:()=>!0}));try{const Y=await S(this,Mt).start();if(Y===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(Y),(M=(E=S(this,kn).config).onSuccess)==null||M.call(E,Y,this),(A=(N=S(this,kn).config).onSettled)==null||A.call(N,Y,this.state.error,this),Y}catch(Y){if(Y instanceof df){if(Y.silent)return S(this,Mt).promise;if(Y.revert){if(this.state.data===void 0)throw Y;return this.state.data}}throw je(this,dn,fa).call(this,{type:"error",error:Y}),(O=(j=S(this,kn).config).onError)==null||O.call(j,Y,this),(D=(z=S(this,kn).config).onSettled)==null||D.call(z,this.state.data,Y,this),Y}finally{this.scheduleGc()}}},Fi=new WeakMap,Bl=new WeakMap,Xi=new WeakMap,kn=new WeakMap,Hl=new WeakMap,Mt=new WeakMap,fo=new WeakMap,ql=new WeakMap,dn=new WeakSet,Bv=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},fa=function(l){const s=o=>{switch(l.type){case"failed":return{...o,fetchFailureCount:l.failureCount,fetchFailureReason:l.error};case"pause":return{...o,fetchStatus:"paused"};case"continue":return{...o,fetchStatus:"fetching"};case"fetch":return{...o,...Hv(o.data,this.options),fetchMeta:l.meta??null};case"success":const u={...o,...mb(l.data,l.dataUpdatedAt),dataUpdateCount:o.dataUpdateCount+1,...!l.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return fe(this,Xi,l.manual?u:void 0),u;case"error":const d=l.error;return{...o,error:d,errorUpdateCount:o.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:o.fetchFailureCount+1,fetchFailureReason:d,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...o,isInvalidated:!0};case"setState":return{...o,...l.state}}};this.state=s(this.state),ht.batch(()=>{this.observers.forEach(o=>{o.onQueryUpdate()}),S(this,kn).notify({query:this,type:"updated",action:l})})},h0);function Hv(n,l){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Dv(l.networkMode)?"fetching":"paused",...n===void 0&&{error:null,status:"pending"}}}function mb(n,l){return{data:n,dataUpdatedAt:l??Date.now(),error:null,isInvalidated:!1,status:"success"}}function yb(n){const l=typeof n.initialData=="function"?n.initialData():n.initialData,s=l!==void 0,o=s?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0;return{data:l,dataUpdateCount:0,dataUpdatedAt:s?o??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:s?"success":"pending",fetchStatus:"idle"}}var Pt,Ke,ho,Qt,Gl,Zi,ha,Wa,po,Pi,Ji,Il,Ql,el,Wi,Xe,ro,ff,hf,pf,mf,yf,gf,bf,qv,p0,fh=(p0=class extends Wl{constructor(l,s){super();be(this,Xe);be(this,Pt);be(this,Ke);be(this,ho);be(this,Qt);be(this,Gl);be(this,Zi);be(this,ha);be(this,Wa);be(this,po);be(this,Pi);be(this,Ji);be(this,Il);be(this,Ql);be(this,el);be(this,Wi,new Set);this.options=s,fe(this,Pt,l),fe(this,Wa,null),fe(this,ha,uf()),this.bindMethods(),this.setOptions(s)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(S(this,Ke).addObserver(this),gb(S(this,Ke),this.options)?je(this,Xe,ro).call(this):this.updateResult(),je(this,Xe,mf).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return vf(S(this,Ke),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return vf(S(this,Ke),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,je(this,Xe,yf).call(this),je(this,Xe,gf).call(this),S(this,Ke).removeObserver(this)}setOptions(l){const s=this.options,o=S(this,Ke);if(this.options=S(this,Pt).defaultQueryOptions(l),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof fn(this.options.enabled,S(this,Ke))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");je(this,Xe,bf).call(this),S(this,Ke).setOptions(this.options),s._defaulted&&!co(this.options,s)&&S(this,Pt).getQueryCache().notify({type:"observerOptionsUpdated",query:S(this,Ke),observer:this});const u=this.hasListeners();u&&bb(S(this,Ke),o,this.options,s)&&je(this,Xe,ro).call(this),this.updateResult(),u&&(S(this,Ke)!==o||fn(this.options.enabled,S(this,Ke))!==fn(s.enabled,S(this,Ke))||sl(this.options.staleTime,S(this,Ke))!==sl(s.staleTime,S(this,Ke)))&&je(this,Xe,ff).call(this);const d=je(this,Xe,hf).call(this);u&&(S(this,Ke)!==o||fn(this.options.enabled,S(this,Ke))!==fn(s.enabled,S(this,Ke))||d!==S(this,el))&&je(this,Xe,pf).call(this,d)}getOptimisticResult(l){const s=S(this,Pt).getQueryCache().build(S(this,Pt),l),o=this.createResult(s,l);return CE(this,o)&&(fe(this,Qt,o),fe(this,Zi,this.options),fe(this,Gl,S(this,Ke).state)),o}getCurrentResult(){return S(this,Qt)}trackResult(l,s){return new Proxy(l,{get:(o,u)=>(this.trackProp(u),s==null||s(u),u==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&S(this,ha).status==="pending"&&S(this,ha).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(o,u))})}trackProp(l){S(this,Wi).add(l)}getCurrentQuery(){return S(this,Ke)}refetch({...l}={}){return this.fetch({...l})}fetchOptimistic(l){const s=S(this,Pt).defaultQueryOptions(l),o=S(this,Pt).getQueryCache().build(S(this,Pt),s);return o.fetch().then(()=>this.createResult(o,s))}fetch(l){return je(this,Xe,ro).call(this,{...l,cancelRefetch:l.cancelRefetch??!0}).then(()=>(this.updateResult(),S(this,Qt)))}createResult(l,s){var re;const o=S(this,Ke),u=this.options,d=S(this,Qt),h=S(this,Gl),p=S(this,Zi),g=l!==o?l.state:S(this,ho),{state:x}=l;let v={...x},E=!1,M;if(s._optimisticResults){const de=this.hasListeners(),ce=!de&&gb(l,s),ie=de&&bb(l,o,s,u);(ce||ie)&&(v={...v,...Hv(x.data,l.options)}),s._optimisticResults==="isRestoring"&&(v.fetchStatus="idle")}let{error:N,errorUpdatedAt:A,status:j}=v;M=v.data;let O=!1;if(s.placeholderData!==void 0&&M===void 0&&j==="pending"){let de;d!=null&&d.isPlaceholderData&&s.placeholderData===(p==null?void 0:p.placeholderData)?(de=d.data,O=!0):de=typeof s.placeholderData=="function"?s.placeholderData((re=S(this,Ji))==null?void 0:re.state.data,S(this,Ji)):s.placeholderData,de!==void 0&&(j="success",M=cf(d==null?void 0:d.data,de,s),E=!0)}if(s.select&&M!==void 0&&!O)if(d&&M===(h==null?void 0:h.data)&&s.select===S(this,po))M=S(this,Pi);else try{fe(this,po,s.select),M=s.select(M),M=cf(d==null?void 0:d.data,M,s),fe(this,Pi,M),fe(this,Wa,null)}catch(de){fe(this,Wa,de)}S(this,Wa)&&(N=S(this,Wa),M=S(this,Pi),A=Date.now(),j="error");const z=v.fetchStatus==="fetching",D=j==="pending",Y=j==="error",W=D&&z,ee=M!==void 0,U={status:j,fetchStatus:v.fetchStatus,isPending:D,isSuccess:j==="success",isError:Y,isInitialLoading:W,isLoading:W,data:M,dataUpdatedAt:v.dataUpdatedAt,error:N,errorUpdatedAt:A,failureCount:v.fetchFailureCount,failureReason:v.fetchFailureReason,errorUpdateCount:v.errorUpdateCount,isFetched:l.isFetched(),isFetchedAfterMount:v.dataUpdateCount>g.dataUpdateCount||v.errorUpdateCount>g.errorUpdateCount,isFetching:z,isRefetching:z&&!D,isLoadingError:Y&&!ee,isPaused:v.fetchStatus==="paused",isPlaceholderData:E,isRefetchError:Y&&ee,isStale:hh(l,s),refetch:this.refetch,promise:S(this,ha),isEnabled:fn(s.enabled,l)!==!1};if(this.options.experimental_prefetchInRender){const de=U.data!==void 0,ce=U.status==="error"&&!de,ie=F=>{ce?F.reject(U.error):de&&F.resolve(U.data)},L=()=>{const F=fe(this,ha,U.promise=uf());ie(F)},G=S(this,ha);switch(G.status){case"pending":l.queryHash===o.queryHash&&ie(G);break;case"fulfilled":(ce||U.data!==G.value)&&L();break;case"rejected":(!ce||U.error!==G.reason)&&L();break}}return U}updateResult(){const l=S(this,Qt),s=this.createResult(S(this,Ke),this.options);if(fe(this,Gl,S(this,Ke).state),fe(this,Zi,this.options),S(this,Gl).data!==void 0&&fe(this,Ji,S(this,Ke)),co(s,l))return;fe(this,Qt,s);const o=()=>{if(!l)return!0;const{notifyOnChangeProps:u}=this.options,d=typeof u=="function"?u():u;if(d==="all"||!d&&!S(this,Wi).size)return!0;const h=new Set(d??S(this,Wi));return this.options.throwOnError&&h.add("error"),Object.keys(S(this,Qt)).some(p=>{const y=p;return S(this,Qt)[y]!==l[y]&&h.has(y)})};je(this,Xe,qv).call(this,{listeners:o()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&je(this,Xe,mf).call(this)}},Pt=new WeakMap,Ke=new WeakMap,ho=new WeakMap,Qt=new WeakMap,Gl=new WeakMap,Zi=new WeakMap,ha=new WeakMap,Wa=new WeakMap,po=new WeakMap,Pi=new WeakMap,Ji=new WeakMap,Il=new WeakMap,Ql=new WeakMap,el=new WeakMap,Wi=new WeakMap,Xe=new WeakSet,ro=function(l){je(this,Xe,bf).call(this);let s=S(this,Ke).fetch(this.options,l);return l!=null&&l.throwOnError||(s=s.catch(qt)),s},ff=function(){je(this,Xe,yf).call(this);const l=sl(this.options.staleTime,S(this,Ke));if(uo.isServer()||S(this,Qt).isStale||!of(l))return;const o=Rv(S(this,Qt).dataUpdatedAt,l)+1;fe(this,Il,zl.setTimeout(()=>{S(this,Qt).isStale||this.updateResult()},o))},hf=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(S(this,Ke)):this.options.refetchInterval)??!1},pf=function(l){je(this,Xe,gf).call(this),fe(this,el,l),!(uo.isServer()||fn(this.options.enabled,S(this,Ke))===!1||!of(S(this,el))||S(this,el)===0)&&fe(this,Ql,zl.setInterval(()=>{(this.options.refetchIntervalInBackground||oh.isFocused())&&je(this,Xe,ro).call(this)},S(this,el)))},mf=function(){je(this,Xe,ff).call(this),je(this,Xe,pf).call(this,je(this,Xe,hf).call(this))},yf=function(){S(this,Il)!==void 0&&(zl.clearTimeout(S(this,Il)),fe(this,Il,void 0))},gf=function(){S(this,Ql)!==void 0&&(zl.clearInterval(S(this,Ql)),fe(this,Ql,void 0))},bf=function(){const l=S(this,Pt).getQueryCache().build(S(this,Pt),this.options);if(l===S(this,Ke))return;const s=S(this,Ke);fe(this,Ke,l),fe(this,ho,l.state),this.hasListeners()&&(s==null||s.removeObserver(this),l.addObserver(this))},qv=function(l){ht.batch(()=>{l.listeners&&this.listeners.forEach(s=>{s(S(this,Qt))}),S(this,Pt).getQueryCache().notify({query:S(this,Ke),type:"observerResultsUpdated"})})},p0);function ME(n,l){return fn(l.enabled,n)!==!1&&n.state.data===void 0&&!(n.state.status==="error"&&fn(l.retryOnMount,n)===!1)}function gb(n,l){return ME(n,l)||n.state.data!==void 0&&vf(n,l,l.refetchOnMount)}function vf(n,l,s){if(fn(l.enabled,n)!==!1&&sl(l.staleTime,n)!=="static"){const o=typeof s=="function"?s(n):s;return o==="always"||o!==!1&&hh(n,l)}return!1}function bb(n,l,s,o){return(n!==l||fn(o.enabled,n)===!1)&&(!s.suspense||n.state.status!=="error")&&hh(n,s)}function hh(n,l){return fn(l.enabled,n)!==!1&&n.isStaleByTime(sl(l.staleTime,n))}function CE(n,l){return!co(n.getCurrentResult(),l)}var mo,qn,Ht,Kl,Gn,Fa,m0,AE=(m0=class extends Lv{constructor(l){super();be(this,Gn);be(this,mo);be(this,qn);be(this,Ht);be(this,Kl);fe(this,mo,l.client),this.mutationId=l.mutationId,fe(this,Ht,l.mutationCache),fe(this,qn,[]),this.state=l.state||Gv(),this.setOptions(l.options),this.scheduleGc()}setOptions(l){this.options=l,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(l){S(this,qn).includes(l)||(S(this,qn).push(l),this.clearGcTimeout(),S(this,Ht).notify({type:"observerAdded",mutation:this,observer:l}))}removeObserver(l){fe(this,qn,S(this,qn).filter(s=>s!==l)),this.scheduleGc(),S(this,Ht).notify({type:"observerRemoved",mutation:this,observer:l})}optionalRemove(){S(this,qn).length||(this.state.status==="pending"?this.scheduleGc():S(this,Ht).remove(this))}continue(){var l;return((l=S(this,Kl))==null?void 0:l.continue())??this.execute(this.state.variables)}async execute(l){var h,p,y,g,x,v,E,M,N,A,j,O,z,D,Y,W,ee,ae;const s=()=>{je(this,Gn,Fa).call(this,{type:"continue"})},o={client:S(this,mo),meta:this.options.meta,mutationKey:this.options.mutationKey};fe(this,Kl,Uv({fn:()=>this.options.mutationFn?this.options.mutationFn(l,o):Promise.reject(new Error("No mutationFn found")),onFail:(U,re)=>{je(this,Gn,Fa).call(this,{type:"failed",failureCount:U,error:re})},onPause:()=>{je(this,Gn,Fa).call(this,{type:"pause"})},onContinue:s,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>S(this,Ht).canRun(this)}));const u=this.state.status==="pending",d=!S(this,Kl).canStart();try{if(u)s();else{je(this,Gn,Fa).call(this,{type:"pending",variables:l,isPaused:d}),S(this,Ht).config.onMutate&&await S(this,Ht).config.onMutate(l,this,o);const re=await((p=(h=this.options).onMutate)==null?void 0:p.call(h,l,o));re!==this.state.context&&je(this,Gn,Fa).call(this,{type:"pending",context:re,variables:l,isPaused:d})}const U=await S(this,Kl).start();return await((g=(y=S(this,Ht).config).onSuccess)==null?void 0:g.call(y,U,l,this.state.context,this,o)),await((v=(x=this.options).onSuccess)==null?void 0:v.call(x,U,l,this.state.context,o)),await((M=(E=S(this,Ht).config).onSettled)==null?void 0:M.call(E,U,null,this.state.variables,this.state.context,this,o)),await((A=(N=this.options).onSettled)==null?void 0:A.call(N,U,null,l,this.state.context,o)),je(this,Gn,Fa).call(this,{type:"success",data:U}),U}catch(U){try{await((O=(j=S(this,Ht).config).onError)==null?void 0:O.call(j,U,l,this.state.context,this,o))}catch(re){Promise.reject(re)}try{await((D=(z=this.options).onError)==null?void 0:D.call(z,U,l,this.state.context,o))}catch(re){Promise.reject(re)}try{await((W=(Y=S(this,Ht).config).onSettled)==null?void 0:W.call(Y,void 0,U,this.state.variables,this.state.context,this,o))}catch(re){Promise.reject(re)}try{await((ae=(ee=this.options).onSettled)==null?void 0:ae.call(ee,void 0,U,l,this.state.context,o))}catch(re){Promise.reject(re)}throw je(this,Gn,Fa).call(this,{type:"error",error:U}),U}finally{S(this,Ht).runNext(this)}}},mo=new WeakMap,qn=new WeakMap,Ht=new WeakMap,Kl=new WeakMap,Gn=new WeakSet,Fa=function(l){const s=o=>{switch(l.type){case"failed":return{...o,failureCount:l.failureCount,failureReason:l.error};case"pause":return{...o,isPaused:!0};case"continue":return{...o,isPaused:!1};case"pending":return{...o,context:l.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:l.isPaused,status:"pending",variables:l.variables,submittedAt:Date.now()};case"success":return{...o,data:l.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...o,data:void 0,error:l.error,failureCount:o.failureCount+1,failureReason:l.error,isPaused:!1,status:"error"}}};this.state=s(this.state),ht.batch(()=>{S(this,qn).forEach(o=>{o.onMutationUpdate(l)}),S(this,Ht).notify({mutation:this,type:"updated",action:l})})},m0);function Gv(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var pa,Nn,yo,y0,NE=(y0=class extends Wl{constructor(l={}){super();be(this,pa);be(this,Nn);be(this,yo);this.config=l,fe(this,pa,new Set),fe(this,Nn,new Map),fe(this,yo,0)}build(l,s,o){const u=new AE({client:l,mutationCache:this,mutationId:++Ir(this,yo)._,options:l.defaultMutationOptions(s),state:o});return this.add(u),u}add(l){S(this,pa).add(l);const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s);o?o.push(l):S(this,Nn).set(s,[l])}this.notify({type:"added",mutation:l})}remove(l){if(S(this,pa).delete(l)){const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s);if(o)if(o.length>1){const u=o.indexOf(l);u!==-1&&o.splice(u,1)}else o[0]===l&&S(this,Nn).delete(s)}}this.notify({type:"removed",mutation:l})}canRun(l){const s=$r(l);if(typeof s=="string"){const o=S(this,Nn).get(s),u=o==null?void 0:o.find(d=>d.state.status==="pending");return!u||u===l}else return!0}runNext(l){var o;const s=$r(l);if(typeof s=="string"){const u=(o=S(this,Nn).get(s))==null?void 0:o.find(d=>d!==l&&d.state.isPaused);return(u==null?void 0:u.continue())??Promise.resolve()}else return Promise.resolve()}clear(){ht.batch(()=>{S(this,pa).forEach(l=>{this.notify({type:"removed",mutation:l})}),S(this,pa).clear(),S(this,Nn).clear()})}getAll(){return Array.from(S(this,pa))}find(l){const s={exact:!0,...l};return this.getAll().find(o=>db(s,o))}findAll(l={}){return this.getAll().filter(s=>db(l,s))}notify(l){ht.batch(()=>{this.listeners.forEach(s=>{s(l)})})}resumePausedMutations(){const l=this.getAll().filter(s=>s.state.isPaused);return ht.batch(()=>Promise.all(l.map(s=>s.continue().catch(qt))))}},pa=new WeakMap,Nn=new WeakMap,yo=new WeakMap,y0);function $r(n){var l;return(l=n.options.scope)==null?void 0:l.id}var ma,tl,Jt,ya,ba,Wr,xf,g0,TE=(g0=class extends Wl{constructor(s,o){super();be(this,ba);be(this,ma);be(this,tl);be(this,Jt);be(this,ya);fe(this,ma,s),this.setOptions(o),this.bindMethods(),je(this,ba,Wr).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(s){var u;const o=this.options;this.options=S(this,ma).defaultMutationOptions(s),co(this.options,o)||S(this,ma).getMutationCache().notify({type:"observerOptionsUpdated",mutation:S(this,Jt),observer:this}),o!=null&&o.mutationKey&&this.options.mutationKey&&Zl(o.mutationKey)!==Zl(this.options.mutationKey)?this.reset():((u=S(this,Jt))==null?void 0:u.state.status)==="pending"&&S(this,Jt).setOptions(this.options)}onUnsubscribe(){var s;this.hasListeners()||(s=S(this,Jt))==null||s.removeObserver(this)}onMutationUpdate(s){je(this,ba,Wr).call(this),je(this,ba,xf).call(this,s)}getCurrentResult(){return S(this,tl)}reset(){var s;(s=S(this,Jt))==null||s.removeObserver(this),fe(this,Jt,void 0),je(this,ba,Wr).call(this),je(this,ba,xf).call(this)}mutate(s,o){var u;return fe(this,ya,o),(u=S(this,Jt))==null||u.removeObserver(this),fe(this,Jt,S(this,ma).getMutationCache().build(S(this,ma),this.options)),S(this,Jt).addObserver(this),S(this,Jt).execute(s)}},ma=new WeakMap,tl=new WeakMap,Jt=new WeakMap,ya=new WeakMap,ba=new WeakSet,Wr=function(){var o;const s=((o=S(this,Jt))==null?void 0:o.state)??Gv();fe(this,tl,{...s,isPending:s.status==="pending",isSuccess:s.status==="success",isError:s.status==="error",isIdle:s.status==="idle",mutate:this.mutate,reset:this.reset})},xf=function(s){ht.batch(()=>{var o,u,d,h,p,y,g,x;if(S(this,ya)&&this.hasListeners()){const v=S(this,tl).variables,E=S(this,tl).context,M={client:S(this,ma),meta:this.options.meta,mutationKey:this.options.mutationKey};if((s==null?void 0:s.type)==="success"){try{(u=(o=S(this,ya)).onSuccess)==null||u.call(o,s.data,v,E,M)}catch(N){Promise.reject(N)}try{(h=(d=S(this,ya)).onSettled)==null||h.call(d,s.data,null,v,E,M)}catch(N){Promise.reject(N)}}else if((s==null?void 0:s.type)==="error"){try{(y=(p=S(this,ya)).onError)==null||y.call(p,s.error,v,E,M)}catch(N){Promise.reject(N)}try{(x=(g=S(this,ya)).onSettled)==null||x.call(g,void 0,s.error,v,E,M)}catch(N){Promise.reject(N)}}}this.listeners.forEach(v=>{v(S(this,tl))})})},g0);function vb(n,l){const s=new Set(l);return n.filter(o=>!s.has(o))}function OE(n,l,s){const o=n.slice(0);return o[l]=s,o}var es,Wt,ts,Vl,un,nl,go,bo,vo,xo,kt,_f,wf,Iv,Sf,kf,Ef,b0,RE=(b0=class extends Wl{constructor(l,s,o){super();be(this,kt);be(this,es);be(this,Wt);be(this,ts);be(this,Vl);be(this,un);be(this,nl);be(this,go);be(this,bo);be(this,vo);be(this,xo,[]);fe(this,es,l),fe(this,Vl,o),fe(this,ts,[]),fe(this,un,[]),fe(this,Wt,[]),this.setQueries(s)}onSubscribe(){this.listeners.size===1&&S(this,un).forEach(l=>{l.subscribe(s=>{je(this,kt,kf).call(this,l,s)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,S(this,un).forEach(l=>{l.destroy()})}setQueries(l,s){fe(this,ts,l),fe(this,Vl,s),ht.batch(()=>{const o=S(this,un),u=je(this,kt,Sf).call(this,S(this,ts));u.forEach(v=>v.observer.setOptions(v.defaultedQueryOptions));const d=u.map(v=>v.observer),h=d.map(v=>v.getCurrentResult()),p=o.length!==d.length,y=d.some((v,E)=>v!==o[E]),g=p||y,x=g?!0:h.some((v,E)=>{const M=S(this,Wt)[E];return!M||!co(v,M)});!g&&!x||(g&&(fe(this,xo,u),fe(this,un,d)),fe(this,Wt,h),this.hasListeners()&&(g&&(vb(o,d).forEach(v=>{v.destroy()}),vb(d,o).forEach(v=>{v.subscribe(E=>{je(this,kt,kf).call(this,v,E)})})),je(this,kt,Ef).call(this)))})}getCurrentResult(){return S(this,Wt)}getQueries(){return S(this,un).map(l=>l.getCurrentQuery())}getObservers(){return S(this,un)}getOptimisticResult(l,s){const o=je(this,kt,Sf).call(this,l),u=o.map(h=>h.observer.getOptimisticResult(h.defaultedQueryOptions)),d=o.map(h=>h.defaultedQueryOptions.queryHash);return[u,h=>je(this,kt,wf).call(this,h??u,s,d),()=>je(this,kt,_f).call(this,u,o)]}},es=new WeakMap,Wt=new WeakMap,ts=new WeakMap,Vl=new WeakMap,un=new WeakMap,nl=new WeakMap,go=new WeakMap,bo=new WeakMap,vo=new WeakMap,xo=new WeakMap,kt=new WeakSet,_f=function(l,s){return s.map((o,u)=>{const d=l[u];return o.defaultedQueryOptions.notifyOnChangeProps?d:o.observer.trackResult(d,h=>{s.forEach(p=>{p.observer.trackProp(h)})})})},wf=function(l,s,o){if(s){const u=S(this,vo),d=o!==void 0&&u!==void 0&&(u.length!==o.length||o.some((h,p)=>h!==u[p]));return(!S(this,nl)||S(this,Wt)!==S(this,bo)||d||s!==S(this,go))&&(fe(this,go,s),fe(this,bo,S(this,Wt)),o!==void 0&&fe(this,vo,o),fe(this,nl,ch(S(this,nl),s(l)))),S(this,nl)}return l},Iv=function(){var l;return((l=S(this,Vl))==null?void 0:l.combine)!==void 0&&S(this,un).some((s,o)=>{var u;return s.options.suspense&&((u=S(this,Wt)[o])==null?void 0:u.data)===void 0})},Sf=function(l){const s=new Map;S(this,un).forEach(u=>{const d=u.options.queryHash;if(!d)return;const h=s.get(d);h?h.push(u):s.set(d,[u])});const o=[];return l.forEach(u=>{var y;const d=S(this,es).defaultQueryOptions(u),p=((y=s.get(d.queryHash))==null?void 0:y.shift())??new fh(S(this,es),d);o.push({defaultedQueryOptions:d,observer:p})}),o},kf=function(l,s){const o=S(this,un).indexOf(l);o!==-1&&(fe(this,Wt,OE(S(this,Wt),o,s)),je(this,kt,Ef).call(this))},Ef=function(){var l;if(this.hasListeners()){const s=je(this,kt,_f).call(this,S(this,Wt),S(this,xo)),o=je(this,kt,Iv).call(this),u=S(this,nl),d=o?u:je(this,kt,wf).call(this,s,(l=S(this,Vl))==null?void 0:l.combine);(o||u!==d)&&ht.batch(()=>{this.listeners.forEach(h=>{h(S(this,Wt))})})}},b0),In,v0,zE=(v0=class extends Wl{constructor(l={}){super();be(this,In);this.config=l,fe(this,In,new Map)}build(l,s,o){const u=s.queryKey,d=s.queryHash??rh(u,s);let h=this.get(d);return h||(h=new jE({client:l,queryKey:u,queryHash:d,options:l.defaultQueryOptions(s),state:o,defaultOptions:l.getQueryDefaults(u)}),this.add(h)),h}add(l){S(this,In).has(l.queryHash)||(S(this,In).set(l.queryHash,l),this.notify({type:"added",query:l}))}remove(l){const s=S(this,In).get(l.queryHash);s&&(l.destroy(),s===l&&S(this,In).delete(l.queryHash),this.notify({type:"removed",query:l}))}clear(){ht.batch(()=>{this.getAll().forEach(l=>{this.remove(l)})})}get(l){return S(this,In).get(l)}getAll(){return[...S(this,In).values()]}find(l){const s={exact:!0,...l};return this.getAll().find(o=>ub(s,o))}findAll(l={}){const s=this.getAll();return Object.keys(l).length>0?s.filter(o=>ub(l,o)):s}notify(l){ht.batch(()=>{this.listeners.forEach(s=>{s(l)})})}onFocus(){ht.batch(()=>{this.getAll().forEach(l=>{l.onFocus()})})}onOnline(){ht.batch(()=>{this.getAll().forEach(l=>{l.onOnline()})})}},In=new WeakMap,v0),ft,al,ll,ns,as,il,ls,is,x0,DE=(x0=class{constructor(n={}){be(this,ft);be(this,al);be(this,ll);be(this,ns);be(this,as);be(this,il);be(this,ls);be(this,is);fe(this,ft,n.queryCache||new zE),fe(this,al,n.mutationCache||new NE),fe(this,ll,n.defaultOptions||{}),fe(this,ns,new Map),fe(this,as,new Map),fe(this,il,0)}mount(){Ir(this,il)._++,S(this,il)===1&&(fe(this,ls,oh.subscribe(async n=>{n&&(await this.resumePausedMutations(),S(this,ft).onFocus())})),fe(this,is,lc.subscribe(async n=>{n&&(await this.resumePausedMutations(),S(this,ft).onOnline())})))}unmount(){var n,l;Ir(this,il)._--,S(this,il)===0&&((n=S(this,ls))==null||n.call(this),fe(this,ls,void 0),(l=S(this,is))==null||l.call(this),fe(this,is,void 0))}isFetching(n){return S(this,ft).findAll({...n,fetchStatus:"fetching"}).length}isMutating(n){return S(this,al).findAll({...n,status:"pending"}).length}getQueryData(n){var s;const l=this.defaultQueryOptions({queryKey:n});return(s=S(this,ft).get(l.queryHash))==null?void 0:s.state.data}ensureQueryData(n){const l=this.defaultQueryOptions(n),s=S(this,ft).build(this,l),o=s.state.data;return o===void 0?this.fetchQuery(n):(n.revalidateIfStale&&s.isStaleByTime(sl(l.staleTime,s))&&this.prefetchQuery(l),Promise.resolve(o))}getQueriesData(n){return S(this,ft).findAll(n).map(({queryKey:l,state:s})=>{const o=s.data;return[l,o]})}setQueryData(n,l,s){const o=this.defaultQueryOptions({queryKey:n}),u=S(this,ft).get(o.queryHash),d=u==null?void 0:u.state.data,h=pE(l,d);if(h!==void 0)return S(this,ft).build(this,o).setData(h,{...s,manual:!0})}setQueriesData(n,l,s){return ht.batch(()=>S(this,ft).findAll(n).map(({queryKey:o})=>[o,this.setQueryData(o,l,s)]))}getQueryState(n){var s;const l=this.defaultQueryOptions({queryKey:n});return(s=S(this,ft).get(l.queryHash))==null?void 0:s.state}removeQueries(n){const l=S(this,ft);ht.batch(()=>{l.findAll(n).forEach(s=>{l.remove(s)})})}resetQueries(n,l){const s=S(this,ft);return ht.batch(()=>(s.findAll(n).forEach(o=>{o.reset()}),this.refetchQueries({type:"active",...n},l)))}cancelQueries(n,l={}){const s={revert:!0,...l},o=ht.batch(()=>S(this,ft).findAll(n).map(u=>u.cancel(s)));return Promise.all(o).then(qt).catch(qt)}invalidateQueries(n,l={}){return ht.batch(()=>(S(this,ft).findAll(n).forEach(s=>{s.invalidate()}),(n==null?void 0:n.refetchType)==="none"?Promise.resolve():this.refetchQueries({...n,type:(n==null?void 0:n.refetchType)??(n==null?void 0:n.type)??"active"},l)))}refetchQueries(n,l={}){const s={...l,cancelRefetch:l.cancelRefetch??!0},o=ht.batch(()=>S(this,ft).findAll(n).filter(u=>!u.isDisabled()&&!u.isStatic()).map(u=>{let d=u.fetch(void 0,s);return s.throwOnError||(d=d.catch(qt)),u.state.fetchStatus==="paused"?Promise.resolve():d}));return Promise.all(o).then(qt)}fetchQuery(n){const l=this.defaultQueryOptions(n);l.retry===void 0&&(l.retry=!1);const s=S(this,ft).build(this,l);return s.isStaleByTime(sl(l.staleTime,s))?s.fetch(l):Promise.resolve(s.state.data)}prefetchQuery(n){return this.fetchQuery(n).then(qt).catch(qt)}fetchInfiniteQuery(n){return n._type="infinite",this.fetchQuery(n)}prefetchInfiniteQuery(n){return this.fetchInfiniteQuery(n).then(qt).catch(qt)}ensureInfiniteQueryData(n){return n._type="infinite",this.ensureQueryData(n)}resumePausedMutations(){return lc.isOnline()?S(this,al).resumePausedMutations():Promise.resolve()}getQueryCache(){return S(this,ft)}getMutationCache(){return S(this,al)}getDefaultOptions(){return S(this,ll)}setDefaultOptions(n){fe(this,ll,n)}setQueryDefaults(n,l){S(this,ns).set(Zl(n),{queryKey:n,defaultOptions:l})}getQueryDefaults(n){const l=[...S(this,ns).values()],s={};return l.forEach(o=>{os(n,o.queryKey)&&Object.assign(s,o.defaultOptions)}),s}setMutationDefaults(n,l){S(this,as).set(Zl(n),{mutationKey:n,defaultOptions:l})}getMutationDefaults(n){const l=[...S(this,as).values()],s={};return l.forEach(o=>{os(n,o.mutationKey)&&Object.assign(s,o.defaultOptions)}),s}defaultQueryOptions(n){if(n._defaulted)return n;const l={...S(this,ll).queries,...this.getQueryDefaults(n.queryKey),...n,_defaulted:!0};return l.queryHash||(l.queryHash=rh(l.queryKey,l)),l.refetchOnReconnect===void 0&&(l.refetchOnReconnect=l.networkMode!=="always"),l.throwOnError===void 0&&(l.throwOnError=!!l.suspense),!l.networkMode&&l.persister&&(l.networkMode="offlineFirst"),l.queryFn===uh&&(l.enabled=!1),l}defaultMutationOptions(n){return n!=null&&n._defaulted?n:{...S(this,ll).mutations,...(n==null?void 0:n.mutationKey)&&this.getMutationDefaults(n.mutationKey),...n,_defaulted:!0}}clear(){S(this,ft).clear(),S(this,al).clear()}},ft=new WeakMap,al=new WeakMap,ll=new WeakMap,ns=new WeakMap,as=new WeakMap,il=new WeakMap,ls=new WeakMap,is=new WeakMap,x0),Qv=_.createContext(void 0),cs=n=>{const l=_.useContext(Qv);if(!l)throw new Error("No QueryClient set, use QueryClientProvider to set one");return l},UE=({client:n,children:l})=>(_.useEffect(()=>(n.mount(),()=>{n.unmount()}),[n]),f.jsx(Qv.Provider,{value:n,children:l})),Kv=_.createContext(!1),Vv=()=>_.useContext(Kv);Kv.Provider;function LE(){let n=!1;return{clearReset:()=>{n=!1},reset:()=>{n=!0},isReset:()=>n}}var BE=_.createContext(LE()),Yv=()=>_.useContext(BE),$v=(n,l,s)=>{const o=s!=null&&s.state.error&&typeof n.throwOnError=="function"?dh(n.throwOnError,[s.state.error,s]):n.throwOnError;(n.suspense||n.experimental_prefetchInRender||o)&&(l.isReset()||(n.retryOnMount=!1))},Fv=n=>{_.useEffect(()=>{n.clearReset()},[n])},Xv=({result:n,errorResetBoundary:l,throwOnError:s,query:o,suspense:u})=>n.isError&&!l.isReset()&&!n.isFetching&&o&&(u&&n.data===void 0||dh(s,[n.error,o])),Zv=n=>{if(n.suspense){const s=u=>u==="static"?u:Math.max(u??1e3,1e3),o=n.staleTime;n.staleTime=typeof o=="function"?(...u)=>s(o(...u)):s(o),typeof n.gcTime=="number"&&(n.gcTime=Math.max(n.gcTime,1e3))}},HE=(n,l)=>n.isLoading&&n.isFetching&&!l,jf=(n,l)=>(n==null?void 0:n.suspense)&&l.isPending,Mf=(n,l,s)=>l.fetchOptimistic(n).catch(()=>{s.clearReset()});function qE({queries:n,...l},s){const o=cs(),u=Vv(),d=Yv(),h=_.useMemo(()=>n.map(A=>{const j=o.defaultQueryOptions(A);return j._optimisticResults=u?"isRestoring":"optimistic",j}),[n,o,u]);h.forEach(A=>{Zv(A);const j=o.getQueryCache().get(A.queryHash);$v(A,d,j)}),Fv(d);const[p]=_.useState(()=>new RE(o,h,l)),[y,g,x]=p.getOptimisticResult(h,l.combine),v=!u&&l.subscribed!==!1;_.useSyncExternalStore(_.useCallback(A=>v?p.subscribe(ht.batchCalls(A)):qt,[p,v]),()=>p.getCurrentResult(),()=>p.getCurrentResult()),_.useEffect(()=>{p.setQueries(h,l)},[h,l,p]);const M=y.some((A,j)=>jf(h[j],A))?y.flatMap((A,j)=>{const O=h[j];if(O&&jf(O,A)){const z=new fh(o,O);return Mf(O,z,d)}return[]}):[];if(M.length>0)throw Promise.all(M);const N=y.find((A,j)=>{const O=h[j];return O&&Xv({result:A,errorResetBoundary:d,throwOnError:O.throwOnError,query:o.getQueryCache().get(O.queryHash),suspense:O.suspense})});if(N!=null&&N.error)throw N.error;return g(x())}function GE(n,l,s){var M,N,A,j;const o=Vv(),u=Yv(),d=cs(),h=d.defaultQueryOptions(n);(N=(M=d.getDefaultOptions().queries)==null?void 0:M._experimental_beforeQuery)==null||N.call(M,h);const p=d.getQueryCache().get(h.queryHash),y=n.subscribed!==!1;h._optimisticResults=o?"isRestoring":y?"optimistic":void 0,Zv(h),$v(h,u,p),Fv(u);const g=!d.getQueryCache().get(h.queryHash),[x]=_.useState(()=>new l(d,h)),v=x.getOptimisticResult(h),E=!o&&y;if(_.useSyncExternalStore(_.useCallback(O=>{const z=E?x.subscribe(ht.batchCalls(O)):qt;return x.updateResult(),z},[x,E]),()=>x.getCurrentResult(),()=>x.getCurrentResult()),_.useEffect(()=>{x.setOptions(h)},[h,x]),jf(h,v))throw Mf(h,x,u);if(Xv({result:v,errorResetBoundary:u,throwOnError:h.throwOnError,query:p,suspense:h.suspense}))throw v.error;if((j=(A=d.getDefaultOptions().queries)==null?void 0:A._experimental_afterQuery)==null||j.call(A,h,v),h.experimental_prefetchInRender&&!uo.isServer()&&HE(v,o)){const O=g?Mf(h,x,u):p==null?void 0:p.promise;O==null||O.catch(qt).finally(()=>{x.updateResult()})}return h.notifyOnChangeProps?v:x.trackResult(v)}function en(n,l){return GE(n,fh)}function IE(n,l){const s=cs(),[o]=_.useState(()=>new TE(s,n));_.useEffect(()=>{o.setOptions(n)},[o,n]);const u=_.useSyncExternalStore(_.useCallback(h=>o.subscribe(ht.batchCalls(h)),[o]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),d=_.useCallback((h,p)=>{o.mutate(h,p).catch(qt)},[o]);if(u.error&&dh(o.options.throwOnError,[u.error]))throw u.error;return{...u,mutate:d,mutateAsync:u.mutate}}const xb=n=>{let l;const s=new Set,o=(g,x)=>{const v=typeof g=="function"?g(l):g;if(!Object.is(v,l)){const E=l;l=x??(typeof v!="object"||v===null)?v:Object.assign({},l,v),s.forEach(M=>M(l,E))}},u=()=>l,p={setState:o,getState:u,getInitialState:()=>y,subscribe:g=>(s.add(g),()=>s.delete(g))},y=l=n(o,u,p);return p},QE=(n=>n?xb(n):xb),KE=n=>n;function VE(n,l=KE){const s=Qr.useSyncExternalStore(n.subscribe,Qr.useCallback(()=>l(n.getState()),[n,l]),Qr.useCallback(()=>l(n.getInitialState()),[n,l]));return Qr.useDebugValue(s),s}const _b=n=>{const l=QE(n),s=o=>VE(l,o);return Object.assign(s,l),s},Pv=(n=>n?_b(n):_b),En=Pv(n=>({byKey:{},noticeByKey:{},watchedByKey:{},start:(l,s)=>n(o=>({byKey:{...o.byKey,[l]:s},noticeByKey:wb(o.noticeByKey,l),watchedByKey:{...o.watchedByKey,[l]:s.cropKey}})),finish:l=>n(s=>{if(!(l in s.byKey))return s;const o={...s.byKey};return delete o[l],{byKey:o}}),notice:(l,s)=>n(o=>o.noticeByKey[l]===s?o:{noticeByKey:{...o.noticeByKey,[l]:s}}),clearNotice:l=>n(s=>l in s.noticeByKey?{noticeByKey:wb(s.noticeByKey,l)}:s)}));function wb(n,l){if(!(l in n))return n;const s={...n};return delete s[l],s}function YE(n){return En(l=>l.noticeByKey[n])}const Sb=1e3,$E=6e4;function FE({getJobStatus:n}){const l=En(s=>s.byKey);return f.jsx(f.Fragment,{children:Object.entries(l).map(([s,o])=>f.jsx(XE,{entryKey:s,entry:o,getJobStatus:n},o.jobId))})}function XE({entryKey:n,entry:l,getJobStatus:s}){var j,O;const o=En(z=>z.finish),u=En(z=>z.notice),{jobId:d,propertyId:h,cropKey:p,mobileJobId:y,mobileCropKey:g,apply:x,revert:v}=l,E=en({queryKey:["image-crop-job",h,d],queryFn:()=>s(h,d),refetchInterval:z=>{var Y;const D=(Y=z.state.data)==null?void 0:Y.status;return D==="succeeded"||D==="failed"?!1:Sb}}),M=en({queryKey:["image-crop-job",h,y],queryFn:()=>s(h,y),enabled:!!y,refetchInterval:z=>{var Y;const D=(Y=z.state.data)==null?void 0:Y.status;return D==="succeeded"||D==="failed"?!1:Sb}}),N=(j=E.data)==null?void 0:j.status,A=y?(O=M.data)==null?void 0:O.status:void 0;return _.useEffect(()=>{!(N==="succeeded"||N==="failed")||!(!y||A==="succeeded"||A==="failed")||(N==="failed"||A==="failed"?(v(),u(n,"failed"),o(n)):(x(p,y?g:void 0),o(n)))},[N,A,y,n,p,g,x,v,u,o]),_.useEffect(()=>{const z=setTimeout(()=>{u(n,"slow"),o(n)},$E);return()=>clearTimeout(z)},[n,u,o]),null}function ZE(n){if(!n||typeof n!="object")return null;const l=n;return typeof l.job_id!="string"||typeof l.crop_key!="string"||!l.rect||typeof l.rect!="object"||typeof l.ar!="number"?null:l}function Jv(n,l){_.useEffect(()=>{var s,o;for(const u of n){const d=En.getState();if(u.key in d.byKey||d.watchedByKey[u.key]===u.pending.crop_key)continue;const h=l(u);d.start(u.key,{jobId:u.pending.job_id,propertyId:u.propertyId,cropKey:u.pending.crop_key,mobileJobId:(s=u.pending.mobile)==null?void 0:s.job_id,mobileCropKey:(o=u.pending.mobile)==null?void 0:o.crop_key,instanceId:u.instanceId,slotId:u.slotId,itemIndex:u.itemIndex,apply:h.apply,revert:h.revert})}})}const ec={dimOpacity:.35,grayscale:.4,transitionMs:120,spinner:{diameter:28,stroke:3,trackColor:"rgba(20,18,13,.18)",headColor:"rgba(20,18,13,.6)",spinDurationMs:800}},PE={opacity:ec.dimOpacity,filter:`grayscale(${ec.grayscale})`,transition:`opacity ${ec.transitionMs}ms`};function JE(){if(typeof document>"u"||document.getElementById("recrop-spin-kf"))return;const n=document.createElement("style");n.id="recrop-spin-kf",n.textContent="@keyframes recrop-spin{to{transform:rotate(360deg)}}",document.head.appendChild(n)}function Wv(){JE();const n=ec.spinner;return f.jsx("div",{"data-recrop-loading":!0,role:"status","aria-label":"Re-cropping…",className:"pointer-events-none absolute inset-0 z-[5] grid place-items-center",children:f.jsx("span",{"aria-hidden":!0,style:{width:n.diameter,height:n.diameter,border:`${n.stroke}px solid ${n.trackColor}`,borderTopColor:n.headColor,borderRadius:"50%",animation:`recrop-spin ${n.spinDurationMs}ms linear infinite`}})})}function e1(n,l,s){const o=_.useMemo(()=>[...new Set(l.filter(d=>!!d))],[l]),u=qE({queries:o.map(d=>({queryKey:["crop-url",n,d],queryFn:()=>s(n,d),enabled:!!n,staleTime:600*1e3}))});return _.useMemo(()=>{const d=new Map;return o.forEach((h,p)=>{var g;const y=(g=u[p])==null?void 0:g.data;typeof y=="string"&&d.set(h,y)}),d},[o,u])}const t1=_.createContext(null);function WE({api:n,children:l}){return f.jsx(t1.Provider,{value:n,children:l})}function Kn(){const n=_.useContext(t1);if(!n)throw new Error("useMediaLibraryApi: missing MediaLibraryApiProvider");return n}const ic=[{extension:".pdf",mimeTypes:["application/pdf"],family:"pdf"},{extension:".csv",mimeTypes:["text/csv","application/vnd.ms-excel"],family:"spreadsheet"},{extension:".xlsx",mimeTypes:["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],family:"spreadsheet"},{extension:".docx",mimeTypes:["application/vnd.openxmlformats-officedocument.wordprocessingml.document"],family:"text-document"},{extension:".doc",mimeTypes:["application/msword"],family:"text-document"},{extension:".txt",mimeTypes:["text/plain"],family:"text-document"},{extension:".pptx",mimeTypes:["application/vnd.openxmlformats-officedocument.presentationml.presentation"],family:"presentation"}],n1=new Set(ic.map(n=>n.extension)),a1=new Set(ic.flatMap(n=>n.mimeTypes));function hc(n){const l=n.indexOf(";");return(l===-1?n:n.slice(0,l)).trim().toLowerCase()}function ph(n){const l=Math.max(n.lastIndexOf("/"),n.lastIndexOf("\\")),s=n.slice(l+1),o=s.lastIndexOf(".");return o<=0?"":s.slice(o).toLowerCase()}function e3(n){return hc(n).startsWith("image/")}function t3(n){return hc(n).startsWith("video/")}function l1(n,l){return n1.has(ph(n))&&a1.has(hc(l))}function n3(n,l){return e3(l)||t3(l)||l1(n,l)}function a3(n,l){const s=ph(n),o=ic.find(h=>h.extension===s);if(o)return o.family;const u=hc(l),d=ic.find(h=>h.mimeTypes.includes(u));return d?d.family:null}const l3=[...a1,...n1].join(","),i3="an image, a video, or a document (PDF, Word, Excel .xlsx, PowerPoint .pptx, CSV, or text)";function s3(n){switch(n){case"pdf":return{glyph:"doc",typeNoun:"PDF"};case"spreadsheet":return{glyph:"spreadsheet",typeNoun:"Spreadsheet"};case"text-document":return{glyph:"doc",typeNoun:"Document"};case"presentation":return{glyph:"presentation",typeNoun:"Presentation"}}}function o3(n,l){const s=a3(n,l),{glyph:o,typeNoun:u}=s===null?{glyph:"doc",typeNoun:"File"}:s3(s);return{glyph:o,typeNoun:u,extension:ph(n).replace(".","").toUpperCase()}}const Tn={items:[],subs:new Set};function mh(){Tn.subs.forEach(n=>n())}function r3(n){Tn.items=[n,...Tn.items],mh()}function da(n,l){Tn.items=Tn.items.map(s=>s.id===n?{...s,...l}:s),mh()}function kb(n){Tn.items=Tn.items.filter(l=>l.id!==n),mh()}function Eb(){return Tn.items}function c3(){const[,n]=_.useReducer(l=>l+1,0);return _.useEffect(()=>(Tn.subs.add(n),()=>{Tn.subs.delete(n)}),[]),Tn.items}function i1(n){return n<1024?`${n} B`:n<1048576?`${(n/1024).toFixed(0)} KB`:`${(n/1048576).toFixed(1)} MB`}const u3=Pv(n=>({byPlan:{},start:(l,s,o)=>n(u=>({byPlan:{...u.byPlan,[l]:{jobId:s,propertyId:o}}})),advance:(l,s)=>n(o=>{const u=o.byPlan[l];return!u||u.jobId===s?o:{byPlan:{...o.byPlan,[l]:{...u,jobId:s}}}}),finish:l=>n(s=>{if(!(l in s.byPlan))return s;const o={...s.byPlan};return delete o[l],{byPlan:o}})})),d3=5,jb=500*1024*1024;function Mb(n){return`${Math.round(n/(1024*1024))} MB`}function s1(n){return n.size>jb?{ok:!1,message:`This file is ${Mb(n.size)}. The maximum upload size is ${Mb(jb)}.`}:n3(n.name,n.type)?{ok:!0}:{ok:!1,message:`This file type (${n.type||"unknown"}) isn't supported. Upload ${i3}.`}}function f3(n){const l=s1(n);return l.ok?n.type.startsWith("image/")?{ok:!0}:{ok:!1,message:`A floor plan has to be an image. This file is ${n.type||"of an unknown type"}.`}:l}function h3(n){return n.committedUploadId?{kind:"replace",uploadId:n.committedUploadId}:n.attempt?{kind:"resume",attempt:n.attempt}:{kind:"fresh"}}function p3(n){return{id:n.id,kind:"document",name:n.name,size:n.size_bytes>0?i1(n.size_bytes):"",src:n.preview_url,mime:n.mime}}function o1(n){var o;const{getDocuments:l}=Kn(),s=en({queryKey:["documents",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.documents)??[]).map(p3),isLoading:s.isLoading}}function m3(n){var s;const l=new Map;for(const o of n){const u=((s=o.source)==null?void 0:s.upload_id)??o.id;l.has(u)||l.set(u,o)}return[...l.entries()].map(([o,u])=>({id:o,kind:"plan",name:u.display_label||"Floor plan",size:"",src:u.thumbnail_url}))}function y3(n){var o;const{getFloorplans:l}=Kn(),s=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n});return{items:m3(((o=s.data)==null?void 0:o.floorplans)??[]),isLoading:s.isLoading}}async function g3(n,l,s){let o=0;const u=Math.max(1,Math.min(l,n.length)),d=Array.from({length:u},async()=>{for(;o<n.length;){const h=o++;try{await s(n[h],h)}catch{}}});await Promise.all(d)}function b3(n){return{id:n.id,kind:"plan",name:n.display_label,size:"",src:n.thumbnail_url,caption:null,ready:n.ready}}function r1(n){var o;const{getFloorplans:l}=Kn(),s=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.floorplans)??[]).map(b3),isLoading:s.isLoading}}function v3(n){var o;const{getFloorplans:l}=Kn();return((o=en({queryKey:["floorplan-library",n],queryFn:()=>l(n),enabled:!!n}).data)==null?void 0:o.floorplans)??[]}function x3(n,l){n.invalidateQueries({queryKey:["floorplan-library",l]}),n.invalidateQueries({queryKey:["floorplans",l]})}function c1(n){return n.type.startsWith("video/")?"video":l1(n.name,n.type)?"document":"photo"}function _3(n){switch(n){case"photo":case"video":case"document":return n;case"floor_plan":case"link":case null:return null}}function w3(n,l){return[`${n}s`,l]}function S3(n){const{deleteUpload:l,getUploads:s,postUploadWithProgress:o}=Kn(),u=cs(),d=c3(),h=_.useCallback((v,E,M)=>(da(v,{status:"uploading",error:void 0}),o(n,E,()=>{},{...M,onAttempt:N=>da(v,{attempt:N??void 0})}).then(N=>{da(v,{id:N.id,status:"classifying",committedUploadId:N.id})}).catch(N=>{da(v,{status:"failed",error:N instanceof Error?N.message:"Upload failed"})})),[n,o]),p=_.useCallback((v,E)=>{const M=v?Array.from(v):[],N=(E==null?void 0:E.declaredType)==="floor_plan",A=[];for(const j of M){const O=crypto.randomUUID(),z=N?f3(j):s1(j),D=N?"plan":c1(j);r3({id:O,kind:D,name:j.name,size:i1(j.size),src:D==="photo"||D==="plan"?URL.createObjectURL(j):"",status:z.ok?"uploading":"failed",error:z.ok?void 0:z.message,file:j}),z.ok&&A.push({tempId:O,file:j})}g3(A,d3,async j=>{await h(j.tempId,j.file,E)})},[h]),y=_.useCallback(v=>{const E=Eb().find(A=>A.id===v);if(!E)return;const M=E.kind==="plan"?{declaredType:"floor_plan"}:void 0,N=h3(E);if(N.kind==="resume"){h(v,E.file,{...M,attempt:N.attempt});return}if(N.kind==="fresh"){h(v,E.file,M);return}da(v,{status:"uploading",error:void 0}),l(n,N.uploadId).then(()=>(da(v,{attempt:void 0,committedUploadId:void 0}),h(v,E.file,M))).catch(A=>{da(v,{status:"failed",error:A instanceof Error?A.message:"Upload failed"})})},[h,l,n]),g=d.some(v=>v.status==="classifying"),x=en({queryKey:["editor-upload-status",n],queryFn:()=>s(n),enabled:g,refetchInterval:g?1500:!1});return _.useEffect(()=>{var A;const v=(A=x.data)==null?void 0:A.uploads;if(!v)return;const E=new Map(v.map(j=>[j.id,j])),M=new Set;let N=!1;for(const j of Eb()){if(j.status!=="classifying")continue;const O=E.get(j.id);if(!O)continue;if(O.status==="failed"){da(j.id,{status:"failed",error:"Processing failed"});continue}if(j.kind==="plan"){kb(j.id),N=!0;continue}if(O.status!=="ready")continue;const z=_3(O.type);if(z===null){da(j.id,{status:"not_photo",error:`Classified as ${O.type??"non-photo"}`});continue}kb(j.id),M.add(z)}for(const j of M)u.invalidateQueries({queryKey:w3(j,n)});N&&x3(u,n)},[x.data,n,u]),{items:d,addFiles:p,retry:y}}function Fr(n){return typeof n=="string"&&n.length>0?n:null}function k3(n){var s,o,u,d;const l=[];for(const h of n){const p=Fr((s=h.fields)==null?void 0:s.name),y=Fr((o=h.fields)==null?void 0:o.avatar_upload_id);y&&h.avatar_url&&l.push({id:y,kind:"library",name:p?`${p} — headshot`:"Headshot",size:"",src:h.avatar_url,caption:null});const g=Fr((u=h.fields)==null?void 0:u.logo_dark_upload_id);g&&h.logo_dark_url&&l.push({id:g,kind:"library",name:p?`${p} — logo (dark)`:"Logo (dark)",size:"",src:h.logo_dark_url,caption:null});const x=Fr((d=h.fields)==null?void 0:d.logo_light_upload_id);x&&h.logo_light_url&&l.push({id:x,kind:"library",name:p?`${p} — logo (light)`:"Logo (light)",size:"",src:h.logo_light_url,caption:null})}return l}const E3=["library-items","contact"];function u1(){var s;const{listLibraryItems:n}=Kn(),l=en({queryKey:E3,queryFn:()=>n("contact")});return{items:k3(((s=l.data)==null?void 0:s.items)??[]),isLoading:l.isLoading}}function j3(n){return{id:n.id,kind:"video",name:n.name,size:"",src:n.poster_url,caption:n.caption??null,ready:n.ready,durationMs:n.duration_ms,videoSource:n.source,...n.provider!==null?{provider:n.provider}:{}}}function So(n){var o;const{getVideos:l}=Kn(),s=en({queryKey:["videos",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.videos)??[]).map(j3),isLoading:s.isLoading}}function d1(n){if(n==null||!Number.isFinite(n)||n<0)return"";const l=Math.round(n/1e3),s=Math.floor(l/60),o=l%60;return`${s}:${String(o).padStart(2,"0")}`}function M3(n){return{id:n.id,kind:"photo",name:n.name,size:"",src:n.thumbnail_url,caption:n.caption??null}}function yh(n){var o;const{getPhotos:l}=Kn(),s=en({queryKey:["photos",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.photos)??[]).map(M3),isLoading:s.isLoading}}function pc(n){const{items:l}=yh(n),{items:s}=r1(n),{items:o}=u1(),{items:u}=So(n);return _.useMemo(()=>{const d=new Map;for(const h of[...l,...s,...o,...u])h.src&&d.set(h.id,h.src);return d},[l,s,o,u])}const Cf=(n,l)=>["floorplan-source-page",n,l];function C3(n){const{recropFloorplan:l}=Kn(),s=u3(u=>u.start),o=cs();return IE({mutationFn:({planId:u,bbox:d})=>l(n,u,d),onMutate:async({planId:u,bbox:d})=>{const h=Cf(n,u);await o.cancelQueries({queryKey:h});const p=o.getQueryData(h);return o.setQueryData(h,y=>y&&{...y,source_bbox:d}),{prev:p,planId:u}},onError:(u,d,h)=>{h!=null&&h.prev&&o.setQueryData(Cf(n,h.planId),h.prev)},onSuccess:(u,d)=>s(d.planId,u.job_id,n)})}function A3(n){return{id:n.id,kind:"tour",name:n.name,size:"",src:n.poster_url,caption:n.caption??null,ready:n.ready,provider:n.provider}}function gh(n){var o;const{getTours:l}=Kn(),s=en({queryKey:["tours",n],queryFn:()=>l(n),enabled:!!n});return{items:(((o=s.data)==null?void 0:o.tours)??[]).map(A3),isLoading:s.isLoading}}function N3(n,l,s){return n&&l?{w:n,h:l}:s?{w:s.w,h:s.h}:null}function T3(n){const[l,s]=_.useState(0),[o,u]=_.useState(null);_.useEffect(()=>{if(!n)return;let p=!0;const y=new Image;return y.onload=()=>{p&&u({src:n,attempt:l,size:{w:y.naturalWidth||1,h:y.naturalHeight||1}})},y.onerror=()=>{p&&u({src:n,attempt:l,size:null})},y.src=n,()=>{p=!1}},[n,l]);const d=_.useCallback(()=>{s(p=>p+1)},[]),h=o&&o.src===n&&o.attempt===l?o:null;return{size:(h==null?void 0:h.size)??null,failed:h!==null&&h.size===null,retry:d}}const O3=16,f1="Crop floor plan",R3="Loading floor plan…",z3="Couldn't load this floor plan's source page.";function Cb({tone:n,message:l,stageClassName:s,onClose:o,onRetry:u}){return f.jsxs(cn.Shell,{open:!0,variant:"page",onClose:o,children:[f.jsxs("div",{className:cn.head,children:[f.jsx("div",{className:cn.titles,children:f.jsx("h2",{className:cn.title,children:f1})}),f.jsx("button",{type:"button",className:cn.close,onClick:o,"aria-label":"Close",children:f.jsx(cn.CloseIcon,{})})]}),f.jsxs("div",{role:n==="failed"?"alert":"status",className:ye(s,"flex flex-col items-center justify-center gap-3 px-6 text-center"),children:[n==="pending"&&f.jsx("span",{"aria-hidden":!0,className:"size-5 animate-spin rounded-full border-2 border-line border-t-accent [animation-duration:0.7s]"}),f.jsx("p",{className:"m-0 text-[13px] text-ink-2",children:l})]}),f.jsx("div",{className:cn.foot,children:f.jsxs("div",{className:cn.actions,children:[f.jsx("button",{type:"button",className:cn.buttonGhost,onClick:o,children:"Cancel"}),u?f.jsx("button",{type:"button",className:cn.buttonPrimary,onClick:u,children:"Try again"}):null]})})]})}function D3({propertyId:n,planId:l,getSourcePage:s,onClose:o,stageClassName:u="h-[60vh] max-h-[620px]"}){const d=en({queryKey:Cf(n,l),queryFn:()=>s(n,l)}),h=d.data,p=T3(h&&!(h.source_width&&h.source_height)?h.source_url:null),y=N3(h==null?void 0:h.source_width,h==null?void 0:h.source_height,p.size),g=C3(n);if(!d.isFetching&&(d.isError||p.failed))return f.jsx(Cb,{tone:"failed",message:z3,stageClassName:u,onClose:o,onRetry:()=>{p.retry(),d.refetch()}});if(!h||!y)return f.jsx(Cb,{tone:"pending",message:R3,stageClassName:u,onClose:o});const x=h.source_bbox?iE(h.source_bbox,y.w,y.h):{nx:0,ny:0,nw:1,nh:1};return f.jsx(sh,{chrome:cn,src:h.source_url,mode:"free",aspect:y.w/y.h,variant:"page",stageClassName:u,title:f1,seed:{rect:x},onClose:o,onApply:v=>{o(),g.mutate({planId:l,bbox:rE(v.rect,y.w,y.h,O3)})}})}const U3=["Basement","Ground","1st floor","2nd floor","3rd floor","4th floor","Penthouse"],L3="fixed overflow-y-auto rounded-[calc(8*var(--content))] border border-line bg-white py-1 shadow-[0_16px_38px_-12px_rgba(20,18,13,0.4)]",Gd=240,h1=ye(ot,"flex w-full items-center rounded-none px-2.5 py-2 text-left text-body text-ink hover:bg-accent-soft data-[active=true]:bg-accent-soft"),B3=ye(h1,"text-accent"),lo=4,Ab=140,io=8,H3="flex w-full items-stretch rounded-[calc(5*var(--content))] border border-transparent bg-[#f3f1ea] transition-[background,border-color,box-shadow] duration-[120ms] hover:bg-[#ece9df] focus-within:border-ink-3 focus-within:bg-white focus-within:shadow-[0_0_0_3px_rgba(20,18,13,0.05)]",q3="min-w-0 flex-1 appearance-none border-0 bg-transparent px-1.75 py-1 text-[length:calc(11.5*var(--content))] font-semibold text-ink-2 placeholder:font-medium placeholder:text-ink-4";function G3({value:n,onChange:l,presets:s,label:o,placeholder:u="Label…",ariaLabel:d,compact:h=!1}){const[p,y]=_.useState(!1),[g,x]=_.useState(""),[v,E]=_.useState(0),[M,N]=_.useState(null),A=_.useId(),j=_.useRef(null),O=_.useRef(null),z=g.trim().toLowerCase(),D=p&&z?s.filter(F=>F.toLowerCase().includes(z)):s,Y=s.some(F=>F.toLowerCase()===z),W=g.trim().length>0&&!Y,ee=D.length+(W?1:0),ae=_.useCallback(()=>{if(!O.current)return;const F=O.current.getBoundingClientRect(),w=window.innerHeight-F.bottom-lo-io;N({rect:F,above:w<Gd})},[]);function U(){ae(),y(!0)}function re(F){l(F.trim()),de()}function de(){y(!1),x(""),E(0)}function ce(F){if(!p&&(F.key==="ArrowDown"||F.key==="Enter")){U();return}if(F.key==="Escape"){de();return}F.key==="ArrowDown"?(F.preventDefault(),E(w=>Math.min(ee-1,w+1))):F.key==="ArrowUp"?(F.preventDefault(),E(w=>Math.max(0,w-1))):F.key==="Enter"&&(F.preventDefault(),v<D.length?re(D[v]):W&&re(g))}function ie(F){var te,P;const w=F.relatedTarget,Z=(te=j.current)==null?void 0:te.contains(w),ue=(P=document.getElementById(A))==null?void 0:P.contains(w);!Z&&!ue&&de()}_.useEffect(()=>{if(p)return window.addEventListener("scroll",ae,!0),window.addEventListener("resize",ae),()=>{window.removeEventListener("scroll",ae,!0),window.removeEventListener("resize",ae)}},[p,ae]);const L=h?H3:ye(_o,p&&"border-accent"),G=h?q3:ss;return f.jsxs("div",{className:ye(!h&&Qn),ref:j,onBlurCapture:ie,children:[o&&!h&&f.jsx("span",{className:va,children:o}),f.jsx("div",{className:L,ref:O,children:f.jsx("input",{className:G,value:p?g:n,placeholder:n||u,onFocus:U,onChange:F=>{x(F.target.value),p||U(),E(0)},onKeyDown:ce,"aria-label":d??o??"Label","aria-expanded":p,"aria-controls":A,role:"combobox"})}),p&&ee>0&&M&&ih.createPortal(f.jsxs("div",{className:L3,id:A,role:"listbox",style:{left:Math.max(io,Math.min(M.rect.left,window.innerWidth-Math.max(M.rect.width,Ab)-io)),...M.above?{bottom:window.innerHeight-M.rect.top+lo,maxHeight:Math.min(M.rect.top-lo-io,Gd)}:{top:M.rect.bottom+lo,maxHeight:Math.min(window.innerHeight-M.rect.bottom-lo-io,Gd)},minWidth:Math.max(M.rect.width,Ab),zIndex:Ev+200},children:[D.map((F,w)=>f.jsx("button",{type:"button",role:"option","aria-selected":w===v,"data-active":w===v,className:h1,onMouseEnter:()=>E(w),onMouseDown:Z=>Z.preventDefault(),onClick:()=>re(F),children:f.jsx("span",{className:"truncate",children:F})},F)),W&&f.jsx("button",{type:"button",role:"option","aria-selected":v===D.length,"data-active":v===D.length,className:B3,onMouseEnter:()=>E(D.length),onMouseDown:F=>F.preventDefault(),onClick:()=>re(g),children:f.jsxs("span",{className:"truncate",children:["Use “",g.trim(),"”"]})})]}),document.body)]})}const I3="group/card relative flex flex-col overflow-hidden rounded-[8px] border border-line bg-canvas transition-[border-color] duration-[120ms] hover:border-ink-4",Q3="relative aspect-[4/3] touch-none select-none bg-[#fafaf6]",K3="absolute inset-0 block size-full object-contain",V3=ye("absolute inset-0 grid place-items-center font-mono text-[12px] text-ink-3",fc),Y3="absolute right-[5px] top-[5px] z-[4] flex gap-[3px] transition-opacity duration-[120ms]",$3="opacity-0 group-hover/card:opacity-100",Id=ye(ot,"we-no-drag grid size-5 place-items-center rounded-[4px] bg-white text-ink-2 shadow-[0_1px_2px_rgba(20,18,13,0.18)] transition-[background,color] duration-[120ms] hover:bg-[#f3f1ea] hover:text-ink"),F3="hover:bg-[#fbe6e2] hover:text-[#8e2c1e]",X3="border-t border-line-soft px-[7px] py-[6px]",Z3="pointer-events-none absolute bottom-[6px] right-[6px] z-[3] grid size-[22px] place-items-center rounded-full bg-[rgba(255,255,255,0.94)] text-[11px] font-bold text-ink shadow-[0_1px_3px_rgba(20,18,13,0.25)]";function P3({src:n,alt:l="",floor:s,onFloorChange:o,onCrop:u,cropTitle:d="Crop floor plan",onRemove:h,removeTitle:p="Remove from unit",include:y,badge:g,drag:x}){const v=y?!y.on:!1,E=ye(Y3,v?"opacity-100":$3);return f.jsxs("div",{className:ye(I3,v&&"opacity-60",(x==null?void 0:x.active)&&"opacity-[0.28]"),"data-dragid":x==null?void 0:x.dataDragId,children:[f.jsxs("div",{className:ye(Q3,x&&"cursor-grab",(x==null?void 0:x.active)&&"cursor-grabbing"),onPointerDown:x==null?void 0:x.onPointerDown,children:[n?f.jsx("img",{className:ye(K3,v&&"grayscale"),src:n,alt:l,draggable:!1}):f.jsx("div",{className:V3}),f.jsxs("span",{className:E,children:[u&&f.jsx("button",{type:"button",className:Id,title:d,onClick:u,children:f.jsx(ze.crop,{})}),h&&f.jsx("button",{type:"button",className:ye(Id,F3),title:p,onClick:h,children:f.jsx(ze.trash,{})}),y&&f.jsx("button",{type:"button",className:Id,title:y.on?"Hide from site":"Show on site","aria-pressed":y.on,onClick:y.onToggle,children:y.on?f.jsx(ze.eye,{}):f.jsx(ze.eyeOff,{})})]}),g!=null&&f.jsx("span",{className:Z3,children:g})]}),f.jsx("div",{className:X3,children:f.jsx(G3,{value:s,onChange:o,presets:U3,placeholder:"Floor",ariaLabel:"Floor label",compact:!0})})]})}const J3=24,W3=14;function ej(n){return n.length<=J3?n:`${n.slice(0,W3)}…${n.slice(-9)}`}function tj(n,l,s){return n?`${ej(n)}`:`Floor plan ${l}`}function nj(n){var s;if(n.fields!=null)return"row-editor";const l=(s=n.element)==null?void 0:s.type;return l==="image"||l==="video"||l==="tour"?"gallery":l==="poi"?"poi-curation":l==="document"?"document-list":"scalar-list"}function bh(n){const l=nj(n);return{editor:l,granularity:l==="row-editor"?"item":"unit"}}function p1(n){if(n!==null&&typeof n=="object"&&!Array.isArray(n)){const l=n;if(typeof l.asset_id=="string")return{asset_id:l.asset_id}}return{asset_id:""}}function aj(n){return n.map(p1).filter(l=>l.asset_id!=="")}function mc(n){switch(n.kind){case"document":return o3(n.name,n.mime??"");case"video":return{glyph:"video",typeNoun:"Video",extension:""};case"photo":case"plan":case"library":return{glyph:"image",typeNoun:"Image",extension:""};case"tour":return{glyph:"video",typeNoun:"3D tour",extension:""}}}function lj(n){return[mc(n).typeNoun,n.size].filter(Boolean).join(" · ")}function ij(n){const l=new Map;for(const s of n)for(const o of s)l.set(o.id,o);return l}function m1(n){const{items:l}=o1(n),{items:s}=yh(n),{items:o}=y3(n),{items:u}=So(n),d=ij([s,o,u,l]);return h=>d.get(h)}const sj="group/row relative flex min-h-12 items-center gap-2.5 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 py-2 [transition:border-color_.14s,box-shadow_.14s,background_.3s]",oj="flex min-w-0 flex-1 flex-col gap-px",rj="truncate text-[length:calc(13.5*var(--content))] text-ink",cj="truncate text-caption text-ink-3",uj="flex flex-col items-center gap-2 rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-4 text-center text-[length:calc(12.5*var(--content))] text-ink-4",dj="we-no-drag flex flex-shrink-0 items-center gap-0.75",fj="flex items-center gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/row:opacity-100",y1="grid size-6 cursor-pointer place-items-center rounded-md border-0 bg-transparent p-0 text-ink-3 outline-none hover:bg-[#f1f0ea] hover:text-ink-2",g1="relative grid size-[calc(34*var(--content))] flex-shrink-0 place-items-center overflow-hidden rounded-[calc(6*var(--content))] border border-line bg-[#f4f3ee] text-ink-3",hj="size-full object-cover",pj="absolute bottom-0 inset-x-0 truncate bg-[rgba(15,18,9,0.55)] px-0.5 text-center text-[length:calc(7.5*var(--content))] font-bold leading-[1.5] tracking-[0.02em] text-white",mj={doc:Jf,spreadsheet:qk,presentation:uv,image:Wf,video:pv};function ko({glyph:n,extension:l,size:s=16,className:o}){const u=mj[n];return f.jsxs(f.Fragment,{children:[f.jsx(u,{size:s,strokeWidth:1.5,className:o,style:{width:`calc(${s} * var(--content))`,height:`calc(${s} * var(--content))`}}),l&&f.jsx("span",{className:pj,children:l})]})}function yj({entry:n}){const{glyph:l,extension:s}=mc(n);return f.jsx("span",{className:g1,children:n.src?f.jsx("img",{className:hj,src:n.src,alt:"",draggable:!1}):f.jsx(ko,{glyph:l,extension:s})})}function b1({entry:n,trailing:l,onRemove:s,dragProps:o,dragging:u}){return f.jsxs("div",{...o,className:ye(sj,o&&"cursor-grab hover:border-[#d9d5c9]",u&&"cursor-grabbing border-transparent bg-accent-soft [&>*]:opacity-[0.25]"),children:[n?f.jsx(yj,{entry:n}):f.jsx("span",{className:g1,children:f.jsx(ko,{glyph:"doc",extension:""})}),f.jsxs("div",{className:oj,children:[f.jsx("span",{className:rj,title:n==null?void 0:n.name,children:(n==null?void 0:n.name)??"Document unavailable"}),f.jsx("span",{className:cj,children:n?lj(n):"This file is no longer on the property"})]}),(l!==void 0||s!==void 0)&&f.jsx("div",{className:dj,children:f.jsxs("span",{className:fj,children:[l,s&&f.jsx("button",{type:"button",className:ye(y1,"hover:bg-[#fbecea] hover:text-danger"),title:"Remove",onClick:s,children:f.jsx(ze.trash,{})})]})})]})}function gj({label:n,onAdd:l}){return f.jsxs("div",{className:uj,children:[f.jsx("span",{className:"text-ink-4",children:f.jsx(ko,{glyph:"doc",extension:"",size:22})}),f.jsx("span",{children:"No document yet"}),f.jsxs("button",{type:"button",className:"inline-flex h-6.5 cursor-pointer items-center gap-1.25 rounded-full border-0 bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink",onClick:l,children:[f.jsx(ze.plus,{})," ",n]})]})}const v1=_.createContext(null);function bj({ports:n,children:l}){return f.jsx(v1.Provider,{value:n,children:l})}function Vn(){const n=_.useContext(v1);if(!n)throw new Error("useSlotEditorPorts: missing SlotEditorPortsProvider");return n}function Dl(n){return Vn().useEditorStore(n)}function vj(){return Vn().api}function x1(){return Vn()}function Af(n){var l;return n===void 0?"Link":((l=Xl[n])==null?void 0:l.label)??"Link"}function sc(n){return n.kind==="tour"?Af(n.provider):n.kind!=="video"?"":n.videoSource==="link"?Af(n.provider):n.ready===!1?"Processing…":d1(n.durationMs)||"Video"}function vh({kind:n,size:l}){return n==="tour"?f.jsx(ze.tour,{size:l}):f.jsx(ze.play,{size:l})}const xj=ye(ot,"inline-flex items-center gap-1.25 rounded-sm bg-[rgba(255,255,255,0.94)] px-2.5 py-1.5 text-[length:calc(11.5*var(--content))] font-semibold text-ink transition-[background] duration-[120ms] hover:bg-white"),_j="flex items-center justify-between gap-2 px-0.5 text-caption text-ink-3",wj="text-caption font-medium text-ink-4",Sj="16 / 9",kj="relative block w-full overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",_1="block size-full object-cover",Ej="pointer-events-none absolute bottom-1.25 left-1.25 z-[3] rounded-full bg-[rgba(15,18,9,0.72)] px-1.5 py-0.5 text-[10.5px] font-semibold tabular-nums text-white group-data-[ghost]/tile:hidden";function w1({kind:n,label:l,poster:s,hasSelection:o,addLabel:u,onPick:d,status:h,metaName:p,metaDetail:y,emptyText:g,noPosterText:x,children:v}){return f.jsxs("div",{className:th,children:[f.jsxs("div",{className:Qn,children:[f.jsx(ah,{children:l}),f.jsxs("div",{className:"relative h-72.5 overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",children:[s?f.jsx("img",{className:"size-full object-cover",src:s,alt:""}):f.jsxs("div",{className:ye("flex size-full flex-col items-center justify-center gap-1.5 text-small text-ink-3",fc),children:[o?f.jsx(vh,{kind:n,size:22}):f.jsx(ze.up,{}),f.jsx("span",{children:o?x:g})]}),f.jsxs("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:[f.jsx("button",{type:"button",className:xj,onClick:d,children:o?f.jsxs(f.Fragment,{children:[f.jsx(ze.swap,{})," Replace"]}):f.jsxs(f.Fragment,{children:[f.jsx(ze.up,{})," ",u]})}),h&&f.jsx("span",{className:wj,children:h})]})]})]}),p!==void 0&&f.jsxs("div",{className:_j,children:[f.jsx("span",{className:"truncate",children:p}),y&&f.jsx("span",{className:"shrink-0 tabular-nums",children:y})]}),v]})}function S1({kind:n,poster:l,index:s,ghost:o,badge:u,overlays:d,placeholderClassName:h}){return f.jsxs("span",{className:ye(kj,o&&"opacity-[0.28]"),style:{aspectRatio:Sj},children:[l?f.jsx("img",{className:_1,src:l,alt:"",draggable:!1}):f.jsxs("span",{className:ye(h,"relative"),children:[f.jsx("span",{className:"absolute inset-0 grid place-items-center text-ink-3 opacity-40",children:f.jsx(vh,{kind:n,size:22})}),f.jsx("span",{className:"relative",children:s+1})]}),d,u&&f.jsx("span",{className:Ej,children:u})]})}function k1({poster:n,index:l,placeholderClassName:s}){return n?f.jsx("img",{className:_1,src:n,alt:"",draggable:!1}):f.jsx("div",{className:s,children:l+1})}function Nf(n){if(n===void 0)return"Not a valid URL";const l=Object.entries(Xl).find(([o])=>o===n);if(l)return`Needs a ${l[1].label} link`;const s=E1(n);return s.length>0?`Needs a ${n} link (${s.join(", ")})`:`Needs a ${n} link`}function E1(n){return Object.values(Xl).filter(l=>l.kind===n).map(l=>l.label)}function jj(n){try{return new URL(n)}catch{return null}}function Tf(n){const l=n.trim();return l&&(/^https?:\/\//i.test(l)?l:`https://${l}`)}function Of(n){const l=jj(n);if(l===null||l.protocol!=="http:"&&l.protocol!=="https:")return!1;const s=l.hostname;return s.includes(".")&&!s.startsWith(".")&&!s.endsWith(".")}const Mj={photo:"photos",plan:"floor plans",library:"library images",video:"videos",tour:"tours",document:"documents"},Cj={photo:"Photos",plan:"Floor plans",library:"Library",video:"Videos",tour:"Tours",document:"Documents"},Aj={video:"video",tour:"tour"},Nj=["photo","plan","video","document"];function Tj(n){return n==="video"?"video/*":n==="document"?l3:"image/*"}function Qd(n){return n.kind==="plan"&&n.ready===!1||n.kind==="tour"&&n.ready===!1?!1:!n.status||n.status==="classifying"}function Oj(n,l){const s=new Set(n);return s.has(l)?s.delete(l):s.add(l),s}function j1(n){const{items:l,addFiles:s,retry:o}=S3(n),{items:u}=yh(n),{items:d}=r1(n),{items:h}=u1(),{items:p}=So(n),{items:y}=gh(n),{items:g}=o1(n),x=new Set([...u.map(E=>E.id),...d.map(E=>E.id),...p.map(E=>E.id),...y.map(E=>E.id),...g.map(E=>E.id)]);return{items:[...l.filter(E=>!x.has(E.id)),...u,...d,...h,...p,...y,...g],addFiles:s,retry:o}}function Rj({entry:n}){if(n.kind==="document"){const{glyph:l,extension:s}=mc(n);return f.jsx(ko,{glyph:l,extension:s,size:30})}return f.jsx(vh,{kind:n.kind==="tour"?"tour":"video",size:18})}function zj(n){switch(n){case"uploading":return"Uploading…";case"classifying":return"Processing…";case"failed":return"Failed — retry";case"not_photo":return"Not a photo"}}function Nb({primaryLabel:n,primaryDisabled:l,onPrimary:s,onClose:o}){return f.jsx("div",{className:_v,children:f.jsxs("div",{className:wv,children:[f.jsx("button",{className:kv,onClick:o,children:"Cancel"}),f.jsx("button",{className:lh,disabled:l,onClick:s,children:n})]})})}function Dj({open:n,title:l,propertyId:s,onClose:o,footer:u,selectedIds:d,onCellClick:h,onCellDoubleClick:p,initialFilter:y,kinds:g,disabledKinds:x,videoSources:v,onPickOne:E}){const{items:M,addFiles:N,retry:A}=j1(s),j=cs(),{api:O,capabilities:z}=x1(),D=g??["photo","plan","library","video"],[Y,W]=_.useState(""),ee=x??[],ae=D.find(T=>!ee.includes(T))??D[0]??"photo",[U,re]=_.useState(D.includes(y)&&!ee.includes(y)?y:ae),de=_.useRef(null),ce=(v==null?void 0:v.includes("link"))??!1,ie=U==="video"&&!ce?null:Aj[U]??null,L=Y.trim().toLowerCase(),G=M.filter(T=>T.kind===U&&T.name.toLowerCase().includes(L)&&(ce||T.videoSource!=="link")),[F,w]=_.useState(""),[Z,ue]=_.useState(null),[te,P]=_.useState(!1),k=async()=>{const T=F.trim();if(!T||te||ie===null)return;const B=Tf(T);if(!Of(B)||!af(ie,B)){ue(Nf(ie));return}const q=W0(B);if(q===null){ue(Nf(ie));return}ue(null),P(!0);try{const V=await O.postLink(s,B);await j.invalidateQueries({queryKey:[ie==="tour"?"tours":"videos",s]}),w(""),E==null||E(ie==="tour"?{id:V.id,kind:"tour",name:Xl[q].label,size:"",src:"",caption:null,ready:!0,provider:q}:{id:V.id,kind:"video",name:Xl[q].label,size:"",src:"",caption:null,ready:!0,durationMs:null,videoSource:"link",provider:q})}catch{ue("Could not add that link. Try again.")}finally{P(!1)}},I=T=>{const B=T.target.files,q=U==="plan";if(N(B,q?{declaredType:"floor_plan"}:void 0),!q){const V=B==null?void 0:B[0],me=V?c1(V):"photo";D.includes(me)&&!ee.includes(me)&&re(me)}T.target.value=""},$=T=>{if(T.status==="failed"){A(T.id);return}Qd(T)&&h(T)};return f.jsxs(Cv,{open:n,variant:"pick",onClose:o,children:[f.jsxs("div",{className:gv,children:[f.jsx("div",{className:bv,children:f.jsx("h2",{className:vv,children:l})}),f.jsx("button",{className:xv,onClick:o,"aria-label":"Close",children:f.jsx(ze.x,{})})]}),f.jsxs("div",{className:eb,children:[f.jsxs("div",{className:tb,children:[f.jsx("span",{className:nb,children:f.jsx(ze.search,{})}),f.jsx("input",{className:ab,autoFocus:!0,placeholder:"Search file names…",value:Y,onChange:T=>W(T.target.value)})]}),D.length>1&&f.jsx("div",{className:T4,children:D.map(T=>{const B=ee.includes(T);return f.jsx("button",{type:"button",className:R4(U===T,B),disabled:B,"aria-disabled":B||void 0,onClick:()=>!B&&re(T),children:Cj[T]},T)})})]}),ie!==null&&f.jsxs("div",{className:eb,children:[f.jsxs("div",{className:tb,children:[f.jsx("span",{className:nb,children:f.jsx(ze.link,{})}),f.jsx("input",{className:ab,placeholder:`Paste a ${ie} link (${E1(ie).join(" or ")})…`,value:F,disabled:te,onChange:T=>{w(T.target.value),ue(null)},onKeyDown:T=>{T.key==="Enter"&&k()}})]}),f.jsx("button",{type:"button",className:lh,disabled:te||F.trim().length===0,onClick:()=>void k(),children:te?"Adding…":"Add link"})]}),Z&&f.jsx("div",{className:"px-4 pb-1 text-[11.5px] font-medium text-[#b4342b]",role:"alert",children:Z}),f.jsx("div",{className:b4,children:f.jsxs("div",{className:v4,children:[z.upload&&Nj.includes(U)&&f.jsxs("button",{className:C4,onClick:()=>{var T;return(T=de.current)==null?void 0:T.click()},children:[f.jsx("span",{className:A4,children:f.jsx(ze.up,{})}),f.jsx("span",{className:N4,children:"Upload"})]}),G.length===0?f.jsxs("div",{className:x4,children:["No ",Mj[U]," match"," ",L?`”${Y}”`:"your search","."]}):G.map(T=>f.jsxs("button",{className:_4,"data-selected":d.has(T.id)?"":void 0,"aria-disabled":!Qd(T)&&T.status!=="failed",onClick:()=>$(T),onDoubleClick:p&&Qd(T)?()=>p(T):void 0,children:[f.jsx("span",{className:w4,children:f.jsxs("span",{className:S4,children:[T.src?f.jsx("img",{className:T.kind==="plan"&&T.ready===!1?`${lb} opacity-40`:lb,src:T.src,alt:""}):f.jsx("span",{className:E4,children:f.jsx(Rj,{entry:T})}),d.has(T.id)&&f.jsx("span",{className:k4,children:f.jsx(ze.check,{})}),!T.status&&sc(T)&&f.jsx("span",{className:M4,children:sc(T)}),T.status&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",title:T.error??void 0,children:zj(T.status)}),T.kind==="tour"&&T.ready===!1&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",role:"status",children:"Not embeddable"}),T.kind==="plan"&&T.ready===!1&&f.jsx("span",{className:"absolute inset-x-0 bottom-0 bg-[rgba(15,18,9,0.6)] px-1.5 py-1 text-[10.5px] font-semibold text-white",role:"status",children:"Processing…"})]})}),(T.kind==="document"||T.kind==="tour")&&f.jsx("span",{className:j4,title:T.name,children:T.name})]},T.id))]})}),u,z.upload&&f.jsx("input",{ref:de,type:"file",accept:Tj(U),multiple:!0,hidden:!0,onChange:I})]})}function cl(n){var j,O;const{propertyId:l,onClose:s}=n,{items:o}=j1(l),u=((j=n.kinds)==null?void 0:j.length)===1?n.kinds[0]:void 0,d=n.noun??(u==="video"||u==="tour"?u:"photo"),[h,p]=_.useState(n.mode==="single"?n.currentId??null:null),[y,g]=_.useState(()=>n.mode==="multi"?new Set(n.selectedIds.filter(Boolean)):new Set),x=z=>{n.mode==="single"?p(z.id):g(D=>Oj(D,z.id))};let v,E,M,N,A;if(n.mode==="single"){const{onPick:z,currentId:D}=n,Y=o.find(W=>W.id===h)??null;v=new Set(h?[h]:[]),E=W=>z(W),M=f.jsx(Nb,{primaryLabel:`Use ${d}`,primaryDisabled:!Y,onPrimary:()=>Y&&z(Y),onClose:s}),N=`Choose a ${d}`,A=((O=o.find(W=>W.id===D))==null?void 0:O.kind)??"photo"}else{const{onApply:z}=n;v=y,E=void 0,M=f.jsx(Nb,{primaryLabel:"Save selection",onPrimary:()=>z(o.filter(D=>y.has(D.id))),onClose:s}),N=`Choose ${d}s`,A="photo"}return f.jsx(Dj,{open:n.open,title:n.title??N,propertyId:l,onClose:s,initialFilter:n.initialFilter??A,kinds:n.kinds,disabledKinds:n.disabledKinds,videoSources:n.videoSources,onPickOne:n.mode==="single"?n.onPick:void 0,selectedIds:v,onCellClick:x,onCellDoubleClick:E,footer:M})}function Uj({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),h=(l==null?void 0:l.asset_id)??"",p=m1(o),y=h?p(h):void 0;return f.jsxs("div",{className:Qn,children:[f.jsx(ah,{children:n.label}),h?f.jsx(b1,{entry:y,trailing:f.jsx("button",{type:"button",className:y1,title:"Replace",onClick:()=>d(!0),children:f.jsx(ze.swap,{})}),onRemove:()=>s(null)}):f.jsx(gj,{label:`Add ${wo(n.label,"Document")}`,onAdd:()=>d(!0)}),u&&f.jsx(cl,{mode:"single",propertyId:o,noun:"document",kinds:["document","photo","video"],initialFilter:h?void 0:"document",currentId:h||void 0,onClose:()=>d(!1),onPick:g=>{d(!1),s({asset_id:g.id})}})]})}const Lj={PanelUI:Uj,applyOptimistic:null,coerce:p1};function Bj(n,l,s){if(l===s||l<0||s<0)return n;const o=n.slice(),[u]=o.splice(l,1);return o.splice(s,0,u),o}const M1="data-drag-scope";function Kd(n){return Array.from(n.querySelectorAll("[data-dragid]")).filter(l=>l.closest(`[${M1}]`)===n)}function C1({items:n,getKey:l,onReorder:s,onDrop:o,axis:u="xy",threshold:d=4,ignoreSelector:h=".we-no-drag"}){const[p,y]=_.useState(null),[g,x]=_.useState({w:0,h:0}),v=_.useRef(null),E=_.useRef(null),M=_.useRef({}),N=_.useRef({grabX:0,grabY:0,scale:1}),A=_.useRef({x:0,y:0}),j=_.useRef(null),O=_.useRef(null),z=_.useRef(n),D=_.useRef(l),Y=_.useRef({onReorder:s,onDrop:o});_.useLayoutEffect(()=>{Y.current={onReorder:s,onDrop:o}});function W(){const ce=E.current,ie=v.current;if(!ce||!ie)return;const L=ie.getBoundingClientRect(),G=N.current.scale||1,F=(A.current.x-L.left)/G-N.current.grabX,w=(A.current.y-L.top)/G-N.current.grabY;u!=="y"&&(ce.style.left=`${F}px`),ce.style.top=`${w}px`}function ee(){const ce=v.current,ie=ce.getBoundingClientRect(),L=N.current.scale||1,G=(A.current.x-ie.left)/L,F=(A.current.y-ie.top)/L,w=z.current;let Z=0,ue=1/0;return Kd(ce).forEach(te=>{const P=w.findIndex(T=>D.current(T)===te.dataset.dragid);if(P<0)return;const k=te.offsetLeft+te.offsetWidth/2,I=te.offsetTop+te.offsetHeight/2,$=(G-k)**2+(F-I)**2;$<ue&&(ue=$,Z=P)}),Math.max(0,Math.min(w.length-1,Z))}_.useLayoutEffect(()=>{const ce=v.current;if(!ce)return;ce.setAttribute(M1,"");const ie=M.current,L={};Kd(ce).forEach(G=>{const F=G.dataset.dragid,w={left:G.offsetLeft,top:G.offsetTop};L[F]=w;const Z=ie[F];if(Z&&F!==O.current){const ue=Z.left-w.left,te=Z.top-w.top;(ue||te)&&G.animate([{transform:`translate(${ue}px,${te}px)`},{transform:"none"}],{duration:190,easing:"cubic-bezier(.2,.7,.3,1)"})}}),M.current=L,O.current&&W()});function ae(ce,ie){var Z,ue,te,P,k;const L=v.current,G=Kd(L).find(I=>I.dataset.dragid===ce)??null;if(!G)return;const F=G.getBoundingClientRect(),w=L.getBoundingClientRect().width/L.offsetWidth||1;N.current={grabX:(ie.clientX-F.left)/w,grabY:(ie.clientY-F.top)/w,scale:w},(ue=(Z=document.activeElement)==null?void 0:Z.blur)==null||ue.call(Z),(k=(P=(te=window.getSelection)==null?void 0:te.call(window))==null?void 0:P.removeAllRanges)==null||k.call(P),A.current={x:ie.clientX,y:ie.clientY},z.current=n,D.current=l,O.current=ce,x({w:G.offsetWidth,h:G.offsetHeight}),y(ce)}function U(ce,ie){ce.button===0&&(ce.target.closest(h)||(j.current={key:ie,x:ce.clientX,y:ce.clientY},window.addEventListener("pointermove",re),window.addEventListener("pointerup",de)))}function re(ce){const ie=j.current;if(!ie)return;if(!O.current){if(Math.hypot(ce.clientX-ie.x,ce.clientY-ie.y)<d)return;ae(ie.key,ce)}A.current={x:ce.clientX,y:ce.clientY},W();const L=ee(),G=z.current,F=G.findIndex(Z=>D.current(Z)===O.current);if(F<0||F===L)return;const w=Bj(G,F,L);z.current=w,Y.current.onReorder(w)}function de(){window.removeEventListener("pointermove",re),window.removeEventListener("pointerup",de),j.current=null,O.current&&(O.current=null,y(null),Y.current.onDrop(z.current))}return{containerRef:v,cloneRef:E,getItemProps:ce=>({"data-dragid":ce,onPointerDown:ie=>U(ie,ce)}),draggingKey:p,cloneBox:g}}const Hj="flex min-h-6.5 items-center justify-between gap-2.5",qj=ye(ot,"inline-flex h-6.5 items-center gap-1.25 rounded-full bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink"),Gj="relative grid grid-cols-2 gap-2",Ij="[grid-column:1/-1] py-4.5 text-center text-small text-ink-3",Qj="pointer-events-none absolute z-[60] cursor-grabbing overflow-hidden rounded-[8px] bg-canvas shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[8px] after:border-2 after:border-dashed after:border-[#111] after:content-['']",Kj="relative aspect-[4/3] bg-[#fafaf6]",Vj="absolute inset-0 block size-full object-contain";function Tb(n){return Array.isArray(n)?n.map(l=>{if(typeof l!="object"||l===null)return null;const s=l;if(typeof s.key=="string")return s;const o=typeof s.id=="string"?s.id:typeof s.asset_id=="string"?s.asset_id:"";return{key:O1(),id:o,uploadId:typeof s.upload_id=="string"?s.upload_id:"",url:"",alt:"",floor:typeof s.floor_label=="string"?s.floor_label:""}}).filter(l=>l!==null):[]}function Yj(n){return n.map((l,s)=>{const o=l.floor.trim();return{id:l.id,...l.uploadId?{upload_id:l.uploadId}:{},floor_label:o||null,position:s}})}function $j(n){return n.map(l=>{const s=l.floor.trim();return{asset_id:l.id,floor_label:s||null}})}function A1(n,l){var d;if(n.sourceFilter==="floorplans")return!0;const{collection:s,fieldKey:o}=l;if(s==null||o==null)return!1;const u=Zf(s,o,n);return u!==null&&((d=ac(s,u))==null?void 0:d.pool)==="floor_plans"}function N1({slot:n,value:l,propertyId:s,recordContext:o,onChange:u}){var g;const{fieldKey:d,titleKey:h,itemIndex:p}=o,y=(o.siblingRecords??[]).map(x=>{const v=h!=null?x[h]:void 0;return{label:typeof v=="string"?v:"",plans:Tb(d!=null?x[d]:void 0)}});return f.jsx(Zj,{plans:Tb(l),propertyId:s,unitLabel:p!=null&&((g=y[p])==null?void 0:g.label)||void 0,unitIndex:p,siblingUnits:y,onChange:x=>u(n.type==="list"?$j(x):Yj(x))})}function T1(n){return n.map(l=>({planId:l.id,label:l.floor}))}let Ob=0;function O1(){return Ob+=1,`pl-${Ob}`}function Vd(n){return JSON.stringify(n.map(l=>[l.id,l.floor]))}function Fj(n,l,s){const o=new Map(l.map(u=>[u.id,u]));return n.map(u=>{const d=o.get(u.planId);return d?{...d,floor:u.label}:{key:O1(),id:u.planId,uploadId:"",url:s.get(u.planId)??"",alt:"",floor:u.label}})}function Xj(n){return{_key:"fp-sibling",label:n.label,beds:"",baths:"",sqft:"",price:"",plans:T1(n.plans),planExclusions:[],planFloors:{}}}function Zj({plans:n,propertyId:l,unitLabel:s,siblingUnits:o,unitIndex:u,onChange:d}){const{UnitPlanPicker:h,api:p}=x1(),[y,g]=_.useState(!1),[x,v]=_.useState(null),E=v3(l),M=_.useMemo(()=>{const G=new Map;for(const F of E)G.set(F.id,F.thumbnail_url);return G},[E]),N=G=>G.url||M.get(G.id)||"",[A,j]=_.useState(n),[O,z]=_.useState(()=>Vd(n)),D=G=>{j(G),z(Vd(G)),d(G)},{containerRef:Y,cloneRef:W,getItemProps:ee,draggingKey:ae,cloneBox:U}=C1({items:A,getKey:G=>G.key,onReorder:j,onDrop:D,axis:"xy"});if(!ae){const G=Vd(n);G!==O&&(z(G),j(n))}const re=(G,F)=>D(A.map(w=>w.key===G?{...w,floor:F}:w)),de=G=>D(A.filter(F=>F.key!==G)),ce=o==null?void 0:o.map(Xj),ie=ae?A.find(G=>G.key===ae):null,L=ie?N(ie):"";return f.jsxs("div",{className:"flex flex-col gap-2.25",children:[f.jsxs("div",{className:Hj,children:[f.jsxs("span",{className:va,children:[A.length," floor plan",A.length===1?"":"s"]}),f.jsx("div",{className:"flex items-center gap-1.5",children:f.jsxs("button",{type:"button",className:qj,onClick:()=>g(!0),children:[f.jsx(ze.plus,{})," Add"]})})]}),f.jsxs("div",{className:Gj,ref:Y,children:[A.length===0&&f.jsx("div",{className:Ij,children:"No floor plans yet — use Add to choose plans."}),A.map((G,F)=>f.jsx(P3,{src:N(G)||null,floor:G.floor,onFloorChange:w=>re(G.key,w),onCrop:()=>v(G.id),onRemove:()=>de(G.key),removeTitle:"Remove from unit",badge:F+1,drag:{dataDragId:G.key,onPointerDown:ee(G.key).onPointerDown,active:ae===G.key}},G.key)),ie&&f.jsx("div",{ref:W,className:Qj,style:{width:U.w,height:U.h,left:0,top:0},children:f.jsx("div",{className:Kj,children:L&&f.jsx("img",{className:Vj,src:L,alt:"",draggable:!1})})})]}),y&&f.jsx(h,{open:!0,propertyId:l,unit:{_key:"fp-preview",label:s??"",beds:"",baths:"",sqft:"",price:"",plans:T1(A),planExclusions:[],planFloors:{}},units:ce,unitIndex:u,library:E,onClose:()=>g(!1),onUnitPatch:G=>{G.plans&&D(Fj(G.plans,A,M))},onCrop:v}),x&&f.jsx(D3,{propertyId:l,planId:x,getSourcePage:p.getFloorplanSourcePage,onClose:()=>v(null)})]})}const Pj={failed:"Crop failed — the image is unchanged. Try cropping again.",slow:"This crop is still processing. It will appear as soon as it finishes."},Jj="m-0 text-caption leading-[1.4] text-ink-4";function R1({storeKey:n}){const l=YE(n),s=En(o=>o.clearNotice);return l?f.jsxs("p",{role:"alert","data-crop-notice":l,className:ye(l==="failed"?nh:Jj,"flex items-center justify-between gap-2"),children:[f.jsx("span",{children:Pj[l]}),f.jsx("button",{type:"button",className:ye(ot,"shrink-0 underline"),onClick:()=>s(n),children:"Dismiss"})]}):null}const Wj=360,eM="relative overflow-hidden rounded-[calc(9*var(--content))]";function z1({src:n,derivativeUrl:l,mode:s,slotAspect:o,sizing:u,ar:d,dimmed:h,children:p}){const y=l??n,g=s==="locked"?"cover":"contain",x=_.useRef(null),[v,E]=_.useState(null);_.useLayoutEffect(()=>{if(s!=="free")return;const z=x.current;z!=null&&z.complete&&z.naturalWidth>0&&z.naturalHeight>0&&E({src:y,aspect:z.naturalWidth/z.naturalHeight})},[y,s]);const M=z=>{if(s!=="free")return;const D=z.currentTarget;D.naturalWidth>0&&D.naturalHeight>0&&E({src:y,aspect:D.naturalWidth/D.naturalHeight})},N=v&&v.src===y?v.aspect:typeof d=="number"&&d>0?d:o,A=s==="locked"?o:N,j=h?PE:void 0,O=u==="single"?{aspectRatio:String(A),width:"100%",maxWidth:`${Wj*A}px`,marginInline:"auto"}:{aspectRatio:String(A),width:"100%"};return f.jsxs("div",{className:eM,style:O,children:[f.jsx("img",{ref:x,className:`block size-full object-center ${g==="cover"?"object-cover":"object-contain"}`,src:y,alt:"",draggable:!1,onLoad:M,style:j}),p]})}function tM(n){var u,d;const l=vj(),o=(u=en({queryKey:["property",n],queryFn:()=>l.fetchProperty(n)}).data)==null?void 0:u.contacts;return((d=(o==null?void 0:o.find(h=>h.is_primary))??(o==null?void 0:o[0]))==null?void 0:d.library_item_id)??null}const so=ye(ot,"inline-flex items-center gap-1.25 rounded-sm bg-[rgba(255,255,255,0.94)] px-2.5 py-1.5 text-[length:calc(11.5*var(--content))] font-semibold text-ink transition-[background] duration-[120ms] hover:bg-white");function Rb(n,l,s,o){const u=()=>{const d=n.current;return d.photo_id!==o?!0:!!(d.pending_crop&&d.pending_crop.crop_key!==s.crop_key)};return{apply:(d,h)=>{u()||l({...n.current,rect:s.rect,ar:s.ar,crop_key:d,mobile:s.mobile?{rect:s.mobile.rect,crop_key:h??null,derived:s.mobile.derived}:n.current.mobile??void 0,pending_crop:null})},revert:()=>{u()||l({...n.current,pending_crop:null})}}}function Yd({value:n,onChange:l,propertyId:s,cropKey:o,cropCfg:u,contactImage:d,comparablePhoto:h=null,displayName:p}){var T;const{api:y}=Vn(),[g,x]=_.useState(null),v=pc(s),E=e1(s,[n.crop_key],y.getCropDerivativeUrl),M=n.crop_key?E.get(n.crop_key):void 0,N=En(B=>o in B.byKey),A=o.startsWith(`${s}:`)?o.slice(s.length+1):o,[j="",O=""]=A.split(":"),z=tM(s),D=(d==null?void 0:d.itemId)??z,Y=_.useRef(null),[W,ee]=_.useState(!1),ae=d!==null&&D!==null,U=(h==null?void 0:h.comparableId)??null,re=h?U===null?null:{stage:B=>y.stageComparablePhoto(s,U,B),discard:B=>y.deleteStagedComparablePhoto(s,U,B)}:ae?{stage:B=>y.stageLibraryItemImage(D,B,LS(d.kind==="headshot"?{kind:"headshot"}:{kind:"logo",variant:d.variant})),discard:B=>y.deleteStagedLibraryItemImage(D,B)}:null,de=h===null,ce=lf(n),ie=ce?v.has(ce):!1,L=en(h?{queryKey:["comparable-photo-url",U,ce],queryFn:()=>y.presignComparablePhoto(s,U,ce),enabled:!!U&&!!ce&&!ie}:{queryKey:["staged-upload-url",D,ce],queryFn:()=>y.presignLibraryItemUpload(D,ce),enabled:!!D&&!!ce&&!ie}),G=(ce?v.get(ce):void 0)??L.data??n.url??void 0,F=_.useRef(null),w=async B=>{if(re){ee(!0);try{const{upload_id:q,url:V}=await re.stage(B),me=F.current;F.current=q,l({...n,photo_id:q,url:V,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}),me&&me!==q&&re.discard(me).catch(()=>{})}catch(q){console.error("[editor] image stage failed",{contactId:D,comparableId:U,err:q})}finally{ee(!1)}}},Z=B=>{var V;const q=(V=B.target.files)==null?void 0:V[0];B.target.value="",q&&w(q)},ue=()=>{const B=F.current;F.current=null,l({...n,photo_id:"",url:"",rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}),B&&re&&re.discard(B).catch(()=>{})},te=f.jsxs("button",{type:"button",className:so,disabled:W,onClick:()=>{var B;return(B=Y.current)==null?void 0:B.click()},children:[f.jsx(ze.up,{})," ",W?"Saving…":"Upload"]}),P=_.useRef(n);_.useEffect(()=>{P.current=n},[n]);const k=n.pending_crop??null,I=_.useCallback(B=>Rb(P,l,B.pending,P.current.photo_id),[l]);Jv(k?[{key:o,pending:k,propertyId:s,instanceId:j,slotId:O}]:[],I);const $=async B=>{var q,V,me;if(x(null),!!n.photo_id){if(Ov(B.rect)){(n.rect||n.crop_key||n.mobile||n.pending_crop)&&l({...n,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null});return}try{const he=await y.cropImage(s,n.photo_id,B.rect,((q=B.mobile)==null?void 0:q.rect)??null),ke={job_id:he.job_id,crop_key:he.crop_key,rect:B.rect,ar:B.ar,mobile:B.mobile&&he.mobile?{job_id:he.mobile.job_id,crop_key:he.mobile.crop_key,rect:B.mobile.rect,derived:B.mobile.derived}:null};l({...P.current,pending_crop:ke});const Ae=Rb(P,l,ke,n.photo_id);En.getState().start(o,{jobId:he.job_id,propertyId:s,cropKey:he.crop_key,mobileJobId:(V=he.mobile)==null?void 0:V.job_id,mobileCropKey:(me=he.mobile)==null?void 0:me.crop_key,instanceId:j,slotId:O,apply:Ae.apply,revert:Ae.revert})}catch(he){En.getState().notice(o,"failed"),console.error("[editor] image crop failed",{instanceId:j,slotId:O,err:he})}}};return f.jsxs("div",{className:th,children:[f.jsxs("div",{className:Qn,children:[f.jsx(ah,{children:p??"Image"}),G?f.jsxs(z1,{src:G,derivativeUrl:M,ar:n.ar,mode:u.mode,slotAspect:u.aspect,sizing:"single",dimmed:N,children:[N&&f.jsx(Wv,{}),f.jsx("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:f.jsxs("div",{className:"flex items-center gap-1.5",children:[re?te:de?f.jsxs("button",{type:"button",className:so,onClick:()=>x("pick"),children:[f.jsx(ze.swap,{})," Replace"]}):null,f.jsxs("button",{type:"button",className:so,onClick:()=>x("crop"),children:[f.jsx(ze.crop,{})," Crop"]}),h&&f.jsxs("button",{type:"button",className:so,onClick:ue,children:[f.jsx(ze.trash,{})," Remove"]})]})})]}):f.jsxs("div",{className:"relative h-72.5 overflow-hidden rounded-[calc(9*var(--content))] bg-[#e6e3da]",children:[f.jsxs("div",{className:ye("flex size-full flex-col items-center justify-center gap-1.5 text-small text-ink-3",fc),children:[f.jsx(ze.up,{}),f.jsx("span",{children:"No image yet"})]}),f.jsx("div",{className:"absolute inset-x-0 bottom-0 flex items-center justify-between bg-[linear-gradient(to_top,rgba(15,18,9,0.55),transparent)] p-2.5",children:re?te:de?f.jsxs("button",{type:"button",className:so,onClick:()=>x("pick"),children:[f.jsx(ze.up,{})," Add image"]}):null})]}),f.jsx(R1,{storeKey:o})]}),re&&f.jsx("input",{ref:Y,type:"file",accept:"image/*",hidden:!0,onChange:Z}),g==="pick"&&de&&f.jsx(cl,{mode:"single",propertyId:s,currentId:n.photo_id||void 0,onClose:()=>x(null),onPick:B=>{if(B.id===n.photo_id){l({...n,url:B.src}),x(null);return}l({...n,photo_id:B.id,url:B.src,alt:n.alt||B.caption||"",rect:null,ar:null,crop_key:null,pending_crop:null}),x(null)}}),g==="crop"&&G&&f.jsx(sh,{chrome:cn,src:G,mode:u.mode,aspect:u.aspect,aspectLabel:u.aspectLabel,mobileAspect:u.mobileAspect,seed:{rect:n.rect??null},mobileSeed:{rect:((T=n.mobile)==null?void 0:T.rect)??null},onClose:()=>x(null),onApply:B=>{$(B)}})]})}function nM(){return`tmp_${globalThis.crypto.randomUUID()}`}function D1(n){return typeof n=="string"&&n.startsWith("tmp_")}function aM({slot:n,instanceId:l,slotId:s,value:o,onChange:u,propertyId:d,recordContext:h}){if(h){if(d!=null&&A1(n,h))return f.jsx(N1,{slot:n,value:o,propertyId:d,recordContext:h,onChange:x=>u(x)});if(d!=null&&l!=null&&s!=null){if(DS(h.collection,h.fieldKey??"",n)){const v=h.itemId;return f.jsx(Yd,{value:o,onChange:u,propertyId:d,cropKey:`${d}:${l}:${s}:${h.fieldKey}`,cropCfg:Jr(n),displayName:n.label,contactImage:null,comparablePhoto:{comparableId:v!=null&&!D1(v)?v:null}})}const x=US(h.collection,h.fieldKey??"",n);return f.jsx(Yd,{value:o,onChange:u,propertyId:d,cropKey:`${d}:${l}:${s}:${h.fieldKey}`,cropCfg:Jr(n),displayName:n.label,contactImage:x?{...x,instanceId:l,slotId:s,itemId:h.itemId}:null})}return null}const p=Jr(n),y=`${d}:${l}:${s}`,g=tv(n.source);return f.jsx(Yd,{value:o,onChange:u,propertyId:d,cropKey:y,cropCfg:p,contactImage:g?{...g,instanceId:l,slotId:s}:null,displayName:n.label})}function lM(n,l){const s=n.querySelector("img");if(s){l.url&&s.setAttribute("src",l.url),s.setAttribute("alt",l.alt??""),s.style.transform="",s.style.transformOrigin="",s.style.objectPosition="";return}const o=n.querySelector("video");o&&(l.url?o.setAttribute("poster",l.url):o.removeAttribute("poster"))}function U1(n){if(n&&typeof n=="object"){const l=n;return{photo_id:typeof l.photo_id=="string"&&l.photo_id.length>0?l.photo_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",alt:typeof l.alt=="string"?l.alt:"",rect:l.rect&&typeof l.rect=="object"?l.rect:void 0,ar:typeof l.ar=="number"?l.ar:void 0,crop_key:typeof l.crop_key=="string"?l.crop_key:void 0,mobile:l.mobile&&typeof l.mobile=="object"&&l.mobile.rect?l.mobile:void 0,pending_crop:ZE(l.pending_crop)??void 0}}return{photo_id:"",url:"",alt:""}}const iM={PanelUI:aM,applyOptimistic:lM,coerce:n=>Array.isArray(n)?n:U1(n)},sM=ye(ot,"inline-flex h-6.5 items-center gap-1.25 rounded-full bg-accent pl-2.25 pr-2.75 text-[length:calc(11.5*var(--content))] font-semibold text-white transition-[background] duration-[120ms] hover:bg-accent-ink"),oM="group/tile relative cursor-grab touch-none select-none",rs=ye("grid size-full place-items-center font-mono text-small text-ink-3",fc),rM="absolute right-1.25 top-1.25 z-[4] flex gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/tile:opacity-100 group-data-[ghost]/tile:hidden",L1=ye(ot,"we-no-drag grid size-5 place-items-center rounded-[calc(4*var(--content))] bg-white text-ink-2 shadow-[0_1px_2px_rgba(20,18,13,0.18)] transition-[background,color] duration-[120ms] hover:bg-[#f3f1ea] hover:text-ink"),zb="pointer-events-none absolute bottom-1.25 right-1.25 z-[3] grid size-5.5 place-items-center rounded-full bg-[rgba(255,255,255,0.94)] text-caption font-bold text-ink shadow-[0_1px_3px_rgba(20,18,13,0.25)] group-data-[ghost]/tile:hidden",cM="pointer-events-none absolute z-[60] cursor-grabbing overflow-hidden rounded-[calc(9*var(--content))] shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[calc(9*var(--content))] after:border-2 after:border-dashed after:border-[#111] after:content-['']";function yc(n,l,s,o,u){const d=new Set(l.map(g=>g.id)),h=n.filter(g=>d.has(s(g.value))),p=new Set(h.map(g=>s(g.value))),y=l.filter(g=>!p.has(g.id)).map(g=>u(o(g)));return[...h,...y]}function xh({engine:n,noun:l,max:s,emptyText:o,onAdd:u,renderTile:d,renderClone:h,tileActions:p,children:y}){const{rows:g,atMax:x,canRemove:v}=n,{containerRef:E,cloneRef:M,getItemProps:N,draggingKey:A,cloneBox:j}=n.drag,O=A?n.indexOf(A):-1,z=O>=0?g[O]:null;return f.jsxs("div",{className:Qn,children:[f.jsxs("div",{className:"flex min-h-6.5 items-center justify-between gap-2.5",children:[f.jsxs("span",{className:va,children:[g.length," ",l,g.length===1?"":"s"]}),f.jsxs("button",{type:"button",className:sM,onClick:u,disabled:x,title:x?`Maximum ${s} ${l}s`:`Add ${l}s`,style:x?{opacity:.5,cursor:"default"}:void 0,children:[f.jsx(ze.plus,{})," Add"]})]}),f.jsxs("div",{className:"relative grid grid-cols-2 gap-2",ref:E,children:[g.length===0&&f.jsx("div",{className:"[grid-column:1/-1] py-4.5 text-center text-small text-ink-3",children:o}),g.map((D,Y)=>{const W=f.jsxs(f.Fragment,{children:[f.jsxs("span",{className:rM,children:[p==null?void 0:p(D),v&&f.jsx("button",{type:"button",className:ye(L1,"hover:bg-[#FBE6E2] hover:text-[#8E2C1E]"),title:"Remove",onClick:()=>n.remove(D.key),children:f.jsx(ze.trash,{})})]}),f.jsx("span",{className:zb,children:Y+1})]});return f.jsx("div",{...N(D.key),"data-ghost":A===D.key?"":void 0,className:ye(oM,A===D.key&&"cursor-grabbing"),children:d(D,Y,W)},D.key)}),z&&f.jsxs("div",{ref:M,className:cM,style:{width:j.w,height:j.h,left:0,top:0},children:[h(z,O),f.jsx("span",{className:zb,children:O+1})]})]}),y]})}let uM=0;function dM(){return typeof crypto<"u"&&"randomUUID"in crypto?crypto.randomUUID():`li-${(uM++).toString(36)}`}function Rf(n,l){return{key:(l==null?void 0:l(n))??dM(),value:n}}function Db(n,l){return n.map(s=>Rf(s,l))}function $d(n){return JSON.stringify(n)}function ei({items:n,identityOf:l,min:s=0,max:o=1/0,axis:u="y",commit:d,onCommitted:h}){const[p,y]=_.useState(()=>Db(n,l)),[g,x]=_.useState(()=>$d(n)),v=_.useRef(p);_.useEffect(()=>{v.current=p},[p]);function E(j){v.current=j,y(j)}function M(j,O){E(j),x($d(j.map(z=>z.value))),d(j,O),h==null||h(j,O)}const N=C1({items:p,getKey:j=>j.key,onReorder:E,onDrop:j=>M(j,"reorder"),axis:u,threshold:5});if(!N.draggingKey){const j=$d(n);j!==g&&(x(j),y(Db(n,l)))}function A(j,O){const z=v.current;z.some(D=>D.key===j)&&M(z.map(D=>D.key===j?{...D,value:O(D.value)}:D),"edit")}return{rows:p,drag:N,atMax:p.length>=o,canRemove:p.length>s,add:j=>{const O=v.current;O.length>=o||M([...O,Rf(j,l)],"add")},remove:j=>{const O=v.current;O.length<=s||M(O.filter(z=>z.key!==j),"remove")},setValue:(j,O)=>A(j,()=>O),updateValue:A,replace:j=>M(j.slice(0,o),"replace"),mint:j=>Rf(j,l),indexOf:j=>p.findIndex(O=>O.key===j),keyAt:j=>{var O;return((O=p[j])==null?void 0:O.key)??null},latestRows:()=>v.current}}const fM="block h-auto max-h-35 w-auto max-w-full group-data-[ghost]/tile:opacity-[0.28]";function hM(n){return n.map(U1)}function pM({itemSlot:n,min:l,max:s,instanceId:o,slotId:u,value:d,propertyId:h,selectedItemIndex:p,commit:y}){var ue;const{api:g}=Vn(),x=Jr(n),v=pc(h),E=En(te=>te.byKey),M=te=>`${h}:${o}:${u}:${te}`,N=te=>(te.photo_id?v.get(te.photo_id):void 0)??te.url,A=_.useMemo(()=>hM(d),[d]),[j,O]=_.useState(!1),[z,D]=_.useState(null),Y=ei({items:A,min:l,max:s,axis:"xy",commit:y}),{rows:W}=Y,ee=e1(h,W.map(te=>te.value.crop_key),g.getCropDerivativeUrl),[ae,U]=_.useState(null),re=p??null;if(!Y.drag.draggingKey&&re!==ae&&(U(re),re!=null)){const te=Y.keyAt(re);te&&D(te)}const de=(te,P,k)=>{const I=$=>$.photo_id!==k||!!($.pending_crop&&$.pending_crop.crop_key!==P.crop_key);return{apply:($,T)=>Y.updateValue(te,B=>I(B)?B:{...B,rect:P.rect,ar:P.ar,crop_key:$,mobile:P.mobile?{rect:P.mobile.rect,crop_key:T??null,derived:P.mobile.derived}:B.mobile,pending_crop:null}),revert:()=>Y.updateValue(te,$=>I($)?$:{...$,pending_crop:null})}};Jv(W.flatMap(te=>{const P=te.value.pending_crop;return P?[{key:M(te.key),pending:P,propertyId:h,instanceId:o,slotId:u,itemIndex:Y.indexOf(te.key),rowKey:te.key,photoId:te.value.photo_id}]:[]}),te=>de(te.rowKey,te.pending,te.photoId));const ce=async te=>{var $,T,B;const P=z;if(D(null),!P)return;const k=W.find(q=>q.key===P);if(!k||!k.value.photo_id)return;if(Ov(te.rect)){(k.value.rect||k.value.crop_key||k.value.mobile||k.value.pending_crop)&&Y.updateValue(P,q=>({...q,rect:null,ar:null,crop_key:null,mobile:null,pending_crop:null}));return}const I=Y.indexOf(P);try{const q=await g.cropImage(h,k.value.photo_id,te.rect,(($=te.mobile)==null?void 0:$.rect)??null),V={job_id:q.job_id,crop_key:q.crop_key,rect:te.rect,ar:te.ar,mobile:te.mobile&&q.mobile?{job_id:q.mobile.job_id,crop_key:q.mobile.crop_key,rect:te.mobile.rect,derived:te.mobile.derived}:null};Y.updateValue(P,he=>({...he,pending_crop:V}));const me=de(P,V,k.value.photo_id);En.getState().start(M(P),{jobId:q.job_id,propertyId:h,cropKey:q.crop_key,mobileJobId:(T=q.mobile)==null?void 0:T.job_id,mobileCropKey:(B=q.mobile)==null?void 0:B.crop_key,instanceId:o,slotId:u,itemIndex:I,apply:me.apply,revert:me.revert})}catch(q){En.getState().notice(M(P),"failed"),console.error("[editor] image crop failed",{instanceId:o,slotId:u,key:P,err:q})}},ie=te=>{Y.replace(yc(W,te,P=>P.photo_id,P=>({photo_id:P.id,url:P.src,alt:P.caption??""}),Y.mint)),O(!1)},L=z?W.find(te=>te.key===z):null,G=L?N(L.value):"";function F(te,P,k){const I=N(te.value),$=Y.drag.draggingKey===te.key;return I?f.jsxs("span",{"data-thumb":!0,className:ye("block w-full",$&&"opacity-[0.28]"),children:[f.jsxs(z1,{src:I,derivativeUrl:te.value.crop_key?ee.get(te.value.crop_key):void 0,ar:te.value.ar,mode:x.mode,slotAspect:x.aspect,sizing:"tile",dimmed:M(te.key)in E,children:[M(te.key)in E&&f.jsx(Wv,{}),k]}),f.jsx(R1,{storeKey:M(te.key)})]}):f.jsxs("div",{className:ye(rs,"relative w-full"),style:{aspectRatio:String(x.aspect)},children:[P+1,k]})}function w(te,P){const k=N(te.value);return k?f.jsx("img",{className:fM,src:k,alt:"",draggable:!1}):f.jsx("div",{className:rs,children:P+1})}function Z(te){return f.jsx("button",{type:"button",className:L1,title:"Crop",onClick:()=>D(te.key),children:f.jsx(ze.crop,{})})}return f.jsxs(xh,{engine:Y,noun:"image",max:s,emptyText:"No images yet — use Add to choose photos.",onAdd:()=>O(!0),renderTile:F,renderClone:w,tileActions:Z,children:[j&&f.jsx(cl,{mode:"multi",title:"Add photos",propertyId:h,selectedIds:W.map(te=>te.value.photo_id),onApply:ie,onClose:()=>O(!1)}),L&&G&&f.jsx(sh,{chrome:cn,src:G,mode:x.mode,aspect:x.aspect,aspectLabel:x.aspectLabel,mobileAspect:x.mobileAspect,seed:{rect:L.value.rect??null},mobileSeed:{rect:((ue=L.value.mobile)==null?void 0:ue.rect)??null},onApply:te=>{ce(te)},onClose:()=>D(null)})]})}function mM({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),{items:h}=gh(o),p=l.tour_id?h.find(g=>g.id===l.tour_id):void 0,y=(p==null?void 0:p.src)||l.poster;return f.jsx(w1,{kind:"tour",label:n.label,poster:y,hasSelection:!!l.tour_id,addLabel:"Add tour",onPick:()=>d(!0),metaName:p==null?void 0:p.name,metaDetail:Af((p==null?void 0:p.provider)??l.provider),emptyText:"No tour yet",noPosterText:"No thumbnail from this provider",children:u&&f.jsx(cl,{mode:"single",title:"Choose a tour",propertyId:o,kinds:["tour"],initialFilter:"tour",noun:"tour",currentId:l.tour_id||void 0,onClose:()=>d(!1),onPick:g=>{d(!1),g.id!==l.tour_id&&s({...l,tour_id:g.id,url:"",poster:g.src,alt:l.alt||g.caption||"",...g.provider?{provider:g.provider}:{provider:void 0}})}})})}function yM(n,l){const s=n.matches("img")?n:n.querySelector("img");s&&l.poster&&s.setAttribute("src",l.poster)}function B1(n){if(n&&typeof n=="object"){const l=n;return{tour_id:typeof l.tour_id=="string"&&l.tour_id.length>0?l.tour_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",poster:typeof l.poster=="string"?l.poster:"",alt:typeof l.alt=="string"?l.alt:"",...typeof l.provider=="string"&&l.provider?{provider:l.provider}:{}}}return{tour_id:"",url:"",poster:"",alt:""}}const gM={PanelUI:mM,applyOptimistic:yM,coerce:B1};function bM(n){return n.map(B1)}function vM({min:n,max:l,value:s,propertyId:o,commit:u}){const{items:d}=gh(o),h=j=>d.find(O=>O.id===j),p=j=>{var O;return(j.tour_id?(O=h(j.tour_id))==null?void 0:O.src:void 0)||j.poster},y=_.useMemo(()=>bM(s),[s]),[g,x]=_.useState(!1),v=ei({items:y,min:n,max:l,axis:"xy",commit:u}),{rows:E}=v,M=j=>{v.replace(yc(E,j,O=>O.tour_id,O=>({tour_id:O.id,url:"",poster:O.src,alt:O.caption??"",...O.provider?{provider:O.provider}:{}}),v.mint)),x(!1)};function N(j,O,z){const D=h(j.value.tour_id);return f.jsx(S1,{kind:"tour",poster:p(j.value),index:O,ghost:v.drag.draggingKey===j.key,badge:sc(D??{kind:"tour",provider:j.value.provider}),overlays:z,placeholderClassName:rs})}function A(j,O){return f.jsx(k1,{poster:p(j.value),index:O,placeholderClassName:rs})}return f.jsx(xh,{engine:v,noun:"tour",max:l,emptyText:"No tours yet — use Add to choose tours.",onAdd:()=>x(!0),renderTile:N,renderClone:A,children:g&&f.jsx(cl,{mode:"multi",title:"Add tours",propertyId:o,kinds:["tour"],initialFilter:"tour",noun:"tour",selectedIds:E.map(j=>j.value.tour_id),onApply:M,onClose:()=>x(!1)})})}function xM({slot:n,value:l,onChange:s,propertyId:o}){const[u,d]=_.useState(!1),h=pc(o),{items:p}=So(o),y=l.video_id?p.find(E=>E.id===l.video_id):void 0,g=(l.video_id?h.get(l.video_id):void 0)??l.poster,x=(y==null?void 0:y.ready)===!1,v=d1(y==null?void 0:y.durationMs);return f.jsx(w1,{kind:"video",label:n.label,poster:g,hasSelection:!!l.video_id,addLabel:"Add video",onPick:()=>d(!0),status:x?"Processing…":null,metaName:y==null?void 0:y.name,metaDetail:v,emptyText:"No video yet",noPosterText:"Preparing poster…",children:u&&f.jsx(cl,{mode:"single",title:"Choose a video",propertyId:o,kinds:["video"],initialFilter:"video",videoSources:n.sources,currentId:l.video_id||void 0,onClose:()=>d(!1),onPick:E=>{d(!1),E.id!==l.video_id&&s({...l,video_id:E.id,url:"",poster:E.src,alt:l.alt||E.caption||"",...E.videoSource==="link"?{source:"link",...E.provider?{provider:E.provider}:{}}:{source:void 0,provider:void 0}})}})})}function Ub(n,l){return n.matches(l)?n:n.querySelector(l)}function _M(n,l){const s=Ub(n,"video");if(s){l.poster&&s.setAttribute("poster",l.poster),l.url&&s.setAttribute("src",l.url),l.alt&&s.setAttribute("aria-label",l.alt);return}const o=Ub(n,"img");o&&l.poster&&o.setAttribute("src",l.poster)}function H1(n){if(n&&typeof n=="object"){const l=n;return{video_id:typeof l.video_id=="string"&&l.video_id.length>0?l.video_id:typeof l.asset_id=="string"?l.asset_id:"",url:typeof l.url=="string"?l.url:"",poster:typeof l.poster=="string"?l.poster:"",alt:typeof l.alt=="string"?l.alt:"",width:typeof l.width=="number"?l.width:void 0,height:typeof l.height=="number"?l.height:void 0,...l.source==="link"?{source:"link"}:{},...typeof l.provider=="string"&&l.provider?{provider:l.provider}:{}}}return{video_id:"",url:"",poster:"",alt:""}}const wM={PanelUI:xM,applyOptimistic:_M,coerce:H1};function SM(n){return n.map(H1)}function kM({itemSlot:n,min:l,max:s,value:o,propertyId:u,commit:d}){const h=pc(u),{items:p}=So(u),y=z=>p.find(D=>D.id===z),g=z=>(z.video_id?h.get(z.video_id):void 0)??z.poster,x=_.useMemo(()=>SM(o),[o]),[v,E]=_.useState(!1),M=ei({items:x,min:l,max:s,axis:"xy",commit:d}),{rows:N}=M,A=z=>{M.replace(yc(N,z,D=>D.video_id,D=>({video_id:D.id,url:"",poster:D.src,alt:D.caption??"",...D.videoSource==="link"?{source:"link",...D.provider?{provider:D.provider}:{}}:{}}),M.mint)),E(!1)};function j(z,D,Y){const W=y(z.value.video_id);return f.jsx(S1,{kind:"video",poster:g(z.value),index:D,ghost:M.drag.draggingKey===z.key,badge:W?sc(W):"",overlays:Y,placeholderClassName:rs})}function O(z,D){return f.jsx(k1,{poster:g(z.value),index:D,placeholderClassName:rs})}return f.jsx(xh,{engine:M,noun:"video",max:s,emptyText:"No videos yet — use Add to choose videos.",onAdd:()=>E(!0),renderTile:j,renderClone:O,children:v&&f.jsx(cl,{mode:"multi",title:"Add videos",propertyId:u,kinds:["video"],initialFilter:"video",videoSources:n.sources,selectedIds:N.map(z=>z.value.video_id),onApply:A,onClose:()=>E(!1)})})}function EM(n){const l=n.fields;if(!l)return[];const s=n.item_order;if(!s||s.length===0)return Object.entries(l);const o=new Set,u=[];for(const d of s)d in l&&!o.has(d)&&(o.add(d),u.push([d,l[d]]));for(const[d,h]of Object.entries(l))o.has(d)||u.push([d,h]);return u}function jM(n){switch(n.type){case"text":case"select":case"url":return"";case"number":case"image":case"video":case"tour":case"poi":case"document":return null;case"list":return[]}}function Lb(n){const l={};for(const[s,o]of n)l[s]=jM(o);return l}function Bb(n,l,s,o){var y;const u=s.title;if(!u)return`Item ${o+1}`;const d=n[u],h=typeof d=="string"?d.trim():"";if(!h)return"Untitled";const p=(y=l.find(([g])=>g===u))==null?void 0:y[1];if((p==null?void 0:p.type)!=="select")return h;for(const g of p.values??[])if(typeof g!="string"&&g.value===h)return g.label;return h}function MM(n){const{editor:l,granularity:s}=bh(n),o=l==="row-editor"?{kind:"record",entries:EM(n)}:{kind:"single",slot:n.element??{type:"text",label:n.label}};return{editor:l,granularity:s,itemContent:o,min:typeof n.min=="number"?n.min:0,max:typeof n.max=="number"?n.max:1/0,axis:l==="gallery"?"xy":"y"}}const CM="flex flex-col gap-2.75",AM="flex items-center justify-between gap-2.5",NM="relative flex flex-col gap-1.75",TM="rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-3.5 text-center text-[length:calc(12.5*var(--content))] text-ink-4",OM=ye(ot,"flex h-8.5 w-full items-center justify-start gap-1.5 rounded-[calc(8*var(--content))] px-2.5 text-[length:calc(12.5*var(--content))] font-medium text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink disabled:cursor-default disabled:opacity-45 disabled:hover:bg-transparent"),RM="pointer-events-none absolute z-[30] flex items-center gap-2.5 rounded-[calc(8*var(--content))] border border-accent bg-white px-2.5 py-1.75 shadow-[0_14px_30px_-10px_rgba(20,18,13,0.35)]",zM="truncate text-[length:calc(13.5*var(--content))] text-ink";function DM({entry:n}){const l=n?mc(n):void 0;return f.jsx(ko,{glyph:(l==null?void 0:l.glyph)??"doc",extension:""})}function UM({slot:n,min:l,max:s,value:o,propertyId:u,commit:d}){var Y;const h=_.useMemo(()=>aj(o),[o]),[p,y]=_.useState(!1),g=m1(u),x=ei({items:h,min:l,max:s,axis:"y",commit:d}),{rows:v}=x,E=W=>{x.replace(yc(v,W,ee=>ee.asset_id,ee=>({asset_id:ee.id}),x.mint)),y(!1)},{containerRef:M,cloneRef:N,getItemProps:A,draggingKey:j,cloneBox:O}=x.drag,z=j?v.find(W=>W.key===j):null,D=`Add ${wo(n.label,"Document")}`;return f.jsxs("div",{className:CM,children:[f.jsx("div",{className:AM,children:f.jsx("span",{className:va,children:n.label})}),f.jsxs("div",{className:ye(NM,j&&"select-none [&_*]:select-none"),ref:M,children:[v.length===0&&f.jsx("div",{className:TM,children:"No documents yet — use Add to choose one."}),v.map(W=>f.jsx(b1,{entry:g(W.value.asset_id),onRemove:x.canRemove?()=>x.remove(W.key):void 0,dragProps:A(W.key),dragging:j===W.key},W.key)),z&&f.jsxs("div",{ref:N,className:RM,style:{width:O.w,height:O.h,left:0,top:0},children:[f.jsx(DM,{entry:g(z.value.asset_id)}),f.jsx("span",{className:zM,children:((Y=g(z.value.asset_id))==null?void 0:Y.name)??"Document unavailable"})]})]}),f.jsxs("button",{type:"button",className:OM,disabled:x.atMax,title:x.atMax?`Maximum ${s} documents`:void 0,onClick:()=>y(!0),children:[f.jsx(ze.plus,{})," ",D]}),p&&f.jsx(cl,{mode:"multi",propertyId:u,noun:"document",kinds:["document","photo","video"],initialFilter:"document",selectedIds:v.map(W=>W.value.asset_id),onApply:E,onClose:()=>y(!1)})]})}function LM(n,l){const s=lf(n),o=lf(l);return s!=null||o!=null?s===o:n===l?!0:n==null||l==null?!1:String(n)===String(l)}function BM(n,l,s,o,u){const d=Dl(p=>p.markSlotOverridden),h=!u&&J0(n)===null;return function(y,g){h&&d(l,s,{kind:"scalar"}),o(y.map(x=>x.value))}}async function HM(n,l,s){const o=await n(`/properties/${l}/poi/search`,{method:"POST",json:{query:s}});return Array.isArray(o==null?void 0:o.results)?o.results:[]}async function q1(n,l,s){return n(`/properties/${l}/poi/${encodeURIComponent(s)}`)}async function qM(n,l,s){if(s.length===0)return{};const o=await n(`/properties/${l}/poi/photo-urls`,{method:"POST",json:{place_ids:s}});return(o==null?void 0:o.urls)??{}}function G1(n){if(n==null||!Number.isFinite(n))return null;const l=n/1609.344;return l<.1?"< 0.1 mi":`${l.toFixed(1)} mi`}let GM=0;function IM(){return`poi${++GM}${Math.random().toString(36).slice(2,6)}`}const oc=n=>typeof n=="number"&&Number.isFinite(n)?n:void 0,oo=n=>typeof n=="string"&&n!==""?n:void 0;function QM(n){const l={},s=oc(n.rating);s!==void 0&&(l.rating=s);const o=oc(n.review_count);o!==void 0&&(l.review_count=o);const u=oo(n.type_label);u!==void 0&&(l.type_label=u);const d=oo(n.price_level);d!==void 0&&(l.price_level=d);const h=oo(n.website_uri);h!==void 0&&(l.website_uri=h);const p=oo(n.google_maps_uri);p!==void 0&&(l.google_maps_uri=p);const y=oo(n.summary);y!==void 0&&(l.summary=y);const g=KM(n.photo);return g!==void 0&&(l.photo=g),l}function KM(n){if(!n||typeof n!="object")return;const l=n,s=oc(l.width),o=oc(l.height),u=l.attribution;if(!(s===void 0||o===void 0||typeof u!="string"))return{width:s,height:o,attribution:u}}function I1(n){if(!n||typeof n!="object")return null;const l=n;return typeof l.place_id!="string"||typeof l.name!="string"||typeof l.lat!="number"||typeof l.lng!="number"?null:{id:typeof l.id=="string"?l.id:IM(),place_id:l.place_id,name:l.name,address:typeof l.address=="string"?l.address:null,lat:l.lat,lng:l.lng,distance_m:typeof l.distance_m=="number"?l.distance_m:null,...QM(l)}}function VM(n){return n.map(I1).filter(l=>l!==null)}function YM(n){return[n.rating===void 0?null:`★ ${n.rating.toFixed(1)}${n.review_count===void 0?"":` (${n.review_count.toLocaleString()})`}`,n.type_label,G1(n.distance_m),n.address].filter(Boolean).join(" · ")}const _h="group/row relative flex min-h-10.5 items-center gap-2.5 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 py-1.75 [transition:border-color_.14s,box-shadow_.14s,background_.3s]",rc="grid w-5 flex-shrink-0 place-items-center text-ink-4",wh="flex min-w-0 flex-1 flex-col gap-px",cc="truncate text-[length:calc(13.5*var(--content))] text-ink",Sh="truncate text-caption text-ink-3",Q1="rounded-[calc(8*var(--content))] border border-dashed border-line px-3 py-3.5 text-center text-[length:calc(12.5*var(--content))] text-ink-4",K1="text-caption text-danger",V1="opacity-70",Y1="size-[calc(14*var(--content))] flex-shrink-0 animate-[we-ml-spin_.7s_linear_infinite] rounded-full border-2 border-[#d9d5c9] border-t-accent",$M="size-[calc(26*var(--content))] flex-shrink-0 rounded-[calc(5*var(--content))] object-cover bg-[#f1f0ea]",FM="we-no-drag flex flex-shrink-0 items-center gap-0.75",XM="flex items-center gap-0.75 opacity-0 transition-opacity duration-[120ms] group-hover/row:opacity-100",ZM="grid size-6 cursor-pointer place-items-center rounded-md border-0 bg-transparent p-0 text-ink-3 outline-none hover:bg-[#f1f0ea] hover:text-ink-2",$1=()=>f.jsxs("svg",{viewBox:"0 0 16 16",width:"14",height:"14",className:"w-[calc(14*var(--content))] h-[calc(14*var(--content))]",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round",children:[f.jsx("path",{d:"M8 14s4.5-4 4.5-7.5a4.5 4.5 0 0 0-9 0C3.5 10 8 14 8 14Z"}),f.jsx("circle",{cx:"8",cy:"6.4",r:"1.7"})]});function F1(n,l){const{apiFetch:s}=Vn().api,[o,u]=_.useState({}),d=l.filter(p=>p.photo).map(p=>p.place_id).sort().join(","),h=_.useRef(new Set);return _.useEffect(()=>{const y=(d===""?[]:d.split(",")).filter(g=>!h.current.has(g));y.length!==0&&(y.forEach(g=>h.current.add(g)),qM(s,n,y).then(g=>{u(x=>({...x,...g}))}).catch(()=>{y.forEach(g=>h.current.delete(g))}))},[d,n,s]),{urls:o,dropUrl:p=>u(y=>{if(!(p in y))return y;const g={...y};return delete g[p],g})}}function X1({row:n,photoUrl:l,onPhotoError:s,onRemove:o,dragProps:u,dragging:d,flashNew:h}){const p=YM(n);return f.jsxs("div",{...u,className:ye(_h,u&&"cursor-grab hover:border-[#d9d5c9]",d&&"cursor-grabbing border-transparent bg-accent-soft [&>*]:opacity-[0.25]",h&&"animate-[we-ml-rowin_.26s_cubic-bezier(.2,.7,.3,1)_both]"),children:[l?f.jsx("img",{className:$M,src:l,alt:"",draggable:!1,onError:s}):f.jsx("span",{className:rc,children:f.jsx($1,{})}),f.jsxs("div",{className:wh,children:[f.jsx("span",{className:cc,children:n.name}),p&&f.jsx("span",{className:Sh,children:p})]}),o&&f.jsx("div",{className:FM,children:f.jsx("span",{className:XM,children:f.jsx("button",{type:"button",className:ye(ZM,"hover:bg-[#fbecea] hover:text-danger"),title:"Remove",onClick:o,children:f.jsx(ze.trash,{})})})})]})}const PM="relative flex flex-col",JM="flex min-w-0 items-center gap-2 rounded-[calc(8*var(--content))] border border-line bg-white px-2.5 transition-[border-color,box-shadow] duration-[120ms] focus-within:border-accent focus-within:shadow-[0_0_0_3px_rgba(15,42,34,0.07)]",WM="grid flex-shrink-0 place-items-center text-ink-4",eC="min-w-0 flex-1 appearance-none border-0 bg-transparent py-2.25 text-[length:calc(13.5*var(--content))] text-ink placeholder:text-ink-4",tC="size-[calc(15*var(--content))] flex-shrink-0 animate-[we-ml-spin_.7s_linear_infinite] rounded-full border-2 border-[#d9d5c9] border-t-accent",nC="absolute left-0 right-0 top-[calc(100%+4*var(--content))] z-[40] overflow-hidden rounded-[calc(8*var(--content))] border border-line bg-white shadow-[0_14px_30px_-12px_rgba(20,18,13,0.28)]",aC="m-0 max-h-[calc(264*var(--content))] list-none overflow-y-auto p-1",lC=ye(ot,"flex w-full flex-col gap-px rounded-md px-2 py-1.75 text-left"),iC="bg-accent-soft",sC="cursor-default opacity-55",oC="flex items-center gap-1.5 truncate text-[length:calc(13.5*var(--content))] text-ink",rC="truncate text-caption text-ink-3",Fd="px-3 py-3 text-center text-[length:calc(12.5*var(--content))] text-ink-4",cC="inline-flex flex-shrink-0 items-center gap-1 text-good",uC=2,dC=300;function Z1({propertyId:n,placeholder:l,addedIds:s,disabled:o=!1,disabledHint:u,onSelect:d}){const{apiFetch:h}=Vn().api,[p,y]=_.useState(""),[g,x]=_.useState([]),[v,E]=_.useState("idle"),[M,N]=_.useState(0),[A,j]=_.useState(0),O=_.useRef(0),z=_.useId();_.useEffect(()=>{const ee=p.trim();if(ee.length<uC){++O.current,E("idle"),x([]);return}const ae=++O.current;E("loading");const U=setTimeout(()=>{HM(h,n,ee).then(re=>{ae===O.current&&(x(re),N(0),E(re.length?"results":"empty"))}).catch(()=>{ae===O.current&&E("error")})},dC);return()=>clearTimeout(U)},[p,n,A,h]);function D(ee){s.has(ee.place_id)||(d(ee),y(""),x([]),E("idle"))}function Y(ee){if(ee.key==="Escape"){E("idle"),x([]);return}if(v==="results"){if(ee.key==="ArrowDown")ee.preventDefault(),N(ae=>Math.min(g.length-1,ae+1));else if(ee.key==="ArrowUp")ee.preventDefault(),N(ae=>Math.max(0,ae-1));else if(ee.key==="Enter"){ee.preventDefault();const ae=g[M];ae&&D(ae)}}}const W=v!=="idle";return f.jsxs("div",{className:PM,onBlur:ee=>{ee.currentTarget.contains(ee.relatedTarget)||E("idle")},children:[f.jsxs("div",{className:ye(JM,o&&"opacity-55"),role:"combobox","aria-expanded":W,"aria-haspopup":"listbox","aria-controls":z,children:[f.jsx("span",{className:WM,children:f.jsx(ze.search,{})}),f.jsx("input",{className:eC,value:p,placeholder:l,disabled:o,title:o?u:void 0,onChange:ee=>y(ee.target.value),onKeyDown:Y,"aria-label":l,"aria-autocomplete":"list","aria-activedescendant":v==="results"?`${z}-${M}`:void 0}),v==="loading"&&f.jsx("span",{className:tC})]}),W&&f.jsxs("div",{className:nC,children:[v==="loading"&&f.jsx("div",{className:Fd,children:"Searching…"}),v==="empty"&&f.jsxs("div",{className:Fd,children:["No places found for “",p.trim(),"”."]}),v==="error"&&f.jsxs("div",{className:Fd,children:["Couldn't reach search."," ",f.jsx("button",{type:"button",className:"font-semibold text-accent-ink underline",onClick:()=>j(ee=>ee+1),children:"Retry"})]}),v==="results"&&f.jsx("ul",{className:aC,role:"listbox",id:z,children:g.map((ee,ae)=>{const U=s.has(ee.place_id),re=[G1(ee.distance_m),ee.address].filter(Boolean).join(" · ");return f.jsx("li",{id:`${z}-${ae}`,role:"option","aria-selected":ae===M,children:f.jsxs("button",{type:"button",disabled:U,className:ye(lC,ae===M&&!U&&iC,U&&sC),onMouseEnter:()=>N(ae),onClick:()=>D(ee),children:[f.jsxs("span",{className:oC,children:[U&&f.jsxs("span",{className:cC,children:[f.jsx(ze.check,{size:12})," Added ·"]}),f.jsx("span",{className:"truncate",children:ee.name})]}),re&&f.jsx("span",{className:rC,children:re})]})},ee.place_id)})})]})]})}const fC="flex flex-col gap-2.75",hC="flex items-center justify-between gap-2.5 text-[length:calc(10.5*var(--content))] font-medium text-ink-4",pC="relative flex flex-col gap-1.75",mC="pointer-events-none absolute z-[30] flex items-center gap-2.5 rounded-[calc(8*var(--content))] border border-accent bg-white px-2.5 py-1.75 shadow-[0_14px_30px_-10px_rgba(20,18,13,0.35)]",yC=400;function gC({slot:n,min:l,max:s,value:o,propertyId:u,commit:d}){const{apiFetch:h}=Vn().api,p=_.useMemo(()=>VM(o),[o]),[y,g]=_.useState(null),[x,v]=_.useState(null),[E,M]=_.useState({}),N=_.useRef({});_.useEffect(()=>()=>{Object.values(N.current).forEach(clearTimeout)},[]);const A=ei({items:p,identityOf:ie=>ie.id,min:l,max:s,axis:"y",commit:d}),{rows:j}=A,{urls:O,dropUrl:z}=F1(u,p);function D(ie){M(L=>({...L,[ie]:!0})),clearTimeout(N.current[ie]),N.current[ie]=setTimeout(()=>M(L=>{const G={...L};return delete G[ie],G}),yC)}async function Y(ie){if(g(null),!A.atMax&&!A.latestRows().some(L=>L.value.place_id===ie.place_id)){v(ie);try{let L;try{L=await q1(h,u,ie.place_id)}catch{g("Couldn't add that place — try again.");return}if(A.latestRows().some(G=>G.value.place_id===L.place_id))return;A.add(L),D(L.id)}finally{v(null)}}}const{containerRef:W,cloneRef:ee,getItemProps:ae,draggingKey:U,cloneBox:re}=A.drag,de=U?j.find(ie=>ie.key===U):null,ce=new Set(j.map(ie=>ie.value.place_id));return f.jsxs("div",{className:fC,children:[f.jsx("div",{className:hC,children:f.jsx("span",{children:n.label})}),f.jsx(Z1,{propertyId:u,placeholder:n.placeholder??"Search nearby…",addedIds:ce,disabled:A.atMax,disabledHint:`Maximum ${s} places`,onSelect:ie=>void Y(ie)}),y&&f.jsx("span",{className:K1,children:y}),f.jsxs("div",{className:ye(pC,U&&"select-none [&_*]:select-none"),ref:W,children:[j.length===0&&!x&&f.jsx("div",{className:Q1,children:"No places yet — search above to add one."}),j.map(ie=>f.jsx(X1,{row:ie.value,photoUrl:O[ie.value.place_id],onPhotoError:()=>z(ie.value.place_id),onRemove:A.canRemove?()=>A.remove(ie.key):void 0,dragProps:ae(ie.key),dragging:U===ie.key,flashNew:E[ie.value.id]===!0},ie.key)),x&&f.jsxs("div",{className:ye(_h,V1),"aria-live":"polite",children:[f.jsx("span",{className:rc,children:f.jsx("span",{className:Y1})}),f.jsxs("div",{className:wh,children:[f.jsx("span",{className:cc,children:x.name}),f.jsx("span",{className:Sh,children:"Adding…"})]})]}),de&&f.jsxs("div",{ref:ee,className:mC,style:{width:re.w,height:re.h,left:0,top:0},children:[f.jsx("span",{className:rc,children:f.jsx($1,{})}),f.jsx("span",{className:cc,children:de.value.name})]})]})]})}const bC='input, textarea, select, button, [tabindex]:not([tabindex="-1"]), [contenteditable="true"]',zf="data-field-name";function vC(n,l){var o;const s=Array.from(n.querySelectorAll(`[${zf}]`)).find(u=>u.getAttribute(zf)===l);s&&(s.scrollIntoView({block:"nearest"}),(o=s.querySelector(bC))==null||o.focus({preventScroll:!0}))}function Df({slot:n,instanceId:l,slotId:s,value:o,propertyId:u,onChange:d,overridden:h,selectedItemIndex:p,selectedFieldName:y,itemBaseline:g,recordContext:x}){const v=ax(n.type);if(!v)return null;const E=v.coerce(o),{PanelUI:M}=v;return f.jsx(M,{slot:n,instanceId:l,slotId:s,value:E,onChange:d,propertyId:u,selectedItemIndex:p,selectedFieldName:y,overridden:h,itemBaseline:g,recordContext:x})}function xC(n){var l,s;switch(bh(n).editor){case"gallery":return((l=n.element)==null?void 0:l.type)==="video"?Vk:((s=n.element)==null?void 0:s.type)==="tour"?eh:Wk;case"poi-curation":return x5;case"document-list":return Qk;case"row-editor":return Pf;case"scalar-list":return d5}}function _C(n){switch(n.type){case"text":return W5;case"url":return o5;case"image":return Wf;case"video":return pv;case"tour":return eh;case"poi":return rv;case"document":return Jf;case"select":return k5;case"list":return xC(n);default:return Pf}}function P1(n){const l=new Set(n.map(_C));return l.size===1?[...l][0]:Pf}const wC=ye(ot,"flex w-full items-center justify-start gap-2 rounded-lg p-2.75 text-body font-semibold text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink"),SC=ye(ot,"inline-flex items-center gap-1.75 self-start h-9 px-3 rounded-lg text-body font-medium text-danger transition-[background,color] duration-[120ms] hover:bg-danger/15 focus-visible:bg-danger/15 focus-visible:ring-2 focus-visible:ring-danger/25"),kC="relative flex flex-col gap-3",EC="data-[ghost]:opacity-40",jC="pointer-events-none absolute left-0 top-0 z-50 flex items-center gap-2.5 overflow-hidden rounded border border-line bg-canvas pl-2 pr-3.5 shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)]";function Xd(n,l){return l&&typeof n[l]=="string"?{key:l,value:n[l]}:null}function MC({slot:n,entries:l,min:s,max:o,instanceId:u,slotId:d,value:h,commit:p,selectedItemIndex:y,selectedFieldName:g,itemBaseline:x}){const{Accordion:v,AccordionHeader:E}=Vn(),M=l.filter(([,V])=>lx(V)),N=Av(M.map(([,V])=>V)),A=P1(l.map(([,V])=>V)),j=Dl(V=>V.session.property_id),O=Dl(V=>V.select),z=Dl(V=>V.markSlotOverridden),D=Dl(V=>V.relinkSlot),Y=J0(n),W=Y?P0[Y].idKey:null;function ee(V){O({kind:"slot",instance_id:u,slot_id:d,item_index:V})}const ae=_.useRef(null),U=ei({items:h,identityOf:V=>{var me;return((me=Xd(V,W))==null?void 0:me.value)??null},min:s,max:o,axis:"y",commit:p,onCommitted:(V,me)=>{const he=ae.current;if(me!=="reorder"||he==null)return;const ke=V.findIndex(Ae=>Ae.key===he);ke>=0&&ee(ke)}}),{rows:re}=U,de=y??null,ce=de!=null?U.keyAt(de):null;_.useEffect(()=>{ae.current=ce},[ce]);const ie=_.useRef(null);_.useEffect(()=>{ce==null||!g||!ie.current||vC(ie.current,g)},[ce,g]);function L(){O({kind:"slot",instance_id:u,slot_id:d})}function G(V){if(ce===V)return L();const me=U.indexOf(V);me<0||ee(me)}function F(){if(U.atMax)return;const V=Y?{...Lb(l),[W]:nM()}:Lb(l);U.add(V),ee(re.length)}function w(V){if(!U.canRemove)return;const me=re.find(Ae=>Ae.key===V),he=me==null?void 0:me.value[W??""];Y!==null&&me!=null&&typeof he=="string"&&!D1(he)&&z(u,d,{kind:"item_removed",item_id:he});const ke=U.indexOf(V);U.remove(V),ce===V?L():de!=null&&ke>=0&&ke<de&&ee(de-1)}function Z(V,me){const he=re.find(Ae=>Ae.key===V);if(he==null)return;const ke=Xd(he.value,W);if(ke!=null){const Ae=x==null?void 0:x.find(Ue=>Ue[ke.key]===ke.value);for(const Ue of Object.keys(me))if(Ue!==ke.key){const nt=Ae==null?void 0:Ae[Ue];Ae!=null&&LM(me[Ue],nt)?D(u,d,{kind:"item",item_id:ke.value,field:Ue}):z(u,d,{kind:"item",item_id:ke.value,field:Ue})}}U.setValue(V,{...he.value,...me})}const{containerRef:ue,cloneRef:te,getItemProps:P,draggingKey:k,cloneBox:I}=U.drag,$=k?re.find(V=>V.key===k):null,T=$?re.indexOf($):-1,B=$?Bb($.value,l,n,T):"";function q(){return f.jsx("div",{ref:te,className:jC,style:{width:I.w,height:I.h},children:f.jsx(E,{icon:f.jsx(A,{size:14}),title:B,showGrip:!0,showChevron:!1})})}return f.jsxs("div",{className:"flex flex-col gap-3",children:[f.jsxs("div",{ref:ue,className:ye(kC,k&&"select-none [&_*]:select-none"),children:[re.map((V,me)=>{const he=Bb(V.value,l,n,me);return f.jsx("div",{"data-ghost":k===V.key?"":void 0,className:EC,children:f.jsx(v,{open:k==null&&ce===V.key,onToggle:()=>G(V.key),icon:f.jsx(A,{size:14}),title:he,scrollKey:V.key,dragId:V.key,dragHandleProps:{onPointerDown:P(V.key).onPointerDown},children:f.jsxs("div",{className:"flex flex-col gap-4",ref:ce===V.key?ie:void 0,children:[f.jsx(Nv,{rows:N,items:M.map(([ke,Ae])=>{var Ue;return f.jsx("div",{[zf]:ke,children:f.jsx(Df,{slot:Ae,instanceId:u,slotId:d,value:V.value[ke],propertyId:j,onChange:nt=>Z(V.key,{[ke]:nt}),recordContext:{itemId:(Ue=Xd(V.value,W))==null?void 0:Ue.value,itemIndex:me,siblingRecords:re.map(nt=>nt.value),fieldKey:ke,collection:Y,titleKey:n.title}})},ke)})}),ce===V.key&&U.canRemove&&f.jsxs("button",{type:"button",className:ye(SC,"max-w-full"),onClick:()=>w(V.key),children:[f.jsx("span",{className:"inline-flex shrink-0",children:f.jsx(ze.trash,{size:13})}),f.jsxs("span",{className:"min-w-0 truncate",children:["Delete ",he]})]})]})})},V.key)}),$?q():null]}),!U.atMax&&f.jsxs("button",{type:"button",className:wC,onClick:F,children:[f.jsx(ze.plus,{})," Add ",wo(n.label)]})]})}const Zd={listing_intent:n=>[{value:"for_sale",label:"For Sale"},{value:"for_rent",label:"For Rent"}]};function CC(n){return typeof n=="string"?{value:n,label:n}:{value:n.value,label:n.label}}function J1(n,l){var o,u;if(n.values)return n.values.map(CC);const s=(o=n.options)==null?void 0:o.source;return s!==void 0&&s!==""?((u=Zd[s])==null?void 0:u.call(Zd,l))??[]:[]}function AC(n){return n.trim().toLowerCase().replace(/\s+/g,"-")}const NC="fixed z-[120] max-h-[calc(240*var(--content))] overflow-y-auto rounded-[calc(8*var(--content))] border border-line bg-white shadow-[0_16px_38px_-12px_rgba(20,18,13,0.4)]",W1=ye(ot,"flex w-full items-center justify-between gap-2 rounded-none px-2.5 py-2 text-left text-body text-ink hover:bg-accent-soft data-[active=true]:bg-accent-soft"),TC=ye(W1,"text-accent"),OC=4,Hb=160,qb=8,RC=ye(ot,"min-w-0 flex-1 cursor-text bg-transparent py-2.25 text-left text-[length:calc(13.5*var(--content))] text-ink outline-none placeholder:text-ink-4");function Gb({open:n,className:l,onMouseDown:s}){return f.jsx("span",{className:ye("flex flex-shrink-0 items-center text-ink-4 transition-transform duration-[120ms]",n&&"rotate-180",l),onMouseDown:s,"aria-hidden":"true",children:f.jsx("svg",{width:"11",height:"11",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:f.jsx("path",{d:"m6 9 6 6 6-6"})})})}function zC(){return f.jsx("svg",{className:"flex-shrink-0 text-ink-2",width:"13",height:"13",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeWidth:"2.2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:f.jsx("path",{d:"M3.5 8.5l3 3 6-6.5"})})}function DC(n,l){const s=l.toLowerCase().trim();return s?n.filter(o=>o.label.toLowerCase().includes(s)):n}function UC(n,l){const s=l.toLowerCase().trim();return n.some(o=>o.label.toLowerCase()===s)}function Uf({label:n,value:l,options:s,onChange:o,placeholder:u,bare:d=!1,autoOpen:h=!1,onDismiss:p,id:y,creatable:g=!1,canCreate:x}){const[v,E]=_.useState(h),[M,N]=_.useState(0),[A,j]=_.useState(null),[O,z]=_.useState(""),D=_.useId(),Y=_.useRef(null),W=_.useRef(null),ee=_.useRef(null),ae=s.findIndex(q=>q.value===l),U=ae>=0?s[ae]:void 0,re=DC(s,v?O:""),de=AC(O),ce=v&&de.length>0?s.find(q=>q.value===de):void 0,ie=ce&&!re.some(q=>q.value===ce.value)?[...re,ce]:re,L=g&&de.length>0&&!UC(s,O)&&!ce&&((x==null?void 0:x(de))??!0),G=ie.length+(L?1:0);function F(){ee.current&&j(ee.current.getBoundingClientRect()),N(Math.max(0,ae)),E(!0)}const w=_.useCallback(()=>{E(!1),z(""),p==null||p()},[p]);function Z(q){var V;q.value!==l&&o(q.value),E(!1),z(""),(V=W.current)==null||V.focus()}function ue(q){var V;o(q),E(!1),z(""),(V=W.current)==null||V.focus()}function te(q){var V;if(!v){(q.key==="ArrowDown"||q.key==="Enter"||q.key===" ")&&(q.preventDefault(),F());return}if(q.key==="Escape")q.preventDefault(),(V=W.current)==null||V.focus(),w();else if(q.key==="ArrowDown")q.preventDefault(),N(me=>Math.min(G-1,me+1));else if(q.key==="ArrowUp")q.preventDefault(),N(me=>Math.max(0,me-1));else if(q.key==="Enter")if(q.preventDefault(),M<ie.length){const me=ie[M];me&&Z(me)}else L&&ue(de)}const P=_.useCallback(q=>{var he,ke;const V=(he=Y.current)==null?void 0:he.contains(q),me=(ke=document.getElementById(D))==null?void 0:ke.contains(q);return!V&&!me},[D]);function k(q){v&&P(q.relatedTarget)&&w()}_.useEffect(()=>{var q;h&&((q=W.current)==null||q.focus())},[h]),_.useEffect(()=>{if(!v)return;const q=()=>{ee.current&&j(ee.current.getBoundingClientRect())};return q(),window.addEventListener("scroll",q,!0),window.addEventListener("resize",q),()=>{window.removeEventListener("scroll",q,!0),window.removeEventListener("resize",q)}},[v]),_.useEffect(()=>{if(!v)return;const q=V=>{P(V.target)&&w()};return document.addEventListener("mousedown",q),()=>document.removeEventListener("mousedown",q)},[v,P,w]);const I=q=>{q.preventDefault(),v||F()},$=f.jsx("input",{ref:W,id:y,className:d?RC:ye(ss,"cursor-text"),value:v?O:(U==null?void 0:U.label)??l,placeholder:u??"",role:"combobox","aria-haspopup":"listbox","aria-expanded":v,"aria-controls":D,"aria-label":n,onFocus:F,onClick:()=>{v||F()},onChange:q=>{z(q.target.value),v||F(),N(0)},onKeyDown:te}),T=d?f.jsxs(f.Fragment,{children:[$,f.jsx(Gb,{open:v,className:"pl-2",onMouseDown:I})]}):f.jsxs(f.Fragment,{children:[$,f.jsx(Gb,{open:v,className:"pl-1 pr-2.75",onMouseDown:I})]}),B=v&&A&&G>0?ih.createPortal(f.jsxs("div",{className:NC,id:D,role:"listbox",style:{left:Math.max(qb,Math.min(A.left,window.innerWidth-Math.max(A.width,Hb)-qb)),top:A.bottom+OC,minWidth:Math.max(A.width,Hb)},children:[ie.map((q,V)=>f.jsxs("button",{type:"button",role:"option","aria-selected":q.value===l,"data-active":V===M,className:W1,onMouseEnter:()=>N(V),onMouseDown:me=>me.preventDefault(),onClick:()=>Z(q),children:[f.jsx("span",{className:"truncate",children:q.label}),q.value===l&&f.jsx(zC,{})]},q.value)),L&&f.jsx("button",{type:"button",role:"option","aria-selected":M===ie.length,"data-active":M===ie.length,className:TC,onMouseEnter:()=>N(ie.length),onMouseDown:q=>q.preventDefault(),onClick:()=>ue(de),children:f.jsxs("span",{className:"truncate",children:["Create “",de,"”"]})})]}),document.body):null;return d?f.jsxs("div",{className:"flex min-w-0 flex-1 items-center",ref:q=>{Y.current=q,ee.current=q},onBlurCapture:k,children:[T,B]}):f.jsxs("div",{className:Qn,ref:Y,onBlurCapture:k,children:[f.jsx("span",{className:va,children:n}),f.jsx("div",{className:ye(_o,v&&"border-accent"),ref:ee,children:T}),B]})}const LC="relative flex flex-col gap-2",BC="group/li flex cursor-text touch-none items-center gap-2 rounded-[calc(8*var(--content))] border border-line bg-white px-2.75 transition-[border-color,box-shadow] duration-[120ms] hover:border-[#d9d5c9] focus-within:border-accent",HC=ye(ot,"we-no-drag grid size-5.5 flex-shrink-0 place-items-center rounded-[calc(5*var(--content))] text-ink-3 transition-[background,color] duration-[120ms] hover:bg-[#FBE6E2] hover:text-[#8E2C1E]"),qC="pointer-events-none absolute z-[60] flex cursor-grabbing items-center gap-2 overflow-hidden rounded-[calc(8*var(--content))] bg-white px-2.75 text-[length:calc(13.5*var(--content))] text-ink shadow-[0_16px_38px_-8px_rgba(20,18,13,0.5)] after:absolute after:inset-0 after:rounded-[calc(9*var(--content))] after:border after:border-solid after:border-[#d9d5c9] after:content-['']",GC=ye(ot,"flex h-8.5 w-full items-center justify-start gap-1.5 rounded-[calc(8*var(--content))] px-2.5 text-[length:calc(12.5*var(--content))] font-medium text-ink-3 transition-colors duration-[120ms] hover:bg-line-soft hover:text-ink");function IC(n){const l=n.currentTarget.control;if(!l||n.target===l||n.target.closest("button")||(n.preventDefault(),l.focus(),!(l instanceof HTMLInputElement)))return;const o=n.clientX<l.getBoundingClientRect().left?0:l.value.length;l.setSelectionRange(o,o)}function ex({engine:n,label:l,addLabel:s=`Add ${wo(l)}`,renderControl:o,cloneText:u,onAdd:d,renderAdd:h,addDisabled:p=!1}){const{rows:y,drag:g}=n,{containerRef:x,cloneRef:v,getItemProps:E,draggingKey:M,cloneBox:N}=g,A=M?y.find(O=>O.key===M):null,j=h==null?void 0:h(n.add);return f.jsxs("div",{className:Qn,children:[f.jsx("span",{className:va,children:l}),f.jsxs("div",{className:"flex flex-col gap-2",children:[f.jsxs("div",{className:ye(LC,M&&"select-none [&_*]:select-none"),ref:x,children:[y.map(O=>f.jsxs("label",{htmlFor:O.key,onClick:IC,...E(O.key),"data-ghost":M===O.key?"":void 0,className:ye(BC,M===O.key&&"cursor-grabbing border-transparent bg-accent-soft"),children:[f.jsx("span",{"aria-hidden":"true",className:"flex flex-shrink-0 cursor-grab items-center text-ink-4 transition-colors duration-[120ms] hover:text-ink-2 group-data-[ghost]/li:opacity-[0.25]",children:f.jsx(ze.grip,{})}),o({id:O.key,value:O.value,onChange:z=>n.setValue(O.key,z)}),n.canRemove&&f.jsx("button",{type:"button",className:HC,title:"Remove",onClick:()=>n.remove(O.key),children:f.jsx(ze.trash,{})})]},O.key)),A&&f.jsxs("div",{ref:v,className:qC,style:{width:N.w,height:N.h,left:0,top:0,position:"absolute"},children:[f.jsx("span",{"aria-hidden":"true",className:"flex flex-shrink-0 items-center text-ink-4",children:f.jsx(ze.grip,{})}),f.jsx("span",{className:"min-w-0 flex-1 truncate py-2.25",children:u(A.value)})]})]}),j??(!n.atMax&&!p&&f.jsxs("button",{type:"button",className:GC,onClick:()=>d(n.add),children:[f.jsx(ze.plus,{})," ",s]}))]})]})}function QC({engine:n,label:l,placeholder:s="List item",addLabel:o,maxLength:u}){return f.jsx(ex,{engine:n,label:l,addLabel:o,cloneText:d=>d,renderControl:({id:d,value:h,onChange:p})=>f.jsx(Pr,{bare:!0,id:d,value:h,onChange:p,placeholder:s,ariaLabel:s,maxLength:u,className:"cursor-[inherit] py-2.25 text-[length:calc(13.5*var(--content))] group-data-[ghost]/li:opacity-[0.25]"}),onAdd:d=>d("")})}function KC({engine:n,label:l,options:s,unique:o=!1,creatable:u=!1}){const[d,h]=_.useState(!1),p=n.rows.map(E=>E.value),y=E=>o?s.filter(M=>M.value===E||!p.includes(M.value)):s,g=y(null),x=E=>{var M;return((M=s.find(N=>N.value===E))==null?void 0:M.label)??E},v=E=>!o||!p.includes(E);return f.jsx(ex,{engine:n,label:l,addDisabled:!u&&g.length===0,cloneText:E=>x(E),renderControl:({id:E,value:M,onChange:N})=>f.jsx(Uf,{bare:!0,id:E,label:l,value:M,options:y(M),onChange:N,creatable:u,canCreate:v}),onAdd:()=>h(!0),renderAdd:E=>d?f.jsx(Uf,{bare:!0,autoOpen:!0,label:`Add ${wo(l)}`,value:"",placeholder:"Choose one",options:g,onDismiss:()=>h(!1),onChange:M=>{h(!1),E(M)},creatable:u,canCreate:v}):null})}function VC({slot:n,itemSlot:l,min:s,max:o,value:u,commit:d}){const h=Dl(y=>y.session.listing_intent),p=ei({items:u,min:s,max:o,axis:"y",commit:d});return l.type==="select"?f.jsx(KC,{engine:p,label:n.label,options:J1(l,{listingIntent:h}),creatable:l.creatable===!0,unique:n.unique===!0}):f.jsx(QC,{engine:p,label:n.label,maxLength:l.cap})}function YC(n){const{slot:l,instanceId:s,slotId:o,value:u,onChange:d,recordContext:h}=n,p=MM(l),y=BM(l,s,o,d,h!=null);if(h&&A1(l,h))return f.jsx(N1,{slot:l,value:u,propertyId:n.propertyId,recordContext:h,onChange:x=>d(x)});if(p.itemContent.kind==="record")return f.jsx(MC,{slot:l,entries:p.itemContent.entries,min:p.min,max:p.max,instanceId:s,slotId:o,value:u,commit:y,selectedItemIndex:n.selectedItemIndex,selectedFieldName:n.selectedFieldName,itemBaseline:n.itemBaseline});const g=p.itemContent.slot;return p.editor==="gallery"?g.type==="tour"?f.jsx(vM,{min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):g.type==="video"?f.jsx(kM,{itemSlot:g,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):f.jsx(pM,{itemSlot:g,min:p.min,max:p.max,instanceId:s,slotId:o,value:u,propertyId:n.propertyId,selectedItemIndex:n.selectedItemIndex,commit:y}):p.editor==="document-list"?f.jsx(UM,{slot:l,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):p.editor==="poi-curation"?f.jsx(gC,{slot:l,min:p.min,max:p.max,value:u,propertyId:n.propertyId,commit:y}):f.jsx(VC,{slot:l,itemSlot:g,min:p.min,max:p.max,value:u,commit:y})}const $C={PanelUI:YC,applyOptimistic:null,coerce:n=>Array.isArray(n)?n:[]};function FC(n,l){const s=String(n??"").replace(/[^\d.]/g,"");if(s==="")return"";const[o,u]=s.split("."),d=Number((o||"0").replace(/[^\d]/g,"")||0).toLocaleString("en-US");return u!=null?`${d}.${u}`:d}function XC(n,l){let s=n.replace(l!=null&&l.decimals?/[^\d.]/g:/[^\d]/g,"");if(l!=null&&l.decimals){const u=s.indexOf(".");u>=0&&(s=s.slice(0,u+1)+s.slice(u+1).replace(/\./g,""))}const o=s.replace(/[^\d]/g,"");return(l==null?void 0:l.maxDigits)!=null&&o.length>l.maxDigits?null:s}function ZC({label:n,value:l,onChange:s,prefix:o,suffix:u,group:d,decimals:h,maxDigits:p,placeholder:y,errorText:g}){const x=d?FC(l):l;return f.jsxs("div",{className:Qn,children:[f.jsx("span",{className:va,children:n}),f.jsxs("div",{className:ye(_o,g&&"border-danger"),children:[o&&f.jsx("span",{className:ye(sf,"pl-2.75"),children:o}),f.jsx("input",{className:ye(ss,"[font-variant-numeric:tabular-nums]",o&&"pl-1"),inputMode:h?"decimal":"numeric",value:x,placeholder:y??"0",onChange:v=>{const E=XC(v.target.value,{decimals:h,maxDigits:p});E!=null&&s(E)}}),u&&f.jsx("span",{className:ye(sf,"pr-2.75"),children:u})]}),g&&f.jsx("p",{className:nh,children:g})]})}function PC(n){return n==null?"":String(n)}function tx(n){const l=n.trim();if(l==="")return null;const s=Number(l);return Number.isFinite(s)?s:null}function JC({slot:n,value:l,onChange:s}){return f.jsx(ZC,{label:n.label,value:PC(l),onChange:o=>s(tx(o)),prefix:n.prefix,suffix:n.suffix,group:n.thousandsSep,decimals:n.decimals,maxDigits:n.maxDigits,placeholder:n.placeholder})}const WC={PanelUI:JC,applyOptimistic:null,coerce:n=>typeof n=="number"?n:tx(typeof n=="string"?n:"")},eA="flex flex-col gap-2";function tA({slot:n,value:l,onChange:s,propertyId:o}){const{apiFetch:u}=Vn().api,[d,h]=_.useState(null),[p,y]=_.useState(null),g=_.useMemo(()=>l?[l]:[],[l]),{urls:x,dropUrl:v}=F1(o,g);async function E(M){if(h(null),(l==null?void 0:l.place_id)!==M.place_id){y(M);try{const N=await q1(u,o,M.place_id);s(N)}catch{h("Couldn't add that place — try again.")}finally{y(null)}}}return f.jsxs("div",{className:eA,children:[f.jsx(Z1,{propertyId:o,placeholder:n.placeholder??"Search nearby…",addedIds:l?new Set([l.place_id]):new Set,onSelect:M=>void E(M)}),d&&f.jsx("span",{className:K1,children:d}),p?f.jsxs("div",{className:ye(_h,V1),"aria-live":"polite",children:[f.jsx("span",{className:rc,children:f.jsx("span",{className:Y1})}),f.jsxs("div",{className:wh,children:[f.jsx("span",{className:cc,children:p.name}),f.jsx("span",{className:Sh,children:"Adding…"})]})]}):l?f.jsx(X1,{row:l,photoUrl:x[l.place_id],onPhotoError:()=>v(l.place_id),onRemove:()=>s(null)}):f.jsx("div",{className:Q1,children:"No place yet — search above to choose one."})]})}const nA={PanelUI:tA,applyOptimistic:null,coerce:I1};function aA({slot:n,value:l,onChange:s}){const o=Dl(d=>d.session.listing_intent),u=J1(n,{listingIntent:o});return f.jsx(Uf,{label:n.label,value:l??"",options:u,creatable:n.creatable??!1,placeholder:"Choose one",onChange:s})}const lA={PanelUI:aA,applyOptimistic:null,coerce:n=>typeof n=="string"?n:null},iA="data-slot-id",Ib="data-slot-text-leaf",sA="data-slot-group",oA="data-slot-item",rA="data-slot-field",cA="data-slot-unselectable",gc="data-section-instance-id";function uA(n,l){const s=[];n.hasAttribute(Ib)&&s.push(n),s.push(...Array.from(n.querySelectorAll(`[${Ib}]`))),s.length!==0&&s.forEach(o=>{dA(o,l)})}function dA(n,l){const s=n.ownerDocument,o=[];l.split(`
1099
- `).forEach((u,d)=>{d>0&&o.push(s.createElement("br")),o.push(s.createTextNode(u))}),n.replaceChildren(...o)}function nx(n){return typeof n=="string"?n:n==null?"":typeof n=="number"||typeof n=="boolean"?String(n):""}const fA={short:120,medium:240,long:2e3};function hA(n){return fA[n]}function pA({slot:n,value:l,onChange:s}){const o=l??"",u=n.size??"short",d=typeof n.cap=="number"?n.cap:hA(u);return u==="long"?f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder,multiline:!0,rows:5}):u==="medium"?f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder,multiline:!0,rows:2}):f.jsx(Pr,{value:o,onChange:s,label:n.label,max:d,maxLength:d,placeholder:n.placeholder??""})}const mA={PanelUI:pA,applyOptimistic:uA,coerce:nx};function yA({slot:n,value:l,onChange:s}){const o=l??"",[u,d]=_.useState(o),[h,p]=_.useState(o);o!==h&&(p(o),d(o));const y=Tf(u),g=Of(y),x=n.accepts,v=x===void 0||y===""||af(x,y),E=y!==""&&(!g||!v),M=N=>{const A=Tf(N);A!==""&&!Of(A)||A!==""&&x!==void 0&&!af(x,A)||(d(A),A!==o&&s(A))};return f.jsxs("div",{className:Qn,children:[f.jsx(yv,{label:n.label}),f.jsxs("div",{className:_o,children:[f.jsx("input",{className:ss,type:"text",inputMode:"url",value:u,placeholder:n.placeholder??"https://",spellCheck:!1,onChange:N=>d(N.target.value),onBlur:N=>M(N.target.value)}),f.jsx("span",{className:ye(sf,"pr-2.75"),children:g?f.jsx("a",{href:y,target:"_blank",rel:"noopener noreferrer",className:ye(ot,"flex items-center text-ink-4 hover:text-accent transition-colors duration-[120ms]"),"aria-label":"Open URL in new tab",children:f.jsx(ze.external,{})}):f.jsx("span",{className:"flex items-center text-ink-4 opacity-30",children:f.jsx(ze.external,{})})})]}),E&&f.jsx("p",{className:nh,children:g?Nf(x):"Not a valid URL"})]})}const gA={PanelUI:yA,applyOptimistic:null,coerce:nx};let Qb=null;function bA(){return Qb??(Qb={text:mA,number:WC,select:lA,image:iM,list:$C,poi:nA,url:gA,video:wM,tour:gM,document:Lj}),Qb}function ax(n){const s=bA()[n];return s===void 0?null:s}function lx(n){const l=ax(n.type);return l?l.isEditable?l.isEditable(n):n.locked!==!0:!1}function vA(n,l){const s=n.variant;return!s||l==null?!0:s.cases.includes(l)}function xA(n){const l=Object.keys(n.slots),s=n.slot_order;if(!s||s.length===0)return l;const o=new Set,u=[];for(const d of s)d in n.slots&&!o.has(d)&&(o.add(d),u.push(d));for(const d of l)o.has(d)||u.push(d);return u}function ix(n,l){const s=[],o=new Map,u=new Map;for(const d of n.groups??[])for(const h of d.members.flat())u.set(h,{id:d.id,label:d.label});for(const d of xA(n)){const h=n.slots[d];if(!lx(h)||!vA(h,l))continue;const p=u.get(d);if(p){let y=o.get(p.id);y||(y={kind:"group",key:p.id,label:p.label,Icon:null,items:[],rows:[]},o.set(p.id,y),s.push(y)),y.items.push({slotId:d,slot:h})}else bh(h).editor==="row-editor"?s.push({kind:"record",key:d,label:h.label,Icon:null,slotId:d,slot:h}):s.push({kind:"group",key:d,label:h.label,Icon:null,items:[{slotId:d,slot:h}],rows:[]})}for(const d of s)d.kind==="group"&&(d.rows=Av(d.items.map(h=>h.slot)),d.Icon=P1(d.items.map(h=>h.slot)));return s}function _A(n){return n==null?!0:typeof n=="string"?n.trim()==="":Array.isArray(n)?n.length===0:typeof n=="object"?Object.keys(n).length===0:!1}function wA(n,l,s){const o=[];for(const u of ix(n,l)){const d=u.kind==="group"?u.items:[{slotId:u.slotId,slot:u.slot}];for(const{slotId:h,slot:p}of d)p.variant&&_A(s(h))&&o.push(h)}return o}const SA=ge("Instagram",[["rect",{width:"20",height:"20",x:"2",y:"2",rx:"5",ry:"5",key:"ig-frame"}],["path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z",key:"ig-lens"}],["line",{x1:"17.5",x2:"17.51",y1:"6.5",y2:"6.5",key:"ig-flash"}]]),kA=ge("Facebook",[["path",{d:"M18 2h-3a5 5 0 0 0-5 5v3H7v4h3v8h4v-8h3l1-4h-4V7a1 1 0 0 1 1-1h3z",key:"fb-f"}]]),EA=ge("Linkedin",[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"li-arm"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"li-stem"}],["circle",{cx:"4",cy:"4",r:"2",key:"li-dot"}]]),jA=ge("XLogo",[["path",{d:"M18.901 1.153h3.68l-8.04 9.19L24 22.846h-7.406l-5.8-7.584-6.638 7.584H.474l8.6-9.83L0 1.154h7.594l5.243 6.932ZM17.61 20.644h2.039L6.486 3.24H4.298Z",transform:"translate(2 2) scale(0.8333)",fill:"currentColor",stroke:"none",key:"x-mark"}]]),MA={home:Zk,building:rk,template:a5,palette:C5,filePen:Bk,library:i5,plug:U5,helpCircle:_k,lock:h5,creditCard:Mk,settings:Y5,power:H5,user:s4,plus:cv,globe:$k,image:Wf,fileText:Jf,users:r4,eye:sv,eyeOff:iv,pulse:VS,search:dv,chart:fk,layout:t5,chevDown:mk,chevRight:gk,chevSelector:vk,pencil:N5,dots:Rk,grip:ov,external:lv,copy:Ek,trash:fv,archive:$S,sparkle:Z5,arrowUp:ak,arrowDown:XS,arrowLeft:WS,arrowRight:tk,undo:t4,redo:I5,logout:m5,check:av,x:mv,clock:Sk,calendar:uk,mapPin:rv,userPlus:l4,mail:g5,phone:O5,share:F5,upload:hv,bookOpen:ik,newspaper:j5,presentation:uv,instagram:SA,facebook:kA,linkedin:EA,xLogo:jA};function Pl({name:n,size:l=18,stroke:s=2,fill:o,color:u,className:d,style:h}){const p=MA[n];return f.jsx(p,{size:l,strokeWidth:s,fill:o??"none",color:u,className:d,style:{flexShrink:0,width:`calc(${l} * var(--content))`,height:`calc(${l} * var(--content))`,color:u??"currentColor",...h},"aria-hidden":"true"})}function CA(){return f.jsxs("div",{className:"hp-rest-in flex min-h-0 flex-1 flex-col items-center justify-center px-8 pb-10 text-center",children:[f.jsx("span",{className:"text-ink-4","aria-hidden":"true",children:f.jsx(Pl,{name:"pencil",size:22,stroke:1.6})}),f.jsx("p",{className:"m-0 mt-3 text-body-lg font-medium text-ink-2",children:"Nothing selected"}),f.jsx("p",{className:"m-0 mt-1 max-w-[calc(220*var(--content))] text-body leading-[1.45] text-ink-4",children:"Click anything on the canvas to edit it"})]})}const Kb=1;function Vb(n){const l=new URLSearchParams;for(const[o,u]of Object.entries(n))u!=null&&u!==""&&l.set(o,u);const s=l.toString();return s===""?"":`?${s}`}const Rl={catalog:"api/catalog",render:"api/render",media:n=>`api/media${Vb({fixture:n})}`,capture:(n,l)=>`api/capture/${n}${Vb({fixture:l.fixture,format:l.format,page:l.page,canvas:l.canvas})}`,live:(n,l)=>`fixtures/${encodeURIComponent(n)}/live${l==="/"?"/":`${l}/`}`,hmr:"__hmr"},AA={source:"source:changed",stylesheet:"stylesheet:changed",fixtures:"fixtures:changed"};async function Yb(n,l){const s=(await l.text().catch(()=>"")).trim();return new Error(s===""?`${n}: HTTP ${l.status}`:s)}function NA(n,l=(s,o)=>fetch(s,o)){const s=u=>new URL(u,n).href,o=async u=>{const d=await l(s(u));if(!d.ok)throw await Yb(u,d);return await d.json()};return{base:n,async catalog(){const u=await o(Rl.catalog);if(u.wire!==Kb)throw new Error(`This playground speaks wire ${Kb}, and its host answered with wire ${String(u.wire)}.`);return u},async render(u){const d=await l(s(Rl.render),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(u)});if(!d.ok)throw await Yb(Rl.render,d);return await d.json()},media:u=>o(Rl.media(u)),captureHref:(u,d)=>s(Rl.capture(u,d)),liveHref:(u,d)=>s(Rl.live(u,d)),subscribe(u){let d;try{d=new EventSource(s(Rl.hmr))}catch{return()=>{}}const h=Object.entries(u).map(([p,y])=>{const g=AA[p],x=()=>y();return d.addEventListener(g,x),()=>d.removeEventListener(g,x)});return()=>{for(const p of h)p();d.close()}}}}let Lf=null;function TA(n){Lf=n}function OA(){if(Lf===null)throw new Error("The playground's host is not installed yet.");return Lf}let sx=null;function RA(n){sx=n}function zA(){return sx}function $b(n,l){return`${n} ${l}${n===1?"":"s"}`}function DA(n){const l=[n.propertyType,n.listingIntent].filter(o=>o!==null).map(o=>o.replaceAll("_"," "));l.push($b(n.units,"unit"),$b(n.photos,"photo"));const s=l.join(", ");return s.charAt(0).toUpperCase()+s.slice(1)}function UA(n){return`${n.label} (${DA(n.summary)})`}function LA(n,l){return`${n}${n.includes("?")?"&":"?"}v=${encodeURIComponent(l)}`}function BA(n){return{basePath:n.basePath,stylesheets:n.stylesheets.map(l=>LA(l,n.cssRev)),importMap:n.importMap,islandMap:n.islands,hostScriptSrc:n.hostScript,hostResolvesOwnImports:Object.keys(n.importMap).length===0}}function Fb(n){const l=n.sectionSchemaByInstance??{};return{markers:{sectionInstanceId:gc,slotId:iA,slotGroup:sA,slotItem:oA,slotField:rA,slotUnselectable:cA},assets:BA(n),...n.pageBox===void 0?{}:{pageBox:n.pageBox},isSlotEditable:(s,o,u)=>{var h,p,y;const d=(h=l[s])==null?void 0:h.slots[o];return d===void 0||d.locked===!0?!1:u===void 0||((y=(p=d.fields)==null?void 0:p[u])==null?void 0:y.locked)!==!0}}}const HA=/^\/properties\/[^/]+\/poi\/search$/,qA=/^\/properties\/[^/]+\/poi\/([^/]+)$/,Bf=[{place_id:"pg-coffee",name:"Bluebird Coffee",address:"88 Market St",lat:40.798,lng:-73.972,distance_m:210,rating:4.6,review_count:312,type_label:"Coffee shop",price_level:"PRICE_LEVEL_INEXPENSIVE"},{place_id:"pg-park",name:"Riverside Park",address:"500 Riverside Dr",lat:40.8,lng:-73.97,distance_m:320,type_label:"Park"},{place_id:"pg-grocer",name:"Corner Grocery",address:"45 Vine Ave",lat:40.796,lng:-73.968,distance_m:480,rating:4.1,review_count:88,type_label:"Grocery store"},{place_id:"pg-school",name:"Lincoln Elementary School",address:"12 School St",lat:40.803,lng:-73.965,distance_m:640,type_label:"Elementary school"},{place_id:"pg-transit",name:"Metro Station — 5th & Main",address:null,lat:40.799,lng:-73.975,distance_m:750,type_label:"Transit station"},{place_id:"pg-gym",name:"Eastside Fitness",address:"300 Water St",lat:40.805,lng:-73.961,distance_m:1100,rating:3.9,review_count:174,type_label:"Gym",summary:"A neighborhood gym with a lap pool and early hours."}];function GA(n){const l=typeof n=="object"&&n!==null?n.query:void 0,s=typeof l=="string"?l.trim().toLowerCase():"";return s?{results:Bf.filter(o=>{var u;return o.name.toLowerCase().includes(s)||(((u=o.address)==null?void 0:u.toLowerCase().includes(s))??!1)})}:{results:Bf}}let IA=0;function QA(n,l={}){const s=(l.method??"GET").toUpperCase();if(s==="POST"&&HA.test(n))return Promise.resolve(GA(l.json));const o=s==="GET"?qA.exec(n):null;if(o){const u=decodeURIComponent(o[1]),d=Bf.find(h=>h.place_id===u);if(d)return Promise.resolve({...d,id:`pg-row-${++IA}`})}return Promise.reject(new Error(`No API backend in the playground: ${l.method??"GET"} ${n}. This capability is served by the host application; supply a provider to use it here.`))}function KA(n,l,s){const o=Math.min(Math.max(Math.round(n.nx*l),0),Math.max(l-1,0)),u=Math.min(Math.max(Math.round(n.ny*s),0),Math.max(s-1,0)),d=Math.max(Math.min(Math.round(n.nw*l),l-o),1),h=Math.max(Math.min(Math.round(n.nh*s),s-u),1);return{sx:o,sy:u,sw:d,sh:h}}function VA(n,l){return new Promise((s,o)=>{const u=l.createElement("img");u.onload=()=>s(u),u.onerror=()=>o(new Error(`Could not load ${n} to crop it.`)),u.src=n})}async function YA(n,l,s=document){const o=await VA(n,s),{sx:u,sy:d,sw:h,sh:p}=KA(l,o.naturalWidth,o.naturalHeight),y=s.createElement("canvas");y.width=h,y.height=p;const g=y.getContext("2d");if(!g)throw new Error("No 2d canvas context; cannot crop.");g.drawImage(o,u,d,h,p,0,0,h,p);const x=await new Promise(v=>y.toBlob(v));if(!x)throw new Error("Canvas produced no blob; cannot crop.");return URL.createObjectURL(x)}const $l="2026-01-01T00:00:00.000Z",Xb=new Map;function ul(n){let l=Xb.get(n);return l===void 0&&(l=OA().media(n).then(s=>s.items).catch(()=>[]),Xb.set(n,l)),l}function $A(n,l){return l.filter(s=>s.kind==="photo").map(s=>({id:s.id,property_id:n,name:s.name,thumbnail_url:s.src,uploaded_at:$l,caption:s.caption??null}))}function FA(n,l){return l.filter(s=>s.kind==="video").map(s=>({id:s.id,property_id:n,name:s.name,poster_url:s.src,ready:s.ready??!0,duration_ms:s.durationMs??null,width:null,height:null,uploaded_at:$l,caption:s.caption??null,source:s.provider===void 0?"upload":"link",provider:s.provider??null}))}function XA(n){return n.filter(l=>l.kind==="tour").map(l=>({id:l.id,name:l.name,provider:l.provider??"",poster_url:l.src,caption:l.caption??null,ready:l.ready??!0}))}function ZA(n,l){return l.filter(s=>s.kind==="document").map(s=>({id:s.id,property_id:n,name:s.name,mime:s.mime??"",size_bytes:s.sizeBytes??0,preview_url:s.src,uploaded_at:$l}))}function ox(n,l){return{floorplans:l.filter(o=>o.kind==="plan").map(o=>({id:o.id,property_id:n,source:null,thumbnail_url:o.src,ready:!0,uploaded_at:$l,display_label:tj(o.name,1)}))}}function us(n){return Promise.reject(new Error(`${n} is served by the host application and has no playground equivalent. A fixture's media is read-only.`))}async function PA(n){return{photos:$A(n,await ul(n))}}async function JA(n){return{videos:FA(n,await ul(n))}}async function WA(n){return{tours:XA(await ul(n))}}async function eN(n){return{documents:ZA(n,await ul(n))}}async function tN(n){return ox(n,await ul(n))}async function nN(n,l){const{floorplans:s}=ox(n,await ul(n)),o=s.find(u=>u.id===l);if(!o)throw new Error(`The fixture's property has no floor plan ${l}.`);return{source_url:o.thumbnail_url,source_bbox:null,ai_bbox:null,source_width:null,source_height:null}}function aN(n){return us("Upload status")}function lN(n,l,s){return us("Re-cropping a floor plan")}function iN(n,l,s){return us("Pasting a link")}function sN(n,l,s){return us("Uploading a comparable's photo")}function oN(n,l,s){return us("A comparable's photo")}function rN(n,l,s){return us("Uploading a comparable's photo")}const Hf=new Map;let Zb=0;async function cN(n,l,s,o){const d=(await ul(n)).find(y=>y.id===l);if(!(d!=null&&d.src))throw new Error(`The fixture's property has no asset ${l} to crop.`);const h=`dev-crop-${++Zb}`;Hf.set(h,{sourceUrl:d.src,rect:s});const p={status:"processing",job_id:h,crop_key:h};if(o){const y=`dev-crop-${++Zb}`;Hf.set(y,{sourceUrl:d.src,rect:o}),p.mobile={job_id:y,crop_key:y}}return p}function uN(n,l){return Promise.resolve({id:l,kind:"image_crop",status:"succeeded",enqueued_at:$l,started_at:$l,completed_at:$l})}const Pb=new Map;function dN(n,l){const s=Hf.get(l);if(!s)return Promise.reject(new Error(`Unknown crop ${l}.`));let o=Pb.get(l);return o||(o=YA(s.sourceUrl,s.rect),Pb.set(l,o)),o}const Jb="2026-01-01T00:00:00.000Z";function fN(n){return n.endsWith("logo (dark)")?"logo_dark":n.endsWith("logo (light)")?"logo_light":"headshot"}function hN(n,l){if(l)return l;const[s]=n.split(" — ");return s??n}function pN(n){const l=new Map;for(const s of n){if(s.kind!=="library")continue;const o=hN(s.name,s.caption);let u=l.get(o);switch(u||(u={id:`dev-contact-${o.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-|-$/g,"")}`,category:"contact",fields:{name:o},created_at:Jb,updated_at:Jb},l.set(o,u)),fN(s.name)){case"headshot":u.fields.avatar_upload_id=s.id,u.avatar_url=s.src;break;case"logo_dark":u.fields.logo_dark_upload_id=s.id,u.logo_dark_url=s.src;break;case"logo_light":u.fields.logo_light_upload_id=s.id,u.logo_light_url=s.src;break}}return[...l.values()]}async function mN(n="contact"){const l=zA();return{items:l===null?[]:pN(await ul(l))}}function kh(){return Promise.reject(new Error("Library uploads are served by the host application. The dev media pack is read-only."))}function yN(n,l){return kh()}function gN(n,l,s){return kh()}function bN(n,l){return kh()}function vN(n){return Promise.reject(new Error("There is no property in the playground: the canvas renders a template, not a listing."))}const xN=12;function _N(n,l,s,o){if(n.top>=o&&n.bottom<=l-o)return null;const d=Math.max(0,s+n.top-o);return Math.abs(d-s)<1?null:d}function rx({icon:n,title:l,subtitle:s,showGrip:o=!1,showChevron:u=!0,open:d}){return f.jsxs(f.Fragment,{children:[o?f.jsx("span",{"aria-hidden":"true",className:"-mr-1 flex flex-shrink-0 cursor-grab items-center text-ink-4 transition-colors duration-[120ms] hover:text-ink-2 active:cursor-grabbing",children:f.jsx(Pl,{name:"grip",size:14,stroke:1.8})}):null,f.jsx("span",{className:"grid size-6.5 flex-shrink-0 place-items-center rounded-md bg-accent-soft text-accent-ink","aria-hidden":"true",children:n}),s?f.jsxs("span",{className:"flex min-w-0 flex-1 flex-col gap-px",children:[f.jsx("span",{className:"truncate text-[length:calc(13.5*var(--content))] font-medium text-ink-2",children:l}),f.jsx("span",{className:"truncate text-[length:calc(11.5*var(--content))] text-ink-3 [font-variant-numeric:tabular-nums]",children:s})]}):f.jsx("span",{className:"min-w-0 flex-1 truncate text-left text-[length:calc(13.5*var(--content))] font-medium text-ink-2",children:l}),u?f.jsx("span",{"data-acc-open":d,className:"grid flex-shrink-0 place-items-center text-ink-3 transition-transform duration-150 ease-[ease] data-[acc-open=true]:rotate-180","aria-hidden":"true",children:f.jsx(Pl,{name:"chevDown",size:14,stroke:1.8})}):null]})}function cx({open:n,onToggle:l,icon:s,title:o,subtitle:u,scrollKey:d,dragId:h,dragHandleProps:p,children:y}){const g=_.useRef(null);return _.useEffect(()=>{if(!n)return;const x=g.current,v=x==null?void 0:x.closest(".hp-sb-scroll");if(!x||!v)return;const E=window.matchMedia("(prefers-reduced-motion: reduce)").matches,M=()=>{const O=x.getBoundingClientRect(),z=v.getBoundingClientRect(),D=_N({top:O.top-z.top,bottom:O.bottom-z.top,height:O.height},v.clientHeight,v.scrollTop,xN);D!=null&&v.scrollTo({top:D,behavior:E?"auto":"smooth"})};if(E){const O=requestAnimationFrame(M);return()=>cancelAnimationFrame(O)}const N=new AbortController,A=()=>{N.abort(),window.clearTimeout(j),M()};x.addEventListener("transitionend",O=>{O.propertyName==="grid-template-rows"&&O.target instanceof Node&&O.target.parentNode===x&&A()},{signal:N.signal});const j=window.setTimeout(A,280);return()=>{N.abort(),window.clearTimeout(j)}},[n,d]),f.jsxs("div",{ref:g,"data-open":n,"data-dragid":h,className:ye("we-acc flex-shrink-0 overflow-hidden rounded border border-line bg-canvas","origin-center [transform:scale(var(--gx,1),var(--gy,1))] [will-change:transform]","[transition:transform_.18s_cubic-bezier(.34,1.56,.64,1),box-shadow_.18s_ease,border-color_.16s_ease]","has-[>.we-acc-head:hover]:shadow-[0_4px_14px_-6px_rgba(20,24,15,0.18)]","has-[>.we-acc-head:active]:[transition-duration:.08s]","motion-reduce:[transform:none] motion-reduce:[transition:box-shadow_.18s_ease,border-color_.16s_ease]"),children:[f.jsx("button",{type:"button",className:ye("we-acc-head flex w-full cursor-pointer appearance-none items-center gap-2.5 border-0 bg-transparent pr-3.5 py-3 text-left outline-none",p?"pl-2":"pl-3.5",p&&"touch-none"),onClick:l,onPointerDown:p==null?void 0:p.onPointerDown,"aria-expanded":n,children:f.jsx(rx,{icon:s,title:o,subtitle:u,showGrip:p!=null,open:n})}),f.jsx("div",{"data-acc-open":n,className:"grid grid-rows-[0fr] transition-[grid-template-rows] duration-200 ease-out data-[acc-open=true]:grid-rows-[1fr] motion-reduce:transition-none","aria-hidden":!n,children:f.jsx("div",{className:"min-h-0 overflow-hidden",children:f.jsx("div",{"data-acc-open":n,className:"bg-white px-3.5 pb-4 pt-2 opacity-0 transition-opacity duration-200 ease-out data-[acc-open=true]:opacity-100 motion-reduce:transition-none",children:y})})})]})}function wN(n,l,s){return Promise.reject(new Error("Uploading is served by the host application; the playground has no upload backend."))}function SN(n,l){return Promise.reject(new Error("Uploading is served by the host application; the playground has no upload backend."))}const kN={getPhotos:PA,getVideos:JA,getTours:WA,getDocuments:eN,getFloorplans:tN,getUploads:aN,recropFloorplan:lN,listLibraryItems:mN,postUploadWithProgress:wN,deleteUpload:SN};function EN({open:n,onClose:l}){return n?f.jsxs("div",{className:"rounded-md border border-dashed border-ink-4 bg-accent-soft px-3 py-2.5","data-testid":"unit-plan-picker-stub",role:"dialog","aria-label":"Floor-plan assignment",children:[f.jsx("p",{className:"text-caption font-medium text-ink-2",children:"Floor-plan assignment lives in the app"}),f.jsx("p",{className:"mt-1 text-caption text-ink-3",children:"Assigning a floor plan to a unit is a property-editing act, done against a real property. The playground has no property, so this picker is inert here."}),f.jsx("button",{type:"button",className:"mt-2 rounded-md border border-ink-4 px-2 py-1 text-caption text-ink-2",onClick:l,children:"Close"})]}):null}function uc(n){return n===null||typeof n!="object"?JSON.stringify(n)??"undefined":Array.isArray(n)?`[${n.map(uc).join(",")}]`:`{${Object.keys(n).sort().map(l=>`${JSON.stringify(l)}:${uc(n[l])}`).join(",")}}`}function jN(n,l,s,o){if(l===null||l.fixtureId!==s)return[];const u=[];for(const[d,h]of Object.entries(n.slots)){const p=uc(h);if(p===uc(l.slots[d]))continue;const y=o.slots[d];y!==void 0&&u.push({id:`${d}:scalar::@${p}`,kind:"scalar",label:y.label,slotId:d})}return u}const MN={fact:"border-accent/40 text-accent",computed:"border-accent/40 text-accent",authored:"border-line text-ink-2",empty:"border-dashed border-line text-ink-4",edited:"border-honey-2 bg-honey/20 text-honey-ink"};function ux(n){return f.jsx("span",{className:"inline-flex flex-shrink-0 items-center gap-1","data-testid":"provenance-chips",children:n.chips.map(l=>f.jsx("span",{"data-testid":"provenance-chip","data-provenance":l.kind,"data-slots":l.slots.map(s=>s.id).join(" "),title:`${l.kind}: ${l.slots.map(s=>s.ref===null?s.id:`${s.id} ← ${s.ref}`).join(", ")}`,className:`pointer-events-auto inline-flex h-[18px] cursor-help items-center rounded-full border bg-canvas px-1.5 font-mono text-[10px] font-normal normal-case leading-none tracking-[0.02em] ${MN[l.kind]}`,children:l.kind},l.kind))})}function CN(n){return f.jsxs("div",{className:"relative",children:[n.children,f.jsx("div",{className:"pointer-events-none absolute right-10 top-[15px]",children:f.jsx(ux,{chips:n.chips})})]})}function AN(n,l){const s=!l,o=n.required&&!s;return{hidden:s,locked:o,title:o?"Required section — cannot hide":s?"Hidden from live page":"Visible on live page"}}function dx(n){const{variant:l}=n;return l===null||l.locked||l.cases.length<2?null:l.cases}function NN(n,l){return l||(n==null?void 0:n.kind)==="session"?{kind:"edited",ref:null}:n===void 0?{kind:"empty",ref:null}:n.kind==="fact"||n.kind==="computed"?{kind:n.kind,ref:n.ref}:{kind:n.kind,ref:null}}function TN(n,l,s){const o=new Map;for(const u of n){const{kind:d,ref:h}=NN(l==null?void 0:l[u],s(u));o.set(d,[...o.get(d)??[],{id:u,ref:h}])}return[...o].map(([u,d])=>({kind:u,slots:d}))}const Wb="grid h-8 w-8 cursor-pointer place-items-center rounded-md border-0 p-0 transition-colors";function ON(n){const l=AN(n.display,n.enabled);return f.jsxs("header",{className:"flex min-h-[calc(56*var(--content))] flex-shrink-0 items-center justify-between gap-3 px-5 pb-2 pt-4","data-testid":"section-header",children:[f.jsx("div",{className:"flex min-w-0 flex-1 items-center",children:f.jsx("h2",{className:"m-0 truncate text-body-lg font-semibold tracking-[-0.005em] text-ink",children:n.label})}),f.jsxs("div",{className:"inline-flex flex-shrink-0 items-center gap-0.5",children:[f.jsx("button",{type:"button","data-testid":"section-eye","aria-pressed":l.hidden,"aria-label":l.title,onClick:()=>!l.locked&&n.onSetEnabled(l.hidden),disabled:l.locked,title:l.title,className:`${Wb} disabled:cursor-not-allowed disabled:text-ink-4 disabled:opacity-100 ${l.hidden?"bg-[rgba(20,18,13,0.06)] text-ink [box-shadow:inset_0_0_0_1px_var(--color-line)]":"bg-transparent text-ink-2 hover:bg-[rgba(20,18,13,0.06)] hover:text-ink disabled:hover:bg-transparent disabled:hover:text-ink-4"}`,children:f.jsx(Pl,{name:l.hidden?"eyeOff":"eye",size:15,stroke:1.8})}),dx(n.display)?f.jsx("button",{type:"button","data-testid":"section-gear",onClick:n.onOpenSettings,title:"Section settings","aria-label":"Section settings",className:`${Wb} bg-transparent text-ink-2 hover:bg-[rgba(20,18,13,0.06)] hover:text-ink`,children:f.jsx(Pl,{name:"settings",size:15,stroke:1.8})}):null]})]})}const RN=ye("group/case flex cursor-pointer items-center gap-2.5 rounded border border-line bg-canvas px-3 py-2.5","transition-[border-color,background-color] hover:border-[var(--color-ink-4)]","has-[:focus-visible]:border-accent","data-[selected=true]:border-accent data-[selected=true]:bg-accent-soft");function zN(n){const l=dx(n.display),s=wA(n.sectionSchema,n.variant,n.slotValue).length;return f.jsxs(f.Fragment,{children:[f.jsx("header",{className:"flex min-h-[calc(56*var(--content))] flex-shrink-0 items-center justify-between gap-3 px-5 pb-2 pt-4",children:f.jsxs("nav",{className:"inline-flex min-w-0 items-center gap-1.5 text-body-lg tracking-[-0.005em]","aria-label":"Breadcrumbs",children:[f.jsx("button",{type:"button","data-testid":"settings-back",onClick:n.onBack,className:"max-w-[calc(220*var(--content))] cursor-pointer truncate border-0 bg-transparent p-0 font-medium text-ink-3 hover:bg-transparent transition-colors hover:text-ink hover:underline hover:underline-offset-[3px]",children:n.label}),f.jsx("span",{className:"inline-grid place-items-center leading-none text-ink-4","aria-hidden":"true",children:f.jsx(Pl,{name:"chevRight",size:12,stroke:1.8})}),f.jsx("span",{className:"max-w-[calc(220*var(--content))] truncate font-semibold text-ink",children:"Settings"})]})}),f.jsx("div",{className:"hp-sb-scroll min-h-0 flex-1 overflow-y-auto px-4 pb-6 pt-2","data-testid":"section-settings",children:l?f.jsxs("section",{"aria-label":"Variation",className:"flex flex-col gap-2.5",children:[f.jsx("h3",{className:"px-1 text-[length:calc(11.5*var(--content))] font-medium uppercase tracking-[0.04em] text-ink-3",children:"Variation"}),f.jsx("div",{className:"flex flex-col gap-2",children:l.map(o=>f.jsxs("label",{"data-selected":o.value===n.variant,className:RN,children:[f.jsx("input",{type:"radio",className:"sr-only",name:`variation-${n.instanceId}`,value:o.value,checked:o.value===n.variant,onChange:()=>n.onSetVariant(o.value)}),f.jsx("span",{"aria-hidden":"true",className:"grid size-4 flex-shrink-0 place-items-center rounded-full border-[1.5px] border-ink-4 transition-colors group-data-[selected=true]/case:border-accent",children:f.jsx("span",{className:"size-2 rounded-full bg-accent opacity-0 transition-opacity group-data-[selected=true]/case:opacity-100"})}),f.jsx("span",{className:"min-w-0 flex-1 truncate text-[length:calc(13.5*var(--content))] font-medium text-ink",children:o.label})]},o.value))}),s>0?f.jsx("p",{"aria-live":"polite",className:"rounded border border-line bg-accent-soft px-3 py-2 text-[length:calc(12.5*var(--content))] leading-[1.45] text-ink-2",children:s===1?"1 empty field in this variation":`${s} empty fields in this variation`}):null]}):f.jsx("p",{className:"px-1 py-3 text-[length:calc(12.5*var(--content))] text-ink-3",children:"Nothing to configure in this section."})})]})}function DN(){return typeof window<"u"&&typeof window.matchMedia=="function"&&window.matchMedia("(prefers-reduced-motion: reduce)").matches}function e0(n){return f.jsx("svg",{viewBox:"0 0 14 14",width:"13",height:"13",fill:"none",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M2.5 7h9M8 3.5 11.5 7 8 10.5"})})}function UN(n){return f.jsx("svg",{viewBox:"0 0 16 16",width:"15",height:"15",fill:"none",stroke:"currentColor",strokeWidth:"2.2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M3.5 8.5l3 3 6-6.5"})})}function t0(n){return f.jsx("svg",{viewBox:"0 0 14 14",width:"13",height:"13",fill:"none",stroke:"currentColor",strokeWidth:"1.7",strokeLinecap:"round","aria-hidden":"true",...n,children:f.jsx("path",{d:"M3.5 3.5l7 7M10.5 3.5l-7 7"})})}function LN({items:n,onApply:l}){const s=n??[],o=s.length,u=s.map(de=>de.id).join("|"),[d,h]=_.useState(!1),[p,y]=_.useState("idle"),[g,x]=_.useState(!1),[v,E]=_.useState(0),M=_.useRef(null),N=_.useRef(null),A=_.useRef(null),j=_.useRef(null),O=_.useRef(s),z=_.useRef(!0);_.useLayoutEffect(()=>{O.current=s});const D=_.useRef(DN()).current,Y=_.useCallback(de=>{const ce=M.current;if(D||document.hidden||ce==null||typeof ce.animate!="function"){x(!1),h(!1),y("idle"),de==null||de();return}x(!0);const ie=ce.animate([{opacity:1,transform:"none"},{opacity:0,transform:"translateY(6px)"}],{duration:240,easing:"cubic-bezier(.4,0,.2,1)",fill:"forwards"});ie.onfinish=()=>{x(!1),h(!1),y("idle"),de==null||de()}},[D]);_.useEffect(()=>(N.current!=null&&clearTimeout(N.current),o>0&&p==="idle"?u!==j.current&&!d&&(N.current=setTimeout(()=>{h(!0)},550)):o===0&&d&&!g&&p==="idle"&&Y(),()=>{N.current!=null&&clearTimeout(N.current)}),[o,u,d,p,g,Y]),_.useLayoutEffect(()=>{if(!d||p!=="idle"||D||g)return;const de=M.current;de!=null&&typeof de.animate=="function"&&!document.hidden&&de.animate([{opacity:.45,transform:"translateY(10px)"},{opacity:1,transform:"none"}],{duration:420,easing:"cubic-bezier(.18,.82,.25,1)"})},[d,p,D,g]),_.useEffect(()=>{if(p!=="applying")return;const de=ce=>{ce.preventDefault(),ce.returnValue=""};return window.addEventListener("beforeunload",de),()=>window.removeEventListener("beforeunload",de)},[p]),_.useEffect(()=>(z.current=!0,()=>{z.current=!1,N.current!=null&&clearTimeout(N.current),A.current!=null&&clearTimeout(A.current)}),[]);const W=()=>{const de=O.current;E(de.length),y("applying"),(async()=>{try{if(await l(de),!z.current)return;h(!1),y("success"),A.current!=null&&clearTimeout(A.current),A.current=setTimeout(()=>{Y(()=>{j.current=null})},1200)}catch{if(!z.current)return;y("error")}})()},ee=()=>{j.current=u,Y()};if(!d&&p!=="success"&&!g)return null;const ae=p==="applying",U=ae?v:o,re=U===1?f.jsxs(f.Fragment,{children:[f.jsx("b",{className:"font-bold text-ink",children:"1"})," change to your property details"]}):f.jsxs(f.Fragment,{children:[f.jsx("b",{className:"font-bold text-ink",children:U})," changes to your property details"]});return f.jsx("div",{className:"pointer-events-none absolute bottom-[10px] left-0 right-0 z-[6]","aria-live":"polite",children:f.jsx("div",{className:"pointer-events-none",ref:M,children:f.jsx("div",{className:"pointer-events-auto relative mx-3 rounded-[calc(11*var(--content))] border border-line bg-canvas px-[calc(13*var(--content))] pb-[calc(12*var(--content))] pt-[calc(11*var(--content))] shadow-[0_8px_22px_-8px_rgba(20,18,13,.26),0_2px_6px_rgba(20,18,13,.08)] data-[done]:border-[#cfe6d4] data-[done]:bg-[#eef6ef]","data-done":p==="success"?"":void 0,children:p==="success"?f.jsxs("div",{className:"flex items-center gap-2 text-body font-semibold text-good",children:[f.jsx("span",{className:"grid flex-shrink-0 place-items-center [animation:we-ub-pop_.34s_cubic-bezier(.2,1.3,.4,1)_both]",children:f.jsx(UN,{})}),"Updated everywhere"]}):p==="error"?f.jsxs(f.Fragment,{children:[f.jsxs("div",{className:"flex items-start gap-[calc(9*var(--content))]",children:[f.jsxs("div",{className:"min-w-0 flex-1 text-body leading-[1.4]",children:[f.jsx("div",{className:"font-semibold text-danger",children:"Couldn't update"}),f.jsx("div",{className:"mt-0.5 text-[length:calc(11.5*var(--content))] text-ink-3",children:"Something went wrong. Please try again."})]}),f.jsx("button",{type:"button",className:"-mr-0.5 -mt-0.5 grid h-[calc(20*var(--content))] w-[calc(20*var(--content))] flex-shrink-0 cursor-pointer place-items-center rounded-[calc(5*var(--content))] text-ink-4 transition-[background-color,color] duration-[120ms] hover:bg-[rgba(20,18,13,.06)] hover:text-ink-2",onClick:ee,"aria-label":"Dismiss",children:f.jsx(t0,{})})]}),f.jsxs("button",{type:"button","data-action":"retry",className:"mt-[calc(10*var(--content))] box-border inline-flex h-[calc(34*var(--content))] w-full cursor-pointer items-center justify-center gap-[calc(6*var(--content))] rounded-[calc(8*var(--content))] bg-accent text-[length:calc(12.5*var(--content))] font-semibold text-white transition-[background-color,transform] duration-[120ms] hover:bg-[#143a2f] active:translate-y-[0.5px]",onClick:W,children:["Retry ",f.jsx(e0,{})]})]}):f.jsxs(f.Fragment,{children:[f.jsxs("div",{className:"flex items-start gap-[calc(9*var(--content))]",children:[f.jsxs("div",{className:"min-w-0 flex-1 text-body leading-[1.4] text-ink-2",children:[re,f.jsx("div",{className:"mt-0.5 text-[length:calc(11.5*var(--content))] text-ink-3",children:"Update them everywhere these details are used."})]}),f.jsx("button",{type:"button",className:"-mr-0.5 -mt-0.5 grid h-[calc(20*var(--content))] w-[calc(20*var(--content))] flex-shrink-0 cursor-pointer place-items-center rounded-[calc(5*var(--content))] text-ink-4 transition-[background-color,color] duration-[120ms] hover:bg-[rgba(20,18,13,.06)] hover:text-ink-2 disabled:cursor-default disabled:opacity-50",onClick:ee,disabled:ae,"aria-label":"Dismiss",children:f.jsx(t0,{})})]}),f.jsx("button",{type:"button","data-action":"apply",disabled:ae,className:"mt-[calc(10*var(--content))] box-border inline-flex h-[calc(34*var(--content))] w-full cursor-pointer items-center justify-center gap-[calc(6*var(--content))] rounded-[calc(8*var(--content))] bg-accent text-[length:calc(12.5*var(--content))] font-semibold text-white transition-[background-color,transform] duration-[120ms] hover:bg-[#143a2f] active:translate-y-[0.5px] disabled:cursor-default disabled:hover:bg-accent disabled:active:translate-y-0",onClick:W,children:ae?f.jsxs(f.Fragment,{children:[f.jsx("span",{className:"inline-block size-[calc(14*var(--content))] animate-spin rounded-full border-2 border-white/40 border-t-white",role:"status","aria-label":"Updating"}),"Updating…"]}):f.jsxs(f.Fragment,{children:["Update everywhere ",f.jsx(e0,{})]})})]})})})})}const BN="Real editor chrome. The playground has no linked sources, so this cannot update anything — the flow above is a preview.",HN="Nothing was updated. In the app this writes the change to every deliverable sharing the linked source.";function qN({items:n}){const[l,s]=_.useState([]),o=n.filter(h=>!l.includes(h.id)),u=l.length>0&&o.length===0,d=_.useCallback(h=>{s(p=>[...p,...h.map(y=>y.id)])},[]);return f.jsxs("div",{className:"instance-panel__we",children:[f.jsx("div",{className:"instance-panel__we-anchor",children:f.jsx(LN,{items:o,onApply:d})}),o.length>0||u?f.jsx("p",{className:"instance-panel__we-caption","data-testid":"we-caption","data-phase":u?"applied":"preview",children:u?HN:BN}):null]})}const GN={apiFetch:QA,cropImage:cN,getCropDerivativeUrl:dN,getFloorplanSourcePage:nN,postLink:iN,stageLibraryItemImage:gN,presignLibraryItemUpload:yN,deleteStagedLibraryItemImage:bN,stageComparablePhoto:sN,presignComparablePhoto:oN,deleteStagedComparablePhoto:rN,fetchProperty:vN};function IN(n,l,s){return _.useMemo(()=>{const o={session:{property_id:n,listing_intent:null},select:u=>{if(u===null){s(null);return}if(u.kind==="section"){s({kind:"section",instanceId:u.instance_id});return}s({kind:"slot",instanceId:u.instance_id,slotId:u.slot_id,...u.item_index!==void 0?{itemIndex:u.item_index}:{}})},markSlotOverridden:()=>{},relinkSlot:()=>{}};return{useEditorStore:u=>u(o),Accordion:cx,AccordionHeader:rx,UnitPlanPicker:EN,capabilities:{upload:!1},api:GN}},[n,l,s])}function n0(n,l){const{selection:s}=n;if((s==null?void 0:s.kind)==="slot"&&!(s.instanceId!==n.instanceId||s.slotId!==l))return s.itemIndex}function a0(n,l){var s;return TN(l,(s=n.payload)==null?void 0:s.provenance,o=>n.override.slots[o]!==void 0)}function Pd(n,l){var o;const s=n.override.slots[l];return s!==void 0?s:(o=n.payload)==null?void 0:o.resolvedProps.slots[l]}function QN(n){var p;const l=IN(n.fixture,n.selection,n.onSelect),s=_.useMemo(()=>new DE,[]),o=n.displayState.variant,u=_.useMemo(()=>ix(n.sectionSchema,o),[n.sectionSchema,o]),d=_.useMemo(()=>jN(n.override,n.baseline,n.fixture,n.sectionSchema),[n.override,n.baseline,n.fixture,n.sectionSchema]),h=((p=n.selection)==null?void 0:p.kind)==="slot"&&n.selection.instanceId===n.instanceId?n.selection.slotId:null;return f.jsxs("aside",{className:"instance-panel","data-testid":"instance-panel","data-instance-id":n.instanceId,children:[n.settingsOpen?f.jsx(zN,{instanceId:n.instanceId,label:n.label,display:n.display,sectionSchema:n.sectionSchema,variant:o,slotValue:y=>Pd(n,y),onSetVariant:n.onSetVariant,onBack:n.onCloseSettings}):f.jsx(ON,{label:n.label,display:n.display,enabled:n.displayState.enabled,onSetEnabled:n.onSetEnabled,onOpenSettings:n.onOpenSettings}),n.settingsOpen?null:n.renderError?f.jsx("p",{className:"instance-panel__error","data-testid":"render-error",children:n.renderError}):null,n.settingsOpen?null:n.payload===null?f.jsx("p",{className:"instance-panel__empty","data-testid":"panel-loading",children:"Loading…"}):f.jsx(UE,{client:s,children:f.jsx(WE,{api:kN,children:f.jsxs(bj,{ports:l,children:[f.jsx(FE,{getJobStatus:uN}),f.jsxs("div",{className:"instance-panel__dock",children:[f.jsxs("div",{className:"hp-sb-scroll instance-panel__cards","data-testid":"slot-cards","data-dirty":d.length>0?"":void 0,children:[u.map(y=>y.kind==="record"?f.jsxs("section",{"aria-label":y.label,"data-testid":"object-list-card",className:"flex flex-col gap-2.5",children:[f.jsxs("h3",{className:"flex items-center gap-1.5 px-1 text-[length:calc(11.5*var(--content))] font-medium uppercase tracking-[0.04em] text-ink-3",children:[y.Icon?f.jsx(y.Icon,{size:13}):null,y.label,f.jsx("span",{className:"ml-auto",children:f.jsx(ux,{chips:a0(n,[y.slotId])})})]}),f.jsx("div",{className:"flex flex-col gap-3",children:f.jsx(Df,{slot:y.slot,instanceId:n.instanceId,slotId:y.slotId,value:Pd(n,y.slotId),propertyId:n.fixture,onChange:g=>n.onApplySlot(y.slotId,g),selectedItemIndex:n0(n,y.slotId)})})]},y.key):f.jsx(CN,{chips:a0(n,y.items.map(g=>g.slotId)),children:f.jsx(cx,{open:h!=null&&y.items.some(g=>g.slotId===h),onToggle:()=>h!=null&&y.items.some(g=>g.slotId===h)?n.onSelect({kind:"section",instanceId:n.instanceId}):n.onSelect({kind:"slot",instanceId:n.instanceId,slotId:y.items[0].slotId}),icon:y.Icon?f.jsx(y.Icon,{size:14}):null,title:y.label,scrollKey:y.key,children:f.jsx(Nv,{items:y.items.map(({slotId:g,slot:x})=>f.jsx(Df,{slot:x,instanceId:n.instanceId,slotId:g,value:Pd(n,g),propertyId:n.fixture,onChange:v=>n.onApplySlot(g,v),selectedItemIndex:n0(n,g)},g)),rows:y.rows})})},y.key)),u.length===0?f.jsx("p",{className:"instance-panel__empty","data-testid":"no-editable-slots",children:"Nothing to edit in this section."}):null]}),f.jsx(qN,{items:d})]})]})})})]})}function KN(n,l){return n.find(s=>s.pages.includes(l))??null}function VN(n,l,s,o){const u=l.endsWith("/")?l:`${l}/`;if(!n.startsWith(u))return null;const d=n.indexOf("#"),h=d===-1?null:n.slice(d+1),p=(d===-1?n:n.slice(0,d)).slice(u.length).split("/").filter(Boolean),[y,g,x,v,...E]=p;if(y!=="fixtures"||g===void 0||x!=="live"||E.length>0)return null;const M=v===void 0?"/":`/${decodeURIComponent(v)}`,N=s.find(j=>j.path===M);if(!N)return null;const A=KN(o,N.id);return A?{pageId:N.id,canvasId:A.id,anchor:h||null}:null}const Jd="box-border inline-flex h-10 w-full items-center justify-center gap-1.75 rounded-lg border text-center text-[length:calc(13.5*var(--content))] font-semibold tracking-[-0.005em]",YN="group cursor-pointer border-line bg-canvas text-ink transition-[background-color,border-color,box-shadow,color,transform] hover:border-[var(--color-ink-4)] hover:bg-[#fafaf8] active:translate-y-[0.5px]",$N="cursor-pointer border-honey-2 bg-honey text-honey-ink transition-[background-color,border-color,box-shadow,color,transform] hover:bg-honey-2 hover:shadow-[0_2px_6px_rgba(40,44,50,0.12)] active:translate-y-[0.5px]",FN="cursor-not-allowed border-line bg-[#f3f1ea] text-ink-4";function XN({host:n,templateName:l,fixture:s,output:o,format:u,canvas:d,pagePath:h}){const p=o==="website"?{href:n.liveHref(s,h??"/"),title:`Open this page as it would publish — ${l}`}:null,y=o==="image"?{href:n.captureHref("bundle",{fixture:s,format:u,canvas:d}),title:`Download every page of this canvas as a zip — ${l}`}:o==="document"?{href:n.captureHref("print",{fixture:s,format:u}),title:`Download the PDF — ${l}`}:null;return f.jsx("footer",{className:"flex-shrink-0 border-t border-line-soft bg-canvas p-3","data-testid":"panel-footer",children:f.jsxs("div",{className:y&&!p?"w-full":"grid w-full grid-cols-2 gap-2",children:[p?f.jsxs("a",{href:p.href,target:"_blank",rel:"noopener noreferrer","data-testid":"view-live",title:p.title,className:`${Jd} ${YN}`,children:[f.jsx("span",{className:"grid place-items-center text-ink-3 transition-colors group-hover:text-ink",children:f.jsx(Pl,{name:"external",size:12,stroke:1.6})}),f.jsx("span",{"data-testid":"view-live-label",children:"View live"})]}):null,y?f.jsxs("a",{href:y.href,"data-testid":"download",title:y.title,className:`${Jd} ${$N}`,children:[f.jsx(Tk,{size:14,className:"h-[calc(14*var(--content))] w-[calc(14*var(--content))]"}),f.jsx("span",{"data-testid":"download-label",children:"Download"})]}):f.jsx("button",{type:"button",disabled:!0,"data-testid":"publish",title:"Publishing needs a property and a deliverable — preview publish states in the application",className:`${Jd} ${FN}`,children:f.jsx("span",{children:"Publish"})})]})})}function ZN(n,l,s,o){const u=n.ownerDocument,d=[],h=new Map;for(const p of Array.from(n.children)){const y=p,g=y.getAttribute(gc);g&&h.set(g,y)}for(const p of l){const y=h.get(p.instance_id),g=(y==null?void 0:y.dataset.svId)!==p.section_version_id;y&&g&&(o==null||o(y),y.remove());const x=y&&!g,v=x?y:s(p,u);x||d.push(v),n.appendChild(v),h.delete(p.instance_id)}return h.forEach(p=>{o==null||o(p),p.remove()}),d}function fx(n){return n==null?void 0:n.__trCanvasIslands}function PN(n,l,s,o){const u=n==null?void 0:n.querySelector(`[${gc}="${s}"]`);if(!u)return!1;const d=u.querySelector(":scope > .we-section-body")??u,h=fx(l);return h==null||h.unmountRoot(u),d.innerHTML=o,h==null||h.hydrateRoot(u),!0}function JN(){return{slots:{}}}function Hn(n,l,s){var o;return((o=n[l])==null?void 0:o[s])??JN()}function Eh(n,l,s,o){return{...n,[l]:{...n[l],[s]:o}}}function WN(n,l,s,o,u){const d=Hn(n,l,s);return Eh(n,l,s,{...d,slots:{...d.slots,[o]:u}})}function eT(n,l,s,o){return Eh(n,l,s,{...Hn(n,l,s),enabled:o})}function tT(n,l,s,o){return Eh(n,l,s,{...Hn(n,l,s),variant:o})}function nT(n,l){const s=n.enabled??(l==null?void 0:l.enabled)??!0,o=n.variant??(l==null?void 0:l.variant);return o===void 0?{enabled:s}:{enabled:s,variant:o}}function aT(n){return Object.keys(n.slots).length===0?{}:{slots:n.slots}}function lT(n,l){const s={};for(const[o,u]of Object.entries(n[l]??{}))u.enabled===void 0&&u.variant===void 0||(s[o]={...u.enabled===void 0?{}:{enabled:u.enabled},...u.variant===void 0?{}:{variant:u.variant}});return s}function iT(n,l){return Object.keys(n).filter(s=>l[s]!==n[s])}function l0(n,l){if(!l.some(o=>o in n))return n;const s={...n};for(const o of l)delete s[o];return s}function i0(n,l,s,o){return{...n,[l]:{...n[l],[s]:o}}}function sT(n,l,s){const o=n[l];if(!o||!(s in o))return n;const u={...o};return delete u[s],{...n,[l]:u}}function oT(n){const{host:l,fixture:s,doc:o,resolvedDisplay:u,sessions:d,pages:h,frameFor:p}=n,{edits:y,baselines:g,setEdits:x,setBaseline:v}=d,[E,M]=_.useState({}),[N,A]=_.useState({}),j=[s,o??"",...h.map($=>$.id)].join("\0"),[O,z]=_.useState(j);O!==j&&(z(j),M({}),A({}));const D=_.useRef(E);D.current=E;const Y=_.useRef(p);Y.current=p;const W=_.useRef(h);W.current=h;const ee=_.useRef(y);ee.current=y;const ae=_.useRef(s);ae.current=s;const U=_.useRef(o);U.current=o;const re=_.useRef(new Map),de=_.useCallback($=>Hn(y,s,$),[y,s]),ce=_.useCallback($=>nT(Hn(y,s,$),u==null?void 0:u[$]),[y,s,u]),ie=_.useCallback(($,T)=>{var B;return((B=N[$])==null?void 0:B[T])??null},[N]),L=_.useCallback($=>{var T;for(const B of h){const q=(T=N[B.id])==null?void 0:T[$];if(q!==void 0)return q}return null},[N,h]),G=_.useCallback($=>{var T;for(const B of h){const q=(T=E[B.id])==null?void 0:T[$];if(q)return q}return null},[E,h]),F=_.useCallback($=>{var T;return((T=g[s])==null?void 0:T[$])??null},[g,s]),w=_.useCallback(async($,T,B,q)=>{const V=$.id,me=ae.current,he=U.current,ke=`${V}\0${T}`,Ae=(re.current.get(ke)??0)+1;re.current.set(ke,Ae);const Ue=()=>me!==ae.current||he!==U.current||re.current.get(ke)!==Ae;try{const nt=await l.render({page:V,instance:T,fixture:me,session:aT(B),display:lT(ee.current,me)});if(Ue()||(M(hn=>i0(hn,V,T,nt)),Object.keys(B.slots).length===0&&B.variant===void 0&&v(me,T,{fixtureId:me,slots:nt.resolvedProps.slots}),A(hn=>sT(hn,V,T)),!q))return;const{doc:Ve,win:Oe}=Y.current(V);PN(Ve,Oe,T,nt.html)}catch(nt){if(Ue())return;const Ve=nt instanceof Error?nt.message:String(nt);A(Oe=>i0(Oe,V,T,Ve))}},[l,v]),Z=_.useCallback(($,T)=>{var q;if((q=D.current[$])!=null&&q[T])return;const B=W.current.find(V=>V.id===$);B&&w(B,T,Hn(ee.current,ae.current,T),!1)},[w]),ue=_.useCallback(($,T)=>{var B;for(const q of W.current)((B=D.current[q.id])==null?void 0:B[$])!==void 0&&w(q,$,T,!0)},[w]),te=_.useCallback($=>{ue($,Hn(ee.current,ae.current,$))},[ue]),P=_.useCallback(($,T,B)=>{const q=WN(ee.current,ae.current,$,T,B);ee.current=q,x(q),ue($,Hn(q,ae.current,$))},[ue,x]),k=_.useCallback(($,T)=>{const B=eT(ee.current,ae.current,$,T);ee.current=B,x(B);for(const q of W.current)for(const V of Object.keys(D.current[q.id]??{}))w(q,V,Hn(B,ae.current,V),!0)},[w,x]),I=_.useCallback(($,T)=>{const B=tT(ee.current,ae.current,$,T);ee.current=B,x(B),ue($,Hn(B,ae.current,$))},[ue,x]);return _.useMemo(()=>({overrideFor:de,displayFor:ce,payloads:E,errorOn:ie,errorFor:L,payloadFor:G,baselineFor:F,ensureLoaded:Z,reload:te,applySlot:P,setEnabled:k,setVariant:I}),[de,ce,E,ie,L,G,F,Z,te,P,k,I])}const rT={slots:{},slot_order:[]},cT={required:!1,variant:null},uT=[];function s0(n){return n?n.kind==="section"?{kind:"section",instance_id:n.instanceId}:{kind:"slot",instance_id:n.instanceId,slot_id:n.slotId,...n.itemIndex!==void 0?{item_index:n.itemIndex}:{}}:null}function dT(n){return n.kind==="section"?{kind:"section",instanceId:n.instance_id}:{kind:"slot",instanceId:n.instance_id,slotId:n.slot_id,...n.item_index!==void 0?{itemIndex:n.item_index}:{}}}function fT(n,l){if(!n)return[];const s=[];for(const o of n.pages){const u=l.find(d=>d.id===o);u&&s.push(u)}return s}function Xr(n,l,s,o){var y;const u=((y=l.doc)==null?void 0:y.getElementById(n))??null;if(!u||!s)return;const d=u.getBoundingClientRect(),h=Uw({top:d.top,height:d.height},l.wrapper.offsetTop,o,s.scrollTop),p=Dw(h,s.clientHeight,s.scrollTop,zw);p!==null&&s.scrollTo({top:p,behavior:"smooth"})}function o0(n,l){return n.querySelector(`[${gc}="${Fl(l)}"]`)}function Bn(n){const l=JSON.stringify(n);return _.useMemo(()=>n,[l])}function hT(n){var Co,xa,zt;const{host:l,catalog:s,view:o,onViewChange:u,sessions:d}=n,h=_.useRef(null),p=_.useRef([]),[y,g]=_.useState({}),[x,v]=_.useState(1),[E,M]=_.useState(0),[N,A]=_.useState(!1),[j,O]=_.useState(null),z=o.fixture,D=s.fixtures.find(ne=>ne.id===z),Y=D==null?void 0:D.doc,W=D==null?void 0:D.display,[ee,ae]=_.useState(null),U=_.useCallback(ne=>{ae(null),u(ne)},[u]);_.useEffect(()=>{RA(z)},[z]);const re=_.useMemo(()=>new URL(l.base).pathname,[l.base]),de=Bn(s.template.pages),ce=Bn(s.template.canvases),ie=Bn(s.islands.map),L=Bn(s.stylesheets),G=s.islands.hostScript,F=Bn(s.islands.importMap),w=Bn(Object.fromEntries(s.template.instances.map(ne=>[ne.instanceId,ne.sectionSchema]))),Z=Bn(Object.fromEntries(s.template.instances.map(ne=>[ne.instanceId,ne.section]))),ue=Bn(s.template.instances),te=s.template.output,P=te!=="website",k=P?s.template.formats:[],I=Bn(P?k.find(ne=>ne.id===o.format)??k[0]??null:null),$=I!==null&&I.bleed>0?I.bleed:null,T=_.useMemo(()=>I?{formatId:I.id,width:I.cssWidth,height:I.cssHeight,tokens:I.tokens}:void 0,[I]),B=ce.find(ne=>ne.id===o.canvasId)??(o.canvasId===null?ce[0]??null:null),q=ce.length>0&&B===null,V=_.useMemo(()=>B?fT(B,de):uT,[B,de]),me=_.useMemo(()=>V.map(ne=>({id:ne.id})),[V]),he={basePath:re,stylesheets:L,cssRev:String(E),islands:ie,hostScript:G,importMap:F},ke=_.useMemo(()=>qg(Fb({...he,sectionSchemaByInstance:w,...T?{pageBox:T}:{}})),[re,L,E,ie,G,F,w,T]),Ae=_.useMemo(()=>qg(Fb({...he,...T?{pageBox:T}:{}})).srcdoc(),[re,L,E,ie,G,F,T]),[Ue,nt]=_.useState(Ae);Ue!==Ae&&(nt(Ae),g({}));const Ve=_.useCallback(ne=>{const pe=p.current.find(Se=>Se.key===ne);return{doc:(pe==null?void 0:pe.doc)??null,win:(pe==null?void 0:pe.iframe.contentWindow)??null}},[]),Oe=oT({host:l,fixture:z,doc:Y,resolvedDisplay:W,sessions:d,pages:me,frameFor:Ve}),hn=Bn(ue.map(ne=>ne.instanceId).filter(ne=>!Oe.displayFor(ne).enabled)),[Eo,jo]=_.useState(null),ti=_.useRef(o.selection);ti.current=o.selection;const ni=_.useRef(Oe);ni.current=Oe;const ai=_.useRef(V);ai.current=V;const dl=_.useRef(x);dl.current=x;const On=_.useMemo(()=>V.map(ne=>({key:ne.id,srcdoc:Ae,label:ne.label,title:`Canvas preview — ${ne.label}`,...T?{pageBox:T}:{}})),[V,Ae,T]);_.useEffect(()=>{const ne=h.current;if(!ne)return;const pe=Tw(ne,On);p.current=pe;const Se=pe.map(Me=>{const Be=()=>{hw(Me.doc)&&g(Te=>({...Te,[Me.key]:!0}))};return Me.iframe.addEventListener("load",Be),()=>Me.iframe.removeEventListener("load",Be)});return()=>{for(const Me of Se)Me()}},[On]),_.useEffect(()=>{for(const ne of p.current)Rw(ne.overlay,N?$:null)},[N,$,On]),_.useEffect(()=>{const ne=h.current;if(!ne||typeof ResizeObserver>"u")return;const pe=new ResizeObserver(Se=>{var Te;const Me=(Te=Se[0])==null?void 0:Te.contentRect;if(!(Me!=null&&Me.width))return;const Be=ew(Me.width);v(nw(Be,{availableWidthPx:Me.width,availableHeightPx:Me.height},T?{width:T.width,height:T.height}:void 0))});return pe.observe(ne),()=>pe.disconnect()},[T]),_.useEffect(()=>{var ne;(ne=h.current)==null||ne.style.setProperty("--we-scale",String(x))},[x]),_.useEffect(()=>{var pe;if(T)return;const ne=[];for(const Se of p.current){if(!y[Se.key])continue;const Me=(pe=Se.doc)==null?void 0:pe.getElementById("we-page");if(!Me)continue;const Be=()=>Se.setPageHeight(Me.getBoundingClientRect().height);if(Be(),typeof ResizeObserver>"u")continue;const Te=new ResizeObserver(Be);Te.observe(Me),ne.push(()=>Te.disconnect())}return()=>{for(const Se of ne)Se()}},[y,On,T]),_.useEffect(()=>{const ne=Eo;if(!ne)return;const pe=()=>{document.documentElement.style.setProperty("--we-panel-w",`${ne.offsetWidth}px`)};pe();const Se=typeof ResizeObserver<"u"?new ResizeObserver(pe):null;return Se==null||Se.observe(ne),()=>{Se==null||Se.disconnect(),document.documentElement.style.removeProperty("--we-panel-w")}},[Eo]),_.useEffect(()=>{for(const ne of V)for(const pe of ne.instanceIds)Oe.ensureLoaded(ne.id,pe)},[V,Oe.ensureLoaded,z,Y]);const rt=_.useMemo(()=>{const ne={};for(const pe of V){const Se=Oe.payloads[pe.id]??{};ne[pe.id]=pe.instanceIds.filter(Me=>Se[Me]??Oe.errorOn(pe.id,Me)).map(Me=>{var Te,pt;const Be=Oe.errorOn(pe.id,Me);return{instance_id:Me,section_version_id:z,section_key:Z[Me]??Me,section_display_name:((Te=ue.find(mt=>mt.instanceId===Me))==null?void 0:Te.label)??null,html:((pt=Se[Me])==null?void 0:pt.html)??null,render_error:Be?{code:"render_failed",message:Be}:null}})}return ne},[V,Oe.payloads,Oe.errorOn,Z,ue,z]);_.useEffect(()=>{let ne=!1;for(const pe of p.current){if(!y[pe.key])continue;const Se=pe.doc,Me=pe.iframe.contentWindow,Be=Se==null?void 0:Se.getElementById("we-page");if(!Be)continue;const Te=fx(Me),pt=ZN(Be,rt[pe.key]??[],(mt,ct)=>ke.buildSectionWrapper(mt,ct),mt=>Te==null?void 0:Te.unmountRoot(mt));pt.length>0&&!Te&&!ne&&Object.keys(ie).length>0&&(ne=!0,console.warn("playground: no island host on a canvas frame, so nothing will hydrate and sections stay static. Expected window.__trCanvasIslands from the canvas island host script."));for(const mt of pt)Te==null||Te.hydrateRoot(mt).catch(ct=>{console.error("playground: canvas hydration pass failed:",ct)})}},[y,On,rt,ke,ie]);const Mo=_.useRef(()=>{});Mo.current=ne=>{Oe.setEnabled(ne,!0),U({...o,selection:{kind:"section",instanceId:ne}})},_.useEffect(()=>{var Se;const ne=new Set(hn),pe=[];for(const Me of p.current){if(!y[Me.key])continue;const Be=Me.doc;if(!Be)continue;const Te=rt[Me.key]??[];for(const Lt of Te)(Se=o0(Be,Lt.instance_id))==null||Se.setAttribute("data-hidden",ne.has(Lt.instance_id)?"true":"false");const pt=Te.filter(Lt=>ne.has(Lt.instance_id)).map(Lt=>({instanceId:Lt.instance_id,label:ef(Lt)})),mt=_w(Me.tabLayer,document,pt,Lt=>Mo.current(Lt)),ct=()=>ww(mt,Lt=>o0(Be,Lt),x);ct();const Dt=Be.getElementById("we-page");if(!Dt||typeof ResizeObserver>"u")continue;const Ut=new ResizeObserver(ct);Ut.observe(Dt),pe.push(()=>Ut.disconnect())}return()=>{for(const Me of pe)Me()}},[y,On,rt,hn,x]);const ds=_.useCallback(()=>{const ne=p.current,pe=ti.current,Se=s0(pe);for(const Te of ne)Te.doc&&ke.setLiveOwner(Te.doc,Se);const Me=Ow(ne,ke,Se),Be=pe!==null&&hn.includes(pe.instanceId);for(const Te of ne){const pt=Te.overlay.querySelector(".we-chrome-label"),mt=pe&&!Be?Me.find(ct=>ct.handle.key===Te.key):void 0;if(!mt||!pe){zg(Te.overlay,[],Ud),Wd(pt);continue}if(zg(Te.overlay,mt.els,Ud,pe.kind),pe.kind==="section"){const ct=(rt[Te.key]??[]).find(Dt=>Dt.instance_id===pe.instanceId);V_(pt,mt.els[0]??null,ct?ef(ct):"")}else Wd(pt)}},[ke,rt,hn]);_.useEffect(()=>{ds();for(const ne of p.current){if(!y[ne.key])continue;const pe=ne.doc,Se=ne.iframe.contentWindow;pe&&Se&&qw(Se,pe,s0(o.selection))}},[y,On,o.selection,ds]);const li=_.useCallback((ne,pe)=>{const Se=ne.getAttribute("href")??"";if(!Se||Se==="#")return;const Me=h.current;if(Se.startsWith("#")){Xr(Se.slice(1),pe,Me,dl.current);return}const Be=VN(Se,re,de,ce);if(!Be){window.open(Se,"_blank","noopener,noreferrer");return}if(B!==null&&Be.canvasId===B.id){const Te=p.current.find(pt=>pt.key===Be.pageId);if(!Te)return;Be.anchor?Xr(Be.anchor,Te,Me,dl.current):Te!==pe&&Xr("we-page",Te,Me,dl.current);return}U({...o,canvasId:Be.canvasId,selection:null}),Be.anchor&&O({pageId:Be.pageId,anchor:Be.anchor})},[o,U,re,de,ce,B]);_.useEffect(()=>{var pe;if(!j||!y[j.pageId])return;const ne=p.current.find(Se=>Se.key===j.pageId);(pe=ne==null?void 0:ne.doc)!=null&&pe.getElementById(j.anchor)&&(Xr(j.anchor,ne,h.current,dl.current),O(null))},[j,y,rt]),_.useEffect(()=>{const ne=[];for(const pe of p.current){if(!y[pe.key])continue;const Se=pe.doc;if(!Se)continue;const Me=rt[pe.key]??[],Be=pe.overlay.querySelector(".we-chrome-ring--hover"),Te=Dt=>{var _a;const Ut=Dt.target,Lt=ke.resolveTarget(Ut,Me);Zr(Be);const jn=Lt?dT(Lt.selection):null,pl=((_a=Ut.closest)==null?void 0:_a.call(Ut,"a"))??null;if(pl){if(Dt.preventDefault(),(jn==null?void 0:jn.kind)==="slot"){const wa=o.selection,Ao=(wa==null?void 0:wa.kind)==="slot"&&wa.instanceId===jn.instanceId&&wa.slotId===jn.slotId&&wa.itemIndex===jn.itemIndex;U({...o,selection:jn}),Ao&&li(pl,pe);return}li(pl,pe);return}U({...o,selection:jn})},pt=Dt=>{const Ut=ke.resolveTarget(Dt.target,Me);Ut?k0(Be,Ut.element,Ud):Zr(Be)},mt=()=>Zr(Be),ct=Dt=>{Dt.key==="Escape"&&U({...o,selection:null})};Se.body.addEventListener("click",Te),Se.body.addEventListener("mouseover",pt),Se.body.addEventListener("mouseleave",mt),Se.body.addEventListener("keydown",ct),ne.push(()=>{Se.body.removeEventListener("click",Te),Se.body.removeEventListener("mouseover",pt),Se.body.removeEventListener("mouseleave",mt),Se.body.removeEventListener("keydown",ct)})}return()=>{for(const pe of ne)pe()}},[y,On,ke,rt,o,U,li]);const fl=s.capabilities.hmr;_.useEffect(()=>{if(!fl)return;const ne=()=>{const pe=new Set;for(const Se of ai.current)for(const Me of Se.instanceIds)pe.has(Me)||(pe.add(Me),ni.current.reload(Me))};return l.subscribe({source:ne,stylesheet:()=>M(pe=>pe+1)})},[l,fl]);const ii=o.selection,it=(ii==null?void 0:ii.instanceId)??null,hl=V.find(ne=>it!==null&&ne.instanceIds.includes(it))??V[0]??null;return _.useEffect(()=>{it&&hl&&Oe.ensureLoaded(hl.id,it)},[it,hl==null?void 0:hl.id,Oe.ensureLoaded]),q?f.jsxs("div",{className:"boot-error",children:['The template declares no canvas "',o.canvasId,'".',`
1100
- `,"Declared canvases: ",ce.map(ne=>ne.id).join(", ")]}):f.jsxs("div",{className:"canvas-mirror",children:[f.jsx("style",{children:Ew}),ce.length>1?f.jsx("div",{className:"canvas-bar",children:f.jsx("nav",{className:"canvas-bar__card","aria-label":"Canvases",children:ce.map(ne=>f.jsx("button",{type:"button",className:ne.id===(B==null?void 0:B.id)?"canvas-bar__tab is-current":"canvas-bar__tab","aria-current":ne.id===(B==null?void 0:B.id)?"page":void 0,onClick:()=>U({...o,canvasId:ne.id,selection:null}),children:ne.label},ne.id))})}):null,f.jsx("div",{className:"we-canvas-stage canvas-mirror__stage",ref:h,onClick:ne=>{var Se;const pe=ne.target;(pe===h.current||(Se=pe.classList)!=null&&Se.contains(tc))&&U({...o,selection:null})}}),f.jsxs("div",{className:"canvas-mirror__sidebar",ref:jo,children:[f.jsxs("div",{className:"sidebar-template",children:[f.jsxs("label",{className:"sidebar-template__field",children:["Fixture",f.jsx("select",{"data-testid":"fixture-picker",value:z,onChange:ne=>U({...o,fixture:ne.target.value,selection:null}),children:s.fixtures.map(ne=>f.jsx("option",{value:ne.id,children:UA(ne)},ne.id))})]}),P&&I&&k.length>1?f.jsxs("label",{className:"sidebar-template__field",children:["Format",f.jsx("select",{"data-testid":"format-switcher",value:I.id,onChange:ne=>u({...o,format:ne.target.value}),children:k.map(ne=>f.jsx("option",{value:ne.id,children:`${ne.id} — ${ne.pixelWidth}×${ne.pixelHeight}px${ne.physical?` (${ne.physical})`:""}`},ne.id))})]}):null,$!==null?f.jsxs("label",{className:"sidebar-template__toggle",children:[f.jsx("input",{type:"checkbox","data-testid":"guides-toggle",checked:N,onChange:ne=>A(ne.target.checked)}),"Trim & bleed guides"]}):null]}),it?f.jsx(QN,{instanceId:it,label:((Co=ue.find(ne=>ne.instanceId===it))==null?void 0:Co.label)??it,display:((xa=ue.find(ne=>ne.instanceId===it))==null?void 0:xa.display)??cT,displayState:Oe.displayFor(it),settingsOpen:ee===it,onSetEnabled:ne=>Oe.setEnabled(it,ne),onSetVariant:ne=>Oe.setVariant(it,ne),onOpenSettings:()=>ae(it),onCloseSettings:()=>ae(null),fixture:z,sectionSchema:w[it]??rT,override:Oe.overrideFor(it),payload:Oe.payloadFor(it),baseline:Oe.baselineFor(it),renderError:Oe.errorFor(it),selection:ii,onSelect:ne=>U({...o,selection:ne}),onApplySlot:(ne,pe)=>Oe.applySlot(it,ne,pe)}):f.jsx(CA,{}),s.capabilities.capture||te==="website"?f.jsx(XN,{host:l,templateName:s.template.name,fixture:z,output:te,format:(I==null?void 0:I.id)??null,canvas:(B==null?void 0:B.id)??null,pagePath:((zt=V[0])==null?void 0:zt.path)??null}):null]})]})}function pT(n){const[l,s]=_.useState({}),[o,u]=_.useState({}),[d,h]=_.useState(n);if(n!==null&&n!==d){const g=d===null?[]:iT(d,n);h(n),g.length>0&&(s(x=>l0(x,g)),u(x=>l0(x,g)))}const p=_.useCallback(g=>s(g),[]),y=_.useCallback((g,x,v)=>{u(E=>({...E,[g]:{...E[g],[x]:v}}))},[]);return _.useMemo(()=>({edits:l,baselines:o,setEdits:p,setBaseline:y}),[l,o,p,y])}function r0(n){const l=B_(window.location.pathname,n.base);return l===null?null:H_(l,window.location.search)}function mT({host:n}){const[l,s]=_.useState(null),[o,u]=_.useState(null),[d,h]=_.useState(0),[p,y]=_.useState(()=>r0(n)),g=_.useMemo(()=>l===null||l.error!==void 0?null:Object.fromEntries(l.fixtures.map(N=>[N.id,N.doc])),[l]),x=pT(g);_.useEffect(()=>{let N=!0;return n.catalog().then(A=>{N&&(s(A),u(null))},A=>{N&&u(A instanceof Error?A.message:String(A))}),()=>{N=!1}},[n,d]);const v=l==null?void 0:l.template.name;_.useEffect(()=>{v&&(document.title=`${v} - Playground`)},[v]);const E=(l==null?void 0:l.capabilities.hmr)===!0;_.useEffect(()=>{if(!E)return;const N=()=>h(A=>A+1);return n.subscribe({source:N,fixtures:N})},[n,E]),_.useEffect(()=>{const N=()=>y(r0(n));return window.addEventListener("popstate",N),()=>window.removeEventListener("popstate",N)},[n]),_.useEffect(()=>{if(p!==null||l===null)return;const N=q_(l);N!==null&&(window.history.replaceState({},"",new URL(Tg(N),n.base).href),y(N))},[p,l,n]);const M=_.useCallback(N=>{window.history.replaceState({},"",new URL(Tg(N),n.base).href),y(N)},[n]);return o?f.jsxs("div",{className:"boot-error",children:["The playground could not load its catalog — ",o,`
1101
- `,"Is the server still starting? Try refreshing."]}):l?l.error!==void 0?f.jsx("div",{className:"boot-error","data-testid":"catalog-error",children:l.error}):l.fixtures.length===0?f.jsx("div",{className:"empty","data-testid":"no-fixtures",children:"No fixtures to render under. Export a defineFixture() value from a module under fixtures/."}):p?l.fixtures.some(N=>N.id===p.fixture)?f.jsx(hT,{host:n,catalog:l,view:p,onViewChange:M,sessions:x}):f.jsxs("div",{className:"boot-error","data-testid":"unknown-fixture",children:['There is no fixture "',p.fixture,'" (have: ',l.fixtures.map(N=>N.id).join(", "),")."]}):f.jsx("div",{className:"empty",children:"loading canvas…"}):f.jsx("div",{className:"empty",children:"loading…"})}const hx=document.getElementById("root");if(!hx)throw new Error("playground: #root missing from index.html");const px=NA(document.baseURI);TA(px);D_.createRoot(hx).render(f.jsx(_.StrictMode,{children:f.jsx(mT,{host:px})}));