groove-dev 0.27.71 → 0.27.73

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 (137) hide show
  1. package/node_modules/@groove-dev/cli/package.json +1 -1
  2. package/node_modules/@groove-dev/daemon/package.json +1 -1
  3. package/node_modules/@groove-dev/daemon/src/api.js +38 -27
  4. package/node_modules/@groove-dev/daemon/src/providers/claude-code.js +2 -0
  5. package/node_modules/@groove-dev/daemon/src/providers/codex.js +1 -0
  6. package/node_modules/@groove-dev/daemon/src/providers/index.js +3 -3
  7. package/node_modules/@groove-dev/gui/dist/assets/index-BFc7Ov6v.css +1 -0
  8. package/node_modules/@groove-dev/gui/dist/assets/{index-BK6tvmxx.js → index-Deza1S0i.js} +160 -160
  9. package/node_modules/@groove-dev/gui/dist/index.html +2 -2
  10. package/node_modules/@groove-dev/gui/package.json +1 -1
  11. package/node_modules/@groove-dev/gui/src/components/editor/editor-tabs.jsx +5 -5
  12. package/node_modules/@groove-dev/gui/src/components/editor/file-tree.jsx +11 -0
  13. package/node_modules/@groove-dev/gui/src/components/settings/ProviderSetupWizard.jsx +7 -2
  14. package/node_modules/@groove-dev/gui/src/stores/groove.js +46 -54
  15. package/node_modules/@groove-dev/gui/src/views/editor.jsx +4 -3
  16. package/package.json +1 -1
  17. package/packages/cli/package.json +1 -1
  18. package/packages/daemon/package.json +1 -1
  19. package/packages/daemon/src/api.js +38 -27
  20. package/packages/daemon/src/providers/claude-code.js +2 -0
  21. package/packages/daemon/src/providers/codex.js +1 -0
  22. package/packages/daemon/src/providers/index.js +3 -3
  23. package/packages/gui/dist/assets/index-BFc7Ov6v.css +1 -0
  24. package/packages/gui/dist/assets/{index-BK6tvmxx.js → index-Deza1S0i.js} +160 -160
  25. package/packages/gui/dist/index.html +2 -2
  26. package/packages/gui/package.json +1 -1
  27. package/packages/gui/src/components/editor/editor-tabs.jsx +5 -5
  28. package/packages/gui/src/components/editor/file-tree.jsx +11 -0
  29. package/packages/gui/src/components/settings/ProviderSetupWizard.jsx +7 -2
  30. package/packages/gui/src/stores/groove.js +46 -54
  31. package/packages/gui/src/views/editor.jsx +4 -3
  32. package/node_modules/@groove-dev/gui/dist/assets/index-74E3YTkT.css +0 -1
  33. package/packages/gui/dist/assets/index-74E3YTkT.css +0 -1
  34. package/packages/gui/node_modules/.vite/deps/@codemirror_autocomplete.js +0 -68
  35. package/packages/gui/node_modules/.vite/deps/@codemirror_autocomplete.js.map +0 -7
  36. package/packages/gui/node_modules/.vite/deps/@codemirror_commands.js +0 -1420
  37. package/packages/gui/node_modules/.vite/deps/@codemirror_commands.js.map +0 -7
  38. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-css.js +0 -17
  39. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-css.js.map +0 -7
  40. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-html.js +0 -22
  41. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-html.js.map +0 -7
  42. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-javascript.js +0 -34
  43. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-javascript.js.map +0 -7
  44. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-json.js +0 -101
  45. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-json.js.map +0 -7
  46. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-markdown.js +0 -2534
  47. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-markdown.js.map +0 -7
  48. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-python.js +0 -789
  49. package/packages/gui/node_modules/.vite/deps/@codemirror_lang-python.js.map +0 -7
  50. package/packages/gui/node_modules/.vite/deps/@codemirror_language.js +0 -115
  51. package/packages/gui/node_modules/.vite/deps/@codemirror_language.js.map +0 -7
  52. package/packages/gui/node_modules/.vite/deps/@codemirror_search.js +0 -1136
  53. package/packages/gui/node_modules/.vite/deps/@codemirror_search.js.map +0 -7
  54. package/packages/gui/node_modules/.vite/deps/@codemirror_state.js +0 -63
  55. package/packages/gui/node_modules/.vite/deps/@codemirror_state.js.map +0 -7
  56. package/packages/gui/node_modules/.vite/deps/@codemirror_theme-one-dark.js +0 -179
  57. package/packages/gui/node_modules/.vite/deps/@codemirror_theme-one-dark.js.map +0 -7
  58. package/packages/gui/node_modules/.vite/deps/@codemirror_view.js +0 -104
  59. package/packages/gui/node_modules/.vite/deps/@codemirror_view.js.map +0 -7
  60. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-context-menu.js +0 -1202
  61. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-context-menu.js.map +0 -7
  62. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-dialog.js +0 -365
  63. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-dialog.js.map +0 -7
  64. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-scroll-area.js +0 -757
  65. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-scroll-area.js.map +0 -7
  66. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-tabs.js +0 -219
  67. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-tabs.js.map +0 -7
  68. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-tooltip.js +0 -562
  69. package/packages/gui/node_modules/.vite/deps/@radix-ui_react-tooltip.js.map +0 -7
  70. package/packages/gui/node_modules/.vite/deps/@xterm_addon-fit.js +0 -46
  71. package/packages/gui/node_modules/.vite/deps/@xterm_addon-fit.js.map +0 -7
  72. package/packages/gui/node_modules/.vite/deps/@xterm_addon-web-links.js +0 -121
  73. package/packages/gui/node_modules/.vite/deps/@xterm_addon-web-links.js.map +0 -7
  74. package/packages/gui/node_modules/.vite/deps/@xterm_xterm.js +0 -9237
  75. package/packages/gui/node_modules/.vite/deps/@xterm_xterm.js.map +0 -7
  76. package/packages/gui/node_modules/.vite/deps/@xyflow_react.js +0 -9934
  77. package/packages/gui/node_modules/.vite/deps/@xyflow_react.js.map +0 -7
  78. package/packages/gui/node_modules/.vite/deps/_metadata.json +0 -259
  79. package/packages/gui/node_modules/.vite/deps/chunk-3EE34IFC.js +0 -5169
  80. package/packages/gui/node_modules/.vite/deps/chunk-3EE34IFC.js.map +0 -7
  81. package/packages/gui/node_modules/.vite/deps/chunk-3IB5EUP7.js +0 -2000
  82. package/packages/gui/node_modules/.vite/deps/chunk-3IB5EUP7.js.map +0 -7
  83. package/packages/gui/node_modules/.vite/deps/chunk-44CLUOQE.js +0 -1776
  84. package/packages/gui/node_modules/.vite/deps/chunk-44CLUOQE.js.map +0 -7
  85. package/packages/gui/node_modules/.vite/deps/chunk-4JHIKDUF.js +0 -435
  86. package/packages/gui/node_modules/.vite/deps/chunk-4JHIKDUF.js.map +0 -7
  87. package/packages/gui/node_modules/.vite/deps/chunk-ACEP5X2F.js +0 -292
  88. package/packages/gui/node_modules/.vite/deps/chunk-ACEP5X2F.js.map +0 -7
  89. package/packages/gui/node_modules/.vite/deps/chunk-CDLO3JFW.js +0 -1004
  90. package/packages/gui/node_modules/.vite/deps/chunk-CDLO3JFW.js.map +0 -7
  91. package/packages/gui/node_modules/.vite/deps/chunk-FOR2E6IR.js +0 -105
  92. package/packages/gui/node_modules/.vite/deps/chunk-FOR2E6IR.js.map +0 -7
  93. package/packages/gui/node_modules/.vite/deps/chunk-HPXOV7QR.js +0 -23
  94. package/packages/gui/node_modules/.vite/deps/chunk-HPXOV7QR.js.map +0 -7
  95. package/packages/gui/node_modules/.vite/deps/chunk-HVFOBSCQ.js +0 -1062
  96. package/packages/gui/node_modules/.vite/deps/chunk-HVFOBSCQ.js.map +0 -7
  97. package/packages/gui/node_modules/.vite/deps/chunk-PGL3TTJA.js +0 -1115
  98. package/packages/gui/node_modules/.vite/deps/chunk-PGL3TTJA.js.map +0 -7
  99. package/packages/gui/node_modules/.vite/deps/chunk-PGMATLPZ.js +0 -2294
  100. package/packages/gui/node_modules/.vite/deps/chunk-PGMATLPZ.js.map +0 -7
  101. package/packages/gui/node_modules/.vite/deps/chunk-PR4QN5HX.js +0 -42
  102. package/packages/gui/node_modules/.vite/deps/chunk-PR4QN5HX.js.map +0 -7
  103. package/packages/gui/node_modules/.vite/deps/chunk-QX3PPTYO.js +0 -315
  104. package/packages/gui/node_modules/.vite/deps/chunk-QX3PPTYO.js.map +0 -7
  105. package/packages/gui/node_modules/.vite/deps/chunk-RE2FU7ZU.js +0 -10985
  106. package/packages/gui/node_modules/.vite/deps/chunk-RE2FU7ZU.js.map +0 -7
  107. package/packages/gui/node_modules/.vite/deps/chunk-SPKVQGZX.js +0 -701
  108. package/packages/gui/node_modules/.vite/deps/chunk-SPKVQGZX.js.map +0 -7
  109. package/packages/gui/node_modules/.vite/deps/chunk-YAD7VOVN.js +0 -280
  110. package/packages/gui/node_modules/.vite/deps/chunk-YAD7VOVN.js.map +0 -7
  111. package/packages/gui/node_modules/.vite/deps/chunk-YEUURE4V.js +0 -264
  112. package/packages/gui/node_modules/.vite/deps/chunk-YEUURE4V.js.map +0 -7
  113. package/packages/gui/node_modules/.vite/deps/chunk-YYJMNVCJ.js +0 -3459
  114. package/packages/gui/node_modules/.vite/deps/chunk-YYJMNVCJ.js.map +0 -7
  115. package/packages/gui/node_modules/.vite/deps/chunk-Z5NIFSCT.js +0 -1106
  116. package/packages/gui/node_modules/.vite/deps/chunk-Z5NIFSCT.js.map +0 -7
  117. package/packages/gui/node_modules/.vite/deps/clsx.js +0 -22
  118. package/packages/gui/node_modules/.vite/deps/clsx.js.map +0 -7
  119. package/packages/gui/node_modules/.vite/deps/framer-motion.js +0 -12732
  120. package/packages/gui/node_modules/.vite/deps/framer-motion.js.map +0 -7
  121. package/packages/gui/node_modules/.vite/deps/lucide-react.js +0 -29653
  122. package/packages/gui/node_modules/.vite/deps/lucide-react.js.map +0 -7
  123. package/packages/gui/node_modules/.vite/deps/package.json +0 -3
  124. package/packages/gui/node_modules/.vite/deps/react-dom.js +0 -6
  125. package/packages/gui/node_modules/.vite/deps/react-dom.js.map +0 -7
  126. package/packages/gui/node_modules/.vite/deps/react-dom_client.js +0 -20217
  127. package/packages/gui/node_modules/.vite/deps/react-dom_client.js.map +0 -7
  128. package/packages/gui/node_modules/.vite/deps/react.js +0 -5
  129. package/packages/gui/node_modules/.vite/deps/react.js.map +0 -7
  130. package/packages/gui/node_modules/.vite/deps/react_jsx-dev-runtime.js +0 -278
  131. package/packages/gui/node_modules/.vite/deps/react_jsx-dev-runtime.js.map +0 -7
  132. package/packages/gui/node_modules/.vite/deps/react_jsx-runtime.js +0 -6
  133. package/packages/gui/node_modules/.vite/deps/react_jsx-runtime.js.map +0 -7
  134. package/packages/gui/node_modules/.vite/deps/tailwind-merge.js +0 -3263
  135. package/packages/gui/node_modules/.vite/deps/tailwind-merge.js.map +0 -7
  136. package/packages/gui/node_modules/.vite/deps/zustand.js +0 -56
  137. package/packages/gui/node_modules/.vite/deps/zustand.js.map +0 -7
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../node_modules/react-dom/cjs/react-dom.development.js", "../../../../../node_modules/react-dom/index.js"],
4
- "sourcesContent": ["/**\n * @license React\n * react-dom.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function noop() {}\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function createPortal$1(children, containerInfo, implementation) {\n var key =\n 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null;\n try {\n testStringCoercion(key);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n JSCompiler_inline_result &&\n (console.error(\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n key[Symbol.toStringTag]) ||\n key.constructor.name ||\n \"Object\"\n ),\n testStringCoercion(key));\n return {\n $$typeof: REACT_PORTAL_TYPE,\n key: null == key ? null : \"\" + key,\n children: children,\n containerInfo: containerInfo,\n implementation: implementation\n };\n }\n function getCrossOriginStringAs(as, input) {\n if (\"font\" === as) return \"\";\n if (\"string\" === typeof input)\n return \"use-credentials\" === input ? input : \"\";\n }\n function getValueDescriptorExpectingObjectForWarning(thing) {\n return null === thing\n ? \"`null`\"\n : void 0 === thing\n ? \"`undefined`\"\n : \"\" === thing\n ? \"an empty string\"\n : 'something with type \"' + typeof thing + '\"';\n }\n function getValueDescriptorExpectingEnumForWarning(thing) {\n return null === thing\n ? \"`null`\"\n : void 0 === thing\n ? \"`undefined`\"\n : \"\" === thing\n ? \"an empty string\"\n : \"string\" === typeof thing\n ? JSON.stringify(thing)\n : \"number\" === typeof thing\n ? \"`\" + thing + \"`\"\n : 'something with type \"' + typeof thing + '\"';\n }\n function resolveDispatcher() {\n var dispatcher = ReactSharedInternals.H;\n null === dispatcher &&\n console.error(\n \"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\\n1. You might have mismatching versions of React and the renderer (such as React DOM)\\n2. You might be breaking the Rules of Hooks\\n3. You might have more than one copy of React in the same app\\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.\"\n );\n return dispatcher;\n }\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());\n var React = require(\"react\"),\n Internals = {\n d: {\n f: noop,\n r: function () {\n throw Error(\n \"Invalid form element. requestFormReset must be passed a form that was rendered by React.\"\n );\n },\n D: noop,\n C: noop,\n L: noop,\n m: noop,\n X: noop,\n S: noop,\n M: noop\n },\n p: 0,\n findDOMNode: null\n },\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;\n (\"function\" === typeof Map &&\n null != Map.prototype &&\n \"function\" === typeof Map.prototype.forEach &&\n \"function\" === typeof Set &&\n null != Set.prototype &&\n \"function\" === typeof Set.prototype.clear &&\n \"function\" === typeof Set.prototype.forEach) ||\n console.error(\n \"React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills\"\n );\n exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n Internals;\n exports.createPortal = function (children, container) {\n var key =\n 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null;\n if (\n !container ||\n (1 !== container.nodeType &&\n 9 !== container.nodeType &&\n 11 !== container.nodeType)\n )\n throw Error(\"Target container is not a DOM element.\");\n return createPortal$1(children, container, null, key);\n };\n exports.flushSync = function (fn) {\n var previousTransition = ReactSharedInternals.T,\n previousUpdatePriority = Internals.p;\n try {\n if (((ReactSharedInternals.T = null), (Internals.p = 2), fn))\n return fn();\n } finally {\n (ReactSharedInternals.T = previousTransition),\n (Internals.p = previousUpdatePriority),\n Internals.d.f() &&\n console.error(\n \"flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task.\"\n );\n }\n };\n exports.preconnect = function (href, options) {\n \"string\" === typeof href && href\n ? null != options && \"object\" !== typeof options\n ? console.error(\n \"ReactDOM.preconnect(): Expected the `options` argument (second) to be an object but encountered %s instead. The only supported option at this time is `crossOrigin` which accepts a string.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : null != options &&\n \"string\" !== typeof options.crossOrigin &&\n console.error(\n \"ReactDOM.preconnect(): Expected the `crossOrigin` option (second argument) to be a string but encountered %s instead. Try removing this option or passing a string value instead.\",\n getValueDescriptorExpectingObjectForWarning(options.crossOrigin)\n )\n : console.error(\n \"ReactDOM.preconnect(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n \"string\" === typeof href &&\n (options\n ? ((options = options.crossOrigin),\n (options =\n \"string\" === typeof options\n ? \"use-credentials\" === options\n ? options\n : \"\"\n : void 0))\n : (options = null),\n Internals.d.C(href, options));\n };\n exports.prefetchDNS = function (href) {\n if (\"string\" !== typeof href || !href)\n console.error(\n \"ReactDOM.prefetchDNS(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n else if (1 < arguments.length) {\n var options = arguments[1];\n \"object\" === typeof options && options.hasOwnProperty(\"crossOrigin\")\n ? console.error(\n \"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. It looks like the you are attempting to set a crossOrigin property for this DNS lookup hint. Browsers do not perform DNS queries using CORS and setting this attribute on the resource hint has no effect. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : console.error(\n \"ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.\",\n getValueDescriptorExpectingEnumForWarning(options)\n );\n }\n \"string\" === typeof href && Internals.d.D(href);\n };\n exports.preinit = function (href, options) {\n \"string\" === typeof href && href\n ? null == options || \"object\" !== typeof options\n ? console.error(\n \"ReactDOM.preinit(): Expected the `options` argument (second) to be an object with an `as` property describing the type of resource to be preinitialized but encountered %s instead.\",\n getValueDescriptorExpectingEnumForWarning(options)\n )\n : \"style\" !== options.as &&\n \"script\" !== options.as &&\n console.error(\n 'ReactDOM.preinit(): Expected the `as` property in the `options` argument (second) to contain a valid value describing the type of resource to be preinitialized but encountered %s instead. Valid values for `as` are \"style\" and \"script\".',\n getValueDescriptorExpectingEnumForWarning(options.as)\n )\n : console.error(\n \"ReactDOM.preinit(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.\",\n getValueDescriptorExpectingObjectForWarning(href)\n );\n if (\n \"string\" === typeof href &&\n options &&\n \"string\" === typeof options.as\n ) {\n var as = options.as,\n crossOrigin = getCrossOriginStringAs(as, options.crossOrigin),\n integrity =\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n fetchPriority =\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0;\n \"style\" === as\n ? Internals.d.S(\n href,\n \"string\" === typeof options.precedence\n ? options.precedence\n : void 0,\n {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority\n }\n )\n : \"script\" === as &&\n Internals.d.X(href, {\n crossOrigin: crossOrigin,\n integrity: integrity,\n fetchPriority: fetchPriority,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n }\n };\n exports.preinitModule = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n void 0 !== options && \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : options &&\n \"as\" in options &&\n \"script\" !== options.as &&\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingEnumForWarning(options.as) +\n \".\");\n if (encountered)\n console.error(\n \"ReactDOM.preinitModule(): Expected up to two arguments, a non-empty `href` string and, optionally, an `options` object with a valid `as` property.%s\",\n encountered\n );\n else\n switch (\n ((encountered =\n options && \"string\" === typeof options.as ? options.as : \"script\"),\n encountered)\n ) {\n case \"script\":\n break;\n default:\n (encountered =\n getValueDescriptorExpectingEnumForWarning(encountered)),\n console.error(\n 'ReactDOM.preinitModule(): Currently the only supported \"as\" type for this function is \"script\" but received \"%s\" instead. This warning was generated for `href` \"%s\". In the future other module types will be supported, aligning with the import-attributes proposal. Learn more here: (https://github.com/tc39/proposal-import-attributes)',\n encountered,\n href\n );\n }\n if (\"string\" === typeof href)\n if (\"object\" === typeof options && null !== options) {\n if (null == options.as || \"script\" === options.as)\n (encountered = getCrossOriginStringAs(\n options.as,\n options.crossOrigin\n )),\n Internals.d.M(href, {\n crossOrigin: encountered,\n integrity:\n \"string\" === typeof options.integrity\n ? options.integrity\n : void 0,\n nonce:\n \"string\" === typeof options.nonce ? options.nonce : void 0\n });\n } else null == options && Internals.d.M(href);\n };\n exports.preload = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n null == options || \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : (\"string\" === typeof options.as && options.as) ||\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options.as) +\n \".\");\n encountered &&\n console.error(\n 'ReactDOM.preload(): Expected two arguments, a non-empty `href` string and an `options` object with an `as` property valid for a `<link rel=\"preload\" as=\"...\" />` tag.%s',\n encountered\n );\n if (\n \"string\" === typeof href &&\n \"object\" === typeof options &&\n null !== options &&\n \"string\" === typeof options.as\n ) {\n encountered = options.as;\n var crossOrigin = getCrossOriginStringAs(\n encountered,\n options.crossOrigin\n );\n Internals.d.L(href, encountered, {\n crossOrigin: crossOrigin,\n integrity:\n \"string\" === typeof options.integrity ? options.integrity : void 0,\n nonce: \"string\" === typeof options.nonce ? options.nonce : void 0,\n type: \"string\" === typeof options.type ? options.type : void 0,\n fetchPriority:\n \"string\" === typeof options.fetchPriority\n ? options.fetchPriority\n : void 0,\n referrerPolicy:\n \"string\" === typeof options.referrerPolicy\n ? options.referrerPolicy\n : void 0,\n imageSrcSet:\n \"string\" === typeof options.imageSrcSet\n ? options.imageSrcSet\n : void 0,\n imageSizes:\n \"string\" === typeof options.imageSizes\n ? options.imageSizes\n : void 0,\n media: \"string\" === typeof options.media ? options.media : void 0\n });\n }\n };\n exports.preloadModule = function (href, options) {\n var encountered = \"\";\n (\"string\" === typeof href && href) ||\n (encountered +=\n \" The `href` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(href) +\n \".\");\n void 0 !== options && \"object\" !== typeof options\n ? (encountered +=\n \" The `options` argument encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options) +\n \".\")\n : options &&\n \"as\" in options &&\n \"string\" !== typeof options.as &&\n (encountered +=\n \" The `as` option encountered was \" +\n getValueDescriptorExpectingObjectForWarning(options.as) +\n \".\");\n encountered &&\n console.error(\n 'ReactDOM.preloadModule(): Expected two arguments, a non-empty `href` string and, optionally, an `options` object with an `as` property valid for a `<link rel=\"modulepreload\" as=\"...\" />` tag.%s',\n encountered\n );\n \"string\" === typeof href &&\n (options\n ? ((encountered = getCrossOriginStringAs(\n options.as,\n options.crossOrigin\n )),\n Internals.d.m(href, {\n as:\n \"string\" === typeof options.as && \"script\" !== options.as\n ? options.as\n : void 0,\n crossOrigin: encountered,\n integrity:\n \"string\" === typeof options.integrity\n ? options.integrity\n : void 0\n }))\n : Internals.d.m(href));\n };\n exports.requestFormReset = function (form) {\n Internals.d.r(form);\n };\n exports.unstable_batchedUpdates = function (fn, a) {\n return fn(a);\n };\n exports.useFormState = function (action, initialState, permalink) {\n return resolveDispatcher().useFormState(action, initialState, permalink);\n };\n exports.useFormStatus = function () {\n return resolveDispatcher().useHostTransitionStatus();\n };\n exports.version = \"19.2.4\";\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());\n })();\n", "'use strict';\n\nfunction checkDCE() {\n /* global __REACT_DEVTOOLS_GLOBAL_HOOK__ */\n if (\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ === 'undefined' ||\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE !== 'function'\n ) {\n return;\n }\n if (process.env.NODE_ENV !== 'production') {\n // This branch is unreachable because this function is only called\n // in production, but the condition is true only in development.\n // Therefore if the branch is still here, dead code elimination wasn't\n // properly applied.\n // Don't change the message. React DevTools relies on it. Also make sure\n // this message doesn't occur elsewhere in this function, or it will cause\n // a false positive.\n throw new Error('^_^');\n }\n try {\n // Verify that the code above has been dead code eliminated (DCE'd).\n __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(checkDCE);\n } catch (err) {\n // DevTools shouldn't crash React, no matter what.\n // We should still report in case we break this code.\n console.error(err);\n }\n}\n\nif (process.env.NODE_ENV === 'production') {\n // DCE check should happen before ReactDOM bundle executes so that\n // DevTools can report bad minification during injection.\n checkDCE();\n module.exports = require('./cjs/react-dom.production.js');\n} else {\n module.exports = require('./cjs/react-dom.development.js');\n}\n"],
5
- "mappings": ";;;;;;;;AAAA;AAAA;AAAA;AAWA,KACG,WAAY;AACX,eAAS,OAAO;AAAA,MAAC;AACjB,eAAS,mBAAmB,OAAO;AACjC,eAAO,KAAK;AAAA,MACd;AACA,eAAS,eAAe,UAAU,eAAe,gBAAgB;AAC/D,YAAI,MACF,IAAI,UAAU,UAAU,WAAW,UAAU,CAAC,IAAI,UAAU,CAAC,IAAI;AACnE,YAAI;AACF,6BAAmB,GAAG;AACtB,cAAI,2BAA2B;AAAA,QACjC,SAAS,GAAG;AACV,qCAA2B;AAAA,QAC7B;AACA,qCACG,QAAQ;AAAA,UACP;AAAA,UACC,eAAe,OAAO,UACrB,OAAO,eACP,IAAI,OAAO,WAAW,KACtB,IAAI,YAAY,QAChB;AAAA,QACJ,GACA,mBAAmB,GAAG;AACxB,eAAO;AAAA,UACL,UAAU;AAAA,UACV,KAAK,QAAQ,MAAM,OAAO,KAAK;AAAA,UAC/B;AAAA,UACA;AAAA,UACA;AAAA,QACF;AAAA,MACF;AACA,eAAS,uBAAuB,IAAI,OAAO;AACzC,YAAI,WAAW,GAAI,QAAO;AAC1B,YAAI,aAAa,OAAO;AACtB,iBAAO,sBAAsB,QAAQ,QAAQ;AAAA,MACjD;AACA,eAAS,4CAA4C,OAAO;AAC1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B,SAAU,IAAI,GAAG;AACjD,eAAO,GAAG,CAAC;AAAA,MACb;AACA,cAAQ,eAAe,SAAU,QAAQ,cAAc,WAAW;AAChE,eAAO,kBAAkB,EAAE,aAAa,QAAQ,cAAc,SAAS;AAAA,MACzE;AACA,cAAQ,gBAAgB,WAAY;AAClC,eAAO,kBAAkB,EAAE,wBAAwB;AAAA,MACrD;AACA,cAAQ,UAAU;AAClB,sBAAgB,OAAO,kCACrB,eACE,OAAO,+BAA+B,8BACxC,+BAA+B,2BAA2B,MAAM,CAAC;AAAA,IACrE,GAAG;AAAA;AAAA;;;ACvaL;AAAA;AA8BA,QAAI,OAAuC;AAGzC,eAAS;AACT,aAAO,UAAU;AAAA,IACnB,OAAO;AACL,aAAO,UAAU;AAAA,IACnB;AAAA;AAAA;",
6
- "names": []
7
- }
@@ -1,264 +0,0 @@
1
- import {
2
- Primitive,
3
- composeEventHandlers,
4
- dispatchDiscreteCustomEvent,
5
- useCallbackRef,
6
- useComposedRefs,
7
- useLayoutEffect2
8
- } from "./chunk-4JHIKDUF.js";
9
- import {
10
- require_react_dom
11
- } from "./chunk-YAD7VOVN.js";
12
- import {
13
- require_jsx_runtime
14
- } from "./chunk-ACEP5X2F.js";
15
- import {
16
- require_react
17
- } from "./chunk-CDLO3JFW.js";
18
- import {
19
- __toESM
20
- } from "./chunk-PR4QN5HX.js";
21
-
22
- // ../../node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs
23
- var React2 = __toESM(require_react(), 1);
24
-
25
- // ../../node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs
26
- var React = __toESM(require_react(), 1);
27
- function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
28
- const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);
29
- React.useEffect(() => {
30
- const handleKeyDown = (event) => {
31
- if (event.key === "Escape") {
32
- onEscapeKeyDown(event);
33
- }
34
- };
35
- ownerDocument.addEventListener("keydown", handleKeyDown, { capture: true });
36
- return () => ownerDocument.removeEventListener("keydown", handleKeyDown, { capture: true });
37
- }, [onEscapeKeyDown, ownerDocument]);
38
- }
39
-
40
- // ../../node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs
41
- var import_jsx_runtime = __toESM(require_jsx_runtime(), 1);
42
- var DISMISSABLE_LAYER_NAME = "DismissableLayer";
43
- var CONTEXT_UPDATE = "dismissableLayer.update";
44
- var POINTER_DOWN_OUTSIDE = "dismissableLayer.pointerDownOutside";
45
- var FOCUS_OUTSIDE = "dismissableLayer.focusOutside";
46
- var originalBodyPointerEvents;
47
- var DismissableLayerContext = React2.createContext({
48
- layers: /* @__PURE__ */ new Set(),
49
- layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
50
- branches: /* @__PURE__ */ new Set()
51
- });
52
- var DismissableLayer = React2.forwardRef(
53
- (props, forwardedRef) => {
54
- const {
55
- disableOutsidePointerEvents = false,
56
- onEscapeKeyDown,
57
- onPointerDownOutside,
58
- onFocusOutside,
59
- onInteractOutside,
60
- onDismiss,
61
- ...layerProps
62
- } = props;
63
- const context = React2.useContext(DismissableLayerContext);
64
- const [node, setNode] = React2.useState(null);
65
- const ownerDocument = (node == null ? void 0 : node.ownerDocument) ?? (globalThis == null ? void 0 : globalThis.document);
66
- const [, force] = React2.useState({});
67
- const composedRefs = useComposedRefs(forwardedRef, (node2) => setNode(node2));
68
- const layers = Array.from(context.layers);
69
- const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1);
70
- const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled);
71
- const index = node ? layers.indexOf(node) : -1;
72
- const isBodyPointerEventsDisabled = context.layersWithOutsidePointerEventsDisabled.size > 0;
73
- const isPointerEventsEnabled = index >= highestLayerWithOutsidePointerEventsDisabledIndex;
74
- const pointerDownOutside = usePointerDownOutside((event) => {
75
- const target = event.target;
76
- const isPointerDownOnBranch = [...context.branches].some((branch) => branch.contains(target));
77
- if (!isPointerEventsEnabled || isPointerDownOnBranch) return;
78
- onPointerDownOutside == null ? void 0 : onPointerDownOutside(event);
79
- onInteractOutside == null ? void 0 : onInteractOutside(event);
80
- if (!event.defaultPrevented) onDismiss == null ? void 0 : onDismiss();
81
- }, ownerDocument);
82
- const focusOutside = useFocusOutside((event) => {
83
- const target = event.target;
84
- const isFocusInBranch = [...context.branches].some((branch) => branch.contains(target));
85
- if (isFocusInBranch) return;
86
- onFocusOutside == null ? void 0 : onFocusOutside(event);
87
- onInteractOutside == null ? void 0 : onInteractOutside(event);
88
- if (!event.defaultPrevented) onDismiss == null ? void 0 : onDismiss();
89
- }, ownerDocument);
90
- useEscapeKeydown((event) => {
91
- const isHighestLayer = index === context.layers.size - 1;
92
- if (!isHighestLayer) return;
93
- onEscapeKeyDown == null ? void 0 : onEscapeKeyDown(event);
94
- if (!event.defaultPrevented && onDismiss) {
95
- event.preventDefault();
96
- onDismiss();
97
- }
98
- }, ownerDocument);
99
- React2.useEffect(() => {
100
- if (!node) return;
101
- if (disableOutsidePointerEvents) {
102
- if (context.layersWithOutsidePointerEventsDisabled.size === 0) {
103
- originalBodyPointerEvents = ownerDocument.body.style.pointerEvents;
104
- ownerDocument.body.style.pointerEvents = "none";
105
- }
106
- context.layersWithOutsidePointerEventsDisabled.add(node);
107
- }
108
- context.layers.add(node);
109
- dispatchUpdate();
110
- return () => {
111
- if (disableOutsidePointerEvents && context.layersWithOutsidePointerEventsDisabled.size === 1) {
112
- ownerDocument.body.style.pointerEvents = originalBodyPointerEvents;
113
- }
114
- };
115
- }, [node, ownerDocument, disableOutsidePointerEvents, context]);
116
- React2.useEffect(() => {
117
- return () => {
118
- if (!node) return;
119
- context.layers.delete(node);
120
- context.layersWithOutsidePointerEventsDisabled.delete(node);
121
- dispatchUpdate();
122
- };
123
- }, [node, context]);
124
- React2.useEffect(() => {
125
- const handleUpdate = () => force({});
126
- document.addEventListener(CONTEXT_UPDATE, handleUpdate);
127
- return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);
128
- }, []);
129
- return (0, import_jsx_runtime.jsx)(
130
- Primitive.div,
131
- {
132
- ...layerProps,
133
- ref: composedRefs,
134
- style: {
135
- pointerEvents: isBodyPointerEventsDisabled ? isPointerEventsEnabled ? "auto" : "none" : void 0,
136
- ...props.style
137
- },
138
- onFocusCapture: composeEventHandlers(props.onFocusCapture, focusOutside.onFocusCapture),
139
- onBlurCapture: composeEventHandlers(props.onBlurCapture, focusOutside.onBlurCapture),
140
- onPointerDownCapture: composeEventHandlers(
141
- props.onPointerDownCapture,
142
- pointerDownOutside.onPointerDownCapture
143
- )
144
- }
145
- );
146
- }
147
- );
148
- DismissableLayer.displayName = DISMISSABLE_LAYER_NAME;
149
- var BRANCH_NAME = "DismissableLayerBranch";
150
- var DismissableLayerBranch = React2.forwardRef((props, forwardedRef) => {
151
- const context = React2.useContext(DismissableLayerContext);
152
- const ref = React2.useRef(null);
153
- const composedRefs = useComposedRefs(forwardedRef, ref);
154
- React2.useEffect(() => {
155
- const node = ref.current;
156
- if (node) {
157
- context.branches.add(node);
158
- return () => {
159
- context.branches.delete(node);
160
- };
161
- }
162
- }, [context.branches]);
163
- return (0, import_jsx_runtime.jsx)(Primitive.div, { ...props, ref: composedRefs });
164
- });
165
- DismissableLayerBranch.displayName = BRANCH_NAME;
166
- function usePointerDownOutside(onPointerDownOutside, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
167
- const handlePointerDownOutside = useCallbackRef(onPointerDownOutside);
168
- const isPointerInsideReactTreeRef = React2.useRef(false);
169
- const handleClickRef = React2.useRef(() => {
170
- });
171
- React2.useEffect(() => {
172
- const handlePointerDown = (event) => {
173
- if (event.target && !isPointerInsideReactTreeRef.current) {
174
- let handleAndDispatchPointerDownOutsideEvent2 = function() {
175
- handleAndDispatchCustomEvent(
176
- POINTER_DOWN_OUTSIDE,
177
- handlePointerDownOutside,
178
- eventDetail,
179
- { discrete: true }
180
- );
181
- };
182
- var handleAndDispatchPointerDownOutsideEvent = handleAndDispatchPointerDownOutsideEvent2;
183
- const eventDetail = { originalEvent: event };
184
- if (event.pointerType === "touch") {
185
- ownerDocument.removeEventListener("click", handleClickRef.current);
186
- handleClickRef.current = handleAndDispatchPointerDownOutsideEvent2;
187
- ownerDocument.addEventListener("click", handleClickRef.current, { once: true });
188
- } else {
189
- handleAndDispatchPointerDownOutsideEvent2();
190
- }
191
- } else {
192
- ownerDocument.removeEventListener("click", handleClickRef.current);
193
- }
194
- isPointerInsideReactTreeRef.current = false;
195
- };
196
- const timerId = window.setTimeout(() => {
197
- ownerDocument.addEventListener("pointerdown", handlePointerDown);
198
- }, 0);
199
- return () => {
200
- window.clearTimeout(timerId);
201
- ownerDocument.removeEventListener("pointerdown", handlePointerDown);
202
- ownerDocument.removeEventListener("click", handleClickRef.current);
203
- };
204
- }, [ownerDocument, handlePointerDownOutside]);
205
- return {
206
- // ensures we check React component tree (not just DOM tree)
207
- onPointerDownCapture: () => isPointerInsideReactTreeRef.current = true
208
- };
209
- }
210
- function useFocusOutside(onFocusOutside, ownerDocument = globalThis == null ? void 0 : globalThis.document) {
211
- const handleFocusOutside = useCallbackRef(onFocusOutside);
212
- const isFocusInsideReactTreeRef = React2.useRef(false);
213
- React2.useEffect(() => {
214
- const handleFocus = (event) => {
215
- if (event.target && !isFocusInsideReactTreeRef.current) {
216
- const eventDetail = { originalEvent: event };
217
- handleAndDispatchCustomEvent(FOCUS_OUTSIDE, handleFocusOutside, eventDetail, {
218
- discrete: false
219
- });
220
- }
221
- };
222
- ownerDocument.addEventListener("focusin", handleFocus);
223
- return () => ownerDocument.removeEventListener("focusin", handleFocus);
224
- }, [ownerDocument, handleFocusOutside]);
225
- return {
226
- onFocusCapture: () => isFocusInsideReactTreeRef.current = true,
227
- onBlurCapture: () => isFocusInsideReactTreeRef.current = false
228
- };
229
- }
230
- function dispatchUpdate() {
231
- const event = new CustomEvent(CONTEXT_UPDATE);
232
- document.dispatchEvent(event);
233
- }
234
- function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
235
- const target = detail.originalEvent.target;
236
- const event = new CustomEvent(name, { bubbles: false, cancelable: true, detail });
237
- if (handler) target.addEventListener(name, handler, { once: true });
238
- if (discrete) {
239
- dispatchDiscreteCustomEvent(target, event);
240
- } else {
241
- target.dispatchEvent(event);
242
- }
243
- }
244
-
245
- // ../../node_modules/@radix-ui/react-portal/dist/index.mjs
246
- var React3 = __toESM(require_react(), 1);
247
- var import_react_dom = __toESM(require_react_dom(), 1);
248
- var import_jsx_runtime2 = __toESM(require_jsx_runtime(), 1);
249
- var PORTAL_NAME = "Portal";
250
- var Portal = React3.forwardRef((props, forwardedRef) => {
251
- var _a;
252
- const { container: containerProp, ...portalProps } = props;
253
- const [mounted, setMounted] = React3.useState(false);
254
- useLayoutEffect2(() => setMounted(true), []);
255
- const container = containerProp || mounted && ((_a = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : _a.body);
256
- return container ? import_react_dom.default.createPortal((0, import_jsx_runtime2.jsx)(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;
257
- });
258
- Portal.displayName = PORTAL_NAME;
259
-
260
- export {
261
- DismissableLayer,
262
- Portal
263
- };
264
- //# sourceMappingURL=chunk-YEUURE4V.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../node_modules/@radix-ui/react-dismissable-layer/src/dismissable-layer.tsx", "../../../../../node_modules/@radix-ui/react-use-escape-keydown/src/use-escape-keydown.tsx", "../../../../../node_modules/@radix-ui/react-portal/src/portal.tsx"],
4
- "sourcesContent": ["import * as React from 'react';\nimport { composeEventHandlers } from '@radix-ui/primitive';\nimport { Primitive, dispatchDiscreteCustomEvent } from '@radix-ui/react-primitive';\nimport { useComposedRefs } from '@radix-ui/react-compose-refs';\nimport { useCallbackRef } from '@radix-ui/react-use-callback-ref';\nimport { useEscapeKeydown } from '@radix-ui/react-use-escape-keydown';\n\n/* -------------------------------------------------------------------------------------------------\n * DismissableLayer\n * -----------------------------------------------------------------------------------------------*/\n\nconst DISMISSABLE_LAYER_NAME = 'DismissableLayer';\nconst CONTEXT_UPDATE = 'dismissableLayer.update';\nconst POINTER_DOWN_OUTSIDE = 'dismissableLayer.pointerDownOutside';\nconst FOCUS_OUTSIDE = 'dismissableLayer.focusOutside';\n\nlet originalBodyPointerEvents: string;\n\nconst DismissableLayerContext = React.createContext({\n layers: new Set<DismissableLayerElement>(),\n layersWithOutsidePointerEventsDisabled: new Set<DismissableLayerElement>(),\n branches: new Set<DismissableLayerBranchElement>(),\n});\n\ntype DismissableLayerElement = React.ComponentRef<typeof Primitive.div>;\ntype PrimitiveDivProps = React.ComponentPropsWithoutRef<typeof Primitive.div>;\ninterface DismissableLayerProps extends PrimitiveDivProps {\n /**\n * When `true`, hover/focus/click interactions will be disabled on elements outside\n * the `DismissableLayer`. Users will need to click twice on outside elements to\n * interact with them: once to close the `DismissableLayer`, and again to trigger the element.\n */\n disableOutsidePointerEvents?: boolean;\n /**\n * Event handler called when the escape key is down.\n * Can be prevented.\n */\n onEscapeKeyDown?: (event: KeyboardEvent) => void;\n /**\n * Event handler called when the a `pointerdown` event happens outside of the `DismissableLayer`.\n * Can be prevented.\n */\n onPointerDownOutside?: (event: PointerDownOutsideEvent) => void;\n /**\n * Event handler called when the focus moves outside of the `DismissableLayer`.\n * Can be prevented.\n */\n onFocusOutside?: (event: FocusOutsideEvent) => void;\n /**\n * Event handler called when an interaction happens outside the `DismissableLayer`.\n * Specifically, when a `pointerdown` event happens outside or focus moves outside of it.\n * Can be prevented.\n */\n onInteractOutside?: (event: PointerDownOutsideEvent | FocusOutsideEvent) => void;\n /**\n * Handler called when the `DismissableLayer` should be dismissed\n */\n onDismiss?: () => void;\n}\n\nconst DismissableLayer = React.forwardRef<DismissableLayerElement, DismissableLayerProps>(\n (props, forwardedRef) => {\n const {\n disableOutsidePointerEvents = false,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n ...layerProps\n } = props;\n const context = React.useContext(DismissableLayerContext);\n const [node, setNode] = React.useState<DismissableLayerElement | null>(null);\n const ownerDocument = node?.ownerDocument ?? globalThis?.document;\n const [, force] = React.useState({});\n const composedRefs = useComposedRefs(forwardedRef, (node) => setNode(node));\n const layers = Array.from(context.layers);\n const [highestLayerWithOutsidePointerEventsDisabled] = [...context.layersWithOutsidePointerEventsDisabled].slice(-1); // prettier-ignore\n const highestLayerWithOutsidePointerEventsDisabledIndex = layers.indexOf(highestLayerWithOutsidePointerEventsDisabled!); // prettier-ignore\n const index = node ? layers.indexOf(node) : -1;\n const isBodyPointerEventsDisabled = context.layersWithOutsidePointerEventsDisabled.size > 0;\n const isPointerEventsEnabled = index >= highestLayerWithOutsidePointerEventsDisabledIndex;\n\n const pointerDownOutside = usePointerDownOutside((event) => {\n const target = event.target as HTMLElement;\n const isPointerDownOnBranch = [...context.branches].some((branch) => branch.contains(target));\n if (!isPointerEventsEnabled || isPointerDownOnBranch) return;\n onPointerDownOutside?.(event);\n onInteractOutside?.(event);\n if (!event.defaultPrevented) onDismiss?.();\n }, ownerDocument);\n\n const focusOutside = useFocusOutside((event) => {\n const target = event.target as HTMLElement;\n const isFocusInBranch = [...context.branches].some((branch) => branch.contains(target));\n if (isFocusInBranch) return;\n onFocusOutside?.(event);\n onInteractOutside?.(event);\n if (!event.defaultPrevented) onDismiss?.();\n }, ownerDocument);\n\n useEscapeKeydown((event) => {\n const isHighestLayer = index === context.layers.size - 1;\n if (!isHighestLayer) return;\n onEscapeKeyDown?.(event);\n if (!event.defaultPrevented && onDismiss) {\n event.preventDefault();\n onDismiss();\n }\n }, ownerDocument);\n\n React.useEffect(() => {\n if (!node) return;\n if (disableOutsidePointerEvents) {\n if (context.layersWithOutsidePointerEventsDisabled.size === 0) {\n originalBodyPointerEvents = ownerDocument.body.style.pointerEvents;\n ownerDocument.body.style.pointerEvents = 'none';\n }\n context.layersWithOutsidePointerEventsDisabled.add(node);\n }\n context.layers.add(node);\n dispatchUpdate();\n return () => {\n if (\n disableOutsidePointerEvents &&\n context.layersWithOutsidePointerEventsDisabled.size === 1\n ) {\n ownerDocument.body.style.pointerEvents = originalBodyPointerEvents;\n }\n };\n }, [node, ownerDocument, disableOutsidePointerEvents, context]);\n\n /**\n * We purposefully prevent combining this effect with the `disableOutsidePointerEvents` effect\n * because a change to `disableOutsidePointerEvents` would remove this layer from the stack\n * and add it to the end again so the layering order wouldn't be _creation order_.\n * We only want them to be removed from context stacks when unmounted.\n */\n React.useEffect(() => {\n return () => {\n if (!node) return;\n context.layers.delete(node);\n context.layersWithOutsidePointerEventsDisabled.delete(node);\n dispatchUpdate();\n };\n }, [node, context]);\n\n React.useEffect(() => {\n const handleUpdate = () => force({});\n document.addEventListener(CONTEXT_UPDATE, handleUpdate);\n return () => document.removeEventListener(CONTEXT_UPDATE, handleUpdate);\n }, []);\n\n return (\n <Primitive.div\n {...layerProps}\n ref={composedRefs}\n style={{\n pointerEvents: isBodyPointerEventsDisabled\n ? isPointerEventsEnabled\n ? 'auto'\n : 'none'\n : undefined,\n ...props.style,\n }}\n onFocusCapture={composeEventHandlers(props.onFocusCapture, focusOutside.onFocusCapture)}\n onBlurCapture={composeEventHandlers(props.onBlurCapture, focusOutside.onBlurCapture)}\n onPointerDownCapture={composeEventHandlers(\n props.onPointerDownCapture,\n pointerDownOutside.onPointerDownCapture\n )}\n />\n );\n }\n);\n\nDismissableLayer.displayName = DISMISSABLE_LAYER_NAME;\n\n/* -------------------------------------------------------------------------------------------------\n * DismissableLayerBranch\n * -----------------------------------------------------------------------------------------------*/\n\nconst BRANCH_NAME = 'DismissableLayerBranch';\n\ntype DismissableLayerBranchElement = React.ComponentRef<typeof Primitive.div>;\ninterface DismissableLayerBranchProps extends PrimitiveDivProps {}\n\nconst DismissableLayerBranch = React.forwardRef<\n DismissableLayerBranchElement,\n DismissableLayerBranchProps\n>((props, forwardedRef) => {\n const context = React.useContext(DismissableLayerContext);\n const ref = React.useRef<DismissableLayerBranchElement>(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n\n React.useEffect(() => {\n const node = ref.current;\n if (node) {\n context.branches.add(node);\n return () => {\n context.branches.delete(node);\n };\n }\n }, [context.branches]);\n\n return <Primitive.div {...props} ref={composedRefs} />;\n});\n\nDismissableLayerBranch.displayName = BRANCH_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\ntype PointerDownOutsideEvent = CustomEvent<{ originalEvent: PointerEvent }>;\ntype FocusOutsideEvent = CustomEvent<{ originalEvent: FocusEvent }>;\n\n/**\n * Listens for `pointerdown` outside a react subtree. We use `pointerdown` rather than `pointerup`\n * to mimic layer dismissing behaviour present in OS.\n * Returns props to pass to the node we want to check for outside events.\n */\nfunction usePointerDownOutside(\n onPointerDownOutside?: (event: PointerDownOutsideEvent) => void,\n ownerDocument: Document = globalThis?.document\n) {\n const handlePointerDownOutside = useCallbackRef(onPointerDownOutside) as EventListener;\n const isPointerInsideReactTreeRef = React.useRef(false);\n const handleClickRef = React.useRef(() => {});\n\n React.useEffect(() => {\n const handlePointerDown = (event: PointerEvent) => {\n if (event.target && !isPointerInsideReactTreeRef.current) {\n const eventDetail = { originalEvent: event };\n\n function handleAndDispatchPointerDownOutsideEvent() {\n handleAndDispatchCustomEvent(\n POINTER_DOWN_OUTSIDE,\n handlePointerDownOutside,\n eventDetail,\n { discrete: true }\n );\n }\n\n /**\n * On touch devices, we need to wait for a click event because browsers implement\n * a ~350ms delay between the time the user stops touching the display and when the\n * browser executres events. We need to ensure we don't reactivate pointer-events within\n * this timeframe otherwise the browser may execute events that should have been prevented.\n *\n * Additionally, this also lets us deal automatically with cancellations when a click event\n * isn't raised because the page was considered scrolled/drag-scrolled, long-pressed, etc.\n *\n * This is why we also continuously remove the previous listener, because we cannot be\n * certain that it was raised, and therefore cleaned-up.\n */\n if (event.pointerType === 'touch') {\n ownerDocument.removeEventListener('click', handleClickRef.current);\n handleClickRef.current = handleAndDispatchPointerDownOutsideEvent;\n ownerDocument.addEventListener('click', handleClickRef.current, { once: true });\n } else {\n handleAndDispatchPointerDownOutsideEvent();\n }\n } else {\n // We need to remove the event listener in case the outside click has been canceled.\n // See: https://github.com/radix-ui/primitives/issues/2171\n ownerDocument.removeEventListener('click', handleClickRef.current);\n }\n isPointerInsideReactTreeRef.current = false;\n };\n /**\n * if this hook executes in a component that mounts via a `pointerdown` event, the event\n * would bubble up to the document and trigger a `pointerDownOutside` event. We avoid\n * this by delaying the event listener registration on the document.\n * This is not React specific, but rather how the DOM works, ie:\n * ```\n * button.addEventListener('pointerdown', () => {\n * console.log('I will log');\n * document.addEventListener('pointerdown', () => {\n * console.log('I will also log');\n * })\n * });\n */\n const timerId = window.setTimeout(() => {\n ownerDocument.addEventListener('pointerdown', handlePointerDown);\n }, 0);\n return () => {\n window.clearTimeout(timerId);\n ownerDocument.removeEventListener('pointerdown', handlePointerDown);\n ownerDocument.removeEventListener('click', handleClickRef.current);\n };\n }, [ownerDocument, handlePointerDownOutside]);\n\n return {\n // ensures we check React component tree (not just DOM tree)\n onPointerDownCapture: () => (isPointerInsideReactTreeRef.current = true),\n };\n}\n\n/**\n * Listens for when focus happens outside a react subtree.\n * Returns props to pass to the root (node) of the subtree we want to check.\n */\nfunction useFocusOutside(\n onFocusOutside?: (event: FocusOutsideEvent) => void,\n ownerDocument: Document = globalThis?.document\n) {\n const handleFocusOutside = useCallbackRef(onFocusOutside) as EventListener;\n const isFocusInsideReactTreeRef = React.useRef(false);\n\n React.useEffect(() => {\n const handleFocus = (event: FocusEvent) => {\n if (event.target && !isFocusInsideReactTreeRef.current) {\n const eventDetail = { originalEvent: event };\n handleAndDispatchCustomEvent(FOCUS_OUTSIDE, handleFocusOutside, eventDetail, {\n discrete: false,\n });\n }\n };\n ownerDocument.addEventListener('focusin', handleFocus);\n return () => ownerDocument.removeEventListener('focusin', handleFocus);\n }, [ownerDocument, handleFocusOutside]);\n\n return {\n onFocusCapture: () => (isFocusInsideReactTreeRef.current = true),\n onBlurCapture: () => (isFocusInsideReactTreeRef.current = false),\n };\n}\n\nfunction dispatchUpdate() {\n const event = new CustomEvent(CONTEXT_UPDATE);\n document.dispatchEvent(event);\n}\n\nfunction handleAndDispatchCustomEvent<E extends CustomEvent, OriginalEvent extends Event>(\n name: string,\n handler: ((event: E) => void) | undefined,\n detail: { originalEvent: OriginalEvent } & (E extends CustomEvent<infer D> ? D : never),\n { discrete }: { discrete: boolean }\n) {\n const target = detail.originalEvent.target;\n const event = new CustomEvent(name, { bubbles: false, cancelable: true, detail });\n if (handler) target.addEventListener(name, handler as EventListener, { once: true });\n\n if (discrete) {\n dispatchDiscreteCustomEvent(target, event);\n } else {\n target.dispatchEvent(event);\n }\n}\n\nconst Root = DismissableLayer;\nconst Branch = DismissableLayerBranch;\n\nexport {\n DismissableLayer,\n DismissableLayerBranch,\n //\n Root,\n Branch,\n};\nexport type { DismissableLayerProps };\n", "import * as React from 'react';\nimport { useCallbackRef } from '@radix-ui/react-use-callback-ref';\n\n/**\n * Listens for when the escape key is down\n */\nfunction useEscapeKeydown(\n onEscapeKeyDownProp?: (event: KeyboardEvent) => void,\n ownerDocument: Document = globalThis?.document\n) {\n const onEscapeKeyDown = useCallbackRef(onEscapeKeyDownProp);\n\n React.useEffect(() => {\n const handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'Escape') {\n onEscapeKeyDown(event);\n }\n };\n ownerDocument.addEventListener('keydown', handleKeyDown, { capture: true });\n return () => ownerDocument.removeEventListener('keydown', handleKeyDown, { capture: true });\n }, [onEscapeKeyDown, ownerDocument]);\n}\n\nexport { useEscapeKeydown };\n", "import * as React from 'react';\nimport ReactDOM from 'react-dom';\nimport { Primitive } from '@radix-ui/react-primitive';\nimport { useLayoutEffect } from '@radix-ui/react-use-layout-effect';\n\n/* -------------------------------------------------------------------------------------------------\n * Portal\n * -----------------------------------------------------------------------------------------------*/\n\nconst PORTAL_NAME = 'Portal';\n\ntype PortalElement = React.ComponentRef<typeof Primitive.div>;\ntype PrimitiveDivProps = React.ComponentPropsWithoutRef<typeof Primitive.div>;\ninterface PortalProps extends PrimitiveDivProps {\n /**\n * An optional container where the portaled content should be appended.\n */\n container?: Element | DocumentFragment | null;\n}\n\nconst Portal = React.forwardRef<PortalElement, PortalProps>((props, forwardedRef) => {\n const { container: containerProp, ...portalProps } = props;\n const [mounted, setMounted] = React.useState(false);\n useLayoutEffect(() => setMounted(true), []);\n const container = containerProp || (mounted && globalThis?.document?.body);\n return container\n ? ReactDOM.createPortal(<Primitive.div {...portalProps} ref={forwardedRef} />, container)\n : null;\n});\n\nPortal.displayName = PORTAL_NAME;\n\n/* -----------------------------------------------------------------------------------------------*/\n\nconst Root = Portal;\n\nexport {\n Portal,\n //\n Root,\n};\nexport type { PortalProps };\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,SAAuB;;;ACAvB,YAAuB;AAMvB,SAAS,iBACP,qBACA,gBAA0B,yCAAY,UACtC;AACA,QAAM,kBAAkB,eAAe,mBAAmB;AAEpD,EAAA,gBAAU,MAAM;AACpB,UAAM,gBAAgB,CAAC,UAAyB;AAC9C,UAAI,MAAM,QAAQ,UAAU;AAC1B,wBAAgB,KAAK;MACvB;IACF;AACA,kBAAc,iBAAiB,WAAW,eAAe,EAAE,SAAS,KAAK,CAAC;AAC1E,WAAO,MAAM,cAAc,oBAAoB,WAAW,eAAe,EAAE,SAAS,KAAK,CAAC;EAC5F,GAAG,CAAC,iBAAiB,aAAa,CAAC;AACrC;;;ADqIM,yBAAA;AA/IN,IAAM,yBAAyB;AAC/B,IAAM,iBAAiB;AACvB,IAAM,uBAAuB;AAC7B,IAAM,gBAAgB;AAEtB,IAAI;AAEJ,IAAM,0BAAgC,qBAAc;EAClD,QAAQ,oBAAI,IAA6B;EACzC,wCAAwC,oBAAI,IAA6B;EACzE,UAAU,oBAAI,IAAmC;AACnD,CAAC;AAsCD,IAAM,mBAAyB;EAC7B,CAAC,OAAO,iBAAiB;AACvB,UAAM;MACJ,8BAA8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