@midas-ds/components 14.0.0 → 14.1.0
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/AccordionItem-CAi-XFOc.js +343 -0
- package/AccordionItem-tWS22wDv.cjs +1 -0
- package/{Breadcrumbs-DpUPChG9.cjs → Breadcrumbs-BBDGxc68.cjs} +1 -1
- package/{Breadcrumbs-CV3rVTjR.js → Breadcrumbs-BenPNv8Z.js} +4 -4
- package/Button-1sEX8jKn.cjs +1 -0
- package/{Button-xc8A29pm.cjs → Button-BEWKXjlP.cjs} +1 -1
- package/{Button-CRIYvCRM.js → Button-CF97piBl.js} +1 -1
- package/{Button-B6lxIKPk.js → Button-CGe3Nyos.js} +121 -115
- package/CHANGELOG.md +26 -0
- package/{Card-CfosvMF5.js → Card-DJ8E5Rzd.js} +3 -3
- package/{Card-D2E3gviQ.cjs → Card-Db9xdzJ0.cjs} +1 -1
- package/{CharacterCounter-C-PFKoGg.cjs → CharacterCounter-CTpQ12f7.cjs} +1 -1
- package/{CharacterCounter-DpFONstE.js → CharacterCounter-gbDGfize.js} +2 -2
- package/Checkbox-BgrLxY6P.cjs +1 -0
- package/{Checkbox-Cr3MmHPE.js → Checkbox-CdN1D5pD.js} +94 -90
- package/{CheckboxGroup-DEY3JDEL.js → CheckboxGroup-B1b-6bKq.js} +7 -7
- package/{CheckboxGroup-f9Oa1MhQ.cjs → CheckboxGroup-BfZyy5yU.cjs} +1 -1
- package/{Collection-j_iWeuZo.js → Collection-BkxwF21i.js} +205 -213
- package/Collection-vGO6v3_U.cjs +1 -0
- package/{ColorSchemeSwitch-Cur7zN5_.cjs → ColorSchemeSwitch-BOooU0iy.cjs} +1 -1
- package/{ColorSchemeSwitch-ChFSNntp.js → ColorSchemeSwitch-KjnsdbDr.js} +2 -2
- package/{ComboBox-D7eKe-M5.js → ComboBox-D1ZSZ6m-.js} +254 -246
- package/ComboBox-Dztk_jtC.cjs +1 -0
- package/{DateField-BszKZodr.cjs → DateField-BogEOseq.cjs} +1 -1
- package/{DateField-xyhyDy7u.js → DateField-lsr_1fw4.js} +4 -4
- package/{DateInputDivider-2Wf2hlXA.js → DateInputDivider-CRv3YuXd.js} +191 -188
- package/DateInputDivider-CYqm6PZP.cjs +1 -0
- package/{DateRangePicker-YwKi0ukr.js → DateRangePicker-5k1swaEt.js} +119 -115
- package/DateRangePicker-CgNXWOT6.cjs +6 -0
- package/Dialog-B1N4Ndyx.js +256 -0
- package/{Dialog-DOyFzvUa.js → Dialog-BUAp30Wc.js} +712 -694
- package/Dialog-BgSxz1JW.cjs +1 -0
- package/Dialog-PrnV8KTh.cjs +6 -0
- package/{DragAndDrop-DQ_6tl6K.cjs → DragAndDrop-Cs-V-9ak.cjs} +1 -1
- package/{DragAndDrop-DPRU3Y0Y.js → DragAndDrop-DF0VoPJw.js} +1 -1
- package/{Dropdown-5rmvcHD_.cjs → Dropdown-DBFLb8Tl.cjs} +1 -1
- package/{Dropdown-uC9wc8vd.js → Dropdown-DaARa89l.js} +2 -2
- package/{FieldError-C4WBoCRc.cjs → FieldError-Cimgm8qD.cjs} +1 -1
- package/{FieldError-C4kD4yJZ.js → FieldError-l3xULRa0.js} +3 -3
- package/{FileUpload-01wGpykv.js → FileUpload-CN0HNJ_Y.js} +9 -9
- package/{FileUpload-CTbh7Gic.cjs → FileUpload-DHmsupSe.cjs} +1 -1
- package/Group-B0Wj9pI8.cjs +1 -0
- package/Group-BAd7alBM.js +46 -0
- package/{Heading-CEx2LJyM.js → Heading-CCoGfKQ8.js} +9 -9
- package/{Heading-CUShN98j.cjs → Heading-x7y3xadc.cjs} +1 -1
- package/{InfoBanner-CRSz8DK2.js → InfoBanner-BW3vy9mc.js} +1 -1
- package/{InfoBanner-D_pNj1J2.cjs → InfoBanner-_M_rGQiu.cjs} +1 -1
- package/{Input-CCuE9Sc5.cjs → Input-Bda0PCu5.cjs} +1 -1
- package/{Input-CkTOajNJ.js → Input-CQzv-D9g.js} +3 -3
- package/{Label-CV9p0K2n.js → Label-BGMXsSFb.js} +4 -4
- package/{Label-CkIRTC0_.cjs → Label-CNTODOFg.cjs} +1 -1
- package/Layout-BrEuHajQ.cjs +16 -0
- package/{Layout-IeVrHpT0.js → Layout-JL9l-y7w.js} +62 -63
- package/{Link-BFvUN5Sq.js → Link-BudFjYrw.js} +1 -1
- package/{Link-D2K7bDd3.cjs → Link-BvUSTIip.cjs} +1 -1
- package/{Link-a3Ymcnoa.cjs → Link-DRU6Qzia.cjs} +1 -1
- package/{Link-B9CQXWzE.js → Link-l-nMP-Zd.js} +5 -5
- package/{LinkButton-BCn5gR10.cjs → LinkButton-DGdnbTgR.cjs} +1 -1
- package/{LinkButton-DN3J1Agu.js → LinkButton-DP9W-E32.js} +1 -1
- package/ListBox-TGCxrXIJ.cjs +1 -0
- package/{ListBox-2eEa1l0M.js → ListBox-mOCZvKD4.js} +187 -176
- package/{ListBoxLoadMoreItem-IcGb_XwN.js → ListBoxLoadMoreItem-CLdTe6-z.js} +3 -3
- package/{ListBoxLoadMoreItem-BBE3OF4J.cjs → ListBoxLoadMoreItem-UX0jFQN4.cjs} +1 -1
- package/ListBoxSection-BNBHosou.cjs +1 -0
- package/{ListBoxSection-dksiACMZ.js → ListBoxSection-D_kTkvgG.js} +139 -140
- package/{ListKeyboardDelegate-Dyu4eFtP.js → ListKeyboardDelegate-BHnZMUhW.js} +36 -40
- package/ListKeyboardDelegate-CLRlDto7.cjs +1 -0
- package/{OverlayArrow-Bh_G2tJ3.js → OverlayArrow-CjGslX2c.js} +2 -2
- package/{OverlayArrow-DJ4nNscD.cjs → OverlayArrow-bcrb_syE.cjs} +1 -1
- package/{Popover-D7_IfJ3o.js → Popover-CZFi2YGz.js} +2 -2
- package/{Popover-BI2Koco0.cjs → Popover-uYTWBGHa.cjs} +1 -1
- package/{PressResponder-DUhG97jJ.js → PressResponder-BMj6Zvbn.js} +3 -3
- package/{PressResponder-AXK2I_yx.cjs → PressResponder-ChvCuOue.cjs} +1 -1
- package/{ProgressBar-B-TOuoAC.cjs → ProgressBar-BGemuJIq.cjs} +1 -1
- package/{ProgressBar-B0WEQkyq.js → ProgressBar-DhRmckYM.js} +2 -2
- package/{RSPContexts-BW2SEIqe.js → RSPContexts-B0lEq7qq.js} +5 -3
- package/RSPContexts-XUvspq3j.cjs +1 -0
- package/Radio-Bp_31Z59.js +340 -0
- package/Radio-D3RGVrEd.cjs +1 -0
- package/{RangeCalendar-D5TMu8GI.js → RangeCalendar-9C96gMvy.js} +58 -58
- package/{RangeCalendar-B6zKSDju.cjs → RangeCalendar-ChfmP_ql.cjs} +2 -2
- package/{SearchField-wojUSY2S.js → SearchField-DrEdzWAy.js} +3 -3
- package/{SearchField-DnBBlPT7.cjs → SearchField-JaDXLq5W.cjs} +1 -1
- package/Select-BCUH-Z7q.cjs +1 -0
- package/Select-CpPE78Ke.js +676 -0
- package/SelectionIndicator-BiSN1toV.cjs +1 -0
- package/{FocusScope-8ILtcq9W.js → SelectionIndicator-ant6jeC1.js} +256 -165
- package/SelectionManager-C469yQeD.js +1063 -0
- package/SelectionManager-uFYC4wpu.cjs +1 -0
- package/{Separator--4b7vckr.js → Separator-B6l5qSpR.js} +2 -2
- package/{Separator-COlhRmJF.js → Separator-BWAnBMVN.js} +4 -4
- package/{Separator-DcbM84B8.cjs → Separator-DbhmtwDa.cjs} +1 -1
- package/{Separator-BQkxEZC9.cjs → Separator-J0pLW4BN.cjs} +1 -1
- package/Spinner-D6Fcu_Dp.js +54 -0
- package/Spinner-DIapnvIz.cjs +6 -0
- package/TabList-C0tRVI6Q.cjs +1 -0
- package/TabList-DmkxO7MM.js +394 -0
- package/Table-BLqjyYKk.cjs +16 -0
- package/{Table-cCSOrPkK.js → Table-CyWZO9uf.js} +707 -703
- package/Tag-DJqYiBLR.js +774 -0
- package/Tag-FDHGu_WP.cjs +1 -0
- package/{Text-CkhG15SU.cjs → Text-0wXj3J8E.cjs} +1 -1
- package/{Text-BQe1I4-r.js → Text-BBFWBNAH.js} +1 -1
- package/{Text-CkhZTTV5.cjs → Text-D5OSv6Uv.cjs} +1 -1
- package/{Text-BpERRete.js → Text-bqP9NeVg.js} +1 -1
- package/{TextArea-B5TsyJxa.cjs → TextArea-CZxwvBcS.cjs} +1 -1
- package/{TextArea-Cado2arG.js → TextArea-CrY7P18c.js} +8 -8
- package/{TextField-5AI6T1ol.js → TextField-BWea-IT-.js} +10 -10
- package/TextField-DsN-kBfh.cjs +1 -0
- package/{Toast-Cs-Uvf1p.cjs → Toast-DUZ5jfG1.cjs} +1 -1
- package/{Toast-CgXRE33Y.js → Toast-Di3h8A14.js} +12 -12
- package/{ToggleButtonGroup-SKGgfFs4.js → ToggleButtonGroup-Bh4hP6Lk.js} +82 -78
- package/ToggleButtonGroup-D7r34GCt.cjs +1 -0
- package/{Tooltip-txk48Qof.js → Tooltip-CUdmOznK.js} +4 -4
- package/{Tooltip-BrupFzaI.cjs → Tooltip-D-ATlbIM.cjs} +1 -1
- package/{VisuallyHidden-Awup6QxT.cjs → VisuallyHidden-BMelU6B0.cjs} +1 -1
- package/{VisuallyHidden-D2ZXHTJs.js → VisuallyHidden-DuW70K-5.js} +1 -1
- package/accordion/index.cjs +1 -1
- package/accordion/index.js +1 -1
- package/assets/AccordionItem.css +1 -1
- package/assets/RangeCalendar.css +1 -1
- package/assets/Spinner.css +1 -1
- package/assets/TabList.css +1 -1
- package/assets/default.css +1 -1
- package/breadcrumbs/index.cjs +1 -1
- package/breadcrumbs/index.js +1 -1
- package/button/index.cjs +1 -1
- package/button/index.js +1 -1
- package/calendar/index.cjs +1 -1
- package/calendar/index.js +1 -1
- package/card/index.cjs +1 -1
- package/card/index.js +1 -1
- package/character-counter/index.cjs +1 -1
- package/character-counter/index.js +1 -1
- package/checkbox/index.cjs +1 -1
- package/checkbox/index.js +2 -2
- package/color-scheme-switch/index.cjs +1 -1
- package/color-scheme-switch/index.js +1 -1
- package/combobox/index.cjs +1 -1
- package/combobox/index.js +1 -1
- package/date-field/index.cjs +1 -1
- package/date-field/index.js +2 -2
- package/date-picker/index.cjs +1 -1
- package/date-picker/index.js +1 -1
- package/dropdown/index.cjs +1 -1
- package/dropdown/index.js +1 -1
- package/field-error/index.cjs +1 -1
- package/field-error/index.js +1 -1
- package/file-upload/index.cjs +1 -1
- package/file-upload/index.js +1 -1
- package/{getScrollParent-Ru2U2LlM.js → getScrollParent-DFCzfqHG.js} +1 -1
- package/{getScrollParent-DuKmPmUa.cjs → getScrollParent-DjULaF_q.cjs} +1 -1
- package/heading/index.cjs +1 -1
- package/heading/index.js +1 -1
- package/index.cjs +1 -1
- package/index.js +42 -42
- package/info-banner/index.cjs +1 -1
- package/info-banner/index.js +1 -1
- package/label/index.cjs +1 -1
- package/label/index.js +1 -1
- package/layout/index.cjs +1 -1
- package/layout/index.js +1 -1
- package/link/index.cjs +1 -1
- package/link/index.js +2 -2
- package/link-button/index.cjs +1 -1
- package/link-button/index.js +2 -2
- package/list-box/index.cjs +1 -1
- package/list-box/index.js +2 -2
- package/menu/index.cjs +1 -1
- package/menu/index.js +2 -2
- package/modal/index.cjs +1 -1
- package/modal/index.js +2 -2
- package/package.json +4 -4
- package/popover/index.cjs +1 -1
- package/popover/index.js +1 -1
- package/progress-bar/index.cjs +1 -1
- package/progress-bar/index.js +1 -1
- package/radio/index.cjs +1 -1
- package/radio/index.js +1 -1
- package/scrollIntoView-BVI21Y4-.js +65 -0
- package/scrollIntoView-BueMOyGp.cjs +1 -0
- package/search-field/index.cjs +1 -1
- package/search-field/index.js +1 -1
- package/select/index.cjs +1 -1
- package/select/index.js +1 -1
- package/select/types.d.ts +1 -1
- package/select/useMultiSelect.d.ts +2 -2
- package/spinner/Spinner.d.ts +5 -1
- package/spinner/index.cjs +1 -1
- package/spinner/index.js +1 -1
- package/table/index.cjs +1 -1
- package/table/index.js +1 -1
- package/tabs/Tabs.d.ts +2 -9
- package/tabs/index.cjs +1 -1
- package/tabs/index.d.ts +0 -1
- package/tabs/index.js +1 -1
- package/tag/index.cjs +1 -1
- package/tag/index.js +1 -1
- package/text/index.cjs +1 -1
- package/text/index.js +1 -1
- package/textfield/TextArea.d.ts +3 -2
- package/textfield/TextField.d.ts +3 -2
- package/textfield/index.cjs +1 -1
- package/textfield/index.js +1 -1
- package/toast/index.cjs +1 -1
- package/toast/index.js +1 -1
- package/toggle-button/index.cjs +1 -1
- package/toggle-button/index.js +1 -1
- package/tooltip/index.cjs +1 -1
- package/tooltip/index.js +1 -1
- package/{useButton-Bh3duhYL.cjs → useButton-C0r5nrqs.cjs} +1 -1
- package/{useButton-A-VOfwuT.js → useButton-CRgN6aZf.js} +2 -2
- package/useDateFormatter-BrrFo4nY.cjs +1 -0
- package/{useDateFormatter-CxlJTAki.js → useDateFormatter-Bs5A6Xtu.js} +353 -322
- package/{useField-sSWPm-He.js → useField-BhJ9dM2g.js} +1 -1
- package/{useField-CY4OYE5a.cjs → useField-DvszkIMx.cjs} +1 -1
- package/{useFilter-DHcouDzv.js → useFilter-BdUU-HQZ.js} +1 -1
- package/{useFilter-DlZLqsJD.cjs → useFilter-R2IPvbS8.cjs} +1 -1
- package/{useFocusRing-Cig5Y0l-.cjs → useFocusRing-C-XVcAE5.cjs} +1 -1
- package/{useFocusRing-Copf_tx8.js → useFocusRing-CcxI7nbg.js} +2 -2
- package/{useFocusWithin-BKopz9sr.js → useFocusWithin-DhXBuB2O.js} +1 -1
- package/{useFocusWithin-TryC2Kkw.cjs → useFocusWithin-GBjoTL5o.cjs} +1 -1
- package/{useFocusable-CCh54GIw.js → useFocusable-BJj-Bkig.js} +3 -3
- package/{useFocusable-DhdAtEw8.cjs → useFocusable-M4se1KJt.cjs} +1 -1
- package/{useFormValidation-DdIIVZ5j.js → useFormValidation-By7G-T7y.js} +1 -1
- package/{useFormValidation-BJNizNDf.cjs → useFormValidation-DV2Ioblb.cjs} +1 -1
- package/useHasTabbableChild-CIZGg_iG.cjs +1 -0
- package/{useHasTabbableChild-BbgOpdGQ.js → useHasTabbableChild-CnpSoDuJ.js} +1 -1
- package/{useHighlightSelectionDescription-D6F-YO6b.cjs → useHighlightSelectionDescription-CBZfyrhy.cjs} +1 -1
- package/{useHighlightSelectionDescription-BL_02EKv.js → useHighlightSelectionDescription-DPiqOr_Z.js} +2 -2
- package/{useHover-eU40luVI.cjs → useHover-DULSfLuK.cjs} +1 -1
- package/{useHover-zCCNtF6g.js → useHover-DkC5FyNd.js} +4 -4
- package/{useListState-BdC308Sq.cjs → useListState-DBawAMhF.cjs} +1 -1
- package/{useListState-D2yPZrFZ.js → useListState-PZF3ahpk.js} +1 -1
- package/{usePress-4yZ5a87p.js → usePress-BqQIhkNY.js} +43 -43
- package/usePress-DmU79HEg.cjs +7 -0
- package/{useSingleSelectListState-lyai-bC_.js → useSingleSelectListState-BLRBEJC7.js} +1 -1
- package/{useSingleSelectListState-b_SPhYG4.cjs → useSingleSelectListState-CNETmoj5.cjs} +1 -1
- package/{useTextField-DjxrmW7d.js → useTextField-B8pM0p6X.js} +4 -4
- package/{useTextField-DUEQl6sr.cjs → useTextField-CiWV3eeD.cjs} +1 -1
- package/utils/types.d.ts +5 -0
- package/utils-CtICjCYt.cjs +1 -0
- package/{utils-BMBoiyL7.js → utils-D2iKpxcZ.js} +43 -39
- package/utils-DRIRjPUS.cjs +1 -0
- package/{utils-CrT5PVBA.js → utils-Dxh86KaB.js} +19 -17
- package/AccordionItem-BJw5IKe0.js +0 -334
- package/AccordionItem-DhMimhYo.cjs +0 -1
- package/Button-BTX5G3le.cjs +0 -1
- package/Checkbox-D-CFY6QF.cjs +0 -1
- package/Collection-DaZzboRu.cjs +0 -1
- package/ComboBox-C4NybZ32.cjs +0 -1
- package/DateInputDivider-BgXKFwB0.cjs +0 -1
- package/DateRangePicker-DTPkr3hX.cjs +0 -6
- package/Dialog-DLnopN3Z.js +0 -237
- package/Dialog-DNu42oLH.cjs +0 -1
- package/Dialog-w6EBWT__.cjs +0 -1
- package/FocusScope-Dv0F-mG2.cjs +0 -1
- package/Group-C2hEIsGV.js +0 -45
- package/Group-cuyk9Hsy.cjs +0 -1
- package/Layout-CVnlO10z.cjs +0 -16
- package/ListBox-Bx9M5vqb.cjs +0 -1
- package/ListBoxSection-kujY2gUl.cjs +0 -1
- package/ListKeyboardDelegate-DJDPir-w.cjs +0 -1
- package/RSPContexts-D8hmBfGm.cjs +0 -1
- package/Radio-D6KNkSA2.js +0 -333
- package/Radio-DsVsutMH.cjs +0 -1
- package/Select-D9h_RQ2k.cjs +0 -1
- package/Select-Dc6y8gPR.js +0 -654
- package/SelectionManager-D-4ThfPZ.js +0 -1043
- package/SelectionManager-FYrDfe5v.cjs +0 -1
- package/Spinner-CTha503N.js +0 -47
- package/Spinner-DKQ9_SQB.cjs +0 -6
- package/TabList-BhC96APe.cjs +0 -1
- package/TabList-P5HnizZt.js +0 -393
- package/Table-BB8Ag5_3.cjs +0 -16
- package/Tag-D2vh0KRD.js +0 -765
- package/Tag-D32MGLjS.cjs +0 -1
- package/TextField-4xfAzdBI.cjs +0 -1
- package/ToggleButtonGroup-CiX2eXB8.cjs +0 -1
- package/scrollIntoView-ClEACHUk.js +0 -57
- package/scrollIntoView-DRSoJp89.cjs +0 -1
- package/useDateFormatter-D0bVjgIb.cjs +0 -1
- package/useHasTabbableChild-wH3RCjTd.cjs +0 -1
- package/useObserveElement-BdI4zgd7.js +0 -27
- package/useObserveElement-BzEr5D32.cjs +0 -1
- package/usePress-Dj3t18Pf.cjs +0 -7
- package/utils-I-LGXGYH.cjs +0 -1
- package/utils-cBvgilDa.cjs +0 -1
- package/variables-B3KEYyhW.cjs +0 -1
- package/variables-DzXcMW2k.js +0 -5
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { a as
|
|
3
|
-
import { g as
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import { $ as
|
|
7
|
-
import { flushSync as
|
|
8
|
-
import { g as
|
|
9
|
-
import { $ as
|
|
10
|
-
import { c as
|
|
11
|
-
import { f as
|
|
12
|
-
import { b as
|
|
13
|
-
import { e as
|
|
14
|
-
import './assets/ListBoxSection.css';class
|
|
1
|
+
import { jsx as C, jsxs as le } from "react/jsx-runtime";
|
|
2
|
+
import { a as oe, b as ne, c as se } from "./ListBox-mOCZvKD4.js";
|
|
3
|
+
import { g as re, m as ae } from "./Collection-BkxwF21i.js";
|
|
4
|
+
import m, { useState as S, useRef as _, useMemo as k, useCallback as L, useEffect as he, createContext as X, useContext as A } from "react";
|
|
5
|
+
import { d as de, $ as P } from "./mergeProps-Ct8m5-xW.js";
|
|
6
|
+
import { $ as F } from "./context-Dl_saGB6.js";
|
|
7
|
+
import { flushSync as O } from "react-dom";
|
|
8
|
+
import { g as ce } from "./OverlayArrow-CjGslX2c.js";
|
|
9
|
+
import { $ as ue } from "./useEvent-smuTnX4G.js";
|
|
10
|
+
import { c as B } from "./clsx-jbLnTBqA.js";
|
|
11
|
+
import { f as Y } from "./SelectionManager-C469yQeD.js";
|
|
12
|
+
import { b as fe } from "./Dialog-BUAp30Wc.js";
|
|
13
|
+
import { e as ge } from "./Separator-BWAnBMVN.js";
|
|
14
|
+
import './assets/ListBoxSection.css';class ye {
|
|
15
15
|
/**
|
|
16
16
|
* Returns whether the layout should invalidate in response to
|
|
17
17
|
* visible rectangle changes. By default, it only invalidates
|
|
@@ -204,12 +204,12 @@ class f {
|
|
|
204
204
|
this.x = e, this.y = t, this.width = i, this.height = l;
|
|
205
205
|
}
|
|
206
206
|
}
|
|
207
|
-
class
|
|
207
|
+
class z {
|
|
208
208
|
/**
|
|
209
209
|
* Returns a copy of this size.
|
|
210
210
|
*/
|
|
211
211
|
copy() {
|
|
212
|
-
return new
|
|
212
|
+
return new z(this.width, this.height);
|
|
213
213
|
}
|
|
214
214
|
/**
|
|
215
215
|
* Returns whether this size is equal to another one.
|
|
@@ -227,8 +227,8 @@ class H {
|
|
|
227
227
|
this.width = Math.max(e, 0), this.height = Math.max(t, 0);
|
|
228
228
|
}
|
|
229
229
|
}
|
|
230
|
-
let
|
|
231
|
-
class
|
|
230
|
+
let ve = 0;
|
|
231
|
+
class j {
|
|
232
232
|
/**
|
|
233
233
|
* Prepares the view for reuse. Called just before the view is removed from the DOM.
|
|
234
234
|
*/
|
|
@@ -237,7 +237,7 @@ class G {
|
|
|
237
237
|
}
|
|
238
238
|
getReusableView(e) {
|
|
239
239
|
let t = this.reusableViews.get(e);
|
|
240
|
-
return t && t.length > 0 ? t.shift() : new
|
|
240
|
+
return t && t.length > 0 ? t.shift() : new me(this.virtualizer, this, e);
|
|
241
241
|
}
|
|
242
242
|
reuseChild(e) {
|
|
243
243
|
e.prepareForReuse();
|
|
@@ -245,27 +245,27 @@ class G {
|
|
|
245
245
|
t || (t = [], this.reusableViews.set(e.viewType, t)), t.push(e);
|
|
246
246
|
}
|
|
247
247
|
constructor(e, t) {
|
|
248
|
-
this.virtualizer = e, this.key = ++
|
|
248
|
+
this.virtualizer = e, this.key = ++ve, this.viewType = t, this.children = /* @__PURE__ */ new Set(), this.reusableViews = /* @__PURE__ */ new Map(), this.layoutInfo = null, this.content = null, this.rendered = null;
|
|
249
249
|
}
|
|
250
250
|
}
|
|
251
|
-
class
|
|
251
|
+
class pe extends j {
|
|
252
252
|
constructor(e) {
|
|
253
253
|
super(e, "root");
|
|
254
254
|
}
|
|
255
255
|
}
|
|
256
|
-
class
|
|
256
|
+
class me extends j {
|
|
257
257
|
constructor(e, t, i) {
|
|
258
258
|
super(e, i), this.parent = t;
|
|
259
259
|
}
|
|
260
260
|
}
|
|
261
|
-
function
|
|
261
|
+
function we(n, e) {
|
|
262
262
|
if (n === e) return !0;
|
|
263
263
|
if (n.size !== e.size) return !1;
|
|
264
264
|
for (let t of n)
|
|
265
265
|
if (!e.has(t)) return !1;
|
|
266
266
|
return !0;
|
|
267
267
|
}
|
|
268
|
-
class
|
|
268
|
+
class be {
|
|
269
269
|
setVisibleRect(e) {
|
|
270
270
|
let t = performance.now() - this.startTime;
|
|
271
271
|
t < 500 && (e.x !== this.visibleRect.x && t > 0 && (this.velocity.x = (e.x - this.visibleRect.x) / t), e.y !== this.visibleRect.y && t > 0 && (this.velocity.y = (e.y - this.visibleRect.y) / t)), this.startTime = performance.now(), this.visibleRect = e;
|
|
@@ -282,7 +282,7 @@ class xe {
|
|
|
282
282
|
this.startTime = 0, this.velocity = new x(0, 0), this.visibleRect = new f();
|
|
283
283
|
}
|
|
284
284
|
}
|
|
285
|
-
class
|
|
285
|
+
class xe {
|
|
286
286
|
/** Returns whether the given key, or an ancestor, is persisted. */
|
|
287
287
|
isPersistedKey(e) {
|
|
288
288
|
if (this.persistedKeys.has(e)) return !0;
|
|
@@ -363,7 +363,7 @@ class Ie {
|
|
|
363
363
|
/** Performs layout and updates visible views as needed. */
|
|
364
364
|
render(e) {
|
|
365
365
|
let t = this, i = !1, l = !1, o = !1, s = !1, a = !1, h = !1;
|
|
366
|
-
return e.collection !== this.collection && (t.collection = e.collection, i = !0), (e.layout !== this.layout || this.layout.virtualizer !== this) && (this.layout && (this.layout.virtualizer = null), e.layout.virtualizer = this, t.layout = e.layout, i = !0), e.persistedKeys && !
|
|
366
|
+
return e.collection !== this.collection && (t.collection = e.collection, i = !0), (e.layout !== this.layout || this.layout.virtualizer !== this) && (this.layout && (this.layout.virtualizer = null), e.layout.virtualizer = this, t.layout = e.layout, i = !0), e.persistedKeys && !we(e.persistedKeys, this.persistedKeys) && (t.persistedKeys = e.persistedKeys, h = !0), this.visibleRect.equals(e.visibleRect) || (this._overscanManager.setVisibleRect(e.visibleRect), this.layout.shouldInvalidate(e.visibleRect, this.visibleRect) ? (l = !e.visibleRect.pointEquals(this.visibleRect), o = !e.visibleRect.sizeEquals(this.visibleRect), i = !0) : h = !0, t.visibleRect = e.visibleRect), e.invalidationContext !== this._invalidationContext && (e.invalidationContext && (o || (o = e.invalidationContext.sizeChanged || !1), l || (l = e.invalidationContext.offsetChanged || !1), s || (s = e.invalidationContext.itemSizeChanged || !1), a || (a = e.invalidationContext.layoutOptions != null && this._invalidationContext.layoutOptions != null && e.invalidationContext.layoutOptions !== this._invalidationContext.layoutOptions && this.layout.shouldInvalidateLayoutOptions(e.invalidationContext.layoutOptions, this._invalidationContext.layoutOptions)), i || (i = s || o || l || a)), this._invalidationContext = e.invalidationContext), e.isScrolling !== this._isScrolling && (this._isScrolling = e.isScrolling, e.isScrolling || (h = !0)), i ? this.relayout({
|
|
367
367
|
offsetChanged: l,
|
|
368
368
|
sizeChanged: o,
|
|
369
369
|
itemSizeChanged: s,
|
|
@@ -384,11 +384,13 @@ class Ie {
|
|
|
384
384
|
});
|
|
385
385
|
}
|
|
386
386
|
constructor(e) {
|
|
387
|
-
this.delegate = e.delegate, this.collection = e.collection, this.layout = e.layout, this.contentSize = new
|
|
387
|
+
this.delegate = e.delegate, this.collection = e.collection, this.layout = e.layout, this.contentSize = new z(), this.visibleRect = new f(), this.persistedKeys = /* @__PURE__ */ new Set(), this._visibleViews = /* @__PURE__ */ new Map(), this._renderedContent = /* @__PURE__ */ new WeakMap(), this._rootView = new pe(this), this._isScrolling = !1, this._invalidationContext = {}, this._overscanManager = new be();
|
|
388
388
|
}
|
|
389
389
|
}
|
|
390
|
+
const Ie = typeof document < "u" ? m.useLayoutEffect : () => {
|
|
391
|
+
};
|
|
390
392
|
function Re(n) {
|
|
391
|
-
let [e, t] =
|
|
393
|
+
let [e, t] = S(new f(0, 0, 0, 0)), [i, l] = S(!1), [o, s] = S({}), a = _(!1), [h] = S(() => new xe({
|
|
392
394
|
collection: n.collection,
|
|
393
395
|
layout: n.layout,
|
|
394
396
|
delegate: {
|
|
@@ -400,10 +402,10 @@ function Re(n) {
|
|
|
400
402
|
invalidate: s
|
|
401
403
|
}
|
|
402
404
|
}));
|
|
403
|
-
|
|
405
|
+
Ie(() => {
|
|
404
406
|
a.current && (a.current = !1, n.onVisibleRectChange(e));
|
|
405
407
|
});
|
|
406
|
-
let r =
|
|
408
|
+
let r = k(() => n.layoutOptions != null ? {
|
|
407
409
|
...o,
|
|
408
410
|
layoutOptions: n.layoutOptions
|
|
409
411
|
} : o, [
|
|
@@ -417,19 +419,19 @@ function Re(n) {
|
|
|
417
419
|
visibleRect: e,
|
|
418
420
|
invalidationContext: r,
|
|
419
421
|
isScrolling: i
|
|
420
|
-
}), c = h.contentSize, u =
|
|
422
|
+
}), c = h.contentSize, u = L(() => {
|
|
421
423
|
l(!0);
|
|
422
|
-
}, []),
|
|
424
|
+
}, []), y = L(() => {
|
|
423
425
|
l(!1);
|
|
424
426
|
}, []);
|
|
425
|
-
return
|
|
427
|
+
return k(() => ({
|
|
426
428
|
virtualizer: h,
|
|
427
429
|
visibleViews: d,
|
|
428
430
|
setVisibleRect: t,
|
|
429
431
|
contentSize: c,
|
|
430
432
|
isScrolling: i,
|
|
431
433
|
startScrolling: u,
|
|
432
|
-
endScrolling:
|
|
434
|
+
endScrolling: y
|
|
433
435
|
}), [
|
|
434
436
|
h,
|
|
435
437
|
d,
|
|
@@ -437,11 +439,11 @@ function Re(n) {
|
|
|
437
439
|
c,
|
|
438
440
|
i,
|
|
439
441
|
u,
|
|
440
|
-
|
|
442
|
+
y
|
|
441
443
|
]);
|
|
442
444
|
}
|
|
443
445
|
const R = 48;
|
|
444
|
-
class
|
|
446
|
+
class $e extends ye {
|
|
445
447
|
// Backward compatibility for subclassing.
|
|
446
448
|
get collection() {
|
|
447
449
|
return this.virtualizer.collection;
|
|
@@ -525,17 +527,17 @@ class Se extends ve {
|
|
|
525
527
|
}
|
|
526
528
|
if ((r.type === "item" || r.type === "loader") && e > this.requestedRect.maxY) {
|
|
527
529
|
let u = i.indexOf(r);
|
|
528
|
-
for (let
|
|
529
|
-
let
|
|
530
|
-
e += (
|
|
531
|
-
let v = this.buildChild(
|
|
532
|
-
o.push(v), e = v.layoutInfo.rect.maxY, u =
|
|
530
|
+
for (let y of l) {
|
|
531
|
+
let g = i.indexOf(y);
|
|
532
|
+
e += (g - u - 1) * d;
|
|
533
|
+
let v = this.buildChild(y, this.padding, e, null);
|
|
534
|
+
o.push(v), e = v.layoutInfo.rect.maxY, u = g;
|
|
533
535
|
}
|
|
534
536
|
e += (i.length - u - 1) * d;
|
|
535
537
|
break;
|
|
536
538
|
}
|
|
537
539
|
}
|
|
538
|
-
return e -= this.gap, e += s ? 0 : this.padding, this.contentSize = new
|
|
540
|
+
return e -= this.gap, e += s ? 0 : this.padding, this.contentSize = new z(this.virtualizer.visibleRect.width, e), o;
|
|
539
541
|
}
|
|
540
542
|
isValid(e, t) {
|
|
541
543
|
let i = this.layoutNodes.get(e.key);
|
|
@@ -573,18 +575,18 @@ class Se extends ve {
|
|
|
573
575
|
}
|
|
574
576
|
buildSection(e, t, i) {
|
|
575
577
|
let l = this.virtualizer.collection, o = this.virtualizer.visibleRect.width - this.padding, s = new f(t, i, o - t, 0), a = new b(e.type, e.key, s), h = i, r = 0, d = [];
|
|
576
|
-
for (let
|
|
578
|
+
for (let y of Y(e, l)) {
|
|
577
579
|
var c, u;
|
|
578
|
-
let
|
|
579
|
-
if (i +
|
|
580
|
-
i +=
|
|
580
|
+
let g = ((u = (c = this.rowHeight) !== null && c !== void 0 ? c : this.estimatedRowHeight) !== null && u !== void 0 ? u : R) + this.gap;
|
|
581
|
+
if (i + g < this.requestedRect.y && !this.isValid(e, i)) {
|
|
582
|
+
i += g, r++;
|
|
581
583
|
continue;
|
|
582
584
|
}
|
|
583
|
-
let v = this.buildChild(
|
|
585
|
+
let v = this.buildChild(y, t, i, a.key);
|
|
584
586
|
if (i = v.layoutInfo.rect.maxY + this.gap, d.push(v), i > this.requestedRect.maxY) {
|
|
585
587
|
i += ([
|
|
586
|
-
...
|
|
587
|
-
].length - (d.length + r)) *
|
|
588
|
+
...Y(e, l)
|
|
589
|
+
].length - (d.length + r)) * g;
|
|
588
590
|
break;
|
|
589
591
|
}
|
|
590
592
|
}
|
|
@@ -655,8 +657,8 @@ class Se extends ve {
|
|
|
655
657
|
let l = new f(e, Math.max(0, t - this.gap), 1, Math.max(1, this.gap * 2)), o = this.getVisibleLayoutInfos(l), s = null, a = 1 / 0;
|
|
656
658
|
for (let c of o) {
|
|
657
659
|
if (!c.rect.intersects(l)) continue;
|
|
658
|
-
let u = Math.abs(c.rect.y - t),
|
|
659
|
-
|
|
660
|
+
let u = Math.abs(c.rect.y - t), y = Math.abs(c.rect.maxY - t), g = Math.min(u, y);
|
|
661
|
+
g < a && (a = g, s = c.key);
|
|
660
662
|
}
|
|
661
663
|
if (s == null || this.virtualizer.collection.size === 0) return {
|
|
662
664
|
type: "root"
|
|
@@ -715,24 +717,24 @@ class Se extends ve {
|
|
|
715
717
|
var o;
|
|
716
718
|
this.estimatedHeadingHeight = (o = e.estimatedHeadingHeight) !== null && o !== void 0 ? o : null;
|
|
717
719
|
var s;
|
|
718
|
-
this.loaderHeight = (s = e.loaderHeight) !== null && s !== void 0 ? s : null, this.dropIndicatorThickness = e.dropIndicatorThickness || 2, this.gap = e.gap || 0, this.padding = e.padding || 0, this.layoutNodes = /* @__PURE__ */ new Map(), this.rootNodes = [], this.lastCollection = null, this.invalidateEverything = !1, this.validRect = new f(), this.requestedRect = new f(), this.contentSize = new
|
|
720
|
+
this.loaderHeight = (s = e.loaderHeight) !== null && s !== void 0 ? s : null, this.dropIndicatorThickness = e.dropIndicatorThickness || 2, this.gap = e.gap || 0, this.padding = e.padding || 0, this.layoutNodes = /* @__PURE__ */ new Map(), this.rootNodes = [], this.lastCollection = null, this.invalidateEverything = !1, this.validRect = new f(), this.requestedRect = new f(), this.contentSize = new z();
|
|
719
721
|
}
|
|
720
722
|
}
|
|
721
|
-
let
|
|
722
|
-
function
|
|
723
|
-
if (
|
|
723
|
+
let $ = null;
|
|
724
|
+
function Se(n = !1) {
|
|
725
|
+
if ($ === null || n) {
|
|
724
726
|
const e = document.createElement("div"), t = e.style;
|
|
725
727
|
t.width = "50px", t.height = "50px", t.overflow = "scroll", t.direction = "rtl";
|
|
726
728
|
const i = document.createElement("div"), l = i.style;
|
|
727
|
-
return l.width = "100px", l.height = "100px", e.appendChild(i), document.body.appendChild(e), e.scrollLeft > 0 ?
|
|
729
|
+
return l.width = "100px", l.height = "100px", e.appendChild(i), document.body.appendChild(e), e.scrollLeft > 0 ? $ = "positive-descending" : (e.scrollLeft = 1, e.scrollLeft === 0 ? $ = "negative" : $ = "positive-ascending"), document.body.removeChild(e), $;
|
|
728
730
|
}
|
|
729
|
-
return
|
|
731
|
+
return $;
|
|
730
732
|
}
|
|
731
733
|
function ze(n, e) {
|
|
732
734
|
let { scrollLeft: t } = n;
|
|
733
735
|
if (e === "rtl") {
|
|
734
736
|
let { scrollWidth: i, clientWidth: l } = n;
|
|
735
|
-
switch (
|
|
737
|
+
switch (Se()) {
|
|
736
738
|
case "negative":
|
|
737
739
|
t = -t;
|
|
738
740
|
break;
|
|
@@ -744,7 +746,7 @@ function ze(n, e) {
|
|
|
744
746
|
return t;
|
|
745
747
|
}
|
|
746
748
|
function He(n, e) {
|
|
747
|
-
let { contentSize: t, onVisibleRectChange: i, innerStyle: l, onScrollStart: o, onScrollEnd: s, scrollDirection: a = "both", ...h } = n, r =
|
|
749
|
+
let { contentSize: t, onVisibleRectChange: i, innerStyle: l, onScrollStart: o, onScrollEnd: s, scrollDirection: a = "both", ...h } = n, r = _({
|
|
748
750
|
scrollTop: 0,
|
|
749
751
|
scrollLeft: 0,
|
|
750
752
|
scrollEndTime: 0,
|
|
@@ -752,17 +754,14 @@ function He(n, e) {
|
|
|
752
754
|
width: 0,
|
|
753
755
|
height: 0,
|
|
754
756
|
isScrolling: !1
|
|
755
|
-
}).current, { direction: d } =
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
s
|
|
760
|
-
]), y = z((p) => {
|
|
761
|
-
p.target === p.currentTarget && (n.onScroll && n.onScroll(p), B(() => {
|
|
762
|
-
let m = p.currentTarget.scrollTop, _ = ze(p.currentTarget, d);
|
|
763
|
-
r.scrollTop = Math.max(0, Math.min(m, t.height - r.height)), r.scrollLeft = Math.max(0, Math.min(_, t.width - r.width)), i(new f(r.scrollLeft, r.scrollTop, r.width, r.height)), r.isScrolling || (r.isScrolling = !0, u(!0), window.dispatchEvent(new Event("tk.disconnect-observer")), o && o());
|
|
757
|
+
}).current, { direction: d } = F(), [c, u] = S(!1), y = L((p) => {
|
|
758
|
+
p.target === p.currentTarget && (n.onScroll && n.onScroll(p), O(() => {
|
|
759
|
+
let w = p.currentTarget.scrollTop, H = ze(p.currentTarget, d);
|
|
760
|
+
r.scrollTop = Math.max(0, Math.min(w, t.height - r.height)), r.scrollLeft = Math.max(0, Math.min(H, t.width - r.width)), i(new f(r.scrollLeft, r.scrollTop, r.width, r.height)), r.isScrolling || (r.isScrolling = !0, u(!0), window.dispatchEvent(new Event("tk.disconnect-observer")), o && o());
|
|
764
761
|
let E = Date.now();
|
|
765
|
-
|
|
762
|
+
r.scrollEndTime <= E + 50 && (r.scrollEndTime = E + 300, r.scrollTimeout != null && clearTimeout(r.scrollTimeout), r.scrollTimeout = setTimeout(() => {
|
|
763
|
+
r.isScrolling = !1, u(!1), r.scrollTimeout = null, window.dispatchEvent(new Event("tk.connect-observer")), s && s();
|
|
764
|
+
}, 300));
|
|
766
765
|
}));
|
|
767
766
|
}, [
|
|
768
767
|
n,
|
|
@@ -771,43 +770,43 @@ function He(n, e) {
|
|
|
771
770
|
t,
|
|
772
771
|
i,
|
|
773
772
|
o,
|
|
774
|
-
|
|
773
|
+
s
|
|
775
774
|
]);
|
|
776
|
-
|
|
775
|
+
ue(e, "scroll", y), he(() => () => {
|
|
777
776
|
r.scrollTimeout != null && clearTimeout(r.scrollTimeout), r.isScrolling && window.dispatchEvent(new Event("tk.connect-observer"));
|
|
778
777
|
}, []);
|
|
779
|
-
let
|
|
780
|
-
let
|
|
781
|
-
if (!
|
|
782
|
-
|
|
783
|
-
let
|
|
784
|
-
(r.width !==
|
|
785
|
-
i(new f(r.scrollLeft, r.scrollTop,
|
|
786
|
-
}), (!
|
|
778
|
+
let g = _(!1), v = de((p) => {
|
|
779
|
+
let w = e.current;
|
|
780
|
+
if (!w || g.current) return;
|
|
781
|
+
g.current = !0;
|
|
782
|
+
let H = process.env.NODE_ENV === "test" && !process.env.VIRT_ON, E = Object.getOwnPropertyNames(window.HTMLElement.prototype).includes("clientWidth"), ie = Object.getOwnPropertyNames(window.HTMLElement.prototype).includes("clientHeight"), K = w.clientWidth, q = w.clientHeight, V = H && !E ? 1 / 0 : K, M = H && !ie ? 1 / 0 : q;
|
|
783
|
+
(r.width !== V || r.height !== M) && (r.width = V, r.height = M, p(() => {
|
|
784
|
+
i(new f(r.scrollLeft, r.scrollTop, V, M));
|
|
785
|
+
}), (!H && K !== w.clientWidth || q !== w.clientHeight) && (r.width = w.clientWidth, r.height = w.clientHeight, p(() => {
|
|
787
786
|
i(new f(r.scrollLeft, r.scrollTop, r.width, r.height));
|
|
788
|
-
}))),
|
|
789
|
-
}),
|
|
790
|
-
|
|
791
|
-
if (!
|
|
787
|
+
}))), g.current = !1;
|
|
788
|
+
}), N = _(null), [Z, ee] = S({});
|
|
789
|
+
P(() => {
|
|
790
|
+
if (!g.current && (N.current == null || !t.equals(N.current)))
|
|
792
791
|
if (typeof IS_REACT_ACT_ENVIRONMENT == "boolean" ? IS_REACT_ACT_ENVIRONMENT : typeof jest < "u") {
|
|
793
|
-
|
|
792
|
+
ee({}), N.current = t;
|
|
794
793
|
return;
|
|
795
|
-
} else queueMicrotask(() =>
|
|
796
|
-
|
|
797
|
-
}),
|
|
798
|
-
|
|
794
|
+
} else queueMicrotask(() => v(O));
|
|
795
|
+
N.current = t;
|
|
796
|
+
}), P(() => {
|
|
797
|
+
v((p) => p());
|
|
799
798
|
}, [
|
|
800
|
-
|
|
799
|
+
Z
|
|
801
800
|
]);
|
|
802
|
-
let
|
|
803
|
-
|
|
801
|
+
let te = L(() => {
|
|
802
|
+
v(O);
|
|
804
803
|
}, [
|
|
805
|
-
|
|
804
|
+
v
|
|
806
805
|
]);
|
|
807
|
-
|
|
806
|
+
ce({
|
|
808
807
|
ref: e,
|
|
809
808
|
box: "border-box",
|
|
810
|
-
onResize:
|
|
809
|
+
onResize: te
|
|
811
810
|
});
|
|
812
811
|
let I = {
|
|
813
812
|
// Reset padding so that relative positioning works correctly. Padding will be done in JS layout.
|
|
@@ -833,7 +832,7 @@ function He(n, e) {
|
|
|
833
832
|
};
|
|
834
833
|
}
|
|
835
834
|
function _e(n) {
|
|
836
|
-
let { layoutInfo: e, virtualizer: t, ref: i } = n, l = e == null ? void 0 : e.key, o =
|
|
835
|
+
let { layoutInfo: e, virtualizer: t, ref: i } = n, l = e == null ? void 0 : e.key, o = L(() => {
|
|
837
836
|
if (l != null && i.current) {
|
|
838
837
|
let s = Ce(i.current);
|
|
839
838
|
t.updateItemSize(l, s);
|
|
@@ -843,7 +842,7 @@ function _e(n) {
|
|
|
843
842
|
l,
|
|
844
843
|
i
|
|
845
844
|
]);
|
|
846
|
-
return
|
|
845
|
+
return P(() => {
|
|
847
846
|
e != null && e.estimatedSize && o();
|
|
848
847
|
}), {
|
|
849
848
|
updateSize: o
|
|
@@ -852,16 +851,16 @@ function _e(n) {
|
|
|
852
851
|
function Ce(n) {
|
|
853
852
|
let e = n.style.height;
|
|
854
853
|
n.style.height = "";
|
|
855
|
-
let t = new
|
|
854
|
+
let t = new z(n.scrollWidth, n.scrollHeight);
|
|
856
855
|
return n.style.height = e, t;
|
|
857
856
|
}
|
|
858
|
-
function
|
|
859
|
-
let { style: e, className: t, layoutInfo: i, virtualizer: l, parent: o, children: s } = n, { direction: a } =
|
|
857
|
+
function U(n) {
|
|
858
|
+
let { style: e, className: t, layoutInfo: i, virtualizer: l, parent: o, children: s } = n, { direction: a } = F(), h = _(null);
|
|
860
859
|
return _e({
|
|
861
860
|
layoutInfo: i,
|
|
862
861
|
virtualizer: l,
|
|
863
862
|
ref: h
|
|
864
|
-
}), /* @__PURE__ */
|
|
863
|
+
}), /* @__PURE__ */ m.createElement("div", {
|
|
865
864
|
role: "presentation",
|
|
866
865
|
ref: h,
|
|
867
866
|
className: t,
|
|
@@ -871,9 +870,9 @@ function J(n) {
|
|
|
871
870
|
}
|
|
872
871
|
}, s);
|
|
873
872
|
}
|
|
874
|
-
let
|
|
873
|
+
let W = /* @__PURE__ */ new WeakMap();
|
|
875
874
|
function ke(n, e, t) {
|
|
876
|
-
let i = e === "rtl" ? "right" : "left", l =
|
|
875
|
+
let i = e === "rtl" ? "right" : "left", l = W.get(n);
|
|
877
876
|
if (l && l[i] != null) {
|
|
878
877
|
if (!t) return l;
|
|
879
878
|
let h = n.rect.y - t.rect.y, r = n.rect.x - t.rect.x;
|
|
@@ -904,24 +903,24 @@ function ke(n, e, t) {
|
|
|
904
903
|
contain: "size layout style",
|
|
905
904
|
...o
|
|
906
905
|
};
|
|
907
|
-
return
|
|
906
|
+
return W.set(n, a), a;
|
|
908
907
|
}
|
|
909
|
-
const
|
|
908
|
+
const G = /* @__PURE__ */ X(null), J = /* @__PURE__ */ X(null);
|
|
910
909
|
function Le(n) {
|
|
911
|
-
let { children: e, layout: t, layoutOptions: i } = n, l =
|
|
910
|
+
let { children: e, layout: t, layoutOptions: i } = n, l = k(() => typeof t == "function" ? new t() : t, [
|
|
912
911
|
t
|
|
913
|
-
]), o =
|
|
912
|
+
]), o = k(() => ({
|
|
914
913
|
isVirtualized: !0,
|
|
915
914
|
layoutDelegate: l,
|
|
916
915
|
dropTargetDelegate: l.getDropTargetFromPoint ? l : void 0,
|
|
917
916
|
CollectionRoot: Ne,
|
|
918
|
-
CollectionBranch:
|
|
917
|
+
CollectionBranch: Ee
|
|
919
918
|
}), [
|
|
920
919
|
l
|
|
921
920
|
]);
|
|
922
|
-
return /* @__PURE__ */
|
|
921
|
+
return /* @__PURE__ */ m.createElement(re.Provider, {
|
|
923
922
|
value: o
|
|
924
|
-
}, /* @__PURE__ */
|
|
923
|
+
}, /* @__PURE__ */ m.createElement(J.Provider, {
|
|
925
924
|
value: {
|
|
926
925
|
layout: l,
|
|
927
926
|
layoutOptions: i
|
|
@@ -930,7 +929,7 @@ function Le(n) {
|
|
|
930
929
|
}
|
|
931
930
|
function Ne({ collection: n, persistedKeys: e, scrollRef: t, renderDropIndicator: i }) {
|
|
932
931
|
var l;
|
|
933
|
-
let { layout: o, layoutOptions: s } =
|
|
932
|
+
let { layout: o, layoutOptions: s } = A(J), a = (l = o.useLayoutOptions) === null || l === void 0 ? void 0 : l.call(o), h = Re({
|
|
934
933
|
layout: o,
|
|
935
934
|
collection: n,
|
|
936
935
|
renderView: (d, c) => {
|
|
@@ -942,7 +941,7 @@ function Ne({ collection: n, persistedKeys: e, scrollRef: t, renderDropIndicator
|
|
|
942
941
|
c && (c.scrollLeft = d.x, c.scrollTop = d.y);
|
|
943
942
|
},
|
|
944
943
|
persistedKeys: e,
|
|
945
|
-
layoutOptions:
|
|
944
|
+
layoutOptions: k(() => s && a ? {
|
|
946
945
|
...s,
|
|
947
946
|
...a
|
|
948
947
|
} : s || a, [
|
|
@@ -955,37 +954,37 @@ function Ne({ collection: n, persistedKeys: e, scrollRef: t, renderDropIndicator
|
|
|
955
954
|
onScrollStart: h.startScrolling,
|
|
956
955
|
onScrollEnd: h.endScrolling
|
|
957
956
|
}, t);
|
|
958
|
-
return /* @__PURE__ */
|
|
957
|
+
return /* @__PURE__ */ m.createElement("div", r, /* @__PURE__ */ m.createElement(G.Provider, {
|
|
959
958
|
value: h
|
|
960
|
-
},
|
|
959
|
+
}, Q(null, h.visibleViews, i)));
|
|
961
960
|
}
|
|
962
|
-
function
|
|
963
|
-
let i =
|
|
964
|
-
return
|
|
961
|
+
function Ee({ parent: n, renderDropIndicator: e }) {
|
|
962
|
+
let i = A(G).virtualizer.getVisibleView(n.key);
|
|
963
|
+
return Q(i, Array.from(i.children), e);
|
|
965
964
|
}
|
|
966
|
-
function
|
|
967
|
-
return e.map((i) =>
|
|
965
|
+
function Q(n, e, t) {
|
|
966
|
+
return e.map((i) => Te(n, i, t));
|
|
968
967
|
}
|
|
969
|
-
function
|
|
970
|
-
let i = /* @__PURE__ */
|
|
968
|
+
function Te(n, e, t) {
|
|
969
|
+
let i = /* @__PURE__ */ m.createElement(U, {
|
|
971
970
|
key: e.key,
|
|
972
971
|
layoutInfo: e.layoutInfo,
|
|
973
972
|
virtualizer: e.virtualizer,
|
|
974
973
|
parent: n == null ? void 0 : n.layoutInfo
|
|
975
974
|
}, e.rendered), { collection: l, layout: o } = e.virtualizer, s = e.content;
|
|
976
|
-
return (s == null ? void 0 : s.type) === "item" && t && o.getDropTargetLayoutInfo && (i = /* @__PURE__ */
|
|
975
|
+
return (s == null ? void 0 : s.type) === "item" && t && o.getDropTargetLayoutInfo && (i = /* @__PURE__ */ m.createElement(m.Fragment, {
|
|
977
976
|
key: e.key
|
|
978
|
-
},
|
|
977
|
+
}, D(n, e, {
|
|
979
978
|
type: "item",
|
|
980
979
|
key: e.content.key,
|
|
981
980
|
dropPosition: "before"
|
|
982
|
-
}, t), i,
|
|
981
|
+
}, t), i, ae(l, s, (a) => D(n, e, a, t)))), i;
|
|
983
982
|
}
|
|
984
|
-
function
|
|
983
|
+
function D(n, e, t, i) {
|
|
985
984
|
let l = i(t);
|
|
986
985
|
if (l) {
|
|
987
986
|
let o = e.virtualizer.layout.getDropTargetLayoutInfo(t);
|
|
988
|
-
l = /* @__PURE__ */
|
|
987
|
+
l = /* @__PURE__ */ m.createElement(U, {
|
|
989
988
|
layoutInfo: o,
|
|
990
989
|
virtualizer: e.virtualizer,
|
|
991
990
|
parent: n == null ? void 0 : n.layoutInfo
|
|
@@ -993,7 +992,7 @@ function A(n, e, t, i) {
|
|
|
993
992
|
}
|
|
994
993
|
return l;
|
|
995
994
|
}
|
|
996
|
-
class Ve extends
|
|
995
|
+
class Ve extends $e {
|
|
997
996
|
/**
|
|
998
997
|
* When using the ListLayout our scroll container height is not calculated properly when the content is partially sectioned.
|
|
999
998
|
* ```ts
|
|
@@ -1018,7 +1017,7 @@ class Ve extends Se {
|
|
|
1018
1017
|
}), this.contentSize;
|
|
1019
1018
|
}
|
|
1020
1019
|
}
|
|
1021
|
-
const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSectionHeading_ts7z5_31", Be = "_listBoxButton_ts7z5_41", Ke = "_listBoxItem_ts7z5_53", qe = "_listBoxLoadMoreItem_ts7z5_99",
|
|
1020
|
+
const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSectionHeading_ts7z5_31", Be = "_listBoxButton_ts7z5_41", Ke = "_listBoxItem_ts7z5_53", qe = "_listBoxLoadMoreItem_ts7z5_99", T = {
|
|
1022
1021
|
listBox: Me,
|
|
1023
1022
|
listBoxPopover: Oe,
|
|
1024
1023
|
listBoxSectionHeading: Pe,
|
|
@@ -1029,17 +1028,17 @@ const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSe
|
|
|
1029
1028
|
className: n,
|
|
1030
1029
|
children: e,
|
|
1031
1030
|
...t
|
|
1032
|
-
}) => /* @__PURE__ */
|
|
1031
|
+
}) => /* @__PURE__ */ C(
|
|
1033
1032
|
Le,
|
|
1034
1033
|
{
|
|
1035
1034
|
layout: Ve,
|
|
1036
1035
|
layoutOptions: {
|
|
1037
1036
|
headingHeight: 44
|
|
1038
1037
|
},
|
|
1039
|
-
children: /* @__PURE__ */
|
|
1040
|
-
|
|
1038
|
+
children: /* @__PURE__ */ C(
|
|
1039
|
+
oe,
|
|
1041
1040
|
{
|
|
1042
|
-
className:
|
|
1041
|
+
className: B(T.listBox, n),
|
|
1043
1042
|
...t,
|
|
1044
1043
|
children: e
|
|
1045
1044
|
}
|
|
@@ -1049,10 +1048,10 @@ const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSe
|
|
|
1049
1048
|
children: n,
|
|
1050
1049
|
className: e,
|
|
1051
1050
|
...t
|
|
1052
|
-
}) => /* @__PURE__ */
|
|
1053
|
-
|
|
1051
|
+
}) => /* @__PURE__ */ C(
|
|
1052
|
+
ne,
|
|
1054
1053
|
{
|
|
1055
|
-
className:
|
|
1054
|
+
className: B(T.listBoxItem, e),
|
|
1056
1055
|
...t,
|
|
1057
1056
|
children: n
|
|
1058
1057
|
}
|
|
@@ -1060,10 +1059,10 @@ const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSe
|
|
|
1060
1059
|
className: n,
|
|
1061
1060
|
children: e,
|
|
1062
1061
|
...t
|
|
1063
|
-
}) => /* @__PURE__ */
|
|
1064
|
-
|
|
1062
|
+
}) => /* @__PURE__ */ C(
|
|
1063
|
+
fe,
|
|
1065
1064
|
{
|
|
1066
|
-
className:
|
|
1065
|
+
className: B(n, T.listBoxPopover),
|
|
1067
1066
|
offset: 0,
|
|
1068
1067
|
...t,
|
|
1069
1068
|
children: e
|
|
@@ -1072,8 +1071,8 @@ const Me = "_listBox_ts7z5_4", Oe = "_listBoxPopover_ts7z5_16", Pe = "_listBoxSe
|
|
|
1072
1071
|
children: n,
|
|
1073
1072
|
name: e,
|
|
1074
1073
|
...t
|
|
1075
|
-
}) => /* @__PURE__ */
|
|
1076
|
-
/* @__PURE__ */
|
|
1074
|
+
}) => /* @__PURE__ */ le(se, { ...t, children: [
|
|
1075
|
+
/* @__PURE__ */ C(ge, { className: T.listBoxSectionHeading, children: e }),
|
|
1077
1076
|
n
|
|
1078
1077
|
] });
|
|
1079
1078
|
export {
|
|
@@ -1081,5 +1080,5 @@ export {
|
|
|
1081
1080
|
it as a,
|
|
1082
1081
|
lt as b,
|
|
1083
1082
|
ot as c,
|
|
1084
|
-
|
|
1083
|
+
T as s
|
|
1085
1084
|
};
|