@elastic/eui 93.2.0 → 93.4.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 -324
- package/es/components/breadcrumbs/breadcrumb.styles.js +5 -27
- package/es/components/breadcrumbs/breadcrumbs.js +8 -6
- package/es/components/breadcrumbs/types.js +1 -0
- package/es/components/button/button_display/_button_display.js +2 -3
- package/es/components/button/button_empty/button_empty.js +2 -3
- package/es/components/button/button_group/button_group.js +19 -7
- package/es/components/button/button_group/button_group.styles.js +11 -14
- 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/button/button_icon/button_icon.js +4 -5
- package/es/components/button/button_icon/button_icon.styles.js +11 -3
- package/es/components/datagrid/body/cell/data_grid_cell.js +102 -59
- 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 +34 -31
- package/es/components/datagrid/body/cell/index.js +1 -1
- package/es/components/datagrid/body/data_grid_body.js +14 -0
- package/es/components/datagrid/body/data_grid_body_custom.js +54 -35
- package/es/components/datagrid/body/data_grid_body_virtualized.js +87 -56
- package/es/components/datagrid/body/data_grid_row_manager.js +7 -5
- 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 +47 -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/facet/facet_button.styles.js +1 -2
- 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 +7 -7
- package/es/components/icon/icon.js +13 -16
- package/es/components/icon/icon.styles.js +6 -9
- package/es/components/link/external_link_icon.js +11 -8
- package/es/components/link/link.js +2 -3
- package/es/components/link/link.styles.js +4 -10
- 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/page/page_header/page_header_content.js +4 -2
- package/es/components/progress/progress.styles.js +2 -2
- package/es/components/skeleton/skeleton_circle.js +2 -3
- package/es/components/skeleton/skeleton_rectangle.js +2 -3
- package/es/components/skeleton/skeleton_text.js +16 -12
- package/es/components/skeleton/skeleton_title.js +2 -3
- package/es/components/spacer/spacer.js +2 -3
- package/es/components/text/text.js +2 -3
- package/es/components/text/text_align.js +1 -2
- package/es/components/text/text_align.styles.js +5 -7
- package/es/components/text/text_color.js +2 -3
- package/es/components/title/title.js +2 -3
- package/es/components/title/title.styles.js +0 -7
- 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/global_styling/mixins/_typography.js +17 -6
- 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/index.js +1 -1
- package/es/services/theme/style_memoization.js +47 -14
- package/es/themes/amsterdam/global_styling/mixins/button.js +47 -24
- package/eui.d.ts +2862 -2748
- package/i18ntokens.json +267 -267
- 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 -328
- package/lib/components/breadcrumbs/breadcrumb.styles.js +5 -29
- package/lib/components/breadcrumbs/breadcrumbs.js +7 -5
- package/lib/components/breadcrumbs/types.js +5 -0
- package/lib/components/button/button_display/_button_display.js +1 -2
- package/lib/components/button/button_empty/button_empty.js +1 -2
- package/lib/components/button/button_group/button_group.js +18 -6
- package/lib/components/button/button_group/button_group.styles.js +11 -14
- 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/button/button_icon/button_icon.js +3 -4
- package/lib/components/button/button_icon/button_icon.styles.js +10 -2
- package/lib/components/datagrid/body/cell/data_grid_cell.js +100 -58
- 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 +34 -31
- package/lib/components/datagrid/body/cell/index.js +2 -2
- package/lib/components/datagrid/body/data_grid_body.js +14 -0
- package/lib/components/datagrid/body/data_grid_body_custom.js +53 -34
- package/lib/components/datagrid/body/data_grid_body_virtualized.js +86 -55
- package/lib/components/datagrid/body/data_grid_row_manager.js +6 -4
- 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 +45 -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/facet/facet_button.styles.js +1 -2
- 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 +7 -7
- package/lib/components/icon/icon.js +12 -15
- package/lib/components/icon/icon.styles.js +5 -8
- package/lib/components/link/external_link_icon.js +10 -7
- package/lib/components/link/link.js +1 -2
- package/lib/components/link/link.styles.js +6 -14
- 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/page/page_header/page_header_content.js +4 -2
- package/lib/components/progress/progress.styles.js +1 -1
- package/lib/components/skeleton/skeleton_circle.js +1 -2
- package/lib/components/skeleton/skeleton_rectangle.js +1 -2
- package/lib/components/skeleton/skeleton_text.js +18 -11
- package/lib/components/skeleton/skeleton_title.js +1 -2
- package/lib/components/spacer/spacer.js +1 -2
- package/lib/components/text/text.js +1 -2
- package/lib/components/text/text_align.js +1 -2
- package/lib/components/text/text_align.styles.js +5 -7
- package/lib/components/text/text_color.js +1 -2
- package/lib/components/title/title.js +1 -2
- package/lib/components/title/title.styles.js +2 -10
- 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/global_styling/mixins/_typography.js +27 -19
- 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/index.js +6 -0
- package/lib/services/theme/style_memoization.js +49 -16
- package/lib/themes/amsterdam/global_styling/mixins/button.js +49 -25
- 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 -109
- 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_display/_button_display.js +2 -3
- package/optimize/es/components/button/button_empty/button_empty.js +2 -3
- package/optimize/es/components/button/button_group/button_group.js +5 -7
- package/optimize/es/components/button/button_group/button_group.styles.js +11 -14
- 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/button/button_icon/button_icon.js +4 -5
- package/optimize/es/components/button/button_icon/button_icon.styles.js +8 -3
- package/optimize/es/components/datagrid/body/cell/data_grid_cell.js +83 -56
- 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 +34 -31
- package/optimize/es/components/datagrid/body/cell/index.js +1 -1
- package/optimize/es/components/datagrid/body/data_grid_body_custom.js +40 -35
- package/optimize/es/components/datagrid/body/data_grid_body_virtualized.js +71 -49
- package/optimize/es/components/datagrid/body/data_grid_row_manager.js +7 -5
- 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 +47 -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/facet/facet_button.styles.js +1 -2
- 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/icon/icon.js +13 -16
- package/optimize/es/components/icon/icon.styles.js +6 -9
- package/optimize/es/components/link/external_link_icon.js +11 -8
- package/optimize/es/components/link/link.js +2 -3
- package/optimize/es/components/link/link.styles.js +4 -10
- 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/progress/progress.styles.js +2 -2
- package/optimize/es/components/skeleton/skeleton_circle.js +2 -3
- package/optimize/es/components/skeleton/skeleton_rectangle.js +2 -3
- package/optimize/es/components/skeleton/skeleton_text.js +16 -12
- package/optimize/es/components/skeleton/skeleton_title.js +2 -3
- package/optimize/es/components/spacer/spacer.js +2 -3
- package/optimize/es/components/text/text.js +2 -3
- package/optimize/es/components/text/text_align.js +1 -2
- package/optimize/es/components/text/text_align.styles.js +5 -7
- package/optimize/es/components/text/text_color.js +2 -3
- package/optimize/es/components/title/title.js +2 -3
- package/optimize/es/components/title/title.styles.js +0 -7
- 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/global_styling/mixins/_typography.js +14 -6
- 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/index.js +1 -1
- package/optimize/es/services/theme/style_memoization.js +47 -14
- package/optimize/es/themes/amsterdam/global_styling/mixins/button.js +47 -24
- 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 -112
- 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_display/_button_display.js +1 -2
- package/optimize/lib/components/button/button_empty/button_empty.js +1 -2
- package/optimize/lib/components/button/button_group/button_group.js +4 -6
- package/optimize/lib/components/button/button_group/button_group.styles.js +11 -14
- 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/button/button_icon/button_icon.js +3 -4
- package/optimize/lib/components/button/button_icon/button_icon.styles.js +8 -2
- package/optimize/lib/components/datagrid/body/cell/data_grid_cell.js +81 -55
- 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 +34 -31
- package/optimize/lib/components/datagrid/body/cell/index.js +2 -2
- package/optimize/lib/components/datagrid/body/data_grid_body_custom.js +39 -34
- package/optimize/lib/components/datagrid/body/data_grid_body_virtualized.js +72 -50
- package/optimize/lib/components/datagrid/body/data_grid_row_manager.js +6 -4
- 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 +45 -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/facet/facet_button.styles.js +1 -2
- 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/icon/icon.js +12 -15
- package/optimize/lib/components/icon/icon.styles.js +5 -8
- package/optimize/lib/components/link/external_link_icon.js +10 -7
- package/optimize/lib/components/link/link.js +1 -2
- package/optimize/lib/components/link/link.styles.js +6 -14
- 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/progress/progress.styles.js +1 -1
- package/optimize/lib/components/skeleton/skeleton_circle.js +1 -2
- package/optimize/lib/components/skeleton/skeleton_rectangle.js +1 -2
- package/optimize/lib/components/skeleton/skeleton_text.js +18 -11
- package/optimize/lib/components/skeleton/skeleton_title.js +1 -2
- package/optimize/lib/components/spacer/spacer.js +1 -2
- package/optimize/lib/components/text/text.js +1 -2
- package/optimize/lib/components/text/text_align.js +1 -2
- package/optimize/lib/components/text/text_align.styles.js +5 -7
- package/optimize/lib/components/text/text_color.js +1 -2
- package/optimize/lib/components/title/title.js +1 -2
- package/optimize/lib/components/title/title.styles.js +2 -10
- 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/global_styling/mixins/_typography.js +25 -19
- 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/index.js +6 -0
- package/optimize/lib/services/theme/style_memoization.js +49 -16
- package/optimize/lib/themes/amsterdam/global_styling/mixins/button.js +49 -26
- package/package.json +3 -3
- package/src/components/datagrid/_data_grid_data_row.scss +4 -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 -323
- package/test-env/components/breadcrumbs/breadcrumb.styles.js +5 -29
- package/test-env/components/breadcrumbs/breadcrumbs.js +7 -5
- package/test-env/components/breadcrumbs/types.js +5 -0
- package/test-env/components/button/button_display/_button_display.js +1 -2
- package/test-env/components/button/button_empty/button_empty.js +1 -2
- package/test-env/components/button/button_group/button_group.js +18 -6
- package/test-env/components/button/button_group/button_group.styles.js +11 -14
- 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/button/button_icon/button_icon.js +3 -4
- package/test-env/components/button/button_icon/button_icon.styles.js +8 -2
- package/test-env/components/datagrid/body/cell/data_grid_cell.js +100 -58
- 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 +34 -31
- package/test-env/components/datagrid/body/cell/index.js +2 -2
- package/test-env/components/datagrid/body/data_grid_body.js +14 -0
- package/test-env/components/datagrid/body/data_grid_body_custom.js +53 -34
- package/test-env/components/datagrid/body/data_grid_body_virtualized.js +86 -55
- package/test-env/components/datagrid/body/data_grid_row_manager.js +6 -4
- 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 +45 -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/facet/facet_button.styles.js +1 -2
- 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 +7 -7
- package/test-env/components/icon/icon.styles.js +5 -8
- package/test-env/components/link/external_link_icon.js +10 -7
- package/test-env/components/link/link.js +1 -2
- package/test-env/components/link/link.styles.js +6 -14
- package/test-env/components/modal/confirm_modal.js +2 -1
- package/test-env/components/modal/modal.js +12 -3
- package/test-env/components/page/page_header/page_header_content.js +4 -2
- package/test-env/components/progress/progress.styles.js +1 -1
- package/test-env/components/skeleton/skeleton_circle.js +1 -2
- package/test-env/components/skeleton/skeleton_rectangle.js +1 -2
- package/test-env/components/skeleton/skeleton_text.js +18 -11
- package/test-env/components/skeleton/skeleton_title.js +1 -2
- package/test-env/components/spacer/spacer.js +1 -2
- package/test-env/components/text/text.js +1 -2
- package/test-env/components/text/text_align.js +1 -2
- package/test-env/components/text/text_align.styles.js +5 -7
- package/test-env/components/text/text_color.js +1 -2
- package/test-env/components/title/title.js +1 -2
- package/test-env/components/title/title.styles.js +2 -10
- 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/global_styling/mixins/_typography.js +25 -19
- 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/index.js +6 -0
- package/test-env/services/theme/style_memoization.js +49 -16
- package/test-env/themes/amsterdam/global_styling/mixins/button.js +49 -26
- package/src/themes/charts/theme.scss +0 -5
|
@@ -12,128 +12,113 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
12
12
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
13
13
|
* Side Public License, v 1.
|
|
14
14
|
*/
|
|
15
|
-
var
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
// 1. Allow EuiPanels to expand to fill the item.
|
|
122
|
-
euiFlexItem: _ref13,
|
|
123
|
-
growZero: _ref12,
|
|
124
|
-
grow: _ref11,
|
|
125
|
-
growSizes: {
|
|
126
|
-
'1': _ref10,
|
|
127
|
-
'2': _ref9,
|
|
128
|
-
'3': _ref8,
|
|
129
|
-
'4': _ref7,
|
|
130
|
-
'5': _ref6,
|
|
131
|
-
'6': _ref5,
|
|
132
|
-
'7': _ref4,
|
|
133
|
-
'8': _ref3,
|
|
134
|
-
'9': _ref2,
|
|
135
|
-
'10': _ref
|
|
15
|
+
var euiFlexItemStyles = {
|
|
16
|
+
// 1. Allow EuiPanels to expand to fill the item.
|
|
17
|
+
euiFlexItem: process.env.NODE_ENV === "production" ? {
|
|
18
|
+
name: "19hf44n-euiFlexItem",
|
|
19
|
+
styles: "display:flex;flex-direction:column;label:euiFlexItem;"
|
|
20
|
+
} : {
|
|
21
|
+
name: "19hf44n-euiFlexItem",
|
|
22
|
+
styles: "display:flex;flex-direction:column;label:euiFlexItem;",
|
|
23
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
24
|
+
},
|
|
25
|
+
growZero: process.env.NODE_ENV === "production" ? {
|
|
26
|
+
name: "1pat7n0-growZero",
|
|
27
|
+
styles: "flex-grow:0;flex-basis:auto;label:growZero;"
|
|
28
|
+
} : {
|
|
29
|
+
name: "1pat7n0-growZero",
|
|
30
|
+
styles: "flex-grow:0;flex-basis:auto;label:growZero;",
|
|
31
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
32
|
+
},
|
|
33
|
+
grow: process.env.NODE_ENV === "production" ? {
|
|
34
|
+
name: "tr4wer-grow",
|
|
35
|
+
styles: "flex-basis:0%;label:grow;"
|
|
36
|
+
} : {
|
|
37
|
+
name: "tr4wer-grow",
|
|
38
|
+
styles: "flex-basis:0%;label:grow;",
|
|
39
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
40
|
+
},
|
|
41
|
+
growSizes: {
|
|
42
|
+
'1': process.env.NODE_ENV === "production" ? {
|
|
43
|
+
name: "1v6uyoj-1",
|
|
44
|
+
styles: "flex-grow:1;label:1;"
|
|
45
|
+
} : {
|
|
46
|
+
name: "1v6uyoj-1",
|
|
47
|
+
styles: "flex-grow:1;label:1;",
|
|
48
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
49
|
+
},
|
|
50
|
+
'2': process.env.NODE_ENV === "production" ? {
|
|
51
|
+
name: "1l86xxh-2",
|
|
52
|
+
styles: "flex-grow:2;label:2;"
|
|
53
|
+
} : {
|
|
54
|
+
name: "1l86xxh-2",
|
|
55
|
+
styles: "flex-grow:2;label:2;",
|
|
56
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
57
|
+
},
|
|
58
|
+
'3': process.env.NODE_ENV === "production" ? {
|
|
59
|
+
name: "1sl79ay-3",
|
|
60
|
+
styles: "flex-grow:3;label:3;"
|
|
61
|
+
} : {
|
|
62
|
+
name: "1sl79ay-3",
|
|
63
|
+
styles: "flex-grow:3;label:3;",
|
|
64
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
65
|
+
},
|
|
66
|
+
'4': process.env.NODE_ENV === "production" ? {
|
|
67
|
+
name: "k4pnsg-4",
|
|
68
|
+
styles: "flex-grow:4;label:4;"
|
|
69
|
+
} : {
|
|
70
|
+
name: "k4pnsg-4",
|
|
71
|
+
styles: "flex-grow:4;label:4;",
|
|
72
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
73
|
+
},
|
|
74
|
+
'5': process.env.NODE_ENV === "production" ? {
|
|
75
|
+
name: "1cx5fxs-5",
|
|
76
|
+
styles: "flex-grow:5;label:5;"
|
|
77
|
+
} : {
|
|
78
|
+
name: "1cx5fxs-5",
|
|
79
|
+
styles: "flex-grow:5;label:5;",
|
|
80
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
81
|
+
},
|
|
82
|
+
'6': process.env.NODE_ENV === "production" ? {
|
|
83
|
+
name: "1in9iiy-6",
|
|
84
|
+
styles: "flex-grow:6;label:6;"
|
|
85
|
+
} : {
|
|
86
|
+
name: "1in9iiy-6",
|
|
87
|
+
styles: "flex-grow:6;label:6;",
|
|
88
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
89
|
+
},
|
|
90
|
+
'7': process.env.NODE_ENV === "production" ? {
|
|
91
|
+
name: "fvh3nz-7",
|
|
92
|
+
styles: "flex-grow:7;label:7;"
|
|
93
|
+
} : {
|
|
94
|
+
name: "fvh3nz-7",
|
|
95
|
+
styles: "flex-grow:7;label:7;",
|
|
96
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
97
|
+
},
|
|
98
|
+
'8': process.env.NODE_ENV === "production" ? {
|
|
99
|
+
name: "fjdgzc-8",
|
|
100
|
+
styles: "flex-grow:8;label:8;"
|
|
101
|
+
} : {
|
|
102
|
+
name: "fjdgzc-8",
|
|
103
|
+
styles: "flex-grow:8;label:8;",
|
|
104
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
105
|
+
},
|
|
106
|
+
'9': process.env.NODE_ENV === "production" ? {
|
|
107
|
+
name: "1tyr8p6-9",
|
|
108
|
+
styles: "flex-grow:9;label:9;"
|
|
109
|
+
} : {
|
|
110
|
+
name: "1tyr8p6-9",
|
|
111
|
+
styles: "flex-grow:9;label:9;",
|
|
112
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
113
|
+
},
|
|
114
|
+
'10': process.env.NODE_ENV === "production" ? {
|
|
115
|
+
name: "n7polf-10",
|
|
116
|
+
styles: "flex-grow:10;label:10;"
|
|
117
|
+
} : {
|
|
118
|
+
name: "n7polf-10",
|
|
119
|
+
styles: "flex-grow:10;label:10;",
|
|
120
|
+
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
136
121
|
}
|
|
137
|
-
}
|
|
122
|
+
}
|
|
138
123
|
};
|
|
139
124
|
exports.euiFlexItemStyles = euiFlexItemStyles;
|
|
@@ -111,33 +111,31 @@ var EuiFlyout = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
111
111
|
resizeRef = _useState2[0],
|
|
112
112
|
setResizeRef = _useState2[1];
|
|
113
113
|
var setRef = (0, _services.useCombinedRefs)([setResizeRef, ref]);
|
|
114
|
-
|
|
115
|
-
|
|
114
|
+
var _useResizeObserver = (0, _resize_observer.useResizeObserver)(isPushed ? resizeRef : null, 'width'),
|
|
115
|
+
width = _useResizeObserver.width;
|
|
116
116
|
(0, _react.useEffect)(function () {
|
|
117
|
-
// This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
|
|
118
|
-
document.body.classList.add('euiBody--hasFlyout');
|
|
119
|
-
|
|
120
117
|
/**
|
|
121
118
|
* Accomodate for the `isPushed` state by adding padding to the body equal to the width of the element
|
|
122
119
|
*/
|
|
123
120
|
if (isPushed) {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
document.body.style
|
|
128
|
-
}
|
|
121
|
+
var paddingSide = side === 'left' ? 'paddingInlineStart' : 'paddingInlineEnd';
|
|
122
|
+
document.body.style[paddingSide] = "".concat(width, "px");
|
|
123
|
+
return function () {
|
|
124
|
+
document.body.style[paddingSide] = '';
|
|
125
|
+
};
|
|
129
126
|
}
|
|
127
|
+
}, [isPushed, side, width]);
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* This class doesn't actually do anything by EUI, but is nice to add for consumers (JIC)
|
|
131
|
+
*/
|
|
132
|
+
(0, _react.useEffect)(function () {
|
|
133
|
+
document.body.classList.add('euiBody--hasFlyout');
|
|
130
134
|
return function () {
|
|
135
|
+
// Remove the hasFlyout class when the flyout is unmounted
|
|
131
136
|
document.body.classList.remove('euiBody--hasFlyout');
|
|
132
|
-
if (isPushed) {
|
|
133
|
-
if (side === 'right') {
|
|
134
|
-
document.body.style.paddingInlineEnd = '';
|
|
135
|
-
} else if (side === 'left') {
|
|
136
|
-
document.body.style.paddingInlineStart = '';
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
137
|
};
|
|
140
|
-
}, [
|
|
138
|
+
}, []);
|
|
141
139
|
|
|
142
140
|
/**
|
|
143
141
|
* ESC key closes flyout (always?)
|
|
@@ -7,9 +7,9 @@ exports.EuiHeaderBreadcrumbs = void 0;
|
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
10
|
+
var _services = require("../../../services");
|
|
10
11
|
var _breadcrumbs = require("../../breadcrumbs");
|
|
11
12
|
var _header_breadcrumbs = require("./header_breadcrumbs.styles");
|
|
12
|
-
var _services = require("../../../services");
|
|
13
13
|
var _react2 = require("@emotion/react");
|
|
14
14
|
var _excluded = ["className", "breadcrumbs"];
|
|
15
15
|
/*
|
|
@@ -28,15 +28,13 @@ var EuiHeaderBreadcrumbs = function EuiHeaderBreadcrumbs(_ref) {
|
|
|
28
28
|
breadcrumbs = _ref.breadcrumbs,
|
|
29
29
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
30
30
|
var classes = (0, _classnames.default)('euiHeaderBreadcrumbs', className);
|
|
31
|
-
var
|
|
32
|
-
var styles = (0, _header_breadcrumbs.euiHeaderBreadcrumbsStyles)(euiTheme);
|
|
33
|
-
var cssHeaderBreadcrumbStyles = [styles.euiHeaderBreadcrumbs];
|
|
31
|
+
var styles = (0, _services.useEuiMemoizedStyles)(_header_breadcrumbs.euiHeaderBreadcrumbsStyles);
|
|
34
32
|
return (0, _react2.jsx)(_breadcrumbs.EuiBreadcrumbs, _extends({
|
|
35
33
|
max: 4,
|
|
36
34
|
truncate: true,
|
|
37
35
|
breadcrumbs: breadcrumbs,
|
|
38
36
|
className: classes,
|
|
39
|
-
css:
|
|
37
|
+
css: styles.euiHeaderBreadcrumbs,
|
|
40
38
|
type: "application"
|
|
41
39
|
}, rest));
|
|
42
40
|
};
|
|
@@ -95,12 +93,14 @@ EuiHeaderBreadcrumbs.propTypes = {
|
|
|
95
93
|
*/
|
|
96
94
|
"aria-current": _propTypes.default.any,
|
|
97
95
|
/**
|
|
98
|
-
* Creates a breadcrumb that toggles a popover dialog
|
|
96
|
+
* Creates a breadcrumb that toggles a popover dialog. Takes any rendered node(s),
|
|
97
|
+
* or a render function that will pass callback allowing you to close the
|
|
98
|
+
* breadcrumb popover from within your popover content.
|
|
99
99
|
*
|
|
100
100
|
* If passed, both `href` and `onClick` will be ignored - the breadcrumb's
|
|
101
101
|
* click behavior should only trigger a popover.
|
|
102
102
|
*/
|
|
103
|
-
popoverContent: _propTypes.default.node,
|
|
103
|
+
popoverContent: _propTypes.default.oneOfType([_propTypes.default.node.isRequired, _propTypes.default.func.isRequired]),
|
|
104
104
|
/**
|
|
105
105
|
* Allows customizing the popover if necessary. Accepts any props that
|
|
106
106
|
* [EuiPopover](/#/layout/popover) accepts, except for props that control state.
|
|
@@ -21,7 +21,7 @@ var _services = require("../../services");
|
|
|
21
21
|
var _named_colors = require("./named_colors");
|
|
22
22
|
var _icon = require("./icon.styles");
|
|
23
23
|
var _react3 = require("@emotion/react");
|
|
24
|
-
var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "onIconLoad", "
|
|
24
|
+
var _excluded = ["type", "size", "color", "className", "tabIndex", "title", "onIconLoad", "style", "stylesMemoizer"];
|
|
25
25
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
26
26
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
27
27
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
@@ -206,8 +206,8 @@ var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
206
206
|
tabIndex = _this$props.tabIndex,
|
|
207
207
|
title = _this$props.title,
|
|
208
208
|
onIconLoad = _this$props.onIconLoad,
|
|
209
|
-
theme = _this$props.theme,
|
|
210
209
|
style = _this$props.style,
|
|
210
|
+
stylesMemoizer = _this$props.stylesMemoizer,
|
|
211
211
|
rest = _objectWithoutProperties(_this$props, _excluded);
|
|
212
212
|
var _this$state = this.state,
|
|
213
213
|
isLoading = _this$state.isLoading,
|
|
@@ -229,7 +229,7 @@ var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
229
229
|
var classes = (0, _classnames.default)('euiIcon', className);
|
|
230
230
|
|
|
231
231
|
// Emotion styles
|
|
232
|
-
var styles = (
|
|
232
|
+
var styles = stylesMemoizer(_icon.euiIconStyles);
|
|
233
233
|
var cssStyles = [styles.euiIcon, styles[size], color && (0, _named_colors.isNamedColor)(color) && styles[color], isCustomColor && styles.customColor, isElasticLogoOutline && styles.logoElasticOutline, isAppIcon && !appIconHasColor && styles.app, isLoading && styles.isLoading, !isLoading && neededLoading && styles.isLoaded];
|
|
234
234
|
var icon = this.state.icon || _empty.icon;
|
|
235
235
|
if (typeof icon === 'string') {
|
|
@@ -246,30 +246,27 @@ var EuiIconClass = /*#__PURE__*/function (_PureComponent) {
|
|
|
246
246
|
|
|
247
247
|
// If it's an empty icon, or if there is no aria-label, aria-labelledby, or title it gets aria-hidden true
|
|
248
248
|
var isAriaHidden = icon === _empty.icon || !(this.props['aria-label'] || this.props['aria-labelledby'] || this.props.title);
|
|
249
|
-
var hideIconEmpty = isAriaHidden && {
|
|
250
|
-
'aria-hidden': true
|
|
251
|
-
};
|
|
252
|
-
var titleId;
|
|
253
249
|
|
|
254
250
|
// If no aria-label or aria-labelledby is provided but there's a title, a titleId is generated
|
|
255
251
|
// The svg aria-labelledby attribute gets this titleId
|
|
256
252
|
// The svg title element gets this titleId as an id
|
|
257
|
-
|
|
258
|
-
titleId
|
|
259
|
-
|
|
260
|
-
};
|
|
261
|
-
}
|
|
253
|
+
var titleId = !this.props['aria-label'] && !this.props['aria-labelledby'] && title ? {
|
|
254
|
+
titleId: generateId()
|
|
255
|
+
} : undefined;
|
|
262
256
|
return (0, _react3.jsx)(Svg, _extends({
|
|
263
257
|
className: classes,
|
|
264
258
|
style: optionalCustomStyles,
|
|
265
259
|
css: cssStyles,
|
|
266
260
|
tabIndex: tabIndex,
|
|
267
261
|
role: "img",
|
|
268
|
-
title: title
|
|
262
|
+
title: title
|
|
263
|
+
}, titleId, {
|
|
269
264
|
"data-icon-type": iconTitle,
|
|
270
265
|
"data-is-loaded": isLoaded || undefined,
|
|
271
266
|
"data-is-loading": isLoading || undefined
|
|
272
|
-
},
|
|
267
|
+
}, rest, {
|
|
268
|
+
"aria-hidden": isAriaHidden || undefined
|
|
269
|
+
}));
|
|
273
270
|
}
|
|
274
271
|
}
|
|
275
272
|
}]);
|
|
@@ -311,5 +308,5 @@ EuiIconClass.propTypes = {
|
|
|
311
308
|
*/
|
|
312
309
|
onIconLoad: _propTypes.default.func
|
|
313
310
|
};
|
|
314
|
-
var EuiIcon = (0, _services.
|
|
311
|
+
var EuiIcon = (0, _services.withEuiStylesMemoizer)(EuiIconClass);
|
|
315
312
|
exports.EuiIcon = EuiIcon;
|
|
@@ -15,9 +15,6 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
15
15
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
16
16
|
* Side Public License, v 1.
|
|
17
17
|
*/
|
|
18
|
-
var iconSize = function iconSize(size) {
|
|
19
|
-
return "\n ".concat((0, _global_styling.logicalCSS)('width', size), ";\n ").concat((0, _global_styling.logicalCSS)('height', size), ";\n ");
|
|
20
|
-
};
|
|
21
18
|
var iconLoadingOpacity = 0.05;
|
|
22
19
|
exports.iconLoadingOpacity = iconLoadingOpacity;
|
|
23
20
|
var iconLoading = (0, _react.keyframes)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n 0% {\n opacity: ", ";\n }\n\n 100% {\n opacity: 1;\n }\n"])), iconLoadingOpacity);
|
|
@@ -57,11 +54,11 @@ var euiIconStyles = function euiIconStyles(_ref3) {
|
|
|
57
54
|
logoElasticOutline: _ref,
|
|
58
55
|
// Sizes
|
|
59
56
|
original: /*#__PURE__*/(0, _react.css)(";label:original;"),
|
|
60
|
-
s: /*#__PURE__*/(0, _react.css)(
|
|
61
|
-
m: /*#__PURE__*/(0, _react.css)(
|
|
62
|
-
l: /*#__PURE__*/(0, _react.css)(
|
|
63
|
-
xl: /*#__PURE__*/(0, _react.css)(
|
|
64
|
-
xxl: /*#__PURE__*/(0, _react.css)(
|
|
57
|
+
s: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalSizeCSS)(euiTheme.size.m), ";label:s;"),
|
|
58
|
+
m: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalSizeCSS)(euiTheme.size.base), ";label:m;"),
|
|
59
|
+
l: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalSizeCSS)(euiTheme.size.l), ";label:l;"),
|
|
60
|
+
xl: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalSizeCSS)(euiTheme.size.xl), ";label:xl;"),
|
|
61
|
+
xxl: /*#__PURE__*/(0, _react.css)((0, _global_styling.logicalSizeCSS)(euiTheme.size.xxl), ";label:xxl;"),
|
|
65
62
|
// Variants
|
|
66
63
|
// App icons are two-toned. This provides the base color.
|
|
67
64
|
app: /*#__PURE__*/(0, _react.css)("fill:", euiTheme.colors.text, ";.euiIcon__fillSecondary{fill:", euiTheme.colors.successText, ";};label:app;"),
|
|
@@ -28,16 +28,19 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
28
28
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
29
29
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
30
30
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
31
|
-
var
|
|
32
|
-
var
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
31
|
+
var iconStyle = function iconStyle(_ref) {
|
|
32
|
+
var euiTheme = _ref.euiTheme;
|
|
33
|
+
return (0, _global_styling.logicalStyle)('margin-left', euiTheme.size.xs);
|
|
34
|
+
};
|
|
35
|
+
var EuiExternalLinkIcon = function EuiExternalLinkIcon(_ref2) {
|
|
36
|
+
var target = _ref2.target,
|
|
37
|
+
external = _ref2.external,
|
|
38
|
+
rest = _objectWithoutProperties(_ref2, _excluded);
|
|
39
|
+
var iconCssStyle = (0, _services.useEuiMemoizedStyles)(iconStyle);
|
|
37
40
|
var showExternalLinkIcon = target === '_blank' && external !== false || external === true;
|
|
38
41
|
var iconAriaLabel = (0, _i18n.useEuiI18n)('euiExternalLinkIcon.ariaLabel', 'External link');
|
|
39
42
|
return (0, _react2.jsx)(_react.default.Fragment, null, showExternalLinkIcon && (0, _react2.jsx)(_icon.EuiIcon, _extends({
|
|
40
|
-
css:
|
|
43
|
+
css: iconCssStyle,
|
|
41
44
|
"aria-label": iconAriaLabel,
|
|
42
45
|
size: "s",
|
|
43
46
|
type: "popout"
|
|
@@ -48,8 +48,7 @@ var EuiLink = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
48
48
|
onClick = _ref.onClick,
|
|
49
49
|
_disabled = _ref.disabled,
|
|
50
50
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
51
|
-
var
|
|
52
|
-
var styles = (0, _link.euiLinkStyles)(euiTheme);
|
|
51
|
+
var styles = (0, _services.useEuiMemoizedStyles)(_link.euiLinkStyles);
|
|
53
52
|
var cssStyles = [styles.euiLink];
|
|
54
53
|
var isHrefValid = !href || (0, _href_validator.validateHref)(href);
|
|
55
54
|
var disabled = _disabled || !isHrefValid;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.euiLinkStyles = exports.
|
|
6
|
+
exports.euiLinkStyles = exports.euiLinkCSS = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
8
|
var _global_styling = require("../../global_styling");
|
|
9
9
|
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)."; } /*
|
|
@@ -13,20 +13,9 @@ function _EMOTION_STRINGIFIED_CSS_ERROR__() { return "You have tried to stringif
|
|
|
13
13
|
* in compliance with, at your election, the Elastic License 2.0 or the Server
|
|
14
14
|
* Side Public License, v 1.
|
|
15
15
|
*/
|
|
16
|
-
var _colorCSS = function _colorCSS(color) {
|
|
17
|
-
return "\n color: ".concat(color, ";\n\n &:target {\n color: darken(").concat(color, ", 10%);\n }\n ");
|
|
18
|
-
};
|
|
19
|
-
var euiLinkHoverCSS = function euiLinkHoverCSS() {
|
|
20
|
-
return "\n text-decoration: underline;\n ";
|
|
21
|
-
};
|
|
22
|
-
exports.euiLinkHoverCSS = euiLinkHoverCSS;
|
|
23
|
-
var euiLinkFocusCSS = function euiLinkFocusCSS(euiTheme) {
|
|
24
|
-
return "\n text-decoration: underline;\n text-decoration-thickness: ".concat(euiTheme.border.width.thick, ";\n ");
|
|
25
|
-
};
|
|
26
|
-
exports.euiLinkFocusCSS = euiLinkFocusCSS;
|
|
27
16
|
var euiLinkCSS = function euiLinkCSS(euiThemeContext) {
|
|
28
17
|
var euiTheme = euiThemeContext.euiTheme;
|
|
29
|
-
return "\n font-weight: ".concat(euiTheme.font.weight.medium, ";\n ").concat((0, _global_styling.logicalTextAlignCSS)('left'), "\n\n &:hover {\n
|
|
18
|
+
return "\n font-weight: ".concat(euiTheme.font.weight.medium, ";\n ").concat((0, _global_styling.logicalTextAlignCSS)('left'), "\n\n &:hover {\n text-decoration: underline;\n }\n\n &:focus {\n ").concat((0, _global_styling.euiFocusRing)(euiThemeContext, 'outset'), "\n text-decoration: underline;\n text-decoration-thickness: ").concat(euiTheme.border.width.thick, ";\n }\n ");
|
|
30
19
|
};
|
|
31
20
|
exports.euiLinkCSS = euiLinkCSS;
|
|
32
21
|
var _ref = process.env.NODE_ENV === "production" ? {
|
|
@@ -53,4 +42,7 @@ var euiLinkStyles = function euiLinkStyles(euiThemeContext) {
|
|
|
53
42
|
text: /*#__PURE__*/(0, _react.css)(_colorCSS(euiTheme.colors.text), ";label:text;")
|
|
54
43
|
};
|
|
55
44
|
};
|
|
56
|
-
exports.euiLinkStyles = euiLinkStyles;
|
|
45
|
+
exports.euiLinkStyles = euiLinkStyles;
|
|
46
|
+
var _colorCSS = function _colorCSS(color) {
|
|
47
|
+
return "\n color: ".concat(color, ";\n\n &:target {\n color: darken(").concat(color, ", 10%);\n }\n ");
|
|
48
|
+
};
|
|
@@ -85,7 +85,8 @@ var EuiConfirmModal = function EuiConfirmModal(_ref) {
|
|
|
85
85
|
return (0, _react2.jsx)(_modal.EuiModal, _extends({
|
|
86
86
|
className: classes,
|
|
87
87
|
css: cssStyles,
|
|
88
|
-
onClose: onCancel
|
|
88
|
+
onClose: onCancel,
|
|
89
|
+
role: "alertdialog"
|
|
89
90
|
}, rest), modalTitle, message && (0, _react2.jsx)(_modal_body.EuiModalBody, null, (0, _react2.jsx)(_text.EuiText, {
|
|
90
91
|
"data-test-subj": "confirmModalBodyText"
|
|
91
92
|
}, message)), (0, _react2.jsx)(_modal_footer.EuiModalFooter, null, (0, _react2.jsx)(_button.EuiButtonEmpty, {
|
|
@@ -15,7 +15,7 @@ var _overlay_mask = require("../overlay_mask");
|
|
|
15
15
|
var _i18n = require("../i18n");
|
|
16
16
|
var _modal = require("./modal.styles");
|
|
17
17
|
var _react2 = require("@emotion/react");
|
|
18
|
-
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "style"];
|
|
18
|
+
var _excluded = ["className", "children", "initialFocus", "onClose", "maxWidth", "role", "style"];
|
|
19
19
|
/*
|
|
20
20
|
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
|
|
21
21
|
* or more contributor license agreements. Licensed under the Elastic License
|
|
@@ -39,6 +39,8 @@ var EuiModal = function EuiModal(_ref) {
|
|
|
39
39
|
onClose = _ref.onClose,
|
|
40
40
|
_ref$maxWidth = _ref.maxWidth,
|
|
41
41
|
maxWidth = _ref$maxWidth === void 0 ? true : _ref$maxWidth,
|
|
42
|
+
_ref$role = _ref.role,
|
|
43
|
+
role = _ref$role === void 0 ? 'dialog' : _ref$role,
|
|
42
44
|
style = _ref.style,
|
|
43
45
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
44
46
|
var onKeyDown = function onKeyDown(event) {
|
|
@@ -68,7 +70,9 @@ var EuiModal = function EuiModal(_ref) {
|
|
|
68
70
|
className: classes,
|
|
69
71
|
onKeyDown: onKeyDown,
|
|
70
72
|
tabIndex: 0,
|
|
71
|
-
style: newStyle
|
|
73
|
+
style: newStyle,
|
|
74
|
+
role: role,
|
|
75
|
+
"aria-modal": true
|
|
72
76
|
}, rest), (0, _react2.jsx)(_i18n.EuiI18n, {
|
|
73
77
|
token: "euiModal.closeModal",
|
|
74
78
|
default: "Closes this modal window"
|
|
@@ -103,5 +107,10 @@ EuiModal.propTypes = {
|
|
|
103
107
|
* Specifies what element should initially have focus.
|
|
104
108
|
* Can be a DOM node, or a selector string (which will be passed to document.querySelector() to find the DOM node), or a function that returns a DOM node.
|
|
105
109
|
*/
|
|
106
|
-
initialFocus: _propTypes.default.oneOfType([_propTypes.default.any.isRequired, _propTypes.default.func.isRequired, _propTypes.default.string.isRequired])
|
|
110
|
+
initialFocus: _propTypes.default.oneOfType([_propTypes.default.any.isRequired, _propTypes.default.func.isRequired, _propTypes.default.string.isRequired]),
|
|
111
|
+
/**
|
|
112
|
+
* Identifies a modal dialog to screen readers. Modal dialogs that confirm destructive actions
|
|
113
|
+
* or need a user's attention should use "alertdialog".
|
|
114
|
+
*/
|
|
115
|
+
role: _propTypes.default.oneOf(["dialog", "alertdialog"])
|
|
107
116
|
};
|
|
@@ -49,14 +49,13 @@ var EuiResizeObserver = /*#__PURE__*/function (_EuiObserver) {
|
|
|
49
49
|
height: 0,
|
|
50
50
|
width: 0
|
|
51
51
|
});
|
|
52
|
-
_defineProperty(_assertThisInitialized(_this), "onResize", function () {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
width = _this$childNode$getBo.width;
|
|
52
|
+
_defineProperty(_assertThisInitialized(_this), "onResize", function (_ref) {
|
|
53
|
+
var _ref2 = _slicedToArray(_ref, 1),
|
|
54
|
+
entry = _ref2[0];
|
|
55
|
+
var _entry$borderBoxSize$ = entry.borderBoxSize[0],
|
|
56
|
+
width = _entry$borderBoxSize$.inlineSize,
|
|
57
|
+
height = _entry$borderBoxSize$.blockSize;
|
|
58
|
+
|
|
60
59
|
// Check for actual resize event
|
|
61
60
|
if (_this.state.height === height && _this.state.width === width) {
|
|
62
61
|
return;
|
|
@@ -111,23 +110,15 @@ var useResizeObserver = function useResizeObserver(container, dimension) {
|
|
|
111
110
|
}, [dimension]);
|
|
112
111
|
(0, _react.useEffect)(function () {
|
|
113
112
|
if (container != null) {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
});
|
|
121
|
-
var observer = makeResizeObserver(container, function () {
|
|
122
|
-
// `entry.contentRect` provides incomplete `height` and `width` data.
|
|
123
|
-
// Use `getBoundingClientRect` to account for padding and border.
|
|
124
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/DOMRectReadOnly
|
|
125
|
-
var _container$getBoundin = container.getBoundingClientRect(),
|
|
126
|
-
height = _container$getBoundin.height,
|
|
127
|
-
width = _container$getBoundin.width;
|
|
113
|
+
var observer = makeResizeObserver(container, function (_ref3) {
|
|
114
|
+
var _ref4 = _slicedToArray(_ref3, 1),
|
|
115
|
+
entry = _ref4[0];
|
|
116
|
+
var _entry$borderBoxSize$2 = entry.borderBoxSize[0],
|
|
117
|
+
inlineSize = _entry$borderBoxSize$2.inlineSize,
|
|
118
|
+
blockSize = _entry$borderBoxSize$2.blockSize;
|
|
128
119
|
setSize({
|
|
129
|
-
width:
|
|
130
|
-
height:
|
|
120
|
+
width: inlineSize,
|
|
121
|
+
height: blockSize
|
|
131
122
|
});
|
|
132
123
|
});
|
|
133
124
|
return function () {
|