@oracle/oraclejet-preact 20.0.3 → 20.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/amd/BarChart-e3c190b5.js +2 -0
- package/amd/BarChart-e3c190b5.js.map +1 -0
- package/amd/BaseCardView-16fda4c3.js +2 -0
- package/amd/BaseCardView-16fda4c3.js.map +1 -0
- package/amd/BaseDiagram-b9695479.js +2 -0
- package/amd/BaseDiagram-b9695479.js.map +1 -0
- package/amd/ButtonSetButton-ded680bb.js +2 -0
- package/amd/ButtonSetButton-ded680bb.js.map +1 -0
- package/amd/ButtonSetIconButton-c4dcbd9a.js +2 -0
- package/amd/ButtonSetIconButton-c4dcbd9a.js.map +1 -0
- package/amd/ButtonSetItem-4d644b7d.js +2 -0
- package/amd/ButtonSetItem-4d644b7d.js.map +1 -0
- package/amd/CardFlexView-d3eb7373.js +2 -0
- package/amd/CardFlexView-d3eb7373.js.map +1 -0
- package/amd/CardGridView-842f70cd.js +2 -0
- package/amd/CardGridView-842f70cd.js.map +1 -0
- package/amd/Chart-00a1b01f.js +2 -0
- package/amd/Chart-00a1b01f.js.map +1 -0
- package/amd/ComboChart-36e22cb8.js +2 -0
- package/amd/ComboChart-36e22cb8.js.map +1 -0
- package/amd/ContainerDiagram-6f41a26a.js +2 -0
- package/amd/ContainerDiagram-6f41a26a.js.map +1 -0
- package/amd/DatePicker-cf0e3fcd.js +2 -0
- package/amd/DatePicker-cf0e3fcd.js.map +1 -0
- package/amd/DatePickerHeader-406aa5c6.js +2 -0
- package/amd/DatePickerHeader-406aa5c6.js.map +1 -0
- package/amd/Diagram-6072b867.js +2 -0
- package/amd/Diagram-6072b867.js.map +1 -0
- package/amd/Dropdown-7cc463f6.js +2 -0
- package/amd/Dropdown-7cc463f6.js.map +1 -0
- package/amd/IconMenuButton-ec28ecfb.js +2 -0
- package/amd/IconMenuButton-ec28ecfb.js.map +1 -0
- package/amd/IconSwitchButton-28f4854a.js +2 -0
- package/amd/IconSwitchButton-28f4854a.js.map +1 -0
- package/amd/IconToggleButton-56035aa0.js +2 -0
- package/amd/IconToggleButton-56035aa0.js.map +1 -0
- package/amd/InlineSelectSingle-a1c1f520.js +2 -0
- package/amd/InlineSelectSingle-a1c1f520.js.map +1 -0
- package/amd/InputColor-bde91b03.js +2 -0
- package/amd/InputColor-bde91b03.js.map +1 -0
- package/amd/InputDatePicker-3351af0f.js +2 -0
- package/amd/InputDatePicker-3351af0f.js.map +1 -0
- package/amd/InputPassword-59369c13.js +2 -0
- package/amd/InputPassword-59369c13.js.map +1 -0
- package/amd/InputSensitiveText-ad79acc4.js +2 -0
- package/amd/InputSensitiveText-ad79acc4.js.map +1 -0
- package/amd/Legend-482f99eb.js +2 -0
- package/amd/Legend-482f99eb.js.map +1 -0
- package/amd/LineAreaChart-6f5dabc1.js +2 -0
- package/amd/LineAreaChart-6f5dabc1.js.map +1 -0
- package/amd/Link-20f7e72d.js +2 -0
- package/amd/Link-20f7e72d.js.map +1 -0
- package/amd/LinkVariants.styles.css +0 -1
- package/amd/LinkVariants.styles2.css +0 -1
- package/amd/ListView-dfbd3f41.js +2 -0
- package/amd/ListView-dfbd3f41.js.map +1 -0
- package/amd/Menu-0c8295f2.js +2 -0
- package/amd/Menu-0c8295f2.js.map +1 -0
- package/amd/MenuButton-1fbc486e.js +2 -0
- package/amd/MenuButton-1fbc486e.js.map +1 -0
- package/amd/MenuItem-f3de5e35.js +2 -0
- package/amd/MenuItem-f3de5e35.js.map +1 -0
- package/amd/MonthView-effa60a5.js +2 -0
- package/amd/MonthView-effa60a5.js.map +1 -0
- package/amd/NavigationListItem-0e162c3e.js +2 -0
- package/amd/NavigationListItem-0e162c3e.js.map +1 -0
- package/amd/NavigationListLinkItem-161049bb.js +2 -0
- package/amd/NavigationListLinkItem-161049bb.js.map +1 -0
- package/amd/OverflowTabBar-aa6557e2.js +2 -0
- package/amd/OverflowTabBar-aa6557e2.js.map +1 -0
- package/amd/OverflowTabBarItem-f05a778f.js +2 -0
- package/amd/OverflowTabBarItem-f05a778f.js.map +1 -0
- package/amd/PRIVATE_BaseCardView.js +1 -1
- package/amd/PRIVATE_BaseDiagram.js +1 -1
- package/amd/PRIVATE_Chart.js +1 -1
- package/amd/PRIVATE_DatePickerHeader.js +1 -1
- package/amd/PRIVATE_FormControls.js +1 -1
- package/amd/PRIVATE_IconSwitchButton.js +1 -1
- package/amd/PRIVATE_MonthView.js +1 -1
- package/amd/PRIVATE_MonthYearGridView.js +1 -1
- package/amd/PRIVATE_RevealToggleIcon.js +1 -1
- package/amd/PRIVATE_SelectCommon.js +1 -1
- package/amd/PRIVATE_StyledDatePickerButton/themes/StyledDatePickerButtonStyles.css.js +1 -1
- package/amd/PRIVATE_StyledDatePickerButton.js +1 -1
- package/amd/PRIVATE_Table.js +1 -1
- package/amd/PRIVATE_TableList.js +1 -1
- package/amd/PRIVATE_TruncatingLink.js +1 -1
- package/amd/PictoChart-c303675a.js +2 -0
- package/amd/PictoChart-c303675a.js.map +1 -0
- package/amd/PieChart-df15d363.js +2 -0
- package/amd/PieChart-df15d363.js.map +1 -0
- package/amd/RemovableNavigationListItem-e298c5de.js +2 -0
- package/amd/RemovableNavigationListItem-e298c5de.js.map +1 -0
- package/amd/ReorderableTabBar-e82d2982.js +2 -0
- package/amd/ReorderableTabBar-e82d2982.js.map +1 -0
- package/amd/RevealToggleIcon-be164a7b.js +2 -0
- package/amd/RevealToggleIcon-be164a7b.js.map +1 -0
- package/amd/ScatterChart-88bc2872.js +2 -0
- package/amd/ScatterChart-88bc2872.js.map +1 -0
- package/amd/SectionalLegend-3bae380b.js +2 -0
- package/amd/SectionalLegend-3bae380b.js.map +1 -0
- package/amd/SectionedContent-878a2df1.js +2 -0
- package/amd/SectionedContent-878a2df1.js.map +1 -0
- package/amd/SelectMenuItem-5bd09f45.js +2 -0
- package/amd/SelectMenuItem-5bd09f45.js.map +1 -0
- package/amd/SelectMobileFieldInput-d8be9c82.js +2 -0
- package/amd/SelectMobileFieldInput-d8be9c82.js.map +1 -0
- package/amd/SelectMultiple-467c640d.js +2 -0
- package/amd/SelectMultiple-467c640d.js.map +1 -0
- package/amd/SelectSingle-a600e403.js +2 -0
- package/amd/SelectSingle-a600e403.js.map +1 -0
- package/amd/SplitMenuButton-42f95b11.js +2 -0
- package/amd/SplitMenuButton-42f95b11.js.map +1 -0
- package/amd/StyledDatePickerButton-416ddc14.js +2 -0
- package/amd/StyledDatePickerButton-416ddc14.js.map +1 -0
- package/amd/StyledDatePickerButtonStyles.styles.css +18 -12
- package/amd/Submenu-f8ab8c2e.js +2 -0
- package/amd/Submenu-f8ab8c2e.js.map +1 -0
- package/amd/TabBar-61d65c39.js +2 -0
- package/amd/TabBar-61d65c39.js.map +1 -0
- package/amd/TabBarContextMenu-6977866c.js +2 -0
- package/amd/TabBarContextMenu-6977866c.js.map +1 -0
- package/amd/TabBarMixed-092116bd.js +2 -0
- package/amd/TabBarMixed-092116bd.js.map +1 -0
- package/amd/Table-225ba4db.js +2 -0
- package/amd/Table-225ba4db.js.map +1 -0
- package/amd/TableView-f7990126.js +2 -0
- package/amd/TableView-f7990126.js.map +1 -0
- package/amd/TagCloud-69af60c1.js +2 -0
- package/amd/TagCloud-69af60c1.js.map +1 -0
- package/amd/Theme-redwood/theme.css +178 -178
- package/amd/Theme-stable/theme.css +351 -351
- package/amd/ToggleButton-c9e433d4.js +2 -0
- package/amd/ToggleButton-c9e433d4.js.map +1 -0
- package/amd/ToggleButtonLabel-367494b8.js +2 -0
- package/amd/ToggleButtonLabel-367494b8.js.map +1 -0
- package/amd/TruncatingLink-2e947915.js +2 -0
- package/amd/TruncatingLink-2e947915.js.map +1 -0
- package/amd/UNSAFE_BarChart/__test__/BarChart.spec.js +1 -1
- package/amd/UNSAFE_BarChart.js +1 -1
- package/amd/UNSAFE_ButtonLayout/tests/ButtonLayout.spec.js +1 -1
- package/amd/UNSAFE_ButtonSetButton.js +1 -1
- package/amd/UNSAFE_ButtonSetIconButton.js +1 -1
- package/amd/UNSAFE_ButtonSetItem.js +1 -1
- package/amd/UNSAFE_CardFlexView.js +1 -1
- package/amd/UNSAFE_CardGridView.js +1 -1
- package/amd/UNSAFE_ComboChart.js +1 -1
- package/amd/UNSAFE_ContainerDiagram.js +1 -1
- package/amd/UNSAFE_DatePicker.js +1 -1
- package/amd/UNSAFE_Diagram.js +1 -1
- package/amd/UNSAFE_Dropdown.js +1 -1
- package/amd/UNSAFE_IconMenuButton.js +1 -1
- package/amd/UNSAFE_IconToggleButton.js +1 -1
- package/amd/UNSAFE_InlineSelectSingle.js +1 -1
- package/amd/UNSAFE_InputColor.js +1 -1
- package/amd/UNSAFE_InputDatePicker.js +1 -1
- package/amd/UNSAFE_InputPassword.js +1 -1
- package/amd/UNSAFE_InputSensitiveText.js +1 -1
- package/amd/UNSAFE_LabelledLink.js +1 -1
- package/amd/UNSAFE_LabelledLink.js.map +1 -1
- package/amd/UNSAFE_Legend.js +1 -1
- package/amd/UNSAFE_LineAreaChart.js +1 -1
- package/amd/UNSAFE_Link/themes/LinkStyles.css.js +1 -1
- package/amd/UNSAFE_Link.js +1 -1
- package/amd/UNSAFE_ListView.js +1 -1
- package/amd/UNSAFE_Menu.js +1 -1
- package/amd/UNSAFE_MenuButton.js +1 -1
- package/amd/UNSAFE_NavigationList.js +1 -1
- package/amd/UNSAFE_NavigationListCommon.js +1 -1
- package/amd/UNSAFE_OverflowTabBar.js +1 -1
- package/amd/UNSAFE_PictoChart.js +1 -1
- package/amd/UNSAFE_PieChart/__test__/PieChart.spec.js +1 -1
- package/amd/UNSAFE_PieChart.js +1 -1
- package/amd/UNSAFE_ReorderableTabBar.js +1 -1
- package/amd/UNSAFE_ScatterChart.js +1 -1
- package/amd/UNSAFE_SectionalLegend.js +1 -1
- package/amd/UNSAFE_SelectMultiple.js +1 -1
- package/amd/UNSAFE_SelectSingle.js +1 -1
- package/amd/UNSAFE_SplitMenuButton.js +1 -1
- package/amd/UNSAFE_TabBar.js +1 -1
- package/amd/UNSAFE_TabBarCommon.js +1 -1
- package/amd/UNSAFE_TabBarMixed.js +1 -1
- package/amd/UNSAFE_TableView.js +1 -1
- package/amd/UNSAFE_TagCloud.js +1 -1
- package/amd/UNSAFE_ToggleButton.js +1 -1
- package/amd/UNSAFE_ToggleButtonLabel.js +1 -1
- package/amd/UNSAFE_Toolbar/tests/Toolbar.spec.js +1 -1
- package/amd/YearsGridView-09b45b4e.js +2 -0
- package/amd/YearsGridView-09b45b4e.js.map +1 -0
- package/amd/hooks/PRIVATE_useChartContextMenu.js +1 -1
- package/amd/hooks/PRIVATE_useChartMarquee.js +1 -1
- package/amd/hooks/PRIVATE_useMiddleEllipsis.js +2 -0
- package/amd/hooks/PRIVATE_useMiddleEllipsis.js.map +1 -0
- package/amd/hooks/PRIVATE_useTabBar.js +1 -1
- package/amd/hooks/PRIVATE_useVisContextMenu.js +1 -1
- package/amd/hooks/PRIVATE_useVisDragModeControls.js +1 -1
- package/amd/listViewSelectionTests-e7898c59.js +2 -0
- package/amd/listViewSelectionTests-e7898c59.js.map +1 -0
- package/amd/useChartContextMenu-9abf418f.js +2 -0
- package/amd/useChartContextMenu-9abf418f.js.map +1 -0
- package/amd/useChartMarquee-ec70d86c.js +2 -0
- package/amd/useChartMarquee-ec70d86c.js.map +1 -0
- package/amd/useContextMenu-49bd8ffb.js +2 -0
- package/amd/useContextMenu-49bd8ffb.js.map +1 -0
- package/amd/useDisplayValue-8b0c1851.js +2 -0
- package/amd/useDisplayValue-8b0c1851.js.map +1 -0
- package/amd/useLegendContextMenu-90023a78.js +2 -0
- package/amd/useLegendContextMenu-90023a78.js.map +1 -0
- package/amd/useMiddleEllipsis-9ade43e6.js +2 -0
- package/amd/useMiddleEllipsis-9ade43e6.js.map +1 -0
- package/amd/useSelectCommon-af642fe7.js +2 -0
- package/amd/useSelectCommon-af642fe7.js.map +1 -0
- package/amd/useTabBar-430d9e32.js +2 -0
- package/amd/useTabBar-430d9e32.js.map +1 -0
- package/amd/useVisDragModeControls-c1d2abc6.js +2 -0
- package/amd/useVisDragModeControls-c1d2abc6.js.map +1 -0
- package/cjs/BaseButton-15b86552.js +86 -0
- package/cjs/BaseButton-15b86552.js.map +1 -0
- package/cjs/BaseCardView-ba63723a.js +6 -6
- package/cjs/BaseDiagram-576c2a13.js +2956 -0
- package/cjs/BaseDiagram-576c2a13.js.map +1 -0
- package/cjs/BaseRichSelection-c7cad1af.js +9 -9
- package/cjs/BaseSelector-2dc69917.js +1 -1
- package/cjs/BaseSwatchView-76da473f.js +2 -2
- package/cjs/Button-d79df225.js +24 -0
- package/cjs/Button-d79df225.js.map +1 -0
- package/cjs/ButtonSet-ed013090.js +2 -2
- package/cjs/ButtonSetButton-a7384fb3.js +35 -0
- package/cjs/ButtonSetButton-a7384fb3.js.map +1 -0
- package/cjs/ButtonSetIconButton-345ead86.js +40 -0
- package/cjs/ButtonSetIconButton-345ead86.js.map +1 -0
- package/cjs/ButtonSetItem-1f2f6742.js +67 -0
- package/cjs/ButtonSetItem-1f2f6742.js.map +1 -0
- package/cjs/Center-a23cf0cd.js +18 -0
- package/cjs/Center-a23cf0cd.js.map +1 -0
- package/cjs/Chart-3360191e.js +754 -0
- package/cjs/Chart-3360191e.js.map +1 -0
- package/cjs/CheckboxControl-d37c7764.js +6 -6
- package/cjs/CheckboxRadioField-24e06523.js +6 -6
- package/cjs/CheckboxRadioLabelValueLayout-0ed43779.js +1 -1
- package/cjs/CheckboxSetContext-c62db26d.js +12 -0
- package/cjs/CheckboxSetContext-c62db26d.js.map +1 -0
- package/cjs/Chip-b2dd59ed.js +1 -1
- package/cjs/ClearIcon-f61fc0b9.js +1 -1
- package/cjs/CollapseIcon-9fbe13a9.js +1 -1
- package/cjs/Collapsible-9315585f.js +2 -2
- package/cjs/ColorPalette-9f041744.js +83 -0
- package/cjs/ColorPalette-9f041744.js.map +1 -0
- package/cjs/ColorPicker-24ca67b6.js +25 -0
- package/cjs/ColorPicker-24ca67b6.js.map +1 -0
- package/cjs/ColorSwatch-cddebd6b.js +4 -4
- package/cjs/CompactLabelAssistance-f7b3b814.js +95 -0
- package/cjs/CompactLabelAssistance-f7b3b814.js.map +1 -0
- package/cjs/CompactUserAssistance-a5f1bb2b.js +5 -5
- package/cjs/ComponentMessageContainer-b692adf3.js +4 -4
- package/cjs/DatePicker-c4d49200.js +601 -0
- package/cjs/DatePicker-c4d49200.js.map +1 -0
- package/cjs/DatePickerHeader-9bcd2308.js +48 -0
- package/cjs/DatePickerHeader-9bcd2308.js.map +1 -0
- package/cjs/Dialog-871d9a7c.js +389 -0
- package/cjs/Dialog-871d9a7c.js.map +1 -0
- package/cjs/DirectionalCollapseArrowIcon-392d6599.js +1 -1
- package/cjs/DirectionalExpandArrowIcon-ff9f6f78.js +1 -1
- package/cjs/Dropdown-b73f547b.js +337 -0
- package/cjs/Dropdown-b73f547b.js.map +1 -0
- package/cjs/EmbeddedIconButton-f2e69758.js +13 -0
- package/cjs/EmbeddedIconButton-f2e69758.js.map +1 -0
- package/cjs/EnvironmentProvider-932667b2.js +61 -0
- package/cjs/EnvironmentProvider-932667b2.js.map +1 -0
- package/cjs/Expander-f4c574e5.js +1 -1
- package/cjs/Flex-ec48072d.js +32 -0
- package/cjs/Flex-ec48072d.js.map +1 -0
- package/cjs/Floating-de219e52.js +467 -0
- package/cjs/Floating-de219e52.js.map +1 -0
- package/cjs/Grid-156807d4.js +29 -0
- package/cjs/Grid-156807d4.js.map +1 -0
- package/cjs/GroupLoadingIndicator-7e035ba2.js +1 -1
- package/cjs/HighlightText-93f2fea0.js +33 -0
- package/cjs/HighlightText-93f2fea0.js.map +1 -0
- package/cjs/Icon-56789beb.js +3 -3
- package/cjs/IconButton-7503293b.js +4 -4
- package/cjs/IconSwitchButton-550d6ced.js +44 -0
- package/cjs/IconSwitchButton-550d6ced.js.map +1 -0
- package/cjs/IconToggleButton-b7a72539.js +43 -0
- package/cjs/IconToggleButton-b7a72539.js.map +1 -0
- package/cjs/IconUserAssistance-848c227c.js +76 -0
- package/cjs/IconUserAssistance-848c227c.js.map +1 -0
- package/cjs/InlineHelp-2add2d34.js +1 -1
- package/cjs/InlineUserAssistance-cfaa3d3e.js +5 -5
- package/cjs/InputDateMask-c7baadd4.js +7 -7
- package/cjs/Label-eb654b0e.js +8 -8
- package/cjs/LabelValueLayout-d67109b3.js +1 -1
- package/cjs/Layer-06e11b9c.js +94 -0
- package/cjs/Layer-06e11b9c.js.map +1 -0
- package/cjs/LayerHost-21391a0d.js +46 -0
- package/cjs/LayerHost-21391a0d.js.map +1 -0
- package/cjs/LayerManager-fd7f4d2f.js +36 -0
- package/cjs/LayerManager-fd7f4d2f.js.map +1 -0
- package/cjs/Link-f8403e9f.js +35 -0
- package/cjs/Link-f8403e9f.js.map +1 -0
- package/cjs/LinkVariants.styles.css +0 -1
- package/cjs/LinkVariants.styles2.css +0 -1
- package/cjs/List-afcfa338.js +5 -5
- package/cjs/LiveRegion-60535481.js +41 -0
- package/cjs/LiveRegion-60535481.js.map +1 -0
- package/cjs/MaxLengthLiveRegion-82e6c492.js +28 -0
- package/cjs/MaxLengthLiveRegion-82e6c492.js.map +1 -0
- package/cjs/Message-258e59da.js +2 -2
- package/cjs/MessageLayer-a18a7c26.js +61 -0
- package/cjs/MessageLayer-a18a7c26.js.map +1 -0
- package/cjs/MessagesManager-cba4bc60.js +3 -3
- package/cjs/Modal-b751b643.js +3 -3
- package/cjs/MonthView-25653876.js +231 -0
- package/cjs/MonthView-25653876.js.map +1 -0
- package/cjs/NavigationListItem-ef597eb9.js +312 -0
- package/cjs/NavigationListItem-ef597eb9.js.map +1 -0
- package/cjs/NavigationListLinkItem-62c3912e.js +237 -0
- package/cjs/NavigationListLinkItem-62c3912e.js.map +1 -0
- package/cjs/NumberInputText-36164d46.js +6 -6
- package/cjs/OverflowTabBarItem-4053a20b.js +262 -0
- package/cjs/OverflowTabBarItem-4053a20b.js.map +1 -0
- package/cjs/PRIVATE_BaseCardView.js +22 -22
- package/cjs/PRIVATE_BaseDiagram.js +38 -38
- package/cjs/PRIVATE_BaseSelector.js +17 -17
- package/cjs/PRIVATE_BaseSwatchView.js +18 -18
- package/cjs/PRIVATE_Chart.js +48 -48
- package/cjs/PRIVATE_CheckboxControl.js +25 -25
- package/cjs/PRIVATE_CheckboxRadioField.js +27 -27
- package/cjs/PRIVATE_ClearIcon.js +18 -18
- package/cjs/PRIVATE_CollapsibleNavigationList.js +20 -20
- package/cjs/PRIVATE_DatePickerHeader.js +23 -23
- package/cjs/PRIVATE_DatePickerLayout.js +4 -4
- package/cjs/PRIVATE_EmbeddedIconButton.js +6 -6
- package/cjs/PRIVATE_Expander.js +19 -19
- package/cjs/PRIVATE_FormControls.js +21 -21
- package/cjs/PRIVATE_IconSwitchButton.js +19 -19
- package/cjs/PRIVATE_Icons/CheckboxCrossed.js +16 -16
- package/cjs/PRIVATE_Icons/CheckboxMixed.js +16 -16
- package/cjs/PRIVATE_Icons/CheckboxOff.js +16 -16
- package/cjs/PRIVATE_Icons/CheckboxOn.js +16 -16
- package/cjs/PRIVATE_Icons/DragV.js +16 -16
- package/cjs/PRIVATE_Icons/None.js +16 -16
- package/cjs/PRIVATE_List.js +21 -21
- package/cjs/PRIVATE_Message.js +20 -20
- package/cjs/PRIVATE_MessageLayer.js +12 -12
- package/cjs/PRIVATE_MonthView.js +81 -8
- package/cjs/PRIVATE_MonthView.js.map +1 -1
- package/cjs/PRIVATE_MonthYearGridView.js +8 -8
- package/cjs/PRIVATE_PlotArea.js +5 -5
- package/cjs/PRIVATE_RevealToggleIcon.js +21 -21
- package/cjs/PRIVATE_RichSelectionCommon.js +28 -28
- package/cjs/PRIVATE_SelectCommon.js +34 -34
- package/cjs/PRIVATE_StyledCard.js +3 -3
- package/cjs/PRIVATE_StyledCheckbox.js +16 -16
- package/cjs/PRIVATE_StyledDatePickerButton/themes/StyledDatePickerButtonStyles.css.js +1 -1
- package/cjs/PRIVATE_StyledDatePickerButton.js +1 -1
- package/cjs/PRIVATE_StyledSwitch.js +4 -4
- package/cjs/PRIVATE_SwatchFlexView.js +18 -18
- package/cjs/PRIVATE_Table.js +38 -38
- package/cjs/PRIVATE_TableDisplay.js +19 -19
- package/cjs/PRIVATE_TableList.js +27 -27
- package/cjs/PRIVATE_ThemedIcons/CalendarIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ChartMarqueeSelectIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ChartPanIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ChartZoomIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CheckIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CheckboxCrossedIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CheckboxMixedIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CheckboxOffIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CheckboxOnIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CloseIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/CollapseIcon.js +17 -17
- package/cjs/PRIVATE_ThemedIcons/CollapseUpIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/DecrementIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/DeleteIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/DirectionalCollapseArrowIcon.js +17 -17
- package/cjs/PRIVATE_ThemedIcons/DirectionalExpandArrowIcon.js +17 -17
- package/cjs/PRIVATE_ThemedIcons/DragHandleIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/DropdownArrowIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ExpandIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/HelpIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/IncrementIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MenuButtonDropdownIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MessageConfirmationIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MessageErrorIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MessageInfoIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MessageWarningIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/MinusIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/NavDownIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/None.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/OverviewHorizontalDragHandleIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/PlusIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/RadioOffIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/RadioOnIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/SortAscendingIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/SortDescendingIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ViewHideIcon.js +16 -16
- package/cjs/PRIVATE_ThemedIcons/ViewIcon.js +16 -16
- package/cjs/PRIVATE_TimeComponent.js +19 -19
- package/cjs/PRIVATE_TruncatingLink.js +20 -17
- package/cjs/PRIVATE_TruncatingLink.js.map +1 -1
- package/cjs/PRIVATE_VisOverview.js +16 -16
- package/cjs/PRIVATE_VisStatusMessage.js +5 -5
- package/cjs/PRIVATE_VisTabularDatatip.js +4 -4
- package/cjs/Popup-6de390dd.js +300 -0
- package/cjs/Popup-6de390dd.js.map +1 -0
- package/cjs/ProgressButtonLabelLayout-2e429893.js +3 -3
- package/cjs/ProgressCircle-f9c43168.js +50 -0
- package/cjs/ProgressCircle-f9c43168.js.map +1 -0
- package/cjs/RadioItem-c74ac827.js +6 -6
- package/cjs/ReadonlyTextFieldInput-60965d77.js +1 -1
- package/cjs/ReferenceLineArea-d00d2b33.js +592 -0
- package/cjs/ReferenceLineArea-d00d2b33.js.map +1 -0
- package/cjs/RevealToggleIcon-6a86726c.js +28 -0
- package/cjs/RevealToggleIcon-6a86726c.js.map +1 -0
- package/cjs/SectionedContent-463bf70e.js +68 -0
- package/cjs/SectionedContent-463bf70e.js.map +1 -0
- package/cjs/SelectMenuGroupContext-002c9144.js +563 -0
- package/cjs/SelectMenuGroupContext-002c9144.js.map +1 -0
- package/cjs/SelectMobileFieldInput-2adf002d.js +248 -0
- package/cjs/SelectMobileFieldInput-2adf002d.js.map +1 -0
- package/cjs/SelectorAll-2905a1c9.js +53 -0
- package/cjs/SelectorAll-2905a1c9.js.map +1 -0
- package/cjs/Sheet-1d6e8cf8.js +2 -2
- package/cjs/SortControl-8c15705b.js +3 -3
- package/cjs/StyledCard-13c323e4.js +1 -1
- package/cjs/StyledDatePickerButton-f20c0596.js +34 -0
- package/cjs/StyledDatePickerButton-f20c0596.js.map +1 -0
- package/cjs/StyledDatePickerButtonStyles.styles.css +18 -12
- package/cjs/StyledLabelValueLayout-3ee66ef1.js +22 -0
- package/cjs/StyledLabelValueLayout-3ee66ef1.js.map +1 -0
- package/cjs/StyledSwitch-17127a03.js +2 -2
- package/cjs/StyledTextField-7839c90d.js +5 -5
- package/cjs/Submenu-fb652ff4.js +251 -0
- package/cjs/Submenu-fb652ff4.js.map +1 -0
- package/cjs/TabBar-1e6a97b5.js +73 -0
- package/cjs/TabBar-1e6a97b5.js.map +1 -0
- package/cjs/TabBarContextMenu-f7acee3d.js +102 -0
- package/cjs/TabBarContextMenu-f7acee3d.js.map +1 -0
- package/cjs/TabBarLayout-ca8af14b.js +1 -1
- package/cjs/TabBarLinkItem-8f54f16d.js +15 -0
- package/cjs/TabBarLinkItem-8f54f16d.js.map +1 -0
- package/cjs/Table-daa93733.js +4114 -0
- package/cjs/Table-daa93733.js.map +1 -0
- package/cjs/TableColGroup-b7e1e296.js +1 -1
- package/cjs/TextArea-85d34b3e.js +229 -0
- package/cjs/TextArea-85d34b3e.js.map +1 -0
- package/cjs/TextField-5c164264.js +3 -3
- package/cjs/Theme-redwood/theme.css +145 -145
- package/cjs/Theme-stable/theme.css +138 -138
- package/cjs/TimeComponentCanvas2D-baa58795.js +6 -6
- package/cjs/ToggleButton-0ec0c75b.js +30 -0
- package/cjs/ToggleButton-0ec0c75b.js.map +1 -0
- package/cjs/ToggleButtonLabel-ce19879c.js +77 -0
- package/cjs/ToggleButtonLabel-ce19879c.js.map +1 -0
- package/cjs/TruncatingLink-f6a80ee5.js +95 -0
- package/cjs/TruncatingLink-f6a80ee5.js.map +1 -0
- package/cjs/TruncatingText-ac1f6793.js +1 -1
- package/cjs/UNSAFE_AccordionItemMultiple.js +18 -18
- package/cjs/UNSAFE_AccordionItemSingle.js +18 -18
- package/cjs/UNSAFE_ActionCard.js +2 -2
- package/cjs/UNSAFE_BarChart.js +49 -49
- package/cjs/UNSAFE_BareButton.js +2 -2
- package/cjs/UNSAFE_BaseButton.js +5 -5
- package/cjs/UNSAFE_Button.js +6 -6
- package/cjs/UNSAFE_ButtonSet.js +4 -4
- package/cjs/UNSAFE_ButtonSetButton.js +7 -7
- package/cjs/UNSAFE_ButtonSetIconButton.js +19 -19
- package/cjs/UNSAFE_ButtonSetItem.js +22 -22
- package/cjs/UNSAFE_ButtonSetMultiple.js +4 -4
- package/cjs/UNSAFE_ButtonSetSingle.js +4 -4
- package/cjs/UNSAFE_Card.js +3 -3
- package/cjs/UNSAFE_CardFlexView.js +22 -22
- package/cjs/UNSAFE_CardGridView.js +22 -22
- package/cjs/UNSAFE_Center.js +5 -5
- package/cjs/UNSAFE_Checkbox.js +25 -25
- package/cjs/UNSAFE_CheckboxItem.js +71 -132
- package/cjs/UNSAFE_CheckboxItem.js.map +1 -1
- package/cjs/UNSAFE_CheckboxRadioField.js +4 -4
- package/cjs/UNSAFE_CheckboxSet.js +75 -46
- package/cjs/UNSAFE_CheckboxSet.js.map +1 -1
- package/cjs/UNSAFE_Chip.js +2 -2
- package/cjs/UNSAFE_Collapsible.js +18 -18
- package/cjs/UNSAFE_ColorPalette.js +95 -95
- package/cjs/UNSAFE_ColorPicker.js +77 -77
- package/cjs/UNSAFE_ColorSwatch.js +17 -17
- package/cjs/UNSAFE_ComboChart.js +49 -49
- package/cjs/UNSAFE_ComponentMessage.js +20 -20
- package/cjs/UNSAFE_ContainerDiagram.js +38 -38
- package/cjs/UNSAFE_ConveyorBelt.js +18 -18
- package/cjs/UNSAFE_DatePicker.js +54 -31
- package/cjs/UNSAFE_DatePicker.js.map +1 -1
- package/cjs/UNSAFE_Diagram.js +38 -38
- package/cjs/UNSAFE_Dialog.js +22 -22
- package/cjs/UNSAFE_DragHandle.js +17 -17
- package/cjs/UNSAFE_DrawerLayout.js +12 -12
- package/cjs/UNSAFE_DrawerPopup.js +11 -11
- package/cjs/UNSAFE_Dropdown.js +15 -15
- package/cjs/UNSAFE_Environment.js +4 -4
- package/cjs/UNSAFE_ExpandableList.js +25 -25
- package/cjs/UNSAFE_FilePicker.js +4 -4
- package/cjs/UNSAFE_FlatTreeView.js +25 -25
- package/cjs/UNSAFE_Flex.js +4 -4
- package/cjs/UNSAFE_Floating.js +11 -11
- package/cjs/UNSAFE_FormLayout.js +2 -2
- package/cjs/UNSAFE_Gantt.js +23 -23
- package/cjs/UNSAFE_Grid.js +4 -4
- package/cjs/UNSAFE_HighlightText.js +4 -4
- package/cjs/UNSAFE_Icon.js +16 -16
- package/cjs/UNSAFE_IconButton.js +17 -17
- package/cjs/UNSAFE_IconMenuButton.js +26 -26
- package/cjs/UNSAFE_IconProgressButton.js +21 -21
- package/cjs/UNSAFE_IconToggleButton.js +19 -19
- package/cjs/UNSAFE_Indexer.js +19 -19
- package/cjs/UNSAFE_InlineSelectSingle.js +34 -34
- package/cjs/UNSAFE_InputColor.js +42 -42
- package/cjs/UNSAFE_InputDateMask.js +26 -26
- package/cjs/UNSAFE_InputDatePicker.js +149 -127
- package/cjs/UNSAFE_InputDatePicker.js.map +1 -1
- package/cjs/UNSAFE_InputPassword.js +29 -29
- package/cjs/UNSAFE_InputSensitiveText.js +30 -30
- package/cjs/UNSAFE_InputText.js +28 -28
- package/cjs/UNSAFE_InputTimeMask.js +26 -26
- package/cjs/UNSAFE_Label.js +25 -25
- package/cjs/UNSAFE_LabelValueLayout.js +4 -4
- package/cjs/UNSAFE_LabelledLink.js +36 -31
- package/cjs/UNSAFE_LabelledLink.js.map +1 -1
- package/cjs/UNSAFE_Layer.js +8 -8
- package/cjs/UNSAFE_Legend.js +30 -30
- package/cjs/UNSAFE_LineAreaChart.js +49 -49
- package/cjs/UNSAFE_Link/themes/LinkStyles.css.js +1 -1
- package/cjs/UNSAFE_Link.js +3 -3
- package/cjs/UNSAFE_ListItemLayout.js +4 -4
- package/cjs/UNSAFE_ListView.js +29 -29
- package/cjs/UNSAFE_LiveRegion.js +4 -4
- package/cjs/UNSAFE_Menu.js +28 -28
- package/cjs/UNSAFE_MenuButton.js +26 -26
- package/cjs/UNSAFE_MessageBanner.js +20 -20
- package/cjs/UNSAFE_MessageToast.js +22 -22
- package/cjs/UNSAFE_MeterBar.js +16 -16
- package/cjs/UNSAFE_MeterCircle.js +17 -17
- package/cjs/UNSAFE_Modal.js +8 -8
- package/cjs/UNSAFE_NavigationList.js +38 -40
- package/cjs/UNSAFE_NavigationList.js.map +1 -1
- package/cjs/UNSAFE_NavigationListCommon.js +33 -34
- package/cjs/UNSAFE_NavigationListCommon.js.map +1 -1
- package/cjs/UNSAFE_NumberInputText.js +28 -28
- package/cjs/UNSAFE_OverflowTabBar.js +85 -88
- package/cjs/UNSAFE_OverflowTabBar.js.map +1 -1
- package/cjs/UNSAFE_PictoChart.js +27 -27
- package/cjs/UNSAFE_PieChart.js +28 -28
- package/cjs/UNSAFE_Popup.js +18 -18
- package/cjs/UNSAFE_ProgressBar.js +4 -4
- package/cjs/UNSAFE_ProgressButton.js +21 -21
- package/cjs/UNSAFE_ProgressButtonLabelLayout.js +10 -10
- package/cjs/UNSAFE_ProgressCircle.js +4 -4
- package/cjs/UNSAFE_RadioItem.js +25 -25
- package/cjs/UNSAFE_RadioSet.js +27 -27
- package/cjs/UNSAFE_RatingGauge.js +18 -18
- package/cjs/UNSAFE_ReorderableTabBar.js +44 -57
- package/cjs/UNSAFE_ReorderableTabBar.js.map +1 -1
- package/cjs/UNSAFE_RichCheckboxSet.js +64 -68
- package/cjs/UNSAFE_RichCheckboxSet.js.map +1 -1
- package/cjs/UNSAFE_RichRadioSet.js +29 -29
- package/cjs/UNSAFE_RichSelectionItem.js +112 -175
- package/cjs/UNSAFE_RichSelectionItem.js.map +1 -1
- package/cjs/UNSAFE_ScatterChart.js +49 -49
- package/cjs/UNSAFE_SectionalLegend.js +30 -30
- package/cjs/UNSAFE_SelectMultiple.js +38 -38
- package/cjs/UNSAFE_SelectSingle.js +38 -38
- package/cjs/UNSAFE_SelectionCard.js +3 -3
- package/cjs/UNSAFE_Selector.js +17 -17
- package/cjs/UNSAFE_SelectorAll.js +19 -19
- package/cjs/UNSAFE_Sheet.js +11 -11
- package/cjs/UNSAFE_SortControl.js +20 -20
- package/cjs/UNSAFE_SplitMenuButton.js +27 -27
- package/cjs/UNSAFE_SplitMenuButton.js.map +1 -1
- package/cjs/UNSAFE_Switch.js +26 -26
- package/cjs/UNSAFE_TabBar.js +87 -90
- package/cjs/UNSAFE_TabBar.js.map +1 -1
- package/cjs/UNSAFE_TabBarCommon.js +100 -103
- package/cjs/UNSAFE_TabBarCommon.js.map +1 -1
- package/cjs/UNSAFE_TabBarMixed.js +61 -64
- package/cjs/UNSAFE_TabBarMixed.js.map +1 -1
- package/cjs/UNSAFE_TableView.js +38 -38
- package/cjs/UNSAFE_TagCloud.js +28 -28
- package/cjs/UNSAFE_TextArea.js +119 -234
- package/cjs/UNSAFE_TextArea.js.map +1 -1
- package/cjs/UNSAFE_TextAreaAutosize.js +30 -30
- package/cjs/UNSAFE_TextAreaAutosize.js.map +1 -1
- package/cjs/UNSAFE_TextField.js +20 -20
- package/cjs/UNSAFE_ToggleButton.js +7 -7
- package/cjs/UNSAFE_ToggleButtonLabel.js +1 -1
- package/cjs/UNSAFE_Toolbar.js +4 -4
- package/cjs/UNSAFE_Train.js +17 -17
- package/cjs/UNSAFE_TruncatingBadge.js +17 -17
- package/cjs/UNSAFE_TruncatingText.js +17 -17
- package/cjs/UNSAFE_UserAssistance.js +26 -26
- package/cjs/UNSAFE_View.js +7 -7
- package/cjs/UNSAFE_VirtualizedListView.js +21 -21
- package/cjs/UNSAFE_VisInvalidDataMessage.js +6 -6
- package/cjs/UNSAFE_VisNoDataMessage.js +6 -6
- package/cjs/UNSAFE_VisProgressiveLoader.js +5 -5
- package/cjs/UNSAFE_WindowOverlay.js +4 -4
- package/cjs/View-67ff7d0e.js +170 -0
- package/cjs/View-67ff7d0e.js.map +1 -0
- package/cjs/VisStatusMessage-3ca153ac.js +31 -0
- package/cjs/VisStatusMessage-3ca153ac.js.map +1 -0
- package/cjs/VisTabularDatatip-e79da9de.js +26 -0
- package/cjs/VisTabularDatatip-e79da9de.js.map +1 -0
- package/cjs/WindowOverlay-b9595d88.js +112 -0
- package/cjs/WindowOverlay-b9595d88.js.map +1 -0
- package/cjs/YearsGridView-9fd78c0f.js +190 -0
- package/cjs/YearsGridView-9fd78c0f.js.map +1 -0
- package/cjs/hoc/PRIVATE_withDirectionIcon.js +4 -4
- package/cjs/hoc/PRIVATE_withThemeIcon.js +3 -3
- package/cjs/hoc/UNSAFE_withThemeProps.js +3 -3
- package/cjs/hooks/PRIVATE_useChartContextMenu.js +26 -26
- package/cjs/hooks/PRIVATE_useChartDatatip.js +14 -14
- package/cjs/hooks/PRIVATE_useChartEvents.js +19 -19
- package/cjs/hooks/PRIVATE_useChartMarquee.js +26 -26
- package/cjs/hooks/PRIVATE_useCollectionFocusRing.js +17 -17
- package/cjs/hooks/PRIVATE_useCssVars.js +7 -7
- package/cjs/hooks/PRIVATE_useCurrentKey.js +4 -4
- package/cjs/hooks/PRIVATE_useDatatip.js +12 -12
- package/cjs/hooks/PRIVATE_useDetectHorizontalOverflow.js +16 -16
- package/cjs/hooks/PRIVATE_useFloating.js +4 -4
- package/cjs/hooks/PRIVATE_useItemAction.js +17 -17
- package/cjs/hooks/PRIVATE_useListCommon.js +19 -19
- package/cjs/hooks/PRIVATE_useMiddleEllipsis.js +12 -0
- package/cjs/hooks/PRIVATE_useMiddleEllipsis.js.map +1 -0
- package/cjs/hooks/PRIVATE_useOutsideMousedown.js +9 -9
- package/cjs/hooks/PRIVATE_useRadioFocusManager.js +4 -4
- package/cjs/hooks/PRIVATE_useReorderable.js +19 -19
- package/cjs/hooks/PRIVATE_useRovingTabIndexContainer.js +4 -4
- package/cjs/hooks/PRIVATE_useSelection.js +4 -4
- package/cjs/hooks/PRIVATE_useTabBar.js +29 -29
- package/cjs/hooks/PRIVATE_useTabbableModeSet.js +17 -17
- package/cjs/hooks/PRIVATE_useTooltipOnTruncation.js +17 -17
- package/cjs/hooks/PRIVATE_useVisContextMenu.js +25 -25
- package/cjs/hooks/PRIVATE_useVisDragModeControls.js +25 -25
- package/cjs/hooks/PRIVATE_useVisEvents.js +4 -4
- package/cjs/hooks/PRIVATE_useVisMeterEvents.js +14 -14
- package/cjs/hooks/PRIVATE_useVisSelection.js +15 -15
- package/cjs/hooks/UNSAFE_useBareButton.js +2 -2
- package/cjs/hooks/UNSAFE_useColorScheme.js +3 -3
- package/cjs/hooks/UNSAFE_useCurrentBgColor.js +2 -2
- package/cjs/hooks/UNSAFE_useDensity.js +3 -3
- package/cjs/hooks/UNSAFE_useHiddenTestMethod.js +3 -3
- package/cjs/hooks/UNSAFE_useOutsideClick.js +8 -8
- package/cjs/hooks/UNSAFE_usePrefixSuffix.js +4 -4
- package/cjs/hooks/UNSAFE_useScale.js +3 -3
- package/cjs/hooks/UNSAFE_useTestId.js +3 -3
- package/cjs/hooks/UNSAFE_useTheme.js +3 -3
- package/cjs/hooks/UNSAFE_useThemeInterpolations.js +6 -6
- package/cjs/hooks/UNSAFE_useTooltip.js +17 -17
- package/cjs/hooks/UNSAFE_useTranslationBundle.js +3 -3
- package/cjs/hooks/UNSAFE_useUser.js +3 -3
- package/cjs/popupUtils-79656e59.js +31 -0
- package/cjs/popupUtils-79656e59.js.map +1 -0
- package/cjs/tooltipUtils-c554343d.js +115 -0
- package/cjs/tooltipUtils-c554343d.js.map +1 -0
- package/cjs/useBareButton-463210c9.js +1 -1
- package/cjs/useCellNavigation-09201a92.js +1 -1
- package/cjs/useChartContextMenu-c961873c.js +125 -0
- package/cjs/useChartContextMenu-c961873c.js.map +1 -0
- package/cjs/useChartDatatip-0ead533e.js +341 -0
- package/cjs/useChartDatatip-0ead533e.js.map +1 -0
- package/cjs/useChartMarquee-ade8e91c.js +306 -0
- package/cjs/useChartMarquee-ade8e91c.js.map +1 -0
- package/cjs/useColorScheme-852ec82e.js +21 -0
- package/cjs/useColorScheme-852ec82e.js.map +1 -0
- package/cjs/useContextMenu-c02f8dee.js +119 -0
- package/cjs/useContextMenu-c02f8dee.js.map +1 -0
- package/cjs/useCssVars-b7192b44.js +60 -0
- package/cjs/useCssVars-b7192b44.js.map +1 -0
- package/cjs/useCurrentKey-b66cf089.js +85 -0
- package/cjs/useCurrentKey-b66cf089.js.map +1 -0
- package/cjs/useDatatip-3462cc49.js +96 -0
- package/cjs/useDatatip-3462cc49.js.map +1 -0
- package/cjs/useDensity-2a45f4dd.js +21 -0
- package/cjs/useDensity-2a45f4dd.js.map +1 -0
- package/cjs/useDisplayValue-047ff360.js +82 -0
- package/cjs/useDisplayValue-047ff360.js.map +1 -0
- package/cjs/useExpandCollapse-359c0224.js +72 -0
- package/cjs/useExpandCollapse-359c0224.js.map +1 -0
- package/cjs/useFloating-c408d4be.js +1926 -0
- package/cjs/useFloating-c408d4be.js.map +1 -0
- package/cjs/useHiddenTestMethod-620e91e0.js +30 -0
- package/cjs/useHiddenTestMethod-620e91e0.js.map +1 -0
- package/cjs/useKeyboardEvents-d9528b16.js +88 -0
- package/cjs/useKeyboardEvents-d9528b16.js.map +1 -0
- package/cjs/useLegendContextMenu-b7993cf0.js +285 -0
- package/cjs/useLegendContextMenu-b7993cf0.js.map +1 -0
- package/cjs/useMeterDatatip-fdab9ee5.js +76 -0
- package/cjs/useMeterDatatip-fdab9ee5.js.map +1 -0
- package/cjs/useMiddleEllipsis-792e61a9.js +230 -0
- package/cjs/useMiddleEllipsis-792e61a9.js.map +1 -0
- package/cjs/useNavigation-fa3f5a50.js +1 -1
- package/cjs/useOutsideClick-5c31ee35.js +117 -0
- package/cjs/useOutsideClick-5c31ee35.js.map +1 -0
- package/cjs/useOutsideMousedown-eda95637.js +50 -0
- package/cjs/useOutsideMousedown-eda95637.js.map +1 -0
- package/cjs/usePopupAnimation-985e90a2.js +87 -0
- package/cjs/usePopupAnimation-985e90a2.js.map +1 -0
- package/cjs/usePrefixSuffix-a6a1b772.js +72 -0
- package/cjs/usePrefixSuffix-a6a1b772.js.map +1 -0
- package/cjs/useRadioFocusManager-58e51026.js +110 -0
- package/cjs/useRadioFocusManager-58e51026.js.map +1 -0
- package/cjs/useReorderableItem-969a3eac.js +299 -0
- package/cjs/useReorderableItem-969a3eac.js.map +1 -0
- package/cjs/useRovingTabIndexContainer-46b897fd.js +108 -0
- package/cjs/useRovingTabIndexContainer-46b897fd.js.map +1 -0
- package/cjs/useScale-529046e3.js +21 -0
- package/cjs/useScale-529046e3.js.map +1 -0
- package/cjs/useSelectCommon-728573f9.js +507 -0
- package/cjs/useSelectCommon-728573f9.js.map +1 -0
- package/cjs/useSelectDrill-813d4fbe.js +114 -0
- package/cjs/useSelectDrill-813d4fbe.js.map +1 -0
- package/cjs/useSelection-0b3dd2cf.js +188 -0
- package/cjs/useSelection-0b3dd2cf.js.map +1 -0
- package/cjs/useSelection-0ef0ee3c.js +260 -0
- package/cjs/useSelection-0ef0ee3c.js.map +1 -0
- package/cjs/useTabBar-114caa2f.js +309 -0
- package/cjs/useTabBar-114caa2f.js.map +1 -0
- package/cjs/useTestId-a8b07506.js +23 -0
- package/cjs/useTestId-a8b07506.js.map +1 -0
- package/cjs/useTheme-71e406b0.js +21 -0
- package/cjs/useTheme-71e406b0.js.map +1 -0
- package/cjs/useThemeInterpolations-ca3ddfd9.js +71 -0
- package/cjs/useThemeInterpolations-ca3ddfd9.js.map +1 -0
- package/cjs/useTooltip-d1200aff.js +51 -0
- package/cjs/useTooltip-d1200aff.js.map +1 -0
- package/cjs/useTooltipControlled-0dc34549.js +376 -0
- package/cjs/useTooltipControlled-0dc34549.js.map +1 -0
- package/cjs/useTooltipOnTruncation-d8253c7e.js +29 -0
- package/cjs/useTooltipOnTruncation-d8253c7e.js.map +1 -0
- package/cjs/useTranslationBundle-990e7928.js +31 -0
- package/cjs/useTranslationBundle-990e7928.js.map +1 -0
- package/cjs/useUser-cc045b3e.js +21 -0
- package/cjs/useUser-cc045b3e.js.map +1 -0
- package/cjs/useVisDragModeControls-737aa2dd.js +89 -0
- package/cjs/useVisDragModeControls-737aa2dd.js.map +1 -0
- package/cjs/useVisEvents-4ad7b798.js +155 -0
- package/cjs/useVisEvents-4ad7b798.js.map +1 -0
- package/cjs/utils/PRIVATE_collectionUtils.js +17 -17
- package/cjs/utils/PRIVATE_tabBarUtils.js +17 -17
- package/cjs/utils/PRIVATE_tooltipUtils.js +14 -14
- package/cjs/utils/PRIVATE_visTestUtils.js +4 -4
- package/cjs/utils/UNSAFE_popupUtils.js +8 -8
- package/cjs/withDirectionIcon-a14b071b.js +16 -0
- package/cjs/withDirectionIcon-a14b071b.js.map +1 -0
- package/cjs/withThemeProps-894a40fc.js +2 -2
- package/es/BaseButton-243d200f.js +84 -0
- package/es/BaseButton-243d200f.js.map +1 -0
- package/es/BaseCardView-85b9a71e.js +631 -0
- package/es/BaseCardView-85b9a71e.js.map +1 -0
- package/es/BaseDiagram-19f481a0.js +2954 -0
- package/es/BaseDiagram-19f481a0.js.map +1 -0
- package/es/BaseRichSelection-223d9830.js +9 -9
- package/es/BaseSelector-7cbc48bc.js +1 -1
- package/es/BaseSwatchView-2e1e6bd2.js +2 -2
- package/es/Button-a76ecfa8.js +22 -0
- package/es/Button-a76ecfa8.js.map +1 -0
- package/es/ButtonSet-b7464e9a.js +2 -2
- package/es/ButtonSetButton-5e07834a.js +33 -0
- package/es/ButtonSetButton-5e07834a.js.map +1 -0
- package/es/ButtonSetIconButton-7e6573a0.js +38 -0
- package/es/ButtonSetIconButton-7e6573a0.js.map +1 -0
- package/es/ButtonSetItem-08dd9bd2.js +65 -0
- package/es/ButtonSetItem-08dd9bd2.js.map +1 -0
- package/es/Center-3860fe60.js +16 -0
- package/es/Center-3860fe60.js.map +1 -0
- package/es/Chart-aeda6a0c.js +752 -0
- package/es/Chart-aeda6a0c.js.map +1 -0
- package/es/CheckboxControl-c008372a.js +6 -6
- package/es/CheckboxRadioField-a387b3cb.js +6 -6
- package/es/CheckboxRadioLabelValueLayout-e3845f16.js +1 -1
- package/es/CheckboxSet-3aab5935.js +1 -1
- package/es/Chip-4efea02e.js +1 -1
- package/es/ClearIcon-f85ea340.js +1 -1
- package/es/CollapseIcon-84f6ba8e.js +1 -1
- package/es/Collapsible-2608ce3b.js +2 -2
- package/es/ColorPalette-950c6fc6.js +2 -2
- package/es/ColorPicker-8c297849.js +23 -0
- package/es/ColorPicker-8c297849.js.map +1 -0
- package/es/ColorSwatch-8339ee2f.js +4 -4
- package/es/CompactLabelAssistance-50ff3f7e.js +92 -0
- package/es/CompactLabelAssistance-50ff3f7e.js.map +1 -0
- package/es/CompactUserAssistance-6aa8894b.js +5 -5
- package/es/ComponentMessageContainer-d16c8b1f.js +4 -4
- package/es/DatePicker-6861ae90.js +599 -0
- package/es/DatePicker-6861ae90.js.map +1 -0
- package/es/DatePickerHeader-1a050945.js +46 -0
- package/es/DatePickerHeader-1a050945.js.map +1 -0
- package/es/DiagramStyles.styles2.css +10 -16
- package/es/DiagramStyles.styles3.css +16 -10
- package/es/Dialog-d1de5b06.js +387 -0
- package/es/Dialog-d1de5b06.js.map +1 -0
- package/es/DirectionalCollapseArrowIcon-132761da.js +1 -1
- package/es/DirectionalExpandArrowIcon-5bc45cad.js +1 -1
- package/es/Dropdown-f7992670.js +322 -0
- package/es/Dropdown-f7992670.js.map +1 -0
- package/es/EmbeddedIconButton-9f0e56b7.js +11 -0
- package/es/EmbeddedIconButton-9f0e56b7.js.map +1 -0
- package/es/EnvironmentProvider-6cf8ed37.js +58 -0
- package/es/EnvironmentProvider-6cf8ed37.js.map +1 -0
- package/es/Expander-1347e769.js +1 -1
- package/es/Flex-fc483125.js +30 -0
- package/es/Flex-fc483125.js.map +1 -0
- package/es/Floating-be4c0cb6.js +465 -0
- package/es/Floating-be4c0cb6.js.map +1 -0
- package/es/Grid-6f92d323.js +27 -0
- package/es/Grid-6f92d323.js.map +1 -0
- package/es/GroupLoadingIndicator-19c6545a.js +1 -1
- package/es/HighlightText-dd484ffd.js +31 -0
- package/es/HighlightText-dd484ffd.js.map +1 -0
- package/es/Icon-4983d06e.js +3 -3
- package/es/IconButton-7f91481c.js +4 -4
- package/es/IconSwitchButton-0ef3178f.js +42 -0
- package/es/IconSwitchButton-0ef3178f.js.map +1 -0
- package/es/IconToggleButton-7d9efcb3.js +41 -0
- package/es/IconToggleButton-7d9efcb3.js.map +1 -0
- package/es/IconUserAssistance-6abc7837.js +74 -0
- package/es/IconUserAssistance-6abc7837.js.map +1 -0
- package/es/InlineHelp-9eaac91c.js +1 -1
- package/es/InlineUserAssistance-890293dd.js +5 -5
- package/es/InputDateMask-ec27aee7.js +7 -7
- package/es/Label-5d1ae8d7.js +8 -8
- package/es/LabelValueLayout-c6b9945a.js +1 -1
- package/es/Layer-6c27170e.js +91 -0
- package/es/Layer-6c27170e.js.map +1 -0
- package/es/LayerHost-3cf255a6.js +41 -0
- package/es/LayerHost-3cf255a6.js.map +1 -0
- package/es/LayerManager-e30fbfd6.js +34 -0
- package/es/LayerManager-e30fbfd6.js.map +1 -0
- package/es/Link-db2fdeab.js +33 -0
- package/es/Link-db2fdeab.js.map +1 -0
- package/es/LinkVariants.styles.css +0 -1
- package/es/LinkVariants.styles2.css +0 -1
- package/es/List-4636ba9b.js +5 -5
- package/es/LiveRegion-2e8830ae.js +39 -0
- package/es/LiveRegion-2e8830ae.js.map +1 -0
- package/es/MaxLengthLiveRegion-8f552ae2.js +26 -0
- package/es/MaxLengthLiveRegion-8f552ae2.js.map +1 -0
- package/es/Message-510c2db8.js +2 -2
- package/es/MessageLayer-1dbdc0b6.js +58 -0
- package/es/MessageLayer-1dbdc0b6.js.map +1 -0
- package/es/MessagesManager-47000438.js +3 -3
- package/es/Modal-c0f730b8.js +3 -3
- package/es/MonthView-6628071f.js +229 -0
- package/es/MonthView-6628071f.js.map +1 -0
- package/es/NavigationListItem-3a9e0951.js +291 -0
- package/es/NavigationListItem-3a9e0951.js.map +1 -0
- package/es/NavigationListLinkItem-e28fd846.js +5 -5
- package/es/NumberInputText-60be5757.js +6 -6
- package/es/OverflowTabBarItem-ee746856.js +257 -0
- package/es/OverflowTabBarItem-ee746856.js.map +1 -0
- package/es/PRIVATE_BaseCardView.js +23 -23
- package/es/PRIVATE_BaseDiagram.js +38 -38
- package/es/PRIVATE_BaseSelector.js +17 -17
- package/es/PRIVATE_BaseSwatchView.js +18 -18
- package/es/PRIVATE_Chart.js +45 -45
- package/es/PRIVATE_CheckboxControl.js +25 -25
- package/es/PRIVATE_CheckboxRadioField.js +27 -27
- package/es/PRIVATE_ClearIcon.js +18 -18
- package/es/PRIVATE_CollapsibleNavigationList.js +20 -20
- package/es/PRIVATE_DatePickerHeader.js +23 -23
- package/es/PRIVATE_DatePickerLayout.js +4 -4
- package/es/PRIVATE_EmbeddedIconButton.js +6 -6
- package/es/PRIVATE_Expander.js +19 -19
- package/es/PRIVATE_FormControls.js +21 -21
- package/es/PRIVATE_IconSwitchButton.js +19 -19
- package/es/PRIVATE_Icons/CheckboxCrossed.js +16 -16
- package/es/PRIVATE_Icons/CheckboxMixed.js +16 -16
- package/es/PRIVATE_Icons/CheckboxOff.js +16 -16
- package/es/PRIVATE_Icons/CheckboxOn.js +16 -16
- package/es/PRIVATE_Icons/DragV.js +16 -16
- package/es/PRIVATE_Icons/None.js +16 -16
- package/es/PRIVATE_List.js +21 -21
- package/es/PRIVATE_Message.js +20 -20
- package/es/PRIVATE_MessageLayer.js +12 -12
- package/es/PRIVATE_MonthView.js +81 -8
- package/es/PRIVATE_MonthView.js.map +1 -1
- package/es/PRIVATE_MonthYearGridView.js +8 -8
- package/es/PRIVATE_PlotArea.js +5 -5
- package/es/PRIVATE_RevealToggleIcon.js +21 -21
- package/es/PRIVATE_RichSelectionCommon.js +28 -28
- package/es/PRIVATE_SelectCommon.js +34 -34
- package/es/PRIVATE_StyledCard.js +3 -3
- package/es/PRIVATE_StyledCheckbox.js +16 -16
- package/es/PRIVATE_StyledDatePickerButton/themes/StyledDatePickerButtonStyles.css.js +1 -1
- package/es/PRIVATE_StyledDatePickerButton.js +1 -1
- package/es/PRIVATE_StyledSwitch.js +4 -4
- package/es/PRIVATE_SwatchFlexView.js +18 -18
- package/es/PRIVATE_Table.js +38 -38
- package/es/PRIVATE_TableDisplay.js +19 -19
- package/es/PRIVATE_TableList.js +31 -31
- package/es/PRIVATE_ThemedIcons/CalendarIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ChartMarqueeSelectIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ChartPanIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ChartZoomIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CheckIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CheckboxCrossedIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CheckboxMixedIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CheckboxOffIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CheckboxOnIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CloseIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/CollapseIcon.js +17 -17
- package/es/PRIVATE_ThemedIcons/CollapseUpIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/DecrementIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/DeleteIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/DirectionalCollapseArrowIcon.js +17 -17
- package/es/PRIVATE_ThemedIcons/DirectionalExpandArrowIcon.js +17 -17
- package/es/PRIVATE_ThemedIcons/DragHandleIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/DropdownArrowIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ExpandIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/HelpIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/IncrementIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MenuButtonDropdownIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MessageConfirmationIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MessageErrorIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MessageInfoIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MessageWarningIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/MinusIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/NavDownIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/None.js +16 -16
- package/es/PRIVATE_ThemedIcons/OverviewHorizontalDragHandleIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/PlusIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/RadioOffIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/RadioOnIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/SortAscendingIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/SortDescendingIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ViewHideIcon.js +16 -16
- package/es/PRIVATE_ThemedIcons/ViewIcon.js +16 -16
- package/es/PRIVATE_TimeComponent.js +19 -19
- package/es/PRIVATE_TruncatingLink.js +20 -17
- package/es/PRIVATE_TruncatingLink.js.map +1 -1
- package/es/PRIVATE_VisOverview.js +16 -16
- package/es/PRIVATE_VisStatusMessage.js +5 -5
- package/es/PRIVATE_VisTabularDatatip.js +4 -4
- package/es/Popup-22d51095.js +298 -0
- package/es/Popup-22d51095.js.map +1 -0
- package/es/ProgressButtonLabelLayout-69549cf9.js +3 -3
- package/es/ProgressCircle-bce87dad.js +48 -0
- package/es/ProgressCircle-bce87dad.js.map +1 -0
- package/es/RadioItem-94909632.js +6 -6
- package/es/ReadonlyTextFieldInput-106ce959.js +1 -1
- package/es/ReferenceLineArea-cc72b070.js +586 -0
- package/es/ReferenceLineArea-cc72b070.js.map +1 -0
- package/es/RevealToggleIcon-c5d9d731.js +26 -0
- package/es/RevealToggleIcon-c5d9d731.js.map +1 -0
- package/es/SectionedContent-ac90a3d0.js +65 -0
- package/es/SectionedContent-ac90a3d0.js.map +1 -0
- package/es/SegmentStyles.styles.css +12 -9
- package/es/SegmentStyles.styles2.css +9 -12
- package/es/SelectMenuGroupContext-130a850c.js +554 -0
- package/es/SelectMenuGroupContext-130a850c.js.map +1 -0
- package/es/SelectMobileFieldInput-5ca800d5.js +241 -0
- package/es/SelectMobileFieldInput-5ca800d5.js.map +1 -0
- package/es/SelectorAll-3d39196b.js +51 -0
- package/es/SelectorAll-3d39196b.js.map +1 -0
- package/es/Sheet-f9f8a4a4.js +2 -2
- package/es/SortControl-1044fcd9.js +3 -3
- package/es/StyledCard-77623731.js +1 -1
- package/es/StyledDatePickerButton-a7782821.js +32 -0
- package/es/StyledDatePickerButton-a7782821.js.map +1 -0
- package/es/StyledDatePickerButtonStyles.styles.css +18 -12
- package/es/StyledLabelValueLayout-bddfb884.js +18 -0
- package/es/StyledLabelValueLayout-bddfb884.js.map +1 -0
- package/es/StyledSwitch-dbf29d95.js +2 -2
- package/es/StyledTextField-7605d76a.js +5 -5
- package/es/Submenu-fa7c2b4f.js +247 -0
- package/es/Submenu-fa7c2b4f.js.map +1 -0
- package/es/TabBar-fd31ca03.js +69 -0
- package/es/TabBar-fd31ca03.js.map +1 -0
- package/es/TabBarContextMenu-3bf4dc64.js +99 -0
- package/es/TabBarContextMenu-3bf4dc64.js.map +1 -0
- package/es/TabBarLayout-9b67d1b6.js +1 -1
- package/es/TabBarLinkItem-43854314.js +13 -0
- package/es/TabBarLinkItem-43854314.js.map +1 -0
- package/es/Table-535987d0.js +4112 -0
- package/es/Table-535987d0.js.map +1 -0
- package/es/TableColGroup-d74bd4f5.js +1 -1
- package/es/TextField-7884fcd7.js +3 -3
- package/es/Theme-redwood/theme.css +432 -432
- package/es/Theme-stable/theme.css +474 -474
- package/es/TimeComponentCanvas2D-cfb0066d.js +6 -6
- package/es/ToggleButton-65f5d293.js +28 -0
- package/es/ToggleButton-65f5d293.js.map +1 -0
- package/es/ToggleButtonLabel-bf4e1599.js +75 -0
- package/es/ToggleButtonLabel-bf4e1599.js.map +1 -0
- package/es/TrainVariants.styles.css +6 -6
- package/es/TrainVariants.styles2.css +6 -6
- package/es/TruncatingLink-6aaf40b9.js +93 -0
- package/es/TruncatingLink-6aaf40b9.js.map +1 -0
- package/es/TruncatingText-1bf00351.js +1 -1
- package/es/UNSAFE_AccordionItemMultiple.js +18 -18
- package/es/UNSAFE_AccordionItemSingle.js +18 -18
- package/es/UNSAFE_ActionCard.js +2 -2
- package/es/UNSAFE_BarChart.js +46 -46
- package/es/UNSAFE_BareButton.js +2 -2
- package/es/UNSAFE_BaseButton.js +5 -5
- package/es/UNSAFE_Button.js +6 -6
- package/es/UNSAFE_ButtonSet.js +4 -4
- package/es/UNSAFE_ButtonSetButton.js +7 -7
- package/es/UNSAFE_ButtonSetIconButton.js +19 -19
- package/es/UNSAFE_ButtonSetItem.js +22 -22
- package/es/UNSAFE_ButtonSetMultiple.js +4 -4
- package/es/UNSAFE_ButtonSetSingle.js +4 -4
- package/es/UNSAFE_Card.js +3 -3
- package/es/UNSAFE_CardFlexView.js +23 -23
- package/es/UNSAFE_CardGridView.js +23 -23
- package/es/UNSAFE_Center.js +5 -5
- package/es/UNSAFE_Checkbox.js +25 -25
- package/es/UNSAFE_CheckboxItem.js +27 -27
- package/es/UNSAFE_CheckboxRadioField.js +4 -4
- package/es/UNSAFE_CheckboxSet.js +26 -26
- package/es/UNSAFE_Chip.js +2 -2
- package/es/UNSAFE_Collapsible.js +18 -18
- package/es/UNSAFE_ColorPalette.js +19 -19
- package/es/UNSAFE_ColorPicker.js +21 -21
- package/es/UNSAFE_ColorSwatch.js +17 -17
- package/es/UNSAFE_ComboChart.js +46 -46
- package/es/UNSAFE_ComponentMessage.js +20 -20
- package/es/UNSAFE_ContainerDiagram/themes/DiagramStyles.css.js +1 -1
- package/es/UNSAFE_ContainerDiagram.js +38 -38
- package/es/UNSAFE_ConveyorBelt.js +18 -18
- package/es/UNSAFE_DatePicker.js +54 -31
- package/es/UNSAFE_DatePicker.js.map +1 -1
- package/es/UNSAFE_Diagram/themes/DiagramStyles.css.js +1 -1
- package/es/UNSAFE_Diagram.js +38 -38
- package/es/UNSAFE_Dialog.js +22 -22
- package/es/UNSAFE_DragHandle.js +17 -17
- package/es/UNSAFE_DrawerLayout.js +12 -12
- package/es/UNSAFE_DrawerPopup.js +11 -11
- package/es/UNSAFE_Dropdown.js +15 -15
- package/es/UNSAFE_Environment.js +4 -4
- package/es/UNSAFE_ExpandableList.js +25 -25
- package/es/UNSAFE_FilePicker.js +4 -4
- package/es/UNSAFE_FlatTreeView.js +25 -25
- package/es/UNSAFE_Flex.js +4 -4
- package/es/UNSAFE_Floating.js +11 -11
- package/es/UNSAFE_FormLayout.js +2 -2
- package/es/UNSAFE_Gantt.js +23 -23
- package/es/UNSAFE_Grid.js +4 -4
- package/es/UNSAFE_HighlightText.js +4 -4
- package/es/UNSAFE_Icon.js +16 -16
- package/es/UNSAFE_IconButton.js +17 -17
- package/es/UNSAFE_IconMenuButton.js +26 -26
- package/es/UNSAFE_IconProgressButton.js +21 -21
- package/es/UNSAFE_IconToggleButton.js +19 -19
- package/es/UNSAFE_Indexer.js +19 -19
- package/es/UNSAFE_InlineSelectSingle.js +34 -34
- package/es/UNSAFE_InputColor.js +32 -32
- package/es/UNSAFE_InputDateMask/themes/SegmentStyles.css.js +1 -1
- package/es/UNSAFE_InputDateMask.js +27 -27
- package/es/UNSAFE_InputDatePicker.js +64 -42
- package/es/UNSAFE_InputDatePicker.js.map +1 -1
- package/es/UNSAFE_InputPassword.js +29 -29
- package/es/UNSAFE_InputSensitiveText.js +30 -30
- package/es/UNSAFE_InputText.js +28 -28
- package/es/UNSAFE_InputTimeMask/themes/SegmentStyles.css.js +1 -1
- package/es/UNSAFE_InputTimeMask.js +27 -27
- package/es/UNSAFE_Label.js +25 -25
- package/es/UNSAFE_LabelValueLayout.js +4 -4
- package/es/UNSAFE_LabelledLink.js +36 -31
- package/es/UNSAFE_LabelledLink.js.map +1 -1
- package/es/UNSAFE_Layer.js +8 -8
- package/es/UNSAFE_Legend.js +30 -30
- package/es/UNSAFE_LineAreaChart.js +46 -46
- package/es/UNSAFE_Link/themes/LinkStyles.css.js +1 -1
- package/es/UNSAFE_Link.js +3 -3
- package/es/UNSAFE_ListItemLayout.js +4 -4
- package/es/UNSAFE_ListView.js +75 -75
- package/es/UNSAFE_LiveRegion.js +4 -4
- package/es/UNSAFE_Menu.js +29 -29
- package/es/UNSAFE_MenuButton.js +26 -26
- package/es/UNSAFE_MessageBanner.js +20 -20
- package/es/UNSAFE_MessageToast.js +22 -22
- package/es/UNSAFE_MeterBar.js +16 -16
- package/es/UNSAFE_MeterCircle.js +17 -17
- package/es/UNSAFE_Modal.js +8 -8
- package/es/UNSAFE_NavigationList.js +42 -42
- package/es/UNSAFE_NavigationListCommon.js +20 -20
- package/es/UNSAFE_NumberInputText.js +28 -28
- package/es/UNSAFE_OverflowTabBar.js +42 -42
- package/es/UNSAFE_PictoChart.js +27 -27
- package/es/UNSAFE_PieChart.js +28 -28
- package/es/UNSAFE_Popup.js +18 -18
- package/es/UNSAFE_ProgressBar.js +4 -4
- package/es/UNSAFE_ProgressButton.js +21 -21
- package/es/UNSAFE_ProgressButtonLabelLayout.js +10 -10
- package/es/UNSAFE_ProgressCircle.js +4 -4
- package/es/UNSAFE_RadioItem.js +25 -25
- package/es/UNSAFE_RadioSet.js +27 -27
- package/es/UNSAFE_RatingGauge.js +18 -18
- package/es/UNSAFE_ReorderableTabBar.js +42 -42
- package/es/UNSAFE_RichCheckboxSet.js +28 -28
- package/es/UNSAFE_RichRadioSet.js +29 -29
- package/es/UNSAFE_RichSelectionItem.js +30 -30
- package/es/UNSAFE_ScatterChart.js +46 -46
- package/es/UNSAFE_SectionalLegend.js +30 -30
- package/es/UNSAFE_SelectMultiple.js +38 -38
- package/es/UNSAFE_SelectSingle.js +38 -38
- package/es/UNSAFE_SelectionCard.js +3 -3
- package/es/UNSAFE_Selector.js +17 -17
- package/es/UNSAFE_SelectorAll.js +19 -19
- package/es/UNSAFE_Sheet.js +11 -11
- package/es/UNSAFE_SortControl.js +20 -20
- package/es/UNSAFE_SplitMenuButton.js +27 -27
- package/es/UNSAFE_SplitMenuButton.js.map +1 -1
- package/es/UNSAFE_Switch.js +26 -26
- package/es/UNSAFE_TabBar.js +43 -43
- package/es/UNSAFE_TabBarCommon.js +33 -33
- package/es/UNSAFE_TabBarMixed.js +41 -41
- package/es/UNSAFE_TableView.js +38 -38
- package/es/UNSAFE_TagCloud.js +28 -28
- package/es/UNSAFE_TextArea.js +237 -117
- package/es/UNSAFE_TextArea.js.map +1 -1
- package/es/UNSAFE_TextAreaAutosize.js +28 -28
- package/es/UNSAFE_TextField.js +20 -20
- package/es/UNSAFE_ToggleButton.js +7 -7
- package/es/UNSAFE_ToggleButtonLabel.js +1 -1
- package/es/UNSAFE_Toolbar.js +4 -4
- package/es/UNSAFE_Train/themes/redwood/TrainTheme.js +1 -1
- package/es/UNSAFE_Train/themes/redwood/TrainVariants.css.js +1 -1
- package/es/UNSAFE_Train/themes/stable/TrainTheme.js +1 -1
- package/es/UNSAFE_Train/themes/stable/TrainVariants.css.js +1 -1
- package/es/UNSAFE_Train.js +18 -18
- package/es/UNSAFE_TruncatingBadge.js +17 -17
- package/es/UNSAFE_TruncatingText.js +17 -17
- package/es/UNSAFE_UserAssistance.js +26 -26
- package/es/UNSAFE_View.js +7 -7
- package/es/UNSAFE_VirtualizedListView.js +21 -21
- package/es/UNSAFE_VisInvalidDataMessage.js +6 -6
- package/es/UNSAFE_VisNoDataMessage.js +6 -6
- package/es/UNSAFE_VisProgressiveLoader.js +5 -5
- package/es/UNSAFE_WindowOverlay.js +4 -4
- package/es/View-818f2f31.js +167 -0
- package/es/View-818f2f31.js.map +1 -0
- package/es/VisStatusMessage-09c532e3.js +29 -0
- package/es/VisStatusMessage-09c532e3.js.map +1 -0
- package/es/VisTabularDatatip-f45069f1.js +24 -0
- package/es/VisTabularDatatip-f45069f1.js.map +1 -0
- package/es/WindowOverlay-467c2d12.js +110 -0
- package/es/WindowOverlay-467c2d12.js.map +1 -0
- package/es/YearsGridView-27d6fa06.js +187 -0
- package/es/YearsGridView-27d6fa06.js.map +1 -0
- package/es/hoc/PRIVATE_withDirectionIcon.js +4 -4
- package/es/hoc/PRIVATE_withThemeIcon.js +3 -3
- package/es/hoc/UNSAFE_withThemeProps.js +3 -3
- package/es/hooks/PRIVATE_useChartContextMenu.js +26 -26
- package/es/hooks/PRIVATE_useChartDatatip.js +14 -14
- package/es/hooks/PRIVATE_useChartEvents.js +19 -19
- package/es/hooks/PRIVATE_useChartMarquee.js +26 -26
- package/es/hooks/PRIVATE_useCollectionFocusRing.js +17 -17
- package/es/hooks/PRIVATE_useCssVars.js +7 -7
- package/es/hooks/PRIVATE_useCurrentKey.js +4 -4
- package/es/hooks/PRIVATE_useDatatip.js +12 -12
- package/es/hooks/PRIVATE_useDetectHorizontalOverflow.js +16 -16
- package/es/hooks/PRIVATE_useFloating.js +4 -4
- package/es/hooks/PRIVATE_useItemAction.js +17 -17
- package/es/hooks/PRIVATE_useListCommon.js +19 -19
- package/es/hooks/PRIVATE_useMiddleEllipsis.js +4 -0
- package/es/hooks/PRIVATE_useMiddleEllipsis.js.map +1 -0
- package/es/hooks/PRIVATE_useOutsideMousedown.js +9 -9
- package/es/hooks/PRIVATE_useRadioFocusManager.js +4 -4
- package/es/hooks/PRIVATE_useReorderable.js +19 -19
- package/es/hooks/PRIVATE_useRovingTabIndexContainer.js +4 -4
- package/es/hooks/PRIVATE_useSelection.js +4 -4
- package/es/hooks/PRIVATE_useTabBar.js +29 -29
- package/es/hooks/PRIVATE_useTabbableModeSet.js +17 -17
- package/es/hooks/PRIVATE_useTooltipOnTruncation.js +17 -17
- package/es/hooks/PRIVATE_useVisContextMenu.js +25 -25
- package/es/hooks/PRIVATE_useVisDragModeControls.js +25 -25
- package/es/hooks/PRIVATE_useVisEvents.js +4 -4
- package/es/hooks/PRIVATE_useVisMeterEvents.js +14 -14
- package/es/hooks/PRIVATE_useVisSelection.js +15 -15
- package/es/hooks/UNSAFE_useBareButton.js +2 -2
- package/es/hooks/UNSAFE_useColorScheme.js +3 -3
- package/es/hooks/UNSAFE_useCurrentBgColor.js +2 -2
- package/es/hooks/UNSAFE_useDensity.js +3 -3
- package/es/hooks/UNSAFE_useHiddenTestMethod.js +3 -3
- package/es/hooks/UNSAFE_useOutsideClick.js +8 -8
- package/es/hooks/UNSAFE_usePrefixSuffix.js +4 -4
- package/es/hooks/UNSAFE_useScale.js +3 -3
- package/es/hooks/UNSAFE_useTestId.js +3 -3
- package/es/hooks/UNSAFE_useTheme.js +3 -3
- package/es/hooks/UNSAFE_useThemeInterpolations.js +6 -6
- package/es/hooks/UNSAFE_useTooltip.js +17 -17
- package/es/hooks/UNSAFE_useTranslationBundle.js +3 -3
- package/es/hooks/UNSAFE_useUser.js +3 -3
- package/es/popupUtils-7774330e.js +29 -0
- package/es/popupUtils-7774330e.js.map +1 -0
- package/es/tooltipUtils-90fb656f.js +110 -0
- package/es/tooltipUtils-90fb656f.js.map +1 -0
- package/es/useBareButton-ff4bd21e.js +1 -1
- package/es/useCellNavigation-0565b6dd.js +1 -1
- package/es/useChartContextMenu-933091d8.js +123 -0
- package/es/useChartContextMenu-933091d8.js.map +1 -0
- package/es/useChartDatatip-cba78e0f.js +336 -0
- package/es/useChartDatatip-cba78e0f.js.map +1 -0
- package/es/useChartMarquee-914929b6.js +304 -0
- package/es/useChartMarquee-914929b6.js.map +1 -0
- package/es/useColorScheme-67245285.js +19 -0
- package/es/useColorScheme-67245285.js.map +1 -0
- package/es/useContextMenu-8a1230a3.js +116 -0
- package/es/useContextMenu-8a1230a3.js.map +1 -0
- package/es/useCssVars-048a52d8.js +58 -0
- package/es/useCssVars-048a52d8.js.map +1 -0
- package/es/useCurrentKey-38e5f097.js +83 -0
- package/es/useCurrentKey-38e5f097.js.map +1 -0
- package/es/useDatatip-ef5c47a7.js +94 -0
- package/es/useDatatip-ef5c47a7.js.map +1 -0
- package/es/useDensity-969273f3.js +19 -0
- package/es/useDensity-969273f3.js.map +1 -0
- package/es/useDisplayValue-29f03329.js +78 -0
- package/es/useDisplayValue-29f03329.js.map +1 -0
- package/es/useExpandCollapse-51f9bb4b.js +70 -0
- package/es/useExpandCollapse-51f9bb4b.js.map +1 -0
- package/es/useFloating-c74a7f54.js +1916 -0
- package/es/useFloating-c74a7f54.js.map +1 -0
- package/es/useHiddenTestMethod-ec7b3989.js +28 -0
- package/es/useHiddenTestMethod-ec7b3989.js.map +1 -0
- package/es/useKeyboardEvents-a1495728.js +85 -0
- package/es/useKeyboardEvents-a1495728.js.map +1 -0
- package/es/useLegendContextMenu-6ea00771.js +279 -0
- package/es/useLegendContextMenu-6ea00771.js.map +1 -0
- package/es/useMeterDatatip-f61ca3e0.js +73 -0
- package/es/useMeterDatatip-f61ca3e0.js.map +1 -0
- package/es/useMiddleEllipsis-b073ca6b.js +228 -0
- package/es/useMiddleEllipsis-b073ca6b.js.map +1 -0
- package/es/useNavigation-b257c33a.js +1 -1
- package/es/useOutsideClick-01f3d3e1.js +115 -0
- package/es/useOutsideClick-01f3d3e1.js.map +1 -0
- package/es/useOutsideMousedown-e0866d58.js +48 -0
- package/es/useOutsideMousedown-e0866d58.js.map +1 -0
- package/es/usePopupAnimation-7c5db425.js +85 -0
- package/es/usePopupAnimation-7c5db425.js.map +1 -0
- package/es/usePrefixSuffix-95fc00fd.js +70 -0
- package/es/usePrefixSuffix-95fc00fd.js.map +1 -0
- package/es/useRadioFocusManager-d9eecfb4.js +108 -0
- package/es/useRadioFocusManager-d9eecfb4.js.map +1 -0
- package/es/useReorderableItem-06bd7a7b.js +296 -0
- package/es/useReorderableItem-06bd7a7b.js.map +1 -0
- package/es/useRovingTabIndexContainer-c0356f5d.js +106 -0
- package/es/useRovingTabIndexContainer-c0356f5d.js.map +1 -0
- package/es/useScale-93490e54.js +19 -0
- package/es/useScale-93490e54.js.map +1 -0
- package/es/useSelectCommon-c70bb10f.js +489 -0
- package/es/useSelectCommon-c70bb10f.js.map +1 -0
- package/es/useSelectDrill-2f855daa.js +111 -0
- package/es/useSelectDrill-2f855daa.js.map +1 -0
- package/es/useSelection-10ed8060.js +186 -0
- package/es/useSelection-10ed8060.js.map +1 -0
- package/es/useSelection-d6fefa3d.js +258 -0
- package/es/useSelection-d6fefa3d.js.map +1 -0
- package/es/useTabBar-27e8c4ea.js +305 -0
- package/es/useTabBar-27e8c4ea.js.map +1 -0
- package/es/useTestId-ab1bede6.js +21 -0
- package/es/useTestId-ab1bede6.js.map +1 -0
- package/es/useTextAreaAltEnter-ac460f4c.js +61 -0
- package/es/useTextAreaAltEnter-ac460f4c.js.map +1 -0
- package/es/useTheme-c2cfbc29.js +19 -0
- package/es/useTheme-c2cfbc29.js.map +1 -0
- package/es/useThemeInterpolations-5f358139.js +68 -0
- package/es/useThemeInterpolations-5f358139.js.map +1 -0
- package/es/useTooltip-ab739df0.js +49 -0
- package/es/useTooltip-ab739df0.js.map +1 -0
- package/es/useTooltipControlled-b7f30aee.js +373 -0
- package/es/useTooltipControlled-b7f30aee.js.map +1 -0
- package/es/useTooltipOnTruncation-31afc3f2.js +27 -0
- package/es/useTooltipOnTruncation-31afc3f2.js.map +1 -0
- package/es/useTranslationBundle-bc6e0896.js +29 -0
- package/es/useTranslationBundle-bc6e0896.js.map +1 -0
- package/es/useUser-e543b73c.js +19 -0
- package/es/useUser-e543b73c.js.map +1 -0
- package/es/useVisDragModeControls-6865056f.js +87 -0
- package/es/useVisDragModeControls-6865056f.js.map +1 -0
- package/es/useVisEvents-0edc925f.js +153 -0
- package/es/useVisEvents-0edc925f.js.map +1 -0
- package/es/utils/PRIVATE_collectionUtils.js +17 -17
- package/es/utils/PRIVATE_tabBarUtils.js +17 -17
- package/es/utils/PRIVATE_tooltipUtils.js +14 -14
- package/es/utils/PRIVATE_visTestUtils.js +4 -4
- package/es/utils/UNSAFE_popupUtils.js +8 -8
- package/es/withDirectionIcon-b725a6d7.js +14 -0
- package/es/withDirectionIcon-b725a6d7.js.map +1 -0
- package/es/withThemeProps-dbd4fedf.js +2 -2
- package/package.json +2 -2
- package/types/UNSAFE_Dropdown/Dropdown.d.ts +5 -1
- package/types/UNSAFE_LabelledLink/LabelledLink.d.ts +5 -1
- package/types/UNSAFE_Link/themes/LinkStyles.css.d.ts +0 -1
- package/types/UNSAFE_Link/themes/redwood/LinkVariants.css.d.ts +0 -1
- package/types/UNSAFE_Link/themes/stable/LinkVariants.css.d.ts +0 -1
- package/types/UNSAFE_Menu/DropdownMenu.d.ts +1 -0
- package/amd/BarChart-f429b382.js +0 -2
- package/amd/BarChart-f429b382.js.map +0 -1
- package/amd/BaseCardView-b8119561.js +0 -2
- package/amd/BaseCardView-b8119561.js.map +0 -1
- package/amd/BaseDiagram-00ea8628.js +0 -2
- package/amd/BaseDiagram-00ea8628.js.map +0 -1
- package/amd/ButtonSetButton-fa0256aa.js +0 -2
- package/amd/ButtonSetButton-fa0256aa.js.map +0 -1
- package/amd/ButtonSetIconButton-9010f20c.js +0 -2
- package/amd/ButtonSetIconButton-9010f20c.js.map +0 -1
- package/amd/ButtonSetItem-4b29107a.js +0 -2
- package/amd/ButtonSetItem-4b29107a.js.map +0 -1
- package/amd/CardFlexView-aa2f3de8.js +0 -2
- package/amd/CardFlexView-aa2f3de8.js.map +0 -1
- package/amd/CardGridView-85f90c75.js +0 -2
- package/amd/CardGridView-85f90c75.js.map +0 -1
- package/amd/Chart-57965de4.js +0 -2
- package/amd/Chart-57965de4.js.map +0 -1
- package/amd/ComboChart-c42ed049.js +0 -2
- package/amd/ComboChart-c42ed049.js.map +0 -1
- package/amd/ContainerDiagram-678f9746.js +0 -2
- package/amd/ContainerDiagram-678f9746.js.map +0 -1
- package/amd/DatePicker-bf521b1c.js +0 -2
- package/amd/DatePicker-bf521b1c.js.map +0 -1
- package/amd/DatePickerHeader-82f4f285.js +0 -2
- package/amd/DatePickerHeader-82f4f285.js.map +0 -1
- package/amd/Diagram-492f8b21.js +0 -2
- package/amd/Diagram-492f8b21.js.map +0 -1
- package/amd/Dropdown-7eca9554.js +0 -2
- package/amd/Dropdown-7eca9554.js.map +0 -1
- package/amd/IconMenuButton-82b8431d.js +0 -2
- package/amd/IconMenuButton-82b8431d.js.map +0 -1
- package/amd/IconSwitchButton-c44e0edf.js +0 -2
- package/amd/IconSwitchButton-c44e0edf.js.map +0 -1
- package/amd/IconToggleButton-0ab34b44.js +0 -2
- package/amd/IconToggleButton-0ab34b44.js.map +0 -1
- package/amd/InlineSelectSingle-87bc8a45.js +0 -2
- package/amd/InlineSelectSingle-87bc8a45.js.map +0 -1
- package/amd/InputColor-58e3fce3.js +0 -2
- package/amd/InputColor-58e3fce3.js.map +0 -1
- package/amd/InputDatePicker-7227a858.js +0 -2
- package/amd/InputDatePicker-7227a858.js.map +0 -1
- package/amd/InputPassword-450915c8.js +0 -2
- package/amd/InputPassword-450915c8.js.map +0 -1
- package/amd/InputSensitiveText-d94d24f0.js +0 -2
- package/amd/InputSensitiveText-d94d24f0.js.map +0 -1
- package/amd/Legend-47a1bf23.js +0 -2
- package/amd/Legend-47a1bf23.js.map +0 -1
- package/amd/LineAreaChart-48efb7f7.js +0 -2
- package/amd/LineAreaChart-48efb7f7.js.map +0 -1
- package/amd/Link-a8fad252.js +0 -2
- package/amd/Link-a8fad252.js.map +0 -1
- package/amd/ListView-2678b2af.js +0 -2
- package/amd/ListView-2678b2af.js.map +0 -1
- package/amd/Menu-1b8fefc5.js +0 -2
- package/amd/Menu-1b8fefc5.js.map +0 -1
- package/amd/MenuButton-2fe1ef2c.js +0 -2
- package/amd/MenuButton-2fe1ef2c.js.map +0 -1
- package/amd/MenuItem-85e4ffdc.js +0 -2
- package/amd/MenuItem-85e4ffdc.js.map +0 -1
- package/amd/MonthView-96fafba4.js +0 -2
- package/amd/MonthView-96fafba4.js.map +0 -1
- package/amd/NavigationList-a6bb123d.js +0 -2
- package/amd/NavigationList-a6bb123d.js.map +0 -1
- package/amd/NavigationListItem-10bf6656.js +0 -2
- package/amd/NavigationListItem-10bf6656.js.map +0 -1
- package/amd/NavigationListLinkItem-df1826e6.js +0 -2
- package/amd/NavigationListLinkItem-df1826e6.js.map +0 -1
- package/amd/OverflowTabBar-f8bf9356.js +0 -2
- package/amd/OverflowTabBar-f8bf9356.js.map +0 -1
- package/amd/OverflowTabBarItem-0aa39512.js +0 -2
- package/amd/OverflowTabBarItem-0aa39512.js.map +0 -1
- package/amd/PictoChart-ab426a71.js +0 -2
- package/amd/PictoChart-ab426a71.js.map +0 -1
- package/amd/PieChart-57ffe4c0.js +0 -2
- package/amd/PieChart-57ffe4c0.js.map +0 -1
- package/amd/RemovableNavigationListItem-60593d4c.js +0 -2
- package/amd/RemovableNavigationListItem-60593d4c.js.map +0 -1
- package/amd/ReorderableTabBar-19a503c7.js +0 -2
- package/amd/ReorderableTabBar-19a503c7.js.map +0 -1
- package/amd/RevealToggleIcon-093f60c4.js +0 -2
- package/amd/RevealToggleIcon-093f60c4.js.map +0 -1
- package/amd/ScatterChart-6427e7ec.js +0 -2
- package/amd/ScatterChart-6427e7ec.js.map +0 -1
- package/amd/SectionalLegend-bd980f3f.js +0 -2
- package/amd/SectionalLegend-bd980f3f.js.map +0 -1
- package/amd/SectionedContent-74559d9d.js +0 -2
- package/amd/SectionedContent-74559d9d.js.map +0 -1
- package/amd/SelectMenuItem-affab9f3.js +0 -2
- package/amd/SelectMenuItem-affab9f3.js.map +0 -1
- package/amd/SelectMobileFieldInput-4795a794.js +0 -2
- package/amd/SelectMobileFieldInput-4795a794.js.map +0 -1
- package/amd/SelectMultiple-e216b16c.js +0 -2
- package/amd/SelectMultiple-e216b16c.js.map +0 -1
- package/amd/SelectSingle-d53cf202.js +0 -2
- package/amd/SelectSingle-d53cf202.js.map +0 -1
- package/amd/SplitMenuButton-76adec12.js +0 -2
- package/amd/SplitMenuButton-76adec12.js.map +0 -1
- package/amd/StyledDatePickerButton-bceb62e1.js +0 -2
- package/amd/StyledDatePickerButton-bceb62e1.js.map +0 -1
- package/amd/Submenu-52ec8bfb.js +0 -2
- package/amd/Submenu-52ec8bfb.js.map +0 -1
- package/amd/TabBar-92bac52f.js +0 -2
- package/amd/TabBar-92bac52f.js.map +0 -1
- package/amd/TabBarContextMenu-6a167e27.js +0 -2
- package/amd/TabBarContextMenu-6a167e27.js.map +0 -1
- package/amd/TabBarMixed-5b5a5047.js +0 -2
- package/amd/TabBarMixed-5b5a5047.js.map +0 -1
- package/amd/Table-74566993.js +0 -2
- package/amd/Table-74566993.js.map +0 -1
- package/amd/TableView-3d82855c.js +0 -2
- package/amd/TableView-3d82855c.js.map +0 -1
- package/amd/TagCloud-c10a166e.js +0 -2
- package/amd/TagCloud-c10a166e.js.map +0 -1
- package/amd/ToggleButton-b77486fe.js +0 -2
- package/amd/ToggleButton-b77486fe.js.map +0 -1
- package/amd/ToggleButtonLabel-87364773.js +0 -2
- package/amd/ToggleButtonLabel-87364773.js.map +0 -1
- package/amd/TruncatingLink-591e7ff1.js +0 -2
- package/amd/TruncatingLink-591e7ff1.js.map +0 -1
- package/amd/YearsGridView-561c3074.js +0 -2
- package/amd/YearsGridView-561c3074.js.map +0 -1
- package/amd/listViewSelectionTests-7d18f09e.js +0 -2
- package/amd/listViewSelectionTests-7d18f09e.js.map +0 -1
- package/amd/useChartContextMenu-abadeabc.js +0 -2
- package/amd/useChartContextMenu-abadeabc.js.map +0 -1
- package/amd/useChartMarquee-3865426f.js +0 -2
- package/amd/useChartMarquee-3865426f.js.map +0 -1
- package/amd/useContextMenu-67972d45.js +0 -2
- package/amd/useContextMenu-67972d45.js.map +0 -1
- package/amd/useDisplayValue-9b671893.js +0 -2
- package/amd/useDisplayValue-9b671893.js.map +0 -1
- package/amd/useLegendContextMenu-55fedade.js +0 -2
- package/amd/useLegendContextMenu-55fedade.js.map +0 -1
- package/amd/useNavigationListItem-582f5564.js +0 -2
- package/amd/useNavigationListItem-582f5564.js.map +0 -1
- package/amd/useSelectCommon-f33709d2.js +0 -2
- package/amd/useSelectCommon-f33709d2.js.map +0 -1
- package/amd/useTabBar-b05edef0.js +0 -2
- package/amd/useTabBar-b05edef0.js.map +0 -1
- package/amd/useVisDragModeControls-5f059d09.js +0 -2
- package/amd/useVisDragModeControls-5f059d09.js.map +0 -1
- package/cjs/BaseButton-d8f96bfa.js +0 -86
- package/cjs/BaseButton-d8f96bfa.js.map +0 -1
- package/cjs/BaseDiagram-ce4f1a20.js +0 -2956
- package/cjs/BaseDiagram-ce4f1a20.js.map +0 -1
- package/cjs/Button-020e0381.js +0 -24
- package/cjs/Button-020e0381.js.map +0 -1
- package/cjs/ButtonSetButton-569e0efb.js +0 -35
- package/cjs/ButtonSetButton-569e0efb.js.map +0 -1
- package/cjs/ButtonSetIconButton-3778ac7b.js +0 -40
- package/cjs/ButtonSetIconButton-3778ac7b.js.map +0 -1
- package/cjs/ButtonSetItem-4322c957.js +0 -67
- package/cjs/ButtonSetItem-4322c957.js.map +0 -1
- package/cjs/Center-9a0ee4f3.js +0 -18
- package/cjs/Center-9a0ee4f3.js.map +0 -1
- package/cjs/Chart-966da017.js +0 -754
- package/cjs/Chart-966da017.js.map +0 -1
- package/cjs/CheckboxSet-6865f4fd.js +0 -55
- package/cjs/CheckboxSet-6865f4fd.js.map +0 -1
- package/cjs/ColorPalette-b14114d8.js +0 -83
- package/cjs/ColorPalette-b14114d8.js.map +0 -1
- package/cjs/ColorPicker-8f0b6000.js +0 -25
- package/cjs/ColorPicker-8f0b6000.js.map +0 -1
- package/cjs/CompactLabelAssistance-e910bb56.js +0 -95
- package/cjs/CompactLabelAssistance-e910bb56.js.map +0 -1
- package/cjs/DatePicker-b60f8a7e.js +0 -601
- package/cjs/DatePicker-b60f8a7e.js.map +0 -1
- package/cjs/DatePickerHeader-1010204c.js +0 -48
- package/cjs/DatePickerHeader-1010204c.js.map +0 -1
- package/cjs/Dialog-8b65180c.js +0 -389
- package/cjs/Dialog-8b65180c.js.map +0 -1
- package/cjs/Dropdown-1ba432a8.js +0 -333
- package/cjs/Dropdown-1ba432a8.js.map +0 -1
- package/cjs/EmbeddedIconButton-cc159a01.js +0 -13
- package/cjs/EmbeddedIconButton-cc159a01.js.map +0 -1
- package/cjs/EnvironmentProvider-5f2435e6.js +0 -61
- package/cjs/EnvironmentProvider-5f2435e6.js.map +0 -1
- package/cjs/Flex-3a257bc3.js +0 -32
- package/cjs/Flex-3a257bc3.js.map +0 -1
- package/cjs/Floating-79cbe5ad.js +0 -467
- package/cjs/Floating-79cbe5ad.js.map +0 -1
- package/cjs/Grid-cef20569.js +0 -29
- package/cjs/Grid-cef20569.js.map +0 -1
- package/cjs/HighlightText-f4535f3d.js +0 -33
- package/cjs/HighlightText-f4535f3d.js.map +0 -1
- package/cjs/IconSwitchButton-9b0df2d6.js +0 -44
- package/cjs/IconSwitchButton-9b0df2d6.js.map +0 -1
- package/cjs/IconToggleButton-d2147159.js +0 -43
- package/cjs/IconToggleButton-d2147159.js.map +0 -1
- package/cjs/IconUserAssistance-89913ad1.js +0 -76
- package/cjs/IconUserAssistance-89913ad1.js.map +0 -1
- package/cjs/Layer-b60deb1b.js +0 -94
- package/cjs/Layer-b60deb1b.js.map +0 -1
- package/cjs/LayerHost-3cd73603.js +0 -46
- package/cjs/LayerHost-3cd73603.js.map +0 -1
- package/cjs/LayerManager-c535d963.js +0 -36
- package/cjs/LayerManager-c535d963.js.map +0 -1
- package/cjs/Link-cc34e4c1.js +0 -35
- package/cjs/Link-cc34e4c1.js.map +0 -1
- package/cjs/LiveRegion-62ce9ac7.js +0 -41
- package/cjs/LiveRegion-62ce9ac7.js.map +0 -1
- package/cjs/MaxLengthLiveRegion-0a6ba765.js +0 -28
- package/cjs/MaxLengthLiveRegion-0a6ba765.js.map +0 -1
- package/cjs/MessageLayer-8e6e3d98.js +0 -61
- package/cjs/MessageLayer-8e6e3d98.js.map +0 -1
- package/cjs/MonthView-a2661a58.js +0 -210
- package/cjs/MonthView-a2661a58.js.map +0 -1
- package/cjs/NavigationList-d0d74565.js +0 -307
- package/cjs/NavigationList-d0d74565.js.map +0 -1
- package/cjs/NavigationListItem-b0b03089.js +0 -12
- package/cjs/NavigationListItem-b0b03089.js.map +0 -1
- package/cjs/NavigationListLinkItem-317a5200.js +0 -146
- package/cjs/NavigationListLinkItem-317a5200.js.map +0 -1
- package/cjs/OverflowTabBarItem-19ad4971.js +0 -264
- package/cjs/OverflowTabBarItem-19ad4971.js.map +0 -1
- package/cjs/Popup-de16d915.js +0 -300
- package/cjs/Popup-de16d915.js.map +0 -1
- package/cjs/ProgressCircle-cac3c03a.js +0 -50
- package/cjs/ProgressCircle-cac3c03a.js.map +0 -1
- package/cjs/ReferenceLineArea-7bc34276.js +0 -592
- package/cjs/ReferenceLineArea-7bc34276.js.map +0 -1
- package/cjs/RevealToggleIcon-a6a4f8db.js +0 -28
- package/cjs/RevealToggleIcon-a6a4f8db.js.map +0 -1
- package/cjs/SectionedContent-5eff5dce.js +0 -68
- package/cjs/SectionedContent-5eff5dce.js.map +0 -1
- package/cjs/SelectMenuGroupContext-a349d259.js +0 -551
- package/cjs/SelectMenuGroupContext-a349d259.js.map +0 -1
- package/cjs/SelectMobileFieldInput-cbf57541.js +0 -248
- package/cjs/SelectMobileFieldInput-cbf57541.js.map +0 -1
- package/cjs/SelectorAll-9118eb07.js +0 -53
- package/cjs/SelectorAll-9118eb07.js.map +0 -1
- package/cjs/StyledDatePickerButton-becd2a7d.js +0 -33
- package/cjs/StyledDatePickerButton-becd2a7d.js.map +0 -1
- package/cjs/StyledLabelValueLayout-48da61b9.js +0 -22
- package/cjs/StyledLabelValueLayout-48da61b9.js.map +0 -1
- package/cjs/Submenu-8e92469f.js +0 -251
- package/cjs/Submenu-8e92469f.js.map +0 -1
- package/cjs/TabBar-d84e222e.js +0 -79
- package/cjs/TabBar-d84e222e.js.map +0 -1
- package/cjs/TabBarContextMenu-d9bf65c2.js +0 -102
- package/cjs/TabBarContextMenu-d9bf65c2.js.map +0 -1
- package/cjs/TabBarLinkItem-e924f83b.js +0 -15
- package/cjs/TabBarLinkItem-e924f83b.js.map +0 -1
- package/cjs/Table-a102e1ee.js +0 -4114
- package/cjs/Table-a102e1ee.js.map +0 -1
- package/cjs/ToggleButton-5ebfe20e.js +0 -30
- package/cjs/ToggleButton-5ebfe20e.js.map +0 -1
- package/cjs/ToggleButtonLabel-c8f36317.js +0 -73
- package/cjs/ToggleButtonLabel-c8f36317.js.map +0 -1
- package/cjs/TruncatingLink-867da10e.js +0 -58
- package/cjs/TruncatingLink-867da10e.js.map +0 -1
- package/cjs/View-ed116d78.js +0 -170
- package/cjs/View-ed116d78.js.map +0 -1
- package/cjs/VisStatusMessage-07e63c6e.js +0 -31
- package/cjs/VisStatusMessage-07e63c6e.js.map +0 -1
- package/cjs/VisTabularDatatip-abfef042.js +0 -26
- package/cjs/VisTabularDatatip-abfef042.js.map +0 -1
- package/cjs/WindowOverlay-85d999fa.js +0 -112
- package/cjs/WindowOverlay-85d999fa.js.map +0 -1
- package/cjs/YearsGridView-d0d4e8e1.js +0 -190
- package/cjs/YearsGridView-d0d4e8e1.js.map +0 -1
- package/cjs/popupUtils-1d123cbe.js +0 -31
- package/cjs/popupUtils-1d123cbe.js.map +0 -1
- package/cjs/tooltipUtils-2bc15136.js +0 -115
- package/cjs/tooltipUtils-2bc15136.js.map +0 -1
- package/cjs/useChartContextMenu-af989b4f.js +0 -125
- package/cjs/useChartContextMenu-af989b4f.js.map +0 -1
- package/cjs/useChartDatatip-1bceba5d.js +0 -341
- package/cjs/useChartDatatip-1bceba5d.js.map +0 -1
- package/cjs/useChartMarquee-ede5cae4.js +0 -306
- package/cjs/useChartMarquee-ede5cae4.js.map +0 -1
- package/cjs/useColorScheme-f8b1447d.js +0 -21
- package/cjs/useColorScheme-f8b1447d.js.map +0 -1
- package/cjs/useContextMenu-2500df06.js +0 -119
- package/cjs/useContextMenu-2500df06.js.map +0 -1
- package/cjs/useCssVars-8e83d496.js +0 -60
- package/cjs/useCssVars-8e83d496.js.map +0 -1
- package/cjs/useCurrentKey-1b9e3382.js +0 -85
- package/cjs/useCurrentKey-1b9e3382.js.map +0 -1
- package/cjs/useDatatip-b7b4f13f.js +0 -96
- package/cjs/useDatatip-b7b4f13f.js.map +0 -1
- package/cjs/useDensity-0b9fd9ca.js +0 -21
- package/cjs/useDensity-0b9fd9ca.js.map +0 -1
- package/cjs/useDisplayValue-4ace417c.js +0 -82
- package/cjs/useDisplayValue-4ace417c.js.map +0 -1
- package/cjs/useExpandCollapse-ef990199.js +0 -72
- package/cjs/useExpandCollapse-ef990199.js.map +0 -1
- package/cjs/useFloating-c753a7f9.js +0 -1926
- package/cjs/useFloating-c753a7f9.js.map +0 -1
- package/cjs/useHiddenTestMethod-eae1d48b.js +0 -30
- package/cjs/useHiddenTestMethod-eae1d48b.js.map +0 -1
- package/cjs/useKeyboardEvents-0ab70381.js +0 -88
- package/cjs/useKeyboardEvents-0ab70381.js.map +0 -1
- package/cjs/useLegendContextMenu-2cf579d7.js +0 -285
- package/cjs/useLegendContextMenu-2cf579d7.js.map +0 -1
- package/cjs/useMeterDatatip-92ca91d9.js +0 -76
- package/cjs/useMeterDatatip-92ca91d9.js.map +0 -1
- package/cjs/useNavigationListItem-b97e76d5.js +0 -104
- package/cjs/useNavigationListItem-b97e76d5.js.map +0 -1
- package/cjs/useOutsideClick-dbf3d604.js +0 -117
- package/cjs/useOutsideClick-dbf3d604.js.map +0 -1
- package/cjs/useOutsideMousedown-70f36cca.js +0 -50
- package/cjs/useOutsideMousedown-70f36cca.js.map +0 -1
- package/cjs/usePopupAnimation-f3b34413.js +0 -87
- package/cjs/usePopupAnimation-f3b34413.js.map +0 -1
- package/cjs/usePrefixSuffix-23d1cc33.js +0 -72
- package/cjs/usePrefixSuffix-23d1cc33.js.map +0 -1
- package/cjs/useRadioFocusManager-a11750e7.js +0 -110
- package/cjs/useRadioFocusManager-a11750e7.js.map +0 -1
- package/cjs/useReorderableItem-64be8d2b.js +0 -299
- package/cjs/useReorderableItem-64be8d2b.js.map +0 -1
- package/cjs/useRovingTabIndexContainer-0ce4681d.js +0 -108
- package/cjs/useRovingTabIndexContainer-0ce4681d.js.map +0 -1
- package/cjs/useScale-db16c2b8.js +0 -21
- package/cjs/useScale-db16c2b8.js.map +0 -1
- package/cjs/useSelectCommon-27afecfa.js +0 -507
- package/cjs/useSelectCommon-27afecfa.js.map +0 -1
- package/cjs/useSelectDrill-0b4b47ec.js +0 -114
- package/cjs/useSelectDrill-0b4b47ec.js.map +0 -1
- package/cjs/useSelection-37939f09.js +0 -260
- package/cjs/useSelection-37939f09.js.map +0 -1
- package/cjs/useSelection-da64e28e.js +0 -188
- package/cjs/useSelection-da64e28e.js.map +0 -1
- package/cjs/useTabBar-35b73d10.js +0 -309
- package/cjs/useTabBar-35b73d10.js.map +0 -1
- package/cjs/useTestId-4f53d561.js +0 -23
- package/cjs/useTestId-4f53d561.js.map +0 -1
- package/cjs/useTextAreaAltEnter-11424062.js +0 -64
- package/cjs/useTextAreaAltEnter-11424062.js.map +0 -1
- package/cjs/useTheme-2a034a21.js +0 -21
- package/cjs/useTheme-2a034a21.js.map +0 -1
- package/cjs/useThemeInterpolations-a37b37d9.js +0 -71
- package/cjs/useThemeInterpolations-a37b37d9.js.map +0 -1
- package/cjs/useTooltip-34accecc.js +0 -51
- package/cjs/useTooltip-34accecc.js.map +0 -1
- package/cjs/useTooltipControlled-0a95856c.js +0 -376
- package/cjs/useTooltipControlled-0a95856c.js.map +0 -1
- package/cjs/useTooltipOnTruncation-8867b10e.js +0 -29
- package/cjs/useTooltipOnTruncation-8867b10e.js.map +0 -1
- package/cjs/useTranslationBundle-12dd087d.js +0 -31
- package/cjs/useTranslationBundle-12dd087d.js.map +0 -1
- package/cjs/useUser-1295b5cb.js +0 -21
- package/cjs/useUser-1295b5cb.js.map +0 -1
- package/cjs/useVisDragModeControls-2443a4e0.js +0 -89
- package/cjs/useVisDragModeControls-2443a4e0.js.map +0 -1
- package/cjs/useVisEvents-334c2c8d.js +0 -155
- package/cjs/useVisEvents-334c2c8d.js.map +0 -1
- package/cjs/withDirectionIcon-4940a248.js +0 -16
- package/cjs/withDirectionIcon-4940a248.js.map +0 -1
- package/es/BaseButton-41068c85.js +0 -84
- package/es/BaseButton-41068c85.js.map +0 -1
- package/es/BaseCardView-b3d8bae0.js +0 -634
- package/es/BaseCardView-b3d8bae0.js.map +0 -1
- package/es/BaseDiagram-b5b22e53.js +0 -2954
- package/es/BaseDiagram-b5b22e53.js.map +0 -1
- package/es/Button-956f51c7.js +0 -22
- package/es/Button-956f51c7.js.map +0 -1
- package/es/ButtonSetButton-8685c752.js +0 -33
- package/es/ButtonSetButton-8685c752.js.map +0 -1
- package/es/ButtonSetIconButton-c8ed85f9.js +0 -38
- package/es/ButtonSetIconButton-c8ed85f9.js.map +0 -1
- package/es/ButtonSetItem-280755f3.js +0 -65
- package/es/ButtonSetItem-280755f3.js.map +0 -1
- package/es/Center-71a03e65.js +0 -16
- package/es/Center-71a03e65.js.map +0 -1
- package/es/Chart-8c63da28.js +0 -752
- package/es/Chart-8c63da28.js.map +0 -1
- package/es/ColorPicker-ae648c4c.js +0 -23
- package/es/ColorPicker-ae648c4c.js.map +0 -1
- package/es/CompactLabelAssistance-e2fcfcab.js +0 -92
- package/es/CompactLabelAssistance-e2fcfcab.js.map +0 -1
- package/es/DatePicker-7287f0f9.js +0 -599
- package/es/DatePicker-7287f0f9.js.map +0 -1
- package/es/DatePickerHeader-f8cf86bb.js +0 -46
- package/es/DatePickerHeader-f8cf86bb.js.map +0 -1
- package/es/Dialog-83368f52.js +0 -387
- package/es/Dialog-83368f52.js.map +0 -1
- package/es/Dropdown-019aba37.js +0 -318
- package/es/Dropdown-019aba37.js.map +0 -1
- package/es/EmbeddedIconButton-46434710.js +0 -11
- package/es/EmbeddedIconButton-46434710.js.map +0 -1
- package/es/EnvironmentProvider-6a0a8212.js +0 -58
- package/es/EnvironmentProvider-6a0a8212.js.map +0 -1
- package/es/Flex-03129963.js +0 -30
- package/es/Flex-03129963.js.map +0 -1
- package/es/Floating-4a82db94.js +0 -465
- package/es/Floating-4a82db94.js.map +0 -1
- package/es/Grid-9e4b4f19.js +0 -27
- package/es/Grid-9e4b4f19.js.map +0 -1
- package/es/HighlightText-0205faef.js +0 -31
- package/es/HighlightText-0205faef.js.map +0 -1
- package/es/IconSwitchButton-05f1f602.js +0 -42
- package/es/IconSwitchButton-05f1f602.js.map +0 -1
- package/es/IconToggleButton-808818f5.js +0 -41
- package/es/IconToggleButton-808818f5.js.map +0 -1
- package/es/IconUserAssistance-61978211.js +0 -74
- package/es/IconUserAssistance-61978211.js.map +0 -1
- package/es/Layer-535577b5.js +0 -91
- package/es/Layer-535577b5.js.map +0 -1
- package/es/LayerHost-7931b424.js +0 -41
- package/es/LayerHost-7931b424.js.map +0 -1
- package/es/LayerManager-52a26c55.js +0 -34
- package/es/LayerManager-52a26c55.js.map +0 -1
- package/es/Link-8503aab2.js +0 -33
- package/es/Link-8503aab2.js.map +0 -1
- package/es/LiveRegion-cebac18d.js +0 -39
- package/es/LiveRegion-cebac18d.js.map +0 -1
- package/es/MaxLengthLiveRegion-8099fde5.js +0 -26
- package/es/MaxLengthLiveRegion-8099fde5.js.map +0 -1
- package/es/MessageLayer-2a7fdec7.js +0 -58
- package/es/MessageLayer-2a7fdec7.js.map +0 -1
- package/es/MonthView-4b2b483a.js +0 -208
- package/es/MonthView-4b2b483a.js.map +0 -1
- package/es/NavigationListItem-340ab770.js +0 -309
- package/es/NavigationListItem-340ab770.js.map +0 -1
- package/es/OverflowTabBarItem-aa0ce915.js +0 -257
- package/es/OverflowTabBarItem-aa0ce915.js.map +0 -1
- package/es/Popup-992b6c27.js +0 -298
- package/es/Popup-992b6c27.js.map +0 -1
- package/es/ProgressCircle-46084d0b.js +0 -48
- package/es/ProgressCircle-46084d0b.js.map +0 -1
- package/es/ReferenceLineArea-53129f72.js +0 -586
- package/es/ReferenceLineArea-53129f72.js.map +0 -1
- package/es/RevealToggleIcon-2d622d8f.js +0 -26
- package/es/RevealToggleIcon-2d622d8f.js.map +0 -1
- package/es/SectionedContent-30e5bf98.js +0 -65
- package/es/SectionedContent-30e5bf98.js.map +0 -1
- package/es/SelectMenuGroupContext-aa1fe822.js +0 -542
- package/es/SelectMenuGroupContext-aa1fe822.js.map +0 -1
- package/es/SelectMobileFieldInput-345c4d45.js +0 -241
- package/es/SelectMobileFieldInput-345c4d45.js.map +0 -1
- package/es/SelectorAll-de7ba2e1.js +0 -51
- package/es/SelectorAll-de7ba2e1.js.map +0 -1
- package/es/StyledDatePickerButton-78f2f6e8.js +0 -31
- package/es/StyledDatePickerButton-78f2f6e8.js.map +0 -1
- package/es/StyledLabelValueLayout-bb05f474.js +0 -18
- package/es/StyledLabelValueLayout-bb05f474.js.map +0 -1
- package/es/Submenu-cbd77756.js +0 -247
- package/es/Submenu-cbd77756.js.map +0 -1
- package/es/TabBar-67ca442c.js +0 -71
- package/es/TabBar-67ca442c.js.map +0 -1
- package/es/TabBarContextMenu-c3326d67.js +0 -99
- package/es/TabBarContextMenu-c3326d67.js.map +0 -1
- package/es/TabBarLinkItem-e7be54fa.js +0 -13
- package/es/TabBarLinkItem-e7be54fa.js.map +0 -1
- package/es/Table-2f197c6a.js +0 -4112
- package/es/Table-2f197c6a.js.map +0 -1
- package/es/TextArea-93ce78a7.js +0 -225
- package/es/TextArea-93ce78a7.js.map +0 -1
- package/es/ToggleButton-bb69cf10.js +0 -28
- package/es/ToggleButton-bb69cf10.js.map +0 -1
- package/es/ToggleButtonLabel-7f53fbee.js +0 -71
- package/es/ToggleButtonLabel-7f53fbee.js.map +0 -1
- package/es/TruncatingLink-298c6343.js +0 -56
- package/es/TruncatingLink-298c6343.js.map +0 -1
- package/es/View-5bdd9b3c.js +0 -167
- package/es/View-5bdd9b3c.js.map +0 -1
- package/es/VisStatusMessage-e2d629bb.js +0 -29
- package/es/VisStatusMessage-e2d629bb.js.map +0 -1
- package/es/VisTabularDatatip-85b00c1b.js +0 -24
- package/es/VisTabularDatatip-85b00c1b.js.map +0 -1
- package/es/WindowOverlay-7264c44a.js +0 -110
- package/es/WindowOverlay-7264c44a.js.map +0 -1
- package/es/YearsGridView-6c18094a.js +0 -187
- package/es/YearsGridView-6c18094a.js.map +0 -1
- package/es/popupUtils-51366a29.js +0 -29
- package/es/popupUtils-51366a29.js.map +0 -1
- package/es/tooltipUtils-af0abd38.js +0 -110
- package/es/tooltipUtils-af0abd38.js.map +0 -1
- package/es/useChartContextMenu-5de82cd7.js +0 -123
- package/es/useChartContextMenu-5de82cd7.js.map +0 -1
- package/es/useChartDatatip-8dd22b71.js +0 -336
- package/es/useChartDatatip-8dd22b71.js.map +0 -1
- package/es/useChartMarquee-761eb7db.js +0 -304
- package/es/useChartMarquee-761eb7db.js.map +0 -1
- package/es/useColorScheme-c4f6caab.js +0 -19
- package/es/useColorScheme-c4f6caab.js.map +0 -1
- package/es/useContextMenu-730d6c12.js +0 -116
- package/es/useContextMenu-730d6c12.js.map +0 -1
- package/es/useCssVars-bc2527ac.js +0 -58
- package/es/useCssVars-bc2527ac.js.map +0 -1
- package/es/useCurrentKey-5f865bbd.js +0 -83
- package/es/useCurrentKey-5f865bbd.js.map +0 -1
- package/es/useDatatip-4895a07a.js +0 -94
- package/es/useDatatip-4895a07a.js.map +0 -1
- package/es/useDensity-1acb0153.js +0 -19
- package/es/useDensity-1acb0153.js.map +0 -1
- package/es/useDisplayValue-65bbc74e.js +0 -78
- package/es/useDisplayValue-65bbc74e.js.map +0 -1
- package/es/useExpandCollapse-5739cfd2.js +0 -70
- package/es/useExpandCollapse-5739cfd2.js.map +0 -1
- package/es/useFloating-b9d680f7.js +0 -1916
- package/es/useFloating-b9d680f7.js.map +0 -1
- package/es/useHiddenTestMethod-f3f25093.js +0 -28
- package/es/useHiddenTestMethod-f3f25093.js.map +0 -1
- package/es/useKeyboardEvents-9aae7ea3.js +0 -85
- package/es/useKeyboardEvents-9aae7ea3.js.map +0 -1
- package/es/useLegendContextMenu-a678b26f.js +0 -279
- package/es/useLegendContextMenu-a678b26f.js.map +0 -1
- package/es/useMeterDatatip-538a4d53.js +0 -73
- package/es/useMeterDatatip-538a4d53.js.map +0 -1
- package/es/useOutsideClick-b777a43e.js +0 -115
- package/es/useOutsideClick-b777a43e.js.map +0 -1
- package/es/useOutsideMousedown-c45c22c0.js +0 -48
- package/es/useOutsideMousedown-c45c22c0.js.map +0 -1
- package/es/usePopupAnimation-96d2bc83.js +0 -85
- package/es/usePopupAnimation-96d2bc83.js.map +0 -1
- package/es/usePrefixSuffix-f981b65f.js +0 -70
- package/es/usePrefixSuffix-f981b65f.js.map +0 -1
- package/es/useRadioFocusManager-36eb283e.js +0 -108
- package/es/useRadioFocusManager-36eb283e.js.map +0 -1
- package/es/useReorderableItem-857636b7.js +0 -296
- package/es/useReorderableItem-857636b7.js.map +0 -1
- package/es/useRovingTabIndexContainer-5992e107.js +0 -106
- package/es/useRovingTabIndexContainer-5992e107.js.map +0 -1
- package/es/useScale-434ad939.js +0 -19
- package/es/useScale-434ad939.js.map +0 -1
- package/es/useSelectCommon-a3c69d60.js +0 -489
- package/es/useSelectCommon-a3c69d60.js.map +0 -1
- package/es/useSelectDrill-f669e729.js +0 -111
- package/es/useSelectDrill-f669e729.js.map +0 -1
- package/es/useSelection-65134722.js +0 -258
- package/es/useSelection-65134722.js.map +0 -1
- package/es/useSelection-82bec039.js +0 -186
- package/es/useSelection-82bec039.js.map +0 -1
- package/es/useTabBar-c5558e77.js +0 -305
- package/es/useTabBar-c5558e77.js.map +0 -1
- package/es/useTestId-f24ac480.js +0 -21
- package/es/useTestId-f24ac480.js.map +0 -1
- package/es/useTheme-0e7497db.js +0 -19
- package/es/useTheme-0e7497db.js.map +0 -1
- package/es/useThemeInterpolations-e144e8ec.js +0 -68
- package/es/useThemeInterpolations-e144e8ec.js.map +0 -1
- package/es/useTooltip-94af94d4.js +0 -49
- package/es/useTooltip-94af94d4.js.map +0 -1
- package/es/useTooltipControlled-f2cfa454.js +0 -373
- package/es/useTooltipControlled-f2cfa454.js.map +0 -1
- package/es/useTooltipOnTruncation-94282e75.js +0 -27
- package/es/useTooltipOnTruncation-94282e75.js.map +0 -1
- package/es/useTranslationBundle-4822502f.js +0 -29
- package/es/useTranslationBundle-4822502f.js.map +0 -1
- package/es/useUser-06d34d19.js +0 -19
- package/es/useUser-06d34d19.js.map +0 -1
- package/es/useVisDragModeControls-af64848c.js +0 -87
- package/es/useVisDragModeControls-af64848c.js.map +0 -1
- package/es/useVisEvents-256dee29.js +0 -153
- package/es/useVisEvents-256dee29.js.map +0 -1
- package/es/withDirectionIcon-a8d84a3d.js +0 -14
- package/es/withDirectionIcon-a8d84a3d.js.map +0 -1
|
@@ -0,0 +1,2954 @@
|
|
|
1
|
+
/* @oracle/oraclejet-preact: undefined */
|
|
2
|
+
import { jsx, jsxs, Fragment } from 'preact/jsx-runtime';
|
|
3
|
+
import { T as TrackResizeContainer } from './TrackResizeContainer-3d7b18b7.js';
|
|
4
|
+
import { labelStyles, buttonStyle, layerStyles, itemStyles, linkLayerStyle, panZoomStyles, outerStyles, dimensionStyle } from './PRIVATE_BaseDiagram/themes/DiagramStyles.css.js';
|
|
5
|
+
import { u as useResizeObserver } from './useResizeObserver-13641643.js';
|
|
6
|
+
import { useRef, useCallback, useState, useLayoutEffect } from 'preact/hooks';
|
|
7
|
+
import { g as generateAriaLabel } from './accUtils-9d5183c4.js';
|
|
8
|
+
import { c as containsKey, r as removeKey, a as addKey } from './keys-49c92dbb.js';
|
|
9
|
+
import { c as classNames } from './classNames-4e12b00d.js';
|
|
10
|
+
import { u as useTranslationBundle } from './useTranslationBundle-bc6e0896.js';
|
|
11
|
+
import { u as useUser } from './useUser-e543b73c.js';
|
|
12
|
+
import { E as EmbeddedIconButton } from './EmbeddedIconButton-9f0e56b7.js';
|
|
13
|
+
import { S as SvgPlus } from './Plus-b62e474b.js';
|
|
14
|
+
import { S as SvgMinus } from './Minus-6bd44b40.js';
|
|
15
|
+
import { g as getRandomId, c as calculateOffset } from './layoutUtils-ec5be703.js';
|
|
16
|
+
import { u as useVisHover } from './useVisHover-d7a0b2f3.js';
|
|
17
|
+
import { m as mergeProps } from './mergeProps-88ea8306.js';
|
|
18
|
+
import { u as useDatatip } from './useDatatip-ef5c47a7.js';
|
|
19
|
+
import { u as useTextDimensions } from './useTextDimensions-45f79df4.js';
|
|
20
|
+
import { i as isTouch } from './clientUtils-cccff45f.js';
|
|
21
|
+
import { u as useVisDragModeControls } from './useVisDragModeControls-6865056f.js';
|
|
22
|
+
import { u as useSelection } from './useSelection-10ed8060.js';
|
|
23
|
+
import { u as useVisTouchResponse } from './useVisTouchResponse-a59ab166.js';
|
|
24
|
+
import { l } from './stringUtils-0fe25200.js';
|
|
25
|
+
import { u as useContextMenu } from './useContextMenu-8a1230a3.js';
|
|
26
|
+
import './SelectMenuGroupContext-130a850c.js';
|
|
27
|
+
import 'preact';
|
|
28
|
+
import './logger-c92f309c.js';
|
|
29
|
+
import './LayerHost-3cf255a6.js';
|
|
30
|
+
import 'preact/compat';
|
|
31
|
+
import './TooltipContentStyles.styles.css';
|
|
32
|
+
import './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentBaseTheme.styles.css';
|
|
33
|
+
import './hooks/UNSAFE_useTooltip/themes/redwood/TooltipContentVariants.css.js';
|
|
34
|
+
import './tooltipUtils-90fb656f.js';
|
|
35
|
+
import './IconStyle.styles.css';
|
|
36
|
+
import './UNSAFE_Menu/themes/MenuItemStyles.css.js';
|
|
37
|
+
import './UNSAFE_Separator/themes/SeparatorStyles.css.js';
|
|
38
|
+
import './MenuSeparatorStyles.styles.css';
|
|
39
|
+
import './UNSAFE_Menu/themes/redwood/MenuSeparatorBaseTheme.styles.css';
|
|
40
|
+
import './UNSAFE_Menu/themes/redwood/MenuSeparatorVariants.css.js';
|
|
41
|
+
import './MenuStyles.styles.css';
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Constructs the json object to be passed into the layout function
|
|
45
|
+
*/
|
|
46
|
+
function constructLayoutJSON(nodeItems, linkItems, promotedLinks, dimensions, width, height, zoom, nodeIdToParentMap, rootRef, getTextDimensions) {
|
|
47
|
+
const labelDims = new Map();
|
|
48
|
+
const nodeValues = Array.from(nodeItems.values());
|
|
49
|
+
const linkValues = Array.from(linkItems.values());
|
|
50
|
+
if (getTextDimensions) {
|
|
51
|
+
getLabelProps(nodeValues, linkValues, labelDims, getTextDimensions);
|
|
52
|
+
}
|
|
53
|
+
const linkKeys = Array.from(linkItems.keys());
|
|
54
|
+
for (const id of linkKeys) {
|
|
55
|
+
const item = linkItems.get(id);
|
|
56
|
+
if (item && getTextDimensions && item.label) {
|
|
57
|
+
const label = item.label;
|
|
58
|
+
const fontProps = _getFontProps(item.labelStyle);
|
|
59
|
+
labelDims.set(id, getTextDimensions(label, fontProps));
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
const getLabelDimensions = function (data) {
|
|
63
|
+
return labelDims.get(data.id);
|
|
64
|
+
};
|
|
65
|
+
const getNodeDimensions = function (data) {
|
|
66
|
+
return dimensions.get(data.id);
|
|
67
|
+
};
|
|
68
|
+
const getRelativeNodeBounds = function (id, containerId) {
|
|
69
|
+
const absPos = getAbsoluteNodePosition(id, containerId, rootRef);
|
|
70
|
+
if (absPos) {
|
|
71
|
+
return {
|
|
72
|
+
x: absPos.x / zoom,
|
|
73
|
+
y: absPos.y / zoom,
|
|
74
|
+
width: absPos.width / zoom,
|
|
75
|
+
height: absPos.height / zoom
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
else {
|
|
79
|
+
return undefined;
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
const getContainerId = function (startNode, endNode) {
|
|
83
|
+
return getCommonAncestorId(startNode, endNode, nodeIdToParentMap);
|
|
84
|
+
};
|
|
85
|
+
const getPromotedLinks = function () {
|
|
86
|
+
return promotedLinks;
|
|
87
|
+
};
|
|
88
|
+
return {
|
|
89
|
+
layoutJSON: {
|
|
90
|
+
getNodeDimensions: getNodeDimensions,
|
|
91
|
+
getLabelDimensions: getLabelDimensions,
|
|
92
|
+
getContainerId,
|
|
93
|
+
getRelativeNodeBounds,
|
|
94
|
+
getPromotedLinks,
|
|
95
|
+
componentSize: {
|
|
96
|
+
width: width,
|
|
97
|
+
height: height
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
labelDims: labelDims
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
function normalizeBounds(bounds, zoom) {
|
|
104
|
+
return {
|
|
105
|
+
x: bounds.x / zoom,
|
|
106
|
+
y: bounds.y / zoom,
|
|
107
|
+
width: bounds.width / zoom,
|
|
108
|
+
height: bounds.height / zoom
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
function getAbsoluteLinkBounds(itemId, referenceId, bounds, zoom, rootRef, isPromoted) {
|
|
112
|
+
if (rootRef && rootRef.current) {
|
|
113
|
+
let linkElement;
|
|
114
|
+
if (isPromoted) {
|
|
115
|
+
const id = `${itemId.startNode}_${itemId.endNode}`;
|
|
116
|
+
linkElement = rootRef.current.querySelector(`[data-oj-private-promoted-link=${id}]`);
|
|
117
|
+
}
|
|
118
|
+
else {
|
|
119
|
+
linkElement = rootRef.current.querySelector(`[data-oj-private-link=${itemId}]`);
|
|
120
|
+
}
|
|
121
|
+
let nodeContainer;
|
|
122
|
+
if (referenceId) {
|
|
123
|
+
nodeContainer = rootRef.current.querySelector(`[data-oj-private-node=${referenceId}]`);
|
|
124
|
+
}
|
|
125
|
+
const dims = bounds.get(itemId);
|
|
126
|
+
if (linkElement && nodeContainer && dims) {
|
|
127
|
+
const linkBoundingRect = normalizeBounds(linkElement.getBoundingClientRect(), zoom);
|
|
128
|
+
const diagramBoundingRect = normalizeBounds(nodeContainer.getBoundingClientRect(), zoom);
|
|
129
|
+
return {
|
|
130
|
+
x: linkBoundingRect.x - diagramBoundingRect.x,
|
|
131
|
+
y: linkBoundingRect.y - diagramBoundingRect.y,
|
|
132
|
+
width: dims.width,
|
|
133
|
+
height: dims.height
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
return null;
|
|
138
|
+
}
|
|
139
|
+
function getBounds(nodes, links, promotedLinks, nodeBounds, linkDimensions, promotedLinkDimensions, zoom, rootRef) {
|
|
140
|
+
let minX = Infinity;
|
|
141
|
+
let minY = Infinity;
|
|
142
|
+
let maxX = -Infinity;
|
|
143
|
+
let maxY = -Infinity;
|
|
144
|
+
let id;
|
|
145
|
+
let topId;
|
|
146
|
+
let leftId;
|
|
147
|
+
for (let i = 0; i < nodes.length; i++) {
|
|
148
|
+
id = nodes[i].id;
|
|
149
|
+
const bounds = nodeBounds.get(id);
|
|
150
|
+
if (bounds) {
|
|
151
|
+
if (minX > bounds.x) {
|
|
152
|
+
minX = bounds.x;
|
|
153
|
+
leftId = id;
|
|
154
|
+
}
|
|
155
|
+
if (minY > bounds.y) {
|
|
156
|
+
minY = bounds.y;
|
|
157
|
+
topId = id;
|
|
158
|
+
}
|
|
159
|
+
if (maxX < bounds.x + bounds.width) {
|
|
160
|
+
maxX = bounds.x + bounds.width;
|
|
161
|
+
}
|
|
162
|
+
if (maxY < bounds.y + bounds.height) {
|
|
163
|
+
maxY = bounds.y + bounds.height;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
const nodeMinX = minX;
|
|
168
|
+
const nodeMinY = minY;
|
|
169
|
+
let linkMinX = 0;
|
|
170
|
+
let linkMinY = 0;
|
|
171
|
+
let linkMaxX = maxX - minX;
|
|
172
|
+
let linkMaxY = maxY - minY;
|
|
173
|
+
for (let i = 0; i < links.length; i++) {
|
|
174
|
+
id = links[i].id;
|
|
175
|
+
//Top and left bounds are relative to the current most top and left nodes
|
|
176
|
+
const topBounds = getAbsoluteLinkBounds(id, topId, linkDimensions, zoom, rootRef);
|
|
177
|
+
const leftBounds = getAbsoluteLinkBounds(id, leftId, linkDimensions, zoom, rootRef);
|
|
178
|
+
if (leftBounds) {
|
|
179
|
+
if (leftBounds.x < linkMinX) {
|
|
180
|
+
linkMinX = leftBounds.x;
|
|
181
|
+
}
|
|
182
|
+
if (linkMaxX < leftBounds.x + leftBounds.width) {
|
|
183
|
+
linkMaxX = leftBounds.x + leftBounds.width;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
if (topBounds) {
|
|
187
|
+
if (topBounds.y < linkMinY) {
|
|
188
|
+
linkMinY = topBounds.y;
|
|
189
|
+
}
|
|
190
|
+
if (linkMaxY < topBounds.y + topBounds.height) {
|
|
191
|
+
linkMaxY = topBounds.y + topBounds.height;
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
for (let i = 0; i < promotedLinks.length; i++) {
|
|
196
|
+
id = promotedLinks[i];
|
|
197
|
+
//Top and left bounds are relative to the current most top and left nodes
|
|
198
|
+
const topBounds = getAbsoluteLinkBounds(id, topId, promotedLinkDimensions, zoom, rootRef, true);
|
|
199
|
+
const leftBounds = getAbsoluteLinkBounds(id, leftId, promotedLinkDimensions, zoom, rootRef, true);
|
|
200
|
+
if (leftBounds) {
|
|
201
|
+
if (leftBounds.x < linkMinX) {
|
|
202
|
+
linkMinX = leftBounds.x;
|
|
203
|
+
}
|
|
204
|
+
if (linkMaxX < leftBounds.x + leftBounds.width) {
|
|
205
|
+
linkMaxX = leftBounds.x + leftBounds.width;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
if (topBounds) {
|
|
209
|
+
if (topBounds.y < linkMinY) {
|
|
210
|
+
linkMinY = topBounds.y;
|
|
211
|
+
}
|
|
212
|
+
if (linkMaxY < topBounds.y + topBounds.height) {
|
|
213
|
+
linkMaxY = topBounds.y + topBounds.height;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
return {
|
|
218
|
+
minX: nodeMinX,
|
|
219
|
+
minY: nodeMinY,
|
|
220
|
+
contentWidth: maxX - minX,
|
|
221
|
+
contentHeight: maxY - minY,
|
|
222
|
+
bounds: { x: linkMinX, y: linkMinY, width: linkMaxX - linkMinX, height: linkMaxY - linkMinY }
|
|
223
|
+
};
|
|
224
|
+
}
|
|
225
|
+
function getAbsoluteNodePosition(nodeId, containerId, rootRef) {
|
|
226
|
+
if (rootRef && rootRef.current) {
|
|
227
|
+
const nodeElement = rootRef.current.querySelector(`[data-oj-private-node=${nodeId}]`);
|
|
228
|
+
let nodeContainer;
|
|
229
|
+
if (containerId) {
|
|
230
|
+
nodeContainer = rootRef.current.querySelector(`[data-oj-private-child=${containerId}]`);
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
nodeContainer = rootRef.current.querySelector('[data-oj-private-node-container]');
|
|
234
|
+
}
|
|
235
|
+
if (nodeElement && nodeContainer) {
|
|
236
|
+
const nodeBoundingRect = nodeElement.getBoundingClientRect();
|
|
237
|
+
const nodeContainerRect = nodeContainer.getBoundingClientRect();
|
|
238
|
+
return {
|
|
239
|
+
x: nodeBoundingRect.x - nodeContainerRect.x,
|
|
240
|
+
y: nodeBoundingRect.y - nodeContainerRect.y,
|
|
241
|
+
width: nodeBoundingRect.width,
|
|
242
|
+
height: nodeBoundingRect.height
|
|
243
|
+
};
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
return null;
|
|
247
|
+
}
|
|
248
|
+
function getLabelProps(nodeItems, linkItems, labelDims, getTextDimensions) {
|
|
249
|
+
nodeItems.forEach((value) => {
|
|
250
|
+
if (value.nodes) {
|
|
251
|
+
getNodeLabelProps(value.nodes, labelDims, getTextDimensions);
|
|
252
|
+
}
|
|
253
|
+
if (value.label) {
|
|
254
|
+
const label = value.label;
|
|
255
|
+
const fontProps = _getFontProps(value.labelStyle);
|
|
256
|
+
labelDims.set(value.id, getTextDimensions(label, fontProps));
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
linkItems.forEach((value) => {
|
|
260
|
+
if (value.label) {
|
|
261
|
+
const label = value.label;
|
|
262
|
+
const fontProps = _getFontProps(value.labelStyle);
|
|
263
|
+
labelDims.set(value.id, getTextDimensions(label, fontProps));
|
|
264
|
+
}
|
|
265
|
+
});
|
|
266
|
+
}
|
|
267
|
+
function getNodeLabelProps(nodeItems, labelDims, getTextDimensions) {
|
|
268
|
+
nodeItems.forEach((value) => {
|
|
269
|
+
if (value.nodes) {
|
|
270
|
+
getNodeLabelProps(value.nodes, labelDims, getTextDimensions);
|
|
271
|
+
}
|
|
272
|
+
if (value.label) {
|
|
273
|
+
const label = value.label;
|
|
274
|
+
const fontProps = _getFontProps(value.labelStyle);
|
|
275
|
+
labelDims.set(value.id, getTextDimensions(label, fontProps));
|
|
276
|
+
}
|
|
277
|
+
});
|
|
278
|
+
}
|
|
279
|
+
/**
|
|
280
|
+
* Deconstructs the output of the layout function
|
|
281
|
+
*/
|
|
282
|
+
function deconstructLayoutJSON(layoutJSON, nodeData, linkData) {
|
|
283
|
+
const positions = new Map();
|
|
284
|
+
const nodeLabelPos = new Map();
|
|
285
|
+
const linkLabelPos = new Map();
|
|
286
|
+
findPoints(layoutJSON, nodeData, positions, nodeLabelPos);
|
|
287
|
+
const links = layoutJSON.links;
|
|
288
|
+
let link;
|
|
289
|
+
if (links) {
|
|
290
|
+
for (let i = 0; i < linkData.length; i++) {
|
|
291
|
+
link = links[linkData[i].id];
|
|
292
|
+
if (link && link.label)
|
|
293
|
+
linkLabelPos.set(linkData[i].id, link.label);
|
|
294
|
+
}
|
|
295
|
+
}
|
|
296
|
+
return {
|
|
297
|
+
nodePoints: positions,
|
|
298
|
+
nodeLabelPos: nodeLabelPos,
|
|
299
|
+
linkLabelPos: linkLabelPos
|
|
300
|
+
};
|
|
301
|
+
}
|
|
302
|
+
function findPoints(output, nodeData, positions, nodeLabelPos) {
|
|
303
|
+
const nodes = output.nodes;
|
|
304
|
+
let node;
|
|
305
|
+
if (nodes) {
|
|
306
|
+
for (let i = 0; i < nodeData.length; i++) {
|
|
307
|
+
const data = nodeData[i];
|
|
308
|
+
const id = data.id;
|
|
309
|
+
if (data.nodes) {
|
|
310
|
+
findPoints(output, data.nodes, positions, nodeLabelPos);
|
|
311
|
+
}
|
|
312
|
+
node = nodes[id];
|
|
313
|
+
if (node) {
|
|
314
|
+
positions.set(id, node.position);
|
|
315
|
+
if (node.label) {
|
|
316
|
+
nodeLabelPos.set(id, node.label);
|
|
317
|
+
}
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
}
|
|
322
|
+
/**
|
|
323
|
+
* Merges the node points into the dimensions
|
|
324
|
+
*/
|
|
325
|
+
function mergeDimensions(dimensions, nodePoints, rootRef) {
|
|
326
|
+
const nodeBounds = new Map();
|
|
327
|
+
const nodeAbsBounds = new Map();
|
|
328
|
+
dimensions.forEach((value, key) => {
|
|
329
|
+
const point = nodePoints.get(key);
|
|
330
|
+
const absPoint = getAbsoluteNodePosition(key, undefined, rootRef);
|
|
331
|
+
if (point) {
|
|
332
|
+
nodeBounds.set(key, { x: point.x, y: point.y, width: value.width, height: value.height });
|
|
333
|
+
}
|
|
334
|
+
if (absPoint) {
|
|
335
|
+
nodeAbsBounds.set(key, { x: absPoint.x, y: absPoint.y, width: value.width, height: value.height });
|
|
336
|
+
}
|
|
337
|
+
});
|
|
338
|
+
return { nodeBounds, nodeAbsBounds };
|
|
339
|
+
}
|
|
340
|
+
/**
|
|
341
|
+
* Deep equality check for whether two arrays of bounds are the same
|
|
342
|
+
*/
|
|
343
|
+
function isEqualBounds(bounds1, bounds2) {
|
|
344
|
+
if (bounds1.size !== bounds2.size)
|
|
345
|
+
return false;
|
|
346
|
+
let equal = true;
|
|
347
|
+
bounds1.forEach((value, key) => {
|
|
348
|
+
const b2Value = bounds2.get(key);
|
|
349
|
+
if (!b2Value)
|
|
350
|
+
equal = false;
|
|
351
|
+
else if (Math.abs(value.x - b2Value.x) > 0.5 ||
|
|
352
|
+
Math.abs(value.y - b2Value.y) > 0.5 ||
|
|
353
|
+
Math.abs(value.width - b2Value.width) > 0.5 ||
|
|
354
|
+
Math.abs(value.height - b2Value.height) > 0.5)
|
|
355
|
+
equal = false;
|
|
356
|
+
});
|
|
357
|
+
return equal;
|
|
358
|
+
}
|
|
359
|
+
/**
|
|
360
|
+
* Returns the text for the diagram datatip.
|
|
361
|
+
*/
|
|
362
|
+
function getDatatipContent(nodesMap, linksMap, focusedItem, hoveredItem, datatip) {
|
|
363
|
+
let itemInfo;
|
|
364
|
+
const isPointerActive = hoveredItem?.isCurrent;
|
|
365
|
+
if (isPointerActive && hoveredItem.id != null) {
|
|
366
|
+
itemInfo = hoveredItem;
|
|
367
|
+
}
|
|
368
|
+
if (focusedItem && focusedItem.isCurrent) {
|
|
369
|
+
itemInfo = focusedItem;
|
|
370
|
+
}
|
|
371
|
+
if (itemInfo && datatip) {
|
|
372
|
+
let context;
|
|
373
|
+
switch (itemInfo.type) {
|
|
374
|
+
case 'node': {
|
|
375
|
+
context = { data: nodesMap.get(itemInfo.id), type: 'node' };
|
|
376
|
+
break;
|
|
377
|
+
}
|
|
378
|
+
case 'link': {
|
|
379
|
+
context = { data: linksMap.get(itemInfo.id), type: 'link' };
|
|
380
|
+
break;
|
|
381
|
+
}
|
|
382
|
+
default: {
|
|
383
|
+
context = { id: itemInfo.id, type: 'promotedLink' };
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
return datatip(context);
|
|
387
|
+
}
|
|
388
|
+
if (itemInfo) {
|
|
389
|
+
const text = (itemInfo.type === 'node' ? nodesMap.get(itemInfo.id) : linksMap.get(itemInfo.id))?.accessibleLabel;
|
|
390
|
+
return {
|
|
391
|
+
content: text
|
|
392
|
+
};
|
|
393
|
+
}
|
|
394
|
+
return;
|
|
395
|
+
}
|
|
396
|
+
/**
|
|
397
|
+
* Creates a map with key id and value node or link data
|
|
398
|
+
*/
|
|
399
|
+
function createLinksMap(items) {
|
|
400
|
+
const itemIdToDataMap = new Map();
|
|
401
|
+
const itemIdToIndexMap = new Map();
|
|
402
|
+
const itemIndexToIdMap = new Map();
|
|
403
|
+
const itemIdToParentMap = new Map();
|
|
404
|
+
for (let i = 0; i < items.length; i++) {
|
|
405
|
+
const item = items[i];
|
|
406
|
+
itemIdToDataMap.set(item.id, item);
|
|
407
|
+
itemIdToIndexMap.set(item.id, i);
|
|
408
|
+
itemIndexToIdMap.set(i, item.id);
|
|
409
|
+
}
|
|
410
|
+
return {
|
|
411
|
+
itemIdToDataMap,
|
|
412
|
+
itemIdToIndexMap,
|
|
413
|
+
itemIndexToIdMap,
|
|
414
|
+
itemIdToParentMap
|
|
415
|
+
};
|
|
416
|
+
}
|
|
417
|
+
/**
|
|
418
|
+
* Creates a map with key id and value node or link data
|
|
419
|
+
*/
|
|
420
|
+
function createPromotedLinksMap(items) {
|
|
421
|
+
const promotedLinkMap = new Map();
|
|
422
|
+
for (let i = 0; i < items.length; i++) {
|
|
423
|
+
const item = items[i];
|
|
424
|
+
promotedLinkMap.set(`${item.startNode}_${item.endNode}`, item);
|
|
425
|
+
}
|
|
426
|
+
return promotedLinkMap;
|
|
427
|
+
}
|
|
428
|
+
/**
|
|
429
|
+
* Creates a map with key id and value node or link data
|
|
430
|
+
*/
|
|
431
|
+
function createNodesMap(items, expanded) {
|
|
432
|
+
const itemIdToDataMap = new Map();
|
|
433
|
+
const itemIdToIndexMap = new Map();
|
|
434
|
+
const itemIndexToIdMap = new Map();
|
|
435
|
+
const itemIdToParentMap = new Map();
|
|
436
|
+
const allContainerNodes = [];
|
|
437
|
+
const allVisibleNodes = [];
|
|
438
|
+
for (let i = 0; i < items.length; i++) {
|
|
439
|
+
const item = items[i];
|
|
440
|
+
const index = String(i);
|
|
441
|
+
itemIdToDataMap.set(item.id, item);
|
|
442
|
+
itemIdToIndexMap.set(item.id, index);
|
|
443
|
+
itemIndexToIdMap.set(index, item.id);
|
|
444
|
+
allVisibleNodes.push(item.id);
|
|
445
|
+
if (item.nodes) {
|
|
446
|
+
allContainerNodes.push(item);
|
|
447
|
+
if (containsKey(expanded, item.id)) {
|
|
448
|
+
_createItemMap(item.nodes, itemIdToDataMap, itemIdToIndexMap, itemIndexToIdMap, itemIdToParentMap, allContainerNodes, expanded, allVisibleNodes, item.id, String(i));
|
|
449
|
+
}
|
|
450
|
+
}
|
|
451
|
+
}
|
|
452
|
+
return {
|
|
453
|
+
itemIdToDataMap,
|
|
454
|
+
itemIdToIndexMap,
|
|
455
|
+
itemIndexToIdMap,
|
|
456
|
+
itemIdToParentMap,
|
|
457
|
+
allContainerNodes,
|
|
458
|
+
allVisibleNodes
|
|
459
|
+
};
|
|
460
|
+
}
|
|
461
|
+
function _createItemMap(items, itemIdToDataMap, itemIdToIndexMap, itemIndexToIdMap, itemIdToParentMap, allContainerNodes, expanded, allVisibleNodes, parentId, parentIndex) {
|
|
462
|
+
for (let i = 0; i < items.length; i++) {
|
|
463
|
+
const item = items[i];
|
|
464
|
+
const index = `${parentIndex}_${i}`;
|
|
465
|
+
itemIdToDataMap.set(item.id, item);
|
|
466
|
+
itemIdToIndexMap.set(item.id, index);
|
|
467
|
+
itemIndexToIdMap.set(index, item.id);
|
|
468
|
+
itemIdToParentMap.set(item.id, parentId);
|
|
469
|
+
allVisibleNodes.push(item.id);
|
|
470
|
+
if (item.nodes) {
|
|
471
|
+
allContainerNodes.push(item);
|
|
472
|
+
if (containsKey(expanded, item.id)) {
|
|
473
|
+
_createItemMap(item.nodes, itemIdToDataMap, itemIdToIndexMap, itemIndexToIdMap, itemIdToParentMap, allContainerNodes, expanded, allVisibleNodes, item.id, index);
|
|
474
|
+
}
|
|
475
|
+
}
|
|
476
|
+
}
|
|
477
|
+
}
|
|
478
|
+
/**
|
|
479
|
+
* Filter out links with no start or end nodes
|
|
480
|
+
*/
|
|
481
|
+
function filterLinksWithNoStartOrEndNodes(links, nodesMap) {
|
|
482
|
+
const newLinks = [];
|
|
483
|
+
for (let i = 0; i < links.length; i++) {
|
|
484
|
+
const link = links[i];
|
|
485
|
+
if (nodesMap.get(link.startNode) && nodesMap.get(link.endNode)) {
|
|
486
|
+
newLinks.push(link);
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
return newLinks;
|
|
490
|
+
}
|
|
491
|
+
/**
|
|
492
|
+
* Pulls out the dimensions from an array of bounds
|
|
493
|
+
*/
|
|
494
|
+
function getDimensionsFromBounds(bounds) {
|
|
495
|
+
const dims = new Map();
|
|
496
|
+
bounds.forEach((value, key) => {
|
|
497
|
+
dims.set(key, { width: value.width, height: value.height });
|
|
498
|
+
});
|
|
499
|
+
return dims;
|
|
500
|
+
}
|
|
501
|
+
/**
|
|
502
|
+
* Returns the center position of the node or link
|
|
503
|
+
* For links, draws a straight line between the centers of the start/end node
|
|
504
|
+
* and returns the center of that line
|
|
505
|
+
*/
|
|
506
|
+
function getFocusedItemBounds(focusedItemInfo, bounds, links, linkIdToIndexMap, rootRef) {
|
|
507
|
+
if (focusedItemInfo.type === 'node') {
|
|
508
|
+
// Return the first element if cannot find the Node index
|
|
509
|
+
const position = getAbsoluteNodePosition(focusedItemInfo.id, undefined, rootRef);
|
|
510
|
+
const nodeBounds = bounds.get(focusedItemInfo.id) || bounds.values().next().value;
|
|
511
|
+
return {
|
|
512
|
+
x: position ? position.x : nodeBounds.x,
|
|
513
|
+
y: position ? position.y : nodeBounds.y,
|
|
514
|
+
width: nodeBounds.width,
|
|
515
|
+
height: nodeBounds.height
|
|
516
|
+
};
|
|
517
|
+
}
|
|
518
|
+
else {
|
|
519
|
+
// Center of a straight line between start/end node centers
|
|
520
|
+
const link = focusedItemInfo.type === 'promotedLink'
|
|
521
|
+
? focusedItemInfo.id
|
|
522
|
+
: links[linkIdToIndexMap.get(focusedItemInfo.id) || 0];
|
|
523
|
+
const startNB = bounds.get(link.startNode) || bounds.values().next().value;
|
|
524
|
+
const endNB = bounds.get(link.endNode) || bounds.values().next().value;
|
|
525
|
+
const startNCenter = {
|
|
526
|
+
x: startNB.x + startNB.width / 2,
|
|
527
|
+
y: startNB.y + startNB.height / 2
|
|
528
|
+
};
|
|
529
|
+
const endNCenter = { x: endNB.x + endNB.width / 2, y: endNB.y + endNB.height / 2 };
|
|
530
|
+
const minX = Math.min(startNCenter.x, endNCenter.x);
|
|
531
|
+
const minY = Math.min(startNCenter.y, endNCenter.y);
|
|
532
|
+
return {
|
|
533
|
+
x: minX,
|
|
534
|
+
y: minY,
|
|
535
|
+
width: Math.abs(startNCenter.x - endNCenter.x),
|
|
536
|
+
height: Math.abs(startNCenter.y - endNCenter.y)
|
|
537
|
+
};
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
/**
|
|
541
|
+
* Returns the bounds of the diagram content
|
|
542
|
+
*/
|
|
543
|
+
function getContentBounds(nodeBounds, labelBounds) {
|
|
544
|
+
if (nodeBounds.size === 0)
|
|
545
|
+
return { x: 0, width: Infinity, y: 0, height: Infinity };
|
|
546
|
+
let minX = Infinity;
|
|
547
|
+
let minY = Infinity;
|
|
548
|
+
let maxX = -Infinity;
|
|
549
|
+
let maxY = -Infinity;
|
|
550
|
+
let dims;
|
|
551
|
+
nodeBounds.forEach((value) => {
|
|
552
|
+
dims = value;
|
|
553
|
+
minX = dims.x < minX ? dims.x : minX;
|
|
554
|
+
minY = dims.y < minY ? dims.y : minY;
|
|
555
|
+
maxX = dims.x + dims.width > maxX ? dims.x + dims.width : maxX;
|
|
556
|
+
maxY = dims.y + dims.height > maxY ? dims.y + dims.height : maxY;
|
|
557
|
+
});
|
|
558
|
+
if (labelBounds) {
|
|
559
|
+
minX = labelBounds.x < minX ? labelBounds.x : minX;
|
|
560
|
+
minY = labelBounds.y < minY ? labelBounds.y : minY;
|
|
561
|
+
maxX = labelBounds.x + labelBounds.width > maxX ? labelBounds.x + labelBounds.width : maxX;
|
|
562
|
+
maxY = labelBounds.y + labelBounds.height > maxY ? labelBounds.y + labelBounds.height : maxY;
|
|
563
|
+
}
|
|
564
|
+
return { x: minX, width: maxX - minX, y: minY, height: maxY - minY };
|
|
565
|
+
}
|
|
566
|
+
/**
|
|
567
|
+
* Returns the label bounds
|
|
568
|
+
*/
|
|
569
|
+
function getAllLabelBounds(labelDims, nodeLabelPos = new Map(), linkLabelPos = new Map(), isRTL, rootRef) {
|
|
570
|
+
if (nodeLabelPos.size === 0)
|
|
571
|
+
return undefined;
|
|
572
|
+
let minX = Infinity;
|
|
573
|
+
let minY = Infinity;
|
|
574
|
+
let maxX = -Infinity;
|
|
575
|
+
let maxY = -Infinity;
|
|
576
|
+
let dims;
|
|
577
|
+
let nodeBound;
|
|
578
|
+
nodeLabelPos.forEach((value, key) => {
|
|
579
|
+
dims = getLabelBounds(value, labelDims.get(key), isRTL);
|
|
580
|
+
nodeBound = getAbsoluteNodePosition(key, null, rootRef);
|
|
581
|
+
if (nodeBound) {
|
|
582
|
+
minX = dims.x + nodeBound.x < minX ? dims.x + nodeBound.x : minX;
|
|
583
|
+
minY = dims.y + nodeBound.y < minY ? dims.y + nodeBound.y : minY;
|
|
584
|
+
maxX = dims.x + dims.width + nodeBound.x > maxX ? dims.x + dims.width + nodeBound.x : maxX;
|
|
585
|
+
maxY = dims.y + dims.height + nodeBound.y > maxY ? dims.y + dims.height + nodeBound.y : maxY;
|
|
586
|
+
}
|
|
587
|
+
});
|
|
588
|
+
linkLabelPos.forEach((value, key) => {
|
|
589
|
+
dims = getLabelBounds(value, labelDims.get(key), isRTL);
|
|
590
|
+
if (dims) {
|
|
591
|
+
minX = dims.x < minX ? dims.x : minX;
|
|
592
|
+
minY = dims.y < minY ? dims.y : minY;
|
|
593
|
+
maxX = dims.x + dims.width > maxX ? dims.x + dims.width : maxX;
|
|
594
|
+
maxY = dims.y + dims.height > maxY ? dims.y + dims.height : maxY;
|
|
595
|
+
}
|
|
596
|
+
});
|
|
597
|
+
return { x: minX, width: maxX - minX, y: minY, height: maxY - minY };
|
|
598
|
+
}
|
|
599
|
+
function getLabelBounds(label, dims, isRTL) {
|
|
600
|
+
const labelPos = getLabelPosition(dims, label, isRTL);
|
|
601
|
+
const isRotating = label.rotationAngle;
|
|
602
|
+
if (!isRotating) {
|
|
603
|
+
return { x: labelPos.x, y: labelPos.y, width: dims.width, height: dims.height };
|
|
604
|
+
}
|
|
605
|
+
else {
|
|
606
|
+
// Find the 4 corners of the label bounds relative to the rotation point
|
|
607
|
+
const rotationPoint = label.rotationPoint
|
|
608
|
+
? label.rotationPoint
|
|
609
|
+
: { x: dims.width / 2, y: dims.height / 2 };
|
|
610
|
+
const angle = label.rotationAngle;
|
|
611
|
+
const topLeft = getCoordsRelToRotPoint({ x: 0, y: 0 }, rotationPoint);
|
|
612
|
+
const topRight = getCoordsRelToRotPoint({ x: dims.width, y: 0 }, rotationPoint);
|
|
613
|
+
const bottomLeft = getCoordsRelToRotPoint({ x: 0, y: dims.height }, rotationPoint);
|
|
614
|
+
const bottomRight = getCoordsRelToRotPoint({ x: dims.width, y: dims.height }, rotationPoint);
|
|
615
|
+
const rotTopLeft = rotatePoint(topLeft, angle);
|
|
616
|
+
const rotBotLeft = rotatePoint(bottomLeft, angle);
|
|
617
|
+
const rotTopRight = rotatePoint(topRight, angle);
|
|
618
|
+
const rotBotRight = rotatePoint(bottomRight, angle);
|
|
619
|
+
const points = [rotTopLeft, rotBotLeft, rotTopRight, rotBotRight].map((pos) => {
|
|
620
|
+
return {
|
|
621
|
+
x: pos.x + labelPos.x + rotationPoint.x,
|
|
622
|
+
y: pos.y + labelPos.y + rotationPoint.y
|
|
623
|
+
};
|
|
624
|
+
});
|
|
625
|
+
return getBoundsFromPoints(points);
|
|
626
|
+
}
|
|
627
|
+
}
|
|
628
|
+
function getCoordsRelToRotPoint(labelPoint, rotPoint) {
|
|
629
|
+
return { x: labelPoint.x - rotPoint.x, y: labelPoint.y - rotPoint.y };
|
|
630
|
+
}
|
|
631
|
+
function rotatePoint(pos, angle) {
|
|
632
|
+
return {
|
|
633
|
+
x: pos.x * Math.cos(angle) - pos.y * Math.sin(angle),
|
|
634
|
+
y: pos.x * Math.sin(angle) + pos.y * Math.cos(angle)
|
|
635
|
+
};
|
|
636
|
+
}
|
|
637
|
+
function getBoundsFromPoints(points) {
|
|
638
|
+
let minX = points[0].x;
|
|
639
|
+
let minY = points[0].y;
|
|
640
|
+
let maxX = points[0].x;
|
|
641
|
+
let maxY = points[0].y;
|
|
642
|
+
for (let i = 1; i < points.length; i++) {
|
|
643
|
+
const point = points[i];
|
|
644
|
+
if (point.x < minX)
|
|
645
|
+
minX = point.x;
|
|
646
|
+
else if (point.x > maxX)
|
|
647
|
+
maxX = point.x;
|
|
648
|
+
if (point.y < minY)
|
|
649
|
+
minY = point.y;
|
|
650
|
+
else if (point.y > maxY)
|
|
651
|
+
maxY = point.y;
|
|
652
|
+
}
|
|
653
|
+
return {
|
|
654
|
+
x: minX,
|
|
655
|
+
y: minY,
|
|
656
|
+
width: maxX - minX,
|
|
657
|
+
height: maxY - minY
|
|
658
|
+
};
|
|
659
|
+
}
|
|
660
|
+
/**
|
|
661
|
+
* Returns the position of the label
|
|
662
|
+
* @param dimensions
|
|
663
|
+
* @param positionProps
|
|
664
|
+
* @returns position of the label
|
|
665
|
+
*/
|
|
666
|
+
function getLabelPosition(dimensions, positionProps, isRTL) {
|
|
667
|
+
const position = positionProps.position;
|
|
668
|
+
const hAlign = positionProps.hAlign ? positionProps.hAlign : isRTL ? 'right' : 'left';
|
|
669
|
+
const vAlign = positionProps.vAlign;
|
|
670
|
+
let x, y;
|
|
671
|
+
if (hAlign === 'center') {
|
|
672
|
+
x = position.x - dimensions.width / 2;
|
|
673
|
+
}
|
|
674
|
+
else if (hAlign === 'right') {
|
|
675
|
+
x = position.x - dimensions.width;
|
|
676
|
+
}
|
|
677
|
+
else {
|
|
678
|
+
x = position.x;
|
|
679
|
+
}
|
|
680
|
+
if (vAlign === 'middle') {
|
|
681
|
+
y = position.y - dimensions.height / 2;
|
|
682
|
+
}
|
|
683
|
+
else if (vAlign === 'bottom') {
|
|
684
|
+
y = position.y - dimensions.height;
|
|
685
|
+
}
|
|
686
|
+
else if (vAlign === 'baseline') {
|
|
687
|
+
y = position.y + dimensions.y;
|
|
688
|
+
}
|
|
689
|
+
else {
|
|
690
|
+
y = position.y;
|
|
691
|
+
}
|
|
692
|
+
return {
|
|
693
|
+
x: x,
|
|
694
|
+
y: y
|
|
695
|
+
};
|
|
696
|
+
}
|
|
697
|
+
/**
|
|
698
|
+
* Compares if two ItemInfo are equal
|
|
699
|
+
*/
|
|
700
|
+
function isEqualItem(item1, item2) {
|
|
701
|
+
return item1?.id === item2?.id && item1?.type === item2?.type;
|
|
702
|
+
}
|
|
703
|
+
/**
|
|
704
|
+
* Returns the item info of the data-oj-node or data-oj-link attribute for a given element.
|
|
705
|
+
*/
|
|
706
|
+
function getNavigableInfo(element, promotedLinkMap, rootElementRef) {
|
|
707
|
+
let type;
|
|
708
|
+
let elem = element;
|
|
709
|
+
let navigableId;
|
|
710
|
+
while (!navigableId) {
|
|
711
|
+
if (elem.dataset['ojPrivateNode']) {
|
|
712
|
+
type = 'node';
|
|
713
|
+
navigableId = elem.dataset['ojPrivateNode'];
|
|
714
|
+
}
|
|
715
|
+
else if (elem.dataset['ojPrivateLink']) {
|
|
716
|
+
navigableId = elem.dataset['ojPrivateLink'];
|
|
717
|
+
type = 'link';
|
|
718
|
+
}
|
|
719
|
+
else if (elem.dataset['ojPrivatePromotedLink']) {
|
|
720
|
+
navigableId = promotedLinkMap.get(elem.dataset['ojPrivatePromotedLink']);
|
|
721
|
+
type = 'promotedLink';
|
|
722
|
+
}
|
|
723
|
+
if (!navigableId) {
|
|
724
|
+
if (elem.parentElement && elem.parentElement !== rootElementRef?.current) {
|
|
725
|
+
elem = elem.parentElement;
|
|
726
|
+
}
|
|
727
|
+
else {
|
|
728
|
+
break;
|
|
729
|
+
}
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
return {
|
|
733
|
+
id: navigableId,
|
|
734
|
+
type: type
|
|
735
|
+
};
|
|
736
|
+
}
|
|
737
|
+
/**
|
|
738
|
+
* Returns the id of the node the expand collapse button belongs to
|
|
739
|
+
*/
|
|
740
|
+
function expCollapseButtonId(element, rootElementRef) {
|
|
741
|
+
let elem = element;
|
|
742
|
+
let id;
|
|
743
|
+
while (!id) {
|
|
744
|
+
id = elem.dataset['ojPrivateButton'];
|
|
745
|
+
if (!id) {
|
|
746
|
+
if (elem.parentElement &&
|
|
747
|
+
!elem.parentElement.dataset['ojPrivateNode'] &&
|
|
748
|
+
elem.parentElement !== rootElementRef?.current) {
|
|
749
|
+
elem = elem.parentElement;
|
|
750
|
+
}
|
|
751
|
+
else {
|
|
752
|
+
break;
|
|
753
|
+
}
|
|
754
|
+
}
|
|
755
|
+
}
|
|
756
|
+
return id;
|
|
757
|
+
}
|
|
758
|
+
/**
|
|
759
|
+
* Returns the aria label
|
|
760
|
+
*/
|
|
761
|
+
function getItemAriaLabel(translations, supportsSelection, states, accessibleLabel) {
|
|
762
|
+
return generateAriaLabel(translations, accessibleLabel || '', {
|
|
763
|
+
isSelected: !supportsSelection ? undefined : states.isSelected,
|
|
764
|
+
isIndirect: states.isIndirect,
|
|
765
|
+
isExpanded: states.isExpanded,
|
|
766
|
+
isCollapsed: states.isCollapsed
|
|
767
|
+
});
|
|
768
|
+
}
|
|
769
|
+
/**
|
|
770
|
+
* Returns the font props for a node or link
|
|
771
|
+
*/
|
|
772
|
+
function _getFontProps(styles) {
|
|
773
|
+
const fontProps = {};
|
|
774
|
+
if (!styles)
|
|
775
|
+
return fontProps;
|
|
776
|
+
if (styles.fontFamily)
|
|
777
|
+
fontProps.fontFamily = styles.fontFamily;
|
|
778
|
+
if (styles.fontSize)
|
|
779
|
+
fontProps.fontSize = styles.fontSize;
|
|
780
|
+
if (styles.fontStyle)
|
|
781
|
+
fontProps.fontStyle = styles.fontStyle;
|
|
782
|
+
if (styles.fontWeight)
|
|
783
|
+
fontProps.fontWeight = styles.fontWeight;
|
|
784
|
+
return fontProps;
|
|
785
|
+
}
|
|
786
|
+
/**
|
|
787
|
+
* Returns whether the node is a leaf node
|
|
788
|
+
*/
|
|
789
|
+
function isLeafNode(nodeData) {
|
|
790
|
+
return !nodeData.nodes;
|
|
791
|
+
}
|
|
792
|
+
function isContainerReady(nodeData, nodeBounds, links, promotedLinks, linkDimensions, promotedLinkDimensions) {
|
|
793
|
+
const nodes = nodeData.nodes;
|
|
794
|
+
for (let i = 0; i < nodes?.length; i++) {
|
|
795
|
+
const child = nodes[i].id;
|
|
796
|
+
if (!nodeBounds.get(child)) {
|
|
797
|
+
return false;
|
|
798
|
+
}
|
|
799
|
+
}
|
|
800
|
+
for (let i = 0; i < links.length; i++) {
|
|
801
|
+
const link = links[i].id;
|
|
802
|
+
const linkDims = linkDimensions.get(link);
|
|
803
|
+
if (!linkDims || (linkDims.width === 0 && linkDims.height === 0)) {
|
|
804
|
+
return false;
|
|
805
|
+
}
|
|
806
|
+
}
|
|
807
|
+
for (let i = 0; i < promotedLinks.length; i++) {
|
|
808
|
+
const link = promotedLinks[i];
|
|
809
|
+
const linkDims = promotedLinkDimensions.get(getPromotedString(link));
|
|
810
|
+
if (!linkDims || (linkDims.width === 0 && linkDims.height === 0)) {
|
|
811
|
+
return false;
|
|
812
|
+
}
|
|
813
|
+
}
|
|
814
|
+
return true;
|
|
815
|
+
}
|
|
816
|
+
function getPromotedString(id) {
|
|
817
|
+
return `${id.startNode}_${id.endNode}`;
|
|
818
|
+
}
|
|
819
|
+
function comparePromotedLinks(link1, link2) {
|
|
820
|
+
return link1.startNode === link2.startNode && link1.endNode === link2.endNode;
|
|
821
|
+
}
|
|
822
|
+
function isPromoted(link) {
|
|
823
|
+
return !('id' in link);
|
|
824
|
+
}
|
|
825
|
+
function getCommonAncestorId(startId, endId, nodeIdToParentMap) {
|
|
826
|
+
const startAnc = _getAncestorIds(startId, nodeIdToParentMap);
|
|
827
|
+
const endAnc = _getAncestorIds(endId, nodeIdToParentMap);
|
|
828
|
+
for (let i = 0; i < startAnc.length; i++) {
|
|
829
|
+
if (endAnc.indexOf(startAnc[i]) > -1) {
|
|
830
|
+
return startAnc[i];
|
|
831
|
+
}
|
|
832
|
+
}
|
|
833
|
+
return undefined;
|
|
834
|
+
}
|
|
835
|
+
function getLinksForNode(containerId, links, promotedLinks, nodeIdToParentMap) {
|
|
836
|
+
// front links are in front of nodes
|
|
837
|
+
const frontLinks = [];
|
|
838
|
+
const backLinks = [];
|
|
839
|
+
for (let i = 0; i < links.length; i++) {
|
|
840
|
+
const link = links[i];
|
|
841
|
+
const ancId = getCommonAncestorId(link.startNode, link.endNode, nodeIdToParentMap);
|
|
842
|
+
if (ancId === containerId) {
|
|
843
|
+
if (!nodeIdToParentMap.get(link.startNode) && !nodeIdToParentMap.get(link.endNode))
|
|
844
|
+
backLinks.push(link);
|
|
845
|
+
else
|
|
846
|
+
frontLinks.push(link);
|
|
847
|
+
}
|
|
848
|
+
}
|
|
849
|
+
const frontPromotedLinks = [];
|
|
850
|
+
const backPromotedLinks = [];
|
|
851
|
+
for (let i = 0; i < promotedLinks.length; i++) {
|
|
852
|
+
const link = promotedLinks[i];
|
|
853
|
+
const ancId = getCommonAncestorId(link.startNode, link.endNode, nodeIdToParentMap);
|
|
854
|
+
if (ancId === containerId) {
|
|
855
|
+
if (!nodeIdToParentMap.get(link.startNode) && !nodeIdToParentMap.get(link.endNode))
|
|
856
|
+
backPromotedLinks.push(link);
|
|
857
|
+
else
|
|
858
|
+
frontPromotedLinks.push(link);
|
|
859
|
+
}
|
|
860
|
+
}
|
|
861
|
+
return { frontLinks, frontPromotedLinks, backLinks, backPromotedLinks };
|
|
862
|
+
}
|
|
863
|
+
function _getAncestorIds(nodeId, nodes) {
|
|
864
|
+
const ancestors = [];
|
|
865
|
+
let anc = nodes.get(nodeId);
|
|
866
|
+
while (anc !== undefined) {
|
|
867
|
+
ancestors.push(anc);
|
|
868
|
+
anc = nodes.get(anc);
|
|
869
|
+
}
|
|
870
|
+
return ancestors;
|
|
871
|
+
}
|
|
872
|
+
function containerLinksReady(containerLinks, layoutOutput) {
|
|
873
|
+
const nodes = layoutOutput.nodes;
|
|
874
|
+
for (let i = 0; i < containerLinks.length; i++) {
|
|
875
|
+
const link = containerLinks[i];
|
|
876
|
+
if (!(nodes[link.startNode] && nodes[link.endNode])) {
|
|
877
|
+
return false;
|
|
878
|
+
}
|
|
879
|
+
}
|
|
880
|
+
return true;
|
|
881
|
+
}
|
|
882
|
+
function changeExpanded(id, expanded) {
|
|
883
|
+
if (containsKey(expanded, id)) {
|
|
884
|
+
return removeKey(expanded, id, false);
|
|
885
|
+
}
|
|
886
|
+
else {
|
|
887
|
+
return addKey(expanded, id);
|
|
888
|
+
}
|
|
889
|
+
}
|
|
890
|
+
function getPromotedLinks(links, expanded, allContainerNodes, allVisibleNodes) {
|
|
891
|
+
const collapsed = [];
|
|
892
|
+
allContainerNodes.forEach((node) => {
|
|
893
|
+
if (!containsKey(expanded, node.id)) {
|
|
894
|
+
collapsed.push(node);
|
|
895
|
+
}
|
|
896
|
+
});
|
|
897
|
+
const promotedLinks = [];
|
|
898
|
+
const linkToPromotedMap = new Map();
|
|
899
|
+
const promotedToLinkMap = new Map();
|
|
900
|
+
for (let i = 0; i < links.length; i++) {
|
|
901
|
+
const link = links[i];
|
|
902
|
+
const linkId = link.id;
|
|
903
|
+
const startVisible = allVisibleNodes.includes(link.startNode)
|
|
904
|
+
? link.startNode
|
|
905
|
+
: firstVisibleAncestor(link.startNode, collapsed);
|
|
906
|
+
const endVisible = allVisibleNodes.includes(link.endNode)
|
|
907
|
+
? link.endNode
|
|
908
|
+
: firstVisibleAncestor(link.endNode, collapsed);
|
|
909
|
+
if (startVisible &&
|
|
910
|
+
endVisible &&
|
|
911
|
+
(startVisible !== link.startNode || endVisible !== link.endNode) &&
|
|
912
|
+
startVisible !== endVisible) {
|
|
913
|
+
const promotedLinkId = `${startVisible}_${endVisible}`;
|
|
914
|
+
let subLinks = promotedToLinkMap.get(promotedLinkId);
|
|
915
|
+
if (subLinks) {
|
|
916
|
+
subLinks.push(link);
|
|
917
|
+
}
|
|
918
|
+
else {
|
|
919
|
+
const promotedLink = {
|
|
920
|
+
id: promotedLinkId,
|
|
921
|
+
startNode: startVisible,
|
|
922
|
+
endNode: endVisible
|
|
923
|
+
};
|
|
924
|
+
promotedLinks.push(promotedLink);
|
|
925
|
+
subLinks = [link];
|
|
926
|
+
}
|
|
927
|
+
promotedToLinkMap.set(promotedLinkId, subLinks);
|
|
928
|
+
linkToPromotedMap.set(linkId, promotedLinkId);
|
|
929
|
+
}
|
|
930
|
+
}
|
|
931
|
+
const finalPromoted = [];
|
|
932
|
+
for (let i = 0; i < promotedLinks.length; i++) {
|
|
933
|
+
const promotedLink = promotedLinks[i];
|
|
934
|
+
finalPromoted.push({
|
|
935
|
+
startNode: promotedLink.startNode,
|
|
936
|
+
endNode: promotedLink.endNode,
|
|
937
|
+
links: promotedToLinkMap.get(promotedLink.id)
|
|
938
|
+
});
|
|
939
|
+
}
|
|
940
|
+
return finalPromoted;
|
|
941
|
+
}
|
|
942
|
+
// One of the start/end node position changed causing the link position to change
|
|
943
|
+
function linkPositionChanged(nodeBounds, bounds, links) {
|
|
944
|
+
const nodesWithLinks = [];
|
|
945
|
+
links.forEach((value) => {
|
|
946
|
+
if (!nodesWithLinks.includes(value.startNode)) {
|
|
947
|
+
nodesWithLinks.push(value.startNode);
|
|
948
|
+
}
|
|
949
|
+
if (!nodesWithLinks.includes(value.endNode)) {
|
|
950
|
+
nodesWithLinks.push(value.endNode);
|
|
951
|
+
}
|
|
952
|
+
});
|
|
953
|
+
let rerender = false;
|
|
954
|
+
nodeBounds.forEach((value, key) => {
|
|
955
|
+
const b2Value = bounds.get(key);
|
|
956
|
+
let equal = true;
|
|
957
|
+
if (!b2Value)
|
|
958
|
+
equal = false;
|
|
959
|
+
else if (Math.abs(value.x - b2Value.x) > 0.5 ||
|
|
960
|
+
Math.abs(value.y - b2Value.y) > 0.5 ||
|
|
961
|
+
Math.abs(value.width - b2Value.width) > 0.5 ||
|
|
962
|
+
Math.abs(value.height - b2Value.height) > 0.5) {
|
|
963
|
+
equal = false;
|
|
964
|
+
}
|
|
965
|
+
if (!equal && nodesWithLinks.includes(key)) {
|
|
966
|
+
rerender = true;
|
|
967
|
+
}
|
|
968
|
+
});
|
|
969
|
+
return rerender;
|
|
970
|
+
}
|
|
971
|
+
function getChildInfo(id, nodeIdToDataMap) {
|
|
972
|
+
const nodes = nodeIdToDataMap.get(id)?.nodes;
|
|
973
|
+
if (nodes && nodes.length > 0) {
|
|
974
|
+
return nodes[0];
|
|
975
|
+
}
|
|
976
|
+
return undefined;
|
|
977
|
+
}
|
|
978
|
+
function firstVisibleAncestor(nodeId, collapsed) {
|
|
979
|
+
const isDescendant = (chId, data) => {
|
|
980
|
+
if (data) {
|
|
981
|
+
for (let i = 0; i < data.length; i++) {
|
|
982
|
+
if (data[i].id === chId || isDescendant(chId, data[i].nodes)) {
|
|
983
|
+
return true;
|
|
984
|
+
}
|
|
985
|
+
}
|
|
986
|
+
}
|
|
987
|
+
return false;
|
|
988
|
+
};
|
|
989
|
+
for (let i = 0; i < collapsed.length; i++) {
|
|
990
|
+
const node = collapsed[i];
|
|
991
|
+
if (isDescendant(nodeId, node.nodes)) {
|
|
992
|
+
return node.id;
|
|
993
|
+
}
|
|
994
|
+
}
|
|
995
|
+
return null;
|
|
996
|
+
}
|
|
997
|
+
|
|
998
|
+
const DiagramLabel = ({ text, position, styles, dimensions, isRTL }) => {
|
|
999
|
+
const { labelStyle, labelBorderStyle } = labelStyles;
|
|
1000
|
+
const labelPosition = getLabelPosition(dimensions, position, isRTL);
|
|
1001
|
+
const labelRotation = getLabelRotation(position);
|
|
1002
|
+
return (jsx("div", { class: classNames([labelStyle, styles && styles.borderColor && labelBorderStyle]), style: {
|
|
1003
|
+
top: labelPosition.y,
|
|
1004
|
+
left: labelPosition.x,
|
|
1005
|
+
...styles,
|
|
1006
|
+
...labelRotation
|
|
1007
|
+
}, children: text }));
|
|
1008
|
+
};
|
|
1009
|
+
/**
|
|
1010
|
+
* Returns the label rotation props
|
|
1011
|
+
* @param position
|
|
1012
|
+
* @returns rotation props
|
|
1013
|
+
*/
|
|
1014
|
+
function getLabelRotation(position) {
|
|
1015
|
+
const rotationAngle = position.rotationAngle;
|
|
1016
|
+
const rotationPoint = position.rotationPoint;
|
|
1017
|
+
const rotation = {};
|
|
1018
|
+
if (rotationAngle) {
|
|
1019
|
+
rotation['transform'] = `rotate(${rotationAngle}deg)`;
|
|
1020
|
+
}
|
|
1021
|
+
if (rotationPoint) {
|
|
1022
|
+
rotation['transform-origin'] = `${rotationPoint.x}px ${rotationPoint.y}px`;
|
|
1023
|
+
}
|
|
1024
|
+
return rotation;
|
|
1025
|
+
}
|
|
1026
|
+
|
|
1027
|
+
const DiagramNodeElement = ({ id, state, position, activeId, nodeRenderer, onNodeSizeChanged, data, accessibleLabel, isDimmed, supportsSelection, content, labelPosition, labelDimensions }) => {
|
|
1028
|
+
const { nodeStyles, dimmedItemStyle } = itemStyles;
|
|
1029
|
+
const translations = useTranslationBundle('@oracle/oraclejet-preact');
|
|
1030
|
+
const ref = useRef(null);
|
|
1031
|
+
// TODO JET-62472 change to one resize observer function
|
|
1032
|
+
const optionsRef = useRef({ box: 'border-box' });
|
|
1033
|
+
useResizeObserver(ref, useCallback((entry) => {
|
|
1034
|
+
const boxSize = entry.borderBoxSize;
|
|
1035
|
+
const width = boxSize[0].inlineSize;
|
|
1036
|
+
const height = boxSize[0].blockSize;
|
|
1037
|
+
onNodeSizeChanged(width, height, id);
|
|
1038
|
+
}, [id, onNodeSizeChanged]), optionsRef.current);
|
|
1039
|
+
const nodePos = position ? position : { x: 0, y: 0 };
|
|
1040
|
+
const { direction } = useUser();
|
|
1041
|
+
const hasLabel = data.label && labelPosition && labelDimensions;
|
|
1042
|
+
const expander = (jsx("div", { "data-oj-private-button": id, class: buttonStyle, children: jsx(EmbeddedIconButton, { "aria-hidden": true, size: "xs", children: content ? jsx(SvgMinus, {}) : jsx(SvgPlus, {}) }) }));
|
|
1043
|
+
const context = {
|
|
1044
|
+
state: state,
|
|
1045
|
+
data: data,
|
|
1046
|
+
childContext: content,
|
|
1047
|
+
expander: expander
|
|
1048
|
+
};
|
|
1049
|
+
return (jsxs("div", { ref: ref, class: nodeStyles, "data-oj-private-node": id, role: content ? 'group' : "img", "aria-label": getItemAriaLabel(translations, supportsSelection, {
|
|
1050
|
+
isSelected: state.isSelected,
|
|
1051
|
+
isExpanded: content !== undefined,
|
|
1052
|
+
isCollapsed: (content === undefined) && (data.nodes !== undefined)
|
|
1053
|
+
}, accessibleLabel), style: {
|
|
1054
|
+
top: nodePos.y,
|
|
1055
|
+
left: nodePos.x
|
|
1056
|
+
}, id: state.isFocused || state.isHovered ? activeId : undefined, children: [jsx("div", { class: classNames([isDimmed ? dimmedItemStyle : undefined]), children: nodeRenderer(context) }), hasLabel ? (jsx("div", { class: layerStyles, children: jsx(DiagramLabel, { styles: data.labelStyle, text: data.label, position: labelPosition, dimensions: labelDimensions.get(id), isRTL: direction === 'rtl' }) })) : undefined] }, id));
|
|
1057
|
+
};
|
|
1058
|
+
|
|
1059
|
+
const DiagramLinkElement = ({ id, state, activeId, data, linkRenderer, accessibleLabel, isDimmed, supportsSelection, layoutOutput, onLinkSizeChanged }) => {
|
|
1060
|
+
const translations = useTranslationBundle('@oracle/oraclejet-preact');
|
|
1061
|
+
const { dimmedItemStyle, linkStyles } = itemStyles;
|
|
1062
|
+
const context = {
|
|
1063
|
+
state: state,
|
|
1064
|
+
data: data,
|
|
1065
|
+
layoutOutput: layoutOutput,
|
|
1066
|
+
type: 'link'
|
|
1067
|
+
};
|
|
1068
|
+
const ref = useRef(null);
|
|
1069
|
+
const optionsRef = useRef({ box: 'border-box' });
|
|
1070
|
+
useResizeObserver(ref, useCallback((entry) => {
|
|
1071
|
+
const boxSize = entry.borderBoxSize;
|
|
1072
|
+
const width = boxSize[0].inlineSize;
|
|
1073
|
+
const height = boxSize[0].blockSize;
|
|
1074
|
+
onLinkSizeChanged(width, height, id);
|
|
1075
|
+
}, [id, onLinkSizeChanged]), optionsRef.current);
|
|
1076
|
+
return (jsx("g", { ref: ref, id: state.isFocused ? activeId : undefined, "aria-label": getItemAriaLabel(translations, supportsSelection, {
|
|
1077
|
+
isSelected: state.isSelected
|
|
1078
|
+
}, accessibleLabel), "data-oj-private-link": id, role: "img", class: classNames([linkStyles, isDimmed && dimmedItemStyle]), children: linkRenderer(context) }, id));
|
|
1079
|
+
};
|
|
1080
|
+
|
|
1081
|
+
/**
|
|
1082
|
+
* @license
|
|
1083
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
1084
|
+
* Licensed under The Universal Permissive License (UPL), Version 1.0
|
|
1085
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
1086
|
+
* @ignore
|
|
1087
|
+
*/
|
|
1088
|
+
const ZOOM_INCREMENT = 0.05;
|
|
1089
|
+
const ZOOM_TO_FIT_PADDING = 20;
|
|
1090
|
+
const zoom = (nextZoom, zoom, minZoom, maxZoom, onZoomChange) => {
|
|
1091
|
+
const newZoom = nextZoom > maxZoom || nextZoom < minZoom ? zoom : nextZoom;
|
|
1092
|
+
const isZoomChanged = newZoom !== zoom;
|
|
1093
|
+
isZoomChanged &&
|
|
1094
|
+
onZoomChange &&
|
|
1095
|
+
onZoomChange({
|
|
1096
|
+
zoomValue: newZoom
|
|
1097
|
+
});
|
|
1098
|
+
};
|
|
1099
|
+
/**
|
|
1100
|
+
* Returns the zoom properties for the diagram.
|
|
1101
|
+
*/
|
|
1102
|
+
function getZoomProps(props, width, height, contentBounds) {
|
|
1103
|
+
const zoomTofitZoom = getZoomToFitZoom(width, height, contentBounds);
|
|
1104
|
+
const maxZoom = props.maxZoom || 1;
|
|
1105
|
+
const minZoom = props.minZoom || Math.min(maxZoom, zoomTofitZoom);
|
|
1106
|
+
const zoom = props.zoomValue ? props.zoomValue : zoomTofitZoom;
|
|
1107
|
+
return {
|
|
1108
|
+
zooming: props.zooming ? props.zooming : 'off',
|
|
1109
|
+
// default value of 0 indicates zoom-to-fit level
|
|
1110
|
+
minZoom: minZoom,
|
|
1111
|
+
maxZoom: maxZoom,
|
|
1112
|
+
// zoom value of 0 will default to zoom to fit
|
|
1113
|
+
zoomValue: constrainZoom(zoom, minZoom, maxZoom),
|
|
1114
|
+
onZoom: props.onZoom
|
|
1115
|
+
};
|
|
1116
|
+
}
|
|
1117
|
+
/**
|
|
1118
|
+
* Returns the zoom to fit zoom level
|
|
1119
|
+
*/
|
|
1120
|
+
function getZoomToFitZoom(width, height, contentBounds) {
|
|
1121
|
+
const zoomX = (width - 2 * ZOOM_TO_FIT_PADDING) / contentBounds.width;
|
|
1122
|
+
const zoomY = (height - 2 * ZOOM_TO_FIT_PADDING) / contentBounds.height;
|
|
1123
|
+
return Math.min(zoomX, zoomY);
|
|
1124
|
+
}
|
|
1125
|
+
/**
|
|
1126
|
+
* Constrains the zoom level
|
|
1127
|
+
*/
|
|
1128
|
+
function constrainZoom(zoom, minZoom, maxZoom) {
|
|
1129
|
+
let newZoom = Math.max(minZoom, zoom);
|
|
1130
|
+
newZoom = Math.min(maxZoom, newZoom);
|
|
1131
|
+
return newZoom;
|
|
1132
|
+
}
|
|
1133
|
+
/**
|
|
1134
|
+
* Returns the panX, panY, and zoom when zooming and centering an item
|
|
1135
|
+
*/
|
|
1136
|
+
function zoomAndCenterItemFromInfo(info, linkIdToDataMap, bounds, width, height, maxZoom) {
|
|
1137
|
+
const type = info.type;
|
|
1138
|
+
let totalBounds;
|
|
1139
|
+
if (type === 'node') {
|
|
1140
|
+
totalBounds = bounds.get(info.id);
|
|
1141
|
+
}
|
|
1142
|
+
else {
|
|
1143
|
+
const link = linkIdToDataMap.get(info.id);
|
|
1144
|
+
const startNodeBounds = bounds.get(link.startNode);
|
|
1145
|
+
const endNodeBounds = bounds.get(link.endNode);
|
|
1146
|
+
const minX = Math.min(startNodeBounds.x, endNodeBounds.x);
|
|
1147
|
+
const minY = Math.min(startNodeBounds.y, endNodeBounds.y);
|
|
1148
|
+
const maxX = Math.max(startNodeBounds.x + startNodeBounds.width, endNodeBounds.x + startNodeBounds.width);
|
|
1149
|
+
const maxY = Math.max(startNodeBounds.y + startNodeBounds.height, endNodeBounds.y + endNodeBounds.height);
|
|
1150
|
+
totalBounds = { x: minX, y: minY, width: maxX - minX, height: maxY - minY };
|
|
1151
|
+
}
|
|
1152
|
+
return getPanZoomToCenterNode(totalBounds, maxZoom, width, height);
|
|
1153
|
+
}
|
|
1154
|
+
/**
|
|
1155
|
+
* Returns the pan and zoom values in order
|
|
1156
|
+
* to center a node or link
|
|
1157
|
+
*/
|
|
1158
|
+
function getPanZoomToCenterNode(bounds, maxZoom, width, height) {
|
|
1159
|
+
const zoomX = (width - 2 * ZOOM_TO_FIT_PADDING) / bounds.width;
|
|
1160
|
+
const zoomY = (height - 2 * ZOOM_TO_FIT_PADDING) / bounds.height;
|
|
1161
|
+
const zoom = Math.min(zoomX, zoomY, maxZoom);
|
|
1162
|
+
const cX = bounds.width / 2 + bounds.x;
|
|
1163
|
+
const cY = bounds.height / 2 + bounds.y;
|
|
1164
|
+
return { centerX: cX, centerY: cY, zoom: zoom };
|
|
1165
|
+
}
|
|
1166
|
+
|
|
1167
|
+
function DiagramLabelLayer({ labelPosition, itemProps, labelDimensions }) {
|
|
1168
|
+
const { direction } = useUser();
|
|
1169
|
+
return (jsx("div", { class: layerStyles, children: itemProps.map((item) => {
|
|
1170
|
+
if (item.label && labelPosition.get(item.id)) {
|
|
1171
|
+
return (jsx(DiagramLabel, { styles: item.labelStyle, text: item.label, position: labelPosition.get(item.id), dimensions: labelDimensions.get(item.id), isRTL: direction === 'rtl' }));
|
|
1172
|
+
}
|
|
1173
|
+
return undefined;
|
|
1174
|
+
}) }));
|
|
1175
|
+
}
|
|
1176
|
+
|
|
1177
|
+
function DiagramLinkLayer({ links, states, linkRenderer, width, height, supportsSelection, onLinkSizeChanged, layoutOutput, combinedNodeBounds, linkLabelPositions, labelDimensions, minX, minY }) {
|
|
1178
|
+
const zoom = getZoomToFitZoom(width, height, combinedNodeBounds);
|
|
1179
|
+
return (jsxs("div", { class: linkLayerStyle, style: { top: -minY, left: -minX }, children: [jsx("svg", { width: width / zoom, height: height / zoom, class: layerStyles, overflow: "visible", children: links.map((link) => {
|
|
1180
|
+
const state = {
|
|
1181
|
+
isSelected: states.selectedLinkIds.includes(link.id),
|
|
1182
|
+
isFocused: states.focusedId === link.id,
|
|
1183
|
+
isHovered: states.hoveredId === link.id,
|
|
1184
|
+
zoom: states.zoom
|
|
1185
|
+
};
|
|
1186
|
+
return (jsx(DiagramLinkElement, { id: link.id, state: state, isDimmed: (states.highlightedNodeIds.length !== 0 ||
|
|
1187
|
+
states.highlightedLinkIds.length !== 0 ||
|
|
1188
|
+
states.highlightedPromotedLinkIds.length !== 0) &&
|
|
1189
|
+
!states.highlightedLinkIds.includes(link.id), activeId: states.activeId, accessibleLabel: link.accessibleLabel, data: link, linkRenderer: linkRenderer, supportsSelection: supportsSelection, layoutOutput: layoutOutput, onLinkSizeChanged: onLinkSizeChanged }));
|
|
1190
|
+
}) }), labelDimensions ? (jsx("div", { children: links && linkLabelPositions ? (jsx(DiagramLabelLayer, { labelPosition: linkLabelPositions, itemProps: links, labelDimensions: labelDimensions })) : undefined })) : undefined] }));
|
|
1191
|
+
}
|
|
1192
|
+
|
|
1193
|
+
const DiagramPromotedLinkElement = ({ id, state, activeId, linkRenderer, isDimmed, supportsSelection, layoutOutput, onLinkSizeChanged }) => {
|
|
1194
|
+
const translations = useTranslationBundle('@oracle/oraclejet-preact');
|
|
1195
|
+
const { dimmedItemStyle, linkStyles } = itemStyles;
|
|
1196
|
+
const context = {
|
|
1197
|
+
state: state,
|
|
1198
|
+
data: id.links,
|
|
1199
|
+
layoutOutput: layoutOutput,
|
|
1200
|
+
startNode: id.startNode,
|
|
1201
|
+
endNode: id.endNode,
|
|
1202
|
+
type: 'promotedLink'
|
|
1203
|
+
};
|
|
1204
|
+
const ref = useRef(null);
|
|
1205
|
+
const optionsRef = useRef({ box: 'border-box' });
|
|
1206
|
+
const stringId = getPromotedString(id);
|
|
1207
|
+
useResizeObserver(ref, useCallback((entry) => {
|
|
1208
|
+
const boxSize = entry.borderBoxSize;
|
|
1209
|
+
const width = boxSize[0].inlineSize;
|
|
1210
|
+
const height = boxSize[0].blockSize;
|
|
1211
|
+
onLinkSizeChanged(width, height, stringId);
|
|
1212
|
+
}, [stringId, onLinkSizeChanged]), optionsRef.current);
|
|
1213
|
+
const num_links = id.links.length;
|
|
1214
|
+
const accessibleLabel = num_links > 1
|
|
1215
|
+
? translations.diagram_promotedLinks({ num_links: num_links.toString() })
|
|
1216
|
+
: translations.diagram_promotedLink();
|
|
1217
|
+
return (jsx("g", { ref: ref, id: state.isFocused ? activeId : undefined, "aria-label": getItemAriaLabel(translations, supportsSelection, {
|
|
1218
|
+
isSelected: state.isSelected,
|
|
1219
|
+
isIndirect: true
|
|
1220
|
+
}, accessibleLabel), "data-oj-private-promoted-link": stringId, role: "img", class: classNames([linkStyles, isDimmed && dimmedItemStyle]), children: linkRenderer(context) }, stringId));
|
|
1221
|
+
};
|
|
1222
|
+
|
|
1223
|
+
function DiagramPromotedLinkLayer({ links, states, linkRenderer, width, height, supportsSelection, onLinkSizeChanged, layoutOutput, combinedNodeBounds, minX, minY }) {
|
|
1224
|
+
const zoom = getZoomToFitZoom(width, height, combinedNodeBounds);
|
|
1225
|
+
return (jsx("div", { class: linkLayerStyle, style: { top: -minY, left: -minX }, children: jsx("svg", { width: width / zoom, height: height / zoom, class: layerStyles, overflow: "visible", children: links.map((link) => {
|
|
1226
|
+
const state = {
|
|
1227
|
+
isSelected: states.selectedPromotedLinkIds.includes(link),
|
|
1228
|
+
isFocused: states.focusedId === link,
|
|
1229
|
+
isHovered: states.hoveredId === link,
|
|
1230
|
+
zoom: states.zoom
|
|
1231
|
+
};
|
|
1232
|
+
return (jsx(DiagramPromotedLinkElement, { id: link, state: state, isDimmed: (states.highlightedNodeIds.length !== 0 ||
|
|
1233
|
+
states.highlightedLinkIds.length !== 0 ||
|
|
1234
|
+
states.highlightedPromotedLinkIds.length !== 0) &&
|
|
1235
|
+
!states.highlightedPromotedLinkIds.includes(link), activeId: states.activeId, linkRenderer: linkRenderer, supportsSelection: supportsSelection, layoutOutput: layoutOutput, onLinkSizeChanged: onLinkSizeChanged }));
|
|
1236
|
+
}) }) }));
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
function DiagramNodeLayer({ nodes, states, nodeRenderer, linkRenderer, nodeBounds, width, height, onNodeSizeChanged, onLinkSizeChanged, onPromotedLinkSizeChanged, supportsSelection, nodeLabelPositions, linkLabelPositions, labelDimensions, minX = 0, minY = 0, parentId, links, promotedLinks, layoutOutput, zoom, nodeIdToParentMap, linkDimensions, promotedLinkDimensions, rootRef, combinedNodeBounds, nodeBoundsRef, normalizeLinks = false }) {
|
|
1240
|
+
const { frontLinks, frontPromotedLinks, backLinks, backPromotedLinks } = getLinksForNode(parentId, links, promotedLinks, nodeIdToParentMap);
|
|
1241
|
+
return (jsxs("div", { class: layerStyles, "data-oj-private-node-container": true, children: [layoutOutput &&
|
|
1242
|
+
linkRenderer &&
|
|
1243
|
+
backLinks.length > 0 &&
|
|
1244
|
+
containerLinksReady(backLinks, layoutOutput) && (jsx(DiagramLinkLayer, { links: backLinks, states: states, linkRenderer: linkRenderer, width: width / zoom, height: height, supportsSelection: supportsSelection, labelDimensions: labelDimensions, layoutOutput: layoutOutput, onLinkSizeChanged: onLinkSizeChanged, linkLabelPositions: linkLabelPositions, combinedNodeBounds: combinedNodeBounds, minY: normalizeLinks ? minY : 0, minX: normalizeLinks ? minX : 0 })), layoutOutput &&
|
|
1245
|
+
linkRenderer &&
|
|
1246
|
+
backPromotedLinks.length > 0 &&
|
|
1247
|
+
containerLinksReady(backPromotedLinks, layoutOutput) && (jsx(DiagramPromotedLinkLayer, { links: backPromotedLinks, states: states, linkRenderer: linkRenderer, width: width / zoom, height: height, supportsSelection: supportsSelection, layoutOutput: layoutOutput, onLinkSizeChanged: onPromotedLinkSizeChanged, combinedNodeBounds: combinedNodeBounds, minY: normalizeLinks ? minY : 0, minX: normalizeLinks ? minX : 0 })), nodes.map((node) => {
|
|
1248
|
+
// this is for initial render before the layout function so render all nodes at 0,0
|
|
1249
|
+
const position = nodeBounds && nodeBounds.get(node.id)
|
|
1250
|
+
? { x: nodeBounds.get(node.id).x - minX, y: nodeBounds.get(node.id).y - minY }
|
|
1251
|
+
: undefined;
|
|
1252
|
+
const state = {
|
|
1253
|
+
isSelected: states.selectedNodeIds.includes(node.id),
|
|
1254
|
+
isFocused: states.focusedId === node.id,
|
|
1255
|
+
isHovered: states.hoveredId === node.id,
|
|
1256
|
+
zoom: states.zoom,
|
|
1257
|
+
isExpanded: states.expanded && containsKey(states.expanded, node.id)
|
|
1258
|
+
};
|
|
1259
|
+
const { backLinks, backPromotedLinks } = getLinksForNode(node.id, links, promotedLinks, nodeIdToParentMap);
|
|
1260
|
+
// Leaf node or node is collapsed
|
|
1261
|
+
if (isLeafNode(node) || !containsKey(states.expanded, node.id)) {
|
|
1262
|
+
return (jsx(DiagramNodeElement, { id: node.id, position: position, state: state, isDimmed: (states.highlightedNodeIds.length !== 0 ||
|
|
1263
|
+
states.highlightedLinkIds.length !== 0 ||
|
|
1264
|
+
states.highlightedPromotedLinkIds.length !== 0) &&
|
|
1265
|
+
!states.highlightedNodeIds.includes(node.id), activeId: states.activeId, nodeRenderer: nodeRenderer, onNodeSizeChanged: onNodeSizeChanged, accessibleLabel: node.accessibleLabel, data: node, supportsSelection: supportsSelection, labelDimensions: labelDimensions, labelPosition: nodeLabelPositions?.get(node.id) }));
|
|
1266
|
+
// Expanded container where children are ready
|
|
1267
|
+
}
|
|
1268
|
+
else if (nodeBounds &&
|
|
1269
|
+
isContainerReady(node, nodeBounds, backLinks, backPromotedLinks, linkDimensions, promotedLinkDimensions)) {
|
|
1270
|
+
const childContent = getContent(node, states, nodeRenderer, onNodeSizeChanged, onLinkSizeChanged, onPromotedLinkSizeChanged, supportsSelection, links, promotedLinks, nodeIdToParentMap, width, height, zoom, node.id, nodeBounds, linkDimensions, promotedLinkDimensions, combinedNodeBounds, nodeBoundsRef, nodeLabelPositions, linkLabelPositions, labelDimensions, linkRenderer, layoutOutput, rootRef);
|
|
1271
|
+
return (jsx(DiagramNodeElement, { id: node.id, position: position, state: state, isDimmed: (states.highlightedNodeIds.length !== 0 ||
|
|
1272
|
+
states.highlightedLinkIds.length !== 0 ||
|
|
1273
|
+
states.highlightedPromotedLinkIds.length !== 0) &&
|
|
1274
|
+
!states.highlightedNodeIds.includes(node.id), activeId: states.activeId, nodeRenderer: nodeRenderer, onNodeSizeChanged: onNodeSizeChanged, accessibleLabel: node.accessibleLabel, data: node, supportsSelection: supportsSelection, content: childContent, labelDimensions: labelDimensions, labelPosition: nodeLabelPositions?.get(node.id) }));
|
|
1275
|
+
}
|
|
1276
|
+
else {
|
|
1277
|
+
const childContent = getContent(node, states, nodeRenderer, onNodeSizeChanged, onLinkSizeChanged, onPromotedLinkSizeChanged, supportsSelection, links, promotedLinks, nodeIdToParentMap, width, height, zoom, node.id, nodeBounds, linkDimensions, promotedLinkDimensions, combinedNodeBounds, nodeBoundsRef, nodeLabelPositions, linkLabelPositions, labelDimensions, linkRenderer, layoutOutput, rootRef);
|
|
1278
|
+
return jsx("div", { children: childContent.content });
|
|
1279
|
+
}
|
|
1280
|
+
}), layoutOutput &&
|
|
1281
|
+
linkRenderer &&
|
|
1282
|
+
frontLinks.length > 0 &&
|
|
1283
|
+
containerLinksReady(frontLinks, layoutOutput) && (jsx(DiagramLinkLayer, { links: frontLinks, states: states, linkRenderer: linkRenderer, width: width / zoom, height: height, supportsSelection: supportsSelection, labelDimensions: labelDimensions, layoutOutput: layoutOutput, onLinkSizeChanged: onLinkSizeChanged, linkLabelPositions: linkLabelPositions, combinedNodeBounds: combinedNodeBounds, minY: normalizeLinks ? minY : 0, minX: normalizeLinks ? minX : 0 })), layoutOutput &&
|
|
1284
|
+
linkRenderer &&
|
|
1285
|
+
frontPromotedLinks.length > 0 &&
|
|
1286
|
+
containerLinksReady(frontPromotedLinks, layoutOutput) && (jsx(DiagramPromotedLinkLayer, { links: frontPromotedLinks, states: states, linkRenderer: linkRenderer, width: width / zoom, height: height, supportsSelection: supportsSelection, layoutOutput: layoutOutput, onLinkSizeChanged: onPromotedLinkSizeChanged, combinedNodeBounds: combinedNodeBounds, minY: normalizeLinks ? minY : 0, minX: normalizeLinks ? minX : 0 }))] }));
|
|
1287
|
+
}
|
|
1288
|
+
function getContent(nodeData, states, nodeRenderer, onNodeSizeChanged, onLinkSizeChanged, onPromotedLinkSizeChanged, supportsSelection, links, promotedLinks, nodeIdToParentMap, width, height, zoom, parentId, nodeBounds, linkDimensions, promotedLinkDimensions, combinedNodeBounds, nodeBoundsRef, nodeLabelPositions, linkLabelPositions, labelDimensions, linkRenderer, layoutOutput, rootRef) {
|
|
1289
|
+
const nodes = nodeData.nodes;
|
|
1290
|
+
const { backLinks, backPromotedLinks } = getLinksForNode(parentId, links, promotedLinks, nodeIdToParentMap);
|
|
1291
|
+
const { minX, minY, contentWidth, contentHeight, bounds } = getBounds(nodes, backLinks, backPromotedLinks, nodeBounds, linkDimensions, promotedLinkDimensions, zoom, rootRef);
|
|
1292
|
+
const nodeFullBounds = nodeBoundsRef.current;
|
|
1293
|
+
nodeFullBounds?.set(nodeData.id, bounds);
|
|
1294
|
+
nodeBoundsRef.current = nodeFullBounds;
|
|
1295
|
+
const content = (jsx("div", { "data-oj-private-child": parentId, style: { position: 'relative' }, children: jsx(DiagramNodeLayer, { nodes: nodes, nodeBounds: nodeBounds, states: states, minX: nodeBounds ? minX : undefined, minY: nodeBounds ? minY : undefined, nodeRenderer: nodeRenderer, onNodeSizeChanged: onNodeSizeChanged, onLinkSizeChanged: onLinkSizeChanged, onPromotedLinkSizeChanged: onPromotedLinkSizeChanged, supportsSelection: supportsSelection, nodeLabelPositions: nodeLabelPositions, linkLabelPositions: linkLabelPositions, labelDimensions: labelDimensions, links: links, promotedLinks: promotedLinks, nodeIdToParentMap: nodeIdToParentMap, linkRenderer: linkRenderer, layoutOutput: layoutOutput, width: width, height: height, zoom: zoom, parentId: parentId, linkDimensions: linkDimensions, promotedLinkDimensions: promotedLinkDimensions, rootRef: rootRef, combinedNodeBounds: combinedNodeBounds, nodeBoundsRef: nodeBoundsRef }) }));
|
|
1296
|
+
return {
|
|
1297
|
+
content,
|
|
1298
|
+
width: contentWidth ? contentWidth : 0,
|
|
1299
|
+
height: contentHeight ? contentHeight - minY : 0,
|
|
1300
|
+
bounds
|
|
1301
|
+
};
|
|
1302
|
+
}
|
|
1303
|
+
|
|
1304
|
+
function DiagramLayers({ nodes, links, promotedLinks, nodeRenderer, linkRenderer, states, nodeBounds, width, height, onNodeSizeChanged, onLinkSizeChanged, onPromotedLinkSizeChanged, labelDimensions, nodeLabelPositions, linkLabelPositions, supportsSelection, layoutOutput, zoom, nodeIdToParentMap, linkDimensions, promotedLinkDimensions, rootRef, combinedNodeBounds, nodeBoundsRef, normalizeLinks }) {
|
|
1305
|
+
const { backLinks, backPromotedLinks } = getLinksForNode(undefined, links, promotedLinks, nodeIdToParentMap);
|
|
1306
|
+
const { minX, minY } = getBounds(nodes, backLinks, backPromotedLinks, nodeBounds, linkDimensions, promotedLinkDimensions, zoom, rootRef);
|
|
1307
|
+
return (jsx(Fragment, { children: jsx(DiagramNodeLayer, { nodes: nodes, nodeBounds: nodeBounds, states: states, nodeRenderer: nodeRenderer, onNodeSizeChanged: onNodeSizeChanged, onLinkSizeChanged: onLinkSizeChanged, onPromotedLinkSizeChanged: onPromotedLinkSizeChanged, supportsSelection: supportsSelection, nodeLabelPositions: nodeLabelPositions, linkLabelPositions: linkLabelPositions, labelDimensions: labelDimensions, linkDimensions: linkDimensions, promotedLinkDimensions: promotedLinkDimensions, rootRef: rootRef, links: links, promotedLinks: promotedLinks, nodeIdToParentMap: nodeIdToParentMap, linkRenderer: linkRenderer, layoutOutput: layoutOutput, width: width, height: height, zoom: zoom, minX: nodeBounds && minX !== Infinity ? minX : undefined, minY: nodeBounds && minY !== Infinity ? minY : undefined, combinedNodeBounds: combinedNodeBounds, nodeBoundsRef: nodeBoundsRef, normalizeLinks: normalizeLinks }) }));
|
|
1308
|
+
}
|
|
1309
|
+
|
|
1310
|
+
const constrainPan = (previousPan, nextPan, panBounds, panDirection) => {
|
|
1311
|
+
const panX = panDirection !== 'y' ? nextPan.panX : previousPan.panX;
|
|
1312
|
+
const panY = panDirection !== 'x' ? nextPan.panY : previousPan.panY;
|
|
1313
|
+
return {
|
|
1314
|
+
panX: panX > panBounds.maxX ? panBounds.maxX : panX < panBounds.minX ? panBounds.minX : panX,
|
|
1315
|
+
panY: panY > panBounds.maxY ? panBounds.maxY : panY < panBounds.minY ? panBounds.minY : panY
|
|
1316
|
+
};
|
|
1317
|
+
};
|
|
1318
|
+
const pan = (previousPan, nextPan, panDirection, zoom, width, height, panBounds, onPanChange) => {
|
|
1319
|
+
if (!panBounds) {
|
|
1320
|
+
//On initial render before nodes are rendered
|
|
1321
|
+
return { newPan: { panX: 0, panY: 0 } };
|
|
1322
|
+
}
|
|
1323
|
+
const newPan = constrainPan(previousPan, nextPan, panBounds, panDirection);
|
|
1324
|
+
const isPanChanged = newPan.panX !== previousPan.panX || newPan.panY !== previousPan.panY;
|
|
1325
|
+
const center = panXYToCenterXY(newPan.panX, newPan.panY, zoom, width, height);
|
|
1326
|
+
isPanChanged &&
|
|
1327
|
+
onPanChange &&
|
|
1328
|
+
onPanChange({
|
|
1329
|
+
centerX: center.centerX,
|
|
1330
|
+
centerY: center.centerY
|
|
1331
|
+
});
|
|
1332
|
+
return { newPan };
|
|
1333
|
+
};
|
|
1334
|
+
const getPanBounds = (dWidth, dHeight, elemBounds, zoom, minZoom, initPanZoomState, panType) => {
|
|
1335
|
+
const { x, y, width, height } = elemBounds;
|
|
1336
|
+
let minX, maxX, minY, maxY;
|
|
1337
|
+
if (panType === 'centerContent') {
|
|
1338
|
+
minX = dWidth / 2 - (width + x) * zoom;
|
|
1339
|
+
minY = dHeight / 2 - (height + y) * zoom;
|
|
1340
|
+
maxX = dWidth / 2 - x * zoom;
|
|
1341
|
+
maxY = dHeight / 2 - y * zoom;
|
|
1342
|
+
}
|
|
1343
|
+
else {
|
|
1344
|
+
// panType equals fixed
|
|
1345
|
+
const zoomRatio = zoom / minZoom;
|
|
1346
|
+
// Find left corner of the content at min zoom and content is centered
|
|
1347
|
+
const minZoomX = (dWidth - width * minZoom) / 2 - x * minZoom;
|
|
1348
|
+
const minZoomY = (dHeight - height * minZoom) / 2 - y * minZoom;
|
|
1349
|
+
// When we pan all the way to the right, the left corner of displayable area is 0,0 as in min zoom.
|
|
1350
|
+
// When we pan all the way to the left, lets find the corner of the displayable area
|
|
1351
|
+
const leftCornerX = dWidth - dWidth * zoomRatio;
|
|
1352
|
+
const leftCornerY = dHeight - dHeight * zoomRatio;
|
|
1353
|
+
// Now we have everything to calculate pan zoom constraints
|
|
1354
|
+
minX = leftCornerX + minZoomX * zoomRatio;
|
|
1355
|
+
minY = leftCornerY + minZoomY * zoomRatio;
|
|
1356
|
+
maxX = minZoomX * zoomRatio;
|
|
1357
|
+
maxY = minZoomY * zoomRatio;
|
|
1358
|
+
}
|
|
1359
|
+
const initZoom = initPanZoomState.zoom;
|
|
1360
|
+
const initCenterX = initPanZoomState.centerX;
|
|
1361
|
+
const initCenterY = initPanZoomState.centerY;
|
|
1362
|
+
// If an initial panZoomState is set, should expand pan bounds to include it
|
|
1363
|
+
let dx, dy;
|
|
1364
|
+
if (initCenterX) {
|
|
1365
|
+
const boundsX = initCenterX * initZoom - dWidth / 2;
|
|
1366
|
+
if (-boundsX * initZoom < minX) {
|
|
1367
|
+
dx = minX - boundsX * initZoom;
|
|
1368
|
+
minX -= dx;
|
|
1369
|
+
maxX += dx;
|
|
1370
|
+
}
|
|
1371
|
+
else if (-boundsX * initZoom > maxX) {
|
|
1372
|
+
dx = -boundsX * initZoom - maxX;
|
|
1373
|
+
minX -= dx;
|
|
1374
|
+
maxX += dx;
|
|
1375
|
+
}
|
|
1376
|
+
}
|
|
1377
|
+
if (initCenterY) {
|
|
1378
|
+
const boundsY = initCenterY * initZoom - dHeight / 2;
|
|
1379
|
+
if (-boundsY * initZoom < minY) {
|
|
1380
|
+
dy = minY - boundsY * initZoom;
|
|
1381
|
+
minY -= dy;
|
|
1382
|
+
maxY += dy;
|
|
1383
|
+
}
|
|
1384
|
+
else if (-boundsY * initZoom > maxY) {
|
|
1385
|
+
dy = -boundsY * initZoom - maxY;
|
|
1386
|
+
minY -= dy;
|
|
1387
|
+
maxY += dy;
|
|
1388
|
+
}
|
|
1389
|
+
}
|
|
1390
|
+
return {
|
|
1391
|
+
minX: minX,
|
|
1392
|
+
maxX: maxX,
|
|
1393
|
+
minY: minY,
|
|
1394
|
+
maxY: maxY
|
|
1395
|
+
};
|
|
1396
|
+
};
|
|
1397
|
+
/**
|
|
1398
|
+
* Returns the pan properties for the diagram.
|
|
1399
|
+
*/
|
|
1400
|
+
function getPanProps(props, contentBounds, userDragMode, isDeviceTouch) {
|
|
1401
|
+
return {
|
|
1402
|
+
panning: isDeviceTouch
|
|
1403
|
+
? userDragMode === 'pan' && props.panning
|
|
1404
|
+
? props.panning
|
|
1405
|
+
: 'off'
|
|
1406
|
+
: props.panning
|
|
1407
|
+
? props.panning
|
|
1408
|
+
: 'off',
|
|
1409
|
+
panDirection: props.panDirection ? props.panDirection : 'any',
|
|
1410
|
+
centerX: props.centerX !== undefined ? props.centerX : contentBounds.width / 2,
|
|
1411
|
+
centerY: props.centerY !== undefined ? props.centerY : contentBounds.height / 2,
|
|
1412
|
+
onPan: props.onPan
|
|
1413
|
+
};
|
|
1414
|
+
}
|
|
1415
|
+
/**
|
|
1416
|
+
* Converts centerX,Y coordinates to panX,Y coordinates
|
|
1417
|
+
*/
|
|
1418
|
+
function centerXYToPanXY(centerX, centerY, zoom, width, height) {
|
|
1419
|
+
return {
|
|
1420
|
+
panX: width / 2 - centerX * zoom,
|
|
1421
|
+
panY: height / 2 - centerY * zoom
|
|
1422
|
+
};
|
|
1423
|
+
}
|
|
1424
|
+
/**
|
|
1425
|
+
* Converts panX,Y coordinates to centerX,Y coordinates
|
|
1426
|
+
*/
|
|
1427
|
+
function panXYToCenterXY(panX, panY, zoom, width, height) {
|
|
1428
|
+
return {
|
|
1429
|
+
centerX: (width / 2 - panX) / zoom,
|
|
1430
|
+
centerY: (height / 2 - panY) / zoom
|
|
1431
|
+
};
|
|
1432
|
+
}
|
|
1433
|
+
|
|
1434
|
+
function DiagramPanZoomContainer({ centerX, centerY, children, zoom, width, height }) {
|
|
1435
|
+
const panValues = centerXYToPanXY(centerX, centerY, zoom, width, height);
|
|
1436
|
+
return (jsx("div", { class: panZoomStyles, style: {
|
|
1437
|
+
//TODO JET-62471 look at using matrices or both in transform instead
|
|
1438
|
+
translate: `${panValues.panX}px ${panValues.panY}px`,
|
|
1439
|
+
transform: `scale(${zoom})`
|
|
1440
|
+
}, children: children }));
|
|
1441
|
+
}
|
|
1442
|
+
|
|
1443
|
+
/**
|
|
1444
|
+
* @license
|
|
1445
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
1446
|
+
* The Universal Permissive License (UPL), Version 1.0
|
|
1447
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
1448
|
+
* @ignore
|
|
1449
|
+
*/
|
|
1450
|
+
/**
|
|
1451
|
+
* Returns the link data based on link info in a diagram.
|
|
1452
|
+
* @param itemInfo
|
|
1453
|
+
* @returns
|
|
1454
|
+
*/
|
|
1455
|
+
function getLinkDetailFromInfo(itemInfo, links, promotedLinks) {
|
|
1456
|
+
let link;
|
|
1457
|
+
for (let i = 0; i < links.length; i++) {
|
|
1458
|
+
link = links[i];
|
|
1459
|
+
if (itemInfo.id === link.id) {
|
|
1460
|
+
return link;
|
|
1461
|
+
}
|
|
1462
|
+
}
|
|
1463
|
+
for (let i = 0; i < promotedLinks.length; i++) {
|
|
1464
|
+
link = promotedLinks[i];
|
|
1465
|
+
if (comparePromotedLinks(itemInfo.id, link)) {
|
|
1466
|
+
return link;
|
|
1467
|
+
}
|
|
1468
|
+
}
|
|
1469
|
+
return undefined;
|
|
1470
|
+
}
|
|
1471
|
+
/**
|
|
1472
|
+
* Utility method that adds sorting attributes of each link to an array
|
|
1473
|
+
*/
|
|
1474
|
+
function addSortingAttributes(node, listOfLinks, nodes, nodeBounds) {
|
|
1475
|
+
let angle, distance, direction;
|
|
1476
|
+
const linkDetail = [];
|
|
1477
|
+
for (let i = 0; i < listOfLinks.length; i++) {
|
|
1478
|
+
const link = listOfLinks[i];
|
|
1479
|
+
angle = _getClockwiseAngle(node, link, nodes, nodeBounds);
|
|
1480
|
+
distance = _getNodesDistance(link, nodes, nodeBounds);
|
|
1481
|
+
direction = _getLinkDirection(node, link);
|
|
1482
|
+
if ('id' in link)
|
|
1483
|
+
linkDetail.push({
|
|
1484
|
+
id: link.id,
|
|
1485
|
+
angle: angle,
|
|
1486
|
+
distance: distance,
|
|
1487
|
+
direction: direction,
|
|
1488
|
+
type: 'link'
|
|
1489
|
+
});
|
|
1490
|
+
else {
|
|
1491
|
+
linkDetail.push({
|
|
1492
|
+
id: getPromotedString(link),
|
|
1493
|
+
angle: angle,
|
|
1494
|
+
distance: distance,
|
|
1495
|
+
direction: direction,
|
|
1496
|
+
type: 'promotedLink'
|
|
1497
|
+
});
|
|
1498
|
+
}
|
|
1499
|
+
}
|
|
1500
|
+
return linkDetail;
|
|
1501
|
+
}
|
|
1502
|
+
/**
|
|
1503
|
+
* Returns a function that compares two link around a given node
|
|
1504
|
+
* The links are analyzed by angle, distance from the node and direction. The sorting attributes are added to the links before sorting.
|
|
1505
|
+
*/
|
|
1506
|
+
function getLinkComparator() {
|
|
1507
|
+
return (link1, link2) => {
|
|
1508
|
+
const { angle: linkAngle1, distance: linkDistance1, direction: linkDirection1 } = link1;
|
|
1509
|
+
const { angle: linkAngle2, distance: linkDistance2, direction: linkDirection2 } = link2;
|
|
1510
|
+
let res = -1;
|
|
1511
|
+
if (!_anglesAreEqualWithinTolerance(linkAngle1, linkAngle2) && linkAngle1 > linkAngle2) {
|
|
1512
|
+
res = 1;
|
|
1513
|
+
}
|
|
1514
|
+
else if (_anglesAreEqualWithinTolerance(linkAngle1, linkAngle2)) {
|
|
1515
|
+
//check distance and direction
|
|
1516
|
+
if (linkDistance1 > linkDistance2) {
|
|
1517
|
+
res = 1;
|
|
1518
|
+
}
|
|
1519
|
+
else if (linkDistance2 == linkDistance1 && linkDirection1 > linkDirection2) {
|
|
1520
|
+
//outgoing to ingoing
|
|
1521
|
+
res = 1;
|
|
1522
|
+
}
|
|
1523
|
+
else if (linkDistance2 == linkDistance1 && linkDirection1 == linkDirection2) {
|
|
1524
|
+
res = 0;
|
|
1525
|
+
}
|
|
1526
|
+
}
|
|
1527
|
+
return res;
|
|
1528
|
+
};
|
|
1529
|
+
}
|
|
1530
|
+
/**
|
|
1531
|
+
* Returns navigable links for a given node
|
|
1532
|
+
*/
|
|
1533
|
+
function getNavigableLinksForNodeId(nodeId, listOfLinks) {
|
|
1534
|
+
const links = [];
|
|
1535
|
+
listOfLinks.forEach((link) => {
|
|
1536
|
+
const startId = link.startNode;
|
|
1537
|
+
const endId = link.endNode;
|
|
1538
|
+
if (startId == nodeId || endId == nodeId)
|
|
1539
|
+
links.push(link);
|
|
1540
|
+
});
|
|
1541
|
+
return links;
|
|
1542
|
+
}
|
|
1543
|
+
/**
|
|
1544
|
+
* Get the clockwise angle for the link given node as a center
|
|
1545
|
+
*/
|
|
1546
|
+
function _getClockwiseAngle(node, link, nodes, nodeBounds) {
|
|
1547
|
+
//find opposite node
|
|
1548
|
+
let currNode;
|
|
1549
|
+
let startNode = nodes[0];
|
|
1550
|
+
let endNode = nodes[0];
|
|
1551
|
+
for (let i = 0; i < nodes.length; i++) {
|
|
1552
|
+
currNode = nodes[i];
|
|
1553
|
+
if (currNode.id === link.startNode) {
|
|
1554
|
+
startNode = currNode;
|
|
1555
|
+
}
|
|
1556
|
+
else if (currNode.id === link.endNode) {
|
|
1557
|
+
endNode = currNode;
|
|
1558
|
+
}
|
|
1559
|
+
}
|
|
1560
|
+
const oppositeNode = node.id == startNode.id ? endNode : startNode;
|
|
1561
|
+
const p1 = _getNodeCenter(node, nodeBounds);
|
|
1562
|
+
const p2 = _getNodeCenter(oppositeNode, nodeBounds);
|
|
1563
|
+
let angle = Math.atan2(p2.y - p1.y, p2.x - p1.x);
|
|
1564
|
+
angle = angle < 0 ? angle + Math.PI * 2 : angle;
|
|
1565
|
+
return angle;
|
|
1566
|
+
}
|
|
1567
|
+
/**
|
|
1568
|
+
* Get the distance between start and end nodes for the given link
|
|
1569
|
+
*/
|
|
1570
|
+
function _getNodesDistance(link, nodes, nodeBounds) {
|
|
1571
|
+
let currNode;
|
|
1572
|
+
let startNode = nodes[0];
|
|
1573
|
+
let endNode = nodes[0];
|
|
1574
|
+
for (let i = 0; i < nodes.length; i++) {
|
|
1575
|
+
currNode = nodes[i];
|
|
1576
|
+
if (currNode.id === link.startNode) {
|
|
1577
|
+
startNode = currNode;
|
|
1578
|
+
}
|
|
1579
|
+
else if (currNode.id === link.endNode) {
|
|
1580
|
+
endNode = currNode;
|
|
1581
|
+
}
|
|
1582
|
+
}
|
|
1583
|
+
const p1 = _getNodeCenter(startNode, nodeBounds);
|
|
1584
|
+
const p2 = _getNodeCenter(endNode, nodeBounds);
|
|
1585
|
+
return Math.sqrt(Math.pow(p2.x - p1.x, 2) + Math.pow(p2.y - p1.y, 2));
|
|
1586
|
+
}
|
|
1587
|
+
/**
|
|
1588
|
+
* Get link direction for the given node. 1 if the node is the end node
|
|
1589
|
+
* and 0 if it is the start node
|
|
1590
|
+
*/
|
|
1591
|
+
function _getLinkDirection(node, link) {
|
|
1592
|
+
if (link.endNode === node.id) {
|
|
1593
|
+
return 1;
|
|
1594
|
+
}
|
|
1595
|
+
return 0;
|
|
1596
|
+
}
|
|
1597
|
+
/**
|
|
1598
|
+
* Get node center
|
|
1599
|
+
*/
|
|
1600
|
+
function _getNodeCenter(node, nodeBounds) {
|
|
1601
|
+
const nodeBB = nodeBounds.get(node.id);
|
|
1602
|
+
return { x: nodeBB.x + nodeBB.width / 2, y: nodeBB.y + nodeBB.height / 2 };
|
|
1603
|
+
}
|
|
1604
|
+
/**
|
|
1605
|
+
* Calculates the angle weighted by distance
|
|
1606
|
+
*/
|
|
1607
|
+
function calcDistanceAngleWeighted(objectBB, currentBB, direction) {
|
|
1608
|
+
// Variables used for calculating penalties when calculating distances between two navigables.
|
|
1609
|
+
const optimalAngle1 = (15 / 180) * Math.PI;
|
|
1610
|
+
const optimalAngle2 = (40 / 180) * Math.PI;
|
|
1611
|
+
const suboptimalAnglePenalty1 = 2; // multiplier to the distance
|
|
1612
|
+
const suboptimalAnglePenalty2 = 6; // multiplier to the distance
|
|
1613
|
+
const objCenterX = objectBB.x + objectBB.width / 2;
|
|
1614
|
+
const objCenterY = objectBB.y + objectBB.height / 2;
|
|
1615
|
+
const curCenterX = currentBB.x + currentBB.width / 2;
|
|
1616
|
+
const curCenterY = currentBB.y + currentBB.height / 2;
|
|
1617
|
+
const x_dist = Math.abs(objCenterX - curCenterX);
|
|
1618
|
+
const y_dist = Math.abs(objCenterY - curCenterY);
|
|
1619
|
+
const angle = Math.atan2(y_dist, x_dist);
|
|
1620
|
+
let distance = Math.sqrt(x_dist * x_dist + y_dist * y_dist);
|
|
1621
|
+
// Angle penalty based on direction
|
|
1622
|
+
if ((angle > optimalAngle1 && (direction == 'right' || direction == 'left')) ||
|
|
1623
|
+
(angle < Math.PI / 2 - optimalAngle1 && (direction == 'up' || direction == 'down'))) {
|
|
1624
|
+
if ((angle > optimalAngle2 && (direction == 'right' || direction == 'left')) ||
|
|
1625
|
+
(angle < Math.PI / 2 - optimalAngle2 && (direction == 'up' || direction == 'down'))) {
|
|
1626
|
+
distance *= suboptimalAnglePenalty2;
|
|
1627
|
+
}
|
|
1628
|
+
else {
|
|
1629
|
+
distance *= suboptimalAnglePenalty1;
|
|
1630
|
+
}
|
|
1631
|
+
}
|
|
1632
|
+
return distance;
|
|
1633
|
+
}
|
|
1634
|
+
/**
|
|
1635
|
+
* Given a direction, is a certain node is a valid destination to navigate to
|
|
1636
|
+
*/
|
|
1637
|
+
function isValidDestination(objBB, curBB, direction, compareCenters) {
|
|
1638
|
+
// compare the centers of the navigable and to be valid, the navigable must be in the right direction
|
|
1639
|
+
// without tolerance
|
|
1640
|
+
if (compareCenters) {
|
|
1641
|
+
const objCenterX = objBB.x + 0.5 * objBB.width;
|
|
1642
|
+
const curCenterX = curBB.x + 0.5 * curBB.width;
|
|
1643
|
+
const objCenterY = objBB.y + 0.5 * objBB.height;
|
|
1644
|
+
const curCenterY = curBB.y + 0.5 * curBB.height;
|
|
1645
|
+
switch (direction) {
|
|
1646
|
+
case 'up':
|
|
1647
|
+
return objCenterY < curCenterY;
|
|
1648
|
+
case 'down':
|
|
1649
|
+
return objBB.y > curCenterY;
|
|
1650
|
+
case 'right':
|
|
1651
|
+
return objCenterX > curCenterX;
|
|
1652
|
+
case 'left':
|
|
1653
|
+
return objCenterX < curCenterX;
|
|
1654
|
+
}
|
|
1655
|
+
return true;
|
|
1656
|
+
}
|
|
1657
|
+
switch (direction) {
|
|
1658
|
+
case 'up':
|
|
1659
|
+
return objBB.y < curBB.y || _areEqualWithinTolerance(objBB.y, curBB.y);
|
|
1660
|
+
case 'down':
|
|
1661
|
+
return objBB.y > curBB.y || _areEqualWithinTolerance(objBB.y, curBB.y);
|
|
1662
|
+
case 'right':
|
|
1663
|
+
return objBB.x > curBB.x || _areEqualWithinTolerance(objBB.x, curBB.x);
|
|
1664
|
+
case 'left':
|
|
1665
|
+
return objBB.x < curBB.x || _areEqualWithinTolerance(objBB.x, curBB.x);
|
|
1666
|
+
}
|
|
1667
|
+
return true;
|
|
1668
|
+
}
|
|
1669
|
+
/**
|
|
1670
|
+
* Returns true if two nodes are in contact
|
|
1671
|
+
*/
|
|
1672
|
+
function calcInContact(objRect, curRect, direction) {
|
|
1673
|
+
switch (direction) {
|
|
1674
|
+
case 'up':
|
|
1675
|
+
return (_isVerticallyAligned(objRect, curRect) &&
|
|
1676
|
+
(curRect.y <= objRect.y + objRect.height ||
|
|
1677
|
+
_areEqualWithinTolerance(curRect.y, objRect.y + objRect.height)));
|
|
1678
|
+
case 'down':
|
|
1679
|
+
return (_isVerticallyAligned(objRect, curRect) &&
|
|
1680
|
+
(objRect.y <= curRect.y + curRect.height ||
|
|
1681
|
+
_areEqualWithinTolerance(objRect.y, curRect.y + curRect.height)));
|
|
1682
|
+
case 'right':
|
|
1683
|
+
return (_isHorizontallyAligned(objRect, curRect) &&
|
|
1684
|
+
(objRect.x <= curRect.x + curRect.width ||
|
|
1685
|
+
_areEqualWithinTolerance(objRect.x, curRect.x + curRect.width)));
|
|
1686
|
+
case 'left':
|
|
1687
|
+
return (_isHorizontallyAligned(objRect, curRect) &&
|
|
1688
|
+
(curRect.x <= objRect.x + objRect.width ||
|
|
1689
|
+
_areEqualWithinTolerance(curRect.x, objRect.x + objRect.width)));
|
|
1690
|
+
}
|
|
1691
|
+
return false;
|
|
1692
|
+
}
|
|
1693
|
+
function _isVerticallyAligned(rect1, rect2) {
|
|
1694
|
+
return ((rect1.x >= rect2.x && rect1.x <= rect2.x + rect2.width) ||
|
|
1695
|
+
(rect2.x >= rect1.x && rect2.x <= rect1.x + rect1.width));
|
|
1696
|
+
}
|
|
1697
|
+
function _isHorizontallyAligned(rect1, rect2) {
|
|
1698
|
+
return ((rect1.y >= rect2.y && rect1.y <= rect2.y + rect2.height) ||
|
|
1699
|
+
(rect2.y >= rect1.y && rect2.y <= rect1.y + rect1.height));
|
|
1700
|
+
}
|
|
1701
|
+
function _areEqualWithinTolerance(a, b) {
|
|
1702
|
+
return Math.abs(a - b) <= 0.0000001;
|
|
1703
|
+
}
|
|
1704
|
+
function _anglesAreEqualWithinTolerance(a1, a2) {
|
|
1705
|
+
let res = Math.abs(a1 - a2) <= 0.0000001;
|
|
1706
|
+
if (!res) {
|
|
1707
|
+
res = Math.abs(Math.PI * 2 + Math.min(a1, a2) - Math.max(a1, a2)) <= 0.0000001;
|
|
1708
|
+
}
|
|
1709
|
+
return res;
|
|
1710
|
+
}
|
|
1711
|
+
|
|
1712
|
+
/**
|
|
1713
|
+
* @license
|
|
1714
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
1715
|
+
* The Universal Permissive License (UPL), Version 1.0
|
|
1716
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
1717
|
+
* @ignore
|
|
1718
|
+
*/
|
|
1719
|
+
function useDiagramNavigation(bounds, linkIdToDataMap, promotedLinkMap, nodeIdToDataMap) {
|
|
1720
|
+
const currentKeyboardFocusNode = useRef();
|
|
1721
|
+
const nodeBoundsById = bounds;
|
|
1722
|
+
function getNextNavigableNode(direction, compareCenters, current, listOfObjects) {
|
|
1723
|
+
if (!listOfObjects)
|
|
1724
|
+
return current;
|
|
1725
|
+
if (!current)
|
|
1726
|
+
return listOfObjects[0];
|
|
1727
|
+
const currBB = nodeBoundsById.get(current.id);
|
|
1728
|
+
if (!currBB)
|
|
1729
|
+
return listOfObjects[0];
|
|
1730
|
+
let nextObject = current; //init to current object
|
|
1731
|
+
let nextDistance = Number.MAX_VALUE;
|
|
1732
|
+
// If an object is in contact it overrules all other attributes
|
|
1733
|
+
// Only another in contact object with better attributes will have higher precedence
|
|
1734
|
+
let nextInContact = false;
|
|
1735
|
+
// Whether or not the for loop has encountered the current object
|
|
1736
|
+
let hasFoundCurrent = false;
|
|
1737
|
+
let object, inContact, distance;
|
|
1738
|
+
for (let i = 0; i < listOfObjects.length; i++) {
|
|
1739
|
+
object = listOfObjects[i];
|
|
1740
|
+
if (object === current) {
|
|
1741
|
+
hasFoundCurrent = true;
|
|
1742
|
+
continue;
|
|
1743
|
+
}
|
|
1744
|
+
const objBB = nodeBoundsById.get(object.id);
|
|
1745
|
+
if (!objBB)
|
|
1746
|
+
continue;
|
|
1747
|
+
const objBounds = { x: objBB.x, y: objBB.y, width: objBB.width, height: objBB.height };
|
|
1748
|
+
const currBounds = { x: currBB.x, y: currBB.y, width: currBB.width, height: currBB.height };
|
|
1749
|
+
if (!isValidDestination(objBounds, currBounds, direction, compareCenters))
|
|
1750
|
+
continue;
|
|
1751
|
+
inContact = calcInContact(objBounds, currBounds, direction);
|
|
1752
|
+
if (nextInContact && !inContact)
|
|
1753
|
+
continue;
|
|
1754
|
+
distance = calcDistanceAngleWeighted(objBounds, currBounds, direction);
|
|
1755
|
+
if (distance == 0 && !hasFoundCurrent)
|
|
1756
|
+
continue;
|
|
1757
|
+
// Make sure incontact flag have highest precedence
|
|
1758
|
+
if ((!nextInContact && inContact) ||
|
|
1759
|
+
(distance < nextDistance && ((nextInContact && inContact) || !nextInContact))) {
|
|
1760
|
+
nextDistance = distance;
|
|
1761
|
+
nextObject = object;
|
|
1762
|
+
nextInContact = inContact;
|
|
1763
|
+
}
|
|
1764
|
+
}
|
|
1765
|
+
return nextObject;
|
|
1766
|
+
}
|
|
1767
|
+
/**
|
|
1768
|
+
* Get next navigavle link depending on direction - clockwise or conter clockwise.
|
|
1769
|
+
* The decision is made based on location of nodes centers rather than link paths or link angles.
|
|
1770
|
+
*/
|
|
1771
|
+
function getNextNavigableLink(direction, listOfNodes, currentLink, listOfLinks, promotedLinks) {
|
|
1772
|
+
if (!(listOfLinks || promotedLinks))
|
|
1773
|
+
return currentLink;
|
|
1774
|
+
const allLinks = listOfLinks && promotedLinks
|
|
1775
|
+
? [...listOfLinks, ...promotedLinks]
|
|
1776
|
+
: (listOfLinks ? listOfLinks : promotedLinks);
|
|
1777
|
+
if (!currentLink)
|
|
1778
|
+
return allLinks[0];
|
|
1779
|
+
const keyboardFocusNode = currentKeyboardFocusNode.current;
|
|
1780
|
+
const nodeId = keyboardFocusNode ? keyboardFocusNode : currentLink.startNode;
|
|
1781
|
+
const node = nodeIdToDataMap.get(nodeId);
|
|
1782
|
+
if (!node)
|
|
1783
|
+
return currentLink;
|
|
1784
|
+
const adjLinks = getNavigableLinksForNodeId(node.id, allLinks);
|
|
1785
|
+
const linksWithSortingAttributes = addSortingAttributes(node, adjLinks, listOfNodes, nodeBoundsById);
|
|
1786
|
+
linksWithSortingAttributes.sort(getLinkComparator());
|
|
1787
|
+
//clockwise direction
|
|
1788
|
+
const bForward = direction == 'down' ? true : false;
|
|
1789
|
+
let index = 0;
|
|
1790
|
+
for (let i = 0; i < linksWithSortingAttributes.length; i++) {
|
|
1791
|
+
const id = 'id' in currentLink ? currentLink.id : getPromotedString(currentLink);
|
|
1792
|
+
const link = linksWithSortingAttributes[i];
|
|
1793
|
+
if (link.id === id) {
|
|
1794
|
+
if (bForward)
|
|
1795
|
+
index = i == linksWithSortingAttributes.length - 1 ? 0 : i + 1;
|
|
1796
|
+
else
|
|
1797
|
+
index = i == 0 ? linksWithSortingAttributes.length - 1 : i - 1;
|
|
1798
|
+
break;
|
|
1799
|
+
}
|
|
1800
|
+
}
|
|
1801
|
+
if (linksWithSortingAttributes[index].type === 'link') {
|
|
1802
|
+
return linkIdToDataMap.get(linksWithSortingAttributes[index].id);
|
|
1803
|
+
}
|
|
1804
|
+
return promotedLinkMap.get(linksWithSortingAttributes[index].id);
|
|
1805
|
+
}
|
|
1806
|
+
/**
|
|
1807
|
+
* Returns the link detail when a node to link navigation occurs
|
|
1808
|
+
*/
|
|
1809
|
+
function navigateFromNodeToLink(listOfLinks, promotedLinks, event, node) {
|
|
1810
|
+
if (!node)
|
|
1811
|
+
return undefined;
|
|
1812
|
+
const adjLinks = getNavigableLinksForNodeId(node.id, [...listOfLinks, ...promotedLinks]);
|
|
1813
|
+
if (adjLinks.length < 1)
|
|
1814
|
+
return undefined;
|
|
1815
|
+
let link = adjLinks[0];
|
|
1816
|
+
const nodeBB = nodeBoundsById.get(node.id);
|
|
1817
|
+
let object, currNode, currNodeBB, currNodeBBCenterX;
|
|
1818
|
+
const nodeCenterX = nodeBB.x + nodeBB.width / 2;
|
|
1819
|
+
currentKeyboardFocusNode.current = node.id;
|
|
1820
|
+
for (let i = 0; i < adjLinks.length; i++) {
|
|
1821
|
+
object = adjLinks[i];
|
|
1822
|
+
currNode = object.startNode === node.id ? object.endNode : object.startNode;
|
|
1823
|
+
currNodeBB = nodeBoundsById.get(currNode);
|
|
1824
|
+
currNodeBBCenterX = currNodeBB.x + currNodeBB.width / 2;
|
|
1825
|
+
if (
|
|
1826
|
+
// equivalent of ≤ and ≥
|
|
1827
|
+
(event.altKey && event.code === 'Comma' && currNodeBBCenterX <= nodeCenterX) ||
|
|
1828
|
+
(event.altKey && event.code === 'Period' && currNodeBBCenterX >= nodeCenterX)) {
|
|
1829
|
+
link = object;
|
|
1830
|
+
break;
|
|
1831
|
+
}
|
|
1832
|
+
}
|
|
1833
|
+
return (isPromoted(link) ? { id: link, type: 'promotedLink' } : { id: link.id, type: 'link' });
|
|
1834
|
+
}
|
|
1835
|
+
/**
|
|
1836
|
+
* Returns the node detail when a link to node navigation occurs
|
|
1837
|
+
*/
|
|
1838
|
+
function navigateFromLinkToNode(startNode, endNode, event) {
|
|
1839
|
+
const key = event.key;
|
|
1840
|
+
const startNodeBB = nodeBoundsById.get(startNode);
|
|
1841
|
+
const endNodeBB = nodeBoundsById.get(endNode);
|
|
1842
|
+
if (!startNodeBB || !endNodeBB)
|
|
1843
|
+
return undefined;
|
|
1844
|
+
const startNodeCenterX = startNodeBB.x + startNodeBB.width / 2;
|
|
1845
|
+
const endNodeCenterX = endNodeBB.x + endNodeBB.width / 2;
|
|
1846
|
+
const newNode = (endNodeCenterX > startNodeCenterX && key === 'ArrowRight') ||
|
|
1847
|
+
(endNodeCenterX < startNodeCenterX && key === 'ArrowLeft')
|
|
1848
|
+
? endNode
|
|
1849
|
+
: startNode;
|
|
1850
|
+
return { id: newNode, type: 'node' };
|
|
1851
|
+
}
|
|
1852
|
+
return {
|
|
1853
|
+
getNextNavigableNode,
|
|
1854
|
+
getNextNavigableLink,
|
|
1855
|
+
navigateFromNodeToLink,
|
|
1856
|
+
navigateFromLinkToNode
|
|
1857
|
+
};
|
|
1858
|
+
}
|
|
1859
|
+
|
|
1860
|
+
const DEFAULT_KB_PAN = 15;
|
|
1861
|
+
const DEFAULT_KB_ZOOM = 0.15;
|
|
1862
|
+
function useEvents(touchResponse, initNode, nodes, links, promotedLinks, nodeBounds, linkIdToDataMap, nodeIdToDataMap, width, height, maxZoom, expanded, itemIdToParentMap, promotedLinkMap, onItemHover, onItemFocus, kbPanCallback, kbZoomCallback, onExpandedChange) {
|
|
1863
|
+
const { getNextNavigableNode, getNextNavigableLink, navigateFromNodeToLink, navigateFromLinkToNode } = useDiagramNavigation(nodeBounds, linkIdToDataMap, promotedLinkMap, nodeIdToDataMap);
|
|
1864
|
+
const [focusedItemInfo, setfocusedItemInfo] = useState({
|
|
1865
|
+
id: initNode.id,
|
|
1866
|
+
type: 'node'
|
|
1867
|
+
});
|
|
1868
|
+
const [hoveredItemInfo, sethoveredItemInfo] = useState();
|
|
1869
|
+
const activeId = useRef();
|
|
1870
|
+
const cancelEvent = (event) => {
|
|
1871
|
+
event.preventDefault();
|
|
1872
|
+
event.stopPropagation();
|
|
1873
|
+
};
|
|
1874
|
+
const keyDownHandler = (event) => {
|
|
1875
|
+
const key = event.key;
|
|
1876
|
+
let eventConsumed = false;
|
|
1877
|
+
// tabbing out of the diagram
|
|
1878
|
+
if (key === 'TAB') {
|
|
1879
|
+
return;
|
|
1880
|
+
}
|
|
1881
|
+
// if this a switch from node to link or vice versa
|
|
1882
|
+
if (isChangeItemType(event)) {
|
|
1883
|
+
let nextItemInfo;
|
|
1884
|
+
if (focusedItemInfo.type === 'node') {
|
|
1885
|
+
nextItemInfo = navigateFromNodeToLink(links, promotedLinks, event, nodeIdToDataMap.get(focusedItemInfo.id));
|
|
1886
|
+
}
|
|
1887
|
+
else if (focusedItemInfo.type === 'link') {
|
|
1888
|
+
const data = linkIdToDataMap.get(focusedItemInfo.id);
|
|
1889
|
+
nextItemInfo = navigateFromLinkToNode(data.startNode, data.endNode, event);
|
|
1890
|
+
}
|
|
1891
|
+
else {
|
|
1892
|
+
// promoted link
|
|
1893
|
+
const id = focusedItemInfo.id;
|
|
1894
|
+
nextItemInfo = navigateFromLinkToNode(id.startNode, id.endNode, event);
|
|
1895
|
+
}
|
|
1896
|
+
handleKeyboardInput(nextItemInfo);
|
|
1897
|
+
eventConsumed = true;
|
|
1898
|
+
}
|
|
1899
|
+
else if (isNavigationEvent(key)) {
|
|
1900
|
+
const nextItemInfo = handleKeyboardNavigationEvent(key);
|
|
1901
|
+
handleKeyboardInput(nextItemInfo);
|
|
1902
|
+
eventConsumed = true;
|
|
1903
|
+
}
|
|
1904
|
+
else {
|
|
1905
|
+
switch (key) {
|
|
1906
|
+
case 'PageUp': {
|
|
1907
|
+
kbPanCallback &&
|
|
1908
|
+
kbPanCallback({
|
|
1909
|
+
dPan: {
|
|
1910
|
+
dx: event.shiftKey ? -DEFAULT_KB_PAN : 0,
|
|
1911
|
+
dy: event.shiftKey ? 0 : -DEFAULT_KB_PAN
|
|
1912
|
+
}
|
|
1913
|
+
});
|
|
1914
|
+
eventConsumed = true;
|
|
1915
|
+
break;
|
|
1916
|
+
}
|
|
1917
|
+
case 'PageDown': {
|
|
1918
|
+
kbPanCallback &&
|
|
1919
|
+
kbPanCallback({
|
|
1920
|
+
dPan: {
|
|
1921
|
+
dx: event.shiftKey ? DEFAULT_KB_PAN : 0,
|
|
1922
|
+
dy: event.shiftKey ? 0 : DEFAULT_KB_PAN
|
|
1923
|
+
}
|
|
1924
|
+
});
|
|
1925
|
+
eventConsumed = true;
|
|
1926
|
+
break;
|
|
1927
|
+
}
|
|
1928
|
+
case '+':
|
|
1929
|
+
case '=': {
|
|
1930
|
+
kbZoomCallback && kbZoomCallback({ dZoom: DEFAULT_KB_ZOOM });
|
|
1931
|
+
eventConsumed = true;
|
|
1932
|
+
break;
|
|
1933
|
+
}
|
|
1934
|
+
case '-':
|
|
1935
|
+
case '_': {
|
|
1936
|
+
kbZoomCallback && kbZoomCallback({ dZoom: -DEFAULT_KB_ZOOM });
|
|
1937
|
+
eventConsumed = true;
|
|
1938
|
+
break;
|
|
1939
|
+
}
|
|
1940
|
+
case '0': {
|
|
1941
|
+
if (event.ctrlKey && event.altKey) {
|
|
1942
|
+
const { centerX, centerY, zoom } = zoomAndCenterItemFromInfo(focusedItemInfo, linkIdToDataMap, nodeBounds, width, height, maxZoom);
|
|
1943
|
+
kbZoomCallback && kbZoomCallback({ nZoom: zoom });
|
|
1944
|
+
kbPanCallback && kbPanCallback({ nPan: { cx: centerX, cy: centerY } });
|
|
1945
|
+
}
|
|
1946
|
+
else {
|
|
1947
|
+
// zoom to fit
|
|
1948
|
+
kbZoomCallback && kbZoomCallback({});
|
|
1949
|
+
kbPanCallback && kbPanCallback({ center: true });
|
|
1950
|
+
}
|
|
1951
|
+
eventConsumed = true;
|
|
1952
|
+
break;
|
|
1953
|
+
}
|
|
1954
|
+
case ' ': {
|
|
1955
|
+
if (event.ctrlKey && event.shiftKey) {
|
|
1956
|
+
if (focusedItemInfo.type === 'node') {
|
|
1957
|
+
const id = focusedItemInfo.id;
|
|
1958
|
+
const newExpanded = changeExpanded(id, expanded);
|
|
1959
|
+
onExpandedChange && onExpandedChange({ expanded: newExpanded });
|
|
1960
|
+
}
|
|
1961
|
+
}
|
|
1962
|
+
break;
|
|
1963
|
+
}
|
|
1964
|
+
case '[': {
|
|
1965
|
+
if (focusedItemInfo.type === 'node') {
|
|
1966
|
+
const child = getChildInfo(focusedItemInfo.id, nodeIdToDataMap);
|
|
1967
|
+
if (child) {
|
|
1968
|
+
const item = { id: child.id, type: 'node' };
|
|
1969
|
+
handleKeyboardInput(item);
|
|
1970
|
+
}
|
|
1971
|
+
}
|
|
1972
|
+
eventConsumed = true;
|
|
1973
|
+
break;
|
|
1974
|
+
}
|
|
1975
|
+
case ']': {
|
|
1976
|
+
if (focusedItemInfo.type === 'node') {
|
|
1977
|
+
const parentId = itemIdToParentMap.get(focusedItemInfo.id);
|
|
1978
|
+
if (parentId) {
|
|
1979
|
+
const item = { id: parentId, type: 'node' };
|
|
1980
|
+
handleKeyboardInput(item);
|
|
1981
|
+
}
|
|
1982
|
+
}
|
|
1983
|
+
eventConsumed = true;
|
|
1984
|
+
break;
|
|
1985
|
+
}
|
|
1986
|
+
}
|
|
1987
|
+
}
|
|
1988
|
+
if (eventConsumed) {
|
|
1989
|
+
cancelEvent(event);
|
|
1990
|
+
}
|
|
1991
|
+
};
|
|
1992
|
+
const keyUpHandler = (event) => {
|
|
1993
|
+
const key = event.code;
|
|
1994
|
+
switch (key) {
|
|
1995
|
+
case 'Tab': {
|
|
1996
|
+
updatefocusedItemInfo({
|
|
1997
|
+
...focusedItemInfo,
|
|
1998
|
+
isCurrent: true,
|
|
1999
|
+
isFocusVisible: true
|
|
2000
|
+
});
|
|
2001
|
+
break;
|
|
2002
|
+
}
|
|
2003
|
+
}
|
|
2004
|
+
};
|
|
2005
|
+
const blurHandler = () => {
|
|
2006
|
+
if (hoveredItemInfo != null || focusedItemInfo.isCurrent) {
|
|
2007
|
+
onItemFocus?.(undefined);
|
|
2008
|
+
}
|
|
2009
|
+
const itemInfo = { ...focusedItemInfo, isCurrent: false, isFocusVisible: false };
|
|
2010
|
+
setfocusedItemInfo(itemInfo);
|
|
2011
|
+
};
|
|
2012
|
+
const onHover = (event) => {
|
|
2013
|
+
const itemInfo = getNavigableInfo(event.target, promotedLinkMap);
|
|
2014
|
+
if (itemInfo && !isEqualItem(itemInfo, hoveredItemInfo)) {
|
|
2015
|
+
sethoveredItemInfo({ ...itemInfo, isCurrent: true });
|
|
2016
|
+
activeId.current = getRandomId();
|
|
2017
|
+
setfocusedItemInfo({ ...focusedItemInfo, isCurrent: false });
|
|
2018
|
+
let detail;
|
|
2019
|
+
if (itemInfo.type === 'node') {
|
|
2020
|
+
detail = {
|
|
2021
|
+
id: itemInfo.id,
|
|
2022
|
+
type: 'node',
|
|
2023
|
+
data: nodeIdToDataMap.get(itemInfo.id)
|
|
2024
|
+
};
|
|
2025
|
+
}
|
|
2026
|
+
else if (itemInfo.type === 'link') {
|
|
2027
|
+
detail = {
|
|
2028
|
+
id: itemInfo.id,
|
|
2029
|
+
type: 'link',
|
|
2030
|
+
data: linkIdToDataMap.get(itemInfo.id)
|
|
2031
|
+
};
|
|
2032
|
+
}
|
|
2033
|
+
else if (itemInfo.type === 'promotedLink') {
|
|
2034
|
+
detail = {
|
|
2035
|
+
type: 'promotedLink',
|
|
2036
|
+
id: itemInfo.id
|
|
2037
|
+
};
|
|
2038
|
+
}
|
|
2039
|
+
onItemHover?.(detail);
|
|
2040
|
+
}
|
|
2041
|
+
};
|
|
2042
|
+
const onHoverLeave = () => {
|
|
2043
|
+
sethoveredItemInfo(undefined);
|
|
2044
|
+
activeId.current = undefined;
|
|
2045
|
+
onItemHover?.(undefined);
|
|
2046
|
+
};
|
|
2047
|
+
const hoverHandlers = useVisHover(onHover, undefined, onHoverLeave, touchResponse);
|
|
2048
|
+
const pointerUpHandler = (event) => {
|
|
2049
|
+
const itemInfo = getNavigableInfo(event.target, promotedLinkMap);
|
|
2050
|
+
if (itemInfo.id != null) {
|
|
2051
|
+
let buttonId;
|
|
2052
|
+
if (itemInfo.type === 'node') {
|
|
2053
|
+
buttonId = expCollapseButtonId(event.target);
|
|
2054
|
+
if (buttonId) {
|
|
2055
|
+
const newExpanded = changeExpanded(buttonId, expanded);
|
|
2056
|
+
onExpandedChange && onExpandedChange({ expanded: newExpanded });
|
|
2057
|
+
event.preventDefault();
|
|
2058
|
+
event.stopPropagation();
|
|
2059
|
+
return;
|
|
2060
|
+
}
|
|
2061
|
+
}
|
|
2062
|
+
setfocusedItemInfo(itemInfo);
|
|
2063
|
+
activeId.current = getRandomId();
|
|
2064
|
+
}
|
|
2065
|
+
};
|
|
2066
|
+
function updatefocusedItemInfo(itemInfo) {
|
|
2067
|
+
if (itemInfo.type === 'node') {
|
|
2068
|
+
onItemFocus?.({
|
|
2069
|
+
id: itemInfo.id,
|
|
2070
|
+
type: 'node',
|
|
2071
|
+
data: nodeIdToDataMap.get(itemInfo.id)
|
|
2072
|
+
});
|
|
2073
|
+
}
|
|
2074
|
+
else if (itemInfo.type === 'link') {
|
|
2075
|
+
onItemFocus?.({
|
|
2076
|
+
id: itemInfo.id,
|
|
2077
|
+
type: 'link',
|
|
2078
|
+
data: linkIdToDataMap.get(itemInfo.id)
|
|
2079
|
+
});
|
|
2080
|
+
}
|
|
2081
|
+
else if (itemInfo.type === 'promotedLink') {
|
|
2082
|
+
onItemFocus?.({
|
|
2083
|
+
id: itemInfo.id,
|
|
2084
|
+
type: 'promotedLink'
|
|
2085
|
+
});
|
|
2086
|
+
}
|
|
2087
|
+
activeId.current = getRandomId();
|
|
2088
|
+
setfocusedItemInfo(itemInfo);
|
|
2089
|
+
}
|
|
2090
|
+
function handleKeyboardInput(item) {
|
|
2091
|
+
if (!item)
|
|
2092
|
+
return;
|
|
2093
|
+
if (!isEqualItem(item, focusedItemInfo)) {
|
|
2094
|
+
item.isCurrent = true;
|
|
2095
|
+
item.isFocusVisible = true;
|
|
2096
|
+
if (hoveredItemInfo) {
|
|
2097
|
+
sethoveredItemInfo({ ...hoveredItemInfo, isCurrent: false });
|
|
2098
|
+
}
|
|
2099
|
+
updatefocusedItemInfo(item);
|
|
2100
|
+
}
|
|
2101
|
+
}
|
|
2102
|
+
function isNavigationEvent(key) {
|
|
2103
|
+
switch (key) {
|
|
2104
|
+
case 'ArrowDown':
|
|
2105
|
+
case 'ArrowUp':
|
|
2106
|
+
case 'ArrowRight':
|
|
2107
|
+
case 'ArrowLeft': {
|
|
2108
|
+
return true;
|
|
2109
|
+
}
|
|
2110
|
+
}
|
|
2111
|
+
return false;
|
|
2112
|
+
}
|
|
2113
|
+
function isChangeItemType(event) {
|
|
2114
|
+
const key = event.code;
|
|
2115
|
+
// check if switching from node to link
|
|
2116
|
+
// equivalent of ≤ and ≥
|
|
2117
|
+
if (focusedItemInfo.type === 'node' && event.altKey && (key === 'Period' || key === 'Comma')) {
|
|
2118
|
+
return true;
|
|
2119
|
+
// check if switching from link to node
|
|
2120
|
+
}
|
|
2121
|
+
else if (!(focusedItemInfo.type === 'node') &&
|
|
2122
|
+
(key === 'ArrowLeft' || key === 'ArrowRight')) {
|
|
2123
|
+
return true;
|
|
2124
|
+
}
|
|
2125
|
+
return false;
|
|
2126
|
+
}
|
|
2127
|
+
function handleKeyboardNavigationEvent(key) {
|
|
2128
|
+
let direction = 'down';
|
|
2129
|
+
switch (key) {
|
|
2130
|
+
case 'ArrowDown': {
|
|
2131
|
+
direction = 'down';
|
|
2132
|
+
break;
|
|
2133
|
+
}
|
|
2134
|
+
case 'ArrowUp': {
|
|
2135
|
+
direction = 'up';
|
|
2136
|
+
break;
|
|
2137
|
+
}
|
|
2138
|
+
case 'ArrowRight': {
|
|
2139
|
+
direction = 'right';
|
|
2140
|
+
break;
|
|
2141
|
+
}
|
|
2142
|
+
case 'ArrowLeft': {
|
|
2143
|
+
direction = 'left';
|
|
2144
|
+
break;
|
|
2145
|
+
}
|
|
2146
|
+
}
|
|
2147
|
+
if (focusedItemInfo.type === 'node') {
|
|
2148
|
+
const parent = itemIdToParentMap.get(focusedItemInfo.id);
|
|
2149
|
+
const navigableNodes = parent && nodeIdToDataMap.get(parent) ? nodeIdToDataMap.get(parent).nodes : nodes;
|
|
2150
|
+
const itemDetail = getNextNavigableNode(direction, true, nodeIdToDataMap.get(focusedItemInfo.id), navigableNodes);
|
|
2151
|
+
return itemDetail ? { id: itemDetail.id, type: 'node' } : focusedItemInfo;
|
|
2152
|
+
}
|
|
2153
|
+
else {
|
|
2154
|
+
const linkDetail = getLinkDetailFromInfo(focusedItemInfo, links, promotedLinks);
|
|
2155
|
+
const itemDetail = getNextNavigableLink(direction, nodes, linkDetail, links, promotedLinks);
|
|
2156
|
+
if (itemDetail && isPromoted(itemDetail))
|
|
2157
|
+
return { id: itemDetail, type: 'promotedLink' };
|
|
2158
|
+
else if (itemDetail && !isPromoted(itemDetail))
|
|
2159
|
+
return { id: itemDetail.id, type: 'link' };
|
|
2160
|
+
else
|
|
2161
|
+
return { id: focusedItemInfo.id, type: focusedItemInfo.type };
|
|
2162
|
+
}
|
|
2163
|
+
}
|
|
2164
|
+
const onContextMenuDismissed = (gesture) => {
|
|
2165
|
+
if (gesture === 'keyboard') {
|
|
2166
|
+
updatefocusedItemInfo({
|
|
2167
|
+
...focusedItemInfo,
|
|
2168
|
+
isFocusVisible: true,
|
|
2169
|
+
isCurrent: true
|
|
2170
|
+
});
|
|
2171
|
+
}
|
|
2172
|
+
};
|
|
2173
|
+
const onFocus = () => {
|
|
2174
|
+
activeId.current = getRandomId();
|
|
2175
|
+
};
|
|
2176
|
+
return {
|
|
2177
|
+
focusedItemInfo,
|
|
2178
|
+
hoveredItemInfo,
|
|
2179
|
+
activeId: activeId.current,
|
|
2180
|
+
onContextMenuDismissed,
|
|
2181
|
+
eventsProps: mergeProps(hoverHandlers, {
|
|
2182
|
+
onKeyUp: keyUpHandler,
|
|
2183
|
+
onKeyDown: keyDownHandler,
|
|
2184
|
+
onBlur: blurHandler,
|
|
2185
|
+
onPointerUp: pointerUpHandler,
|
|
2186
|
+
onFocus
|
|
2187
|
+
})
|
|
2188
|
+
};
|
|
2189
|
+
}
|
|
2190
|
+
|
|
2191
|
+
/**
|
|
2192
|
+
* Returns the datatip.
|
|
2193
|
+
* @param text The text string for the diagram item.
|
|
2194
|
+
* @param rootRef The ref for root of the diagram.
|
|
2195
|
+
* @param focusedItemBoundsRef The ref for focused item bounds.
|
|
2196
|
+
* @param focusedItemInfo The ItemInfo for focused item.
|
|
2197
|
+
* @returns
|
|
2198
|
+
*/
|
|
2199
|
+
const useDiagramDatatip = ({ touchResponse, datatip, focusedItemBoundsRef, focusedItemInfo, panState, zoom, width, nodesMap, linksMap, hoveredItem }) => {
|
|
2200
|
+
const { direction } = useUser();
|
|
2201
|
+
const isRtl = direction === 'rtl';
|
|
2202
|
+
const datatipC = getDatatipContent(nodesMap, linksMap, focusedItemInfo, hoveredItem, datatip);
|
|
2203
|
+
const elementBounds = focusedItemBoundsRef.current
|
|
2204
|
+
? {
|
|
2205
|
+
x: focusedItemBoundsRef.current.x + panState.panX,
|
|
2206
|
+
y: focusedItemBoundsRef.current.y + panState.panY,
|
|
2207
|
+
width: focusedItemBoundsRef.current.width * zoom,
|
|
2208
|
+
height: focusedItemBoundsRef.current.height * zoom
|
|
2209
|
+
}
|
|
2210
|
+
: undefined;
|
|
2211
|
+
const offset = focusedItemInfo.isCurrent
|
|
2212
|
+
? calculateOffset(isRtl, width, elementBounds)
|
|
2213
|
+
: calculateOffset(isRtl, width);
|
|
2214
|
+
const { datatipContent, datatipProps } = useDatatip({
|
|
2215
|
+
content: datatipC?.content,
|
|
2216
|
+
borderColor: datatipC?.borderColor,
|
|
2217
|
+
placement: 'top-start',
|
|
2218
|
+
offset,
|
|
2219
|
+
anchor: focusedItemInfo?.isCurrent ? 'element' : 'pointer',
|
|
2220
|
+
touchResponse
|
|
2221
|
+
});
|
|
2222
|
+
return { datatipContent: datatipContent, datatipProps: datatipProps };
|
|
2223
|
+
};
|
|
2224
|
+
|
|
2225
|
+
const usePointerGesture = ({ captureTargetRef, numPointers = 1, onPointerGestureDown, onPointerGestureMove, onPointerGestureEnd, onExtraneousPointerDown, isDisabled = false }) => {
|
|
2226
|
+
const activePointers = useRef([]);
|
|
2227
|
+
if (isDisabled) {
|
|
2228
|
+
activePointers.current = [];
|
|
2229
|
+
}
|
|
2230
|
+
const onPointerDown = (e) => {
|
|
2231
|
+
activePointers.current.push(e);
|
|
2232
|
+
if (activePointers.current.length === numPointers) {
|
|
2233
|
+
onPointerGestureDown && onPointerGestureDown({ pointers: activePointers.current });
|
|
2234
|
+
}
|
|
2235
|
+
else if (activePointers.current.length > numPointers) {
|
|
2236
|
+
onExtraneousPointerDown && onExtraneousPointerDown({ pointers: activePointers.current });
|
|
2237
|
+
}
|
|
2238
|
+
};
|
|
2239
|
+
const onPointerMove = (e) => {
|
|
2240
|
+
if (activePointers.current.length === 0)
|
|
2241
|
+
return;
|
|
2242
|
+
const index = activePointers.current.findIndex((pointerEvent) => pointerEvent.pointerId === e.pointerId);
|
|
2243
|
+
if (index === -1)
|
|
2244
|
+
return;
|
|
2245
|
+
activePointers.current[index] = e;
|
|
2246
|
+
if (activePointers.current.length === numPointers) {
|
|
2247
|
+
activePointers.current.forEach((e) => captureTargetRef.current.setPointerCapture(e.pointerId));
|
|
2248
|
+
onPointerGestureMove && onPointerGestureMove({ pointers: activePointers.current });
|
|
2249
|
+
}
|
|
2250
|
+
};
|
|
2251
|
+
const onPointerUp = (e) => {
|
|
2252
|
+
const index = activePointers.current.findIndex((pointerEvent) => pointerEvent.pointerId === e.pointerId);
|
|
2253
|
+
if (index === -1)
|
|
2254
|
+
return;
|
|
2255
|
+
activePointers.current[index] = e;
|
|
2256
|
+
if (activePointers.current.length === numPointers) {
|
|
2257
|
+
onPointerGestureEnd && onPointerGestureEnd({ pointers: activePointers.current });
|
|
2258
|
+
}
|
|
2259
|
+
activePointers.current.splice(index, 1);
|
|
2260
|
+
};
|
|
2261
|
+
const onPointerCancel = onPointerUp;
|
|
2262
|
+
const onPointerLeave = onPointerUp;
|
|
2263
|
+
return isDisabled
|
|
2264
|
+
? {}
|
|
2265
|
+
: {
|
|
2266
|
+
onPointerDown,
|
|
2267
|
+
onPointerMove,
|
|
2268
|
+
onPointerUp,
|
|
2269
|
+
onPointerCancel,
|
|
2270
|
+
onPointerLeave
|
|
2271
|
+
};
|
|
2272
|
+
};
|
|
2273
|
+
|
|
2274
|
+
/**
|
|
2275
|
+
* Whether point with coordinates are in the draggable region
|
|
2276
|
+
*/
|
|
2277
|
+
const inDraggableRegion = (x, y, region) => {
|
|
2278
|
+
if (!region)
|
|
2279
|
+
return true;
|
|
2280
|
+
const { xMin, xMax, yMin, yMax } = region;
|
|
2281
|
+
return x >= xMin && x <= xMax && y >= yMin && y <= yMax;
|
|
2282
|
+
};
|
|
2283
|
+
/**
|
|
2284
|
+
* Returns region offset
|
|
2285
|
+
*/
|
|
2286
|
+
const getRegionOffset = (x, y, region) => {
|
|
2287
|
+
if (!region)
|
|
2288
|
+
return { regionOffsetX: x, regionOffsetY: y };
|
|
2289
|
+
return { regionOffsetX: x - region.xMin, regionOffsetY: y - region.yMin };
|
|
2290
|
+
};
|
|
2291
|
+
const useDrag = ({ captureTargetRef, draggableRegion, onDragStart, onDragMove, onDragEnd, isDisabled = false }) => {
|
|
2292
|
+
const inactiveState = { isDragging: false, x0: -1, y0: -1, regionOffsetX: -1, regionOffsetY: -1 };
|
|
2293
|
+
const dragState = useRef(inactiveState);
|
|
2294
|
+
const handlePointerEvent = (e, cb) => {
|
|
2295
|
+
const { isDragging, x0, y0, regionOffsetX, regionOffsetY } = dragState.current;
|
|
2296
|
+
if (!isDragging)
|
|
2297
|
+
return;
|
|
2298
|
+
const x = e.pageX;
|
|
2299
|
+
const y = e.pageY;
|
|
2300
|
+
cb && cb({ x, y, dx: x - x0, dy: y - y0, regionOffsetX, regionOffsetY, originalEvent: e });
|
|
2301
|
+
};
|
|
2302
|
+
const dragProps = usePointerGesture({
|
|
2303
|
+
captureTargetRef,
|
|
2304
|
+
numPointers: 1, // Only allow 1 pointer dragging
|
|
2305
|
+
onExtraneousPointerDown: () => {
|
|
2306
|
+
dragState.current = inactiveState;
|
|
2307
|
+
},
|
|
2308
|
+
onPointerGestureDown: ({ pointers: [e] }) => {
|
|
2309
|
+
const x = e.pageX;
|
|
2310
|
+
const y = e.pageY;
|
|
2311
|
+
if (e.button !== 0 || !inDraggableRegion(x, y, draggableRegion))
|
|
2312
|
+
return;
|
|
2313
|
+
const { regionOffsetX, regionOffsetY } = getRegionOffset(x, y, draggableRegion);
|
|
2314
|
+
dragState.current = { isDragging: true, x0: x, y0: y, regionOffsetX, regionOffsetY };
|
|
2315
|
+
onDragStart && onDragStart({ x, y, regionOffsetX, regionOffsetY, originalEvent: e });
|
|
2316
|
+
},
|
|
2317
|
+
onPointerGestureMove: ({ pointers: [e] }) => {
|
|
2318
|
+
handlePointerEvent(e, onDragMove);
|
|
2319
|
+
},
|
|
2320
|
+
onPointerGestureEnd: ({ pointers: [e] }) => {
|
|
2321
|
+
handlePointerEvent(e, onDragEnd);
|
|
2322
|
+
dragState.current = inactiveState;
|
|
2323
|
+
}
|
|
2324
|
+
});
|
|
2325
|
+
return isDisabled ? {} : dragProps;
|
|
2326
|
+
};
|
|
2327
|
+
|
|
2328
|
+
const useDragPan = ({ panProps, captureTargetRef, panBounds, width, height, zoom, onDragPanStart, onDragPanEnd }) => {
|
|
2329
|
+
const prevPanState = useRef({ panX: 0, panY: 0 });
|
|
2330
|
+
const initialPanState = useRef({ panX: 0, panY: 0 });
|
|
2331
|
+
const dragProps = useDrag({
|
|
2332
|
+
captureTargetRef,
|
|
2333
|
+
onDragStart: () => {
|
|
2334
|
+
const panValues = centerXYToPanXY(panProps.centerX, panProps.centerY, zoom, width, height);
|
|
2335
|
+
initialPanState.current = {
|
|
2336
|
+
panX: panValues.panX,
|
|
2337
|
+
panY: panValues.panY
|
|
2338
|
+
};
|
|
2339
|
+
onDragPanStart && onDragPanStart();
|
|
2340
|
+
},
|
|
2341
|
+
onDragMove: ({ dx, dy }) => {
|
|
2342
|
+
const nextPan = {
|
|
2343
|
+
panX: initialPanState.current.panX + dx,
|
|
2344
|
+
panY: initialPanState.current.panY + dy
|
|
2345
|
+
};
|
|
2346
|
+
const { newPan } = pan(prevPanState.current, nextPan, panProps.panDirection, zoom, width, height, panBounds, panProps.onPan);
|
|
2347
|
+
prevPanState.current = newPan;
|
|
2348
|
+
},
|
|
2349
|
+
onDragEnd: ({ originalEvent }) => {
|
|
2350
|
+
// If panning occurred, call preventDefault to prevent selection from occurring
|
|
2351
|
+
if (initialPanState.current.panX !== prevPanState.current.panX ||
|
|
2352
|
+
initialPanState.current.panY !== prevPanState.current.panY)
|
|
2353
|
+
originalEvent.preventDefault();
|
|
2354
|
+
onDragPanEnd && onDragPanEnd();
|
|
2355
|
+
},
|
|
2356
|
+
isDisabled: panProps.panning === 'off'
|
|
2357
|
+
});
|
|
2358
|
+
return dragProps;
|
|
2359
|
+
};
|
|
2360
|
+
|
|
2361
|
+
const PX_FACTOR_PER_LINE = 15; // Value used in Toolkit
|
|
2362
|
+
const PX_FACTOR_PER_PAGE = 40; // Value copied from datagrid; this is not handled in Toolkit
|
|
2363
|
+
const getNormalizedDelta = (e) => {
|
|
2364
|
+
const { deltaX, deltaY, deltaMode } = e;
|
|
2365
|
+
switch (deltaMode) {
|
|
2366
|
+
case e.DOM_DELTA_PIXEL:
|
|
2367
|
+
return { deltaX: -deltaX, deltaY: -deltaY };
|
|
2368
|
+
case e.DOM_DELTA_LINE:
|
|
2369
|
+
return { deltaX: -deltaX * PX_FACTOR_PER_LINE, deltaY: -deltaY * PX_FACTOR_PER_LINE };
|
|
2370
|
+
case e.DOM_DELTA_PAGE:
|
|
2371
|
+
return { deltaX: -deltaX * PX_FACTOR_PER_PAGE, deltaY: -deltaY * PX_FACTOR_PER_PAGE };
|
|
2372
|
+
default:
|
|
2373
|
+
return { deltaX: -deltaX, deltaY: -deltaY };
|
|
2374
|
+
}
|
|
2375
|
+
};
|
|
2376
|
+
const useWheel = ({ onWheel: onWheelCallback, preventDefault = true, isDisabled = false }) => {
|
|
2377
|
+
const onWheel = (e) => {
|
|
2378
|
+
const { deltaX, deltaY } = getNormalizedDelta(e);
|
|
2379
|
+
if (preventDefault)
|
|
2380
|
+
e.preventDefault();
|
|
2381
|
+
onWheelCallback({
|
|
2382
|
+
x: e.offsetX,
|
|
2383
|
+
y: e.offsetY,
|
|
2384
|
+
deltaX,
|
|
2385
|
+
deltaY,
|
|
2386
|
+
ctrlKey: e.ctrlKey || e.metaKey
|
|
2387
|
+
});
|
|
2388
|
+
};
|
|
2389
|
+
return isDisabled ? {} : { onWheel };
|
|
2390
|
+
};
|
|
2391
|
+
|
|
2392
|
+
/**
|
|
2393
|
+
* @license
|
|
2394
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
2395
|
+
* Licensed under The Universal Permissive License (UPL), Version 1.0
|
|
2396
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
2397
|
+
* @ignore
|
|
2398
|
+
*/
|
|
2399
|
+
const useWheelZoom = ({ zooming, minZoom, maxZoom, zoomValue, onZoom }) => {
|
|
2400
|
+
const wheelProps = useWheel({
|
|
2401
|
+
onWheel: ({ deltaY }) => {
|
|
2402
|
+
const newZoom = zoomValue * (1 + ZOOM_INCREMENT * deltaY);
|
|
2403
|
+
zoom(newZoom, zoomValue, minZoom, maxZoom, onZoom);
|
|
2404
|
+
},
|
|
2405
|
+
isDisabled: zooming === 'off'
|
|
2406
|
+
});
|
|
2407
|
+
return wheelProps;
|
|
2408
|
+
};
|
|
2409
|
+
|
|
2410
|
+
const getMidpoint = (p1, p2) => ({ x: (p1.x + p2.x) / 2, y: (p1.y + p2.y) / 2 });
|
|
2411
|
+
const getDistance = (p1, p2) => Math.sqrt((p2.x - p1.x) ** 2 + (p2.y - p2.y) ** 2);
|
|
2412
|
+
const usePinch = ({ captureTargetRef, onPinchZoomStart, onPinchZoomChange, onPinchZoomEnd, isDisabled = false }) => {
|
|
2413
|
+
const origin = useRef({ x: -1, y: -1 });
|
|
2414
|
+
const prevDistance = useRef(-1);
|
|
2415
|
+
const reset = () => {
|
|
2416
|
+
origin.current = { x: -1, y: -1 };
|
|
2417
|
+
prevDistance.current = -1;
|
|
2418
|
+
};
|
|
2419
|
+
if (isDisabled)
|
|
2420
|
+
reset();
|
|
2421
|
+
const pinchProps = usePointerGesture({
|
|
2422
|
+
captureTargetRef,
|
|
2423
|
+
numPointers: 2, // Pinch gesture requires 2 pointers
|
|
2424
|
+
onPointerGestureDown: ({ pointers: [pointer1, pointer2] }) => {
|
|
2425
|
+
const p1 = { x: pointer1.offsetX, y: pointer1.offsetY };
|
|
2426
|
+
const p2 = { x: pointer2.offsetX, y: pointer2.offsetY };
|
|
2427
|
+
origin.current = getMidpoint(p1, p2);
|
|
2428
|
+
prevDistance.current = getDistance(p1, p2);
|
|
2429
|
+
onPinchZoomStart &&
|
|
2430
|
+
onPinchZoomStart({
|
|
2431
|
+
origin: origin.current,
|
|
2432
|
+
delta: 0
|
|
2433
|
+
});
|
|
2434
|
+
},
|
|
2435
|
+
onPointerGestureMove: ({ pointers: [pointer1, pointer2] }) => {
|
|
2436
|
+
const p1 = { x: pointer1.offsetX, y: pointer1.offsetY };
|
|
2437
|
+
const p2 = { x: pointer2.offsetX, y: pointer2.offsetY };
|
|
2438
|
+
const distance = getDistance(p1, p2);
|
|
2439
|
+
const delta = distance - prevDistance.current;
|
|
2440
|
+
prevDistance.current = distance;
|
|
2441
|
+
onPinchZoomChange &&
|
|
2442
|
+
onPinchZoomChange({
|
|
2443
|
+
origin: origin.current,
|
|
2444
|
+
delta
|
|
2445
|
+
});
|
|
2446
|
+
},
|
|
2447
|
+
onPointerGestureEnd: () => {
|
|
2448
|
+
reset();
|
|
2449
|
+
onPinchZoomEnd && onPinchZoomEnd();
|
|
2450
|
+
}
|
|
2451
|
+
});
|
|
2452
|
+
return isDisabled ? {} : pinchProps;
|
|
2453
|
+
};
|
|
2454
|
+
|
|
2455
|
+
const usePinchZoom = ({ captureTargetRef, zooming, minZoom, maxZoom, zoomValue, onZoom }) => {
|
|
2456
|
+
const pinchProps = usePinch({
|
|
2457
|
+
captureTargetRef,
|
|
2458
|
+
onPinchZoomChange: ({ delta }) => {
|
|
2459
|
+
const newZoom = zoomValue * (1 + ZOOM_INCREMENT * delta);
|
|
2460
|
+
zoom(newZoom, zoomValue, minZoom, maxZoom, onZoom);
|
|
2461
|
+
},
|
|
2462
|
+
isDisabled: zooming === 'off'
|
|
2463
|
+
});
|
|
2464
|
+
return pinchProps;
|
|
2465
|
+
};
|
|
2466
|
+
|
|
2467
|
+
const usePanZoom = ({ props, captureTargetRef, width, height, contentBounds, isRtl }) => {
|
|
2468
|
+
const [cursor, setCursor] = useState();
|
|
2469
|
+
const zoomProps = getZoomProps(props, width, height, contentBounds);
|
|
2470
|
+
const panBounds = useRef();
|
|
2471
|
+
const prevZoom = useRef();
|
|
2472
|
+
const panning = useRef();
|
|
2473
|
+
const initPanZoomState = useRef({
|
|
2474
|
+
zoom: props.zoomValue || 0,
|
|
2475
|
+
centerX: props.centerX,
|
|
2476
|
+
centerY: props.centerY
|
|
2477
|
+
});
|
|
2478
|
+
const isDeviceTouch = isTouch();
|
|
2479
|
+
const plotArea = {
|
|
2480
|
+
width: width,
|
|
2481
|
+
height: height,
|
|
2482
|
+
x: 0,
|
|
2483
|
+
y: 0
|
|
2484
|
+
};
|
|
2485
|
+
const showPanButton = isDeviceTouch ? props.panning && props.panning !== 'off' : undefined;
|
|
2486
|
+
const dragModeOptions = {
|
|
2487
|
+
isZoomScroll: true,
|
|
2488
|
+
plotAreaSpace: plotArea,
|
|
2489
|
+
componentWidth: width,
|
|
2490
|
+
isRtl,
|
|
2491
|
+
showPanButton: showPanButton ?? false,
|
|
2492
|
+
showZoomButton: false,
|
|
2493
|
+
showSelectButton: false,
|
|
2494
|
+
isDisabled: !isDeviceTouch
|
|
2495
|
+
};
|
|
2496
|
+
const { toggleButtonContent, userDragMode } = useVisDragModeControls(dragModeOptions);
|
|
2497
|
+
const panProps = getPanProps(props, contentBounds, userDragMode, isDeviceTouch);
|
|
2498
|
+
if (contentBounds.width !== Infinity &&
|
|
2499
|
+
(zoomProps.zoomValue !== prevZoom.current || panProps.panning !== panning.current)) {
|
|
2500
|
+
panBounds.current = getPanBounds(width, height, contentBounds, zoomProps.zoomValue, zoomProps.minZoom, initPanZoomState.current, panProps.panning);
|
|
2501
|
+
prevZoom.current = zoomProps.zoomValue;
|
|
2502
|
+
panning.current = panProps.panning;
|
|
2503
|
+
}
|
|
2504
|
+
const dragPanProps = useDragPan({
|
|
2505
|
+
panProps: panProps,
|
|
2506
|
+
captureTargetRef: captureTargetRef,
|
|
2507
|
+
panBounds: panBounds.current,
|
|
2508
|
+
zoom: zoomProps.zoomValue,
|
|
2509
|
+
width,
|
|
2510
|
+
height,
|
|
2511
|
+
onDragPanStart: () => setCursor('grabbing'),
|
|
2512
|
+
onDragPanEnd: () => setCursor('auto')
|
|
2513
|
+
});
|
|
2514
|
+
//dZoom or nZoom is required
|
|
2515
|
+
const kbZoomCallback = (props) => {
|
|
2516
|
+
const newZoom = props.dZoom
|
|
2517
|
+
? zoomProps.zoomValue + props.dZoom
|
|
2518
|
+
: getZoomToFitZoom(width, height, contentBounds);
|
|
2519
|
+
zoom(props.nZoom ? props.nZoom : newZoom, zoomProps.zoomValue, zoomProps.minZoom, zoomProps.maxZoom, zoomProps.onZoom);
|
|
2520
|
+
};
|
|
2521
|
+
const prevPanState = useRef({ panX: 0, panY: 0 });
|
|
2522
|
+
// dPan or nPan is required
|
|
2523
|
+
const kbPanCallback = (props) => {
|
|
2524
|
+
let centerX;
|
|
2525
|
+
let centerY;
|
|
2526
|
+
if (props.center) {
|
|
2527
|
+
centerX = contentBounds.x + contentBounds.width / 2;
|
|
2528
|
+
centerY = contentBounds.y + contentBounds.height / 2;
|
|
2529
|
+
}
|
|
2530
|
+
else if (props.dPan) {
|
|
2531
|
+
centerX = panProps.centerX + props.dPan.dx;
|
|
2532
|
+
centerY = panProps.centerY + props.dPan.dy;
|
|
2533
|
+
}
|
|
2534
|
+
else {
|
|
2535
|
+
centerX = props.nPan.cx;
|
|
2536
|
+
centerY = props.nPan.cy;
|
|
2537
|
+
}
|
|
2538
|
+
const panValues = centerXYToPanXY(centerX, centerY, zoomProps.zoomValue, width, height);
|
|
2539
|
+
const { newPan } = pan(prevPanState.current, panValues, panProps.panDirection, zoomProps.zoomValue, width, height, panBounds.current, panProps.onPan);
|
|
2540
|
+
prevPanState.current = newPan;
|
|
2541
|
+
};
|
|
2542
|
+
const wheelZoomProps = useWheelZoom(zoomProps);
|
|
2543
|
+
const pinchZoomProps = usePinchZoom({
|
|
2544
|
+
captureTargetRef,
|
|
2545
|
+
zooming: zoomProps.zooming,
|
|
2546
|
+
minZoom: zoomProps.minZoom,
|
|
2547
|
+
maxZoom: zoomProps.maxZoom,
|
|
2548
|
+
zoomValue: zoomProps.zoomValue,
|
|
2549
|
+
onZoom: zoomProps.onZoom
|
|
2550
|
+
});
|
|
2551
|
+
const panZoomProps = mergeProps(dragPanProps, wheelZoomProps, pinchZoomProps);
|
|
2552
|
+
return {
|
|
2553
|
+
panZoomProps,
|
|
2554
|
+
panProps,
|
|
2555
|
+
zoomProps,
|
|
2556
|
+
toggleButtonContent,
|
|
2557
|
+
cursor,
|
|
2558
|
+
centerX: panProps.centerX,
|
|
2559
|
+
centerY: panProps.centerY,
|
|
2560
|
+
zoomValue: zoomProps.zoomValue,
|
|
2561
|
+
kbPanCallback: panProps.panning !== 'off' ? kbPanCallback : undefined,
|
|
2562
|
+
kbZoomCallback: zoomProps.zooming !== 'off' ? kbZoomCallback : undefined
|
|
2563
|
+
};
|
|
2564
|
+
};
|
|
2565
|
+
|
|
2566
|
+
function useDiagramSelection({ selectedIds, selectionMode, nodeMap, linkMap, focusedItemInfo, onSelectionChange, rootRef, promotedLinkMap }) {
|
|
2567
|
+
const nodeIdToDataMap = nodeMap.itemIdToDataMap;
|
|
2568
|
+
const nodeEncodedToIdMap = new Map();
|
|
2569
|
+
const linkEncodedToIdMap = new Map();
|
|
2570
|
+
const linkIdToDataMap = linkMap.itemIdToDataMap;
|
|
2571
|
+
const encodeNodeId = (id) => {
|
|
2572
|
+
const encoded = `N_${id}`;
|
|
2573
|
+
nodeEncodedToIdMap.set(encoded, id);
|
|
2574
|
+
return encoded;
|
|
2575
|
+
};
|
|
2576
|
+
const decodeNodeId = (id) => nodeEncodedToIdMap.get(id);
|
|
2577
|
+
const encodeLinkId = (id) => {
|
|
2578
|
+
const encoded = `L_${id}`;
|
|
2579
|
+
linkEncodedToIdMap.set(encoded, id);
|
|
2580
|
+
return encoded;
|
|
2581
|
+
};
|
|
2582
|
+
const decodeLinkId = (id) => linkEncodedToIdMap.get(id);
|
|
2583
|
+
const encodePromotedLinkId = (id) => `P_${JSON.stringify(id)}`;
|
|
2584
|
+
const decodePromotedLinkId = (id) => JSON.parse(id.slice(2));
|
|
2585
|
+
const encodedNodesSelection = selectedIds.nodes ? selectedIds.nodes.map(encodeNodeId) : [];
|
|
2586
|
+
const encodedLinksSelection = selectedIds.links ? selectedIds.links.map(encodeLinkId) : [];
|
|
2587
|
+
const encodedPromotedLinksSelection = selectedIds.promotedLinks
|
|
2588
|
+
? selectedIds.promotedLinks.map(encodePromotedLinkId)
|
|
2589
|
+
: [];
|
|
2590
|
+
const encodedSelection = [
|
|
2591
|
+
...encodedNodesSelection,
|
|
2592
|
+
...encodedLinksSelection,
|
|
2593
|
+
...encodedPromotedLinksSelection
|
|
2594
|
+
];
|
|
2595
|
+
const idExtracter = (event) => {
|
|
2596
|
+
// return encodeNodeId(id) or encodeLinkId(id) depending on node or link selection or undefined if clicked on empty space
|
|
2597
|
+
const info = event.type === 'keyup'
|
|
2598
|
+
? focusedItemInfo
|
|
2599
|
+
: getNavigableInfo(event.target, promotedLinkMap, rootRef);
|
|
2600
|
+
return info.id !== undefined
|
|
2601
|
+
? info.type === 'node'
|
|
2602
|
+
? encodeNodeId(info.id)
|
|
2603
|
+
: info.type === 'link'
|
|
2604
|
+
? encodeLinkId(info.id)
|
|
2605
|
+
: encodePromotedLinkId(info.id)
|
|
2606
|
+
: undefined;
|
|
2607
|
+
};
|
|
2608
|
+
const onEncodedSelectionChange = (detail) => {
|
|
2609
|
+
const newNodeIds = detail.ids
|
|
2610
|
+
.filter((encId) => encId[0] === 'N')
|
|
2611
|
+
.map((encId) => decodeNodeId(encId));
|
|
2612
|
+
const newLinkIds = detail.ids
|
|
2613
|
+
.filter((encId) => encId[0] === 'L')
|
|
2614
|
+
.map((encId) => decodeLinkId(encId));
|
|
2615
|
+
const newPromotedLinkIds = detail.ids
|
|
2616
|
+
.filter((encId) => encId[0] === 'P')
|
|
2617
|
+
.map((encId) => decodePromotedLinkId(encId));
|
|
2618
|
+
const newSelectedNodeIds = newNodeIds.filter((id) => nodeIdToDataMap.get(id)?.selectable !== 'off');
|
|
2619
|
+
const newSelectedLinkIds = newLinkIds.filter((id) => linkIdToDataMap.get(id)?.selectable !== 'off');
|
|
2620
|
+
const nodeData = newSelectedNodeIds.map((selectedId) => {
|
|
2621
|
+
return nodeIdToDataMap.get(selectedId);
|
|
2622
|
+
});
|
|
2623
|
+
const linkData = newSelectedLinkIds.map((selectedId) => {
|
|
2624
|
+
return linkIdToDataMap.get(selectedId);
|
|
2625
|
+
});
|
|
2626
|
+
return (onSelectionChange &&
|
|
2627
|
+
onSelectionChange({
|
|
2628
|
+
nodes: {
|
|
2629
|
+
ids: newSelectedNodeIds,
|
|
2630
|
+
data: nodeData
|
|
2631
|
+
},
|
|
2632
|
+
links: {
|
|
2633
|
+
ids: newSelectedLinkIds,
|
|
2634
|
+
data: linkData
|
|
2635
|
+
},
|
|
2636
|
+
promotedLinks: {
|
|
2637
|
+
ids: newPromotedLinkIds
|
|
2638
|
+
}
|
|
2639
|
+
}));
|
|
2640
|
+
};
|
|
2641
|
+
const getDataById = (id) => {
|
|
2642
|
+
let data;
|
|
2643
|
+
if (id[0] === 'N') {
|
|
2644
|
+
const nodeId = decodeNodeId(id);
|
|
2645
|
+
data = nodeMap.itemIdToDataMap.get(nodeId);
|
|
2646
|
+
}
|
|
2647
|
+
else if (id[0] === 'L') {
|
|
2648
|
+
const linkId = decodeLinkId(id);
|
|
2649
|
+
data = linkMap.itemIdToDataMap.get(linkId);
|
|
2650
|
+
}
|
|
2651
|
+
else if (id[0] === 'P') {
|
|
2652
|
+
data = decodePromotedLinkId(id);
|
|
2653
|
+
}
|
|
2654
|
+
return data;
|
|
2655
|
+
};
|
|
2656
|
+
const isKeyboardSelection = (event) => {
|
|
2657
|
+
return event.key === '[' || event.key === ']';
|
|
2658
|
+
};
|
|
2659
|
+
const { selectionContent, selectionProps } = useSelection({
|
|
2660
|
+
selection: encodedSelection,
|
|
2661
|
+
idExtracter,
|
|
2662
|
+
selectionMode,
|
|
2663
|
+
getDataById,
|
|
2664
|
+
onChange: onEncodedSelectionChange,
|
|
2665
|
+
isKeyboardSelection
|
|
2666
|
+
});
|
|
2667
|
+
return { selectionContent, selectionProps };
|
|
2668
|
+
}
|
|
2669
|
+
|
|
2670
|
+
/**
|
|
2671
|
+
* @license
|
|
2672
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
2673
|
+
* Licensed under The Universal Permissive License (UPL), Version 1.0
|
|
2674
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
2675
|
+
* @ignore
|
|
2676
|
+
*/
|
|
2677
|
+
function getDiagramContextMenuContext(nodesMap, linksMap, type, idx) {
|
|
2678
|
+
let context;
|
|
2679
|
+
if (type === 'node') {
|
|
2680
|
+
context = {
|
|
2681
|
+
data: nodesMap.get(idx),
|
|
2682
|
+
type
|
|
2683
|
+
};
|
|
2684
|
+
}
|
|
2685
|
+
else if (type === 'link') {
|
|
2686
|
+
context = {
|
|
2687
|
+
data: linksMap.get(idx),
|
|
2688
|
+
type
|
|
2689
|
+
};
|
|
2690
|
+
}
|
|
2691
|
+
else if (type === 'promotedLink') {
|
|
2692
|
+
context = {
|
|
2693
|
+
id: idx,
|
|
2694
|
+
type
|
|
2695
|
+
};
|
|
2696
|
+
}
|
|
2697
|
+
else {
|
|
2698
|
+
context = {
|
|
2699
|
+
type: 'background'
|
|
2700
|
+
};
|
|
2701
|
+
}
|
|
2702
|
+
return {
|
|
2703
|
+
context: context
|
|
2704
|
+
};
|
|
2705
|
+
}
|
|
2706
|
+
|
|
2707
|
+
/**
|
|
2708
|
+
* @license
|
|
2709
|
+
* Copyright (c) %FIRST_YEAR% %CURRENT_YEAR%, Oracle and/or its affiliates.
|
|
2710
|
+
* Licensed under The Universal Permissive License (UPL), Version 1.0
|
|
2711
|
+
* as shown at https://oss.oracle.com/licenses/upl/
|
|
2712
|
+
* @ignore
|
|
2713
|
+
*/
|
|
2714
|
+
const useDiagramContextMenu = ({ focusedItemInfo, rootRef, contextMenuConfig, onContextMenuDismissed, nodesMap, linksMap, promotedLinkMap }) => {
|
|
2715
|
+
const { contextMenuProps, contextMenuContent } = useContextMenu({
|
|
2716
|
+
onContextMenuHandler: ({ gesture, target }) => {
|
|
2717
|
+
let idx;
|
|
2718
|
+
let elementType = 'background';
|
|
2719
|
+
const currentTarget = target;
|
|
2720
|
+
if (gesture === 'keyboard') {
|
|
2721
|
+
idx = focusedItemInfo.id;
|
|
2722
|
+
elementType = focusedItemInfo.type;
|
|
2723
|
+
}
|
|
2724
|
+
else if (currentTarget.closest('[data-oj-private-node]')?.dataset['ojPrivateNode']) {
|
|
2725
|
+
idx = currentTarget.closest('[data-oj-private-node]')?.dataset['ojPrivateNode'];
|
|
2726
|
+
elementType = 'node';
|
|
2727
|
+
}
|
|
2728
|
+
else if (currentTarget.closest('[data-oj-private-link]')?.dataset['ojPrivateLink']) {
|
|
2729
|
+
idx = currentTarget.closest('[data-oj-private-link]')?.dataset['ojPrivateLink'];
|
|
2730
|
+
elementType = 'link';
|
|
2731
|
+
}
|
|
2732
|
+
else if (currentTarget.closest('[data-oj-private-promoted-link]')?.dataset['ojPrivatePromotedLink']) {
|
|
2733
|
+
idx = currentTarget.closest('[data-oj-private-promoted-link]')?.dataset['ojPrivatePromotedLink'];
|
|
2734
|
+
idx = promotedLinkMap.get(idx);
|
|
2735
|
+
elementType = 'promotedLink';
|
|
2736
|
+
}
|
|
2737
|
+
const { context } = getDiagramContextMenuContext(nodesMap, linksMap, elementType, idx);
|
|
2738
|
+
if (gesture === 'keyboard') {
|
|
2739
|
+
let element;
|
|
2740
|
+
if (focusedItemInfo.type === 'node') {
|
|
2741
|
+
element = rootRef.current?.querySelector(`[data-oj-private-node="${idx}"]`);
|
|
2742
|
+
}
|
|
2743
|
+
else if (focusedItemInfo.type === 'link') {
|
|
2744
|
+
element = rootRef.current?.querySelector(`[data-oj-private-link="${idx}"]`);
|
|
2745
|
+
}
|
|
2746
|
+
else {
|
|
2747
|
+
element = rootRef.current?.querySelector(`[data-oj-private-promoted-link="${getPromotedString(idx)}"]`);
|
|
2748
|
+
}
|
|
2749
|
+
return {
|
|
2750
|
+
type: 'element',
|
|
2751
|
+
context,
|
|
2752
|
+
elem: element ? element : null
|
|
2753
|
+
};
|
|
2754
|
+
}
|
|
2755
|
+
return { type: 'pointer', context };
|
|
2756
|
+
},
|
|
2757
|
+
contextMenuOptions: {
|
|
2758
|
+
isDisabled: !contextMenuConfig //If there is not a context menu renderer we disable the hook
|
|
2759
|
+
},
|
|
2760
|
+
rootRef,
|
|
2761
|
+
contextMenuConfig,
|
|
2762
|
+
onContextMenuDismissed
|
|
2763
|
+
});
|
|
2764
|
+
return { contextMenuContent, contextMenuProps };
|
|
2765
|
+
};
|
|
2766
|
+
|
|
2767
|
+
const emptyKeys = { all: false, keys: new Set() };
|
|
2768
|
+
function BaseDiagramWithDimensions({ nodes = [], links = [], width, height, selectedIds = {}, selectionMode = 'none', layout, nodeRenderer, linkRenderer, onSelectionChange, onItemHover, onItemFocus, highlightedIds = {}, datatip, expanded = emptyKeys, onExpandedChange, contextMenuConfig, normalizeLinks, ...otherProps }) {
|
|
2769
|
+
const focusedItemBoundsRef = useRef(null);
|
|
2770
|
+
const rootRef = useRef(null);
|
|
2771
|
+
const [bounds, setBounds] = useState(new Map());
|
|
2772
|
+
const [absBounds, setAbsBounds] = useState(new Map());
|
|
2773
|
+
const linkDimensions = useRef(new Map());
|
|
2774
|
+
const promotedLinkDimensions = useRef(new Map());
|
|
2775
|
+
const [combinedLabelBounds, setCombinedLabelBounds] = useState();
|
|
2776
|
+
const { direction } = useUser();
|
|
2777
|
+
const isRtl = direction === 'rtl';
|
|
2778
|
+
const diagramNodes = nodes;
|
|
2779
|
+
const nodeMap = createNodesMap(diagramNodes, expanded);
|
|
2780
|
+
const nodeIdToParentMap = nodeMap.itemIdToParentMap;
|
|
2781
|
+
const nodeIdToDataMap = nodeMap.itemIdToDataMap;
|
|
2782
|
+
const diagramLinks = filterLinksWithNoStartOrEndNodes(links, nodeIdToDataMap);
|
|
2783
|
+
const linkMap = createLinksMap(diagramLinks);
|
|
2784
|
+
const linkIdToDataMap = linkMap.itemIdToDataMap;
|
|
2785
|
+
const resizeThrottling = useRef(false);
|
|
2786
|
+
const newDimensions = getDimensionsFromBounds(bounds);
|
|
2787
|
+
const { textMeasureContent, getTextDimensions } = useTextDimensions();
|
|
2788
|
+
const labelDimensions = useRef(new Map());
|
|
2789
|
+
const linkDimsChanged = useRef(false);
|
|
2790
|
+
const linkRerenderNeeded = useRef(false);
|
|
2791
|
+
const nodeLabelPosRef = useRef(new Map());
|
|
2792
|
+
const linkLabelPosRef = useRef(new Map());
|
|
2793
|
+
const [layoutOutput, setLayoutOutput] = useState();
|
|
2794
|
+
const nodeBoundsRef = useRef(new Map());
|
|
2795
|
+
const promotedLinks = getPromotedLinks(links, expanded, nodeMap.allContainerNodes, nodeMap.allVisibleNodes);
|
|
2796
|
+
const promotedLinkMap = createPromotedLinksMap(promotedLinks);
|
|
2797
|
+
const contentBounds = getContentBounds(bounds, combinedLabelBounds);
|
|
2798
|
+
const { panZoomProps, panProps, zoomProps, toggleButtonContent, cursor, centerX, centerY, zoomValue, kbPanCallback, kbZoomCallback } = usePanZoom({
|
|
2799
|
+
props: otherProps,
|
|
2800
|
+
captureTargetRef: rootRef,
|
|
2801
|
+
width: width,
|
|
2802
|
+
height: height,
|
|
2803
|
+
contentBounds,
|
|
2804
|
+
isRtl
|
|
2805
|
+
});
|
|
2806
|
+
const { touchResponse, touchResponseStyle } = useVisTouchResponse({
|
|
2807
|
+
type: 'auto',
|
|
2808
|
+
supportsTouchDragGestures: zoomProps.zooming === 'on' || panProps.panning !== 'off',
|
|
2809
|
+
rootRef
|
|
2810
|
+
});
|
|
2811
|
+
const { onContextMenuDismissed, focusedItemInfo, hoveredItemInfo, activeId, eventsProps } = useEvents(touchResponse, diagramNodes[0], diagramNodes, diagramLinks, promotedLinks, absBounds, linkIdToDataMap, nodeIdToDataMap, width, height, otherProps.maxZoom || 1, expanded, nodeIdToParentMap, promotedLinkMap, onItemHover, onItemFocus, kbPanCallback, kbZoomCallback, onExpandedChange);
|
|
2812
|
+
const { selectionProps, selectionContent } = useDiagramSelection({
|
|
2813
|
+
selectedIds,
|
|
2814
|
+
selectionMode,
|
|
2815
|
+
nodeMap,
|
|
2816
|
+
linkMap,
|
|
2817
|
+
focusedItemInfo,
|
|
2818
|
+
onSelectionChange,
|
|
2819
|
+
rootRef,
|
|
2820
|
+
promotedLinkMap
|
|
2821
|
+
});
|
|
2822
|
+
// This is for the datatip kb position
|
|
2823
|
+
if (focusedItemInfo && absBounds.size > 0) {
|
|
2824
|
+
focusedItemBoundsRef.current = getFocusedItemBounds(focusedItemInfo, absBounds, diagramLinks, linkMap.itemIdToIndexMap, rootRef);
|
|
2825
|
+
}
|
|
2826
|
+
const { datatipContent, datatipProps: { 'aria-describedby': datatipAriaDescribedby, ...datatipProps } } = useDiagramDatatip({
|
|
2827
|
+
touchResponse,
|
|
2828
|
+
datatip,
|
|
2829
|
+
focusedItemInfo,
|
|
2830
|
+
focusedItemBoundsRef,
|
|
2831
|
+
panState: centerXYToPanXY(centerX, centerY, zoomValue, width, height),
|
|
2832
|
+
zoom: zoomValue,
|
|
2833
|
+
width: width,
|
|
2834
|
+
nodesMap: nodeIdToDataMap,
|
|
2835
|
+
linksMap: linkIdToDataMap,
|
|
2836
|
+
hoveredItem: hoveredItemInfo
|
|
2837
|
+
});
|
|
2838
|
+
const [visibility, setVisibility] = useState('hidden');
|
|
2839
|
+
const style = {
|
|
2840
|
+
width: width,
|
|
2841
|
+
height: height,
|
|
2842
|
+
cursor: cursor,
|
|
2843
|
+
visibility: visibility,
|
|
2844
|
+
...touchResponseStyle
|
|
2845
|
+
};
|
|
2846
|
+
// When expanded changes, diagram loses focus so we need to call re-render
|
|
2847
|
+
const expandRerender = useRef(false);
|
|
2848
|
+
useLayoutEffect(() => {
|
|
2849
|
+
if (rootRef.current) {
|
|
2850
|
+
expandRerender.current = true;
|
|
2851
|
+
}
|
|
2852
|
+
}, [expanded]);
|
|
2853
|
+
useLayoutEffect(() => {
|
|
2854
|
+
if (visibility === 'visible' && expandRerender.current == true) {
|
|
2855
|
+
rootRef.current?.focus();
|
|
2856
|
+
expandRerender.current = false;
|
|
2857
|
+
}
|
|
2858
|
+
}, [visibility]);
|
|
2859
|
+
const states = useRef();
|
|
2860
|
+
states.current = {
|
|
2861
|
+
// update states to new state
|
|
2862
|
+
selectedNodeIds: selectedIds.nodes ?? [],
|
|
2863
|
+
selectedLinkIds: selectedIds.links ?? [],
|
|
2864
|
+
selectedPromotedLinkIds: selectedIds.promotedLinks ?? [],
|
|
2865
|
+
focusedId: focusedItemInfo.isCurrent && focusedItemInfo.isFocusVisible ? focusedItemInfo.id : undefined,
|
|
2866
|
+
hoveredId: hoveredItemInfo?.isCurrent ? hoveredItemInfo.id : undefined,
|
|
2867
|
+
activeId,
|
|
2868
|
+
highlightedNodeIds: highlightedIds.nodes ?? [],
|
|
2869
|
+
highlightedLinkIds: highlightedIds.links ?? [],
|
|
2870
|
+
highlightedPromotedLinkIds: highlightedIds.promotedLinks ?? [],
|
|
2871
|
+
zoom: zoomValue,
|
|
2872
|
+
expanded: expanded || { all: false, keys: new Set() }
|
|
2873
|
+
};
|
|
2874
|
+
const { contextMenuContent, contextMenuProps } = useDiagramContextMenu({
|
|
2875
|
+
focusedItemInfo,
|
|
2876
|
+
rootRef,
|
|
2877
|
+
contextMenuConfig: nodes.length > 0 ? contextMenuConfig : undefined,
|
|
2878
|
+
onContextMenuDismissed,
|
|
2879
|
+
nodesMap: nodeIdToDataMap,
|
|
2880
|
+
linksMap: linkIdToDataMap,
|
|
2881
|
+
promotedLinkMap
|
|
2882
|
+
});
|
|
2883
|
+
const mergedEventProps = mergeProps(panZoomProps, eventsProps, selectionProps, datatipProps, contextMenuProps);
|
|
2884
|
+
// Called anytime node changes size
|
|
2885
|
+
const onNodeSizeChanged = (nodeWidth, nodeHeight, id) => {
|
|
2886
|
+
newDimensions.set(id, { width: nodeWidth, height: nodeHeight });
|
|
2887
|
+
if (resizeThrottling.current) {
|
|
2888
|
+
return;
|
|
2889
|
+
}
|
|
2890
|
+
resizeThrottling.current = true;
|
|
2891
|
+
// performs layout at the next available animation frame when all measurements should be ready
|
|
2892
|
+
window.requestAnimationFrame(() => {
|
|
2893
|
+
const { labelDims, layoutJSON } = constructLayoutJSON(nodeIdToDataMap, linkIdToDataMap, promotedLinks, newDimensions, width, height, zoomValue, nodeIdToParentMap, rootRef, getTextDimensions);
|
|
2894
|
+
labelDimensions.current = labelDims;
|
|
2895
|
+
const layoutOutput = layout(layoutJSON);
|
|
2896
|
+
const { nodePoints, nodeLabelPos, linkLabelPos } = deconstructLayoutJSON(layoutOutput, diagramNodes, diagramLinks);
|
|
2897
|
+
nodeLabelPosRef.current = nodeLabelPos;
|
|
2898
|
+
linkLabelPosRef.current = linkLabelPos;
|
|
2899
|
+
const { nodeBounds, nodeAbsBounds } = mergeDimensions(newDimensions, nodePoints, rootRef);
|
|
2900
|
+
const labelBounds = getAllLabelBounds(labelDims, nodeLabelPos, linkLabelPos, direction === 'rtl', rootRef);
|
|
2901
|
+
const equalBounds = isEqualBounds(nodeBounds, bounds);
|
|
2902
|
+
if (!equalBounds || linkDimsChanged.current || linkRerenderNeeded.current) {
|
|
2903
|
+
linkRerenderNeeded.current = linkPositionChanged(nodeBounds, bounds, links);
|
|
2904
|
+
setBounds(nodeBounds);
|
|
2905
|
+
setAbsBounds(nodeAbsBounds);
|
|
2906
|
+
setCombinedLabelBounds(labelBounds);
|
|
2907
|
+
setLayoutOutput(layoutOutput);
|
|
2908
|
+
linkDimsChanged.current = false;
|
|
2909
|
+
setVisibility('hidden');
|
|
2910
|
+
}
|
|
2911
|
+
else if (visibility == 'hidden') {
|
|
2912
|
+
setVisibility('visible');
|
|
2913
|
+
}
|
|
2914
|
+
resizeThrottling.current = false;
|
|
2915
|
+
});
|
|
2916
|
+
};
|
|
2917
|
+
const onLinkSizeChanged = (linkWidth, linkHeight, id) => {
|
|
2918
|
+
if (linkWidth !== 0 || linkHeight !== 0) {
|
|
2919
|
+
const linkDims = linkDimensions.current.get(id);
|
|
2920
|
+
if (!linkDims ||
|
|
2921
|
+
(linkDims &&
|
|
2922
|
+
(Math.abs(linkWidth - linkDims.width) > 0.5 ||
|
|
2923
|
+
Math.abs(linkHeight - linkDims.height) > 0.5))) {
|
|
2924
|
+
linkDimensions.current.set(id, { width: linkWidth, height: linkHeight });
|
|
2925
|
+
linkDimsChanged.current = true;
|
|
2926
|
+
}
|
|
2927
|
+
}
|
|
2928
|
+
};
|
|
2929
|
+
const onPromotedLinkSizeChanged = (linkWidth, linkHeight, id) => {
|
|
2930
|
+
if (linkWidth !== 0 || linkHeight !== 0) {
|
|
2931
|
+
const linkDims = promotedLinkDimensions.current.get(id);
|
|
2932
|
+
if (!linkDims ||
|
|
2933
|
+
(linkDims &&
|
|
2934
|
+
(Math.abs(linkWidth - linkDims.width) > 0.5 ||
|
|
2935
|
+
Math.abs(linkHeight - linkDims.height) > 0.5))) {
|
|
2936
|
+
promotedLinkDimensions.current.set(id, { width: linkWidth, height: linkHeight });
|
|
2937
|
+
linkDimsChanged.current = true;
|
|
2938
|
+
}
|
|
2939
|
+
}
|
|
2940
|
+
};
|
|
2941
|
+
return (jsxs("div", { ref: rootRef, class: outerStyles, ...mergedEventProps, style: style, tabIndex: 0, role: "application", "aria-label": otherProps['aria-label'], "aria-labelledby": otherProps['aria-labelledby'], "aria-describedby": l([otherProps['aria-describedby'], datatipAriaDescribedby]), "aria-activedescendant": activeId, children: [getTextDimensions ? (jsx(DiagramPanZoomContainer, { centerX: centerX, centerY: centerY, zoom: zoomValue, width: width, height: height, children: jsx(DiagramLayers, { nodes: diagramNodes, links: diagramLinks, zoom: zoomValue, nodeRenderer: nodeRenderer, linkRenderer: linkRenderer, width: width, height: height, nodeBounds: bounds, linkDimensions: linkDimensions.current, promotedLinkDimensions: promotedLinkDimensions.current, states: states.current, onNodeSizeChanged: onNodeSizeChanged, onLinkSizeChanged: onLinkSizeChanged, onPromotedLinkSizeChanged: onPromotedLinkSizeChanged, nodeLabelPositions: nodeLabelPosRef.current, linkLabelPositions: linkLabelPosRef.current, labelDimensions: labelDimensions.current, supportsSelection: selectionMode !== 'none' ||
|
|
2942
|
+
!!(selectedIds?.nodes && selectedIds.nodes.length > 0) ||
|
|
2943
|
+
!!(selectedIds?.links && selectedIds.links.length > 0), layoutOutput: layoutOutput, nodeIdToParentMap: nodeIdToParentMap, rootRef: rootRef, combinedNodeBounds: contentBounds, nodeBoundsRef: nodeBoundsRef, promotedLinks: promotedLinks, normalizeLinks: normalizeLinks }) })) : undefined, textMeasureContent, datatipContent, contextMenuContent, selectionContent, toggleButtonContent] }));
|
|
2944
|
+
}
|
|
2945
|
+
|
|
2946
|
+
/**
|
|
2947
|
+
* Diagrams are used to display a set of nodes and the links between them.
|
|
2948
|
+
*/
|
|
2949
|
+
function BaseDiagram({ width, height, ...otherProps }) {
|
|
2950
|
+
return otherProps.nodes && otherProps.nodes.length > 0 ? (jsx(TrackResizeContainer, { width: width, height: height, class: dimensionStyle, children: (width, height) => (jsx(BaseDiagramWithDimensions, { width: width, height: height, ...otherProps })) })) : null;
|
|
2951
|
+
}
|
|
2952
|
+
|
|
2953
|
+
export { BaseDiagram as B };
|
|
2954
|
+
//# sourceMappingURL=BaseDiagram-19f481a0.js.map
|