openplanr 2.2640.8 → 2.2640.9

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 (186) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/dashboard/.vite/manifest.json +1 -1
  3. package/dist/dashboard/assets/{index-COZ36pFn.js → index-D7R6tnlX.js} +2 -2
  4. package/dist/dashboard/assets/{index-COZ36pFn.js.map → index-D7R6tnlX.js.map} +1 -1
  5. package/dist/dashboard/dashboard-manifest.json +8 -8
  6. package/dist/dashboard/index.html +1 -1
  7. package/lib/host-packages/adapter-registry.json +5 -5
  8. package/lib/host-packages/capability-map.json +1 -1
  9. package/lib/host-packages/claude/.claude-plugin/marketplace.json +2 -2
  10. package/lib/host-packages/claude/openplanr/.claude-plugin/plugin.json +1 -1
  11. package/lib/host-packages/claude/openplanr/.openplanr-content.json +165 -33
  12. package/lib/host-packages/claude/openplanr/README.md +22 -1
  13. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-artifact-shell.mjs +3 -11
  14. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-chunked-workspace-client.mjs +555 -0
  15. package/lib/host-packages/claude/openplanr/runtime/design/scripts/{design-pako-esm.mjs → design-compression.mjs} +2 -1521
  16. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-document.mjs +133 -12
  17. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-encrypted-workspace-client.mjs +647 -0
  18. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-entities.mjs +17 -67
  19. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-handoff.mjs +14 -16
  20. package/lib/host-packages/claude/openplanr/runtime/design/scripts/{design-planr-home.mjs → design-loopback-server.mjs} +15 -36
  21. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-owner-custody.mjs +121 -0
  22. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-resource-pack.mjs +698 -0
  23. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-review.mjs +798 -796
  24. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-runtime-home.mjs +39 -0
  25. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-runtime-support-5cb7531bede8.mjs +24 -0
  26. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-share.mjs +138 -765
  27. package/lib/host-packages/claude/openplanr/runtime/design/scripts/{design-escape.mjs → design-shared-artifact-support-dependencies-design-support-protocol-contracts-3d9b1a86.mjs} +158 -156
  28. package/lib/host-packages/{openai/openplanr/runtime/design/scripts/design-artifact-sources.mjs → claude/openplanr/runtime/design/scripts/design-shared-artifact-support-protocol-contracts-ea2cd15e.mjs} +1 -1
  29. package/lib/host-packages/{openai/openplanr/runtime/design/scripts/design-bounded-json-data.mjs → claude/openplanr/runtime/design/scripts/design-shared-protocol-contracts-31a760fc.mjs} +241 -454
  30. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-shared-protocol-contracts-75a938cc.mjs +222 -0
  31. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-upload-spool.mjs +198 -0
  32. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design.mjs +12 -5
  33. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/01-module-runtime.js +18 -0
  34. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/02-artifact-review-ui.js +809 -0
  35. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/03-protocol-contracts.js +5193 -0
  36. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/04-compression.js +4175 -0
  37. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/05-artifact-sharing.js +65 -0
  38. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/06-artifact-review-ui.js +1755 -0
  39. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/07-artifact-sharing.js +62 -0
  40. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/08-artifact-review-ui.js +2600 -0
  41. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources.json +123 -0
  42. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/package.json +3 -3
  43. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/01-module-runtime.js +34 -0
  44. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/02-react.js +992 -0
  45. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/03-react-dom-client-fiber-foundations.js +2513 -0
  46. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/04-react-dom-client-reconciliation-hooks.js +1919 -0
  47. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/05-react-dom-client-render-phases.js +1759 -0
  48. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/06-react-dom-client-commit-effects.js +1551 -0
  49. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/07-react-dom-client-work-loop-scheduling.js +1121 -0
  50. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/08-react-dom-client-dom-events-properties-hydration.js +2183 -0
  51. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/09-react-dom-client-public-roots.js +705 -0
  52. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/10-react.js +27 -0
  53. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/11-artifact-review-ui.js +13 -0
  54. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +3561 -0
  55. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/13-studio-shell.js +184 -0
  56. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/14-interface-primitives.js +5045 -0
  57. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/15-interface-primitives.js +1698 -0
  58. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +455 -0
  59. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/17-design-studio.js +1844 -0
  60. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +257 -0
  61. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +1 -1
  62. package/lib/host-packages/claude/openplanr/runtime/plan/scripts/design-protocol-contracts.mjs +4966 -0
  63. package/lib/host-packages/claude/openplanr/runtime/plan/scripts/design.mjs +240 -5192
  64. package/lib/host-packages/claude/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +1 -1
  65. package/lib/host-packages/claude/openplanr/skills/delegate/scripts/backend-diagnostics.mjs +6 -2
  66. package/lib/host-packages/cursor/openplanr/.openplanr-content.json +164 -32
  67. package/lib/host-packages/cursor/openplanr/manifest.json +1 -1
  68. package/lib/host-packages/cursor/openplanr/rules/planr-delegate/scripts/backend-diagnostics.mjs +6 -2
  69. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-artifact-shell.mjs +3 -11
  70. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-chunked-workspace-client.mjs +555 -0
  71. package/lib/host-packages/{openai/openplanr/runtime/design/scripts/design-pako-esm.mjs → cursor/openplanr/runtime/design/scripts/design-compression.mjs} +2 -1521
  72. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-document.mjs +133 -12
  73. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-encrypted-workspace-client.mjs +647 -0
  74. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-entities.mjs +17 -67
  75. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-handoff.mjs +14 -16
  76. package/lib/host-packages/{openai/openplanr/runtime/design/scripts/design-planr-home.mjs → cursor/openplanr/runtime/design/scripts/design-loopback-server.mjs} +15 -36
  77. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-owner-custody.mjs +121 -0
  78. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-resource-pack.mjs +698 -0
  79. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-review.mjs +798 -796
  80. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-runtime-home.mjs +39 -0
  81. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-runtime-support-5cb7531bede8.mjs +24 -0
  82. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-share.mjs +138 -765
  83. package/lib/host-packages/{openai/openplanr/runtime/design/scripts/design-escape.mjs → cursor/openplanr/runtime/design/scripts/design-shared-artifact-support-dependencies-design-support-protocol-contracts-3d9b1a86.mjs} +158 -156
  84. package/lib/host-packages/{claude/openplanr/runtime/design/scripts/design-artifact-sources.mjs → cursor/openplanr/runtime/design/scripts/design-shared-artifact-support-protocol-contracts-ea2cd15e.mjs} +1 -1
  85. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/{design-bounded-json-data.mjs → design-shared-protocol-contracts-31a760fc.mjs} +241 -454
  86. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-shared-protocol-contracts-75a938cc.mjs +222 -0
  87. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-upload-spool.mjs +198 -0
  88. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design.mjs +12 -5
  89. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/01-module-runtime.js +18 -0
  90. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/02-artifact-review-ui.js +809 -0
  91. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/03-protocol-contracts.js +5193 -0
  92. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/04-compression.js +4175 -0
  93. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/05-artifact-sharing.js +65 -0
  94. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/06-artifact-review-ui.js +1755 -0
  95. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/07-artifact-sharing.js +62 -0
  96. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/08-artifact-review-ui.js +2600 -0
  97. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources.json +123 -0
  98. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/package.json +3 -3
  99. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/01-module-runtime.js +34 -0
  100. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/02-react.js +992 -0
  101. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/03-react-dom-client-fiber-foundations.js +2513 -0
  102. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/04-react-dom-client-reconciliation-hooks.js +1919 -0
  103. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/05-react-dom-client-render-phases.js +1759 -0
  104. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/06-react-dom-client-commit-effects.js +1551 -0
  105. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/07-react-dom-client-work-loop-scheduling.js +1121 -0
  106. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/08-react-dom-client-dom-events-properties-hydration.js +2183 -0
  107. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/09-react-dom-client-public-roots.js +705 -0
  108. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/10-react.js +27 -0
  109. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/11-artifact-review-ui.js +13 -0
  110. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +3561 -0
  111. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/13-studio-shell.js +184 -0
  112. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/14-interface-primitives.js +5045 -0
  113. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/15-interface-primitives.js +1698 -0
  114. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +455 -0
  115. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/17-design-studio.js +1844 -0
  116. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +257 -0
  117. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +1 -1
  118. package/lib/host-packages/cursor/openplanr/runtime/plan/scripts/design-protocol-contracts.mjs +4966 -0
  119. package/lib/host-packages/cursor/openplanr/runtime/plan/scripts/design.mjs +240 -5192
  120. package/lib/host-packages/cursor/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +1 -1
  121. package/lib/host-packages/openai/.claude-plugin/marketplace.json +2 -2
  122. package/lib/host-packages/openai/openplanr/.codex-plugin/plugin.json +1 -1
  123. package/lib/host-packages/openai/openplanr/.openplanr-content.json +164 -32
  124. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-artifact-shell.mjs +3 -11
  125. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-chunked-workspace-client.mjs +555 -0
  126. package/lib/host-packages/{cursor/openplanr/runtime/design/scripts/design-pako-esm.mjs → openai/openplanr/runtime/design/scripts/design-compression.mjs} +2 -1521
  127. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-document.mjs +133 -12
  128. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-encrypted-workspace-client.mjs +647 -0
  129. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-entities.mjs +17 -67
  130. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-handoff.mjs +14 -16
  131. package/lib/host-packages/{cursor/openplanr/runtime/design/scripts/design-planr-home.mjs → openai/openplanr/runtime/design/scripts/design-loopback-server.mjs} +15 -36
  132. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-owner-custody.mjs +121 -0
  133. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-resource-pack.mjs +698 -0
  134. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-review.mjs +798 -796
  135. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-runtime-home.mjs +39 -0
  136. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-runtime-support-5cb7531bede8.mjs +24 -0
  137. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-share.mjs +138 -765
  138. package/lib/host-packages/{cursor/openplanr/runtime/design/scripts/design-escape.mjs → openai/openplanr/runtime/design/scripts/design-shared-artifact-support-dependencies-design-support-protocol-contracts-3d9b1a86.mjs} +158 -156
  139. package/lib/host-packages/{cursor/openplanr/runtime/design/scripts/design-artifact-sources.mjs → openai/openplanr/runtime/design/scripts/design-shared-artifact-support-protocol-contracts-ea2cd15e.mjs} +1 -1
  140. package/lib/host-packages/{claude/openplanr/runtime/design/scripts/design-bounded-json-data.mjs → openai/openplanr/runtime/design/scripts/design-shared-protocol-contracts-31a760fc.mjs} +241 -454
  141. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-shared-protocol-contracts-75a938cc.mjs +222 -0
  142. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-upload-spool.mjs +198 -0
  143. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design.mjs +12 -5
  144. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/01-module-runtime.js +18 -0
  145. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/02-artifact-review-ui.js +809 -0
  146. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/03-protocol-contracts.js +5193 -0
  147. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/04-compression.js +4175 -0
  148. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/05-artifact-sharing.js +65 -0
  149. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/06-artifact-review-ui.js +1755 -0
  150. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/07-artifact-sharing.js +62 -0
  151. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources/08-artifact-review-ui.js +2600 -0
  152. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js.sources.json +123 -0
  153. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/package.json +3 -3
  154. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/01-module-runtime.js +34 -0
  155. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/02-react.js +992 -0
  156. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/03-react-dom-client-fiber-foundations.js +2513 -0
  157. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/04-react-dom-client-reconciliation-hooks.js +1919 -0
  158. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/05-react-dom-client-render-phases.js +1759 -0
  159. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/06-react-dom-client-commit-effects.js +1551 -0
  160. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/07-react-dom-client-work-loop-scheduling.js +1121 -0
  161. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/08-react-dom-client-dom-events-properties-hydration.js +2183 -0
  162. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/09-react-dom-client-public-roots.js +705 -0
  163. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/10-react.js +27 -0
  164. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/11-artifact-review-ui.js +13 -0
  165. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/12-design-review-experience.js +3561 -0
  166. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/13-studio-shell.js +184 -0
  167. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/14-interface-primitives.js +5045 -0
  168. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/15-interface-primitives.js +1698 -0
  169. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/16-studio-shell.js +455 -0
  170. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources/17-design-studio.js +1844 -0
  171. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js.sources.json +257 -0
  172. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/protocol/package.json +1 -1
  173. package/lib/host-packages/openai/openplanr/runtime/plan/scripts/design-protocol-contracts.mjs +4966 -0
  174. package/lib/host-packages/openai/openplanr/runtime/plan/scripts/design.mjs +240 -5192
  175. package/lib/host-packages/openai/openplanr/runtime/plan/scripts/runtime/packages/protocol/package.json +1 -1
  176. package/lib/host-packages/openai/openplanr/skills/delegate/scripts/backend-diagnostics.mjs +6 -2
  177. package/package.json +2 -2
  178. package/lib/host-packages/claude/openplanr/runtime/design/scripts/design-generated-b0798298053515fd.mjs +0 -18
  179. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +0 -5
  180. package/lib/host-packages/claude/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js +0 -25597
  181. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/design-generated-b0798298053515fd.mjs +0 -18
  182. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +0 -5
  183. package/lib/host-packages/cursor/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js +0 -25597
  184. package/lib/host-packages/openai/openplanr/runtime/design/scripts/design-generated-b0798298053515fd.mjs +0 -18
  185. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +0 -5
  186. package/lib/host-packages/openai/openplanr/runtime/design/scripts/runtime/packages/design/templates/studio/studio.js +0 -25597
