ods-component-lib 1.21.2 → 1.21.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/antd/currencyInput/CurrencySelect.js +16 -11
- package/dist/components/antd/currencyInput/CurrencySelect.js.map +1 -1
- package/dist/components/devextreme/OdsBasicDataGrid/OdsBasicDataGrid.js +32 -43
- package/dist/components/devextreme/OdsBasicDataGrid/OdsBasicDataGrid.js.map +1 -1
- package/dist/components/devextreme/OdsDataGrid.Legacy.js +4 -4
- package/dist/components/devextreme/OdsRemoteDataGrid.js +1 -1
- package/dist/index.js +10 -10
- package/dist/node_modules/@ant-design/cssinjs/es/StyleContext.js +6 -6
- package/dist/node_modules/@ant-design/cssinjs/es/StyleContext.js.map +1 -1
- package/dist/node_modules/@ant-design/cssinjs/es/hooks/useCacheToken.js +20 -20
- package/dist/node_modules/@ant-design/cssinjs/es/hooks/useCacheToken.js.map +1 -1
- package/dist/node_modules/@ant-design/cssinjs/es/hooks/useGlobalCache.js.map +1 -1
- package/dist/node_modules/@ant-design/cssinjs/es/hooks/useStyleRegister.js +101 -98
- package/dist/node_modules/@ant-design/cssinjs/es/hooks/useStyleRegister.js.map +1 -1
- package/dist/node_modules/@ant-design/cssinjs/es/linters/utils.js +1 -1
- package/dist/node_modules/@ant-design/cssinjs/es/util/index.js +29 -27
- package/dist/node_modules/@ant-design/cssinjs/es/util/index.js.map +1 -1
- package/dist/node_modules/@ant-design/cssinjs-utils/es/util/getComponentToken.js +1 -1
- package/dist/node_modules/@ant-design/fast-color/es/FastColor.js +66 -45
- package/dist/node_modules/@ant-design/fast-color/es/FastColor.js.map +1 -1
- package/dist/node_modules/@ant-design/icons/es/icons/FrownOutlined.js +5 -8
- package/dist/node_modules/@ant-design/icons/es/icons/HeartOutlined.js +3 -6
- package/dist/node_modules/@ant-design/icons/es/icons/MehOutlined.js +12 -15
- package/dist/node_modules/@ant-design/icons/es/icons/SmileOutlined.js +8 -11
- package/dist/node_modules/@ant-design/icons/es/utils.js +2 -9
- package/dist/node_modules/@ant-design/icons/es/utils.js.map +1 -1
- package/dist/node_modules/@emotion/stylis/dist/stylis.browser.esm.js +1 -9
- package/dist/node_modules/@emotion/stylis/dist/stylis.browser.esm.js.map +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/index.js +20 -20
- package/dist/node_modules/@rc-component/async-validator/es/index.js.map +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/messages.js +1 -0
- package/dist/node_modules/@rc-component/async-validator/es/messages.js.map +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/rule/type.js +18 -8
- package/dist/node_modules/@rc-component/async-validator/es/rule/type.js.map +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/util.js +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/util.js.map +1 -1
- package/dist/node_modules/@rc-component/async-validator/es/validator/index.js +1 -0
- package/dist/node_modules/@rc-component/async-validator/es/validator/index.js.map +1 -1
- package/dist/node_modules/@rc-component/collapse/es/Collapse.js +1 -1
- package/dist/node_modules/@rc-component/collapse/es/hooks/useItems.js +88 -68
- package/dist/node_modules/@rc-component/collapse/es/hooks/useItems.js.map +1 -1
- package/dist/node_modules/@rc-component/dialog/es/Dialog/Content/Panel.js +75 -96
- package/dist/node_modules/@rc-component/dialog/es/Dialog/Content/Panel.js.map +1 -1
- package/dist/node_modules/@rc-component/dialog/es/Dialog/Content/index.js +22 -20
- package/dist/node_modules/@rc-component/dialog/es/Dialog/Content/index.js.map +1 -1
- package/dist/node_modules/@rc-component/dialog/es/Dialog/index.js +92 -100
- package/dist/node_modules/@rc-component/dialog/es/Dialog/index.js.map +1 -1
- package/dist/node_modules/@rc-component/dialog/es/DialogWrap.js +40 -29
- package/dist/node_modules/@rc-component/dialog/es/DialogWrap.js.map +1 -1
- package/dist/node_modules/@rc-component/dropdown/es/Dropdown.js +2 -2
- package/dist/node_modules/@rc-component/form/es/Field.js +9 -9
- package/dist/node_modules/@rc-component/form/es/FieldContext.js +2 -3
- package/dist/node_modules/@rc-component/form/es/FieldContext.js.map +1 -1
- package/dist/node_modules/@rc-component/form/es/Form.js +78 -92
- package/dist/node_modules/@rc-component/form/es/Form.js.map +1 -1
- package/dist/node_modules/@rc-component/form/es/List.js +1 -1
- package/dist/node_modules/@rc-component/form/es/{useForm.js → hooks/useForm.js} +136 -143
- package/dist/node_modules/@rc-component/form/es/hooks/useForm.js.map +1 -0
- package/dist/node_modules/@rc-component/form/es/hooks/useNotifyWatch.js +43 -0
- package/dist/node_modules/@rc-component/form/es/hooks/useNotifyWatch.js.map +1 -0
- package/dist/node_modules/@rc-component/form/es/{useWatch.js → hooks/useWatch.js} +7 -7
- package/dist/node_modules/@rc-component/form/es/hooks/useWatch.js.map +1 -0
- package/dist/node_modules/@rc-component/form/es/index.js +2 -2
- package/dist/node_modules/@rc-component/form/es/index.js.map +1 -1
- package/dist/node_modules/@rc-component/form/es/utils/NameMap.js +28 -22
- package/dist/node_modules/@rc-component/form/es/utils/NameMap.js.map +1 -1
- package/dist/node_modules/@rc-component/form/es/utils/messages.js +1 -0
- package/dist/node_modules/@rc-component/form/es/utils/messages.js.map +1 -1
- package/dist/node_modules/@rc-component/form/es/utils/validateUtil.js +1 -1
- package/dist/node_modules/@rc-component/form/es/utils/valueUtil.js.map +1 -1
- package/dist/node_modules/@rc-component/image/es/Preview/index.js +111 -105
- package/dist/node_modules/@rc-component/image/es/Preview/index.js.map +1 -1
- package/dist/node_modules/@rc-component/input-number/es/hooks/useCursor.js +1 -1
- package/dist/node_modules/@rc-component/menu/es/Menu.js +1 -1
- package/dist/node_modules/@rc-component/menu/es/MenuItem.js +1 -1
- package/dist/node_modules/@rc-component/menu/es/SubMenu/index.js +1 -1
- package/dist/node_modules/@rc-component/menu/es/hooks/useKeyRecords.js +1 -1
- package/dist/node_modules/@rc-component/menu/es/placements.js +0 -1
- package/dist/node_modules/@rc-component/menu/es/utils/warnUtil.js +1 -1
- package/dist/node_modules/@rc-component/pagination/es/Pagination.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/RangePicker.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/Selector/hooks/useClearIcon.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/Selector/hooks/useInputProps.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/hooks/useCellRender.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/hooks/useFilledProps.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerInput/hooks/usePresets.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/PickerPanel/index.js +1 -1
- package/dist/node_modules/@rc-component/picker/es/hooks/useTimeInfo.js +1 -1
- package/dist/node_modules/@rc-component/portal/es/Portal.js +41 -35
- package/dist/node_modules/@rc-component/portal/es/Portal.js.map +1 -1
- package/dist/node_modules/@rc-component/portal/es/useEscKeyDown.js +48 -0
- package/dist/node_modules/@rc-component/portal/es/useEscKeyDown.js.map +1 -0
- package/dist/node_modules/@rc-component/resize-observer/es/SingleObserver/index.js +18 -54
- package/dist/node_modules/@rc-component/resize-observer/es/SingleObserver/index.js.map +1 -1
- package/dist/node_modules/@rc-component/resize-observer/es/index.js.map +1 -1
- package/dist/node_modules/@rc-component/resize-observer/es/useResizeObserver.js +50 -0
- package/dist/node_modules/@rc-component/resize-observer/es/useResizeObserver.js.map +1 -0
- package/dist/node_modules/@rc-component/select/es/BaseSelect/index.js +141 -140
- package/dist/node_modules/@rc-component/select/es/BaseSelect/index.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/OptionList.js +92 -91
- package/dist/node_modules/@rc-component/select/es/OptionList.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/Select.js +5 -5
- package/dist/node_modules/@rc-component/select/es/SelectInput/Content/MultipleContent.js +50 -50
- package/dist/node_modules/@rc-component/select/es/SelectInput/Content/MultipleContent.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/SelectInput/Content/SingleContent.js +41 -47
- package/dist/node_modules/@rc-component/select/es/SelectInput/Content/SingleContent.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/SelectInput/index.js +85 -80
- package/dist/node_modules/@rc-component/select/es/SelectInput/index.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/hooks/useOpen.js +27 -26
- package/dist/node_modules/@rc-component/select/es/hooks/useOpen.js.map +1 -1
- package/dist/node_modules/@rc-component/select/es/utils/valueUtil.js +1 -1
- package/dist/node_modules/@rc-component/select/es/utils/warningPropsUtil.js +6 -6
- package/dist/node_modules/@rc-component/table/es/Cell/useCellRender.js +1 -1
- package/dist/node_modules/@rc-component/table/es/Table.js +1 -1
- package/dist/node_modules/@rc-component/table/es/VirtualTable/BodyGrid.js +85 -80
- package/dist/node_modules/@rc-component/table/es/VirtualTable/BodyGrid.js.map +1 -1
- package/dist/node_modules/@rc-component/table/es/VirtualTable/index.js +1 -1
- package/dist/node_modules/@rc-component/table/es/hooks/useColumns/index.js +1 -1
- package/dist/node_modules/@rc-component/table/es/hooks/useExpand.js +1 -1
- package/dist/node_modules/@rc-component/table/es/utils/legacyUtil.js +1 -1
- package/dist/node_modules/@rc-component/tabs/es/hooks/useAnimateConfig.js +1 -1
- package/dist/node_modules/@rc-component/tooltip/es/placements.js +0 -1
- package/dist/node_modules/@rc-component/tree/es/Tree.js +1 -1
- package/dist/node_modules/@rc-component/tree/es/util.js +1 -1
- package/dist/node_modules/@rc-component/tree/es/utils/conductUtil.js +1 -1
- package/dist/node_modules/@rc-component/tree/es/utils/treeUtil.js +1 -1
- package/dist/node_modules/@rc-component/tree-select/es/TreeSelect.js +1 -1
- package/dist/node_modules/@rc-component/tree-select/es/hooks/useDataEntities.js +1 -1
- package/dist/node_modules/@rc-component/tree-select/es/utils/legacyUtil.js +1 -1
- package/dist/node_modules/@rc-component/tree-select/es/utils/warningPropsUtil.js +1 -1
- package/dist/node_modules/@rc-component/trigger/es/Popup/index.js +74 -72
- package/dist/node_modules/@rc-component/trigger/es/Popup/index.js.map +1 -1
- package/dist/node_modules/@rc-component/trigger/es/UniqueProvider/index.js +10 -9
- package/dist/node_modules/@rc-component/trigger/es/UniqueProvider/index.js.map +1 -1
- package/dist/node_modules/@rc-component/trigger/es/hooks/useAlign.js +126 -123
- package/dist/node_modules/@rc-component/trigger/es/hooks/useAlign.js.map +1 -1
- package/dist/node_modules/@rc-component/trigger/es/index.js +150 -140
- package/dist/node_modules/@rc-component/trigger/es/index.js.map +1 -1
- package/dist/node_modules/@rc-component/trigger/es/util.js +35 -34
- package/dist/node_modules/@rc-component/trigger/es/util.js.map +1 -1
- package/dist/node_modules/@rc-component/upload/es/attr-accept.js +1 -1
- package/dist/node_modules/@rc-component/util/es/Dom/focus.js +65 -20
- package/dist/node_modules/@rc-component/util/es/Dom/focus.js.map +1 -1
- package/dist/node_modules/@rc-component/util/es/KeyCode.js.map +1 -1
- package/dist/node_modules/@rc-component/util/es/hooks/useId.js.map +1 -1
- package/dist/node_modules/@rc-component/util/es/hooks/useState.js +6 -6
- package/dist/node_modules/@rc-component/util/es/hooks/useState.js.map +1 -1
- package/dist/node_modules/@rc-component/util/es/hooks/useSyncState.js.map +1 -1
- package/dist/node_modules/@rc-component/util/es/isEqual.js +1 -1
- package/dist/node_modules/@rc-component/util/es/utils/set.js +21 -21
- package/dist/node_modules/@rc-component/util/es/utils/set.js.map +1 -1
- package/dist/node_modules/@rc-component/virtual-list/es/hooks/useScrollTo.js +1 -1
- package/dist/node_modules/antd/es/_util/warning.js +1 -1
- package/dist/node_modules/antd/es/_util/wave/WaveEffect.js +53 -48
- package/dist/node_modules/antd/es/_util/wave/WaveEffect.js.map +1 -1
- package/dist/node_modules/antd/es/_util/wave/index.js +1 -1
- package/dist/node_modules/antd/es/_util/wave/index.js.map +1 -1
- package/dist/node_modules/antd/es/_util/wave/style.js +8 -7
- package/dist/node_modules/antd/es/_util/wave/style.js.map +1 -1
- package/dist/node_modules/antd/es/alert/Alert.js +133 -128
- package/dist/node_modules/antd/es/alert/Alert.js.map +1 -1
- package/dist/node_modules/antd/es/badge/Badge.js +29 -28
- package/dist/node_modules/antd/es/badge/Badge.js.map +1 -1
- package/dist/node_modules/antd/es/badge/style/index.js +1 -1
- package/dist/node_modules/antd/es/badge/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/button/buttonHelpers.js +47 -41
- package/dist/node_modules/antd/es/button/buttonHelpers.js.map +1 -1
- package/dist/node_modules/antd/es/button/style/compact.js +45 -36
- package/dist/node_modules/antd/es/button/style/compact.js.map +1 -1
- package/dist/node_modules/antd/es/button/style/variant.js +100 -90
- package/dist/node_modules/antd/es/button/style/variant.js.map +1 -1
- package/dist/node_modules/antd/es/calendar/generateCalendar.js +55 -57
- package/dist/node_modules/antd/es/calendar/generateCalendar.js.map +1 -1
- package/dist/node_modules/antd/es/calendar/style/index.js +18 -18
- package/dist/node_modules/antd/es/calendar/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/card/CardGrid.js.map +1 -1
- package/dist/node_modules/antd/es/card/style/index.js +23 -11
- package/dist/node_modules/antd/es/card/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/checkbox/Group.js +32 -30
- package/dist/node_modules/antd/es/checkbox/Group.js.map +1 -1
- package/dist/node_modules/antd/es/collapse/Collapse.js +61 -61
- package/dist/node_modules/antd/es/collapse/Collapse.js.map +1 -1
- package/dist/node_modules/antd/es/color-picker/color.js +9 -9
- package/dist/node_modules/antd/es/color-picker/color.js.map +1 -1
- package/dist/node_modules/antd/es/config-provider/index.js +76 -71
- package/dist/node_modules/antd/es/config-provider/index.js.map +1 -1
- package/dist/node_modules/antd/es/date-picker/generatePicker/generateRangePicker.js +29 -31
- package/dist/node_modules/antd/es/date-picker/generatePicker/generateRangePicker.js.map +1 -1
- package/dist/node_modules/antd/es/date-picker/generatePicker/generateSinglePicker.js +7 -9
- package/dist/node_modules/antd/es/date-picker/generatePicker/generateSinglePicker.js.map +1 -1
- package/dist/node_modules/antd/es/date-picker/generatePicker/{SuffixIcon.js → useSuffixIcon.js} +4 -4
- package/dist/node_modules/antd/es/date-picker/generatePicker/useSuffixIcon.js.map +1 -0
- package/dist/node_modules/antd/es/date-picker/style/panel.js +4 -4
- package/dist/node_modules/antd/es/date-picker/style/panel.js.map +1 -1
- package/dist/node_modules/antd/es/drawer/useFocusable.js +14 -0
- package/dist/node_modules/antd/es/drawer/useFocusable.js.map +1 -0
- package/dist/node_modules/antd/es/empty/empty.js +27 -32
- package/dist/node_modules/antd/es/empty/empty.js.map +1 -1
- package/dist/node_modules/antd/es/empty/simple.js +2 -2
- package/dist/node_modules/antd/es/empty/simple.js.map +1 -1
- package/dist/node_modules/antd/es/form/hooks/useForm.js +2 -2
- package/dist/node_modules/antd/es/form/index.js +1 -1
- package/dist/node_modules/antd/es/form/style/index.js +24 -24
- package/dist/node_modules/antd/es/form/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/grid/col.js +56 -54
- package/dist/node_modules/antd/es/grid/col.js.map +1 -1
- package/dist/node_modules/antd/es/grid/style/index.js +50 -50
- package/dist/node_modules/antd/es/grid/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/input/TextArea.js +16 -15
- package/dist/node_modules/antd/es/input/TextArea.js.map +1 -1
- package/dist/node_modules/antd/es/input/style/index.js +1 -0
- package/dist/node_modules/antd/es/input/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/input-number/index.js +91 -91
- package/dist/node_modules/antd/es/input-number/index.js.map +1 -1
- package/dist/node_modules/antd/es/input-number/style/index.js +80 -79
- package/dist/node_modules/antd/es/input-number/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/layout/Sider.js +1 -2
- package/dist/node_modules/antd/es/layout/style/sider.js +9 -9
- package/dist/node_modules/antd/es/layout/style/sider.js.map +1 -1
- package/dist/node_modules/antd/es/menu/MenuItem.js +6 -6
- package/dist/node_modules/antd/es/menu/MenuItem.js.map +1 -1
- package/dist/node_modules/antd/es/menu/SubMenu.js +8 -8
- package/dist/node_modules/antd/es/menu/SubMenu.js.map +1 -1
- package/dist/node_modules/antd/es/menu/style/horizontal.js +1 -1
- package/dist/node_modules/antd/es/menu/style/horizontal.js.map +1 -1
- package/dist/node_modules/antd/es/menu/style/index.js +58 -58
- package/dist/node_modules/antd/es/menu/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/menu/style/vertical.js +1 -1
- package/dist/node_modules/antd/es/menu/style/vertical.js.map +1 -1
- package/dist/node_modules/antd/es/message/index.js +1 -1
- package/dist/node_modules/antd/es/modal/ConfirmDialog.js +117 -112
- package/dist/node_modules/antd/es/modal/ConfirmDialog.js.map +1 -1
- package/dist/node_modules/antd/es/modal/Modal.js +115 -109
- package/dist/node_modules/antd/es/modal/Modal.js.map +1 -1
- package/dist/node_modules/antd/es/modal/confirm.js +3 -3
- package/dist/node_modules/antd/es/modal/style/index.js +83 -80
- package/dist/node_modules/antd/es/modal/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/pagination/Pagination.js +85 -81
- package/dist/node_modules/antd/es/pagination/Pagination.js.map +1 -1
- package/dist/node_modules/antd/es/pagination/style/bordered.js +2 -2
- package/dist/node_modules/antd/es/pagination/style/bordered.js.map +1 -1
- package/dist/node_modules/antd/es/pagination/style/index.js +100 -133
- package/dist/node_modules/antd/es/pagination/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/popover/index.js +77 -82
- package/dist/node_modules/antd/es/popover/index.js.map +1 -1
- package/dist/node_modules/antd/es/popover/style/index.js +65 -63
- package/dist/node_modules/antd/es/popover/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/progress/progress.js +4 -4
- package/dist/node_modules/antd/es/radio/context.js +3 -3
- package/dist/node_modules/antd/es/radio/context.js.map +1 -1
- package/dist/node_modules/antd/es/radio/group.js +31 -29
- package/dist/node_modules/antd/es/radio/group.js.map +1 -1
- package/dist/node_modules/antd/es/radio/style/index.js +1 -1
- package/dist/node_modules/antd/es/radio/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/select/style/dropdown.js +1 -1
- package/dist/node_modules/antd/es/select/style/dropdown.js.map +1 -1
- package/dist/node_modules/antd/es/select/style/select-input-multiple.js +71 -69
- package/dist/node_modules/antd/es/select/style/select-input-multiple.js.map +1 -1
- package/dist/node_modules/antd/es/select/style/select-input.js +113 -98
- package/dist/node_modules/antd/es/select/style/select-input.js.map +1 -1
- package/dist/node_modules/antd/es/skeleton/Image.js +9 -9
- package/dist/node_modules/antd/es/skeleton/Image.js.map +1 -1
- package/dist/node_modules/antd/es/space/Item.js +2 -2
- package/dist/node_modules/antd/es/space/Item.js.map +1 -1
- package/dist/node_modules/antd/es/space/index.js +4 -4
- package/dist/node_modules/antd/es/space/index.js.map +1 -1
- package/dist/node_modules/antd/es/space/style/addon.js +47 -46
- package/dist/node_modules/antd/es/space/style/addon.js.map +1 -1
- package/dist/node_modules/antd/es/steps/PanelArrow.js +2 -2
- package/dist/node_modules/antd/es/steps/PanelArrow.js.map +1 -1
- package/dist/node_modules/antd/es/steps/ProgressIcon.js +12 -10
- package/dist/node_modules/antd/es/steps/ProgressIcon.js.map +1 -1
- package/dist/node_modules/antd/es/steps/index.js +108 -106
- package/dist/node_modules/antd/es/steps/index.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/horizontal.js +13 -11
- package/dist/node_modules/antd/es/steps/style/horizontal.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/icon.js +23 -18
- package/dist/node_modules/antd/es/steps/style/icon.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/index.js +41 -41
- package/dist/node_modules/antd/es/steps/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/inline.js +28 -23
- package/dist/node_modules/antd/es/steps/style/inline.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/label-placement.js +44 -39
- package/dist/node_modules/antd/es/steps/style/label-placement.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/nav.js +29 -27
- package/dist/node_modules/antd/es/steps/style/nav.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/panel.js +61 -56
- package/dist/node_modules/antd/es/steps/style/panel.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/progress-dot.js +28 -26
- package/dist/node_modules/antd/es/steps/style/progress-dot.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/progress.js +24 -57
- package/dist/node_modules/antd/es/steps/style/progress.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/rtl.js +10 -8
- package/dist/node_modules/antd/es/steps/style/rtl.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/small.js +21 -16
- package/dist/node_modules/antd/es/steps/style/small.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/status.js +187 -176
- package/dist/node_modules/antd/es/steps/style/status.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/util.js +18 -16
- package/dist/node_modules/antd/es/steps/style/util.js.map +1 -1
- package/dist/node_modules/antd/es/steps/style/vertical.js +21 -16
- package/dist/node_modules/antd/es/steps/style/vertical.js.map +1 -1
- package/dist/node_modules/antd/es/style/placementArrow.js +31 -29
- package/dist/node_modules/antd/es/style/placementArrow.js.map +1 -1
- package/dist/node_modules/antd/es/table/InternalTable.js +65 -62
- package/dist/node_modules/antd/es/table/InternalTable.js.map +1 -1
- package/dist/node_modules/antd/es/table/TableMeasureRowContext.js +6 -0
- package/dist/node_modules/antd/es/table/TableMeasureRowContext.js.map +1 -0
- package/dist/node_modules/antd/es/table/hooks/useFilter/FilterDropdown.js +145 -137
- package/dist/node_modules/antd/es/table/hooks/useFilter/FilterDropdown.js.map +1 -1
- package/dist/node_modules/antd/es/table/style/index.js +3 -3
- package/dist/node_modules/antd/es/table/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/table/style/radius.js +10 -0
- package/dist/node_modules/antd/es/table/style/radius.js.map +1 -1
- package/dist/node_modules/antd/es/table/style/virtual.js +5 -5
- package/dist/node_modules/antd/es/table/style/virtual.js.map +1 -1
- package/dist/node_modules/antd/es/tag/style/index.js +5 -5
- package/dist/node_modules/antd/es/tag/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/theme/util/genStyleUtils.js +29 -32
- package/dist/node_modules/antd/es/theme/util/genStyleUtils.js.map +1 -1
- package/dist/node_modules/antd/es/timeline/Timeline.js +76 -74
- package/dist/node_modules/antd/es/timeline/Timeline.js.map +1 -1
- package/dist/node_modules/antd/es/timeline/style/horizontal.js +21 -18
- package/dist/node_modules/antd/es/timeline/style/horizontal.js.map +1 -1
- package/dist/node_modules/antd/es/timeline/style/index.js +85 -70
- package/dist/node_modules/antd/es/timeline/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/timeline/useItems.js +38 -37
- package/dist/node_modules/antd/es/timeline/useItems.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/PurePanel.js +27 -27
- package/dist/node_modules/antd/es/tooltip/PurePanel.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/UniqueProvider/MotionContent.js +17 -22
- package/dist/node_modules/antd/es/tooltip/UniqueProvider/MotionContent.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/UniqueProvider/index.js +27 -26
- package/dist/node_modules/antd/es/tooltip/UniqueProvider/index.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/index.js +52 -51
- package/dist/node_modules/antd/es/tooltip/index.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/style/index.js +55 -52
- package/dist/node_modules/antd/es/tooltip/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/tooltip/util.js +13 -12
- package/dist/node_modules/antd/es/tooltip/util.js.map +1 -1
- package/dist/node_modules/antd/es/transfer/ListBody.js +16 -16
- package/dist/node_modules/antd/es/transfer/ListBody.js.map +1 -1
- package/dist/node_modules/antd/es/transfer/ListItem.js +43 -43
- package/dist/node_modules/antd/es/transfer/ListItem.js.map +1 -1
- package/dist/node_modules/antd/es/transfer/style/index.js +1 -1
- package/dist/node_modules/antd/es/tree/DirectoryTree.js +42 -41
- package/dist/node_modules/antd/es/tree/DirectoryTree.js.map +1 -1
- package/dist/node_modules/antd/es/typography/Base/index.js +43 -42
- package/dist/node_modules/antd/es/typography/Base/index.js.map +1 -1
- package/dist/node_modules/antd/es/typography/style/index.js +43 -43
- package/dist/node_modules/antd/es/typography/style/index.js.map +1 -1
- package/dist/node_modules/antd/es/typography/style/mixins.js +1 -1
- package/dist/node_modules/antd/es/typography/style/mixins.js.map +1 -1
- package/dist/node_modules/antd/es/version/version.js +1 -1
- package/dist/node_modules/antd/es/version/version.js.map +1 -1
- package/dist/node_modules/antd/es/watermark/context.js +5 -6
- package/dist/node_modules/antd/es/watermark/context.js.map +1 -1
- package/dist/node_modules/antd-style/node_modules/@ant-design/cssinjs/es/StyleContext.js +1 -2
- package/dist/node_modules/antd-style/node_modules/@ant-design/cssinjs/es/StyleContext.js.map +1 -1
- package/dist/node_modules/exceljs/dist/exceljs.min.js +91 -508
- package/dist/node_modules/exceljs/dist/exceljs.min.js.map +1 -1
- package/dist/node_modules/html2canvas/dist/html2canvas.esm.js +5 -55
- package/dist/node_modules/html2canvas/dist/html2canvas.esm.js.map +1 -1
- package/dist/node_modules/jspdf/dist/jspdf.es.min.js +8 -53
- package/dist/node_modules/jspdf/dist/jspdf.es.min.js.map +1 -1
- package/dist/node_modules/lodash/lodash.js +295 -278
- package/dist/node_modules/lodash/lodash.js.map +1 -1
- package/dist/node_modules/moment/dist/moment.js +2 -8
- package/dist/node_modules/moment/dist/moment.js.map +1 -1
- package/dist/node_modules/rc-util/es/isEqual.js +1 -1
- package/package.json +1 -1
- package/dist/node_modules/@rc-component/form/es/BatchUpdate.js +0 -21
- package/dist/node_modules/@rc-component/form/es/BatchUpdate.js.map +0 -1
- package/dist/node_modules/@rc-component/form/es/useForm.js.map +0 -1
- package/dist/node_modules/@rc-component/form/es/useWatch.js.map +0 -1
- package/dist/node_modules/antd/es/date-picker/generatePicker/SuffixIcon.js.map +0 -1
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { isDOM as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
1
|
+
import { isDOM as Xe } from "../../../util/es/Dom/findDOMNode.js";
|
|
2
|
+
import Ye from "../../../util/es/Dom/isVisible.js";
|
|
3
|
+
import ve from "../../../util/es/hooks/useEvent.js";
|
|
4
|
+
import Bt from "../../../util/es/hooks/useLayoutEffect.js";
|
|
5
5
|
import * as k from "react";
|
|
6
|
-
import { collectScroller as
|
|
7
|
-
function
|
|
6
|
+
import { collectScroller as Be, getVisibleArea as Mt, getWin as Me, toNum as Ot } from "../util.js";
|
|
7
|
+
function Vt(o, c = 0) {
|
|
8
8
|
const l = `${c}`, p = l.match(/^(.*)\%$/);
|
|
9
9
|
return p ? o * (parseFloat(p[1]) / 100) : parseFloat(l);
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function Ct(o, c) {
|
|
12
12
|
const [l, p] = c || [];
|
|
13
|
-
return [
|
|
13
|
+
return [Vt(o.width, l), Vt(o.height, p)];
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function Lt(o = "") {
|
|
16
16
|
return [o[0], o[1]];
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function O(o, c) {
|
|
19
19
|
const l = c[0], p = c[1];
|
|
20
|
-
let
|
|
21
|
-
return l === "t" ?
|
|
22
|
-
x:
|
|
23
|
-
y:
|
|
20
|
+
let A, X;
|
|
21
|
+
return l === "t" ? X = o.y : l === "b" ? X = o.y + o.height : X = o.y + o.height / 2, p === "l" ? A = o.x : p === "r" ? A = o.x + o.width : A = o.x + o.width / 2, {
|
|
22
|
+
x: A,
|
|
23
|
+
y: X
|
|
24
24
|
};
|
|
25
25
|
}
|
|
26
26
|
function w(o, c) {
|
|
@@ -29,11 +29,14 @@ function w(o, c) {
|
|
|
29
29
|
b: "t",
|
|
30
30
|
l: "r",
|
|
31
31
|
r: "l"
|
|
32
|
-
};
|
|
33
|
-
return
|
|
32
|
+
}, p = [...o];
|
|
33
|
+
return p[c] = l[o[c]] || "c", p;
|
|
34
|
+
}
|
|
35
|
+
function It(o) {
|
|
36
|
+
return o.join("");
|
|
34
37
|
}
|
|
35
|
-
function
|
|
36
|
-
const [m,
|
|
38
|
+
function je(o, c, l, p, A, X, Tt, K) {
|
|
39
|
+
const [m, Q] = k.useState({
|
|
37
40
|
ready: !1,
|
|
38
41
|
offsetX: 0,
|
|
39
42
|
offsetY: 0,
|
|
@@ -43,24 +46,24 @@ function Fe(o, c, l, p, d, Y, Lt, J) {
|
|
|
43
46
|
arrowY: 0,
|
|
44
47
|
scaleX: 1,
|
|
45
48
|
scaleY: 1,
|
|
46
|
-
align:
|
|
47
|
-
}), U = k.useRef(0),
|
|
49
|
+
align: A[p] || {}
|
|
50
|
+
}), U = k.useRef(0), Z = k.useMemo(() => !c || K ? [] : Be(c), [c]), u = k.useRef({});
|
|
48
51
|
o || (u.current = {});
|
|
49
|
-
const
|
|
50
|
-
if (c && l && o && !
|
|
51
|
-
let y = function(t,
|
|
52
|
-
const Yt = s.x + t, vt = s.y +
|
|
53
|
-
return Math.max(0, (
|
|
54
|
-
},
|
|
55
|
-
|
|
52
|
+
const Ft = ve(() => {
|
|
53
|
+
if (c && l && o && !K) {
|
|
54
|
+
let y = function(t, h, g = ft) {
|
|
55
|
+
const Yt = s.x + t, vt = s.y + h, be = Yt + v, de = vt + Y, Re = Math.max(Yt, g.left), we = Math.max(vt, g.top), Ae = Math.min(be, g.right), Pe = Math.min(de, g.bottom);
|
|
56
|
+
return Math.max(0, (Ae - Re) * (Pe - we));
|
|
57
|
+
}, bt = function() {
|
|
58
|
+
F = s.y + f, H = F + Y, S = s.x + r, D = S + v;
|
|
56
59
|
};
|
|
57
|
-
const e = c,
|
|
58
|
-
position:
|
|
59
|
-
} =
|
|
60
|
-
...
|
|
61
|
-
...
|
|
62
|
-
},
|
|
63
|
-
e.parentElement?.appendChild(
|
|
60
|
+
const e = c, et = e.ownerDocument, ot = Me(e), {
|
|
61
|
+
position: jt
|
|
62
|
+
} = ot.getComputedStyle(e), Nt = e.style.left, Wt = e.style.top, $t = e.style.right, Et = e.style.bottom, Ht = e.style.overflow, V = {
|
|
63
|
+
...A[p],
|
|
64
|
+
...X
|
|
65
|
+
}, P = et.createElement("div");
|
|
66
|
+
e.parentElement?.appendChild(P), P.style.left = `${e.offsetLeft}px`, P.style.top = `${e.offsetTop}px`, P.style.position = jt, P.style.height = `${e.offsetHeight}px`, P.style.width = `${e.offsetWidth}px`, e.style.left = "0", e.style.top = "0", e.style.right = "auto", e.style.bottom = "auto", e.style.overflow = "hidden";
|
|
64
67
|
let i;
|
|
65
68
|
if (Array.isArray(l))
|
|
66
69
|
i = {
|
|
@@ -79,133 +82,133 @@ function Fe(o, c, l, p, d, Y, Lt, J) {
|
|
|
79
82
|
};
|
|
80
83
|
}
|
|
81
84
|
const s = e.getBoundingClientRect(), {
|
|
82
|
-
height:
|
|
83
|
-
width:
|
|
84
|
-
} =
|
|
85
|
+
height: Dt,
|
|
86
|
+
width: kt
|
|
87
|
+
} = ot.getComputedStyle(e);
|
|
85
88
|
s.x = s.x ?? s.left, s.y = s.y ?? s.top;
|
|
86
89
|
const {
|
|
87
|
-
clientWidth:
|
|
88
|
-
clientHeight:
|
|
89
|
-
scrollWidth:
|
|
90
|
-
scrollHeight:
|
|
91
|
-
scrollTop:
|
|
92
|
-
scrollLeft:
|
|
93
|
-
} =
|
|
90
|
+
clientWidth: Ut,
|
|
91
|
+
clientHeight: _t,
|
|
92
|
+
scrollWidth: qt,
|
|
93
|
+
scrollHeight: zt,
|
|
94
|
+
scrollTop: nt,
|
|
95
|
+
scrollLeft: st
|
|
96
|
+
} = et.documentElement, Y = s.height, v = s.width, C = i.height, L = i.width, Gt = {
|
|
94
97
|
left: 0,
|
|
95
98
|
top: 0,
|
|
96
|
-
right:
|
|
97
|
-
bottom:
|
|
98
|
-
},
|
|
99
|
-
left: -
|
|
100
|
-
top: -
|
|
101
|
-
right:
|
|
102
|
-
bottom:
|
|
99
|
+
right: Ut,
|
|
100
|
+
bottom: _t
|
|
101
|
+
}, Jt = {
|
|
102
|
+
left: -st,
|
|
103
|
+
top: -nt,
|
|
104
|
+
right: qt - st,
|
|
105
|
+
bottom: zt - nt
|
|
103
106
|
};
|
|
104
107
|
let {
|
|
105
|
-
htmlRegion:
|
|
106
|
-
} =
|
|
107
|
-
const
|
|
108
|
-
|
|
109
|
-
const
|
|
108
|
+
htmlRegion: I
|
|
109
|
+
} = V;
|
|
110
|
+
const it = "visible", rt = "visibleFirst";
|
|
111
|
+
I !== "scroll" && I !== rt && (I = it);
|
|
112
|
+
const T = I === rt, Kt = Mt(Jt, Z), n = Mt(Gt, Z), ft = I === it ? n : Kt, W = T ? n : ft;
|
|
110
113
|
e.style.left = "auto", e.style.top = "auto", e.style.right = "0", e.style.bottom = "0";
|
|
111
|
-
const
|
|
112
|
-
e.style.left =
|
|
113
|
-
const B =
|
|
114
|
-
if (B === 0 || M === 0 ||
|
|
114
|
+
const lt = e.getBoundingClientRect();
|
|
115
|
+
e.style.left = Nt, e.style.top = Wt, e.style.right = $t, e.style.bottom = Et, e.style.overflow = Ht, e.parentElement?.removeChild(P);
|
|
116
|
+
const B = Ot(Math.round(v / parseFloat(kt) * 1e3) / 1e3), M = Ot(Math.round(Y / parseFloat(Dt) * 1e3) / 1e3);
|
|
117
|
+
if (B === 0 || M === 0 || Xe(l) && !Ye(l))
|
|
115
118
|
return;
|
|
116
119
|
const {
|
|
117
|
-
offset:
|
|
118
|
-
targetOffset:
|
|
119
|
-
} =
|
|
120
|
-
let [x, b] =
|
|
121
|
-
const [
|
|
122
|
-
i.x -=
|
|
123
|
-
const [
|
|
124
|
-
...
|
|
120
|
+
offset: Qt,
|
|
121
|
+
targetOffset: Zt
|
|
122
|
+
} = V;
|
|
123
|
+
let [x, b] = Ct(s, Qt);
|
|
124
|
+
const [te, ee] = Ct(i, Zt);
|
|
125
|
+
i.x -= te, i.y -= ee;
|
|
126
|
+
const [oe, ne] = V.points || [], $ = Lt(ne), d = Lt(oe), ct = O(i, $), pt = O(s, d), _ = {
|
|
127
|
+
...V
|
|
125
128
|
};
|
|
126
|
-
let r =
|
|
127
|
-
const R = y(r, f), E = y(r, f, n),
|
|
128
|
-
adjustX:
|
|
129
|
-
adjustY:
|
|
130
|
-
shiftX:
|
|
131
|
-
shiftY:
|
|
132
|
-
} =
|
|
133
|
-
let
|
|
134
|
-
|
|
135
|
-
const
|
|
136
|
-
if (
|
|
129
|
+
let a = [d, $], r = ct.x - pt.x + x, f = ct.y - pt.y + b;
|
|
130
|
+
const R = y(r, f), E = y(r, f, n), at = O(i, ["t", "l"]), ut = O(s, ["t", "l"]), ht = O(i, ["b", "r"]), gt = O(s, ["b", "r"]), se = V.overflow || {}, {
|
|
131
|
+
adjustX: ie,
|
|
132
|
+
adjustY: re,
|
|
133
|
+
shiftX: mt,
|
|
134
|
+
shiftY: yt
|
|
135
|
+
} = se, xt = (t) => typeof t == "boolean" ? t : t >= 0;
|
|
136
|
+
let F, H, S, D;
|
|
137
|
+
bt();
|
|
138
|
+
const dt = xt(re), Rt = d[0] === $[0];
|
|
139
|
+
if (dt && d[0] === "t" && (H > W.bottom || u.current.bt)) {
|
|
137
140
|
let t = f;
|
|
138
|
-
|
|
139
|
-
const
|
|
141
|
+
Rt ? t -= Y - C : t = at.y - gt.y - b;
|
|
142
|
+
const h = y(r, t), g = y(r, t, n);
|
|
140
143
|
// Of course use larger one
|
|
141
|
-
|
|
142
|
-
|
|
144
|
+
h > R || h === R && (!T || // Choose recommend one
|
|
145
|
+
g >= E) ? (u.current.bt = !0, f = t, b = -b, a = [w(a[0], 0), w(a[1], 0)]) : u.current.bt = !1;
|
|
143
146
|
}
|
|
144
|
-
if (
|
|
147
|
+
if (dt && d[0] === "b" && (F < W.top || u.current.tb)) {
|
|
145
148
|
let t = f;
|
|
146
|
-
|
|
147
|
-
const
|
|
149
|
+
Rt ? t += Y - C : t = ht.y - ut.y - b;
|
|
150
|
+
const h = y(r, t), g = y(r, t, n);
|
|
148
151
|
// Of course use larger one
|
|
149
|
-
|
|
150
|
-
|
|
152
|
+
h > R || h === R && (!T || // Choose recommend one
|
|
153
|
+
g >= E) ? (u.current.tb = !0, f = t, b = -b, a = [w(a[0], 0), w(a[1], 0)]) : u.current.tb = !1;
|
|
151
154
|
}
|
|
152
|
-
const
|
|
153
|
-
if (
|
|
155
|
+
const wt = xt(ie), At = d[1] === $[1];
|
|
156
|
+
if (wt && d[1] === "l" && (D > W.right || u.current.rl)) {
|
|
154
157
|
let t = r;
|
|
155
|
-
|
|
156
|
-
const
|
|
158
|
+
At ? t -= v - L : t = at.x - gt.x - x;
|
|
159
|
+
const h = y(t, f), g = y(t, f, n);
|
|
157
160
|
// Of course use larger one
|
|
158
|
-
|
|
159
|
-
|
|
161
|
+
h > R || h === R && (!T || // Choose recommend one
|
|
162
|
+
g >= E) ? (u.current.rl = !0, r = t, x = -x, a = [w(a[0], 1), w(a[1], 1)]) : u.current.rl = !1;
|
|
160
163
|
}
|
|
161
|
-
if (
|
|
164
|
+
if (wt && d[1] === "r" && (S < W.left || u.current.lr)) {
|
|
162
165
|
let t = r;
|
|
163
|
-
|
|
164
|
-
const
|
|
166
|
+
At ? t += v - L : t = ht.x - ut.x - x;
|
|
167
|
+
const h = y(t, f), g = y(t, f, n);
|
|
165
168
|
// Of course use larger one
|
|
166
|
-
|
|
167
|
-
|
|
169
|
+
h > R || h === R && (!T || // Choose recommend one
|
|
170
|
+
g >= E) ? (u.current.lr = !0, r = t, x = -x, a = [w(a[0], 1), w(a[1], 1)]) : u.current.lr = !1;
|
|
168
171
|
}
|
|
169
|
-
|
|
170
|
-
const
|
|
171
|
-
typeof
|
|
172
|
-
const
|
|
173
|
-
typeof
|
|
174
|
-
const
|
|
175
|
-
|
|
176
|
-
let
|
|
177
|
-
B === 1 && (r = Math.
|
|
178
|
-
const
|
|
172
|
+
_.points = [It(a[0]), It(a[1])], bt();
|
|
173
|
+
const j = mt === !0 ? 0 : mt;
|
|
174
|
+
typeof j == "number" && (S < n.left && (r -= S - n.left - x, i.x + L < n.left + j && (r += i.x - n.left + L - j)), D > n.right && (r -= D - n.right - x, i.x > n.right - j && (r += i.x - n.right + j)));
|
|
175
|
+
const N = yt === !0 ? 0 : yt;
|
|
176
|
+
typeof N == "number" && (F < n.top && (f -= F - n.top - b, i.y + C < n.top + N && (f += i.y - n.top + C - N)), H > n.bottom && (f -= H - n.bottom - b, i.y > n.bottom - N && (f += i.y - n.bottom + N)));
|
|
177
|
+
const q = s.x + r, fe = q + v, z = s.y + f, le = z + Y, Pt = i.x, ce = Pt + L, Xt = i.y, pe = Xt + C, ae = Math.max(q, Pt), ue = Math.min(fe, ce), he = (ae + ue) / 2 - q, ge = Math.max(z, Xt), me = Math.min(le, pe), ye = (ge + me) / 2 - z;
|
|
178
|
+
Tt?.(c, _);
|
|
179
|
+
let G = lt.right - s.x - (r + s.width), J = lt.bottom - s.y - (f + s.height);
|
|
180
|
+
B === 1 && (r = Math.floor(r), G = Math.floor(G)), M === 1 && (f = Math.floor(f), J = Math.floor(J));
|
|
181
|
+
const xe = {
|
|
179
182
|
ready: !0,
|
|
180
183
|
offsetX: r / B,
|
|
181
184
|
offsetY: f / M,
|
|
182
|
-
offsetR:
|
|
183
|
-
offsetB:
|
|
184
|
-
arrowX:
|
|
185
|
-
arrowY:
|
|
185
|
+
offsetR: G / B,
|
|
186
|
+
offsetB: J / M,
|
|
187
|
+
arrowX: he / B,
|
|
188
|
+
arrowY: ye / M,
|
|
186
189
|
scaleX: B,
|
|
187
190
|
scaleY: M,
|
|
188
|
-
align:
|
|
191
|
+
align: _
|
|
189
192
|
};
|
|
190
|
-
|
|
193
|
+
Q(xe);
|
|
191
194
|
}
|
|
192
|
-
}),
|
|
195
|
+
}), St = () => {
|
|
193
196
|
U.current += 1;
|
|
194
197
|
const e = U.current;
|
|
195
198
|
Promise.resolve().then(() => {
|
|
196
|
-
U.current === e &&
|
|
199
|
+
U.current === e && Ft();
|
|
197
200
|
});
|
|
198
|
-
},
|
|
199
|
-
|
|
201
|
+
}, tt = () => {
|
|
202
|
+
Q((e) => ({
|
|
200
203
|
...e,
|
|
201
204
|
ready: !1
|
|
202
205
|
}));
|
|
203
206
|
};
|
|
204
|
-
return
|
|
205
|
-
o ||
|
|
206
|
-
}, [o]), [m.ready, m.offsetX, m.offsetY, m.offsetR, m.offsetB, m.arrowX, m.arrowY, m.scaleX, m.scaleY, m.align,
|
|
207
|
+
return Bt(tt, [p]), Bt(() => {
|
|
208
|
+
o || tt();
|
|
209
|
+
}, [o]), [m.ready, m.offsetX, m.offsetY, m.offsetR, m.offsetB, m.arrowX, m.arrowY, m.scaleX, m.scaleY, m.align, St];
|
|
207
210
|
}
|
|
208
211
|
export {
|
|
209
|
-
|
|
212
|
+
je as default
|
|
210
213
|
};
|
|
211
214
|
//# sourceMappingURL=useAlign.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAlign.js","sources":["../../../../../../node_modules/@rc-component/trigger/es/hooks/useAlign.js"],"sourcesContent":["import { isDOM } from \"@rc-component/util/es/Dom/findDOMNode\";\nimport isVisible from \"@rc-component/util/es/Dom/isVisible\";\nimport useEvent from \"@rc-component/util/es/hooks/useEvent\";\nimport useLayoutEffect from \"@rc-component/util/es/hooks/useLayoutEffect\";\nimport * as React from 'react';\nimport { collectScroller, getVisibleArea, getWin, toNum } from \"../util\";\nfunction getUnitOffset(size, offset = 0) {\n const offsetStr = `${offset}`;\n const cells = offsetStr.match(/^(.*)\\%$/);\n if (cells) {\n return size * (parseFloat(cells[1]) / 100);\n }\n return parseFloat(offsetStr);\n}\nfunction getNumberOffset(rect, offset) {\n const [offsetX, offsetY] = offset || [];\n return [getUnitOffset(rect.width, offsetX), getUnitOffset(rect.height, offsetY)];\n}\nfunction splitPoints(points = '') {\n return [points[0], points[1]];\n}\nfunction getAlignPoint(rect, points) {\n const topBottom = points[0];\n const leftRight = points[1];\n let x;\n let y;\n\n // Top & Bottom\n if (topBottom === 't') {\n y = rect.y;\n } else if (topBottom === 'b') {\n y = rect.y + rect.height;\n } else {\n y = rect.y + rect.height / 2;\n }\n\n // Left & Right\n if (leftRight === 'l') {\n x = rect.x;\n } else if (leftRight === 'r') {\n x = rect.x + rect.width;\n } else {\n x = rect.x + rect.width / 2;\n }\n return {\n x,\n y\n };\n}\nfunction reversePoints(points, index) {\n const reverseMap = {\n t: 'b',\n b: 't',\n l: 'r',\n r: 'l'\n };\n return points.map((point, i) => {\n if (i === index) {\n return reverseMap[point] || 'c';\n }\n return point;\n }).join('');\n}\nexport default function useAlign(open, popupEle, target, placement, builtinPlacements, popupAlign, onPopupAlign, mobile) {\n const [offsetInfo, setOffsetInfo] = React.useState({\n ready: false,\n offsetX: 0,\n offsetY: 0,\n offsetR: 0,\n offsetB: 0,\n arrowX: 0,\n arrowY: 0,\n scaleX: 1,\n scaleY: 1,\n align: builtinPlacements[placement] || {}\n });\n const alignCountRef = React.useRef(0);\n const scrollerList = React.useMemo(() => {\n if (!popupEle || mobile) {\n return [];\n }\n return collectScroller(popupEle);\n }, [popupEle]);\n\n // ========================= Flip ==========================\n // We will memo flip info.\n // If size change to make flip, it will memo the flip info and use it in next align.\n const prevFlipRef = React.useRef({});\n const resetFlipCache = () => {\n prevFlipRef.current = {};\n };\n if (!open) {\n resetFlipCache();\n }\n\n // ========================= Align =========================\n const onAlign = useEvent(() => {\n if (popupEle && target && open && !mobile) {\n const popupElement = popupEle;\n const doc = popupElement.ownerDocument;\n const win = getWin(popupElement);\n const {\n position: popupPosition\n } = win.getComputedStyle(popupElement);\n const originLeft = popupElement.style.left;\n const originTop = popupElement.style.top;\n const originRight = popupElement.style.right;\n const originBottom = popupElement.style.bottom;\n const originOverflow = popupElement.style.overflow;\n\n // Placement\n const placementInfo = {\n ...builtinPlacements[placement],\n ...popupAlign\n };\n\n // placeholder element\n const placeholderElement = doc.createElement('div');\n popupElement.parentElement?.appendChild(placeholderElement);\n placeholderElement.style.left = `${popupElement.offsetLeft}px`;\n placeholderElement.style.top = `${popupElement.offsetTop}px`;\n placeholderElement.style.position = popupPosition;\n placeholderElement.style.height = `${popupElement.offsetHeight}px`;\n placeholderElement.style.width = `${popupElement.offsetWidth}px`;\n\n // Reset first\n popupElement.style.left = '0';\n popupElement.style.top = '0';\n popupElement.style.right = 'auto';\n popupElement.style.bottom = 'auto';\n popupElement.style.overflow = 'hidden';\n\n // Calculate align style, we should consider `transform` case\n let targetRect;\n if (Array.isArray(target)) {\n targetRect = {\n x: target[0],\n y: target[1],\n width: 0,\n height: 0\n };\n } else {\n const rect = target.getBoundingClientRect();\n rect.x = rect.x ?? rect.left;\n rect.y = rect.y ?? rect.top;\n targetRect = {\n x: rect.x,\n y: rect.y,\n width: rect.width,\n height: rect.height\n };\n }\n const popupRect = popupElement.getBoundingClientRect();\n const {\n height,\n width\n } = win.getComputedStyle(popupElement);\n popupRect.x = popupRect.x ?? popupRect.left;\n popupRect.y = popupRect.y ?? popupRect.top;\n const {\n clientWidth,\n clientHeight,\n scrollWidth,\n scrollHeight,\n scrollTop,\n scrollLeft\n } = doc.documentElement;\n const popupHeight = popupRect.height;\n const popupWidth = popupRect.width;\n const targetHeight = targetRect.height;\n const targetWidth = targetRect.width;\n\n // Get bounding of visible area\n const visibleRegion = {\n left: 0,\n top: 0,\n right: clientWidth,\n bottom: clientHeight\n };\n const scrollRegion = {\n left: -scrollLeft,\n top: -scrollTop,\n right: scrollWidth - scrollLeft,\n bottom: scrollHeight - scrollTop\n };\n let {\n htmlRegion\n } = placementInfo;\n const VISIBLE = 'visible';\n const VISIBLE_FIRST = 'visibleFirst';\n if (htmlRegion !== 'scroll' && htmlRegion !== VISIBLE_FIRST) {\n htmlRegion = VISIBLE;\n }\n const isVisibleFirst = htmlRegion === VISIBLE_FIRST;\n const scrollRegionArea = getVisibleArea(scrollRegion, scrollerList);\n const visibleRegionArea = getVisibleArea(visibleRegion, scrollerList);\n const visibleArea = htmlRegion === VISIBLE ? visibleRegionArea : scrollRegionArea;\n\n // When set to `visibleFirst`,\n // the check `adjust` logic will use `visibleRegion` for check first.\n const adjustCheckVisibleArea = isVisibleFirst ? visibleRegionArea : visibleArea;\n\n // Record right & bottom align data\n popupElement.style.left = 'auto';\n popupElement.style.top = 'auto';\n popupElement.style.right = '0';\n popupElement.style.bottom = '0';\n const popupMirrorRect = popupElement.getBoundingClientRect();\n\n // Reset back\n popupElement.style.left = originLeft;\n popupElement.style.top = originTop;\n popupElement.style.right = originRight;\n popupElement.style.bottom = originBottom;\n popupElement.style.overflow = originOverflow;\n popupElement.parentElement?.removeChild(placeholderElement);\n\n // Calculate scale\n const scaleX = toNum(Math.round(popupWidth / parseFloat(width) * 1000) / 1000);\n const scaleY = toNum(Math.round(popupHeight / parseFloat(height) * 1000) / 1000);\n\n // No need to align since it's not visible in view\n if (scaleX === 0 || scaleY === 0 || isDOM(target) && !isVisible(target)) {\n return;\n }\n\n // Offset\n const {\n offset,\n targetOffset\n } = placementInfo;\n let [popupOffsetX, popupOffsetY] = getNumberOffset(popupRect, offset);\n const [targetOffsetX, targetOffsetY] = getNumberOffset(targetRect, targetOffset);\n targetRect.x -= targetOffsetX;\n targetRect.y -= targetOffsetY;\n\n // Points\n const [popupPoint, targetPoint] = placementInfo.points || [];\n const targetPoints = splitPoints(targetPoint);\n const popupPoints = splitPoints(popupPoint);\n const targetAlignPoint = getAlignPoint(targetRect, targetPoints);\n const popupAlignPoint = getAlignPoint(popupRect, popupPoints);\n\n // Real align info may not same as origin one\n const nextAlignInfo = {\n ...placementInfo\n };\n\n // Next Offset\n let nextOffsetX = targetAlignPoint.x - popupAlignPoint.x + popupOffsetX;\n let nextOffsetY = targetAlignPoint.y - popupAlignPoint.y + popupOffsetY;\n\n // ============== Intersection ===============\n // Get area by position. Used for check if flip area is better\n function getIntersectionVisibleArea(offsetX, offsetY, area = visibleArea) {\n const l = popupRect.x + offsetX;\n const t = popupRect.y + offsetY;\n const r = l + popupWidth;\n const b = t + popupHeight;\n const visibleL = Math.max(l, area.left);\n const visibleT = Math.max(t, area.top);\n const visibleR = Math.min(r, area.right);\n const visibleB = Math.min(b, area.bottom);\n return Math.max(0, (visibleR - visibleL) * (visibleB - visibleT));\n }\n const originIntersectionVisibleArea = getIntersectionVisibleArea(nextOffsetX, nextOffsetY);\n\n // As `visibleFirst`, we prepare this for check\n const originIntersectionRecommendArea = getIntersectionVisibleArea(nextOffsetX, nextOffsetY, visibleRegionArea);\n\n // ========================== Overflow ===========================\n const targetAlignPointTL = getAlignPoint(targetRect, ['t', 'l']);\n const popupAlignPointTL = getAlignPoint(popupRect, ['t', 'l']);\n const targetAlignPointBR = getAlignPoint(targetRect, ['b', 'r']);\n const popupAlignPointBR = getAlignPoint(popupRect, ['b', 'r']);\n const overflow = placementInfo.overflow || {};\n const {\n adjustX,\n adjustY,\n shiftX,\n shiftY\n } = overflow;\n const supportAdjust = val => {\n if (typeof val === 'boolean') {\n return val;\n }\n return val >= 0;\n };\n\n // Prepare position\n let nextPopupY;\n let nextPopupBottom;\n let nextPopupX;\n let nextPopupRight;\n function syncNextPopupPosition() {\n nextPopupY = popupRect.y + nextOffsetY;\n nextPopupBottom = nextPopupY + popupHeight;\n nextPopupX = popupRect.x + nextOffsetX;\n nextPopupRight = nextPopupX + popupWidth;\n }\n syncNextPopupPosition();\n\n // >>>>>>>>>> Top & Bottom\n const needAdjustY = supportAdjust(adjustY);\n const sameTB = popupPoints[0] === targetPoints[0];\n\n // Bottom to Top\n if (needAdjustY && popupPoints[0] === 't' && (nextPopupBottom > adjustCheckVisibleArea.bottom || prevFlipRef.current.bt)) {\n let tmpNextOffsetY = nextOffsetY;\n if (sameTB) {\n tmpNextOffsetY -= popupHeight - targetHeight;\n } else {\n tmpNextOffsetY = targetAlignPointTL.y - popupAlignPointBR.y - popupOffsetY;\n }\n const newVisibleArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.bt = true;\n nextOffsetY = tmpNextOffsetY;\n popupOffsetY = -popupOffsetY;\n nextAlignInfo.points = [reversePoints(popupPoints, 0), reversePoints(targetPoints, 0)];\n } else {\n prevFlipRef.current.bt = false;\n }\n }\n\n // Top to Bottom\n if (needAdjustY && popupPoints[0] === 'b' && (nextPopupY < adjustCheckVisibleArea.top || prevFlipRef.current.tb)) {\n let tmpNextOffsetY = nextOffsetY;\n if (sameTB) {\n tmpNextOffsetY += popupHeight - targetHeight;\n } else {\n tmpNextOffsetY = targetAlignPointBR.y - popupAlignPointTL.y - popupOffsetY;\n }\n const newVisibleArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.tb = true;\n nextOffsetY = tmpNextOffsetY;\n popupOffsetY = -popupOffsetY;\n nextAlignInfo.points = [reversePoints(popupPoints, 0), reversePoints(targetPoints, 0)];\n } else {\n prevFlipRef.current.tb = false;\n }\n }\n\n // >>>>>>>>>> Left & Right\n const needAdjustX = supportAdjust(adjustX);\n\n // >>>>> Flip\n const sameLR = popupPoints[1] === targetPoints[1];\n\n // Right to Left\n if (needAdjustX && popupPoints[1] === 'l' && (nextPopupRight > adjustCheckVisibleArea.right || prevFlipRef.current.rl)) {\n let tmpNextOffsetX = nextOffsetX;\n if (sameLR) {\n tmpNextOffsetX -= popupWidth - targetWidth;\n } else {\n tmpNextOffsetX = targetAlignPointTL.x - popupAlignPointBR.x - popupOffsetX;\n }\n const newVisibleArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.rl = true;\n nextOffsetX = tmpNextOffsetX;\n popupOffsetX = -popupOffsetX;\n nextAlignInfo.points = [reversePoints(popupPoints, 1), reversePoints(targetPoints, 1)];\n } else {\n prevFlipRef.current.rl = false;\n }\n }\n\n // Left to Right\n if (needAdjustX && popupPoints[1] === 'r' && (nextPopupX < adjustCheckVisibleArea.left || prevFlipRef.current.lr)) {\n let tmpNextOffsetX = nextOffsetX;\n if (sameLR) {\n tmpNextOffsetX += popupWidth - targetWidth;\n } else {\n tmpNextOffsetX = targetAlignPointBR.x - popupAlignPointTL.x - popupOffsetX;\n }\n const newVisibleArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.lr = true;\n nextOffsetX = tmpNextOffsetX;\n popupOffsetX = -popupOffsetX;\n nextAlignInfo.points = [reversePoints(popupPoints, 1), reversePoints(targetPoints, 1)];\n } else {\n prevFlipRef.current.lr = false;\n }\n }\n\n // ============================ Shift ============================\n syncNextPopupPosition();\n const numShiftX = shiftX === true ? 0 : shiftX;\n if (typeof numShiftX === 'number') {\n // Left\n if (nextPopupX < visibleRegionArea.left) {\n nextOffsetX -= nextPopupX - visibleRegionArea.left - popupOffsetX;\n if (targetRect.x + targetWidth < visibleRegionArea.left + numShiftX) {\n nextOffsetX += targetRect.x - visibleRegionArea.left + targetWidth - numShiftX;\n }\n }\n\n // Right\n if (nextPopupRight > visibleRegionArea.right) {\n nextOffsetX -= nextPopupRight - visibleRegionArea.right - popupOffsetX;\n if (targetRect.x > visibleRegionArea.right - numShiftX) {\n nextOffsetX += targetRect.x - visibleRegionArea.right + numShiftX;\n }\n }\n }\n const numShiftY = shiftY === true ? 0 : shiftY;\n if (typeof numShiftY === 'number') {\n // Top\n if (nextPopupY < visibleRegionArea.top) {\n nextOffsetY -= nextPopupY - visibleRegionArea.top - popupOffsetY;\n\n // When target if far away from visible area\n // Stop shift\n if (targetRect.y + targetHeight < visibleRegionArea.top + numShiftY) {\n nextOffsetY += targetRect.y - visibleRegionArea.top + targetHeight - numShiftY;\n }\n }\n\n // Bottom\n if (nextPopupBottom > visibleRegionArea.bottom) {\n nextOffsetY -= nextPopupBottom - visibleRegionArea.bottom - popupOffsetY;\n if (targetRect.y > visibleRegionArea.bottom - numShiftY) {\n nextOffsetY += targetRect.y - visibleRegionArea.bottom + numShiftY;\n }\n }\n }\n\n // ============================ Arrow ============================\n // Arrow center align\n const popupLeft = popupRect.x + nextOffsetX;\n const popupRight = popupLeft + popupWidth;\n const popupTop = popupRect.y + nextOffsetY;\n const popupBottom = popupTop + popupHeight;\n const targetLeft = targetRect.x;\n const targetRight = targetLeft + targetWidth;\n const targetTop = targetRect.y;\n const targetBottom = targetTop + targetHeight;\n\n /** Max left of the popup and target element */\n const maxLeft = Math.max(popupLeft, targetLeft);\n /** Min right of the popup and target element */\n const minRight = Math.min(popupRight, targetRight);\n\n /** The center X of popup & target cross area */\n const xCenter = (maxLeft + minRight) / 2;\n /** Arrow X of popup offset */\n const nextArrowX = xCenter - popupLeft;\n const maxTop = Math.max(popupTop, targetTop);\n const minBottom = Math.min(popupBottom, targetBottom);\n const yCenter = (maxTop + minBottom) / 2;\n const nextArrowY = yCenter - popupTop;\n onPopupAlign?.(popupEle, nextAlignInfo);\n\n // Additional calculate right & bottom position\n let offsetX4Right = popupMirrorRect.right - popupRect.x - (nextOffsetX + popupRect.width);\n let offsetY4Bottom = popupMirrorRect.bottom - popupRect.y - (nextOffsetY + popupRect.height);\n if (scaleX === 1) {\n nextOffsetX = Math.round(nextOffsetX);\n offsetX4Right = Math.round(offsetX4Right);\n }\n if (scaleY === 1) {\n nextOffsetY = Math.round(nextOffsetY);\n offsetY4Bottom = Math.round(offsetY4Bottom);\n }\n const nextOffsetInfo = {\n ready: true,\n offsetX: nextOffsetX / scaleX,\n offsetY: nextOffsetY / scaleY,\n offsetR: offsetX4Right / scaleX,\n offsetB: offsetY4Bottom / scaleY,\n arrowX: nextArrowX / scaleX,\n arrowY: nextArrowY / scaleY,\n scaleX,\n scaleY,\n align: nextAlignInfo\n };\n setOffsetInfo(nextOffsetInfo);\n }\n });\n const triggerAlign = () => {\n alignCountRef.current += 1;\n const id = alignCountRef.current;\n\n // Merge all align requirement into one frame\n Promise.resolve().then(() => {\n if (alignCountRef.current === id) {\n onAlign();\n }\n });\n };\n\n // Reset ready status when placement & open changed\n const resetReady = () => {\n setOffsetInfo(ori => ({\n ...ori,\n ready: false\n }));\n };\n useLayoutEffect(resetReady, [placement]);\n useLayoutEffect(() => {\n if (!open) {\n resetReady();\n }\n }, [open]);\n return [offsetInfo.ready, offsetInfo.offsetX, offsetInfo.offsetY, offsetInfo.offsetR, offsetInfo.offsetB, offsetInfo.arrowX, offsetInfo.arrowY, offsetInfo.scaleX, offsetInfo.scaleY, offsetInfo.align, triggerAlign];\n}"],"names":["getUnitOffset","size","offset","offsetStr","cells","getNumberOffset","rect","offsetX","offsetY","splitPoints","points","getAlignPoint","topBottom","leftRight","x","y","reversePoints","index","reverseMap","point","i","useAlign","open","popupEle","target","placement","builtinPlacements","popupAlign","onPopupAlign","mobile","offsetInfo","setOffsetInfo","React","alignCountRef","scrollerList","collectScroller","prevFlipRef","onAlign","useEvent","getIntersectionVisibleArea","area","visibleArea","l","popupRect","t","r","popupWidth","b","popupHeight","visibleL","visibleT","visibleR","visibleB","syncNextPopupPosition","nextPopupY","nextOffsetY","nextPopupBottom","nextPopupX","nextOffsetX","nextPopupRight","popupElement","doc","win","getWin","popupPosition","originLeft","originTop","originRight","originBottom","originOverflow","placementInfo","placeholderElement","targetRect","height","width","clientWidth","clientHeight","scrollWidth","scrollHeight","scrollTop","scrollLeft","targetHeight","targetWidth","visibleRegion","scrollRegion","htmlRegion","VISIBLE","VISIBLE_FIRST","isVisibleFirst","scrollRegionArea","getVisibleArea","visibleRegionArea","adjustCheckVisibleArea","popupMirrorRect","scaleX","toNum","scaleY","isDOM","isVisible","targetOffset","popupOffsetX","popupOffsetY","targetOffsetX","targetOffsetY","popupPoint","targetPoint","targetPoints","popupPoints","targetAlignPoint","popupAlignPoint","nextAlignInfo","originIntersectionVisibleArea","originIntersectionRecommendArea","targetAlignPointTL","popupAlignPointTL","targetAlignPointBR","popupAlignPointBR","overflow","adjustX","adjustY","shiftX","shiftY","supportAdjust","val","needAdjustY","sameTB","tmpNextOffsetY","newVisibleArea","newVisibleRecommendArea","needAdjustX","sameLR","tmpNextOffsetX","numShiftX","numShiftY","popupLeft","popupRight","popupTop","popupBottom","targetLeft","targetRight","targetTop","targetBottom","maxLeft","minRight","nextArrowX","maxTop","minBottom","nextArrowY","offsetX4Right","offsetY4Bottom","nextOffsetInfo","triggerAlign","id","resetReady","ori","useLayoutEffect"],"mappings":";;;;;;AAMA,SAASA,GAAcC,GAAMC,IAAS,GAAG;AACvC,QAAMC,IAAY,GAAGD,CAAM,IACrBE,IAAQD,EAAU,MAAM,UAAU;AACxC,SAAIC,IACKH,KAAQ,WAAWG,EAAM,CAAC,CAAC,IAAI,OAEjC,WAAWD,CAAS;AAC7B;AACA,SAASE,GAAgBC,GAAMJ,GAAQ;AACrC,QAAM,CAACK,GAASC,CAAO,IAAIN,KAAU,CAAA;AACrC,SAAO,CAACF,GAAcM,EAAK,OAAOC,CAAO,GAAGP,GAAcM,EAAK,QAAQE,CAAO,CAAC;AACjF;AACA,SAASC,GAAYC,IAAS,IAAI;AAChC,SAAO,CAACA,EAAO,CAAC,GAAGA,EAAO,CAAC,CAAC;AAC9B;AACA,SAASC,EA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AAA,QACrB,OAAO;AAAA,QACP,SAAS5F,IAAcoC;AAAA,QACvB,SAASvC,IAAcyC;AAAA,QACvB,SAASoD,IAAgBtD;AAAA,QACzB,SAASuD,IAAiBrD;AAAA,QAC1B,QAAQgD,KAAalD;AAAA,QACrB,QAAQqD,KAAanD;AAAA,QACrB,QAAAF;AAAA,QACA,QAAAE;AAAA,QACA,OAAOc;AAAA,MACf;AACM,MAAA/E,EAAcuH,EAAc;AAAA,IAC9B;AAAA,EACF,CAAC,GACKC,KAAe,MAAM;AACzB,IAAAtH,EAAc,WAAW;AACzB,UAAMuH,IAAKvH,EAAc;AAGzB,YAAQ,UAAU,KAAK,MAAM;AAC3B,MAAIA,EAAc,YAAYuH,KAC5BnH,GAAO;AAAA,IAEX,CAAC;AAAA,EACH,GAGMoH,IAAa,MAAM;AACvB,IAAA1H,EAAc,CAAA2H,OAAQ;AAAA,MACpB,GAAGA;AAAA,MACH,OAAO;AAAA,IACb,EAAM;AAAA,EACJ;AACA,SAAAC,GAAgBF,GAAY,CAAChI,CAAS,CAAC,GACvCkI,GAAgB,MAAM;AACpB,IAAKrI,KACHmI,EAAU;AAAA,EAEd,GAAG,CAACnI,CAAI,CAAC,GACF,CAACQ,EAAW,OAAOA,EAAW,SAASA,EAAW,SAASA,EAAW,SAASA,EAAW,SAASA,EAAW,QAAQA,EAAW,QAAQA,EAAW,QAAQA,EAAW,QAAQA,EAAW,OAAOyH,EAAY;AACtN;","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"useAlign.js","sources":["../../../../../../node_modules/@rc-component/trigger/es/hooks/useAlign.js"],"sourcesContent":["import { isDOM } from \"@rc-component/util/es/Dom/findDOMNode\";\nimport isVisible from \"@rc-component/util/es/Dom/isVisible\";\nimport useEvent from \"@rc-component/util/es/hooks/useEvent\";\nimport useLayoutEffect from \"@rc-component/util/es/hooks/useLayoutEffect\";\nimport * as React from 'react';\nimport { collectScroller, getVisibleArea, getWin, toNum } from \"../util\";\nfunction getUnitOffset(size, offset = 0) {\n const offsetStr = `${offset}`;\n const cells = offsetStr.match(/^(.*)\\%$/);\n if (cells) {\n return size * (parseFloat(cells[1]) / 100);\n }\n return parseFloat(offsetStr);\n}\nfunction getNumberOffset(rect, offset) {\n const [offsetX, offsetY] = offset || [];\n return [getUnitOffset(rect.width, offsetX), getUnitOffset(rect.height, offsetY)];\n}\nfunction splitPoints(points = '') {\n return [points[0], points[1]];\n}\nfunction getAlignPoint(rect, points) {\n const topBottom = points[0];\n const leftRight = points[1];\n let x;\n let y;\n\n // Top & Bottom\n if (topBottom === 't') {\n y = rect.y;\n } else if (topBottom === 'b') {\n y = rect.y + rect.height;\n } else {\n y = rect.y + rect.height / 2;\n }\n\n // Left & Right\n if (leftRight === 'l') {\n x = rect.x;\n } else if (leftRight === 'r') {\n x = rect.x + rect.width;\n } else {\n x = rect.x + rect.width / 2;\n }\n return {\n x,\n y\n };\n}\nfunction reversePoints(points, index) {\n const reverseMap = {\n t: 'b',\n b: 't',\n l: 'r',\n r: 'l'\n };\n const clone = [...points];\n clone[index] = reverseMap[points[index]] || 'c';\n return clone;\n}\nfunction flatPoints(points) {\n return points.join('');\n}\nexport default function useAlign(open, popupEle, target, placement, builtinPlacements, popupAlign, onPopupAlign, mobile) {\n const [offsetInfo, setOffsetInfo] = React.useState({\n ready: false,\n offsetX: 0,\n offsetY: 0,\n offsetR: 0,\n offsetB: 0,\n arrowX: 0,\n arrowY: 0,\n scaleX: 1,\n scaleY: 1,\n align: builtinPlacements[placement] || {}\n });\n const alignCountRef = React.useRef(0);\n const scrollerList = React.useMemo(() => {\n if (!popupEle || mobile) {\n return [];\n }\n return collectScroller(popupEle);\n }, [popupEle]);\n\n // ========================= Flip ==========================\n // We will memo flip info.\n // If size change to make flip, it will memo the flip info and use it in next align.\n const prevFlipRef = React.useRef({});\n const resetFlipCache = () => {\n prevFlipRef.current = {};\n };\n if (!open) {\n resetFlipCache();\n }\n\n // ========================= Align =========================\n const onAlign = useEvent(() => {\n if (popupEle && target && open && !mobile) {\n const popupElement = popupEle;\n const doc = popupElement.ownerDocument;\n const win = getWin(popupElement);\n const {\n position: popupPosition\n } = win.getComputedStyle(popupElement);\n const originLeft = popupElement.style.left;\n const originTop = popupElement.style.top;\n const originRight = popupElement.style.right;\n const originBottom = popupElement.style.bottom;\n const originOverflow = popupElement.style.overflow;\n\n // Placement\n const placementInfo = {\n ...builtinPlacements[placement],\n ...popupAlign\n };\n\n // placeholder element\n const placeholderElement = doc.createElement('div');\n popupElement.parentElement?.appendChild(placeholderElement);\n placeholderElement.style.left = `${popupElement.offsetLeft}px`;\n placeholderElement.style.top = `${popupElement.offsetTop}px`;\n placeholderElement.style.position = popupPosition;\n placeholderElement.style.height = `${popupElement.offsetHeight}px`;\n placeholderElement.style.width = `${popupElement.offsetWidth}px`;\n\n // Reset first\n popupElement.style.left = '0';\n popupElement.style.top = '0';\n popupElement.style.right = 'auto';\n popupElement.style.bottom = 'auto';\n popupElement.style.overflow = 'hidden';\n\n // Calculate align style, we should consider `transform` case\n let targetRect;\n if (Array.isArray(target)) {\n targetRect = {\n x: target[0],\n y: target[1],\n width: 0,\n height: 0\n };\n } else {\n const rect = target.getBoundingClientRect();\n rect.x = rect.x ?? rect.left;\n rect.y = rect.y ?? rect.top;\n targetRect = {\n x: rect.x,\n y: rect.y,\n width: rect.width,\n height: rect.height\n };\n }\n const popupRect = popupElement.getBoundingClientRect();\n const {\n height,\n width\n } = win.getComputedStyle(popupElement);\n popupRect.x = popupRect.x ?? popupRect.left;\n popupRect.y = popupRect.y ?? popupRect.top;\n const {\n clientWidth,\n clientHeight,\n scrollWidth,\n scrollHeight,\n scrollTop,\n scrollLeft\n } = doc.documentElement;\n const popupHeight = popupRect.height;\n const popupWidth = popupRect.width;\n const targetHeight = targetRect.height;\n const targetWidth = targetRect.width;\n\n // Get bounding of visible area\n const visibleRegion = {\n left: 0,\n top: 0,\n right: clientWidth,\n bottom: clientHeight\n };\n const scrollRegion = {\n left: -scrollLeft,\n top: -scrollTop,\n right: scrollWidth - scrollLeft,\n bottom: scrollHeight - scrollTop\n };\n let {\n htmlRegion\n } = placementInfo;\n const VISIBLE = 'visible';\n const VISIBLE_FIRST = 'visibleFirst';\n if (htmlRegion !== 'scroll' && htmlRegion !== VISIBLE_FIRST) {\n htmlRegion = VISIBLE;\n }\n const isVisibleFirst = htmlRegion === VISIBLE_FIRST;\n const scrollRegionArea = getVisibleArea(scrollRegion, scrollerList);\n const visibleRegionArea = getVisibleArea(visibleRegion, scrollerList);\n const visibleArea = htmlRegion === VISIBLE ? visibleRegionArea : scrollRegionArea;\n\n // When set to `visibleFirst`,\n // the check `adjust` logic will use `visibleRegion` for check first.\n const adjustCheckVisibleArea = isVisibleFirst ? visibleRegionArea : visibleArea;\n\n // Record right & bottom align data\n popupElement.style.left = 'auto';\n popupElement.style.top = 'auto';\n popupElement.style.right = '0';\n popupElement.style.bottom = '0';\n const popupMirrorRect = popupElement.getBoundingClientRect();\n\n // Reset back\n popupElement.style.left = originLeft;\n popupElement.style.top = originTop;\n popupElement.style.right = originRight;\n popupElement.style.bottom = originBottom;\n popupElement.style.overflow = originOverflow;\n popupElement.parentElement?.removeChild(placeholderElement);\n\n // Calculate scale\n const scaleX = toNum(Math.round(popupWidth / parseFloat(width) * 1000) / 1000);\n const scaleY = toNum(Math.round(popupHeight / parseFloat(height) * 1000) / 1000);\n\n // No need to align since it's not visible in view\n if (scaleX === 0 || scaleY === 0 || isDOM(target) && !isVisible(target)) {\n return;\n }\n\n // Offset\n const {\n offset,\n targetOffset\n } = placementInfo;\n let [popupOffsetX, popupOffsetY] = getNumberOffset(popupRect, offset);\n const [targetOffsetX, targetOffsetY] = getNumberOffset(targetRect, targetOffset);\n targetRect.x -= targetOffsetX;\n targetRect.y -= targetOffsetY;\n\n // Points\n const [popupPoint, targetPoint] = placementInfo.points || [];\n const targetPoints = splitPoints(targetPoint);\n const popupPoints = splitPoints(popupPoint);\n const targetAlignPoint = getAlignPoint(targetRect, targetPoints);\n const popupAlignPoint = getAlignPoint(popupRect, popupPoints);\n\n // Real align info may not same as origin one\n const nextAlignInfo = {\n ...placementInfo\n };\n let nextPoints = [popupPoints, targetPoints];\n\n // Next Offset\n let nextOffsetX = targetAlignPoint.x - popupAlignPoint.x + popupOffsetX;\n let nextOffsetY = targetAlignPoint.y - popupAlignPoint.y + popupOffsetY;\n\n // ============== Intersection ===============\n // Get area by position. Used for check if flip area is better\n function getIntersectionVisibleArea(offsetX, offsetY, area = visibleArea) {\n const l = popupRect.x + offsetX;\n const t = popupRect.y + offsetY;\n const r = l + popupWidth;\n const b = t + popupHeight;\n const visibleL = Math.max(l, area.left);\n const visibleT = Math.max(t, area.top);\n const visibleR = Math.min(r, area.right);\n const visibleB = Math.min(b, area.bottom);\n return Math.max(0, (visibleR - visibleL) * (visibleB - visibleT));\n }\n const originIntersectionVisibleArea = getIntersectionVisibleArea(nextOffsetX, nextOffsetY);\n\n // As `visibleFirst`, we prepare this for check\n const originIntersectionRecommendArea = getIntersectionVisibleArea(nextOffsetX, nextOffsetY, visibleRegionArea);\n\n // ========================== Overflow ===========================\n const targetAlignPointTL = getAlignPoint(targetRect, ['t', 'l']);\n const popupAlignPointTL = getAlignPoint(popupRect, ['t', 'l']);\n const targetAlignPointBR = getAlignPoint(targetRect, ['b', 'r']);\n const popupAlignPointBR = getAlignPoint(popupRect, ['b', 'r']);\n const overflow = placementInfo.overflow || {};\n const {\n adjustX,\n adjustY,\n shiftX,\n shiftY\n } = overflow;\n const supportAdjust = val => {\n if (typeof val === 'boolean') {\n return val;\n }\n return val >= 0;\n };\n\n // Prepare position\n let nextPopupY;\n let nextPopupBottom;\n let nextPopupX;\n let nextPopupRight;\n function syncNextPopupPosition() {\n nextPopupY = popupRect.y + nextOffsetY;\n nextPopupBottom = nextPopupY + popupHeight;\n nextPopupX = popupRect.x + nextOffsetX;\n nextPopupRight = nextPopupX + popupWidth;\n }\n syncNextPopupPosition();\n\n // >>>>>>>>>> Top & Bottom\n const needAdjustY = supportAdjust(adjustY);\n const sameTB = popupPoints[0] === targetPoints[0];\n\n // Bottom to Top\n if (needAdjustY && popupPoints[0] === 't' && (nextPopupBottom > adjustCheckVisibleArea.bottom || prevFlipRef.current.bt)) {\n let tmpNextOffsetY = nextOffsetY;\n if (sameTB) {\n tmpNextOffsetY -= popupHeight - targetHeight;\n } else {\n tmpNextOffsetY = targetAlignPointTL.y - popupAlignPointBR.y - popupOffsetY;\n }\n const newVisibleArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.bt = true;\n nextOffsetY = tmpNextOffsetY;\n popupOffsetY = -popupOffsetY;\n nextPoints = [reversePoints(nextPoints[0], 0), reversePoints(nextPoints[1], 0)];\n } else {\n prevFlipRef.current.bt = false;\n }\n }\n\n // Top to Bottom\n if (needAdjustY && popupPoints[0] === 'b' && (nextPopupY < adjustCheckVisibleArea.top || prevFlipRef.current.tb)) {\n let tmpNextOffsetY = nextOffsetY;\n if (sameTB) {\n tmpNextOffsetY += popupHeight - targetHeight;\n } else {\n tmpNextOffsetY = targetAlignPointBR.y - popupAlignPointTL.y - popupOffsetY;\n }\n const newVisibleArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(nextOffsetX, tmpNextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.tb = true;\n nextOffsetY = tmpNextOffsetY;\n popupOffsetY = -popupOffsetY;\n nextPoints = [reversePoints(nextPoints[0], 0), reversePoints(nextPoints[1], 0)];\n } else {\n prevFlipRef.current.tb = false;\n }\n }\n\n // >>>>>>>>>> Left & Right\n const needAdjustX = supportAdjust(adjustX);\n\n // >>>>> Flip\n const sameLR = popupPoints[1] === targetPoints[1];\n\n // Right to Left\n if (needAdjustX && popupPoints[1] === 'l' && (nextPopupRight > adjustCheckVisibleArea.right || prevFlipRef.current.rl)) {\n let tmpNextOffsetX = nextOffsetX;\n if (sameLR) {\n tmpNextOffsetX -= popupWidth - targetWidth;\n } else {\n tmpNextOffsetX = targetAlignPointTL.x - popupAlignPointBR.x - popupOffsetX;\n }\n const newVisibleArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.rl = true;\n nextOffsetX = tmpNextOffsetX;\n popupOffsetX = -popupOffsetX;\n nextPoints = [reversePoints(nextPoints[0], 1), reversePoints(nextPoints[1], 1)];\n } else {\n prevFlipRef.current.rl = false;\n }\n }\n\n // Left to Right\n if (needAdjustX && popupPoints[1] === 'r' && (nextPopupX < adjustCheckVisibleArea.left || prevFlipRef.current.lr)) {\n let tmpNextOffsetX = nextOffsetX;\n if (sameLR) {\n tmpNextOffsetX += popupWidth - targetWidth;\n } else {\n tmpNextOffsetX = targetAlignPointBR.x - popupAlignPointTL.x - popupOffsetX;\n }\n const newVisibleArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY);\n const newVisibleRecommendArea = getIntersectionVisibleArea(tmpNextOffsetX, nextOffsetY, visibleRegionArea);\n if (\n // Of course use larger one\n newVisibleArea > originIntersectionVisibleArea || newVisibleArea === originIntersectionVisibleArea && (!isVisibleFirst ||\n // Choose recommend one\n newVisibleRecommendArea >= originIntersectionRecommendArea)) {\n prevFlipRef.current.lr = true;\n nextOffsetX = tmpNextOffsetX;\n popupOffsetX = -popupOffsetX;\n nextPoints = [reversePoints(nextPoints[0], 1), reversePoints(nextPoints[1], 1)];\n } else {\n prevFlipRef.current.lr = false;\n }\n }\n nextAlignInfo.points = [flatPoints(nextPoints[0]), flatPoints(nextPoints[1])];\n\n // ============================ Shift ============================\n syncNextPopupPosition();\n const numShiftX = shiftX === true ? 0 : shiftX;\n if (typeof numShiftX === 'number') {\n // Left\n if (nextPopupX < visibleRegionArea.left) {\n nextOffsetX -= nextPopupX - visibleRegionArea.left - popupOffsetX;\n if (targetRect.x + targetWidth < visibleRegionArea.left + numShiftX) {\n nextOffsetX += targetRect.x - visibleRegionArea.left + targetWidth - numShiftX;\n }\n }\n\n // Right\n if (nextPopupRight > visibleRegionArea.right) {\n nextOffsetX -= nextPopupRight - visibleRegionArea.right - popupOffsetX;\n if (targetRect.x > visibleRegionArea.right - numShiftX) {\n nextOffsetX += targetRect.x - visibleRegionArea.right + numShiftX;\n }\n }\n }\n const numShiftY = shiftY === true ? 0 : shiftY;\n if (typeof numShiftY === 'number') {\n // Top\n if (nextPopupY < visibleRegionArea.top) {\n nextOffsetY -= nextPopupY - visibleRegionArea.top - popupOffsetY;\n\n // When target if far away from visible area\n // Stop shift\n if (targetRect.y + targetHeight < visibleRegionArea.top + numShiftY) {\n nextOffsetY += targetRect.y - visibleRegionArea.top + targetHeight - numShiftY;\n }\n }\n\n // Bottom\n if (nextPopupBottom > visibleRegionArea.bottom) {\n nextOffsetY -= nextPopupBottom - visibleRegionArea.bottom - popupOffsetY;\n if (targetRect.y > visibleRegionArea.bottom - numShiftY) {\n nextOffsetY += targetRect.y - visibleRegionArea.bottom + numShiftY;\n }\n }\n }\n\n // ============================ Arrow ============================\n // Arrow center align\n const popupLeft = popupRect.x + nextOffsetX;\n const popupRight = popupLeft + popupWidth;\n const popupTop = popupRect.y + nextOffsetY;\n const popupBottom = popupTop + popupHeight;\n const targetLeft = targetRect.x;\n const targetRight = targetLeft + targetWidth;\n const targetTop = targetRect.y;\n const targetBottom = targetTop + targetHeight;\n\n /** Max left of the popup and target element */\n const maxLeft = Math.max(popupLeft, targetLeft);\n /** Min right of the popup and target element */\n const minRight = Math.min(popupRight, targetRight);\n\n /** The center X of popup & target cross area */\n const xCenter = (maxLeft + minRight) / 2;\n /** Arrow X of popup offset */\n const nextArrowX = xCenter - popupLeft;\n const maxTop = Math.max(popupTop, targetTop);\n const minBottom = Math.min(popupBottom, targetBottom);\n const yCenter = (maxTop + minBottom) / 2;\n const nextArrowY = yCenter - popupTop;\n onPopupAlign?.(popupEle, nextAlignInfo);\n\n // Additional calculate right & bottom position\n let offsetX4Right = popupMirrorRect.right - popupRect.x - (nextOffsetX + popupRect.width);\n let offsetY4Bottom = popupMirrorRect.bottom - popupRect.y - (nextOffsetY + popupRect.height);\n if (scaleX === 1) {\n nextOffsetX = Math.floor(nextOffsetX);\n offsetX4Right = Math.floor(offsetX4Right);\n }\n if (scaleY === 1) {\n nextOffsetY = Math.floor(nextOffsetY);\n offsetY4Bottom = Math.floor(offsetY4Bottom);\n }\n const nextOffsetInfo = {\n ready: true,\n offsetX: nextOffsetX / scaleX,\n offsetY: nextOffsetY / scaleY,\n offsetR: offsetX4Right / scaleX,\n offsetB: offsetY4Bottom / scaleY,\n arrowX: nextArrowX / scaleX,\n arrowY: nextArrowY / scaleY,\n scaleX,\n scaleY,\n align: nextAlignInfo\n };\n setOffsetInfo(nextOffsetInfo);\n }\n });\n const triggerAlign = () => {\n alignCountRef.current += 1;\n const id = alignCountRef.current;\n\n // Merge all align requirement into one frame\n Promise.resolve().then(() => {\n if (alignCountRef.current === id) {\n onAlign();\n }\n });\n };\n\n // Reset ready status when placement & open changed\n const resetReady = () => {\n setOffsetInfo(ori => ({\n ...ori,\n ready: false\n }));\n };\n useLayoutEffect(resetReady, [placement]);\n useLayoutEffect(() => {\n if (!open) {\n resetReady();\n }\n }, [open]);\n return [offsetInfo.ready, offsetInfo.offsetX, offsetInfo.offsetY, offsetInfo.offsetR, offsetInfo.offsetB, offsetInfo.arrowX, offsetInfo.arrowY, offsetInfo.scaleX, offsetInfo.scaleY, offsetInfo.align, triggerAlign];\n}"],"names":["getUnitOffset","size","offset","offsetStr","cells","getNumberOffset","rect","offsetX","offsetY","splitPoints","points","getAlignPoint","topBottom","leftRight","x","y","reversePoints","index","reverseMap","clone","flatPoints","useAlign","open","popupEle","target","placement","builtinPlacements","popupAlign","onPopupAlign","mobile","offsetInfo","setOffsetInfo","React","alignCountRef","scrollerList","collectScroller","prevFlipRef","onAlign","useEvent","getIntersectionVisibleArea","area","visibleArea","l","popupRect","t","r","popupWidth","b","popupHeight","visibleL","visibleT","visibleR","visibleB","syncNextPopupPosition","nextPopupY","nextOffsetY","nextPopupBottom","nextPopupX","nextOffsetX","nextPopupRight","popupElement","doc","win","getWin","popupPosition","originLeft","originTop","originRight","originBottom","originOverflow","placementInfo","placeholderElement","targetRect","height","width","clientWidth","clientHeight","scrollWidth","scrollHeight","scrollTop","scrollLeft","targetHeight","targetWidth","visibleRegion","scrollRegion","htmlRegion","VISIBLE","VISIBLE_FIRST","isVisibleFirst","scrollRegionArea","getVisibleArea","visibleRegionArea","adjustCheckVisibleArea","popupMirrorRect","scaleX","toNum","scaleY","isDOM","isVisible","targetOffset","popupOffsetX","popupOffsetY","targetOffsetX","targetOffsetY","popupPoint","targetPoint","targetPoints","popupPoints","targetAlignPoint","popupAlignPoint","nextAlignInfo","nextPoints","originIntersectionVisibleArea","originIntersectionRecommendArea","targetAlignPointTL","popupAlignPointTL","targetAlignPointBR","popupAlignPointBR","overflow","adjustX","adjustY","shiftX","shiftY","supportAdjust","val","needAdjustY","sameTB","tmpNextOffsetY","newVisibleArea","newVisibleRecommendArea","needAdjustX","sameLR","tmpNextOffsetX","numShiftX","numShiftY","popupLeft","popupRight","popupTop","popupBottom","targetLeft","targetRight","targetTop","targetBottom","maxLeft","minRight","nextArrowX","maxTop","minBottom","nextArrowY","offsetX4Right","offsetY4Bottom","nextOffsetInfo","triggerAlign","id","resetReady","ori","useLayoutEffect"],"mappings":";;;;;;AAMA,SAASA,GAAcC,GAAMC,IAAS,GAAG;AACvC,QAAMC,IAAY,GAAGD,CAAM,IACrBE,IAAQD,EAAU,MAAM,UAAU;AACxC,SAAIC,IACKH,KAAQ,WAAWG,EAAM,CAAC,CAAC,IAAI,OAEjC,WAAWD,CAAS;AAC7B;AACA,SAASE,GAAgBC,GAAMJ,GAAQ;AACrC,QAAM,CAACK,GAASC,CAAO,IAAIN,KAAU,CAAA;AACrC,SAAO,CAACF,GAAcM,EAAK,OAAOC,CAAO,GAAGP,GAAcM,EAAK,QAAQE,CAAO,CAAC;AACjF;AACA,SAASC,GAAYC,IAAS,IAAI;AAChC,SAAO,CAACA,EAAO,CAAC,GAAGA,EAAO,CAAC,CAAC;AAC9B;AACA,SAASC,EAAcL,GAAMI,GAAQ;AACnC,QAAME,IAAYF,EAAO,CAAC,GACpBG,IAAYH,EAAO,CAAC;AAC1B,MAAII,GACAC;AAGJ,SAAIH,MAAc,MAChBG,IAAIT,EAAK,IACAM,MAAc,MACvBG,IAAIT,EAAK,IAAIA,EAAK,SAElBS,IAAIT,EAAK,IAAIA,EAAK,SAAS,GAIzBO,MAAc,MAChBC,IAAIR,EAAK,IACAO,MAAc,MACvBC,IAAIR,EAAK,IAAIA,EAAK,QAElBQ,IAAIR,EAAK,IAAIA,EAAK,QAAQ,GAErB;AAAA,IACL,GAAAQ;AAAA,IACA,GAAAC;AAAA,EACJ;AACA;AACA,SAASC,EAAcN,GAAQO,GAAO;AACpC,QAAMC,IAAa;AAAA,IACjB,GAAG;AAAA,IACH,GAAG;AAAA,IACH,GAAG;AAAA,IACH,GAAG;AAAA,EACP,GACQC,IAAQ,CAAC,GAAGT,CAAM;AACxB,SAAAS,EAAMF,CAAK,IAAIC,EAAWR,EAAOO,CAAK,CAAC,KAAK,KACrCE;AACT;AACA,SAAS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