@elastic/eui 93.3.0 → 93.5.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/dist/eui_charts_theme.d.ts +9 -0
- package/dist/eui_charts_theme.js +56 -14
- package/dist/eui_charts_theme.js.map +1 -1
- package/dist/eui_theme_dark.css +3 -0
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +3 -0
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/breadcrumbs/_breadcrumb_content.js +362 -0
- package/es/components/breadcrumbs/_breadcrumb_content.styles.js +48 -0
- package/es/components/breadcrumbs/breadcrumb.js +10 -327
- package/es/components/breadcrumbs/breadcrumb.styles.js +5 -27
- package/es/components/breadcrumbs/breadcrumbs.js +4 -4
- package/es/components/breadcrumbs/types.js +1 -0
- package/es/components/button/button_group/button_group.js +16 -2
- package/es/components/button/button_group/button_group.styles.js +1 -1
- package/es/components/button/button_group/button_group_button.js +59 -5
- package/es/components/button/button_group/button_group_button.styles.js +39 -3
- package/es/components/datagrid/body/cell/data_grid_cell.js +97 -58
- package/es/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
- package/es/components/datagrid/body/cell/data_grid_cell_popover.js +64 -56
- package/es/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
- package/es/components/datagrid/body/cell/index.js +1 -1
- package/es/components/datagrid/body/data_grid_body.js +13 -0
- package/es/components/datagrid/body/data_grid_body_custom.js +52 -36
- package/es/components/datagrid/body/data_grid_body_virtualized.js +84 -56
- package/es/components/datagrid/body/data_grid_row_manager.js +6 -4
- package/es/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
- package/es/components/datagrid/body/header/data_grid_control_header_cell.js +5 -4
- package/es/components/datagrid/body/header/data_grid_header_cell.js +73 -53
- package/es/components/datagrid/body/header/data_grid_header_row.js +15 -551
- package/es/components/datagrid/body/header/use_data_grid_header.js +7 -6
- package/es/components/datagrid/controls/column_selector.js +126 -123
- package/es/components/datagrid/controls/column_sorting.js +605 -103
- package/es/components/datagrid/controls/column_sorting_draggable.js +24 -22
- package/es/components/datagrid/controls/display_selector.js +109 -107
- package/es/components/datagrid/data_grid.a11y.js +13 -12
- package/es/components/datagrid/data_grid.js +45 -22
- package/es/components/datagrid/utils/col_widths.js +12 -8
- package/es/components/datagrid/utils/focus.js +10 -8
- package/es/components/datagrid/utils/grid_height_width.js +31 -30
- package/es/components/datagrid/utils/ref.js +1 -1
- package/es/components/datagrid/utils/row_heights.js +2 -2
- package/es/components/datagrid/utils/sorting.js +29 -27
- package/es/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/es/components/date_picker/super_date_picker/super_update_button.js +57 -29
- package/es/components/flex/flex_grid.js +22 -8
- package/es/components/flex/flex_grid.styles.js +13 -6
- package/es/components/flex/flex_group.js +10 -11
- package/es/components/flex/flex_item.js +9 -11
- package/es/components/flex/flex_item.styles.js +107 -122
- package/es/components/flyout/flyout.js +16 -18
- package/es/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
- package/es/components/header/header_links/header_links.js +10 -2
- package/es/components/icon/icon.js +3 -3
- package/es/components/modal/confirm_modal.js +2 -1
- package/es/components/modal/modal.js +12 -3
- package/es/components/observer/resize_observer/resize_observer.js +15 -24
- package/es/components/panel/panel.js +2 -3
- package/es/components/resizable_container/resizable_button.js +2 -3
- package/es/components/resizable_container/resizable_collapse_button.js +2 -3
- package/es/components/resizable_container/resizable_container.js +1 -2
- package/es/components/resizable_container/resizable_container.styles.js +11 -14
- package/es/components/resizable_container/resizable_panel.js +6 -8
- package/es/components/resizable_container/resizable_panel.styles.js +18 -29
- package/es/components/selectable/selectable_list/selectable_list.js +26 -6
- package/es/components/spacer/spacer.js +2 -3
- package/es/components/toast/global_toast_list.js +70 -73
- package/es/components/toast/toast.js +27 -42
- package/es/components/toast/toast.styles.js +2 -17
- package/es/components/tool_tip/icon_tip.js +4 -3
- package/es/global_styling/mixins/_color.js +60 -32
- package/es/global_styling/mixins/_padding.js +60 -16
- package/es/services/color/eui_palettes.js +21 -13
- package/es/services/color/index.js +1 -1
- package/es/services/hooks/index.js +1 -0
- package/es/services/hooks/useDeepEqual.js +23 -0
- package/es/services/index.js +1 -1
- package/es/services/theme/style_memoization.js +1 -3
- package/eui.d.ts +2558 -2470
- package/i18ntokens.json +297 -279
- package/lib/components/breadcrumbs/_breadcrumb_content.js +372 -0
- package/lib/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
- package/lib/components/breadcrumbs/breadcrumb.js +11 -331
- package/lib/components/breadcrumbs/breadcrumb.styles.js +5 -29
- package/lib/components/breadcrumbs/breadcrumbs.js +3 -3
- package/lib/components/breadcrumbs/types.js +5 -0
- package/lib/components/button/button_group/button_group.js +16 -2
- package/lib/components/button/button_group/button_group.styles.js +1 -1
- package/lib/components/button/button_group/button_group_button.js +59 -5
- package/lib/components/button/button_group/button_group_button.styles.js +45 -11
- package/lib/components/datagrid/body/cell/data_grid_cell.js +95 -57
- package/lib/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
- package/lib/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
- package/lib/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
- package/lib/components/datagrid/body/cell/index.js +2 -2
- package/lib/components/datagrid/body/data_grid_body.js +13 -0
- package/lib/components/datagrid/body/data_grid_body_custom.js +51 -35
- package/lib/components/datagrid/body/data_grid_body_virtualized.js +83 -55
- package/lib/components/datagrid/body/data_grid_row_manager.js +5 -3
- package/lib/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
- package/lib/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
- package/lib/components/datagrid/body/header/data_grid_header_cell.js +72 -52
- package/lib/components/datagrid/body/header/data_grid_header_row.js +14 -550
- package/lib/components/datagrid/body/header/use_data_grid_header.js +7 -6
- package/lib/components/datagrid/controls/column_selector.js +126 -123
- package/lib/components/datagrid/controls/column_sorting.js +615 -110
- package/lib/components/datagrid/controls/column_sorting_draggable.js +27 -22
- package/lib/components/datagrid/controls/display_selector.js +109 -107
- package/lib/components/datagrid/data_grid.a11y.js +13 -12
- package/lib/components/datagrid/data_grid.js +43 -20
- package/lib/components/datagrid/utils/col_widths.js +12 -8
- package/lib/components/datagrid/utils/focus.js +10 -8
- package/lib/components/datagrid/utils/grid_height_width.js +29 -28
- package/lib/components/datagrid/utils/ref.js +1 -1
- package/lib/components/datagrid/utils/row_heights.js +1 -1
- package/lib/components/datagrid/utils/sorting.js +31 -29
- package/lib/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/lib/components/date_picker/super_date_picker/super_update_button.js +57 -29
- package/lib/components/flex/flex_grid.js +23 -7
- package/lib/components/flex/flex_grid.styles.js +13 -6
- package/lib/components/flex/flex_group.js +10 -10
- package/lib/components/flex/flex_item.js +13 -13
- package/lib/components/flex/flex_item.styles.js +107 -122
- package/lib/components/flyout/flyout.js +16 -18
- package/lib/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
- package/lib/components/header/header_links/header_links.js +10 -2
- package/lib/components/icon/icon.js +3 -3
- package/lib/components/modal/confirm_modal.js +2 -1
- package/lib/components/modal/modal.js +12 -3
- package/lib/components/observer/resize_observer/resize_observer.js +15 -24
- package/lib/components/panel/panel.js +1 -2
- package/lib/components/resizable_container/resizable_button.js +1 -2
- package/lib/components/resizable_container/resizable_collapse_button.js +1 -2
- package/lib/components/resizable_container/resizable_container.js +1 -2
- package/lib/components/resizable_container/resizable_container.styles.js +11 -14
- package/lib/components/resizable_container/resizable_panel.js +3 -5
- package/lib/components/resizable_container/resizable_panel.styles.js +17 -28
- package/lib/components/selectable/selectable_list/selectable_list.js +26 -6
- package/lib/components/spacer/spacer.js +1 -2
- package/lib/components/toast/global_toast_list.js +68 -71
- package/lib/components/toast/toast.js +25 -40
- package/lib/components/toast/toast.styles.js +11 -25
- package/lib/components/tool_tip/icon_tip.js +4 -3
- package/lib/global_styling/mixins/_color.js +65 -40
- package/lib/global_styling/mixins/_padding.js +66 -25
- package/lib/services/color/eui_palettes.js +24 -14
- package/lib/services/color/index.js +14 -0
- package/lib/services/hooks/index.js +11 -0
- package/lib/services/hooks/useDeepEqual.js +30 -0
- package/lib/services/index.js +15 -1
- package/lib/services/theme/style_memoization.js +1 -3
- package/optimize/es/components/breadcrumbs/_breadcrumb_content.js +153 -0
- package/optimize/es/components/breadcrumbs/_breadcrumb_content.styles.js +48 -0
- package/optimize/es/components/breadcrumbs/breadcrumb.js +10 -110
- package/optimize/es/components/breadcrumbs/breadcrumb.styles.js +5 -27
- package/optimize/es/components/breadcrumbs/breadcrumbs.js +4 -4
- package/optimize/es/components/breadcrumbs/types.js +1 -0
- package/optimize/es/components/button/button_group/button_group.js +2 -2
- package/optimize/es/components/button/button_group/button_group.styles.js +1 -1
- package/optimize/es/components/button/button_group/button_group_button.js +36 -4
- package/optimize/es/components/button/button_group/button_group_button.styles.js +39 -3
- package/optimize/es/components/datagrid/body/cell/data_grid_cell.js +80 -55
- package/optimize/es/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
- package/optimize/es/components/datagrid/body/cell/data_grid_cell_popover.js +64 -56
- package/optimize/es/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
- package/optimize/es/components/datagrid/body/cell/index.js +1 -1
- package/optimize/es/components/datagrid/body/data_grid_body_custom.js +39 -36
- package/optimize/es/components/datagrid/body/data_grid_body_virtualized.js +69 -49
- package/optimize/es/components/datagrid/body/data_grid_row_manager.js +6 -4
- package/optimize/es/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
- package/optimize/es/components/datagrid/body/header/data_grid_control_header_cell.js +4 -3
- package/optimize/es/components/datagrid/body/header/data_grid_header_cell.js +65 -49
- package/optimize/es/components/datagrid/body/header/data_grid_header_row.js +15 -13
- package/optimize/es/components/datagrid/body/header/use_data_grid_header.js +7 -6
- package/optimize/es/components/datagrid/controls/column_selector.js +126 -123
- package/optimize/es/components/datagrid/controls/column_sorting.js +121 -103
- package/optimize/es/components/datagrid/controls/column_sorting_draggable.js +24 -22
- package/optimize/es/components/datagrid/controls/display_selector.js +109 -107
- package/optimize/es/components/datagrid/data_grid.a11y.js +13 -12
- package/optimize/es/components/datagrid/data_grid.js +45 -22
- package/optimize/es/components/datagrid/utils/col_widths.js +9 -5
- package/optimize/es/components/datagrid/utils/focus.js +10 -8
- package/optimize/es/components/datagrid/utils/grid_height_width.js +31 -30
- package/optimize/es/components/datagrid/utils/ref.js +1 -1
- package/optimize/es/components/datagrid/utils/row_heights.js +2 -2
- package/optimize/es/components/datagrid/utils/sorting.js +29 -27
- package/optimize/es/components/date_picker/super_date_picker/super_update_button.js +49 -29
- package/optimize/es/components/flex/flex_grid.js +19 -8
- package/optimize/es/components/flex/flex_grid.styles.js +13 -6
- package/optimize/es/components/flex/flex_group.js +9 -10
- package/optimize/es/components/flex/flex_item.js +9 -11
- package/optimize/es/components/flex/flex_item.styles.js +107 -122
- package/optimize/es/components/flyout/flyout.js +16 -18
- package/optimize/es/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
- package/optimize/es/components/header/header_links/header_links.js +3 -2
- package/optimize/es/components/icon/icon.js +3 -3
- package/optimize/es/components/modal/confirm_modal.js +2 -1
- package/optimize/es/components/modal/modal.js +6 -2
- package/optimize/es/components/observer/resize_observer/resize_observer.js +15 -24
- package/optimize/es/components/panel/panel.js +2 -3
- package/optimize/es/components/resizable_container/resizable_button.js +2 -3
- package/optimize/es/components/resizable_container/resizable_collapse_button.js +2 -3
- package/optimize/es/components/resizable_container/resizable_container.js +1 -2
- package/optimize/es/components/resizable_container/resizable_container.styles.js +11 -14
- package/optimize/es/components/resizable_container/resizable_panel.js +6 -8
- package/optimize/es/components/resizable_container/resizable_panel.styles.js +18 -26
- package/optimize/es/components/selectable/selectable_list/selectable_list.js +26 -6
- package/optimize/es/components/spacer/spacer.js +2 -3
- package/optimize/es/components/toast/global_toast_list.js +70 -73
- package/optimize/es/components/toast/toast.js +27 -42
- package/optimize/es/components/toast/toast.styles.js +2 -17
- package/optimize/es/components/tool_tip/icon_tip.js +4 -3
- package/optimize/es/global_styling/mixins/_color.js +57 -32
- package/optimize/es/global_styling/mixins/_padding.js +52 -16
- package/optimize/es/services/color/eui_palettes.js +21 -13
- package/optimize/es/services/color/index.js +1 -1
- package/optimize/es/services/hooks/index.js +1 -0
- package/optimize/es/services/hooks/useDeepEqual.js +23 -0
- package/optimize/es/services/index.js +1 -1
- package/optimize/es/services/theme/style_memoization.js +1 -3
- package/optimize/lib/components/breadcrumbs/_breadcrumb_content.js +163 -0
- package/optimize/lib/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
- package/optimize/lib/components/breadcrumbs/breadcrumb.js +10 -113
- package/optimize/lib/components/breadcrumbs/breadcrumb.styles.js +5 -29
- package/optimize/lib/components/breadcrumbs/breadcrumbs.js +3 -3
- package/optimize/lib/components/breadcrumbs/types.js +5 -0
- package/optimize/lib/components/button/button_group/button_group.js +2 -2
- package/optimize/lib/components/button/button_group/button_group.styles.js +1 -1
- package/optimize/lib/components/button/button_group/button_group_button.js +37 -5
- package/optimize/lib/components/button/button_group/button_group_button.styles.js +45 -11
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell.js +78 -54
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
- package/optimize/lib/components/datagrid/body/cell/index.js +2 -2
- package/optimize/lib/components/datagrid/body/data_grid_body_custom.js +38 -35
- package/optimize/lib/components/datagrid/body/data_grid_body_virtualized.js +70 -50
- package/optimize/lib/components/datagrid/body/data_grid_row_manager.js +5 -3
- package/optimize/lib/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
- package/optimize/lib/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
- package/optimize/lib/components/datagrid/body/header/data_grid_header_cell.js +65 -49
- package/optimize/lib/components/datagrid/body/header/data_grid_header_row.js +14 -12
- package/optimize/lib/components/datagrid/body/header/use_data_grid_header.js +7 -6
- package/optimize/lib/components/datagrid/controls/column_selector.js +126 -123
- package/optimize/lib/components/datagrid/controls/column_sorting.js +125 -107
- package/optimize/lib/components/datagrid/controls/column_sorting_draggable.js +27 -22
- package/optimize/lib/components/datagrid/controls/display_selector.js +109 -107
- package/optimize/lib/components/datagrid/data_grid.a11y.js +13 -12
- package/optimize/lib/components/datagrid/data_grid.js +43 -20
- package/optimize/lib/components/datagrid/utils/col_widths.js +9 -5
- package/optimize/lib/components/datagrid/utils/focus.js +10 -8
- package/optimize/lib/components/datagrid/utils/grid_height_width.js +29 -28
- package/optimize/lib/components/datagrid/utils/ref.js +1 -1
- package/optimize/lib/components/datagrid/utils/row_heights.js +1 -1
- package/optimize/lib/components/datagrid/utils/sorting.js +31 -29
- package/optimize/lib/components/date_picker/super_date_picker/super_update_button.js +49 -29
- package/optimize/lib/components/flex/flex_grid.js +21 -7
- package/optimize/lib/components/flex/flex_grid.styles.js +13 -6
- package/optimize/lib/components/flex/flex_group.js +9 -9
- package/optimize/lib/components/flex/flex_item.js +13 -13
- package/optimize/lib/components/flex/flex_item.styles.js +107 -122
- package/optimize/lib/components/flyout/flyout.js +16 -18
- package/optimize/lib/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
- package/optimize/lib/components/header/header_links/header_links.js +3 -2
- package/optimize/lib/components/icon/icon.js +3 -3
- package/optimize/lib/components/modal/confirm_modal.js +2 -1
- package/optimize/lib/components/modal/modal.js +6 -2
- package/optimize/lib/components/observer/resize_observer/resize_observer.js +15 -24
- package/optimize/lib/components/panel/panel.js +1 -2
- package/optimize/lib/components/resizable_container/resizable_button.js +1 -2
- package/optimize/lib/components/resizable_container/resizable_collapse_button.js +1 -2
- package/optimize/lib/components/resizable_container/resizable_container.js +1 -2
- package/optimize/lib/components/resizable_container/resizable_container.styles.js +11 -14
- package/optimize/lib/components/resizable_container/resizable_panel.js +3 -5
- package/optimize/lib/components/resizable_container/resizable_panel.styles.js +17 -26
- package/optimize/lib/components/selectable/selectable_list/selectable_list.js +26 -6
- package/optimize/lib/components/spacer/spacer.js +1 -2
- package/optimize/lib/components/toast/global_toast_list.js +68 -71
- package/optimize/lib/components/toast/toast.js +25 -40
- package/optimize/lib/components/toast/toast.styles.js +11 -25
- package/optimize/lib/components/tool_tip/icon_tip.js +4 -3
- package/optimize/lib/global_styling/mixins/_color.js +63 -40
- package/optimize/lib/global_styling/mixins/_padding.js +59 -25
- package/optimize/lib/services/color/eui_palettes.js +24 -14
- package/optimize/lib/services/color/index.js +14 -0
- package/optimize/lib/services/hooks/index.js +11 -0
- package/optimize/lib/services/hooks/useDeepEqual.js +30 -0
- package/optimize/lib/services/index.js +15 -1
- package/optimize/lib/services/theme/style_memoization.js +1 -3
- package/package.json +8 -11
- package/src/components/form/text_area/_text_area.scss +5 -0
- package/src/components/selectable/selectable_list/_selectable_list.scss +2 -0
- package/test-env/components/breadcrumbs/_breadcrumb_content.js +363 -0
- package/test-env/components/breadcrumbs/_breadcrumb_content.styles.js +55 -0
- package/test-env/components/breadcrumbs/breadcrumb.js +11 -326
- package/test-env/components/breadcrumbs/breadcrumb.styles.js +5 -29
- package/test-env/components/breadcrumbs/breadcrumbs.js +3 -3
- package/test-env/components/breadcrumbs/types.js +5 -0
- package/test-env/components/button/button_group/button_group.js +16 -2
- package/test-env/components/button/button_group/button_group.styles.js +1 -1
- package/test-env/components/button/button_group/button_group_button.js +56 -5
- package/test-env/components/button/button_group/button_group_button.styles.js +45 -11
- package/test-env/components/datagrid/body/cell/data_grid_cell.js +95 -57
- package/test-env/components/datagrid/body/cell/data_grid_cell_actions.js +24 -18
- package/test-env/components/datagrid/body/cell/data_grid_cell_popover.js +63 -55
- package/test-env/components/datagrid/body/cell/data_grid_cell_wrapper.js +32 -31
- package/test-env/components/datagrid/body/cell/index.js +2 -2
- package/test-env/components/datagrid/body/data_grid_body.js +13 -0
- package/test-env/components/datagrid/body/data_grid_body_custom.js +51 -35
- package/test-env/components/datagrid/body/data_grid_body_virtualized.js +83 -55
- package/test-env/components/datagrid/body/data_grid_row_manager.js +5 -3
- package/test-env/components/datagrid/body/footer/use_data_grid_footer.js +1 -2
- package/test-env/components/datagrid/body/header/data_grid_control_header_cell.js +8 -4
- package/test-env/components/datagrid/body/header/data_grid_header_cell.js +72 -52
- package/test-env/components/datagrid/body/header/data_grid_header_row.js +14 -550
- package/test-env/components/datagrid/body/header/use_data_grid_header.js +7 -6
- package/test-env/components/datagrid/controls/column_selector.js +126 -123
- package/test-env/components/datagrid/controls/column_sorting.js +607 -106
- package/test-env/components/datagrid/controls/column_sorting_draggable.js +27 -22
- package/test-env/components/datagrid/controls/display_selector.js +109 -107
- package/test-env/components/datagrid/data_grid.a11y.js +13 -12
- package/test-env/components/datagrid/data_grid.js +43 -20
- package/test-env/components/datagrid/utils/col_widths.js +9 -5
- package/test-env/components/datagrid/utils/focus.js +10 -8
- package/test-env/components/datagrid/utils/grid_height_width.js +29 -28
- package/test-env/components/datagrid/utils/ref.js +1 -1
- package/test-env/components/datagrid/utils/row_heights.js +1 -1
- package/test-env/components/datagrid/utils/sorting.js +31 -29
- package/test-env/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/test-env/components/date_picker/super_date_picker/super_update_button.js +57 -29
- package/test-env/components/flex/flex_grid.js +21 -7
- package/test-env/components/flex/flex_grid.styles.js +13 -6
- package/test-env/components/flex/flex_group.js +10 -10
- package/test-env/components/flex/flex_item.js +13 -13
- package/test-env/components/flex/flex_item.styles.js +107 -122
- package/test-env/components/header/header_breadcrumbs/header_breadcrumbs.js +3 -5
- package/test-env/components/header/header_links/header_links.js +10 -2
- package/test-env/components/modal/confirm_modal.js +2 -1
- package/test-env/components/modal/modal.js +12 -3
- package/test-env/components/panel/panel.js +1 -2
- package/test-env/components/resizable_container/resizable_button.js +1 -2
- package/test-env/components/resizable_container/resizable_collapse_button.js +1 -2
- package/test-env/components/resizable_container/resizable_container.js +1 -2
- package/test-env/components/resizable_container/resizable_container.styles.js +11 -14
- package/test-env/components/resizable_container/resizable_panel.js +3 -5
- package/test-env/components/resizable_container/resizable_panel.styles.js +17 -26
- package/test-env/components/selectable/selectable_list/selectable_list.js +26 -6
- package/test-env/components/spacer/spacer.js +1 -2
- package/test-env/components/toast/global_toast_list.js +68 -71
- package/test-env/components/toast/toast.js +25 -40
- package/test-env/components/toast/toast.styles.js +11 -25
- package/test-env/components/tool_tip/icon_tip.js +4 -3
- package/test-env/global_styling/mixins/_color.js +63 -40
- package/test-env/global_styling/mixins/_padding.js +59 -25
- package/test-env/services/color/eui_palettes.js +24 -14
- package/test-env/services/color/index.js +14 -0
- package/test-env/services/hooks/index.js +11 -0
- package/test-env/services/hooks/useDeepEqual.js +30 -0
- package/test-env/services/index.js +15 -1
- package/test-env/services/theme/style_memoization.js +1 -3
- package/src/themes/charts/theme.scss +0 -5
|
@@ -87,33 +87,31 @@ export var EuiFlyout = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
87
87
|
resizeRef = _useState2[0],
|
|
88
88
|
setResizeRef = _useState2[1];
|
|
89
89
|
var setRef = useCombinedRefs([setResizeRef, ref]);
|
|
90
|
-
|
|
91
|
-
|
|
90
|
+
var _useResizeObserver = useResizeObserver(isPushed ? resizeRef : null, 'width'),
|
|
91
|
+
width = _useResizeObserver.width;
|
|
92
92
|
useEffect(function () {
|
|
93
|
-
// This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
|
|
94
|
-
document.body.classList.add('euiBody--hasFlyout');
|
|
95
|
-
|
|
96
93
|
/**
|
|
97
94
|
* Accomodate for the `isPushed` state by adding padding to the body equal to the width of the element
|
|
98
95
|
*/
|
|
99
96
|
if (isPushed) {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
document.body.style
|
|
104
|
-
}
|
|
97
|
+
var paddingSide = side === 'left' ? 'paddingInlineStart' : 'paddingInlineEnd';
|
|
98
|
+
document.body.style[paddingSide] = "".concat(width, "px");
|
|
99
|
+
return function () {
|
|
100
|
+
document.body.style[paddingSide] = '';
|
|
101
|
+
};
|
|
105
102
|
}
|
|
103
|
+
}, [isPushed, side, width]);
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
|
|
107
|
+
*/
|
|
108
|
+
useEffect(function () {
|
|
109
|
+
document.body.classList.add('euiBody--hasFlyout');
|
|
106
110
|
return function () {
|
|
111
|
+
// Remove the hasFlyout class when the flyout is unmounted
|
|
107
112
|
document.body.classList.remove('euiBody--hasFlyout');
|
|
108
|
-
if (isPushed) {
|
|
109
|
-
if (side === 'right') {
|
|
110
|
-
document.body.style.paddingInlineEnd = '';
|
|
111
|
-
} else if (side === 'left') {
|
|
112
|
-
document.body.style.paddingInlineStart = '';
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
113
|
};
|
|
116
|
-
}, [
|
|
114
|
+
}, []);
|
|
117
115
|
|
|
118
116
|
/**
|
|
119
117
|
* ESC key closes flyout (always?)
|
|
@@ -11,24 +11,22 @@ var _excluded = ["className", "breadcrumbs"];
|
|
|
11
11
|
|
|
12
12
|
import React from 'react';
|
|
13
13
|
import classNames from 'classnames';
|
|
14
|
+
import { useEuiMemoizedStyles } from '../../../services';
|
|
14
15
|
import { EuiBreadcrumbs } from '../../breadcrumbs';
|
|
15
16
|
import { euiHeaderBreadcrumbsStyles } from './header_breadcrumbs.styles';
|
|
16
|
-
import { useEuiTheme } from '../../../services';
|
|
17
17
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
18
18
|
export var EuiHeaderBreadcrumbs = function EuiHeaderBreadcrumbs(_ref) {
|
|
19
19
|
var className = _ref.className,
|
|
20
20
|
breadcrumbs = _ref.breadcrumbs,
|
|
21
21
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
22
22
|
var classes = classNames('euiHeaderBreadcrumbs', className);
|
|
23
|
-
var
|
|
24
|
-
var styles = euiHeaderBreadcrumbsStyles(euiTheme);
|
|
25
|
-
var cssHeaderBreadcrumbStyles = [styles.euiHeaderBreadcrumbs];
|
|
23
|
+
var styles = useEuiMemoizedStyles(euiHeaderBreadcrumbsStyles);
|
|
26
24
|
return ___EmotionJSX(EuiBreadcrumbs, _extends({
|
|
27
25
|
max: 4,
|
|
28
26
|
truncate: true,
|
|
29
27
|
breadcrumbs: breadcrumbs,
|
|
30
28
|
className: classes,
|
|
31
|
-
css:
|
|
29
|
+
css: styles.euiHeaderBreadcrumbs,
|
|
32
30
|
type: "application"
|
|
33
31
|
}, rest));
|
|
34
32
|
};
|
|
@@ -71,6 +71,7 @@ export var EuiHeaderLinks = function EuiHeaderLinks(_ref) {
|
|
|
71
71
|
size: "m"
|
|
72
72
|
}));
|
|
73
73
|
});
|
|
74
|
+
var renderedChildren = typeof children === 'function' ? children(closeMenu) : children;
|
|
74
75
|
return ___EmotionJSX(EuiI18n, {
|
|
75
76
|
token: "euiHeaderLinks.appNavigation",
|
|
76
77
|
default: "App menu"
|
|
@@ -84,7 +85,7 @@ export var EuiHeaderLinks = function EuiHeaderLinks(_ref) {
|
|
|
84
85
|
}, ___EmotionJSX("div", {
|
|
85
86
|
className: "euiHeaderLinks__list",
|
|
86
87
|
css: [styles.euiHeaderLinks__list, styles.gutterSizes[gutterSize], ";label:EuiHeaderLinks;"]
|
|
87
|
-
},
|
|
88
|
+
}, renderedChildren)), ___EmotionJSX(EuiShowFor, {
|
|
88
89
|
sizes: popoverBreakpoints
|
|
89
90
|
}, ___EmotionJSX(EuiPopover, _extends({
|
|
90
91
|
button: button,
|
|
@@ -96,6 +97,6 @@ export var EuiHeaderLinks = function EuiHeaderLinks(_ref) {
|
|
|
96
97
|
}, popoverProps), ___EmotionJSX("div", {
|
|
97
98
|
className: "euiHeaderLinks__mobileList",
|
|
98
99
|
css: styles.euiHeaderLinks__mobileList
|
|
99
|
-
},
|
|
100
|
+
}, renderedChildren))));
|
|
100
101
|
});
|
|
101
102
|
};
|
|
@@ -216,8 +216,8 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
216
216
|
} else {
|
|
217
217
|
var Svg = icon;
|
|
218
218
|
|
|
219
|
-
// If
|
|
220
|
-
var isAriaHidden =
|
|
219
|
+
// If there is no aria-label, aria-labelledby, or title it gets aria-hidden true
|
|
220
|
+
var isAriaHidden = !(this.props['aria-label'] || this.props['aria-labelledby'] || this.props.title);
|
|
221
221
|
|
|
222
222
|
// If no aria-label or aria-labelledby is provided but there's a title, a titleId is generated
|
|
223
223
|
// The svg aria-labelledby attribute gets this titleId
|
|
@@ -237,7 +237,7 @@ export var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
237
237
|
"data-is-loaded": isLoaded || undefined,
|
|
238
238
|
"data-is-loading": isLoading || undefined
|
|
239
239
|
}, rest, {
|
|
240
|
-
"aria-hidden": isAriaHidden ||
|
|
240
|
+
"aria-hidden": isAriaHidden || rest['aria-hidden']
|
|
241
241
|
}));
|
|
242
242
|
}
|
|
243
243
|
}
|
|
@@ -72,7 +72,8 @@ export var EuiConfirmModal = function EuiConfirmModal(_ref) {
|
|
|
72
72
|
return ___EmotionJSX(EuiModal, _extends({
|
|
73
73
|
className: classes,
|
|
74
74
|
css: cssStyles,
|
|
75
|
-
onClose: onCancel
|
|
75
|
+
onClose: onCancel,
|
|
76
|
+
role: "alertdialog"
|
|
76
77
|
}, rest), modalTitle, message && ___EmotionJSX(EuiModalBody, null, ___EmotionJSX(EuiText, {
|
|
77
78
|
"data-test-subj": "confirmModalBodyText"
|
|
78
79
|
}, message)), ___EmotionJSX(EuiModalFooter, null, ___EmotionJSX(EuiButtonEmpty, {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
-
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "style"];
|
|
4
|
+
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "role", "style"];
|
|
5
5
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
6
6
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7
7
|
/*
|
|
@@ -28,6 +28,8 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
28
28
|
onClose = _ref.onClose,
|
|
29
29
|
_ref$maxWidth = _ref.maxWidth,
|
|
30
30
|
maxWidth = _ref$maxWidth === void 0 ? true : _ref$maxWidth,
|
|
31
|
+
_ref$role = _ref.role,
|
|
32
|
+
role = _ref$role === void 0 ? 'dialog' : _ref$role,
|
|
31
33
|
style = _ref.style,
|
|
32
34
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
33
35
|
var onKeyDown = function onKeyDown(event) {
|
|
@@ -57,7 +59,9 @@ export var EuiModal = function EuiModal(_ref) {
|
|
|
57
59
|
className: classes,
|
|
58
60
|
onKeyDown: onKeyDown,
|
|
59
61
|
tabIndex: 0,
|
|
60
|
-
style: newStyle
|
|
62
|
+
style: newStyle,
|
|
63
|
+
role: role,
|
|
64
|
+
"aria-modal": true
|
|
61
65
|
}, rest), ___EmotionJSX(EuiI18n, {
|
|
62
66
|
token: "euiModal.closeModal",
|
|
63
67
|
default: "Closes this modal window"
|
|
@@ -34,14 +34,13 @@ export var EuiResizeObserver = /*#__PURE__*/function (_EuiObserver) {
|
|
|
34
34
|
height: 0,
|
|
35
35
|
width: 0
|
|
36
36
|
});
|
|
37
|
-
_defineProperty(_assertThisInitialized(_this), "onResize", function () {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
width = _this$childNode$getBo.width;
|
|
37
|
+
_defineProperty(_assertThisInitialized(_this), "onResize", function (_ref) {
|
|
38
|
+
var _ref2 = _slicedToArray(_ref, 1),
|
|
39
|
+
entry = _ref2[0];
|
|
40
|
+
var _entry$borderBoxSize$ = entry.borderBoxSize[0],
|
|
41
|
+
width = _entry$borderBoxSize$.inlineSize,
|
|
42
|
+
height = _entry$borderBoxSize$.blockSize;
|
|
43
|
+
|
|
45
44
|
// Check for actual resize event
|
|
46
45
|
if (_this.state.height === height && _this.state.width === width) {
|
|
47
46
|
return;
|
|
@@ -95,23 +94,15 @@ export var useResizeObserver = function useResizeObserver(container, dimension)
|
|
|
95
94
|
}, [dimension]);
|
|
96
95
|
useEffect(function () {
|
|
97
96
|
if (container != null) {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
});
|
|
105
|
-
var observer = makeResizeObserver(container, function () {
|
|
106
|
-
// `entry.contentRect` provides incomplete `height` and `width` data.
|
|
107
|
-
// Use `getBoundingClientRect` to account for padding and border.
|
|
108
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/DOMRectReadOnly
|
|
109
|
-
var _container$getBoundin = container.getBoundingClientRect(),
|
|
110
|
-
height = _container$getBoundin.height,
|
|
111
|
-
width = _container$getBoundin.width;
|
|
97
|
+
var observer = makeResizeObserver(container, function (_ref3) {
|
|
98
|
+
var _ref4 = _slicedToArray(_ref3, 1),
|
|
99
|
+
entry = _ref4[0];
|
|
100
|
+
var _entry$borderBoxSize$2 = entry.borderBoxSize[0],
|
|
101
|
+
inlineSize = _entry$borderBoxSize$2.inlineSize,
|
|
102
|
+
blockSize = _entry$borderBoxSize$2.blockSize;
|
|
112
103
|
setSize({
|
|
113
|
-
width:
|
|
114
|
-
height:
|
|
104
|
+
width: inlineSize,
|
|
105
|
+
height: blockSize
|
|
115
106
|
});
|
|
116
107
|
});
|
|
117
108
|
return function () {
|
|
@@ -12,7 +12,7 @@ var _excluded = ["children", "className", "paddingSize", "borderRadius", "color"
|
|
|
12
12
|
|
|
13
13
|
import React from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
-
import {
|
|
15
|
+
import { useEuiMemoizedStyles } from '../../services';
|
|
16
16
|
import { useEuiBackgroundColorCSS, useEuiPaddingCSS, BACKGROUND_COLORS, PADDING_SIZES } from '../../global_styling';
|
|
17
17
|
import { keysOf } from '../common';
|
|
18
18
|
import { euiPanelStyles } from './panel.styles';
|
|
@@ -48,11 +48,10 @@ export var EuiPanel = function EuiPanel(_ref) {
|
|
|
48
48
|
panelRef = _ref.panelRef,
|
|
49
49
|
element = _ref.element,
|
|
50
50
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
51
|
-
var euiTheme = useEuiTheme();
|
|
52
51
|
// Shadows are only allowed when there's a white background (plain)
|
|
53
52
|
var canHaveShadow = !hasBorder && color === 'plain';
|
|
54
53
|
var canHaveBorder = color === 'plain' || color === 'transparent';
|
|
55
|
-
var styles = euiPanelStyles
|
|
54
|
+
var styles = useEuiMemoizedStyles(euiPanelStyles);
|
|
56
55
|
var cssStyles = [styles.euiPanel, grow && styles.grow, styles.radius[borderRadius], useEuiPaddingCSS()[paddingSize], useEuiBackgroundColorCSS()[color], canHaveShadow && hasShadow === true && styles.hasShadow, canHaveBorder && hasBorder === true && styles.hasBorder, rest.onClick && styles.isClickable];
|
|
57
56
|
var classes = classNames('euiPanel', "euiPanel--".concat(color), _defineProperty({}, "euiPanel--".concat(paddingSizeToClassNameMap[paddingSize]), paddingSizeToClassNameMap[paddingSize]), className);
|
|
58
57
|
if (rest.onClick && element !== 'div') {
|
|
@@ -14,7 +14,7 @@ var _excluded = ["isHorizontal", "indicator", "alignIndicator", "className"],
|
|
|
14
14
|
import React, { useCallback, useMemo, useRef, forwardRef } from 'react';
|
|
15
15
|
import classNames from 'classnames';
|
|
16
16
|
import { EuiI18n } from '../i18n';
|
|
17
|
-
import {
|
|
17
|
+
import { useEuiMemoizedStyles, useGeneratedHtmlId } from '../../services';
|
|
18
18
|
import { useEuiResizableContainerContext } from './context';
|
|
19
19
|
import { euiResizableButtonStyles } from './resizable_button.styles';
|
|
20
20
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
@@ -32,8 +32,7 @@ export var EuiResizableButton = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
32
32
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
33
33
|
var classes = classNames('euiResizableButton', className);
|
|
34
34
|
var resizeDirection = isHorizontal ? 'horizontal' : 'vertical';
|
|
35
|
-
var
|
|
36
|
-
var styles = euiResizableButtonStyles(euiTheme);
|
|
35
|
+
var styles = useEuiMemoizedStyles(euiResizableButtonStyles);
|
|
37
36
|
var cssStyles = [styles.euiResizableButton, styles[indicator], styles["".concat(indicator, "Direction")][resizeDirection], styles[resizeDirection], indicator === 'handle' && styles.alignIndicator[alignIndicator]];
|
|
38
37
|
return ___EmotionJSX(EuiI18n, {
|
|
39
38
|
tokens: ['euiResizableButton.horizontalResizerAriaLabel', 'euiResizableButton.verticalResizerAriaLabel'],
|
|
@@ -12,7 +12,7 @@ var _excluded = ["className", "externalPosition", "internalPosition", "direction
|
|
|
12
12
|
|
|
13
13
|
import React from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
-
import {
|
|
15
|
+
import { useEuiMemoizedStyles } from '../../services';
|
|
16
16
|
import { EuiButtonIcon } from '../button';
|
|
17
17
|
import { euiScreenReaderOnlyStyles } from '../accessibility/screen_reader_only/screen_reader_only.styles';
|
|
18
18
|
import { euiResizableCollapseButtonStyles } from './resizable_collapse_button.styles';
|
|
@@ -31,8 +31,7 @@ export var EuiResizableCollapseButton = function EuiResizableCollapseButton(_ref
|
|
|
31
31
|
var isHorizontal = direction === 'horizontal';
|
|
32
32
|
var showOnFocus = !isCollapsed && !isVisible;
|
|
33
33
|
var screenReaderOnlyStyles = euiScreenReaderOnlyStyles(showOnFocus).euiScreenReaderOnly;
|
|
34
|
-
var
|
|
35
|
-
var styles = euiResizableCollapseButtonStyles(euiTheme);
|
|
34
|
+
var styles = useEuiMemoizedStyles(euiResizableCollapseButtonStyles);
|
|
36
35
|
var collapsedStyles = [styles.collapsed.collapsed, styles.collapsed[direction], styles.collapsed["".concat(direction, "Positions")][internalPosition]];
|
|
37
36
|
var collapsibleStyles = [styles.collapsible.collapsible, styles.collapsible[direction][externalPosition], styles.collapsible[direction][internalPosition]];
|
|
38
37
|
var cssStyles = [styles.euiResizableCollapseButton, showOnFocus && screenReaderOnlyStyles].concat(_toConsumableArray(isCollapsed ? collapsedStyles : collapsibleStyles));
|
|
@@ -21,7 +21,7 @@ import { EuiResizableContainerContextProvider } from './context';
|
|
|
21
21
|
import { euiResizableButtonWithControls } from './resizable_button';
|
|
22
22
|
import { euiResizablePanelWithControls, getModeType } from './resizable_panel';
|
|
23
23
|
import { useContainerCallbacks, getPosition } from './helpers';
|
|
24
|
-
import { euiResizableContainerStyles } from './resizable_container.styles';
|
|
24
|
+
import { euiResizableContainerStyles as styles } from './resizable_container.styles';
|
|
25
25
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
26
26
|
var initialState = {
|
|
27
27
|
isDragging: false,
|
|
@@ -49,7 +49,6 @@ export var EuiResizableContainer = function EuiResizableContainer(_ref) {
|
|
|
49
49
|
var containerRef = useRef(null);
|
|
50
50
|
var isHorizontal = direction === 'horizontal';
|
|
51
51
|
var classes = classNames('euiResizableContainer', className);
|
|
52
|
-
var styles = euiResizableContainerStyles();
|
|
53
52
|
var cssStyles = [styles.euiResizableContainer, styles[direction]];
|
|
54
53
|
var _useContainerCallback = useContainerCallbacks({
|
|
55
54
|
initialState: _objectSpread(_objectSpread({}, initialState), {}, {
|
|
@@ -9,18 +9,15 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
9
9
|
|
|
10
10
|
import { css } from '@emotion/react';
|
|
11
11
|
import { logicalCSS } from '../../global_styling';
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
horizontal: /*#__PURE__*/css(";label:horizontal;"),
|
|
24
|
-
vertical: _ref
|
|
25
|
-
};
|
|
12
|
+
export var euiResizableContainerStyles = {
|
|
13
|
+
euiResizableContainer: /*#__PURE__*/css("display:flex;", logicalCSS('width', '100%'), ";;label:euiResizableContainer;"),
|
|
14
|
+
horizontal: /*#__PURE__*/css(";label:horizontal;"),
|
|
15
|
+
vertical: process.env.NODE_ENV === "production" ? {
|
|
16
|
+
name: "omnk2l-vertical",
|
|
17
|
+
styles: "flex-direction:column;label:vertical;"
|
|
18
|
+
} : {
|
|
19
|
+
name: "omnk2l-vertical",
|
|
20
|
+
styles: "flex-direction:column;label:vertical;",
|
|
21
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
22
|
+
}
|
|
26
23
|
};
|
|
@@ -15,13 +15,13 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
15
15
|
|
|
16
16
|
import React, { useEffect, useMemo, useRef } from 'react';
|
|
17
17
|
import classNames from 'classnames';
|
|
18
|
-
import { useGeneratedHtmlId,
|
|
19
|
-
import { logicalSizeStyle,
|
|
18
|
+
import { useGeneratedHtmlId, useEuiMemoizedStyles } from '../../services';
|
|
19
|
+
import { logicalSizeStyle, useEuiPaddingSize, useEuiPaddingCSS } from '../../global_styling';
|
|
20
20
|
import { useEuiResizableContainerContext } from './context';
|
|
21
21
|
import { EuiPanel } from '../panel';
|
|
22
22
|
import { useEuiI18n } from '../i18n';
|
|
23
23
|
import { EuiResizableCollapseButton } from './resizable_collapse_button';
|
|
24
|
-
import { euiResizablePanelStyles, euiResizablePanelContentStyles } from './resizable_panel.styles';
|
|
24
|
+
import { euiResizablePanelStyles as styles, euiResizablePanelContentStyles } from './resizable_panel.styles';
|
|
25
25
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
26
26
|
var defaultToggleOptions = {
|
|
27
27
|
className: null,
|
|
@@ -133,15 +133,13 @@ export var EuiResizablePanel = function EuiResizablePanel(_ref) {
|
|
|
133
133
|
return direction;
|
|
134
134
|
}, [isCollapsed, isCollapsible, position, panels, panelId]);
|
|
135
135
|
var axis = isHorizontal ? 'horizontal' : 'vertical';
|
|
136
|
-
var
|
|
137
|
-
var
|
|
138
|
-
var cssStyles = [styles.euiResizablePanel, isCollapsed && styles.collapsed, styles.paddingSizes[wrapperPadding], wrapperProps === null || wrapperProps === void 0 ? void 0 : wrapperProps.css];
|
|
139
|
-
var contentStyles = euiResizablePanelContentStyles(euiTheme);
|
|
136
|
+
var cssStyles = [styles.euiResizablePanel, isCollapsed && styles.collapsed, useEuiPaddingCSS()[wrapperPadding], wrapperProps === null || wrapperProps === void 0 ? void 0 : wrapperProps.css];
|
|
137
|
+
var contentStyles = useEuiMemoizedStyles(euiResizablePanelContentStyles);
|
|
140
138
|
var contentCssStyles = [contentStyles.euiResizablePanel__content, scrollable && contentStyles.scrollable, isCollapsed && contentStyles.collapsedChildren, isCollapsed && !isCollapsible && contentStyles[axis].collapsed, isCollapsible && contentStyles[axis].hasCollapsibleButton];
|
|
141
139
|
var classes = classNames('euiResizablePanel', wrapperProps === null || wrapperProps === void 0 ? void 0 : wrapperProps.className);
|
|
142
140
|
var panelClasses = classNames('euiResizablePanel__content', className);
|
|
143
141
|
var inlineStyles = _objectSpread(_objectSpread({}, wrapperProps === null || wrapperProps === void 0 ? void 0 : wrapperProps.style), isHorizontal ? logicalSizeStyle("".concat(size || innerSize, "%"), 'auto') : logicalSizeStyle('100%', "".concat(size || innerSize, "%")));
|
|
144
|
-
var padding =
|
|
142
|
+
var padding = useEuiPaddingSize(paddingSize) || '0px';
|
|
145
143
|
useEffect(function () {
|
|
146
144
|
if (!registration) return;
|
|
147
145
|
var initSize = size !== null && size !== void 0 ? size : initialSize || 0;
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
1
|
function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
|
|
5
2
|
/*
|
|
6
3
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
@@ -11,29 +8,24 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
11
8
|
*/
|
|
12
9
|
|
|
13
10
|
import { css } from '@emotion/react';
|
|
14
|
-
import { logicalCSS, logicalCSSWithFallback, euiScrollBarStyles
|
|
15
|
-
var
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
return {
|
|
33
|
-
euiResizablePanel: _ref3,
|
|
34
|
-
collapsed: _ref2,
|
|
35
|
-
paddingSizes: _objectSpread({}, euiPaddingSizeCSS(euiThemeContext))
|
|
36
|
-
};
|
|
11
|
+
import { logicalCSS, logicalCSSWithFallback, euiScrollBarStyles } from '../../global_styling';
|
|
12
|
+
export var euiResizablePanelStyles = {
|
|
13
|
+
euiResizablePanel: process.env.NODE_ENV === "production" ? {
|
|
14
|
+
name: "15ifdgc-euiResizablePanel",
|
|
15
|
+
styles: "position:relative;label:euiResizablePanel;"
|
|
16
|
+
} : {
|
|
17
|
+
name: "15ifdgc-euiResizablePanel",
|
|
18
|
+
styles: "position:relative;label:euiResizablePanel;",
|
|
19
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
20
|
+
},
|
|
21
|
+
collapsed: process.env.NODE_ENV === "production" ? {
|
|
22
|
+
name: "11qmbh3-collapsed",
|
|
23
|
+
styles: "overflow:hidden;label:collapsed;"
|
|
24
|
+
} : {
|
|
25
|
+
name: "11qmbh3-collapsed",
|
|
26
|
+
styles: "overflow:hidden;label:collapsed;",
|
|
27
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
28
|
+
}
|
|
37
29
|
};
|
|
38
30
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
39
31
|
name: "597kt8-collapsedChildren",
|
|
@@ -415,14 +415,30 @@ export var EuiSelectableList = /*#__PURE__*/function (_Component) {
|
|
|
415
415
|
key: "componentDidUpdate",
|
|
416
416
|
value: function componentDidUpdate(prevProps) {
|
|
417
417
|
var _this$props9 = this.props,
|
|
418
|
+
isVirtualized = _this$props9.isVirtualized,
|
|
418
419
|
activeOptionIndex = _this$props9.activeOptionIndex,
|
|
419
420
|
visibleOptions = _this$props9.visibleOptions,
|
|
420
421
|
options = _this$props9.options;
|
|
421
|
-
if (
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
422
|
+
if (prevProps.activeOptionIndex !== activeOptionIndex) {
|
|
423
|
+
var makeOptionId = this.props.makeOptionId;
|
|
424
|
+
if (this.listBoxRef && this.props.searchable !== true) {
|
|
425
|
+
this.listBoxRef.setAttribute('aria-activedescendant', makeOptionId(activeOptionIndex));
|
|
426
|
+
}
|
|
427
|
+
if (typeof activeOptionIndex !== 'undefined') {
|
|
428
|
+
if (isVirtualized) {
|
|
429
|
+
var _this$listRef;
|
|
430
|
+
(_this$listRef = this.listRef) === null || _this$listRef === void 0 ? void 0 : _this$listRef.scrollToItem(activeOptionIndex, 'auto');
|
|
431
|
+
} else {
|
|
432
|
+
var _this$listBoxRef;
|
|
433
|
+
var activeOptionId = "#".concat(makeOptionId(activeOptionIndex));
|
|
434
|
+
var activeOptionEl = (_this$listBoxRef = this.listBoxRef) === null || _this$listBoxRef === void 0 ? void 0 : _this$listBoxRef.querySelector(activeOptionId);
|
|
435
|
+
if (activeOptionEl) {
|
|
436
|
+
activeOptionEl.scrollIntoView({
|
|
437
|
+
block: 'nearest'
|
|
438
|
+
});
|
|
439
|
+
}
|
|
440
|
+
}
|
|
441
|
+
}
|
|
426
442
|
}
|
|
427
443
|
if (prevProps.visibleOptions !== visibleOptions || prevProps.options !== options) {
|
|
428
444
|
var optionArray = visibleOptions || options;
|
|
@@ -465,14 +481,18 @@ export var EuiSelectableList = /*#__PURE__*/function (_Component) {
|
|
|
465
481
|
textWrap = _this$props10.textWrap,
|
|
466
482
|
truncationProps = _this$props10.truncationProps,
|
|
467
483
|
rest = _objectWithoutProperties(_this$props10, _excluded3);
|
|
484
|
+
var heightIsFull = forcedHeight === 'full';
|
|
468
485
|
var classes = classNames('euiSelectableList', {
|
|
469
|
-
'euiSelectableList-fullHeight':
|
|
486
|
+
'euiSelectableList-fullHeight': heightIsFull,
|
|
470
487
|
'euiSelectableList-bordered': bordered
|
|
471
488
|
}, className);
|
|
472
489
|
return ___EmotionJSX("div", _extends({
|
|
473
490
|
className: classes
|
|
474
491
|
}, rest), isVirtualized ? this.renderVirtualizedList() : ___EmotionJSX("div", {
|
|
475
492
|
className: "euiSelectableList__list",
|
|
493
|
+
style: !heightIsFull ? {
|
|
494
|
+
blockSize: forcedHeight
|
|
495
|
+
} : undefined,
|
|
476
496
|
ref: this.removeScrollableTabStop
|
|
477
497
|
}, ___EmotionJSX("ul", {
|
|
478
498
|
ref: this.setListBoxRef
|
|
@@ -12,7 +12,7 @@ var _excluded = ["className", "size"];
|
|
|
12
12
|
|
|
13
13
|
import React from 'react';
|
|
14
14
|
import classNames from 'classnames';
|
|
15
|
-
import {
|
|
15
|
+
import { useEuiMemoizedStyles } from '../../services';
|
|
16
16
|
import { euiSpacerStyles } from './spacer.styles';
|
|
17
17
|
import { jsx as ___EmotionJSX } from "@emotion/react";
|
|
18
18
|
export var SIZES = ['xs', 's', 'm', 'l', 'xl', 'xxl'];
|
|
@@ -21,8 +21,7 @@ export var EuiSpacer = function EuiSpacer(_ref) {
|
|
|
21
21
|
_ref$size = _ref.size,
|
|
22
22
|
size = _ref$size === void 0 ? 'l' : _ref$size,
|
|
23
23
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
24
|
-
var
|
|
25
|
-
var styles = euiSpacerStyles(euiTheme);
|
|
24
|
+
var styles = useEuiMemoizedStyles(euiSpacerStyles);
|
|
26
25
|
var classes = classNames('euiSpacer', _defineProperty({}, "euiSpacer--".concat(size), size), className);
|
|
27
26
|
var cssStyles = [styles.euiSpacer, styles[size]];
|
|
28
27
|
return ___EmotionJSX("div", _extends({
|