@ncino/web-components 9.1.0 → 9.2.0-preview.2
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/eq.js +1 -0
- package/dist/_virtual/getSymbols.js +1 -0
- package/dist/_virtual/getTag.js +1 -0
- package/dist/_virtual/isEqual.js +1 -0
- package/dist/_virtual/isEqual2.js +1 -0
- package/dist/_virtual/isEqualWith.js +1 -0
- package/dist/_virtual/isPlainObject.js +1 -0
- package/dist/_virtual/noop.js +1 -0
- package/dist/_virtual/tags.js +1 -0
- package/dist/assets/node_modules/.pnpm/{ckeditor5@47.3.0 → ckeditor5@47.4.0}/node_modules/ckeditor5/dist/ckeditor5.css +1 -1
- package/dist/components/input/gator/input-file/input-file.gator.js +1 -1
- package/dist/components/input-rich-text/ckeditor-config.js +1 -1
- package/dist/components/input-rich-text/input-rich-text.slds.js +2 -2
- package/dist/components/panel/gator/panel.storybook-test.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-alignment@47.3.0 → @ckeditor_ckeditor5-alignment@47.4.0}/node_modules/@ckeditor/ckeditor5-alignment/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-autoformat@47.3.0 → @ckeditor_ckeditor5-autoformat@47.4.0}/node_modules/@ckeditor/ckeditor5-autoformat/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-autosave@47.3.0 → @ckeditor_ckeditor5-autosave@47.4.0}/node_modules/@ckeditor/ckeditor5-autosave/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-basic-styles@47.3.0 → @ckeditor_ckeditor5-basic-styles@47.4.0}/node_modules/@ckeditor/ckeditor5-basic-styles/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-block-quote@47.3.0 → @ckeditor_ckeditor5-block-quote@47.4.0}/node_modules/@ckeditor/ckeditor5-block-quote/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-clipboard@47.3.0 → @ckeditor_ckeditor5-clipboard@47.4.0}/node_modules/@ckeditor/ckeditor5-clipboard/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-cloud-services@47.3.0 → @ckeditor_ckeditor5-cloud-services@47.4.0}/node_modules/@ckeditor/ckeditor5-cloud-services/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-code-block@47.3.0 → @ckeditor_ckeditor5-code-block@47.4.0}/node_modules/@ckeditor/ckeditor5-code-block/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-core@47.4.0/node_modules/@ckeditor/ckeditor5-core/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-editor-classic@47.3.0 → @ckeditor_ckeditor5-editor-classic@47.4.0}/node_modules/@ckeditor/ckeditor5-editor-classic/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-engine@47.3.0 → @ckeditor_ckeditor5-engine@47.4.0}/node_modules/@ckeditor/ckeditor5-engine/dist/index.js +2 -2
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-enter@47.3.0 → @ckeditor_ckeditor5-enter@47.4.0}/node_modules/@ckeditor/ckeditor5-enter/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-essentials@47.3.0 → @ckeditor_ckeditor5-essentials@47.4.0}/node_modules/@ckeditor/ckeditor5-essentials/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-find-and-replace@47.3.0 → @ckeditor_ckeditor5-find-and-replace@47.4.0}/node_modules/@ckeditor/ckeditor5-find-and-replace/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-font@47.3.0 → @ckeditor_ckeditor5-font@47.4.0}/node_modules/@ckeditor/ckeditor5-font/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-heading@47.3.0 → @ckeditor_ckeditor5-heading@47.4.0}/node_modules/@ckeditor/ckeditor5-heading/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-highlight@47.3.0 → @ckeditor_ckeditor5-highlight@47.4.0}/node_modules/@ckeditor/ckeditor5-highlight/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-horizontal-line@47.3.0 → @ckeditor_ckeditor5-horizontal-line@47.4.0}/node_modules/@ckeditor/ckeditor5-horizontal-line/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-html-embed@47.3.0 → @ckeditor_ckeditor5-html-embed@47.4.0}/node_modules/@ckeditor/ckeditor5-html-embed/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-html-support@47.3.0 → @ckeditor_ckeditor5-html-support@47.4.0}/node_modules/@ckeditor/ckeditor5-html-support/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-image@47.4.0/node_modules/@ckeditor/ckeditor5-image/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-indent@47.3.0 → @ckeditor_ckeditor5-indent@47.4.0}/node_modules/@ckeditor/ckeditor5-indent/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-language@47.3.0 → @ckeditor_ckeditor5-language@47.4.0}/node_modules/@ckeditor/ckeditor5-language/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-link@47.3.0 → @ckeditor_ckeditor5-link@47.4.0}/node_modules/@ckeditor/ckeditor5-link/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-list@47.3.0 → @ckeditor_ckeditor5-list@47.4.0}/node_modules/@ckeditor/ckeditor5-list/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-markdown-gfm@47.3.0 → @ckeditor_ckeditor5-markdown-gfm@47.4.0}/node_modules/@ckeditor/ckeditor5-markdown-gfm/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-media-embed@47.4.0/node_modules/@ckeditor/ckeditor5-media-embed/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-mention@47.3.0 → @ckeditor_ckeditor5-mention@47.4.0}/node_modules/@ckeditor/ckeditor5-mention/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-page-break@47.3.0 → @ckeditor_ckeditor5-page-break@47.4.0}/node_modules/@ckeditor/ckeditor5-page-break/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-paragraph@47.3.0 → @ckeditor_ckeditor5-paragraph@47.4.0}/node_modules/@ckeditor/ckeditor5-paragraph/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-paste-from-office@47.3.0 → @ckeditor_ckeditor5-paste-from-office@47.4.0}/node_modules/@ckeditor/ckeditor5-paste-from-office/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-remove-format@47.3.0 → @ckeditor_ckeditor5-remove-format@47.4.0}/node_modules/@ckeditor/ckeditor5-remove-format/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-select-all@47.3.0 → @ckeditor_ckeditor5-select-all@47.4.0}/node_modules/@ckeditor/ckeditor5-select-all/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-show-blocks@47.3.0 → @ckeditor_ckeditor5-show-blocks@47.4.0}/node_modules/@ckeditor/ckeditor5-show-blocks/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-source-editing@47.3.0 → @ckeditor_ckeditor5-source-editing@47.4.0}/node_modules/@ckeditor/ckeditor5-source-editing/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-special-characters@47.3.0 → @ckeditor_ckeditor5-special-characters@47.4.0}/node_modules/@ckeditor/ckeditor5-special-characters/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-style@47.3.0 → @ckeditor_ckeditor5-style@47.4.0}/node_modules/@ckeditor/ckeditor5-style/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-table@47.4.0/node_modules/@ckeditor/ckeditor5-table/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-typing@47.4.0/node_modules/@ckeditor/ckeditor5-typing/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-ui@47.4.0/node_modules/@ckeditor/ckeditor5-ui/dist/index.js +1 -0
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-undo@47.3.0 → @ckeditor_ckeditor5-undo@47.4.0}/node_modules/@ckeditor/ckeditor5-undo/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-upload@47.3.0 → @ckeditor_ckeditor5-upload@47.4.0}/node_modules/@ckeditor/ckeditor5-upload/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-utils@47.3.0 → @ckeditor_ckeditor5-utils@47.4.0}/node_modules/@ckeditor/ckeditor5-utils/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-widget@47.3.0 → @ckeditor_ckeditor5-widget@47.4.0}/node_modules/@ckeditor/ckeditor5-widget/dist/index.js +1 -1
- package/dist/node_modules/.pnpm/@deltablot_dropzone@7.4.3/node_modules/@deltablot/dropzone/dist/dropzone.js +38 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/compat/isEqual.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/_internal/getSymbols2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/_internal/getTag2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/_internal/tags2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/object/merge.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/predicate/isEqualWith.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/compat/util/eq2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/function/noop.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/function/noop2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isEqual.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isEqual2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isEqualWith.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isEqualWith2.js +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isPlainObject.js +1 -1
- package/dist/node_modules/.pnpm/es-toolkit@1.39.5/node_modules/es-toolkit/dist/predicate/isPlainObject2.js +1 -0
- package/dist/node_modules/.pnpm/mdast-util-from-markdown@2.0.2/node_modules/mdast-util-from-markdown/lib/index.js +1 -1
- package/dist/node_modules/.pnpm/micromark-core-commonmark@2.0.3/node_modules/micromark-core-commonmark/lib/character-reference.js +1 -1
- package/dist/node_modules/.pnpm/micromark-util-decode-string@2.0.1/node_modules/micromark-util-decode-string/index.js +1 -1
- package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/storybook/dist/_browser-chunks/chunk-RP5RXKFU.js → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/storybook/dist/_browser-chunks/chunk-Q5RYDXT3.js} +19 -19
- package/dist/node_modules/.pnpm/storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/storybook/dist/_browser-chunks/chunk-VIJ7SQRO.js +1 -0
- package/dist/node_modules/.pnpm/storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/storybook/dist/core-events/index.js +1 -0
- package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0 → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4}/node_modules/storybook/dist/instrumenter/index.js +1 -1
- package/dist/node_modules/.pnpm/storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/storybook/dist/test/index.js +156 -0
- package/package.json +14 -14
- package/web-types.json +1 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-core@47.3.0/node_modules/@ckeditor/ckeditor5-core/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-image@47.3.0/node_modules/@ckeditor/ckeditor5-image/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-media-embed@47.3.0/node_modules/@ckeditor/ckeditor5-media-embed/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-table@47.3.0/node_modules/@ckeditor/ckeditor5-table/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-typing@47.3.0/node_modules/@ckeditor/ckeditor5-typing/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@ckeditor_ckeditor5-ui@47.3.0/node_modules/@ckeditor/ckeditor5-ui/dist/index.js +0 -1
- package/dist/node_modules/.pnpm/@deltablot_dropzone@7.3.1/node_modules/@deltablot/dropzone/dist/dropzone.js +0 -22
- package/dist/node_modules/.pnpm/storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/storybook/dist/_browser-chunks/chunk-EZSQOHRI.js +0 -1
- package/dist/node_modules/.pnpm/storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/storybook/dist/core-events/index.js +0 -1
- package/dist/node_modules/.pnpm/storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/storybook/dist/test/index.js +0 -152
- /package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-icons@47.3.0 → @ckeditor_ckeditor5-icons@47.4.0}/node_modules/@ckeditor/ckeditor5-icons/dist/index.js +0 -0
- /package/dist/node_modules/.pnpm/{@ckeditor_ckeditor5-watchdog@47.3.0 → @ckeditor_ckeditor5-watchdog@47.4.0}/node_modules/@ckeditor/ckeditor5-watchdog/dist/index.js +0 -0
- /package/dist/node_modules/.pnpm/{decode-named-character-reference@1.2.0 → decode-named-character-reference@1.3.0}/node_modules/decode-named-character-reference/index.dom.js +0 -0
- /package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0/node_modules/storybook/dist/_browser-chunks/chunk-JP7NCOJX.js → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/storybook/dist/_browser-chunks/chunk-3LY4VQVK.js} +0 -0
- /package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0 → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4}/node_modules/storybook/dist/_browser-chunks/chunk-A242L54C.js +0 -0
- /package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0 → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4}/node_modules/storybook/dist/_browser-chunks/chunk-ZUWEVLDX.js +0 -0
- /package/dist/node_modules/.pnpm/{storybook@10.1.10_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.0_react@19.2.0__react@19.2.0 → storybook@10.2.1_@testing-library_dom@10.4.1_prettier@3.7.4_react-dom@19.2.4_react@19.2.4__react@19.2.4}/node_modules/storybook/dist/client-logger/index.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{isPlainObject as p}from"./isPlainObject2.js";import{getSymbols as h}from"../compat/_internal/getSymbols.js";import{getTag as A}from"../compat/_internal/getTag.js";import{functionTag as w,regexpTag as v,symbolTag as B,dateTag as x,booleanTag as I,numberTag as S,stringTag as U,objectTag as m,errorTag as z,dataViewTag as L,arrayBufferTag as K,float64ArrayTag as P,float32ArrayTag as W,bigInt64ArrayTag as C,int32ArrayTag as M,int16ArrayTag as D,int8ArrayTag as F,bigUint64ArrayTag as G,uint32ArrayTag as H,uint16ArrayTag as J,uint8ClampedArrayTag as N,uint8ArrayTag as Q,arrayTag as R,setTag as X,mapTag as Y,argumentsTag as O}from"../compat/_internal/tags.js";import{eq as Z}from"../compat/util/eq.js";function k(r,e,t){return l(r,e,void 0,void 0,void 0,void 0,t)}function l(r,e,t,f,i,u,a){const T=a(r,e,t,f,i,u);if(T!==void 0)return T;if(typeof r==typeof e)switch(typeof r){case"bigint":case"string":case"boolean":case"symbol":case"undefined":return r===e;case"number":return r===e||Object.is(r,e);case"function":return r===e;case"object":return y(r,e,u,a)}return y(r,e,u,a)}function y(r,e,t,f){if(Object.is(r,e))return!0;let i=A(r),u=A(e);if(i===O&&(i=m),u===O&&(u=m),i!==u)return!1;switch(i){case U:return r.toString()===e.toString();case S:{const n=r.valueOf(),s=e.valueOf();return Z(n,s)}case I:case x:case B:return Object.is(r.valueOf(),e.valueOf());case v:return r.source===e.source&&r.flags===e.flags;case w:return r===e}t=t??new Map;const a=t.get(r),T=t.get(e);if(a!=null&&T!=null)return a===e;t.set(r,e),t.set(e,r);try{switch(i){case Y:{if(r.size!==e.size)return!1;for(const[n,s]of r.entries())if(!e.has(n)||!l(s,e.get(n),n,r,e,t,f))return!1;return!0}case X:{if(r.size!==e.size)return!1;const n=Array.from(r.values()),s=Array.from(e.values());for(let c=0;c<n.length;c++){const g=n[c],o=s.findIndex(d=>l(g,d,void 0,r,e,t,f));if(o===-1)return!1;s.splice(o,1)}return!0}case R:case Q:case N:case J:case H:case G:case F:case D:case M:case C:case W:case P:{if(typeof Buffer<"u"&&Buffer.isBuffer(r)!==Buffer.isBuffer(e)||r.length!==e.length)return!1;for(let n=0;n<r.length;n++)if(!l(r[n],e[n],n,r,e,t,f))return!1;return!0}case K:return r.byteLength!==e.byteLength?!1:y(new Uint8Array(r),new Uint8Array(e),t,f);case L:return r.byteLength!==e.byteLength||r.byteOffset!==e.byteOffset?!1:y(new Uint8Array(r),new Uint8Array(e),t,f);case z:return r.name===e.name&&r.message===e.message;case m:{if(!(y(r.constructor,e.constructor,t,f)||p(r)&&p(e)))return!1;const s=[...Object.keys(r),...h(r)],c=[...Object.keys(e),...h(e)];if(s.length!==c.length)return!1;for(let g=0;g<s.length;g++){const o=s[g],d=r[o];if(!Object.hasOwn(e,o))return!1;const j=e[o];if(!l(d,j,o,r,e,t,f))return!1}return!0}default:return!1}}finally{t.delete(r),t.delete(e)}}export{k as isEqualWith};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
function r(t){if(!t||typeof t!="object")return!1;const e=Object.getPrototypeOf(t);return e===null||e===Object.prototype||Object.getPrototypeOf(e)===null?Object.prototype.toString.call(t)==="[object Object]":!1}export{
|
|
1
|
+
import{__exports as o}from"../../../../../../../_virtual/isPlainObject.js";var n;function j(){return n?o:(n=1,(function(r){Object.defineProperty(r,Symbol.toStringTag,{value:"Module"});function c(t){if(!t||typeof t!="object")return!1;const e=Object.getPrototypeOf(t);return e===null||e===Object.prototype||Object.getPrototypeOf(e)===null?Object.prototype.toString.call(t)==="[object Object]":!1}r.isPlainObject=c})(o),o)}export{j as __require};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function r(t){if(!t||typeof t!="object")return!1;const e=Object.getPrototypeOf(t);return e===null||e===Object.prototype||Object.getPrototypeOf(e)===null?Object.prototype.toString.call(t)==="[object Object]":!1}export{r as isPlainObject};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{decodeNumericCharacterReference as Be}from"../../../../micromark-util-decode-numeric-character-reference@2.0.2/node_modules/micromark-util-decode-numeric-character-reference/index.js";import{decodeString as Re}from"../../../../micromark-util-decode-string@2.0.1/node_modules/micromark-util-decode-string/index.js";import{normalizeIdentifier as T}from"../../../../micromark-util-normalize-identifier@2.0.1/node_modules/micromark-util-normalize-identifier/index.js";import{decodeNamedCharacterReference as Ce}from"../../../../decode-named-character-reference@1.2.0/node_modules/decode-named-character-reference/index.dom.js";import{postprocess as He}from"../../../../micromark@4.0.2/node_modules/micromark/lib/postprocess.js";import{parse as Le}from"../../../../micromark@4.0.2/node_modules/micromark/lib/parse.js";import{preprocess as ze}from"../../../../micromark@4.0.2/node_modules/micromark/lib/preprocess.js";import{stringifyPosition as I}from"../../../../unist-util-stringify-position@4.0.0/node_modules/unist-util-stringify-position/lib/index.js";import{toString as Pe}from"../../../../mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js";const M={}.hasOwnProperty;function We(o,a,l){return typeof a!="string"&&(l=a,a=void 0),Oe(l)(He(Le(l).document().write(ze()(o,a,!0))))}function Oe(o){const a={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:r(P),autolinkProtocol:p,autolinkEmail:p,atxHeading:r(H),blockQuote:r(me),characterEscape:p,characterReference:p,codeFenced:r(C),codeFencedFenceInfo:h,codeFencedFenceMeta:h,codeIndented:r(C,h),codeText:r(xe,h),codeTextData:p,data:p,codeFlowValue:p,definition:r(ye),definitionDestinationString:h,definitionLabelString:h,definitionTitleString:h,emphasis:r(be),hardBreakEscape:r(L),hardBreakTrailing:r(L),htmlFlow:r(z,h),htmlFlowData:p,htmlText:r(z,h),htmlTextData:p,image:r(Se),label:h,link:r(P),listItem:r(we),listItemValue:U,listOrdered:r(O,N),listUnordered:r(O),paragraph:r(Ie),reference:he,referenceString:h,resourceDestinationString:h,resourceTitleString:h,setextHeading:r(H),strong:r(Te),thematicBreak:r(Fe)},exit:{atxHeading:c(),atxHeadingSequence:X,autolink:c(),autolinkEmail:ge,autolinkProtocol:ke,blockQuote:c(),characterEscapeValue:k,characterReferenceMarkerHexadecimal:R,characterReferenceMarkerNumeric:R,characterReferenceValue:fe,characterReference:pe,codeFenced:c(W),codeFencedFence:A,codeFencedFenceInfo:_,codeFencedFenceMeta:j,codeFlowValue:k,codeIndented:c($),codeText:c(ie),codeTextData:k,data:k,definition:c(),definitionDestinationString:K,definitionLabelString:G,definitionTitleString:J,emphasis:c(),hardBreakEscape:c(B),hardBreakTrailing:c(B),htmlFlow:c(te),htmlFlowData:k,htmlText:c(ne),htmlTextData:k,image:c(se),label:ce,labelText:re,lineEnding:ee,link:c(ae),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:ue,resourceDestinationString:oe,resourceTitleString:le,resource:de,setextHeading:c(v),setextHeadingLineSequence:Z,setextHeadingText:Y,strong:c(),thematicBreak:c()}};V(a,(o||{}).mdastExtensions||[]);const l={};return d;function d(e){let t={type:"root",children:[]};const n={stack:[t],tokenStack:[],config:a,enter:E,exit:F,buffer:h,resume:q,data:l},i=[];let s=-1;for(;++s<e.length;)if(e[s][1].type==="listOrdered"||e[s][1].type==="listUnordered")if(e[s][0]==="enter")i.push(s);else{const f=i.pop();s=Q(e,f,s)}for(s=-1;++s<e.length;){const f=a[e[s][0]];M.call(f,e[s][1].type)&&f[e[s][1].type].call(Object.assign({sliceSerialize:e[s][2].sliceSerialize},n),e[s][1])}if(n.tokenStack.length>0){const f=n.tokenStack[n.tokenStack.length-1];(f[1]||D).call(n,void 0,f[0])}for(t.position={start:x(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:x(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},s=-1;++s<a.transforms.length;)t=a.transforms[s](t)||t;return t}function Q(e,t,n){let i=t-1,s=-1,f=!1,y,g,S,w;for(;++i<=n;){const u=e[i];switch(u[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{u[0]==="enter"?s++:s--,w=void 0;break}case"lineEndingBlank":{u[0]==="enter"&&(y&&!w&&!s&&!S&&(S=i),w=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:w=void 0}if(!s&&u[0]==="enter"&&u[1].type==="listItemPrefix"||s===-1&&u[0]==="exit"&&(u[1].type==="listUnordered"||u[1].type==="listOrdered")){if(y){let b=i;for(g=void 0;b--;){const m=e[b];if(m[1].type==="lineEnding"||m[1].type==="lineEndingBlank"){if(m[0]==="exit")continue;g&&(e[g][1].type="lineEndingBlank",f=!0),m[1].type="lineEnding",g=b}else if(!(m[1].type==="linePrefix"||m[1].type==="blockQuotePrefix"||m[1].type==="blockQuotePrefixWhitespace"||m[1].type==="blockQuoteMarker"||m[1].type==="listItemIndent"))break}S&&(!g||S<g)&&(y._spread=!0),y.end=Object.assign({},g?e[g][1].start:u[1].end),e.splice(g||i,0,["exit",y,u[2]]),i++,n++}if(u[1].type==="listItemPrefix"){const b={type:"listItem",_spread:!1,start:Object.assign({},u[1].start),end:void 0};y=b,e.splice(i,0,["enter",b,u[2]]),i++,n++,S=void 0,w=!0}}}return e[t][1]._spread=f,n}function r(e,t){return n;function n(i){E.call(this,e(i),i),t&&t.call(this,i)}}function h(){this.stack.push({type:"fragment",children:[]})}function E(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:x(t.start),end:void 0}}function c(e){return t;function t(n){e&&e.call(this,n),F.call(this,n)}}function F(e,t){const n=this.stack.pop(),i=this.tokenStack.pop();if(i)i[0].type!==e.type&&(t?t.call(this,e,i[0]):(i[1]||D).call(this,e,i[0]));else throw new Error("Cannot close `"+e.type+"` ("+I({start:e.start,end:e.end})+"): it’s not open");n.position.end=x(e.end)}function q(){return Pe(this.stack.pop())}function N(){this.data.expectingFirstListItemValue=!0}function U(e){if(this.data.expectingFirstListItemValue){const t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function _(){const e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function j(){const e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function A(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function W(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function $(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,"")}function G(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=T(this.sliceSerialize(e)).toLowerCase()}function J(){const e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function K(){const e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function X(e){const t=this.stack[this.stack.length-1];if(!t.depth){const n=this.sliceSerialize(e).length;t.depth=n}}function Y(){this.data.setextHeadingSlurpLineEnding=!0}function Z(e){const t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function v(){this.data.setextHeadingSlurpLineEnding=void 0}function p(e){const n=this.stack[this.stack.length-1].children;let i=n[n.length-1];(!i||i.type!=="text")&&(i=Ee(),i.position={start:x(e.start),end:void 0},n.push(i)),this.stack.push(i)}function k(e){const t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=x(e.end)}function ee(e){const t=this.stack[this.stack.length-1];if(this.data.atHardBreak){const n=t.children[t.children.length-1];n.position.end=x(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&a.canContainEols.includes(t.type)&&(p.call(this,e),k.call(this,e))}function B(){this.data.atHardBreak=!0}function te(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ne(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ie(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ae(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function se(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function re(e){const t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=Re(t),n.identifier=T(t).toLowerCase()}function ce(){const e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];if(this.data.inReference=!0,n.type==="link"){const i=e.children;n.children=i}else n.alt=t}function oe(){const e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function le(){const e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function de(){this.data.inReference=void 0}function he(){this.data.referenceType="collapsed"}function ue(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=T(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"}function R(e){this.data.characterReferenceType=e.type}function fe(e){const t=this.sliceSerialize(e),n=this.data.characterReferenceType;let i;n?(i=Be(t,n==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):i=Ce(t);const s=this.stack[this.stack.length-1];s.value+=i}function pe(e){const t=this.stack.pop();t.position.end=x(e.end)}function ke(e){k.call(this,e);const t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function ge(e){k.call(this,e);const t=this.stack[this.stack.length-1];t.url="mailto:"+this.sliceSerialize(e)}function me(){return{type:"blockquote",children:[]}}function C(){return{type:"code",lang:null,meta:null,value:""}}function xe(){return{type:"inlineCode",value:""}}function ye(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function be(){return{type:"emphasis",children:[]}}function H(){return{type:"heading",depth:0,children:[]}}function L(){return{type:"break"}}function z(){return{type:"html",value:""}}function Se(){return{type:"image",title:null,url:"",alt:null}}function P(){return{type:"link",title:null,url:"",children:[]}}function O(e){return{type:"list",ordered:e.type==="listOrdered",start:null,spread:e._spread,children:[]}}function we(e){return{type:"listItem",spread:e._spread,checked:null,children:[]}}function Ie(){return{type:"paragraph",children:[]}}function Te(){return{type:"strong",children:[]}}function Ee(){return{type:"text",value:""}}function Fe(){return{type:"thematicBreak"}}}function x(o){return{line:o.line,column:o.column,offset:o.offset}}function V(o,a){let l=-1;for(;++l<a.length;){const d=a[l];Array.isArray(d)?V(o,d):De(o,d)}}function De(o,a){let l;for(l in a)if(M.call(a,l))switch(l){case"canContainEols":{const d=a[l];d&&o[l].push(...d);break}case"transforms":{const d=a[l];d&&o[l].push(...d);break}case"enter":case"exit":{const d=a[l];d&&Object.assign(o[l],d);break}}}function D(o,a){throw o?new Error("Cannot close `"+o.type+"` ("+I({start:o.start,end:o.end})+"): a different token (`"+a.type+"`, "+I({start:a.start,end:a.end})+") is open"):new Error("Cannot close document, a token (`"+a.type+"`, "+I({start:a.start,end:a.end})+") is still open")}export{We as fromMarkdown};
|
|
1
|
+
import{decodeNumericCharacterReference as Be}from"../../../../micromark-util-decode-numeric-character-reference@2.0.2/node_modules/micromark-util-decode-numeric-character-reference/index.js";import{decodeString as Re}from"../../../../micromark-util-decode-string@2.0.1/node_modules/micromark-util-decode-string/index.js";import{normalizeIdentifier as T}from"../../../../micromark-util-normalize-identifier@2.0.1/node_modules/micromark-util-normalize-identifier/index.js";import{decodeNamedCharacterReference as Ce}from"../../../../decode-named-character-reference@1.3.0/node_modules/decode-named-character-reference/index.dom.js";import{postprocess as He}from"../../../../micromark@4.0.2/node_modules/micromark/lib/postprocess.js";import{parse as Le}from"../../../../micromark@4.0.2/node_modules/micromark/lib/parse.js";import{preprocess as ze}from"../../../../micromark@4.0.2/node_modules/micromark/lib/preprocess.js";import{stringifyPosition as I}from"../../../../unist-util-stringify-position@4.0.0/node_modules/unist-util-stringify-position/lib/index.js";import{toString as Pe}from"../../../../mdast-util-to-string@4.0.0/node_modules/mdast-util-to-string/lib/index.js";const M={}.hasOwnProperty;function We(o,a,l){return typeof a!="string"&&(l=a,a=void 0),Oe(l)(He(Le(l).document().write(ze()(o,a,!0))))}function Oe(o){const a={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:r(P),autolinkProtocol:p,autolinkEmail:p,atxHeading:r(H),blockQuote:r(me),characterEscape:p,characterReference:p,codeFenced:r(C),codeFencedFenceInfo:h,codeFencedFenceMeta:h,codeIndented:r(C,h),codeText:r(xe,h),codeTextData:p,data:p,codeFlowValue:p,definition:r(ye),definitionDestinationString:h,definitionLabelString:h,definitionTitleString:h,emphasis:r(be),hardBreakEscape:r(L),hardBreakTrailing:r(L),htmlFlow:r(z,h),htmlFlowData:p,htmlText:r(z,h),htmlTextData:p,image:r(Se),label:h,link:r(P),listItem:r(we),listItemValue:U,listOrdered:r(O,N),listUnordered:r(O),paragraph:r(Ie),reference:he,referenceString:h,resourceDestinationString:h,resourceTitleString:h,setextHeading:r(H),strong:r(Te),thematicBreak:r(Fe)},exit:{atxHeading:c(),atxHeadingSequence:X,autolink:c(),autolinkEmail:ge,autolinkProtocol:ke,blockQuote:c(),characterEscapeValue:k,characterReferenceMarkerHexadecimal:R,characterReferenceMarkerNumeric:R,characterReferenceValue:fe,characterReference:pe,codeFenced:c(W),codeFencedFence:A,codeFencedFenceInfo:_,codeFencedFenceMeta:j,codeFlowValue:k,codeIndented:c($),codeText:c(ie),codeTextData:k,data:k,definition:c(),definitionDestinationString:K,definitionLabelString:G,definitionTitleString:J,emphasis:c(),hardBreakEscape:c(B),hardBreakTrailing:c(B),htmlFlow:c(te),htmlFlowData:k,htmlText:c(ne),htmlTextData:k,image:c(se),label:ce,labelText:re,lineEnding:ee,link:c(ae),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:ue,resourceDestinationString:oe,resourceTitleString:le,resource:de,setextHeading:c(v),setextHeadingLineSequence:Z,setextHeadingText:Y,strong:c(),thematicBreak:c()}};V(a,(o||{}).mdastExtensions||[]);const l={};return d;function d(e){let t={type:"root",children:[]};const n={stack:[t],tokenStack:[],config:a,enter:E,exit:F,buffer:h,resume:q,data:l},i=[];let s=-1;for(;++s<e.length;)if(e[s][1].type==="listOrdered"||e[s][1].type==="listUnordered")if(e[s][0]==="enter")i.push(s);else{const f=i.pop();s=Q(e,f,s)}for(s=-1;++s<e.length;){const f=a[e[s][0]];M.call(f,e[s][1].type)&&f[e[s][1].type].call(Object.assign({sliceSerialize:e[s][2].sliceSerialize},n),e[s][1])}if(n.tokenStack.length>0){const f=n.tokenStack[n.tokenStack.length-1];(f[1]||D).call(n,void 0,f[0])}for(t.position={start:x(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:x(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},s=-1;++s<a.transforms.length;)t=a.transforms[s](t)||t;return t}function Q(e,t,n){let i=t-1,s=-1,f=!1,y,g,S,w;for(;++i<=n;){const u=e[i];switch(u[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{u[0]==="enter"?s++:s--,w=void 0;break}case"lineEndingBlank":{u[0]==="enter"&&(y&&!w&&!s&&!S&&(S=i),w=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:w=void 0}if(!s&&u[0]==="enter"&&u[1].type==="listItemPrefix"||s===-1&&u[0]==="exit"&&(u[1].type==="listUnordered"||u[1].type==="listOrdered")){if(y){let b=i;for(g=void 0;b--;){const m=e[b];if(m[1].type==="lineEnding"||m[1].type==="lineEndingBlank"){if(m[0]==="exit")continue;g&&(e[g][1].type="lineEndingBlank",f=!0),m[1].type="lineEnding",g=b}else if(!(m[1].type==="linePrefix"||m[1].type==="blockQuotePrefix"||m[1].type==="blockQuotePrefixWhitespace"||m[1].type==="blockQuoteMarker"||m[1].type==="listItemIndent"))break}S&&(!g||S<g)&&(y._spread=!0),y.end=Object.assign({},g?e[g][1].start:u[1].end),e.splice(g||i,0,["exit",y,u[2]]),i++,n++}if(u[1].type==="listItemPrefix"){const b={type:"listItem",_spread:!1,start:Object.assign({},u[1].start),end:void 0};y=b,e.splice(i,0,["enter",b,u[2]]),i++,n++,S=void 0,w=!0}}}return e[t][1]._spread=f,n}function r(e,t){return n;function n(i){E.call(this,e(i),i),t&&t.call(this,i)}}function h(){this.stack.push({type:"fragment",children:[]})}function E(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:x(t.start),end:void 0}}function c(e){return t;function t(n){e&&e.call(this,n),F.call(this,n)}}function F(e,t){const n=this.stack.pop(),i=this.tokenStack.pop();if(i)i[0].type!==e.type&&(t?t.call(this,e,i[0]):(i[1]||D).call(this,e,i[0]));else throw new Error("Cannot close `"+e.type+"` ("+I({start:e.start,end:e.end})+"): it’s not open");n.position.end=x(e.end)}function q(){return Pe(this.stack.pop())}function N(){this.data.expectingFirstListItemValue=!0}function U(e){if(this.data.expectingFirstListItemValue){const t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function _(){const e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function j(){const e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function A(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function W(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function $(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,"")}function G(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=T(this.sliceSerialize(e)).toLowerCase()}function J(){const e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function K(){const e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function X(e){const t=this.stack[this.stack.length-1];if(!t.depth){const n=this.sliceSerialize(e).length;t.depth=n}}function Y(){this.data.setextHeadingSlurpLineEnding=!0}function Z(e){const t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function v(){this.data.setextHeadingSlurpLineEnding=void 0}function p(e){const n=this.stack[this.stack.length-1].children;let i=n[n.length-1];(!i||i.type!=="text")&&(i=Ee(),i.position={start:x(e.start),end:void 0},n.push(i)),this.stack.push(i)}function k(e){const t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=x(e.end)}function ee(e){const t=this.stack[this.stack.length-1];if(this.data.atHardBreak){const n=t.children[t.children.length-1];n.position.end=x(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&a.canContainEols.includes(t.type)&&(p.call(this,e),k.call(this,e))}function B(){this.data.atHardBreak=!0}function te(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ne(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ie(){const e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ae(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function se(){const e=this.stack[this.stack.length-1];if(this.data.inReference){const t=this.data.referenceType||"shortcut";e.type+="Reference",e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function re(e){const t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=Re(t),n.identifier=T(t).toLowerCase()}function ce(){const e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];if(this.data.inReference=!0,n.type==="link"){const i=e.children;n.children=i}else n.alt=t}function oe(){const e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function le(){const e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function de(){this.data.inReference=void 0}function he(){this.data.referenceType="collapsed"}function ue(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=T(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType="full"}function R(e){this.data.characterReferenceType=e.type}function fe(e){const t=this.sliceSerialize(e),n=this.data.characterReferenceType;let i;n?(i=Be(t,n==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):i=Ce(t);const s=this.stack[this.stack.length-1];s.value+=i}function pe(e){const t=this.stack.pop();t.position.end=x(e.end)}function ke(e){k.call(this,e);const t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function ge(e){k.call(this,e);const t=this.stack[this.stack.length-1];t.url="mailto:"+this.sliceSerialize(e)}function me(){return{type:"blockquote",children:[]}}function C(){return{type:"code",lang:null,meta:null,value:""}}function xe(){return{type:"inlineCode",value:""}}function ye(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function be(){return{type:"emphasis",children:[]}}function H(){return{type:"heading",depth:0,children:[]}}function L(){return{type:"break"}}function z(){return{type:"html",value:""}}function Se(){return{type:"image",title:null,url:"",alt:null}}function P(){return{type:"link",title:null,url:"",children:[]}}function O(e){return{type:"list",ordered:e.type==="listOrdered",start:null,spread:e._spread,children:[]}}function we(e){return{type:"listItem",spread:e._spread,checked:null,children:[]}}function Ie(){return{type:"paragraph",children:[]}}function Te(){return{type:"strong",children:[]}}function Ee(){return{type:"text",value:""}}function Fe(){return{type:"thematicBreak"}}}function x(o){return{line:o.line,column:o.column,offset:o.offset}}function V(o,a){let l=-1;for(;++l<a.length;){const d=a[l];Array.isArray(d)?V(o,d):De(o,d)}}function De(o,a){let l;for(l in a)if(M.call(a,l))switch(l){case"canContainEols":{const d=a[l];d&&o[l].push(...d);break}case"transforms":{const d=a[l];d&&o[l].push(...d);break}case"enter":case"exit":{const d=a[l];d&&Object.assign(o[l],d);break}}}function D(o,a){throw o?new Error("Cannot close `"+o.type+"` ("+I({start:o.start,end:o.end})+"): a different token (`"+a.type+"`, "+I({start:a.start,end:a.end})+") is open"):new Error("Cannot close document, a token (`"+a.type+"`, "+I({start:a.start,end:a.end})+") is still open")}export{We as fromMarkdown};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{decodeNamedCharacterReference as k}from"../../../../decode-named-character-reference@1.
|
|
1
|
+
import{decodeNamedCharacterReference as k}from"../../../../decode-named-character-reference@1.3.0/node_modules/decode-named-character-reference/index.dom.js";import{asciiAlphanumeric as u,asciiHexDigit as M,asciiDigit as p}from"../../../../micromark-util-character@2.1.1/node_modules/micromark-util-character/index.js";const N={name:"characterReference",tokenize:z};function z(e,h,t){const m=this;let i=0,n,a;return R;function R(r){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(r),e.exit("characterReferenceMarker"),l}function l(r){return r===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(r),e.exit("characterReferenceMarkerNumeric"),o):(e.enter("characterReferenceValue"),n=31,a=u,c(r))}function o(r){return r===88||r===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(r),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),n=6,a=M,c):(e.enter("characterReferenceValue"),n=7,a=p,c(r))}function c(r){if(r===59&&i){const x=e.exit("characterReferenceValue");return a===u&&!k(m.sliceSerialize(x))?t(r):(e.enter("characterReferenceMarker"),e.consume(r),e.exit("characterReferenceMarker"),e.exit("characterReference"),h)}return a(r)&&i++<n?(e.consume(r),c):t(r)}}export{N as characterReference};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{decodeNamedCharacterReference as o}from"../../../decode-named-character-reference@1.
|
|
1
|
+
import{decodeNamedCharacterReference as o}from"../../../decode-named-character-reference@1.3.0/node_modules/decode-named-character-reference/index.dom.js";import{decodeNumericCharacterReference as a}from"../../../micromark-util-decode-numeric-character-reference@2.0.2/node_modules/micromark-util-decode-numeric-character-reference/index.js";const n=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function m(r){return r.replace(n,f)}function f(r,c,e){if(c)return c;if(e.charCodeAt(0)===35){const t=e.charCodeAt(1),d=t===120||t===88;return a(e.slice(d?2:1),d?16:10)}return o(e)||r}export{m as decodeString};
|
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
var
|
|
2
|
-
`)&&(h=r.spacingOuter+l+h+r.spacingOuter+n),h=`{${h}}`),`${r.spacingInner+n+c.prop.open+f+c.prop.close}=${c.value.open}${h}${c.value.close}`}).join("")}function Ye(e,t,r,n,i,u){return e.map(o=>t.spacingOuter+r+(typeof o=="string"?Vt(o,t):u(o,t,r,n,i))).join("")}function Vt(e,t){let r=t.colors.content;return r.open+qt(e)+r.close}function Ur(e,t){let r=t.colors.comment;return`${r.open}<!--${qt(e)}-->${r.close}`}function qe(e,t,r,n,i){let u=n.colors.tag;return`${u.open}<${e}${t&&u.close+t+n.spacingOuter+i+u.open}${r?`>${u.close}${r}${n.spacingOuter}${i}${u.open}</${e}`:`${t&&!n.min?"":" "}/`}>${u.close}`}function Ve(e,t){let r=t.colors.tag;return`${r.open}<${e}${r.close} …${r.open} />${r.close}`}var Wr=1,Jt=3,Kt=8,Gt=11,Yr=/^(?:(?:HTML|SVG)\w*)?Element$/;function qr(e){try{return typeof e.hasAttribute=="function"&&e.hasAttribute("is")}catch{return!1}}function Vr(e){let t=e.constructor.name,{nodeType:r,tagName:n}=e,i=typeof n=="string"&&n.includes("-")||qr(e);return r===Wr&&(Yr.test(t)||i)||r===Jt&&t==="Text"||r===Kt&&t==="Comment"||r===Gt&&t==="DocumentFragment"}var Jr=e=>{var t;return(e==null||(t=e.constructor)===null||t===void 0?void 0:t.name)&&Vr(e)};function Kr(e){return e.nodeType===Jt}function Gr(e){return e.nodeType===Kt}function Me(e){return e.nodeType===Gt}var Hr=(e,t,r,n,i,u)=>{if(Kr(e))return Vt(e.data,t);if(Gr(e))return Ur(e.data,t);let o=Me(e)?"DocumentFragment":e.tagName.toLowerCase();return++n>t.maxDepth?Ve(o,t):qe(o,We(Me(e)?[]:Array.from(e.attributes,l=>l.name).sort(),Me(e)?{}:[...e.attributes].reduce((l,c)=>(l[c.name]=c.value,l),{}),t,r+t.indent,n,i,u),Ye(Array.prototype.slice.call(e.childNodes||e.children),t,r+t.indent,n,i,u),t,r)},Xr={serialize:Hr,test:Jr},Zr="@@__IMMUTABLE_ITERABLE__@@",Qr="@@__IMMUTABLE_LIST__@@",vr="@@__IMMUTABLE_KEYED__@@",en="@@__IMMUTABLE_MAP__@@",Qe="@@__IMMUTABLE_ORDERED__@@",tn="@@__IMMUTABLE_RECORD__@@",rn="@@__IMMUTABLE_SEQ__@@",nn="@@__IMMUTABLE_SET__@@",un="@@__IMMUTABLE_STACK__@@",ce=e=>`Immutable.${e}`,Ce=e=>`[${e}]`,fe=" ",ve="…";function on(e,t,r,n,i,u,o){return++n>t.maxDepth?Ce(ce(o)):`${ce(o)+fe}{${pe(e.entries(),t,r,n,i,u)}}`}function ln(e){let t=0;return{next(){if(t<e._keys.length){let r=e._keys[t++];return{done:!1,value:[r,e.get(r)]}}return{done:!0,value:void 0}}}}function cn(e,t,r,n,i,u){let o=ce(e._name||"Record");return++n>t.maxDepth?Ce(o):`${o+fe}{${pe(ln(e),t,r,n,i,u)}}`}function sn(e,t,r,n,i,u){let o=ce("Seq");return++n>t.maxDepth?Ce(o):e[vr]?`${o+fe}{${e._iter||e._object?pe(e.entries(),t,r,n,i,u):ve}}`:`${o+fe}[${e._iter||e._array||e._collection||e._iterable?ke(e.values(),t,r,n,i,u):ve}]`}function Ne(e,t,r,n,i,u,o){return++n>t.maxDepth?Ce(ce(o)):`${ce(o)+fe}[${ke(e.values(),t,r,n,i,u)}]`}var an=(e,t,r,n,i,u)=>e[en]?on(e,t,r,n,i,u,e[Qe]?"OrderedMap":"Map"):e[Qr]?Ne(e,t,r,n,i,u,"List"):e[nn]?Ne(e,t,r,n,i,u,e[Qe]?"OrderedSet":"Set"):e[un]?Ne(e,t,r,n,i,u,"Stack"):e[rn]?sn(e,t,r,n,i,u):cn(e,t,r,n,i,u),fn=e=>e&&(e[Zr]===!0||e[tn]===!0),mn={serialize:an,test:fn};function Ht(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var et={exports:{}},T={},tt;function gn(){if(tt)return T;tt=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),u=Symbol.for("react.consumer"),o=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),_=Symbol.for("react.view_transition"),g=Symbol.for("react.client.reference");function m(s){if(typeof s=="object"&&s!==null){var a=s.$$typeof;switch(a){case e:switch(s=s.type,s){case r:case i:case n:case c:case f:case _:return s;default:switch(s=s&&s.$$typeof,s){case o:case l:case h:case p:return s;case u:return s;default:return a}}case t:return a}}}return T.ContextConsumer=u,T.ContextProvider=o,T.Element=e,T.ForwardRef=l,T.Fragment=r,T.Lazy=h,T.Memo=p,T.Portal=t,T.Profiler=i,T.StrictMode=n,T.Suspense=c,T.SuspenseList=f,T.isContextConsumer=function(s){return m(s)===u},T.isContextProvider=function(s){return m(s)===o},T.isElement=function(s){return typeof s=="object"&&s!==null&&s.$$typeof===e},T.isForwardRef=function(s){return m(s)===l},T.isFragment=function(s){return m(s)===r},T.isLazy=function(s){return m(s)===h},T.isMemo=function(s){return m(s)===p},T.isPortal=function(s){return m(s)===t},T.isProfiler=function(s){return m(s)===i},T.isStrictMode=function(s){return m(s)===n},T.isSuspense=function(s){return m(s)===c},T.isSuspenseList=function(s){return m(s)===f},T.isValidElementType=function(s){return typeof s=="string"||typeof s=="function"||s===r||s===i||s===n||s===c||s===f||typeof s=="object"&&s!==null&&(s.$$typeof===h||s.$$typeof===p||s.$$typeof===o||s.$$typeof===u||s.$$typeof===l||s.$$typeof===g||s.getModuleId!==void 0)},T.typeOf=m,T}var rt;function pn(){return rt||(rt=1,et.exports=gn()),et.exports}var Xt=pn(),hn=Ht(Xt),yn=Wt({__proto__:null,default:hn},[Xt]),nt={exports:{}},A={},it;function bn(){if(it)return A;it=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),u=Symbol.for("react.provider"),o=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),_=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),m;m=Symbol.for("react.module.reference");function s(a){if(typeof a=="object"&&a!==null){var b=a.$$typeof;switch(b){case e:switch(a=a.type,a){case r:case i:case n:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case l:case o:case c:case _:case h:case u:return a;default:return b}}case t:return b}}}return A.ContextConsumer=o,A.ContextProvider=u,A.Element=e,A.ForwardRef=c,A.Fragment=r,A.Lazy=_,A.Memo=h,A.Portal=t,A.Profiler=i,A.StrictMode=n,A.Suspense=f,A.SuspenseList=p,A.isAsyncMode=function(){return!1},A.isConcurrentMode=function(){return!1},A.isContextConsumer=function(a){return s(a)===o},A.isContextProvider=function(a){return s(a)===u},A.isElement=function(a){return typeof a=="object"&&a!==null&&a.$$typeof===e},A.isForwardRef=function(a){return s(a)===c},A.isFragment=function(a){return s(a)===r},A.isLazy=function(a){return s(a)===_},A.isMemo=function(a){return s(a)===h},A.isPortal=function(a){return s(a)===t},A.isProfiler=function(a){return s(a)===i},A.isStrictMode=function(a){return s(a)===n},A.isSuspense=function(a){return s(a)===f},A.isSuspenseList=function(a){return s(a)===p},A.isValidElementType=function(a){return typeof a=="string"||typeof a=="function"||a===r||a===i||a===n||a===f||a===p||a===g||typeof a=="object"&&a!==null&&(a.$$typeof===_||a.$$typeof===h||a.$$typeof===u||a.$$typeof===o||a.$$typeof===c||a.$$typeof===m||a.getModuleId!==void 0)},A.typeOf=s,A}var ut;function $n(){return ut||(ut=1,nt.exports=bn()),nt.exports}var Zt=$n(),Sn=Ht(Zt),En=Wt({__proto__:null,default:Sn},[Zt]),_n=["isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","isSuspenseList","isValidElementType"],ne=Object.fromEntries(_n.map(e=>[e,t=>En[e](t)||yn[e](t)]));function Qt(e,t=[]){if(Array.isArray(e))for(let r of e)Qt(r,t);else e!=null&&e!==!1&&e!==""&&t.push(e);return t}function ot(e){let t=e.type;if(typeof t=="string")return t;if(typeof t=="function")return t.displayName||t.name||"Unknown";if(ne.isFragment(e))return"React.Fragment";if(ne.isSuspense(e))return"React.Suspense";if(typeof t=="object"&&t!==null){if(ne.isContextProvider(e))return"Context.Provider";if(ne.isContextConsumer(e))return"Context.Consumer";if(ne.isForwardRef(e)){if(t.displayName)return t.displayName;let r=t.render.displayName||t.render.name||"";return r===""?"ForwardRef":`ForwardRef(${r})`}if(ne.isMemo(e)){let r=t.displayName||t.type.displayName||t.type.name||"";return r===""?"Memo":`Memo(${r})`}}return"UNDEFINED"}function On(e){let{props:t}=e;return Object.keys(t).filter(r=>r!=="children"&&t[r]!==void 0).sort()}var Cn=(e,t,r,n,i,u)=>++n>t.maxDepth?Ve(ot(e),t):qe(ot(e),We(On(e),e.props,t,r+t.indent,n,i,u),Ye(Qt(e.props.children),t,r+t.indent,n,i,u),t,r),wn=e=>e!=null&&ne.isElement(e),An={serialize:Cn,test:wn},Tn=typeof Symbol=="function"&&Symbol.for?Symbol.for("react.test.json"):245830487;function Mn(e){let{props:t}=e;return t?Object.keys(t).filter(r=>t[r]!==void 0).sort():[]}var Nn=(e,t,r,n,i,u)=>++n>t.maxDepth?Ve(e.type,t):qe(e.type,e.props?We(Mn(e),e.props,t,r+t.indent,n,i,u):"",e.children?Ye(e.children,t,r+t.indent,n,i,u):"",t,r),Pn=e=>e&&e.$$typeof===Tn,dn={serialize:Nn,test:Pn},vt=Object.prototype.toString,Ln=Date.prototype.toISOString,Rn=Error.prototype.toString,lt=RegExp.prototype.toString;function $e(e){return typeof e.constructor=="function"&&e.constructor.name||"Object"}function Fn(e){return typeof window<"u"&&e===window}var In=/^Symbol\((.*)\)(.*)$/,Dn=/\n/g,er=class extends Error{constructor(e,t){super(e),this.stack=t,this.name=this.constructor.name}};function jn(e){return e==="[object Array]"||e==="[object ArrayBuffer]"||e==="[object DataView]"||e==="[object Float32Array]"||e==="[object Float64Array]"||e==="[object Int8Array]"||e==="[object Int16Array]"||e==="[object Int32Array]"||e==="[object Uint8Array]"||e==="[object Uint8ClampedArray]"||e==="[object Uint16Array]"||e==="[object Uint32Array]"}function Bn(e){return Object.is(e,-0)?"-0":String(e)}function xn(e){return`${e}n`}function ct(e,t){return t?`[Function ${e.name||"anonymous"}]`:"[Function]"}function st(e){return String(e).replace(In,"Symbol($1)")}function at(e){return`[${Rn.call(e)}]`}function tr(e,t,r,n){if(e===!0||e===!1)return`${e}`;if(e===void 0)return"undefined";if(e===null)return"null";let i=typeof e;if(i==="number")return Bn(e);if(i==="bigint")return xn(e);if(i==="string")return n?`"${e.replaceAll(/"|\\/g,"\\$&")}"`:`"${e}"`;if(i==="function")return ct(e,t);if(i==="symbol")return st(e);let u=vt.call(e);return u==="[object WeakMap]"?"WeakMap {}":u==="[object WeakSet]"?"WeakSet {}":u==="[object Function]"||u==="[object GeneratorFunction]"?ct(e,t):u==="[object Symbol]"?st(e):u==="[object Date]"?Number.isNaN(+e)?"Date { NaN }":Ln.call(e):u==="[object Error]"?at(e):u==="[object RegExp]"?r?lt.call(e).replaceAll(/[$()*+.?[\\\]^{|}]/g,"\\$&"):lt.call(e):e instanceof Error?at(e):null}function rr(e,t,r,n,i,u){if(i.includes(e))return"[Circular]";i=[...i],i.push(e);let o=++n>t.maxDepth,l=t.min;if(t.callToJSON&&!o&&e.toJSON&&typeof e.toJSON=="function"&&!u)return v(e.toJSON(),t,r,n,i,!0);let c=vt.call(e);return c==="[object Arguments]"?o?"[Arguments]":`${l?"":"Arguments "}[${_e(e,t,r,n,i,v)}]`:jn(c)?o?`[${e.constructor.name}]`:`${l||!t.printBasicPrototype&&e.constructor.name==="Array"?"":`${e.constructor.name} `}[${_e(e,t,r,n,i,v)}]`:c==="[object Map]"?o?"[Map]":`Map {${pe(e.entries(),t,r,n,i,v," => ")}}`:c==="[object Set]"?o?"[Set]":`Set {${ke(e.values(),t,r,n,i,v)}}`:o||Fn(e)?`[${$e(e)}]`:`${l||!t.printBasicPrototype&&$e(e)==="Object"?"":`${$e(e)} `}{${Ue(e,t,r,n,i,v)}}`}var zn={test:e=>e&&e instanceof Error,serialize(e,t,r,n,i,u){if(i.includes(e))return"[Circular]";i=[...i,e];let o=++n>t.maxDepth,{message:l,cause:c,...f}=e,p={message:l,...typeof c<"u"?{cause:c}:{},...e instanceof AggregateError?{errors:e.errors}:{},...f},h=e.name!=="Error"?e.name:$e(e);return o?`[${h}]`:`${h} {${pe(Object.entries(p).values(),t,r,n,i,u)}}`}};function kn(e){return e.serialize!=null}function nr(e,t,r,n,i,u){let o;try{o=kn(e)?e.serialize(t,r,n,i,u,v):e.print(t,l=>v(l,r,n,i,u),l=>{let c=n+r.indent;return c+l.replaceAll(Dn,`
|
|
3
|
-
${c}`)},{edgeSpacing:r.spacingOuter,min:r.min,spacing:r.spacingInner},r.colors)}catch(l){throw new er(l.message,l.stack)}if(typeof o!="string")throw new TypeError(`pretty-format: Plugin must return type "string" but instead returned "${typeof o}".`);return o}function ir(e,t){for(let r of e)try{if(r.test(t))return r}catch(n){throw new er(n.message,n.stack)}return null}function v(e,t,r,n,i,u){let o=ir(t.plugins,e);if(o!==null)return nr(o,e,t,r,n,i);let l=tr(e,t.printFunctionName,t.escapeRegex,t.escapeString);return l!==null?l:rr(e,t,r,n,i,u)}var Je={comment:"gray",content:"reset",prop:"yellow",tag:"cyan",value:"green"},ur=Object.keys(Je),W={callToJSON:!0,compareKeys:void 0,escapeRegex:!1,escapeString:!0,highlight:!1,indent:2,maxDepth:Number.POSITIVE_INFINITY,maxWidth:Number.POSITIVE_INFINITY,min:!1,plugins:[],printBasicPrototype:!0,printFunctionName:!0,theme:Je};function
|
|
1
|
+
var Mr={reset:[0,0],bold:[1,22,"\x1B[22m\x1B[1m"],dim:[2,22,"\x1B[22m\x1B[2m"],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29],black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39],bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49],blackBright:[90,39],redBright:[91,39],greenBright:[92,39],yellowBright:[93,39],blueBright:[94,39],magentaBright:[95,39],cyanBright:[96,39],whiteBright:[97,39],bgBlackBright:[100,49],bgRedBright:[101,49],bgGreenBright:[102,49],bgYellowBright:[103,49],bgBlueBright:[104,49],bgMagentaBright:[105,49],bgCyanBright:[106,49],bgWhiteBright:[107,49]},Ut=Object.entries(Mr);function _e(e){return String(e)}_e.open="";_e.close="";Ut.reduce((e,[t])=>(e[t]=_e,e),{isColorSupported:!1});function Nr(e=!1){let t=typeof process<"u"?process:void 0,r=t?.env||{},n=t?.argv||[];return!("NO_COLOR"in r||n.includes("--no-color"))&&("FORCE_COLOR"in r||n.includes("--color")||t?.platform==="win32"||e&&r.TERM!=="dumb"||"CI"in r)||typeof window<"u"&&!!window.chrome}function Pr(e=!1){let t=Nr(e),r=(o,l,c,f)=>{let p="",h=0;do p+=o.substring(h,f)+c,h=f+l.length,f=o.indexOf(l,h);while(~f);return p+o.substring(h)},n=(o,l,c=o)=>{let f=p=>{let h=String(p),_=h.indexOf(l,o.length);return~_?o+r(h,l,c,_)+l:o+h+l};return f.open=o,f.close=l,f},i={isColorSupported:t},u=o=>`\x1B[${o}m`;for(let[o,l]of Ut)i[o]=t?n(u(l[0]),u(l[1]),l[2]):_e;return i}var Z=Pr();function Wt(e,t){return t.forEach(function(r){r&&typeof r!="string"&&!Array.isArray(r)&&Object.keys(r).forEach(function(n){if(n!=="default"&&!(n in e)){var i=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return r[n]}})}})}),Object.freeze(e)}function dr(e,t){let r=Object.keys(e),n=t===null?r:r.sort(t);if(Object.getOwnPropertySymbols)for(let i of Object.getOwnPropertySymbols(e))Object.getOwnPropertyDescriptor(e,i).enumerable&&n.push(i);return n}function pe(e,t,r,n,i,u,o=": "){let l="",c=0,f=e.next();if(!f.done){l+=t.spacingOuter;let p=r+t.indent;for(;!f.done;){if(l+=p,c++===t.maxWidth){l+="…";break}let h=u(f.value[0],t,p,n,i),_=u(f.value[1],t,p,n,i);l+=h+o+_,f=e.next(),f.done?t.min||(l+=","):l+=`,${t.spacingInner}`}l+=t.spacingOuter+r}return l}function ke(e,t,r,n,i,u){let o="",l=0,c=e.next();if(!c.done){o+=t.spacingOuter;let f=r+t.indent;for(;!c.done;){if(o+=f,l++===t.maxWidth){o+="…";break}o+=u(c.value,t,f,n,i),c=e.next(),c.done?t.min||(o+=","):o+=`,${t.spacingInner}`}o+=t.spacingOuter+r}return o}function Ee(e,t,r,n,i,u){let o="";e=e instanceof ArrayBuffer?new DataView(e):e;let l=f=>f instanceof DataView,c=l(e)?e.byteLength:e.length;if(c>0){o+=t.spacingOuter;let f=r+t.indent;for(let p=0;p<c;p++){if(o+=f,p===t.maxWidth){o+="…";break}(l(e)||p in e)&&(o+=u(l(e)?e.getInt8(p):e[p],t,f,n,i)),p<c-1?o+=`,${t.spacingInner}`:t.min||(o+=",")}o+=t.spacingOuter+r}return o}function Ue(e,t,r,n,i,u){let o="",l=dr(e,t.compareKeys);if(l.length>0){o+=t.spacingOuter;let c=r+t.indent;for(let f=0;f<l.length;f++){let p=l[f],h=u(p,t,c,n,i),_=u(e[p],t,c,n,i);o+=`${c+h}: ${_}`,f<l.length-1?o+=`,${t.spacingInner}`:t.min||(o+=",")}o+=t.spacingOuter+r}return o}var Lr=typeof Symbol=="function"&&Symbol.for?Symbol.for("jest.asymmetricMatcher"):1267621,Ae=" ",Rr=(e,t,r,n,i,u)=>{let o=e.toString();if(o==="ArrayContaining"||o==="ArrayNotContaining")return++n>t.maxDepth?`[${o}]`:`${o+Ae}[${Ee(e.sample,t,r,n,i,u)}]`;if(o==="ObjectContaining"||o==="ObjectNotContaining")return++n>t.maxDepth?`[${o}]`:`${o+Ae}{${Ue(e.sample,t,r,n,i,u)}}`;if(o==="StringMatching"||o==="StringNotMatching"||o==="StringContaining"||o==="StringNotContaining")return o+Ae+u(e.sample,t,r,n,i);if(typeof e.toAsymmetricMatcher!="function")throw new TypeError(`Asymmetric matcher ${e.constructor.name} does not implement toAsymmetricMatcher()`);return e.toAsymmetricMatcher()},Fr=e=>e&&e.$$typeof===Lr,Ir={serialize:Rr,test:Fr},Dr=" ",Yt=new Set(["DOMStringMap","NamedNodeMap"]),jr=/^(?:HTML\w*Collection|NodeList)$/;function Br(e){return Yt.has(e)||jr.test(e)}var xr=e=>e&&e.constructor&&!!e.constructor.name&&Br(e.constructor.name);function zr(e){return e.constructor.name==="NamedNodeMap"}var kr=(e,t,r,n,i,u)=>{let o=e.constructor.name;return++n>t.maxDepth?`[${o}]`:(t.min?"":o+Dr)+(Yt.has(o)?`{${Ue(zr(e)?[...e].reduce((l,c)=>(l[c.name]=c.value,l),{}):{...e},t,r,n,i,u)}}`:`[${Ee([...e],t,r,n,i,u)}]`)},Ur={serialize:kr,test:xr};function qt(e){return e.replaceAll("<","<").replaceAll(">",">")}function We(e,t,r,n,i,u,o){let l=n+r.indent,c=r.colors;return e.map(f=>{let p=t[f],h=o(p,r,l,i,u);return typeof p!="string"&&(h.includes(`
|
|
2
|
+
`)&&(h=r.spacingOuter+l+h+r.spacingOuter+n),h=`{${h}}`),`${r.spacingInner+n+c.prop.open+f+c.prop.close}=${c.value.open}${h}${c.value.close}`}).join("")}function Ye(e,t,r,n,i,u){return e.map(o=>t.spacingOuter+r+(typeof o=="string"?Vt(o,t):u(o,t,r,n,i))).join("")}function Vt(e,t){let r=t.colors.content;return r.open+qt(e)+r.close}function Wr(e,t){let r=t.colors.comment;return`${r.open}<!--${qt(e)}-->${r.close}`}function qe(e,t,r,n,i){let u=n.colors.tag;return`${u.open}<${e}${t&&u.close+t+n.spacingOuter+i+u.open}${r?`>${u.close}${r}${n.spacingOuter}${i}${u.open}</${e}`:`${t&&!n.min?"":" "}/`}>${u.close}`}function Ve(e,t){let r=t.colors.tag;return`${r.open}<${e}${r.close} …${r.open} />${r.close}`}var Yr=1,Jt=3,Kt=8,Gt=11,qr=/^(?:(?:HTML|SVG)\w*)?Element$/;function Vr(e){try{return typeof e.hasAttribute=="function"&&e.hasAttribute("is")}catch{return!1}}function Jr(e){let t=e.constructor.name,{nodeType:r,tagName:n}=e,i=typeof n=="string"&&n.includes("-")||Vr(e);return r===Yr&&(qr.test(t)||i)||r===Jt&&t==="Text"||r===Kt&&t==="Comment"||r===Gt&&t==="DocumentFragment"}var Kr=e=>{var t;return(e==null||(t=e.constructor)===null||t===void 0?void 0:t.name)&&Jr(e)};function Gr(e){return e.nodeType===Jt}function Hr(e){return e.nodeType===Kt}function Te(e){return e.nodeType===Gt}var Xr=(e,t,r,n,i,u)=>{if(Gr(e))return Vt(e.data,t);if(Hr(e))return Wr(e.data,t);let o=Te(e)?"DocumentFragment":e.tagName.toLowerCase();return++n>t.maxDepth?Ve(o,t):qe(o,We(Te(e)?[]:Array.from(e.attributes,l=>l.name).sort(),Te(e)?{}:[...e.attributes].reduce((l,c)=>(l[c.name]=c.value,l),{}),t,r+t.indent,n,i,u),Ye(Array.prototype.slice.call(e.childNodes||e.children),t,r+t.indent,n,i,u),t,r)},Zr={serialize:Xr,test:Kr},Qr="@@__IMMUTABLE_ITERABLE__@@",vr="@@__IMMUTABLE_LIST__@@",en="@@__IMMUTABLE_KEYED__@@",tn="@@__IMMUTABLE_MAP__@@",Qe="@@__IMMUTABLE_ORDERED__@@",rn="@@__IMMUTABLE_RECORD__@@",nn="@@__IMMUTABLE_SEQ__@@",un="@@__IMMUTABLE_SET__@@",on="@@__IMMUTABLE_STACK__@@",ce=e=>`Immutable.${e}`,Oe=e=>`[${e}]`,fe=" ",ve="…";function ln(e,t,r,n,i,u,o){return++n>t.maxDepth?Oe(ce(o)):`${ce(o)+fe}{${pe(e.entries(),t,r,n,i,u)}}`}function cn(e){let t=0;return{next(){if(t<e._keys.length){let r=e._keys[t++];return{done:!1,value:[r,e.get(r)]}}return{done:!0,value:void 0}}}}function sn(e,t,r,n,i,u){let o=ce(e._name||"Record");return++n>t.maxDepth?Oe(o):`${o+fe}{${pe(cn(e),t,r,n,i,u)}}`}function an(e,t,r,n,i,u){let o=ce("Seq");return++n>t.maxDepth?Oe(o):e[en]?`${o+fe}{${e._iter||e._object?pe(e.entries(),t,r,n,i,u):ve}}`:`${o+fe}[${e._iter||e._array||e._collection||e._iterable?ke(e.values(),t,r,n,i,u):ve}]`}function Me(e,t,r,n,i,u,o){return++n>t.maxDepth?Oe(ce(o)):`${ce(o)+fe}[${ke(e.values(),t,r,n,i,u)}]`}var fn=(e,t,r,n,i,u)=>e[tn]?ln(e,t,r,n,i,u,e[Qe]?"OrderedMap":"Map"):e[vr]?Me(e,t,r,n,i,u,"List"):e[un]?Me(e,t,r,n,i,u,e[Qe]?"OrderedSet":"Set"):e[on]?Me(e,t,r,n,i,u,"Stack"):e[nn]?an(e,t,r,n,i,u):sn(e,t,r,n,i,u),mn=e=>e&&(e[Qr]===!0||e[rn]===!0),gn={serialize:fn,test:mn};function Ht(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var et={exports:{}},T={},tt;function pn(){if(tt)return T;tt=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),u=Symbol.for("react.consumer"),o=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),f=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),_=Symbol.for("react.view_transition"),g=Symbol.for("react.client.reference");function m(s){if(typeof s=="object"&&s!==null){var a=s.$$typeof;switch(a){case e:switch(s=s.type,s){case r:case i:case n:case c:case f:case _:return s;default:switch(s=s&&s.$$typeof,s){case o:case l:case h:case p:return s;case u:return s;default:return a}}case t:return a}}}return T.ContextConsumer=u,T.ContextProvider=o,T.Element=e,T.ForwardRef=l,T.Fragment=r,T.Lazy=h,T.Memo=p,T.Portal=t,T.Profiler=i,T.StrictMode=n,T.Suspense=c,T.SuspenseList=f,T.isContextConsumer=function(s){return m(s)===u},T.isContextProvider=function(s){return m(s)===o},T.isElement=function(s){return typeof s=="object"&&s!==null&&s.$$typeof===e},T.isForwardRef=function(s){return m(s)===l},T.isFragment=function(s){return m(s)===r},T.isLazy=function(s){return m(s)===h},T.isMemo=function(s){return m(s)===p},T.isPortal=function(s){return m(s)===t},T.isProfiler=function(s){return m(s)===i},T.isStrictMode=function(s){return m(s)===n},T.isSuspense=function(s){return m(s)===c},T.isSuspenseList=function(s){return m(s)===f},T.isValidElementType=function(s){return typeof s=="string"||typeof s=="function"||s===r||s===i||s===n||s===c||s===f||typeof s=="object"&&s!==null&&(s.$$typeof===h||s.$$typeof===p||s.$$typeof===o||s.$$typeof===u||s.$$typeof===l||s.$$typeof===g||s.getModuleId!==void 0)},T.typeOf=m,T}var rt;function hn(){return rt||(rt=1,et.exports=pn()),et.exports}var Xt=hn(),yn=Ht(Xt),bn=Wt({__proto__:null,default:yn},[Xt]),nt={exports:{}},A={},it;function $n(){if(it)return A;it=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),u=Symbol.for("react.provider"),o=Symbol.for("react.context"),l=Symbol.for("react.server_context"),c=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),p=Symbol.for("react.suspense_list"),h=Symbol.for("react.memo"),_=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),m;m=Symbol.for("react.module.reference");function s(a){if(typeof a=="object"&&a!==null){var b=a.$$typeof;switch(b){case e:switch(a=a.type,a){case r:case i:case n:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case l:case o:case c:case _:case h:case u:return a;default:return b}}case t:return b}}}return A.ContextConsumer=o,A.ContextProvider=u,A.Element=e,A.ForwardRef=c,A.Fragment=r,A.Lazy=_,A.Memo=h,A.Portal=t,A.Profiler=i,A.StrictMode=n,A.Suspense=f,A.SuspenseList=p,A.isAsyncMode=function(){return!1},A.isConcurrentMode=function(){return!1},A.isContextConsumer=function(a){return s(a)===o},A.isContextProvider=function(a){return s(a)===u},A.isElement=function(a){return typeof a=="object"&&a!==null&&a.$$typeof===e},A.isForwardRef=function(a){return s(a)===c},A.isFragment=function(a){return s(a)===r},A.isLazy=function(a){return s(a)===_},A.isMemo=function(a){return s(a)===h},A.isPortal=function(a){return s(a)===t},A.isProfiler=function(a){return s(a)===i},A.isStrictMode=function(a){return s(a)===n},A.isSuspense=function(a){return s(a)===f},A.isSuspenseList=function(a){return s(a)===p},A.isValidElementType=function(a){return typeof a=="string"||typeof a=="function"||a===r||a===i||a===n||a===f||a===p||a===g||typeof a=="object"&&a!==null&&(a.$$typeof===_||a.$$typeof===h||a.$$typeof===u||a.$$typeof===o||a.$$typeof===c||a.$$typeof===m||a.getModuleId!==void 0)},A.typeOf=s,A}var ut;function Sn(){return ut||(ut=1,nt.exports=$n()),nt.exports}var Zt=Sn(),En=Ht(Zt),_n=Wt({__proto__:null,default:En},[Zt]),On=["isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","isSuspenseList","isValidElementType"],ne=Object.fromEntries(On.map(e=>[e,t=>_n[e](t)||bn[e](t)]));function Qt(e,t=[]){if(Array.isArray(e))for(let r of e)Qt(r,t);else e!=null&&e!==!1&&e!==""&&t.push(e);return t}function ot(e){let t=e.type;if(typeof t=="string")return t;if(typeof t=="function")return t.displayName||t.name||"Unknown";if(ne.isFragment(e))return"React.Fragment";if(ne.isSuspense(e))return"React.Suspense";if(typeof t=="object"&&t!==null){if(ne.isContextProvider(e))return"Context.Provider";if(ne.isContextConsumer(e))return"Context.Consumer";if(ne.isForwardRef(e)){if(t.displayName)return t.displayName;let r=t.render.displayName||t.render.name||"";return r===""?"ForwardRef":`ForwardRef(${r})`}if(ne.isMemo(e)){let r=t.displayName||t.type.displayName||t.type.name||"";return r===""?"Memo":`Memo(${r})`}}return"UNDEFINED"}function Cn(e){let{props:t}=e;return Object.keys(t).filter(r=>r!=="children"&&t[r]!==void 0).sort()}var wn=(e,t,r,n,i,u)=>++n>t.maxDepth?Ve(ot(e),t):qe(ot(e),We(Cn(e),e.props,t,r+t.indent,n,i,u),Ye(Qt(e.props.children),t,r+t.indent,n,i,u),t,r),An=e=>e!=null&&ne.isElement(e),Tn={serialize:wn,test:An},Mn=typeof Symbol=="function"&&Symbol.for?Symbol.for("react.test.json"):245830487;function Nn(e){let{props:t}=e;return t?Object.keys(t).filter(r=>t[r]!==void 0).sort():[]}var Pn=(e,t,r,n,i,u)=>++n>t.maxDepth?Ve(e.type,t):qe(e.type,e.props?We(Nn(e),e.props,t,r+t.indent,n,i,u):"",e.children?Ye(e.children,t,r+t.indent,n,i,u):"",t,r),dn=e=>e&&e.$$typeof===Mn,Ln={serialize:Pn,test:dn},vt=Object.prototype.toString,Rn=Date.prototype.toISOString,Fn=Error.prototype.toString,lt=RegExp.prototype.toString;function $e(e){return typeof e.constructor=="function"&&e.constructor.name||"Object"}function In(e){return typeof window<"u"&&e===window}var Dn=/^Symbol\((.*)\)(.*)$/,jn=/\n/g,er=class extends Error{constructor(e,t){super(e),this.stack=t,this.name=this.constructor.name}};function Bn(e){return e==="[object Array]"||e==="[object ArrayBuffer]"||e==="[object DataView]"||e==="[object Float32Array]"||e==="[object Float64Array]"||e==="[object Int8Array]"||e==="[object Int16Array]"||e==="[object Int32Array]"||e==="[object Uint8Array]"||e==="[object Uint8ClampedArray]"||e==="[object Uint16Array]"||e==="[object Uint32Array]"}function xn(e){return Object.is(e,-0)?"-0":String(e)}function zn(e){return`${e}n`}function ct(e,t){return t?`[Function ${e.name||"anonymous"}]`:"[Function]"}function st(e){return String(e).replace(Dn,"Symbol($1)")}function at(e){return`[${Fn.call(e)}]`}function tr(e,t,r,n){if(e===!0||e===!1)return`${e}`;if(e===void 0)return"undefined";if(e===null)return"null";let i=typeof e;if(i==="number")return xn(e);if(i==="bigint")return zn(e);if(i==="string")return n?`"${e.replaceAll(/"|\\/g,"\\$&")}"`:`"${e}"`;if(i==="function")return ct(e,t);if(i==="symbol")return st(e);let u=vt.call(e);return u==="[object WeakMap]"?"WeakMap {}":u==="[object WeakSet]"?"WeakSet {}":u==="[object Function]"||u==="[object GeneratorFunction]"?ct(e,t):u==="[object Symbol]"?st(e):u==="[object Date]"?Number.isNaN(+e)?"Date { NaN }":Rn.call(e):u==="[object Error]"?at(e):u==="[object RegExp]"?r?lt.call(e).replaceAll(/[$()*+.?[\\\]^{|}]/g,"\\$&"):lt.call(e):e instanceof Error?at(e):null}function rr(e,t,r,n,i,u){if(i.includes(e))return"[Circular]";i=[...i],i.push(e);let o=++n>t.maxDepth,l=t.min;if(t.callToJSON&&!o&&e.toJSON&&typeof e.toJSON=="function"&&!u)return v(e.toJSON(),t,r,n,i,!0);let c=vt.call(e);return c==="[object Arguments]"?o?"[Arguments]":`${l?"":"Arguments "}[${Ee(e,t,r,n,i,v)}]`:Bn(c)?o?`[${e.constructor.name}]`:`${l||!t.printBasicPrototype&&e.constructor.name==="Array"?"":`${e.constructor.name} `}[${Ee(e,t,r,n,i,v)}]`:c==="[object Map]"?o?"[Map]":`Map {${pe(e.entries(),t,r,n,i,v," => ")}}`:c==="[object Set]"?o?"[Set]":`Set {${ke(e.values(),t,r,n,i,v)}}`:o||In(e)?`[${$e(e)}]`:`${l||!t.printBasicPrototype&&$e(e)==="Object"?"":`${$e(e)} `}{${Ue(e,t,r,n,i,v)}}`}var kn={test:e=>e&&e instanceof Error,serialize(e,t,r,n,i,u){if(i.includes(e))return"[Circular]";i=[...i,e];let o=++n>t.maxDepth,{message:l,cause:c,...f}=e,p={message:l,...typeof c<"u"?{cause:c}:{},...e instanceof AggregateError?{errors:e.errors}:{},...f},h=e.name!=="Error"?e.name:$e(e);return o?`[${h}]`:`${h} {${pe(Object.entries(p).values(),t,r,n,i,u)}}`}};function Un(e){return e.serialize!=null}function nr(e,t,r,n,i,u){let o;try{o=Un(e)?e.serialize(t,r,n,i,u,v):e.print(t,l=>v(l,r,n,i,u),l=>{let c=n+r.indent;return c+l.replaceAll(jn,`
|
|
3
|
+
${c}`)},{edgeSpacing:r.spacingOuter,min:r.min,spacing:r.spacingInner},r.colors)}catch(l){throw new er(l.message,l.stack)}if(typeof o!="string")throw new TypeError(`pretty-format: Plugin must return type "string" but instead returned "${typeof o}".`);return o}function ir(e,t){for(let r of e)try{if(r.test(t))return r}catch(n){throw new er(n.message,n.stack)}return null}function v(e,t,r,n,i,u){let o=ir(t.plugins,e);if(o!==null)return nr(o,e,t,r,n,i);let l=tr(e,t.printFunctionName,t.escapeRegex,t.escapeString);return l!==null?l:rr(e,t,r,n,i,u)}var Je={comment:"gray",content:"reset",prop:"yellow",tag:"cyan",value:"green"},ur=Object.keys(Je),W={callToJSON:!0,compareKeys:void 0,escapeRegex:!1,escapeString:!0,highlight:!1,indent:2,maxDepth:Number.POSITIVE_INFINITY,maxWidth:Number.POSITIVE_INFINITY,min:!1,plugins:[],printBasicPrototype:!0,printFunctionName:!0,theme:Je};function Wn(e){for(let t of Object.keys(e))if(!Object.prototype.hasOwnProperty.call(W,t))throw new Error(`pretty-format: Unknown option "${t}".`);if(e.min&&e.indent!==void 0&&e.indent!==0)throw new Error('pretty-format: Options "min" and "indent" cannot be used together.')}function Yn(){return ur.reduce((e,t)=>{let r=Je[t],n=r&&Z[r];if(n&&typeof n.close=="string"&&typeof n.open=="string")e[t]=n;else throw new Error(`pretty-format: Option "theme" has a key "${t}" whose value "${r}" is undefined in ansi-styles.`);return e},Object.create(null))}function qn(){return ur.reduce((e,t)=>(e[t]={close:"",open:""},e),Object.create(null))}function or(e){return e?.printFunctionName??W.printFunctionName}function lr(e){return e?.escapeRegex??W.escapeRegex}function cr(e){return e?.escapeString??W.escapeString}function ft(e){return{callToJSON:e?.callToJSON??W.callToJSON,colors:e?.highlight?Yn():qn(),compareKeys:typeof e?.compareKeys=="function"||e?.compareKeys===null?e.compareKeys:W.compareKeys,escapeRegex:lr(e),escapeString:cr(e),indent:e?.min?"":Vn(e?.indent??W.indent),maxDepth:e?.maxDepth??W.maxDepth,maxWidth:e?.maxWidth??W.maxWidth,min:e?.min??W.min,plugins:e?.plugins??W.plugins,printBasicPrototype:e?.printBasicPrototype??!0,printFunctionName:or(e),spacingInner:e?.min?" ":`
|
|
4
4
|
`,spacingOuter:e?.min?"":`
|
|
5
|
-
`}}function
|
|
6
|
-
`)}function yi(e,t){switch(e.nodeType){case 1:return sr(e,t);case 3:return t.inspect(e.data,t);default:return t.inspect(e,t)}}function sr(e,t){let r=e.getAttributeNames(),n=e.tagName.toLowerCase(),i=t.stylize(`<${n}`,"special"),u=t.stylize(">","special"),o=t.stylize(`</${n}>`,"special");t.truncate-=n.length*2+5;let l="";r.length>0&&(l+=" ",l+=Y(r.map(p=>[p,e.getAttribute(p)]),t,hi," ")),t.truncate-=l.length;let c=t.truncate,f=Ie(e.children,t);return f&&f.length>c&&(f=`${se}(${e.children.length})`),`${i}${l}${u}${f}${o}`}var bi=typeof Symbol=="function"&&typeof Symbol.for=="function",de=bi?Symbol.for("chai/inspect"):"@@chai/inspect",Le=Symbol.for("nodejs.util.inspect.custom"),St=new WeakMap,Et={},_t={undefined:(e,t)=>t.stylize("undefined","undefined"),null:(e,t)=>t.stylize("null","null"),boolean:(e,t)=>t.stylize(String(e),"boolean"),Boolean:(e,t)=>t.stylize(String(e),"boolean"),number:pt,Number:pt,bigint:ht,BigInt:ht,string:bt,String:bt,function:gt,Function:gt,symbol:$t,Symbol:$t,Array:Xn,Date:Qn,Map:ti,Set:ui,RegExp:ni,Promise:ai,WeakSet:(e,t)=>t.stylize("WeakSet{…}","special"),WeakMap:(e,t)=>t.stylize("WeakMap{…}","special"),Arguments:mi,Int8Array:X,Uint8Array:X,Uint8ClampedArray:X,Int16Array:X,Uint16Array:X,Int32Array:X,Uint32Array:X,Float32Array:X,Float64Array:X,Generator:()=>"",DataView:()=>"",ArrayBuffer:()=>"",Error:pi,HTMLCollection:Ie,NodeList:Ie},$i=(e,t,r,n)=>de in e&&typeof e[de]=="function"?e[de](t):Le in e&&typeof e[Le]=="function"?e[Le](t.depth,t,n):"inspect"in e&&typeof e.inspect=="function"?e.inspect(t.depth,t):"constructor"in e&&St.has(e.constructor)?St.get(e.constructor)(e,t):Et[r]?Et[r](e,t):"",Si=Object.prototype.toString;function Ee(e,t={}){let r=Kn(t,Ee),{customInspect:n}=r,i=e===null?"null":typeof e;if(i==="object"&&(i=Si.call(e).slice(8,-1)),i in _t)return _t[i](e,r);if(n&&e){let o=$i(e,r,i,Ee);if(o)return typeof o=="string"?o:Ee(o,r)}let u=e?Object.getPrototypeOf(e):!1;return u===Object.prototype||u===null?Se(e,r):e&&typeof HTMLElement=="function"&&e instanceof HTMLElement?sr(e,r):"constructor"in e?e.constructor!==Object?fi(e,r):Se(e,r):e===Object(e)?Se(e,r):r.stylize(String(e),i)}var{AsymmetricMatcher:Ei,DOMCollection:_i,DOMElement:Oi,Immutable:Ci,ReactElement:wi,ReactTestComponent:Ai}=Ke,Ot=[Ai,wi,Oi,_i,Ci,Ei];function ge(e,t=10,{maxLength:r,...n}={}){let i=r??1e4,u;try{u=V(e,{maxDepth:t,escapeString:!1,plugins:Ot,...n})}catch{u=V(e,{callToJSON:!1,maxDepth:t,escapeString:!1,plugins:Ot,...n})}return u.length>=i&&t>1?ge(e,Math.floor(Math.min(t,Number.MAX_SAFE_INTEGER)/2),{maxLength:r,...n}):u}var Ti=/%[sdjifoOc%]/g;function Mi(...e){if(typeof e[0]!="string"){let u=[];for(let o=0;o<e.length;o++)u.push(ae(e[o],{depth:0,colors:!1}));return u.join(" ")}let t=e.length,r=1,n=e[0],i=String(n).replace(Ti,u=>{if(u==="%%")return"%";if(r>=t)return u;switch(u){case"%s":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:typeof o=="number"&&o===0&&1/o<0?"-0":typeof o=="object"&&o!==null?typeof o.toString=="function"&&o.toString!==Object.prototype.toString?o.toString():ae(o,{depth:0,colors:!1}):String(o)}case"%d":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:Number(o).toString()}case"%i":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:Number.parseInt(String(o)).toString()}case"%f":return Number.parseFloat(String(e[r++])).toString();case"%o":return ae(e[r++],{showHidden:!0,showProxy:!0});case"%O":return ae(e[r++]);case"%c":return r++,"";case"%j":try{return JSON.stringify(e[r++])}catch(o){let l=o.message;if(l.includes("circular structure")||l.includes("cyclic structures")||l.includes("cyclic object"))return"[Circular]";throw o}default:return u}});for(let u=e[r];r<t;u=e[++r])u===null||typeof u!="object"?i+=` ${u}`:i+=` ${ae(u)}`;return i}function ae(e,t={}){return t.truncate===0&&(t.truncate=Number.POSITIVE_INFINITY),Ee(e,t)}function Ni(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Eu(e,t,r){let n=typeof e;if(!r.includes(n))throw new TypeError(`${t} value must be ${r.join(" or ")}, received "${n}"`)}function _u(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)}function Pi(e){return e===Object.prototype||e===Function.prototype||e===RegExp.prototype}function De(e){return Object.prototype.toString.apply(e).slice(8,-1)}function di(e,t){let r=typeof t=="function"?t:n=>t.add(n);Object.getOwnPropertyNames(e).forEach(r),Object.getOwnPropertySymbols(e).forEach(r)}function ar(e){let t=new Set;return Pi(e)?[]:(di(e,t),Array.from(t))}var fr={forceWritable:!1};function Ct(e,t=fr){return je(e,new WeakMap,t)}function je(e,t,r=fr){let n,i;if(t.has(e))return t.get(e);if(Array.isArray(e)){for(i=Array.from({length:n=e.length}),t.set(e,i);n--;)i[n]=je(e[n],t,r);return i}if(Object.prototype.toString.call(e)==="[object Object]"){i=Object.create(Object.getPrototypeOf(e)),t.set(e,i);let u=ar(e);for(let o of u){let l=Object.getOwnPropertyDescriptor(e,o);if(!l)continue;let c=je(e[o],t,r);r.forceWritable?Object.defineProperty(i,o,{enumerable:l.enumerable,configurable:!0,writable:!0,value:c}):"get"in l?Object.defineProperty(i,o,{...l,get(){return c}}):Object.defineProperty(i,o,{...l,value:c})}return i}return e}function Ou(){}var R=-1,L=1,P=0,N=class{0;1;constructor(e,t){this[0]=e,this[1]=t}};function Li(e,t){if(!e||!t||e.charAt(0)!==t.charAt(0))return 0;let r=0,n=Math.min(e.length,t.length),i=n,u=0;for(;r<i;)e.substring(u,i)===t.substring(u,i)?(r=i,u=r):n=i,i=Math.floor((n-r)/2+r);return i}function mr(e,t){if(!e||!t||e.charAt(e.length-1)!==t.charAt(t.length-1))return 0;let r=0,n=Math.min(e.length,t.length),i=n,u=0;for(;r<i;)e.substring(e.length-i,e.length-u)===t.substring(t.length-i,t.length-u)?(r=i,u=r):n=i,i=Math.floor((n-r)/2+r);return i}function wt(e,t){let r=e.length,n=t.length;if(r===0||n===0)return 0;r>n?e=e.substring(r-n):r<n&&(t=t.substring(0,r));let i=Math.min(r,n);if(e===t)return i;let u=0,o=1;for(;;){let l=e.substring(i-o),c=t.indexOf(l);if(c===-1)return u;o+=c,(c===0||e.substring(i-o)===t.substring(0,o))&&(u=o,o++)}}function Ri(e){let t=!1,r=[],n=0,i=null,u=0,o=0,l=0,c=0,f=0;for(;u<e.length;)e[u][0]===P?(r[n++]=u,o=c,l=f,c=0,f=0,i=e[u][1]):(e[u][0]===L?c+=e[u][1].length:f+=e[u][1].length,i&&i.length<=Math.max(o,l)&&i.length<=Math.max(c,f)&&(e.splice(r[n-1],0,new N(R,i)),e[r[n-1]+1][0]=L,n--,n--,u=n>0?r[n-1]:-1,o=0,l=0,c=0,f=0,i=null,t=!0)),u++;for(t&&gr(e),Di(e),u=1;u<e.length;){if(e[u-1][0]===R&&e[u][0]===L){let p=e[u-1][1],h=e[u][1],_=wt(p,h),g=wt(h,p);_>=g?(_>=p.length/2||_>=h.length/2)&&(e.splice(u,0,new N(P,h.substring(0,_))),e[u-1][1]=p.substring(0,p.length-_),e[u+1][1]=h.substring(_),u++):(g>=p.length/2||g>=h.length/2)&&(e.splice(u,0,new N(P,p.substring(0,g))),e[u-1][0]=L,e[u-1][1]=h.substring(0,h.length-g),e[u+1][0]=R,e[u+1][1]=p.substring(g),u++),u++}u++}}var At=/[^a-z0-9]/i,Tt=/\s/,Mt=/[\r\n]/,Fi=/\n\r?\n$/,Ii=/^\r?\n\r?\n/;function Di(e){let t=1;for(;t<e.length-1;){if(e[t-1][0]===P&&e[t+1][0]===P){let r=e[t-1][1],n=e[t][1],i=e[t+1][1],u=mr(r,n);if(u){let p=n.substring(n.length-u);r=r.substring(0,r.length-u),n=p+n.substring(0,n.length-u),i=p+i}let o=r,l=n,c=i,f=he(r,n)+he(n,i);for(;n.charAt(0)===i.charAt(0);){r+=n.charAt(0),n=n.substring(1)+i.charAt(0),i=i.substring(1);let p=he(r,n)+he(n,i);p>=f&&(f=p,o=r,l=n,c=i)}e[t-1][1]!==o&&(o?e[t-1][1]=o:(e.splice(t-1,1),t--),e[t][1]=l,c?e[t+1][1]=c:(e.splice(t+1,1),t--))}t++}}function gr(e){e.push(new N(P,""));let t=0,r=0,n=0,i="",u="",o;for(;t<e.length;)switch(e[t][0]){case L:n++,u+=e[t][1],t++;break;case R:r++,i+=e[t][1],t++;break;case P:r+n>1?(r!==0&&n!==0&&(o=Li(u,i),o!==0&&(t-r-n>0&&e[t-r-n-1][0]===P?e[t-r-n-1][1]+=u.substring(0,o):(e.splice(0,0,new N(P,u.substring(0,o))),t++),u=u.substring(o),i=i.substring(o)),o=mr(u,i),o!==0&&(e[t][1]=u.substring(u.length-o)+e[t][1],u=u.substring(0,u.length-o),i=i.substring(0,i.length-o))),t-=r+n,e.splice(t,r+n),i.length&&(e.splice(t,0,new N(R,i)),t++),u.length&&(e.splice(t,0,new N(L,u)),t++),t++):t!==0&&e[t-1][0]===P?(e[t-1][1]+=e[t][1],e.splice(t,1)):t++,n=0,r=0,i="",u="";break}e[e.length-1][1]===""&&e.pop();let l=!1;for(t=1;t<e.length-1;)e[t-1][0]===P&&e[t+1][0]===P&&(e[t][1].substring(e[t][1].length-e[t-1][1].length)===e[t-1][1]?(e[t][1]=e[t-1][1]+e[t][1].substring(0,e[t][1].length-e[t-1][1].length),e[t+1][1]=e[t-1][1]+e[t+1][1],e.splice(t-1,1),l=!0):e[t][1].substring(0,e[t+1][1].length)===e[t+1][1]&&(e[t-1][1]+=e[t+1][1],e[t][1]=e[t][1].substring(e[t+1][1].length)+e[t+1][1],e.splice(t+1,1),l=!0)),t++;l&&gr(e)}function he(e,t){if(!e||!t)return 6;let r=e.charAt(e.length-1),n=t.charAt(0),i=r.match(At),u=n.match(At),o=i&&r.match(Tt),l=u&&n.match(Tt),c=o&&r.match(Mt),f=l&&n.match(Mt),p=c&&e.match(Fi),h=f&&t.match(Ii);return p||h?5:c||f?4:i&&!o&&l?3:o||l?2:i||u?1:0}var pr="Compared values have no visual difference.",ji="Compared values serialize to the same structure.\nPrinting internal object structure without calling `toJSON` instead.",ye={},Nt;function Bi(){if(Nt)return ye;Nt=1,Object.defineProperty(ye,"__esModule",{value:!0}),ye.default=_;let e="diff-sequences",t=0,r=(g,m,s,a,b)=>{let S=0;for(;g<m&&s<a&&b(g,s);)g+=1,s+=1,S+=1;return S},n=(g,m,s,a,b)=>{let S=0;for(;g<=m&&s<=a&&b(m,a);)m-=1,a-=1,S+=1;return S},i=(g,m,s,a,b,S,C)=>{let y=0,E=-g,O=S[y],$=O;S[y]+=r(O+1,m,a+O-E+1,s,b);let M=g<C?g:C;for(y+=1,E+=2;y<=M;y+=1,E+=2){if(y!==g&&$<S[y])O=S[y];else if(O=$+1,m<=O)return y-1;$=S[y],S[y]=O+r(O+1,m,a+O-E+1,s,b)}return C},u=(g,m,s,a,b,S,C)=>{let y=0,E=g,O=S[y],$=O;S[y]-=n(m,O-1,s,a+O-E-1,b);let M=g<C?g:C;for(y+=1,E-=2;y<=M;y+=1,E-=2){if(y!==g&&S[y]<$)O=S[y];else if(O=$-1,O<m)return y-1;$=S[y],S[y]=O-n(m,O-1,s,a+O-E-1,b)}return C},o=(g,m,s,a,b,S,C,y,E,O,$)=>{let M=a-m,J=s-m,I=b-a-J,F=-I-(g-1),j=-I+(g-1),B=t,K=g<y?g:y;for(let w=0,d=-g;w<=K;w+=1,d+=2){let G=w===0||w!==g&&B<C[w],D=G?C[w]:B,z=G?D:D+1,H=M+z-d,k=r(z+1,s,H+1,b,S),U=z+k;if(B=C[w],C[w]=U,F<=d&&d<=j){let re=(g-1-(d+I))/2;if(re<=O&&E[re]-1<=U){let Q=M+D-(G?d+1:d-1),x=n(m,D,a,Q,S),q=D-x,ue=Q-x,oe=q+1,Ae=ue+1;$.nChangePreceding=g-1,g-1===oe+Ae-m-a?($.aEndPreceding=m,$.bEndPreceding=a):($.aEndPreceding=oe,$.bEndPreceding=Ae),$.nCommonPreceding=x,x!==0&&($.aCommonPreceding=oe,$.bCommonPreceding=Ae),$.nCommonFollowing=k,k!==0&&($.aCommonFollowing=z+1,$.bCommonFollowing=H+1);let Xe=U+1,Ze=H+k+1;return $.nChangeFollowing=g-1,g-1===s+b-Xe-Ze?($.aStartFollowing=s,$.bStartFollowing=b):($.aStartFollowing=Xe,$.bStartFollowing=Ze),!0}}}return!1},l=(g,m,s,a,b,S,C,y,E,O,$)=>{let M=b-s,J=s-m,I=b-a-J,F=I-g,j=I+g,B=t,K=g<O?g:O;for(let w=0,d=g;w<=K;w+=1,d-=2){let G=w===0||w!==g&&E[w]<B,D=G?E[w]:B,z=G?D:D-1,H=M+z-d,k=n(m,z-1,a,H-1,S),U=z-k;if(B=E[w],E[w]=U,F<=d&&d<=j){let re=(g+(d-I))/2;if(re<=y&&U-1<=C[re]){let Q=H-k;if($.nChangePreceding=g,g===U+Q-m-a?($.aEndPreceding=m,$.bEndPreceding=a):($.aEndPreceding=U,$.bEndPreceding=Q),$.nCommonPreceding=k,k!==0&&($.aCommonPreceding=U,$.bCommonPreceding=Q),$.nChangeFollowing=g-1,g===1)$.nCommonFollowing=0,$.aStartFollowing=s,$.bStartFollowing=b;else{let x=M+D-(G?d-1:d+1),q=r(D,s,x,b,S);$.nCommonFollowing=q,q!==0&&($.aCommonFollowing=D,$.bCommonFollowing=x);let ue=D+q,oe=x+q;g-1===s+b-ue-oe?($.aStartFollowing=s,$.bStartFollowing=b):($.aStartFollowing=ue,$.bStartFollowing=oe)}return!0}}}return!1},c=(g,m,s,a,b,S,C,y,E)=>{let O=a-m,$=b-s,M=s-m,J=b-a,I=J-M,F=M,j=M;if(C[0]=m-1,y[0]=s,I%2===0){let B=(g||I)/2,K=(M+J)/2;for(let w=1;w<=K;w+=1)if(F=i(w,s,b,O,S,C,F),w<B)j=u(w,m,a,$,S,y,j);else if(l(w,m,s,a,b,S,C,F,y,j,E))return}else{let B=((g||I)+1)/2,K=(M+J+1)/2,w=1;for(F=i(w,s,b,O,S,C,F),w+=1;w<=K;w+=1)if(j=u(w-1,m,a,$,S,y,j),w<B)F=i(w,s,b,O,S,C,F);else if(o(w,m,s,a,b,S,C,F,y,j,E))return}throw new Error(`${e}: no overlap aStart=${m} aEnd=${s} bStart=${a} bEnd=${b}`)},f=(g,m,s,a,b,S,C,y,E,O)=>{if(b-a<s-m){if(S=!S,S&&C.length===1){let{foundSubsequence:re,isCommon:Q}=C[0];C[1]={foundSubsequence:(x,q,ue)=>{re(x,ue,q)},isCommon:(x,q)=>Q(q,x)}}let k=m,U=s;m=a,s=b,a=k,b=U}let{foundSubsequence:$,isCommon:M}=C[S?1:0];c(g,m,s,a,b,M,y,E,O);let{nChangePreceding:J,aEndPreceding:I,bEndPreceding:F,nCommonPreceding:j,aCommonPreceding:B,bCommonPreceding:K,nCommonFollowing:w,aCommonFollowing:d,bCommonFollowing:G,nChangeFollowing:D,aStartFollowing:z,bStartFollowing:H}=O;m<I&&a<F&&f(J,m,I,a,F,S,C,y,E,O),j!==0&&$(j,B,K),w!==0&&$(w,d,G),z<s&&H<b&&f(D,z,s,H,b,S,C,y,E,O)},p=(g,m)=>{if(typeof m!="number")throw new TypeError(`${e}: ${g} typeof ${typeof m} is not a number`);if(!Number.isSafeInteger(m))throw new RangeError(`${e}: ${g} value ${m} is not a safe integer`);if(m<0)throw new RangeError(`${e}: ${g} value ${m} is a negative integer`)},h=(g,m)=>{let s=typeof m;if(s!=="function")throw new TypeError(`${e}: ${g} typeof ${s} is not a function`)};function _(g,m,s,a){p("aLength",g),p("bLength",m),h("isCommon",s),h("foundSubsequence",a);let b=r(0,g,0,m,s);if(b!==0&&a(b,0,0),g!==b||m!==b){let S=b,C=b,y=n(S,g-1,C,m-1,s),E=g-y,O=m-y,$=b+y;g!==$&&m!==$&&f(0,S,E,C,O,!1,[{foundSubsequence:a,isCommon:s}],[t],[t],{aCommonFollowing:t,aCommonPreceding:t,aEndPreceding:t,aStartFollowing:t,bCommonFollowing:t,bCommonPreceding:t,bEndPreceding:t,bStartFollowing:t,nChangeFollowing:t,nChangePreceding:t,nCommonFollowing:t,nCommonPreceding:t}),y!==0&&a(y,E,O)}}return ye}var xi=Bi(),hr=Ni(xi);function zi(e,t){return e.replace(/\s+$/,r=>t(r))}function Ge(e,t,r,n,i,u){return e.length!==0?r(`${n} ${zi(e,i)}`):n!==" "?r(n):t&&u.length!==0?r(`${n} ${u}`):""}function yr(e,t,{aColor:r,aIndicator:n,changeLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function br(e,t,{bColor:r,bIndicator:n,changeLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function $r(e,t,{commonColor:r,commonIndicator:n,commonLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function Pt(e,t,r,n,{patchColor:i}){return i(`@@ -${e+1},${t-e} +${r+1},${n-r} @@`)}function ki(e,t){let r=e.length,n=t.contextLines,i=n+n,u=r,o=!1,l=0,c=0;for(;c!==r;){let y=c;for(;c!==r&&e[c][0]===P;)c+=1;if(y!==c)if(y===0)c>n&&(u-=c-n,o=!0);else if(c===r){let E=c-y;E>n&&(u-=E-n,o=!0)}else{let E=c-y;E>i&&(u-=E-i,l+=1)}for(;c!==r&&e[c][0]!==P;)c+=1}let f=l!==0||o;l!==0?u+=l+1:o&&(u+=1);let p=u-1,h=[],_=0;f&&h.push("");let g=0,m=0,s=0,a=0,b=y=>{let E=h.length;h.push($r(y,E===0||E===p,t)),s+=1,a+=1},S=y=>{let E=h.length;h.push(yr(y,E===0||E===p,t)),s+=1},C=y=>{let E=h.length;h.push(br(y,E===0||E===p,t)),a+=1};for(c=0;c!==r;){let y=c;for(;c!==r&&e[c][0]===P;)c+=1;if(y!==c)if(y===0){c>n&&(y=c-n,g=y,m=y,s=g,a=m);for(let E=y;E!==c;E+=1)b(e[E][1])}else if(c===r){let E=c-y>n?y+n:c;for(let O=y;O!==E;O+=1)b(e[O][1])}else{let E=c-y;if(E>i){let O=y+n;for(let M=y;M!==O;M+=1)b(e[M][1]);h[_]=Pt(g,s,m,a,t),_=h.length,h.push("");let $=E-i;g=s+$,m=a+$,s=g,a=m;for(let M=c-n;M!==c;M+=1)b(e[M][1])}else for(let O=y;O!==c;O+=1)b(e[O][1])}for(;c!==r&&e[c][0]===R;)S(e[c][1]),c+=1;for(;c!==r&&e[c][0]===L;)C(e[c][1]),c+=1}return f&&(h[_]=Pt(g,s,m,a,t)),h.join(`
|
|
7
|
-
`)}function Ui(e,t){return e.map((r,n,i)=>{let u=r[1],o=n===0||n===i.length-1;switch(r[0]){case R:return
|
|
8
|
-
`)}var
|
|
5
|
+
`}}function Vn(e){return Array.from({length:e+1}).join(" ")}function V(e,t){if(t&&(Wn(t),t.plugins)){let n=ir(t.plugins,e);if(n!==null)return nr(n,e,ft(t),"",0,[])}let r=tr(e,or(t),lr(t),cr(t));return r!==null?r:rr(e,ft(t),"",0,[])}var Ke={AsymmetricMatcher:Ir,DOMCollection:Ur,DOMElement:Zr,Immutable:gn,ReactElement:Tn,ReactTestComponent:Ln,Error:kn},mt={bold:["1","22"],dim:["2","22"],italic:["3","23"],underline:["4","24"],inverse:["7","27"],hidden:["8","28"],strike:["9","29"],black:["30","39"],red:["31","39"],green:["32","39"],yellow:["33","39"],blue:["34","39"],magenta:["35","39"],cyan:["36","39"],white:["37","39"],brightblack:["30;1","39"],brightred:["31;1","39"],brightgreen:["32;1","39"],brightyellow:["33;1","39"],brightblue:["34;1","39"],brightmagenta:["35;1","39"],brightcyan:["36;1","39"],brightwhite:["37;1","39"],grey:["90","39"]},Jn={special:"cyan",number:"yellow",bigint:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",symbol:"green",date:"magenta",regexp:"red"},se="…";function Kn(e,t){let r=mt[Jn[t]]||mt[t]||"";return r?`\x1B[${r[0]}m${String(e)}\x1B[${r[1]}m`:String(e)}function Gn({showHidden:e=!1,depth:t=2,colors:r=!1,customInspect:n=!0,showProxy:i=!1,maxArrayLength:u=1/0,breakLength:o=1/0,seen:l=[],truncate:c=1/0,stylize:f=String}={},p){let h={showHidden:!!e,depth:Number(t),colors:!!r,customInspect:!!n,showProxy:!!i,maxArrayLength:Number(u),breakLength:Number(o),truncate:Number(c),seen:l,inspect:p,stylize:f};return h.colors&&(h.stylize=Kn),h}function Hn(e){return e>="\uD800"&&e<="\uDBFF"}function te(e,t,r=se){e=String(e);let n=r.length,i=e.length;if(n>t&&i>n)return r;if(i>t&&i>n){let u=t-n;return u>0&&Hn(e[u-1])&&(u=u-1),`${e.slice(0,u)}${r}`}return e}function Y(e,t,r,n=", "){r=r||t.inspect;let i=e.length;if(i===0)return"";let u=t.truncate,o="",l="",c="";for(let f=0;f<i;f+=1){let p=f+1===e.length,h=f+2===e.length;c=`${se}(${e.length-f})`;let _=e[f];t.truncate=u-o.length-(p?0:n.length);let g=l||r(_,t)+(p?"":n),m=o.length+g.length,s=m+c.length;if(p&&m>u&&o.length+c.length<=u||!p&&!h&&s>u||(l=p?"":r(e[f+1],t)+(h?"":n),!p&&h&&s>u&&m+l.length>u))break;if(o+=g,!p&&!h&&m+l.length>=u){c=`${se}(${e.length-f-1})`;break}c=""}return`${o}${c}`}function Xn(e){return e.match(/^[a-zA-Z_][a-zA-Z_0-9]*$/)?e:JSON.stringify(e).replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'")}function me([e,t],r){return r.truncate-=2,typeof e=="string"?e=Xn(e):typeof e!="number"&&(e=`[${r.inspect(e,r)}]`),r.truncate-=e.length,t=r.inspect(t,r),`${e}: ${t}`}function Zn(e,t){let r=Object.keys(e).slice(e.length);if(!e.length&&!r.length)return"[]";t.truncate-=4;let n=Y(e,t);t.truncate-=n.length;let i="";return r.length&&(i=Y(r.map(u=>[u,e[u]]),t,me)),`[ ${n}${i?`, ${i}`:""} ]`}var Qn=e=>typeof Buffer=="function"&&e instanceof Buffer?"Buffer":e[Symbol.toStringTag]?e[Symbol.toStringTag]:e.constructor.name;function X(e,t){let r=Qn(e);t.truncate-=r.length+4;let n=Object.keys(e).slice(e.length);if(!e.length&&!n.length)return`${r}[]`;let i="";for(let o=0;o<e.length;o++){let l=`${t.stylize(te(e[o],t.truncate),"number")}${o===e.length-1?"":", "}`;if(t.truncate-=l.length,e[o]!==e.length&&t.truncate<=3){i+=`${se}(${e.length-e[o]+1})`;break}i+=l}let u="";return n.length&&(u=Y(n.map(o=>[o,e[o]]),t,me)),`${r}[ ${i}${u?`, ${u}`:""} ]`}function vn(e,t){let r=e.toJSON();if(r===null)return"Invalid Date";let n=r.split("T"),i=n[0];return t.stylize(`${i}T${te(n[1],t.truncate-i.length-1)}`,"date")}function gt(e,t){let r=e[Symbol.toStringTag]||"Function",n=e.name;return n?t.stylize(`[${r} ${te(n,t.truncate-11)}]`,"special"):t.stylize(`[${r}]`,"special")}function ei([e,t],r){return r.truncate-=4,e=r.inspect(e,r),r.truncate-=e.length,t=r.inspect(t,r),`${e} => ${t}`}function ti(e){let t=[];return e.forEach((r,n)=>{t.push([n,r])}),t}function ri(e,t){return e.size===0?"Map{}":(t.truncate-=7,`Map{ ${Y(ti(e),t,ei)} }`)}var ni=Number.isNaN||(e=>e!==e);function pt(e,t){return ni(e)?t.stylize("NaN","number"):e===1/0?t.stylize("Infinity","number"):e===-1/0?t.stylize("-Infinity","number"):e===0?t.stylize(1/e===1/0?"+0":"-0","number"):t.stylize(te(String(e),t.truncate),"number")}function ht(e,t){let r=te(e.toString(),t.truncate-1);return r!==se&&(r+="n"),t.stylize(r,"bigint")}function ii(e,t){let r=e.toString().split("/")[2],n=t.truncate-(2+r.length),i=e.source;return t.stylize(`/${te(i,n)}/${r}`,"regexp")}function ui(e){let t=[];return e.forEach(r=>{t.push(r)}),t}function oi(e,t){return e.size===0?"Set{}":(t.truncate-=7,`Set{ ${Y(ui(e),t)} }`)}var yt=new RegExp("['\\u0000-\\u001f\\u007f-\\u009f\\u00ad\\u0600-\\u0604\\u070f\\u17b4\\u17b5\\u200c-\\u200f\\u2028-\\u202f\\u2060-\\u206f\\ufeff\\ufff0-\\uffff]","g"),li={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r","'":"\\'","\\":"\\\\"},ci=16;function si(e){return li[e]||`\\u${`0000${e.charCodeAt(0).toString(ci)}`.slice(-4)}`}function bt(e,t){return yt.test(e)&&(e=e.replace(yt,si)),t.stylize(`'${te(e,t.truncate-2)}'`,"string")}function $t(e){return"description"in Symbol.prototype?e.description?`Symbol(${e.description})`:"Symbol()":e.toString()}var sr=()=>"Promise{…}";try{let{getPromiseDetails:e,kPending:t,kRejected:r}=process.binding("util");Array.isArray(e(Promise.resolve()))&&(sr=(n,i)=>{let[u,o]=e(n);return u===t?"Promise{<pending>}":`Promise${u===r?"!":""}{${i.inspect(o,i)}}`})}catch{}var ai=sr;function Se(e,t){let r=Object.getOwnPropertyNames(e),n=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e):[];if(r.length===0&&n.length===0)return"{}";if(t.truncate-=4,t.seen=t.seen||[],t.seen.includes(e))return"[Circular]";t.seen.push(e);let i=Y(r.map(l=>[l,e[l]]),t,me),u=Y(n.map(l=>[l,e[l]]),t,me);t.seen.pop();let o="";return i&&u&&(o=", "),`{ ${i}${o}${u} }`}var Ne=typeof Symbol<"u"&&Symbol.toStringTag?Symbol.toStringTag:!1;function fi(e,t){let r="";return Ne&&Ne in e&&(r=e[Ne]),r=r||e.constructor.name,(!r||r==="_class")&&(r="<Anonymous Class>"),t.truncate-=r.length,`${r}${Se(e,t)}`}function mi(e,t){return e.length===0?"Arguments[]":(t.truncate-=13,`Arguments[ ${Y(e,t)} ]`)}var gi=["stack","line","column","name","message","fileName","lineNumber","columnNumber","number","description","cause"];function pi(e,t){let r=Object.getOwnPropertyNames(e).filter(o=>gi.indexOf(o)===-1),n=e.name;t.truncate-=n.length;let i="";if(typeof e.message=="string"?i=te(e.message,t.truncate):r.unshift("message"),i=i?`: ${i}`:"",t.truncate-=i.length+5,t.seen=t.seen||[],t.seen.includes(e))return"[Circular]";t.seen.push(e);let u=Y(r.map(o=>[o,e[o]]),t,me);return`${n}${i}${u?` { ${u} }`:""}`}function hi([e,t],r){return r.truncate-=3,t?`${r.stylize(String(e),"yellow")}=${r.stylize(`"${t}"`,"string")}`:`${r.stylize(String(e),"yellow")}`}function Fe(e,t){return Y(e,t,yi,`
|
|
6
|
+
`)}function yi(e,t){switch(e.nodeType){case 1:return ar(e,t);case 3:return t.inspect(e.data,t);default:return t.inspect(e,t)}}function ar(e,t){let r=e.getAttributeNames(),n=e.tagName.toLowerCase(),i=t.stylize(`<${n}`,"special"),u=t.stylize(">","special"),o=t.stylize(`</${n}>`,"special");t.truncate-=n.length*2+5;let l="";r.length>0&&(l+=" ",l+=Y(r.map(p=>[p,e.getAttribute(p)]),t,hi," ")),t.truncate-=l.length;let c=t.truncate,f=Fe(e.children,t);return f&&f.length>c&&(f=`${se}(${e.children.length})`),`${i}${l}${u}${f}${o}`}var bi=typeof Symbol=="function"&&typeof Symbol.for=="function",Pe=bi?Symbol.for("chai/inspect"):"@@chai/inspect",de=Symbol.for("nodejs.util.inspect.custom"),St=new WeakMap,Et={},_t={undefined:(e,t)=>t.stylize("undefined","undefined"),null:(e,t)=>t.stylize("null","null"),boolean:(e,t)=>t.stylize(String(e),"boolean"),Boolean:(e,t)=>t.stylize(String(e),"boolean"),number:pt,Number:pt,bigint:ht,BigInt:ht,string:bt,String:bt,function:gt,Function:gt,symbol:$t,Symbol:$t,Array:Zn,Date:vn,Map:ri,Set:oi,RegExp:ii,Promise:ai,WeakSet:(e,t)=>t.stylize("WeakSet{…}","special"),WeakMap:(e,t)=>t.stylize("WeakMap{…}","special"),Arguments:mi,Int8Array:X,Uint8Array:X,Uint8ClampedArray:X,Int16Array:X,Uint16Array:X,Int32Array:X,Uint32Array:X,Float32Array:X,Float64Array:X,Generator:()=>"",DataView:()=>"",ArrayBuffer:()=>"",Error:pi,HTMLCollection:Fe,NodeList:Fe},$i=(e,t,r)=>Pe in e&&typeof e[Pe]=="function"?e[Pe](t):de in e&&typeof e[de]=="function"?e[de](t.depth,t):"inspect"in e&&typeof e.inspect=="function"?e.inspect(t.depth,t):"constructor"in e&&St.has(e.constructor)?St.get(e.constructor)(e,t):Et[r]?Et[r](e,t):"",Si=Object.prototype.toString;function Ie(e,t={}){let r=Gn(t,Ie),{customInspect:n}=r,i=e===null?"null":typeof e;if(i==="object"&&(i=Si.call(e).slice(8,-1)),i in _t)return _t[i](e,r);if(n&&e){let o=$i(e,r,i);if(o)return typeof o=="string"?o:Ie(o,r)}let u=e?Object.getPrototypeOf(e):!1;return u===Object.prototype||u===null?Se(e,r):e&&typeof HTMLElement=="function"&&e instanceof HTMLElement?ar(e,r):"constructor"in e?e.constructor!==Object?fi(e,r):Se(e,r):e===Object(e)?Se(e,r):r.stylize(String(e),i)}var{AsymmetricMatcher:Ei,DOMCollection:_i,DOMElement:Oi,Immutable:Ci,ReactElement:wi,ReactTestComponent:Ai}=Ke,Ot=[Ai,wi,Oi,_i,Ci,Ei];function ge(e,t=10,{maxLength:r,...n}={}){let i=r??1e4,u;try{u=V(e,{maxDepth:t,escapeString:!1,plugins:Ot,...n})}catch{u=V(e,{callToJSON:!1,maxDepth:t,escapeString:!1,plugins:Ot,...n})}return u.length>=i&&t>1?ge(e,Math.floor(Math.min(t,Number.MAX_SAFE_INTEGER)/2),{maxLength:r,...n}):u}var Ti=/%[sdjifoOc%]/g;function Mi(...e){if(typeof e[0]!="string"){let u=[];for(let o=0;o<e.length;o++)u.push(ae(e[o],{depth:0,colors:!1}));return u.join(" ")}let t=e.length,r=1,n=e[0],i=String(n).replace(Ti,u=>{if(u==="%%")return"%";if(r>=t)return u;switch(u){case"%s":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:typeof o=="number"&&o===0&&1/o<0?"-0":typeof o=="object"&&o!==null?typeof o.toString=="function"&&o.toString!==Object.prototype.toString?o.toString():ae(o,{depth:0,colors:!1}):String(o)}case"%d":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:Number(o).toString()}case"%i":{let o=e[r++];return typeof o=="bigint"?`${o.toString()}n`:Number.parseInt(String(o)).toString()}case"%f":return Number.parseFloat(String(e[r++])).toString();case"%o":return ae(e[r++],{showHidden:!0,showProxy:!0});case"%O":return ae(e[r++]);case"%c":return r++,"";case"%j":try{return JSON.stringify(e[r++])}catch(o){let l=o.message;if(l.includes("circular structure")||l.includes("cyclic structures")||l.includes("cyclic object"))return"[Circular]";throw o}default:return u}});for(let u=e[r];r<t;u=e[++r])u===null||typeof u!="object"?i+=` ${u}`:i+=` ${ae(u)}`;return i}function ae(e,t={}){return t.truncate===0&&(t.truncate=Number.POSITIVE_INFINITY),Ie(e,t)}function Ni(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Eu(e,t,r){let n=typeof e;if(!r.includes(n))throw new TypeError(`${t} value must be ${r.join(" or ")}, received "${n}"`)}function _u(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)}function Pi(e){return e===Object.prototype||e===Function.prototype||e===RegExp.prototype}function De(e){return Object.prototype.toString.apply(e).slice(8,-1)}function di(e,t){let r=typeof t=="function"?t:n=>t.add(n);Object.getOwnPropertyNames(e).forEach(r),Object.getOwnPropertySymbols(e).forEach(r)}function fr(e){let t=new Set;return Pi(e)?[]:(di(e,t),Array.from(t))}var mr={forceWritable:!1};function Ct(e,t=mr){return je(e,new WeakMap,t)}function je(e,t,r=mr){let n,i;if(t.has(e))return t.get(e);if(Array.isArray(e)){for(i=Array.from({length:n=e.length}),t.set(e,i);n--;)i[n]=je(e[n],t,r);return i}if(Object.prototype.toString.call(e)==="[object Object]"){i=Object.create(Object.getPrototypeOf(e)),t.set(e,i);let u=fr(e);for(let o of u){let l=Object.getOwnPropertyDescriptor(e,o);if(!l)continue;let c=je(e[o],t,r);r.forceWritable?Object.defineProperty(i,o,{enumerable:l.enumerable,configurable:!0,writable:!0,value:c}):"get"in l?Object.defineProperty(i,o,{...l,get(){return c}}):Object.defineProperty(i,o,{...l,value:c})}return i}return e}function Ou(){}var R=-1,L=1,P=0,N=class{0;1;constructor(e,t){this[0]=e,this[1]=t}};function Li(e,t){if(!e||!t||e.charAt(0)!==t.charAt(0))return 0;let r=0,n=Math.min(e.length,t.length),i=n,u=0;for(;r<i;)e.substring(u,i)===t.substring(u,i)?(r=i,u=r):n=i,i=Math.floor((n-r)/2+r);return i}function gr(e,t){if(!e||!t||e.charAt(e.length-1)!==t.charAt(t.length-1))return 0;let r=0,n=Math.min(e.length,t.length),i=n,u=0;for(;r<i;)e.substring(e.length-i,e.length-u)===t.substring(t.length-i,t.length-u)?(r=i,u=r):n=i,i=Math.floor((n-r)/2+r);return i}function wt(e,t){let r=e.length,n=t.length;if(r===0||n===0)return 0;r>n?e=e.substring(r-n):r<n&&(t=t.substring(0,r));let i=Math.min(r,n);if(e===t)return i;let u=0,o=1;for(;;){let l=e.substring(i-o),c=t.indexOf(l);if(c===-1)return u;o+=c,(c===0||e.substring(i-o)===t.substring(0,o))&&(u=o,o++)}}function Ri(e){let t=!1,r=[],n=0,i=null,u=0,o=0,l=0,c=0,f=0;for(;u<e.length;)e[u][0]===P?(r[n++]=u,o=c,l=f,c=0,f=0,i=e[u][1]):(e[u][0]===L?c+=e[u][1].length:f+=e[u][1].length,i&&i.length<=Math.max(o,l)&&i.length<=Math.max(c,f)&&(e.splice(r[n-1],0,new N(R,i)),e[r[n-1]+1][0]=L,n--,n--,u=n>0?r[n-1]:-1,o=0,l=0,c=0,f=0,i=null,t=!0)),u++;for(t&&pr(e),Di(e),u=1;u<e.length;){if(e[u-1][0]===R&&e[u][0]===L){let p=e[u-1][1],h=e[u][1],_=wt(p,h),g=wt(h,p);_>=g?(_>=p.length/2||_>=h.length/2)&&(e.splice(u,0,new N(P,h.substring(0,_))),e[u-1][1]=p.substring(0,p.length-_),e[u+1][1]=h.substring(_),u++):(g>=p.length/2||g>=h.length/2)&&(e.splice(u,0,new N(P,p.substring(0,g))),e[u-1][0]=L,e[u-1][1]=h.substring(0,h.length-g),e[u+1][0]=R,e[u+1][1]=p.substring(g),u++),u++}u++}}var At=/[^a-z0-9]/i,Tt=/\s/,Mt=/[\r\n]/,Fi=/\n\r?\n$/,Ii=/^\r?\n\r?\n/;function Di(e){let t=1;for(;t<e.length-1;){if(e[t-1][0]===P&&e[t+1][0]===P){let r=e[t-1][1],n=e[t][1],i=e[t+1][1],u=gr(r,n);if(u){let p=n.substring(n.length-u);r=r.substring(0,r.length-u),n=p+n.substring(0,n.length-u),i=p+i}let o=r,l=n,c=i,f=he(r,n)+he(n,i);for(;n.charAt(0)===i.charAt(0);){r+=n.charAt(0),n=n.substring(1)+i.charAt(0),i=i.substring(1);let p=he(r,n)+he(n,i);p>=f&&(f=p,o=r,l=n,c=i)}e[t-1][1]!==o&&(o?e[t-1][1]=o:(e.splice(t-1,1),t--),e[t][1]=l,c?e[t+1][1]=c:(e.splice(t+1,1),t--))}t++}}function pr(e){e.push(new N(P,""));let t=0,r=0,n=0,i="",u="",o;for(;t<e.length;)switch(e[t][0]){case L:n++,u+=e[t][1],t++;break;case R:r++,i+=e[t][1],t++;break;case P:r+n>1?(r!==0&&n!==0&&(o=Li(u,i),o!==0&&(t-r-n>0&&e[t-r-n-1][0]===P?e[t-r-n-1][1]+=u.substring(0,o):(e.splice(0,0,new N(P,u.substring(0,o))),t++),u=u.substring(o),i=i.substring(o)),o=gr(u,i),o!==0&&(e[t][1]=u.substring(u.length-o)+e[t][1],u=u.substring(0,u.length-o),i=i.substring(0,i.length-o))),t-=r+n,e.splice(t,r+n),i.length&&(e.splice(t,0,new N(R,i)),t++),u.length&&(e.splice(t,0,new N(L,u)),t++),t++):t!==0&&e[t-1][0]===P?(e[t-1][1]+=e[t][1],e.splice(t,1)):t++,n=0,r=0,i="",u="";break}e[e.length-1][1]===""&&e.pop();let l=!1;for(t=1;t<e.length-1;)e[t-1][0]===P&&e[t+1][0]===P&&(e[t][1].substring(e[t][1].length-e[t-1][1].length)===e[t-1][1]?(e[t][1]=e[t-1][1]+e[t][1].substring(0,e[t][1].length-e[t-1][1].length),e[t+1][1]=e[t-1][1]+e[t+1][1],e.splice(t-1,1),l=!0):e[t][1].substring(0,e[t+1][1].length)===e[t+1][1]&&(e[t-1][1]+=e[t+1][1],e[t][1]=e[t][1].substring(e[t+1][1].length)+e[t+1][1],e.splice(t+1,1),l=!0)),t++;l&&pr(e)}function he(e,t){if(!e||!t)return 6;let r=e.charAt(e.length-1),n=t.charAt(0),i=r.match(At),u=n.match(At),o=i&&r.match(Tt),l=u&&n.match(Tt),c=o&&r.match(Mt),f=l&&n.match(Mt),p=c&&e.match(Fi),h=f&&t.match(Ii);return p||h?5:c||f?4:i&&!o&&l?3:o||l?2:i||u?1:0}var hr="Compared values have no visual difference.",ji="Compared values serialize to the same structure.\nPrinting internal object structure without calling `toJSON` instead.",ye={},Nt;function Bi(){if(Nt)return ye;Nt=1,Object.defineProperty(ye,"__esModule",{value:!0}),ye.default=_;let e="diff-sequences",t=0,r=(g,m,s,a,b)=>{let S=0;for(;g<m&&s<a&&b(g,s);)g+=1,s+=1,S+=1;return S},n=(g,m,s,a,b)=>{let S=0;for(;g<=m&&s<=a&&b(m,a);)m-=1,a-=1,S+=1;return S},i=(g,m,s,a,b,S,C)=>{let y=0,E=-g,O=S[y],$=O;S[y]+=r(O+1,m,a+O-E+1,s,b);let M=g<C?g:C;for(y+=1,E+=2;y<=M;y+=1,E+=2){if(y!==g&&$<S[y])O=S[y];else if(O=$+1,m<=O)return y-1;$=S[y],S[y]=O+r(O+1,m,a+O-E+1,s,b)}return C},u=(g,m,s,a,b,S,C)=>{let y=0,E=g,O=S[y],$=O;S[y]-=n(m,O-1,s,a+O-E-1,b);let M=g<C?g:C;for(y+=1,E-=2;y<=M;y+=1,E-=2){if(y!==g&&S[y]<$)O=S[y];else if(O=$-1,O<m)return y-1;$=S[y],S[y]=O-n(m,O-1,s,a+O-E-1,b)}return C},o=(g,m,s,a,b,S,C,y,E,O,$)=>{let M=a-m,J=s-m,I=b-a-J,F=-I-(g-1),j=-I+(g-1),B=t,K=g<y?g:y;for(let w=0,d=-g;w<=K;w+=1,d+=2){let G=w===0||w!==g&&B<C[w],D=G?C[w]:B,z=G?D:D+1,H=M+z-d,k=r(z+1,s,H+1,b,S),U=z+k;if(B=C[w],C[w]=U,F<=d&&d<=j){let re=(g-1-(d+I))/2;if(re<=O&&E[re]-1<=U){let Q=M+D-(G?d+1:d-1),x=n(m,D,a,Q,S),q=D-x,ue=Q-x,oe=q+1,we=ue+1;$.nChangePreceding=g-1,g-1===oe+we-m-a?($.aEndPreceding=m,$.bEndPreceding=a):($.aEndPreceding=oe,$.bEndPreceding=we),$.nCommonPreceding=x,x!==0&&($.aCommonPreceding=oe,$.bCommonPreceding=we),$.nCommonFollowing=k,k!==0&&($.aCommonFollowing=z+1,$.bCommonFollowing=H+1);let Xe=U+1,Ze=H+k+1;return $.nChangeFollowing=g-1,g-1===s+b-Xe-Ze?($.aStartFollowing=s,$.bStartFollowing=b):($.aStartFollowing=Xe,$.bStartFollowing=Ze),!0}}}return!1},l=(g,m,s,a,b,S,C,y,E,O,$)=>{let M=b-s,J=s-m,I=b-a-J,F=I-g,j=I+g,B=t,K=g<O?g:O;for(let w=0,d=g;w<=K;w+=1,d-=2){let G=w===0||w!==g&&E[w]<B,D=G?E[w]:B,z=G?D:D-1,H=M+z-d,k=n(m,z-1,a,H-1,S),U=z-k;if(B=E[w],E[w]=U,F<=d&&d<=j){let re=(g+(d-I))/2;if(re<=y&&U-1<=C[re]){let Q=H-k;if($.nChangePreceding=g,g===U+Q-m-a?($.aEndPreceding=m,$.bEndPreceding=a):($.aEndPreceding=U,$.bEndPreceding=Q),$.nCommonPreceding=k,k!==0&&($.aCommonPreceding=U,$.bCommonPreceding=Q),$.nChangeFollowing=g-1,g===1)$.nCommonFollowing=0,$.aStartFollowing=s,$.bStartFollowing=b;else{let x=M+D-(G?d-1:d+1),q=r(D,s,x,b,S);$.nCommonFollowing=q,q!==0&&($.aCommonFollowing=D,$.bCommonFollowing=x);let ue=D+q,oe=x+q;g-1===s+b-ue-oe?($.aStartFollowing=s,$.bStartFollowing=b):($.aStartFollowing=ue,$.bStartFollowing=oe)}return!0}}}return!1},c=(g,m,s,a,b,S,C,y,E)=>{let O=a-m,$=b-s,M=s-m,J=b-a,I=J-M,F=M,j=M;if(C[0]=m-1,y[0]=s,I%2===0){let B=(g||I)/2,K=(M+J)/2;for(let w=1;w<=K;w+=1)if(F=i(w,s,b,O,S,C,F),w<B)j=u(w,m,a,$,S,y,j);else if(l(w,m,s,a,b,S,C,F,y,j,E))return}else{let B=((g||I)+1)/2,K=(M+J+1)/2,w=1;for(F=i(w,s,b,O,S,C,F),w+=1;w<=K;w+=1)if(j=u(w-1,m,a,$,S,y,j),w<B)F=i(w,s,b,O,S,C,F);else if(o(w,m,s,a,b,S,C,F,y,j,E))return}throw new Error(`${e}: no overlap aStart=${m} aEnd=${s} bStart=${a} bEnd=${b}`)},f=(g,m,s,a,b,S,C,y,E,O)=>{if(b-a<s-m){if(S=!S,S&&C.length===1){let{foundSubsequence:re,isCommon:Q}=C[0];C[1]={foundSubsequence:(x,q,ue)=>{re(x,ue,q)},isCommon:(x,q)=>Q(q,x)}}let k=m,U=s;m=a,s=b,a=k,b=U}let{foundSubsequence:$,isCommon:M}=C[S?1:0];c(g,m,s,a,b,M,y,E,O);let{nChangePreceding:J,aEndPreceding:I,bEndPreceding:F,nCommonPreceding:j,aCommonPreceding:B,bCommonPreceding:K,nCommonFollowing:w,aCommonFollowing:d,bCommonFollowing:G,nChangeFollowing:D,aStartFollowing:z,bStartFollowing:H}=O;m<I&&a<F&&f(J,m,I,a,F,S,C,y,E,O),j!==0&&$(j,B,K),w!==0&&$(w,d,G),z<s&&H<b&&f(D,z,s,H,b,S,C,y,E,O)},p=(g,m)=>{if(typeof m!="number")throw new TypeError(`${e}: ${g} typeof ${typeof m} is not a number`);if(!Number.isSafeInteger(m))throw new RangeError(`${e}: ${g} value ${m} is not a safe integer`);if(m<0)throw new RangeError(`${e}: ${g} value ${m} is a negative integer`)},h=(g,m)=>{let s=typeof m;if(s!=="function")throw new TypeError(`${e}: ${g} typeof ${s} is not a function`)};function _(g,m,s,a){p("aLength",g),p("bLength",m),h("isCommon",s),h("foundSubsequence",a);let b=r(0,g,0,m,s);if(b!==0&&a(b,0,0),g!==b||m!==b){let S=b,C=b,y=n(S,g-1,C,m-1,s),E=g-y,O=m-y,$=b+y;g!==$&&m!==$&&f(0,S,E,C,O,!1,[{foundSubsequence:a,isCommon:s}],[t],[t],{aCommonFollowing:t,aCommonPreceding:t,aEndPreceding:t,aStartFollowing:t,bCommonFollowing:t,bCommonPreceding:t,bEndPreceding:t,bStartFollowing:t,nChangeFollowing:t,nChangePreceding:t,nCommonFollowing:t,nCommonPreceding:t}),y!==0&&a(y,E,O)}}return ye}var xi=Bi(),yr=Ni(xi);function zi(e,t){return e.replace(/\s+$/,r=>t(r))}function Ge(e,t,r,n,i,u){return e.length!==0?r(`${n} ${zi(e,i)}`):n!==" "?r(n):t&&u.length!==0?r(`${n} ${u}`):""}function br(e,t,{aColor:r,aIndicator:n,changeLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function $r(e,t,{bColor:r,bIndicator:n,changeLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function Sr(e,t,{commonColor:r,commonIndicator:n,commonLineTrailingSpaceColor:i,emptyFirstOrLastLinePlaceholder:u}){return Ge(e,t,r,n,i,u)}function Pt(e,t,r,n,{patchColor:i}){return i(`@@ -${e+1},${t-e} +${r+1},${n-r} @@`)}function ki(e,t){let r=e.length,n=t.contextLines,i=n+n,u=r,o=!1,l=0,c=0;for(;c!==r;){let y=c;for(;c!==r&&e[c][0]===P;)c+=1;if(y!==c)if(y===0)c>n&&(u-=c-n,o=!0);else if(c===r){let E=c-y;E>n&&(u-=E-n,o=!0)}else{let E=c-y;E>i&&(u-=E-i,l+=1)}for(;c!==r&&e[c][0]!==P;)c+=1}let f=l!==0||o;l!==0?u+=l+1:o&&(u+=1);let p=u-1,h=[],_=0;f&&h.push("");let g=0,m=0,s=0,a=0,b=y=>{let E=h.length;h.push(Sr(y,E===0||E===p,t)),s+=1,a+=1},S=y=>{let E=h.length;h.push(br(y,E===0||E===p,t)),s+=1},C=y=>{let E=h.length;h.push($r(y,E===0||E===p,t)),a+=1};for(c=0;c!==r;){let y=c;for(;c!==r&&e[c][0]===P;)c+=1;if(y!==c)if(y===0){c>n&&(y=c-n,g=y,m=y,s=g,a=m);for(let E=y;E!==c;E+=1)b(e[E][1])}else if(c===r){let E=c-y>n?y+n:c;for(let O=y;O!==E;O+=1)b(e[O][1])}else{let E=c-y;if(E>i){let O=y+n;for(let M=y;M!==O;M+=1)b(e[M][1]);h[_]=Pt(g,s,m,a,t),_=h.length,h.push("");let $=E-i;g=s+$,m=a+$,s=g,a=m;for(let M=c-n;M!==c;M+=1)b(e[M][1])}else for(let O=y;O!==c;O+=1)b(e[O][1])}for(;c!==r&&e[c][0]===R;)S(e[c][1]),c+=1;for(;c!==r&&e[c][0]===L;)C(e[c][1]),c+=1}return f&&(h[_]=Pt(g,s,m,a,t)),h.join(`
|
|
7
|
+
`)}function Ui(e,t){return e.map((r,n,i)=>{let u=r[1],o=n===0||n===i.length-1;switch(r[0]){case R:return br(u,o,t);case L:return $r(u,o,t);default:return Sr(u,o,t)}}).join(`
|
|
8
|
+
`)}var Le=e=>e,Er=5,Wi=0;function Yi(){return{aAnnotation:"Expected",aColor:Z.green,aIndicator:"-",bAnnotation:"Received",bColor:Z.red,bIndicator:"+",changeColor:Z.inverse,changeLineTrailingSpaceColor:Le,commonColor:Z.dim,commonIndicator:" ",commonLineTrailingSpaceColor:Le,compareKeys:void 0,contextLines:Er,emptyFirstOrLastLinePlaceholder:"",expand:!1,includeChangeCounts:!1,omitAnnotationLines:!1,patchColor:Z.yellow,printBasicPrototype:!1,truncateThreshold:Wi,truncateAnnotation:"... Diff result is truncated",truncateAnnotationColor:Le}}function qi(e){return e&&typeof e=="function"?e:void 0}function Vi(e){return typeof e=="number"&&Number.isSafeInteger(e)&&e>=0?e:Er}function ie(e={}){return{...Yi(),...e,compareKeys:qi(e.compareKeys),contextLines:Vi(e.contextLines)}}function le(e){return e.length===1&&e[0].length===0}function Ji(e){let t=0,r=0;return e.forEach(n=>{switch(n[0]){case R:t+=1;break;case L:r+=1;break}}),{a:t,b:r}}function Ki({aAnnotation:e,aColor:t,aIndicator:r,bAnnotation:n,bColor:i,bIndicator:u,includeChangeCounts:o,omitAnnotationLines:l},c){if(l)return"";let f="",p="";if(o){let g=String(c.a),m=String(c.b),s=n.length-e.length,a=" ".repeat(Math.max(0,s)),b=" ".repeat(Math.max(0,-s)),S=m.length-g.length,C=" ".repeat(Math.max(0,S)),y=" ".repeat(Math.max(0,-S));f=`${a} ${r} ${C}${g}`,p=`${b} ${u} ${y}${m}`}let h=`${r} ${e}${f}`,_=`${u} ${n}${p}`;return`${t(h)}
|
|
9
9
|
${i(_)}
|
|
10
10
|
|
|
11
11
|
`}function He(e,t,r){return Ki(r,Ji(e))+(r.expand?Ui(e,r):ki(e,r))+(t?r.truncateAnnotationColor(`
|
|
12
|
-
${r.truncateAnnotation}`):"")}function
|
|
12
|
+
${r.truncateAnnotation}`):"")}function Ce(e,t,r){let n=ie(r),[i,u]=_r(le(e)?[]:e,le(t)?[]:t,n);return He(i,u,n)}function Gi(e,t,r,n,i){if(le(e)&&le(r)&&(e=[],r=[]),le(t)&&le(n)&&(t=[],n=[]),e.length!==r.length||t.length!==n.length)return Ce(e,t,i);let[u,o]=_r(r,n,i),l=0,c=0;return u.forEach(f=>{switch(f[0]){case R:f[1]=e[l],l+=1;break;case L:f[1]=t[c],c+=1;break;default:f[1]=t[c],l+=1,c+=1}}),He(u,o,ie(i))}function _r(e,t,r){let n=r?.truncateThreshold??!1,i=Math.max(Math.floor(r?.truncateThreshold??0),0),u=n?Math.min(e.length,i):e.length,o=n?Math.min(t.length,i):t.length,l=u!==e.length||o!==t.length,c=(_,g)=>e[_]===t[g],f=[],p=0,h=0;for(yr(u,o,c,(_,g,m)=>{for(;p!==g;p+=1)f.push(new N(R,e[p]));for(;h!==m;h+=1)f.push(new N(L,t[h]));for(;_!==0;_-=1,p+=1,h+=1)f.push(new N(P,t[h]))});p!==u;p+=1)f.push(new N(R,e[p]));for(;h!==o;h+=1)f.push(new N(L,t[h]));return[f,l]}function dt(e){if(e===void 0)return"undefined";if(e===null)return"null";if(Array.isArray(e))return"array";if(typeof e=="boolean")return"boolean";if(typeof e=="function")return"function";if(typeof e=="number")return"number";if(typeof e=="string")return"string";if(typeof e=="bigint")return"bigint";if(typeof e=="object"){if(e!=null){if(e.constructor===RegExp)return"regexp";if(e.constructor===Map)return"map";if(e.constructor===Set)return"set";if(e.constructor===Date)return"date"}return"object"}else if(typeof e=="symbol")return"symbol";throw new Error(`value of unknown type: ${e}`)}function Lt(e){return e.includes(`\r
|
|
13
13
|
`)?`\r
|
|
14
14
|
`:`
|
|
15
15
|
`}function Hi(e,t,r){let n=r?.truncateThreshold??!1,i=Math.max(Math.floor(r?.truncateThreshold??0),0),u=e.length,o=t.length;if(n){let _=e.includes(`
|
|
16
16
|
`),g=t.includes(`
|
|
17
17
|
`),m=Lt(e),s=Lt(t),a=_?`${e.split(m,i).join(m)}
|
|
18
18
|
`:e,b=g?`${t.split(s,i).join(s)}
|
|
19
|
-
`:t;u=a.length,o=b.length}let l=u!==e.length||o!==t.length,c=(_,g)=>e[_]===t[g],f=0,p=0,h=[];return
|
|
19
|
+
`:t;u=a.length,o=b.length}let l=u!==e.length||o!==t.length,c=(_,g)=>e[_]===t[g],f=0,p=0,h=[];return yr(u,o,c,(_,g,m)=>{f!==g&&h.push(new N(R,e.slice(f,g))),p!==m&&h.push(new N(L,t.slice(p,m))),f=g+_,p=m+_,h.push(new N(P,t.slice(m,p)))}),f!==u&&h.push(new N(R,e.slice(f))),p!==o&&h.push(new N(L,t.slice(p))),[h,l]}function Xi(e,t,r){return t.reduce((n,i)=>n+(i[0]===P?i[1]:i[0]===e&&i[1].length!==0?r(i[1]):""),"")}var Rt=class{op;line;lines;changeColor;constructor(e,t){this.op=e,this.line=[],this.lines=[],this.changeColor=t}pushSubstring(e){this.pushDiff(new N(this.op,e))}pushLine(){this.lines.push(this.line.length!==1?new N(this.op,Xi(this.op,this.line,this.changeColor)):this.line[0][0]===this.op?this.line[0]:new N(this.op,this.line[0][1])),this.line.length=0}isLineEmpty(){return this.line.length===0}pushDiff(e){this.line.push(e)}align(e){let t=e[1];if(t.includes(`
|
|
20
20
|
`)){let r=t.split(`
|
|
21
21
|
`),n=r.length-1;r.forEach((i,u)=>{u<n?(this.pushSubstring(i),this.pushLine()):i.length!==0&&this.pushSubstring(i)})}else this.pushDiff(e)}moveLinesTo(e){this.isLineEmpty()||this.pushLine(),e.push(...this.lines),this.lines.length=0}},Zi=class{deleteBuffer;insertBuffer;lines;constructor(e,t){this.deleteBuffer=e,this.insertBuffer=t,this.lines=[]}pushDiffCommonLine(e){this.lines.push(e)}pushDiffChangeLines(e){let t=e[1].length===0;(!t||this.deleteBuffer.isLineEmpty())&&this.deleteBuffer.pushDiff(e),(!t||this.insertBuffer.isLineEmpty())&&this.insertBuffer.pushDiff(e)}flushChangeLines(){this.deleteBuffer.moveLinesTo(this.lines),this.insertBuffer.moveLinesTo(this.lines)}align(e){let t=e[0],r=e[1];if(r.includes(`
|
|
22
22
|
`)){let n=r.split(`
|
|
23
23
|
`),i=n.length-1;n.forEach((u,o)=>{if(o===0){let l=new N(t,u);this.deleteBuffer.isLineEmpty()&&this.insertBuffer.isLineEmpty()?(this.flushChangeLines(),this.pushDiffCommonLine(l)):(this.pushDiffChangeLines(l),this.flushChangeLines())}else o<i?this.pushDiffCommonLine(new N(t,u)):u.length!==0&&this.pushDiffChangeLines(new N(t,u))})}else this.pushDiffChangeLines(e)}getLines(){return this.flushChangeLines(),this.lines}};function Qi(e,t){let r=new Rt(R,t),n=new Rt(L,t),i=new Zi(r,n);return e.forEach(u=>{switch(u[0]){case R:r.align(u);break;case L:n.align(u);break;default:i.align(u)}}),i.getLines()}function vi(e,t){if(t){let r=e.length-1;return e.some((n,i)=>n[0]===P&&(i!==r||n[1]!==`
|
|
24
24
|
`))}return e.some(r=>r[0]===P)}function eu(e,t,r){if(e!==t&&e.length!==0&&t.length!==0){let n=e.includes(`
|
|
25
25
|
`)||t.includes(`
|
|
26
|
-
`),[i,u]=
|
|
26
|
+
`),[i,u]=Or(n?`${e}
|
|
27
27
|
`:e,n?`${t}
|
|
28
|
-
`:t,!0,r);if(vi(i,n)){let o=ie(r),l=Qi(i,o.changeColor);return He(l,u,o)}}return
|
|
28
|
+
`:t,!0,r);if(vi(i,n)){let o=ie(r),l=Qi(i,o.changeColor);return He(l,u,o)}}return Ce(e.split(`
|
|
29
29
|
`),t.split(`
|
|
30
|
-
`),r)}function
|
|
30
|
+
`),r)}function Or(e,t,r,n){let[i,u]=Hi(e,t,n);return Ri(i),[i,u]}function Be(e,t){let{commonColor:r}=ie(t);return r(e)}var{AsymmetricMatcher:tu,DOMCollection:ru,DOMElement:nu,Immutable:iu,ReactElement:uu,ReactTestComponent:ou}=Ke,Cr=[ou,uu,nu,ru,iu,tu,Ke.Error],xe={maxDepth:20,plugins:Cr},wr={callToJSON:!1,maxDepth:8,plugins:Cr};function lu(e,t,r){if(Object.is(e,t))return"";let n=dt(e),i=n,u=!1;if(n==="object"&&typeof e.asymmetricMatch=="function"){if(e.$$typeof!==Symbol.for("jest.asymmetricMatcher")||typeof e.getExpectedType!="function")return;i=e.getExpectedType(),u=i==="string"}if(i!==dt(t)){let o=function(C){return C.length<=a?C:`${C.slice(0,a)}...`},{aAnnotation:l,aColor:c,aIndicator:f,bAnnotation:p,bColor:h,bIndicator:_}=ie(r),g=ze(wr,r),m=V(e,g),s=V(t,g),a=1e5;m=o(m),s=o(s);let b=`${c(`${f} ${l}:`)}
|
|
31
31
|
${m}`,S=`${h(`${_} ${p}:`)}
|
|
32
32
|
${s}`;return`${b}
|
|
33
33
|
|
|
34
|
-
${S}`}if(!u)switch(n){case"string":return
|
|
34
|
+
${S}`}if(!u)switch(n){case"string":return Ce(e.split(`
|
|
35
35
|
`),t.split(`
|
|
36
|
-
`),r);case"boolean":case"number":return cu(e,t,r);case"map":return
|
|
36
|
+
`),r);case"boolean":case"number":return cu(e,t,r);case"map":return Re(Ft(e),Ft(t),r);case"set":return Re(It(e),It(t),r);default:return Re(e,t,r)}}function cu(e,t,r){let n=V(e,xe),i=V(t,xe);return n===i?"":Ce(n.split(`
|
|
37
37
|
`),i.split(`
|
|
38
|
-
`),r)}function Ft(e){return new Map(Array.from(e.entries()).sort())}function It(e){return new Set(Array.from(e.values()).sort())}function
|
|
38
|
+
`),r)}function Ft(e){return new Map(Array.from(e.entries()).sort())}function It(e){return new Set(Array.from(e.values()).sort())}function Re(e,t,r){let n,i=!1;try{let o=ze(xe,r);n=Dt(e,t,o,r)}catch{i=!0}let u=Be(hr,r);if(n===void 0||n===u){let o=ze(wr,r);n=Dt(e,t,o,r),n!==u&&!i&&(n=`${Be(ji,r)}
|
|
39
39
|
|
|
40
|
-
${n}`)}return n}function ze(e,t){let{compareKeys:r,printBasicPrototype:n,maxDepth:i}=ie(t);return{...e,compareKeys:r,printBasicPrototype:n,maxDepth:i??e.maxDepth}}function Dt(e,t,r,n){let i={...r,indent:0},u=V(e,i),o=V(t,i);if(u===o)return Be(
|
|
40
|
+
${n}`)}return n}function ze(e,t){let{compareKeys:r,printBasicPrototype:n,maxDepth:i}=ie(t);return{...e,compareKeys:r,printBasicPrototype:n,maxDepth:i??e.maxDepth}}function Dt(e,t,r,n){let i={...r,indent:0},u=V(e,i),o=V(t,i);if(u===o)return Be(hr,n);{let l=V(e,r),c=V(t,r);return Gi(l.split(`
|
|
41
41
|
`),c.split(`
|
|
42
42
|
`),u.split(`
|
|
43
43
|
`),o.split(`
|
|
44
44
|
`),n)}}var jt=2e4;function Bt(e){return De(e)==="Object"&&typeof e.asymmetricMatch=="function"}function xt(e,t){let r=De(e),n=De(t);return r===n&&(r==="Object"||r==="Array")}function su(e,t,r){let{aAnnotation:n,bAnnotation:i}=ie(r);if(typeof t=="string"&&typeof e=="string"&&t.length>0&&e.length>0&&t.length<=jt&&e.length<=jt&&t!==e){if(t.includes(`
|
|
45
45
|
`)||e.includes(`
|
|
46
|
-
`))return eu(t,e,r);let[f]=
|
|
47
|
-
${g}`}let u=Ct(t,{forceWritable:!0}),o=Ct(e,{forceWritable:!0}),{replacedExpected:l,replacedActual:c}=
|
|
48
|
-
Inner error message: ${n?.message}`))}}export{Eu as assertTypes,lu as diff,Ni as getDefaultExportFromCjs,De as getType,_u as isObject,Ou as noop,su as printDiffOrStringify,Su as processError,
|
|
46
|
+
`))return eu(t,e,r);let[f]=Or(t,e),p=f.some(m=>m[0]===P),h=au(n,i),_=h(n)+gu(zt(f,R,p)),g=h(i)+mu(zt(f,L,p));return`${_}
|
|
47
|
+
${g}`}let u=Ct(t,{forceWritable:!0}),o=Ct(e,{forceWritable:!0}),{replacedExpected:l,replacedActual:c}=Ar(o,u);return lu(l,c,r)}function Ar(e,t,r=new WeakSet,n=new WeakSet){return e instanceof Error&&t instanceof Error&&typeof e.cause<"u"&&typeof t.cause>"u"?(delete e.cause,{replacedActual:e,replacedExpected:t}):xt(e,t)?r.has(e)||n.has(t)?{replacedActual:e,replacedExpected:t}:(r.add(e),n.add(t),fr(t).forEach(i=>{let u=t[i],o=e[i];if(Bt(u))u.asymmetricMatch(o)&&(e[i]=u);else if(Bt(o))o.asymmetricMatch(u)&&(t[i]=o);else if(xt(o,u)){let l=Ar(o,u,r,n);e[i]=l.replacedActual,t[i]=l.replacedExpected}}),{replacedActual:e,replacedExpected:t}):{replacedActual:e,replacedExpected:t}}function au(...e){let t=e.reduce((r,n)=>n.length>r?n.length:r,0);return r=>`${r}: ${" ".repeat(t-r.length)}`}var fu="·";function Tr(e){return e.replace(/\s+$/gm,t=>fu.repeat(t.length))}function mu(e){return Z.red(Tr(ge(e)))}function gu(e){return Z.green(Tr(ge(e)))}function zt(e,t,r){return e.reduce((n,i)=>n+(i[0]===P?i[1]:i[0]===t?r?Z.inverse(i[1]):i[1]:""),"")}var pu="@@__IMMUTABLE_RECORD__@@",hu="@@__IMMUTABLE_ITERABLE__@@";function yu(e){return e&&(e[hu]||e[pu])}var bu=Object.getPrototypeOf({});function kt(e){return e instanceof Error?`<unserializable>: ${e.message}`:typeof e=="string"?`<unserializable>: ${e}`:"<unserializable>"}function ee(e,t=new WeakMap){if(!e||typeof e=="string")return e;if(e instanceof Error&&"toJSON"in e&&typeof e.toJSON=="function"){let r=e.toJSON();return r&&r!==e&&typeof r=="object"&&(typeof e.message=="string"&&be(()=>r.message??(r.message=e.message)),typeof e.stack=="string"&&be(()=>r.stack??(r.stack=e.stack)),typeof e.name=="string"&&be(()=>r.name??(r.name=e.name)),e.cause!=null&&be(()=>r.cause??(r.cause=ee(e.cause,t)))),ee(r,t)}if(typeof e=="function")return`Function<${e.name||"anonymous"}>`;if(typeof e=="symbol")return e.toString();if(typeof e!="object")return e;if(typeof Buffer<"u"&&e instanceof Buffer)return`<Buffer(${e.length}) ...>`;if(typeof Uint8Array<"u"&&e instanceof Uint8Array)return`<Uint8Array(${e.length}) ...>`;if(yu(e))return ee(e.toJSON(),t);if(e instanceof Promise||e.constructor&&e.constructor.prototype==="AsyncFunction")return"Promise";if(typeof Element<"u"&&e instanceof Element)return e.tagName;if(typeof e.asymmetricMatch=="function")return`${e.toString()} ${Mi(e.sample)}`;if(typeof e.toJSON=="function")return ee(e.toJSON(),t);if(t.has(e))return t.get(e);if(Array.isArray(e)){let r=new Array(e.length);return t.set(e,r),e.forEach((n,i)=>{try{r[i]=ee(n,t)}catch(u){r[i]=kt(u)}}),r}else{let r=Object.create(null);t.set(e,r);let n=e;for(;n&&n!==bu;)Object.getOwnPropertyNames(n).forEach(i=>{if(!(i in r))try{r[i]=ee(e[i],t)}catch(u){delete r[i],r[i]=kt(u)}}),n=Object.getPrototypeOf(n);return r}}function be(e){try{return e()}catch{}}function $u(e){return e.replace(/__(vite_ssr_import|vi_import)_\d+__\./g,"")}function Su(e,t,r=new WeakSet){if(!e||typeof e!="object")return{message:String(e)};let n=e;(n.showDiff||n.showDiff===void 0&&n.expected!==void 0&&n.actual!==void 0)&&(n.diff=su(n.actual,n.expected,{...t,...n.diffOptions})),"expected"in n&&typeof n.expected!="string"&&(n.expected=ge(n.expected,10)),"actual"in n&&typeof n.actual!="string"&&(n.actual=ge(n.actual,10));try{typeof n.message=="string"&&(n.message=$u(n.message))}catch{}try{!r.has(n)&&typeof n.cause=="object"&&(r.add(n),n.cause=Su(n.cause,t,r))}catch{}try{return ee(n)}catch(i){return ee(new Error(`Failed to fully serialize error: ${i?.message}
|
|
48
|
+
Inner error message: ${n?.message}`))}}export{Eu as assertTypes,lu as diff,Ni as getDefaultExportFromCjs,De as getType,_u as isObject,Ou as noop,su as printDiffOrStringify,Su as processError,ge as stringify};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{__commonJS as y}from"./chunk-A242L54C.js";var w=y({"../../node_modules/color-name/index.js"(p,g){g.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}}}),v=y({"../../node_modules/color-convert/conversions.js"(p,g){var h=w(),f={};for(let n of Object.keys(h))f[h[n]]=n;var o={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};g.exports=o;for(let n of Object.keys(o)){if(!("channels"in o[n]))throw new Error("missing channels property: "+n);if(!("labels"in o[n]))throw new Error("missing channel labels property: "+n);if(o[n].labels.length!==o[n].channels)throw new Error("channel and label counts mismatch: "+n);let{channels:l,labels:e}=o[n];delete o[n].channels,delete o[n].labels,Object.defineProperty(o[n],"channels",{value:l}),Object.defineProperty(o[n],"labels",{value:e})}o.rgb.hsl=function(n){let l=n[0]/255,e=n[1]/255,r=n[2]/255,t=Math.min(l,e,r),a=Math.max(l,e,r),i=a-t,u,s;a===t?u=0:l===a?u=(e-r)/i:e===a?u=2+(r-l)/i:r===a&&(u=4+(l-e)/i),u=Math.min(u*60,360),u<0&&(u+=360);let c=(t+a)/2;return a===t?s=0:c<=.5?s=i/(a+t):s=i/(2-a-t),[u,s*100,c*100]},o.rgb.hsv=function(n){let l,e,r,t,a,i=n[0]/255,u=n[1]/255,s=n[2]/255,c=Math.max(i,u,s),b=c-Math.min(i,u,s),d=function(k){return(c-k)/6/b+1/2};return b===0?(t=0,a=0):(a=b/c,l=d(i),e=d(u),r=d(s),i===c?t=r-e:u===c?t=1/3+l-r:s===c&&(t=2/3+e-l),t<0?t+=1:t>1&&(t-=1)),[t*360,a*100,c*100]},o.rgb.hwb=function(n){let l=n[0],e=n[1],r=n[2],t=o.rgb.hsl(n)[0],a=1/255*Math.min(l,Math.min(e,r));return r=1-1/255*Math.max(l,Math.max(e,r)),[t,a*100,r*100]},o.rgb.cmyk=function(n){let l=n[0]/255,e=n[1]/255,r=n[2]/255,t=Math.min(1-l,1-e,1-r),a=(1-l-t)/(1-t)||0,i=(1-e-t)/(1-t)||0,u=(1-r-t)/(1-t)||0;return[a*100,i*100,u*100,t*100]};function m(n,l){return(n[0]-l[0])**2+(n[1]-l[1])**2+(n[2]-l[2])**2}o.rgb.keyword=function(n){let l=f[n];if(l)return l;let e=1/0,r;for(let t of Object.keys(h)){let a=h[t],i=m(n,a);i<e&&(e=i,r=t)}return r},o.keyword.rgb=function(n){return h[n]},o.rgb.xyz=function(n){let l=n[0]/255,e=n[1]/255,r=n[2]/255;l=l>.04045?((l+.055)/1.055)**2.4:l/12.92,e=e>.04045?((e+.055)/1.055)**2.4:e/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;let t=l*.4124+e*.3576+r*.1805,a=l*.2126+e*.7152+r*.0722,i=l*.0193+e*.1192+r*.9505;return[t*100,a*100,i*100]},o.rgb.lab=function(n){let l=o.rgb.xyz(n),e=l[0],r=l[1],t=l[2];e/=95.047,r/=100,t/=108.883,e=e>.008856?e**(1/3):7.787*e+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,t=t>.008856?t**(1/3):7.787*t+16/116;let a=116*r-16,i=500*(e-r),u=200*(r-t);return[a,i,u]},o.hsl.rgb=function(n){let l=n[0]/360,e=n[1]/100,r=n[2]/100,t,a,i;if(e===0)return i=r*255,[i,i,i];r<.5?t=r*(1+e):t=r+e-r*e;let u=2*r-t,s=[0,0,0];for(let c=0;c<3;c++)a=l+1/3*-(c-1),a<0&&a++,a>1&&a--,6*a<1?i=u+(t-u)*6*a:2*a<1?i=t:3*a<2?i=u+(t-u)*(2/3-a)*6:i=u,s[c]=i*255;return s},o.hsl.hsv=function(n){let l=n[0],e=n[1]/100,r=n[2]/100,t=e,a=Math.max(r,.01);r*=2,e*=r<=1?r:2-r,t*=a<=1?a:2-a;let i=(r+e)/2,u=r===0?2*t/(a+t):2*e/(r+e);return[l,u*100,i*100]},o.hsv.rgb=function(n){let l=n[0]/60,e=n[1]/100,r=n[2]/100,t=Math.floor(l)%6,a=l-Math.floor(l),i=255*r*(1-e),u=255*r*(1-e*a),s=255*r*(1-e*(1-a));switch(r*=255,t){case 0:return[r,s,i];case 1:return[u,r,i];case 2:return[i,r,s];case 3:return[i,u,r];case 4:return[s,i,r];case 5:return[r,i,u]}},o.hsv.hsl=function(n){let l=n[0],e=n[1]/100,r=n[2]/100,t=Math.max(r,.01),a,i;i=(2-e)*r;let u=(2-e)*t;return a=e*t,a/=u<=1?u:2-u,a=a||0,i/=2,[l,a*100,i*100]},o.hwb.rgb=function(n){let l=n[0]/360,e=n[1]/100,r=n[2]/100,t=e+r,a;t>1&&(e/=t,r/=t);let i=Math.floor(6*l),u=1-r;a=6*l-i,(i&1)!==0&&(a=1-a);let s=e+a*(u-e),c,b,d;switch(i){default:case 6:case 0:c=u,b=s,d=e;break;case 1:c=s,b=u,d=e;break;case 2:c=e,b=u,d=s;break;case 3:c=e,b=s,d=u;break;case 4:c=s,b=e,d=u;break;case 5:c=u,b=e,d=s;break}return[c*255,b*255,d*255]},o.cmyk.rgb=function(n){let l=n[0]/100,e=n[1]/100,r=n[2]/100,t=n[3]/100,a=1-Math.min(1,l*(1-t)+t),i=1-Math.min(1,e*(1-t)+t),u=1-Math.min(1,r*(1-t)+t);return[a*255,i*255,u*255]},o.xyz.rgb=function(n){let l=n[0]/100,e=n[1]/100,r=n[2]/100,t,a,i;return t=l*3.2406+e*-1.5372+r*-.4986,a=l*-.9689+e*1.8758+r*.0415,i=l*.0557+e*-.204+r*1.057,t=t>.0031308?1.055*t**(1/2.4)-.055:t*12.92,a=a>.0031308?1.055*a**(1/2.4)-.055:a*12.92,i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92,t=Math.min(Math.max(0,t),1),a=Math.min(Math.max(0,a),1),i=Math.min(Math.max(0,i),1),[t*255,a*255,i*255]},o.xyz.lab=function(n){let l=n[0],e=n[1],r=n[2];l/=95.047,e/=100,r/=108.883,l=l>.008856?l**(1/3):7.787*l+16/116,e=e>.008856?e**(1/3):7.787*e+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;let t=116*e-16,a=500*(l-e),i=200*(e-r);return[t,a,i]},o.lab.xyz=function(n){let l=n[0],e=n[1],r=n[2],t,a,i;a=(l+16)/116,t=e/500+a,i=a-r/200;let u=a**3,s=t**3,c=i**3;return a=u>.008856?u:(a-16/116)/7.787,t=s>.008856?s:(t-16/116)/7.787,i=c>.008856?c:(i-16/116)/7.787,t*=95.047,a*=100,i*=108.883,[t,a,i]},o.lab.lch=function(n){let l=n[0],e=n[1],r=n[2],t;t=Math.atan2(r,e)*360/2/Math.PI,t<0&&(t+=360);let a=Math.sqrt(e*e+r*r);return[l,a,t]},o.lch.lab=function(n){let l=n[0],e=n[1],r=n[2]/360*2*Math.PI,t=e*Math.cos(r),a=e*Math.sin(r);return[l,t,a]},o.rgb.ansi16=function(n,l=null){let[e,r,t]=n,a=l===null?o.rgb.hsv(n)[2]:l;if(a=Math.round(a/50),a===0)return 30;let i=30+(Math.round(t/255)<<2|Math.round(r/255)<<1|Math.round(e/255));return a===2&&(i+=60),i},o.hsv.ansi16=function(n){return o.rgb.ansi16(o.hsv.rgb(n),n[2])},o.rgb.ansi256=function(n){let l=n[0],e=n[1],r=n[2];return l===e&&e===r?l<8?16:l>248?231:Math.round((l-8)/247*24)+232:16+36*Math.round(l/255*5)+6*Math.round(e/255*5)+Math.round(r/255*5)},o.ansi16.rgb=function(n){let l=n%10;if(l===0||l===7)return n>50&&(l+=3.5),l=l/10.5*255,[l,l,l];let e=(~~(n>50)+1)*.5,r=(l&1)*e*255,t=(l>>1&1)*e*255,a=(l>>2&1)*e*255;return[r,t,a]},o.ansi256.rgb=function(n){if(n>=232){let a=(n-232)*10+8;return[a,a,a]}n-=16;let l,e=Math.floor(n/36)/5*255,r=Math.floor((l=n%36)/6)/5*255,t=l%6/5*255;return[e,r,t]},o.rgb.hex=function(n){let l=(((Math.round(n[0])&255)<<16)+((Math.round(n[1])&255)<<8)+(Math.round(n[2])&255)).toString(16).toUpperCase();return"000000".substring(l.length)+l},o.hex.rgb=function(n){let l=n.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!l)return[0,0,0];let e=l[0];l[0].length===3&&(e=e.split("").map(u=>u+u).join(""));let r=parseInt(e,16),t=r>>16&255,a=r>>8&255,i=r&255;return[t,a,i]},o.rgb.hcg=function(n){let l=n[0]/255,e=n[1]/255,r=n[2]/255,t=Math.max(Math.max(l,e),r),a=Math.min(Math.min(l,e),r),i=t-a,u,s;return i<1?u=a/(1-i):u=0,i<=0?s=0:t===l?s=(e-r)/i%6:t===e?s=2+(r-l)/i:s=4+(l-e)/i,s/=6,s%=1,[s*360,i*100,u*100]},o.hsl.hcg=function(n){let l=n[1]/100,e=n[2]/100,r=e<.5?2*l*e:2*l*(1-e),t=0;return r<1&&(t=(e-.5*r)/(1-r)),[n[0],r*100,t*100]},o.hsv.hcg=function(n){let l=n[1]/100,e=n[2]/100,r=l*e,t=0;return r<1&&(t=(e-r)/(1-r)),[n[0],r*100,t*100]},o.hcg.rgb=function(n){let l=n[0]/360,e=n[1]/100,r=n[2]/100;if(e===0)return[r*255,r*255,r*255];let t=[0,0,0],a=l%1*6,i=a%1,u=1-i,s=0;switch(Math.floor(a)){case 0:t[0]=1,t[1]=i,t[2]=0;break;case 1:t[0]=u,t[1]=1,t[2]=0;break;case 2:t[0]=0,t[1]=1,t[2]=i;break;case 3:t[0]=0,t[1]=u,t[2]=1;break;case 4:t[0]=i,t[1]=0,t[2]=1;break;default:t[0]=1,t[1]=0,t[2]=u}return s=(1-e)*r,[(e*t[0]+s)*255,(e*t[1]+s)*255,(e*t[2]+s)*255]},o.hcg.hsv=function(n){let l=n[1]/100,e=n[2]/100,r=l+e*(1-l),t=0;return r>0&&(t=l/r),[n[0],t*100,r*100]},o.hcg.hsl=function(n){let l=n[1]/100,e=n[2]/100*(1-l)+.5*l,r=0;return e>0&&e<.5?r=l/(2*e):e>=.5&&e<1&&(r=l/(2*(1-e))),[n[0],r*100,e*100]},o.hcg.hwb=function(n){let l=n[1]/100,e=n[2]/100,r=l+e*(1-l);return[n[0],(r-l)*100,(1-r)*100]},o.hwb.hcg=function(n){let l=n[1]/100,e=1-n[2]/100,r=e-l,t=0;return r<1&&(t=(e-r)/(1-r)),[n[0],r*100,t*100]},o.apple.rgb=function(n){return[n[0]/65535*255,n[1]/65535*255,n[2]/65535*255]},o.rgb.apple=function(n){return[n[0]/255*65535,n[1]/255*65535,n[2]/255*65535]},o.gray.rgb=function(n){return[n[0]/100*255,n[0]/100*255,n[0]/100*255]},o.gray.hsl=function(n){return[0,0,n[0]]},o.gray.hsv=o.gray.hsl,o.gray.hwb=function(n){return[0,100,n[0]]},o.gray.cmyk=function(n){return[0,0,0,n[0]]},o.gray.lab=function(n){return[n[0],0,0]},o.gray.hex=function(n){let l=Math.round(n[0]/100*255)&255,e=((l<<16)+(l<<8)+l).toString(16).toUpperCase();return"000000".substring(e.length)+e},o.rgb.gray=function(n){return[(n[0]+n[1]+n[2])/3/255*100]}}}),x=y({"../../node_modules/color-convert/route.js"(p,g){var h=v();function f(){let l={},e=Object.keys(h);for(let r=e.length,t=0;t<r;t++)l[e[t]]={distance:-1,parent:null};return l}function o(l){let e=f(),r=[l];for(e[l].distance=0;r.length;){let t=r.pop(),a=Object.keys(h[t]);for(let i=a.length,u=0;u<i;u++){let s=a[u],c=e[s];c.distance===-1&&(c.distance=e[t].distance+1,c.parent=t,r.unshift(s))}}return e}function m(l,e){return function(r){return e(l(r))}}function n(l,e){let r=[e[l].parent,l],t=h[e[l].parent][l],a=e[l].parent;for(;e[a].parent;)r.unshift(e[a].parent),t=m(h[e[a].parent][a],t),a=e[a].parent;return t.conversion=r,t}g.exports=function(l){let e=o(l),r={},t=Object.keys(e);for(let a=t.length,i=0;i<a;i++){let u=t[i];e[u].parent!==null&&(r[u]=n(u,e))}return r}}}),j=y({"../../node_modules/color-convert/index.js"(p,g){var h=v(),f=x(),o={},m=Object.keys(h);function n(e){let r=function(...t){let a=t[0];return a==null?a:(a.length>1&&(t=a),e(t))};return"conversion"in e&&(r.conversion=e.conversion),r}function l(e){let r=function(...t){let a=t[0];if(a==null)return a;a.length>1&&(t=a);let i=e(t);if(typeof i=="object")for(let u=i.length,s=0;s<u;s++)i[s]=Math.round(i[s]);return i};return"conversion"in e&&(r.conversion=e.conversion),r}m.forEach(e=>{o[e]={},Object.defineProperty(o[e],"channels",{value:h[e].channels}),Object.defineProperty(o[e],"labels",{value:h[e].labels});let r=f(e);Object.keys(r).forEach(t=>{let a=r[t];o[e][t]=l(a),o[e][t].raw=n(a)})}),g.exports=o}});export{j as require_color_convert};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var R=(E=>(E.CHANNEL_WS_DISCONNECT="channelWSDisconnect",E.CHANNEL_CREATED="channelCreated",E.CONFIG_ERROR="configError",E.STORY_INDEX_INVALIDATED="storyIndexInvalidated",E.STORY_SPECIFIED="storySpecified",E.SET_CONFIG="setConfig",E.SET_STORIES="setStories",E.SET_INDEX="setIndex",E.SET_CURRENT_STORY="setCurrentStory",E.CURRENT_STORY_WAS_SET="currentStoryWasSet",E.FORCE_RE_RENDER="forceReRender",E.FORCE_REMOUNT="forceRemount",E.PRELOAD_ENTRIES="preloadStories",E.STORY_PREPARED="storyPrepared",E.DOCS_PREPARED="docsPrepared",E.STORY_CHANGED="storyChanged",E.STORY_UNCHANGED="storyUnchanged",E.STORY_RENDERED="storyRendered",E.STORY_FINISHED="storyFinished",E.STORY_MISSING="storyMissing",E.STORY_ERRORED="storyErrored",E.STORY_THREW_EXCEPTION="storyThrewException",E.STORY_RENDER_PHASE_CHANGED="storyRenderPhaseChanged",E.STORY_HOT_UPDATED="storyHotUpdated",E.PLAY_FUNCTION_THREW_EXCEPTION="playFunctionThrewException",E.UNHANDLED_ERRORS_WHILE_PLAYING="unhandledErrorsWhilePlaying",E.UPDATE_STORY_ARGS="updateStoryArgs",E.STORY_ARGS_UPDATED="storyArgsUpdated",E.RESET_STORY_ARGS="resetStoryArgs",E.SET_FILTER="setFilter",E.SET_GLOBALS="setGlobals",E.UPDATE_GLOBALS="updateGlobals",E.GLOBALS_UPDATED="globalsUpdated",E.REGISTER_SUBSCRIPTION="registerSubscription",E.PREVIEW_INITIALIZED="previewInitialized",E.PREVIEW_KEYDOWN="previewKeydown",E.PREVIEW_BUILDER_PROGRESS="preview_builder_progress",E.SELECT_STORY="selectStory",E.STORIES_COLLAPSE_ALL="storiesCollapseAll",E.STORIES_EXPAND_ALL="storiesExpandAll",E.DOCS_RENDERED="docsRendered",E.SHARED_STATE_CHANGED="sharedStateChanged",E.SHARED_STATE_SET="sharedStateSet",E.NAVIGATE_URL="navigateUrl",E.UPDATE_QUERY_PARAMS="updateQueryParams",E.REQUEST_WHATS_NEW_DATA="requestWhatsNewData",E.RESULT_WHATS_NEW_DATA="resultWhatsNewData",E.SET_WHATS_NEW_CACHE="setWhatsNewCache",E.TOGGLE_WHATS_NEW_NOTIFICATIONS="toggleWhatsNewNotifications",E.TELEMETRY_ERROR="telemetryError",E.FILE_COMPONENT_SEARCH_REQUEST="fileComponentSearchRequest",E.FILE_COMPONENT_SEARCH_RESPONSE="fileComponentSearchResponse",E.SAVE_STORY_REQUEST="saveStoryRequest",E.SAVE_STORY_RESPONSE="saveStoryResponse",E.ARGTYPES_INFO_REQUEST="argtypesInfoRequest",E.ARGTYPES_INFO_RESPONSE="argtypesInfoResponse",E.CREATE_NEW_STORYFILE_REQUEST="createNewStoryfileRequest",E.CREATE_NEW_STORYFILE_RESPONSE="createNewStoryfileResponse",E.GHOST_STORIES_REQUEST="ghostStoriesRequest",E.GHOST_STORIES_RESPONSE="ghostStoriesResponse",E.OPEN_IN_EDITOR_REQUEST="openInEditorRequest",E.OPEN_IN_EDITOR_RESPONSE="openInEditorResponse",E.MANAGER_INERT_ATTRIBUTE_CHANGED="managerInertAttributeChanged",E))(R||{}),{CHANNEL_WS_DISCONNECT:S,CHANNEL_CREATED:_,CONFIG_ERROR:T,CREATE_NEW_STORYFILE_REQUEST:O,CREATE_NEW_STORYFILE_RESPONSE:N,CURRENT_STORY_WAS_SET:A,DOCS_PREPARED:I,DOCS_RENDERED:D,FILE_COMPONENT_SEARCH_REQUEST:r,FILE_COMPONENT_SEARCH_RESPONSE:C,FORCE_RE_RENDER:P,FORCE_REMOUNT:o,GLOBALS_UPDATED:L,NAVIGATE_URL:a,PLAY_FUNCTION_THREW_EXCEPTION:Y,UNHANDLED_ERRORS_WHILE_PLAYING:U,PRELOAD_ENTRIES:G,PREVIEW_INITIALIZED:H,PREVIEW_BUILDER_PROGRESS:W,PREVIEW_KEYDOWN:d,REGISTER_SUBSCRIPTION:i,RESET_STORY_ARGS:t,SELECT_STORY:p,SET_CONFIG:F,SET_CURRENT_STORY:l,SET_FILTER:y,SET_GLOBALS:e,SET_INDEX:h,SET_STORIES:c,SHARED_STATE_CHANGED:g,SHARED_STATE_SET:s,STORIES_COLLAPSE_ALL:u,STORIES_EXPAND_ALL:Q,STORY_ARGS_UPDATED:M,STORY_CHANGED:V,STORY_ERRORED:f,STORY_INDEX_INVALIDATED:w,STORY_MISSING:B,STORY_PREPARED:X,STORY_RENDER_PHASE_CHANGED:q,STORY_RENDERED:b,STORY_FINISHED:m,STORY_SPECIFIED:x,STORY_THREW_EXCEPTION:K,STORY_UNCHANGED:Z,STORY_HOT_UPDATED:z,UPDATE_GLOBALS:j,UPDATE_QUERY_PARAMS:k,UPDATE_STORY_ARGS:J,REQUEST_WHATS_NEW_DATA:$,RESULT_WHATS_NEW_DATA:n,SET_WHATS_NEW_CACHE:v,TOGGLE_WHATS_NEW_NOTIFICATIONS:EE,TELEMETRY_ERROR:RE,SAVE_STORY_REQUEST:SE,SAVE_STORY_RESPONSE:_E,ARGTYPES_INFO_REQUEST:TE,ARGTYPES_INFO_RESPONSE:OE,GHOST_STORIES_REQUEST:NE,GHOST_STORIES_RESPONSE:AE,OPEN_IN_EDITOR_REQUEST:IE,OPEN_IN_EDITOR_RESPONSE:DE,MANAGER_INERT_ATTRIBUTE_CHANGED:rE}=R;export{TE as ARGTYPES_INFO_REQUEST,OE as ARGTYPES_INFO_RESPONSE,_ as CHANNEL_CREATED,S as CHANNEL_WS_DISCONNECT,T as CONFIG_ERROR,O as CREATE_NEW_STORYFILE_REQUEST,N as CREATE_NEW_STORYFILE_RESPONSE,A as CURRENT_STORY_WAS_SET,I as DOCS_PREPARED,D as DOCS_RENDERED,r as FILE_COMPONENT_SEARCH_REQUEST,C as FILE_COMPONENT_SEARCH_RESPONSE,o as FORCE_REMOUNT,P as FORCE_RE_RENDER,NE as GHOST_STORIES_REQUEST,AE as GHOST_STORIES_RESPONSE,L as GLOBALS_UPDATED,rE as MANAGER_INERT_ATTRIBUTE_CHANGED,a as NAVIGATE_URL,IE as OPEN_IN_EDITOR_REQUEST,DE as OPEN_IN_EDITOR_RESPONSE,Y as PLAY_FUNCTION_THREW_EXCEPTION,G as PRELOAD_ENTRIES,W as PREVIEW_BUILDER_PROGRESS,H as PREVIEW_INITIALIZED,d as PREVIEW_KEYDOWN,i as REGISTER_SUBSCRIPTION,$ as REQUEST_WHATS_NEW_DATA,t as RESET_STORY_ARGS,n as RESULT_WHATS_NEW_DATA,SE as SAVE_STORY_REQUEST,_E as SAVE_STORY_RESPONSE,p as SELECT_STORY,F as SET_CONFIG,l as SET_CURRENT_STORY,y as SET_FILTER,e as SET_GLOBALS,h as SET_INDEX,c as SET_STORIES,v as SET_WHATS_NEW_CACHE,g as SHARED_STATE_CHANGED,s as SHARED_STATE_SET,u as STORIES_COLLAPSE_ALL,Q as STORIES_EXPAND_ALL,M as STORY_ARGS_UPDATED,V as STORY_CHANGED,f as STORY_ERRORED,m as STORY_FINISHED,z as STORY_HOT_UPDATED,w as STORY_INDEX_INVALIDATED,B as STORY_MISSING,X as STORY_PREPARED,b as STORY_RENDERED,q as STORY_RENDER_PHASE_CHANGED,x as STORY_SPECIFIED,K as STORY_THREW_EXCEPTION,Z as STORY_UNCHANGED,RE as TELEMETRY_ERROR,EE as TOGGLE_WHATS_NEW_NOTIFICATIONS,U as UNHANDLED_ERRORS_WHILE_PLAYING,j as UPDATE_GLOBALS,k as UPDATE_QUERY_PARAMS,J as UPDATE_STORY_ARGS};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{EVENTS as m}from"../_browser-chunks/chunk-ZUWEVLDX.js";import{processError as C}from"../_browser-chunks/chunk-RP5RXKFU.js";import{once as A}from"../client-logger/index.js";import{FORCE_REMOUNT as E,STORY_RENDER_PHASE_CHANGED as P,SET_CURRENT_STORY as D}from"../core-events/index.js";import{global as p}from"../../../../../@storybook_global@5.0.0/node_modules/@storybook/global/dist/index.js";var R=globalThis.__STORYBOOK_ADDONS_PREVIEW,j=new Error("This function ran after the play function completed. Did you forget to `await` it?"),T=s=>Object.prototype.toString.call(s)==="[object Object]",x=s=>Object.prototype.toString.call(s)==="[object Module]",U=s=>{if(!T(s)&&!x(s))return!1;if(s.constructor===void 0)return!0;let a=s.constructor.prototype;return!!T(a)},B=s=>{try{return new s.constructor}catch{return{}}},w=()=>({renderPhase:"preparing",isDebugging:!1,isPlaying:!1,isLocked:!1,cursor:0,calls:[],shadowCalls:[],callRefsByResult:new Map,chainedCallIds:new Set,ancestors:[],playUntil:void 0,resolvers:{},syncTimeout:void 0}),b=(s,a=!1)=>{let e=(a?s.shadowCalls:s.calls).filter(o=>o.retain);if(!e.length)return;let h=new Map(Array.from(s.callRefsByResult.entries()).filter(([,o])=>o.retain));return{cursor:e.length,calls:e,callRefsByResult:h}},L=class{constructor(){this.detached=!1,this.initialized=!1,this.state={},this.loadParentWindowState=()=>{try{this.state=p.window?.parent?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__||{}}catch{this.detached=!0}},this.updateParentWindowState=()=>{try{p.window.parent.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__=this.state}catch{this.detached=!0}},this.loadParentWindowState();let s=({storyId:i,renderPhase:r,isPlaying:n=!0,isDebugging:t=!1})=>{let l=this.getState(i);this.setState(i,{...w(),...b(l,t),renderPhase:r||l.renderPhase,shadowCalls:t?l.shadowCalls:[],chainedCallIds:t?l.chainedCallIds:new Set,playUntil:t?l.playUntil:void 0,isPlaying:n,isDebugging:t}),this.sync(i)},a=i=>({storyId:r,playUntil:n})=>{this.getState(r).isDebugging||this.setState(r,({calls:l})=>({calls:[],shadowCalls:l.map(d=>({...d,status:"waiting"})),isDebugging:!0}));let t=this.getLog(r);this.setState(r,({shadowCalls:l})=>{if(n||!t.length)return{playUntil:n};let d=l.findIndex(f=>f.id===t[0].callId);return{playUntil:l.slice(0,d).filter(f=>f.interceptable&&!f.ancestors?.length).slice(-1)[0]?.id}}),i.emit(E,{storyId:r,isDebugging:!0})},e=i=>({storyId:r})=>{let n=this.getLog(r).filter(l=>!l.ancestors?.length),t=n.reduceRight((l,d,f)=>l>=0||d.status==="waiting"?l:f,-1);a(i)({storyId:r,playUntil:n[t-1]?.callId})},h=i=>({storyId:r,callId:n})=>{let{calls:t,shadowCalls:l,resolvers:d}=this.getState(r),f=t.find(({id:g})=>g===n),_=l.find(({id:g})=>g===n);if(!f&&_&&Object.values(d).length>0){let g=this.getLog(r).find(S=>S.status==="waiting")?.callId;_.id!==g&&this.setState(r,{playUntil:_.id}),Object.values(d).forEach(S=>S())}else a(i)({storyId:r,playUntil:n})},o=i=>({storyId:r})=>{let{resolvers:n}=this.getState(r);if(Object.values(n).length>0)Object.values(n).forEach(t=>t());else{let t=this.getLog(r).find(l=>l.status==="waiting")?.callId;t?a(i)({storyId:r,playUntil:t}):u({storyId:r})}},u=({storyId:i})=>{this.setState(i,{playUntil:void 0,isDebugging:!1}),Object.values(this.getState(i).resolvers).forEach(r=>r())},c=({storyId:i,newPhase:r})=>{let{isDebugging:n}=this.getState(i);if(r==="preparing"&&n)return s({storyId:i,renderPhase:r,isDebugging:n});if(r==="playing")return s({storyId:i,renderPhase:r,isDebugging:n});r==="played"?this.setState(i,{renderPhase:r,isLocked:!1,isPlaying:!1,isDebugging:!1}):r==="errored"?this.setState(i,{renderPhase:r,isLocked:!1,isPlaying:!1}):r==="aborted"?this.setState(i,{renderPhase:r,isLocked:!0,isPlaying:!1}):this.setState(i,{renderPhase:r}),this.sync(i)};R&&R.ready().then(()=>{this.channel=R.getChannel(),this.channel.on(E,s),this.channel.on(P,c),this.channel.on(D,()=>{this.initialized?this.cleanup():this.initialized=!0}),this.channel.on(m.START,a(this.channel)),this.channel.on(m.BACK,e(this.channel)),this.channel.on(m.GOTO,h(this.channel)),this.channel.on(m.NEXT,o(this.channel)),this.channel.on(m.END,u)})}getState(s){return this.state[s]||w()}setState(s,a){if(s){let e=this.getState(s),h=typeof a=="function"?a(e):a;this.state={...this.state,[s]:{...e,...h}},this.updateParentWindowState()}}cleanup(){this.state=Object.entries(this.state).reduce((a,[e,h])=>{let o=b(h);return o&&(a[e]=Object.assign(w(),o)),a},{});let s={controlStates:{detached:this.detached,start:!1,back:!1,goto:!1,next:!1,end:!1},logItems:[]};this.channel?.emit(m.SYNC,s),this.updateParentWindowState()}getLog(s){let{calls:a,shadowCalls:e}=this.getState(s),h=[...e];a.forEach((u,c)=>{h[c]=u});let o=new Set;return h.reduceRight((u,c)=>(c.args.forEach(i=>{i?.__callId__&&o.add(i.__callId__)}),c.path.forEach(i=>{i.__callId__&&o.add(i.__callId__)}),(c.interceptable||c.exception)&&!o.has(c.id)&&(u.unshift({callId:c.id,status:c.status,ancestors:c.ancestors}),o.add(c.id)),u),[])}instrument(s,a,e=0){if(!U(s))return s;let{mutate:h=!1,path:o=[]}=a,u=a.getKeys?a.getKeys(s,e):Object.keys(s);return e+=1,u.reduce((c,i)=>{let r=M(s,i);if(typeof r?.get=="function"){if(r.configurable){let t=()=>r?.get?.bind(s)?.();Object.defineProperty(c,i,{get:()=>this.instrument(t(),{...a,path:o.concat(i)},e)})}return c}let n=s[i];return typeof n!="function"?(c[i]=this.instrument(n,{...a,path:o.concat(i)},e),c):"__originalFn__"in n&&typeof n.__originalFn__=="function"?(c[i]=n,c):(c[i]=(...t)=>this.track(i,n,s,t,a),c[i].__originalFn__=n,Object.defineProperty(c[i],"name",{value:i,writable:!1}),Object.keys(n).length>0&&Object.assign(c[i],this.instrument({...n},{...a,path:o.concat(i)},e)),c)},h?s:B(s))}track(s,a,e,h,o){let u=h?.[0]?.__storyId__||p.__STORYBOOK_PREVIEW__?.selectionStore?.selection?.storyId,{cursor:c,ancestors:i}=this.getState(u);this.setState(u,{cursor:c+1});let r=`${i.slice(-1)[0]||u} [${c}] ${s}`,{path:n=[],intercept:t=!1,retain:l=!1}=o,d=typeof t=="function"?t(s,n):t,f={id:r,cursor:c,storyId:u,ancestors:i,path:n,method:s,args:h,interceptable:d,retain:l},_=(d&&!i.length?this.intercept:this.invoke).call(this,a,e,f,o);return this.instrument(_,{...o,mutate:!0,path:[{__callId__:f.id}]})}intercept(s,a,e,h){let{chainedCallIds:o,isDebugging:u,playUntil:c}=this.getState(e.storyId),i=o.has(e.id);return!u||i||c?(c===e.id&&this.setState(e.storyId,{playUntil:void 0}),this.invoke(s,a,e,h)):new Promise(r=>{this.setState(e.storyId,({resolvers:n})=>({isLocked:!1,resolvers:{...n,[e.id]:r}}))}).then(()=>(this.setState(e.storyId,r=>{let{[e.id]:n,...t}=r.resolvers;return{isLocked:!0,resolvers:t}}),this.invoke(s,a,e,h)))}invoke(s,a,e,h){let{callRefsByResult:o,renderPhase:u}=this.getState(e.storyId),c=25,i=(t,l,d)=>{if(d.includes(t))return"[Circular]";if(d=[...d,t],l>c)return"...";if(o.has(t))return o.get(t);if(t instanceof Array)return t.map(f=>i(f,++l,d));if(t instanceof Date)return{__date__:{value:t.toISOString()}};if(t instanceof Error){let{name:f,message:_,stack:g}=t;return{__error__:{name:f,message:_,stack:g}}}if(t instanceof RegExp){let{flags:f,source:_}=t;return{__regexp__:{flags:f,source:_}}}if(t instanceof p.window?.HTMLElement){let{prefix:f,localName:_,id:g,classList:S,innerText:y}=t,O=Array.from(S);return{__element__:{prefix:f,localName:_,id:g,classNames:O,innerText:y}}}return typeof t=="function"?{__function__:{name:"getMockName"in t?t.getMockName():t.name}}:typeof t=="symbol"?{__symbol__:{description:t.description}}:typeof t=="object"&&t?.constructor?.name&&t?.constructor?.name!=="Object"?{__class__:{name:t.constructor.name}}:Object.prototype.toString.call(t)==="[object Object]"?Object.fromEntries(Object.entries(t).map(([f,_])=>[f,i(_,++l,d)])):t},r={...e,args:e.args.map(t=>i(t,0,[]))};e.path.forEach(t=>{t?.__callId__&&this.setState(e.storyId,({chainedCallIds:l})=>({chainedCallIds:new Set(Array.from(l).concat(t.__callId__))}))});let n=t=>{if(t instanceof Error){let{name:l,message:d,stack:f,callId:_=e.id}=t,{showDiff:g=void 0,diff:S=void 0,actual:y=void 0,expected:O=void 0}=t.name==="AssertionError"?C(t):t,I={name:l,message:d,stack:f,callId:_,showDiff:g,diff:S,actual:y,expected:O};if(this.update({...r,status:"error",exception:I}),this.setState(e.storyId,N=>({callRefsByResult:new Map([...Array.from(N.callRefsByResult.entries()),[t,{__callId__:e.id,retain:e.retain}]])})),e.ancestors?.length)throw Object.prototype.hasOwnProperty.call(t,"callId")||Object.defineProperty(t,"callId",{value:e.id}),t}throw t};try{if(u==="played"&&!e.retain)throw j;let t=(h.getArgs?h.getArgs(e,this.getState(e.storyId)):e.args).map(d=>typeof d!="function"||k(d)||Object.keys(d).length?d:(...f)=>{let{cursor:_,ancestors:g}=this.getState(e.storyId);this.setState(e.storyId,{cursor:0,ancestors:[...g,e.id]});let S=()=>this.setState(e.storyId,{cursor:_,ancestors:g}),y=!1;try{let O=d(...f);return O instanceof Promise?(y=!0,O.finally(S)):O}finally{y||S()}}),l=s.apply(a,t);return l&&["object","function","symbol"].includes(typeof l)&&this.setState(e.storyId,d=>({callRefsByResult:new Map([...Array.from(d.callRefsByResult.entries()),[l,{__callId__:e.id,retain:e.retain}]])})),this.update({...r,status:l instanceof Promise?"active":"done"}),l instanceof Promise?l.then(d=>(this.update({...r,status:"done"}),d),n):l}catch(t){return n(t)}}update(s){this.channel?.emit(m.CALL,s),this.setState(s.storyId,({calls:a})=>{let e=a.concat(s).reduce((h,o)=>Object.assign(h,{[o.id]:o}),{});return{calls:Object.values(e).sort((h,o)=>h.id.localeCompare(o.id,void 0,{numeric:!0}))}}),this.sync(s.storyId)}sync(s){let a=()=>{let{isLocked:e,isPlaying:h}=this.getState(s),o=this.getLog(s),u=o.filter(({ancestors:n})=>!n.length).find(n=>n.status==="waiting")?.callId,c=o.some(n=>n.status==="active");if(this.detached||e||c||o.length===0){let n={controlStates:{detached:this.detached,start:!1,back:!1,goto:!1,next:!1,end:!1},logItems:o};this.channel?.emit(m.SYNC,n);return}let i=o.some(n=>n.status==="done"||n.status==="error"),r={controlStates:{detached:this.detached,start:i,back:i,goto:!0,next:h,end:h},logItems:o,pausedAt:u};this.channel?.emit(m.SYNC,r)};this.setState(s,({syncTimeout:e})=>(clearTimeout(e),{syncTimeout:setTimeout(a,0)}))}};function F(s,a={}){try{let e=!1,h=!1;return p.window?.location?.search?.includes("instrument=true")?e=!0:p.window?.location?.search?.includes("instrument=false")&&(h=!0),p.window?.parent===p.window&&!e||h?s:(p.window&&!p.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__&&(p.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__=new L),(p.window?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__).instrument(s,a))}catch(e){return A.warn(e),s}}function M(s,a){let e=s;for(;e!=null;){let h=Object.getOwnPropertyDescriptor(e,a);if(h)return h;e=Object.getPrototypeOf(e)}}function k(s){if(typeof s!="function")return!1;let a=Object.getOwnPropertyDescriptor(s,"prototype");return a?!a.writable:!1}export{m as EVENTS,F as instrument};
|
|
1
|
+
import{EVENTS as m}from"../_browser-chunks/chunk-ZUWEVLDX.js";import{processError as C}from"../_browser-chunks/chunk-Q5RYDXT3.js";import{once as A}from"../client-logger/index.js";import{FORCE_REMOUNT as E,STORY_RENDER_PHASE_CHANGED as P,SET_CURRENT_STORY as D}from"../core-events/index.js";import{global as p}from"../../../../../@storybook_global@5.0.0/node_modules/@storybook/global/dist/index.js";var R=globalThis.__STORYBOOK_ADDONS_PREVIEW,j=new Error("This function ran after the play function completed. Did you forget to `await` it?"),T=s=>Object.prototype.toString.call(s)==="[object Object]",x=s=>Object.prototype.toString.call(s)==="[object Module]",U=s=>{if(!T(s)&&!x(s))return!1;if(s.constructor===void 0)return!0;let a=s.constructor.prototype;return!!T(a)},B=s=>{try{return new s.constructor}catch{return{}}},w=()=>({renderPhase:"preparing",isDebugging:!1,isPlaying:!1,isLocked:!1,cursor:0,calls:[],shadowCalls:[],callRefsByResult:new Map,chainedCallIds:new Set,ancestors:[],playUntil:void 0,resolvers:{},syncTimeout:void 0}),b=(s,a=!1)=>{let e=(a?s.shadowCalls:s.calls).filter(o=>o.retain);if(!e.length)return;let h=new Map(Array.from(s.callRefsByResult.entries()).filter(([,o])=>o.retain));return{cursor:e.length,calls:e,callRefsByResult:h}},L=class{constructor(){this.detached=!1,this.initialized=!1,this.state={},this.loadParentWindowState=()=>{try{this.state=p.window?.parent?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__||{}}catch{this.detached=!0}},this.updateParentWindowState=()=>{try{p.window.parent.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER_STATE__=this.state}catch{this.detached=!0}},this.loadParentWindowState();let s=({storyId:i,renderPhase:r,isPlaying:n=!0,isDebugging:t=!1})=>{let l=this.getState(i);this.setState(i,{...w(),...b(l,t),renderPhase:r||l.renderPhase,shadowCalls:t?l.shadowCalls:[],chainedCallIds:t?l.chainedCallIds:new Set,playUntil:t?l.playUntil:void 0,isPlaying:n,isDebugging:t}),this.sync(i)},a=i=>({storyId:r,playUntil:n})=>{this.getState(r).isDebugging||this.setState(r,({calls:l})=>({calls:[],shadowCalls:l.map(d=>({...d,status:"waiting"})),isDebugging:!0}));let t=this.getLog(r);this.setState(r,({shadowCalls:l})=>{if(n||!t.length)return{playUntil:n};let d=l.findIndex(f=>f.id===t[0].callId);return{playUntil:l.slice(0,d).filter(f=>f.interceptable&&!f.ancestors?.length).slice(-1)[0]?.id}}),i.emit(E,{storyId:r,isDebugging:!0})},e=i=>({storyId:r})=>{let n=this.getLog(r).filter(l=>!l.ancestors?.length),t=n.reduceRight((l,d,f)=>l>=0||d.status==="waiting"?l:f,-1);a(i)({storyId:r,playUntil:n[t-1]?.callId})},h=i=>({storyId:r,callId:n})=>{let{calls:t,shadowCalls:l,resolvers:d}=this.getState(r),f=t.find(({id:g})=>g===n),_=l.find(({id:g})=>g===n);if(!f&&_&&Object.values(d).length>0){let g=this.getLog(r).find(S=>S.status==="waiting")?.callId;_.id!==g&&this.setState(r,{playUntil:_.id}),Object.values(d).forEach(S=>S())}else a(i)({storyId:r,playUntil:n})},o=i=>({storyId:r})=>{let{resolvers:n}=this.getState(r);if(Object.values(n).length>0)Object.values(n).forEach(t=>t());else{let t=this.getLog(r).find(l=>l.status==="waiting")?.callId;t?a(i)({storyId:r,playUntil:t}):u({storyId:r})}},u=({storyId:i})=>{this.setState(i,{playUntil:void 0,isDebugging:!1}),Object.values(this.getState(i).resolvers).forEach(r=>r())},c=({storyId:i,newPhase:r})=>{let{isDebugging:n}=this.getState(i);if(r==="preparing"&&n)return s({storyId:i,renderPhase:r,isDebugging:n});if(r==="playing")return s({storyId:i,renderPhase:r,isDebugging:n});r==="played"?this.setState(i,{renderPhase:r,isLocked:!1,isPlaying:!1,isDebugging:!1}):r==="errored"?this.setState(i,{renderPhase:r,isLocked:!1,isPlaying:!1}):r==="aborted"?this.setState(i,{renderPhase:r,isLocked:!0,isPlaying:!1}):this.setState(i,{renderPhase:r}),this.sync(i)};R&&R.ready().then(()=>{this.channel=R.getChannel(),this.channel.on(E,s),this.channel.on(P,c),this.channel.on(D,()=>{this.initialized?this.cleanup():this.initialized=!0}),this.channel.on(m.START,a(this.channel)),this.channel.on(m.BACK,e(this.channel)),this.channel.on(m.GOTO,h(this.channel)),this.channel.on(m.NEXT,o(this.channel)),this.channel.on(m.END,u)})}getState(s){return this.state[s]||w()}setState(s,a){if(s){let e=this.getState(s),h=typeof a=="function"?a(e):a;this.state={...this.state,[s]:{...e,...h}},this.updateParentWindowState()}}cleanup(){this.state=Object.entries(this.state).reduce((a,[e,h])=>{let o=b(h);return o&&(a[e]=Object.assign(w(),o)),a},{});let s={controlStates:{detached:this.detached,start:!1,back:!1,goto:!1,next:!1,end:!1},logItems:[]};this.channel?.emit(m.SYNC,s),this.updateParentWindowState()}getLog(s){let{calls:a,shadowCalls:e}=this.getState(s),h=[...e];a.forEach((u,c)=>{h[c]=u});let o=new Set;return h.reduceRight((u,c)=>(c.args.forEach(i=>{i?.__callId__&&o.add(i.__callId__)}),c.path.forEach(i=>{i.__callId__&&o.add(i.__callId__)}),(c.interceptable||c.exception)&&!o.has(c.id)&&(u.unshift({callId:c.id,status:c.status,ancestors:c.ancestors}),o.add(c.id)),u),[])}instrument(s,a,e=0){if(!U(s))return s;let{mutate:h=!1,path:o=[]}=a,u=a.getKeys?a.getKeys(s,e):Object.keys(s);return e+=1,u.reduce((c,i)=>{let r=M(s,i);if(typeof r?.get=="function"){if(r.configurable){let t=()=>r?.get?.bind(s)?.();Object.defineProperty(c,i,{get:()=>this.instrument(t(),{...a,path:o.concat(i)},e)})}return c}let n=s[i];return typeof n!="function"?(c[i]=this.instrument(n,{...a,path:o.concat(i)},e),c):"__originalFn__"in n&&typeof n.__originalFn__=="function"?(c[i]=n,c):(c[i]=(...t)=>this.track(i,n,s,t,a),c[i].__originalFn__=n,Object.defineProperty(c[i],"name",{value:i,writable:!1}),Object.keys(n).length>0&&Object.assign(c[i],this.instrument({...n},{...a,path:o.concat(i)},e)),c)},h?s:B(s))}track(s,a,e,h,o){let u=h?.[0]?.__storyId__||p.__STORYBOOK_PREVIEW__?.selectionStore?.selection?.storyId,{cursor:c,ancestors:i}=this.getState(u);this.setState(u,{cursor:c+1});let r=`${i.slice(-1)[0]||u} [${c}] ${s}`,{path:n=[],intercept:t=!1,retain:l=!1}=o,d=typeof t=="function"?t(s,n):t,f={id:r,cursor:c,storyId:u,ancestors:i,path:n,method:s,args:h,interceptable:d,retain:l},_=(d&&!i.length?this.intercept:this.invoke).call(this,a,e,f,o);return this.instrument(_,{...o,mutate:!0,path:[{__callId__:f.id}]})}intercept(s,a,e,h){let{chainedCallIds:o,isDebugging:u,playUntil:c}=this.getState(e.storyId),i=o.has(e.id);return!u||i||c?(c===e.id&&this.setState(e.storyId,{playUntil:void 0}),this.invoke(s,a,e,h)):new Promise(r=>{this.setState(e.storyId,({resolvers:n})=>({isLocked:!1,resolvers:{...n,[e.id]:r}}))}).then(()=>(this.setState(e.storyId,r=>{let{[e.id]:n,...t}=r.resolvers;return{isLocked:!0,resolvers:t}}),this.invoke(s,a,e,h)))}invoke(s,a,e,h){let{callRefsByResult:o,renderPhase:u}=this.getState(e.storyId),c=25,i=(t,l,d)=>{if(d.includes(t))return"[Circular]";if(d=[...d,t],l>c)return"...";if(o.has(t))return o.get(t);if(t instanceof Array)return t.map(f=>i(f,++l,d));if(t instanceof Date)return{__date__:{value:t.toISOString()}};if(t instanceof Error){let{name:f,message:_,stack:g}=t;return{__error__:{name:f,message:_,stack:g}}}if(t instanceof RegExp){let{flags:f,source:_}=t;return{__regexp__:{flags:f,source:_}}}if(t instanceof p.window?.HTMLElement){let{prefix:f,localName:_,id:g,classList:S,innerText:y}=t,O=Array.from(S);return{__element__:{prefix:f,localName:_,id:g,classNames:O,innerText:y}}}return typeof t=="function"?{__function__:{name:"getMockName"in t?t.getMockName():t.name}}:typeof t=="symbol"?{__symbol__:{description:t.description}}:typeof t=="object"&&t?.constructor?.name&&t?.constructor?.name!=="Object"?{__class__:{name:t.constructor.name}}:Object.prototype.toString.call(t)==="[object Object]"?Object.fromEntries(Object.entries(t).map(([f,_])=>[f,i(_,++l,d)])):t},r={...e,args:e.args.map(t=>i(t,0,[]))};e.path.forEach(t=>{t?.__callId__&&this.setState(e.storyId,({chainedCallIds:l})=>({chainedCallIds:new Set(Array.from(l).concat(t.__callId__))}))});let n=t=>{if(t instanceof Error){let{name:l,message:d,stack:f,callId:_=e.id}=t,{showDiff:g=void 0,diff:S=void 0,actual:y=void 0,expected:O=void 0}=t.name==="AssertionError"?C(t):t,I={name:l,message:d,stack:f,callId:_,showDiff:g,diff:S,actual:y,expected:O};if(this.update({...r,status:"error",exception:I}),this.setState(e.storyId,N=>({callRefsByResult:new Map([...Array.from(N.callRefsByResult.entries()),[t,{__callId__:e.id,retain:e.retain}]])})),e.ancestors?.length)throw Object.prototype.hasOwnProperty.call(t,"callId")||Object.defineProperty(t,"callId",{value:e.id}),t}throw t};try{if(u==="played"&&!e.retain)throw j;let t=(h.getArgs?h.getArgs(e,this.getState(e.storyId)):e.args).map(d=>typeof d!="function"||k(d)||Object.keys(d).length?d:(...f)=>{let{cursor:_,ancestors:g}=this.getState(e.storyId);this.setState(e.storyId,{cursor:0,ancestors:[...g,e.id]});let S=()=>this.setState(e.storyId,{cursor:_,ancestors:g}),y=!1;try{let O=d(...f);return O instanceof Promise?(y=!0,O.finally(S)):O}finally{y||S()}}),l=s.apply(a,t);return l&&["object","function","symbol"].includes(typeof l)&&this.setState(e.storyId,d=>({callRefsByResult:new Map([...Array.from(d.callRefsByResult.entries()),[l,{__callId__:e.id,retain:e.retain}]])})),this.update({...r,status:l instanceof Promise?"active":"done"}),l instanceof Promise?l.then(d=>(this.update({...r,status:"done"}),d),n):l}catch(t){return n(t)}}update(s){this.channel?.emit(m.CALL,s),this.setState(s.storyId,({calls:a})=>{let e=a.concat(s).reduce((h,o)=>Object.assign(h,{[o.id]:o}),{});return{calls:Object.values(e).sort((h,o)=>h.id.localeCompare(o.id,void 0,{numeric:!0}))}}),this.sync(s.storyId)}sync(s){let a=()=>{let{isLocked:e,isPlaying:h}=this.getState(s),o=this.getLog(s),u=o.filter(({ancestors:n})=>!n.length).find(n=>n.status==="waiting")?.callId,c=o.some(n=>n.status==="active");if(this.detached||e||c||o.length===0){let n={controlStates:{detached:this.detached,start:!1,back:!1,goto:!1,next:!1,end:!1},logItems:o};this.channel?.emit(m.SYNC,n);return}let i=o.some(n=>n.status==="done"||n.status==="error"),r={controlStates:{detached:this.detached,start:i,back:i,goto:!0,next:h,end:h},logItems:o,pausedAt:u};this.channel?.emit(m.SYNC,r)};this.setState(s,({syncTimeout:e})=>(clearTimeout(e),{syncTimeout:setTimeout(a,0)}))}};function F(s,a={}){try{let e=!1,h=!1;return p.window?.location?.search?.includes("instrument=true")?e=!0:p.window?.location?.search?.includes("instrument=false")&&(h=!0),p.window?.parent===p.window&&!e||h?s:(p.window&&!p.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__&&(p.window.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__=new L),(p.window?.__STORYBOOK_ADDON_INTERACTIONS_INSTRUMENTER__).instrument(s,a))}catch(e){return A.warn(e),s}}function M(s,a){let e=s;for(;e!=null;){let h=Object.getOwnPropertyDescriptor(e,a);if(h)return h;e=Object.getPrototypeOf(e)}}function k(s){if(typeof s!="function")return!1;let a=Object.getOwnPropertyDescriptor(s,"prototype");return a?!a.writable:!1}export{m as EVENTS,F as instrument};
|