@e-llm-studio/citation 0.0.68 → 0.0.69
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.
- package/dist/_virtual/index10.js +1 -1
- package/dist/_virtual/index3.js +1 -1
- package/dist/_virtual/index4.js +1 -1
- package/dist/_virtual/index5.js +1 -1
- package/dist/_virtual/index6.js +1 -1
- package/dist/_virtual/index8.js +1 -1
- package/dist/_virtual/index9.js +1 -1
- package/dist/cjs/_virtual/index10.js +1 -1
- package/dist/cjs/_virtual/index3.js +1 -1
- package/dist/cjs/_virtual/index4.js +1 -1
- package/dist/cjs/_virtual/index5.js +1 -1
- package/dist/cjs/_virtual/index6.js +1 -1
- package/dist/cjs/_virtual/index8.js +1 -1
- package/dist/cjs/_virtual/index9.js +1 -1
- package/dist/cjs/features/Bookemon/BookOverviewCard/BookOverviewCard.js +1 -1
- package/dist/cjs/features/Bookemon/BookPreview/BookPreview.js +1 -1
- package/dist/cjs/node_modules/@material-ui/icons/utils/createSvgIcon.js +1 -1
- package/dist/cjs/node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js +1 -1
- package/dist/cjs/node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js +1 -1
- package/dist/cjs/node_modules/hoist-non-react-statics/node_modules/react-is/index.js +1 -1
- package/dist/cjs/node_modules/hoist-non-react-statics/node_modules/react-is/index.js.map +1 -1
- package/dist/cjs/node_modules/prop-types/index.js +1 -1
- package/dist/cjs/node_modules/prop-types/node_modules/react-is/index.js +1 -1
- package/dist/cjs/node_modules/react-is/index.js +1 -1
- package/dist/cjs/node_modules/react-markdown/lib/ast-to-react.js +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/react-is/cjs/react-is.development.js +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/react-is/cjs/react-is.production.min.js +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/react-is/index.js +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/unified/lib/index.js +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/unified/lib/index.js.map +1 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/vfile/lib/index.js +1 -1
- package/dist/features/Bookemon/BookOverviewCard/BookOverviewCard.js +1 -1
- package/dist/features/Bookemon/BookPreview/BookPreview.js +1 -1
- package/dist/node_modules/@material-ui/icons/utils/createSvgIcon.js +1 -1
- package/dist/node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.development.js +1 -1
- package/dist/node_modules/hoist-non-react-statics/node_modules/react-is/cjs/react-is.production.min.js +1 -1
- package/dist/node_modules/hoist-non-react-statics/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/hoist-non-react-statics/node_modules/react-is/index.js.map +1 -1
- package/dist/node_modules/prop-types/index.js +1 -1
- package/dist/node_modules/prop-types/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-markdown/lib/ast-to-react.js +1 -1
- package/dist/node_modules/react-markdown/node_modules/react-is/cjs/react-is.development.js +1 -1
- package/dist/node_modules/react-markdown/node_modules/react-is/cjs/react-is.production.min.js +1 -1
- package/dist/node_modules/react-markdown/node_modules/react-is/index.js +1 -1
- package/dist/node_modules/react-markdown/node_modules/unified/lib/index.js +1 -1
- package/dist/node_modules/react-markdown/node_modules/unified/lib/index.js.map +1 -1
- package/dist/node_modules/react-markdown/node_modules/vfile/lib/index.js +1 -1
- package/dist/types/src/BookemonTest.d.ts.map +1 -1
- package/dist/types/src/features/Bookemon/BookOverviewCard/BookOverviewCard.d.ts +2 -0
- package/dist/types/src/features/Bookemon/BookOverviewCard/BookOverviewCard.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/_virtual/browser.js +0 -2
- package/dist/_virtual/browser.js.map +0 -1
- package/dist/_virtual/form_data.js +0 -2
- package/dist/_virtual/form_data.js.map +0 -1
- package/dist/_virtual/index14.js +0 -2
- package/dist/_virtual/index14.js.map +0 -1
- package/dist/_virtual/index15.js +0 -2
- package/dist/_virtual/index15.js.map +0 -1
- package/dist/_virtual/index16.js +0 -2
- package/dist/_virtual/index16.js.map +0 -1
- package/dist/_virtual/index17.js +0 -2
- package/dist/_virtual/index17.js.map +0 -1
- package/dist/_virtual/index18.js +0 -2
- package/dist/_virtual/index18.js.map +0 -1
- package/dist/_virtual/index19.js +0 -2
- package/dist/_virtual/index19.js.map +0 -1
- package/dist/_virtual/node.js +0 -2
- package/dist/_virtual/node.js.map +0 -1
- package/dist/_virtual/serialOrdered.js +0 -2
- package/dist/_virtual/serialOrdered.js.map +0 -1
- package/dist/cjs/_virtual/browser.js +0 -2
- package/dist/cjs/_virtual/browser.js.map +0 -1
- package/dist/cjs/_virtual/form_data.js +0 -2
- package/dist/cjs/_virtual/form_data.js.map +0 -1
- package/dist/cjs/_virtual/index14.js +0 -2
- package/dist/cjs/_virtual/index14.js.map +0 -1
- package/dist/cjs/_virtual/index15.js +0 -2
- package/dist/cjs/_virtual/index15.js.map +0 -1
- package/dist/cjs/_virtual/index16.js +0 -2
- package/dist/cjs/_virtual/index16.js.map +0 -1
- package/dist/cjs/_virtual/index17.js +0 -2
- package/dist/cjs/_virtual/index17.js.map +0 -1
- package/dist/cjs/_virtual/index18.js +0 -2
- package/dist/cjs/_virtual/index18.js.map +0 -1
- package/dist/cjs/_virtual/index19.js +0 -2
- package/dist/cjs/_virtual/index19.js.map +0 -1
- package/dist/cjs/_virtual/node.js +0 -2
- package/dist/cjs/_virtual/node.js.map +0 -1
- package/dist/cjs/_virtual/serialOrdered.js +0 -2
- package/dist/cjs/_virtual/serialOrdered.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/index.js +0 -2
- package/dist/cjs/node_modules/asynckit/index.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/abort.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/abort.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/async.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/async.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/defer.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/defer.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/iterate.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/iterate.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/state.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/state.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/lib/terminator.js +0 -2
- package/dist/cjs/node_modules/asynckit/lib/terminator.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/parallel.js +0 -2
- package/dist/cjs/node_modules/asynckit/parallel.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/serial.js +0 -2
- package/dist/cjs/node_modules/asynckit/serial.js.map +0 -1
- package/dist/cjs/node_modules/asynckit/serialOrdered.js +0 -2
- package/dist/cjs/node_modules/asynckit/serialOrdered.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/adapters/http.js +0 -2
- package/dist/cjs/node_modules/axios/lib/adapters/http.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/AxiosTransformStream.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/AxiosTransformStream.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/callbackify.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/callbackify.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/formDataToStream.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/formDataToStream.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/fromDataURI.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/fromDataURI.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/helpers/readBlob.js +0 -2
- package/dist/cjs/node_modules/axios/lib/helpers/readBlob.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/platform/node/classes/FormData.js +0 -2
- package/dist/cjs/node_modules/axios/lib/platform/node/classes/FormData.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/platform/node/classes/URLSearchParams.js +0 -2
- package/dist/cjs/node_modules/axios/lib/platform/node/classes/URLSearchParams.js.map +0 -1
- package/dist/cjs/node_modules/axios/lib/platform/node/index.js +0 -2
- package/dist/cjs/node_modules/axios/lib/platform/node/index.js.map +0 -1
- package/dist/cjs/node_modules/combined-stream/lib/combined_stream.js +0 -2
- package/dist/cjs/node_modules/combined-stream/lib/combined_stream.js.map +0 -1
- package/dist/cjs/node_modules/debug/src/browser.js +0 -2
- package/dist/cjs/node_modules/debug/src/browser.js.map +0 -1
- package/dist/cjs/node_modules/debug/src/common.js +0 -2
- package/dist/cjs/node_modules/debug/src/common.js.map +0 -1
- package/dist/cjs/node_modules/debug/src/index.js +0 -2
- package/dist/cjs/node_modules/debug/src/index.js.map +0 -1
- package/dist/cjs/node_modules/debug/src/node.js +0 -2
- package/dist/cjs/node_modules/debug/src/node.js.map +0 -1
- package/dist/cjs/node_modules/decode-named-character-reference/index.js +0 -2
- package/dist/cjs/node_modules/decode-named-character-reference/index.js.map +0 -1
- package/dist/cjs/node_modules/decode-named-character-reference/node_modules/character-entities/index.js +0 -2
- package/dist/cjs/node_modules/decode-named-character-reference/node_modules/character-entities/index.js.map +0 -1
- package/dist/cjs/node_modules/delayed-stream/lib/delayed_stream.js +0 -2
- package/dist/cjs/node_modules/delayed-stream/lib/delayed_stream.js.map +0 -1
- package/dist/cjs/node_modules/follow-redirects/debug.js +0 -2
- package/dist/cjs/node_modules/follow-redirects/debug.js.map +0 -1
- package/dist/cjs/node_modules/follow-redirects/index.js +0 -2
- package/dist/cjs/node_modules/follow-redirects/index.js.map +0 -1
- package/dist/cjs/node_modules/form-data/lib/form_data.js +0 -2
- package/dist/cjs/node_modules/form-data/lib/form_data.js.map +0 -1
- package/dist/cjs/node_modules/form-data/lib/populate.js +0 -2
- package/dist/cjs/node_modules/form-data/lib/populate.js.map +0 -1
- package/dist/cjs/node_modules/has-flag/index.js +0 -2
- package/dist/cjs/node_modules/has-flag/index.js.map +0 -1
- package/dist/cjs/node_modules/mdast-util-definitions/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/cjs/node_modules/mdast-util-definitions/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/cjs/node_modules/mdast-util-to-hast/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/cjs/node_modules/mdast-util-to-hast/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/cjs/node_modules/mime-db/db.json.js +0 -2
- package/dist/cjs/node_modules/mime-db/db.json.js.map +0 -1
- package/dist/cjs/node_modules/mime-db/index.js +0 -8
- package/dist/cjs/node_modules/mime-db/index.js.map +0 -1
- package/dist/cjs/node_modules/mime-types/index.js +0 -8
- package/dist/cjs/node_modules/mime-types/index.js.map +0 -1
- package/dist/cjs/node_modules/ms/index.js +0 -2
- package/dist/cjs/node_modules/ms/index.js.map +0 -1
- package/dist/cjs/node_modules/proxy-from-env/index.js +0 -2
- package/dist/cjs/node_modules/proxy-from-env/index.js.map +0 -1
- package/dist/cjs/node_modules/react-markdown/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/cjs/node_modules/react-markdown/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/cjs/node_modules/react-resizable-panels/dist/react-resizable-panels.js +0 -2
- package/dist/cjs/node_modules/react-resizable-panels/dist/react-resizable-panels.js.map +0 -1
- package/dist/cjs/node_modules/supports-color/index.js +0 -2
- package/dist/cjs/node_modules/supports-color/index.js.map +0 -1
- package/dist/node_modules/asynckit/index.js +0 -2
- package/dist/node_modules/asynckit/index.js.map +0 -1
- package/dist/node_modules/asynckit/lib/abort.js +0 -2
- package/dist/node_modules/asynckit/lib/abort.js.map +0 -1
- package/dist/node_modules/asynckit/lib/async.js +0 -2
- package/dist/node_modules/asynckit/lib/async.js.map +0 -1
- package/dist/node_modules/asynckit/lib/defer.js +0 -2
- package/dist/node_modules/asynckit/lib/defer.js.map +0 -1
- package/dist/node_modules/asynckit/lib/iterate.js +0 -2
- package/dist/node_modules/asynckit/lib/iterate.js.map +0 -1
- package/dist/node_modules/asynckit/lib/state.js +0 -2
- package/dist/node_modules/asynckit/lib/state.js.map +0 -1
- package/dist/node_modules/asynckit/lib/terminator.js +0 -2
- package/dist/node_modules/asynckit/lib/terminator.js.map +0 -1
- package/dist/node_modules/asynckit/parallel.js +0 -2
- package/dist/node_modules/asynckit/parallel.js.map +0 -1
- package/dist/node_modules/asynckit/serial.js +0 -2
- package/dist/node_modules/asynckit/serial.js.map +0 -1
- package/dist/node_modules/asynckit/serialOrdered.js +0 -2
- package/dist/node_modules/asynckit/serialOrdered.js.map +0 -1
- package/dist/node_modules/axios/lib/adapters/http.js +0 -2
- package/dist/node_modules/axios/lib/adapters/http.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/AxiosTransformStream.js +0 -2
- package/dist/node_modules/axios/lib/helpers/AxiosTransformStream.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js +0 -2
- package/dist/node_modules/axios/lib/helpers/ZlibHeaderTransformStream.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/callbackify.js +0 -2
- package/dist/node_modules/axios/lib/helpers/callbackify.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/formDataToStream.js +0 -2
- package/dist/node_modules/axios/lib/helpers/formDataToStream.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/fromDataURI.js +0 -2
- package/dist/node_modules/axios/lib/helpers/fromDataURI.js.map +0 -1
- package/dist/node_modules/axios/lib/helpers/readBlob.js +0 -2
- package/dist/node_modules/axios/lib/helpers/readBlob.js.map +0 -1
- package/dist/node_modules/axios/lib/platform/node/classes/FormData.js +0 -2
- package/dist/node_modules/axios/lib/platform/node/classes/FormData.js.map +0 -1
- package/dist/node_modules/axios/lib/platform/node/classes/URLSearchParams.js +0 -2
- package/dist/node_modules/axios/lib/platform/node/classes/URLSearchParams.js.map +0 -1
- package/dist/node_modules/axios/lib/platform/node/index.js +0 -2
- package/dist/node_modules/axios/lib/platform/node/index.js.map +0 -1
- package/dist/node_modules/combined-stream/lib/combined_stream.js +0 -2
- package/dist/node_modules/combined-stream/lib/combined_stream.js.map +0 -1
- package/dist/node_modules/debug/src/browser.js +0 -2
- package/dist/node_modules/debug/src/browser.js.map +0 -1
- package/dist/node_modules/debug/src/common.js +0 -2
- package/dist/node_modules/debug/src/common.js.map +0 -1
- package/dist/node_modules/debug/src/index.js +0 -2
- package/dist/node_modules/debug/src/index.js.map +0 -1
- package/dist/node_modules/debug/src/node.js +0 -2
- package/dist/node_modules/debug/src/node.js.map +0 -1
- package/dist/node_modules/decode-named-character-reference/index.js +0 -2
- package/dist/node_modules/decode-named-character-reference/index.js.map +0 -1
- package/dist/node_modules/decode-named-character-reference/node_modules/character-entities/index.js +0 -2
- package/dist/node_modules/decode-named-character-reference/node_modules/character-entities/index.js.map +0 -1
- package/dist/node_modules/delayed-stream/lib/delayed_stream.js +0 -2
- package/dist/node_modules/delayed-stream/lib/delayed_stream.js.map +0 -1
- package/dist/node_modules/follow-redirects/debug.js +0 -2
- package/dist/node_modules/follow-redirects/debug.js.map +0 -1
- package/dist/node_modules/follow-redirects/index.js +0 -2
- package/dist/node_modules/follow-redirects/index.js.map +0 -1
- package/dist/node_modules/form-data/lib/form_data.js +0 -2
- package/dist/node_modules/form-data/lib/form_data.js.map +0 -1
- package/dist/node_modules/form-data/lib/populate.js +0 -2
- package/dist/node_modules/form-data/lib/populate.js.map +0 -1
- package/dist/node_modules/has-flag/index.js +0 -2
- package/dist/node_modules/has-flag/index.js.map +0 -1
- package/dist/node_modules/mdast-util-definitions/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/node_modules/mdast-util-definitions/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/node_modules/mdast-util-to-hast/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/node_modules/mdast-util-to-hast/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/node_modules/mime-db/db.json.js +0 -2
- package/dist/node_modules/mime-db/db.json.js.map +0 -1
- package/dist/node_modules/mime-db/index.js +0 -8
- package/dist/node_modules/mime-db/index.js.map +0 -1
- package/dist/node_modules/mime-types/index.js +0 -8
- package/dist/node_modules/mime-types/index.js.map +0 -1
- package/dist/node_modules/ms/index.js +0 -2
- package/dist/node_modules/ms/index.js.map +0 -1
- package/dist/node_modules/proxy-from-env/index.js +0 -2
- package/dist/node_modules/proxy-from-env/index.js.map +0 -1
- package/dist/node_modules/react-markdown/node_modules/unist-util-visit-parents/lib/color.js +0 -2
- package/dist/node_modules/react-markdown/node_modules/unist-util-visit-parents/lib/color.js.map +0 -1
- package/dist/node_modules/react-resizable-panels/dist/react-resizable-panels.js +0 -2
- package/dist/node_modules/react-resizable-panels/dist/react-resizable-panels.js.map +0 -1
- package/dist/node_modules/supports-color/index.js +0 -2
- package/dist/node_modules/supports-color/index.js.map +0 -1
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react");function n(e){if(e&&e.__esModule)return e;var n=Object.create(null);return e&&Object.keys(e).forEach((function(t){if("default"!==t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})}})),n.default=e,Object.freeze(n)}var t=n(e);const r="undefined"!=typeof window,o=e.createContext(null);o.displayName="PanelGroupContext";const a={group:"data-panel-group",groupDirection:"data-panel-group-direction",groupId:"data-panel-group-id",panel:"data-panel",panelCollapsible:"data-panel-collapsible",panelId:"data-panel-id",panelSize:"data-panel-size",resizeHandle:"data-resize-handle",resizeHandleActive:"data-resize-handle-active",resizeHandleEnabled:"data-panel-resize-handle-enabled",resizeHandleId:"data-panel-resize-handle-id",resizeHandleState:"data-resize-handle-state"},l=r?e.useLayoutEffect:()=>{},i=t["useId".toString()],u="function"==typeof i?i:()=>null;let s=0;function c(n=null){const t=u(),r=e.useRef(n||t||null);return null===r.current&&(r.current=""+s++),null!=n?n:r.current}function d({children:n,className:t="",collapsedSize:r,collapsible:i,defaultSize:u,forwardedRef:s,id:d,maxSize:f,minSize:p,onCollapse:g,onExpand:y,onResize:m,order:h,style:v,tagName:z="div",...b}){const x=e.useContext(o);if(null===x)throw Error("Panel components must be rendered within a PanelGroup container");const{collapsePanel:S,expandPanel:w,getPanelSize:I,getPanelStyle:E,groupId:P,isPanelCollapsed:C,reevaluatePanelConstraints:A,registerPanel:k,resizePanel:D,unregisterPanel:R}=x,L=c(d),$=e.useRef({callbacks:{onCollapse:g,onExpand:y,onResize:m},constraints:{collapsedSize:r,collapsible:i,defaultSize:u,maxSize:f,minSize:p},id:L,idIsFromProps:void 0!==d,order:h});e.useRef({didLogMissingDefaultSizeWarning:!1}),l((()=>{const{callbacks:e,constraints:n}=$.current,t={...n};$.current.id=L,$.current.idIsFromProps=void 0!==d,$.current.order=h,e.onCollapse=g,e.onExpand=y,e.onResize=m,n.collapsedSize=r,n.collapsible=i,n.defaultSize=u,n.maxSize=f,n.minSize=p,t.collapsedSize===n.collapsedSize&&t.collapsible===n.collapsible&&t.maxSize===n.maxSize&&t.minSize===n.minSize||A($.current,t)})),l((()=>{const e=$.current;return k(e),()=>{R(e)}}),[h,L,k,R]),e.useImperativeHandle(s,(()=>({collapse:()=>{S($.current)},expand:e=>{w($.current,e)},getId:()=>L,getSize:()=>I($.current),isCollapsed:()=>C($.current),isExpanded:()=>!C($.current),resize:e=>{D($.current,e)}})),[S,w,I,C,L,D]);const M=E($.current,u);return e.createElement(z,{...b,children:n,className:t,id:L,style:{...M,...v},[a.groupId]:P,[a.panel]:"",[a.panelCollapsible]:i||void 0,[a.panelId]:L,[a.panelSize]:parseFloat(""+M.flexGrow).toFixed(1)})}const f=e.forwardRef(((n,t)=>e.createElement(d,{...n,forwardedRef:t})));d.displayName="Panel",f.displayName="forwardRef(Panel)";let p=null,g=-1,y=null;function m(e,n,t){var r,o;const a=function(e,n){const t=!!(n&D),r=!!(n&R);if(n){if(n&A)return t?"se-resize":r?"ne-resize":"e-resize";if(n&k)return t?"sw-resize":r?"nw-resize":"w-resize";if(t)return"s-resize";if(r)return"n-resize"}switch(e){case"horizontal":return"ew-resize";case"intersection":return"move";case"vertical":return"ns-resize"}}(e,n);if(p!==a){var l;if(p=a,null===y&&(y=document.createElement("style"),document.head.appendChild(y)),g>=0)null===(l=y.sheet)||void 0===l||l.removeRule(g);g=null!==(r=null===(o=y.sheet)||void 0===o?void 0:o.insertRule(`*{cursor: ${a} !important;}`))&&void 0!==r?r:-1}}function h(e){return"keydown"===e.type}function v(e){return e.type.startsWith("pointer")}function z(e){return e.type.startsWith("mouse")}function b(e){if(v(e)){if(e.isPrimary)return{x:e.clientX,y:e.clientY}}else if(z(e))return{x:e.clientX,y:e.clientY};return{x:1/0,y:1/0}}function x(e,n,t){return t?e.x<n.x+n.width&&e.x+e.width>n.x&&e.y<n.y+n.height&&e.y+e.height>n.y:e.x<=n.x+n.width&&e.x+e.width>=n.x&&e.y<=n.y+n.height&&e.y+e.height>=n.y}const S=/\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\b/;function w(e){const n=getComputedStyle(e);return"fixed"===n.position||(!("auto"===n.zIndex||"static"===n.position&&!function(e){var n;const t=getComputedStyle(null!==(n=C(e))&&void 0!==n?n:e).display;return"flex"===t||"inline-flex"===t}(e))||(+n.opacity<1||("transform"in n&&"none"!==n.transform||("webkitTransform"in n&&"none"!==n.webkitTransform||("mixBlendMode"in n&&"normal"!==n.mixBlendMode||("filter"in n&&"none"!==n.filter||("webkitFilter"in n&&"none"!==n.webkitFilter||("isolation"in n&&"isolate"===n.isolation||(!!S.test(n.willChange)||"touch"===n.webkitOverflowScrolling)))))))))}function I(e){let n=e.length;for(;n--;){const t=e[n];if(J(t,"Missing node"),w(t))return t}return null}function E(e){return e&&Number(getComputedStyle(e).zIndex)||0}function P(e){const n=[];for(;e;)n.push(e),e=C(e);return n}function C(e){const{parentNode:n}=e;return n&&n instanceof ShadowRoot?n.host:n}const A=1,k=2,D=4,R=8,L="coarse"===function(){if("function"==typeof matchMedia)return matchMedia("(pointer:coarse)").matches?"coarse":"fine"}();let $=[],M=!1,N=new Map,H=new Map;const F=new Set;function G(e){const{target:n}=e,{x:t,y:r}=b(e);M=!0,j({target:n,x:t,y:r}),_(),$.length>0&&(q("down",e),V(),e.preventDefault(),T(n)||e.stopImmediatePropagation())}function O(e){const{x:n,y:t}=b(e);if(M&&"pointerleave"!==e.type&&0===e.buttons&&(M=!1,q("up",e)),!M){const{target:r}=e;j({target:r,x:n,y:t})}q("move",e),V(),$.length>0&&e.preventDefault()}function B(e){const{target:n}=e,{x:t,y:r}=b(e);H.clear(),M=!1,$.length>0&&(e.preventDefault(),T(n)||e.stopImmediatePropagation()),q("up",e),j({target:n,x:t,y:r}),V(),_()}function T(e){let n=e;for(;n;){if(n.hasAttribute(a.resizeHandle))return!0;n=n.parentElement}return!1}function j({target:e,x:n,y:t}){$.splice(0);let r=null;(e instanceof HTMLElement||e instanceof SVGElement)&&(r=e),F.forEach((e=>{const{element:o,hitAreaMargins:a}=e,l=o.getBoundingClientRect(),{bottom:i,left:u,right:s,top:c}=l,d=L?a.coarse:a.fine;if(n>=u-d&&n<=s+d&&t>=c-d&&t<=i+d){if(null!==r&&document.contains(r)&&o!==r&&!o.contains(r)&&!r.contains(o)&&function(e,n){if(e===n)throw new Error("Cannot compare node with itself");const t={a:P(e),b:P(n)};let r;for(;t.a.at(-1)===t.b.at(-1);)e=t.a.pop(),n=t.b.pop(),r=e;J(r,"Stacking order can only be calculated for elements with a common ancestor");const o=E(I(t.a)),a=E(I(t.b));if(o===a){const e=r.childNodes,n={a:t.a.at(-1),b:t.b.at(-1)};let o=e.length;for(;o--;){const t=e[o];if(t===n.a)return 1;if(t===n.b)return-1}}return Math.sign(o-a)}(r,o)>0){let e=r,n=!1;for(;e&&!e.contains(o);){if(x(e.getBoundingClientRect(),l,!0)){n=!0;break}e=e.parentElement}if(n)return}$.push(e)}}))}function U(e,n){H.set(e,n)}function V(){let e=!1,n=!1;$.forEach((t=>{const{direction:r}=t;"horizontal"===r?e=!0:n=!0}));let t=0;H.forEach((e=>{t|=e})),e&&n?m("intersection",t):e?m("horizontal",t):n?m("vertical",t):null!==y&&(document.head.removeChild(y),p=null,y=null,g=-1)}let W;function _(){var e;null===(e=W)||void 0===e||e.abort(),W=new AbortController;const n={capture:!0,signal:W.signal};F.size&&(M?($.length>0&&N.forEach(((e,t)=>{const{body:r}=t;e>0&&(r.addEventListener("contextmenu",B,n),r.addEventListener("pointerleave",O,n),r.addEventListener("pointermove",O,n))})),N.forEach(((e,t)=>{const{body:r}=t;r.addEventListener("pointerup",B,n),r.addEventListener("pointercancel",B,n)}))):N.forEach(((e,t)=>{const{body:r}=t;e>0&&(r.addEventListener("pointerdown",G,n),r.addEventListener("pointermove",O,n))})))}function q(e,n){F.forEach((t=>{const{setResizeHandlerState:r}=t,o=$.includes(t);r(e,o,n)}))}function J(e,n){if(!e)throw console.error(n),Error(n)}function K(e,n,t=10){return e.toFixed(t)===n.toFixed(t)?0:e>n?1:-1}function X(e,n,t=10){return 0===K(e,n,t)}function Y(e,n,t){return 0===K(e,n,t)}function Q({panelConstraints:e,panelIndex:n,size:t}){const r=e[n];J(null!=r,`Panel constraints not found for index ${n}`);let{collapsedSize:o=0,collapsible:a,maxSize:l=100,minSize:i=0}=r;if(K(t,i)<0)if(a){t=K(t,(o+i)/2)<0?o:i}else t=i;return t=Math.min(l,t),t=parseFloat(t.toFixed(10))}function Z({delta:e,initialLayout:n,panelConstraints:t,pivotIndices:r,prevLayout:o,trigger:a}){if(Y(e,0))return n;const l=[...n],[i,u]=r;J(null!=i,"Invalid first pivot index"),J(null!=u,"Invalid second pivot index");let s=0;if("keyboard"===a){{const r=e<0?u:i,o=t[r];J(o,`Panel constraints not found for index ${r}`);const{collapsedSize:a=0,collapsible:l,minSize:s=0}=o;if(l){const t=n[r];if(J(null!=t,`Previous layout not found for panel index ${r}`),Y(t,a)){const n=s-t;K(n,Math.abs(e))>0&&(e=e<0?0-n:n)}}}{const r=e<0?i:u,o=t[r];J(o,`No panel constraints found for index ${r}`);const{collapsedSize:a=0,collapsible:l,minSize:s=0}=o;if(l){const t=n[r];if(J(null!=t,`Previous layout not found for panel index ${r}`),Y(t,s)){const n=t-a;K(n,Math.abs(e))>0&&(e=e<0?0-n:n)}}}}{const r=e<0?1:-1;let o=e<0?u:i,a=0;for(;;){const e=n[o];J(null!=e,`Previous layout not found for panel index ${o}`);if(a+=Q({panelConstraints:t,panelIndex:o,size:100})-e,o+=r,o<0||o>=t.length)break}const l=Math.min(Math.abs(e),Math.abs(a));e=e<0?0-l:l}{let r=e<0?i:u;for(;r>=0&&r<t.length;){const o=Math.abs(e)-Math.abs(s),a=n[r];J(null!=a,`Previous layout not found for panel index ${r}`);const i=Q({panelConstraints:t,panelIndex:r,size:a-o});if(!Y(a,i)&&(s+=a-i,l[r]=i,s.toFixed(3).localeCompare(Math.abs(e).toFixed(3),void 0,{numeric:!0})>=0))break;e<0?r--:r++}}if(function(e,n,t){if(e.length!==n.length)return!1;for(let r=0;r<e.length;r++)if(!Y(e[r],n[r],t))return!1;return!0}(o,l))return o;{const r=e<0?u:i,o=n[r];J(null!=o,`Previous layout not found for panel index ${r}`);const a=o+s,c=Q({panelConstraints:t,panelIndex:r,size:a});if(l[r]=c,!Y(c,a)){let n=a-c;let r=e<0?u:i;for(;r>=0&&r<t.length;){const o=l[r];J(null!=o,`Previous layout not found for panel index ${r}`);const a=Q({panelConstraints:t,panelIndex:r,size:o+n});if(Y(o,a)||(n-=a-o,l[r]=a),Y(n,0))break;e>0?r--:r++}}}return Y(l.reduce(((e,n)=>n+e),0),100)?l:o}function ee({layout:e,panelsArray:n,pivotIndices:t}){let r=0,o=100,a=0,l=0;const i=t[0];J(null!=i,"No pivot index found"),n.forEach(((e,n)=>{const{constraints:t}=e,{maxSize:u=100,minSize:s=0}=t;n===i?(r=s,o=u):(a+=s,l+=u)}));return{valueMax:Math.min(o,100-a),valueMin:Math.max(r,100-l),valueNow:e[i]}}function ne(e,n=document){return Array.from(n.querySelectorAll(`[${a.resizeHandleId}][data-panel-group-id="${e}"]`))}function te(e,n,t=document){const r=ne(e,t).findIndex((e=>e.getAttribute(a.resizeHandleId)===n));return null!=r?r:null}function re(e,n,t){const r=te(e,n,t);return null!=r?[r,r+1]:[-1,-1]}function oe(e,n=document){if(((t=n)instanceof HTMLElement||"object"==typeof t&&null!==t&&"tagName"in t&&"getAttribute"in t)&&n.dataset.panelGroupId==e)return n;var t;const r=n.querySelector(`[data-panel-group][data-panel-group-id="${e}"]`);return r||null}function ae(e,n=document){const t=n.querySelector(`[${a.resizeHandleId}="${e}"]`);return t||null}function le(e,n,t,r=document){var o,a,l,i;const u=ae(n,r),s=ne(e,r),c=u?s.indexOf(u):-1;return[null!==(o=null===(a=t[c])||void 0===a?void 0:a.id)&&void 0!==o?o:null,null!==(l=null===(i=t[c+1])||void 0===i?void 0:i.id)&&void 0!==l?l:null]}function ie(e,n){if(e.length!==n.length)return!1;for(let t=0;t<e.length;t++)if(e[t]!==n[t])return!1;return!0}function ue(e,n){const t="horizontal"===e,{x:r,y:o}=b(n);return t?r:o}function se(e,n,t,r,o,l){if(h(e)){const n="horizontal"===t;let r=0;r=e.shiftKey?100:null!=o?o:10;let a=0;switch(e.key){case"ArrowDown":a=n?0:r;break;case"ArrowLeft":a=n?-r:0;break;case"ArrowRight":a=n?r:0;break;case"ArrowUp":a=n?0:-r;break;case"End":a=100;break;case"Home":a=-100}return a}return null==r?0:function(e,n,t,r,o){const l="horizontal"===t,i=ae(n,o);J(i,`No resize handle element found for id "${n}"`);const u=i.getAttribute(a.groupId);J(u,"Resize handle element has no group id attribute");let{initialCursorPosition:s}=r;const c=ue(t,e),d=oe(u,o);J(d,`No group element found for id "${u}"`);const f=d.getBoundingClientRect();return(c-s)/(l?f.width:f.height)*100}(e,n,t,r,l)}function ce(e,n,t){n.forEach(((n,r)=>{const o=e[r];J(o,`Panel data not found for index ${r}`);const{callbacks:a,constraints:l,id:i}=o,{collapsedSize:u=0,collapsible:s}=l,c=t[i];if(null==c||n!==c){t[i]=n;const{onCollapse:e,onExpand:r,onResize:o}=a;o&&o(n,c),s&&(e||r)&&(!r||null!=c&&!X(c,u)||X(n,u)||r(),!e||null!=c&&X(c,u)||!X(n,u)||e())}}))}function de(e,n){if(e.length!==n.length)return!1;for(let t=0;t<e.length;t++)if(e[t]!=n[t])return!1;return!0}function fe(e){try{if("undefined"==typeof localStorage)throw new Error("localStorage not supported in this environment");e.getItem=e=>localStorage.getItem(e),e.setItem=(e,n)=>{localStorage.setItem(e,n)}}catch(n){console.error(n),e.getItem=()=>null,e.setItem=()=>{}}}function pe(e){return`react-resizable-panels:${e}`}function ge(e){return e.map((e=>{const{constraints:n,id:t,idIsFromProps:r,order:o}=e;return r?t:o?`${o}:${JSON.stringify(n)}`:JSON.stringify(n)})).sort(((e,n)=>e.localeCompare(n))).join(",")}function ye(e,n){try{const t=pe(e),r=n.getItem(t);if(r){const e=JSON.parse(r);if("object"==typeof e&&null!=e)return e}}catch(e){}return null}function me(e,n,t,r,o){var a;const l=pe(e),i=ge(n),u=null!==(a=ye(e,o))&&void 0!==a?a:{};u[i]={expandToSizes:Object.fromEntries(t.entries()),layout:r};try{o.setItem(l,JSON.stringify(u))}catch(e){console.error(e)}}function he({layout:e,panelConstraints:n}){const t=[...e],r=t.reduce(((e,n)=>e+n),0);if(t.length!==n.length)throw Error(`Invalid ${n.length} panel layout: ${t.map((e=>`${e}%`)).join(", ")}`);if(!Y(r,100)&&t.length>0)for(let e=0;e<n.length;e++){const n=t[e];J(null!=n,`No layout data found for index ${e}`);const o=100/r*n;t[e]=o}let o=0;for(let e=0;e<n.length;e++){const r=t[e];J(null!=r,`No layout data found for index ${e}`);const a=Q({panelConstraints:n,panelIndex:e,size:r});r!=a&&(o+=r-a,t[e]=a)}if(!Y(o,0))for(let e=0;e<n.length;e++){const r=t[e];J(null!=r,`No layout data found for index ${e}`);const a=Q({panelConstraints:n,panelIndex:e,size:r+o});if(r!==a&&(o-=a-r,t[e]=a,Y(o,0)))break}return t}const ve={getItem:e=>(fe(ve),ve.getItem(e)),setItem:(e,n)=>{fe(ve),ve.setItem(e,n)}},ze={};function be({autoSaveId:n=null,children:t,className:r="",direction:i,forwardedRef:u,id:s=null,onLayout:d=null,keyboardResizeBy:f=null,storage:p=ve,style:g,tagName:y="div",...m}){const b=c(s),x=e.useRef(null),[S,w]=e.useState(null),[I,E]=e.useState([]),P=function(){const[n,t]=e.useState(0);return e.useCallback((()=>t((e=>e+1))),[])}(),C=e.useRef({}),L=e.useRef(new Map),$=e.useRef(0),M=e.useRef({autoSaveId:n,direction:i,dragState:S,id:b,keyboardResizeBy:f,onLayout:d,storage:p}),N=e.useRef({layout:I,panelDataArray:[],panelDataArrayChanged:!1});e.useRef({didLogIdAndOrderWarning:!1,didLogPanelConstraintsWarning:!1,prevPanelIds:[]}),e.useImperativeHandle(u,(()=>({getId:()=>M.current.id,getLayout:()=>{const{layout:e}=N.current;return e},setLayout:e=>{const{onLayout:n}=M.current,{layout:t,panelDataArray:r}=N.current,o=he({layout:e,panelConstraints:r.map((e=>e.constraints))});ie(t,o)||(E(o),N.current.layout=o,n&&n(o),ce(r,o,C.current))}})),[]),l((()=>{M.current.autoSaveId=n,M.current.direction=i,M.current.dragState=S,M.current.id=b,M.current.onLayout=d,M.current.storage=p})),function({committedValuesRef:n,eagerValuesRef:t,groupId:r,layout:o,panelDataArray:i,panelGroupElement:u,setLayout:s}){e.useRef({didWarnAboutMissingResizeHandle:!1}),l((()=>{if(!u)return;const e=ne(r,u);for(let n=0;n<i.length-1;n++){const{valueMax:t,valueMin:r,valueNow:a}=ee({layout:o,panelsArray:i,pivotIndices:[n,n+1]}),l=e[n];if(null==l);else{const e=i[n];J(e,`No panel data found for index "${n}"`),l.setAttribute("aria-controls",e.id),l.setAttribute("aria-valuemax",""+Math.round(t)),l.setAttribute("aria-valuemin",""+Math.round(r)),l.setAttribute("aria-valuenow",null!=a?""+Math.round(a):"")}}return()=>{e.forEach(((e,n)=>{e.removeAttribute("aria-controls"),e.removeAttribute("aria-valuemax"),e.removeAttribute("aria-valuemin"),e.removeAttribute("aria-valuenow")}))}}),[r,o,i,u]),e.useEffect((()=>{if(!u)return;const e=t.current;J(e,"Eager values not found");const{panelDataArray:n}=e;J(null!=oe(r,u),`No group found for id "${r}"`);const l=ne(r,u);J(l,`No resize handles found for group id "${r}"`);const i=l.map((e=>{const t=e.getAttribute(a.resizeHandleId);J(t,"Resize handle element has no handle id attribute");const[l,i]=le(r,t,n,u);if(null==l||null==i)return()=>{};const c=e=>{if(!e.defaultPrevented)switch(e.key){case"Enter":{e.preventDefault();const a=n.findIndex((e=>e.id===l));if(a>=0){const e=n[a];J(e,`No panel data found for index ${a}`);const l=o[a],{collapsedSize:i=0,collapsible:c,minSize:d=0}=e.constraints;if(null!=l&&c){const e=Z({delta:Y(l,i)?d-i:i-l,initialLayout:o,panelConstraints:n.map((e=>e.constraints)),pivotIndices:re(r,t,u),prevLayout:o,trigger:"keyboard"});o!==e&&s(e)}}break}}};return e.addEventListener("keydown",c),()=>{e.removeEventListener("keydown",c)}}));return()=>{i.forEach((e=>e()))}}),[u,n,t,r,o,i,s])}({committedValuesRef:M,eagerValuesRef:N,groupId:b,layout:I,panelDataArray:N.current.panelDataArray,setLayout:E,panelGroupElement:x.current}),e.useEffect((()=>{const{panelDataArray:e}=N.current;if(n){if(0===I.length||I.length!==e.length)return;let t=ze[n];null==t&&(t=function(e,n=10){let t=null;return(...r)=>{null!==t&&clearTimeout(t),t=setTimeout((()=>{e(...r)}),n)}}(me,100),ze[n]=t);const r=[...e],o=new Map(L.current);t(n,r,o,I,p)}}),[n,I,p]),e.useEffect((()=>{}));const H=e.useCallback((e=>{const{onLayout:n}=M.current,{layout:t,panelDataArray:r}=N.current;if(e.constraints.collapsible){const o=r.map((e=>e.constraints)),{collapsedSize:a=0,panelSize:l,pivotIndices:i}=we(r,e,t);if(J(null!=l,`Panel size not found for panel "${e.id}"`),!X(l,a)){L.current.set(e.id,l);const u=Z({delta:Se(r,e)===r.length-1?l-a:a-l,initialLayout:t,panelConstraints:o,pivotIndices:i,prevLayout:t,trigger:"imperative-api"});de(t,u)||(E(u),N.current.layout=u,n&&n(u),ce(r,u,C.current))}}}),[]),F=e.useCallback(((e,n)=>{const{onLayout:t}=M.current,{layout:r,panelDataArray:o}=N.current;if(e.constraints.collapsible){const a=o.map((e=>e.constraints)),{collapsedSize:l=0,panelSize:i=0,minSize:u=0,pivotIndices:s}=we(o,e,r),c=null!=n?n:u;if(X(i,l)){const n=L.current.get(e.id),l=null!=n&&n>=c?n:c,u=Z({delta:Se(o,e)===o.length-1?i-l:l-i,initialLayout:r,panelConstraints:a,pivotIndices:s,prevLayout:r,trigger:"imperative-api"});de(r,u)||(E(u),N.current.layout=u,t&&t(u),ce(o,u,C.current))}}}),[]),G=e.useCallback((e=>{const{layout:n,panelDataArray:t}=N.current,{panelSize:r}=we(t,e,n);return J(null!=r,`Panel size not found for panel "${e.id}"`),r}),[]),O=e.useCallback(((e,n)=>{const{panelDataArray:t}=N.current,r=Se(t,e);return function({defaultSize:e,dragState:n,layout:t,panelData:r,panelIndex:o,precision:a=3}){const l=t[o];let i;return i=null==l?null!=e?e.toFixed(a):"1":1===r.length?"1":l.toFixed(a),{flexBasis:0,flexGrow:i,flexShrink:1,overflow:"hidden",pointerEvents:null!==n?"none":void 0}}({defaultSize:n,dragState:S,layout:I,panelData:t,panelIndex:r})}),[S,I]),B=e.useCallback((e=>{const{layout:n,panelDataArray:t}=N.current,{collapsedSize:r=0,collapsible:o,panelSize:a}=we(t,e,n);return J(null!=a,`Panel size not found for panel "${e.id}"`),!0===o&&X(a,r)}),[]),T=e.useCallback((e=>{const{layout:n,panelDataArray:t}=N.current,{collapsedSize:r=0,collapsible:o,panelSize:a}=we(t,e,n);return J(null!=a,`Panel size not found for panel "${e.id}"`),!o||K(a,r)>0}),[]),j=e.useCallback((e=>{const{panelDataArray:n}=N.current;n.push(e),n.sort(((e,n)=>{const t=e.order,r=n.order;return null==t&&null==r?0:null==t?-1:null==r?1:t-r})),N.current.panelDataArrayChanged=!0,P()}),[P]);l((()=>{if(N.current.panelDataArrayChanged){N.current.panelDataArrayChanged=!1;const{autoSaveId:e,onLayout:n,storage:t}=M.current,{layout:r,panelDataArray:o}=N.current;let a=null;if(e){const n=function(e,n,t){var r,o;return null!==(o=(null!==(r=ye(e,t))&&void 0!==r?r:{})[ge(n)])&&void 0!==o?o:null}(e,o,t);n&&(L.current=new Map(Object.entries(n.expandToSizes)),a=n.layout)}null==a&&(a=function({panelDataArray:e}){const n=Array(e.length),t=e.map((e=>e.constraints));let r=0,o=100;for(let a=0;a<e.length;a++){const e=t[a];J(e,`Panel constraints not found for index ${a}`);const{defaultSize:l}=e;null!=l&&(r++,n[a]=l,o-=l)}for(let a=0;a<e.length;a++){const l=t[a];J(l,`Panel constraints not found for index ${a}`);const{defaultSize:i}=l;if(null!=i)continue;const u=o/(e.length-r);r++,n[a]=u,o-=u}return n}({panelDataArray:o}));const l=he({layout:a,panelConstraints:o.map((e=>e.constraints))});ie(r,l)||(E(l),N.current.layout=l,n&&n(l),ce(o,l,C.current))}})),l((()=>{const e=N.current;return()=>{e.layout=[]}}),[]);const V=e.useCallback((e=>{let n=!1;const t=x.current;if(t){"rtl"===window.getComputedStyle(t,null).getPropertyValue("direction")&&(n=!0)}return function(t){t.preventDefault();const r=x.current;if(!r)return()=>null;const{direction:o,dragState:a,id:l,keyboardResizeBy:i,onLayout:u}=M.current,{layout:s,panelDataArray:c}=N.current,{initialLayout:d}=null!=a?a:{},f=re(l,e,r);let p=se(t,e,o,a,i,r);const g="horizontal"===o;g&&n&&(p=-p);const y=Z({delta:p,initialLayout:null!=d?d:s,panelConstraints:c.map((e=>e.constraints)),pivotIndices:f,prevLayout:s,trigger:h(t)?"keyboard":"mouse-or-touch"}),m=!de(s,y);(v(t)||z(t))&&$.current!=p&&($.current=p,U(e,m||0===p?0:g?p<0?A:k:p<0?D:R)),m&&(E(y),N.current.layout=y,u&&u(y),ce(c,y,C.current))}}),[]),W=e.useCallback(((e,n)=>{const{onLayout:t}=M.current,{layout:r,panelDataArray:o}=N.current,a=o.map((e=>e.constraints)),{panelSize:l,pivotIndices:i}=we(o,e,r);J(null!=l,`Panel size not found for panel "${e.id}"`);const u=Z({delta:Se(o,e)===o.length-1?l-n:n-l,initialLayout:r,panelConstraints:a,pivotIndices:i,prevLayout:r,trigger:"imperative-api"});de(r,u)||(E(u),N.current.layout=u,t&&t(u),ce(o,u,C.current))}),[]),_=e.useCallback(((e,n)=>{const{layout:t,panelDataArray:r}=N.current,{collapsedSize:o=0,collapsible:a}=n,{collapsedSize:l=0,collapsible:i,maxSize:u=100,minSize:s=0}=e.constraints,{panelSize:c}=we(r,e,t);null!=c&&(a&&i&&X(c,o)?X(o,l)||W(e,l):c<s?W(e,s):c>u&&W(e,u))}),[W]),q=e.useCallback(((e,n)=>{const{direction:t}=M.current,{layout:r}=N.current;if(!x.current)return;const o=ae(e,x.current);J(o,`Drag handle element not found for id "${e}"`);const a=ue(t,n);w({dragHandleId:e,dragHandleRect:o.getBoundingClientRect(),initialCursorPosition:a,initialLayout:r})}),[]),Q=e.useCallback((()=>{w(null)}),[]),te=e.useCallback((e=>{const{panelDataArray:n}=N.current,t=Se(n,e);t>=0&&(n.splice(t,1),delete C.current[e.id],N.current.panelDataArrayChanged=!0,P())}),[P]),fe=e.useMemo((()=>({collapsePanel:H,direction:i,dragState:S,expandPanel:F,getPanelSize:G,getPanelStyle:O,groupId:b,isPanelCollapsed:B,isPanelExpanded:T,reevaluatePanelConstraints:_,registerPanel:j,registerResizeHandle:V,resizePanel:W,startDragging:q,stopDragging:Q,unregisterPanel:te,panelGroupElement:x.current})),[H,S,i,F,G,O,b,B,T,_,j,V,W,q,Q,te]),pe={display:"flex",flexDirection:"horizontal"===i?"row":"column",height:"100%",overflow:"hidden",width:"100%"};return e.createElement(o.Provider,{value:fe},e.createElement(y,{...m,children:t,className:r,id:s,ref:x,style:{...pe,...g},[a.group]:"",[a.groupDirection]:i,[a.groupId]:b}))}const xe=e.forwardRef(((n,t)=>e.createElement(be,{...n,forwardedRef:t})));function Se(e,n){return e.findIndex((e=>e===n||e.id===n.id))}function we(e,n,t){const r=Se(e,n),o=r===e.length-1?[r-1,r]:[r,r+1],a=t[r];return{...n.constraints,panelSize:a,pivotIndices:o}}function Ie({children:n=null,className:t="",disabled:r=!1,hitAreaMargins:i,id:u,onBlur:s,onClick:d,onDragging:f,onFocus:p,onPointerDown:g,onPointerUp:y,style:m={},tabIndex:h=0,tagName:v="div",...z}){var b,x;const S=e.useRef(null),w=e.useRef({onClick:d,onDragging:f,onPointerDown:g,onPointerUp:y});e.useEffect((()=>{w.current.onClick=d,w.current.onDragging=f,w.current.onPointerDown=g,w.current.onPointerUp=y}));const I=e.useContext(o);if(null===I)throw Error("PanelResizeHandle components must be rendered within a PanelGroup container");const{direction:E,groupId:P,registerResizeHandle:C,startDragging:A,stopDragging:k,panelGroupElement:D}=I,R=c(u),[L,M]=e.useState("inactive"),[G,O]=e.useState(!1),[B,T]=e.useState(null),j=e.useRef({state:L});l((()=>{j.current.state=L})),e.useEffect((()=>{if(r)T(null);else{const e=C(R);T((()=>e))}}),[r,R,C]);const U=null!==(b=null==i?void 0:i.coarse)&&void 0!==b?b:15,W=null!==(x=null==i?void 0:i.fine)&&void 0!==x?x:5;e.useEffect((()=>{if(r||null==B)return;const e=S.current;J(e,"Element ref not attached");let n=!1;return function(e,n,t,r,o){var a;const{ownerDocument:l}=n,i={direction:t,element:n,hitAreaMargins:r,setResizeHandlerState:o},u=null!==(a=N.get(l))&&void 0!==a?a:0;return N.set(l,u+1),F.add(i),_(),function(){var n;H.delete(e),F.delete(i);const t=null!==(n=N.get(l))&&void 0!==n?n:1;if(N.set(l,t-1),_(),1===t&&N.delete(l),$.includes(i)){const e=$.indexOf(i);e>=0&&$.splice(e,1),V(),o("up",!0,null)}}}(R,e,E,{coarse:U,fine:W},((e,t,r)=>{if(t)switch(e){case"down":{M("drag"),n=!1,J(r,'Expected event to be defined for "down" action'),A(R,r);const{onDragging:e,onPointerDown:t}=w.current;null==e||e(!0),null==t||t();break}case"move":{const{state:e}=j.current;n=!0,"drag"!==e&&M("hover"),J(r,'Expected event to be defined for "move" action'),B(r);break}case"up":{M("hover"),k();const{onClick:e,onDragging:t,onPointerUp:r}=w.current;null==t||t(!1),null==r||r(),n||null==e||e();break}}else M("inactive")}))}),[U,E,r,W,C,R,B,A,k]),function({disabled:n,handleId:t,resizeHandler:r,panelGroupElement:o}){e.useEffect((()=>{if(n||null==r||null==o)return;const e=ae(t,o);if(null==e)return;const l=n=>{if(!n.defaultPrevented)switch(n.key){case"ArrowDown":case"ArrowLeft":case"ArrowRight":case"ArrowUp":case"End":case"Home":n.preventDefault(),r(n);break;case"F6":{n.preventDefault();const r=e.getAttribute(a.groupId);J(r,`No group element found for id "${r}"`);const l=ne(r,o),i=te(r,t,o);J(null!==i,`No resize element found for id "${t}"`),l[n.shiftKey?i>0?i-1:l.length-1:i+1<l.length?i+1:0].focus();break}}};return e.addEventListener("keydown",l),()=>{e.removeEventListener("keydown",l)}}),[o,n,t,r])}({disabled:r,handleId:R,resizeHandler:B,panelGroupElement:D});return e.createElement(v,{...z,children:n,className:t,id:u,onBlur:()=>{O(!1),null==s||s()},onFocus:()=>{O(!0),null==p||p()},ref:S,role:"separator",style:{touchAction:"none",userSelect:"none",...m},tabIndex:h,[a.groupDirection]:E,[a.groupId]:P,[a.resizeHandle]:"",[a.resizeHandleActive]:"drag"===L?"pointer":G?"keyboard":void 0,[a.resizeHandleEnabled]:!r,[a.resizeHandleId]:R,[a.resizeHandleState]:L})}be.displayName="PanelGroup",xe.displayName="forwardRef(PanelGroup)",Ie.displayName="PanelResizeHandle",exports.DATA_ATTRIBUTES=a,exports.Panel=f,exports.PanelGroup=xe,exports.PanelResizeHandle=Ie,exports.assert=J,exports.getPanelGroupElement=oe,exports.getResizeHandleElement=ae,exports.getResizeHandleElementIndex=te,exports.getResizeHandleElementsForGroup=ne,exports.getResizeHandlePanelIds=le,exports.intersects=x;
|
|
2
|
-
//# sourceMappingURL=react-resizable-panels.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"react-resizable-panels.js","sources":["../../../../../node_modules/react-resizable-panels/dist/react-resizable-panels.js"],"sourcesContent":["import * as React from 'react';\nimport { createContext, useLayoutEffect, useRef, forwardRef, createElement, useContext, useImperativeHandle, useState, useCallback, useEffect, useMemo } from 'react';\n\nconst isBrowser = typeof window !== \"undefined\";\n\n// The \"contextmenu\" event is not supported as a PointerEvent in all browsers yet, so MouseEvent still need to be handled\n\nconst PanelGroupContext = createContext(null);\nPanelGroupContext.displayName = \"PanelGroupContext\";\n\nconst DATA_ATTRIBUTES = {\n group: \"data-panel-group\",\n groupDirection: \"data-panel-group-direction\",\n groupId: \"data-panel-group-id\",\n panel: \"data-panel\",\n panelCollapsible: \"data-panel-collapsible\",\n panelId: \"data-panel-id\",\n panelSize: \"data-panel-size\",\n resizeHandle: \"data-resize-handle\",\n resizeHandleActive: \"data-resize-handle-active\",\n resizeHandleEnabled: \"data-panel-resize-handle-enabled\",\n resizeHandleId: \"data-panel-resize-handle-id\",\n resizeHandleState: \"data-resize-handle-state\"\n};\nconst PRECISION = 10;\n\nconst useIsomorphicLayoutEffect = isBrowser ? useLayoutEffect : () => {};\n\nconst useId = React[\"useId\".toString()];\nconst wrappedUseId = typeof useId === \"function\" ? useId : () => null;\nlet counter = 0;\nfunction useUniqueId(idFromParams = null) {\n const idFromUseId = wrappedUseId();\n const idRef = useRef(idFromParams || idFromUseId || null);\n if (idRef.current === null) {\n idRef.current = \"\" + counter++;\n }\n return idFromParams !== null && idFromParams !== void 0 ? idFromParams : idRef.current;\n}\n\nfunction PanelWithForwardedRef({\n children,\n className: classNameFromProps = \"\",\n collapsedSize,\n collapsible,\n defaultSize,\n forwardedRef,\n id: idFromProps,\n maxSize,\n minSize,\n onCollapse,\n onExpand,\n onResize,\n order,\n style: styleFromProps,\n tagName: Type = \"div\",\n ...rest\n}) {\n const context = useContext(PanelGroupContext);\n if (context === null) {\n throw Error(`Panel components must be rendered within a PanelGroup container`);\n }\n const {\n collapsePanel,\n expandPanel,\n getPanelSize,\n getPanelStyle,\n groupId,\n isPanelCollapsed,\n reevaluatePanelConstraints,\n registerPanel,\n resizePanel,\n unregisterPanel\n } = context;\n const panelId = useUniqueId(idFromProps);\n const panelDataRef = useRef({\n callbacks: {\n onCollapse,\n onExpand,\n onResize\n },\n constraints: {\n collapsedSize,\n collapsible,\n defaultSize,\n maxSize,\n minSize\n },\n id: panelId,\n idIsFromProps: idFromProps !== undefined,\n order\n });\n useRef({\n didLogMissingDefaultSizeWarning: false\n });\n useIsomorphicLayoutEffect(() => {\n const {\n callbacks,\n constraints\n } = panelDataRef.current;\n const prevConstraints = {\n ...constraints\n };\n panelDataRef.current.id = panelId;\n panelDataRef.current.idIsFromProps = idFromProps !== undefined;\n panelDataRef.current.order = order;\n callbacks.onCollapse = onCollapse;\n callbacks.onExpand = onExpand;\n callbacks.onResize = onResize;\n constraints.collapsedSize = collapsedSize;\n constraints.collapsible = collapsible;\n constraints.defaultSize = defaultSize;\n constraints.maxSize = maxSize;\n constraints.minSize = minSize;\n\n // If constraints have changed, we should revisit panel sizes.\n // This is uncommon but may happen if people are trying to implement pixel based constraints.\n if (prevConstraints.collapsedSize !== constraints.collapsedSize || prevConstraints.collapsible !== constraints.collapsible || prevConstraints.maxSize !== constraints.maxSize || prevConstraints.minSize !== constraints.minSize) {\n reevaluatePanelConstraints(panelDataRef.current, prevConstraints);\n }\n });\n useIsomorphicLayoutEffect(() => {\n const panelData = panelDataRef.current;\n registerPanel(panelData);\n return () => {\n unregisterPanel(panelData);\n };\n }, [order, panelId, registerPanel, unregisterPanel]);\n useImperativeHandle(forwardedRef, () => ({\n collapse: () => {\n collapsePanel(panelDataRef.current);\n },\n expand: minSize => {\n expandPanel(panelDataRef.current, minSize);\n },\n getId() {\n return panelId;\n },\n getSize() {\n return getPanelSize(panelDataRef.current);\n },\n isCollapsed() {\n return isPanelCollapsed(panelDataRef.current);\n },\n isExpanded() {\n return !isPanelCollapsed(panelDataRef.current);\n },\n resize: size => {\n resizePanel(panelDataRef.current, size);\n }\n }), [collapsePanel, expandPanel, getPanelSize, isPanelCollapsed, panelId, resizePanel]);\n const style = getPanelStyle(panelDataRef.current, defaultSize);\n return createElement(Type, {\n ...rest,\n children,\n className: classNameFromProps,\n id: panelId,\n style: {\n ...style,\n ...styleFromProps\n },\n // CSS selectors\n [DATA_ATTRIBUTES.groupId]: groupId,\n [DATA_ATTRIBUTES.panel]: \"\",\n [DATA_ATTRIBUTES.panelCollapsible]: collapsible || undefined,\n [DATA_ATTRIBUTES.panelId]: panelId,\n [DATA_ATTRIBUTES.panelSize]: parseFloat(\"\" + style.flexGrow).toFixed(1)\n });\n}\nconst Panel = forwardRef((props, ref) => createElement(PanelWithForwardedRef, {\n ...props,\n forwardedRef: ref\n}));\nPanelWithForwardedRef.displayName = \"Panel\";\nPanel.displayName = \"forwardRef(Panel)\";\n\nlet nonce;\nfunction getNonce() {\n return nonce;\n}\nfunction setNonce(value) {\n nonce = value;\n}\n\nlet currentCursorStyle = null;\nlet enabled = true;\nlet getCustomCursorStyleFunction = null;\nlet prevRuleIndex = -1;\nlet styleElement = null;\nfunction customizeGlobalCursorStyles(callback) {\n getCustomCursorStyleFunction = callback;\n}\nfunction disableGlobalCursorStyles() {\n enabled = false;\n}\nfunction enableGlobalCursorStyles() {\n enabled = true;\n}\nfunction getCursorStyle(state, constraintFlags, isPointerDown) {\n const horizontalMin = (constraintFlags & EXCEEDED_HORIZONTAL_MIN) !== 0;\n const horizontalMax = (constraintFlags & EXCEEDED_HORIZONTAL_MAX) !== 0;\n const verticalMin = (constraintFlags & EXCEEDED_VERTICAL_MIN) !== 0;\n const verticalMax = (constraintFlags & EXCEEDED_VERTICAL_MAX) !== 0;\n if (getCustomCursorStyleFunction) {\n return getCustomCursorStyleFunction({\n exceedsHorizontalMaximum: horizontalMax,\n exceedsHorizontalMinimum: horizontalMin,\n exceedsVerticalMaximum: verticalMax,\n exceedsVerticalMinimum: verticalMin,\n intersectsHorizontalDragHandle: state === \"horizontal\" || state === \"intersection\",\n intersectsVerticalDragHandle: state === \"vertical\" || state === \"intersection\",\n isPointerDown\n });\n }\n if (constraintFlags) {\n if (horizontalMin) {\n if (verticalMin) {\n return \"se-resize\";\n } else if (verticalMax) {\n return \"ne-resize\";\n } else {\n return \"e-resize\";\n }\n } else if (horizontalMax) {\n if (verticalMin) {\n return \"sw-resize\";\n } else if (verticalMax) {\n return \"nw-resize\";\n } else {\n return \"w-resize\";\n }\n } else if (verticalMin) {\n return \"s-resize\";\n } else if (verticalMax) {\n return \"n-resize\";\n }\n }\n switch (state) {\n case \"horizontal\":\n return \"ew-resize\";\n case \"intersection\":\n return \"move\";\n case \"vertical\":\n return \"ns-resize\";\n }\n}\nfunction resetGlobalCursorStyle() {\n if (styleElement !== null) {\n document.head.removeChild(styleElement);\n currentCursorStyle = null;\n styleElement = null;\n prevRuleIndex = -1;\n }\n}\nfunction setGlobalCursorStyle(state, constraintFlags, isPointerDown) {\n var _styleElement$sheet$i, _styleElement$sheet2;\n if (!enabled) {\n return;\n }\n const style = getCursorStyle(state, constraintFlags, isPointerDown);\n if (currentCursorStyle === style) {\n return;\n }\n currentCursorStyle = style;\n if (styleElement === null) {\n styleElement = document.createElement(\"style\");\n const nonce = getNonce();\n if (nonce) {\n styleElement.setAttribute(\"nonce\", nonce);\n }\n document.head.appendChild(styleElement);\n }\n if (prevRuleIndex >= 0) {\n var _styleElement$sheet;\n (_styleElement$sheet = styleElement.sheet) === null || _styleElement$sheet === void 0 ? void 0 : _styleElement$sheet.removeRule(prevRuleIndex);\n }\n prevRuleIndex = (_styleElement$sheet$i = (_styleElement$sheet2 = styleElement.sheet) === null || _styleElement$sheet2 === void 0 ? void 0 : _styleElement$sheet2.insertRule(`*{cursor: ${style} !important;}`)) !== null && _styleElement$sheet$i !== void 0 ? _styleElement$sheet$i : -1;\n}\n\nfunction isKeyDown(event) {\n return event.type === \"keydown\";\n}\nfunction isPointerEvent(event) {\n return event.type.startsWith(\"pointer\");\n}\nfunction isMouseEvent(event) {\n return event.type.startsWith(\"mouse\");\n}\n\nfunction getResizeEventCoordinates(event) {\n if (isPointerEvent(event)) {\n if (event.isPrimary) {\n return {\n x: event.clientX,\n y: event.clientY\n };\n }\n } else if (isMouseEvent(event)) {\n return {\n x: event.clientX,\n y: event.clientY\n };\n }\n return {\n x: Infinity,\n y: Infinity\n };\n}\n\nfunction getInputType() {\n if (typeof matchMedia === \"function\") {\n return matchMedia(\"(pointer:coarse)\").matches ? \"coarse\" : \"fine\";\n }\n}\n\nfunction intersects(rectOne, rectTwo, strict) {\n if (strict) {\n return rectOne.x < rectTwo.x + rectTwo.width && rectOne.x + rectOne.width > rectTwo.x && rectOne.y < rectTwo.y + rectTwo.height && rectOne.y + rectOne.height > rectTwo.y;\n } else {\n return rectOne.x <= rectTwo.x + rectTwo.width && rectOne.x + rectOne.width >= rectTwo.x && rectOne.y <= rectTwo.y + rectTwo.height && rectOne.y + rectOne.height >= rectTwo.y;\n }\n}\n\n// Forked from NPM stacking-order@2.0.0\n\n/**\n * Determine which of two nodes appears in front of the other —\n * if `a` is in front, returns 1, otherwise returns -1\n * @param {HTMLElement | SVGElement} a\n * @param {HTMLElement | SVGElement} b\n */\nfunction compare(a, b) {\n if (a === b) throw new Error(\"Cannot compare node with itself\");\n const ancestors = {\n a: get_ancestors(a),\n b: get_ancestors(b)\n };\n let common_ancestor;\n\n // remove shared ancestors\n while (ancestors.a.at(-1) === ancestors.b.at(-1)) {\n a = ancestors.a.pop();\n b = ancestors.b.pop();\n common_ancestor = a;\n }\n assert(common_ancestor, \"Stacking order can only be calculated for elements with a common ancestor\");\n const z_indexes = {\n a: get_z_index(find_stacking_context(ancestors.a)),\n b: get_z_index(find_stacking_context(ancestors.b))\n };\n if (z_indexes.a === z_indexes.b) {\n const children = common_ancestor.childNodes;\n const furthest_ancestors = {\n a: ancestors.a.at(-1),\n b: ancestors.b.at(-1)\n };\n let i = children.length;\n while (i--) {\n const child = children[i];\n if (child === furthest_ancestors.a) return 1;\n if (child === furthest_ancestors.b) return -1;\n }\n }\n return Math.sign(z_indexes.a - z_indexes.b);\n}\nconst props = /\\b(?:position|zIndex|opacity|transform|webkitTransform|mixBlendMode|filter|webkitFilter|isolation)\\b/;\n\n/** @param {HTMLElement | SVGElement} node */\nfunction is_flex_item(node) {\n var _get_parent;\n // @ts-ignore\n const display = getComputedStyle((_get_parent = get_parent(node)) !== null && _get_parent !== void 0 ? _get_parent : node).display;\n return display === \"flex\" || display === \"inline-flex\";\n}\n\n/** @param {HTMLElement | SVGElement} node */\nfunction creates_stacking_context(node) {\n const style = getComputedStyle(node);\n\n // https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Positioning/Understanding_z_index/The_stacking_context\n if (style.position === \"fixed\") return true;\n // Forked to fix upstream bug https://github.com/Rich-Harris/stacking-order/issues/3\n // if (\n // (style.zIndex !== \"auto\" && style.position !== \"static\") ||\n // is_flex_item(node)\n // )\n if (style.zIndex !== \"auto\" && (style.position !== \"static\" || is_flex_item(node))) return true;\n if (+style.opacity < 1) return true;\n if (\"transform\" in style && style.transform !== \"none\") return true;\n if (\"webkitTransform\" in style && style.webkitTransform !== \"none\") return true;\n if (\"mixBlendMode\" in style && style.mixBlendMode !== \"normal\") return true;\n if (\"filter\" in style && style.filter !== \"none\") return true;\n if (\"webkitFilter\" in style && style.webkitFilter !== \"none\") return true;\n if (\"isolation\" in style && style.isolation === \"isolate\") return true;\n if (props.test(style.willChange)) return true;\n // @ts-expect-error\n if (style.webkitOverflowScrolling === \"touch\") return true;\n return false;\n}\n\n/** @param {(HTMLElement| SVGElement)[]} nodes */\nfunction find_stacking_context(nodes) {\n let i = nodes.length;\n while (i--) {\n const node = nodes[i];\n assert(node, \"Missing node\");\n if (creates_stacking_context(node)) return node;\n }\n return null;\n}\n\n/** @param {HTMLElement | SVGElement} node */\nfunction get_z_index(node) {\n return node && Number(getComputedStyle(node).zIndex) || 0;\n}\n\n/** @param {HTMLElement} node */\nfunction get_ancestors(node) {\n const ancestors = [];\n while (node) {\n ancestors.push(node);\n // @ts-ignore\n node = get_parent(node);\n }\n return ancestors; // [ node, ... <body>, <html>, document ]\n}\n\n/** @param {HTMLElement} node */\nfunction get_parent(node) {\n const {\n parentNode\n } = node;\n if (parentNode && parentNode instanceof ShadowRoot) {\n return parentNode.host;\n }\n return parentNode;\n}\n\nconst EXCEEDED_HORIZONTAL_MIN = 0b0001;\nconst EXCEEDED_HORIZONTAL_MAX = 0b0010;\nconst EXCEEDED_VERTICAL_MIN = 0b0100;\nconst EXCEEDED_VERTICAL_MAX = 0b1000;\nconst isCoarsePointer = getInputType() === \"coarse\";\nlet intersectingHandles = [];\nlet isPointerDown = false;\nlet ownerDocumentCounts = new Map();\nlet panelConstraintFlags = new Map();\nconst registeredResizeHandlers = new Set();\nfunction registerResizeHandle(resizeHandleId, element, direction, hitAreaMargins, setResizeHandlerState) {\n var _ownerDocumentCounts$;\n const {\n ownerDocument\n } = element;\n const data = {\n direction,\n element,\n hitAreaMargins,\n setResizeHandlerState\n };\n const count = (_ownerDocumentCounts$ = ownerDocumentCounts.get(ownerDocument)) !== null && _ownerDocumentCounts$ !== void 0 ? _ownerDocumentCounts$ : 0;\n ownerDocumentCounts.set(ownerDocument, count + 1);\n registeredResizeHandlers.add(data);\n updateListeners();\n return function unregisterResizeHandle() {\n var _ownerDocumentCounts$2;\n panelConstraintFlags.delete(resizeHandleId);\n registeredResizeHandlers.delete(data);\n const count = (_ownerDocumentCounts$2 = ownerDocumentCounts.get(ownerDocument)) !== null && _ownerDocumentCounts$2 !== void 0 ? _ownerDocumentCounts$2 : 1;\n ownerDocumentCounts.set(ownerDocument, count - 1);\n updateListeners();\n if (count === 1) {\n ownerDocumentCounts.delete(ownerDocument);\n }\n\n // If the resize handle that is currently unmounting is intersecting with the pointer,\n // update the global pointer to account for the change\n if (intersectingHandles.includes(data)) {\n const index = intersectingHandles.indexOf(data);\n if (index >= 0) {\n intersectingHandles.splice(index, 1);\n }\n updateCursor();\n\n // Also instruct the handle to stop dragging; this prevents the parent group from being left in an inconsistent state\n // See github.com/bvaughn/react-resizable-panels/issues/402\n setResizeHandlerState(\"up\", true, null);\n }\n };\n}\nfunction handlePointerDown(event) {\n const {\n target\n } = event;\n const {\n x,\n y\n } = getResizeEventCoordinates(event);\n isPointerDown = true;\n recalculateIntersectingHandles({\n target,\n x,\n y\n });\n updateListeners();\n if (intersectingHandles.length > 0) {\n updateResizeHandlerStates(\"down\", event);\n\n // Update cursor based on return value(s) from active handles\n updateCursor();\n event.preventDefault();\n if (!isWithinResizeHandle(target)) {\n event.stopImmediatePropagation();\n }\n }\n}\nfunction handlePointerMove(event) {\n const {\n x,\n y\n } = getResizeEventCoordinates(event);\n\n // Edge case (see #340)\n // Detect when the pointer has been released outside an iframe on a different domain\n if (isPointerDown &&\n // Skip this check for \"pointerleave\" events, else Firefox triggers a false positive (see #514)\n event.type !== \"pointerleave\" && event.buttons === 0) {\n isPointerDown = false;\n updateResizeHandlerStates(\"up\", event);\n }\n if (!isPointerDown) {\n const {\n target\n } = event;\n\n // Recalculate intersecting handles whenever the pointer moves, except if it has already been pressed\n // at that point, the handles may not move with the pointer (depending on constraints)\n // but the same set of active handles should be locked until the pointer is released\n recalculateIntersectingHandles({\n target,\n x,\n y\n });\n }\n updateResizeHandlerStates(\"move\", event);\n\n // Update cursor based on return value(s) from active handles\n updateCursor();\n if (intersectingHandles.length > 0) {\n event.preventDefault();\n }\n}\nfunction handlePointerUp(event) {\n const {\n target\n } = event;\n const {\n x,\n y\n } = getResizeEventCoordinates(event);\n panelConstraintFlags.clear();\n isPointerDown = false;\n if (intersectingHandles.length > 0) {\n event.preventDefault();\n if (!isWithinResizeHandle(target)) {\n event.stopImmediatePropagation();\n }\n }\n updateResizeHandlerStates(\"up\", event);\n recalculateIntersectingHandles({\n target,\n x,\n y\n });\n updateCursor();\n updateListeners();\n}\nfunction isWithinResizeHandle(element) {\n let currentElement = element;\n while (currentElement) {\n if (currentElement.hasAttribute(DATA_ATTRIBUTES.resizeHandle)) {\n return true;\n }\n currentElement = currentElement.parentElement;\n }\n return false;\n}\nfunction recalculateIntersectingHandles({\n target,\n x,\n y\n}) {\n intersectingHandles.splice(0);\n let targetElement = null;\n if (target instanceof HTMLElement || target instanceof SVGElement) {\n targetElement = target;\n }\n registeredResizeHandlers.forEach(data => {\n const {\n element: dragHandleElement,\n hitAreaMargins\n } = data;\n const dragHandleRect = dragHandleElement.getBoundingClientRect();\n const {\n bottom,\n left,\n right,\n top\n } = dragHandleRect;\n const margin = isCoarsePointer ? hitAreaMargins.coarse : hitAreaMargins.fine;\n const eventIntersects = x >= left - margin && x <= right + margin && y >= top - margin && y <= bottom + margin;\n if (eventIntersects) {\n // TRICKY\n // We listen for pointers events at the root in order to support hit area margins\n // (determining when the pointer is close enough to an element to be considered a \"hit\")\n // Clicking on an element \"above\" a handle (e.g. a modal) should prevent a hit though\n // so at this point we need to compare stacking order of a potentially intersecting drag handle,\n // and the element that was actually clicked/touched\n if (targetElement !== null && document.contains(targetElement) && dragHandleElement !== targetElement && !dragHandleElement.contains(targetElement) && !targetElement.contains(dragHandleElement) &&\n // Calculating stacking order has a cost, so we should avoid it if possible\n // That is why we only check potentially intersecting handles,\n // and why we skip if the event target is within the handle's DOM\n compare(targetElement, dragHandleElement) > 0) {\n // If the target is above the drag handle, then we also need to confirm they overlap\n // If they are beside each other (e.g. a panel and its drag handle) then the handle is still interactive\n //\n // It's not enough to compare only the target\n // The target might be a small element inside of a larger container\n // (For example, a SPAN or a DIV inside of a larger modal dialog)\n let currentElement = targetElement;\n let didIntersect = false;\n while (currentElement) {\n if (currentElement.contains(dragHandleElement)) {\n break;\n } else if (intersects(currentElement.getBoundingClientRect(), dragHandleRect, true)) {\n didIntersect = true;\n break;\n }\n currentElement = currentElement.parentElement;\n }\n if (didIntersect) {\n return;\n }\n }\n intersectingHandles.push(data);\n }\n });\n}\nfunction reportConstraintsViolation(resizeHandleId, flag) {\n panelConstraintFlags.set(resizeHandleId, flag);\n}\nfunction updateCursor() {\n let intersectsHorizontal = false;\n let intersectsVertical = false;\n intersectingHandles.forEach(data => {\n const {\n direction\n } = data;\n if (direction === \"horizontal\") {\n intersectsHorizontal = true;\n } else {\n intersectsVertical = true;\n }\n });\n let constraintFlags = 0;\n panelConstraintFlags.forEach(flag => {\n constraintFlags |= flag;\n });\n if (intersectsHorizontal && intersectsVertical) {\n setGlobalCursorStyle(\"intersection\", constraintFlags, isPointerDown);\n } else if (intersectsHorizontal) {\n setGlobalCursorStyle(\"horizontal\", constraintFlags, isPointerDown);\n } else if (intersectsVertical) {\n setGlobalCursorStyle(\"vertical\", constraintFlags, isPointerDown);\n } else {\n resetGlobalCursorStyle();\n }\n}\nlet listenersAbortController;\nfunction updateListeners() {\n var _listenersAbortContro;\n (_listenersAbortContro = listenersAbortController) === null || _listenersAbortContro === void 0 ? void 0 : _listenersAbortContro.abort();\n listenersAbortController = new AbortController();\n const options = {\n capture: true,\n signal: listenersAbortController.signal\n };\n if (!registeredResizeHandlers.size) {\n return;\n }\n if (isPointerDown) {\n if (intersectingHandles.length > 0) {\n ownerDocumentCounts.forEach((count, ownerDocument) => {\n const {\n body\n } = ownerDocument;\n if (count > 0) {\n body.addEventListener(\"contextmenu\", handlePointerUp, options);\n body.addEventListener(\"pointerleave\", handlePointerMove, options);\n body.addEventListener(\"pointermove\", handlePointerMove, options);\n }\n });\n }\n ownerDocumentCounts.forEach((_, ownerDocument) => {\n const {\n body\n } = ownerDocument;\n body.addEventListener(\"pointerup\", handlePointerUp, options);\n body.addEventListener(\"pointercancel\", handlePointerUp, options);\n });\n } else {\n ownerDocumentCounts.forEach((count, ownerDocument) => {\n const {\n body\n } = ownerDocument;\n if (count > 0) {\n body.addEventListener(\"pointerdown\", handlePointerDown, options);\n body.addEventListener(\"pointermove\", handlePointerMove, options);\n }\n });\n }\n}\nfunction updateResizeHandlerStates(action, event) {\n registeredResizeHandlers.forEach(data => {\n const {\n setResizeHandlerState\n } = data;\n const isActive = intersectingHandles.includes(data);\n setResizeHandlerState(action, isActive, event);\n });\n}\n\nfunction useForceUpdate() {\n const [_, setCount] = useState(0);\n return useCallback(() => setCount(prevCount => prevCount + 1), []);\n}\n\nfunction assert(expectedCondition, message) {\n if (!expectedCondition) {\n console.error(message);\n throw Error(message);\n }\n}\n\nfunction fuzzyCompareNumbers(actual, expected, fractionDigits = PRECISION) {\n if (actual.toFixed(fractionDigits) === expected.toFixed(fractionDigits)) {\n return 0;\n } else {\n return actual > expected ? 1 : -1;\n }\n}\nfunction fuzzyNumbersEqual$1(actual, expected, fractionDigits = PRECISION) {\n return fuzzyCompareNumbers(actual, expected, fractionDigits) === 0;\n}\n\nfunction fuzzyNumbersEqual(actual, expected, fractionDigits) {\n return fuzzyCompareNumbers(actual, expected, fractionDigits) === 0;\n}\n\nfunction fuzzyLayoutsEqual(actual, expected, fractionDigits) {\n if (actual.length !== expected.length) {\n return false;\n }\n for (let index = 0; index < actual.length; index++) {\n const actualSize = actual[index];\n const expectedSize = expected[index];\n if (!fuzzyNumbersEqual(actualSize, expectedSize, fractionDigits)) {\n return false;\n }\n }\n return true;\n}\n\n// Panel size must be in percentages; pixel values should be pre-converted\nfunction resizePanel({\n panelConstraints: panelConstraintsArray,\n panelIndex,\n size\n}) {\n const panelConstraints = panelConstraintsArray[panelIndex];\n assert(panelConstraints != null, `Panel constraints not found for index ${panelIndex}`);\n let {\n collapsedSize = 0,\n collapsible,\n maxSize = 100,\n minSize = 0\n } = panelConstraints;\n if (fuzzyCompareNumbers(size, minSize) < 0) {\n if (collapsible) {\n // Collapsible panels should snap closed or open only once they cross the halfway point between collapsed and min size.\n const halfwayPoint = (collapsedSize + minSize) / 2;\n if (fuzzyCompareNumbers(size, halfwayPoint) < 0) {\n size = collapsedSize;\n } else {\n size = minSize;\n }\n } else {\n size = minSize;\n }\n }\n size = Math.min(maxSize, size);\n size = parseFloat(size.toFixed(PRECISION));\n return size;\n}\n\n// All units must be in percentages; pixel values should be pre-converted\nfunction adjustLayoutByDelta({\n delta,\n initialLayout,\n panelConstraints: panelConstraintsArray,\n pivotIndices,\n prevLayout,\n trigger\n}) {\n if (fuzzyNumbersEqual(delta, 0)) {\n return initialLayout;\n }\n const nextLayout = [...initialLayout];\n const [firstPivotIndex, secondPivotIndex] = pivotIndices;\n assert(firstPivotIndex != null, \"Invalid first pivot index\");\n assert(secondPivotIndex != null, \"Invalid second pivot index\");\n let deltaApplied = 0;\n\n // const DEBUG = [];\n // DEBUG.push(`adjustLayoutByDelta()`);\n // DEBUG.push(` initialLayout: ${initialLayout.join(\", \")}`);\n // DEBUG.push(` prevLayout: ${prevLayout.join(\", \")}`);\n // DEBUG.push(` delta: ${delta}`);\n // DEBUG.push(` pivotIndices: ${pivotIndices.join(\", \")}`);\n // DEBUG.push(` trigger: ${trigger}`);\n // DEBUG.push(\"\");\n\n // A resizing panel affects the panels before or after it.\n //\n // A negative delta means the panel(s) immediately after the resize handle should grow/expand by decreasing its offset.\n // Other panels may also need to shrink/contract (and shift) to make room, depending on the min weights.\n //\n // A positive delta means the panel(s) immediately before the resize handle should \"expand\".\n // This is accomplished by shrinking/contracting (and shifting) one or more of the panels after the resize handle.\n\n {\n // If this is a resize triggered by a keyboard event, our logic for expanding/collapsing is different.\n // We no longer check the halfway threshold because this may prevent the panel from expanding at all.\n if (trigger === \"keyboard\") {\n {\n // Check if we should expand a collapsed panel\n const index = delta < 0 ? secondPivotIndex : firstPivotIndex;\n const panelConstraints = panelConstraintsArray[index];\n assert(panelConstraints, `Panel constraints not found for index ${index}`);\n const {\n collapsedSize = 0,\n collapsible,\n minSize = 0\n } = panelConstraints;\n\n // DEBUG.push(`edge case check 1: ${index}`);\n // DEBUG.push(` -> collapsible? ${collapsible}`);\n if (collapsible) {\n const prevSize = initialLayout[index];\n assert(prevSize != null, `Previous layout not found for panel index ${index}`);\n if (fuzzyNumbersEqual(prevSize, collapsedSize)) {\n const localDelta = minSize - prevSize;\n // DEBUG.push(` -> expand delta: ${localDelta}`);\n\n if (fuzzyCompareNumbers(localDelta, Math.abs(delta)) > 0) {\n delta = delta < 0 ? 0 - localDelta : localDelta;\n // DEBUG.push(` -> delta: ${delta}`);\n }\n }\n }\n }\n\n {\n // Check if we should collapse a panel at its minimum size\n const index = delta < 0 ? firstPivotIndex : secondPivotIndex;\n const panelConstraints = panelConstraintsArray[index];\n assert(panelConstraints, `No panel constraints found for index ${index}`);\n const {\n collapsedSize = 0,\n collapsible,\n minSize = 0\n } = panelConstraints;\n\n // DEBUG.push(`edge case check 2: ${index}`);\n // DEBUG.push(` -> collapsible? ${collapsible}`);\n if (collapsible) {\n const prevSize = initialLayout[index];\n assert(prevSize != null, `Previous layout not found for panel index ${index}`);\n if (fuzzyNumbersEqual(prevSize, minSize)) {\n const localDelta = prevSize - collapsedSize;\n // DEBUG.push(` -> expand delta: ${localDelta}`);\n\n if (fuzzyCompareNumbers(localDelta, Math.abs(delta)) > 0) {\n delta = delta < 0 ? 0 - localDelta : localDelta;\n // DEBUG.push(` -> delta: ${delta}`);\n }\n }\n }\n }\n }\n // DEBUG.push(\"\");\n }\n\n {\n // Pre-calculate max available delta in the opposite direction of our pivot.\n // This will be the maximum amount we're allowed to expand/contract the panels in the primary direction.\n // If this amount is less than the requested delta, adjust the requested delta.\n // If this amount is greater than the requested delta, that's useful information too–\n // as an expanding panel might change from collapsed to min size.\n\n const increment = delta < 0 ? 1 : -1;\n let index = delta < 0 ? secondPivotIndex : firstPivotIndex;\n let maxAvailableDelta = 0;\n\n // DEBUG.push(\"pre calc...\");\n while (true) {\n const prevSize = initialLayout[index];\n assert(prevSize != null, `Previous layout not found for panel index ${index}`);\n const maxSafeSize = resizePanel({\n panelConstraints: panelConstraintsArray,\n panelIndex: index,\n size: 100\n });\n const delta = maxSafeSize - prevSize;\n // DEBUG.push(` ${index}: ${prevSize} -> ${maxSafeSize}`);\n\n maxAvailableDelta += delta;\n index += increment;\n if (index < 0 || index >= panelConstraintsArray.length) {\n break;\n }\n }\n\n // DEBUG.push(` -> max available delta: ${maxAvailableDelta}`);\n const minAbsDelta = Math.min(Math.abs(delta), Math.abs(maxAvailableDelta));\n delta = delta < 0 ? 0 - minAbsDelta : minAbsDelta;\n // DEBUG.push(` -> adjusted delta: ${delta}`);\n // DEBUG.push(\"\");\n }\n\n {\n // Delta added to a panel needs to be subtracted from other panels (within the constraints that those panels allow).\n\n const pivotIndex = delta < 0 ? firstPivotIndex : secondPivotIndex;\n let index = pivotIndex;\n while (index >= 0 && index < panelConstraintsArray.length) {\n const deltaRemaining = Math.abs(delta) - Math.abs(deltaApplied);\n const prevSize = initialLayout[index];\n assert(prevSize != null, `Previous layout not found for panel index ${index}`);\n const unsafeSize = prevSize - deltaRemaining;\n const safeSize = resizePanel({\n panelConstraints: panelConstraintsArray,\n panelIndex: index,\n size: unsafeSize\n });\n if (!fuzzyNumbersEqual(prevSize, safeSize)) {\n deltaApplied += prevSize - safeSize;\n nextLayout[index] = safeSize;\n if (deltaApplied.toFixed(3).localeCompare(Math.abs(delta).toFixed(3), undefined, {\n numeric: true\n }) >= 0) {\n break;\n }\n }\n if (delta < 0) {\n index--;\n } else {\n index++;\n }\n }\n }\n // DEBUG.push(`after 1: ${nextLayout.join(\", \")}`);\n // DEBUG.push(` deltaApplied: ${deltaApplied}`);\n // DEBUG.push(\"\");\n\n // If we were unable to resize any of the panels panels, return the previous state.\n // This will essentially bailout and ignore e.g. drags past a panel's boundaries\n if (fuzzyLayoutsEqual(prevLayout, nextLayout)) {\n // DEBUG.push(`bailout to previous layout: ${prevLayout.join(\", \")}`);\n // console.log(DEBUG.join(\"\\n\"));\n\n return prevLayout;\n }\n {\n // Now distribute the applied delta to the panels in the other direction\n const pivotIndex = delta < 0 ? secondPivotIndex : firstPivotIndex;\n const prevSize = initialLayout[pivotIndex];\n assert(prevSize != null, `Previous layout not found for panel index ${pivotIndex}`);\n const unsafeSize = prevSize + deltaApplied;\n const safeSize = resizePanel({\n panelConstraints: panelConstraintsArray,\n panelIndex: pivotIndex,\n size: unsafeSize\n });\n\n // Adjust the pivot panel before, but only by the amount that surrounding panels were able to shrink/contract.\n nextLayout[pivotIndex] = safeSize;\n\n // Edge case where expanding or contracting one panel caused another one to change collapsed state\n if (!fuzzyNumbersEqual(safeSize, unsafeSize)) {\n let deltaRemaining = unsafeSize - safeSize;\n const pivotIndex = delta < 0 ? secondPivotIndex : firstPivotIndex;\n let index = pivotIndex;\n while (index >= 0 && index < panelConstraintsArray.length) {\n const prevSize = nextLayout[index];\n assert(prevSize != null, `Previous layout not found for panel index ${index}`);\n const unsafeSize = prevSize + deltaRemaining;\n const safeSize = resizePanel({\n panelConstraints: panelConstraintsArray,\n panelIndex: index,\n size: unsafeSize\n });\n if (!fuzzyNumbersEqual(prevSize, safeSize)) {\n deltaRemaining -= safeSize - prevSize;\n nextLayout[index] = safeSize;\n }\n if (fuzzyNumbersEqual(deltaRemaining, 0)) {\n break;\n }\n if (delta > 0) {\n index--;\n } else {\n index++;\n }\n }\n }\n }\n // DEBUG.push(`after 2: ${nextLayout.join(\", \")}`);\n // DEBUG.push(` deltaApplied: ${deltaApplied}`);\n // DEBUG.push(\"\");\n\n const totalSize = nextLayout.reduce((total, size) => size + total, 0);\n // DEBUG.push(`total size: ${totalSize}`);\n\n // If our new layout doesn't add up to 100%, that means the requested delta can't be applied\n // In that case, fall back to our most recent valid layout\n if (!fuzzyNumbersEqual(totalSize, 100)) {\n // DEBUG.push(`bailout to previous layout: ${prevLayout.join(\", \")}`);\n // console.log(DEBUG.join(\"\\n\"));\n\n return prevLayout;\n }\n\n // console.log(DEBUG.join(\"\\n\"));\n return nextLayout;\n}\n\nfunction calculateAriaValues({\n layout,\n panelsArray,\n pivotIndices\n}) {\n let currentMinSize = 0;\n let currentMaxSize = 100;\n let totalMinSize = 0;\n let totalMaxSize = 0;\n const firstIndex = pivotIndices[0];\n assert(firstIndex != null, \"No pivot index found\");\n\n // A panel's effective min/max sizes also need to account for other panel's sizes.\n panelsArray.forEach((panelData, index) => {\n const {\n constraints\n } = panelData;\n const {\n maxSize = 100,\n minSize = 0\n } = constraints;\n if (index === firstIndex) {\n currentMinSize = minSize;\n currentMaxSize = maxSize;\n } else {\n totalMinSize += minSize;\n totalMaxSize += maxSize;\n }\n });\n const valueMax = Math.min(currentMaxSize, 100 - totalMinSize);\n const valueMin = Math.max(currentMinSize, 100 - totalMaxSize);\n const valueNow = layout[firstIndex];\n return {\n valueMax,\n valueMin,\n valueNow\n };\n}\n\nfunction getResizeHandleElementsForGroup(groupId, scope = document) {\n return Array.from(scope.querySelectorAll(`[${DATA_ATTRIBUTES.resizeHandleId}][data-panel-group-id=\"${groupId}\"]`));\n}\n\nfunction getResizeHandleElementIndex(groupId, id, scope = document) {\n const handles = getResizeHandleElementsForGroup(groupId, scope);\n const index = handles.findIndex(handle => handle.getAttribute(DATA_ATTRIBUTES.resizeHandleId) === id);\n return index !== null && index !== void 0 ? index : null;\n}\n\nfunction determinePivotIndices(groupId, dragHandleId, panelGroupElement) {\n const index = getResizeHandleElementIndex(groupId, dragHandleId, panelGroupElement);\n return index != null ? [index, index + 1] : [-1, -1];\n}\n\nfunction isHTMLElement(target) {\n if (target instanceof HTMLElement) {\n return true;\n }\n\n // Fallback to duck typing to handle edge case of portals within a popup window\n return typeof target === \"object\" && target !== null && \"tagName\" in target && \"getAttribute\" in target;\n}\n\nfunction getPanelGroupElement(id, rootElement = document) {\n // If the root element is the PanelGroup\n if (isHTMLElement(rootElement) && rootElement.dataset.panelGroupId == id) {\n return rootElement;\n }\n\n // Else query children\n const element = rootElement.querySelector(`[data-panel-group][data-panel-group-id=\"${id}\"]`);\n if (element) {\n return element;\n }\n return null;\n}\n\nfunction getResizeHandleElement(id, scope = document) {\n const element = scope.querySelector(`[${DATA_ATTRIBUTES.resizeHandleId}=\"${id}\"]`);\n if (element) {\n return element;\n }\n return null;\n}\n\nfunction getResizeHandlePanelIds(groupId, handleId, panelsArray, scope = document) {\n var _panelsArray$index$id, _panelsArray$index, _panelsArray$id, _panelsArray;\n const handle = getResizeHandleElement(handleId, scope);\n const handles = getResizeHandleElementsForGroup(groupId, scope);\n const index = handle ? handles.indexOf(handle) : -1;\n const idBefore = (_panelsArray$index$id = (_panelsArray$index = panelsArray[index]) === null || _panelsArray$index === void 0 ? void 0 : _panelsArray$index.id) !== null && _panelsArray$index$id !== void 0 ? _panelsArray$index$id : null;\n const idAfter = (_panelsArray$id = (_panelsArray = panelsArray[index + 1]) === null || _panelsArray === void 0 ? void 0 : _panelsArray.id) !== null && _panelsArray$id !== void 0 ? _panelsArray$id : null;\n return [idBefore, idAfter];\n}\n\n// https://www.w3.org/WAI/ARIA/apg/patterns/windowsplitter/\n\nfunction useWindowSplitterPanelGroupBehavior({\n committedValuesRef,\n eagerValuesRef,\n groupId,\n layout,\n panelDataArray,\n panelGroupElement,\n setLayout\n}) {\n useRef({\n didWarnAboutMissingResizeHandle: false\n });\n useIsomorphicLayoutEffect(() => {\n if (!panelGroupElement) {\n return;\n }\n const resizeHandleElements = getResizeHandleElementsForGroup(groupId, panelGroupElement);\n for (let index = 0; index < panelDataArray.length - 1; index++) {\n const {\n valueMax,\n valueMin,\n valueNow\n } = calculateAriaValues({\n layout,\n panelsArray: panelDataArray,\n pivotIndices: [index, index + 1]\n });\n const resizeHandleElement = resizeHandleElements[index];\n if (resizeHandleElement == null) ; else {\n const panelData = panelDataArray[index];\n assert(panelData, `No panel data found for index \"${index}\"`);\n resizeHandleElement.setAttribute(\"aria-controls\", panelData.id);\n resizeHandleElement.setAttribute(\"aria-valuemax\", \"\" + Math.round(valueMax));\n resizeHandleElement.setAttribute(\"aria-valuemin\", \"\" + Math.round(valueMin));\n resizeHandleElement.setAttribute(\"aria-valuenow\", valueNow != null ? \"\" + Math.round(valueNow) : \"\");\n }\n }\n return () => {\n resizeHandleElements.forEach((resizeHandleElement, index) => {\n resizeHandleElement.removeAttribute(\"aria-controls\");\n resizeHandleElement.removeAttribute(\"aria-valuemax\");\n resizeHandleElement.removeAttribute(\"aria-valuemin\");\n resizeHandleElement.removeAttribute(\"aria-valuenow\");\n });\n };\n }, [groupId, layout, panelDataArray, panelGroupElement]);\n useEffect(() => {\n if (!panelGroupElement) {\n return;\n }\n const eagerValues = eagerValuesRef.current;\n assert(eagerValues, `Eager values not found`);\n const {\n panelDataArray\n } = eagerValues;\n const groupElement = getPanelGroupElement(groupId, panelGroupElement);\n assert(groupElement != null, `No group found for id \"${groupId}\"`);\n const handles = getResizeHandleElementsForGroup(groupId, panelGroupElement);\n assert(handles, `No resize handles found for group id \"${groupId}\"`);\n const cleanupFunctions = handles.map(handle => {\n const handleId = handle.getAttribute(DATA_ATTRIBUTES.resizeHandleId);\n assert(handleId, `Resize handle element has no handle id attribute`);\n const [idBefore, idAfter] = getResizeHandlePanelIds(groupId, handleId, panelDataArray, panelGroupElement);\n if (idBefore == null || idAfter == null) {\n return () => {};\n }\n const onKeyDown = event => {\n if (event.defaultPrevented) {\n return;\n }\n switch (event.key) {\n case \"Enter\":\n {\n event.preventDefault();\n const index = panelDataArray.findIndex(panelData => panelData.id === idBefore);\n if (index >= 0) {\n const panelData = panelDataArray[index];\n assert(panelData, `No panel data found for index ${index}`);\n const size = layout[index];\n const {\n collapsedSize = 0,\n collapsible,\n minSize = 0\n } = panelData.constraints;\n if (size != null && collapsible) {\n const nextLayout = adjustLayoutByDelta({\n delta: fuzzyNumbersEqual(size, collapsedSize) ? minSize - collapsedSize : collapsedSize - size,\n initialLayout: layout,\n panelConstraints: panelDataArray.map(panelData => panelData.constraints),\n pivotIndices: determinePivotIndices(groupId, handleId, panelGroupElement),\n prevLayout: layout,\n trigger: \"keyboard\"\n });\n if (layout !== nextLayout) {\n setLayout(nextLayout);\n }\n }\n }\n break;\n }\n }\n };\n handle.addEventListener(\"keydown\", onKeyDown);\n return () => {\n handle.removeEventListener(\"keydown\", onKeyDown);\n };\n });\n return () => {\n cleanupFunctions.forEach(cleanupFunction => cleanupFunction());\n };\n }, [panelGroupElement, committedValuesRef, eagerValuesRef, groupId, layout, panelDataArray, setLayout]);\n}\n\nfunction areEqual(arrayA, arrayB) {\n if (arrayA.length !== arrayB.length) {\n return false;\n }\n for (let index = 0; index < arrayA.length; index++) {\n if (arrayA[index] !== arrayB[index]) {\n return false;\n }\n }\n return true;\n}\n\nfunction getResizeEventCursorPosition(direction, event) {\n const isHorizontal = direction === \"horizontal\";\n const {\n x,\n y\n } = getResizeEventCoordinates(event);\n return isHorizontal ? x : y;\n}\n\nfunction calculateDragOffsetPercentage(event, dragHandleId, direction, initialDragState, panelGroupElement) {\n const isHorizontal = direction === \"horizontal\";\n const handleElement = getResizeHandleElement(dragHandleId, panelGroupElement);\n assert(handleElement, `No resize handle element found for id \"${dragHandleId}\"`);\n const groupId = handleElement.getAttribute(DATA_ATTRIBUTES.groupId);\n assert(groupId, `Resize handle element has no group id attribute`);\n let {\n initialCursorPosition\n } = initialDragState;\n const cursorPosition = getResizeEventCursorPosition(direction, event);\n const groupElement = getPanelGroupElement(groupId, panelGroupElement);\n assert(groupElement, `No group element found for id \"${groupId}\"`);\n const groupRect = groupElement.getBoundingClientRect();\n const groupSizeInPixels = isHorizontal ? groupRect.width : groupRect.height;\n const offsetPixels = cursorPosition - initialCursorPosition;\n const offsetPercentage = offsetPixels / groupSizeInPixels * 100;\n return offsetPercentage;\n}\n\n// https://developer.mozilla.org/en-US/docs/Web/API/MouseEvent/movementX\nfunction calculateDeltaPercentage(event, dragHandleId, direction, initialDragState, keyboardResizeBy, panelGroupElement) {\n if (isKeyDown(event)) {\n const isHorizontal = direction === \"horizontal\";\n let delta = 0;\n if (event.shiftKey) {\n delta = 100;\n } else if (keyboardResizeBy != null) {\n delta = keyboardResizeBy;\n } else {\n delta = 10;\n }\n let movement = 0;\n switch (event.key) {\n case \"ArrowDown\":\n movement = isHorizontal ? 0 : delta;\n break;\n case \"ArrowLeft\":\n movement = isHorizontal ? -delta : 0;\n break;\n case \"ArrowRight\":\n movement = isHorizontal ? delta : 0;\n break;\n case \"ArrowUp\":\n movement = isHorizontal ? 0 : -delta;\n break;\n case \"End\":\n movement = 100;\n break;\n case \"Home\":\n movement = -100;\n break;\n }\n return movement;\n } else {\n if (initialDragState == null) {\n return 0;\n }\n return calculateDragOffsetPercentage(event, dragHandleId, direction, initialDragState, panelGroupElement);\n }\n}\n\nfunction calculateUnsafeDefaultLayout({\n panelDataArray\n}) {\n const layout = Array(panelDataArray.length);\n const panelConstraintsArray = panelDataArray.map(panelData => panelData.constraints);\n let numPanelsWithSizes = 0;\n let remainingSize = 100;\n\n // Distribute default sizes first\n for (let index = 0; index < panelDataArray.length; index++) {\n const panelConstraints = panelConstraintsArray[index];\n assert(panelConstraints, `Panel constraints not found for index ${index}`);\n const {\n defaultSize\n } = panelConstraints;\n if (defaultSize != null) {\n numPanelsWithSizes++;\n layout[index] = defaultSize;\n remainingSize -= defaultSize;\n }\n }\n\n // Remaining size should be distributed evenly between panels without default sizes\n for (let index = 0; index < panelDataArray.length; index++) {\n const panelConstraints = panelConstraintsArray[index];\n assert(panelConstraints, `Panel constraints not found for index ${index}`);\n const {\n defaultSize\n } = panelConstraints;\n if (defaultSize != null) {\n continue;\n }\n const numRemainingPanels = panelDataArray.length - numPanelsWithSizes;\n const size = remainingSize / numRemainingPanels;\n numPanelsWithSizes++;\n layout[index] = size;\n remainingSize -= size;\n }\n return layout;\n}\n\n// Layout should be pre-converted into percentages\nfunction callPanelCallbacks(panelsArray, layout, panelIdToLastNotifiedSizeMap) {\n layout.forEach((size, index) => {\n const panelData = panelsArray[index];\n assert(panelData, `Panel data not found for index ${index}`);\n const {\n callbacks,\n constraints,\n id: panelId\n } = panelData;\n const {\n collapsedSize = 0,\n collapsible\n } = constraints;\n const lastNotifiedSize = panelIdToLastNotifiedSizeMap[panelId];\n if (lastNotifiedSize == null || size !== lastNotifiedSize) {\n panelIdToLastNotifiedSizeMap[panelId] = size;\n const {\n onCollapse,\n onExpand,\n onResize\n } = callbacks;\n if (onResize) {\n onResize(size, lastNotifiedSize);\n }\n if (collapsible && (onCollapse || onExpand)) {\n if (onExpand && (lastNotifiedSize == null || fuzzyNumbersEqual$1(lastNotifiedSize, collapsedSize)) && !fuzzyNumbersEqual$1(size, collapsedSize)) {\n onExpand();\n }\n if (onCollapse && (lastNotifiedSize == null || !fuzzyNumbersEqual$1(lastNotifiedSize, collapsedSize)) && fuzzyNumbersEqual$1(size, collapsedSize)) {\n onCollapse();\n }\n }\n }\n });\n}\n\nfunction compareLayouts(a, b) {\n if (a.length !== b.length) {\n return false;\n } else {\n for (let index = 0; index < a.length; index++) {\n if (a[index] != b[index]) {\n return false;\n }\n }\n }\n return true;\n}\n\n// This method returns a number between 1 and 100 representing\n\n// the % of the group's overall space this panel should occupy.\nfunction computePanelFlexBoxStyle({\n defaultSize,\n dragState,\n layout,\n panelData,\n panelIndex,\n precision = 3\n}) {\n const size = layout[panelIndex];\n let flexGrow;\n if (size == null) {\n // Initial render (before panels have registered themselves)\n // In order to support server rendering, fall back to default size if provided\n flexGrow = defaultSize != undefined ? defaultSize.toFixed(precision) : \"1\";\n } else if (panelData.length === 1) {\n // Special case: Single panel group should always fill full width/height\n flexGrow = \"1\";\n } else {\n flexGrow = size.toFixed(precision);\n }\n return {\n flexBasis: 0,\n flexGrow,\n flexShrink: 1,\n // Without this, Panel sizes may be unintentionally overridden by their content\n overflow: \"hidden\",\n // Disable pointer events inside of a panel during resize\n // This avoid edge cases like nested iframes\n pointerEvents: dragState !== null ? \"none\" : undefined\n };\n}\n\nfunction debounce(callback, durationMs = 10) {\n let timeoutId = null;\n let callable = (...args) => {\n if (timeoutId !== null) {\n clearTimeout(timeoutId);\n }\n timeoutId = setTimeout(() => {\n callback(...args);\n }, durationMs);\n };\n return callable;\n}\n\n// PanelGroup might be rendering in a server-side environment where localStorage is not available\n// or on a browser with cookies/storage disabled.\n// In either case, this function avoids accessing localStorage until needed,\n// and avoids throwing user-visible errors.\nfunction initializeDefaultStorage(storageObject) {\n try {\n if (typeof localStorage !== \"undefined\") {\n // Bypass this check for future calls\n storageObject.getItem = name => {\n return localStorage.getItem(name);\n };\n storageObject.setItem = (name, value) => {\n localStorage.setItem(name, value);\n };\n } else {\n throw new Error(\"localStorage not supported in this environment\");\n }\n } catch (error) {\n console.error(error);\n storageObject.getItem = () => null;\n storageObject.setItem = () => {};\n }\n}\n\nfunction getPanelGroupKey(autoSaveId) {\n return `react-resizable-panels:${autoSaveId}`;\n}\n\n// Note that Panel ids might be user-provided (stable) or useId generated (non-deterministic)\n// so they should not be used as part of the serialization key.\n// Using the min/max size attributes should work well enough as a backup.\n// Pre-sorting by minSize allows remembering layouts even if panels are re-ordered/dragged.\nfunction getPanelKey(panels) {\n return panels.map(panel => {\n const {\n constraints,\n id,\n idIsFromProps,\n order\n } = panel;\n if (idIsFromProps) {\n return id;\n } else {\n return order ? `${order}:${JSON.stringify(constraints)}` : JSON.stringify(constraints);\n }\n }).sort((a, b) => a.localeCompare(b)).join(\",\");\n}\nfunction loadSerializedPanelGroupState(autoSaveId, storage) {\n try {\n const panelGroupKey = getPanelGroupKey(autoSaveId);\n const serialized = storage.getItem(panelGroupKey);\n if (serialized) {\n const parsed = JSON.parse(serialized);\n if (typeof parsed === \"object\" && parsed != null) {\n return parsed;\n }\n }\n } catch (error) {}\n return null;\n}\nfunction loadPanelGroupState(autoSaveId, panels, storage) {\n var _loadSerializedPanelG, _state$panelKey;\n const state = (_loadSerializedPanelG = loadSerializedPanelGroupState(autoSaveId, storage)) !== null && _loadSerializedPanelG !== void 0 ? _loadSerializedPanelG : {};\n const panelKey = getPanelKey(panels);\n return (_state$panelKey = state[panelKey]) !== null && _state$panelKey !== void 0 ? _state$panelKey : null;\n}\nfunction savePanelGroupState(autoSaveId, panels, panelSizesBeforeCollapse, sizes, storage) {\n var _loadSerializedPanelG2;\n const panelGroupKey = getPanelGroupKey(autoSaveId);\n const panelKey = getPanelKey(panels);\n const state = (_loadSerializedPanelG2 = loadSerializedPanelGroupState(autoSaveId, storage)) !== null && _loadSerializedPanelG2 !== void 0 ? _loadSerializedPanelG2 : {};\n state[panelKey] = {\n expandToSizes: Object.fromEntries(panelSizesBeforeCollapse.entries()),\n layout: sizes\n };\n try {\n storage.setItem(panelGroupKey, JSON.stringify(state));\n } catch (error) {\n console.error(error);\n }\n}\n\n// All units must be in percentages; pixel values should be pre-converted\nfunction validatePanelGroupLayout({\n layout: prevLayout,\n panelConstraints\n}) {\n const nextLayout = [...prevLayout];\n const nextLayoutTotalSize = nextLayout.reduce((accumulated, current) => accumulated + current, 0);\n\n // Validate layout expectations\n if (nextLayout.length !== panelConstraints.length) {\n throw Error(`Invalid ${panelConstraints.length} panel layout: ${nextLayout.map(size => `${size}%`).join(\", \")}`);\n } else if (!fuzzyNumbersEqual(nextLayoutTotalSize, 100) && nextLayout.length > 0) {\n for (let index = 0; index < panelConstraints.length; index++) {\n const unsafeSize = nextLayout[index];\n assert(unsafeSize != null, `No layout data found for index ${index}`);\n const safeSize = 100 / nextLayoutTotalSize * unsafeSize;\n nextLayout[index] = safeSize;\n }\n }\n let remainingSize = 0;\n\n // First pass: Validate the proposed layout given each panel's constraints\n for (let index = 0; index < panelConstraints.length; index++) {\n const unsafeSize = nextLayout[index];\n assert(unsafeSize != null, `No layout data found for index ${index}`);\n const safeSize = resizePanel({\n panelConstraints,\n panelIndex: index,\n size: unsafeSize\n });\n if (unsafeSize != safeSize) {\n remainingSize += unsafeSize - safeSize;\n nextLayout[index] = safeSize;\n }\n }\n\n // If there is additional, left over space, assign it to any panel(s) that permits it\n // (It's not worth taking multiple additional passes to evenly distribute)\n if (!fuzzyNumbersEqual(remainingSize, 0)) {\n for (let index = 0; index < panelConstraints.length; index++) {\n const prevSize = nextLayout[index];\n assert(prevSize != null, `No layout data found for index ${index}`);\n const unsafeSize = prevSize + remainingSize;\n const safeSize = resizePanel({\n panelConstraints,\n panelIndex: index,\n size: unsafeSize\n });\n if (prevSize !== safeSize) {\n remainingSize -= safeSize - prevSize;\n nextLayout[index] = safeSize;\n\n // Once we've used up the remainder, bail\n if (fuzzyNumbersEqual(remainingSize, 0)) {\n break;\n }\n }\n }\n }\n return nextLayout;\n}\n\nconst LOCAL_STORAGE_DEBOUNCE_INTERVAL = 100;\nconst defaultStorage = {\n getItem: name => {\n initializeDefaultStorage(defaultStorage);\n return defaultStorage.getItem(name);\n },\n setItem: (name, value) => {\n initializeDefaultStorage(defaultStorage);\n defaultStorage.setItem(name, value);\n }\n};\nconst debounceMap = {};\nfunction PanelGroupWithForwardedRef({\n autoSaveId = null,\n children,\n className: classNameFromProps = \"\",\n direction,\n forwardedRef,\n id: idFromProps = null,\n onLayout = null,\n keyboardResizeBy = null,\n storage = defaultStorage,\n style: styleFromProps,\n tagName: Type = \"div\",\n ...rest\n}) {\n const groupId = useUniqueId(idFromProps);\n const panelGroupElementRef = useRef(null);\n const [dragState, setDragState] = useState(null);\n const [layout, setLayout] = useState([]);\n const forceUpdate = useForceUpdate();\n const panelIdToLastNotifiedSizeMapRef = useRef({});\n const panelSizeBeforeCollapseRef = useRef(new Map());\n const prevDeltaRef = useRef(0);\n const committedValuesRef = useRef({\n autoSaveId,\n direction,\n dragState,\n id: groupId,\n keyboardResizeBy,\n onLayout,\n storage\n });\n const eagerValuesRef = useRef({\n layout,\n panelDataArray: [],\n panelDataArrayChanged: false\n });\n useRef({\n didLogIdAndOrderWarning: false,\n didLogPanelConstraintsWarning: false,\n prevPanelIds: []\n });\n useImperativeHandle(forwardedRef, () => ({\n getId: () => committedValuesRef.current.id,\n getLayout: () => {\n const {\n layout\n } = eagerValuesRef.current;\n return layout;\n },\n setLayout: unsafeLayout => {\n const {\n onLayout\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n const safeLayout = validatePanelGroupLayout({\n layout: unsafeLayout,\n panelConstraints: panelDataArray.map(panelData => panelData.constraints)\n });\n if (!areEqual(prevLayout, safeLayout)) {\n setLayout(safeLayout);\n eagerValuesRef.current.layout = safeLayout;\n if (onLayout) {\n onLayout(safeLayout);\n }\n callPanelCallbacks(panelDataArray, safeLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n }\n }), []);\n useIsomorphicLayoutEffect(() => {\n committedValuesRef.current.autoSaveId = autoSaveId;\n committedValuesRef.current.direction = direction;\n committedValuesRef.current.dragState = dragState;\n committedValuesRef.current.id = groupId;\n committedValuesRef.current.onLayout = onLayout;\n committedValuesRef.current.storage = storage;\n });\n useWindowSplitterPanelGroupBehavior({\n committedValuesRef,\n eagerValuesRef,\n groupId,\n layout,\n panelDataArray: eagerValuesRef.current.panelDataArray,\n setLayout,\n panelGroupElement: panelGroupElementRef.current\n });\n useEffect(() => {\n const {\n panelDataArray\n } = eagerValuesRef.current;\n\n // If this panel has been configured to persist sizing information, save sizes to local storage.\n if (autoSaveId) {\n if (layout.length === 0 || layout.length !== panelDataArray.length) {\n return;\n }\n let debouncedSave = debounceMap[autoSaveId];\n\n // Limit the frequency of localStorage updates.\n if (debouncedSave == null) {\n debouncedSave = debounce(savePanelGroupState, LOCAL_STORAGE_DEBOUNCE_INTERVAL);\n debounceMap[autoSaveId] = debouncedSave;\n }\n\n // Clone mutable data before passing to the debounced function,\n // else we run the risk of saving an incorrect combination of mutable and immutable values to state.\n const clonedPanelDataArray = [...panelDataArray];\n const clonedPanelSizesBeforeCollapse = new Map(panelSizeBeforeCollapseRef.current);\n debouncedSave(autoSaveId, clonedPanelDataArray, clonedPanelSizesBeforeCollapse, layout, storage);\n }\n }, [autoSaveId, layout, storage]);\n\n // DEV warnings\n useEffect(() => {\n });\n\n // External APIs are safe to memoize via committed values ref\n const collapsePanel = useCallback(panelData => {\n const {\n onLayout\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n if (panelData.constraints.collapsible) {\n const panelConstraintsArray = panelDataArray.map(panelData => panelData.constraints);\n const {\n collapsedSize = 0,\n panelSize,\n pivotIndices\n } = panelDataHelper(panelDataArray, panelData, prevLayout);\n assert(panelSize != null, `Panel size not found for panel \"${panelData.id}\"`);\n if (!fuzzyNumbersEqual$1(panelSize, collapsedSize)) {\n // Store size before collapse;\n // This is the size that gets restored if the expand() API is used.\n panelSizeBeforeCollapseRef.current.set(panelData.id, panelSize);\n const isLastPanel = findPanelDataIndex(panelDataArray, panelData) === panelDataArray.length - 1;\n const delta = isLastPanel ? panelSize - collapsedSize : collapsedSize - panelSize;\n const nextLayout = adjustLayoutByDelta({\n delta,\n initialLayout: prevLayout,\n panelConstraints: panelConstraintsArray,\n pivotIndices,\n prevLayout,\n trigger: \"imperative-api\"\n });\n if (!compareLayouts(prevLayout, nextLayout)) {\n setLayout(nextLayout);\n eagerValuesRef.current.layout = nextLayout;\n if (onLayout) {\n onLayout(nextLayout);\n }\n callPanelCallbacks(panelDataArray, nextLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n }\n }\n }, []);\n\n // External APIs are safe to memoize via committed values ref\n const expandPanel = useCallback((panelData, minSizeOverride) => {\n const {\n onLayout\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n if (panelData.constraints.collapsible) {\n const panelConstraintsArray = panelDataArray.map(panelData => panelData.constraints);\n const {\n collapsedSize = 0,\n panelSize = 0,\n minSize: minSizeFromProps = 0,\n pivotIndices\n } = panelDataHelper(panelDataArray, panelData, prevLayout);\n const minSize = minSizeOverride !== null && minSizeOverride !== void 0 ? minSizeOverride : minSizeFromProps;\n if (fuzzyNumbersEqual$1(panelSize, collapsedSize)) {\n // Restore this panel to the size it was before it was collapsed, if possible.\n const prevPanelSize = panelSizeBeforeCollapseRef.current.get(panelData.id);\n const baseSize = prevPanelSize != null && prevPanelSize >= minSize ? prevPanelSize : minSize;\n const isLastPanel = findPanelDataIndex(panelDataArray, panelData) === panelDataArray.length - 1;\n const delta = isLastPanel ? panelSize - baseSize : baseSize - panelSize;\n const nextLayout = adjustLayoutByDelta({\n delta,\n initialLayout: prevLayout,\n panelConstraints: panelConstraintsArray,\n pivotIndices,\n prevLayout,\n trigger: \"imperative-api\"\n });\n if (!compareLayouts(prevLayout, nextLayout)) {\n setLayout(nextLayout);\n eagerValuesRef.current.layout = nextLayout;\n if (onLayout) {\n onLayout(nextLayout);\n }\n callPanelCallbacks(panelDataArray, nextLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n }\n }\n }, []);\n\n // External APIs are safe to memoize via committed values ref\n const getPanelSize = useCallback(panelData => {\n const {\n layout,\n panelDataArray\n } = eagerValuesRef.current;\n const {\n panelSize\n } = panelDataHelper(panelDataArray, panelData, layout);\n assert(panelSize != null, `Panel size not found for panel \"${panelData.id}\"`);\n return panelSize;\n }, []);\n\n // This API should never read from committedValuesRef\n const getPanelStyle = useCallback((panelData, defaultSize) => {\n const {\n panelDataArray\n } = eagerValuesRef.current;\n const panelIndex = findPanelDataIndex(panelDataArray, panelData);\n return computePanelFlexBoxStyle({\n defaultSize,\n dragState,\n layout,\n panelData: panelDataArray,\n panelIndex\n });\n }, [dragState, layout]);\n\n // External APIs are safe to memoize via committed values ref\n const isPanelCollapsed = useCallback(panelData => {\n const {\n layout,\n panelDataArray\n } = eagerValuesRef.current;\n const {\n collapsedSize = 0,\n collapsible,\n panelSize\n } = panelDataHelper(panelDataArray, panelData, layout);\n assert(panelSize != null, `Panel size not found for panel \"${panelData.id}\"`);\n return collapsible === true && fuzzyNumbersEqual$1(panelSize, collapsedSize);\n }, []);\n\n // External APIs are safe to memoize via committed values ref\n const isPanelExpanded = useCallback(panelData => {\n const {\n layout,\n panelDataArray\n } = eagerValuesRef.current;\n const {\n collapsedSize = 0,\n collapsible,\n panelSize\n } = panelDataHelper(panelDataArray, panelData, layout);\n assert(panelSize != null, `Panel size not found for panel \"${panelData.id}\"`);\n return !collapsible || fuzzyCompareNumbers(panelSize, collapsedSize) > 0;\n }, []);\n const registerPanel = useCallback(panelData => {\n const {\n panelDataArray\n } = eagerValuesRef.current;\n panelDataArray.push(panelData);\n panelDataArray.sort((panelA, panelB) => {\n const orderA = panelA.order;\n const orderB = panelB.order;\n if (orderA == null && orderB == null) {\n return 0;\n } else if (orderA == null) {\n return -1;\n } else if (orderB == null) {\n return 1;\n } else {\n return orderA - orderB;\n }\n });\n eagerValuesRef.current.panelDataArrayChanged = true;\n forceUpdate();\n }, [forceUpdate]);\n\n // (Re)calculate group layout whenever panels are registered or unregistered.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n useIsomorphicLayoutEffect(() => {\n if (eagerValuesRef.current.panelDataArrayChanged) {\n eagerValuesRef.current.panelDataArrayChanged = false;\n const {\n autoSaveId,\n onLayout,\n storage\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n\n // If this panel has been configured to persist sizing information,\n // default size should be restored from local storage if possible.\n let unsafeLayout = null;\n if (autoSaveId) {\n const state = loadPanelGroupState(autoSaveId, panelDataArray, storage);\n if (state) {\n panelSizeBeforeCollapseRef.current = new Map(Object.entries(state.expandToSizes));\n unsafeLayout = state.layout;\n }\n }\n if (unsafeLayout == null) {\n unsafeLayout = calculateUnsafeDefaultLayout({\n panelDataArray\n });\n }\n\n // Validate even saved layouts in case something has changed since last render\n // e.g. for pixel groups, this could be the size of the window\n const nextLayout = validatePanelGroupLayout({\n layout: unsafeLayout,\n panelConstraints: panelDataArray.map(panelData => panelData.constraints)\n });\n if (!areEqual(prevLayout, nextLayout)) {\n setLayout(nextLayout);\n eagerValuesRef.current.layout = nextLayout;\n if (onLayout) {\n onLayout(nextLayout);\n }\n callPanelCallbacks(panelDataArray, nextLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n }\n });\n\n // Reset the cached layout if hidden by the Activity/Offscreen API\n useIsomorphicLayoutEffect(() => {\n const eagerValues = eagerValuesRef.current;\n return () => {\n eagerValues.layout = [];\n };\n }, []);\n const registerResizeHandle = useCallback(dragHandleId => {\n let isRTL = false;\n const panelGroupElement = panelGroupElementRef.current;\n if (panelGroupElement) {\n const style = window.getComputedStyle(panelGroupElement, null);\n if (style.getPropertyValue(\"direction\") === \"rtl\") {\n isRTL = true;\n }\n }\n return function resizeHandler(event) {\n event.preventDefault();\n const panelGroupElement = panelGroupElementRef.current;\n if (!panelGroupElement) {\n return () => null;\n }\n const {\n direction,\n dragState,\n id: groupId,\n keyboardResizeBy,\n onLayout\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n const {\n initialLayout\n } = dragState !== null && dragState !== void 0 ? dragState : {};\n const pivotIndices = determinePivotIndices(groupId, dragHandleId, panelGroupElement);\n let delta = calculateDeltaPercentage(event, dragHandleId, direction, dragState, keyboardResizeBy, panelGroupElement);\n const isHorizontal = direction === \"horizontal\";\n if (isHorizontal && isRTL) {\n delta = -delta;\n }\n const panelConstraints = panelDataArray.map(panelData => panelData.constraints);\n const nextLayout = adjustLayoutByDelta({\n delta,\n initialLayout: initialLayout !== null && initialLayout !== void 0 ? initialLayout : prevLayout,\n panelConstraints,\n pivotIndices,\n prevLayout,\n trigger: isKeyDown(event) ? \"keyboard\" : \"mouse-or-touch\"\n });\n const layoutChanged = !compareLayouts(prevLayout, nextLayout);\n\n // Only update the cursor for layout changes triggered by touch/mouse events (not keyboard)\n // Update the cursor even if the layout hasn't changed (we may need to show an invalid cursor state)\n if (isPointerEvent(event) || isMouseEvent(event)) {\n // Watch for multiple subsequent deltas; this might occur for tiny cursor movements.\n // In this case, Panel sizes might not change–\n // but updating cursor in this scenario would cause a flicker.\n if (prevDeltaRef.current != delta) {\n prevDeltaRef.current = delta;\n if (!layoutChanged && delta !== 0) {\n // If the pointer has moved too far to resize the panel any further, note this so we can update the cursor.\n // This mimics VS Code behavior.\n if (isHorizontal) {\n reportConstraintsViolation(dragHandleId, delta < 0 ? EXCEEDED_HORIZONTAL_MIN : EXCEEDED_HORIZONTAL_MAX);\n } else {\n reportConstraintsViolation(dragHandleId, delta < 0 ? EXCEEDED_VERTICAL_MIN : EXCEEDED_VERTICAL_MAX);\n }\n } else {\n reportConstraintsViolation(dragHandleId, 0);\n }\n }\n }\n if (layoutChanged) {\n setLayout(nextLayout);\n eagerValuesRef.current.layout = nextLayout;\n if (onLayout) {\n onLayout(nextLayout);\n }\n callPanelCallbacks(panelDataArray, nextLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n };\n }, []);\n\n // External APIs are safe to memoize via committed values ref\n const resizePanel = useCallback((panelData, unsafePanelSize) => {\n const {\n onLayout\n } = committedValuesRef.current;\n const {\n layout: prevLayout,\n panelDataArray\n } = eagerValuesRef.current;\n const panelConstraintsArray = panelDataArray.map(panelData => panelData.constraints);\n const {\n panelSize,\n pivotIndices\n } = panelDataHelper(panelDataArray, panelData, prevLayout);\n assert(panelSize != null, `Panel size not found for panel \"${panelData.id}\"`);\n const isLastPanel = findPanelDataIndex(panelDataArray, panelData) === panelDataArray.length - 1;\n const delta = isLastPanel ? panelSize - unsafePanelSize : unsafePanelSize - panelSize;\n const nextLayout = adjustLayoutByDelta({\n delta,\n initialLayout: prevLayout,\n panelConstraints: panelConstraintsArray,\n pivotIndices,\n prevLayout,\n trigger: \"imperative-api\"\n });\n if (!compareLayouts(prevLayout, nextLayout)) {\n setLayout(nextLayout);\n eagerValuesRef.current.layout = nextLayout;\n if (onLayout) {\n onLayout(nextLayout);\n }\n callPanelCallbacks(panelDataArray, nextLayout, panelIdToLastNotifiedSizeMapRef.current);\n }\n }, []);\n const reevaluatePanelConstraints = useCallback((panelData, prevConstraints) => {\n const {\n layout,\n panelDataArray\n } = eagerValuesRef.current;\n const {\n collapsedSize: prevCollapsedSize = 0,\n collapsible: prevCollapsible\n } = prevConstraints;\n const {\n collapsedSize: nextCollapsedSize = 0,\n collapsible: nextCollapsible,\n maxSize: nextMaxSize = 100,\n minSize: nextMinSize = 0\n } = panelData.constraints;\n const {\n panelSize: prevPanelSize\n } = panelDataHelper(panelDataArray, panelData, layout);\n if (prevPanelSize == null) {\n // It's possible that the panels in this group have changed since the last render\n return;\n }\n if (prevCollapsible && nextCollapsible && fuzzyNumbersEqual$1(prevPanelSize, prevCollapsedSize)) {\n if (!fuzzyNumbersEqual$1(prevCollapsedSize, nextCollapsedSize)) {\n resizePanel(panelData, nextCollapsedSize);\n }\n } else if (prevPanelSize < nextMinSize) {\n resizePanel(panelData, nextMinSize);\n } else if (prevPanelSize > nextMaxSize) {\n resizePanel(panelData, nextMaxSize);\n }\n }, [resizePanel]);\n\n // TODO Multiple drag handles can be active at the same time so this API is a bit awkward now\n const startDragging = useCallback((dragHandleId, event) => {\n const {\n direction\n } = committedValuesRef.current;\n const {\n layout\n } = eagerValuesRef.current;\n if (!panelGroupElementRef.current) {\n return;\n }\n const handleElement = getResizeHandleElement(dragHandleId, panelGroupElementRef.current);\n assert(handleElement, `Drag handle element not found for id \"${dragHandleId}\"`);\n const initialCursorPosition = getResizeEventCursorPosition(direction, event);\n setDragState({\n dragHandleId,\n dragHandleRect: handleElement.getBoundingClientRect(),\n initialCursorPosition,\n initialLayout: layout\n });\n }, []);\n const stopDragging = useCallback(() => {\n setDragState(null);\n }, []);\n const unregisterPanel = useCallback(panelData => {\n const {\n panelDataArray\n } = eagerValuesRef.current;\n const index = findPanelDataIndex(panelDataArray, panelData);\n if (index >= 0) {\n panelDataArray.splice(index, 1);\n\n // TRICKY\n // When a panel is removed from the group, we should delete the most recent prev-size entry for it.\n // If we don't do this, then a conditionally rendered panel might not call onResize when it's re-mounted.\n // Strict effects mode makes this tricky though because all panels will be registered, unregistered, then re-registered on mount.\n delete panelIdToLastNotifiedSizeMapRef.current[panelData.id];\n eagerValuesRef.current.panelDataArrayChanged = true;\n forceUpdate();\n }\n }, [forceUpdate]);\n const context = useMemo(() => ({\n collapsePanel,\n direction,\n dragState,\n expandPanel,\n getPanelSize,\n getPanelStyle,\n groupId,\n isPanelCollapsed,\n isPanelExpanded,\n reevaluatePanelConstraints,\n registerPanel,\n registerResizeHandle,\n resizePanel,\n startDragging,\n stopDragging,\n unregisterPanel,\n panelGroupElement: panelGroupElementRef.current\n }), [collapsePanel, dragState, direction, expandPanel, getPanelSize, getPanelStyle, groupId, isPanelCollapsed, isPanelExpanded, reevaluatePanelConstraints, registerPanel, registerResizeHandle, resizePanel, startDragging, stopDragging, unregisterPanel]);\n const style = {\n display: \"flex\",\n flexDirection: direction === \"horizontal\" ? \"row\" : \"column\",\n height: \"100%\",\n overflow: \"hidden\",\n width: \"100%\"\n };\n return createElement(PanelGroupContext.Provider, {\n value: context\n }, createElement(Type, {\n ...rest,\n children,\n className: classNameFromProps,\n id: idFromProps,\n ref: panelGroupElementRef,\n style: {\n ...style,\n ...styleFromProps\n },\n // CSS selectors\n [DATA_ATTRIBUTES.group]: \"\",\n [DATA_ATTRIBUTES.groupDirection]: direction,\n [DATA_ATTRIBUTES.groupId]: groupId\n }));\n}\nconst PanelGroup = forwardRef((props, ref) => createElement(PanelGroupWithForwardedRef, {\n ...props,\n forwardedRef: ref\n}));\nPanelGroupWithForwardedRef.displayName = \"PanelGroup\";\nPanelGroup.displayName = \"forwardRef(PanelGroup)\";\nfunction findPanelDataIndex(panelDataArray, panelData) {\n return panelDataArray.findIndex(prevPanelData => prevPanelData === panelData || prevPanelData.id === panelData.id);\n}\nfunction panelDataHelper(panelDataArray, panelData, layout) {\n const panelIndex = findPanelDataIndex(panelDataArray, panelData);\n const isLastPanel = panelIndex === panelDataArray.length - 1;\n const pivotIndices = isLastPanel ? [panelIndex - 1, panelIndex] : [panelIndex, panelIndex + 1];\n const panelSize = layout[panelIndex];\n return {\n ...panelData.constraints,\n panelSize,\n pivotIndices\n };\n}\n\n// https://www.w3.org/WAI/ARIA/apg/patterns/windowsplitter/\n\nfunction useWindowSplitterResizeHandlerBehavior({\n disabled,\n handleId,\n resizeHandler,\n panelGroupElement\n}) {\n useEffect(() => {\n if (disabled || resizeHandler == null || panelGroupElement == null) {\n return;\n }\n const handleElement = getResizeHandleElement(handleId, panelGroupElement);\n if (handleElement == null) {\n return;\n }\n const onKeyDown = event => {\n if (event.defaultPrevented) {\n return;\n }\n switch (event.key) {\n case \"ArrowDown\":\n case \"ArrowLeft\":\n case \"ArrowRight\":\n case \"ArrowUp\":\n case \"End\":\n case \"Home\":\n {\n event.preventDefault();\n resizeHandler(event);\n break;\n }\n case \"F6\":\n {\n event.preventDefault();\n const groupId = handleElement.getAttribute(DATA_ATTRIBUTES.groupId);\n assert(groupId, `No group element found for id \"${groupId}\"`);\n const handles = getResizeHandleElementsForGroup(groupId, panelGroupElement);\n const index = getResizeHandleElementIndex(groupId, handleId, panelGroupElement);\n assert(index !== null, `No resize element found for id \"${handleId}\"`);\n const nextIndex = event.shiftKey ? index > 0 ? index - 1 : handles.length - 1 : index + 1 < handles.length ? index + 1 : 0;\n const nextHandle = handles[nextIndex];\n nextHandle.focus();\n break;\n }\n }\n };\n handleElement.addEventListener(\"keydown\", onKeyDown);\n return () => {\n handleElement.removeEventListener(\"keydown\", onKeyDown);\n };\n }, [panelGroupElement, disabled, handleId, resizeHandler]);\n}\n\nfunction PanelResizeHandle({\n children = null,\n className: classNameFromProps = \"\",\n disabled = false,\n hitAreaMargins,\n id: idFromProps,\n onBlur,\n onClick,\n onDragging,\n onFocus,\n onPointerDown,\n onPointerUp,\n style: styleFromProps = {},\n tabIndex = 0,\n tagName: Type = \"div\",\n ...rest\n}) {\n var _hitAreaMargins$coars, _hitAreaMargins$fine;\n const elementRef = useRef(null);\n\n // Use a ref to guard against users passing inline props\n const callbacksRef = useRef({\n onClick,\n onDragging,\n onPointerDown,\n onPointerUp\n });\n useEffect(() => {\n callbacksRef.current.onClick = onClick;\n callbacksRef.current.onDragging = onDragging;\n callbacksRef.current.onPointerDown = onPointerDown;\n callbacksRef.current.onPointerUp = onPointerUp;\n });\n const panelGroupContext = useContext(PanelGroupContext);\n if (panelGroupContext === null) {\n throw Error(`PanelResizeHandle components must be rendered within a PanelGroup container`);\n }\n const {\n direction,\n groupId,\n registerResizeHandle: registerResizeHandleWithParentGroup,\n startDragging,\n stopDragging,\n panelGroupElement\n } = panelGroupContext;\n const resizeHandleId = useUniqueId(idFromProps);\n const [state, setState] = useState(\"inactive\");\n const [isFocused, setIsFocused] = useState(false);\n const [resizeHandler, setResizeHandler] = useState(null);\n const committedValuesRef = useRef({\n state\n });\n useIsomorphicLayoutEffect(() => {\n committedValuesRef.current.state = state;\n });\n useEffect(() => {\n if (disabled) {\n setResizeHandler(null);\n } else {\n const resizeHandler = registerResizeHandleWithParentGroup(resizeHandleId);\n setResizeHandler(() => resizeHandler);\n }\n }, [disabled, resizeHandleId, registerResizeHandleWithParentGroup]);\n\n // Extract hit area margins before passing them to the effect's dependency array\n // so that inline object values won't trigger re-renders\n const coarseHitAreaMargins = (_hitAreaMargins$coars = hitAreaMargins === null || hitAreaMargins === void 0 ? void 0 : hitAreaMargins.coarse) !== null && _hitAreaMargins$coars !== void 0 ? _hitAreaMargins$coars : 15;\n const fineHitAreaMargins = (_hitAreaMargins$fine = hitAreaMargins === null || hitAreaMargins === void 0 ? void 0 : hitAreaMargins.fine) !== null && _hitAreaMargins$fine !== void 0 ? _hitAreaMargins$fine : 5;\n useEffect(() => {\n if (disabled || resizeHandler == null) {\n return;\n }\n const element = elementRef.current;\n assert(element, \"Element ref not attached\");\n let didMove = false;\n const setResizeHandlerState = (action, isActive, event) => {\n if (!isActive) {\n setState(\"inactive\");\n return;\n }\n switch (action) {\n case \"down\":\n {\n setState(\"drag\");\n didMove = false;\n assert(event, 'Expected event to be defined for \"down\" action');\n startDragging(resizeHandleId, event);\n const {\n onDragging,\n onPointerDown\n } = callbacksRef.current;\n onDragging === null || onDragging === void 0 ? void 0 : onDragging(true);\n onPointerDown === null || onPointerDown === void 0 ? void 0 : onPointerDown();\n break;\n }\n case \"move\":\n {\n const {\n state\n } = committedValuesRef.current;\n didMove = true;\n if (state !== \"drag\") {\n setState(\"hover\");\n }\n assert(event, 'Expected event to be defined for \"move\" action');\n resizeHandler(event);\n break;\n }\n case \"up\":\n {\n setState(\"hover\");\n stopDragging();\n const {\n onClick,\n onDragging,\n onPointerUp\n } = callbacksRef.current;\n onDragging === null || onDragging === void 0 ? void 0 : onDragging(false);\n onPointerUp === null || onPointerUp === void 0 ? void 0 : onPointerUp();\n if (!didMove) {\n onClick === null || onClick === void 0 ? void 0 : onClick();\n }\n break;\n }\n }\n };\n return registerResizeHandle(resizeHandleId, element, direction, {\n coarse: coarseHitAreaMargins,\n fine: fineHitAreaMargins\n }, setResizeHandlerState);\n }, [coarseHitAreaMargins, direction, disabled, fineHitAreaMargins, registerResizeHandleWithParentGroup, resizeHandleId, resizeHandler, startDragging, stopDragging]);\n useWindowSplitterResizeHandlerBehavior({\n disabled,\n handleId: resizeHandleId,\n resizeHandler,\n panelGroupElement\n });\n const style = {\n touchAction: \"none\",\n userSelect: \"none\"\n };\n return createElement(Type, {\n ...rest,\n children,\n className: classNameFromProps,\n id: idFromProps,\n onBlur: () => {\n setIsFocused(false);\n onBlur === null || onBlur === void 0 ? void 0 : onBlur();\n },\n onFocus: () => {\n setIsFocused(true);\n onFocus === null || onFocus === void 0 ? void 0 : onFocus();\n },\n ref: elementRef,\n role: \"separator\",\n style: {\n ...style,\n ...styleFromProps\n },\n tabIndex,\n // CSS selectors\n [DATA_ATTRIBUTES.groupDirection]: direction,\n [DATA_ATTRIBUTES.groupId]: groupId,\n [DATA_ATTRIBUTES.resizeHandle]: \"\",\n [DATA_ATTRIBUTES.resizeHandleActive]: state === \"drag\" ? \"pointer\" : isFocused ? \"keyboard\" : undefined,\n [DATA_ATTRIBUTES.resizeHandleEnabled]: !disabled,\n [DATA_ATTRIBUTES.resizeHandleId]: resizeHandleId,\n [DATA_ATTRIBUTES.resizeHandleState]: state\n });\n}\nPanelResizeHandle.displayName = \"PanelResizeHandle\";\n\nfunction usePanelGroupContext() {\n const context = useContext(PanelGroupContext);\n return {\n direction: context === null || context === void 0 ? void 0 : context.direction,\n groupId: context === null || context === void 0 ? void 0 : context.groupId\n };\n}\n\nfunction getPanelElement(id, scope = document) {\n const element = scope.querySelector(`[data-panel-id=\"${id}\"]`);\n if (element) {\n return element;\n }\n return null;\n}\n\nfunction getPanelElementsForGroup(groupId, scope = document) {\n return Array.from(scope.querySelectorAll(`[data-panel][data-panel-group-id=\"${groupId}\"]`));\n}\n\nfunction getIntersectingRectangle(rectOne, rectTwo, strict) {\n if (!intersects(rectOne, rectTwo, strict)) {\n return {\n x: 0,\n y: 0,\n width: 0,\n height: 0\n };\n }\n return {\n x: Math.max(rectOne.x, rectTwo.x),\n y: Math.max(rectOne.y, rectTwo.y),\n width: Math.min(rectOne.x + rectOne.width, rectTwo.x + rectTwo.width) - Math.max(rectOne.x, rectTwo.x),\n height: Math.min(rectOne.y + rectOne.height, rectTwo.y + rectTwo.height) - Math.max(rectOne.y, rectTwo.y)\n };\n}\n\nexport { DATA_ATTRIBUTES, Panel, PanelGroup, PanelResizeHandle, assert, customizeGlobalCursorStyles, disableGlobalCursorStyles, enableGlobalCursorStyles, getIntersectingRectangle, getPanelElement, getPanelElementsForGroup, getPanelGroupElement, getResizeHandleElement, getResizeHandleElementIndex, getResizeHandleElementsForGroup, getResizeHandlePanelIds, intersects, setNonce, usePanelGroupContext };\n"],"names":["isBrowser","window","PanelGroupContext","createContext","displayName","DATA_ATTRIBUTES","group","groupDirection","groupId","panel","panelCollapsible","panelId","panelSize","resizeHandle","resizeHandleActive","resizeHandleEnabled","resizeHandleId","resizeHandleState","useIsomorphicLayoutEffect","useLayoutEffect","useId","React","toString","wrappedUseId","counter","useUniqueId","idFromParams","idFromUseId","idRef","useRef","current","PanelWithForwardedRef","children","className","classNameFromProps","collapsedSize","collapsible","defaultSize","forwardedRef","id","idFromProps","maxSize","minSize","onCollapse","onExpand","onResize","order","style","styleFromProps","tagName","Type","rest","context","useContext","Error","collapsePanel","expandPanel","getPanelSize","getPanelStyle","isPanelCollapsed","reevaluatePanelConstraints","registerPanel","resizePanel","unregisterPanel","panelDataRef","callbacks","constraints","idIsFromProps","undefined","didLogMissingDefaultSizeWarning","prevConstraints","panelData","useImperativeHandle","collapse","expand","getId","getSize","isCollapsed","isExpanded","resize","size","createElement","parseFloat","flexGrow","toFixed","Panel","forwardRef","props","ref","currentCursorStyle","prevRuleIndex","styleElement","setGlobalCursorStyle","state","constraintFlags","isPointerDown","_styleElement$sheet$i","_styleElement$sheet2","verticalMin","EXCEEDED_VERTICAL_MIN","verticalMax","EXCEEDED_VERTICAL_MAX","EXCEEDED_HORIZONTAL_MIN","EXCEEDED_HORIZONTAL_MAX","getCursorStyle","_styleElement$sheet","document","head","appendChild","sheet","removeRule","insertRule","isKeyDown","event","type","isPointerEvent","startsWith","isMouseEvent","getResizeEventCoordinates","isPrimary","x","clientX","y","clientY","Infinity","intersects","rectOne","rectTwo","strict","width","height","creates_stacking_context","node","getComputedStyle","position","zIndex","_get_parent","display","get_parent","is_flex_item","opacity","transform","webkitTransform","mixBlendMode","filter","webkitFilter","isolation","test","willChange","webkitOverflowScrolling","find_stacking_context","nodes","i","length","assert","get_z_index","Number","get_ancestors","ancestors","push","parentNode","ShadowRoot","host","isCoarsePointer","matchMedia","matches","getInputType","intersectingHandles","ownerDocumentCounts","Map","panelConstraintFlags","registeredResizeHandlers","Set","handlePointerDown","target","recalculateIntersectingHandles","updateListeners","updateResizeHandlerStates","updateCursor","preventDefault","isWithinResizeHandle","stopImmediatePropagation","handlePointerMove","buttons","handlePointerUp","clear","element","currentElement","hasAttribute","parentElement","splice","targetElement","HTMLElement","SVGElement","forEach","data","dragHandleElement","hitAreaMargins","dragHandleRect","getBoundingClientRect","bottom","left","right","top","margin","coarse","fine","contains","a","b","common_ancestor","at","pop","z_indexes","childNodes","furthest_ancestors","child","Math","sign","compare","didIntersect","reportConstraintsViolation","flag","set","intersectsHorizontal","intersectsVertical","direction","removeChild","listenersAbortController","_listenersAbortContro","abort","AbortController","options","capture","signal","count","ownerDocument","body","addEventListener","_","action","setResizeHandlerState","isActive","includes","expectedCondition","message","console","error","fuzzyCompareNumbers","actual","expected","fractionDigits","fuzzyNumbersEqual$1","fuzzyNumbersEqual","panelConstraints","panelConstraintsArray","panelIndex","min","adjustLayoutByDelta","delta","initialLayout","pivotIndices","prevLayout","trigger","nextLayout","firstPivotIndex","secondPivotIndex","deltaApplied","index","prevSize","localDelta","abs","increment","maxAvailableDelta","minAbsDelta","deltaRemaining","safeSize","localeCompare","numeric","fuzzyLayoutsEqual","pivotIndex","unsafeSize","reduce","total","calculateAriaValues","layout","panelsArray","currentMinSize","currentMaxSize","totalMinSize","totalMaxSize","firstIndex","valueMax","valueMin","max","valueNow","getResizeHandleElementsForGroup","scope","Array","from","querySelectorAll","getResizeHandleElementIndex","findIndex","handle","getAttribute","determinePivotIndices","dragHandleId","panelGroupElement","getPanelGroupElement","rootElement","dataset","panelGroupId","querySelector","getResizeHandleElement","getResizeHandlePanelIds","handleId","_panelsArray$index$id","_panelsArray$index","_panelsArray$id","_panelsArray","handles","indexOf","areEqual","arrayA","arrayB","getResizeEventCursorPosition","isHorizontal","calculateDeltaPercentage","initialDragState","keyboardResizeBy","shiftKey","movement","key","handleElement","initialCursorPosition","cursorPosition","groupElement","groupRect","calculateDragOffsetPercentage","callPanelCallbacks","panelIdToLastNotifiedSizeMap","lastNotifiedSize","compareLayouts","initializeDefaultStorage","storageObject","localStorage","getItem","name","setItem","value","getPanelGroupKey","autoSaveId","getPanelKey","panels","map","JSON","stringify","sort","join","loadSerializedPanelGroupState","storage","panelGroupKey","serialized","parsed","parse","savePanelGroupState","panelSizesBeforeCollapse","sizes","_loadSerializedPanelG2","panelKey","expandToSizes","Object","fromEntries","entries","validatePanelGroupLayout","nextLayoutTotalSize","accumulated","remainingSize","defaultStorage","debounceMap","PanelGroupWithForwardedRef","onLayout","panelGroupElementRef","dragState","setDragState","useState","setLayout","forceUpdate","setCount","useCallback","prevCount","useForceUpdate","panelIdToLastNotifiedSizeMapRef","panelSizeBeforeCollapseRef","prevDeltaRef","committedValuesRef","eagerValuesRef","panelDataArray","panelDataArrayChanged","didLogIdAndOrderWarning","didLogPanelConstraintsWarning","prevPanelIds","getLayout","unsafeLayout","safeLayout","didWarnAboutMissingResizeHandle","resizeHandleElements","resizeHandleElement","setAttribute","round","removeAttribute","useEffect","eagerValues","cleanupFunctions","idBefore","idAfter","onKeyDown","defaultPrevented","removeEventListener","cleanupFunction","useWindowSplitterPanelGroupBehavior","debouncedSave","callback","durationMs","timeoutId","args","clearTimeout","setTimeout","debounce","clonedPanelDataArray","clonedPanelSizesBeforeCollapse","panelDataHelper","findPanelDataIndex","minSizeOverride","minSizeFromProps","prevPanelSize","get","baseSize","precision","flexBasis","flexShrink","overflow","pointerEvents","computePanelFlexBoxStyle","isPanelExpanded","panelA","panelB","orderA","orderB","_loadSerializedPanelG","_state$panelKey","loadPanelGroupState","numPanelsWithSizes","calculateUnsafeDefaultLayout","registerResizeHandle","isRTL","getPropertyValue","layoutChanged","unsafePanelSize","prevCollapsedSize","prevCollapsible","nextCollapsedSize","nextCollapsible","nextMaxSize","nextMinSize","startDragging","stopDragging","useMemo","flexDirection","Provider","PanelGroup","prevPanelData","PanelResizeHandle","disabled","onBlur","onClick","onDragging","onFocus","onPointerDown","onPointerUp","tabIndex","_hitAreaMargins$coars","_hitAreaMargins$fine","elementRef","callbacksRef","panelGroupContext","registerResizeHandleWithParentGroup","setState","isFocused","setIsFocused","resizeHandler","setResizeHandler","coarseHitAreaMargins","fineHitAreaMargins","didMove","_ownerDocumentCounts$","add","_ownerDocumentCounts$2","delete","focus","useWindowSplitterResizeHandlerBehavior","role","touchAction","userSelect"],"mappings":"qYAGA,MAAMA,EAA8B,oBAAXC,OAInBC,EAAoBC,EAAAA,cAAc,MACxCD,EAAkBE,YAAc,oBAE3B,MAACC,EAAkB,CACtBC,M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AAIA,EAAQ,EAAIoD,EAAQvK,OAAS,EAAImH,EAAQ,EAAIoD,EAAQvK,OAASmH,EAAQ,EAAI,GAE9GuO,QACX,KACD,EACJ,EAGH,OADAtK,EAAc/F,iBAAiB,UAAWkL,GACnC,KACLnF,EAAcqF,oBAAoB,UAAWF,EAAU,CACxD,GACA,CAAC7G,EAAmBsK,EAAU9J,EAAU+K,GAC7C,CAqIEU,CAAuC,CACrC3B,WACA9J,SAAU3S,EACV0d,gBACAvL,sBAMF,OAAOlO,EAAAA,cAAc/B,EAAM,IACtBC,EACHnB,WACAC,UAAWC,EACXK,GAAIC,EACJkb,OAAQ,KACNe,GAAa,GACbf,SAAgDA,GAAQ,EAE1DG,QAAS,KACPY,GAAa,GACbZ,SAAkDA,GAAS,EAE7DrY,IAAK2Y,EACLkB,KAAM,YACNtc,MAAO,CAlBPuc,YAAa,OACbC,WAAY,UAmBPvc,GAELgb,WAEA,CAAC3d,EAAgBE,gBAAiB2N,EAClC,CAAC7N,EAAgBG,SAAUA,EAC3B,CAACH,EAAgBQ,cAAe,GAChC,CAACR,EAAgBS,oBAA+B,SAAV+E,EAAmB,UAAY2Y,EAAY,gBAAapa,EAC9F,CAAC/D,EAAgBU,sBAAuB0c,EACxC,CAACpd,EAAgBW,gBAAiBA,EAClC,CAACX,EAAgBY,mBAAoB4E,GAEzC,CAjPA+R,GAA2BxX,YAAc,aACzCkd,GAAWld,YAAc,yBAiPzBod,GAAkBpd,YAAc"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("os"),e=require("tty"),t=require("../has-flag/index.js");function o(r){return r&&"object"==typeof r&&"default"in r?r:{default:r}}var n,i,s=o(r),u=o(e);exports.__require=function(){if(i)return n;i=1;const r=s.default,e=u.default,o=t.__require(),{env:l}=process;let c;function R(r){return 0!==r&&{level:r,hasBasic:!0,has256:r>=2,has16m:r>=3}}function a(e,t){if(0===c)return 0;if(o("color=16m")||o("color=full")||o("color=truecolor"))return 3;if(o("color=256"))return 2;if(e&&!t&&void 0===c)return 0;const n=c||0;if("dumb"===l.TERM)return n;if("win32"===process.platform){const e=r.release().split(".");return Number(e[0])>=10&&Number(e[2])>=10586?Number(e[2])>=14931?3:2:1}if("CI"in l)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some((r=>r in l))||"codeship"===l.CI_NAME?1:n;if("TEAMCITY_VERSION"in l)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(l.TEAMCITY_VERSION)?1:0;if("truecolor"===l.COLORTERM)return 3;if("TERM_PROGRAM"in l){const r=parseInt((l.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(l.TERM_PROGRAM){case"iTerm.app":return r>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(l.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(l.TERM)||"COLORTERM"in l?1:n}return o("no-color")||o("no-colors")||o("color=false")||o("color=never")?c=0:(o("color")||o("colors")||o("color=true")||o("color=always"))&&(c=1),"FORCE_COLOR"in l&&(c="true"===l.FORCE_COLOR?1:"false"===l.FORCE_COLOR?0:0===l.FORCE_COLOR.length?1:Math.min(parseInt(l.FORCE_COLOR,10),3)),n={supportsColor:function(r){return R(a(r,r&&r.isTTY))},stdout:R(a(!0,e.isatty(1))),stderr:R(a(!0,e.isatty(2)))}};
|
|
2
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../node_modules/supports-color/index.js"],"sourcesContent":["'use strict';\nconst os = require('os');\nconst tty = require('tty');\nconst hasFlag = require('has-flag');\n\nconst {env} = process;\n\nlet forceColor;\nif (hasFlag('no-color') ||\n\thasFlag('no-colors') ||\n\thasFlag('color=false') ||\n\thasFlag('color=never')) {\n\tforceColor = 0;\n} else if (hasFlag('color') ||\n\thasFlag('colors') ||\n\thasFlag('color=true') ||\n\thasFlag('color=always')) {\n\tforceColor = 1;\n}\n\nif ('FORCE_COLOR' in env) {\n\tif (env.FORCE_COLOR === 'true') {\n\t\tforceColor = 1;\n\t} else if (env.FORCE_COLOR === 'false') {\n\t\tforceColor = 0;\n\t} else {\n\t\tforceColor = env.FORCE_COLOR.length === 0 ? 1 : Math.min(parseInt(env.FORCE_COLOR, 10), 3);\n\t}\n}\n\nfunction translateLevel(level) {\n\tif (level === 0) {\n\t\treturn false;\n\t}\n\n\treturn {\n\t\tlevel,\n\t\thasBasic: true,\n\t\thas256: level >= 2,\n\t\thas16m: level >= 3\n\t};\n}\n\nfunction supportsColor(haveStream, streamIsTTY) {\n\tif (forceColor === 0) {\n\t\treturn 0;\n\t}\n\n\tif (hasFlag('color=16m') ||\n\t\thasFlag('color=full') ||\n\t\thasFlag('color=truecolor')) {\n\t\treturn 3;\n\t}\n\n\tif (hasFlag('color=256')) {\n\t\treturn 2;\n\t}\n\n\tif (haveStream && !streamIsTTY && forceColor === undefined) {\n\t\treturn 0;\n\t}\n\n\tconst min = forceColor || 0;\n\n\tif (env.TERM === 'dumb') {\n\t\treturn min;\n\t}\n\n\tif (process.platform === 'win32') {\n\t\t// Windows 10 build 10586 is the first Windows release that supports 256 colors.\n\t\t// Windows 10 build 14931 is the first release that supports 16m/TrueColor.\n\t\tconst osRelease = os.release().split('.');\n\t\tif (\n\t\t\tNumber(osRelease[0]) >= 10 &&\n\t\t\tNumber(osRelease[2]) >= 10586\n\t\t) {\n\t\t\treturn Number(osRelease[2]) >= 14931 ? 3 : 2;\n\t\t}\n\n\t\treturn 1;\n\t}\n\n\tif ('CI' in env) {\n\t\tif (['TRAVIS', 'CIRCLECI', 'APPVEYOR', 'GITLAB_CI', 'GITHUB_ACTIONS', 'BUILDKITE'].some(sign => sign in env) || env.CI_NAME === 'codeship') {\n\t\t\treturn 1;\n\t\t}\n\n\t\treturn min;\n\t}\n\n\tif ('TEAMCITY_VERSION' in env) {\n\t\treturn /^(9\\.(0*[1-9]\\d*)\\.|\\d{2,}\\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;\n\t}\n\n\tif (env.COLORTERM === 'truecolor') {\n\t\treturn 3;\n\t}\n\n\tif ('TERM_PROGRAM' in env) {\n\t\tconst version = parseInt((env.TERM_PROGRAM_VERSION || '').split('.')[0], 10);\n\n\t\tswitch (env.TERM_PROGRAM) {\n\t\t\tcase 'iTerm.app':\n\t\t\t\treturn version >= 3 ? 3 : 2;\n\t\t\tcase 'Apple_Terminal':\n\t\t\t\treturn 2;\n\t\t\t// No default\n\t\t}\n\t}\n\n\tif (/-256(color)?$/i.test(env.TERM)) {\n\t\treturn 2;\n\t}\n\n\tif (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {\n\t\treturn 1;\n\t}\n\n\tif ('COLORTERM' in env) {\n\t\treturn 1;\n\t}\n\n\treturn min;\n}\n\nfunction getSupportLevel(stream) {\n\tconst level = supportsColor(stream, stream && stream.isTTY);\n\treturn translateLevel(level);\n}\n\nmodule.exports = {\n\tsupportsColor: getSupportLevel,\n\tstdout: translateLevel(supportsColor(true, tty.isatty(1))),\n\tstderr: translateLevel(supportsColor(true, tty.isatty(2)))\n};\n"],"names":["os","require$$0","tty","require$$1","hasFlag","require$$2","env","process","forceColor","translateLevel","level","hasBasic","has256","has16m","supportsColor","haveStream","streamIsTTY","undefined","min","TERM","platform","osRelease","release","split","Number","some","sign","CI_NAME","test","TEAMCITY_VERSION","COLORTERM","version","parseInt","TERM_PROGRAM_VERSION","TERM_PROGRAM","FORCE_COLOR","length","Math","supportsColor_1","stream","isTTY","stdout","isatty","stderr"],"mappings":"wRACA,MAAMA,EAAKC,EAAAA,QACLC,EAAMC,EAAAA,QACNC,EAAUC,EAAAA,aAEVC,IAACA,GAAOC,QAEd,IAAIC,EAuBJ,SAASC,EAAeC,GACvB,OAAc,IAAVA,GAIG,CACNA,QACAC,UAAU,EACVC,OAAQ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AI6B,YACM,EACiB,UAApB7B,EAAI6B,YACD,EAE2B,IAA3B7B,EAAI6B,YAAYC,OAAe,EAAIC,KAAKnB,IAAIc,SAAS1B,EAAI6B,YAAa,IAAK,IAwG1FG,EAAiB,CAChBxB,cAND,SAAyByB,GAExB,OAAO9B,EADOK,EAAcyB,EAAQA,GAAUA,EAAOC,OAEtD,EAICC,OAAQhC,EAAeK,GAAc,EAAMZ,EAAIwC,OAAO,KACtDC,OAAQlC,EAAeK,GAAc,EAAMZ,EAAIwC,OAAO"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../node_modules/asynckit/index.js"],"sourcesContent":["module.exports =\n{\n parallel : require('./parallel.js'),\n serial : require('./serial.js'),\n serialOrdered : require('./serialOrdered.js')\n};\n"],"names":["asynckit","parallel","require$$0","serial","require$$1","serialOrdered","require$$2"],"mappings":"sKAAcA,EACd,CACEC,SAAgBC,IAChBC,OAAgBC,IAChBC,cAAgBC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"abort.js","sources":["../../../../node_modules/asynckit/lib/abort.js"],"sourcesContent":["// API\nmodule.exports = abort;\n\n/**\n * Aborts leftover active jobs\n *\n * @param {object} state - current state object\n */\nfunction abort(state)\n{\n Object.keys(state.jobs).forEach(clean.bind(state));\n\n // reset leftover jobs\n state.jobs = {};\n}\n\n/**\n * Cleans up leftover job by invoking abort function for the provided job id\n *\n * @this state\n * @param {string|number} key - job id to abort\n */\nfunction clean(key)\n{\n if (typeof this.jobs[key] == 'function')\n {\n this.jobs[key]();\n }\n}\n"],"names":["clean","key","this","jobs","abort_1","state","Object","keys","forEach","bind"],"mappings":"mCAsBA,SAASA,EAAMC,GAEgB,mBAAlBC,KAAKC,KAAKF,IAEnBC,KAAKC,KAAKF,IAEd,YA3BAG,EAOA,SAAeC,GAEbC,OAAOC,KAAKF,EAAMF,MAAMK,QAAQR,EAAMS,KAAKJ,IAG3CA,EAAMF,KAAO,EACf"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"async.js","sources":["../../../../node_modules/asynckit/lib/async.js"],"sourcesContent":["var defer = require('./defer.js');\n\n// API\nmodule.exports = async;\n\n/**\n * Runs provided callback asynchronously\n * even if callback itself is not\n *\n * @param {function} callback - callback to invoke\n * @returns {function} - augmented callback\n */\nfunction async(callback)\n{\n var isAsync = false;\n\n // check if async happened\n defer(function() { isAsync = true; });\n\n return function async_callback(err, result)\n {\n if (isAsync)\n {\n callback(err, result);\n }\n else\n {\n defer(function nextTick_callback()\n {\n callback(err, result);\n });\n }\n };\n}\n"],"names":["defer","require$$0","async_1","callback","isAsync","err","result"],"mappings":"8EAAA,IAAIA,EAAQC,WAGZC,EASA,SAAeC,GAEb,IAAIC,GAAU,EAKd,OAFAJ,GAAM,WAAaI,GAAU,CAAO,IAE7B,SAAwBC,EAAKC,GAE9BF,EAEFD,EAASE,EAAKC,GAIdN,GAAM,WAEJG,EAASE,EAAKC,EACtB,IAGA"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
var e,t;function n(){if(t)return e;return t=1,e=function(e){var t="function"==typeof setImmediate?setImmediate:"object"==typeof process&&"function"==typeof process.nextTick?process.nextTick:null;t?t(e):setTimeout(e,0)}}export{n as __require};
|
|
2
|
-
//# sourceMappingURL=defer.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"defer.js","sources":["../../../../node_modules/asynckit/lib/defer.js"],"sourcesContent":["module.exports = defer;\n\n/**\n * Runs provided function on next iteration of the event loop\n *\n * @param {function} fn - function to run\n */\nfunction defer(fn)\n{\n var nextTick = typeof setImmediate == 'function'\n ? setImmediate\n : (\n typeof process == 'object' && typeof process.nextTick == 'function'\n ? process.nextTick\n : null\n );\n\n if (nextTick)\n {\n nextTick(fn);\n }\n else\n {\n setTimeout(fn, 0);\n }\n}\n"],"names":["defer_1","fn","nextTick","setImmediate","process","setTimeout"],"mappings":"8CAAAA,EAOA,SAAeC,GAEb,IAAIC,EAAkC,mBAAhBC,aAClBA,aAEkB,iBAAXC,SAAkD,mBAApBA,QAAQF,SAC3CE,QAAQF,SACR,KAGFA,EAEFA,EAASD,GAITI,WAAWJ,EAAI,EAEnB"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__require as r}from"./async.js";import{__require as e}from"./abort.js";var t,n;function i(){if(n)return t;n=1;var i=r(),s=e();return t=function(r,e,t,n){var o=t.keyedList?t.keyedList[t.index]:t.index;t.jobs[o]=function(r,e,t,n){var s;s=2==r.length?r(t,i(n)):r(t,e,i(n));return s}(e,o,r[o],(function(r,e){o in t.jobs&&(delete t.jobs[o],r?s(t):t.results[o]=e,n(r,t.results))}))}}export{i as __require};
|
|
2
|
-
//# sourceMappingURL=iterate.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"iterate.js","sources":["../../../../node_modules/asynckit/lib/iterate.js"],"sourcesContent":["var async = require('./async.js')\n , abort = require('./abort.js')\n ;\n\n// API\nmodule.exports = iterate;\n\n/**\n * Iterates over each job object\n *\n * @param {array|object} list - array or object (named list) to iterate over\n * @param {function} iterator - iterator to run\n * @param {object} state - current job status\n * @param {function} callback - invoked when all elements processed\n */\nfunction iterate(list, iterator, state, callback)\n{\n // store current index\n var key = state['keyedList'] ? state['keyedList'][state.index] : state.index;\n\n state.jobs[key] = runJob(iterator, key, list[key], function(error, output)\n {\n // don't repeat yourself\n // skip secondary callbacks\n if (!(key in state.jobs))\n {\n return;\n }\n\n // clean up jobs\n delete state.jobs[key];\n\n if (error)\n {\n // don't process rest of the results\n // stop still active jobs\n // and reset the list\n abort(state);\n }\n else\n {\n state.results[key] = output;\n }\n\n // return salvaged results\n callback(error, state.results);\n });\n}\n\n/**\n * Runs iterator over provided job element\n *\n * @param {function} iterator - iterator to invoke\n * @param {string|number} key - key/index of the element in the list of jobs\n * @param {mixed} item - job description\n * @param {function} callback - invoked after iterator is done with the job\n * @returns {function|mixed} - job abort function or something else\n */\nfunction runJob(iterator, key, item, callback)\n{\n var aborter;\n\n // allow shortcut if iterator expects only two arguments\n if (iterator.length == 2)\n {\n aborter = iterator(item, async(callback));\n }\n // otherwise go with full three arguments\n else\n {\n aborter = iterator(item, key, async(callback));\n }\n\n return aborter;\n}\n"],"names":["async","require$$0","abort","require$$1","iterate_1","list","iterator","state","callback","key","index","jobs","item","aborter","length","runJob","error","output","results"],"mappings":"qHAAA,IAAIA,EAAQC,IACRC,EAAQC,WAIZC,EAUA,SAAiBC,EAAMC,EAAUC,EAAOC,GAGtC,IAAIC,EAAMF,EAAiB,UAAIA,EAAiB,UAAEA,EAAMG,OAASH,EAAMG,MAEvEH,EAAMI,KAAKF,GAsCb,SAAgBH,EAAUG,EAAKG,EAAMJ,GAEnC,IAAIK,EAKFA,EAFqB,GAAnBP,EAASQ,OAEDR,EAASM,EAAMZ,EAAMQ,IAKrBF,EAASM,EAAMH,EAAKT,EAAMQ,IAGtC,OAAOK,CACT,CAtDoBE,CAAOT,EAAUG,EAAKJ,EAAKI,IAAM,SAASO,EAAOC,GAI3DR,KAAOF,EAAMI,cAMZJ,EAAMI,KAAKF,GAEdO,EAKFd,EAAMK,GAINA,EAAMW,QAAQT,GAAOQ,EAIvBT,EAASQ,EAAOT,EAAMW,SAC1B,GACA"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
var e,r;function t(){if(r)return e;return r=1,e=function(e,r){var t=!Array.isArray(e),n={index:0,keyedList:t||r?Object.keys(e):null,jobs:{},results:t?{}:[],size:t?Object.keys(e).length:e.length};r&&n.keyedList.sort(t?r:function(t,n){return r(e[t],e[n])});return n}}export{t as __require};
|
|
2
|
-
//# sourceMappingURL=state.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"state.js","sources":["../../../../node_modules/asynckit/lib/state.js"],"sourcesContent":["// API\nmodule.exports = state;\n\n/**\n * Creates initial state object\n * for iteration over list\n *\n * @param {array|object} list - list to iterate over\n * @param {function|null} sortMethod - function to use for keys sort,\n * or `null` to keep them as is\n * @returns {object} - initial state object\n */\nfunction state(list, sortMethod)\n{\n var isNamedList = !Array.isArray(list)\n , initState =\n {\n index : 0,\n keyedList: isNamedList || sortMethod ? Object.keys(list) : null,\n jobs : {},\n results : isNamedList ? {} : [],\n size : isNamedList ? Object.keys(list).length : list.length\n }\n ;\n\n if (sortMethod)\n {\n // sort array keys based on it's values\n // sort object's keys just on own merit\n initState.keyedList.sort(isNamedList ? sortMethod : function(a, b)\n {\n return sortMethod(list[a], list[b]);\n });\n }\n\n return initState;\n}\n"],"names":["state_1","list","sortMethod","isNamedList","Array","isArray","initState","index","keyedList","Object","keys","jobs","results","size","length","sort","a","b"],"mappings":"8CACAA,EAWA,SAAeC,EAAMC,GAEnB,IAAIC,GAAeC,MAAMC,QAAQJ,GAC7BK,EACF,CACEC,MAAW,EACXC,UAAWL,GAAeD,EAAaO,OAAOC,KAAKT,GAAQ,KAC3DU,KAAW,CAAE,EACbC,QAAWT,EAAc,CAAA,EAAK,GAC9BU,KAAWV,EAAcM,OAAOC,KAAKT,GAAMa,OAASb,EAAKa,QAIzDZ,GAIFI,EAAUE,UAAUO,KAAKZ,EAAcD,EAAa,SAASc,EAAGC,GAE9D,OAAOf,EAAWD,EAAKe,GAAIf,EAAKgB,GACtC,GAGE,OAAOX,CACT"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__require as r}from"./abort.js";import{__require as t}from"./async.js";var e,i;function s(){if(i)return e;i=1;var s=r(),n=t();return e=function(r){if(!Object.keys(this.jobs).length)return;this.index=this.size,s(this),n(r)(null,this.results)}}export{s as __require};
|
|
2
|
-
//# sourceMappingURL=terminator.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"terminator.js","sources":["../../../../node_modules/asynckit/lib/terminator.js"],"sourcesContent":["var abort = require('./abort.js')\n , async = require('./async.js')\n ;\n\n// API\nmodule.exports = terminator;\n\n/**\n * Terminates jobs in the attached state context\n *\n * @this AsyncKitState#\n * @param {function} callback - final callback to invoke after termination\n */\nfunction terminator(callback)\n{\n if (!Object.keys(this.jobs).length)\n {\n return;\n }\n\n // fast forward iteration index\n this.index = this.size;\n\n // abort jobs\n abort(this);\n\n // send back results we have so far\n async(callback)(null, this.results);\n}\n"],"names":["abort","require$$0","async","require$$1","terminator_1","callback","Object","keys","this","jobs","length","index","size","results"],"mappings":"qHAAA,IAAIA,EAAQC,IACRC,EAAQC,WAIZC,EAQA,SAAoBC,GAElB,IAAKC,OAAOC,KAAKC,KAAKC,MAAMC,OAE1B,OAIFF,KAAKG,MAAQH,KAAKI,KAGlBZ,EAAMQ,MAGNN,EAAMG,EAANH,CAAgB,KAAMM,KAAKK,QAC7B"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__require as r}from"./lib/iterate.js";import{__require as e}from"./lib/state.js";import{__require as t}from"./lib/terminator.js";var i,n;function o(){if(n)return i;n=1;var o=r(),s=e(),u=t();return i=function(r,e,t){var i=s(r);for(;i.index<(i.keyedList||r).length;)o(r,e,i,(function(r,e){r?t(r,e):0!==Object.keys(i.jobs).length||t(null,i.results)})),i.index++;return u.bind(i,t)}}export{o as __require};
|
|
2
|
-
//# sourceMappingURL=parallel.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"parallel.js","sources":["../../../node_modules/asynckit/parallel.js"],"sourcesContent":["var iterate = require('./lib/iterate.js')\n , initState = require('./lib/state.js')\n , terminator = require('./lib/terminator.js')\n ;\n\n// Public API\nmodule.exports = parallel;\n\n/**\n * Runs iterator over provided array elements in parallel\n *\n * @param {array|object} list - array or object (named list) to iterate over\n * @param {function} iterator - iterator to run\n * @param {function} callback - invoked when all elements processed\n * @returns {function} - jobs terminator\n */\nfunction parallel(list, iterator, callback)\n{\n var state = initState(list);\n\n while (state.index < (state['keyedList'] || list).length)\n {\n iterate(list, iterator, state, function(error, result)\n {\n if (error)\n {\n callback(error, result);\n return;\n }\n\n // looks like it's the last one\n if (Object.keys(state.jobs).length === 0)\n {\n callback(null, state.results);\n return;\n }\n });\n\n state.index++;\n }\n\n return terminator.bind(state, callback);\n}\n"],"names":["iterate","require$$0","initState","require$$1","terminator","require$$2","parallel_1","list","iterator","callback","state","index","length","error","result","Object","keys","jobs","results","bind"],"mappings":"+KAAA,IAAIA,EAAaC,IACbC,EAAaC,IACbC,EAAaC,WAIjBC,EAUA,SAAkBC,EAAMC,EAAUC,GAEhC,IAAIC,EAAQR,EAAUK,GAEtB,KAAOG,EAAMC,OAASD,EAAiB,WAAKH,GAAMK,QAEhDZ,EAAQO,EAAMC,EAAUE,GAAO,SAASG,EAAOC,GAEzCD,EAEFJ,EAASI,EAAOC,GAKqB,IAAnCC,OAAOC,KAAKN,EAAMO,MAAML,QAE1BH,EAAS,KAAMC,EAAMQ,QAG7B,IAEIR,EAAMC,QAGR,OAAOP,EAAWe,KAAKT,EAAOD,EAChC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serial.js","sources":["../../../node_modules/asynckit/serial.js"],"sourcesContent":["var serialOrdered = require('./serialOrdered.js');\n\n// Public API\nmodule.exports = serial;\n\n/**\n * Runs iterator over provided array elements in series\n *\n * @param {array|object} list - array or object (named list) to iterate over\n * @param {function} iterator - iterator to run\n * @param {function} callback - invoked when all elements processed\n * @returns {function} - jobs terminator\n */\nfunction serial(list, iterator, callback)\n{\n return serialOrdered(list, iterator, null, callback);\n}\n"],"names":["serialOrdered","require$$0","serial_1","list","iterator","callback"],"mappings":"sFAAA,IAAIA,EAAgBC,WAGpBC,EAUA,SAAgBC,EAAMC,EAAUC,GAE9B,OAAOL,EAAcG,EAAMC,EAAU,KAAMC,EAC7C"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__module as r}from"../../_virtual/serialOrdered.js";import{__require as e}from"./lib/iterate.js";import{__require as t}from"./lib/state.js";import{__require as i}from"./lib/terminator.js";var n;function o(){if(n)return r.exports;n=1;var o=e(),s=t(),u=i();function a(r,e){return r<e?-1:r>e?1:0}return r.exports=function(r,e,t,i){var n=s(r,t);return o(r,e,n,(function t(s,u){s?i(s,u):(n.index++,n.index<(n.keyedList||r).length?o(r,e,n,t):i(null,n.results))})),u.bind(n,i)},r.exports.ascending=a,r.exports.descending=function(r,e){return-1*a(r,e)},r.exports}export{o as __require};
|
|
2
|
-
//# sourceMappingURL=serialOrdered.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serialOrdered.js","sources":["../../../node_modules/asynckit/serialOrdered.js"],"sourcesContent":["var iterate = require('./lib/iterate.js')\n , initState = require('./lib/state.js')\n , terminator = require('./lib/terminator.js')\n ;\n\n// Public API\nmodule.exports = serialOrdered;\n// sorting helpers\nmodule.exports.ascending = ascending;\nmodule.exports.descending = descending;\n\n/**\n * Runs iterator over provided sorted array elements in series\n *\n * @param {array|object} list - array or object (named list) to iterate over\n * @param {function} iterator - iterator to run\n * @param {function} sortMethod - custom sort function\n * @param {function} callback - invoked when all elements processed\n * @returns {function} - jobs terminator\n */\nfunction serialOrdered(list, iterator, sortMethod, callback)\n{\n var state = initState(list, sortMethod);\n\n iterate(list, iterator, state, function iteratorHandler(error, result)\n {\n if (error)\n {\n callback(error, result);\n return;\n }\n\n state.index++;\n\n // are we there yet?\n if (state.index < (state['keyedList'] || list).length)\n {\n iterate(list, iterator, state, iteratorHandler);\n return;\n }\n\n // done here\n callback(null, state.results);\n });\n\n return terminator.bind(state, callback);\n}\n\n/*\n * -- Sort methods\n */\n\n/**\n * sort helper to sort array elements in ascending order\n *\n * @param {mixed} a - an item to compare\n * @param {mixed} b - an item to compare\n * @returns {number} - comparison result\n */\nfunction ascending(a, b)\n{\n return a < b ? -1 : a > b ? 1 : 0;\n}\n\n/**\n * sort helper to sort array elements in descending order\n *\n * @param {mixed} a - an item to compare\n * @param {mixed} b - an item to compare\n * @returns {number} - comparison result\n */\nfunction descending(a, b)\n{\n return -1 * ascending(a, b);\n}\n"],"names":["iterate","require$$0","initState","require$$1","terminator","require$$2","ascending","a","b","serialOrderedModule","exports","list","iterator","sortMethod","callback","state","iteratorHandler","error","result","index","length","results","bind","descending"],"mappings":"gPAAA,IAAIA,EAAaC,IACbC,EAAaC,IACbC,EAAaC,IAyDjB,SAASC,EAAUC,EAAGC,GAEpB,OAAOD,EAAIC,GAAK,EAAID,EAAIC,EAAI,EAAI,CAClC,QAxDAC,EAAAC,QAcA,SAAuBC,EAAMC,EAAUC,EAAYC,GAEjD,IAAIC,EAAQb,EAAUS,EAAME,GAuB5B,OArBAb,EAAQW,EAAMC,EAAUG,GAAO,SAASC,EAAgBC,EAAOC,GAEzDD,EAEFH,EAASG,EAAOC,IAIlBH,EAAMI,QAGFJ,EAAMI,OAASJ,EAAiB,WAAKJ,GAAMS,OAE7CpB,EAAQW,EAAMC,EAAUG,EAAOC,GAKjCF,EAAS,KAAMC,EAAMM,SACzB,IAESjB,EAAWkB,KAAKP,EAAOD,EAChC,EAtCAL,EAAAC,QAAAJ,UAA4BA,EAC5BG,EAAAC,QAAAa,WA8DA,SAAoBhB,EAAGC,GAErB,OAAQ,EAAIF,EAAUC,EAAGC,EAC3B"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"../utils.js";import t from"../core/settle.js";import r from"../core/buildFullPath.js";import o from"../helpers/buildURL.js";import s from"../../../../_virtual/index9.js";import n from"http";import a from"https";import i from"util";import c from"../../../../_virtual/index10.js";import m from"zlib";import{VERSION as f}from"../env/data.js";import d from"../defaults/transitional.js";import l from"../core/AxiosError.js";import p from"../cancel/CanceledError.js";import u from"../platform/index.js";import h from"../helpers/fromDataURI.js";import g from"stream";import b from"../core/AxiosHeaders.js";import y from"../helpers/AxiosTransformStream.js";import{EventEmitter as R}from"events";import x from"../helpers/formDataToStream.js";import E from"../helpers/readBlob.js";import B from"../helpers/ZlibHeaderTransformStream.js";import T from"../helpers/callbackify.js";import{progressEventDecorator as w,progressEventReducer as L,asyncDecorator as A}from"../helpers/progressEventReducer.js";const S={flush:m.constants.Z_SYNC_FLUSH,finishFlush:m.constants.Z_SYNC_FLUSH},_={flush:m.constants.BROTLI_OPERATION_FLUSH,finishFlush:m.constants.BROTLI_OPERATION_FLUSH},U=e.isFunction(m.createBrotliDecompress),{http:j,https:O}=c,C=/https:?/,P=u.protocols.map((e=>e+":")),v=(e,[t,r])=>(e.on("end",r).on("error",r),t);function D(e,t){e.beforeRedirects.proxy&&e.beforeRedirects.proxy(e),e.beforeRedirects.config&&e.beforeRedirects.config(e,t)}function F(e,t,r){let o=t;if(!o&&!1!==o){const e=s.getProxyForUrl(r);e&&(o=new URL(e))}if(o){if(o.username&&(o.auth=(o.username||"")+":"+(o.password||"")),o.auth){(o.auth.username||o.auth.password)&&(o.auth=(o.auth.username||"")+":"+(o.auth.password||""));const t=Buffer.from(o.auth,"utf8").toString("base64");e.headers["Proxy-Authorization"]="Basic "+t}e.headers.host=e.hostname+(e.port?":"+e.port:"");const t=o.hostname||o.host;e.hostname=t,e.host=t,e.port=o.port,e.path=r,o.protocol&&(e.protocol=o.protocol.includes(":")?o.protocol:`${o.protocol}:`)}e.beforeRedirects.proxy=function(e){F(e,t,e.href)}}const N="undefined"!=typeof process&&"process"===e.kindOf(process),k=(t,r)=>(({address:t,family:r})=>{if(!e.isString(t))throw TypeError("address must be a string");return{address:t,family:r||(t.indexOf(".")<0?6:4)}})(e.isObject(t)?t:{address:t,family:r});var z=N&&function(s){return c=async function(c,N,z){let{data:H,lookup:I,family:M}=s;const{responseType:q,responseEncoding:Q}=s,Z=s.method.toUpperCase();let K,Y,$=!1;if(I){const t=T(I,(t=>e.isArray(t)?t:[t]));I=(r,o,s)=>{t(r,o,((t,r,n)=>{if(t)return s(t);const a=e.isArray(r)?r.map((e=>k(e))):[k(r,n)];o.all?s(t,a):s(t,a[0].address,a[0].family)}))}}const G=new R,J=()=>{s.cancelToken&&s.cancelToken.unsubscribe(V),s.signal&&s.signal.removeEventListener("abort",V),G.removeAllListeners()};function V(e){G.emit("abort",!e||e.type?new p(null,s,Y):e)}z(((e,t)=>{K=!0,t&&($=!0,J())})),G.once("abort",N),(s.cancelToken||s.signal)&&(s.cancelToken&&s.cancelToken.subscribe(V),s.signal&&(s.signal.aborted?V():s.signal.addEventListener("abort",V)));const W=r(s.baseURL,s.url),X=new URL(W,u.hasBrowserEnv?u.origin:void 0),ee=X.protocol||P[0];if("data:"===ee){let r;if("GET"!==Z)return t(c,N,{status:405,statusText:"method not allowed",headers:{},config:s});try{r=h(s.url,"blob"===q,{Blob:s.env&&s.env.Blob})}catch(e){throw l.from(e,l.ERR_BAD_REQUEST,s)}return"text"===q?(r=r.toString(Q),Q&&"utf8"!==Q||(r=e.stripBOM(r))):"stream"===q&&(r=g.Readable.from(r)),t(c,N,{data:r,status:200,statusText:"OK",headers:new b,config:s})}if(-1===P.indexOf(ee))return N(new l("Unsupported protocol "+ee,l.ERR_BAD_REQUEST,s));const te=b.from(s.headers).normalize();te.set("User-Agent","axios/"+f,!1);const{onUploadProgress:re,onDownloadProgress:oe}=s,se=s.maxRate;let ne,ae;if(e.isSpecCompliantForm(H)){const e=te.getContentType(/boundary=([-_\w\d]{10,70})/i);H=x(H,(e=>{te.set(e)}),{tag:`axios-${f}-boundary`,boundary:e&&e[1]||void 0})}else if(e.isFormData(H)&&e.isFunction(H.getHeaders)){if(te.set(H.getHeaders()),!te.hasContentLength())try{const e=await i.promisify(H.getLength).call(H);Number.isFinite(e)&&e>=0&&te.setContentLength(e)}catch(e){}}else if(e.isBlob(H)||e.isFile(H))H.size&&te.setContentType(H.type||"application/octet-stream"),te.setContentLength(H.size||0),H=g.Readable.from(E(H));else if(H&&!e.isStream(H)){if(Buffer.isBuffer(H));else if(e.isArrayBuffer(H))H=Buffer.from(new Uint8Array(H));else{if(!e.isString(H))return N(new l("Data after transformation must be a string, an ArrayBuffer, a Buffer, or a Stream",l.ERR_BAD_REQUEST,s));H=Buffer.from(H,"utf-8")}if(te.setContentLength(H.length,!1),s.maxBodyLength>-1&&H.length>s.maxBodyLength)return N(new l("Request body larger than maxBodyLength limit",l.ERR_BAD_REQUEST,s))}const ie=e.toFiniteNumber(te.getContentLength());let ce,me;e.isArray(se)?(ne=se[0],ae=se[1]):ne=ae=se,H&&(re||ne)&&(e.isStream(H)||(H=g.Readable.from(H,{objectMode:!1})),H=g.pipeline([H,new y({maxRate:e.toFiniteNumber(ne)})],e.noop),re&&H.on("progress",v(H,w(ie,L(A(re),!1,3))))),s.auth&&(ce=(s.auth.username||"")+":"+(s.auth.password||"")),!ce&&X.username&&(ce=X.username+":"+X.password),ce&&te.delete("authorization");try{me=o(X.pathname+X.search,s.params,s.paramsSerializer).replace(/^\?/,"")}catch(e){const t=new Error(e.message);return t.config=s,t.url=s.url,t.exists=!0,N(t)}te.set("Accept-Encoding","gzip, compress, deflate"+(U?", br":""),!1);const fe={path:me,method:Z,headers:te.toJSON(),agents:{http:s.httpAgent,https:s.httpsAgent},auth:ce,protocol:ee,family:M,beforeRedirect:D,beforeRedirects:{}};let de;!e.isUndefined(I)&&(fe.lookup=I),s.socketPath?fe.socketPath=s.socketPath:(fe.hostname=X.hostname.startsWith("[")?X.hostname.slice(1,-1):X.hostname,fe.port=X.port,F(fe,s.proxy,ee+"//"+X.hostname+(X.port?":"+X.port:"")+fe.path));const le=C.test(fe.protocol);if(fe.agent=le?s.httpsAgent:s.httpAgent,s.transport?de=s.transport:0===s.maxRedirects?de=le?a:n:(s.maxRedirects&&(fe.maxRedirects=s.maxRedirects),s.beforeRedirect&&(fe.beforeRedirects.config=s.beforeRedirect),de=le?O:j),s.maxBodyLength>-1?fe.maxBodyLength=s.maxBodyLength:fe.maxBodyLength=1/0,s.insecureHTTPParser&&(fe.insecureHTTPParser=s.insecureHTTPParser),Y=de.request(fe,(function(r){if(Y.destroyed)return;const o=[r],n=+r.headers["content-length"];if(oe||ae){const t=new y({maxRate:e.toFiniteNumber(ae)});oe&&t.on("progress",v(t,w(n,L(A(oe),!0,3)))),o.push(t)}let a=r;const i=r.req||Y;if(!1!==s.decompress&&r.headers["content-encoding"])switch("HEAD"!==Z&&204!==r.statusCode||delete r.headers["content-encoding"],(r.headers["content-encoding"]||"").toLowerCase()){case"gzip":case"x-gzip":case"compress":case"x-compress":o.push(m.createUnzip(S)),delete r.headers["content-encoding"];break;case"deflate":o.push(new B),o.push(m.createUnzip(S)),delete r.headers["content-encoding"];break;case"br":U&&(o.push(m.createBrotliDecompress(_)),delete r.headers["content-encoding"])}a=o.length>1?g.pipeline(o,e.noop):o[0];const f=g.finished(a,(()=>{f(),J()})),d={status:r.statusCode,statusText:r.statusMessage,headers:new b(r.headers),config:s,request:i};if("stream"===q)d.data=a,t(c,N,d);else{const r=[];let o=0;a.on("data",(function(e){r.push(e),o+=e.length,s.maxContentLength>-1&&o>s.maxContentLength&&($=!0,a.destroy(),N(new l("maxContentLength size of "+s.maxContentLength+" exceeded",l.ERR_BAD_RESPONSE,s,i)))})),a.on("aborted",(function(){if($)return;const e=new l("stream has been aborted",l.ERR_BAD_RESPONSE,s,i);a.destroy(e),N(e)})),a.on("error",(function(e){Y.destroyed||N(l.from(e,null,s,i))})),a.on("end",(function(){try{let t=1===r.length?r[0]:Buffer.concat(r);"arraybuffer"!==q&&(t=t.toString(Q),Q&&"utf8"!==Q||(t=e.stripBOM(t))),d.data=t}catch(e){return N(l.from(e,null,s,d.request,d))}t(c,N,d)}))}G.once("abort",(e=>{a.destroyed||(a.emit("error",e),a.destroy())}))})),G.once("abort",(e=>{N(e),Y.destroy(e)})),Y.on("error",(function(e){N(l.from(e,null,s,Y))})),Y.on("socket",(function(e){e.setKeepAlive(!0,6e4)})),s.timeout){const e=parseInt(s.timeout,10);if(Number.isNaN(e))return void N(new l("error trying to parse `config.timeout` to int",l.ERR_BAD_OPTION_VALUE,s,Y));Y.setTimeout(e,(function(){if(K)return;let e=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const t=s.transitional||d;s.timeoutErrorMessage&&(e=s.timeoutErrorMessage),N(new l(e,t.clarifyTimeoutError?l.ETIMEDOUT:l.ECONNABORTED,s,Y)),V()}))}if(e.isStream(H)){let e=!1,t=!1;H.on("end",(()=>{e=!0})),H.once("error",(e=>{t=!0,Y.destroy(e)})),H.on("close",(()=>{e||t||V(new p("Request stream has been aborted",s,Y))})),H.pipe(Y)}else Y.end(H)},new Promise(((e,t)=>{let r,o;const s=(e,t)=>{o||(o=!0,r&&r(e,t))},n=e=>{s(e,!0),t(e)};c((t=>{s(t),e(t)}),n,(e=>r=e)).catch(n)}));var c};export{z as default};
|
|
2
|
-
//# sourceMappingURL=http.js.map
|