@aussieljk/forkbook 0.0.1-7 → 0.0.1-9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/create/templates/react-native/index.expo.js +4 -4
- package/assets/create/templates/react-native/index.js +5 -5
- package/assets/server/template.ejs +13 -0
- package/dist/_browser-chunks/{Color-2YRIFQLC.js → Color-GEC6HRBY.js} +2 -2
- package/dist/_browser-chunks/{WithTooltip-4R5JMWZ7.js → WithTooltip-CS3HPMGA.js} +6 -4
- package/dist/_browser-chunks/{chunk-4EFKUJG2.js → chunk-6QEYM2YW.js} +25 -25
- package/dist/_browser-chunks/chunk-C5TKXHTM.js +82 -0
- package/dist/_browser-chunks/{chunk-WVF42CP2.js → chunk-DNJ3OSLB.js} +46 -52
- package/dist/_browser-chunks/{chunk-E47B5255.js → chunk-IFADVEQE.js} +63 -543
- package/dist/_browser-chunks/chunk-NPNIBOPF.js +18 -0
- package/dist/_browser-chunks/{chunk-YYWKZ7O3.js → chunk-NTUHL5NS.js} +5 -2
- package/dist/_browser-chunks/chunk-OOETBSA7.js +502 -0
- package/dist/_browser-chunks/{chunk-HTL5ODCB.js → chunk-PFCGVFP6.js} +3 -3
- package/dist/_browser-chunks/{chunk-H4ZHAXN3.js → chunk-V5U45XXZ.js} +1 -1
- package/dist/_browser-chunks/chunk-XKTORVEQ.js +255 -0
- package/dist/_browser-chunks/{chunk-DAUHYZUB.js → chunk-XTQCLWVH.js} +255 -494
- package/dist/_browser-chunks/{chunk-SFMQDIN2.js → chunk-ZHKZKFY4.js} +1 -1
- package/dist/_node-chunks/{attached-runtime-WFZCCGUB.js → attached-runtime-OI5IEIR7.js} +30 -30
- package/dist/_node-chunks/builder-manager-JEIVVV43.js +1139 -0
- package/dist/_node-chunks/{chunk-R6AKCXPH.js → chunk-2FWH7OUZ.js} +7 -7
- package/dist/_node-chunks/{chunk-MF5BYASO.js → chunk-2QPSOAHI.js} +6 -6
- package/dist/_node-chunks/{chunk-PQLXHVWK.js → chunk-2T2S3YYS.js} +6 -6
- package/dist/_node-chunks/{chunk-MF3AT3JQ.js → chunk-35JF5BS4.js} +6 -6
- package/dist/_node-chunks/{chunk-KHWCZDIW.js → chunk-3I43FMZC.js} +7 -7
- package/dist/_node-chunks/{chunk-7PMQPS5E.js → chunk-3R57KO3F.js} +10 -10
- package/dist/_node-chunks/chunk-4CWEAS2M.js +11 -0
- package/dist/_node-chunks/{chunk-CNMMDQC3.js → chunk-4HYKKRBM.js} +13 -15
- package/dist/_node-chunks/{chunk-CBBFNVFZ.js → chunk-4W6HJYYC.js} +7 -7
- package/dist/_node-chunks/{chunk-6K3ZE4HN.js → chunk-57BBVTHQ.js} +6 -6
- package/dist/_node-chunks/{chunk-RZ7UEP4N.js → chunk-5MDE2KCS.js} +6 -6
- package/dist/_node-chunks/{chunk-JPHSU5OI.js → chunk-5NCRCPYK.js} +6 -6
- package/dist/_node-chunks/{chunk-CENNLCU7.js → chunk-6O6BHNDO.js} +7 -7
- package/dist/_node-chunks/{chunk-LZYYZ62Y.js → chunk-7PZDRNVT.js} +6 -6
- package/dist/_node-chunks/{chunk-QSP42ZBM.js → chunk-7X5WP3UJ.js} +6 -6
- package/dist/_node-chunks/{chunk-JDKYP7FW.js → chunk-7XYURNT2.js} +10 -10
- package/dist/_node-chunks/{chunk-HUMAXGH2.js → chunk-AONRQAQP.js} +6 -6
- package/dist/_node-chunks/{chunk-KWER36VB.js → chunk-ASFRQHZH.js} +6 -6
- package/dist/_node-chunks/{chunk-UNCBLHIP.js → chunk-AUY6EZPA.js} +10 -10
- package/dist/_node-chunks/{chunk-P3GOMPP3.js → chunk-BCFTMBAH.js} +7 -7
- package/dist/_node-chunks/{chunk-MRWBN46D.js → chunk-BEHNZYWF.js} +8 -8
- package/dist/_node-chunks/{chunk-UPJMGWMZ.js → chunk-BZNVRJ6H.js} +7 -7
- package/dist/_node-chunks/{chunk-ZSGOW4WQ.js → chunk-CHLWJ5F5.js} +6 -6
- package/dist/_node-chunks/{chunk-F3SAYS4R.js → chunk-CMDR42D7.js} +6 -6
- package/dist/_node-chunks/{chunk-QWRQXG2V.js → chunk-CP646EXE.js} +8 -8
- package/dist/_node-chunks/chunk-DDRGY4RJ.js +57 -0
- package/dist/_node-chunks/{chunk-NQAFLS5U.js → chunk-DMDIIGJ4.js} +7 -7
- package/dist/_node-chunks/{chunk-WHOF2BJB.js → chunk-DTZELAXT.js} +7 -7
- package/dist/_node-chunks/{chunk-BQC6WCUS.js → chunk-ELMANXC3.js} +6 -6
- package/dist/_node-chunks/{chunk-SHH7JROR.js → chunk-ELXK72IJ.js} +6 -6
- package/dist/_node-chunks/{chunk-LJTP5PAJ.js → chunk-F6RXCQF6.js} +6 -6
- package/dist/_node-chunks/{chunk-M7ZVSBNU.js → chunk-FKQHIPUA.js} +6 -6
- package/dist/_node-chunks/{chunk-X63YMAHP.js → chunk-FPWDVE2V.js} +7 -7
- package/dist/_node-chunks/{chunk-J3Q56GX3.js → chunk-FVJLKXNS.js} +23 -23
- package/dist/_node-chunks/{chunk-NUYBFTOU.js → chunk-GABGLW7D.js} +7 -7
- package/dist/_node-chunks/{chunk-Y6G64J5S.js → chunk-GOZDHTIK.js} +6 -6
- package/dist/_node-chunks/{chunk-QWDR5OWQ.js → chunk-GPSR4MZL.js} +15 -15
- package/dist/_node-chunks/{chunk-JED5F3H2.js → chunk-GZ2YC6US.js} +6 -6
- package/dist/_node-chunks/chunk-H5HD6EW2.js +28 -0
- package/dist/_node-chunks/{chunk-I535GEPH.js → chunk-I6ANUF4J.js} +7 -7
- package/dist/_node-chunks/{chunk-MJFMB4WD.js → chunk-ICIP5FB5.js} +9 -9
- package/dist/_node-chunks/{chunk-O7VJA7SM.js → chunk-IK35TZRH.js} +7 -7
- package/dist/_node-chunks/{chunk-5PYQ573S.js → chunk-IOJ6NYLD.js} +7 -7
- package/dist/_node-chunks/{chunk-ESZIQTUH.js → chunk-IWEZ5KSJ.js} +7 -7
- package/dist/_node-chunks/{chunk-SWHTDOB4.js → chunk-JOOZKSBS.js} +7 -7
- package/dist/_node-chunks/{chunk-G2AANC4A.js → chunk-JXVJAA3U.js} +6 -6
- package/dist/_node-chunks/{chunk-ATX7SHS7.js → chunk-K6VX4GUH.js} +8 -8
- package/dist/_node-chunks/{chunk-ESCZ2NSB.js → chunk-L7US6VLX.js} +6 -6
- package/dist/_node-chunks/{chunk-UVV24PG4.js → chunk-LKMHU2P3.js} +7 -7
- package/dist/_node-chunks/{chunk-CDFQORVD.js → chunk-LMWS7NDR.js} +7 -7
- package/dist/_node-chunks/{chunk-WME5NEJA.js → chunk-LPDII6WJ.js} +6 -6
- package/dist/_node-chunks/{chunk-ZIDIYSJQ.js → chunk-MBJ2CUVU.js} +7 -7
- package/dist/_node-chunks/{chunk-6QZ3PX5R.js → chunk-MGXABKCL.js} +7 -7
- package/dist/_node-chunks/{chunk-BR4WDRY6.js → chunk-MHLTWQGQ.js} +8 -8
- package/dist/_node-chunks/{chunk-Q6QRFKHB.js → chunk-MMMKY3DA.js} +8 -8
- package/dist/_node-chunks/{chunk-WBB4NQ6H.js → chunk-MXNT3HBF.js} +6 -6
- package/dist/_node-chunks/{chunk-64JPAW3T.js → chunk-O7WMRMVJ.js} +6 -6
- package/dist/_node-chunks/{chunk-NSZGBFPR.js → chunk-OPLD7FOE.js} +6 -6
- package/dist/_node-chunks/{chunk-MBIIJTGQ.js → chunk-P4CWOISW.js} +7 -7
- package/dist/_node-chunks/{chunk-OGJ7LDX3.js → chunk-POXIO453.js} +7 -7
- package/dist/_node-chunks/{chunk-BRHJ4P3A.js → chunk-PRTTCG3N.js} +6 -6
- package/dist/_node-chunks/{chunk-K5RUOW42.js → chunk-QE3NKWUX.js} +7 -7
- package/dist/_node-chunks/{chunk-SZYMLCHF.js → chunk-QMERCCIQ.js} +6 -6
- package/dist/_node-chunks/{chunk-U3E7E4Q2.js → chunk-QVF2NJK4.js} +10 -10
- package/dist/_node-chunks/{chunk-YZWUD7I5.js → chunk-R33EXC6B.js} +50 -50
- package/dist/_node-chunks/{chunk-JQICISDD.js → chunk-R3BJJGEG.js} +6 -6
- package/dist/_node-chunks/chunk-REDMAZRP.js +18 -0
- package/dist/_node-chunks/{chunk-7V5AOV2J.js → chunk-RJV4QWRP.js} +7 -7
- package/dist/_node-chunks/{chunk-3ZCGT6VF.js → chunk-RXEMA2TT.js} +6 -6
- package/dist/_node-chunks/{chunk-S3HB4EWT.js → chunk-TKOUTJWX.js} +8 -8
- package/dist/_node-chunks/{chunk-TOGDRW2W.js → chunk-TRZWEDUE.js} +6 -6
- package/dist/_node-chunks/{chunk-YVIPYJ53.js → chunk-U3BEYEZ5.js} +8 -8
- package/dist/_node-chunks/{chunk-UF6Q6L5C.js → chunk-UI6NW64P.js} +125 -144
- package/dist/_node-chunks/chunk-UK2NKD4E.js +532 -0
- package/dist/_node-chunks/{chunk-JMS4H7QB.js → chunk-VF6725VX.js} +7 -7
- package/dist/_node-chunks/{chunk-7HVDL6M3.js → chunk-VJJTMS2R.js} +9 -9
- package/dist/_node-chunks/{chunk-7VHCAGBJ.js → chunk-VQBXHU2T.js} +8 -8
- package/dist/_node-chunks/{chunk-DT45EUDD.js → chunk-VZ3PQJKF.js} +27 -32
- package/dist/_node-chunks/{chunk-6CB3XSQ2.js → chunk-WI6FDUOM.js} +8 -8
- package/dist/_node-chunks/{chunk-U6DHF3RM.js → chunk-WTS7HYGM.js} +7 -7
- package/dist/_node-chunks/{chunk-OWT6AVWK.js → chunk-WXMIR2F2.js} +8 -8
- package/dist/_node-chunks/{chunk-FVFSSIGA.js → chunk-XA2UQNP3.js} +10 -10
- package/dist/_node-chunks/{chunk-FTUQ7T3V.js → chunk-Y2FWEOIW.js} +8 -8
- package/dist/_node-chunks/{chunk-EAL4RVEF.js → chunk-Y5JLYH6J.js} +6 -6
- package/dist/_node-chunks/{chunk-JOSJ64KD.js → chunk-YELBVH4K.js} +7 -7
- package/dist/_node-chunks/{chunk-MZQXEAI6.js → chunk-YK5N35SR.js} +9 -9
- package/dist/_node-chunks/{chunk-4HGC3G6B.js → chunk-YLXOGJX6.js} +21 -9
- package/dist/_node-chunks/{chunk-NLPC2DDQ.js → chunk-YSVJU5VZ.js} +6 -6
- package/dist/_node-chunks/{chunk-RCY7TLET.js → chunk-ZFTEHWNT.js} +8 -8
- package/dist/_node-chunks/{chunk-JTLOSDYL.js → chunk-ZLBDSC7U.js} +9 -9
- package/dist/_node-chunks/{chunk-UAG3XK32.js → chunk-ZMI35R7E.js} +47 -36
- package/dist/_node-chunks/{chunk-RKKMQA6N.js → chunk-ZOE2QQSS.js} +8 -8
- package/dist/_node-chunks/{chunk-DMDZPUHM.js → chunk-ZST2SPBX.js} +6 -6
- package/dist/_node-chunks/{chunk-Y2GHAOKI.js → chunk-ZUYRTHXN.js} +6 -6
- package/dist/_node-chunks/dist-FABQFQ76.js +27 -0
- package/dist/_node-chunks/dist-ZUXZVI3A.js +16 -0
- package/dist/_node-chunks/{local-runtime-UN5QK2SE.js → local-runtime-LKT5I6NG.js} +20 -20
- package/dist/_node-chunks/{mdx-plugin-6M6CMNL3.js → mdx-plugin-2YIBFVCV.js} +13 -13
- package/dist/_node-chunks/{monorepo-253VKW4B.js → monorepo-HROZW452.js} +11 -11
- package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-3ZOE54OQ.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-MUIOTVJR.js} +11 -11
- package/dist/_node-chunks/optimized-tests-EK5H7MUQ.js +22 -0
- package/dist/_node-chunks/{pattern-copy-play-CCCJRMSL.js → pattern-copy-play-VQNMME5S.js} +11 -11
- package/dist/_node-chunks/postinstallAddon-T4RENREB.js +20 -0
- package/dist/_node-chunks/{rehype-external-links-LJTPLCGD.js → rehype-external-links-WXD3NVWK.js} +9 -9
- package/dist/_node-chunks/{rehype-slug-KQI7ULEZ.js → rehype-slug-LWBEJBWR.js} +9 -9
- package/dist/_node-chunks/{relaxed-limits-MUE2NI7S.js → relaxed-limits-MKV6OE3S.js} +11 -11
- package/dist/_node-chunks/{run-SYLR25HA.js → run-A4A2HQDT.js} +17 -17
- package/dist/_node-chunks/{run-PGZMPNMS.js → run-UBPF7ZUG.js} +53 -26
- package/dist/_node-chunks/session-id-YZZIHNID.js +23 -0
- package/dist/_node-chunks/{setup-XZWSUYPG.js → setup-SMMCS2Q5.js} +8 -8
- package/dist/_node-chunks/{vitest.config.4.template-T25YYRGV.js → vitest.config.4.template-PYSDGPB4.js} +7 -7
- package/dist/addon-a11y/index.js +1 -1
- package/dist/addon-a11y/manager.js +19 -23
- package/dist/addon-a11y/preset.js +7 -7
- package/dist/addon-a11y/preview.js +1 -1
- package/dist/addon-docs/blocks.js +21 -27
- package/dist/addon-docs/manager.js +2 -2
- package/dist/addon-docs/preset.js +10 -10
- package/dist/addon-links/index.js +4 -2
- package/dist/addon-links/preview.d.ts +1 -1
- package/dist/addon-links/preview.js +4 -2
- package/dist/addon-links/react/index.js +3 -1
- package/dist/addon-mcp/preset.js +10 -10
- package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +8 -10
- package/dist/addon-pseudo-states/manager.js +2 -2
- package/dist/addon-themes/manager.js +3 -3
- package/dist/addon-themes/postinstall.js +7 -7
- package/dist/addon-vitest/constants.js +8 -8
- package/dist/addon-vitest/manager.js +8 -8
- package/dist/addon-vitest/node/coverage-reporter.js +8 -8
- package/dist/addon-vitest/node/vitest.js +16 -16
- package/dist/addon-vitest/postinstall.js +10 -10
- package/dist/addon-vitest/preset.js +14 -14
- package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
- package/dist/addon-vitest/vitest-plugin/index.js +15 -15
- package/dist/addon-vitest/vitest-plugin/setup-file.js +1 -1
- package/dist/babel/index.js +11 -11
- package/dist/bin/core.js +62 -62
- package/dist/bin/dispatcher.js +13 -16
- package/dist/bin/loader.js +8 -8
- package/dist/builder-vite/index.js +15 -15
- package/dist/builder-vite/preset.js +13 -13
- package/dist/{chunk-B_ZhEPlo.d.ts → chunk-BhAPwdVB.d.ts} +1 -1
- package/dist/{chunk-DuDsmeM7.d.ts → chunk-CFk6djyM.d.ts} +4 -4
- package/dist/{chunk-CMaYrou5.d.ts → chunk-DXsI731B.d.ts} +1 -1
- package/dist/{chunk-BWzbIWPz.d.ts → chunk-Dw_4ad2Y.d.ts} +5 -5
- package/dist/{chunk-LrH1y9J2.d.ts → chunk-PdOIKm0H.d.ts} +42 -9
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +22 -22
- package/dist/cli/skills/content/index.d.ts +1 -1
- package/dist/cli/skills/content/index.js +2 -2
- package/dist/cli/tools/sdk/child-host.d.ts +1 -1
- package/dist/cli/tools/sdk/child-host.js +17 -17
- package/dist/cli/tools/sdk/index.d.ts +1 -1
- package/dist/cli/tools/sdk/index.js +18 -18
- package/dist/cli-commands/bin/index.js +7 -7
- package/dist/common/index.d.ts +14 -27
- package/dist/common/index.js +36 -40
- package/dist/components/index.d.ts +38 -1
- package/dist/components/index.js +597 -522
- package/dist/core-server/index.d.ts +6 -6
- package/dist/core-server/index.js +283 -174
- package/dist/core-server/presets/common-manager.js +492 -118
- package/dist/core-server/presets/common-override-preset.js +10 -10
- package/dist/core-server/presets/common-preset.js +51 -43
- package/dist/create/bin/index.js +7 -7
- package/dist/create/index.js +15 -15
- package/dist/csf-tools/index.d.ts +3 -1
- package/dist/csf-tools/index.js +14 -12
- package/dist/manager/_manager-chunks/{globals-runtime-CI-C7ncS.js → globals-runtime-B1q30If4.js} +4 -4
- package/dist/manager/_manager-chunks/{globals-runtime-4fCHtNC6.js → globals-runtime-BY3epqww.js} +413 -2
- package/dist/manager/_manager-chunks/globals-runtime-Bj5KDUJi.js +8935 -0
- package/dist/manager/_manager-chunks/{globals-runtime-Bpc_ftuT.js → globals-runtime-Bs75QQ_I.js} +3 -1192
- package/dist/manager/_manager-chunks/{globals-runtime-D82vqOGq.js → globals-runtime-BweHuXkK.js} +2 -2
- package/dist/manager/_manager-chunks/{globals-runtime-BKPOYSwp.js → globals-runtime-C4GdZS7_.js} +4 -4
- package/dist/manager/_manager-chunks/{globals-runtime-DB8fVA5g.js → globals-runtime-CA8AuIRT.js} +2 -1
- package/dist/manager/_manager-chunks/{globals-runtime-CzEhVGVp.js → globals-runtime-CnfHMZV0.js} +153 -27
- package/dist/manager/_manager-chunks/{globals-runtime-BMIT8BJb.js → globals-runtime-DgHSAUIB.js} +1 -1
- package/dist/manager/_manager-chunks/{globals-runtime-kmPSyf3j.js → globals-runtime-DvV_TF3-.js} +2 -2
- package/dist/manager/_manager-chunks/{globals-runtime-DMq1Phbl.js → globals-runtime-FcobHVj9.js} +480 -375
- package/dist/manager/_manager-chunks/{globals-runtime-CoCzM1V_.js → globals-runtime-WZKaeKm9.js} +1 -1
- package/dist/manager/_manager-chunks/{globals-runtime-CI_p54Ha.js → globals-runtime-dh5vgpgm.js} +238 -232
- package/dist/manager/_manager-chunks/{globals-runtime-DOPUchia.js → globals-runtime-wjkxyMn0.js} +4 -3
- package/dist/manager/_manager-chunks/{runtime-Cf0p9DUx.js → runtime-BSkBrZa7.js} +3 -3
- package/dist/manager/_manager-chunks/{runtime-D09XMY6V.js → runtime-Bdda1ODD.js} +1 -1
- package/dist/manager/_manager-chunks/{runtime-B4U0u9p4.js → runtime-Bp_XtatN.js} +2 -2
- package/dist/manager/_manager-chunks/{runtime-D-nYLsdk.js → runtime-D-bkVc6v.js} +32 -31
- package/dist/manager/_manager-chunks/{runtime-DzxaTqVN.js → runtime-DP_7wWTN.js} +2 -2
- package/dist/manager/_manager-chunks/{runtime-BM30BmeT.js → runtime-DlX-MKi1.js} +335 -327
- package/dist/manager/_manager-chunks/{runtime-ecY5qnmo.js → runtime-TytMkKcC.js} +339 -240
- package/dist/manager/_manager-chunks/{runtime-DvrwKw7z.js → runtime-jOBCBZ66.js} +98 -61
- package/dist/manager/globals-runtime.js +1 -1
- package/dist/manager/globals.d.ts +1 -1
- package/dist/manager/globals.js +1 -1
- package/dist/manager/runtime.js +1 -1
- package/dist/manager-api/index.d.ts +1 -1
- package/dist/manager-api/index.js +34 -9
- package/dist/manager-errors.d.ts +1 -1
- package/dist/mcp/index.js +8 -8
- package/dist/mocking-utils/index.js +9 -9
- package/dist/nextjs-vite/index.d.ts +2 -2
- package/dist/nextjs-vite/node/index.d.ts +2 -2
- package/dist/nextjs-vite/node/index.js +7 -7
- package/dist/nextjs-vite/preset.js +11 -11
- package/dist/nextjs-vite/vite-plugin/index.js +7 -7
- package/dist/nextjs-vite-plugin/index.js +8 -8
- package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
- package/dist/node-logger/index.js +9 -9
- package/dist/oxc-parser/index.js +10 -10
- package/dist/oxc-parser/worker.js +10 -10
- package/dist/preview-api/index.d.ts +1 -1
- package/dist/preview-errors.d.ts +1 -1
- package/dist/react/docgen/docgen-worker.js +11 -11
- package/dist/react/preset.js +13 -13
- package/dist/react-native/bin/get-stories.js +12 -12
- package/dist/react-native/index.d.ts +8 -8
- package/dist/react-native/index.js +3 -3
- package/dist/react-native/metro/node.js +10 -10
- package/dist/react-native/metro/{withStorybook.d.ts → withForkbook.d.ts} +9 -9
- package/dist/react-native/metro/{withStorybook.js → withForkbook.js} +16 -16
- package/dist/react-native/scripts/generate.d.ts +1 -1
- package/dist/react-native/scripts/generate.js +8 -8
- package/dist/react-native/stub.js +1 -1
- package/dist/react-vite/index.d.ts +2 -2
- package/dist/react-vite/node/index.d.ts +3 -3
- package/dist/react-vite/node/index.js +7 -7
- package/dist/react-vite/preset.js +7 -7
- package/dist/router/index.d.ts +69 -1
- package/dist/router/index.js +48 -8
- package/dist/server-errors.d.ts +1 -1
- package/dist/server-errors.js +9 -9
- package/dist/shared/open-service/index.d.ts +1 -1
- package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
- package/dist/telemetry/index.d.ts +3 -3
- package/dist/telemetry/index.js +43 -43
- package/dist/theming/index.js +13 -9
- package/dist/types/index.d.ts +2 -2
- package/package.json +7 -9
- package/dist/_node-chunks/builder-manager-DHKHRZK4.js +0 -1623
- package/dist/_node-chunks/chunk-EFFWFE6W.js +0 -11
- package/dist/_node-chunks/chunk-UGXN7JTT.js +0 -18
- package/dist/_node-chunks/dist-5EG56KTF.js +0 -16
- package/dist/_node-chunks/dist-UEXSNGGQ.js +0 -27
- package/dist/_node-chunks/optimized-tests-JSWLRMEI.js +0 -22
- package/dist/_node-chunks/postinstallAddon-VMANBHPR.js +0 -20
- package/dist/_node-chunks/session-id-J4A25UQ6.js +0 -23
- package/dist/manager/_manager-chunks/globals-runtime-BMCaBukU.js +0 -413
- package/dist/manager/_manager-chunks/globals-runtime-BO0pfoqL.js +0 -3414
- package/dist/manager/_manager-chunks/globals-runtime-BZKYJxYC.js +0 -2093
- package/dist/manager/_manager-chunks/globals-runtime-CTyYXvUm.js +0 -41
- package/dist/manager/_manager-chunks/globals-runtime-Dbt08xWQ.js +0 -1960
|
@@ -1,53 +1,41 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
getCssDimensions,
|
|
3
|
+
inertValue,
|
|
4
|
+
useOpenChangeComplete,
|
|
5
|
+
useSyncExternalStore,
|
|
6
|
+
useTransitionStatus
|
|
7
|
+
} from "./chunk-XKTORVEQ.js";
|
|
8
|
+
import {
|
|
9
|
+
ACTIVE_COMPOSITE_ITEM,
|
|
10
|
+
CompositeList,
|
|
11
|
+
CompositeRoot,
|
|
12
|
+
useCompositeItem,
|
|
13
|
+
useCompositeListItem,
|
|
14
|
+
useControlled
|
|
15
|
+
} from "./chunk-OOETBSA7.js";
|
|
16
|
+
import {
|
|
8
17
|
EMPTY_ARRAY,
|
|
9
|
-
EMPTY_OBJECT,
|
|
10
|
-
END,
|
|
11
|
-
HOME,
|
|
12
|
-
MODIFIER_KEYS,
|
|
13
18
|
TransitionStatusDataAttributes_exports,
|
|
14
19
|
activeElement,
|
|
15
20
|
contains,
|
|
16
21
|
createChangeEventDetails,
|
|
17
|
-
error,
|
|
18
|
-
findNonDisabledListIndex,
|
|
19
22
|
formatErrorMessage_default,
|
|
20
|
-
getCssDimensions,
|
|
21
|
-
getMaxListIndex,
|
|
22
|
-
getMinListIndex,
|
|
23
23
|
getParentNode,
|
|
24
|
-
getTarget,
|
|
25
24
|
getWindow,
|
|
26
|
-
inertValue,
|
|
27
25
|
isHTMLElement,
|
|
28
|
-
isIndexOutOfListBounds,
|
|
29
26
|
isLastTraversableNode,
|
|
30
|
-
isListIndexDisabled,
|
|
31
|
-
isNativeInput,
|
|
32
27
|
isReactVersionAtLeast,
|
|
33
28
|
ownerDocument,
|
|
34
29
|
reason_parts_exports,
|
|
35
|
-
scrollIntoViewIfNeeded,
|
|
36
30
|
transitionStatusMapping,
|
|
37
31
|
useBaseUiId,
|
|
38
32
|
useButton,
|
|
39
33
|
useCompositeRootContext,
|
|
40
|
-
useDirection,
|
|
41
34
|
useForcedRerendering,
|
|
42
35
|
useIsoLayoutEffect,
|
|
43
|
-
useMergedRefs,
|
|
44
|
-
useOpenChangeComplete,
|
|
45
|
-
useRefWithInit,
|
|
46
36
|
useRenderElement,
|
|
47
|
-
useStableCallback
|
|
48
|
-
|
|
49
|
-
useTransitionStatus
|
|
50
|
-
} from "./chunk-DAUHYZUB.js";
|
|
37
|
+
useStableCallback
|
|
38
|
+
} from "./chunk-XTQCLWVH.js";
|
|
51
39
|
import {
|
|
52
40
|
__export
|
|
53
41
|
} from "./chunk-IMSF75WX.js";
|
|
@@ -63,203 +51,14 @@ __export(index_parts_exports, {
|
|
|
63
51
|
});
|
|
64
52
|
|
|
65
53
|
// ../../node_modules/@base-ui/react/tabs/root/TabsRoot.mjs
|
|
66
|
-
import * as React5 from "react";
|
|
67
|
-
|
|
68
|
-
// ../../node_modules/@base-ui/utils/useControlled.mjs
|
|
69
|
-
import * as React from "react";
|
|
70
|
-
function useControlled({
|
|
71
|
-
controlled,
|
|
72
|
-
default: defaultProp,
|
|
73
|
-
name,
|
|
74
|
-
state = "value"
|
|
75
|
-
}) {
|
|
76
|
-
let {
|
|
77
|
-
current: isControlled
|
|
78
|
-
} = React.useRef(controlled !== void 0), [valueState, setValue] = React.useState(() => defaultProp), value = isControlled && controlled !== void 0 ? controlled : valueState;
|
|
79
|
-
if (process.env.NODE_ENV !== "production") {
|
|
80
|
-
React.useEffect(() => {
|
|
81
|
-
isControlled !== (controlled !== void 0) && error([`A component is changing the ${isControlled ? "" : "un"}controlled ${state} state of ${name} to be ${isControlled ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${name} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(`
|
|
82
|
-
`));
|
|
83
|
-
}, [state, name, controlled]);
|
|
84
|
-
let {
|
|
85
|
-
current: defaultValue
|
|
86
|
-
} = React.useRef(defaultProp);
|
|
87
|
-
React.useEffect(() => {
|
|
88
|
-
!isControlled && serializeToDevModeString(defaultValue) !== serializeToDevModeString(defaultProp) && error([`A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. To suppress this warning opt to use a controlled ${name}.`].join(`
|
|
89
|
-
`));
|
|
90
|
-
}, [defaultProp]);
|
|
91
|
-
}
|
|
92
|
-
let setValueIfUncontrolled = React.useCallback((newValue) => {
|
|
93
|
-
isControlled || setValue(newValue);
|
|
94
|
-
}, []);
|
|
95
|
-
return [value, setValueIfUncontrolled];
|
|
96
|
-
}
|
|
97
|
-
function serializeToDevModeString(input) {
|
|
98
|
-
let nextId = 0, seen = /* @__PURE__ */ new WeakMap();
|
|
99
|
-
try {
|
|
100
|
-
return JSON.stringify(input, function(key, value) {
|
|
101
|
-
if (!(key === "_owner" && this != null && typeof this == "object" && "$$typeof" in this)) {
|
|
102
|
-
if (typeof value == "bigint")
|
|
103
|
-
return `__bigint__:${value}`;
|
|
104
|
-
if (value !== null && typeof value == "object") {
|
|
105
|
-
let id = seen.get(value);
|
|
106
|
-
if (id !== void 0)
|
|
107
|
-
return `__object__:${id}`;
|
|
108
|
-
seen.set(value, nextId), nextId += 1;
|
|
109
|
-
}
|
|
110
|
-
return value;
|
|
111
|
-
}
|
|
112
|
-
}) ?? `__top__:${typeof input}`;
|
|
113
|
-
} catch {
|
|
114
|
-
return "__unserializable__";
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
// ../../node_modules/@base-ui/react/internals/composite/list/CompositeList.mjs
|
|
119
|
-
import * as React3 from "react";
|
|
120
|
-
|
|
121
|
-
// ../../node_modules/@base-ui/react/internals/composite/list/CompositeListContext.mjs
|
|
122
54
|
import * as React2 from "react";
|
|
123
|
-
var CompositeListContext = React2.createContext({
|
|
124
|
-
register: () => {
|
|
125
|
-
},
|
|
126
|
-
unregister: () => {
|
|
127
|
-
},
|
|
128
|
-
subscribeMapChange: () => () => {
|
|
129
|
-
},
|
|
130
|
-
nextIndexRef: {
|
|
131
|
-
current: 0
|
|
132
|
-
}
|
|
133
|
-
});
|
|
134
|
-
process.env.NODE_ENV !== "production" && (CompositeListContext.displayName = "CompositeListContext");
|
|
135
|
-
function useCompositeListContext() {
|
|
136
|
-
return React2.useContext(CompositeListContext);
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
// ../../node_modules/@base-ui/react/internals/composite/list/CompositeList.mjs
|
|
140
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
141
|
-
function CompositeList(props) {
|
|
142
|
-
let {
|
|
143
|
-
children,
|
|
144
|
-
elementsRef,
|
|
145
|
-
labelsRef,
|
|
146
|
-
onMapChange: onMapChangeProp
|
|
147
|
-
} = props, onMapChange = useStableCallback(onMapChangeProp), [, setMapTick] = React3.useState(0), listeners = useRefWithInit(createListeners).current, map = useRefWithInit(createMap).current, nextIndexRef = React3.useRef(0), isDirtyRef = React3.useRef(!0), itemsRef = React3.useRef(null), mutationObserverRef = React3.useRef(null), scheduleMapUpdate = useStableCallback(() => {
|
|
148
|
-
isDirtyRef.current || (isDirtyRef.current = !0, setMapTick((tick) => tick + 1));
|
|
149
|
-
}), register = useStableCallback((node, registration) => {
|
|
150
|
-
map.set(node, registration), scheduleMapUpdate();
|
|
151
|
-
}), unregister = useStableCallback((node) => {
|
|
152
|
-
map.delete(node), scheduleMapUpdate();
|
|
153
|
-
}), syncRefs = useStableCallback((items) => {
|
|
154
|
-
let nextMap = /* @__PURE__ */ new Map();
|
|
155
|
-
return elementsRef.current.length = 0, labelsRef && (labelsRef.current.length = 0), items.forEach((item) => {
|
|
156
|
-
nextMap.set(item.element, {
|
|
157
|
-
...item.registration.metadata ?? {},
|
|
158
|
-
index: item.index
|
|
159
|
-
}), elementsRef.current[item.index] = item.element, labelsRef && (labelsRef.current[item.index] = item.registration.label !== void 0 ? item.registration.label : item.registration.textRef?.current?.textContent ?? item.element.textContent);
|
|
160
|
-
}), nextIndexRef.current = elementsRef.current.length, nextMap;
|
|
161
|
-
});
|
|
162
|
-
function observe(sortedNodes) {
|
|
163
|
-
if (mutationObserverRef.current?.disconnect(), mutationObserverRef.current = null, typeof MutationObserver != "function" || sortedNodes.length < 2)
|
|
164
|
-
return;
|
|
165
|
-
let mutationObserver = new MutationObserver((entries) => {
|
|
166
|
-
if (!hasMovedNode(entries))
|
|
167
|
-
return;
|
|
168
|
-
let previousConnectedNode = null;
|
|
169
|
-
for (let node of sortedNodes)
|
|
170
|
-
if (node.isConnected) {
|
|
171
|
-
if (previousConnectedNode && sortByDocumentPosition(previousConnectedNode, node) > 0) {
|
|
172
|
-
mutationObserver.disconnect(), scheduleMapUpdate();
|
|
173
|
-
return;
|
|
174
|
-
}
|
|
175
|
-
previousConnectedNode = node;
|
|
176
|
-
}
|
|
177
|
-
});
|
|
178
|
-
mutationObserverRef.current = mutationObserver;
|
|
179
|
-
let roots = /* @__PURE__ */ new Set();
|
|
180
|
-
for (let i = 1; i < sortedNodes.length; i += 1) {
|
|
181
|
-
let root = getCommonAncestor(sortedNodes[i - 1], sortedNodes[i]);
|
|
182
|
-
root && roots.add(root);
|
|
183
|
-
}
|
|
184
|
-
roots.forEach((root) => mutationObserver.observe(root, {
|
|
185
|
-
childList: !0
|
|
186
|
-
}));
|
|
187
|
-
}
|
|
188
|
-
let flush = useStableCallback(() => {
|
|
189
|
-
let [items, automaticNodes] = getCompositeListSnapshot(map), nextMap = syncRefs(items), previousItems = itemsRef.current, changed = !previousItems || previousItems.length !== items.length || items.some((item, index2) => {
|
|
190
|
-
let previousItem = previousItems[index2];
|
|
191
|
-
return item.index !== previousItem.index || item.element !== previousItem.element || item.registration.index !== previousItem.registration.index || item.registration.metadata !== previousItem.registration.metadata;
|
|
192
|
-
});
|
|
193
|
-
observe(automaticNodes), itemsRef.current = items, isDirtyRef.current = !1, changed && (listeners.forEach((listener) => listener(nextMap)), onMapChange(nextMap));
|
|
194
|
-
});
|
|
195
|
-
useIsoLayoutEffect(() => (!isDirtyRef.current && itemsRef.current && syncRefs(itemsRef.current), () => {
|
|
196
|
-
elementsRef.current = [], labelsRef && (labelsRef.current = []);
|
|
197
|
-
}), [elementsRef, labelsRef, syncRefs]), useIsoLayoutEffect(() => {
|
|
198
|
-
isDirtyRef.current && flush();
|
|
199
|
-
}), useIsoLayoutEffect(() => () => {
|
|
200
|
-
mutationObserverRef.current?.disconnect(), isDirtyRef.current = !0;
|
|
201
|
-
}, []);
|
|
202
|
-
let subscribeMapChange = useStableCallback((fn) => (listeners.add(fn), () => {
|
|
203
|
-
listeners.delete(fn);
|
|
204
|
-
})), contextValue = React3.useMemo(() => ({
|
|
205
|
-
register,
|
|
206
|
-
unregister,
|
|
207
|
-
subscribeMapChange,
|
|
208
|
-
nextIndexRef
|
|
209
|
-
}), [register, unregister, subscribeMapChange, nextIndexRef]);
|
|
210
|
-
return _jsx(CompositeListContext.Provider, {
|
|
211
|
-
value: contextValue,
|
|
212
|
-
children
|
|
213
|
-
});
|
|
214
|
-
}
|
|
215
|
-
function createMap() {
|
|
216
|
-
return /* @__PURE__ */ new Map();
|
|
217
|
-
}
|
|
218
|
-
function createListeners() {
|
|
219
|
-
return /* @__PURE__ */ new Set();
|
|
220
|
-
}
|
|
221
|
-
function getCompositeListSnapshot(map) {
|
|
222
|
-
let reservedIndices = /* @__PURE__ */ new Set(), items = [], automaticItems = [];
|
|
223
|
-
map.forEach((registration, node) => {
|
|
224
|
-
if (!node.isConnected)
|
|
225
|
-
return;
|
|
226
|
-
let index2 = registration.index, item = {
|
|
227
|
-
index: index2 ?? -1,
|
|
228
|
-
element: node,
|
|
229
|
-
registration
|
|
230
|
-
};
|
|
231
|
-
index2 === null ? automaticItems.push(item) : index2 >= 0 && (reservedIndices.add(index2), items.push(item));
|
|
232
|
-
});
|
|
233
|
-
let nextAutomaticIndex = 0;
|
|
234
|
-
return automaticItems.sort((a, b) => sortByDocumentPosition(a.element, b.element)), automaticItems.forEach((item) => {
|
|
235
|
-
for (; reservedIndices.has(nextAutomaticIndex); )
|
|
236
|
-
nextAutomaticIndex += 1;
|
|
237
|
-
item.index = nextAutomaticIndex, items.push(item), nextAutomaticIndex += 1;
|
|
238
|
-
}), reservedIndices.size > 0 && items.sort((a, b) => a.index - b.index), [items, automaticItems.map((item) => item.element)];
|
|
239
|
-
}
|
|
240
|
-
function getCommonAncestor(firstNode, lastNode) {
|
|
241
|
-
let ancestor = firstNode.parentElement;
|
|
242
|
-
for (; ancestor && !ancestor.contains(lastNode); )
|
|
243
|
-
ancestor = ancestor.parentElement;
|
|
244
|
-
return ancestor;
|
|
245
|
-
}
|
|
246
|
-
function hasMovedNode(entries) {
|
|
247
|
-
for (let entry of entries)
|
|
248
|
-
for (let i = 0; i < entry.removedNodes.length; i += 1)
|
|
249
|
-
if (entry.removedNodes[i].isConnected)
|
|
250
|
-
return !0;
|
|
251
|
-
return !1;
|
|
252
|
-
}
|
|
253
|
-
function sortByDocumentPosition(a, b) {
|
|
254
|
-
return a.nextElementSibling === b ? -1 : b.nextElementSibling === a ? 1 : a.compareDocumentPosition(b) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1;
|
|
255
|
-
}
|
|
256
55
|
|
|
257
56
|
// ../../node_modules/@base-ui/react/tabs/root/TabsRootContext.mjs
|
|
258
|
-
import * as
|
|
259
|
-
var TabsRootContext =
|
|
57
|
+
import * as React from "react";
|
|
58
|
+
var TabsRootContext = React.createContext(void 0);
|
|
260
59
|
process.env.NODE_ENV !== "production" && (TabsRootContext.displayName = "TabsRootContext");
|
|
261
60
|
function useTabsRootContext() {
|
|
262
|
-
let context =
|
|
61
|
+
let context = React.useContext(TabsRootContext);
|
|
263
62
|
if (context === void 0)
|
|
264
63
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: TabsRootContext is missing. Tabs parts must be placed within <Tabs.Root>." : formatErrorMessage_default(64));
|
|
265
64
|
return context;
|
|
@@ -276,8 +75,8 @@ var tabsStateAttributesMapping = {
|
|
|
276
75
|
};
|
|
277
76
|
|
|
278
77
|
// ../../node_modules/@base-ui/react/tabs/root/TabsRoot.mjs
|
|
279
|
-
import { jsx as
|
|
280
|
-
var TabsRoot =
|
|
78
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
79
|
+
var TabsRoot = React2.forwardRef(function(componentProps, forwardedRef) {
|
|
281
80
|
let {
|
|
282
81
|
className,
|
|
283
82
|
defaultValue: defaultValueProp = 0,
|
|
@@ -287,12 +86,12 @@ var TabsRoot = React5.forwardRef(function(componentProps, forwardedRef) {
|
|
|
287
86
|
value: valueProp,
|
|
288
87
|
style,
|
|
289
88
|
...elementProps
|
|
290
|
-
} = componentProps, hasExplicitDefaultValueProp = componentProps.defaultValue !== void 0, tabPanelRefs =
|
|
89
|
+
} = componentProps, hasExplicitDefaultValueProp = componentProps.defaultValue !== void 0, tabPanelRefs = React2.useRef([]), [mountedTabPanels, setMountedTabPanels] = React2.useState(() => /* @__PURE__ */ new Map()), [value, setValue] = useControlled({
|
|
291
90
|
controlled: valueProp,
|
|
292
91
|
default: defaultValueProp,
|
|
293
92
|
name: "Tabs",
|
|
294
93
|
state: "value"
|
|
295
|
-
}), isControlled = valueProp !== void 0, [tabMap, setTabMap] =
|
|
94
|
+
}), isControlled = valueProp !== void 0, [tabMap, setTabMap] = React2.useState(() => /* @__PURE__ */ new Map()), lastKnownTabElementRef = React2.useRef(void 0), getTabElementBySelectedValue = React2.useCallback((selectedValue) => findTabElement(tabMap, selectedValue), [tabMap]), [activationDirectionState, setActivationDirectionState] = React2.useState(() => ({
|
|
296
95
|
previousValue: value,
|
|
297
96
|
tabActivationDirection: "none"
|
|
298
97
|
})), {
|
|
@@ -324,11 +123,11 @@ var TabsRoot = React5.forwardRef(function(componentProps, forwardedRef) {
|
|
|
324
123
|
let next = new Map(prev);
|
|
325
124
|
return next.delete(panelValue), next;
|
|
326
125
|
});
|
|
327
|
-
})), getTabPanelIdByValue =
|
|
126
|
+
})), getTabPanelIdByValue = React2.useCallback((tabValue) => mountedTabPanels.get(tabValue), [mountedTabPanels]), getTabIdByPanelValue = React2.useCallback((tabPanelValue) => {
|
|
328
127
|
for (let tabMetadata of tabMap.values())
|
|
329
128
|
if (tabPanelValue === tabMetadata.value)
|
|
330
129
|
return tabMetadata.id;
|
|
331
|
-
}, [tabMap]), tabsContextValue =
|
|
130
|
+
}, [tabMap]), tabsContextValue = React2.useMemo(() => ({
|
|
332
131
|
getTabElementBySelectedValue,
|
|
333
132
|
getTabIdByPanelValue,
|
|
334
133
|
getTabPanelIdByValue,
|
|
@@ -338,15 +137,15 @@ var TabsRoot = React5.forwardRef(function(componentProps, forwardedRef) {
|
|
|
338
137
|
setTabMap,
|
|
339
138
|
tabActivationDirection,
|
|
340
139
|
value
|
|
341
|
-
}), [getTabElementBySelectedValue, getTabIdByPanelValue, getTabPanelIdByValue, onValueChange, orientation, registerMountedTabPanel, setTabMap, tabActivationDirection, value]), selectedTabMetadata =
|
|
140
|
+
}), [getTabElementBySelectedValue, getTabIdByPanelValue, getTabPanelIdByValue, onValueChange, orientation, registerMountedTabPanel, setTabMap, tabActivationDirection, value]), selectedTabMetadata = React2.useMemo(() => {
|
|
342
141
|
for (let tabMetadata of tabMap.values())
|
|
343
142
|
if (tabMetadata.value === value)
|
|
344
143
|
return tabMetadata;
|
|
345
|
-
}, [tabMap, value]), firstEnabledTabValue =
|
|
144
|
+
}, [tabMap, value]), firstEnabledTabValue = React2.useMemo(() => {
|
|
346
145
|
for (let tabMetadata of tabMap.values())
|
|
347
146
|
if (!tabMetadata.disabled)
|
|
348
147
|
return tabMetadata.value;
|
|
349
|
-
}, [tabMap]), shouldNotifyInitialValueChangeRef =
|
|
148
|
+
}, [tabMap]), shouldNotifyInitialValueChangeRef = React2.useRef(!hasExplicitDefaultValueProp), initialDefaultValueRef = React2.useRef(defaultValueProp), shouldHonorDisabledDefaultValueRef = React2.useRef(hasExplicitDefaultValueProp), didRegisterTabsRef = React2.useRef(!1);
|
|
350
149
|
useIsoLayoutEffect(() => {
|
|
351
150
|
if (isControlled)
|
|
352
151
|
return;
|
|
@@ -386,9 +185,9 @@ var TabsRoot = React5.forwardRef(function(componentProps, forwardedRef) {
|
|
|
386
185
|
props: elementProps,
|
|
387
186
|
stateAttributesMapping: tabsStateAttributesMapping
|
|
388
187
|
});
|
|
389
|
-
return
|
|
188
|
+
return _jsx(TabsRootContext.Provider, {
|
|
390
189
|
value: tabsContextValue,
|
|
391
|
-
children:
|
|
190
|
+
children: _jsx(CompositeList, {
|
|
392
191
|
elementsRef: tabPanelRefs,
|
|
393
192
|
children: element
|
|
394
193
|
})
|
|
@@ -412,97 +211,21 @@ function computeActivationDirection(oldValue, newValue, orientation, tabMap) {
|
|
|
412
211
|
}
|
|
413
212
|
|
|
414
213
|
// ../../node_modules/@base-ui/react/tabs/tab/TabsTab.mjs
|
|
415
|
-
import * as
|
|
416
|
-
|
|
417
|
-
// ../../node_modules/@base-ui/react/internals/composite/constants.mjs
|
|
418
|
-
var ACTIVE_COMPOSITE_ITEM = "data-composite-item-active";
|
|
419
|
-
|
|
420
|
-
// ../../node_modules/@base-ui/react/internals/composite/item/useCompositeItem.mjs
|
|
421
|
-
import * as React7 from "react";
|
|
422
|
-
|
|
423
|
-
// ../../node_modules/@base-ui/react/internals/composite/list/useCompositeListItem.mjs
|
|
424
|
-
import * as React6 from "react";
|
|
425
|
-
function useCompositeListItem(params = {}) {
|
|
426
|
-
let {
|
|
427
|
-
guess,
|
|
428
|
-
label,
|
|
429
|
-
metadata,
|
|
430
|
-
textRef,
|
|
431
|
-
index: externalIndex
|
|
432
|
-
} = params, {
|
|
433
|
-
register,
|
|
434
|
-
unregister,
|
|
435
|
-
subscribeMapChange,
|
|
436
|
-
nextIndexRef
|
|
437
|
-
} = useCompositeListContext(), indexRef = React6.useRef(-1), [internalIndex, setInternalIndex] = React6.useState(externalIndex == null && guess ? () => {
|
|
438
|
-
if (indexRef.current === -1) {
|
|
439
|
-
let newIndex = nextIndexRef.current;
|
|
440
|
-
nextIndexRef.current += 1, indexRef.current = newIndex;
|
|
441
|
-
}
|
|
442
|
-
return indexRef.current;
|
|
443
|
-
} : -1), index2 = externalIndex ?? internalIndex, componentRef = React6.useRef(null), ref = React6.useCallback((node) => {
|
|
444
|
-
let previousNode = componentRef.current;
|
|
445
|
-
previousNode && unregister(previousNode), componentRef.current = node, node && register(node, {
|
|
446
|
-
metadata: metadata ?? null,
|
|
447
|
-
index: externalIndex ?? null,
|
|
448
|
-
label,
|
|
449
|
-
textRef
|
|
450
|
-
});
|
|
451
|
-
}, [externalIndex, register, unregister, metadata, label, textRef]);
|
|
452
|
-
return useIsoLayoutEffect(() => {
|
|
453
|
-
if (externalIndex == null)
|
|
454
|
-
return subscribeMapChange((map) => {
|
|
455
|
-
let i = componentRef.current ? map.get(componentRef.current)?.index : null;
|
|
456
|
-
i != null && setInternalIndex(i);
|
|
457
|
-
});
|
|
458
|
-
}, [externalIndex, subscribeMapChange]), {
|
|
459
|
-
ref,
|
|
460
|
-
index: index2
|
|
461
|
-
};
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
// ../../node_modules/@base-ui/react/internals/composite/item/useCompositeItem.mjs
|
|
465
|
-
function useCompositeItem(params = {}) {
|
|
466
|
-
let {
|
|
467
|
-
highlightItemOnHover,
|
|
468
|
-
highlightedIndex,
|
|
469
|
-
onHighlightedIndexChange
|
|
470
|
-
} = useCompositeRootContext(), {
|
|
471
|
-
ref,
|
|
472
|
-
index: index2
|
|
473
|
-
} = useCompositeListItem(params), isHighlighted = highlightedIndex === index2, itemRef = React7.useRef(null), mergedRef = useMergedRefs(ref, itemRef);
|
|
474
|
-
return {
|
|
475
|
-
compositeProps: {
|
|
476
|
-
tabIndex: isHighlighted ? 0 : -1,
|
|
477
|
-
onFocus() {
|
|
478
|
-
onHighlightedIndexChange(index2);
|
|
479
|
-
},
|
|
480
|
-
onMouseMove() {
|
|
481
|
-
let item = itemRef.current;
|
|
482
|
-
if (!highlightItemOnHover || !item)
|
|
483
|
-
return;
|
|
484
|
-
let disabled = item.hasAttribute("disabled") || item.ariaDisabled === "true";
|
|
485
|
-
!isHighlighted && !disabled && item.focus();
|
|
486
|
-
}
|
|
487
|
-
},
|
|
488
|
-
compositeRef: mergedRef,
|
|
489
|
-
index: index2
|
|
490
|
-
};
|
|
491
|
-
}
|
|
214
|
+
import * as React4 from "react";
|
|
492
215
|
|
|
493
216
|
// ../../node_modules/@base-ui/react/tabs/list/TabsListContext.mjs
|
|
494
|
-
import * as
|
|
495
|
-
var TabsListContext =
|
|
217
|
+
import * as React3 from "react";
|
|
218
|
+
var TabsListContext = React3.createContext(void 0);
|
|
496
219
|
process.env.NODE_ENV !== "production" && (TabsListContext.displayName = "TabsListContext");
|
|
497
220
|
function useTabsListContext() {
|
|
498
|
-
let context =
|
|
221
|
+
let context = React3.useContext(TabsListContext);
|
|
499
222
|
if (context === void 0)
|
|
500
223
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: TabsListContext is missing. TabsList parts must be placed within <Tabs.List>." : formatErrorMessage_default(65));
|
|
501
224
|
return context;
|
|
502
225
|
}
|
|
503
226
|
|
|
504
227
|
// ../../node_modules/@base-ui/react/tabs/tab/TabsTab.mjs
|
|
505
|
-
var TabsTab =
|
|
228
|
+
var TabsTab = React4.forwardRef(function(componentProps, forwardedRef) {
|
|
506
229
|
let {
|
|
507
230
|
className,
|
|
508
231
|
disabled = !1,
|
|
@@ -525,7 +248,7 @@ var TabsTab = React9.forwardRef(function(componentProps, forwardedRef) {
|
|
|
525
248
|
} = useTabsListContext(), {
|
|
526
249
|
highlightedIndex,
|
|
527
250
|
onHighlightedIndexChange
|
|
528
|
-
} = useCompositeRootContext(), id = useBaseUiId(idProp), tabMetadata =
|
|
251
|
+
} = useCompositeRootContext(), id = useBaseUiId(idProp), tabMetadata = React4.useMemo(() => ({
|
|
529
252
|
disabled,
|
|
530
253
|
id,
|
|
531
254
|
value
|
|
@@ -537,7 +260,7 @@ var TabsTab = React9.forwardRef(function(componentProps, forwardedRef) {
|
|
|
537
260
|
// because the index is needed for Tab internals
|
|
538
261
|
} = useCompositeItem({
|
|
539
262
|
metadata: tabMetadata
|
|
540
|
-
}), active = value === activeTabValue, isNavigatingRef =
|
|
263
|
+
}), active = value === activeTabValue, isNavigatingRef = React4.useRef(!1), unobserveTabElementRef = React4.useRef(null), observeTabElement = useStableCallback((element2) => {
|
|
541
264
|
unobserveTabElementRef.current?.(), unobserveTabElementRef.current = element2 ? registerTabResizeObserverElement(element2) : null;
|
|
542
265
|
});
|
|
543
266
|
useIsoLayoutEffect(() => {
|
|
@@ -562,7 +285,7 @@ var TabsTab = React9.forwardRef(function(componentProps, forwardedRef) {
|
|
|
562
285
|
disabled,
|
|
563
286
|
native: nativeButton,
|
|
564
287
|
focusableWhenDisabled: !0
|
|
565
|
-
}), tabPanelId = getTabPanelIdByValue(value), isPressingRef =
|
|
288
|
+
}), tabPanelId = getTabPanelIdByValue(value), isPressingRef = React4.useRef(!1), isMainButtonRef = React4.useRef(!1);
|
|
566
289
|
function activate(event) {
|
|
567
290
|
onValueChange(value, createChangeEventDetails(reason_parts_exports.none, event.nativeEvent, void 0, {
|
|
568
291
|
activationDirection: "none"
|
|
@@ -612,21 +335,21 @@ var TabsTab = React9.forwardRef(function(componentProps, forwardedRef) {
|
|
|
612
335
|
process.env.NODE_ENV !== "production" && (TabsTab.displayName = "TabsTab");
|
|
613
336
|
|
|
614
337
|
// ../../node_modules/@base-ui/react/tabs/indicator/TabsIndicator.mjs
|
|
615
|
-
import * as
|
|
338
|
+
import * as React8 from "react";
|
|
616
339
|
|
|
617
340
|
// ../../node_modules/@base-ui/react/internals/PrehydrationScript.mjs
|
|
618
341
|
import "react";
|
|
619
342
|
|
|
620
343
|
// ../../node_modules/@base-ui/utils/hydration.mjs
|
|
621
|
-
import * as
|
|
344
|
+
import * as React5 from "react";
|
|
622
345
|
var emptySubscribe = () => () => {
|
|
623
346
|
}, getTrue = () => !0, getFalse = () => !1;
|
|
624
347
|
function useIsHydratedModern() {
|
|
625
348
|
return useSyncExternalStore(emptySubscribe, getTrue, getFalse);
|
|
626
349
|
}
|
|
627
350
|
function useIsHydratedLegacy() {
|
|
628
|
-
let [hydrated, setHydrated] =
|
|
629
|
-
return
|
|
351
|
+
let [hydrated, setHydrated] = React5.useState(!1);
|
|
352
|
+
return React5.useEffect(() => {
|
|
630
353
|
setHydrated(!0);
|
|
631
354
|
}, []), hydrated;
|
|
632
355
|
}
|
|
@@ -636,25 +359,25 @@ function useIsHydrating() {
|
|
|
636
359
|
}
|
|
637
360
|
|
|
638
361
|
// ../../node_modules/@base-ui/react/internals/csp-context/CSPContext.mjs
|
|
639
|
-
import * as
|
|
640
|
-
var CSPContext =
|
|
362
|
+
import * as React6 from "react";
|
|
363
|
+
var CSPContext = React6.createContext(void 0);
|
|
641
364
|
process.env.NODE_ENV !== "production" && (CSPContext.displayName = "CSPContext");
|
|
642
365
|
var DEFAULT_CSP_CONTEXT_VALUE = {
|
|
643
366
|
disableStyleElements: !1
|
|
644
367
|
};
|
|
645
368
|
function useCSPContext() {
|
|
646
|
-
return
|
|
369
|
+
return React6.useContext(CSPContext) ?? DEFAULT_CSP_CONTEXT_VALUE;
|
|
647
370
|
}
|
|
648
371
|
|
|
649
372
|
// ../../node_modules/@base-ui/react/internals/PrehydrationScript.mjs
|
|
650
|
-
import { jsx as
|
|
373
|
+
import { jsx as _jsx2 } from "react/jsx-runtime";
|
|
651
374
|
function PrehydrationScript(props) {
|
|
652
375
|
let {
|
|
653
376
|
script: script2
|
|
654
377
|
} = props, {
|
|
655
378
|
nonce
|
|
656
379
|
} = useCSPContext();
|
|
657
|
-
return useIsHydrating() ?
|
|
380
|
+
return useIsHydrating() ? _jsx2("script", {
|
|
658
381
|
nonce,
|
|
659
382
|
dangerouslySetInnerHTML: {
|
|
660
383
|
__html: script2
|
|
@@ -684,12 +407,12 @@ function getElementTransform(element, computedStyle) {
|
|
|
684
407
|
var activeTabLeft = "--active-tab-left", activeTabRight = "--active-tab-right", activeTabTop = "--active-tab-top", activeTabBottom = "--active-tab-bottom", activeTabWidth = "--active-tab-width", activeTabHeight = "--active-tab-height";
|
|
685
408
|
|
|
686
409
|
// ../../node_modules/@base-ui/react/tabs/indicator/TabsIndicator.mjs
|
|
687
|
-
import { jsx as
|
|
410
|
+
import { jsx as _jsx3, jsxs as _jsxs } from "react/jsx-runtime";
|
|
688
411
|
var _PrehydrationScript, stateAttributesMapping = {
|
|
689
412
|
...tabsStateAttributesMapping,
|
|
690
413
|
activeTabPosition: () => null,
|
|
691
414
|
activeTabSize: () => null
|
|
692
|
-
}, MAX_LAYOUT_ROUNDING_ERROR = 2, TabsIndicator =
|
|
415
|
+
}, MAX_LAYOUT_ROUNDING_ERROR = 2, TabsIndicator = React8.forwardRef(function(componentProps, forwardedRef) {
|
|
693
416
|
let {
|
|
694
417
|
className,
|
|
695
418
|
render,
|
|
@@ -705,7 +428,7 @@ var _PrehydrationScript, stateAttributesMapping = {
|
|
|
705
428
|
tabsListElement,
|
|
706
429
|
registerIndicatorUpdateListener
|
|
707
430
|
} = useTabsListContext(), rerender = useForcedRerendering();
|
|
708
|
-
|
|
431
|
+
React8.useEffect(() => registerIndicatorUpdateListener(rerender), [registerIndicatorUpdateListener, rerender]);
|
|
709
432
|
let left = 0, right = 0, top = 0, bottom = 0, width = 0, height = 0, isTabSelected = !1;
|
|
710
433
|
if (value != null && tabsListElement != null) {
|
|
711
434
|
let activeTab = getTabElementBySelectedValue(value);
|
|
@@ -756,8 +479,8 @@ var _PrehydrationScript, stateAttributesMapping = {
|
|
|
756
479
|
}],
|
|
757
480
|
stateAttributesMapping
|
|
758
481
|
});
|
|
759
|
-
return value == null ? null : _jsxs(
|
|
760
|
-
children: [element, renderBeforeHydration && (_PrehydrationScript || (_PrehydrationScript =
|
|
482
|
+
return value == null ? null : _jsxs(React8.Fragment, {
|
|
483
|
+
children: [element, renderBeforeHydration && (_PrehydrationScript || (_PrehydrationScript = _jsx3(PrehydrationScript, {
|
|
761
484
|
script: ""
|
|
762
485
|
})))]
|
|
763
486
|
});
|
|
@@ -808,7 +531,7 @@ function resolveTranslateLength(value, referenceSize) {
|
|
|
808
531
|
}
|
|
809
532
|
|
|
810
533
|
// ../../node_modules/@base-ui/react/tabs/panel/TabsPanel.mjs
|
|
811
|
-
import * as
|
|
534
|
+
import * as React9 from "react";
|
|
812
535
|
|
|
813
536
|
// ../../node_modules/@base-ui/react/tabs/panel/TabsPanelDataAttributes.mjs
|
|
814
537
|
var index = "data-index";
|
|
@@ -818,7 +541,7 @@ var startingStyle = TransitionStatusDataAttributes_exports.startingStyle, ending
|
|
|
818
541
|
var stateAttributesMapping2 = {
|
|
819
542
|
...tabsStateAttributesMapping,
|
|
820
543
|
...transitionStatusMapping
|
|
821
|
-
}, TabsPanel =
|
|
544
|
+
}, TabsPanel = React9.forwardRef(function(componentProps, forwardedRef) {
|
|
822
545
|
let {
|
|
823
546
|
className,
|
|
824
547
|
value,
|
|
@@ -844,7 +567,7 @@ var stateAttributesMapping2 = {
|
|
|
844
567
|
orientation,
|
|
845
568
|
tabActivationDirection,
|
|
846
569
|
transitionStatus
|
|
847
|
-
}, panelRef =
|
|
570
|
+
}, panelRef = React9.useRef(null), element = useRenderElement("div", componentProps, {
|
|
848
571
|
state,
|
|
849
572
|
ref: [forwardedRef, listItemRef, panelRef],
|
|
850
573
|
props: [{
|
|
@@ -873,212 +596,9 @@ var stateAttributesMapping2 = {
|
|
|
873
596
|
process.env.NODE_ENV !== "production" && (TabsPanel.displayName = "TabsPanel");
|
|
874
597
|
|
|
875
598
|
// ../../node_modules/@base-ui/react/tabs/list/TabsList.mjs
|
|
876
|
-
import * as
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
import * as React16 from "react";
|
|
880
|
-
|
|
881
|
-
// ../../node_modules/@base-ui/react/internals/composite/root/useCompositeRoot.mjs
|
|
882
|
-
import * as React15 from "react";
|
|
883
|
-
|
|
884
|
-
// ../../node_modules/@base-ui/utils/isElementDisabled.mjs
|
|
885
|
-
function isElementDisabled(element) {
|
|
886
|
-
return element == null || element.hasAttribute("disabled") || element.getAttribute("aria-disabled") === "true";
|
|
887
|
-
}
|
|
888
|
-
|
|
889
|
-
// ../../node_modules/@base-ui/react/internals/composite/root/useCompositeRoot.mjs
|
|
890
|
-
function useCompositeRoot(params) {
|
|
891
|
-
let {
|
|
892
|
-
loopFocus = !0,
|
|
893
|
-
orientation = "both",
|
|
894
|
-
grid,
|
|
895
|
-
onLoop,
|
|
896
|
-
direction,
|
|
897
|
-
highlightedIndex: externalHighlightedIndex,
|
|
898
|
-
onHighlightedIndexChange: externalSetHighlightedIndex,
|
|
899
|
-
rootRef: externalRef,
|
|
900
|
-
enableHomeAndEndKeys = !1,
|
|
901
|
-
stopEventPropagation,
|
|
902
|
-
disabledIndices,
|
|
903
|
-
modifierKeys = EMPTY_ARRAY
|
|
904
|
-
} = params, [internalHighlightedIndex, internalSetHighlightedIndex] = React15.useState(0), isGrid = grid != null, rootRef = React15.useRef(null), mergedRef = useMergedRefs(rootRef, externalRef), elementsRef = React15.useRef([]), hasSetDefaultIndexRef = React15.useRef(!1), highlightedElementRef = React15.useRef(null), highlightedIndex = externalHighlightedIndex ?? internalHighlightedIndex, onHighlightedIndexChange = useStableCallback((index2, shouldScrollIntoView = !1) => {
|
|
905
|
-
if (highlightedElementRef.current = elementsRef.current[index2] ?? null, (externalSetHighlightedIndex ?? internalSetHighlightedIndex)(index2), shouldScrollIntoView) {
|
|
906
|
-
let newActiveItem = elementsRef.current[index2];
|
|
907
|
-
scrollIntoViewIfNeeded(rootRef.current, newActiveItem, direction, orientation);
|
|
908
|
-
}
|
|
909
|
-
}), onMapChange = useStableCallback((map) => {
|
|
910
|
-
if (map.size === 0)
|
|
911
|
-
return;
|
|
912
|
-
if (hasSetDefaultIndexRef.current) {
|
|
913
|
-
let elements = elementsRef.current, nextIndex = elements.indexOf(highlightedElementRef.current);
|
|
914
|
-
if (nextIndex === -1) {
|
|
915
|
-
let replacement = elements[highlightedIndex];
|
|
916
|
-
!replacement || isListIndexDisabled(elements, highlightedIndex, disabledIndices) ? onHighlightedIndexChange(getFallbackIndex(elements, disabledIndices)) : highlightedElementRef.current = replacement;
|
|
917
|
-
} else nextIndex !== highlightedIndex && onHighlightedIndexChange(nextIndex);
|
|
918
|
-
return;
|
|
919
|
-
}
|
|
920
|
-
hasSetDefaultIndexRef.current = !0;
|
|
921
|
-
let sortedElements = Array.from(map.keys()), activeItem = sortedElements.find((compositeElement) => compositeElement?.hasAttribute(ACTIVE_COMPOSITE_ITEM)) ?? null, activeIndex = activeItem ? map.get(activeItem)?.index ?? -1 : -1;
|
|
922
|
-
if (activeIndex !== -1)
|
|
923
|
-
onHighlightedIndexChange(activeIndex);
|
|
924
|
-
else if (isListIndexDisabled(sortedElements, highlightedIndex, disabledIndices)) {
|
|
925
|
-
let firstEnabledIndex = findNonDisabledListIndex(sortedElements, {
|
|
926
|
-
disabledIndices
|
|
927
|
-
});
|
|
928
|
-
isIndexOutOfListBounds(sortedElements, firstEnabledIndex) || onHighlightedIndexChange(firstEnabledIndex);
|
|
929
|
-
}
|
|
930
|
-
scrollIntoViewIfNeeded(rootRef.current, activeItem, direction, orientation);
|
|
931
|
-
});
|
|
932
|
-
useIsoLayoutEffect(() => {
|
|
933
|
-
if (disabledIndices == null || externalHighlightedIndex != null || !hasSetDefaultIndexRef.current)
|
|
934
|
-
return;
|
|
935
|
-
let elements = elementsRef.current;
|
|
936
|
-
if (isListIndexDisabled(elements, highlightedIndex, disabledIndices)) {
|
|
937
|
-
let firstEnabledIndex = findNonDisabledListIndex(elements, {
|
|
938
|
-
disabledIndices
|
|
939
|
-
});
|
|
940
|
-
isIndexOutOfListBounds(elements, firstEnabledIndex) || onHighlightedIndexChange(firstEnabledIndex);
|
|
941
|
-
}
|
|
942
|
-
}, [disabledIndices, externalHighlightedIndex, highlightedIndex, elementsRef, onHighlightedIndexChange]);
|
|
943
|
-
let wrappedOnLoop = useStableCallback((event, prevIndex, nextIndex) => onLoop ? onLoop(event, prevIndex, nextIndex, elementsRef) : nextIndex), onKeyDown = useStableCallback((event) => {
|
|
944
|
-
let isHomeOrEnd = event.key === HOME || event.key === END;
|
|
945
|
-
if (!COMPOSITE_KEYS.has(event.key) || !enableHomeAndEndKeys && isHomeOrEnd || isModifierKeySet(event, modifierKeys) || !rootRef.current)
|
|
946
|
-
return;
|
|
947
|
-
let isRtl = direction === "rtl", horizontalForwardKey = isRtl ? ARROW_LEFT : ARROW_RIGHT, horizontalBackwardKey = isRtl ? ARROW_RIGHT : ARROW_LEFT, forwardKey = orientation === "vertical" ? ARROW_DOWN : horizontalForwardKey, backwardKey = orientation === "vertical" ? ARROW_UP : horizontalBackwardKey, target = getTarget(event.nativeEvent);
|
|
948
|
-
if (target != null && isNativeInput(target) && !isElementDisabled(target)) {
|
|
949
|
-
let selectionStart = target.selectionStart, selectionEnd = target.selectionEnd, textContent = target.value;
|
|
950
|
-
if (selectionStart == null || event.shiftKey || selectionStart !== selectionEnd || event.key !== backwardKey && selectionStart < textContent.length || event.key !== forwardKey && selectionStart > 0)
|
|
951
|
-
return;
|
|
952
|
-
}
|
|
953
|
-
let nextIndex = highlightedIndex, minIndex = getMinListIndex(elementsRef, disabledIndices), maxIndex = getMaxListIndex(elementsRef, disabledIndices);
|
|
954
|
-
grid != null && (nextIndex = grid({
|
|
955
|
-
disabledIndices,
|
|
956
|
-
elementsRef,
|
|
957
|
-
event,
|
|
958
|
-
highlightedIndex,
|
|
959
|
-
loopFocus,
|
|
960
|
-
maxIndex,
|
|
961
|
-
minIndex,
|
|
962
|
-
onLoop: wrappedOnLoop,
|
|
963
|
-
orientation,
|
|
964
|
-
rtl: isRtl
|
|
965
|
-
}));
|
|
966
|
-
let isForwardKey = orientation !== "vertical" && event.key === horizontalForwardKey || orientation !== "horizontal" && event.key === ARROW_DOWN, isBackwardKey = orientation !== "vertical" && event.key === horizontalBackwardKey || orientation !== "horizontal" && event.key === ARROW_UP;
|
|
967
|
-
enableHomeAndEndKeys && (event.key === HOME ? nextIndex = minIndex : event.key === END && (nextIndex = maxIndex)), nextIndex === highlightedIndex && (isForwardKey || isBackwardKey) && (loopFocus && nextIndex === maxIndex && isForwardKey ? (nextIndex = minIndex, onLoop && (nextIndex = onLoop(event, highlightedIndex, nextIndex, elementsRef))) : loopFocus && nextIndex === minIndex && isBackwardKey ? (nextIndex = maxIndex, onLoop && (nextIndex = onLoop(event, highlightedIndex, nextIndex, elementsRef))) : nextIndex = findNonDisabledListIndex(elementsRef.current, {
|
|
968
|
-
startingIndex: nextIndex,
|
|
969
|
-
decrement: isBackwardKey,
|
|
970
|
-
disabledIndices
|
|
971
|
-
})), nextIndex !== highlightedIndex && !isIndexOutOfListBounds(elementsRef.current, nextIndex) && (stopEventPropagation && event.stopPropagation(), (isGrid || isHomeOrEnd || isForwardKey || isBackwardKey) && event.preventDefault(), onHighlightedIndexChange(nextIndex, !0), queueMicrotask(() => {
|
|
972
|
-
elementsRef.current[nextIndex]?.focus();
|
|
973
|
-
}));
|
|
974
|
-
});
|
|
975
|
-
return {
|
|
976
|
-
props: {
|
|
977
|
-
ref: mergedRef,
|
|
978
|
-
onFocus(event) {
|
|
979
|
-
let element = rootRef.current, target = getTarget(event.nativeEvent);
|
|
980
|
-
!element || target == null || !isNativeInput(target) || target.setSelectionRange(0, target.value.length);
|
|
981
|
-
},
|
|
982
|
-
onKeyDown
|
|
983
|
-
},
|
|
984
|
-
highlightedIndex,
|
|
985
|
-
onHighlightedIndexChange,
|
|
986
|
-
elementsRef,
|
|
987
|
-
onMapChange,
|
|
988
|
-
relayKeyboardEvent: onKeyDown
|
|
989
|
-
};
|
|
990
|
-
}
|
|
991
|
-
function getFallbackIndex(elements, disabledIndices) {
|
|
992
|
-
let fallbackIndex = -1;
|
|
993
|
-
for (let index2 = 0; index2 < elements.length; index2 += 1) {
|
|
994
|
-
let element = elements[index2];
|
|
995
|
-
if (!(!element || isListIndexDisabled(elements, index2, disabledIndices))) {
|
|
996
|
-
if (element.hasAttribute(ACTIVE_COMPOSITE_ITEM))
|
|
997
|
-
return index2;
|
|
998
|
-
fallbackIndex === -1 && (fallbackIndex = index2);
|
|
999
|
-
}
|
|
1000
|
-
}
|
|
1001
|
-
return Math.max(fallbackIndex, 0);
|
|
1002
|
-
}
|
|
1003
|
-
function isModifierKeySet(event, ignoredModifierKeys) {
|
|
1004
|
-
for (let key of MODIFIER_KEYS)
|
|
1005
|
-
if (!ignoredModifierKeys.includes(key) && event.getModifierState(key))
|
|
1006
|
-
return !0;
|
|
1007
|
-
return !1;
|
|
1008
|
-
}
|
|
1009
|
-
|
|
1010
|
-
// ../../node_modules/@base-ui/react/internals/composite/root/CompositeRoot.mjs
|
|
1011
|
-
import { jsx as _jsx5 } from "react/jsx-runtime";
|
|
1012
|
-
function CompositeRoot(componentProps) {
|
|
1013
|
-
let {
|
|
1014
|
-
render,
|
|
1015
|
-
className,
|
|
1016
|
-
style,
|
|
1017
|
-
refs = EMPTY_ARRAY,
|
|
1018
|
-
props = EMPTY_ARRAY,
|
|
1019
|
-
state = EMPTY_OBJECT,
|
|
1020
|
-
stateAttributesMapping: stateAttributesMapping3,
|
|
1021
|
-
highlightedIndex: highlightedIndexProp,
|
|
1022
|
-
onHighlightedIndexChange: onHighlightedIndexChangeProp,
|
|
1023
|
-
orientation,
|
|
1024
|
-
grid,
|
|
1025
|
-
loopFocus,
|
|
1026
|
-
onLoop,
|
|
1027
|
-
enableHomeAndEndKeys,
|
|
1028
|
-
onMapChange: onMapChangeProp,
|
|
1029
|
-
stopEventPropagation = !0,
|
|
1030
|
-
rootRef,
|
|
1031
|
-
disabledIndices,
|
|
1032
|
-
modifierKeys,
|
|
1033
|
-
highlightItemOnHover = !1,
|
|
1034
|
-
tag = "div",
|
|
1035
|
-
...elementProps
|
|
1036
|
-
} = componentProps, direction = useDirection(), {
|
|
1037
|
-
props: defaultProps,
|
|
1038
|
-
highlightedIndex,
|
|
1039
|
-
onHighlightedIndexChange,
|
|
1040
|
-
elementsRef,
|
|
1041
|
-
onMapChange: onMapChangeUnwrapped,
|
|
1042
|
-
relayKeyboardEvent
|
|
1043
|
-
} = useCompositeRoot({
|
|
1044
|
-
grid,
|
|
1045
|
-
loopFocus,
|
|
1046
|
-
onLoop,
|
|
1047
|
-
orientation,
|
|
1048
|
-
highlightedIndex: highlightedIndexProp,
|
|
1049
|
-
onHighlightedIndexChange: onHighlightedIndexChangeProp,
|
|
1050
|
-
rootRef,
|
|
1051
|
-
stopEventPropagation,
|
|
1052
|
-
enableHomeAndEndKeys,
|
|
1053
|
-
direction,
|
|
1054
|
-
disabledIndices,
|
|
1055
|
-
modifierKeys
|
|
1056
|
-
}), element = useRenderElement(tag, componentProps, {
|
|
1057
|
-
state,
|
|
1058
|
-
ref: refs,
|
|
1059
|
-
props: [defaultProps, ...props, elementProps],
|
|
1060
|
-
stateAttributesMapping: stateAttributesMapping3
|
|
1061
|
-
}), contextValue = React16.useMemo(() => ({
|
|
1062
|
-
highlightedIndex,
|
|
1063
|
-
onHighlightedIndexChange,
|
|
1064
|
-
highlightItemOnHover,
|
|
1065
|
-
relayKeyboardEvent
|
|
1066
|
-
}), [highlightedIndex, onHighlightedIndexChange, highlightItemOnHover, relayKeyboardEvent]);
|
|
1067
|
-
return _jsx5(CompositeRootContext.Provider, {
|
|
1068
|
-
value: contextValue,
|
|
1069
|
-
children: _jsx5(CompositeList, {
|
|
1070
|
-
elementsRef,
|
|
1071
|
-
onMapChange: (newMap) => {
|
|
1072
|
-
onMapChangeProp?.(newMap), onMapChangeUnwrapped(newMap);
|
|
1073
|
-
},
|
|
1074
|
-
children: element
|
|
1075
|
-
})
|
|
1076
|
-
});
|
|
1077
|
-
}
|
|
1078
|
-
|
|
1079
|
-
// ../../node_modules/@base-ui/react/tabs/list/TabsList.mjs
|
|
1080
|
-
import { jsx as _jsx6 } from "react/jsx-runtime";
|
|
1081
|
-
var TabsList = React17.forwardRef(function(componentProps, forwardedRef) {
|
|
599
|
+
import * as React10 from "react";
|
|
600
|
+
import { jsx as _jsx4 } from "react/jsx-runtime";
|
|
601
|
+
var TabsList = React10.forwardRef(function(componentProps, forwardedRef) {
|
|
1082
602
|
let {
|
|
1083
603
|
activateOnFocus = !1,
|
|
1084
604
|
className,
|
|
@@ -1090,7 +610,7 @@ var TabsList = React17.forwardRef(function(componentProps, forwardedRef) {
|
|
|
1090
610
|
orientation,
|
|
1091
611
|
setTabMap,
|
|
1092
612
|
tabActivationDirection
|
|
1093
|
-
} = useTabsRootContext(), [highlightedTabIndex, setHighlightedTabIndex] =
|
|
613
|
+
} = useTabsRootContext(), [highlightedTabIndex, setHighlightedTabIndex] = React10.useState(0), [tabsListElement, setTabsListElement] = React10.useState(null), indicatorUpdateListenersRef = React10.useRef(/* @__PURE__ */ new Set()), tabResizeObserverElementsRef = React10.useRef(/* @__PURE__ */ new Set()), resizeObserverRef = React10.useRef(null);
|
|
1094
614
|
useIsoLayoutEffect(() => {
|
|
1095
615
|
if (typeof ResizeObserver > "u")
|
|
1096
616
|
return;
|
|
@@ -1115,15 +635,15 @@ var TabsList = React17.forwardRef(function(componentProps, forwardedRef) {
|
|
|
1115
635
|
}, defaultProps = {
|
|
1116
636
|
"aria-orientation": orientation === "vertical" ? "vertical" : void 0,
|
|
1117
637
|
role: "tablist"
|
|
1118
|
-
}, tabsListContextValue =
|
|
638
|
+
}, tabsListContextValue = React10.useMemo(() => ({
|
|
1119
639
|
activateOnFocus,
|
|
1120
640
|
registerIndicatorUpdateListener,
|
|
1121
641
|
registerTabResizeObserverElement,
|
|
1122
642
|
tabsListElement
|
|
1123
643
|
}), [activateOnFocus, registerIndicatorUpdateListener, registerTabResizeObserverElement, tabsListElement]);
|
|
1124
|
-
return
|
|
644
|
+
return _jsx4(TabsListContext.Provider, {
|
|
1125
645
|
value: tabsListContextValue,
|
|
1126
|
-
children:
|
|
646
|
+
children: _jsx4(CompositeRoot, {
|
|
1127
647
|
render,
|
|
1128
648
|
className,
|
|
1129
649
|
style,
|