@@ -0,0 +1,1121 @@
1
+
2
+ var executionContext = 0;
3
+ var workInProgressRoot = null;
4
+ var workInProgress = null;
5
+ var workInProgressRootRenderLanes = 0;
6
+ var workInProgressSuspendedReason = 0;
7
+ var workInProgressThrownValue = null;
8
+ var workInProgressRootDidSkipSuspendedSiblings = false;
9
+ var workInProgressRootIsPrerendering = false;
10
+ var workInProgressRootDidAttachPingListener = false;
11
+ var entangledRenderLanes = 0;
12
+ var workInProgressRootExitStatus = 0;
13
+ var workInProgressRootSkippedLanes = 0;
14
+ var workInProgressRootInterleavedUpdatedLanes = 0;
15
+ var workInProgressRootPingedLanes = 0;
16
+ var workInProgressDeferredLane = 0;
17
+ var workInProgressSuspendedRetryLanes = 0;
18
+ var workInProgressRootConcurrentErrors = null;
19
+ var workInProgressRootRecoverableErrors = null;
20
+ var workInProgressRootDidIncludeRecursiveRenderUpdate = false;
21
+ var globalMostRecentFallbackTime = 0;
22
+ var globalMostRecentTransitionTime = 0;
23
+ var workInProgressRootRenderTargetTime = Infinity;
24
+ var workInProgressTransitions = null;
25
+ var legacyErrorBoundariesThatAlreadyFailed = null;
26
+ var pendingEffectsStatus = 0;
27
+ var pendingEffectsRoot = null;
28
+ var pendingFinishedWork = null;
29
+ var pendingEffectsLanes = 0;
30
+ var pendingEffectsRemainingLanes = 0;
31
+ var pendingPassiveTransitions = null;
32
+ var pendingRecoverableErrors = null;
33
+ var nestedUpdateCount = 0;
34
+ var rootWithNestedUpdates = null;
35
+ function requestUpdateLane() {
36
+ return 0 !== (executionContext & 2) && 0 !== workInProgressRootRenderLanes ? workInProgressRootRenderLanes & -workInProgressRootRenderLanes : null !== ReactSharedInternals.T ? requestTransitionLane() : resolveUpdatePriority();
37
+ }
38
+ function requestDeferredLane() {
39
+ if (0 === workInProgressDeferredLane)
40
+ if (0 === (workInProgressRootRenderLanes & 536870912) || isHydrating) {
41
+ var lane = nextTransitionDeferredLane;
42
+ nextTransitionDeferredLane <<= 1;
43
+ 0 === (nextTransitionDeferredLane & 3932160) && (nextTransitionDeferredLane = 262144);
44
+ workInProgressDeferredLane = lane;
45
+ } else workInProgressDeferredLane = 536870912;
46
+ lane = suspenseHandlerStackCursor.current;
47
+ null !== lane && (lane.flags |= 32);
48
+ return workInProgressDeferredLane;
49
+ }
50
+ function scheduleUpdateOnFiber(root2, fiber, lane) {
51
+ if (root2 === workInProgressRoot && (2 === workInProgressSuspendedReason || 9 === workInProgressSuspendedReason) || null !== root2.cancelPendingCommit)
52
+ prepareFreshStack(root2, 0), markRootSuspended(
53
+ root2,
54
+ workInProgressRootRenderLanes,
55
+ workInProgressDeferredLane,
56
+ false
57
+ );
58
+ markRootUpdated$1(root2, lane);
59
+ if (0 === (executionContext & 2) || root2 !== workInProgressRoot)
60
+ root2 === workInProgressRoot && (0 === (executionContext & 2) && (workInProgressRootInterleavedUpdatedLanes |= lane), 4 === workInProgressRootExitStatus && markRootSuspended(
61
+ root2,
62
+ workInProgressRootRenderLanes,
63
+ workInProgressDeferredLane,
64
+ false
65
+ )), ensureRootIsScheduled(root2);
66
+ }
67
+ function performWorkOnRoot(root$jscomp$0, lanes, forceSync) {
68
+ if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
69
+ var shouldTimeSlice = !forceSync && 0 === (lanes & 127) && 0 === (lanes & root$jscomp$0.expiredLanes) || checkIfRootIsPrerendering(root$jscomp$0, lanes), exitStatus = shouldTimeSlice ? renderRootConcurrent(root$jscomp$0, lanes) : renderRootSync(root$jscomp$0, lanes, true), renderWasConcurrent = shouldTimeSlice;
70
+ do {
71
+ if (0 === exitStatus) {
72
+ workInProgressRootIsPrerendering && !shouldTimeSlice && markRootSuspended(root$jscomp$0, lanes, 0, false);
73
+ break;
74
+ } else {
75
+ forceSync = root$jscomp$0.current.alternate;
76
+ if (renderWasConcurrent && !isRenderConsistentWithExternalStores(forceSync)) {
77
+ exitStatus = renderRootSync(root$jscomp$0, lanes, false);
78
+ renderWasConcurrent = false;
79
+ continue;
80
+ }
81
+ if (2 === exitStatus) {
82
+ renderWasConcurrent = lanes;
83
+ if (root$jscomp$0.errorRecoveryDisabledLanes & renderWasConcurrent)
84
+ var JSCompiler_inline_result = 0;
85
+ else
86
+ JSCompiler_inline_result = root$jscomp$0.pendingLanes & -536870913, JSCompiler_inline_result = 0 !== JSCompiler_inline_result ? JSCompiler_inline_result : JSCompiler_inline_result & 536870912 ? 536870912 : 0;
87
+ if (0 !== JSCompiler_inline_result) {
88
+ lanes = JSCompiler_inline_result;
89
+ a: {
90
+ var root2 = root$jscomp$0;
91
+ exitStatus = workInProgressRootConcurrentErrors;
92
+ var wasRootDehydrated = root2.current.memoizedState.isDehydrated;
93
+ wasRootDehydrated && (prepareFreshStack(root2, JSCompiler_inline_result).flags |= 256);
94
+ JSCompiler_inline_result = renderRootSync(
95
+ root2,
96
+ JSCompiler_inline_result,
97
+ false
98
+ );
99
+ if (2 !== JSCompiler_inline_result) {
100
+ if (workInProgressRootDidAttachPingListener && !wasRootDehydrated) {
101
+ root2.errorRecoveryDisabledLanes |= renderWasConcurrent;
102
+ workInProgressRootInterleavedUpdatedLanes |= renderWasConcurrent;
103
+ exitStatus = 4;
104
+ break a;
105
+ }
106
+ renderWasConcurrent = workInProgressRootRecoverableErrors;
107
+ workInProgressRootRecoverableErrors = exitStatus;
108
+ null !== renderWasConcurrent && (null === workInProgressRootRecoverableErrors ? workInProgressRootRecoverableErrors = renderWasConcurrent : workInProgressRootRecoverableErrors.push.apply(
109
+ workInProgressRootRecoverableErrors,
110
+ renderWasConcurrent
111
+ ));
112
+ }
113
+ exitStatus = JSCompiler_inline_result;
114
+ }
115
+ renderWasConcurrent = false;
116
+ if (2 !== exitStatus) continue;
117
+ }
118
+ }
119
+ if (1 === exitStatus) {
120
+ prepareFreshStack(root$jscomp$0, 0);
121
+ markRootSuspended(root$jscomp$0, lanes, 0, true);
122
+ break;
123
+ }
124
+ a: {
125
+ shouldTimeSlice = root$jscomp$0;
126
+ renderWasConcurrent = exitStatus;
127
+ switch (renderWasConcurrent) {
128
+ case 0:
129
+ case 1:
130
+ throw Error(formatProdErrorMessage(345));
131
+ case 4:
132
+ if ((lanes & 4194048) !== lanes) break;
133
+ case 6:
134
+ markRootSuspended(
135
+ shouldTimeSlice,
136
+ lanes,
137
+ workInProgressDeferredLane,
138
+ !workInProgressRootDidSkipSuspendedSiblings
139
+ );
140
+ break a;
141
+ case 2:
142
+ workInProgressRootRecoverableErrors = null;
143
+ break;
144
+ case 3:
145
+ case 5:
146
+ break;
147
+ default:
148
+ throw Error(formatProdErrorMessage(329));
149
+ }
150
+ if ((lanes & 62914560) === lanes && (exitStatus = globalMostRecentFallbackTime + 300 - now(), 10 < exitStatus)) {
151
+ markRootSuspended(
152
+ shouldTimeSlice,
153
+ lanes,
154
+ workInProgressDeferredLane,
155
+ !workInProgressRootDidSkipSuspendedSiblings
156
+ );
157
+ if (0 !== getNextLanes(shouldTimeSlice, 0, true)) break a;
158
+ pendingEffectsLanes = lanes;
159
+ shouldTimeSlice.timeoutHandle = scheduleTimeout(
160
+ commitRootWhenReady.bind(
161
+ null,
162
+ shouldTimeSlice,
163
+ forceSync,
164
+ workInProgressRootRecoverableErrors,
165
+ workInProgressTransitions,
166
+ workInProgressRootDidIncludeRecursiveRenderUpdate,
167
+ lanes,
168
+ workInProgressDeferredLane,
169
+ workInProgressRootInterleavedUpdatedLanes,
170
+ workInProgressSuspendedRetryLanes,
171
+ workInProgressRootDidSkipSuspendedSiblings,
172
+ renderWasConcurrent,
173
+ "Throttled",
174
+ -0,
175
+ 0
176
+ ),
177
+ exitStatus
178
+ );
179
+ break a;
180
+ }
181
+ commitRootWhenReady(
182
+ shouldTimeSlice,
183
+ forceSync,
184
+ workInProgressRootRecoverableErrors,
185
+ workInProgressTransitions,
186
+ workInProgressRootDidIncludeRecursiveRenderUpdate,
187
+ lanes,
188
+ workInProgressDeferredLane,
189
+ workInProgressRootInterleavedUpdatedLanes,
190
+ workInProgressSuspendedRetryLanes,
191
+ workInProgressRootDidSkipSuspendedSiblings,
192
+ renderWasConcurrent,
193
+ null,
194
+ -0,
195
+ 0
196
+ );
197
+ }
198
+ }
199
+ break;
200
+ } while (1);
201
+ ensureRootIsScheduled(root$jscomp$0);
202
+ }
203
+ function commitRootWhenReady(root2, finishedWork, recoverableErrors, transitions, didIncludeRenderPhaseUpdate, lanes, spawnedLane, updatedLanes, suspendedRetryLanes, didSkipSuspendedSiblings, exitStatus, suspendedCommitReason, completedRenderStartTime, completedRenderEndTime) {
204
+ root2.timeoutHandle = -1;
205
+ suspendedCommitReason = finishedWork.subtreeFlags;
206
+ if (suspendedCommitReason & 8192 || 16785408 === (suspendedCommitReason & 16785408)) {
207
+ suspendedCommitReason = {
208
+ stylesheets: null,
209
+ count: 0,
210
+ imgCount: 0,
211
+ imgBytes: 0,
212
+ suspenseyImages: [],
213
+ waitingForImages: true,
214
+ waitingForViewTransition: false,
215
+ unsuspend: noop$1
216
+ };
217
+ accumulateSuspenseyCommitOnFiber(
218
+ finishedWork,
219
+ lanes,
220
+ suspendedCommitReason
221
+ );
222
+ var timeoutOffset = (lanes & 62914560) === lanes ? globalMostRecentFallbackTime - now() : (lanes & 4194048) === lanes ? globalMostRecentTransitionTime - now() : 0;
223
+ timeoutOffset = waitForCommitToBeReady(
224
+ suspendedCommitReason,
225
+ timeoutOffset
226
+ );
227
+ if (null !== timeoutOffset) {
228
+ pendingEffectsLanes = lanes;
229
+ root2.cancelPendingCommit = timeoutOffset(
230
+ commitRoot.bind(
231
+ null,
232
+ root2,
233
+ finishedWork,
234
+ lanes,
235
+ recoverableErrors,
236
+ transitions,
237
+ didIncludeRenderPhaseUpdate,
238
+ spawnedLane,
239
+ updatedLanes,
240
+ suspendedRetryLanes,
241
+ exitStatus,
242
+ suspendedCommitReason,
243
+ null,
244
+ completedRenderStartTime,
245
+ completedRenderEndTime
246
+ )
247
+ );
248
+ markRootSuspended(root2, lanes, spawnedLane, !didSkipSuspendedSiblings);
249
+ return;
250
+ }
251
+ }
252
+ commitRoot(
253
+ root2,
254
+ finishedWork,
255
+ lanes,
256
+ recoverableErrors,
257
+ transitions,
258
+ didIncludeRenderPhaseUpdate,
259
+ spawnedLane,
260
+ updatedLanes,
261
+ suspendedRetryLanes
262
+ );
263
+ }
264
+ function isRenderConsistentWithExternalStores(finishedWork) {
265
+ for (var node = finishedWork; ; ) {
266
+ var tag = node.tag;
267
+ if ((0 === tag || 11 === tag || 15 === tag) && node.flags & 16384 && (tag = node.updateQueue, null !== tag && (tag = tag.stores, null !== tag)))
268
+ for (var i = 0; i < tag.length; i++) {
269
+ var check = tag[i], getSnapshot = check.getSnapshot;
270
+ check = check.value;
271
+ try {
272
+ if (!objectIs(getSnapshot(), check)) return false;
273
+ } catch (error) {
274
+ return false;
275
+ }
276
+ }
277
+ tag = node.child;
278
+ if (node.subtreeFlags & 16384 && null !== tag)
279
+ tag.return = node, node = tag;
280
+ else {
281
+ if (node === finishedWork) break;
282
+ for (; null === node.sibling; ) {
283
+ if (null === node.return || node.return === finishedWork) return true;
284
+ node = node.return;
285
+ }
286
+ node.sibling.return = node.return;
287
+ node = node.sibling;
288
+ }
289
+ }
290
+ return true;
291
+ }
292
+ function markRootSuspended(root2, suspendedLanes, spawnedLane, didAttemptEntireTree) {
293
+ suspendedLanes &= ~workInProgressRootPingedLanes;
294
+ suspendedLanes &= ~workInProgressRootInterleavedUpdatedLanes;
295
+ root2.suspendedLanes |= suspendedLanes;
296
+ root2.pingedLanes &= ~suspendedLanes;
297
+ didAttemptEntireTree && (root2.warmLanes |= suspendedLanes);
298
+ didAttemptEntireTree = root2.expirationTimes;
299
+ for (var lanes = suspendedLanes; 0 < lanes; ) {
300
+ var index$6 = 31 - clz32(lanes), lane = 1 << index$6;
301
+ didAttemptEntireTree[index$6] = -1;
302
+ lanes &= ~lane;
303
+ }
304
+ 0 !== spawnedLane && markSpawnedDeferredLane(root2, spawnedLane, suspendedLanes);
305
+ }
306
+ function flushSyncWork$1() {
307
+ return 0 === (executionContext & 6) ? (flushSyncWorkAcrossRoots_impl(0, false), false) : true;
308
+ }
309
+ function resetWorkInProgressStack() {
310
+ if (null !== workInProgress) {
311
+ if (0 === workInProgressSuspendedReason)
312
+ var interruptedWork = workInProgress.return;
313
+ else
314
+ interruptedWork = workInProgress, lastContextDependency = currentlyRenderingFiber$1 = null, resetHooksOnUnwind(interruptedWork), thenableState$1 = null, thenableIndexCounter$1 = 0, interruptedWork = workInProgress;
315
+ for (; null !== interruptedWork; )
316
+ unwindInterruptedWork(interruptedWork.alternate, interruptedWork), interruptedWork = interruptedWork.return;
317
+ workInProgress = null;
318
+ }
319
+ }
320
+ function prepareFreshStack(root2, lanes) {
321
+ var timeoutHandle = root2.timeoutHandle;
322
+ -1 !== timeoutHandle && (root2.timeoutHandle = -1, cancelTimeout(timeoutHandle));
323
+ timeoutHandle = root2.cancelPendingCommit;
324
+ null !== timeoutHandle && (root2.cancelPendingCommit = null, timeoutHandle());
325
+ pendingEffectsLanes = 0;
326
+ resetWorkInProgressStack();
327
+ workInProgressRoot = root2;
328
+ workInProgress = timeoutHandle = createWorkInProgress(root2.current, null);
329
+ workInProgressRootRenderLanes = lanes;
330
+ workInProgressSuspendedReason = 0;
331
+ workInProgressThrownValue = null;
332
+ workInProgressRootDidSkipSuspendedSiblings = false;
333
+ workInProgressRootIsPrerendering = checkIfRootIsPrerendering(root2, lanes);
334
+ workInProgressRootDidAttachPingListener = false;
335
+ workInProgressSuspendedRetryLanes = workInProgressDeferredLane = workInProgressRootPingedLanes = workInProgressRootInterleavedUpdatedLanes = workInProgressRootSkippedLanes = workInProgressRootExitStatus = 0;
336
+ workInProgressRootRecoverableErrors = workInProgressRootConcurrentErrors = null;
337
+ workInProgressRootDidIncludeRecursiveRenderUpdate = false;
338
+ 0 !== (lanes & 8) && (lanes |= lanes & 32);
339
+ var allEntangledLanes = root2.entangledLanes;
340
+ if (0 !== allEntangledLanes)
341
+ for (root2 = root2.entanglements, allEntangledLanes &= lanes; 0 < allEntangledLanes; ) {
342
+ var index$4 = 31 - clz32(allEntangledLanes), lane = 1 << index$4;
343
+ lanes |= root2[index$4];
344
+ allEntangledLanes &= ~lane;
345
+ }
346
+ entangledRenderLanes = lanes;
347
+ finishQueueingConcurrentUpdates();
348
+ return timeoutHandle;
349
+ }
350
+ function handleThrow(root2, thrownValue) {
351
+ currentlyRenderingFiber = null;
352
+ ReactSharedInternals.H = ContextOnlyDispatcher;
353
+ thrownValue === SuspenseException || thrownValue === SuspenseActionException ? (thrownValue = getSuspendedThenable(), workInProgressSuspendedReason = 3) : thrownValue === SuspenseyCommitException ? (thrownValue = getSuspendedThenable(), workInProgressSuspendedReason = 4) : workInProgressSuspendedReason = thrownValue === SelectiveHydrationException ? 8 : null !== thrownValue && "object" === typeof thrownValue && "function" === typeof thrownValue.then ? 6 : 1;
354
+ workInProgressThrownValue = thrownValue;
355
+ null === workInProgress && (workInProgressRootExitStatus = 1, logUncaughtError(
356
+ root2,
357
+ createCapturedValueAtFiber(thrownValue, root2.current)
358
+ ));
359
+ }
360
+ function shouldRemainOnPreviousScreen() {
361
+ var handler = suspenseHandlerStackCursor.current;
362
+ return null === handler ? true : (workInProgressRootRenderLanes & 4194048) === workInProgressRootRenderLanes ? null === shellBoundary ? true : false : (workInProgressRootRenderLanes & 62914560) === workInProgressRootRenderLanes || 0 !== (workInProgressRootRenderLanes & 536870912) ? handler === shellBoundary : false;
363
+ }
364
+ function pushDispatcher() {
365
+ var prevDispatcher = ReactSharedInternals.H;
366
+ ReactSharedInternals.H = ContextOnlyDispatcher;
367
+ return null === prevDispatcher ? ContextOnlyDispatcher : prevDispatcher;
368
+ }
369
+ function pushAsyncDispatcher() {
370
+ var prevAsyncDispatcher = ReactSharedInternals.A;
371
+ ReactSharedInternals.A = DefaultAsyncDispatcher;
372
+ return prevAsyncDispatcher;
373
+ }
374
+ function renderDidSuspendDelayIfPossible() {
375
+ workInProgressRootExitStatus = 4;
376
+ workInProgressRootDidSkipSuspendedSiblings || (workInProgressRootRenderLanes & 4194048) !== workInProgressRootRenderLanes && null !== suspenseHandlerStackCursor.current || (workInProgressRootIsPrerendering = true);
377
+ 0 === (workInProgressRootSkippedLanes & 134217727) && 0 === (workInProgressRootInterleavedUpdatedLanes & 134217727) || null === workInProgressRoot || markRootSuspended(
378
+ workInProgressRoot,
379
+ workInProgressRootRenderLanes,
380
+ workInProgressDeferredLane,
381
+ false
382
+ );
383
+ }
384
+ function renderRootSync(root2, lanes, shouldYieldForPrerendering) {
385
+ var prevExecutionContext = executionContext;
386
+ executionContext |= 2;
387
+ var prevDispatcher = pushDispatcher(), prevAsyncDispatcher = pushAsyncDispatcher();
388
+ if (workInProgressRoot !== root2 || workInProgressRootRenderLanes !== lanes)
389
+ workInProgressTransitions = null, prepareFreshStack(root2, lanes);
390
+ lanes = false;
391
+ var exitStatus = workInProgressRootExitStatus;
392
+ a: do
393
+ try {
394
+ if (0 !== workInProgressSuspendedReason && null !== workInProgress) {
395
+ var unitOfWork = workInProgress, thrownValue = workInProgressThrownValue;
396
+ switch (workInProgressSuspendedReason) {
397
+ case 8:
398
+ resetWorkInProgressStack();
399
+ exitStatus = 6;
400
+ break a;
401
+ case 3:
402
+ case 2:
403
+ case 9:
404
+ case 6:
405
+ null === suspenseHandlerStackCursor.current && (lanes = true);
406
+ var reason = workInProgressSuspendedReason;
407
+ workInProgressSuspendedReason = 0;
408
+ workInProgressThrownValue = null;
409
+ throwAndUnwindWorkLoop(root2, unitOfWork, thrownValue, reason);
410
+ if (shouldYieldForPrerendering && workInProgressRootIsPrerendering) {
411
+ exitStatus = 0;
412
+ break a;
413
+ }
414
+ break;
415
+ default:
416
+ reason = workInProgressSuspendedReason, workInProgressSuspendedReason = 0, workInProgressThrownValue = null, throwAndUnwindWorkLoop(root2, unitOfWork, thrownValue, reason);
417
+ }
418
+ }
419
+ workLoopSync();
420
+ exitStatus = workInProgressRootExitStatus;
421
+ break;
422
+ } catch (thrownValue$165) {
423
+ handleThrow(root2, thrownValue$165);
424
+ }
425
+ while (1);
426
+ lanes && root2.shellSuspendCounter++;
427
+ lastContextDependency = currentlyRenderingFiber$1 = null;
428
+ executionContext = prevExecutionContext;
429
+ ReactSharedInternals.H = prevDispatcher;
430
+ ReactSharedInternals.A = prevAsyncDispatcher;
431
+ null === workInProgress && (workInProgressRoot = null, workInProgressRootRenderLanes = 0, finishQueueingConcurrentUpdates());
432
+ return exitStatus;
433
+ }
434
+ function workLoopSync() {
435
+ for (; null !== workInProgress; ) performUnitOfWork(workInProgress);
436
+ }
437
+ function renderRootConcurrent(root2, lanes) {
438
+ var prevExecutionContext = executionContext;
439
+ executionContext |= 2;
440
+ var prevDispatcher = pushDispatcher(), prevAsyncDispatcher = pushAsyncDispatcher();
441
+ workInProgressRoot !== root2 || workInProgressRootRenderLanes !== lanes ? (workInProgressTransitions = null, workInProgressRootRenderTargetTime = now() + 500, prepareFreshStack(root2, lanes)) : workInProgressRootIsPrerendering = checkIfRootIsPrerendering(
442
+ root2,
443
+ lanes
444
+ );
445
+ a: do
446
+ try {
447
+ if (0 !== workInProgressSuspendedReason && null !== workInProgress) {
448
+ lanes = workInProgress;
449
+ var thrownValue = workInProgressThrownValue;
450
+ b: switch (workInProgressSuspendedReason) {
451
+ case 1:
452
+ workInProgressSuspendedReason = 0;
453
+ workInProgressThrownValue = null;
454
+ throwAndUnwindWorkLoop(root2, lanes, thrownValue, 1);
455
+ break;
456
+ case 2:
457
+ case 9:
458
+ if (isThenableResolved(thrownValue)) {
459
+ workInProgressSuspendedReason = 0;
460
+ workInProgressThrownValue = null;
461
+ replaySuspendedUnitOfWork(lanes);
462
+ break;
463
+ }
464
+ lanes = function() {
465
+ 2 !== workInProgressSuspendedReason && 9 !== workInProgressSuspendedReason || workInProgressRoot !== root2 || (workInProgressSuspendedReason = 7);
466
+ ensureRootIsScheduled(root2);
467
+ };
468
+ thrownValue.then(lanes, lanes);
469
+ break a;
470
+ case 3:
471
+ workInProgressSuspendedReason = 7;
472
+ break a;
473
+ case 4:
474
+ workInProgressSuspendedReason = 5;
475
+ break a;
476
+ case 7:
477
+ isThenableResolved(thrownValue) ? (workInProgressSuspendedReason = 0, workInProgressThrownValue = null, replaySuspendedUnitOfWork(lanes)) : (workInProgressSuspendedReason = 0, workInProgressThrownValue = null, throwAndUnwindWorkLoop(root2, lanes, thrownValue, 7));
478
+ break;
479
+ case 5:
480
+ var resource = null;
481
+ switch (workInProgress.tag) {
482
+ case 26:
483
+ resource = workInProgress.memoizedState;
484
+ case 5:
485
+ case 27:
486
+ var hostFiber = workInProgress;
487
+ if (resource ? preloadResource(resource) : hostFiber.stateNode.complete) {
488
+ workInProgressSuspendedReason = 0;
489
+ workInProgressThrownValue = null;
490
+ var sibling = hostFiber.sibling;
491
+ if (null !== sibling) workInProgress = sibling;
492
+ else {
493
+ var returnFiber = hostFiber.return;
494
+ null !== returnFiber ? (workInProgress = returnFiber, completeUnitOfWork(returnFiber)) : workInProgress = null;
495
+ }
496
+ break b;
497
+ }
498
+ }
499
+ workInProgressSuspendedReason = 0;
500
+ workInProgressThrownValue = null;
501
+ throwAndUnwindWorkLoop(root2, lanes, thrownValue, 5);
502
+ break;
503
+ case 6:
504
+ workInProgressSuspendedReason = 0;
505
+ workInProgressThrownValue = null;
506
+ throwAndUnwindWorkLoop(root2, lanes, thrownValue, 6);
507
+ break;
508
+ case 8:
509
+ resetWorkInProgressStack();
510
+ workInProgressRootExitStatus = 6;
511
+ break a;
512
+ default:
513
+ throw Error(formatProdErrorMessage(462));
514
+ }
515
+ }
516
+ workLoopConcurrentByScheduler();
517
+ break;
518
+ } catch (thrownValue$167) {
519
+ handleThrow(root2, thrownValue$167);
520
+ }
521
+ while (1);
522
+ lastContextDependency = currentlyRenderingFiber$1 = null;
523
+ ReactSharedInternals.H = prevDispatcher;
524
+ ReactSharedInternals.A = prevAsyncDispatcher;
525
+ executionContext = prevExecutionContext;
526
+ if (null !== workInProgress) return 0;
527
+ workInProgressRoot = null;
528
+ workInProgressRootRenderLanes = 0;
529
+ finishQueueingConcurrentUpdates();
530
+ return workInProgressRootExitStatus;
531
+ }
532
+ function workLoopConcurrentByScheduler() {
533
+ for (; null !== workInProgress && !shouldYield(); )
534
+ performUnitOfWork(workInProgress);
535
+ }
536
+ function performUnitOfWork(unitOfWork) {
537
+ var next = beginWork(unitOfWork.alternate, unitOfWork, entangledRenderLanes);
538
+ unitOfWork.memoizedProps = unitOfWork.pendingProps;
539
+ null === next ? completeUnitOfWork(unitOfWork) : workInProgress = next;
540
+ }
541
+ function replaySuspendedUnitOfWork(unitOfWork) {
542
+ var next = unitOfWork;
543
+ var current = next.alternate;
544
+ switch (next.tag) {
545
+ case 15:
546
+ case 0:
547
+ next = replayFunctionComponent(
548
+ current,
549
+ next,
550
+ next.pendingProps,
551
+ next.type,
552
+ void 0,
553
+ workInProgressRootRenderLanes
554
+ );
555
+ break;
556
+ case 11:
557
+ next = replayFunctionComponent(
558
+ current,
559
+ next,
560
+ next.pendingProps,
561
+ next.type.render,
562
+ next.ref,
563
+ workInProgressRootRenderLanes
564
+ );
565
+ break;
566
+ case 5:
567
+ resetHooksOnUnwind(next);
568
+ default:
569
+ unwindInterruptedWork(current, next), next = workInProgress = resetWorkInProgress(next, entangledRenderLanes), next = beginWork(current, next, entangledRenderLanes);
570
+ }
571
+ unitOfWork.memoizedProps = unitOfWork.pendingProps;
572
+ null === next ? completeUnitOfWork(unitOfWork) : workInProgress = next;
573
+ }
574
+ function throwAndUnwindWorkLoop(root2, unitOfWork, thrownValue, suspendedReason) {
575
+ lastContextDependency = currentlyRenderingFiber$1 = null;
576
+ resetHooksOnUnwind(unitOfWork);
577
+ thenableState$1 = null;
578
+ thenableIndexCounter$1 = 0;
579
+ var returnFiber = unitOfWork.return;
580
+ try {
581
+ if (throwException(
582
+ root2,
583
+ returnFiber,
584
+ unitOfWork,
585
+ thrownValue,
586
+ workInProgressRootRenderLanes
587
+ )) {
588
+ workInProgressRootExitStatus = 1;
589
+ logUncaughtError(
590
+ root2,
591
+ createCapturedValueAtFiber(thrownValue, root2.current)
592
+ );
593
+ workInProgress = null;
594
+ return;
595
+ }
596
+ } catch (error) {
597
+ if (null !== returnFiber) throw workInProgress = returnFiber, error;
598
+ workInProgressRootExitStatus = 1;
599
+ logUncaughtError(
600
+ root2,
601
+ createCapturedValueAtFiber(thrownValue, root2.current)
602
+ );
603
+ workInProgress = null;
604
+ return;
605
+ }
606
+ if (unitOfWork.flags & 32768) {
607
+ if (isHydrating || 1 === suspendedReason) root2 = true;
608
+ else if (workInProgressRootIsPrerendering || 0 !== (workInProgressRootRenderLanes & 536870912))
609
+ root2 = false;
610
+ else if (workInProgressRootDidSkipSuspendedSiblings = root2 = true, 2 === suspendedReason || 9 === suspendedReason || 3 === suspendedReason || 6 === suspendedReason)
611
+ suspendedReason = suspenseHandlerStackCursor.current, null !== suspendedReason && 13 === suspendedReason.tag && (suspendedReason.flags |= 16384);
612
+ unwindUnitOfWork(unitOfWork, root2);
613
+ } else completeUnitOfWork(unitOfWork);
614
+ }
615
+ function completeUnitOfWork(unitOfWork) {
616
+ var completedWork = unitOfWork;
617
+ do {
618
+ if (0 !== (completedWork.flags & 32768)) {
619
+ unwindUnitOfWork(
620
+ completedWork,
621
+ workInProgressRootDidSkipSuspendedSiblings
622
+ );
623
+ return;
624
+ }
625
+ unitOfWork = completedWork.return;
626
+ var next = completeWork(
627
+ completedWork.alternate,
628
+ completedWork,
629
+ entangledRenderLanes
630
+ );
631
+ if (null !== next) {
632
+ workInProgress = next;
633
+ return;
634
+ }
635
+ completedWork = completedWork.sibling;
636
+ if (null !== completedWork) {
637
+ workInProgress = completedWork;
638
+ return;
639
+ }
640
+ workInProgress = completedWork = unitOfWork;
641
+ } while (null !== completedWork);
642
+ 0 === workInProgressRootExitStatus && (workInProgressRootExitStatus = 5);
643
+ }
644
+ function unwindUnitOfWork(unitOfWork, skipSiblings) {
645
+ do {
646
+ var next = unwindWork(unitOfWork.alternate, unitOfWork);
647
+ if (null !== next) {
648
+ next.flags &= 32767;
649
+ workInProgress = next;
650
+ return;
651
+ }
652
+ next = unitOfWork.return;
653
+ null !== next && (next.flags |= 32768, next.subtreeFlags = 0, next.deletions = null);
654
+ if (!skipSiblings && (unitOfWork = unitOfWork.sibling, null !== unitOfWork)) {
655
+ workInProgress = unitOfWork;
656
+ return;
657
+ }
658
+ workInProgress = unitOfWork = next;
659
+ } while (null !== unitOfWork);
660
+ workInProgressRootExitStatus = 6;
661
+ workInProgress = null;
662
+ }
663
+ function commitRoot(root2, finishedWork, lanes, recoverableErrors, transitions, didIncludeRenderPhaseUpdate, spawnedLane, updatedLanes, suspendedRetryLanes) {
664
+ root2.cancelPendingCommit = null;
665
+ do
666
+ flushPendingEffects();
667
+ while (0 !== pendingEffectsStatus);
668
+ if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(327));
669
+ if (null !== finishedWork) {
670
+ if (finishedWork === root2.current) throw Error(formatProdErrorMessage(177));
671
+ didIncludeRenderPhaseUpdate = finishedWork.lanes | finishedWork.childLanes;
672
+ didIncludeRenderPhaseUpdate |= concurrentlyUpdatedLanes;
673
+ markRootFinished(
674
+ root2,
675
+ lanes,
676
+ didIncludeRenderPhaseUpdate,
677
+ spawnedLane,
678
+ updatedLanes,
679
+ suspendedRetryLanes
680
+ );
681
+ root2 === workInProgressRoot && (workInProgress = workInProgressRoot = null, workInProgressRootRenderLanes = 0);
682
+ pendingFinishedWork = finishedWork;
683
+ pendingEffectsRoot = root2;
684
+ pendingEffectsLanes = lanes;
685
+ pendingEffectsRemainingLanes = didIncludeRenderPhaseUpdate;
686
+ pendingPassiveTransitions = transitions;
687
+ pendingRecoverableErrors = recoverableErrors;
688
+ 0 !== (finishedWork.subtreeFlags & 10256) || 0 !== (finishedWork.flags & 10256) ? (root2.callbackNode = null, root2.callbackPriority = 0, scheduleCallback$1(NormalPriority$1, function() {
689
+ flushPassiveEffects();
690
+ return null;
691
+ })) : (root2.callbackNode = null, root2.callbackPriority = 0);
692
+ recoverableErrors = 0 !== (finishedWork.flags & 13878);
693
+ if (0 !== (finishedWork.subtreeFlags & 13878) || recoverableErrors) {
694
+ recoverableErrors = ReactSharedInternals.T;
695
+ ReactSharedInternals.T = null;
696
+ transitions = ReactDOMSharedInternals.p;
697
+ ReactDOMSharedInternals.p = 2;
698
+ spawnedLane = executionContext;
699
+ executionContext |= 4;
700
+ try {
701
+ commitBeforeMutationEffects(root2, finishedWork, lanes);
702
+ } finally {
703
+ executionContext = spawnedLane, ReactDOMSharedInternals.p = transitions, ReactSharedInternals.T = recoverableErrors;
704
+ }
705
+ }
706
+ pendingEffectsStatus = 1;
707
+ flushMutationEffects();
708
+ flushLayoutEffects();
709
+ flushSpawnedWork();
710
+ }
711
+ }
712
+ function flushMutationEffects() {
713
+ if (1 === pendingEffectsStatus) {
714
+ pendingEffectsStatus = 0;
715
+ var root2 = pendingEffectsRoot, finishedWork = pendingFinishedWork, rootMutationHasEffect = 0 !== (finishedWork.flags & 13878);
716
+ if (0 !== (finishedWork.subtreeFlags & 13878) || rootMutationHasEffect) {
717
+ rootMutationHasEffect = ReactSharedInternals.T;
718
+ ReactSharedInternals.T = null;
719
+ var previousPriority = ReactDOMSharedInternals.p;
720
+ ReactDOMSharedInternals.p = 2;
721
+ var prevExecutionContext = executionContext;
722
+ executionContext |= 4;
723
+ try {
724
+ commitMutationEffectsOnFiber(finishedWork, root2);
725
+ var priorSelectionInformation = selectionInformation, curFocusedElem = getActiveElementDeep(root2.containerInfo), priorFocusedElem = priorSelectionInformation.focusedElem, priorSelectionRange = priorSelectionInformation.selectionRange;
726
+ if (curFocusedElem !== priorFocusedElem && priorFocusedElem && priorFocusedElem.ownerDocument && containsNode(
727
+ priorFocusedElem.ownerDocument.documentElement,
728
+ priorFocusedElem
729
+ )) {
730
+ if (null !== priorSelectionRange && hasSelectionCapabilities(priorFocusedElem)) {
731
+ var start2 = priorSelectionRange.start, end = priorSelectionRange.end;
732
+ void 0 === end && (end = start2);
733
+ if ("selectionStart" in priorFocusedElem)
734
+ priorFocusedElem.selectionStart = start2, priorFocusedElem.selectionEnd = Math.min(
735
+ end,
736
+ priorFocusedElem.value.length
737
+ );
738
+ else {
739
+ var doc = priorFocusedElem.ownerDocument || document, win = doc && doc.defaultView || window;
740
+ if (win.getSelection) {
741
+ var selection = win.getSelection(), length = priorFocusedElem.textContent.length, start$jscomp$0 = Math.min(priorSelectionRange.start, length), end$jscomp$0 = void 0 === priorSelectionRange.end ? start$jscomp$0 : Math.min(priorSelectionRange.end, length);
742
+ !selection.extend && start$jscomp$0 > end$jscomp$0 && (curFocusedElem = end$jscomp$0, end$jscomp$0 = start$jscomp$0, start$jscomp$0 = curFocusedElem);
743
+ var startMarker = getNodeForCharacterOffset(
744
+ priorFocusedElem,
745
+ start$jscomp$0
746
+ ), endMarker = getNodeForCharacterOffset(
747
+ priorFocusedElem,
748
+ end$jscomp$0
749
+ );
750
+ if (startMarker && endMarker && (1 !== selection.rangeCount || selection.anchorNode !== startMarker.node || selection.anchorOffset !== startMarker.offset || selection.focusNode !== endMarker.node || selection.focusOffset !== endMarker.offset)) {
751
+ var range = doc.createRange();
752
+ range.setStart(startMarker.node, startMarker.offset);
753
+ selection.removeAllRanges();
754
+ start$jscomp$0 > end$jscomp$0 ? (selection.addRange(range), selection.extend(endMarker.node, endMarker.offset)) : (range.setEnd(endMarker.node, endMarker.offset), selection.addRange(range));
755
+ }
756
+ }
757
+ }
758
+ }
759
+ doc = [];
760
+ for (selection = priorFocusedElem; selection = selection.parentNode; )
761
+ 1 === selection.nodeType && doc.push({
762
+ element: selection,
763
+ left: selection.scrollLeft,
764
+ top: selection.scrollTop
765
+ });
766
+ "function" === typeof priorFocusedElem.focus && priorFocusedElem.focus();
767
+ for (priorFocusedElem = 0; priorFocusedElem < doc.length; priorFocusedElem++) {
768
+ var info = doc[priorFocusedElem];
769
+ info.element.scrollLeft = info.left;
770
+ info.element.scrollTop = info.top;
771
+ }
772
+ }
773
+ _enabled = !!eventsEnabled;
774
+ selectionInformation = eventsEnabled = null;
775
+ } finally {
776
+ executionContext = prevExecutionContext, ReactDOMSharedInternals.p = previousPriority, ReactSharedInternals.T = rootMutationHasEffect;
777
+ }
778
+ }
779
+ root2.current = finishedWork;
780
+ pendingEffectsStatus = 2;
781
+ }
782
+ }
783
+ function flushLayoutEffects() {
784
+ if (2 === pendingEffectsStatus) {
785
+ pendingEffectsStatus = 0;
786
+ var root2 = pendingEffectsRoot, finishedWork = pendingFinishedWork, rootHasLayoutEffect = 0 !== (finishedWork.flags & 8772);
787
+ if (0 !== (finishedWork.subtreeFlags & 8772) || rootHasLayoutEffect) {
788
+ rootHasLayoutEffect = ReactSharedInternals.T;
789
+ ReactSharedInternals.T = null;
790
+ var previousPriority = ReactDOMSharedInternals.p;
791
+ ReactDOMSharedInternals.p = 2;
792
+ var prevExecutionContext = executionContext;
793
+ executionContext |= 4;
794
+ try {
795
+ commitLayoutEffectOnFiber(root2, finishedWork.alternate, finishedWork);
796
+ } finally {
797
+ executionContext = prevExecutionContext, ReactDOMSharedInternals.p = previousPriority, ReactSharedInternals.T = rootHasLayoutEffect;
798
+ }
799
+ }
800
+ pendingEffectsStatus = 3;
801
+ }
802
+ }
803
+ function flushSpawnedWork() {
804
+ if (4 === pendingEffectsStatus || 3 === pendingEffectsStatus) {
805
+ pendingEffectsStatus = 0;
806
+ requestPaint();
807
+ var root2 = pendingEffectsRoot, finishedWork = pendingFinishedWork, lanes = pendingEffectsLanes, recoverableErrors = pendingRecoverableErrors;
808
+ 0 !== (finishedWork.subtreeFlags & 10256) || 0 !== (finishedWork.flags & 10256) ? pendingEffectsStatus = 5 : (pendingEffectsStatus = 0, pendingFinishedWork = pendingEffectsRoot = null, releaseRootPooledCache(root2, root2.pendingLanes));
809
+ var remainingLanes = root2.pendingLanes;
810
+ 0 === remainingLanes && (legacyErrorBoundariesThatAlreadyFailed = null);
811
+ lanesToEventPriority(lanes);
812
+ finishedWork = finishedWork.stateNode;
813
+ if (injectedHook && "function" === typeof injectedHook.onCommitFiberRoot)
814
+ try {
815
+ injectedHook.onCommitFiberRoot(
816
+ rendererID,
817
+ finishedWork,
818
+ void 0,
819
+ 128 === (finishedWork.current.flags & 128)
820
+ );
821
+ } catch (err) {
822
+ }
823
+ if (null !== recoverableErrors) {
824
+ finishedWork = ReactSharedInternals.T;
825
+ remainingLanes = ReactDOMSharedInternals.p;
826
+ ReactDOMSharedInternals.p = 2;
827
+ ReactSharedInternals.T = null;
828
+ try {
829
+ for (var onRecoverableError = root2.onRecoverableError, i = 0; i < recoverableErrors.length; i++) {
830
+ var recoverableError = recoverableErrors[i];
831
+ onRecoverableError(recoverableError.value, {
832
+ componentStack: recoverableError.stack
833
+ });
834
+ }
835
+ } finally {
836
+ ReactSharedInternals.T = finishedWork, ReactDOMSharedInternals.p = remainingLanes;
837
+ }
838
+ }
839
+ 0 !== (pendingEffectsLanes & 3) && flushPendingEffects();
840
+ ensureRootIsScheduled(root2);
841
+ remainingLanes = root2.pendingLanes;
842
+ 0 !== (lanes & 261930) && 0 !== (remainingLanes & 42) ? root2 === rootWithNestedUpdates ? nestedUpdateCount++ : (nestedUpdateCount = 0, rootWithNestedUpdates = root2) : nestedUpdateCount = 0;
843
+ flushSyncWorkAcrossRoots_impl(0, false);
844
+ }
845
+ }
846
+ function releaseRootPooledCache(root2, remainingLanes) {
847
+ 0 === (root2.pooledCacheLanes &= remainingLanes) && (remainingLanes = root2.pooledCache, null != remainingLanes && (root2.pooledCache = null, releaseCache(remainingLanes)));
848
+ }
849
+ function flushPendingEffects() {
850
+ flushMutationEffects();
851
+ flushLayoutEffects();
852
+ flushSpawnedWork();
853
+ return flushPassiveEffects();
854
+ }
855
+ function flushPassiveEffects() {
856
+ if (5 !== pendingEffectsStatus) return false;
857
+ var root2 = pendingEffectsRoot, remainingLanes = pendingEffectsRemainingLanes;
858
+ pendingEffectsRemainingLanes = 0;
859
+ var renderPriority = lanesToEventPriority(pendingEffectsLanes), prevTransition = ReactSharedInternals.T, previousPriority = ReactDOMSharedInternals.p;
860
+ try {
861
+ ReactDOMSharedInternals.p = 32 > renderPriority ? 32 : renderPriority;
862
+ ReactSharedInternals.T = null;
863
+ renderPriority = pendingPassiveTransitions;
864
+ pendingPassiveTransitions = null;
865
+ var root$jscomp$0 = pendingEffectsRoot, lanes = pendingEffectsLanes;
866
+ pendingEffectsStatus = 0;
867
+ pendingFinishedWork = pendingEffectsRoot = null;
868
+ pendingEffectsLanes = 0;
869
+ if (0 !== (executionContext & 6)) throw Error(formatProdErrorMessage(331));
870
+ var prevExecutionContext = executionContext;
871
+ executionContext |= 4;
872
+ commitPassiveUnmountOnFiber(root$jscomp$0.current);
873
+ commitPassiveMountOnFiber(
874
+ root$jscomp$0,
875
+ root$jscomp$0.current,
876
+ lanes,
877
+ renderPriority
878
+ );
879
+ executionContext = prevExecutionContext;
880
+ flushSyncWorkAcrossRoots_impl(0, false);
881
+ if (injectedHook && "function" === typeof injectedHook.onPostCommitFiberRoot)
882
+ try {
883
+ injectedHook.onPostCommitFiberRoot(rendererID, root$jscomp$0);
884
+ } catch (err) {
885
+ }
886
+ return true;
887
+ } finally {
888
+ ReactDOMSharedInternals.p = previousPriority, ReactSharedInternals.T = prevTransition, releaseRootPooledCache(root2, remainingLanes);
889
+ }
890
+ }
891
+ function captureCommitPhaseErrorOnRoot(rootFiber, sourceFiber, error) {
892
+ sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
893
+ sourceFiber = createRootErrorUpdate(rootFiber.stateNode, sourceFiber, 2);
894
+ rootFiber = enqueueUpdate(rootFiber, sourceFiber, 2);
895
+ null !== rootFiber && (markRootUpdated$1(rootFiber, 2), ensureRootIsScheduled(rootFiber));
896
+ }
897
+ function captureCommitPhaseError(sourceFiber, nearestMountedAncestor, error) {
898
+ if (3 === sourceFiber.tag)
899
+ captureCommitPhaseErrorOnRoot(sourceFiber, sourceFiber, error);
900
+ else
901
+ for (; null !== nearestMountedAncestor; ) {
902
+ if (3 === nearestMountedAncestor.tag) {
903
+ captureCommitPhaseErrorOnRoot(
904
+ nearestMountedAncestor,
905
+ sourceFiber,
906
+ error
907
+ );
908
+ break;
909
+ } else if (1 === nearestMountedAncestor.tag) {
910
+ var instance = nearestMountedAncestor.stateNode;
911
+ if ("function" === typeof nearestMountedAncestor.type.getDerivedStateFromError || "function" === typeof instance.componentDidCatch && (null === legacyErrorBoundariesThatAlreadyFailed || !legacyErrorBoundariesThatAlreadyFailed.has(instance))) {
912
+ sourceFiber = createCapturedValueAtFiber(error, sourceFiber);
913
+ error = createClassErrorUpdate(2);
914
+ instance = enqueueUpdate(nearestMountedAncestor, error, 2);
915
+ null !== instance && (initializeClassErrorUpdate(
916
+ error,
917
+ instance,
918
+ nearestMountedAncestor,
919
+ sourceFiber
920
+ ), markRootUpdated$1(instance, 2), ensureRootIsScheduled(instance));
921
+ break;
922
+ }
923
+ }
924
+ nearestMountedAncestor = nearestMountedAncestor.return;
925
+ }
926
+ }
927
+ function attachPingListener(root2, wakeable, lanes) {
928
+ var pingCache = root2.pingCache;
929
+ if (null === pingCache) {
930
+ pingCache = root2.pingCache = new PossiblyWeakMap();
931
+ var threadIDs = /* @__PURE__ */ new Set();
932
+ pingCache.set(wakeable, threadIDs);
933
+ } else
934
+ threadIDs = pingCache.get(wakeable), void 0 === threadIDs && (threadIDs = /* @__PURE__ */ new Set(), pingCache.set(wakeable, threadIDs));
935
+ threadIDs.has(lanes) || (workInProgressRootDidAttachPingListener = true, threadIDs.add(lanes), root2 = pingSuspendedRoot.bind(null, root2, wakeable, lanes), wakeable.then(root2, root2));
936
+ }
937
+ function pingSuspendedRoot(root2, wakeable, pingedLanes) {
938
+ var pingCache = root2.pingCache;
939
+ null !== pingCache && pingCache.delete(wakeable);
940
+ root2.pingedLanes |= root2.suspendedLanes & pingedLanes;
941
+ root2.warmLanes &= ~pingedLanes;
942
+ workInProgressRoot === root2 && (workInProgressRootRenderLanes & pingedLanes) === pingedLanes && (4 === workInProgressRootExitStatus || 3 === workInProgressRootExitStatus && (workInProgressRootRenderLanes & 62914560) === workInProgressRootRenderLanes && 300 > now() - globalMostRecentFallbackTime ? 0 === (executionContext & 2) && prepareFreshStack(root2, 0) : workInProgressRootPingedLanes |= pingedLanes, workInProgressSuspendedRetryLanes === workInProgressRootRenderLanes && (workInProgressSuspendedRetryLanes = 0));
943
+ ensureRootIsScheduled(root2);
944
+ }
945
+ function retryTimedOutBoundary(boundaryFiber, retryLane) {
946
+ 0 === retryLane && (retryLane = claimNextRetryLane());
947
+ boundaryFiber = enqueueConcurrentRenderForLane(boundaryFiber, retryLane);
948
+ null !== boundaryFiber && (markRootUpdated$1(boundaryFiber, retryLane), ensureRootIsScheduled(boundaryFiber));
949
+ }
950
+ function retryDehydratedSuspenseBoundary(boundaryFiber) {
951
+ var suspenseState = boundaryFiber.memoizedState, retryLane = 0;
952
+ null !== suspenseState && (retryLane = suspenseState.retryLane);
953
+ retryTimedOutBoundary(boundaryFiber, retryLane);
954
+ }
955
+ function resolveRetryWakeable(boundaryFiber, wakeable) {
956
+ var retryLane = 0;
957
+ switch (boundaryFiber.tag) {
958
+ case 31:
959
+ case 13:
960
+ var retryCache = boundaryFiber.stateNode;
961
+ var suspenseState = boundaryFiber.memoizedState;
962
+ null !== suspenseState && (retryLane = suspenseState.retryLane);
963
+ break;
964
+ case 19:
965
+ retryCache = boundaryFiber.stateNode;
966
+ break;
967
+ case 22:
968
+ retryCache = boundaryFiber.stateNode._retryCache;
969
+ break;
970
+ default:
971
+ throw Error(formatProdErrorMessage(314));
972
+ }
973
+ null !== retryCache && retryCache.delete(wakeable);
974
+ retryTimedOutBoundary(boundaryFiber, retryLane);
975
+ }
976
+ function scheduleCallback$1(priorityLevel, callback) {
977
+ return scheduleCallback$3(priorityLevel, callback);
978
+ }
979
+ var firstScheduledRoot = null;
980
+ var lastScheduledRoot = null;
981
+ var didScheduleMicrotask = false;
982
+ var mightHavePendingSyncWork = false;
983
+ var isFlushingWork = false;
984
+ var currentEventTransitionLane = 0;
985
+ function ensureRootIsScheduled(root2) {
986
+ root2 !== lastScheduledRoot && null === root2.next && (null === lastScheduledRoot ? firstScheduledRoot = lastScheduledRoot = root2 : lastScheduledRoot = lastScheduledRoot.next = root2);
987
+ mightHavePendingSyncWork = true;
988
+ didScheduleMicrotask || (didScheduleMicrotask = true, scheduleImmediateRootScheduleTask());
989
+ }
990
+ function flushSyncWorkAcrossRoots_impl(syncTransitionLanes, onlyLegacy) {
991
+ if (!isFlushingWork && mightHavePendingSyncWork) {
992
+ isFlushingWork = true;
993
+ do {
994
+ var didPerformSomeWork = false;
995
+ for (var root$170 = firstScheduledRoot; null !== root$170; ) {
996
+ if (!onlyLegacy)
997
+ if (0 !== syncTransitionLanes) {
998
+ var pendingLanes = root$170.pendingLanes;
999
+ if (0 === pendingLanes) var JSCompiler_inline_result = 0;
1000
+ else {
1001
+ var suspendedLanes = root$170.suspendedLanes, pingedLanes = root$170.pingedLanes;
1002
+ JSCompiler_inline_result = (1 << 31 - clz32(42 | syncTransitionLanes) + 1) - 1;
1003
+ JSCompiler_inline_result &= pendingLanes & ~(suspendedLanes & ~pingedLanes);
1004
+ JSCompiler_inline_result = JSCompiler_inline_result & 201326741 ? JSCompiler_inline_result & 201326741 | 1 : JSCompiler_inline_result ? JSCompiler_inline_result | 2 : 0;
1005
+ }
1006
+ 0 !== JSCompiler_inline_result && (didPerformSomeWork = true, performSyncWorkOnRoot(root$170, JSCompiler_inline_result));
1007
+ } else
1008
+ JSCompiler_inline_result = workInProgressRootRenderLanes, JSCompiler_inline_result = getNextLanes(
1009
+ root$170,
1010
+ root$170 === workInProgressRoot ? JSCompiler_inline_result : 0,
1011
+ null !== root$170.cancelPendingCommit || -1 !== root$170.timeoutHandle
1012
+ ), 0 === (JSCompiler_inline_result & 3) || checkIfRootIsPrerendering(root$170, JSCompiler_inline_result) || (didPerformSomeWork = true, performSyncWorkOnRoot(root$170, JSCompiler_inline_result));
1013
+ root$170 = root$170.next;
1014
+ }
1015
+ } while (didPerformSomeWork);
1016
+ isFlushingWork = false;
1017
+ }
1018
+ }
1019
+ function processRootScheduleInImmediateTask() {
1020
+ processRootScheduleInMicrotask();
1021
+ }
1022
+ function processRootScheduleInMicrotask() {
1023
+ mightHavePendingSyncWork = didScheduleMicrotask = false;
1024
+ var syncTransitionLanes = 0;
1025
+ 0 !== currentEventTransitionLane && shouldAttemptEagerTransition() && (syncTransitionLanes = currentEventTransitionLane);
1026
+ for (var currentTime = now(), prev = null, root2 = firstScheduledRoot; null !== root2; ) {
1027
+ var next = root2.next, nextLanes = scheduleTaskForRootDuringMicrotask(root2, currentTime);
1028
+ if (0 === nextLanes)
1029
+ root2.next = null, null === prev ? firstScheduledRoot = next : prev.next = next, null === next && (lastScheduledRoot = prev);
1030
+ else if (prev = root2, 0 !== syncTransitionLanes || 0 !== (nextLanes & 3))
1031
+ mightHavePendingSyncWork = true;
1032
+ root2 = next;
1033
+ }
1034
+ 0 !== pendingEffectsStatus && 5 !== pendingEffectsStatus || flushSyncWorkAcrossRoots_impl(syncTransitionLanes, false);
1035
+ 0 !== currentEventTransitionLane && (currentEventTransitionLane = 0);
1036
+ }
1037
+ function scheduleTaskForRootDuringMicrotask(root2, currentTime) {
1038
+ for (var suspendedLanes = root2.suspendedLanes, pingedLanes = root2.pingedLanes, expirationTimes = root2.expirationTimes, lanes = root2.pendingLanes & -62914561; 0 < lanes; ) {
1039
+ var index$5 = 31 - clz32(lanes), lane = 1 << index$5, expirationTime = expirationTimes[index$5];
1040
+ if (-1 === expirationTime) {
1041
+ if (0 === (lane & suspendedLanes) || 0 !== (lane & pingedLanes))
1042
+ expirationTimes[index$5] = computeExpirationTime(lane, currentTime);
1043
+ } else expirationTime <= currentTime && (root2.expiredLanes |= lane);
1044
+ lanes &= ~lane;
1045
+ }
1046
+ currentTime = workInProgressRoot;
1047
+ suspendedLanes = workInProgressRootRenderLanes;
1048
+ suspendedLanes = getNextLanes(
1049
+ root2,
1050
+ root2 === currentTime ? suspendedLanes : 0,
1051
+ null !== root2.cancelPendingCommit || -1 !== root2.timeoutHandle
1052
+ );
1053
+ pingedLanes = root2.callbackNode;
1054
+ if (0 === suspendedLanes || root2 === currentTime && (2 === workInProgressSuspendedReason || 9 === workInProgressSuspendedReason) || null !== root2.cancelPendingCommit)
1055
+ return null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes), root2.callbackNode = null, root2.callbackPriority = 0;
1056
+ if (0 === (suspendedLanes & 3) || checkIfRootIsPrerendering(root2, suspendedLanes)) {
1057
+ currentTime = suspendedLanes & -suspendedLanes;
1058
+ if (currentTime === root2.callbackPriority) return currentTime;
1059
+ null !== pingedLanes && cancelCallback$1(pingedLanes);
1060
+ switch (lanesToEventPriority(suspendedLanes)) {
1061
+ case 2:
1062
+ case 8:
1063
+ suspendedLanes = UserBlockingPriority;
1064
+ break;
1065
+ case 32:
1066
+ suspendedLanes = NormalPriority$1;
1067
+ break;
1068
+ case 268435456:
1069
+ suspendedLanes = IdlePriority;
1070
+ break;
1071
+ default:
1072
+ suspendedLanes = NormalPriority$1;
1073
+ }
1074
+ pingedLanes = performWorkOnRootViaSchedulerTask.bind(null, root2);
1075
+ suspendedLanes = scheduleCallback$3(suspendedLanes, pingedLanes);
1076
+ root2.callbackPriority = currentTime;
1077
+ root2.callbackNode = suspendedLanes;
1078
+ return currentTime;
1079
+ }
1080
+ null !== pingedLanes && null !== pingedLanes && cancelCallback$1(pingedLanes);
1081
+ root2.callbackPriority = 2;
1082
+ root2.callbackNode = null;
1083
+ return 2;
1084
+ }
1085
+ function performWorkOnRootViaSchedulerTask(root2, didTimeout) {
1086
+ if (0 !== pendingEffectsStatus && 5 !== pendingEffectsStatus)
1087
+ return root2.callbackNode = null, root2.callbackPriority = 0, null;
1088
+ var originalCallbackNode = root2.callbackNode;
1089
+ if (flushPendingEffects() && root2.callbackNode !== originalCallbackNode)
1090
+ return null;
1091
+ var workInProgressRootRenderLanes$jscomp$0 = workInProgressRootRenderLanes;
1092
+ workInProgressRootRenderLanes$jscomp$0 = getNextLanes(
1093
+ root2,
1094
+ root2 === workInProgressRoot ? workInProgressRootRenderLanes$jscomp$0 : 0,
1095
+ null !== root2.cancelPendingCommit || -1 !== root2.timeoutHandle
1096
+ );
1097
+ if (0 === workInProgressRootRenderLanes$jscomp$0) return null;
1098
+ performWorkOnRoot(root2, workInProgressRootRenderLanes$jscomp$0, didTimeout);
1099
+ scheduleTaskForRootDuringMicrotask(root2, now());
1100
+ return null != root2.callbackNode && root2.callbackNode === originalCallbackNode ? performWorkOnRootViaSchedulerTask.bind(null, root2) : null;
1101
+ }
1102
+ function performSyncWorkOnRoot(root2, lanes) {
1103
+ if (flushPendingEffects()) return null;
1104
+ performWorkOnRoot(root2, lanes, true);
1105
+ }
1106
+ function scheduleImmediateRootScheduleTask() {
1107
+ scheduleMicrotask(function() {
1108
+ 0 !== (executionContext & 6) ? scheduleCallback$3(
1109
+ ImmediatePriority,
1110
+ processRootScheduleInImmediateTask
1111
+ ) : processRootScheduleInMicrotask();
1112
+ });
1113
+ }
1114
+ function requestTransitionLane() {
1115
+ if (0 === currentEventTransitionLane) {
1116
+ var actionScopeLane = currentEntangledLane;
1117
+ 0 === actionScopeLane && (actionScopeLane = nextTransitionUpdateLane, nextTransitionUpdateLane <<= 1, 0 === (nextTransitionUpdateLane & 261888) && (nextTransitionUpdateLane = 256));
1118
+ currentEventTransitionLane = actionScopeLane;
1119
+ }
1120
+ return currentEventTransitionLane;
1121
+ }